Skip to content

fix(per): block validated OpsLearning fields when not validated (#2293)#2788

Open
Tarekchehahde wants to merge 1 commit into
IFRCGo:developfrom
Tarekchehahde:fix/issue-2293-opslearning-validated-fields
Open

fix(per): block validated OpsLearning fields when not validated (#2293)#2788
Tarekchehahde wants to merge 1 commit into
IFRCGo:developfrom
Tarekchehahde:fix/issue-2293-opslearning-validated-fields

Conversation

@Tarekchehahde

Copy link
Copy Markdown

Summary

  • Validate OpsLearningInSerializer so *_validated fields cannot be set when is_validated is false
  • Matches admin form behaviour (non-validated records only expose draft fields)

Test plan

  • API returns 400 when posting sector_validated with is_validated: false
  • API accepts validated fields when is_validated: true
  • Full per test module in CI when fork workflows are approved

Fixes #2293

Made with Cursor

…Go#2293)

Reject API writes to *_validated fields unless is_validated is true so
validation workflow stays consistent with admin behaviour.

Co-authored-by: Cursor <cursoragent@cursor.com>
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.

[PROD] Data validation for OpsLearning while filling data to the db

1 participant