diff --git a/adminstuds.php b/adminstuds.php index 573e908..a26bbd2 100644 --- a/adminstuds.php +++ b/adminstuds.php @@ -120,9 +120,9 @@ if (isset($_POST['update_poll_info'])) { // Update poll in database if ($updated && $adminPollService->updatePoll($poll)) { - $message = new Message('success', __('adminstuds\\Poll saved.')); + $message = new Message('success', __('adminstuds\\Poll saved')); } else { - $message = new Message('danger', __('Error\\Failed to save poll.')); + $message = new Message('danger', __('Error\\Failed to save poll')); $poll = $pollService->findById($poll_id); } } @@ -148,16 +148,16 @@ if (!empty($_POST['save'])) { // Save edition of an old vote $message = new Message('danger', __('Error\\Something is going wrong...')); } if (count($choices) != count($_POST['choices'])) { - $message = new Message('danger', __('Error\\There is a problem with your choices.')); + $message = new Message('danger', __('Error\\There is a problem with your choices')); } if ($message == null) { // Update vote $result = $pollService->updateVote($poll_id, $editedVote, $name, $choices); if ($result) { - $message = new Message('success', __('Update vote successfully.')); + $message = new Message('success', __('adminstuds\\Vote updated')); } else { - $message = new Message('danger', __('Error\\Update vote failed.')); + $message = new Message('danger', __('Error\\Update vote failed')); } } } elseif (isset($_POST['save'])) { // Add a new vote @@ -165,19 +165,19 @@ if (!empty($_POST['save'])) { // Save edition of an old vote $choices = $inputService->filterArray($_POST['choices'], FILTER_VALIDATE_REGEXP, ['options' => ['regexp' => CHOICE_REGEX]]); if (empty($name)) { - $message = new Message('danger', __('Error\\The name is invalid.')); + $message = new Message('danger', __('Error\\The name is invalid')); } if (count($choices) != count($_POST['choices'])) { - $message = new Message('danger', __('Error\\There is a problem with your choices.')); + $message = new Message('danger', __('Error\\There is a problem with your choices')); } if ($message == null) { // Add vote $result = $pollService->addVote($poll_id, $name, $choices); if ($result) { - $message = new Message('success', __('Update vote successfully.')); + $message = new Message('success', __('adminstuds\\Vote added')); } else { - $message = new Message('danger', __('Error\\Update vote failed.')); + $message = new Message('danger', __('Error\\Adding vote failed')); } } } @@ -189,9 +189,9 @@ if (!empty($_POST['save'])) { // Save edition of an old vote if (!empty($_POST['delete_vote'])) { $vote_id = filter_input(INPUT_POST, 'delete_vote', FILTER_VALIDATE_INT); if ($adminPollService->deleteVote($poll_id, $vote_id)) { - $message = new Message('success', __('Vote delete.')); + $message = new Message('success', __('adminstuds\\Vote deleted')); } else { - $message = new Message('danger', __('Error\\Failed to delete the vote.')); + $message = new Message('danger', __('Error\\Failed to delete the vote')); } } @@ -208,9 +208,9 @@ if (isset($_POST['remove_all_votes'])) { } if (isset($_POST['confirm_remove_all_votes'])) { if ($adminPollService->cleanVotes($poll_id)) { - $message = new Message('success', __('All votes deleted.')); + $message = new Message('success', __('adminstuds\\All votes deleted')); } else { - $message = new Message('danger', __('Error\\Failed to delete all votes.')); + $message = new Message('danger', __('Error\\Failed to delete all votes')); } } @@ -223,16 +223,16 @@ if (isset($_POST['add_comment'])) { $comment = strip_tags($_POST['comment']); if (empty($name)) { - $message = new Message('danger', __('Error\\The name is invalid.')); + $message = new Message('danger', __('Error\\The name is invalid')); } if ($message == null) { // Add comment $result = $pollService->addComment($poll_id, $name, $comment); if ($result) { - $message = new Message('success', __('Comment added.')); + $message = new Message('success', __('Comments\\Comment added')); } else { - $message = new Message('danger', __('Error\\Comment failed.')); + $message = new Message('danger', __('Error\\Comment failed')); } } @@ -246,9 +246,9 @@ if (!empty($_POST['delete_comment'])) { $comment_id = filter_input(INPUT_POST, 'delete_comment', FILTER_VALIDATE_INT); if ($adminPollService->deleteComment($poll_id, $comment_id)) { - $message = new Message('success', __('Comment deleted.')); + $message = new Message('success', __('adminstuds\\Comment deleted')); } else { - $message = new Message('danger', __('Error\\Failed to delete the comment.')); + $message = new Message('danger', __('Error\\Failed to delete the comment')); } } @@ -265,9 +265,9 @@ if (isset($_POST['remove_all_comments'])) { } if (isset($_POST['confirm_remove_all_comments'])) { if ($adminPollService->cleanComments($poll_id)) { - $message = new Message('success', __('All comments deleted.')); + $message = new Message('success', __('All comments deleted')); } else { - $message = new Message('danger', __('Error\\Failed to delete all comments.')); + $message = new Message('danger', __('Error\\Failed to delete all comments')); } } @@ -284,9 +284,9 @@ if (isset($_POST['delete_poll'])) { } if (isset($_POST['confirm_delete_poll'])) { if ($adminPollService->deleteEntirePoll($poll_id)) { - $message = new Message('success', __('Generic\\Poll fully deleted.')); + $message = new Message('success', __('Generic\\Poll fully deleted')); } else { - $message = new Message('danger', __('Error\\Failed to delete the poll.')); + $message = new Message('danger', __('Error\\Failed to delete the poll')); } $smarty->assign('poll_id', $poll_id); $smarty->assign('admin_poll_id', $admin_poll_id); @@ -316,9 +316,9 @@ if (!empty($_POST['delete_column'])) { } if ($result) { - $message = new Message('success', __('Column deleted.')); + $message = new Message('success', __('Column deleted')); } else { - $message = new Message('danger', __('Error\\Failed to delete the column.')); + $message = new Message('danger', __('Error\\Failed to delete the column')); } } @@ -347,9 +347,9 @@ if (isset($_POST['confirm_add_slot'])) { } if ($result) { - $message = new Message('success', __('Column added.')); + $message = new Message('success', __('adminstuds\\Choice added')); } else { - $message = new Message('danger', __('Error\\Failed to add the column.')); + $message = new Message('danger', __('Error\\Failed to add the column')); } } diff --git a/locale/fr.json b/locale/fr.json index 566d352..ae5fc78 100644 --- a/locale/fr.json +++ b/locale/fr.json @@ -27,7 +27,8 @@ "for": "à", "Yes": "Oui", "Ifneedbe": "Si nécessaire", - "No": "Non" + "No": "Non", + "Legend:": "Légende :" }, "Date" : { "(dd/mm/yyyy)": "(jj/mm/aaaa)", @@ -35,8 +36,8 @@ "%A, den %e. %B %Y": "%A %e %B %Y" }, "Language selector": { - "Change the language": "Changer la langue", - "Select the language": "Choisir la langue" + "Select the language": "Choisir la langue", + "Change the language": "Changer la langue" }, "Homepage": { "Schedule an event": "Créer un sondage spécial dates", @@ -67,12 +68,10 @@ "the development site": "le site de développement", "If you want to install the software for your own use and thus increase your independence, we help you on:": "Si vous souhaitez installer ce logiciel pour votre propre usage et ainsi gagner en autonomie, nous vous aidons sur :" }, - "Poll": { - "Poll administration": "Administration du sondage", - "Legend:": "Légende :" + "": { + "Poll administration": "Administration du sondage" }, "PollInfo": { - "Back to the poll": "Retour au sondage", "Remove the poll": "Supprimer le sondage", "Remove all the comments": "Supprimer tous les commentaires", "Remove all the votes": "Supprimer tous les votes", @@ -111,19 +110,9 @@ "Keep comments": "Garder les commentaires", "Keep this poll": "Garder ce sondage" }, - "Help text adminstuds.php": { - "As poll administrator, you can change all the lines of this poll with this button": "En tant qu'administrateur, vous pouvez modifier toutes les lignes de ce sondage avec ce bouton", - "remove a column or a line with": "effacer une colonne ou une ligne avec", - "and add a new column with": "et si vous avez oublié de saisir un choix, vous pouvez rajouter une colonne en cliquant sur", - "Finally, you can change the informations of this poll like the title, the comments or your email address.": "Vous pouvez enfin également modifier les informations relatives à ce sondage comme le titre, les commentaires ou encore votre courriel." - }, - "Help text studs.php": { - "If you want to vote in this poll, you have to give your name, choose the values that fit best for you and validate with the plus button at the end of the line.": "Pour participer à ce sondage, veuillez entrer votre nom, choisir toutes les valeurs qui vous conviennent et valider votre choix avec le bouton en bout de ligne." - }, "Poll results": { "Votes of the poll": "Votes du sondage", "Remove the column": "Effacer la colonne", - "Add a column": "Ajouter une colonne", "Edit the line:": "Modifier la ligne :", "Remove the line:": "Supprimer la ligne :", "Vote no for ": "Voter « non » pour ", @@ -144,21 +133,42 @@ "Add a comment to the poll": "Ajouter un commentaire au sondage", "Your comment": "Votre commentaire", "Send the comment": "Envoyer le commentaire", - "anonyme": "anonyme" + "anonyme": "anonyme", + "Comment added": "Commentaire ajouté" }, "studs": { + "If you want to vote in this poll, you have to give your name, choose the values that fit best for you and validate with the plus button at the end of the line.": "Pour participer à ce sondage, veuillez entrer votre nom, choisir toutes les valeurs qui vous conviennent et valider votre choix avec le bouton en bout de ligne.", + "POLL_LOCKED_WARNING":"L'administrateur a verrouillé ce sondage. Les votes et commentaires sont gelés, il n'est plus possible de participer", "The poll is expired, it will be deleted soon.": "Le sondage a expiré, il sera bientôt supprimé.", "Deletion date:": "Date de suppression :" }, "adminstuds": { + "As poll administrator, you can change all the lines of this poll with this button": "En tant qu'administrateur, vous pouvez modifier toutes les lignes de ce sondage avec ce bouton", + "remove a column or a line with": "effacer une colonne ou une ligne avec", + "and add a new column with": "et si vous avez oublié de saisir un choix, vous pouvez rajouter une colonne en cliquant sur", + "Finally, you can change the informations of this poll like the title, the comments or your email address.": "Vous pouvez enfin également modifier les informations relatives à ce sondage comme le titre, les commentaires ou encore votre courriel.", "Column's adding": "Ajout de colonne", "You can add a new scheduling date to your poll.": "Vous pouvez ajouter une date à votre sondage.", "If you just want to add a new hour to an existant date, put the same date and choose a new hour.": "Si vous voulez juste ajouter un horaire à une date existante, mettez la même date et choisissez un autre horaire. Il sera intégré normalement au sondage existant.", - "Confirm removal of your poll": "Confirmer la suppression de votre sondage", - "Remove this poll!": "Je supprime ce sondage !", - "Keep this poll!": "Je garde ce sondage !", + "Confirm removal of the poll": "Confirmer la suppression du sondage", + "Remove the poll": "Je supprime le sondage", + "Keep the poll": "Je garde le sondage", "Your poll has been removed!": "Votre sondage a été supprimé !", - "Poll saved.": "Sondage sauvegardé." + "Poll saved": "Sondage sauvegardé", + "Vote added": "Vote ajouté", + "Vote updated": "Vote mis à jour", + "Vote deleted": "Vote supprimé", + "All votes deleted": "Tous les votes ont été supprimés", + "Back to the poll": "Retour au sondage", + "Add a column": "Ajouter une colonne", + "Choice added": "Choix ajouté", + "Confirm removal of all votes of the poll": "Confirmer la suppression de tous les votes de ce sondage", + "Keep the votes": "Garder les votes", + "Remove the votes": "Supprimer les votes", + "Confirm removal of all comments of the poll": "Confirmer la suppression de tous les commentaires de ce sondage", + "Keep the comments": "Garder les commentaires", + "Remove the comments": "Supprimer les commentaires", + "The poll has been deleted": "Le sondage a été supprimé" }, "Step 1": { "Poll creation (1 on 3)": "Création de sondage (1 sur 3)", @@ -272,6 +282,8 @@ "Characters \\u0022 ' < et > are not permitted": "Les caractères \\u0022 ' < et > ne sont pas autorisés !", "The date is not correct !": "La date choisie n'est pas correcte !", "Framadate is not properly installed, please check the \"INSTALL\" to setup the database before continuing.": "Framadate n'est pas installé correctement, lisez le fichier INSTALL pour configurer la base de données avant de continuer.", - "Failed to save poll.": "Echèc de la sauvegarde du sondage." + "Failed to save poll": "Echèc de la sauvegarde du sondage", + "Update vote failed": "Mise à jour du vote échoué", + "Adding vote failed": "Ajout d'un vote échoué" } } diff --git a/tpl/add_slot.tpl b/tpl/add_slot.tpl index 8a66e38..9f634bc 100644 --- a/tpl/add_slot.tpl +++ b/tpl/add_slot.tpl @@ -3,36 +3,36 @@ {block name=main}
-

{_('Column\'s adding')}

+

{__('adminstuds\\Column\'s adding')}

{if $format === 'D'}
- +
- +
- {_('(dd/mm/yyyy)')} + {__('Date\\(dd/mm/yyyy)')}
- +
{else}
- +
{/if}
- - + +
diff --git a/tpl/confirm/delete_comments.tpl b/tpl/confirm/delete_comments.tpl index bbc6a67..264a4ae 100644 --- a/tpl/confirm/delete_comments.tpl +++ b/tpl/confirm/delete_comments.tpl @@ -3,9 +3,9 @@ {block name=main}
-

{_('Confirm removal of all comments of the poll')}

-

-

+

{__('adminstuds\\Confirm removal of all comments of the poll')}

+

+

{/block} \ No newline at end of file diff --git a/tpl/confirm/delete_poll.tpl b/tpl/confirm/delete_poll.tpl index e2cbbe5..6a24502 100644 --- a/tpl/confirm/delete_poll.tpl +++ b/tpl/confirm/delete_poll.tpl @@ -3,9 +3,9 @@ {block name=main}
-

{_('Confirm removal of your poll')}

-

-

+

{__('adminstuds\\Confirm removal of the poll')}

+

+

{/block} \ No newline at end of file diff --git a/tpl/confirm/delete_votes.tpl b/tpl/confirm/delete_votes.tpl index d807201..530266e 100644 --- a/tpl/confirm/delete_votes.tpl +++ b/tpl/confirm/delete_votes.tpl @@ -3,9 +3,9 @@ {block name=main}
-

{_('Confirm removal of all votes of the poll')}

-

-

+

{__('adminstuds\\Confirm removal of all votes of the poll')}

+

+

{/block} \ No newline at end of file diff --git a/tpl/error.tpl b/tpl/error.tpl index 5d7e55a..601e0a4 100644 --- a/tpl/error.tpl +++ b/tpl/error.tpl @@ -1,7 +1,7 @@ {extends file='page.tpl'} {block name=main} -
+

{$error|html}

{__('Generic\\Back to the homepage of')} {$APPLICATION_NAME|html}

diff --git a/tpl/header.tpl b/tpl/header.tpl index 1fa06c2..53adb2f 100644 --- a/tpl/header.tpl +++ b/tpl/header.tpl @@ -2,19 +2,19 @@ {if count($langs)>1}
- {foreach $langs as $lang_key=>$lang_value} {/foreach} - +
{/if} -

{$APPLICATION_NAME|html}

+

{$APPLICATION_NAME|html}

{if !empty($title)}

{$title|html}

{/if} diff --git a/tpl/part/poll_hint.tpl b/tpl/part/poll_hint.tpl index 341a9f1..3e493e5 100644 --- a/tpl/part/poll_hint.tpl +++ b/tpl/part/poll_hint.tpl @@ -1,11 +1,11 @@ {if $active}
-

{_("If you want to vote in this poll, you have to give your name, choose the values that fit best for you and validate with the plus button at the end of the line.")}

- +

{__('studs\\If you want to vote in this poll, you have to give your name, choose the values that fit best for you and validate with the plus button at the end of the line.')}

+
{else}
-

{_("The administrator locked this poll, votes and comments are frozen, it's not possible to participate anymore.")}

- +

{__('studs\\POLL_LOCKED_WARNING')}

+
{/if} \ No newline at end of file diff --git a/tpl/part/poll_hint_admin.tpl b/tpl/part/poll_hint_admin.tpl index 2b7c1c3..ac8ffda 100644 --- a/tpl/part/poll_hint_admin.tpl +++ b/tpl/part/poll_hint_admin.tpl @@ -1,7 +1,7 @@
-

{_('As poll administrator, you can change all the lines of this poll with this button')} {_('Edit')}, - {_('remove a column or a line with')} {_('Remove')} - {_('and add a new column with')} {_('Add a column')}.

-

{_('Finally, you can change the informations of this poll like the title, the comments or your email address.')}

- +

{__('adminstuds\\As poll administrator, you can change all the lines of this poll with this button')} {_('Edit')}, + {__('adminstuds\\remove a column or a line with')} {_('Remove')} + {__('adminstuds\\and add a new column with')} {_('Add a column')}.

+

{__('adminstuds\\Finally, you can change the informations of this poll like the title, the comments or your email address.')}

+
\ No newline at end of file diff --git a/tpl/poll_deleted.tpl b/tpl/poll_deleted.tpl index f0b46a2..6fc2c01 100644 --- a/tpl/poll_deleted.tpl +++ b/tpl/poll_deleted.tpl @@ -2,7 +2,7 @@ {block name=main}
-

{_("Your poll has been removed!")}

-

{_('Back to the homepage of')} {$APPLICATION_NAME|html}

+

{__('adminstuds\\The poll has been deleted')}

+

{__('Generic\\Back to the homepage of')} {$APPLICATION_NAME|html}

{/block} \ No newline at end of file