Skip to content

Commit 5a95143

Browse files
pkp/pkp-lib#11252 Bug fix, Always query for selected stage in the managers
1 parent 97863b8 commit 5a95143

File tree

7 files changed

+15
-7
lines changed

7 files changed

+15
-7
lines changed

src/managers/ReviewerManager/ReviewerManager.vue

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -78,6 +78,7 @@ const Components = {
7878
7979
const props = defineProps({
8080
submission: {type: Object, required: true},
81+
submissionStageId: {type: Number, required: true},
8182
reviewRoundId: {type: Number, required: true},
8283
redactedForAuthors: {type: Boolean, required: false, default: false},
8384
componentForms: {type: Object, required: true},

src/managers/ReviewerManager/reviewerManagerStore.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,7 @@ export const useReviewerManagerStore = defineComponentStore(
7878
function getActionArgs(additionalArgs = {}) {
7979
return {
8080
submission: props.submission,
81-
submissionStageId: props.submission.stageId,
81+
submissionStageId: props.submissionStageId,
8282
reviewRoundId: props.reviewRoundId,
8383
componentForms: props.componentForms,
8484
...additionalArgs,

src/managers/ReviewerManager/useReviewerManagerActions.js

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,14 +30,17 @@ export const Actions = {
3030
export function useReviewerManagerActions() {
3131
const {t, localizeSubmission} = useLocalize();
3232

33-
function reviewerAddReviewer({submission, reviewRoundId}, finishedCallback) {
33+
function reviewerAddReviewer(
34+
{submission, reviewRoundId, submissionStageId},
35+
finishedCallback,
36+
) {
3437
const {openLegacyModal} = useLegacyGridUrl({
3538
op: 'showReviewerForm',
3639
component: 'grid.users.reviewer.ReviewerGridHandler',
3740
params: {
3841
selectionType: pkp.const.REVIEWER_SELECT_ADVANCED_SEARCH,
3942
submissionId: submission.id,
40-
stageId: submission.stageId,
43+
stageId: submissionStageId,
4144
reviewRoundId,
4245
},
4346
});

src/pages/workflow/composables/useWorkflowConfig/workflowConfigAuthorOJS.js

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -131,7 +131,7 @@ export const WorkflowConfig = {
131131
props: {
132132
namespace: 'SUBMISSION_FILES',
133133
submission: submission,
134-
submissionStageId: submission.stageId,
134+
submissionStageId: selectedStageId,
135135
},
136136
});
137137

@@ -168,6 +168,7 @@ export const WorkflowConfig = {
168168
component: 'ReviewerManager',
169169
props: {
170170
submission: submission,
171+
submissionStageId: selectedStageId,
171172
reviewRoundId: selectedReviewRound?.id,
172173
redactedForAuthors: true,
173174
componentForms: pageInitConfig.componentForms,
@@ -241,7 +242,7 @@ export const WorkflowConfig = {
241242
props: {
242243
namespace: 'COPYEDITED_FILES',
243244
submission: submission,
244-
submissionStageId: submission.stageId,
245+
submissionStageId: selectedStageId,
245246
},
246247
});
247248

src/pages/workflow/composables/useWorkflowConfig/workflowConfigAuthorOMP.js

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ export const WorkflowConfig = {
4848
props: {
4949
namespace: 'SUBMISSION_FILES',
5050
submission: submission,
51-
submissionStageId: submission.stageId,
51+
submissionStageId: selectedStageId,
5252
},
5353
});
5454

@@ -79,6 +79,7 @@ export const WorkflowConfig = {
7979
component: 'ReviewerManager',
8080
props: {
8181
submission: submission,
82+
submissionStageId: selectedStageId,
8283
reviewRoundId: selectedReviewRound?.id,
8384
redactedForAuthors: true,
8485
componentForms: pageInitConfig.componentForms,
@@ -152,7 +153,7 @@ export const WorkflowConfig = {
152153
props: {
153154
namespace: 'COPYEDITED_FILES',
154155
submission: submission,
155-
submissionStageId: submission.stageId,
156+
submissionStageId: selectedStageId,
156157
},
157158
});
158159

src/pages/workflow/composables/useWorkflowConfig/workflowConfigEditorialOJS.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -329,6 +329,7 @@ export const WorkflowConfig = {
329329
component: 'ReviewerManager',
330330
props: {
331331
submission: submission,
332+
submissionStageId: selectedStageId,
332333
reviewRoundId: selectedReviewRound?.id,
333334
componentForms: pageInitConfig.componentForms,
334335
recommendations: pageInitConfig.recommendations,

src/pages/workflow/composables/useWorkflowConfig/workflowConfigEditorialOMP.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -208,6 +208,7 @@ export const WorkflowConfig = {
208208
component: 'ReviewerManager',
209209
props: {
210210
submission: submission,
211+
submissionStageId: selectedStageId,
211212
reviewRoundId: selectedReviewRound?.id,
212213
componentForms: pageInitConfig.componentForms,
213214
},

0 commit comments

Comments
 (0)