feat(register status):add

This commit is contained in:
shahzeydyfah
2024-03-16 06:55:10 +03:30
parent 855af7e52a
commit d95d4485e1
+1 -1
View File
@@ -11,5 +11,5 @@ class RegisterStatusRepository(BaseRepository[RegisterStatusModel]):
super().__init__(collection=TaskEnv.CLN_AUDIT_STATUS,model=RegisterStatusModel)
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