fix(contract):change required field to optional in detail
This commit is contained in:
@@ -11,7 +11,7 @@ class RegisterStatusRepository(BaseRepository):
|
|||||||
|
|
||||||
async def get_last(self,project_id:uuid.UUID):
|
async def get_last(self,project_id:uuid.UUID):
|
||||||
last = await use_collection(TaskEnv.CLN_AUDIT_STATUS).find({"project_id":project_id}).sort('$natural', -1).to_list(1)
|
last = await use_collection(TaskEnv.CLN_AUDIT_STATUS).find({"project_id":project_id}).sort('$natural', -1).to_list(1)
|
||||||
if last:
|
if last and len(last) > 0 and 'number' in last[0]:
|
||||||
return last[0]['number']
|
return last[0]['number']
|
||||||
else:
|
else:
|
||||||
return None
|
return None
|
||||||
|
|||||||
Reference in New Issue
Block a user