Skip to content

Commit 8db35c4

Browse files
authored
fix: Document upload prompt: missing status list field (#1991)
1 parent 923c755 commit 8db35c4

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

apps/dataset/serializers/document_serializers.py

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -700,7 +700,11 @@ def edit(self, instance: Dict, with_valid=False):
700700
_document.save()
701701
return self.one()
702702

703-
def refresh(self, state_list, with_valid=True):
703+
def refresh(self, state_list=None, with_valid=True):
704+
if state_list is None:
705+
state_list = [State.PENDING.value, State.STARTED.value, State.SUCCESS.value, State.FAILURE.value,
706+
State.REVOKE.value,
707+
State.REVOKED.value, State.IGNORED.value]
704708
if with_valid:
705709
self.is_valid(raise_exception=True)
706710
document_id = self.data.get("document_id")

0 commit comments

Comments
 (0)