Skip to content

pkp/pkp-lib#11241 Added missing decisions migration for OPS #945

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

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
<?php

/**
* @file classes/migration/upgrade/v3_5_0/I11241_MissingDecisionConstantsUpdate.php
*
* Copyright (c) 2025 Simon Fraser University
* Copyright (c) 2025 John Willinsky
* Distributed under the GNU GPL v3. For full terms see the file docs/COPYING.
*
* @class I11241_MissingDecisionConstantsUpdate
*
* @brief Fixed the missing decisions data in stages
*
* @see https://github.com/pkp/pkp-lib/issues/11241
* https://github.com/pkp/pkp-lib/issues/9533
*/

namespace APP\migration\upgrade\v3_5_0;

class I11241_MissingDecisionConstantsUpdate extends \PKP\migration\upgrade\v3_4_0\I7725_DecisionConstantsUpdate
{
/**
* Get the decisions constants mappings
*/
public function getDecisionMappings(): array
{
return [
// \PKP\decision\Decision::INITIAL_DECLINE
[
'stage_id' => WORKFLOW_STAGE_ID_PRODUCTION,
'current_value' => 9,
'updated_value' => 8,
],
// \PKP\decision\Decision::REVERT_DECLINE to \PKP\decision\Decision::REVERT_INITIAL_DECLINE
// \PKP\decision\Decision::REVERT_DECLINE removed in 3.4
[
'stage_id' => WORKFLOW_STAGE_ID_PRODUCTION,
'current_value' => 17,
'updated_value' => 16,
]
];
}
}
1 change: 1 addition & 0 deletions dbscripts/xml/upgrade.xml
Original file line number Diff line number Diff line change
Expand Up @@ -153,6 +153,7 @@
<migration class="PKP\migration\upgrade\v3_4_0\I7624_StrftimeDeprecation"/>
<migration class="PKP\migration\upgrade\v3_5_0\I11238_PrepareDBForStructuredCitations"/>
<migration class="APP\migration\upgrade\v3_5_0\I10659_UpdateCrossrefSchema"/>
<migration class="APP\migration\upgrade\v3_5_0\I11241_MissingDecisionConstantsUpdate"/>
<note file="docs/release-notes/README-3.5.0" />
</upgrade>

Expand Down