Skip to content

Commit

Permalink
fix: Document upload prompt: missing status list field
Browse files Browse the repository at this point in the history
  • Loading branch information
shaohuzhang1 committed Jan 7, 2025
1 parent 923c755 commit 0206150
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion apps/dataset/serializers/document_serializers.py
Original file line number Diff line number Diff line change
Expand Up @@ -700,7 +700,11 @@ def edit(self, instance: Dict, with_valid=False):
_document.save()
return self.one()

def refresh(self, state_list, with_valid=True):
def refresh(self, state_list=None, with_valid=True):
if state_list is None:
state_list = [State.PENDING.value, State.STARTED.value, State.SUCCESS.value, State.FAILURE.value,
State.REVOKE.value,
State.REVOKED.value, State.IGNORED.value]
if with_valid:
self.is_valid(raise_exception=True)
document_id = self.data.get("document_id")
Expand Down

0 comments on commit 0206150

Please sign in to comment.