X-Git-Url: http://git.polytechnique.org/?a=blobdiff_plain;f=templates%2Fsurvey%2Findex.tpl;h=81c3b7315217e78a8f7a38786828cabb6b6aea06;hb=173ff0bdf41db90ee0995e0c3bf844bf2151d0e6;hp=0610d0de97fb48e97160bbf4aa3f3f94d357ddf3;hpb=02125f198deab9cdf58e4fa6f0136e54edae57ac;p=platal.git diff --git a/templates/survey/index.tpl b/templates/survey/index.tpl index 0610d0d..81c3b73 100644 --- a/templates/survey/index.tpl +++ b/templates/survey/index.tpl @@ -1,6 +1,6 @@ {**************************************************************************} {* *} -{* Copyright (C) 2003-2008 Polytechnique.org *} +{* Copyright (C) 2003-2011 Polytechnique.org *} {* http://opensource.polytechnique.org/ *} {* *} {* This program is free software; you can redistribute it and/or modify *} @@ -22,50 +22,66 @@

Sondages

+{* Survey::MODE_ALL equals 0. *} +{assign var=SurveyMODE_ALL value=0} +{if $survey_current->total() > 0 || $smarty.session.auth} - {iterate item=s from=$survey_current} - {if $smarty.session.auth || $s.mode == Survey::MODE_ALL} + {if $smarty.session.auth || $s.mode == $SurveyMODE_ALL} - + + {assign var="has_cs" value="true"} {/if} {/iterate} + {if hasPerm('user')} - + {/if}
+ Sondages en cours
- • - - {$s.title} [{$s.end|date_format:"%x"} - {$survey_modes[$s.mode]}] - + + {$s.title} + {if $s.uid eq $smarty.session.user->id() || hasPerm('admin')} + (résultats partiels) + {/if} + + {$s.end|date_format:"%x"} + + {$survey_modes[$s.mode]}
- {if !$has_cs}Aucun sondage en cours{/if} - {if $smarty.session.auth}{icon name=page_edit} Proposer un sondage{/if} + + {if $smarty.session.auth}{icon name=page_edit} Proposer un sondage{/if}
+{/if}
- {iterate item=s from=$survey_old} - {if $smarty.session.auth || $s.mode == Survey::MODE_ALL} + {if $smarty.session.auth || $s.mode == $SurveyMODE_ALL} - + + {assign var="has_os" value="true"} {/if}
+ Anciens sondages
- • + - {$s.title} [{$s.end|date_format:"%x"} - {$survey_modes[$s.mode]}] + {$s.title} + {$s.end|date_format:"%x"} + + {$survey_modes[$s.mode]} +