Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[TGDK][Fix] Ensure articles transition to 'Accepted' stage when review is the final workflow step #4552

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

SSanchez7
Copy link

Important

This implementation is part of a set of features and fixes developed within the context of a project for the TGDK academic journal, with the goal of customizing Janeway to meet the journal's specific needs, which may also be extended to other contexts.

Problem / Objective

When the draft_decisions option is enabled and the editorial workflow is limited to the review stage, accepting a draft decision that approves an article should transition its stage to Accepted. However, it incorrectly transitions to Editor Copyediting.

This issue becomes particularly problematic when the workflow is restricted to the review stage, as articles appear in the Copyediting stage instead of being marked as Accepted. This discrepancy leads to logistical issues within the platform.

Solution

The problem was identified in the manage_draft function, where the stage is directly set to STAGE_EDITOR_COPYEDITING:

article.accept_article(stage=submission_models.STAGE_EDITOR_COPYEDITING)

The fix ensures that the initial stage after approval is set to STAGE_ACCEPTED. If subsequent workflow stages exist (e.g., Copyediting), the article will transition to those automatically, but the primary stage must always begin as Accepted.

Copy link
Member

@ajrbyers ajrbyers left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @SSanchez7 this looks great.

@SSanchez7 SSanchez7 marked this pull request as ready for review December 20, 2024 10:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants