@@ -47,25 +47,27 | |||
|
47 | 47 | </h4> |
|
48 | 48 | </div> |
|
49 | 49 | |
|
50 |
<div id="collapseTwo-{{ location. |
|
|
50 | <div id="collapseTwo-{{ location.id }}" class="panel-collapse collapse in" role="tabpanel" aria-labelledby="headingTwo"> | |
|
51 | 51 | <div class="panel-body"> |
|
52 | 52 | <table class="table table-hover"> |
|
53 | 53 | <tr> |
|
54 | <th>#</th> | |
|
54 | ||
|
55 | 55 | {% for header in experiment_keys %} |
|
56 | 56 | <th>{{ header|title }}</th> |
|
57 | 57 | {% endfor%} |
|
58 | 58 | </tr> |
|
59 | 59 | |
|
60 | 60 | {% for item in experiments %} |
|
61 | {% if location.name in item.location.name %} | |
|
62 |
<tr class="clickable-row" data-href="{% url 'url_experiment' |
|
|
63 | <td>{{ forloop.counter }}</td> | |
|
61 | {% for exs in item %} | |
|
62 | <tr class="clickable-row" data-href="{% url 'url_experiment' exs.id %}" > | |
|
63 | ||
|
64 | 64 | {% for key in experiment_keys %} |
|
65 | <td>{{ item|value:key }}</td> | |
|
65 | {% if location.name in exs.location.name %} | |
|
66 | <td>{{ exs|value:key }}</td> | |
|
67 | {% endif %} | |
|
66 | 68 | {% endfor %} |
|
69 | {% endfor %} | |
|
67 | 70 | </tr> |
|
68 | {% endif %} | |
|
69 | 71 | {% endfor %} |
|
70 | 72 | </table> |
|
71 | 73 | </div> |
@@ -776,8 +776,9 def operation(request, id_camp=None): | |||
|
776 | 776 | if form.is_valid(): |
|
777 | 777 | return redirect('url_operation', id_camp=campaign.id) |
|
778 | 778 | |
|
779 | locations = Location.objects.filter(experiment__campaign = campaign) | |
|
779 | locations = Location.objects.filter(experiment__campaign__pk = campaign.id) | |
|
780 | 780 | experiments = Experiment.objects.filter(campaign=campaign) |
|
781 | experiments = [Experiment.objects.filter(location__pk=location.id) for location in locations] | |
|
781 | 782 | |
|
782 | 783 | kwargs = {} |
|
783 | 784 | #---Campaign |
General Comments 0
You need to be logged in to leave comments.
Login now