]> git.agnieray.net Git - galette.git/blob - galette/templates/default/elements/edit_entitleds.html.twig
dbd1eb32659aaf095ed769ada733d785624fc10f
[galette.git] / galette / templates / default / elements / edit_entitleds.html.twig
1 {% if class == 'Status' %}
2 <div class="ui icon info visible message">
3 <i class="info circle blue icon" aria-hidden="true"></i>
4 <div class="content">
5 {{ _T("Note: members with a status priority lower than %priority are staff members.")|replace({'%priority': non_staff_priority}) }}
6 </div>
7 </div>
8 {% endif %}
9 <div class="ui basic fitted segment loader_selector">
10 <table class="listing ui celled striped table">
11 <thead>
12 <tr>
13 <th class="id_row">#</th>
14 <th>{{ _T("Name") }}</th>
15 {% if class == 'ContributionsTypes' %}
16 <th>{{ _T("Extends membership?") }}</th>
17 {% elseif class == 'Status' %}
18 <th>{{ _T("Priority") }}</th>
19 {% endif %}
20 <th>{{ _T("Actions") }}</th>
21 </tr>
22 </thead>
23 <tfoot>
24 <tr>
25 <td data-scope="row">
26 <span class="displaynone">
27 {% if class == 'Status' %}
28 {{ _T("New status") }}
29 {% else %}
30 {{ _T("New contribution type") }}
31 {% endif %}
32 </span>
33 </td>
34 <td class="left" data-title="{{ _T("Name") }}">
35 <div class="required field">
36 <label for="name" class="displaynone">{{ _T("Name") }}</label>
37 <input size="40" type="text" name="{{ fields.libelle }}" required="required"/>
38 </div>
39 </td>
40 <td class="left" data-title="{% if class == 'ContributionsTypes' %}{{ _T("Extends membership?") }}{% else %}{{ _T("Priority") }}{% endif %}">
41 {% if class == 'ContributionsTypes' %}
42 <select name="{{ fields.third }}" class="ui dropdown nochosen">
43 <option value="0" selected="selected">{{ _T("No") }}</option>
44 <option value="1">{{ _T("Yes") }}</option>
45 </select>
46 {% elseif class == 'Status' %}
47 <input size="4" type="text" name="{{ fields.third }}" value="99" />
48 {% endif %}
49 </td>
50 <td class="center actions_row">
51 <input type="hidden" name="new" value="1" />
52 <input type="hidden" name="class" value="{{ class }}" />
53 <button type="submit" name="valid" class="ui labeled icon button">
54 <i class="plus green icon" aria-hidden="true"></i>
55 {{ _T("Add") }}
56 </button>
57 </td>
58 </tr>
59 </tfoot>
60 <tbody>
61 {% for eid, entry in entries %}
62 <tr>
63 <td data-scope="row">
64 {{ eid }}
65 <span class="displaynone">
66 <a href="{{ url_for('editEntitled', {'class': url_class, 'action': 'edit', 'id': eid}) }}">
67 {{ _T("%s field")|replace({'%s': entry.name|escape}) }}
68 </a>
69 </span>
70 </td>
71 <td class="left" data-title="{{ _T("Name") }}">
72 {% if class == 'Status' %}
73 {% if entry.extra < 30 %}
74 <span>
75 <i class="ui user tie icon tooltip" aria-hidden="true"></i>
76 <span class="ui special popup">{{ _T("Staff member") }}</span>
77 </span>
78 {% else %}
79 <i class="ui icon">&nbsp;</i>
80 {% endif %}
81 {% endif %}
82 {{ entry.name|escape }}
83 </td>
84 <td data-title="{% if class == 'ContributionsTypes' %}{{ _T("Extends membership?") }}{% else %}{{ _T("Priority") }}{% endif %}">
85 {% if class == 'ContributionsTypes' %}
86 {% if entry.extra == 1 %}
87 {{ _T("Yes") }}
88 {% else %}
89 {{ _T("No") }}
90 {% endif %}
91 {% elseif class == 'Status' %}
92 {{ entry.extra }}
93 {% endif %}
94 </td>
95 <td class="center actions_row">
96 <a
97 href="{{ url_for('editEntitled', {'class': url_class, 'action': 'edit', 'id': eid}) }}"
98 class="action single-edit"
99 >
100 <i class="ui edit icon tooltip" aria-hidden="true"></i>
101 <span class="ui special popup">{{ _T("Edit '%s' field")|replace({'%s': entry.name|escape}) }}</span>
102 </a>
103 <a
104 href="{{ url_for('removeEntitled', {'class': url_class, 'id': eid}) }}"
105 class="delete"
106 >
107 <i class="ui trash red icon tooltip" aria-hidden="true"></i>
108 <span class="ui special popup">{{ _T("Delete '%s' field")|replace({'%s': entry.name|escape}) }}</span>
109 </a>
110 </td>
111 </tr>
112 {% endfor %}
113 </tbody>
114 </table>
115 </div>