updated reachables
This commit is contained in:
@@ -374,6 +374,8 @@ class Event2Occupant(CrudCollection):
|
||||
cls.set_session(db)
|
||||
Service2Events.set_session(db)
|
||||
Events.set_session(db)
|
||||
Event2OccupantExtra.set_session(db)
|
||||
|
||||
occupant_events = cls.query.filter(cls.build_living_space_id == build_living_space_id).all()
|
||||
service_ids = list(set([event.event_service_id for event in occupant_events]))
|
||||
active_event_ids = Service2Events.query.filter(Service2Events.service_id.in_(service_ids)).all()
|
||||
@@ -409,6 +411,7 @@ class Application2Employee(CrudCollection):
|
||||
Service2Application.set_session(db)
|
||||
Applications.set_session(db)
|
||||
Application2EmployeeExtra.set_session(db)
|
||||
|
||||
employee_services = cls.query.filter(cls.employee_id == employee_id).all()
|
||||
service_ids = [service.service_id for service in employee_services]
|
||||
active_applications = Service2Application.query.filter(Service2Application.service_id.in_(service_ids)).all()
|
||||
|
||||
Reference in New Issue
Block a user