Skip to content

Commit

Permalink
[STTNHUB-313] api: Allow passing item state to assignments_link endpo…
Browse files Browse the repository at this point in the history
…int (#1920)
  • Loading branch information
MarkLark86 authored Feb 22, 2024
1 parent e3289c9 commit 7ac9140
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion server/planning/assignments/assignments_link.py
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ def link_archive_items_to_assignments(self, assignment, related_items, actioned_
"assignment_id": assignment.get(config.ID_FIELD),
"planning_id": assignment["planning_item"],
"coverage_id": assignment["coverage_item"],
"item_state": item.get("state"),
"item_state": doc.get("item_state") or item.get("state"),
"sequence_no": item.get("rewrite_sequence") or 0,
"publish_time": get_delivery_publish_time(item),
"scheduled_update_id": assignment.get("scheduled_update_id"),
Expand Down Expand Up @@ -252,6 +252,7 @@ class AssignmentsLinkResource(Resource):
schema = {
"assignment_id": {"type": "objectid", "required": True},
"item_id": {"type": "string", "required": True},
"item_state": {"type": "string"},
"reassign": {"type": "boolean", "required": True},
"force": {"type": "boolean"},
"skip_archive_update": {"type": "boolean"},
Expand Down

0 comments on commit 7ac9140

Please sign in to comment.