Skip to content

Commit

Permalink
pkp/pkp-lib#10767 Bring back preview button for unpublished submission
Browse files Browse the repository at this point in the history
  • Loading branch information
jardakotesovec committed Jan 8, 2025
1 parent 495c6ab commit dc96505
Showing 1 changed file with 14 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,20 @@ export function getHeaderItems({
});
}

if (
submission.status !== pkp.const.STATUS_PUBLISHED &&
(submission.stageId === pkp.const.WORKFLOW_STAGE_ID_EDITING ||
submission.stageId === pkp.const.WORKFLOW_STAGE_ID_PRODUCTION)
) {
actions.push({
component: 'WorkflowActionButton',
props: {
label: t('common.preview'),
action: Actions.WORKFLOW_VIEW_PUBLISHED_SUBMISSION,
},
});
}

if (permissions.canAccessEditorialHistory) {
actions.push({
component: 'WorkflowActionButton',
Expand Down

0 comments on commit dc96505

Please sign in to comment.