Skip to content

Commit

Permalink
pkp/pkp-lib#10263 Relax editing metadata on published/posted materials
Browse files Browse the repository at this point in the history
  • Loading branch information
Hafsa-Naeem committed Aug 26, 2024
1 parent d588c80 commit 2c98a03
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 12 deletions.
4 changes: 4 additions & 0 deletions classes/controllers/grid/issues/IssueGridHandler.php
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,7 @@
use PKP\file\TemporaryFileManager;
use PKP\mail\Mailer;
use PKP\notification\NotificationSubscriptionSettingsDAO;
use PKP\observers\events\MetadataChanged;
use PKP\plugins\Hook;
use PKP\plugins\PluginRegistry;
use PKP\security\authorization\ContextAccessPolicy;
Expand Down Expand Up @@ -603,6 +604,9 @@ public function publishIssue($args, $request)
foreach ($publications as $publication) { /** @var Publication $publication */
if ($publication->getData('status') === Submission::STATUS_SCHEDULED && $publication->getData('issueId') === (int) $issue->getId()) {
Repo::publication()->publish($publication);

// dispatch the MetadataChanged event after publishing
event(new MetadataChanged($submission));
}
}
}
Expand Down
7 changes: 1 addition & 6 deletions templates/authorDashboard/authorDashboard.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -110,12 +110,7 @@
</dropdown>
</span>
</pkp-header>
<div
v-if="workingPublication.status === getConstant('STATUS_PUBLISHED')"
class="pkpPublication__versionPublished"
>
{translate key="publication.editDisabled"}
</div>

<tabs :is-side-tabs="true" :track-history="true" class="pkpPublication__tabs" :label="currentPublicationTabsLabel">
<tab id="titleAbstract" label="{translate key="publication.titleAbstract"}">
<pkp-form v-bind="components.{PKP\components\forms\publication\TitleAbstractForm::FORM_TITLE_ABSTRACT}" @set="set" />
Expand Down
6 changes: 0 additions & 6 deletions templates/workflow/workflow.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -170,12 +170,6 @@
</template>
{/if}
</pkp-header>
<div
v-if="workingPublication.status === getConstant('STATUS_PUBLISHED')"
class="pkpPublication__versionPublished"
>
{translate key="publication.editDisabled"}
</div>
<tabs class="pkpPublication__tabs" :is-side-tabs="true" :track-history="true" :label="currentPublicationTabsLabel">
<tab id="titleAbstract" label="{translate key="publication.titleAbstract"}">
<pkp-form v-bind="components.{PKP\components\forms\publication\TitleAbstractForm::FORM_TITLE_ABSTRACT}" @set="set" />
Expand Down

0 comments on commit 2c98a03

Please sign in to comment.