This commit is contained in:
seb
2026-09-27 07:08:13 +02:00
parent 3ab9d904e6
commit 559307675c
13 changed files with 845 additions and 8 deletions

View File

@@ -54,6 +54,16 @@ const actions = {
return row;
},
/**
* Delete a brand by id.
* @param {number} id
*/
async remove(id) {
await brandApi.delete(id);
const brands = brandAutomat.state.brands.filter((b) => b.id !== id);
brandAutomat.setState({ brands });
},
/** Reset to idle state (called on logout / company switch). */
reset() {
brandAutomat.setState(initialState);