alchemy functions updated

This commit is contained in:
2024-11-10 12:49:31 +03:00
parent e01a2c8afb
commit 7a7241c71c
13 changed files with 238 additions and 180 deletions

View File

@@ -235,7 +235,9 @@ class ServiceBindEmployeeEventMethods(MethodToEvent):
detail="Occupant is not authorized to add service to any employee",
)
employee = Employees.filter_by_one(uu_id=data.employee_uu_id, *Employees.valid_record_dict).data
employee = Employees.filter_by_one(
uu_id=data.employee_uu_id, *Employees.valid_record_dict
).data
if not employee:
return JSONResponse(
content={
@@ -246,7 +248,9 @@ class ServiceBindEmployeeEventMethods(MethodToEvent):
status_code=status.HTTP_404_NOT_FOUND,
)
service = Services.filter_by_one(uu_id=data.service_uu_id, *Services.valid_record_dict).data
service = Services.filter_by_one(
uu_id=data.service_uu_id, *Services.valid_record_dict
).data
if not service:
return JSONResponse(
content={