Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions DatesPlugin.inc.php
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ function register($category, $path, $mainContextId = NULL) {
if (!Config::getVar('general', 'installed') || defined('RUNNING_UPGRADE')) return true;
if ($success && $this->getEnabled()) {
// Insert Dates div
HookRegistry::register('Templates::Article::Details', array($this, 'addDates'));
HookRegistry::register('Templates::Article::Details::Dates', array($this, 'addDates'));
}
return $success;
}
Expand Down Expand Up @@ -60,7 +60,7 @@ function addDates($hookName, $params) {
$smarty = $params[1];
$output =& $params[2];

$article = $smarty->get_template_vars('article');
$article = $templateMgr->get_template_vars('article');

$dates = "";
$submitdate = $article->getDateSubmitted();
Expand Down
23 changes: 23 additions & 0 deletions locale/fr_FR/locale.po
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
msgid ""
msgstr ""

"plugins/generic/dates/locale/en_US/locale.po
"Copyright (c) 2014-2021 Simon Fraser University
"Copyright (c) 2003-2021 John Willinsky
"Distributed under the GNU GPL v3. For full terms see the file docs/COPYING.
"dates plugin localization strings

msgid "plugins.generic.dates.displayName"
msgstr "Plugin Date"

msgid "plugins.generic.dates.description"
msgstr "Ajoute les dates de soumission, d'acceptation et de publication à la page article"

msgid "plugins.generic.dates.received"
msgstr "Reçu"

msgid "plugins.generic.dates.accepted"
msgstr "Accepté"

msgid "plugins.generic.dates.published"
msgstr "Publié"
14 changes: 9 additions & 5 deletions templates/dates.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -7,16 +7,20 @@
*
*}
<div class="item dates">
<div class="value">
<section class="sub_item">
{if array_key_exists('received', $dates)}
{translate key="plugins.generic.dates.received"} {$dates.received} <br/>
<h2 class="label">{translate key="plugins.generic.dates.received"} </h2>
<div class="value">{$dates.received} </div>
{/if}
{if $dates.accepted}
{translate key="plugins.generic.dates.accepted"} {$dates.accepted} <br/>
<h2 class="label">
{translate key="plugins.generic.dates.accepted"} </h2>
<div class="value">{$dates.accepted} </div>
{/if}
{if $dates.published}
{translate key="plugins.generic.dates.published"} {$dates.published} <br/>
<h2 class="label"> {translate key="plugins.generic.dates.published"} </h2>
<div class="value">{$dates.published} </div>
{/if}
</div>
</section>
</div>