feat(register status):add
This commit is contained in:
@@ -11,5 +11,5 @@ class RegisterStatusRepository(BaseRepository[RegisterStatusModel]):
|
|||||||
super().__init__(collection=TaskEnv.CLN_AUDIT_STATUS,model=RegisterStatusModel)
|
super().__init__(collection=TaskEnv.CLN_AUDIT_STATUS,model=RegisterStatusModel)
|
||||||
|
|
||||||
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_one({"project_id":project_id}).sort('$natural', -1)
|
last = await use_collection(TaskEnv.CLN_AUDIT_STATUS).find({"project_id":project_id}).sort('$natural', -1).to_list(1)
|
||||||
return last
|
return last
|
||||||
|
|||||||
Reference in New Issue
Block a user