|
|
|
@ -439,9 +439,9 @@ async def get_count_remaining_life(*, db_session: DbSession, common) -> dict[str
|
|
|
|
row = result.mappings().one()
|
|
|
|
row = result.mappings().one()
|
|
|
|
|
|
|
|
|
|
|
|
return {
|
|
|
|
return {
|
|
|
|
"safe": int(row["red"] or 0),
|
|
|
|
"safe": int(row["green"] or 0),
|
|
|
|
"warning": int(row["orange"] or 0),
|
|
|
|
"warning": int(row["orange"] or 0),
|
|
|
|
"critical": int(row["green"] or 0),
|
|
|
|
"critical": int(row["red"] or 0),
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
async def get_top_10_replacement_priorities(*, db_session: DbSession, common) -> list[Equipment]:
|
|
|
|
async def get_top_10_replacement_priorities(*, db_session: DbSession, common) -> list[Equipment]:
|
|
|
|
|