fix(regulatory): 轮询时加载条件确认卡
This commit is contained in:
@@ -23,8 +23,7 @@ def batch_status(request, batch_id: int):
|
||||
workflow_type="regulatory_review",
|
||||
workflow_batch_id=batch.pk,
|
||||
).order_by("id")
|
||||
return JsonResponse(
|
||||
{
|
||||
payload = {
|
||||
"batch": {
|
||||
"id": batch.pk,
|
||||
"workflow_type": "regulatory_review",
|
||||
@@ -46,7 +45,14 @@ def batch_status(request, batch_id: int):
|
||||
for node in nodes
|
||||
],
|
||||
}
|
||||
)
|
||||
if batch.status == RegulatoryReviewBatch.Status.WAITING_USER and (batch.condition_json or {}).get("candidates"):
|
||||
payload["condition_confirmation"] = {
|
||||
"batch_id": batch.pk,
|
||||
"batch_no": batch.batch_no,
|
||||
"confirm_url": f"/api/review-agent/regulatory-review/{batch.pk}/conditions/",
|
||||
"candidates": batch.condition_json["candidates"],
|
||||
}
|
||||
return JsonResponse(payload)
|
||||
|
||||
|
||||
@require_http_methods(["POST"])
|
||||
|
||||
Reference in New Issue
Block a user