Version brouillon qui marche à peu près
This commit is contained in:
35
index.html
Normal file
35
index.html
Normal file
@ -0,0 +1,35 @@
|
||||
{{#restrict section="accounting" level="write" block=true}}{{/restrict}}
|
||||
{{:admin_header title="Liste des scrutins"}}
|
||||
|
||||
<nav class="tabs">
|
||||
<aside>
|
||||
{{:linkbutton href="edit.html" label="Nouveau scrutin" shape="plus"}}
|
||||
</aside>
|
||||
</nav>
|
||||
|
||||
{{#list select="$$.name AS 'Scrutin'" order=1 desc=true}}
|
||||
{{:assign var="qs" name=$name desc=$desc question=$question activity_see=$activity_see}}
|
||||
{{:assign qs=$qs|http_build_query}}
|
||||
{{:assign url="!voter/results.php?%s"|args:$qs}}
|
||||
{{*Forbid visibility if not member of activity*}}
|
||||
{{if $activity_see}}
|
||||
{{#sql select="*" tables="services_users" where="id_service = :id_act AND id_user = :id_user" :id_act=$activity_see :id_user=$logged_user.id count="TRUE"}}
|
||||
{{if !$count}}
|
||||
{{:continue 2}}
|
||||
{{/if}}
|
||||
{{/sql}}
|
||||
{{/if}}
|
||||
<tr>
|
||||
<th>{{$name}}</th>
|
||||
<td class="actions">
|
||||
{{:linkbutton href="result.html?id=%d"|args:$id label="Voir les résultats" shape="eye"}}
|
||||
{{:linkbutton href="vote.html?id=%d"|args:$id label="Voter" shape="check"}}
|
||||
{{:linkbutton href="edit.html?id=%d"|args:$id label="Modifier" shape="edit"}}
|
||||
{{:linkbutton target="_dialog" href="delete.html?id=%d"|args:$id label="Supprimer" shape="delete"}}
|
||||
</td>
|
||||
</tr>
|
||||
{{else}}
|
||||
<p class="alert block">
|
||||
Aucun scrutin.
|
||||
</p>
|
||||
{{/list}}
|
||||
Reference in New Issue
Block a user