Skip to content

Feat 58 submission workflow#60

Open
karimouf wants to merge 15 commits intoproject-31-eiwafrom
feat-58-submission_workflow
Open

Feat 58 submission workflow#60
karimouf wants to merge 15 commits intoproject-31-eiwafrom
feat-58-submission_workflow

Conversation

@karimouf
Copy link
Collaborator

@karimouf karimouf commented Jan 7, 2026

Main Description

A new revision‑based submission review workflow has been introduced to the CARE system. This feature allows administrators and reviewers to create new submissions that build on data from previous study sessions. When reviewing a revised submission, the previous version is displayed in read‑only mode, while the new version appears with the assessment sidebar pre‑filled using the prior submission's grade (without persisting it). A new assignment mode ensures that submissions can only be created when all selected users have an associated study session.


New User Features

  • Ability to create a new study based on existing study session data with workflow step mapping to previous submissions
  • Read‑only display of the previous submission version during revision review via readOnlyComponents configuration
  • Assessment sidebar in the new submission pre‑populated with the previous submission's grade from previous_assessment_result (not saved automatically, marked with isSaved: false)
  • New assignment mode study_session requiring all selected users to have a corresponding study session before submission
  • Clear error messaging when users lack a required study session or when the previous submission cannot be found

New Dev Features

  • Added previousSubmissionId column to submission table (migration 20260103134710-extend-submission-previousSubmissionId.js)
  • Added parentSubmissionId foreign key to track submission lineage and revision chains
  • New Revision Workflow with two-step annotation process added to workflow system (migration 20260103145255-extend-workflow-revision_workflow.js)

Improvements

  • Handled multiple pdfs being loaded in the same study

Bug Fixes

  • Fixed document data duplication to create new entries instead of modifying original document data
  • Fixed assessment component based readonly

Known Limitations

  • Cannot create a new document_data entry for the same study session

Future Steps

NA

@karimouf karimouf requested a review from dennis-zyska January 7, 2026 14:51
karimouf and others added 2 commits January 21, 2026 17:53
stepType: 1,
allowBackward: true,
workflowStepDocument: null,
configuration: {
Copy link
Collaborator

Choose a reason for hiding this comment

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

We should add to the configuration that the assessment from the previous step should be loaded, maybe sometimes this is not needed

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

You mean like we add a check that the previous assessment is loaded why do wee need that though?

// 1. Manual data from document_data[assessment_result]
const raw = this.documentData[this.assessmentDataKey];
// 1. Manual data from document_data[assessment_result] or previous_assessment_result as fallback
let raw = this.documentData[this.assessmentDataKey];
Copy link
Collaborator

Choose a reason for hiding this comment

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

Can you double check that if I save one of the criteria, it only saves in the new assessment_results the criteria that I already saved with the button click?

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