From 01f644c1a85549481a8dee611244da81bebe7849 Mon Sep 17 00:00:00 2001
From: Kaitlin Newson
Date: Tue, 21 Apr 2026 12:16:59 -0300
Subject: [PATCH 1/2] pkp/pkp-lib#4695 add support for article number metadata
---
.../forms/context/MetadataSettingsForm.php | 56 +++++++++++--------
classes/core/Application.php | 14 ++++-
locale/en/manager.po | 7 +++
locale/en/submission.po | 5 ++
schemas/context.json | 6 ++
schemas/publication.json | 6 ++
.../frontend/objects/article_details.tpl | 22 ++++++--
7 files changed, 85 insertions(+), 31 deletions(-)
diff --git a/classes/components/forms/context/MetadataSettingsForm.php b/classes/components/forms/context/MetadataSettingsForm.php
index 18af2cea8aa..9d6ff0828eb 100644
--- a/classes/components/forms/context/MetadataSettingsForm.php
+++ b/classes/components/forms/context/MetadataSettingsForm.php
@@ -1,9 +1,10 @@
addField(new FieldOptions('enablePublisherId', [
- 'label' => __('submission.publisherId'),
- 'description' => __('submission.publisherId.description'),
- 'options' => [
- [
- 'value' => 'publication',
- 'label' => __('submission.publisherId.enable', ['objects' => __('submission.publications')]),
- ],
- [
- 'value' => 'galley',
- 'label' => __('submission.publisherId.enable', ['objects' => __('submission.layout.galleys')]),
- ],
- [
- 'value' => 'issue',
- 'label' => __('submission.publisherId.enable', ['objects' => __('issue.issues')]),
+ $this
+ ->addField(new FieldOptions('enablePublisherId', [
+ 'label' => __('submission.publisherId'),
+ 'description' => __('submission.publisherId.description'),
+ 'options' => [
+ [
+ 'value' => 'publication',
+ 'label' => __('submission.publisherId.enable', ['objects' => __('submission.publications')]),
+ ],
+ [
+ 'value' => 'galley',
+ 'label' => __('submission.publisherId.enable', ['objects' => __('submission.layout.galleys')]),
+ ],
+ [
+ 'value' => 'issue',
+ 'label' => __('submission.publisherId.enable', ['objects' => __('issue.issues')]),
+ ],
+ [
+ 'value' => 'issueGalley',
+ 'label' => __('submission.publisherId.enable', ['objects' => __('editor.issues.galleys')]),
+ ],
],
- [
- 'value' => 'issueGalley',
- 'label' => __('submission.publisherId.enable', ['objects' => __('editor.issues.galleys')]),
+ 'value' => $context->getData('enablePublisherId') ? $context->getData('enablePublisherId') : [],
+ ]))
+ ->addField(new FieldOptions('enableArticleNumber', [
+ 'label' => __('submission.articleNumber'),
+ 'description' => __('submission.articleNumber.description'),
+ 'options' => [
+ ['value' => true, 'label' => __('manager.setup.metadata.articleNumber.enable')]
],
- ],
- 'value' => $context->getData('enablePublisherId') ? $context->getData('enablePublisherId') : [],
- ]));
+ 'value' => (bool) $context->getData('enableArticleNumber'),
+ ]));
}
}
diff --git a/classes/core/Application.php b/classes/core/Application.php
index c73322f1a30..a0ac336981e 100644
--- a/classes/core/Application.php
+++ b/classes/core/Application.php
@@ -3,8 +3,8 @@
/**
* @file classes/core/Application.php
*
- * Copyright (c) 2014-2021 Simon Fraser University
- * Copyright (c) 2003-2021 John Willinsky
+ * Copyright (c) 2014-2026 Simon Fraser University
+ * Copyright (c) 2003-2026 John Willinsky
* Distributed under the GNU GPL v3. For full terms see the file docs/COPYING.
*
* @class Application
@@ -140,6 +140,16 @@ public function getPluginCategories(): array
];
}
+ /**
+ * Get the supported metadata setting names for this application.
+ */
+ public static function getMetadataFields(): array
+ {
+ return array_merge(parent::getMetadataFields(), [
+ 'articleNumber',
+ ]);
+ }
+
/**
* Get the top-level context DAO.
*/
diff --git a/locale/en/manager.po b/locale/en/manager.po
index 4adb08d58f1..e6f332afe60 100644
--- a/locale/en/manager.po
+++ b/locale/en/manager.po
@@ -955,6 +955,13 @@ msgstr "Continuous Publication"
msgid "manager.setup.issuelessPublication"
msgstr "Issueless Publication"
+msgid "manager.setup.metadata.articleNumber.description"
+msgstr ""
+"The article number can be used in citations and other metadata instead of page numbers."
+
+msgid "manager.setup.metadata.articleNumber.enable"
+msgstr "Enable article number metadata"
+
msgid "manager.statistics.statistics"
msgstr "Journal Statistics"
diff --git a/locale/en/submission.po b/locale/en/submission.po
index d9ef0c08693..99e78aef28e 100644
--- a/locale/en/submission.po
+++ b/locale/en/submission.po
@@ -469,3 +469,8 @@ msgstr ""
msgid "submission.submit.form.contributorRoleRequired"
msgstr "Please select the contributor's role."
+msgid "submission.articleNumber"
+msgstr "Article Number"
+
+msgid "submission.articleNumber.description"
+msgstr "The article number can be used in citations and other metadata instead of page numbers."
diff --git a/schemas/context.json b/schemas/context.json
index 36ad3501287..c7fe9987504 100644
--- a/schemas/context.json
+++ b/schemas/context.json
@@ -62,6 +62,12 @@
"nullable"
]
},
+ "enableArticleNumber": {
+ "type": "boolean",
+ "validation": [
+ "nullable"
+ ]
+ },
"enableOpenAccessNotification": {
"type": "boolean",
"validation": [
diff --git a/schemas/publication.json b/schemas/publication.json
index 4bddfca09a9..5908184cf28 100644
--- a/schemas/publication.json
+++ b/schemas/publication.json
@@ -20,6 +20,12 @@
"nullable"
]
},
+ "articleNumber": {
+ "type": "string",
+ "validation": [
+ "nullable"
+ ]
+ },
"galleys": {
"type": "array",
"apiSummary": true,
diff --git a/templates/frontend/objects/article_details.tpl b/templates/frontend/objects/article_details.tpl
index 7ca515f9359..3125d322c05 100755
--- a/templates/frontend/objects/article_details.tpl
+++ b/templates/frontend/objects/article_details.tpl
@@ -1,8 +1,8 @@
{**
* templates/frontend/objects/article_details.tpl
*
- * Copyright (c) 2014-2025 Simon Fraser University
- * Copyright (c) 2003-2025 John Willinsky
+ * Copyright (c) 2014-2026 Simon Fraser University
+ * Copyright (c) 2003-2026 John Willinsky
* Distributed under the GNU GPL v3. For full terms see the file docs/COPYING.
*
* @brief View of an Article which displays all details about the article.
@@ -129,7 +129,7 @@
{$contributorRoleName|escape}
{if !$contributorRoleName@last}{translate key="common.commaListSeparator"}{/if}
- {strip}
+ {/strip}
{/foreach}
{if $author->getData('orcid')}
@@ -190,7 +190,7 @@
{foreach name="keywords" from=$publication->getLocalizedData('keywords') item="keyword"}
- {$keyword.name|escape}{if !$smarty.foreach.keywords.last}{translate key="common.commaListSeparator"}{/if}
+ {$keyword.name|escape}{if !$smarty.foreach.keywords.last}{translate key="common.commaListSeparator"}{/if}
{/foreach}
@@ -417,9 +417,8 @@
{/if}
{* Issue article appears in *}
- {if $issue || $section || $categories}
+ {if $issue || $section || $categories || $publication->getData('articleNumber')}
-
{if $issue}
{/if}
+
+ {if $publication->getData('articleNumber')}
+
+
+ {translate key="submission.articleNumber"}
+
+
+ {$publication->getData('articleNumber')|escape}
+
+
+ {/if}
{/if}
From 9d6b025d529112fc4397c4b01d8bad9051689d16 Mon Sep 17 00:00:00 2001
From: Kaitlin Newson
Date: Fri, 24 Apr 2026 13:43:57 -0300
Subject: [PATCH 2/2] submodule updates
---
lib/pkp | 2 +-
plugins/generic/citationStyleLanguage | 2 +-
plugins/generic/crossref | 2 +-
plugins/generic/jatsTemplate | 2 +-
4 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/lib/pkp b/lib/pkp
index aee04153f01..6f7838a0852 160000
--- a/lib/pkp
+++ b/lib/pkp
@@ -1 +1 @@
-Subproject commit aee04153f01b75b648269f995dc65572b0e5ee3c
+Subproject commit 6f7838a085268aa97496952e694e6fec62e45b93
diff --git a/plugins/generic/citationStyleLanguage b/plugins/generic/citationStyleLanguage
index 35257bec6ba..373db19362c 160000
--- a/plugins/generic/citationStyleLanguage
+++ b/plugins/generic/citationStyleLanguage
@@ -1 +1 @@
-Subproject commit 35257bec6ba6cf68feec7f44c7d91bf7413f0781
+Subproject commit 373db19362c3c6247679856ca8430431382bf0c0
diff --git a/plugins/generic/crossref b/plugins/generic/crossref
index 6c20602e830..895543fc21d 160000
--- a/plugins/generic/crossref
+++ b/plugins/generic/crossref
@@ -1 +1 @@
-Subproject commit 6c20602e830903653756f2acad42dd58cf177e02
+Subproject commit 895543fc21d8b964601a2cfe8a792a4c95897aa1
diff --git a/plugins/generic/jatsTemplate b/plugins/generic/jatsTemplate
index e0bbf87687f..37ca2de5fcd 160000
--- a/plugins/generic/jatsTemplate
+++ b/plugins/generic/jatsTemplate
@@ -1 +1 @@
-Subproject commit e0bbf87687f975bb50d489d1670638e0930933c9
+Subproject commit 37ca2de5fcdff0e6e6bcdef211e209e95883255e