dealposbooks 5.46.1 → 5.46.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/{chunk-GKXIOXWW.js → chunk-45JI5H5L.js} +2 -2
- package/{chunk-HXXN64RL.js → chunk-4IHVNLEA.js} +1 -1
- package/{chunk-Z2ADGCWR.js → chunk-4ODQPLDW.js} +1 -1
- package/{chunk-PRW2K6L4.js → chunk-5GAJOO6O.js} +2 -2
- package/{chunk-Y3UB475V.js → chunk-5RW6MEBV.js} +1 -1
- package/{chunk-VBCL4G4V.js → chunk-6LW7PY2Z.js} +1 -1
- package/{chunk-ME7O3OZS.js → chunk-6VBTHQT3.js} +1 -1
- package/{chunk-6HNKPNHQ.js → chunk-7DJNG6VE.js} +1 -1
- package/{chunk-53W5RLOG.js → chunk-B2BDKUAE.js} +2 -2
- package/{chunk-DAUF3TQ2.js → chunk-BJBAWNDR.js} +1 -1
- package/{chunk-A3XYHEBB.js → chunk-BKLUYVDG.js} +1 -1
- package/{chunk-KYQ3HOYB.js → chunk-BVXYCUBY.js} +1 -1
- package/{chunk-XILZA7G5.js → chunk-C6TI7B2G.js} +1 -1
- package/{chunk-OKX4P7HR.js → chunk-CO2UYCZ2.js} +1 -1
- package/{chunk-JYEZYL2U.js → chunk-DFGIXWZK.js} +1 -1
- package/{chunk-56N6E5N3.js → chunk-EAEMBSUD.js} +1 -1
- package/{chunk-BPBHYTKN.js → chunk-ETHACYOI.js} +1 -1
- package/{chunk-7UGQCTEO.js → chunk-EXBBFIDN.js} +1 -1
- package/{chunk-MOUK63TZ.js → chunk-FMHGC2MA.js} +1 -1
- package/{chunk-KGTXHU4K.js → chunk-G6IPI7YM.js} +1 -1
- package/{chunk-PQB7CIVB.js → chunk-G7QPRYOR.js} +1 -1
- package/{chunk-QXZZJ543.js → chunk-GXJ3G456.js} +1 -1
- package/{chunk-SZUKKFRX.js → chunk-IV5AW2OY.js} +1 -1
- package/{chunk-MYE27TEJ.js → chunk-IWF5R5FH.js} +1 -1
- package/{chunk-C2KFSD3V.js → chunk-KS2JAY2L.js} +1 -1
- package/{chunk-YUNKEY4N.js → chunk-MJSJBCDR.js} +1 -1
- package/{chunk-TYVIEINK.js → chunk-N4RQTE4T.js} +1 -1
- package/{chunk-IZCYMXSH.js → chunk-NHIAQTUJ.js} +1 -1
- package/{chunk-ZYDAEVQY.js → chunk-NPAM3NOH.js} +1 -1
- package/{chunk-SBAIX6FL.js → chunk-NQXDAWEZ.js} +1 -1
- package/{chunk-R7TX5W65.js → chunk-OR5FLZPY.js} +1 -1
- package/{chunk-FXWKWGGZ.js → chunk-PEOJDDJN.js} +1 -1
- package/{chunk-W4HYYYPX.js → chunk-PFWNBHNC.js} +1 -1
- package/{chunk-SLUPHKW6.js → chunk-PNWKCLWA.js} +1 -1
- package/{chunk-SPFVPLUI.js → chunk-Q34IDOYA.js} +1 -1
- package/{chunk-LLPR22QN.js → chunk-QUUGFWG3.js} +1 -1
- package/{chunk-ICH2UTRM.js → chunk-RZHWMBFY.js} +1 -1
- package/chunk-S7AFTSCW.js +1 -0
- package/{chunk-LWIIL6RI.js → chunk-T6OMUVQY.js} +1 -1
- package/{chunk-BPZ7LLVJ.js → chunk-UCDJJGO5.js} +1 -1
- package/{chunk-325YO3CB.js → chunk-UH5YUPBR.js} +1 -1
- package/{chunk-G25NFEKL.js → chunk-VKKAJODP.js} +1 -1
- package/{chunk-CRRQQY3W.js → chunk-WFQQUFSS.js} +1 -1
- package/{chunk-Y2PXP5OT.js → chunk-WKE2HPSD.js} +1 -1
- package/{chunk-NID2PW3N.js → chunk-WY2JNDES.js} +1 -1
- package/{chunk-TOSO7HJJ.js → chunk-X46QKMJY.js} +1 -1
- package/{chunk-O4TXGGHF.js → chunk-XFOCD2H7.js} +1 -1
- package/{chunk-JGRTH5OW.js → chunk-XFVMOYX7.js} +1 -1
- package/{chunk-OBX4APL6.js → chunk-XXNDXSPP.js} +1 -1
- package/{chunk-FYFSBGP3.js → chunk-Y3URGAXL.js} +1 -1
- package/{chunk-AS6FT6H3.js → chunk-YTZ3JIC5.js} +1 -1
- package/{chunk-QKRPHDSG.js → chunk-YZH7Y43Y.js} +1 -1
- package/{chunk-NLRLM4WP.js → chunk-ZWR2YCUC.js} +1 -1
- package/index.html +2 -2
- package/{main-7RGHX2IL.js → main-ON5LJQLR.js} +1 -1
- package/package.json +1 -1
- package/chunk-YM5BXLAN.js +0 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as I,b as k,c as F,d as j,e as R,f as O}from"./chunk-XD7VHCRC.js";import"./chunk-R7N6BWL5.js";import{a as E}from"./chunk-QF4D5YPK.js";import{b as T}from"./chunk-3GGXPPQT.js";import"./chunk-MFK5RQPJ.js";import"./chunk-Q24GCSGD.js";import{h as w}from"./chunk-
|
|
1
|
+
import{a as I,b as k,c as F,d as j,e as R,f as O}from"./chunk-XD7VHCRC.js";import"./chunk-R7N6BWL5.js";import{a as E}from"./chunk-QF4D5YPK.js";import{b as T}from"./chunk-3GGXPPQT.js";import"./chunk-MFK5RQPJ.js";import"./chunk-Q24GCSGD.js";import{h as w}from"./chunk-WKE2HPSD.js";import"./chunk-VGNJD35F.js";import{a as S}from"./chunk-2XUSZCQL.js";import"./chunk-YV2QJ63P.js";import"./chunk-ARH3WEEF.js";import"./chunk-H6HNANYB.js";import"./chunk-2D2YD753.js";import"./chunk-OIBDX2CA.js";import{a as P}from"./chunk-OR5FLZPY.js";import"./chunk-2MKKFLNJ.js";import{s as M}from"./chunk-VZ5CMS5O.js";import"./chunk-F2X3VGZZ.js";import{Db as h,Dc as _,Ha as u,Ob as v,Rb as m,Rc as C,Tb as c,Ub as s,Vb as o,Wb as r,_ as f,ca as d,fc as g,hb as n,ia as l,rc as p,sc as x,tc as y,xb as b}from"./chunk-NMCKMUY4.js";import"./chunk-YQFG5XE2.js";var D=(()=>{class e{constructor(){this.httpService=l(P)}getUserProfile(){return this.httpService.get(void 0,"api/MyProfile")}static{this.\u0275fac=function(i){return new(i||e)}}static{this.\u0275prov=d({token:e,factory:e.\u0275fac,providedIn:"root"})}}return e})();var A=()=>({height:"calc(100vh - 70px)"});function B(e,a){if(e&1&&(o(0,"div",10)(1,"div",11)(2,"p",12),p(3),r()()()),e&2){let t=a.$implicit;n(3),y(" ",t.roleName," ")}}function L(e,a){if(e&1&&(o(0,"div",4)(1,"div",5)(2,"div",6)(3,"span",7),p(4),r()()(),o(5,"div",8)(6,"div",9),c(7,B,4,1,"div",10,m),r()()()),e&2){let t=a.$implicit;n(4),x(t.roleGroupName),n(3),s(t.listRole)}}function $(e,a){if(e&1&&(o(0,"p-panel")(1,"p-tabs",2)(2,"p-tablist")(3,"p-tab",2),p(4,"Roles"),r()(),o(5,"p-tabpanels")(6,"p-tabpanel",2)(7,"div",3),c(8,L,9,1,"div",4,m),r()()()()()),e&2){let t,i=g();v(_(2,A)),n(8),s((t=i.roles())==null?null:t.Roles)}}var N=(()=>{class e{constructor(){this.profileService=l(D),this.roles=u(null)}ngOnInit(){this.profileService.getUserProfile().pipe(E("response"),f(t=>this.roles.set(t))).subscribe()}static{this.\u0275fac=function(i){return new(i||e)}}static{this.\u0275cmp=b({type:e,selectors:[["app-my-profile"]],decls:3,vars:0,consts:[["content",""],["pageTitle","My Profile"],["value","0"],["formArrayName","roles",1,"container-fluid","d-flex","flex-column","row-gap-3"],[1,"row"],[1,"col-2","border","d-flex","align-items-center","justify-content-between",2,"height","50px","background","#f6f6f6"],[1,"d-flex","justify-content-center","w-100"],[1,"text-dark","fw-semibold","fs-2"],[1,"col"],["formArrayName","roles",1,"row","h-100"],[1,"col-3","border-top","border-bottom","border-end","p-0","bg-white"],[1,"d-flex","h-100","align-items-center","gap-2","px-2"],[1,"fs-2","text-dark","m-0"]],template:function(i,G){i&1&&(o(0,"app-main-panel",1),h(1,$,10,3,"ng-template",null,0,C),r())},dependencies:[w,S,O,R,j,F,I,k,M,T],styles:["[_nghost-%COMP%]{display:block} .p-tabs .p-tab{padding-top:0!important}"],changeDetection:0})}}return e})();var le=[{path:"",redirectTo:"my-profile",pathMatch:"full"},{path:"",children:[{path:"my-profile",component:N}]}];export{le as PROFILE_ROUTES};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as D}from"./chunk-BPBHYTKN.js";import{a as it}from"./chunk-G4XX7EU2.js";import{a as Pe}from"./chunk-MOUK63TZ.js";import{a as Ue,b as He}from"./chunk-BLR3HBYP.js";import{a as te}from"./chunk-FYFSBGP3.js";import{b as N}from"./chunk-JYEZYL2U.js";import{a as Me}from"./chunk-XKI7WLHE.js";import{a as Ge,b as Be}from"./chunk-7DYACF4D.js";import"./chunk-NZN6QJR3.js";import"./chunk-IGWIRCAS.js";import{a as z,b as j}from"./chunk-3A4BFUGD.js";import{d as De,i as ke,j as Je,k as Ne}from"./chunk-EL5BUFMO.js";import{a as Ee,b as Te}from"./chunk-EQ4PLHI4.js";import"./chunk-H7Q35Y7G.js";import"./chunk-R7N6BWL5.js";import{a as Re}from"./chunk-QF4D5YPK.js";import"./chunk-2AAVNIG7.js";import{a as Ve,b as Fe}from"./chunk-LFZCMZAP.js";import"./chunk-6A2KUPOG.js";import"./chunk-36OX4S7M.js";import"./chunk-Q5CVMJZC.js";import"./chunk-3GGXPPQT.js";import"./chunk-MFK5RQPJ.js";import"./chunk-6GN3MGBY.js";import"./chunk-Q24GCSGD.js";import{g as we,h as Ie}from"./chunk-Y2PXP5OT.js";import{b as ve,c as ye}from"./chunk-VGNJD35F.js";import{a as _e,b as ge}from"./chunk-2XUSZCQL.js";import{a as y,b as he,c as Se,d as xe,e as Ce,f as be,g as tt}from"./chunk-YV2QJ63P.js";import"./chunk-ARH3WEEF.js";import{n as ce,o as de,w as ue,x as fe}from"./chunk-H6HNANYB.js";import"./chunk-2D2YD753.js";import{b as ie,c as ne,e as oe,f as re,k as le,l as ae,o as pe,u as me,x as se}from"./chunk-OIBDX2CA.js";import"./chunk-AOOG6YOT.js";import"./chunk-R7TX5W65.js";import"./chunk-2MKKFLNJ.js";import{h as $,j as Q,k as X,n as et,p as Y,q as Z,s as ee}from"./chunk-VZ5CMS5O.js";import"./chunk-F2X3VGZZ.js";import{$b as E,Bb as L,Cc as q,Db as g,Ec as V,Ha as k,Lb as s,Nc as w,Oc as P,Pc as F,Rc as b,Vb as l,Wb as o,Xb as x,Y as B,_ as G,bd as I,c as R,db as U,ec as T,fc as _,hb as a,ia as v,qa as h,ra as S,rc as m,s as O,sc as C,tc as J,ua as Ze,vc as A,wc as W,xb as H,xc as M,yc as K}from"./chunk-NMCKMUY4.js";import{a as c,b as d}from"./chunk-YQFG5XE2.js";var gt={data:{data:[],totalCount:0},meta:{options:{outlets:[],paymentStates:[],deliveryStates:[]},filter:{number:null,outletName:null,paymentState:0,deliveryState:0,from:null,to:null,customerID:null,pageNumber:1,pageSize:20,export:!1,exportPageNumber:1,exportPageSize:1e4}},filter:{number:null,outletName:null,paymentState:0,deliveryState:0,from:null,to:null,customerID:null,pageNumber:1,pageSize:20,export:!1,exportPageNumber:1,exportPageSize:1e4}},Ke=he(be(gt),Se(t=>({first:I(()=>(t.filter().pageNumber-1)*t.filter().pageSize+1),end:I(()=>Math.min(t.filter().pageNumber*t.filter().pageSize,t.data().totalCount)),hasCheckedRows:I(()=>t.data().data.some(p=>p.checked)),checkedInvoice:I(()=>t.data().data.filter(p=>p.checked).map(p=>p.id))})),Ce(t=>{let p=v(D),e=v(N);return{updateFilter(n){y(t,i=>d(c({},i),{filter:c(c({},i.filter),n),skipRequestFirst:!1}))},onRowSelect(n){y(t,i=>{let f=i.data.data.map(u=>u.id===n.id?d(c({},u),{checked:!0}):u);return d(c({},i),{data:d(c({},i.data),{data:f})})})},onRowUnselect(n){y(t,i=>{let f=i.data.data.map(u=>u.id===n.id?d(c({},u),{checked:!1}):u);return d(c({},i),{data:d(c({},i.data),{data:f})})})},onHeaderCheckboxToggle(n){y(t,i=>{let f=i.data.data.map(u=>d(c({},u),{checked:n}));return d(c({},i),{data:d(c({},i.data),{data:f})})})},getCustomerInvoice:z(R(O(n=>Object.entries(n).reduce((i,[f,u])=>(u!=null&&(i[f]=u),i),{})),B(n=>p.getJournalInvoice(n).pipe(O(i=>d(c({},i),{data:i.data.map(f=>d(c({},f),{due:e.from(f.due)?e.from(f.due).format():null,checked:!1}))})),Re("getCustomerInvoice"),j({next:i=>{y(t,f=>d(c({},f),{data:d(c({},f.data),{data:i.data,totalCount:i.totalCount})}))},error:i=>{console.error("Error fetching customer invoice:",i)}}))))),getCustomerInvoiceLoader:z(R(B(()=>p.getJournalInvoiceLoader().pipe(j({next:n=>{y(t,i=>d(c({},i),{meta:n}))},error:n=>{console.error("Error fetching customer invoice loader:",n)}})))))}}),xe(t=>({onInit:()=>{t.getCustomerInvoiceLoader(),t.getCustomerInvoice(t.filter)}})));var qe=t=>({"ng-invalid ng-dirty":t});function xt(t,p){if(t&1){let e=E();l(0,"p-button",10),T("onClick",function(){h(e);let n=_(2);return S(n.onGenerateJournal())}),o()}}function Ct(t,p){if(t&1&&g(0,xt,1,0,"p-button",9),t&2){let e=_();s("ngIf",e.store.hasCheckedRows())}}function bt(t,p){t&1&&(l(0,"tr")(1,"th",12),x(2,"p-tableHeaderCheckbox"),o(),l(3,"th",13),m(4,"Outlet"),o(),l(5,"th",14),m(6,"Number"),o(),l(7,"th",15),m(8,"Customer"),o(),l(9,"th",16),m(10,"Date"),o(),l(11,"th",16),m(12,"Due"),o(),l(13,"th",13),m(14,"Amount"),o(),l(15,"th",17),m(16,"Payment"),o(),l(17,"th",17),m(18,"Delivery"),o(),x(19,"th",18),o())}function vt(t,p){if(t&1&&(l(0,"tr")(1,"td"),x(2,"p-tableCheckbox",19),o(),l(3,"td"),m(4),o(),l(5,"td")(6,"a",20),m(7),o()(),l(8,"td")(9,"a",20),m(10),o()(),l(11,"td"),m(12),w(13,"date"),o(),l(14,"td"),m(15),w(16,"date"),o(),l(17,"td"),m(18),w(19,"number"),o(),l(20,"td"),x(21,"p-chip",21),o(),l(22,"td"),x(23,"p-chip",21),o(),l(24,"td"),x(25,"p-button",22),o()()),t&2){let e=p.$implicit,r=_(2);a(2),s("value",e),a(2),C(e.outlet),a(2),s("href",r.authService.getTenantExternalURL()+"/menu/Orders/Orders/Customer_Invoice/Info?ID="+e.id,U),a(),J(" ",e.number," "),a(2),s("href",r.authService.getTenantExternalURL()+"/menu/Contacts/Contact/Customers/Info?ID="+e.customerID,U),a(),J(" ",e.customer," "),a(2),C(F(13,14,e.date,"d MMM y hh:mm")),a(3),C(e.due?F(16,17,e.due,"d MMM y hh:mm"):"-"),a(3),C(P(19,20,e.amount)),a(3),s("label",e.payment),a(2),s("label",e.delivery),a(2),s("icon",e.integrated?"fa-solid fa-circle-check":"fa-solid fa-circle-xmark")("severity",e.integrated?"success":"danger")("text",!0)}}function yt(t,p){if(t&1&&m(0),t&2){let e=_(2);A(" Showing ",e.store.first()," to ",e.store.end()," of ",e.store.data().totalCount," entries ")}}function wt(t,p){t&1&&(l(0,"tr")(1,"td",23)(2,"span"),m(3,"No records found."),o()()())}function It(t,p){if(t&1){let e=E();l(0,"p-panel")(1,"p-table",11),T("onPage",function(n){h(e);let i=_();return S(i.onPageChange(n))})("onRowSelect",function(n){h(e);let i=_();return S(i.onRowSelect(n))})("onRowUnselect",function(n){h(e);let i=_();return S(i.onRowUnselect(n))})("onHeaderCheckboxToggle",function(n){h(e);let i=_();return S(i.onHeaderCheckboxToggle(n))}),g(2,bt,20,0,"ng-template",null,3,b)(4,vt,26,22,"ng-template",null,4,b)(6,yt,1,3,"ng-template",null,5,b)(8,wt,4,0,"ng-template",null,6,b),o()()}if(t&2){let e=_();a(),s("lazy",!0)("paginator",!0)("rows",e.store.filter().pageSize)("totalRecords",e.store.data().totalCount)("value",e.store.data().data)}}function Et(t,p){if(t&1&&(l(0,"span",36),m(1),w(2,"truncate"),o()),t&2){let e=p.$implicit;s("pTooltip",e.name),a(),J(" ",F(2,2,e.name,30)," ")}}function Tt(t,p){if(t&1&&(l(0,"div")(1,"span",38),m(2),o()()),t&2){let e=p.$implicit;a(2),C(e)}}function Vt(t,p){if(t&1&&(l(0,"div"),g(1,Tt,3,1,"div",37),o()),t&2){let e=_(2);a(),s("ngForOf",e.getErrors("from"))}}function Ft(t,p){if(t&1&&(l(0,"div")(1,"span",38),m(2),o()()),t&2){let e=p.$implicit;a(2),C(e)}}function Dt(t,p){if(t&1&&(l(0,"div"),g(1,Ft,3,1,"div",37),o()),t&2){let e=_(2);a(),s("ngForOf",e.getErrors("to"))}}function kt(t,p){if(t&1&&(l(0,"div")(1,"span",38),m(2),o()()),t&2){let e=p.$implicit;a(2),C(e)}}function Jt(t,p){if(t&1&&(l(0,"div"),g(1,kt,3,1,"div",37),o()),t&2){let e=_(2);a(),s("ngForOf",e.getErrors("pageSize"))}}function Nt(t,p){if(t&1){let e=E();l(0,"form",24)(1,"div",25)(2,"label",26),m(3,"Outlet"),o(),l(4,"p-select",27),g(5,Et,3,5,"ng-template",null,7,b),o()(),l(7,"div",25)(8,"label",26),m(9,"Payment"),o(),x(10,"p-select",28),o(),l(11,"div",25)(12,"label",26),m(13,"Delivery"),o(),x(14,"p-select",29),o(),l(15,"div",25)(16,"label",26),m(17,"From - To"),o(),l(18,"div",30),x(19,"p-datepicker",31),g(20,Vt,2,1,"div",32),x(21,"p-datepicker",33),g(22,Dt,2,1,"div",32),o()(),l(23,"div",25)(24,"label",26),m(25,"Customer"),o(),l(26,"p-autocomplete",34),T("completeMethod",function(n){h(e);let i=_();return S(i.onSearchContact(n))}),o()(),l(27,"div",25)(28,"label",26),m(29,"Page Size"),o(),x(30,"input",35),g(31,Jt,2,1,"div",32),o()()}if(t&2){let e=_();s("formGroup",e.form),a(4),s("virtualScrollItemSize",50)("options",e.store.meta().options.outlets),a(6),s("options",e.store.meta().options.paymentStates),a(4),s("options",e.store.meta().options.deliveryStates),a(5),s("iconDisplay","input")("showIcon",!0)("ngClass",V(16,qe,e.isInvalid("from"))),a(),s("ngIf",e.isInvalid("from")),a(),s("iconDisplay","input")("showIcon",!0)("ngClass",V(18,qe,e.isInvalid("to"))),a(),s("ngIf",e.isInvalid("to")),a(4),s("suggestions",e.customerSuggestions()),a(4),s("ngClass",V(20,qe,e.isInvalid("pageSize"))),a(),s("ngIf",e.isInvalid("pageSize"))}}var ut=(()=>{class t extends Me{constructor(){super(...arguments),this.store=v(Ke),this.dayjsService=v(N),this.generateJournalService=v(D),this.authService=v(te),this.isDialogFilterVisible=k(!1),this.isInitDialogFilterVisible=k(!1),this.customerSuggestions=k([]),this.fb=v(me)}ngOnInit(){console.log(this.dayjsService.from('0001-01-01T00:00:00"')&&!0),this.generateFilterForm()}generateFilterForm(){let{number:e,outletName:r,paymentState:n,deliveryState:i,from:f,to:u,customerID:ze,pageNumber:je,pageSize:Oe,export:Le,exportPageNumber:Ae,exportPageSize:We}=this.store.filter();this.form=this.fb.group({number:this.fb.control(e),outletName:this.fb.control(r),paymentState:this.fb.control(n),deliveryState:this.fb.control(i),from:this.fb.control(this.dayjsService.from(f)?this.dayjsService.from(f).toDate():null),to:this.fb.control(this.dayjsService.from(u)?this.dayjsService.from(u).toDate():null),customerID:this.fb.control(ze),pageNumber:this.fb.control(je),pageSize:this.fb.control(Oe,[ne.required]),export:this.fb.control(Le),exportPageNumber:this.fb.control(Ae),exportPageSize:this.fb.control(We)})}onSearchContact(e){let{query:r}=e;this.generateJournalService.getCustomerSuggestions(r).pipe(Re("Customer Suggestions"),G(n=>{this.customerSuggestions.set(n)})).subscribe()}onSearch(e){this.store.updateFilter(d(c({},this.store.filter()),{number:e}))}onRowSelect(e){this.store.onRowSelect(e.data)}onRowUnselect(e){if(Array.isArray(e.data)){e.data.forEach(r=>{this.store.onRowUnselect(r)});return}else this.store.onRowUnselect(e.data)}onHeaderCheckboxToggle(e){this.store.onHeaderCheckboxToggle(e.checked)}onPageChange(e){let r=e.first/e.rows;this.store.updateFilter(d(c({},this.store.filter()),{pageNumber:r+1}))}onGenerateJournal(){this.generateJournalService.generateJournalInvoice(this.store.checkedInvoice()).pipe(G(()=>{this.store.getCustomerInvoice(this.store.filter)})).subscribe()}onFilterOKEvent(){if(this.form.invalid){this.form.markAllAsTouched();return}let e=Object.entries(this.form.getRawValue()).reduce((r,[n,i])=>{switch(n){case"customerID":i||(r[n]=it);break;case"from":typeof i=="object"?r[n]=this.dayjsService.from(i)?this.dayjsService.format(i):null:r[n]=i!=null?String(i):null;break;case"to":typeof i=="object"?r[n]=this.dayjsService.from(i)?this.dayjsService.format(i):null:r[n]=i!=null?String(i):null;break;default:r[n]=i===null?"":i;break}return r},{});console.log("Filter Body:",e),this.store.updateFilter(e),this.isDialogFilterVisible.set(!1)}static{this.\u0275fac=(()=>{let e;return function(n){return(e||(e=Ze(t)))(n||t)}})()}static{this.\u0275cmp=H({type:t,selectors:[["app-customer-invoice"]],features:[q([Ke]),L],decls:7,vars:5,consts:[["actionButton",""],["content",""],["filters",""],["header",""],["body",""],["paginatorleft",""],["emptymessage",""],["item",""],["pageTitle","Customer Invoice",3,"isDialogFilterVisibleChange","isInitDialogFilterVisibleChange","filterConfirmed","search","isSearchableInput","isFilterable","isDialogFilterVisible","isInitDialogFilterVisible","scrollable"],["label","Generate Journal",3,"onClick",4,"ngIf"],["label","Generate Journal",3,"onClick"],["dataKey","id",3,"onPage","onRowSelect","onRowUnselect","onHeaderCheckboxToggle","lazy","paginator","rows","totalRecords","value"],[2,"width","1rem"],[2,"width","10rem"],[2,"width","12rem"],[2,"width","14rem"],[2,"width","11rem"],[2,"width","9rem"],[2,"width","4rem"],[3,"value"],["target","_blank",1,"link","link-primary",3,"href"],[3,"label"],[3,"icon","severity","text"],["colspan","10"],[1,"d-flex","flex-column","row-gap-3",3,"formGroup"],[1,"d-flex","flex-column"],["for","outlet"],["virtualScroll","","showClear","","filter","","filterBy","name","formControlName","outletName","appendTo","body","optionLabel","name","optionValue","name","placeholder","Select an Outlet",3,"virtualScrollItemSize","options"],["showClear","","formControlName","paymentState","appendTo","body","optionLabel","value","optionValue","key","placeholder","Select a Payment",3,"options"],["showClear","","formControlName","deliveryState","appendTo","body","optionLabel","value","optionValue","key","placeholder","Select a Delivery",3,"options"],[1,"d-flex","flex-column","gap-2"],["showClear","","formControlName","from","styleClass","w-100","appendTo","body","inputId","icondisplay",3,"iconDisplay","showIcon","ngClass"],[4,"ngIf"],["showClear","","formControlName","to","styleClass","w-100","appendTo","body","inputId","icondisplay",3,"iconDisplay","showIcon","ngClass"],["showClear","","formControlName","customerID","appendTo","body","styleClass","w-100","optionLabel","Value","optionValue","Key","inputStyleClass","w-100",3,"completeMethod","suggestions"],["type","text","pInputText","","formControlName","pageSize","appMaskNumber","",3,"ngClass"],[3,"pTooltip"],[4,"ngFor","ngForOf"],[1,"text-danger"]],template:function(r,n){if(r&1){let i=E();l(0,"app-main-panel",8),K("isDialogFilterVisibleChange",function(u){return h(i),M(n.isDialogFilterVisible,u)||(n.isDialogFilterVisible=u),S(u)})("isInitDialogFilterVisibleChange",function(u){return h(i),M(n.isInitDialogFilterVisible,u)||(n.isInitDialogFilterVisible=u),S(u)}),T("filterConfirmed",function(){return h(i),S(n.onFilterOKEvent())})("search",function(u){return h(i),S(n.onSearch(u))}),g(1,Ct,1,1,"ng-template",null,0,b)(3,It,10,5,"ng-template",null,1,b)(5,Nt,32,22,"ng-template",null,2,b),o()}r&2&&(s("isSearchableInput",!0)("isFilterable",!0),W("isDialogFilterVisible",n.isDialogFilterVisible)("isInitDialogFilterVisible",n.isInitDialogFilterVisible),s("scrollable",!0))},dependencies:[Ie,Ne,De,ke,Je,ee,$,Q,X,Z,Y,Be,Ge,ge,_e,fe,ue,Fe,Ve,Te,Ee,de,ce,He,Ue,se,le,ie,oe,re,ae,pe,ye,ve,we,Pe],encapsulation:2,changeDetection:0})}}return t})();var Rt={data:{data:[],totalCount:0},meta:{options:{Outlets:[],PaymentStates:[],DeliveryStates:[]},filter:{number:null,outletName:null,paymentState:0,deliveryState:0,from:null,to:null,supplierID:null,pageNumber:1,pageSize:20,export:!1,exportPageNumber:1,exportPageSize:1e4}},filter:{number:null,outletName:null,paymentState:0,deliveryState:0,from:null,to:null,supplierID:null,pageNumber:1,pageSize:20,export:!1,exportPageNumber:1,exportPageSize:1e4},skipRequestFirst:!0},$e=he(tt("JournalSupplierBillStore"),be(Rt),Se(t=>({first:I(()=>(t.filter().pageNumber-1)*t.filter().pageSize+1),end:I(()=>Math.min(t.filter().pageNumber*t.filter().pageSize,t.data().totalCount)),hasCheckedRows:I(()=>t.data().data.some(p=>p.checked)),checkedSupplierBill:I(()=>t.data().data.filter(p=>p.checked).map(p=>p.id))})),Ce(t=>{let p=v(D),e=v(N);return{updateFilter(r){y(t,n=>d(c({},n),{filter:c(c({},n.filter),r),skipRequestFirst:!1}))},onRowSelect(r){y(t,n=>{let i=n.data.data.map(f=>f.id===r.id?d(c({},f),{checked:!0}):f);return d(c({},n),{data:d(c({},n.data),{data:i})})})},onRowUnselect(r){y(t,n=>{let i=n.data.data.map(f=>f.id===r.id?d(c({},f),{checked:!1}):f);return d(c({},n),{data:d(c({},n.data),{data:i})})})},onHeaderCheckboxToggle(r){y(t,n=>{let i=n.data.data.map(f=>d(c({},f),{checked:r}));return d(c({},n),{data:d(c({},n.data),{data:i})})})},getGJSupplierBillLoader:z(R(B(()=>p.getGJSupplierBillLoader().pipe(j({next:r=>{console.log("GJSupplierBillLoader response:",r),y(t,n=>d(c({},n),{meta:r}))},error:r=>{console.error("Error fetching GJSupplierBillLoader:",r)}}))))),getJournalSupplierBill:z(R(O(r=>Object.entries(r).reduce((n,[i,f])=>(f!=null&&(n[i]=f),n),{})),B(r=>p.getJournalSupplierBill(r).pipe(O(n=>d(c({},n),{data:n.data.map(i=>d(c({},i),{due:e.from(i.due)?e.from(i.due).format():null,checked:!1}))})),j({next:n=>{y(t,i=>d(c({},i),{data:n}))},error:n=>{console.error("Error fetching journal supplier bill:",n)}})))))}}),xe(t=>({onInit:()=>{t.getGJSupplierBillLoader(),t.getJournalSupplierBill(t.filter)}})));var Qe=t=>({"ng-invalid ng-dirty":t});function Bt(t,p){if(t&1){let e=E();l(0,"p-button",10),T("onClick",function(){h(e);let n=_(2);return S(n.onGenerateJournal())}),o()}}function Mt(t,p){if(t&1&&g(0,Bt,1,0,"p-button",9),t&2){let e=_();s("ngIf",e.store.hasCheckedRows())}}function Pt(t,p){t&1&&(l(0,"tr")(1,"th",12),x(2,"p-tableHeaderCheckbox"),o(),l(3,"th",13),m(4,"Outlet"),o(),l(5,"th",14),m(6,"Number"),o(),l(7,"th",15),m(8,"Supplier"),o(),l(9,"th",16),m(10,"Date"),o(),l(11,"th",16),m(12,"Due"),o(),l(13,"th",13),m(14,"Amount"),o(),l(15,"th",17),m(16,"Payment"),o(),l(17,"th",17),m(18,"Delivery"),o(),x(19,"th",18),o())}function zt(t,p){if(t&1&&(l(0,"tr")(1,"td"),x(2,"p-tableCheckbox",19),o(),l(3,"td"),m(4),o(),l(5,"td")(6,"a",20),m(7),o()(),l(8,"td"),m(9),o(),l(10,"td"),m(11),w(12,"date"),o(),l(13,"td"),m(14),w(15,"date"),o(),l(16,"td"),m(17),w(18,"number"),o(),l(19,"td"),x(20,"p-chip",21),o(),l(21,"td"),x(22,"p-chip",21),o(),l(23,"td"),x(24,"p-button",22),o()()),t&2){let e=p.$implicit,r=_(2);a(2),s("value",e),a(2),C(e.outlet),a(2),s("href",r.authService.getTenantExternalURL()+"/menu/Orders/Orders/Supplier_Bill/Info?ID="+e.id,U),a(),J(" ",e.number," "),a(2),C(e.customer),a(2),C(F(12,13,e.date,"d MMM y hh:mm")),a(3),C(e.due?F(15,16,e.due,"d MMM y hh:mm"):"-"),a(3),C(P(18,19,e.amount)),a(3),s("label",e.payment),a(2),s("label",e.delivery),a(2),s("icon",e.integrated?"fa-solid fa-circle-check":"fa-solid fa-circle-xmark")("severity",e.integrated?"success":"danger")("text",!0)}}function jt(t,p){if(t&1&&m(0),t&2){let e=_(2);A(" Showing ",e.store.first()," to ",e.store.end()," of ",e.store.data().totalCount," entries ")}}function Ot(t,p){t&1&&(l(0,"tr")(1,"td",23)(2,"span"),m(3,"No records found."),o()()())}function Gt(t,p){if(t&1){let e=E();l(0,"p-panel")(1,"p-table",11),T("onPage",function(n){h(e);let i=_();return S(i.onPageChange(n))})("onRowSelect",function(n){h(e);let i=_();return S(i.onRowSelect(n))})("onRowUnselect",function(n){h(e);let i=_();return S(i.onRowUnselect(n))})("onHeaderCheckboxToggle",function(n){h(e);let i=_();return S(i.onHeaderCheckboxToggle(n))}),g(2,Pt,20,0,"ng-template",null,3,b)(4,zt,25,21,"ng-template",null,4,b)(6,jt,1,3,"ng-template",null,5,b)(8,Ot,4,0,"ng-template",null,6,b),o()()}if(t&2){let e=_();a(),s("value",e.store.data().data)("paginator",!0)("rows",e.store.filter().pageSize)("totalRecords",e.store.data().totalCount)("lazy",!0)}}function Ut(t,p){if(t&1&&(l(0,"span",36),m(1),w(2,"truncate"),o()),t&2){let e=p.$implicit;s("pTooltip",e.name),a(),J(" ",F(2,2,e.name,30)," ")}}function Ht(t,p){if(t&1&&(l(0,"div")(1,"span",38),m(2),o()()),t&2){let e=p.$implicit;a(2),C(e)}}function Lt(t,p){if(t&1&&(l(0,"div"),g(1,Ht,3,1,"div",37),o()),t&2){let e=_(2);a(),s("ngForOf",e.getErrors("from"))}}function At(t,p){if(t&1&&(l(0,"div")(1,"span",38),m(2),o()()),t&2){let e=p.$implicit;a(2),C(e)}}function Wt(t,p){if(t&1&&(l(0,"div"),g(1,At,3,1,"div",37),o()),t&2){let e=_(2);a(),s("ngForOf",e.getErrors("to"))}}function Kt(t,p){if(t&1&&(l(0,"div")(1,"span",38),m(2),o()()),t&2){let e=p.$implicit;a(2),C(e)}}function qt(t,p){if(t&1&&(l(0,"div"),g(1,Kt,3,1,"div",37),o()),t&2){let e=_(2);a(),s("ngForOf",e.getErrors("pageSize"))}}function $t(t,p){if(t&1){let e=E();l(0,"form",24)(1,"div",25)(2,"label",26),m(3,"Outlet"),o(),l(4,"p-select",27),g(5,Ut,3,5,"ng-template",null,7,b),o()(),l(7,"div",25)(8,"label",26),m(9,"Payment"),o(),x(10,"p-select",28),o(),l(11,"div",25)(12,"label",26),m(13,"Delivery"),o(),x(14,"p-select",29),o(),l(15,"div",25)(16,"label",26),m(17,"From - To"),o(),l(18,"div",30),x(19,"p-datepicker",31),g(20,Lt,2,1,"div",32),x(21,"p-datepicker",33),g(22,Wt,2,1,"div",32),o()(),l(23,"div",25)(24,"label",26),m(25,"Supplier"),o(),l(26,"p-autocomplete",34),w(27,"async"),T("completeMethod",function(n){h(e);let i=_();return S(i.onSearchSupplier(n))}),o()(),l(28,"div",25)(29,"label",26),m(30,"Page Size"),o(),x(31,"input",35),g(32,qt,2,1,"div",32),o()()}if(t&2){let e=_();s("formGroup",e.form),a(4),s("virtualScrollItemSize",50)("options",e.store.meta().options.Outlets),a(6),s("options",e.store.meta().options.PaymentStates),a(4),s("options",e.store.meta().options.DeliveryStates),a(5),s("iconDisplay","input")("showIcon",!0)("ngClass",V(18,Qe,e.isInvalid("from"))),a(),s("ngIf",e.isInvalid("from")),a(),s("iconDisplay","input")("showIcon",!0)("ngClass",V(20,Qe,e.isInvalid("to"))),a(),s("ngIf",e.isInvalid("to")),a(4),s("suggestions",P(27,16,e.supplierSuggestions$)),a(5),s("ngClass",V(22,Qe,e.isInvalid("pageSize"))),a(),s("ngIf",e.isInvalid("pageSize"))}}var ft=(()=>{class t extends Me{constructor(){super(),this.generateJournalService=v(D),this.store=v($e),this.authService=v(te),this.isDialogFilterVisible=k(!1),this.isInitDialogFilterVisible=k(!1),this.fb=v(me),this.dayjsService=v(N)}ngOnInit(){this.initform()}onFilterOKEvent(){if(this.form.invalid){this.form.markAllAsTouched();return}let e=Object.entries(this.form.getRawValue()).reduce((r,[n,i])=>(i!=null&&(n==="from"||n==="to"?(typeof i=="string"||typeof i=="number"||i instanceof Date)&&(r[n]=this.dayjsService.from(i)?this.dayjsService.format(i):null):r[n]=i),r),{});this.store.updateFilter(e),this.isDialogFilterVisible.update(r=>!r)}onRowSelect(e){this.store.onRowSelect(e.data)}onSearchSupplier(e){this.supplierSuggestions$=this.generateJournalService.getSupplierSuggestions(e.query).pipe(Re("Supplier Suggestions"))}initform(){let{outletName:e,number:r,from:n,to:i,paymentState:f,deliveryState:u,supplierID:ze,pageNumber:je,pageSize:Oe,export:Le,exportPageNumber:Ae,exportPageSize:We}=this.store.filter();this.form=this.fb.group({outletName:this.fb.control(e),number:this.fb.control(r),from:this.fb.control(this.dayjsService.from(n)?this.dayjsService.from(n).toDate():null),to:this.fb.control(this.dayjsService.from(i)?this.dayjsService.from(i).toDate():null),paymentState:this.fb.control(f),deliveryState:this.fb.control(u),supplierID:this.fb.control(ze),pageNumber:this.fb.control(je),pageSize:this.fb.control(Oe,[ne.required]),export:this.fb.control(Le),exportPageNumber:this.fb.control(Ae),exportPageSize:this.fb.control(We)})}onRowUnselect(e){if(Array.isArray(e.data)){e.data.forEach(r=>{this.store.onRowUnselect(r)});return}else this.store.onRowUnselect(e.data)}onHeaderCheckboxToggle(e){this.store.onHeaderCheckboxToggle(e.checked)}onGenerateJournal(){this.generateJournalService.generateJournalSupplierBill(this.store.checkedSupplierBill()).pipe(G(()=>{this.store.getJournalSupplierBill(this.store.filter)})).subscribe()}onSearch(e){this.store.updateFilter(d(c({},this.store.filter()),{number:e}))}onPageChange(e){this.store.updateFilter(d(c({},this.store.filter()),{pageNumber:e.first/e.rows+1}))}static{this.\u0275fac=function(r){return new(r||t)}}static{this.\u0275cmp=H({type:t,selectors:[["app-journal-supplier-bill"]],features:[q([$e]),L],decls:7,vars:5,consts:[["actionButton",""],["content",""],["filters",""],["header",""],["body",""],["paginatorleft",""],["emptymessage",""],["item",""],["pageTitle","Supplier Bill",3,"isDialogFilterVisibleChange","isInitDialogFilterVisibleChange","filterConfirmed","search","isSearchableInput","isFilterable","isDialogFilterVisible","isInitDialogFilterVisible","scrollable"],["label","Generate Journal",3,"onClick",4,"ngIf"],["label","Generate Journal",3,"onClick"],["dataKey","id",3,"onPage","onRowSelect","onRowUnselect","onHeaderCheckboxToggle","value","paginator","rows","totalRecords","lazy"],[2,"width","1rem"],[2,"width","10rem"],[2,"width","12rem"],[2,"width","14rem"],[2,"width","11rem"],[2,"width","9rem"],[2,"width","4rem"],[3,"value"],["target","_blank",1,"link","link-primary",3,"href"],[3,"label"],[3,"icon","severity","text"],["colspan","10"],[1,"d-flex","flex-column","row-gap-3",3,"formGroup"],[1,"d-flex","flex-column"],["for","outlet"],["virtualScroll","","showClear","","filter","","filterBy","name","formControlName","outletName","appendTo","body","optionLabel","name","optionValue","name","placeholder","Select an Outlet",3,"virtualScrollItemSize","options"],["showClear","","formControlName","paymentState","appendTo","body","optionLabel","value","optionValue","key","placeholder","Select a Payment",3,"options"],["showClear","","formControlName","deliveryState","appendTo","body","optionLabel","value","optionValue","key","placeholder","Select a Delivery",3,"options"],[1,"d-flex","flex-column","gap-2"],["showClear","","formControlName","from","styleClass","w-100","appendTo","body","inputId","icondisplay",3,"iconDisplay","showIcon","ngClass"],[4,"ngIf"],["showClear","","formControlName","to","styleClass","w-100","appendTo","body","inputId","icondisplay",3,"iconDisplay","showIcon","ngClass"],["showClear","","formControlName","supplierID","appendTo","body","styleClass","w-100","optionLabel","Value","optionValue","Key","inputStyleClass","w-100",3,"completeMethod","suggestions"],["type","text","pInputText","","appMaskNumber","","formControlName","pageSize",3,"ngClass"],[3,"pTooltip"],[4,"ngFor","ngForOf"],[1,"text-danger"]],template:function(r,n){if(r&1){let i=E();l(0,"app-main-panel",8),K("isDialogFilterVisibleChange",function(u){return h(i),M(n.isDialogFilterVisible,u)||(n.isDialogFilterVisible=u),S(u)})("isInitDialogFilterVisibleChange",function(u){return h(i),M(n.isInitDialogFilterVisible,u)||(n.isInitDialogFilterVisible=u),S(u)}),T("filterConfirmed",function(){return h(i),S(n.onFilterOKEvent())})("search",function(u){return h(i),S(n.onSearch(u))}),g(1,Mt,1,1,"ng-template",null,0,b)(3,Gt,10,5,"ng-template",null,1,b)(5,$t,33,24,"ng-template",null,2,b),o()}r&2&&(s("isSearchableInput",!0)("isFilterable",!0),W("isDialogFilterVisible",n.isDialogFilterVisible)("isInitDialogFilterVisible",n.isInitDialogFilterVisible),s("scrollable",!0))},dependencies:[Ie,Ne,De,ke,Je,ee,$,Q,X,et,Z,Y,Be,Ge,ge,_e,fe,ue,Fe,Ve,Te,Ee,He,Ue,se,le,ie,oe,re,ae,pe,de,ce,we,ye,ve,Pe],styles:["[_nghost-%COMP%]{display:block}"],changeDetection:0})}}return t})();var Qt={data:{data:[],totalCount:0},meta:{options:{outlets:[]},filter:{number:null,outletName:null,from:null,to:null,pageNumber:1,pageSize:20,export:!1,exportPageNumber:1,exportPageSize:1e4}},filter:{number:null,outletName:null,from:null,to:null,pageNumber:1,pageSize:20,export:!1,exportPageNumber:1,exportPageSize:1e4}},Xe=he(be(Qt),Se(t=>({first:I(()=>(t.filter().pageNumber-1)*t.filter().pageSize+1),end:I(()=>Math.min(t.filter().pageNumber*t.filter().pageSize,t.data().totalCount)),hasCheckedRows:I(()=>t.data().data.some(p=>p.checked)),checkedShift:I(()=>t.data().data.filter(p=>p.checked).map(p=>p.id))})),Ce(t=>{let p=v(D);return{updateFilter(e){y(t,r=>d(c({},r),{filter:c(c({},r.filter),e)}))},onRowSelect(e){y(t,r=>{let n=r.data.data.map(i=>i.id===e.id?d(c({},i),{checked:!0}):i);return d(c({},r),{data:d(c({},r.data),{data:n})})})},onRowUnselect(e){y(t,r=>{let n=r.data.data.map(i=>i.id===e.id?d(c({},i),{checked:!1}):i);return d(c({},r),{data:d(c({},r.data),{data:n})})})},onHeaderCheckboxToggle(e){y(t,r=>{let n=r.data.data.map(i=>d(c({},i),{checked:e}));return d(c({},r),{data:d(c({},r.data),{data:n})})})},getGJShiftLoader:z(R(B(()=>p.getGJShiftLoader().pipe(j(e=>y(t,r=>d(c({},r),{meta:e})),e=>console.error("Error fetching GJ Shift Loader:",e)))))),getJournalShift:z(R(O(e=>Object.entries(e).reduce((r,[n,i])=>(i!=null&&(r[n]=i),r),{})),B(e=>p.getJournalShift(e).pipe(j(r=>y(t,n=>d(c({},n),{data:r})),r=>console.error("Error fetching journal shift:",r))))))}}),xe(t=>({onInit:()=>{t.getGJShiftLoader(),t.getJournalShift(t.filter)}})));var Ye=t=>({"ng-invalid ng-dirty":t});function Xt(t,p){if(t&1){let e=E();l(0,"p-button",10),T("onClick",function(){h(e);let n=_(2);return S(n.onGenerateJournal())}),o()}}function Yt(t,p){if(t&1&&g(0,Xt,1,0,"p-button",9),t&2){let e=_();s("ngIf",e.store.hasCheckedRows())}}function Zt(t,p){t&1&&(l(0,"tr")(1,"th",12),x(2,"p-tableHeaderCheckbox"),o(),l(3,"th",13),m(4,"Number"),o(),l(5,"th",14),m(6,"Open"),o(),l(7,"th",14),m(8,"Close"),o(),l(9,"th",15),m(10,"Cashier"),o(),l(11,"th",16),m(12,"Sales + Tax"),o(),l(13,"th",17),m(14,"Invoices"),o(),l(15,"th",16),m(16,"Outlet"),o(),l(17,"th",17),m(18,"Register"),o(),l(19,"th",17),m(20,"Visitors"),o(),x(21,"th",18),o())}function ei(t,p){if(t&1&&(l(0,"tr")(1,"td"),x(2,"p-tableCheckbox",19),o(),l(3,"td")(4,"a",20),m(5),o()(),l(6,"td"),m(7),w(8,"date"),o(),l(9,"td"),m(10),w(11,"date"),o(),l(12,"td"),m(13),o(),l(14,"td"),m(15),w(16,"number"),o(),l(17,"td"),m(18),w(19,"number"),o(),l(20,"td"),m(21),o(),l(22,"td"),m(23),o(),l(24,"td"),m(25),w(26,"number"),o(),l(27,"td"),x(28,"p-button",21),o()()),t&2){let e=p.$implicit,r=_(2);a(2),s("value",e),a(2),s("href",r.authService.getTenantExternalURL()+"/menu/Shift/Main/Previous_Shift/Register_Shift_Detail?ID="+e.id,U),a(),J(" ",e.number," "),a(2),C(F(8,14,e.open,"dd MMM y hh:mm")),a(3),C(F(11,17,e.close,"dd MMM y hh:mm")),a(3),C(e.cashier),a(2),C(P(16,20,e.salesNTax)),a(3),C(P(19,22,e.totalInvoice)),a(3),C(e.outlet),a(2),C(e.register),a(2),C(P(26,24,e.visitors)),a(3),s("icon",e.integrated?"fa-solid fa-circle-check":"fa-solid fa-circle-xmark")("severity",e.integrated?"success":"danger")("text",!0)}}function ti(t,p){if(t&1&&m(0),t&2){let e=_(2);A(" Showing ",e.store.first()," to ",e.store.end()," of ",e.store.data().totalCount," entries ")}}function ii(t,p){t&1&&(l(0,"tr")(1,"td",22)(2,"span"),m(3,"No records found."),o()()())}function ni(t,p){if(t&1){let e=E();l(0,"p-panel")(1,"p-table",11),T("onPage",function(n){h(e);let i=_();return S(i.onPageChange(n))})("onRowSelect",function(n){h(e);let i=_();return S(i.onRowSelect(n))})("onRowUnselect",function(n){h(e);let i=_();return S(i.onRowUnselect(n))})("onHeaderCheckboxToggle",function(n){h(e);let i=_();return S(i.onHeaderCheckboxToggle(n))}),g(2,Zt,22,0,"ng-template",null,3,b)(4,ei,29,26,"ng-template",null,4,b)(6,ti,1,3,"ng-template",null,5,b)(8,ii,4,0,"ng-template",null,6,b),o()()}if(t&2){let e=_();a(),s("paginator",!0)("lazy",!0)("rows",e.store.filter().pageSize)("totalRecords",e.store.data().totalCount)("value",e.store.data().data)}}function oi(t,p){if(t&1&&(l(0,"span",32),m(1),w(2,"truncate"),o()),t&2){let e=p.$implicit;s("pTooltip",e.name),a(),J(" ",F(2,2,e.name,30)," ")}}function ri(t,p){if(t&1&&(l(0,"div")(1,"span",34),m(2),o()()),t&2){let e=p.$implicit;a(2),C(e)}}function li(t,p){if(t&1&&(l(0,"div"),g(1,ri,3,1,"div",33),o()),t&2){let e=_(2);a(),s("ngForOf",e.getErrors("from"))}}function ai(t,p){if(t&1&&(l(0,"div")(1,"span",34),m(2),o()()),t&2){let e=p.$implicit;a(2),C(e)}}function pi(t,p){if(t&1&&(l(0,"div"),g(1,ai,3,1,"div",33),o()),t&2){let e=_(2);a(),s("ngForOf",e.getErrors("to"))}}function mi(t,p){if(t&1&&(l(0,"div")(1,"span",34),m(2),o()()),t&2){let e=p.$implicit;a(2),C(e)}}function si(t,p){if(t&1&&(l(0,"div"),g(1,mi,3,1,"div",33),o()),t&2){let e=_(2);a(),s("ngForOf",e.getErrors("pageSize"))}}function ci(t,p){if(t&1&&(l(0,"form",23)(1,"div",24)(2,"label",25),m(3,"Outlet"),o(),l(4,"p-select",26),g(5,oi,3,5,"ng-template",null,7,b),o()(),l(7,"div",24)(8,"label",25),m(9,"From - To"),o(),l(10,"div",27),x(11,"p-datepicker",28),g(12,li,2,1,"div",29),x(13,"p-datepicker",30),g(14,pi,2,1,"div",29),o()(),l(15,"div",24)(16,"label",25),m(17,"Page Size"),o(),x(18,"input",31),g(19,si,2,1,"div",29),o()()),t&2){let e=_();s("formGroup",e.form),a(4),s("virtualScrollItemSize",50)("options",e.store.meta().options.outlets),a(7),s("iconDisplay","input")("showIcon",!0)("ngClass",V(13,Ye,e.isInvalid("from"))),a(),s("ngIf",e.isInvalid("from")),a(),s("iconDisplay","input")("showIcon",!0)("ngClass",V(15,Ye,e.isInvalid("to"))),a(),s("ngIf",e.isInvalid("to")),a(4),s("ngClass",V(17,Ye,e.isInvalid("pageSize"))),a(),s("ngIf",e.isInvalid("pageSize"))}}var _t=(()=>{class t extends Me{constructor(){super(),this.generateJournalService=v(D),this.store=v(Xe),this.authService=v(te),this.isDialogFilterVisible=k(!1),this.isInitDialogFilterVisible=k(!1),this.fb=v(me),this.dayjsService=v(N)}ngOnInit(){this.initForm()}initForm(){let{number:e,outletName:r,from:n,to:i,pageNumber:f,pageSize:u,export:ze,exportPageNumber:je,exportPageSize:Oe}=this.store.filter();this.form=this.fb.group({number:this.fb.control(e),outletName:this.fb.control(r),from:this.fb.control(this.dayjsService.from(n)?this.dayjsService.from(n).toDate():null),to:this.fb.control(this.dayjsService.from(i)?this.dayjsService.from(i).toDate():null),pageNumber:this.fb.control(f),pageSize:this.fb.control(u,[ne.required]),export:this.fb.control(ze),exportPageNumber:this.fb.control(je),exportPageSize:this.fb.control(Oe)})}onFilterOKEvent(){if(this.form.invalid){this.form.markAllAsTouched();return}let e=Object.entries(this.form.getRawValue()).reduce((r,[n,i])=>{switch(n){case"from":typeof i=="object"?r[n]=this.dayjsService.from(i)?this.dayjsService.format(i):null:r[n]=i!=null?String(i):null;break;case"to":typeof i=="object"?r[n]=this.dayjsService.from(i)?this.dayjsService.format(i):null:r[n]=i!=null?String(i):null;break;default:r[n]=i===null?"":i;break}return r},{});this.store.updateFilter(e),this.isDialogFilterVisible.set(!1)}onRowSelect(e){this.store.onRowSelect(e.data)}onRowUnselect(e){if(Array.isArray(e.data)){e.data.forEach(r=>{this.store.onRowUnselect(r)});return}else this.store.onRowUnselect(e.data)}onHeaderCheckboxToggle(e){this.store.onHeaderCheckboxToggle(e.checked)}onGenerateJournal(){this.generateJournalService.generateJournalSupplierBill(this.store.checkedShift()).pipe(G(()=>{this.store.getJournalShift(this.store.filter)})).subscribe()}onSearch(e){this.store.updateFilter(d(c({},this.store.filter()),{number:e}))}onPageChange(e){let r=e.first/e.rows;this.store.updateFilter(d(c({},this.store.filter()),{pageNumber:r+1}))}static{this.\u0275fac=function(r){return new(r||t)}}static{this.\u0275cmp=H({type:t,selectors:[["app-journal-shift"]],features:[q([Xe]),L],decls:7,vars:5,consts:[["actionButton",""],["content",""],["filters",""],["header",""],["body",""],["paginatorleft",""],["emptymessage",""],["item",""],["pageTitle","Shift Journal",3,"isDialogFilterVisibleChange","isInitDialogFilterVisibleChange","filterConfirmed","search","isSearchableInput","isFilterable","isDialogFilterVisible","isInitDialogFilterVisible","scrollable"],["label","Generate Journal",3,"onClick",4,"ngIf"],["label","Generate Journal",3,"onClick"],["dataKey","id",3,"onPage","onRowSelect","onRowUnselect","onHeaderCheckboxToggle","paginator","lazy","rows","totalRecords","value"],[2,"width","1rem"],[2,"width","12rem"],[2,"width","11rem"],[2,"width","14rem"],[2,"width","10rem"],[2,"width","9rem"],[2,"width","4rem"],[3,"value"],["target","_blank",1,"link","link-primary",3,"href"],[3,"icon","severity","text"],["colspan","11"],[1,"d-flex","flex-column","row-gap-3",3,"formGroup"],[1,"d-flex","flex-column"],["for","outlet"],["virtualScroll","","showClear","","filter","","filterBy","name","formControlName","outletName","appendTo","body","optionLabel","name","optionValue","name","placeholder","Select an Outlet",3,"virtualScrollItemSize","options"],[1,"d-flex","flex-column","gap-2"],["showClear","","formControlName","from","styleClass","w-100","appendTo","body","inputId","icondisplay",3,"iconDisplay","showIcon","ngClass"],[4,"ngIf"],["showClear","","formControlName","to","styleClass","w-100","appendTo","body","inputId","icondisplay",3,"iconDisplay","showIcon","ngClass"],["type","text","pInputText","","formControlName","pageSize","appMaskNumber","",3,"ngClass"],[3,"pTooltip"],[4,"ngFor","ngForOf"],[1,"text-danger"]],template:function(r,n){if(r&1){let i=E();l(0,"app-main-panel",8),K("isDialogFilterVisibleChange",function(u){return h(i),M(n.isDialogFilterVisible,u)||(n.isDialogFilterVisible=u),S(u)})("isInitDialogFilterVisibleChange",function(u){return h(i),M(n.isInitDialogFilterVisible,u)||(n.isInitDialogFilterVisible=u),S(u)}),T("filterConfirmed",function(){return h(i),S(n.onFilterOKEvent())})("search",function(u){return h(i),S(n.onSearch(u))}),g(1,Yt,1,1,"ng-template",null,0,b)(3,ni,10,5,"ng-template",null,1,b)(5,ci,20,19,"ng-template",null,2,b),o()}r&2&&(s("isSearchableInput",!0)("isFilterable",!0),W("isDialogFilterVisible",n.isDialogFilterVisible)("isInitDialogFilterVisible",n.isInitDialogFilterVisible),s("scrollable",!0))},dependencies:[Ie,Ne,De,ke,Je,ee,$,Q,X,Z,Y,Be,ge,_e,fe,ue,se,le,ie,oe,re,ae,pe,Fe,Ve,Te,Ee,we,ye,ve,de,ce,Pe],styles:["[_nghost-%COMP%]{display:block}"],changeDetection:0})}}return t})();var fo=[{path:"invoice",component:ut},{path:"supplier-bill",component:ft},{path:"shift",component:_t},{path:"join-invoice",loadComponent:()=>import("./chunk-CRRQQY3W.js").then(t=>t.ARJournalComponent)},{path:"join-bill",loadComponent:()=>import("./chunk-OBX4APL6.js").then(t=>t.ApJournalComponent)},{path:"adjustment",loadComponent:()=>import("./chunk-OKX4P7HR.js").then(t=>t.AdjustmentJournalComponent)}];export{fo as generateJournalRoutes};
|
|
1
|
+
import{a as D}from"./chunk-ETHACYOI.js";import{a as it}from"./chunk-G4XX7EU2.js";import{a as Pe}from"./chunk-FMHGC2MA.js";import{a as Ue,b as He}from"./chunk-BLR3HBYP.js";import{a as te}from"./chunk-Y3URGAXL.js";import{b as N}from"./chunk-DFGIXWZK.js";import{a as Me}from"./chunk-XKI7WLHE.js";import{a as Ge,b as Be}from"./chunk-7DYACF4D.js";import"./chunk-NZN6QJR3.js";import"./chunk-IGWIRCAS.js";import{a as z,b as j}from"./chunk-3A4BFUGD.js";import{d as De,i as ke,j as Je,k as Ne}from"./chunk-EL5BUFMO.js";import{a as Ee,b as Te}from"./chunk-EQ4PLHI4.js";import"./chunk-H7Q35Y7G.js";import"./chunk-R7N6BWL5.js";import{a as Re}from"./chunk-QF4D5YPK.js";import"./chunk-2AAVNIG7.js";import{a as Ve,b as Fe}from"./chunk-LFZCMZAP.js";import"./chunk-6A2KUPOG.js";import"./chunk-36OX4S7M.js";import"./chunk-Q5CVMJZC.js";import"./chunk-3GGXPPQT.js";import"./chunk-MFK5RQPJ.js";import"./chunk-6GN3MGBY.js";import"./chunk-Q24GCSGD.js";import{g as we,h as Ie}from"./chunk-WKE2HPSD.js";import{b as ve,c as ye}from"./chunk-VGNJD35F.js";import{a as _e,b as ge}from"./chunk-2XUSZCQL.js";import{a as y,b as he,c as Se,d as xe,e as Ce,f as be,g as tt}from"./chunk-YV2QJ63P.js";import"./chunk-ARH3WEEF.js";import{n as ce,o as de,w as ue,x as fe}from"./chunk-H6HNANYB.js";import"./chunk-2D2YD753.js";import{b as ie,c as ne,e as oe,f as re,k as le,l as ae,o as pe,u as me,x as se}from"./chunk-OIBDX2CA.js";import"./chunk-AOOG6YOT.js";import"./chunk-OR5FLZPY.js";import"./chunk-2MKKFLNJ.js";import{h as $,j as Q,k as X,n as et,p as Y,q as Z,s as ee}from"./chunk-VZ5CMS5O.js";import"./chunk-F2X3VGZZ.js";import{$b as E,Bb as L,Cc as q,Db as g,Ec as V,Ha as k,Lb as s,Nc as w,Oc as P,Pc as F,Rc as b,Vb as l,Wb as o,Xb as x,Y as B,_ as G,bd as I,c as R,db as U,ec as T,fc as _,hb as a,ia as v,qa as h,ra as S,rc as m,s as O,sc as C,tc as J,ua as Ze,vc as A,wc as W,xb as H,xc as M,yc as K}from"./chunk-NMCKMUY4.js";import{a as c,b as d}from"./chunk-YQFG5XE2.js";var gt={data:{data:[],totalCount:0},meta:{options:{outlets:[],paymentStates:[],deliveryStates:[]},filter:{number:null,outletName:null,paymentState:0,deliveryState:0,from:null,to:null,customerID:null,pageNumber:1,pageSize:20,export:!1,exportPageNumber:1,exportPageSize:1e4}},filter:{number:null,outletName:null,paymentState:0,deliveryState:0,from:null,to:null,customerID:null,pageNumber:1,pageSize:20,export:!1,exportPageNumber:1,exportPageSize:1e4}},Ke=he(be(gt),Se(t=>({first:I(()=>(t.filter().pageNumber-1)*t.filter().pageSize+1),end:I(()=>Math.min(t.filter().pageNumber*t.filter().pageSize,t.data().totalCount)),hasCheckedRows:I(()=>t.data().data.some(p=>p.checked)),checkedInvoice:I(()=>t.data().data.filter(p=>p.checked).map(p=>p.id))})),Ce(t=>{let p=v(D),e=v(N);return{updateFilter(n){y(t,i=>d(c({},i),{filter:c(c({},i.filter),n),skipRequestFirst:!1}))},onRowSelect(n){y(t,i=>{let f=i.data.data.map(u=>u.id===n.id?d(c({},u),{checked:!0}):u);return d(c({},i),{data:d(c({},i.data),{data:f})})})},onRowUnselect(n){y(t,i=>{let f=i.data.data.map(u=>u.id===n.id?d(c({},u),{checked:!1}):u);return d(c({},i),{data:d(c({},i.data),{data:f})})})},onHeaderCheckboxToggle(n){y(t,i=>{let f=i.data.data.map(u=>d(c({},u),{checked:n}));return d(c({},i),{data:d(c({},i.data),{data:f})})})},getCustomerInvoice:z(R(O(n=>Object.entries(n).reduce((i,[f,u])=>(u!=null&&(i[f]=u),i),{})),B(n=>p.getJournalInvoice(n).pipe(O(i=>d(c({},i),{data:i.data.map(f=>d(c({},f),{due:e.from(f.due)?e.from(f.due).format():null,checked:!1}))})),Re("getCustomerInvoice"),j({next:i=>{y(t,f=>d(c({},f),{data:d(c({},f.data),{data:i.data,totalCount:i.totalCount})}))},error:i=>{console.error("Error fetching customer invoice:",i)}}))))),getCustomerInvoiceLoader:z(R(B(()=>p.getJournalInvoiceLoader().pipe(j({next:n=>{y(t,i=>d(c({},i),{meta:n}))},error:n=>{console.error("Error fetching customer invoice loader:",n)}})))))}}),xe(t=>({onInit:()=>{t.getCustomerInvoiceLoader(),t.getCustomerInvoice(t.filter)}})));var qe=t=>({"ng-invalid ng-dirty":t});function xt(t,p){if(t&1){let e=E();l(0,"p-button",10),T("onClick",function(){h(e);let n=_(2);return S(n.onGenerateJournal())}),o()}}function Ct(t,p){if(t&1&&g(0,xt,1,0,"p-button",9),t&2){let e=_();s("ngIf",e.store.hasCheckedRows())}}function bt(t,p){t&1&&(l(0,"tr")(1,"th",12),x(2,"p-tableHeaderCheckbox"),o(),l(3,"th",13),m(4,"Outlet"),o(),l(5,"th",14),m(6,"Number"),o(),l(7,"th",15),m(8,"Customer"),o(),l(9,"th",16),m(10,"Date"),o(),l(11,"th",16),m(12,"Due"),o(),l(13,"th",13),m(14,"Amount"),o(),l(15,"th",17),m(16,"Payment"),o(),l(17,"th",17),m(18,"Delivery"),o(),x(19,"th",18),o())}function vt(t,p){if(t&1&&(l(0,"tr")(1,"td"),x(2,"p-tableCheckbox",19),o(),l(3,"td"),m(4),o(),l(5,"td")(6,"a",20),m(7),o()(),l(8,"td")(9,"a",20),m(10),o()(),l(11,"td"),m(12),w(13,"date"),o(),l(14,"td"),m(15),w(16,"date"),o(),l(17,"td"),m(18),w(19,"number"),o(),l(20,"td"),x(21,"p-chip",21),o(),l(22,"td"),x(23,"p-chip",21),o(),l(24,"td"),x(25,"p-button",22),o()()),t&2){let e=p.$implicit,r=_(2);a(2),s("value",e),a(2),C(e.outlet),a(2),s("href",r.authService.getTenantExternalURL()+"/menu/Orders/Orders/Customer_Invoice/Info?ID="+e.id,U),a(),J(" ",e.number," "),a(2),s("href",r.authService.getTenantExternalURL()+"/menu/Contacts/Contact/Customers/Info?ID="+e.customerID,U),a(),J(" ",e.customer," "),a(2),C(F(13,14,e.date,"d MMM y hh:mm")),a(3),C(e.due?F(16,17,e.due,"d MMM y hh:mm"):"-"),a(3),C(P(19,20,e.amount)),a(3),s("label",e.payment),a(2),s("label",e.delivery),a(2),s("icon",e.integrated?"fa-solid fa-circle-check":"fa-solid fa-circle-xmark")("severity",e.integrated?"success":"danger")("text",!0)}}function yt(t,p){if(t&1&&m(0),t&2){let e=_(2);A(" Showing ",e.store.first()," to ",e.store.end()," of ",e.store.data().totalCount," entries ")}}function wt(t,p){t&1&&(l(0,"tr")(1,"td",23)(2,"span"),m(3,"No records found."),o()()())}function It(t,p){if(t&1){let e=E();l(0,"p-panel")(1,"p-table",11),T("onPage",function(n){h(e);let i=_();return S(i.onPageChange(n))})("onRowSelect",function(n){h(e);let i=_();return S(i.onRowSelect(n))})("onRowUnselect",function(n){h(e);let i=_();return S(i.onRowUnselect(n))})("onHeaderCheckboxToggle",function(n){h(e);let i=_();return S(i.onHeaderCheckboxToggle(n))}),g(2,bt,20,0,"ng-template",null,3,b)(4,vt,26,22,"ng-template",null,4,b)(6,yt,1,3,"ng-template",null,5,b)(8,wt,4,0,"ng-template",null,6,b),o()()}if(t&2){let e=_();a(),s("lazy",!0)("paginator",!0)("rows",e.store.filter().pageSize)("totalRecords",e.store.data().totalCount)("value",e.store.data().data)}}function Et(t,p){if(t&1&&(l(0,"span",36),m(1),w(2,"truncate"),o()),t&2){let e=p.$implicit;s("pTooltip",e.name),a(),J(" ",F(2,2,e.name,30)," ")}}function Tt(t,p){if(t&1&&(l(0,"div")(1,"span",38),m(2),o()()),t&2){let e=p.$implicit;a(2),C(e)}}function Vt(t,p){if(t&1&&(l(0,"div"),g(1,Tt,3,1,"div",37),o()),t&2){let e=_(2);a(),s("ngForOf",e.getErrors("from"))}}function Ft(t,p){if(t&1&&(l(0,"div")(1,"span",38),m(2),o()()),t&2){let e=p.$implicit;a(2),C(e)}}function Dt(t,p){if(t&1&&(l(0,"div"),g(1,Ft,3,1,"div",37),o()),t&2){let e=_(2);a(),s("ngForOf",e.getErrors("to"))}}function kt(t,p){if(t&1&&(l(0,"div")(1,"span",38),m(2),o()()),t&2){let e=p.$implicit;a(2),C(e)}}function Jt(t,p){if(t&1&&(l(0,"div"),g(1,kt,3,1,"div",37),o()),t&2){let e=_(2);a(),s("ngForOf",e.getErrors("pageSize"))}}function Nt(t,p){if(t&1){let e=E();l(0,"form",24)(1,"div",25)(2,"label",26),m(3,"Outlet"),o(),l(4,"p-select",27),g(5,Et,3,5,"ng-template",null,7,b),o()(),l(7,"div",25)(8,"label",26),m(9,"Payment"),o(),x(10,"p-select",28),o(),l(11,"div",25)(12,"label",26),m(13,"Delivery"),o(),x(14,"p-select",29),o(),l(15,"div",25)(16,"label",26),m(17,"From - To"),o(),l(18,"div",30),x(19,"p-datepicker",31),g(20,Vt,2,1,"div",32),x(21,"p-datepicker",33),g(22,Dt,2,1,"div",32),o()(),l(23,"div",25)(24,"label",26),m(25,"Customer"),o(),l(26,"p-autocomplete",34),T("completeMethod",function(n){h(e);let i=_();return S(i.onSearchContact(n))}),o()(),l(27,"div",25)(28,"label",26),m(29,"Page Size"),o(),x(30,"input",35),g(31,Jt,2,1,"div",32),o()()}if(t&2){let e=_();s("formGroup",e.form),a(4),s("virtualScrollItemSize",50)("options",e.store.meta().options.outlets),a(6),s("options",e.store.meta().options.paymentStates),a(4),s("options",e.store.meta().options.deliveryStates),a(5),s("iconDisplay","input")("showIcon",!0)("ngClass",V(16,qe,e.isInvalid("from"))),a(),s("ngIf",e.isInvalid("from")),a(),s("iconDisplay","input")("showIcon",!0)("ngClass",V(18,qe,e.isInvalid("to"))),a(),s("ngIf",e.isInvalid("to")),a(4),s("suggestions",e.customerSuggestions()),a(4),s("ngClass",V(20,qe,e.isInvalid("pageSize"))),a(),s("ngIf",e.isInvalid("pageSize"))}}var ut=(()=>{class t extends Me{constructor(){super(...arguments),this.store=v(Ke),this.dayjsService=v(N),this.generateJournalService=v(D),this.authService=v(te),this.isDialogFilterVisible=k(!1),this.isInitDialogFilterVisible=k(!1),this.customerSuggestions=k([]),this.fb=v(me)}ngOnInit(){console.log(this.dayjsService.from('0001-01-01T00:00:00"')&&!0),this.generateFilterForm()}generateFilterForm(){let{number:e,outletName:r,paymentState:n,deliveryState:i,from:f,to:u,customerID:ze,pageNumber:je,pageSize:Oe,export:Le,exportPageNumber:Ae,exportPageSize:We}=this.store.filter();this.form=this.fb.group({number:this.fb.control(e),outletName:this.fb.control(r),paymentState:this.fb.control(n),deliveryState:this.fb.control(i),from:this.fb.control(this.dayjsService.from(f)?this.dayjsService.from(f).toDate():null),to:this.fb.control(this.dayjsService.from(u)?this.dayjsService.from(u).toDate():null),customerID:this.fb.control(ze),pageNumber:this.fb.control(je),pageSize:this.fb.control(Oe,[ne.required]),export:this.fb.control(Le),exportPageNumber:this.fb.control(Ae),exportPageSize:this.fb.control(We)})}onSearchContact(e){let{query:r}=e;this.generateJournalService.getCustomerSuggestions(r).pipe(Re("Customer Suggestions"),G(n=>{this.customerSuggestions.set(n)})).subscribe()}onSearch(e){this.store.updateFilter(d(c({},this.store.filter()),{number:e}))}onRowSelect(e){this.store.onRowSelect(e.data)}onRowUnselect(e){if(Array.isArray(e.data)){e.data.forEach(r=>{this.store.onRowUnselect(r)});return}else this.store.onRowUnselect(e.data)}onHeaderCheckboxToggle(e){this.store.onHeaderCheckboxToggle(e.checked)}onPageChange(e){let r=e.first/e.rows;this.store.updateFilter(d(c({},this.store.filter()),{pageNumber:r+1}))}onGenerateJournal(){this.generateJournalService.generateJournalInvoice(this.store.checkedInvoice()).pipe(G(()=>{this.store.getCustomerInvoice(this.store.filter)})).subscribe()}onFilterOKEvent(){if(this.form.invalid){this.form.markAllAsTouched();return}let e=Object.entries(this.form.getRawValue()).reduce((r,[n,i])=>{switch(n){case"customerID":i||(r[n]=it);break;case"from":typeof i=="object"?r[n]=this.dayjsService.from(i)?this.dayjsService.format(i):null:r[n]=i!=null?String(i):null;break;case"to":typeof i=="object"?r[n]=this.dayjsService.from(i)?this.dayjsService.format(i):null:r[n]=i!=null?String(i):null;break;default:r[n]=i===null?"":i;break}return r},{});console.log("Filter Body:",e),this.store.updateFilter(e),this.isDialogFilterVisible.set(!1)}static{this.\u0275fac=(()=>{let e;return function(n){return(e||(e=Ze(t)))(n||t)}})()}static{this.\u0275cmp=H({type:t,selectors:[["app-customer-invoice"]],features:[q([Ke]),L],decls:7,vars:5,consts:[["actionButton",""],["content",""],["filters",""],["header",""],["body",""],["paginatorleft",""],["emptymessage",""],["item",""],["pageTitle","Customer Invoice",3,"isDialogFilterVisibleChange","isInitDialogFilterVisibleChange","filterConfirmed","search","isSearchableInput","isFilterable","isDialogFilterVisible","isInitDialogFilterVisible","scrollable"],["label","Generate Journal",3,"onClick",4,"ngIf"],["label","Generate Journal",3,"onClick"],["dataKey","id",3,"onPage","onRowSelect","onRowUnselect","onHeaderCheckboxToggle","lazy","paginator","rows","totalRecords","value"],[2,"width","1rem"],[2,"width","10rem"],[2,"width","12rem"],[2,"width","14rem"],[2,"width","11rem"],[2,"width","9rem"],[2,"width","4rem"],[3,"value"],["target","_blank",1,"link","link-primary",3,"href"],[3,"label"],[3,"icon","severity","text"],["colspan","10"],[1,"d-flex","flex-column","row-gap-3",3,"formGroup"],[1,"d-flex","flex-column"],["for","outlet"],["virtualScroll","","showClear","","filter","","filterBy","name","formControlName","outletName","appendTo","body","optionLabel","name","optionValue","name","placeholder","Select an Outlet",3,"virtualScrollItemSize","options"],["showClear","","formControlName","paymentState","appendTo","body","optionLabel","value","optionValue","key","placeholder","Select a Payment",3,"options"],["showClear","","formControlName","deliveryState","appendTo","body","optionLabel","value","optionValue","key","placeholder","Select a Delivery",3,"options"],[1,"d-flex","flex-column","gap-2"],["showClear","","formControlName","from","styleClass","w-100","appendTo","body","inputId","icondisplay",3,"iconDisplay","showIcon","ngClass"],[4,"ngIf"],["showClear","","formControlName","to","styleClass","w-100","appendTo","body","inputId","icondisplay",3,"iconDisplay","showIcon","ngClass"],["showClear","","formControlName","customerID","appendTo","body","styleClass","w-100","optionLabel","Value","optionValue","Key","inputStyleClass","w-100",3,"completeMethod","suggestions"],["type","text","pInputText","","formControlName","pageSize","appMaskNumber","",3,"ngClass"],[3,"pTooltip"],[4,"ngFor","ngForOf"],[1,"text-danger"]],template:function(r,n){if(r&1){let i=E();l(0,"app-main-panel",8),K("isDialogFilterVisibleChange",function(u){return h(i),M(n.isDialogFilterVisible,u)||(n.isDialogFilterVisible=u),S(u)})("isInitDialogFilterVisibleChange",function(u){return h(i),M(n.isInitDialogFilterVisible,u)||(n.isInitDialogFilterVisible=u),S(u)}),T("filterConfirmed",function(){return h(i),S(n.onFilterOKEvent())})("search",function(u){return h(i),S(n.onSearch(u))}),g(1,Ct,1,1,"ng-template",null,0,b)(3,It,10,5,"ng-template",null,1,b)(5,Nt,32,22,"ng-template",null,2,b),o()}r&2&&(s("isSearchableInput",!0)("isFilterable",!0),W("isDialogFilterVisible",n.isDialogFilterVisible)("isInitDialogFilterVisible",n.isInitDialogFilterVisible),s("scrollable",!0))},dependencies:[Ie,Ne,De,ke,Je,ee,$,Q,X,Z,Y,Be,Ge,ge,_e,fe,ue,Fe,Ve,Te,Ee,de,ce,He,Ue,se,le,ie,oe,re,ae,pe,ye,ve,we,Pe],encapsulation:2,changeDetection:0})}}return t})();var Rt={data:{data:[],totalCount:0},meta:{options:{Outlets:[],PaymentStates:[],DeliveryStates:[]},filter:{number:null,outletName:null,paymentState:0,deliveryState:0,from:null,to:null,supplierID:null,pageNumber:1,pageSize:20,export:!1,exportPageNumber:1,exportPageSize:1e4}},filter:{number:null,outletName:null,paymentState:0,deliveryState:0,from:null,to:null,supplierID:null,pageNumber:1,pageSize:20,export:!1,exportPageNumber:1,exportPageSize:1e4},skipRequestFirst:!0},$e=he(tt("JournalSupplierBillStore"),be(Rt),Se(t=>({first:I(()=>(t.filter().pageNumber-1)*t.filter().pageSize+1),end:I(()=>Math.min(t.filter().pageNumber*t.filter().pageSize,t.data().totalCount)),hasCheckedRows:I(()=>t.data().data.some(p=>p.checked)),checkedSupplierBill:I(()=>t.data().data.filter(p=>p.checked).map(p=>p.id))})),Ce(t=>{let p=v(D),e=v(N);return{updateFilter(r){y(t,n=>d(c({},n),{filter:c(c({},n.filter),r),skipRequestFirst:!1}))},onRowSelect(r){y(t,n=>{let i=n.data.data.map(f=>f.id===r.id?d(c({},f),{checked:!0}):f);return d(c({},n),{data:d(c({},n.data),{data:i})})})},onRowUnselect(r){y(t,n=>{let i=n.data.data.map(f=>f.id===r.id?d(c({},f),{checked:!1}):f);return d(c({},n),{data:d(c({},n.data),{data:i})})})},onHeaderCheckboxToggle(r){y(t,n=>{let i=n.data.data.map(f=>d(c({},f),{checked:r}));return d(c({},n),{data:d(c({},n.data),{data:i})})})},getGJSupplierBillLoader:z(R(B(()=>p.getGJSupplierBillLoader().pipe(j({next:r=>{console.log("GJSupplierBillLoader response:",r),y(t,n=>d(c({},n),{meta:r}))},error:r=>{console.error("Error fetching GJSupplierBillLoader:",r)}}))))),getJournalSupplierBill:z(R(O(r=>Object.entries(r).reduce((n,[i,f])=>(f!=null&&(n[i]=f),n),{})),B(r=>p.getJournalSupplierBill(r).pipe(O(n=>d(c({},n),{data:n.data.map(i=>d(c({},i),{due:e.from(i.due)?e.from(i.due).format():null,checked:!1}))})),j({next:n=>{y(t,i=>d(c({},i),{data:n}))},error:n=>{console.error("Error fetching journal supplier bill:",n)}})))))}}),xe(t=>({onInit:()=>{t.getGJSupplierBillLoader(),t.getJournalSupplierBill(t.filter)}})));var Qe=t=>({"ng-invalid ng-dirty":t});function Bt(t,p){if(t&1){let e=E();l(0,"p-button",10),T("onClick",function(){h(e);let n=_(2);return S(n.onGenerateJournal())}),o()}}function Mt(t,p){if(t&1&&g(0,Bt,1,0,"p-button",9),t&2){let e=_();s("ngIf",e.store.hasCheckedRows())}}function Pt(t,p){t&1&&(l(0,"tr")(1,"th",12),x(2,"p-tableHeaderCheckbox"),o(),l(3,"th",13),m(4,"Outlet"),o(),l(5,"th",14),m(6,"Number"),o(),l(7,"th",15),m(8,"Supplier"),o(),l(9,"th",16),m(10,"Date"),o(),l(11,"th",16),m(12,"Due"),o(),l(13,"th",13),m(14,"Amount"),o(),l(15,"th",17),m(16,"Payment"),o(),l(17,"th",17),m(18,"Delivery"),o(),x(19,"th",18),o())}function zt(t,p){if(t&1&&(l(0,"tr")(1,"td"),x(2,"p-tableCheckbox",19),o(),l(3,"td"),m(4),o(),l(5,"td")(6,"a",20),m(7),o()(),l(8,"td"),m(9),o(),l(10,"td"),m(11),w(12,"date"),o(),l(13,"td"),m(14),w(15,"date"),o(),l(16,"td"),m(17),w(18,"number"),o(),l(19,"td"),x(20,"p-chip",21),o(),l(21,"td"),x(22,"p-chip",21),o(),l(23,"td"),x(24,"p-button",22),o()()),t&2){let e=p.$implicit,r=_(2);a(2),s("value",e),a(2),C(e.outlet),a(2),s("href",r.authService.getTenantExternalURL()+"/menu/Orders/Orders/Supplier_Bill/Info?ID="+e.id,U),a(),J(" ",e.number," "),a(2),C(e.customer),a(2),C(F(12,13,e.date,"d MMM y hh:mm")),a(3),C(e.due?F(15,16,e.due,"d MMM y hh:mm"):"-"),a(3),C(P(18,19,e.amount)),a(3),s("label",e.payment),a(2),s("label",e.delivery),a(2),s("icon",e.integrated?"fa-solid fa-circle-check":"fa-solid fa-circle-xmark")("severity",e.integrated?"success":"danger")("text",!0)}}function jt(t,p){if(t&1&&m(0),t&2){let e=_(2);A(" Showing ",e.store.first()," to ",e.store.end()," of ",e.store.data().totalCount," entries ")}}function Ot(t,p){t&1&&(l(0,"tr")(1,"td",23)(2,"span"),m(3,"No records found."),o()()())}function Gt(t,p){if(t&1){let e=E();l(0,"p-panel")(1,"p-table",11),T("onPage",function(n){h(e);let i=_();return S(i.onPageChange(n))})("onRowSelect",function(n){h(e);let i=_();return S(i.onRowSelect(n))})("onRowUnselect",function(n){h(e);let i=_();return S(i.onRowUnselect(n))})("onHeaderCheckboxToggle",function(n){h(e);let i=_();return S(i.onHeaderCheckboxToggle(n))}),g(2,Pt,20,0,"ng-template",null,3,b)(4,zt,25,21,"ng-template",null,4,b)(6,jt,1,3,"ng-template",null,5,b)(8,Ot,4,0,"ng-template",null,6,b),o()()}if(t&2){let e=_();a(),s("value",e.store.data().data)("paginator",!0)("rows",e.store.filter().pageSize)("totalRecords",e.store.data().totalCount)("lazy",!0)}}function Ut(t,p){if(t&1&&(l(0,"span",36),m(1),w(2,"truncate"),o()),t&2){let e=p.$implicit;s("pTooltip",e.name),a(),J(" ",F(2,2,e.name,30)," ")}}function Ht(t,p){if(t&1&&(l(0,"div")(1,"span",38),m(2),o()()),t&2){let e=p.$implicit;a(2),C(e)}}function Lt(t,p){if(t&1&&(l(0,"div"),g(1,Ht,3,1,"div",37),o()),t&2){let e=_(2);a(),s("ngForOf",e.getErrors("from"))}}function At(t,p){if(t&1&&(l(0,"div")(1,"span",38),m(2),o()()),t&2){let e=p.$implicit;a(2),C(e)}}function Wt(t,p){if(t&1&&(l(0,"div"),g(1,At,3,1,"div",37),o()),t&2){let e=_(2);a(),s("ngForOf",e.getErrors("to"))}}function Kt(t,p){if(t&1&&(l(0,"div")(1,"span",38),m(2),o()()),t&2){let e=p.$implicit;a(2),C(e)}}function qt(t,p){if(t&1&&(l(0,"div"),g(1,Kt,3,1,"div",37),o()),t&2){let e=_(2);a(),s("ngForOf",e.getErrors("pageSize"))}}function $t(t,p){if(t&1){let e=E();l(0,"form",24)(1,"div",25)(2,"label",26),m(3,"Outlet"),o(),l(4,"p-select",27),g(5,Ut,3,5,"ng-template",null,7,b),o()(),l(7,"div",25)(8,"label",26),m(9,"Payment"),o(),x(10,"p-select",28),o(),l(11,"div",25)(12,"label",26),m(13,"Delivery"),o(),x(14,"p-select",29),o(),l(15,"div",25)(16,"label",26),m(17,"From - To"),o(),l(18,"div",30),x(19,"p-datepicker",31),g(20,Lt,2,1,"div",32),x(21,"p-datepicker",33),g(22,Wt,2,1,"div",32),o()(),l(23,"div",25)(24,"label",26),m(25,"Supplier"),o(),l(26,"p-autocomplete",34),w(27,"async"),T("completeMethod",function(n){h(e);let i=_();return S(i.onSearchSupplier(n))}),o()(),l(28,"div",25)(29,"label",26),m(30,"Page Size"),o(),x(31,"input",35),g(32,qt,2,1,"div",32),o()()}if(t&2){let e=_();s("formGroup",e.form),a(4),s("virtualScrollItemSize",50)("options",e.store.meta().options.Outlets),a(6),s("options",e.store.meta().options.PaymentStates),a(4),s("options",e.store.meta().options.DeliveryStates),a(5),s("iconDisplay","input")("showIcon",!0)("ngClass",V(18,Qe,e.isInvalid("from"))),a(),s("ngIf",e.isInvalid("from")),a(),s("iconDisplay","input")("showIcon",!0)("ngClass",V(20,Qe,e.isInvalid("to"))),a(),s("ngIf",e.isInvalid("to")),a(4),s("suggestions",P(27,16,e.supplierSuggestions$)),a(5),s("ngClass",V(22,Qe,e.isInvalid("pageSize"))),a(),s("ngIf",e.isInvalid("pageSize"))}}var ft=(()=>{class t extends Me{constructor(){super(),this.generateJournalService=v(D),this.store=v($e),this.authService=v(te),this.isDialogFilterVisible=k(!1),this.isInitDialogFilterVisible=k(!1),this.fb=v(me),this.dayjsService=v(N)}ngOnInit(){this.initform()}onFilterOKEvent(){if(this.form.invalid){this.form.markAllAsTouched();return}let e=Object.entries(this.form.getRawValue()).reduce((r,[n,i])=>(i!=null&&(n==="from"||n==="to"?(typeof i=="string"||typeof i=="number"||i instanceof Date)&&(r[n]=this.dayjsService.from(i)?this.dayjsService.format(i):null):r[n]=i),r),{});this.store.updateFilter(e),this.isDialogFilterVisible.update(r=>!r)}onRowSelect(e){this.store.onRowSelect(e.data)}onSearchSupplier(e){this.supplierSuggestions$=this.generateJournalService.getSupplierSuggestions(e.query).pipe(Re("Supplier Suggestions"))}initform(){let{outletName:e,number:r,from:n,to:i,paymentState:f,deliveryState:u,supplierID:ze,pageNumber:je,pageSize:Oe,export:Le,exportPageNumber:Ae,exportPageSize:We}=this.store.filter();this.form=this.fb.group({outletName:this.fb.control(e),number:this.fb.control(r),from:this.fb.control(this.dayjsService.from(n)?this.dayjsService.from(n).toDate():null),to:this.fb.control(this.dayjsService.from(i)?this.dayjsService.from(i).toDate():null),paymentState:this.fb.control(f),deliveryState:this.fb.control(u),supplierID:this.fb.control(ze),pageNumber:this.fb.control(je),pageSize:this.fb.control(Oe,[ne.required]),export:this.fb.control(Le),exportPageNumber:this.fb.control(Ae),exportPageSize:this.fb.control(We)})}onRowUnselect(e){if(Array.isArray(e.data)){e.data.forEach(r=>{this.store.onRowUnselect(r)});return}else this.store.onRowUnselect(e.data)}onHeaderCheckboxToggle(e){this.store.onHeaderCheckboxToggle(e.checked)}onGenerateJournal(){this.generateJournalService.generateJournalSupplierBill(this.store.checkedSupplierBill()).pipe(G(()=>{this.store.getJournalSupplierBill(this.store.filter)})).subscribe()}onSearch(e){this.store.updateFilter(d(c({},this.store.filter()),{number:e}))}onPageChange(e){this.store.updateFilter(d(c({},this.store.filter()),{pageNumber:e.first/e.rows+1}))}static{this.\u0275fac=function(r){return new(r||t)}}static{this.\u0275cmp=H({type:t,selectors:[["app-journal-supplier-bill"]],features:[q([$e]),L],decls:7,vars:5,consts:[["actionButton",""],["content",""],["filters",""],["header",""],["body",""],["paginatorleft",""],["emptymessage",""],["item",""],["pageTitle","Supplier Bill",3,"isDialogFilterVisibleChange","isInitDialogFilterVisibleChange","filterConfirmed","search","isSearchableInput","isFilterable","isDialogFilterVisible","isInitDialogFilterVisible","scrollable"],["label","Generate Journal",3,"onClick",4,"ngIf"],["label","Generate Journal",3,"onClick"],["dataKey","id",3,"onPage","onRowSelect","onRowUnselect","onHeaderCheckboxToggle","value","paginator","rows","totalRecords","lazy"],[2,"width","1rem"],[2,"width","10rem"],[2,"width","12rem"],[2,"width","14rem"],[2,"width","11rem"],[2,"width","9rem"],[2,"width","4rem"],[3,"value"],["target","_blank",1,"link","link-primary",3,"href"],[3,"label"],[3,"icon","severity","text"],["colspan","10"],[1,"d-flex","flex-column","row-gap-3",3,"formGroup"],[1,"d-flex","flex-column"],["for","outlet"],["virtualScroll","","showClear","","filter","","filterBy","name","formControlName","outletName","appendTo","body","optionLabel","name","optionValue","name","placeholder","Select an Outlet",3,"virtualScrollItemSize","options"],["showClear","","formControlName","paymentState","appendTo","body","optionLabel","value","optionValue","key","placeholder","Select a Payment",3,"options"],["showClear","","formControlName","deliveryState","appendTo","body","optionLabel","value","optionValue","key","placeholder","Select a Delivery",3,"options"],[1,"d-flex","flex-column","gap-2"],["showClear","","formControlName","from","styleClass","w-100","appendTo","body","inputId","icondisplay",3,"iconDisplay","showIcon","ngClass"],[4,"ngIf"],["showClear","","formControlName","to","styleClass","w-100","appendTo","body","inputId","icondisplay",3,"iconDisplay","showIcon","ngClass"],["showClear","","formControlName","supplierID","appendTo","body","styleClass","w-100","optionLabel","Value","optionValue","Key","inputStyleClass","w-100",3,"completeMethod","suggestions"],["type","text","pInputText","","appMaskNumber","","formControlName","pageSize",3,"ngClass"],[3,"pTooltip"],[4,"ngFor","ngForOf"],[1,"text-danger"]],template:function(r,n){if(r&1){let i=E();l(0,"app-main-panel",8),K("isDialogFilterVisibleChange",function(u){return h(i),M(n.isDialogFilterVisible,u)||(n.isDialogFilterVisible=u),S(u)})("isInitDialogFilterVisibleChange",function(u){return h(i),M(n.isInitDialogFilterVisible,u)||(n.isInitDialogFilterVisible=u),S(u)}),T("filterConfirmed",function(){return h(i),S(n.onFilterOKEvent())})("search",function(u){return h(i),S(n.onSearch(u))}),g(1,Mt,1,1,"ng-template",null,0,b)(3,Gt,10,5,"ng-template",null,1,b)(5,$t,33,24,"ng-template",null,2,b),o()}r&2&&(s("isSearchableInput",!0)("isFilterable",!0),W("isDialogFilterVisible",n.isDialogFilterVisible)("isInitDialogFilterVisible",n.isInitDialogFilterVisible),s("scrollable",!0))},dependencies:[Ie,Ne,De,ke,Je,ee,$,Q,X,et,Z,Y,Be,Ge,ge,_e,fe,ue,Fe,Ve,Te,Ee,He,Ue,se,le,ie,oe,re,ae,pe,de,ce,we,ye,ve,Pe],styles:["[_nghost-%COMP%]{display:block}"],changeDetection:0})}}return t})();var Qt={data:{data:[],totalCount:0},meta:{options:{outlets:[]},filter:{number:null,outletName:null,from:null,to:null,pageNumber:1,pageSize:20,export:!1,exportPageNumber:1,exportPageSize:1e4}},filter:{number:null,outletName:null,from:null,to:null,pageNumber:1,pageSize:20,export:!1,exportPageNumber:1,exportPageSize:1e4}},Xe=he(be(Qt),Se(t=>({first:I(()=>(t.filter().pageNumber-1)*t.filter().pageSize+1),end:I(()=>Math.min(t.filter().pageNumber*t.filter().pageSize,t.data().totalCount)),hasCheckedRows:I(()=>t.data().data.some(p=>p.checked)),checkedShift:I(()=>t.data().data.filter(p=>p.checked).map(p=>p.id))})),Ce(t=>{let p=v(D);return{updateFilter(e){y(t,r=>d(c({},r),{filter:c(c({},r.filter),e)}))},onRowSelect(e){y(t,r=>{let n=r.data.data.map(i=>i.id===e.id?d(c({},i),{checked:!0}):i);return d(c({},r),{data:d(c({},r.data),{data:n})})})},onRowUnselect(e){y(t,r=>{let n=r.data.data.map(i=>i.id===e.id?d(c({},i),{checked:!1}):i);return d(c({},r),{data:d(c({},r.data),{data:n})})})},onHeaderCheckboxToggle(e){y(t,r=>{let n=r.data.data.map(i=>d(c({},i),{checked:e}));return d(c({},r),{data:d(c({},r.data),{data:n})})})},getGJShiftLoader:z(R(B(()=>p.getGJShiftLoader().pipe(j(e=>y(t,r=>d(c({},r),{meta:e})),e=>console.error("Error fetching GJ Shift Loader:",e)))))),getJournalShift:z(R(O(e=>Object.entries(e).reduce((r,[n,i])=>(i!=null&&(r[n]=i),r),{})),B(e=>p.getJournalShift(e).pipe(j(r=>y(t,n=>d(c({},n),{data:r})),r=>console.error("Error fetching journal shift:",r))))))}}),xe(t=>({onInit:()=>{t.getGJShiftLoader(),t.getJournalShift(t.filter)}})));var Ye=t=>({"ng-invalid ng-dirty":t});function Xt(t,p){if(t&1){let e=E();l(0,"p-button",10),T("onClick",function(){h(e);let n=_(2);return S(n.onGenerateJournal())}),o()}}function Yt(t,p){if(t&1&&g(0,Xt,1,0,"p-button",9),t&2){let e=_();s("ngIf",e.store.hasCheckedRows())}}function Zt(t,p){t&1&&(l(0,"tr")(1,"th",12),x(2,"p-tableHeaderCheckbox"),o(),l(3,"th",13),m(4,"Number"),o(),l(5,"th",14),m(6,"Open"),o(),l(7,"th",14),m(8,"Close"),o(),l(9,"th",15),m(10,"Cashier"),o(),l(11,"th",16),m(12,"Sales + Tax"),o(),l(13,"th",17),m(14,"Invoices"),o(),l(15,"th",16),m(16,"Outlet"),o(),l(17,"th",17),m(18,"Register"),o(),l(19,"th",17),m(20,"Visitors"),o(),x(21,"th",18),o())}function ei(t,p){if(t&1&&(l(0,"tr")(1,"td"),x(2,"p-tableCheckbox",19),o(),l(3,"td")(4,"a",20),m(5),o()(),l(6,"td"),m(7),w(8,"date"),o(),l(9,"td"),m(10),w(11,"date"),o(),l(12,"td"),m(13),o(),l(14,"td"),m(15),w(16,"number"),o(),l(17,"td"),m(18),w(19,"number"),o(),l(20,"td"),m(21),o(),l(22,"td"),m(23),o(),l(24,"td"),m(25),w(26,"number"),o(),l(27,"td"),x(28,"p-button",21),o()()),t&2){let e=p.$implicit,r=_(2);a(2),s("value",e),a(2),s("href",r.authService.getTenantExternalURL()+"/menu/Shift/Main/Previous_Shift/Register_Shift_Detail?ID="+e.id,U),a(),J(" ",e.number," "),a(2),C(F(8,14,e.open,"dd MMM y hh:mm")),a(3),C(F(11,17,e.close,"dd MMM y hh:mm")),a(3),C(e.cashier),a(2),C(P(16,20,e.salesNTax)),a(3),C(P(19,22,e.totalInvoice)),a(3),C(e.outlet),a(2),C(e.register),a(2),C(P(26,24,e.visitors)),a(3),s("icon",e.integrated?"fa-solid fa-circle-check":"fa-solid fa-circle-xmark")("severity",e.integrated?"success":"danger")("text",!0)}}function ti(t,p){if(t&1&&m(0),t&2){let e=_(2);A(" Showing ",e.store.first()," to ",e.store.end()," of ",e.store.data().totalCount," entries ")}}function ii(t,p){t&1&&(l(0,"tr")(1,"td",22)(2,"span"),m(3,"No records found."),o()()())}function ni(t,p){if(t&1){let e=E();l(0,"p-panel")(1,"p-table",11),T("onPage",function(n){h(e);let i=_();return S(i.onPageChange(n))})("onRowSelect",function(n){h(e);let i=_();return S(i.onRowSelect(n))})("onRowUnselect",function(n){h(e);let i=_();return S(i.onRowUnselect(n))})("onHeaderCheckboxToggle",function(n){h(e);let i=_();return S(i.onHeaderCheckboxToggle(n))}),g(2,Zt,22,0,"ng-template",null,3,b)(4,ei,29,26,"ng-template",null,4,b)(6,ti,1,3,"ng-template",null,5,b)(8,ii,4,0,"ng-template",null,6,b),o()()}if(t&2){let e=_();a(),s("paginator",!0)("lazy",!0)("rows",e.store.filter().pageSize)("totalRecords",e.store.data().totalCount)("value",e.store.data().data)}}function oi(t,p){if(t&1&&(l(0,"span",32),m(1),w(2,"truncate"),o()),t&2){let e=p.$implicit;s("pTooltip",e.name),a(),J(" ",F(2,2,e.name,30)," ")}}function ri(t,p){if(t&1&&(l(0,"div")(1,"span",34),m(2),o()()),t&2){let e=p.$implicit;a(2),C(e)}}function li(t,p){if(t&1&&(l(0,"div"),g(1,ri,3,1,"div",33),o()),t&2){let e=_(2);a(),s("ngForOf",e.getErrors("from"))}}function ai(t,p){if(t&1&&(l(0,"div")(1,"span",34),m(2),o()()),t&2){let e=p.$implicit;a(2),C(e)}}function pi(t,p){if(t&1&&(l(0,"div"),g(1,ai,3,1,"div",33),o()),t&2){let e=_(2);a(),s("ngForOf",e.getErrors("to"))}}function mi(t,p){if(t&1&&(l(0,"div")(1,"span",34),m(2),o()()),t&2){let e=p.$implicit;a(2),C(e)}}function si(t,p){if(t&1&&(l(0,"div"),g(1,mi,3,1,"div",33),o()),t&2){let e=_(2);a(),s("ngForOf",e.getErrors("pageSize"))}}function ci(t,p){if(t&1&&(l(0,"form",23)(1,"div",24)(2,"label",25),m(3,"Outlet"),o(),l(4,"p-select",26),g(5,oi,3,5,"ng-template",null,7,b),o()(),l(7,"div",24)(8,"label",25),m(9,"From - To"),o(),l(10,"div",27),x(11,"p-datepicker",28),g(12,li,2,1,"div",29),x(13,"p-datepicker",30),g(14,pi,2,1,"div",29),o()(),l(15,"div",24)(16,"label",25),m(17,"Page Size"),o(),x(18,"input",31),g(19,si,2,1,"div",29),o()()),t&2){let e=_();s("formGroup",e.form),a(4),s("virtualScrollItemSize",50)("options",e.store.meta().options.outlets),a(7),s("iconDisplay","input")("showIcon",!0)("ngClass",V(13,Ye,e.isInvalid("from"))),a(),s("ngIf",e.isInvalid("from")),a(),s("iconDisplay","input")("showIcon",!0)("ngClass",V(15,Ye,e.isInvalid("to"))),a(),s("ngIf",e.isInvalid("to")),a(4),s("ngClass",V(17,Ye,e.isInvalid("pageSize"))),a(),s("ngIf",e.isInvalid("pageSize"))}}var _t=(()=>{class t extends Me{constructor(){super(),this.generateJournalService=v(D),this.store=v(Xe),this.authService=v(te),this.isDialogFilterVisible=k(!1),this.isInitDialogFilterVisible=k(!1),this.fb=v(me),this.dayjsService=v(N)}ngOnInit(){this.initForm()}initForm(){let{number:e,outletName:r,from:n,to:i,pageNumber:f,pageSize:u,export:ze,exportPageNumber:je,exportPageSize:Oe}=this.store.filter();this.form=this.fb.group({number:this.fb.control(e),outletName:this.fb.control(r),from:this.fb.control(this.dayjsService.from(n)?this.dayjsService.from(n).toDate():null),to:this.fb.control(this.dayjsService.from(i)?this.dayjsService.from(i).toDate():null),pageNumber:this.fb.control(f),pageSize:this.fb.control(u,[ne.required]),export:this.fb.control(ze),exportPageNumber:this.fb.control(je),exportPageSize:this.fb.control(Oe)})}onFilterOKEvent(){if(this.form.invalid){this.form.markAllAsTouched();return}let e=Object.entries(this.form.getRawValue()).reduce((r,[n,i])=>{switch(n){case"from":typeof i=="object"?r[n]=this.dayjsService.from(i)?this.dayjsService.format(i):null:r[n]=i!=null?String(i):null;break;case"to":typeof i=="object"?r[n]=this.dayjsService.from(i)?this.dayjsService.format(i):null:r[n]=i!=null?String(i):null;break;default:r[n]=i===null?"":i;break}return r},{});this.store.updateFilter(e),this.isDialogFilterVisible.set(!1)}onRowSelect(e){this.store.onRowSelect(e.data)}onRowUnselect(e){if(Array.isArray(e.data)){e.data.forEach(r=>{this.store.onRowUnselect(r)});return}else this.store.onRowUnselect(e.data)}onHeaderCheckboxToggle(e){this.store.onHeaderCheckboxToggle(e.checked)}onGenerateJournal(){this.generateJournalService.generateJournalSupplierBill(this.store.checkedShift()).pipe(G(()=>{this.store.getJournalShift(this.store.filter)})).subscribe()}onSearch(e){this.store.updateFilter(d(c({},this.store.filter()),{number:e}))}onPageChange(e){let r=e.first/e.rows;this.store.updateFilter(d(c({},this.store.filter()),{pageNumber:r+1}))}static{this.\u0275fac=function(r){return new(r||t)}}static{this.\u0275cmp=H({type:t,selectors:[["app-journal-shift"]],features:[q([Xe]),L],decls:7,vars:5,consts:[["actionButton",""],["content",""],["filters",""],["header",""],["body",""],["paginatorleft",""],["emptymessage",""],["item",""],["pageTitle","Shift Journal",3,"isDialogFilterVisibleChange","isInitDialogFilterVisibleChange","filterConfirmed","search","isSearchableInput","isFilterable","isDialogFilterVisible","isInitDialogFilterVisible","scrollable"],["label","Generate Journal",3,"onClick",4,"ngIf"],["label","Generate Journal",3,"onClick"],["dataKey","id",3,"onPage","onRowSelect","onRowUnselect","onHeaderCheckboxToggle","paginator","lazy","rows","totalRecords","value"],[2,"width","1rem"],[2,"width","12rem"],[2,"width","11rem"],[2,"width","14rem"],[2,"width","10rem"],[2,"width","9rem"],[2,"width","4rem"],[3,"value"],["target","_blank",1,"link","link-primary",3,"href"],[3,"icon","severity","text"],["colspan","11"],[1,"d-flex","flex-column","row-gap-3",3,"formGroup"],[1,"d-flex","flex-column"],["for","outlet"],["virtualScroll","","showClear","","filter","","filterBy","name","formControlName","outletName","appendTo","body","optionLabel","name","optionValue","name","placeholder","Select an Outlet",3,"virtualScrollItemSize","options"],[1,"d-flex","flex-column","gap-2"],["showClear","","formControlName","from","styleClass","w-100","appendTo","body","inputId","icondisplay",3,"iconDisplay","showIcon","ngClass"],[4,"ngIf"],["showClear","","formControlName","to","styleClass","w-100","appendTo","body","inputId","icondisplay",3,"iconDisplay","showIcon","ngClass"],["type","text","pInputText","","formControlName","pageSize","appMaskNumber","",3,"ngClass"],[3,"pTooltip"],[4,"ngFor","ngForOf"],[1,"text-danger"]],template:function(r,n){if(r&1){let i=E();l(0,"app-main-panel",8),K("isDialogFilterVisibleChange",function(u){return h(i),M(n.isDialogFilterVisible,u)||(n.isDialogFilterVisible=u),S(u)})("isInitDialogFilterVisibleChange",function(u){return h(i),M(n.isInitDialogFilterVisible,u)||(n.isInitDialogFilterVisible=u),S(u)}),T("filterConfirmed",function(){return h(i),S(n.onFilterOKEvent())})("search",function(u){return h(i),S(n.onSearch(u))}),g(1,Yt,1,1,"ng-template",null,0,b)(3,ni,10,5,"ng-template",null,1,b)(5,ci,20,19,"ng-template",null,2,b),o()}r&2&&(s("isSearchableInput",!0)("isFilterable",!0),W("isDialogFilterVisible",n.isDialogFilterVisible)("isInitDialogFilterVisible",n.isInitDialogFilterVisible),s("scrollable",!0))},dependencies:[Ie,Ne,De,ke,Je,ee,$,Q,X,Z,Y,Be,ge,_e,fe,ue,se,le,ie,oe,re,ae,pe,Fe,Ve,Te,Ee,we,ye,ve,de,ce,Pe],styles:["[_nghost-%COMP%]{display:block}"],changeDetection:0})}}return t})();var fo=[{path:"invoice",component:ut},{path:"supplier-bill",component:ft},{path:"shift",component:_t},{path:"join-invoice",loadComponent:()=>import("./chunk-WFQQUFSS.js").then(t=>t.ARJournalComponent)},{path:"join-bill",loadComponent:()=>import("./chunk-XXNDXSPP.js").then(t=>t.ApJournalComponent)},{path:"adjustment",loadComponent:()=>import("./chunk-CO2UYCZ2.js").then(t=>t.AdjustmentJournalComponent)}];export{fo as generateJournalRoutes};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as o}from"./chunk-
|
|
1
|
+
import{a as o}from"./chunk-OR5FLZPY.js";import{z as n}from"./chunk-VZ5CMS5O.js";import{ca as a,ia as i}from"./chunk-NMCKMUY4.js";var d=(()=>{class e{constructor(){this.httpService=i(o)}journalTagList({pageNumber:t,pageSize:r}={}){let u={params:new n().set("pageNumber",t).set("pageSize",r)};return this.httpService.get(void 0,"/api/journalTag/list",u)}journalTagCreate(t){return this.httpService.post(void 0,"/api/journalTag",t)}journalTagGet(t){return this.httpService.get(void 0,`/api/journalTag?ID=${t}`)}journalTagUpdate(t,r){return this.httpService.put(void 0,`/api/journalTag?ID=${r}`,t)}journalTagDelete(t){return this.httpService.delete(void 0,`/api/journaltag?ID=${t}`)}journalTagInfo(t){return this.httpService.get(void 0,`/api/journaltag?ID=${t}`)}journalTagMigrate(){return this.httpService.post(void 0,"/api/JournalTag/migrate",{})}static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275prov=a({token:e,factory:e.\u0275fac,providedIn:"root"})}}return e})();export{d as a};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as y,b as C,e as F,f as M}from"./chunk-XD7VHCRC.js";import{b as T}from"./chunk-NCDT6JPP.js";import{d as L,e as S}from"./chunk-AOOG6YOT.js";import{a as G}from"./chunk-
|
|
1
|
+
import{a as y,b as C,e as F,f as M}from"./chunk-XD7VHCRC.js";import{b as T}from"./chunk-NCDT6JPP.js";import{d as L,e as S}from"./chunk-AOOG6YOT.js";import{a as G}from"./chunk-OR5FLZPY.js";import{s as U}from"./chunk-VZ5CMS5O.js";import{Ec as g,Lb as n,Pb as l,Tb as m,Ub as f,Vb as a,Wb as p,ca as c,fc as h,hb as s,ia as i,rc as v,sc as b,xb as d}from"./chunk-NMCKMUY4.js";var $=(()=>{class t{constructor(){this.httpService=i(G)}getUserLoaderList(){return this.httpService.get(void 0,"api/UserLoader/List")}getUsers(e){return this.httpService.post(void 0,"api/User/List",e)}getUserFormMeta(e){return this.httpService.post(void 0,"api/UserLoader/Form",{ID:e})}inviteUser(e){return this.httpService.post(void 0,"api/User/Submit",e)}deleteUser(e){return this.httpService.post(void 0,"api/User/Delete",{ListID:e})}getGroupLoader(){return this.httpService.get(void 0,"api/UserGroupLoader/List")}getGroupList(e){return this.httpService.post(void 0,"api/UserGroup/List",e)}getGroupFormMeta(e){return this.httpService.get(void 0,e?`api/UserGroup/Form/${e}`:"api/UserGroup/Form")}assignGroupRole(e){return this.httpService.post(void 0,"api/UserGroup/AssignRole",e)}deleteGroup(e){return this.httpService.post(void 0,"api/UserGroup/Delete",{ListID:e})}static{this.\u0275fac=function(r){return new(r||t)}}static{this.\u0275prov=c({token:t,factory:t.\u0275fac,providedIn:"root"})}}return t})();var k=t=>({"ps-0":t}),x=(t,o)=>o.route;function _(t,o){if(t&1&&(a(0,"p-tab",2)(1,"span"),v(2),p()()),t&2){let e=o.$implicit,r=h();l(g(5,k,r.router.url.includes("forms"))),n("value",e.route)("routerLink",e.route),s(2),b(e.label)}}var B=(()=>{class t{constructor(){this.router=i(L),this.tabs=[{route:"/pages/users/users",label:"Users"},{route:"/pages/users/groups",label:"Groups"}]}get activeTab(){return this.tabs.find(r=>this.router.url.startsWith(r.route)).route||this.tabs[0].route}static{this.\u0275fac=function(r){return new(r||t)}}static{this.\u0275cmp=d({type:t,selectors:[["app-user-tabs"]],decls:4,vars:1,consts:[[3,"value"],[3,"value","routerLink","class"],[3,"value","routerLink"]],template:function(r,u){r&1&&(a(0,"p-tabs",0)(1,"p-tablist"),m(2,_,3,7,"p-tab",1,x),p()()),r&2&&(n("value",u.activeTab),s(2),f(u.tabs))},dependencies:[M,F,y,C,S,T,U],styles:["[_nghost-%COMP%]{display:block} .p-tabs .p-tab{padding:0 1.125rem .6rem 0!important}"],changeDetection:0})}}return t})();export{$ as a,B as b};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as x,b as L}from"./chunk-
|
|
1
|
+
import{a as x,b as L}from"./chunk-YZH7Y43Y.js";import"./chunk-DFGIXWZK.js";import{a as E,b as V}from"./chunk-VJ3IBUVO.js";import"./chunk-KJ2WX3FC.js";import{h as H}from"./chunk-WKE2HPSD.js";import{b as N,c as G}from"./chunk-VGNJD35F.js";import{a as R,b as D}from"./chunk-2XUSZCQL.js";import"./chunk-YV2QJ63P.js";import"./chunk-ARH3WEEF.js";import{w as j,x as O}from"./chunk-H6HNANYB.js";import"./chunk-2D2YD753.js";import"./chunk-OIBDX2CA.js";import"./chunk-OR5FLZPY.js";import{a as I}from"./chunk-2MKKFLNJ.js";import{n as $,s as F}from"./chunk-VZ5CMS5O.js";import"./chunk-F2X3VGZZ.js";import{$b as B,Cc as w,Db as A,Dc as _,Lb as p,Nc as c,Ob as h,Oc as s,Rc as C,Vb as n,W as v,Wb as o,Xb as l,Y as T,_ as M,ec as y,fc as m,h as P,hb as a,ia as f,qa as g,ra as d,s as u,sa as S,ta as b,xb as k}from"./chunk-NMCKMUY4.js";import"./chunk-YQFG5XE2.js";var q=()=>({height:"calc(100vh - 100px)"});function J(i,z){if(i&1){let e=B();n(0,"div",3)(1,"p-button",4),y("onClick",function(){g(e);let r=m();return d(r.onFormat())}),o(),n(2,"p-button",5),c(3,"async"),c(4,"async"),y("onClick",function(){g(e);let r=m();return d(r.migratePaymentAccount())}),o()()}if(i&2){let e=m();a(2),p("disabled",s(3,2,e.countInBooks$)!==0)("pTooltip",s(4,4,e.countInBooks$)!==0?"Books already has entries. Please format before re-migrating.":null)}}function K(i,z){if(i&1&&(n(0,"p-scroll-panel")(1,"p-panel")(2,"div",6),l(3,"app-migration-cards",7),c(4,"async"),S(),n(5,"svg",8),l(6,"path",9),o(),b(),l(7,"app-migration-cards",10),c(8,"async"),o()()()),i&2){let e=m();h(_(12,q)),a(),h(_(13,q)),a(2),p("migrationCount",s(4,8,e.countInPOS$))("migrationTitle",e.pageTitle),a(4),p("migrationCount",s(8,10,e.countInBooks$))("migrationTitle",e.pageTitle)}}var ue=(()=>{class i{constructor(){this.migrateService=f(x),this.toastr=f(I),this.refresh$=new P(void 0),this.pageTitle="Payment Account"}ngOnInit(){let e=this.refresh$.pipe(T(()=>this.migrateService.getPaymentMethodAccountCount()),M(t=>console.log("API response:",t)),v(1));this.countInPOS$=e.pipe(u(t=>Number(t.pos))),this.countInBooks$=e.pipe(u(t=>Number(t.books)))}migratePaymentAccount(){this.migrateService.migratePaymentMethod().subscribe(e=>{this.refresh$.next(),this.toastr.success(e.message,"Migration Successful")})}onFormat(){confirm("Are you sure you want to format?")&&this.migrateService.formatPaymentAccount().subscribe(e=>{this.refresh$.next(),this.toastr.success(e.message,"Format Successful")})}static{this.\u0275fac=function(t){return new(t||i)}}static{this.\u0275cmp=k({type:i,selectors:[["app-payment-account"]],features:[w([x])],decls:5,vars:1,consts:[["actionButton",""],["content",""],[3,"pageTitle"],[1,"d-flex","gap-2"],["label","Format","severity","danger",3,"onClick"],["label","Migrate","tooltipPosition","left",3,"onClick","disabled","pTooltip"],[1,"flex","gap-30","flex-wrap",2,"display","flex","justify-content","center","align-items","center","gap","1rem","margin-top","40px"],["migrationPlace","Accounting",3,"migrationCount","migrationTitle"],["width","40","height","40","viewBox","0 0 24 24","fill","none"],["d","M8 5l8 7-8 7","stroke","#007bff","stroke-width","2","stroke-linecap","round","stroke-linejoin","round"],["migrationPlace","Books",3,"migrationCount","migrationTitle"]],template:function(t,r){t&1&&(n(0,"app-main-panel",2),A(1,J,5,6,"ng-template",null,0,C)(3,K,9,14,"ng-template",null,1,C),o()),t&2&&p("pageTitle",r.pageTitle)},dependencies:[H,F,$,V,E,D,R,G,N,L,O,j],encapsulation:2})}}return i})();export{ue as PaymentAccountComponent};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as b}from"./chunk-2MKKFLNJ.js";import{B as I,C as g,D}from"./chunk-VZ5CMS5O.js";import{I as u,_ as d,ca as m,ia as f,n as y,s as h}from"./chunk-NMCKMUY4.js";import{a as o,b as c}from"./chunk-YQFG5XE2.js";var L=(()=>{class s{constructor(){this.httpClient=f(D),this.toastr=f(b)}get(t="",e,a={}){return this.httpClient.get(`${t}${e}`,a).pipe(u(this.handleError.bind(this)))}post(t="",e,a,r={observe:"response"}){return this.httpClient.post(`${t}${e}`,a,o({},r)).pipe(d(this.handleResponse.bind(this)),h(n=>n instanceof I&&Object.prototype.hasOwnProperty.call(r,"observe")&&r.observe==="response"?n.body instanceof Blob?n:n.body:n),u(this.handleError.bind(this)))}put(t="",e,a,r={}){return this.httpClient.put(`${t}${e}`,a,c(o({},r),{observe:"response"})).pipe(d(this.handleResponse.bind(this)),h(n=>n.body),u(this.handleError.bind(this)))}delete(t="",e,a={}){return this.httpClient.delete(`${t}${e}`,c(o({},a),{observe:"response"})).pipe(d(this.handleResponse.bind(this)),h(r=>r.body),u(this.handleError.bind(this)))}handleResponse(t){if(t instanceof I&&t.status===200&&t.body){let e;typeof t.body=="object"&&t.body!==null&&(e=t.body.message||t.body.Message),typeof e=="string"&&e.length>0&&this.toastr.success(e,"Success")}}handleError(t){let e={header:"API Error",message:"An unknown error occurred"};if(t instanceof g)switch(t.status){case 0:e.message="CORS error: Request blocked or server not responding with proper CORS headers",e.header="CORS Error";break;case 504:e.message=t.statusText||"Gateway Timeout",e.header=`API Error: ${t.status}`;break;default:e.header=`API Error: ${t.status}`,e.message=t.error&&(t.error.Message||t.error.message||t.error.error)||t.message}return t instanceof g&&(t.status>=200&&t.status<300?this.toastr.success(e.message,e.header):t.status>=400&&t.status<500?this.toastr.warning(e.message,e.header):t.status>=500&&t.status<600&&this.toastr.error(e.message,e.header)),y(()=>e)}static{this.\u0275fac=function(e){return new(e||s)}}static{this.\u0275prov=m({token:s,factory:s.\u0275fac,providedIn:"root"})}}return s})();var p={production:!0,version:"5.46.
|
|
1
|
+
import{a as b}from"./chunk-2MKKFLNJ.js";import{B as I,C as g,D}from"./chunk-VZ5CMS5O.js";import{I as u,_ as d,ca as m,ia as f,n as y,s as h}from"./chunk-NMCKMUY4.js";import{a as o,b as c}from"./chunk-YQFG5XE2.js";var L=(()=>{class s{constructor(){this.httpClient=f(D),this.toastr=f(b)}get(t="",e,a={}){return this.httpClient.get(`${t}${e}`,a).pipe(u(this.handleError.bind(this)))}post(t="",e,a,r={observe:"response"}){return this.httpClient.post(`${t}${e}`,a,o({},r)).pipe(d(this.handleResponse.bind(this)),h(n=>n instanceof I&&Object.prototype.hasOwnProperty.call(r,"observe")&&r.observe==="response"?n.body instanceof Blob?n:n.body:n),u(this.handleError.bind(this)))}put(t="",e,a,r={}){return this.httpClient.put(`${t}${e}`,a,c(o({},r),{observe:"response"})).pipe(d(this.handleResponse.bind(this)),h(n=>n.body),u(this.handleError.bind(this)))}delete(t="",e,a={}){return this.httpClient.delete(`${t}${e}`,c(o({},a),{observe:"response"})).pipe(d(this.handleResponse.bind(this)),h(r=>r.body),u(this.handleError.bind(this)))}handleResponse(t){if(t instanceof I&&t.status===200&&t.body){let e;typeof t.body=="object"&&t.body!==null&&(e=t.body.message||t.body.Message),typeof e=="string"&&e.length>0&&this.toastr.success(e,"Success")}}handleError(t){let e={header:"API Error",message:"An unknown error occurred"};if(t instanceof g)switch(t.status){case 0:e.message="CORS error: Request blocked or server not responding with proper CORS headers",e.header="CORS Error";break;case 504:e.message=t.statusText||"Gateway Timeout",e.header=`API Error: ${t.status}`;break;default:e.header=`API Error: ${t.status}`,e.message=t.error&&(t.error.Message||t.error.message||t.error.error)||t.message}return t instanceof g&&(t.status>=200&&t.status<300?this.toastr.success(e.message,e.header):t.status>=400&&t.status<500?this.toastr.warning(e.message,e.header):t.status>=500&&t.status<600&&this.toastr.error(e.message,e.header)),y(()=>e)}static{this.\u0275fac=function(e){return new(e||s)}}static{this.\u0275prov=m({token:s,factory:s.\u0275fac,providedIn:"root"})}}return s})();var p={production:!0,version:"5.46.2",changelogUrl:"https://changelog.dealpos.com/?categories=cat_O6pYAT7GI1mts",defaultTimezone:"Asia/Jakarta",intercom:{appId:"xv1oomgl"}};var l=class s{static{this.emailRegex=/^[a-zA-Z0-9._%+-]+@[a-zA-Z0-9.-]+\.[a-zA-Z]{2,}$/}static{this.phoneNumberRegex=/^\d+$/}static{this.GuidEmpty="00000000-0000-0000-0000-000000000000"}static{this.DecimalMinValue="-7.922816251426434e+28"}static{this.InputLockTimeSpan=500}static{this.MinDate="0001-01-01T00:00:00"}static{this.MinTime="00:00:00"}static{this.MinDecimal="-79228162514264337593543950335"}static StringFormat(i,...t){for(let e=0;e<t.length;e++)i=i.replace(`{${e}}`,t[e]);return i}static{this.isMobileDevice=/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent)}static IsNotEmpty(i){return i!=""&&!s.containsOnlySpaces(i)&&i!=s.GuidEmpty&&i!=null&&i!=null}static IsEmpty(i){return!!(i==""||s.containsOnlySpaces(i)||i==null||i==null||i==s.GuidEmpty)}static isGuid(i){let t=/^[0-9a-fA-F]{8}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{12}$/gi,e=!1;return i&&(e=t.test(i)),e}static containsOnlySpaces(i){return/^\s*$/.test(i)}static FilterByID(i,t){try{let e=i.filter(a=>a.ID==t);if(e.length>0)return e[0]}catch{}return null}static{this.Months=[{ID:1,Label:"January"},{ID:2,Label:"February"},{ID:3,Label:"March"},{ID:4,Label:"April"},{ID:5,Label:"May"},{ID:6,Label:"June"},{ID:7,Label:"July"},{ID:8,Label:"August"},{ID:9,Label:"September"},{ID:10,Label:"October"},{ID:11,Label:"November"},{ID:12,Label:"December"}]}static GenerateYears(i,t,e){let a=-1;(t==null||t==null)&&(t=11),(e==null||e==null||!e)&&(a=1);let r=[];for(let n=0;n<t;n++)r.push(i+n*a);return r}static DateOnly(i){return i?new Date(new Date(i).toDateString()):new Date(new Date().toDateString())}static differentInDays(i,t){let e=t.getTime()-i.getTime();return Math.floor(e/(1e3*3600*24))}static minutesDiff(i,t){let e=(t.getTime()-i.getTime())/6e4;return Math.ceil(e)}static hoursDiff(i,t){let a=(t.getTime()-i.getTime())/(1e3*3600);return parseFloat(a.toFixed(1))}static Guid_NewGuid(){let i=new Date().getTime();return"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,function(e){var a=(i+Math.random()*16)%16|0;return i=Math.floor(i/16),(e=="x"?a:a&3|8).toString(16)})}static parseJwt(i){var t=i.split(".")[1],e=t.replace(/-/g,"+").replace(/_/g,"/"),a=decodeURIComponent(atob(e).split("").map(function(r){return"%"+("00"+r.charCodeAt(0).toString(16)).slice(-2)}).join(""));return JSON.parse(a)}static numberOnly(i){let t=i.which?i.which:i.keyCode;return!(t>31&&(t<48||t>57))}static formatNumber(i){let t="",e="",a=Math.abs(i);return a>999&&a<1e6?(e="K",t=(a/1e3).toFixed(0)):a>=1e6?(e="M",t=(a/1e6).toFixed(0)):a<999&&(t=a.toString()),i<0&&(t="-"+t),t.replace(/\B(?=(\d{3})+(?!\d))/g,",")+e}static isToDay(i){if(this.IsNotEmpty(i)){i=typeof i=="string"?new Date(i):i;let t=new Date;return t.setHours(0,0,0,0),i.setHours(0,0,0,0),t.getTime()==i.getTime()}return!1}static setToLatestTime(i){let t=new Date(i);return t.setHours(23,59,59),t}static setToFirstTime(i){let t=new Date(i);return t.setHours(0,0,0),t}static compare(i,t,e){return(i<t?-1:1)*(e?1:-1)}static generateSerialasNote(i=[]){let t="";return i&&i.length>0&&(t=`[${i.map((a,r)=>`${r>0?" ":""}${a.Number}${a.Quantity>1||a.Quantity<0?"*"+a.Quantity:""}`)}]`),t}static getDatesInRange(i,t){let e=new Date(i.getTime()),a=[];for(;e<=t;)a.push(new Date(e)),e.setDate(e.getDate()+1);return a}static getDaysBefore(i,t){return new Date(i.setDate(new Date().getDate()-t))}static getRangeDate(i,t){let e=new Date;e.setMonth(i),e.setFullYear(t);let a=new Date(e.getFullYear(),e.getMonth()-1,1),r=new Date(e.getFullYear(),e.getMonth(),0);return{firstDay:a,lastDay:r}}static setDateTime(i,t){let e=new Date;t&&(e=new Date(t));let a=i.split(":");return e.setHours(parseInt(a[0])),e.setMinutes(parseInt(a[1])),e}static isMaskingField(i=""){return i.includes("?")}static generateMaskingField(i=[]){let t={};return i.forEach((e,a)=>{e=e.split(" ")?.join(""),t=c(o({},t),{[e]:!0})}),t}static checkJSApiSupported(i){let t;return i in window?t=!0:t=!1,t}static cloneObject(i){let t;return this.checkJSApiSupported("structuredClone")?t=structuredClone(i):t=JSON.parse(JSON.stringify(i)),t}static formatTitleFromDate(i,t){let e=null,a=new Date(i),r=new Date(t);return a.getDate()!=r.getDate()&&(e="d"),a.getMonth()!=r.getMonth()&&(e="d MMM"),a.getFullYear()!=r.getFullYear()&&(e="d MMM yyyy"),e}};var N=(()=>{class s{initializeIntercom(){let t=this.getFromLocalStorage();l.IsNotEmpty(t)&&window.Intercom("boot",{app_id:p.intercom.appId,name:t.name,email:t.email,created_at:t.created,user_hash:t.hash})}shutdown(){window.Intercom("shutdown"),this.clearStorage()}clearStorage(){localStorage.removeItem("INTERCOM")}updateLocalStorage(t){localStorage.setItem("INTERCOM",JSON.stringify(t))}getFromLocalStorage(){let t=localStorage.getItem("INTERCOM");return JSON.parse(t)}hideLauncher(){let t=this.getFromLocalStorage();t.hide_default_launcher=!0,window.Intercom("update",o({app_id:p.intercom.appId},t)),this.updateLocalStorage(t)}showLauncher(){let t=this.getFromLocalStorage();t.hide_default_launcher=!1,window.Intercom("update",o({app_id:p.intercom.appId},t)),this.updateLocalStorage(t)}isHideLauncher(){let t=this.getFromLocalStorage();return l.IsEmpty(t?.hide_default_launcher)?!1:t?.hide_default_launcher}static{this.\u0275fac=function(e){return new(e||s)}}static{this.\u0275prov=m({token:s,factory:s.\u0275fac,providedIn:"root"})}}return s})();export{L as a,l as b,p as c,N as d};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as Q}from"./chunk-
|
|
1
|
+
import{a as Q}from"./chunk-NHIAQTUJ.js";import{a as W}from"./chunk-EB6NEJHF.js";import{a as O}from"./chunk-QF4D5YPK.js";import{h as B}from"./chunk-WKE2HPSD.js";import"./chunk-VGNJD35F.js";import{a as A}from"./chunk-2XUSZCQL.js";import"./chunk-YV2QJ63P.js";import"./chunk-ARH3WEEF.js";import{n as z,w as D}from"./chunk-H6HNANYB.js";import"./chunk-2D2YD753.js";import{b as I,c as N,e as w,f as R,l as P,o as V,u as G,x as q}from"./chunk-OIBDX2CA.js";import{b as M,d as k}from"./chunk-AOOG6YOT.js";import"./chunk-OR5FLZPY.js";import"./chunk-2MKKFLNJ.js";import{h as E,k as J}from"./chunk-VZ5CMS5O.js";import"./chunk-F2X3VGZZ.js";import{$b as F,D as x,Db as p,Ec as j,I as h,Lb as r,N as T,Rc as v,Vb as i,Wb as n,Xb as g,Y as d,_ as f,ec as S,fc as s,hb as a,ia as m,k as _,qa as C,ra as b,rc as c,xb as y}from"./chunk-NMCKMUY4.js";import"./chunk-YQFG5XE2.js";var U=t=>({"ng-invalid ng-dirty":t});function Y(t,u){if(t&1){let e=F();i(0,"div")(1,"p-button",3),S("onClick",function(){C(e);let l=s();return b(l.onSubmit())}),n()()}}function H(t,u){t&1&&(i(0,"div",14),c(1," Name is required "),n())}function K(t,u){if(t&1&&(i(0,"div"),p(1,H,2,0,"div",13),n()),t&2){let e=s(2);a(),r("ngIf",e.form.controls.name.errors.required)}}function L(t,u){if(t&1&&(i(0,"p-panel",4)(1,"div",5)(2,"div",6)(3,"div",7)(4,"div",8)(5,"label",9),c(6,"Name"),n(),g(7,"input",10),p(8,K,2,1,"div",11),n()(),i(9,"div",7)(10,"div",8)(11,"label",9),c(12,"Description"),n(),g(13,"textarea",12),n()()()()()),t&2){let e=s();a(),r("formGroup",e.form),a(6),r("ngClass",j(4,U,e.form.controls.name.invalid&&(e.form.controls.name.dirty||e.form.controls.name.touched))),a(),r("ngIf",e.form.controls.name.invalid&&(e.form.controls.name.dirty||e.form.controls.name.touched)),a(5),r("autoResize",!0)}}var ue=(()=>{class t{constructor(){this.fb=m(G),this.journalTagService=m(Q),this.route=m(M),this.router=m(k)}initForm(){console.log("Initializing form"),this.form=this.fb.group({name:this.fb.control("",[N.required]),description:this.fb.control("")})}ngOnInit(){this.initForm(),this.route.queryParamMap.pipe(x(e=>e.has("id")),d(e=>this.journalTagService.journalTagGet(e.get("id"))),O("Query params"),f(e=>{console.log("Got journal tag:",e),this.form.patchValue({name:e.name,description:e.description})})).subscribe()}onSubmit(){if(this.form.invalid){this.form.markAllAsTouched();return}let e=this.form.getRawValue();this.route.queryParamMap.pipe(T(1),d(o=>{let l=o.get("id");return l?this.journalTagService.journalTagUpdate(e,l):this.journalTagService.journalTagCreate(e)}),f(()=>{console.log("Journal tag saved successfully"),this.router.navigate(["/pages/accounting-setup/journal-tag"])}),h(o=>(console.error("Failed to save journal tag:",o),_))).subscribe()}static{this.\u0275fac=function(o){return new(o||t)}}static{this.\u0275cmp=y({type:t,selectors:[["app-journal-tag-form"]],decls:5,vars:1,consts:[["actionButton",""],["content",""],["pageTitle","Journal Tag Form",3,"hasMainWrapperPadding"],["label","Submit",3,"onClick"],["styleClass","rounded-2"],[1,"d-flex","flex-column","gap-2",3,"formGroup"],[1,"row"],[1,"col-6"],[1,"d-flex","flex-column"],["for",""],["size","small","formControlName","name","type","text","pInputText","",3,"ngClass"],[4,"ngIf"],["rows","2","pSize","large","cols","30","pTextarea","","formControlName","description",3,"autoResize"],["class","invalid-feedback text-danger d-block",4,"ngIf"],[1,"invalid-feedback","text-danger","d-block"]],template:function(o,l){o&1&&(i(0,"app-main-panel",2),p(1,Y,2,0,"ng-template",null,0,v)(3,L,14,6,"ng-template",null,1,v),n()),o&2&&r("hasMainWrapperPadding",!0)},dependencies:[B,z,J,A,q,I,w,R,P,V,W,D,E],encapsulation:2})}}return t})();export{ue as JournalTagFormComponent};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as O,b as H}from"./chunk-
|
|
1
|
+
import{a as O,b as H}from"./chunk-YZH7Y43Y.js";import"./chunk-DFGIXWZK.js";import{a as I,b as E}from"./chunk-VJ3IBUVO.js";import"./chunk-KJ2WX3FC.js";import{h as G}from"./chunk-WKE2HPSD.js";import{b as D,c as N}from"./chunk-VGNJD35F.js";import{a as j,b as R}from"./chunk-2XUSZCQL.js";import"./chunk-YV2QJ63P.js";import"./chunk-ARH3WEEF.js";import{w as V,x as A}from"./chunk-H6HNANYB.js";import"./chunk-2D2YD753.js";import"./chunk-OIBDX2CA.js";import"./chunk-OR5FLZPY.js";import{a as F}from"./chunk-2MKKFLNJ.js";import{n as W,s as $}from"./chunk-VZ5CMS5O.js";import"./chunk-F2X3VGZZ.js";import{$b as w,Cc as P,Db as B,Dc as C,Lb as p,Nc as s,Ob as h,Oc as m,Rc as x,Vb as o,W as y,Wb as n,Xb as c,Y as T,_ as S,ec as _,fc as l,h as v,hb as a,ia as u,qa as g,ra as d,s as f,sa as b,ta as k,xb as M}from"./chunk-NMCKMUY4.js";import"./chunk-YQFG5XE2.js";var L=()=>({height:"calc(100vh - 100px)"});function z(i,q){if(i&1){let e=w();o(0,"div",3)(1,"p-button",4),_("onClick",function(){g(e);let r=l();return d(r.onFormat())}),n(),o(2,"p-button",5),s(3,"async"),s(4,"async"),_("onClick",function(){g(e);let r=l();return d(r.migrateWriteoffOutlet())}),n()()}if(i&2){let e=l();a(2),p("disabled",m(3,2,e.countInBooks$)!==0)("pTooltip",m(4,4,e.countInBooks$)!==0?"Books already has entries. Please format before re-migrating.":null)}}function J(i,q){if(i&1&&(o(0,"p-scroll-panel")(1,"p-panel")(2,"div",6),c(3,"app-migration-cards",7),s(4,"async"),b(),o(5,"svg",8),c(6,"path",9),n(),k(),c(7,"app-migration-cards",10),s(8,"async"),n()()()),i&2){let e=l();h(C(12,L)),a(),h(C(13,L)),a(2),p("migrationCount",m(4,8,e.countInPOS$))("migrationTitle",e.pageTitle),a(4),p("migrationCount",m(8,10,e.countInBooks$))("migrationTitle",e.pageTitle)}}var fe=(()=>{class i{constructor(){this.migrateService=u(O),this.toastr=u(F),this.refresh$=new v(void 0),this.pageTitle="Write-Off Outlet"}ngOnInit(){let e=this.refresh$.pipe(T(()=>this.migrateService.getWriteOffOutletAccountCount()),S(t=>console.log("API response:",t)),y(1));this.countInPOS$=e.pipe(f(t=>Number(t.pos))),this.countInBooks$=e.pipe(f(t=>Number(t.books)))}migrateWriteoffOutlet(){this.migrateService.migrateWriteOffOutlet().subscribe(e=>{this.refresh$.next(),this.toastr.success(e.message,"Migration Successful")})}onFormat(){confirm("Are you sure you want to format?")&&this.migrateService.formatWriteOff().subscribe(e=>{this.refresh$.next(),this.toastr.success(e.message,"Format Successful")})}static{this.\u0275fac=function(t){return new(t||i)}}static{this.\u0275cmp=M({type:i,selectors:[["app-writeoff-outlet"]],features:[P([O])],decls:5,vars:1,consts:[["actionButton",""],["content",""],[3,"pageTitle"],[1,"d-flex","gap-2"],["label","Format","severity","danger",3,"onClick"],["label","Migrate","tooltipPosition","left",3,"onClick","disabled","pTooltip"],[1,"flex","gap-30","flex-wrap",2,"display","flex","justify-content","center","align-items","center","gap","1rem","margin-top","40px"],["migrationPlace","Accounting",3,"migrationCount","migrationTitle"],["width","40","height","40","viewBox","0 0 24 24","fill","none"],["d","M8 5l8 7-8 7","stroke","#007bff","stroke-width","2","stroke-linecap","round","stroke-linejoin","round"],["migrationPlace","Books",3,"migrationCount","migrationTitle"]],template:function(t,r){t&1&&(o(0,"app-main-panel",2),B(1,z,5,6,"ng-template",null,0,x)(3,J,9,14,"ng-template",null,1,x),n()),t&2&&p("pageTitle",r.pageTitle)},dependencies:[G,$,W,E,I,R,j,N,D,H,A,V],encapsulation:2})}}return i})();export{fe as WriteOffOutletComponent};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{a as ie,b as yt}from"./chunk-
|
|
1
|
+
import{a as ie,b as yt}from"./chunk-NPAM3NOH.js";import{f as Ct}from"./chunk-XD7VHCRC.js";import"./chunk-NCDT6JPP.js";import{a as xt}from"./chunk-G4XX7EU2.js";import{a as bt}from"./chunk-XKI7WLHE.js";import{a as wt}from"./chunk-N4JIPI53.js";import"./chunk-7DYACF4D.js";import"./chunk-NZN6QJR3.js";import{a as rt}from"./chunk-5CZNOXPC.js";import"./chunk-IGWIRCAS.js";import{a as ee,b as te}from"./chunk-3A4BFUGD.js";import{d as _t,i as ft,j as ht,k as gt}from"./chunk-EL5BUFMO.js";import"./chunk-EQ4PLHI4.js";import"./chunk-H7Q35Y7G.js";import"./chunk-R7N6BWL5.js";import"./chunk-2AAVNIG7.js";import{a as dt,b as ut}from"./chunk-LFZCMZAP.js";import"./chunk-6A2KUPOG.js";import"./chunk-36OX4S7M.js";import"./chunk-Q5CVMJZC.js";import"./chunk-3GGXPPQT.js";import"./chunk-MFK5RQPJ.js";import"./chunk-6GN3MGBY.js";import"./chunk-Q24GCSGD.js";import{h as mt}from"./chunk-WKE2HPSD.js";import{a as We}from"./chunk-VGNJD35F.js";import{a as it,b as nt}from"./chunk-2XUSZCQL.js";import{a as E,b as ot,c as at,d as st,e as lt,f as pt,g as ct}from"./chunk-YV2QJ63P.js";import"./chunk-ARH3WEEF.js";import{a as Je,f as O,k as Ke,m as Xe,o as Ye,s as et,w as Y,x as tt}from"./chunk-H6HNANYB.js";import"./chunk-2D2YD753.js";import{A as ze,C as je,K as qe,La as $e,Ma as X,Ua as Ze,c as K,e as Ae,f as Oe,l as Be,ma as Ge,o as Ne,u as He,x as Qe,z as fe}from"./chunk-OIBDX2CA.js";import{b as Pe,d as Le,e as Re}from"./chunk-AOOG6YOT.js";import"./chunk-OR5FLZPY.js";import"./chunk-2MKKFLNJ.js";import{h as Z,k as J,m as Ve,s as W}from"./chunk-VZ5CMS5O.js";import{c as Me,d as ce,f as me,h as de,i as ue,k as _e}from"./chunk-F2X3VGZZ.js";import{$b as k,$c as Fe,Aa as H,Bb as z,Cc as $,Db as u,Ec as S,Fc as De,Ha as L,Jc as Ee,Kb as F,Lb as p,Ob as Ce,Pb as ae,Qb as j,Rb as R,Rc as x,Tb as M,Ub as A,Vb as l,Wb as s,Xb as y,Y as N,Yb as ye,Zb as ve,_ as re,_b as U,_c as D,bd as P,c as B,ca as we,cd as Ue,da as be,ec as b,fc as c,gc as Te,hb as a,hc as ke,ia as C,kc as V,lc as q,mc as v,nc as T,qa as _,qc as Ie,ra as f,rc as d,sc as I,tc as G,ua as oe,vc as Se,wc as se,xb as Q,xc as le,yb as xe,yc as pe}from"./chunk-NMCKMUY4.js";import{a as h,b as g}from"./chunk-YQFG5XE2.js";var kt={data:[],count:0,filter:{pagination:1,pageSize:10,groupID:null,text:""},meta:{filter:{pagination:1,pageSize:10,groupID:null,text:""},options:{groups:[]}},metaForm:{form:{id:"",groupID:"",accessTypeID:1,listJournalTagID:[]},options:{users:[],groups:[],accessTypes:[],journalTags:[]}}},he=ot(ct("UserStore"),pt(kt),at(t=>({first:P(()=>(t.filter().pagination-1)*t.filter().pageSize+1),end:P(()=>Math.min(t.filter().pagination*t.filter().pageSize,t.count())),hasCheckedRows:P(()=>t.data().some(o=>o.checked)),checkedData:P(()=>t.data().filter(o=>o.checked).map(o=>o.userID)),selectedID:P(()=>t.data().find(o=>o.checked)?.userID||null)})),lt(t=>{let o=C(ie);return{setFilter(n){E(t,i=>g(h({},i),{filter:n}))},onRowSelect(n){E(t,i=>{let r=i.data.map(m=>m.userID===n.userID?g(h({},m),{checked:!0}):m);return g(h({},i),{data:r})})},onRowUnselect(n){E(t,i=>{let r=i.data.map(m=>m.userID===n.userID?g(h({},m),{checked:!1}):m);return g(h({},i),{data:r})})},onHeaderCheckboxToggle(n){let i=localStorage.getItem("AUTH_USERNAME");E(t,r=>{let m=r.data.map(w=>w.userName!==i?g(h({},w),{checked:n}):g(h({},w),{checked:!1}));return g(h({},r),{data:m})})},getUserLoader:ee(B(N(()=>o.getUserLoaderList().pipe(te({next:n=>{E(t,i=>g(h({},i),{meta:n}))},error:n=>{console.error("Failed to fetch user loader list:",n)}}))))),getUserFormMeta:ee(B(N(n=>o.getUserFormMeta(n).pipe(te({next:i=>{E(t,r=>g(h({},r),{metaForm:i}))},error:i=>{console.error("Failed to fetch user form meta:",i)}}))))),getUsers:ee(B(N(n=>o.getUsers(n).pipe(te({next:i=>{E(t,r=>g(h({},r),{data:i.data.map(m=>g(h({},m),{checked:!1})),count:i.count}))},error:i=>{console.error("Failed to fetch users:",i)}})))))}}),st({onInit:t=>{t.getUserLoader(),t.getUsers(t.filter)}}));var Dt=["header"],Et=["footer"],Ft=["content"],Ut=["closeicon"],Vt=["headless"],Pt=["maskRef"],Lt=["container"],Rt=["closeButton"],Mt=["*"],At=(t,o,e,n,i,r)=>({"p-drawer":!0,"p-drawer-active":t,"p-drawer-left":o,"p-drawer-right":e,"p-drawer-top":n,"p-drawer-bottom":i,"p-drawer-full":r}),Ot=(t,o)=>({transform:t,transition:o}),Bt=t=>({value:"visible",params:t});function Nt(t,o){t&1&&U(0)}function Ht(t,o){if(t&1&&u(0,Nt,1,0,"ng-container",4),t&2){let e=c(2);p("ngTemplateOutlet",e.headlessTemplate||e._headlessTemplate)}}function Qt(t,o){t&1&&U(0)}function zt(t,o){if(t&1&&(l(0,"div"),d(1),s()),t&2){let e=c(3);ae(e.cx("title")),a(),I(e.header)}}function jt(t,o){t&1&&y(0,"TimesIcon"),t&2&&F("data-pc-section","closeicon")}function qt(t,o){}function Gt(t,o){t&1&&u(0,qt,0,0,"ng-template")}function $t(t,o){if(t&1&&u(0,jt,1,1,"TimesIcon",8)(1,Gt,1,0,null,4),t&2){let e=c(4);p("ngIf",!e.closeIconTemplate&&!e._closeIconTemplate),a(),p("ngTemplateOutlet",e.closeIconTemplate||e._closeIconTemplate)}}function Zt(t,o){if(t&1){let e=k();l(0,"p-button",9),b("onClick",function(i){_(e);let r=c(3);return f(r.close(i))})("keydown.enter",function(i){_(e);let r=c(3);return f(r.close(i))}),u(1,$t,2,2,"ng-template",null,1,x),s()}if(t&2){let e=c(3);p("ngClass",e.cx("closeButton"))("buttonProps",e.closeButtonProps)("ariaLabel",e.ariaCloseLabel),F("data-pc-section","closebutton")("data-pc-group-section","iconcontainer")}}function Jt(t,o){t&1&&U(0)}function Wt(t,o){t&1&&U(0)}function Kt(t,o){if(t&1&&(ye(0),l(1,"div",5),u(2,Wt,1,0,"ng-container",4),s(),ve()),t&2){let e=c(3);a(),p("ngClass",e.cx("footer")),F("data-pc-section","footer"),a(),p("ngTemplateOutlet",e.footerTemplate||e._footerTemplate)}}function Xt(t,o){if(t&1&&(l(0,"div",5),u(1,Qt,1,0,"ng-container",4)(2,zt,2,3,"div",6)(3,Zt,3,5,"p-button",7),s(),l(4,"div",5),ke(5),u(6,Jt,1,0,"ng-container",4),s(),u(7,Kt,3,3,"ng-container",8)),t&2){let e=c(2);p("ngClass",e.cx("header")),F("data-pc-section","header"),a(),p("ngTemplateOutlet",e.headerTemplate||e._headerTemplate),a(),p("ngIf",e.header),a(),p("ngIf",e.showCloseIcon&&e.closable),a(),p("ngClass",e.cx("content")),F("data-pc-section","content"),a(2),p("ngTemplateOutlet",e.contentTemplate||e._contentTemplate),a(),p("ngIf",e.footerTemplate||e._footerTemplate)}}function Yt(t,o){if(t&1){let e=k();l(0,"div",3,0),b("@panelState.start",function(i){_(e);let r=c();return f(r.onAnimationStart(i))})("@panelState.done",function(i){_(e);let r=c();return f(r.onAnimationEnd(i))})("keydown",function(i){_(e);let r=c();return f(r.onKeyDown(i))}),u(2,Ht,1,1,"ng-container")(3,Xt,8,9),s()}if(t&2){let e=c();Ce(e.style),ae(e.styleClass),p("ngClass",Ee(9,At,e.visible,e.position==="left"&&!e.fullScreen,e.position==="right"&&!e.fullScreen,e.position==="top"&&!e.fullScreen,e.position==="bottom"&&!e.fullScreen,e.fullScreen||e.position==="full"))("@panelState",S(19,Bt,De(16,Ot,e.transformOptions,e.transitionOptions))),F("data-pc-name","sidebar")("data-pc-section","root"),a(2),j(e.headlessTemplate||e._headlessTemplate?2:3)}}var ei=({dt:t})=>`
|
|
2
2
|
.p-drawer {
|
|
3
3
|
display: flex;
|
|
4
4
|
flex-direction: column;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as v,b as H}from"./chunk-
|
|
1
|
+
import{a as v,b as H}from"./chunk-YZH7Y43Y.js";import"./chunk-DFGIXWZK.js";import{a as F,b as I}from"./chunk-VJ3IBUVO.js";import"./chunk-KJ2WX3FC.js";import{h as G}from"./chunk-WKE2HPSD.js";import{b as D,c as N}from"./chunk-VGNJD35F.js";import{a as O,b as R}from"./chunk-2XUSZCQL.js";import"./chunk-YV2QJ63P.js";import"./chunk-ARH3WEEF.js";import{w as V,x as j}from"./chunk-H6HNANYB.js";import"./chunk-2D2YD753.js";import"./chunk-OIBDX2CA.js";import"./chunk-OR5FLZPY.js";import{a as $}from"./chunk-2MKKFLNJ.js";import{n as A,s as P}from"./chunk-VZ5CMS5O.js";import"./chunk-F2X3VGZZ.js";import{$b as w,Cc as B,Db as E,Dc as _,Lb as p,Nc as c,Ob as x,Oc as m,Rc as C,Vb as n,W as y,Wb as o,Xb as l,Y as b,ec as h,fc as s,h as T,hb as a,ia as f,qa as g,ra as d,s as u,sa as M,ta as S,xb as k}from"./chunk-NMCKMUY4.js";import"./chunk-YQFG5XE2.js";var L=()=>({height:"calc(100vh - 100px)"});function z(i,q){if(i&1){let e=w();n(0,"div",3)(1,"p-button",4),h("onClick",function(){g(e);let r=s();return d(r.onFormat())}),o(),n(2,"p-button",5),c(3,"async"),c(4,"async"),h("onClick",function(){g(e);let r=s();return d(r.onMigrate())}),o()()}if(i&2){let e=s();a(2),p("disabled",m(3,2,e.countInBooks$)!==0)("pTooltip",m(4,4,e.countInBooks$)!==0?"Books already has entries. Please format before re-migrating.":null)}}function J(i,q){if(i&1&&(n(0,"p-scroll-panel")(1,"p-panel")(2,"div",6),l(3,"app-migration-cards",7),c(4,"async"),M(),n(5,"svg",8),l(6,"path",9),o(),S(),l(7,"app-migration-cards",10),c(8,"async"),o()()()),i&2){let e=s();x(_(12,L)),a(),x(_(13,L)),a(2),p("migrationCount",m(4,8,e.countInPOS$))("migrationTitle",e.pageTitle),a(4),p("migrationCount",m(8,10,e.countInBooks$))("migrationTitle",e.pageTitle)}}var le=(()=>{class i{constructor(){this.migrateService=f(v),this.toastr=f($),this.refresh$=new T(void 0),this.pageTitle="Expense Account"}ngOnInit(){let e=this.refresh$.pipe(b(()=>this.migrateService.getExpenseAccountCount()),y(1));this.countInPOS$=e.pipe(u(t=>Number(t.pos))),this.countInBooks$=e.pipe(u(t=>Number(t.books)))}onMigrate(){this.migrateService.migrateExpenseAccount().subscribe(e=>{this.refresh$.next(),this.toastr.success(e.message,"Migration Successful")})}onFormat(){window.confirm("Are you sure you want to format this data? This action cannot be undone.")&&this.migrateService.formatExpenseAccount().subscribe(t=>{this.refresh$.next(),this.toastr.success(t.message,"Format Successful")})}static{this.\u0275fac=function(t){return new(t||i)}}static{this.\u0275cmp=k({type:i,selectors:[["app-expense-account"]],features:[B([v])],decls:5,vars:1,consts:[["actionButton",""],["content",""],[3,"pageTitle"],[1,"d-flex","gap-2"],["label","Format","severity","danger",3,"onClick"],["label","Migrate","tooltipPosition","left",3,"onClick","disabled","pTooltip"],[1,"flex","gap-30","flex-wrap",2,"display","flex","justify-content","center","align-items","center","gap","1rem","margin-top","40px"],["migrationPlace","Accounting",3,"migrationCount","migrationTitle"],["width","40","height","40","viewBox","0 0 24 24","fill","none"],["d","M8 5l8 7-8 7","stroke","#007bff","stroke-width","2","stroke-linecap","round","stroke-linejoin","round"],["migrationPlace","Books",3,"migrationCount","migrationTitle"]],template:function(t,r){t&1&&(n(0,"app-main-panel",2),E(1,z,5,6,"ng-template",null,0,C)(3,J,9,14,"ng-template",null,1,C),o()),t&2&&p("pageTitle",r.pageTitle)},dependencies:[G,P,A,I,F,R,O,N,D,H,j,V],encapsulation:2})}}return i})();export{le as ExpenseAccountComponent};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as v,b as L}from"./chunk-
|
|
1
|
+
import{a as v,b as L}from"./chunk-YZH7Y43Y.js";import"./chunk-DFGIXWZK.js";import{a as I,b as E}from"./chunk-VJ3IBUVO.js";import"./chunk-KJ2WX3FC.js";import{h as H}from"./chunk-WKE2HPSD.js";import{b as N,c as G}from"./chunk-VGNJD35F.js";import{a as R,b as D}from"./chunk-2XUSZCQL.js";import"./chunk-YV2QJ63P.js";import"./chunk-ARH3WEEF.js";import{w as V,x as j}from"./chunk-H6HNANYB.js";import"./chunk-2D2YD753.js";import"./chunk-OIBDX2CA.js";import"./chunk-OR5FLZPY.js";import{a as F}from"./chunk-2MKKFLNJ.js";import{n as O,s as $}from"./chunk-VZ5CMS5O.js";import"./chunk-F2X3VGZZ.js";import{$b as B,Cc as P,Db as w,Dc as _,Lb as p,Nc as s,Ob as h,Oc as m,Rc as x,Vb as o,W as y,Wb as n,Xb as l,Y as M,_ as b,ec as C,fc as c,h as T,hb as a,ia as f,qa as g,ra as d,s as u,sa as S,ta as A,xb as k}from"./chunk-NMCKMUY4.js";import"./chunk-YQFG5XE2.js";var q=()=>({height:"calc(100vh - 100px)"});function J(i,z){if(i&1){let t=B();o(0,"div",3)(1,"p-button",4),C("onClick",function(){g(t);let r=c();return d(r.onFormatCOA())}),n(),o(2,"p-button",5),s(3,"async"),s(4,"async"),C("onClick",function(){g(t);let r=c();return d(r.onMigrateCoaAccount())}),n()()}if(i&2){let t=c();a(2),p("disabled",m(3,2,t.countInBooks$)!==0)("pTooltip",m(4,4,t.countInBooks$)!==0?"Books already has entries. Please format before re-migrating.":null)}}function K(i,z){if(i&1&&(o(0,"p-scroll-panel")(1,"p-panel")(2,"div",6),l(3,"app-migration-cards",7),s(4,"async"),S(),o(5,"svg",8),l(6,"path",9),n(),A(),l(7,"app-migration-cards",10),s(8,"async"),n()()()),i&2){let t=c();h(_(12,q)),a(),h(_(13,q)),a(2),p("migrationCount",m(4,8,t.countInPOS$))("migrationTitle",t.pageTitle),a(4),p("migrationCount",m(8,10,t.countInBooks$))("migrationTitle",t.pageTitle)}}var gt=(()=>{class i{constructor(){this.migrateService=f(v),this.toastr=f(F),this.refresh$=new T(void 0),this.pageTitle="Chart of Account"}ngOnInit(){let t=this.refresh$.pipe(M(()=>this.migrateService.getCOACount()),b(e=>console.log("API response:",e)),y(1));this.countInPOS$=t.pipe(u(e=>Number(e.pos))),this.countInBooks$=t.pipe(u(e=>Number(e.books)))}onMigrateCoaAccount(){this.migrateService.migrateCoaAccount().subscribe(t=>{this.refresh$.next(),this.toastr.success(t.message,"Migration Successful")})}onFormatCOA(){window.confirm("Are you sure you want to format this data? This action cannot be undone.")&&this.migrateService.formatManualCOA().subscribe(e=>{this.refresh$.next(),this.toastr.success(e.message,"Format Successful")})}static{this.\u0275fac=function(e){return new(e||i)}}static{this.\u0275cmp=k({type:i,selectors:[["app-chart-of-account"]],features:[P([v])],decls:5,vars:1,consts:[["actionButton",""],["content",""],[3,"pageTitle"],[1,"d-flex","gap-2"],["label","Format","severity","danger",3,"onClick"],["label","Migrate","tooltipPosition","left",3,"onClick","disabled","pTooltip"],[1,"flex","gap-30","flex-wrap",2,"display","flex","justify-content","center","align-items","center","gap","1rem","margin-top","40px"],["migrationPlace","Accounting",3,"migrationCount","migrationTitle"],["width","40","height","40","viewBox","0 0 24 24","fill","none"],["d","M8 5l8 7-8 7","stroke","#007bff","stroke-width","2","stroke-linecap","round","stroke-linejoin","round"],["migrationPlace","Books",3,"migrationCount","migrationTitle"]],template:function(e,r){e&1&&(o(0,"app-main-panel",2),w(1,J,5,6,"ng-template",null,0,x)(3,K,9,14,"ng-template",null,1,x),n()),e&2&&p("pageTitle",r.pageTitle)},dependencies:[H,$,O,L,j,V,E,I,D,R,G,N],encapsulation:2})}}return i})();export{gt as ChartOfAccountComponent};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as Ve,b as Ae}from"./chunk-NCDT6JPP.js";import{b as De}from"./chunk-
|
|
1
|
+
import{a as Ve,b as Ae}from"./chunk-NCDT6JPP.js";import{b as De}from"./chunk-DFGIXWZK.js";import{a as je}from"./chunk-XKI7WLHE.js";import{a as Fe,b as Me}from"./chunk-N4JIPI53.js";import"./chunk-7DYACF4D.js";import"./chunk-NZN6QJR3.js";import{a as N,b as H}from"./chunk-3A4BFUGD.js";import{d as ye,i as ke,j as Ie,k as Te}from"./chunk-EL5BUFMO.js";import{a as we,b as ve}from"./chunk-EQ4PLHI4.js";import"./chunk-H7Q35Y7G.js";import"./chunk-R7N6BWL5.js";import{a as D}from"./chunk-QF4D5YPK.js";import"./chunk-2AAVNIG7.js";import"./chunk-LFZCMZAP.js";import"./chunk-6A2KUPOG.js";import"./chunk-36OX4S7M.js";import"./chunk-Q5CVMJZC.js";import"./chunk-3GGXPPQT.js";import"./chunk-MFK5RQPJ.js";import"./chunk-6GN3MGBY.js";import"./chunk-Q24GCSGD.js";import{h as Pe}from"./chunk-WKE2HPSD.js";import"./chunk-VGNJD35F.js";import{a as xe,b as he}from"./chunk-2XUSZCQL.js";import{a as h,b as _e,c as Ee,d as Re,e as be,f as Se,g as Ce}from"./chunk-YV2QJ63P.js";import"./chunk-ARH3WEEF.js";import{w as fe,x as ge}from"./chunk-H6HNANYB.js";import"./chunk-2D2YD753.js";import{c as L,e as le,f as pe,l as ce,o as me,u as de,x as ue}from"./chunk-OIBDX2CA.js";import{e as oe,l as ae}from"./chunk-AOOG6YOT.js";import{a as se}from"./chunk-OR5FLZPY.js";import"./chunk-2MKKFLNJ.js";import{h as Z,j as ee,k as te,p as ie,q as ne,s as re}from"./chunk-VZ5CMS5O.js";import"./chunk-F2X3VGZZ.js";import{$b as F,Bb as K,Cc as Q,D as U,Db as _,Dc as W,Ec as j,L as B,Lb as f,Nc as V,Ob as z,Oc as X,P as G,Pc as Y,Rc as b,Vb as a,Wb as o,Xb as E,Y as I,_ as T,bd as A,c as k,ca as q,ec as M,fc as x,hb as u,ia as g,qa as w,ra as v,rc as m,s as P,sc as R,tc as J,xb as $}from"./chunk-NMCKMUY4.js";import{a as s,b as c}from"./chunk-YQFG5XE2.js";var y=(()=>{class t{constructor(){this.httpService=g(se)}getPostRecurringExpenseLoader(){return this.httpService.get(void 0,"api/RecurringExpenseLoader/RecurringExpensesGenerate")}previewPostRecurringExpense(e){return this.httpService.post(void 0,"api/RecurringExpense/RecurringExpensesGeneratePreview",e)}submitPostRecurringExpense(e){return this.httpService.post(void 0,"api/RecurringExpense/RecurringExpensesGenerate",e)}static{this.\u0275fac=function(i){return new(i||t)}}static{this.\u0275prov=q({token:t,factory:t.\u0275fac,providedIn:"root"})}}return t})();var Ne={data:{data:[]},meta:{options:{expenses:[]},form:{date:"",number:"",listIDs:[]}},filter:{date:"",number:"",listIDs:[]}},O=_e(Se(Ne),Ce("PostRecurringExpenseStore"),Ee(t=>({hasCheckedRows:A(()=>t.data().data.some(p=>p.checked)),checkedPRE:A(()=>t.data().data.filter(p=>p.checked))})),be(t=>{let p=g(y);return{updateFilter:i=>{h(t,n=>c(s({},n),{filter:s(s({},n.filter),i)}))},emptyData(){h(t,i=>c(s({},i),{data:{data:[],totalCount:0}}))},onRowSelect(i){h(t,n=>{let r=n.data.data.map(l=>l.lastExpenseDate===i.lastExpenseDate?c(s({},l),{checked:!0}):l);return c(s({},n),{data:c(s({},n.data),{data:r})})})},onRowUnselect(i){h(t,n=>{let r=n.data.data.map(l=>l.lastExpenseDate===i.lastExpenseDate?c(s({},l),{checked:!1}):l);return c(s({},n),{data:c(s({},n.data),{data:r})})})},onHeaderCheckboxToggle(i){h(t,n=>{let r=n.data.data.map(l=>c(s({},l),{checked:i}));return c(s({},n),{data:c(s({},n.data),{data:r})})})},getPRELoader:N(k(I(()=>p.getPostRecurringExpenseLoader().pipe(H({next:i=>{h(t,n=>c(s({},n),{meta:i}))},error:i=>{console.error("Error fetching PRE Loader:",i)}}))))),getPREPreview:N(k(U(i=>i.date&&i.listIDs.length>0),P(i=>({Date:i.date,Number:i.number,ListIDs:i.listIDs})),I(i=>p.previewPostRecurringExpense(i).pipe(P(n=>c(s({},n),{data:n.data.map(r=>c(s({},r),{checked:!1}))})),H({next:n=>{h(t,r=>c(s({},r),{data:n}))},error:n=>{console.error("Error fetching PRE Preview:",n)}})))))}}),Re(t=>({onInit:()=>{t.getPRELoader(),t.getPREPreview(t.filter)}})));var He=()=>({height:"calc(100vh - 70px)"}),Oe=t=>({"ng-invalid ng-dirty":t}),Ue=t=>["/pages/recurring/recurring-expense/details/",t];function Be(t,p){if(t&1){let e=F();a(0,"p-button",7),M("onClick",function(){w(e);let n=x(2);return v(n.onSubmitPRE())}),o()}}function Ge(t,p){if(t&1&&_(0,Be,1,0,"p-button",6),t&2){let e=x();f("ngIf",e.store.hasCheckedRows())}}function qe(t,p){if(t&1&&(a(0,"div")(1,"span",19),m(2),o()()),t&2){let e=p.$implicit;u(2),R(e)}}function $e(t,p){if(t&1&&(a(0,"div"),_(1,qe,3,1,"div",18),o()),t&2){let e=x(2);u(),f("ngForOf",e.getErrors("listIDs"))}}function Ke(t,p){t&1&&(a(0,"tr")(1,"th",20),E(2,"p-tableHeaderCheckbox"),o(),a(3,"th"),m(4,"Name"),o(),a(5,"th"),m(6,"Date"),o(),a(7,"th"),m(8,"Asset Account"),o(),a(9,"th"),m(10,"Expense Account"),o(),a(11,"th",21),m(12,"Amount"),o()())}function ze(t,p){if(t&1&&(a(0,"tr")(1,"td"),E(2,"p-tableCheckbox",22),o(),a(3,"td")(4,"a",23),m(5),o()(),a(6,"td"),m(7),V(8,"date"),o(),a(9,"td"),m(10),o(),a(11,"td"),m(12),o(),a(13,"td",21),m(14),V(15,"number"),o()()),t&2){let e=p.$implicit;u(2),f("value",e),u(2),f("routerLink",j(12,Ue,e.id)),u(),J(" ",e.name," "),u(2),R(Y(8,7,e.nextExpenseDate,"d MMM y")),u(3),R(e.paymentName),u(2),R(e.expenseName),u(2),R(X(15,10,e.amount))}}function Je(t,p){t&1&&(a(0,"tr")(1,"td",24)(2,"span"),m(3,"No records found."),o()()())}function Qe(t,p){if(t&1){let e=F();a(0,"p-panel")(1,"div",8)(2,"div",9)(3,"div",10)(4,"div",11)(5,"div",12)(6,"label",13),m(7,"Date"),o(),E(8,"p-datepicker",14),o()(),a(9,"div",11)(10,"div",12)(11,"label",13),m(12,"Recurring Expense"),o(),E(13,"p-multiselect",15),_(14,$e,2,1,"div",16),o()()()()(),E(15,"p-divider"),a(16,"p-table",17),M("onRowSelect",function(n){w(e);let r=x();return v(r.onRowSelect(n))})("onRowUnselect",function(n){w(e);let r=x();return v(r.onRowUnselect(n))})("onHeaderCheckboxToggle",function(n){w(e);let r=x();return v(r.onHeaderCheckboxToggle(n))}),_(17,Ke,13,0,"ng-template",null,2,b)(19,ze,16,14,"ng-template",null,3,b)(21,Je,4,0,"ng-template",null,4,b),o()()}if(t&2){let e=x();z(W(7,He)),u(),f("formGroup",e.form),u(12),f("ngClass",j(8,Oe,e.isInvalid("listIDs")))("options",e.store.meta().options.expenses),u(),f("ngIf",e.isInvalid("listIDs")),u(2),f("value",e.store.data().data)}}var Lt=(()=>{class t extends je{constructor(){super(),this.store=g(O),this.fb=g(de),this.dayjsService=g(De),this.PREService=g(y)}ngOnInit(){this.initForm(),this.form.valueChanges.pipe(B(300),G(),D("Form Value Changes"),P(e=>Object.entries(e).reduce((i,[n,r])=>{switch(n){case"date":typeof r=="object"&&r!==null&&!Array.isArray(r)?i[n]=this.dayjsService.from(r)?this.dayjsService.format(r):null:(typeof r=="string"||typeof r=="number"||r instanceof Date)&&!Array.isArray(r)?i[n]=r!=null?String(r):null:i[n]=null;break;default:i[n]=r===null?"":r;break}return i},{})),D("Mapped Form Value"),T(e=>{(!e.listIDs||e.listIDs.length===0)&&this.store.emptyData(),this.store.updateFilter(e)})).subscribe()}initForm(){let{date:e,listIDs:i,number:n}=this.store.filter();this.form=this.fb.group({date:this.fb.control(this.dayjsService.from(e)?this.dayjsService.from(e).toDate():this.dayjsService.now.toDate(),[L.required]),number:this.fb.control(n||""),listIDs:this.fb.control(i,[L.required])})}onRowSelect(e){this.store.onRowSelect(e.data)}onRowUnselect(e){if(Array.isArray(e.data)){e.data.forEach(i=>{this.store.onRowUnselect(i)});return}else this.store.onRowUnselect(e.data)}onHeaderCheckboxToggle(e){this.store.onHeaderCheckboxToggle(e.checked)}onSubmitPRE(){console.log(this.store.checkedPRE());let i=this.store.checkedPRE().reduce((r,l)=>(r[l.id]||(r[l.id]={ID:l.id,ListDate:[]}),r[l.id].ListDate.push(l.lastExpenseDate),r),{}),n=Object.values(i);console.log("Submitting PRE with body:",n),this.PREService.submitPostRecurringExpense(n).pipe(D("Submit Post Recurring Expense"),T(()=>{let r=this.form.getRawValue(),l=Object.entries(r).reduce((S,[C,d])=>{switch(C){case"date":typeof d=="object"&&d!==null&&!Array.isArray(d)?S[C]=this.dayjsService.from(d)?this.dayjsService.format(d):null:(typeof d=="string"||typeof d=="number"||d instanceof Date)&&!Array.isArray(d)?S[C]=d!=null?String(d):null:S[C]=null;break;default:S[C]=d===null?"":d;break}return S},{});this.store.updateFilter(l)})).subscribe()}static{this.\u0275fac=function(i){return new(i||t)}}static{this.\u0275cmp=$({type:t,selectors:[["app-post-recurring-expense"]],features:[Q([O]),K],decls:5,vars:1,consts:[["actionButton",""],["content",""],["header",""],["body",""],["emptymessage",""],["pageTitle","Post Recurring Expense",3,"scrollable"],["label","Submit",3,"onClick",4,"ngIf"],["label","Submit",3,"onClick"],[1,"row",3,"formGroup"],[1,"col-6"],[1,"row"],[1,"col"],[1,"d-flex","flex-column"],["for",""],["fluid","","formControlName","date"],["display","chip","formControlName","listIDs","optionLabel","name","optionValue","id","placeholder","Select Recurring Expenses","fluid","",3,"ngClass","options"],[4,"ngIf"],["dataKey","lastExpenseDate",3,"onRowSelect","onRowUnselect","onHeaderCheckboxToggle","value"],[4,"ngFor","ngForOf"],[1,"text-danger"],[2,"width","1rem"],[1,"text-end"],[3,"value"],["target","_blank",1,"link","link-primary",3,"routerLink"],["colspan","6"]],template:function(i,n){i&1&&(a(0,"app-main-panel",5),_(1,Ge,1,1,"ng-template",null,0,b)(3,Qe,23,10,"ng-template",null,1,b),o()),i&2&&f("scrollable",!0)},dependencies:[Pe,re,Z,ee,te,ne,ie,he,xe,Ae,Ve,ve,we,Me,Fe,ue,le,pe,ce,me,Te,ye,ke,Ie,ge,fe,ae,oe],styles:["[_nghost-%COMP%]{display:block}"],changeDetection:0})}}return t})();export{Lt as PostRecurringExpenseComponent};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import"./chunk-YQFG5XE2.js";var t=[{path:"",redirectTo:"tax-account",pathMatch:"full"},{path:"tax-account",loadComponent:()=>import("./chunk-UH5YUPBR.js").then(o=>o.TaxAccountComponent)},{path:"chart-of-account",loadComponent:()=>import("./chunk-QUUGFWG3.js").then(o=>o.ChartOfAccountComponent)},{path:"manual-journal",loadComponent:()=>import("./chunk-C6TI7B2G.js").then(o=>o.ManualJournalComponent)},{path:"payment-account",loadComponent:()=>import("./chunk-NQXDAWEZ.js").then(o=>o.PaymentAccountComponent)},{path:"writeoff-outlet",loadComponent:()=>import("./chunk-PFWNBHNC.js").then(o=>o.WriteOffOutletComponent)},{path:"expense-account",loadComponent:()=>import("./chunk-Q34IDOYA.js").then(o=>o.ExpenseAccountComponent)},{path:"coa-configuration",loadComponent:()=>import("./chunk-G6IPI7YM.js").then(o=>o.CoaConfigurationComponent)},{path:"coa-category",loadComponent:()=>import("./chunk-6LW7PY2Z.js").then(o=>o.CoaCategoryComponent)},{path:"outlet-account",loadComponent:()=>import("./chunk-WY2JNDES.js").then(o=>o.OutletAccountComponent)}];export{t as MIGRATE_ROUTES};
|