@@ -480,44 +480,52 @@ class Meta:
480480 ]
481481
482482
483+ class IssueRelationRefSerializer (serializers .Serializer ):
484+ """Project-scoped reference to a related work item."""
485+
486+ project_id = serializers .UUIDField (help_text = "Project containing the related work item" )
487+ issue_id = serializers .UUIDField (help_text = "ID of the related work item" )
488+
489+
483490class IssueRelationResponseSerializer (serializers .Serializer ):
484491 """
485492 Serializer for issue relations response showing grouped relation types.
486493
487- Returns issue IDs organized by relation type for efficient client-side processing.
494+ Each list contains project_id and issue_id pairs so clients can resolve
495+ cross-project relations.
488496 """
489497
490498 blocking = serializers .ListField (
491- child = serializers . UUIDField (),
492- help_text = "List of issue IDs that are blocking this issue" ,
499+ child = IssueRelationRefSerializer (),
500+ help_text = "Work items blocking this issue" ,
493501 )
494502 blocked_by = serializers .ListField (
495- child = serializers . UUIDField (),
496- help_text = "List of issue IDs that this issue is blocked by" ,
503+ child = IssueRelationRefSerializer (),
504+ help_text = "Work items this issue is blocked by" ,
497505 )
498506 duplicate = serializers .ListField (
499- child = serializers . UUIDField (),
500- help_text = "List of issue IDs that are duplicates of this issue " ,
507+ child = IssueRelationRefSerializer (),
508+ help_text = "Duplicate work items " ,
501509 )
502510 relates_to = serializers .ListField (
503- child = serializers . UUIDField (),
504- help_text = "List of issue IDs that relate to this issue " ,
511+ child = IssueRelationRefSerializer (),
512+ help_text = "Related work items " ,
505513 )
506514 start_after = serializers .ListField (
507- child = serializers . UUIDField (),
508- help_text = "List of issue IDs that start after this issue" ,
515+ child = IssueRelationRefSerializer (),
516+ help_text = "Work items that start after this issue" ,
509517 )
510518 start_before = serializers .ListField (
511- child = serializers . UUIDField (),
512- help_text = "List of issue IDs that start before this issue" ,
519+ child = IssueRelationRefSerializer (),
520+ help_text = "Work items that start before this issue" ,
513521 )
514522 finish_after = serializers .ListField (
515- child = serializers . UUIDField (),
516- help_text = "List of issue IDs that finish after this issue" ,
523+ child = IssueRelationRefSerializer (),
524+ help_text = "Work items that finish after this issue" ,
517525 )
518526 finish_before = serializers .ListField (
519- child = serializers . UUIDField (),
520- help_text = "List of issue IDs that finish before this issue" ,
527+ child = IssueRelationRefSerializer (),
528+ help_text = "Work items that finish before this issue" ,
521529 )
522530
523531
0 commit comments