diff --git a/studs.php b/studs.php index f202c4a..ee8dba9 100644 --- a/studs.php +++ b/studs.php @@ -50,6 +50,8 @@ $resultPubliclyVisible = true; $slots = []; $votes = []; $comments = []; +$selectedNewVotes = []; + /* Services */ /*----------*/ @@ -180,6 +182,7 @@ if ($accessGranted) { } } catch (AlreadyExistsException $aee) { $message = new Message('danger', __('Error', 'You already voted')); + $selectedNewVotes = $choices; } catch (ConcurrentEditionException $cee) { $message = new Message('danger', __('Error', 'Poll has been updated before you vote')); } catch (ConcurrentVoteException $cve) { @@ -237,5 +240,6 @@ $smarty->assign('accessGranted', $accessGranted); $smarty->assign('resultPubliclyVisible', $resultPubliclyVisible); $smarty->assign('editedVoteUniqueId', $editedVoteUniqueId); $smarty->assign('ValueMax', $poll->ValueMax); +$smarty->assign('selectedNewVotes', $selectedNewVotes); $smarty->display('studs.tpl'); diff --git a/tpl/part/vote_table_classic.tpl b/tpl/part/vote_table_classic.tpl index 1b57894..9f3193d 100644 --- a/tpl/part/vote_table_classic.tpl +++ b/tpl/part/vote_table_classic.tpl @@ -181,26 +181,34 @@ diff --git a/tpl/part/vote_table_date.tpl b/tpl/part/vote_table_date.tpl index db8cdce..87e3b8e 100644 --- a/tpl/part/vote_table_date.tpl +++ b/tpl/part/vote_table_date.tpl @@ -239,40 +239,43 @@ {foreach $slots as $slot} {foreach $slot->moments as $moment} - - - - {$i = $i+1} {/foreach} {/foreach}