|
|
|
@ -39,7 +39,7 @@ active_simulations = {}
|
|
|
|
# Get Data Service
|
|
|
|
# Get Data Service
|
|
|
|
async def get_all(common, current_user):
|
|
|
|
async def get_all(common, current_user):
|
|
|
|
query = select(AerosSimulation).order_by(desc(AerosSimulation.created_at))
|
|
|
|
query = select(AerosSimulation).order_by(desc(AerosSimulation.created_at))
|
|
|
|
query = query.where(AerosSimulation.status == "completed")
|
|
|
|
# query = query.where(AerosSimulation.status == "completed")
|
|
|
|
if current_user.role.lower() != "admin":
|
|
|
|
if current_user.role.lower() != "admin":
|
|
|
|
query = query.where(AerosSimulation.created_by == current_user.user_id)
|
|
|
|
query = query.where(AerosSimulation.created_by == current_user.user_id)
|
|
|
|
|
|
|
|
|
|
|
|
|