diff --git a/plugins/pubIds/urn/URNPubIdPlugin.php b/plugins/pubIds/urn/URNPubIdPlugin.php index b667878cb65..a801daf260e 100755 --- a/plugins/pubIds/urn/URNPubIdPlugin.php +++ b/plugins/pubIds/urn/URNPubIdPlugin.php @@ -470,7 +470,7 @@ public function loadUrnFieldComponent(string $hookName, array $args): void $templateMgr = $args[0]; $template = $args[1]; - if ($template !== 'workflow/workflow.tpl') { + if ($template !== 'dashboard/editors.tpl') { return; } diff --git a/plugins/pubIds/urn/js/FieldPubIdUrn.js b/plugins/pubIds/urn/js/FieldPubIdUrn.js index 2bb0a45b38c..cd4a989f5a2 100644 --- a/plugins/pubIds/urn/js/FieldPubIdUrn.js +++ b/plugins/pubIds/urn/js/FieldPubIdUrn.js @@ -11,9 +11,10 @@ * @brief A Vue.js component for URN field, that is used for pattern suffixes and that considers check number. */ -pkp.Vue.component('field-pub-id-urn', { +console.log('pubid test', pkp.registry.getComponent('field-pub-id')); +pkp.registry.registerComponent('FieldPubIdUrn', { name: 'FieldPubIdUrn', - extends: pkp.Vue.component('field-pub-id'), + extends: pkp.registry.getComponent('PkpFieldPubId'), props: { applyCheckNumber: { type: Boolean, @@ -22,10 +23,10 @@ pkp.Vue.component('field-pub-id-urn', { }, methods: { generateId() { - var id = pkp.Vue.component('field-pub-id').options.methods['generateId'].apply(this); + var id = pkp.Vue.component('field-pub-id').methods['generateId'].apply(this); return this.applyCheckNumber ? id + $.pkp.plugins.generic.urn.getCheckNumber(id, this.prefix) : id; } }, -}); \ No newline at end of file +})