minor fir

main
Cizz22 7 months ago
parent 4b7976aa6a
commit 2f8b2162ee

@ -137,6 +137,12 @@ async def execute_simulation(
) )
async def get_all_aeros_node(*, db_session: DbSession):
query = select(AerosNode)
results = await db_session.execute(query)
return results.scalars().all()
async def save_simulation_result( async def save_simulation_result(
*, db_session: DbSession, simulation_id: UUID, result: dict *, db_session: DbSession, simulation_id: UUID, result: dict
): ):
@ -146,10 +152,8 @@ async def save_simulation_result(
"""Save the simulation result""" """Save the simulation result"""
avaiable_nodes = { avaiable_nodes = {
node["nodeId"]: await get_simulation_node_by( node.node_id: node
db_session=db_session, node_id=node["nodeId"] for node in await get_all_aeros_node(db_session=db_session)
)
for node in calc_result
} }
calc_objects = [] calc_objects = []
plot_objects = [] plot_objects = []

Loading…
Cancel
Save