refactor: replace Wizard with CoopBuilder in navigation, enhance budget store structure, and streamline template components for improved user experience

This commit is contained in:
Jennie Robinson Faber 2025-08-17 17:25:04 +01:00
parent eede87a273
commit f67b138d95
33 changed files with 4970 additions and 2451 deletions

22
stores/plan.ts Normal file
View file

@ -0,0 +1,22 @@
import { defineStore } from 'pinia';
import type { Member, Offer } from '~/types/coaching';
import type { StreamRow } from '~/utils/offerToStream';
import { offersToStreams } from '~/utils/offerToStream';
export const usePlanStore = defineStore('plan', {
state: () => ({
members: [] as Member[],
streams: [] as StreamRow[]
}),
actions: {
setMembers(m: Member[]) {
this.members = m;
},
addStreamsFromOffers(o: Offer[]) {
const newStreams = offersToStreams(o, this.members);
this.streams.push(...newStreams);
}
}
});