import{q as l,r as n,s as x}from"./chunk-JBWPPKX4.js";import{fa as p}from"./chunk-PVUKHE45.js";import{d as c,n as m}from"./chunk-VD6R3735.js";import{a as b,b as i}from"./chunk-MZPAXKJS.js";var S=(()=>{let t=class t{constructor(s){this.employee=s}};t.type="[Employee] Set Employee";let e=t;return e})(),f=(()=>{let t=class t{constructor(s){this.employee=s}};t.type="[Employee] Update Employee";let e=t;return e})(),g=(()=>{let t=class t{};t.type="[Employee] Reset Employee";let e=t;return e})();var u=(()=>{let t=class t{constructor(s){this.cashboxes=s}};t.type="[Cashboxes] Set Cashboxes";let e=t;return e})(),C=(()=>{let t=class t{constructor(s){this.cashbox=s}};t.type="[Cashboxes] Set Cashbox";let e=t;return e})(),d=(()=>{let t=class t{constructor(s,h){this.cashboxId=s,this.settings=h}};t.type="[Cashboxes] Update Cashbox Settings";let e=t;return e})(),y=(()=>{let t=class t{};t.type="[Cashboxes] Clear Cashboxes";let e=t;return e})();m();var o,r=(o=class{static cashboxes(t){return t.cashboxes}static selectedCashbox(t){return t.selectedCashboxes}setCashboxes(t,a){t.setState({cashboxes:a.cashboxes,selectedCashboxes:t.getState().selectedCashboxes})}setSelectedCashbox(t,a){t.setState({selectedCashboxes:a.cashbox,cashboxes:t.getState().cashboxes})}updateCashboxSettings(t,a){let s=t.getState().cashboxes.map(h=>h.id===a.cashboxId?i(b({},h),{settings:a.settings}):h);t.patchState({cashboxes:s})}clearCashboxes(t){t.setState({cashboxes:[],selectedCashboxes:null})}},o.\u0275fac=function(a){return new(a||o)},o.\u0275prov=p({token:o,factory:o.\u0275fac}),o);c([l(u)],r.prototype,"setCashboxes",null);c([l(C)],r.prototype,"setSelectedCashbox",null);c([l(d)],r.prototype,"updateCashboxSettings",null);c([l(y)],r.prototype,"clearCashboxes",null);c([x()],r,"cashboxes",null);c([x()],r,"selectedCashbox",null);r=c([n({name:"cashboxes",defaults:{cashboxes:[],selectedCashboxes:null}})],r);export{S as a,f as b,g as c,u as d,d as e,r as f};
//# sourceMappingURL=chunk-ZNYLCQSJ.js.map
