fix(game-ui): 암행부 예약 명령 요약을 복원

암행부 API가 앞 5턴의 action과 args를 함께 반환하도록 수정한다.\n개인턴·사령부 공용 formatter를 암행부와 세력도시 연동 표에 적용하고 Chromium 회귀를 추가한다.
This commit is contained in:
2026-08-21 02:48:44 +00:00
parent 4eb80c2970
commit 89f2c6a176
6 changed files with 173 additions and 17 deletions
@@ -64,16 +64,16 @@ export const getSecretGeneralList = accessAuthedProcedure.query(async ({ ctx })
const turns = generalIds.length
? await ctx.db.generalTurn.findMany({
where: { generalId: { in: generalIds }, turnIdx: { lt: 5 } },
select: { generalId: true, turnIdx: true, actionCode: true },
select: { generalId: true, turnIdx: true, actionCode: true, arg: true },
orderBy: [{ generalId: 'asc' }, { turnIdx: 'asc' }],
})
: [];
const cityNames = new Map(cities.map((city) => [city.id, city.name]));
const troopNames = new Map(troops.map((troop) => [troop.troopLeaderId, troop.name]));
const turnMap = new Map<number, string[]>();
const turnMap = new Map<number, Array<{ action: string; args: unknown }>>();
for (const turn of turns) {
const list = turnMap.get(turn.generalId) ?? [];
list[turn.turnIdx] = turn.actionCode;
list[turn.turnIdx] = { action: turn.actionCode, args: turn.arg };
turnMap.set(turn.generalId, list);
}
const generals = generalRows.map((general) => {