events are updated

This commit is contained in:
2024-11-08 18:23:28 +03:00
parent c5b771e5cb
commit df5927e5ac
37 changed files with 223 additions and 149 deletions

View File

@@ -14,7 +14,7 @@ from api_validations.validations_request import (
from api_events.events.abstract_class import MethodToEvent, ActionsSchema
from api_objects.auth.token_objects import EmployeeTokenObject, OccupantTokenObject
from api_validations.core_response import return_json_response_from_alchemy
from api_validations.core_response import AlchemyJsonResponse
class CompanyListEventMethods(MethodToEvent):
@@ -45,8 +45,10 @@ class CompanyListEventMethods(MethodToEvent):
records = Companies.filter_active(
*Companies.get_smart_query(list_options.query)
)
return return_json_response_from_alchemy(
response=records, pagination=list_options
return AlchemyJsonResponse(
completed=True,
message="Building Living Spaces are listed successfully",
result=records,
)