task(B5): seat counting by row and block
This commit is contained in:
@@ -352,8 +352,18 @@ export class SeatingService {
|
||||
return [];
|
||||
}
|
||||
|
||||
/** Count seats in a list of elements */
|
||||
countSeats(elements: CADElement[]): { total: number; byRow: Record<string, number>; byBlock: Record<string, number> } {
|
||||
/**
|
||||
* Zählt Sitzplätze gruppiert nach Reihe und Block.
|
||||
* byRow enthält Reihen aus freien Reihen UND Block-Reihen (seit BUG-1-Fix
|
||||
* tragen Block-Stühle pro Reihe eine eigene rowId).
|
||||
*/
|
||||
countSeats(elements: CADElement[]): {
|
||||
total: number;
|
||||
byRow: Record<string, number>;
|
||||
byBlock: Record<string, number>;
|
||||
/** Platzhalter für künftige Zonen-Gruppierung (aktuell immer leer). */
|
||||
byZone?: Record<string, number>;
|
||||
} {
|
||||
let total = 0;
|
||||
const byRow: Record<string, number> = {};
|
||||
const byBlock: Record<string, number> = {};
|
||||
|
||||
Reference in New Issue
Block a user