dealposbooks 1.9.4 → 1.9.5
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/3rdpartylicenses.txt +375 -375
- package/assets/scss/style.scss +34 -3
- package/assets/scss/variables/_variables.scss +0 -1
- package/chunk-2JCKXI2B.js +180 -0
- package/{chunk-BGDKOH3U.js → chunk-3DN7TZCI.js} +1 -1
- package/chunk-3HN62WAN.js +1 -0
- package/{chunk-25XKSUYX.js → chunk-4B5RFKWI.js} +1 -1
- package/chunk-4FGQ5T64.js +2 -0
- package/{chunk-F7TF7ASR.js → chunk-4GL5YTWS.js} +1 -1
- package/chunk-4LFQJHJZ.js +1 -0
- package/{chunk-AM66YD6C.js → chunk-4S33ZRKF.js} +1 -1
- package/chunk-4WYSO23S.js +1 -0
- package/{chunk-VKO43FOT.js → chunk-5ROVFZR4.js} +1 -1
- package/chunk-5RUWTN5X.js +1 -0
- package/chunk-6JZPAN4G.js +1 -0
- package/chunk-6NDJPEK4.js +185 -0
- package/chunk-6OAGE44Z.js +7 -0
- package/chunk-7GHU4UQ7.js +430 -0
- package/chunk-7UBLUR5O.js +1 -0
- package/{chunk-XMZ7ADZB.js → chunk-7WXXPCRV.js} +1 -1
- package/chunk-7XDZM4MJ.js +1 -0
- package/chunk-AF77PUJO.js +1 -0
- package/chunk-ALX7UOMP.js +193 -0
- package/{chunk-VF7TG32T.js → chunk-ANG5YF2J.js} +1 -1
- package/{chunk-NL5IYBHF.js → chunk-ANMMOPX7.js} +1 -1
- package/chunk-ARESU6CY.js +1 -0
- package/{chunk-5OU7ECCN.js → chunk-ASK2IVMC.js} +1 -1
- package/chunk-AZM2EGTF.js +1 -0
- package/chunk-B7JILYJO.js +1 -0
- package/{chunk-KQAMA66M.js → chunk-BYD3JK4R.js} +1 -1
- package/chunk-CVMIZKGH.js +1 -0
- package/chunk-CVMP55UZ.js +188 -0
- package/chunk-CZMTQ4XK.js +1 -0
- package/chunk-DAV2SMOY.js +222 -0
- package/chunk-DC5OTEZ6.js +1 -0
- package/chunk-DCKLQNGL.js +1 -0
- package/chunk-F2FW6UDP.js +1 -0
- package/chunk-FBUI4SQJ.js +1 -0
- package/chunk-FFODCTQC.js +1 -0
- package/chunk-FIQFBEQK.js +1 -0
- package/chunk-FYQCFDW7.js +1 -0
- package/chunk-G2APSUOI.js +1 -0
- package/chunk-HAZ5H5ZV.js +1 -0
- package/{chunk-7TKATLB4.js → chunk-HI7JDHS3.js} +1 -1
- package/chunk-HJPAXVNY.js +527 -0
- package/{chunk-XEATX3IC.js → chunk-I3HFXOYS.js} +1 -1
- package/{chunk-JRYP3YPK.js → chunk-I7YFUZI7.js} +1 -1
- package/{chunk-HDO45X7Q.js → chunk-IIB2DZLA.js} +1 -1
- package/chunk-IL7RZKFX.js +1 -0
- package/{chunk-7PDAUPWN.js → chunk-IPKPBYSN.js} +12 -12
- package/chunk-IPUUBC74.js +246 -0
- package/{chunk-YQRWSN5V.js → chunk-IZ2XPL4O.js} +1 -1
- package/{chunk-FCGAJLPQ.js → chunk-J2SK4PGN.js} +1 -1
- package/chunk-JGSRMMYX.js +1 -0
- package/{chunk-JQ4DHNFQ.js → chunk-JHCHHBCW.js} +1 -1
- package/{chunk-56MVOUHH.js → chunk-JP3F2QND.js} +1 -1
- package/{chunk-ZKXT6RSI.js → chunk-JQZRKOKE.js} +1 -1
- package/chunk-LYDUVWPM.js +397 -0
- package/chunk-MFMEPXFQ.js +1 -0
- package/{chunk-4FK4QI2U.js → chunk-MP7S52YU.js} +1 -1
- package/chunk-NXCQN45H.js +1 -0
- package/{chunk-HPKZYS2A.js → chunk-O2G255P4.js} +2 -2
- package/{chunk-ITIRJVUS.js → chunk-ONPJXDDI.js} +2 -2
- package/chunk-OSFKXKXD.js +947 -0
- package/chunk-OVIHA23Z.js +201 -0
- package/chunk-P36L53XK.js +1 -0
- package/chunk-P5ZPLAYA.js +79 -0
- package/{chunk-T2A6NORZ.js → chunk-PGECEXRR.js} +1 -1
- package/chunk-PQTUFQME.js +129 -0
- package/{chunk-7XAJOA36.js → chunk-PSDZXCOR.js} +1 -1
- package/chunk-Q7ITPAXT.js +1 -0
- package/chunk-RIOZSND3.js +1 -0
- package/chunk-RVTAI3J3.js +98 -0
- package/{chunk-5QMHSLSU.js → chunk-RZRT24L6.js} +1 -1
- package/chunk-SJ5TWHWM.js +1 -0
- package/chunk-TCF45ELT.js +959 -0
- package/chunk-TYHNOILY.js +1 -0
- package/chunk-VEUXDYYI.js +1 -0
- package/chunk-VG23QNZF.js +231 -0
- package/{chunk-R6HGHSPM.js → chunk-VUPF5YJY.js} +1 -1
- package/chunk-VXSF6SQF.js +1 -0
- package/chunk-WSVAXPZZ.js +82 -0
- package/chunk-X3PB5IV5.js +1 -0
- package/chunk-XLUCH64S.js +449 -0
- package/chunk-YDBJGTTB.js +1 -0
- package/{chunk-5OXHRN43.js → chunk-YLHU3GDJ.js} +1 -1
- package/{chunk-D5AXB5DE.js → chunk-YVEUYFCE.js} +2 -2
- package/chunk-ZWHB7NI7.js +1 -0
- package/index.html +2 -2
- package/main-EJEYMG7N.js +1 -0
- package/package.json +1 -1
- package/{styles-IDKYTRGA.css → styles-AU7PIISM.css} +1 -1
- package/chunk-2TUOAI22.js +0 -1
- package/chunk-3IHOEH5O.js +0 -1
- package/chunk-3VC2KAML.js +0 -1
- package/chunk-4J3EFT67.js +0 -1
- package/chunk-6J5S4UPN.js +0 -2
- package/chunk-7GT5MR57.js +0 -1
- package/chunk-7LCGNNCW.js +0 -627
- package/chunk-7NXTCJMX.js +0 -1
- package/chunk-A3NY5EYN.js +0 -1
- package/chunk-AH5PA2TO.js +0 -1
- package/chunk-B4COOFJS.js +0 -2
- package/chunk-BJGK47CG.js +0 -1
- package/chunk-BWS6U7BM.js +0 -193
- package/chunk-D5RQBZNF.js +0 -1
- package/chunk-DELPZQZH.js +0 -246
- package/chunk-DJUGUNXR.js +0 -503
- package/chunk-DSFIM36S.js +0 -1
- package/chunk-EHCALTHK.js +0 -1
- package/chunk-FUGCJNGU.js +0 -960
- package/chunk-GMLRRSMP.js +0 -1
- package/chunk-IACJNRVA.js +0 -25
- package/chunk-IQZ2MKLS.js +0 -1
- package/chunk-IXPPR5MV.js +0 -1
- package/chunk-J3B5HVW4.js +0 -1
- package/chunk-L6VKOTIV.js +0 -180
- package/chunk-LATJGOV3.js +0 -185
- package/chunk-LLV6TGMT.js +0 -1
- package/chunk-MNCUT4L4.js +0 -1
- package/chunk-NBRL2K4H.js +0 -1
- package/chunk-NDOZ5YES.js +0 -1
- package/chunk-SCEMI63T.js +0 -1
- package/chunk-SDTMCYSJ.js +0 -1
- package/chunk-TDX2HSWE.js +0 -1
- package/chunk-UHVZAFKN.js +0 -1
- package/chunk-UMYCPFK5.js +0 -1660
- package/chunk-UOAJWMSO.js +0 -1
- package/chunk-UZCNPNT7.js +0 -2
- package/chunk-VI3AV775.js +0 -1
- package/chunk-VK5TK23W.js +0 -7
- package/chunk-VNHXLUHA.js +0 -1
- package/chunk-W6UD5NO5.js +0 -2
- package/chunk-WUGCCSIP.js +0 -1
- package/chunk-X234EQET.js +0 -129
- package/chunk-X3FQFXUZ.js +0 -300
- package/chunk-XJ5BSLZV.js +0 -1
- package/chunk-YAKYBQQ6.js +0 -1
- package/main-VQYYYR67.js +0 -1
|
@@ -0,0 +1,185 @@
|
|
|
1
|
+
import{a as f,g as W}from"./chunk-TCF45ELT.js";import{Fa as he,Na as U,Oa as y,R as fe,Wa as ge,wa as me}from"./chunk-ALX7UOMP.js";import{c as de,d as R,f as G,g as J,h as K}from"./chunk-F2X3VGZZ.js";import{h as N,m as d}from"./chunk-BYD3JK4R.js";import{Ab as c,Bc as q,Cb as h,Da as M,Ga as se,Jb as $,Kb as F,Mb as u,Pb as C,Ub as w,Vb as O,Wb as z,Xc as s,Yc as H,Zb as E,_b as oe,aa as m,ba as te,ca as ne,dc as ae,ec as k,fc as g,gb as _,gc as v,ha as D,ic as I,kc as P,lc as B,mc as b,nc as L,pa as ie,pb as V,pc as le,qa as pe,qb as j,qc as ce,rb as T,ta as a,wb as l,xb as re,xc as ue,zc as Q}from"./chunk-YVEUYFCE.js";var x=["*"],ye=["content"],Se=(e,r,t)=>({activateCallback:e,value:r,active:t});function _e(e,r){e&1&&z(0,"p-stepper-separator")}function $e(e,r){if(e&1){let t=oe();w(0,"button",0),ae("click",function(){ie(t);let n=k();return pe(n.onStepClick())}),w(1,"span",1),le(2),O(),w(3,"span",2),v(4),O()(),h(5,_e,1,0,"p-stepper-separator")}if(e&2){let t=k();F("tabindex",t.isStepDisabled()?-1:void 0)("disabled",t.isStepDisabled()),$("id",t.id())("role","tab")("aria-controls",t.ariaControls()),_(2),ce(t.value()),_(3),C(t.isSeparatorVisible()?5:-1)}}function Ce(e,r){e&1&&E(0)}function xe(e,r){e&1&&z(0,"p-stepper-separator")}function De(e,r){if(e&1&&h(0,Ce,1,0,"ng-container",3)(1,xe,1,0,"p-stepper-separator"),e&2){let t=k();F("ngTemplateOutlet",t.content||t._contentTemplate)("ngTemplateOutletContext",q(3,Se,t.onStepClick.bind(t),t.value(),t.active())),_(),C(t.isSeparatorVisible()?1:-1)}}var ve=e=>({transitionParams:e}),Te=e=>({value:"visible",params:e}),Fe=e=>({value:"hidden",params:e});function we(e,r){e&1&&z(0,"p-stepper-separator")}function ke(e,r){e&1&&E(0)}function Ie(e,r){if(e&1&&h(0,ke,1,0,"ng-container",1),e&2){let t=k();F("ngTemplateOutlet",t.contentTemplate||t._contentTemplate)("ngTemplateOutletContext",q(2,Se,t.updateValue.bind(t),t.value(),t.active()))}}var Pe=({dt:e})=>`
|
|
2
|
+
.p-steplist {
|
|
3
|
+
position: relative;
|
|
4
|
+
display: flex;
|
|
5
|
+
justify-content: space-between;
|
|
6
|
+
align-items: center;
|
|
7
|
+
margin: 0;
|
|
8
|
+
padding: 0;
|
|
9
|
+
list-style-type: none;
|
|
10
|
+
overflow-x: auto;
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
.p-step {
|
|
14
|
+
position: relative;
|
|
15
|
+
display: flex;
|
|
16
|
+
flex: 1 1 auto;
|
|
17
|
+
align-items: center;
|
|
18
|
+
gap: ${e("stepper.step.gap")};
|
|
19
|
+
padding: ${e("stepper.step.padding")};
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
.p-step:last-of-type {
|
|
23
|
+
flex: initial;
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
.p-step-header {
|
|
27
|
+
border: 0 none;
|
|
28
|
+
display: inline-flex;
|
|
29
|
+
align-items: center;
|
|
30
|
+
text-decoration: none;
|
|
31
|
+
cursor: pointer;
|
|
32
|
+
transition: background ${e("stepper.transition.duration")}, color ${e("stepper.transition.duration")}, border-color ${e("stepper.transition.duration")}, outline-color ${e("stepper.transition.duration")}, box-shadow ${e("stepper.transition.duration")};
|
|
33
|
+
border-radius: ${e("stepper.step.header.border.radius")};
|
|
34
|
+
outline-color: transparent;
|
|
35
|
+
background: transparent;
|
|
36
|
+
padding: ${e("stepper.step.header.padding")};
|
|
37
|
+
gap: ${e("stepper.step.header.gap")};
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
.p-step-header:focus-visible {
|
|
41
|
+
box-shadow: ${e("stepper.step.header.focus.ring.shadow")};
|
|
42
|
+
outline: ${e("stepper.step.header.focus.ring.width")} ${e("stepper.step.header.focus.ring.style")} ${e("stepper.step.header.focus.ring.color")};
|
|
43
|
+
outline-offset: ${e("stepper.step.header.focus.ring.offset")};
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
.p-stepper.p-stepper-readonly .p-step {
|
|
47
|
+
cursor: auto;
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
.p-step-title {
|
|
51
|
+
display: block;
|
|
52
|
+
white-space: nowrap;
|
|
53
|
+
overflow: hidden;
|
|
54
|
+
text-overflow: ellipsis;
|
|
55
|
+
max-width: 100%;
|
|
56
|
+
color: ${e("stepper.step.title.color")};
|
|
57
|
+
font-weight: ${e("stepper.step.title.font.weight")};
|
|
58
|
+
transition: background ${e("stepper.transition.duration")}, color ${e("stepper.transition.duration")}, border-color ${e("stepper.transition.duration")}, box-shadow ${e("stepper.transition.duration")}, outline-color ${e("stepper.transition.duration")};
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
.p-step-number {
|
|
62
|
+
display: flex;
|
|
63
|
+
align-items: center;
|
|
64
|
+
justify-content: center;
|
|
65
|
+
color: ${e("stepper.step.number.color")};
|
|
66
|
+
border: 2px solid ${e("stepper.step.number.border.color")};
|
|
67
|
+
background: ${e("stepper.step.number.background")};
|
|
68
|
+
min-width: ${e("stepper.step.number.size")};
|
|
69
|
+
height: ${e("stepper.step.number.size")};
|
|
70
|
+
line-height: ${e("stepper.step.number.size")};
|
|
71
|
+
font-size: ${e("stepper.step.number.font.size")};
|
|
72
|
+
z-index: 1;
|
|
73
|
+
border-radius: ${e("stepper.step.number.border.radius")};
|
|
74
|
+
position: relative;
|
|
75
|
+
font-weight: ${e("stepper.step.number.font.weight")};
|
|
76
|
+
}
|
|
77
|
+
|
|
78
|
+
.p-step-number::after {
|
|
79
|
+
content: " ";
|
|
80
|
+
position: absolute;
|
|
81
|
+
width: 100%;
|
|
82
|
+
height: 100%;
|
|
83
|
+
border-radius: ${e("stepper.step.number.border.radius")};
|
|
84
|
+
box-shadow: ${e("stepper.step.number.shadow")};
|
|
85
|
+
}
|
|
86
|
+
|
|
87
|
+
.p-step-active .p-step-header {
|
|
88
|
+
cursor: default;
|
|
89
|
+
}
|
|
90
|
+
|
|
91
|
+
.p-step-active .p-step-number {
|
|
92
|
+
background: ${e("stepper.step.number.active.background")};
|
|
93
|
+
border-color: ${e("stepper.step.number.active.border.color")};
|
|
94
|
+
color: ${e("stepper.step.number.active.color")};
|
|
95
|
+
}
|
|
96
|
+
|
|
97
|
+
.p-step-active .p-step-title {
|
|
98
|
+
color: ${e("stepper.step.title.active.color")};
|
|
99
|
+
}
|
|
100
|
+
|
|
101
|
+
.p-step:not(.p-disabled):focus-visible {
|
|
102
|
+
outline: ${e("focus.ring.width")} ${e("focus.ring.style")} ${e("focus.ring.color")};
|
|
103
|
+
outline-offset: ${e("focus.ring.offset")};
|
|
104
|
+
}
|
|
105
|
+
|
|
106
|
+
.p-step:has(~ .p-step-active) .p-stepper-separator {
|
|
107
|
+
background: ${e("stepper.separator.active.background")};
|
|
108
|
+
}
|
|
109
|
+
|
|
110
|
+
.p-stepper-separator {
|
|
111
|
+
flex: 1 1 0;
|
|
112
|
+
background: ${e("stepper.separator.background")};
|
|
113
|
+
width: 100%;
|
|
114
|
+
height: ${e("stepper.separator.size")};
|
|
115
|
+
transition: background ${e("stepper.transition.duration")}, color ${e("stepper.transition.duration")}, border-color ${e("stepper.transition.duration")}, box-shadow ${e("stepper.transition.duration")}, outline-color ${e("stepper.transition.duration")};
|
|
116
|
+
}
|
|
117
|
+
|
|
118
|
+
.p-steppanels {
|
|
119
|
+
padding: ${e("stepper.steppanels.padding")};
|
|
120
|
+
}
|
|
121
|
+
|
|
122
|
+
.p-steppanel {
|
|
123
|
+
background: ${e("stepper.steppanel.background")};
|
|
124
|
+
color: ${e("stepper.steppanel.color")};
|
|
125
|
+
}
|
|
126
|
+
|
|
127
|
+
.p-stepper:has(.p-stepitem) {
|
|
128
|
+
display: flex;
|
|
129
|
+
flex-direction: column;
|
|
130
|
+
}
|
|
131
|
+
|
|
132
|
+
.p-stepitem {
|
|
133
|
+
display: flex;
|
|
134
|
+
flex-direction: column;
|
|
135
|
+
flex: initial;
|
|
136
|
+
}
|
|
137
|
+
|
|
138
|
+
.p-stepitem.p-stepitem-active {
|
|
139
|
+
flex: 1 1 auto;
|
|
140
|
+
}
|
|
141
|
+
|
|
142
|
+
.p-stepitem .p-step {
|
|
143
|
+
flex: initial;
|
|
144
|
+
}
|
|
145
|
+
|
|
146
|
+
.p-stepitem .p-steppanel-content {
|
|
147
|
+
width: 100%;
|
|
148
|
+
padding: ${e("stepper.steppanel.padding")};
|
|
149
|
+
margin-inline-start: 1rem;
|
|
150
|
+
}
|
|
151
|
+
|
|
152
|
+
.p-stepitem .p-steppanel {
|
|
153
|
+
display: flex;
|
|
154
|
+
flex: 1 1 auto;
|
|
155
|
+
}
|
|
156
|
+
|
|
157
|
+
.p-stepitem .p-stepper-separator {
|
|
158
|
+
flex: 0 0 auto;
|
|
159
|
+
width: ${e("stepper.separator.size")};
|
|
160
|
+
height: auto;
|
|
161
|
+
margin: ${e("stepper.separator.margin")};
|
|
162
|
+
position: relative;
|
|
163
|
+
left: calc(-1 * ${e("stepper.separator.size")});
|
|
164
|
+
}
|
|
165
|
+
|
|
166
|
+
.p-stepitem .p-stepper-separator:dir(rtl) {
|
|
167
|
+
left: calc(-9 * ${e("stepper.separator.size")});
|
|
168
|
+
}
|
|
169
|
+
|
|
170
|
+
.p-stepitem:has(~ .p-stepitem-active) .p-stepper-separator {
|
|
171
|
+
background: ${e("stepper.separator.active.background")};
|
|
172
|
+
}
|
|
173
|
+
|
|
174
|
+
.p-stepitem:last-of-type .p-steppanel {
|
|
175
|
+
padding-inline-start: ${e("stepper.step.number.size")};
|
|
176
|
+
}
|
|
177
|
+
/* For PrimeNG */
|
|
178
|
+
.p-steppanel {
|
|
179
|
+
overflow: hidden;
|
|
180
|
+
}
|
|
181
|
+
|
|
182
|
+
.p-stepppanel:not(.ng-animating) {
|
|
183
|
+
overflow: inherit;
|
|
184
|
+
}
|
|
185
|
+
`,Be={root:({props:e})=>["p-stepper p-component",{"p-readonly":e.linear}],separator:"p-stepper-separator"},be=(()=>{class e extends ge{name="stepper";theme=Pe;classes=Be;static \u0275fac=(()=>{let t;return function(n){return(t||(t=a(e)))(n||e)}})();static \u0275prov=te({token:e,factory:e.\u0275fac})}return e})();var X=(()=>{class e extends f{steps=j(m(()=>S));static \u0275fac=(()=>{let t;return function(n){return(t||(t=a(e)))(n||e)}})();static \u0275cmp=l({type:e,selectors:[["p-step-list"]],contentQueries:function(i,n,p){i&1&&b(p,n.steps,S,4),i&2&&L()},hostVars:4,hostBindings:function(i,n){i&2&&u("p-steplist",!0)("p-component",!0)},features:[c],ngContentSelectors:x,decls:1,vars:0,template:function(i,n){i&1&&(g(),v(0))},dependencies:[d],encapsulation:2,changeDetection:0})}return e})(),ee=(()=>{class e extends f{static \u0275fac=(()=>{let t;return function(n){return(t||(t=a(e)))(n||e)}})();static \u0275cmp=l({type:e,selectors:[["p-stepper-separator"]],hostVars:4,hostBindings:function(i,n){i&2&&u("p-stepper-separator",!0)("p-component",!0)},features:[c],ngContentSelectors:x,decls:1,vars:0,template:function(i,n){i&1&&(g(),v(0))},dependencies:[d],encapsulation:2,changeDetection:0})}return e})(),Y=(()=>{class e extends f{pcStepper=D(m(()=>A));value=T();isActive=s(()=>this.pcStepper.value()===this.value());step=V(m(()=>S));stepPanel=V(m(()=>Z));constructor(){super(),H(()=>{this.step().value.set(this.value())}),H(()=>{this.stepPanel().value.set(this.value())})}static \u0275fac=function(i){return new(i||e)};static \u0275cmp=l({type:e,selectors:[["p-step-item"]],contentQueries:function(i,n,p){i&1&&(b(p,n.step,S,5),b(p,n.stepPanel,Z,5)),i&2&&L(2)},hostVars:5,hostBindings:function(i,n){i&2&&($("data-p-active",n.isActive()),u("p-stepitem",!0)("p-component",!0))},inputs:{value:[1,"value"]},outputs:{value:"valueChange"},features:[c],ngContentSelectors:x,decls:1,vars:0,template:function(i,n){i&1&&(g(),v(0))},dependencies:[d],encapsulation:2,changeDetection:0})}return e})(),S=(()=>{class e extends f{pcStepper=D(m(()=>A));value=T();disabled=M(!1,{transform:t=>W(t)});active=s(()=>this.pcStepper.isStepActive(this.value()));isStepDisabled=s(()=>!this.active()&&(this.pcStepper.linear()||this.disabled()));id=s(()=>`${this.pcStepper.id()}_step_${this.value()}`);ariaControls=s(()=>`${this.pcStepper.id()}_steppanel_${this.value()}`);isSeparatorVisible=s(()=>{if(this.pcStepper.stepList()){let t=this.pcStepper.stepList().steps(),i=t.indexOf(this),n=t.length;return i!==n-1}else return!1});content;templates;_contentTemplate;ngAfterContentInit(){this.templates?.forEach(t=>{switch(t.getType()){case"content":this._contentTemplate=t.template;break}})}onStepClick(){this.pcStepper.updateValue(this.value())}static \u0275fac=(()=>{let t;return function(n){return(t||(t=a(e)))(n||e)}})();static \u0275cmp=l({type:e,selectors:[["p-step"]],contentQueries:function(i,n,p){if(i&1&&(I(p,ye,4),I(p,U,4)),i&2){let o;P(o=B())&&(n.content=o.first),P(o=B())&&(n.templates=o)}},hostVars:13,hostBindings:function(i,n){i&2&&($("aria-current",n.active()?"step":void 0)("role","presentation")("data-p-active",n.active())("data-p-disabled",n.isStepDisabled())("data-pc-name","step"),u("p-step",!0)("p-step-active",n.active())("p-disabled",n.isStepDisabled())("p-component",!0))},inputs:{value:[1,"value"],disabled:[1,"disabled"]},outputs:{value:"valueChange"},features:[c],ngContentSelectors:x,decls:2,vars:1,consts:[["type","button",1,"p-step-header",3,"click","tabindex","disabled"],[1,"p-step-number"],[1,"p-step-title"],[4,"ngTemplateOutlet","ngTemplateOutletContext"]],template:function(i,n){i&1&&(g(),h(0,$e,6,7)(1,De,2,7)),i&2&&C(!n.content&&!n._contentTemplate?0:1)},dependencies:[d,N,ee,y],encapsulation:2,changeDetection:0})}return e})(),Z=(()=>{class e extends f{pcStepper=D(m(()=>A));transitionOptions=s(()=>this.pcStepper.transitionOptions());value=T(void 0);active=s(()=>this.pcStepper.value()===this.value());ariaControls=s(()=>`${this.pcStepper.id()}_step_${this.value()}`);id=s(()=>`${this.pcStepper.id()}_steppanel_${this.value()}`);isVertical=s(()=>this.pcStepper.stepItems().length>0);isSeparatorVisible=s(()=>{if(this.pcStepper.stepItems()){let t=this.pcStepper.stepItems().length,i=fe(this.pcStepper.el.nativeElement,'[data-pc-name="steppanel"]');return me(this.el.nativeElement,i)!==t-1}});contentTemplate;templates;_contentTemplate;ngAfterContentInit(){this.templates?.forEach(t=>{switch(t.getType()){case"content":this._contentTemplate=t.template;break}})}updateValue(t){this.pcStepper.updateValue(t)}static \u0275fac=(()=>{let t;return function(n){return(t||(t=a(e)))(n||e)}})();static \u0275cmp=l({type:e,selectors:[["p-step-panel"]],contentQueries:function(i,n,p){if(i&1&&(I(p,ye,5),I(p,U,4)),i&2){let o;P(o=B())&&(n.contentTemplate=o.first),P(o=B())&&(n.templates=o)}},hostVars:11,hostBindings:function(i,n){i&2&&($("role","tabpanel")("aria-controls",n.ariaControls())("id",n.id())("data-p-active",n.active())("data-pc-name","steppanel"),u("p-steppanel",!0)("p-component",!0)("p-steppanel-active",n.active()))},inputs:{value:[1,"value"]},outputs:{value:"valueChange"},features:[c],decls:3,vars:11,consts:[[1,"p-steppanel-content"],[4,"ngTemplateOutlet","ngTemplateOutletContext"]],template:function(i,n){i&1&&(h(0,we,1,0,"p-stepper-separator"),w(1,"div",0),h(2,Ie,1,6,"ng-container"),O()),i&2&&(C(n.isSeparatorVisible()?0:-1),_(),F("@content",n.isVertical()?n.active()?Q(5,Te,Q(3,ve,n.transitionOptions())):Q(9,Fe,Q(7,ve,n.transitionOptions())):void 0),_(),C(n.active()?2:-1))},dependencies:[d,N,ee,y],encapsulation:2,data:{animation:[de("content",[J("hidden",G({height:"0",visibility:"hidden"})),J("visible",G({height:"*",visibility:"visible"})),K("visible <=> hidden",[R("250ms cubic-bezier(0.86, 0, 0.07, 1)")]),K("void => *",R(0))])]},changeDetection:0})}return e})(),Qe=(()=>{class e extends f{static \u0275fac=(()=>{let t;return function(n){return(t||(t=a(e)))(n||e)}})();static \u0275cmp=l({type:e,selectors:[["p-step-panels"]],hostVars:4,hostBindings:function(i,n){i&2&&u("p-steppanels",!0)("p-component",!0)},features:[c],ngContentSelectors:x,decls:1,vars:0,template:function(i,n){i&1&&(g(),v(0))},dependencies:[d,y],encapsulation:2,changeDetection:0})}return e})(),A=(()=>{class e extends f{value=T(void 0);linear=M(!1,{transform:t=>W(t)});transitionOptions=M("400ms cubic-bezier(0.86, 0, 0.07, 1)");_componentStyle=D(be);id=se(he("pn_id_"));stepItems=j(Y);steps=j(S);stepList=V(X);updateValue(t){this.value.set(t)}isStepActive(t){return this.value()===t}static \u0275fac=(()=>{let t;return function(n){return(t||(t=a(e)))(n||e)}})();static \u0275cmp=l({type:e,selectors:[["p-stepper"]],contentQueries:function(i,n,p){i&1&&(b(p,n.stepItems,Y,4),b(p,n.steps,S,4),b(p,n.stepList,X,5)),i&2&&L(3)},hostVars:6,hostBindings:function(i,n){i&2&&($("role","tablist")("id",n.id()),u("p-stepper",!0)("p-component",!0))},inputs:{value:[1,"value"],linear:[1,"linear"],transitionOptions:[1,"transitionOptions"]},outputs:{value:"valueChange"},features:[ue([be]),c],ngContentSelectors:x,decls:1,vars:0,template:function(i,n){i&1&&(g(),v(0))},dependencies:[d,y],encapsulation:2,changeDetection:0})}return e})(),Xe=(()=>{class e{static \u0275fac=function(i){return new(i||e)};static \u0275mod=re({type:e});static \u0275inj=ne({imports:[A,X,Qe,Z,Y,S,ee,y,y]})}return e})();export{X as a,S as b,Z as c,Qe as d,A as e,Xe as f};
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import{a as Te,b as Le}from"./chunk-RZRT24L6.js";import{a as Ct,b as ye}from"./chunk-IZ2XPL4O.js";import{a as Fe}from"./chunk-CVMIZKGH.js";import{a as St}from"./chunk-NRULEUE7.js";import{b as ht,c as xt}from"./chunk-LYDUVWPM.js";import{a as Ce,b as ve}from"./chunk-VG23QNZF.js";import"./chunk-VUPF5YJY.js";import"./chunk-MP7S52YU.js";import{b as gt}from"./chunk-4B5RFKWI.js";import{a as oe,b as De}from"./chunk-JHCHHBCW.js";import{a as H,b as Y}from"./chunk-JP3F2QND.js";import{a as ut,b as _t,d as xe,k as Se}from"./chunk-OSFKXKXD.js";import{a as ge,b as he}from"./chunk-7GHU4UQ7.js";import"./chunk-P36L53XK.js";import{a as ft}from"./chunk-FBUI4SQJ.js";import{a as A}from"./chunk-B7JILYJO.js";import"./chunk-RVTAI3J3.js";import{b as Re}from"./chunk-DAV2SMOY.js";import"./chunk-P5ZPLAYA.js";import"./chunk-CVMP55UZ.js";import"./chunk-7UBLUR5O.js";import"./chunk-AZM2EGTF.js";import"./chunk-HI7JDHS3.js";import{e as ct}from"./chunk-JQZRKOKE.js";import{c as le,d as pe}from"./chunk-ANG5YF2J.js";import{b as fe}from"./chunk-4GL5YTWS.js";import{f as dt,h as _e}from"./chunk-2JCKXI2B.js";import"./chunk-YLHU3GDJ.js";import{a as V,b as me,c as ce,d as se,e as de,f as ue,g as st}from"./chunk-4S33ZRKF.js";import"./chunk-4FGQ5T64.js";import{w as re,x as ae}from"./chunk-TCF45ELT.js";import"./chunk-ZWHB7NI7.js";import{c as lt,e as X,f as Z,g as pt,i as G,k as ee,m as te,p as ie,u as mt,w as we,z as ne}from"./chunk-ALX7UOMP.js";import{a as at}from"./chunk-HAZ5H5ZV.js";import{a as rt}from"./chunk-4LFQJHJZ.js";import"./chunk-F2X3VGZZ.js";import{C as ot,F as J,M as Q,c as tt,f as Ie,k as it,l as K,m as $,s as nt}from"./chunk-BYD3JK4R.js";import{Cb as C,D as Ee,Ga as T,Ic as x,Jc as S,Kb as c,Kc as Ze,Lc as s,Nb as N,Pb as O,Qb as Je,Sb as Qe,Tb as Xe,Ub as i,V as ze,Vb as n,W as Ue,Wb as E,X as j,Xc as R,Yc as et,Z as k,_b as L,ba as Ke,c as P,cb as $e,dc as w,ec as d,gb as l,ha as h,pa as y,pc as r,qa as b,qc as u,rc as D,s as We,uc as W,vc as q,wb as M,wc as z,xc as U,yc as I,zc as F}from"./chunk-YVEUYFCE.js";import{a as g,b as v,c as Ve,e as Ye}from"./chunk-YQFG5XE2.js";var B=(()=>{class t{constructor(){this.httpService=h(at),this.authService=h(Fe)}fetchGeneralLedgerLoader(e={}){return this.httpService.post(void 0,"api/GeneralLedgerLoader/GetFilter",e)}fetchGeneralLedgerReport(e){return this.httpService.post(void 0,"api/GeneralLedger/Get",e)}exportGeneralLedger(e){let a={responseType:"blob"};return this.httpService.post(void 0,"/api/GeneralLedgerExport/GetGeneralLedgerExport",e,a)}getCustomerSuggestions(e){let a={Prefix:e,Count:100};return this.httpService.get(this.authService.getTenantExternalURL(),"/API/AC/GetCustomerSuggestion",{params:a})}getSupplierSuggestions(e){let a={Prefix:e,Count:100};return this.httpService.get(this.authService.getTenantExternalURL(),"/API/AC/GetSupplierSuggestion",{params:a})}getCashierSuggestions(e){let a={Prefix:e,Count:100};return this.httpService.get(this.authService.getTenantExternalURL(),"/api/ac/GetUserSuggestion",{params:a})}getBalanceSheetLoader(){return this.httpService.get(void 0,"/api/BalanceSheetLoader/GetBalanceSheet")}getBalanceSheet(e,a={}){let o=new nt({fromObject:Object.fromEntries(Object.entries(e).map(([f,_])=>[f,String(_)]))}),m=g({params:o},a);return this.httpService.get(void 0,"/api/BalanceSheet",m)}getIncomeStatementLoader(){return this.httpService.get(void 0,"api/IncomeStatementLoader/Filter")}getIncomeStatement(e,a={}){return this.httpService.post(void 0,"api/IncomeStatement/List",g({},e),a)}static{this.\u0275fac=function(a){return new(a||t)}}static{this.\u0275prov=Ke({token:t,factory:t.\u0275fac,providedIn:"root"})}}return t})();var Gt={metadata:{filter:{categoryID:"",from:new Date().toISOString(),to:new Date().toISOString(),iDs:[],outletIDs:[]},options:{accounts:[],outlets:[]},roles:{isInEmptyOutletRole:!1}},items:{data:[],pageTitle:""},filter:{listAccountID:[],categoryID:null,OutletID:[],ContactID:null,from:null,to:null}},Me=me(ue(Gt),st("General Ledger Store"),ce(t=>({debitTotal:R(()=>t.items.data().reduce((p,e)=>p+e.data.reduce((a,o)=>a+(o.debitAmount||0),0),0)),creditTotal:R(()=>t.items.data().reduce((p,e)=>p+e.data.reduce((a,o)=>a+(o.creditAmount||0),0),0))})),de(t=>{let p=h(B),e={updateFilter:a=>{V(t,o=>v(g({},o),{filter:a}))},loadList:H(P(Ee(a=>Array.isArray(a.listAccountID)&&a.listAccountID.length>0),j(a=>p.fetchGeneralLedgerReport(a).pipe(Y({next:o=>{V(t,m=>v(g({},m),{items:o}))},error:o=>{console.error(o)}}))))),loadLoader:H(P(j(a=>p.fetchGeneralLedgerLoader(a).pipe(Y({next:o=>{V(t,m=>v(g({},m),{metadata:o,filter:v(g({},m.filter),{categoryID:o.filter.categoryID})})),e.loadList(t.filter)},error:o=>{console.error(o)}}))),A("res")))};return e}),se({onInit:t=>{t.loadLoader({})}}));var jt=()=>({height:"calc(100vh - 70px)"}),Nt=()=>({height:"calc(100vh - 100px)"}),qt=t=>["/pages/journal/journal-entry/",t],Ht=t=>({"ng-invalid ng-dirty":t}),Yt=()=>({scrollHeight:"250px"});function Wt(t,p){if(t&1){let e=L();i(0,"div",11)(1,"a",12),r(2,"Return to Accounts"),n(),i(3,"p-button",13),w("onClick",function(){y(e);let o=d();return b(o.onExport())}),n()()}}function zt(t,p){if(t&1&&(i(0,"div",11)(1,"span",16)(2,"h3",17),r(3),n()(),i(4,"span",16)(5,"h3",17),r(6),n()()()),t&2){let e=d().$implicit;l(3),u(e.name),l(3),D(" (",e.chartOfAccountCode,") ")}}function Ut(t,p){t&1&&(i(0,"tr")(1,"th",18),r(2,"Outlet"),n(),i(3,"th",18),r(4,"No."),n(),i(5,"th",18),r(6,"Date"),n(),i(7,"th",18),r(8,"Name"),n(),i(9,"th",18),r(10,"Description"),n(),i(11,"th",19),r(12,"Debit"),n(),i(13,"th",20),r(14,"Credit"),n(),i(15,"th",20),r(16,"Balance"),n()())}function Kt(t,p){if(t&1&&(i(0,"td",25),r(1,"Starting Balance"),n(),i(2,"td",26),r(3),x(4,"number"),n()),t&2){let e=d(2).$implicit;l(3),D(" ",S(4,1,e.startBalance)," ")}}function $t(t,p){if(t&1&&(i(0,"tr"),C(1,Kt,5,3),n(),i(2,"tr")(3,"td",21),r(4),n(),i(5,"td",21)(6,"a",22),r(7),n()(),i(8,"td",21),r(9),x(10,"date"),n(),i(11,"td",21)(12,"a",23),r(13),n()(),E(14,"td"),i(15,"td",24),r(16),x(17,"number"),n(),i(18,"td",24),r(19),x(20,"number"),n(),i(21,"td",24),r(22),x(23,"number"),n()()),t&2){let e=p.$implicit,a=p.rowIndex,o=d(4);l(),O(a===0&&o.store.items().data.length>1?1:-1),l(3),u(e.outletName),l(2),c("routerLink",F(19,qt,e.id)),l(),u(e.number),l(2),u(Ze(10,10,e.date,"dd MMM yyyy")),l(3),c("href",o.authService.getTenantExternalURL()+"/menu/Contacts/Contact/Customers/Info?ID="+e.contactID,$e),l(),u(e.contactName),l(3),D(" ",S(17,13,e.debitAmount)," "),l(3),D(" ",S(20,15,e.creditAmount)," "),l(3),u(S(23,17,e.balance))}}function Jt(t,p){if(t&1&&(i(0,"tr"),E(1,"td",27),i(2,"td",28),r(3,"Total"),n(),i(4,"td",28),r(5),x(6,"number"),n(),i(7,"td",28),r(8),x(9,"number"),n(),E(10,"td"),n()),t&2){let e=d().$index,a=d(3);l(5),D(" ",S(6,2,a.store.items().data[e].debitTotal)," "),l(3),D(" ",S(9,4,a.store.items().data[e].creditTotal)," ")}}function Qt(t,p){t&1&&(i(0,"tr")(1,"td",29)(2,"span"),r(3,"No records found."),n()()())}function Xt(t,p){if(t&1&&(i(0,"p-table",15),C(1,zt,7,2,"ng-template",null,3,s)(3,Ut,17,0,"ng-template",null,4,s)(5,$t,24,21,"ng-template",null,5,s)(7,Jt,11,6,"ng-template",null,6,s)(9,Qt,4,0,"ng-template",null,7,s),n()),t&2){let e=p.$implicit;c("value",e.data)("scrollable",!0)}}function Zt(t,p){if(t&1&&(i(0,"p-panel")(1,"p-scroll-panel"),Qe(2,Xt,11,2,"p-table",15,Je),n()()),t&2){let e=d(2);N(I(4,jt)),l(),N(I(5,Nt)),l(),Xe(e.store.items().data)}}function ei(t,p){if(t&1&&C(0,Zt,4,6,"p-panel",14),t&2){let e=d();c("ngIf",e.store.items()&&e.store.items().data.length)}}function ti(t,p){if(t&1&&(i(0,"div",11)(1,"div",16)(2,"span",45),r(3),n()(),i(4,"div")(5,"span"),r(6,"-"),n()(),i(7,"div",16)(8,"span",46),r(9),n()()()),t&2){let e=p.$implicit;l(3),D("(",e.code,")"),l(6),u(e.name)}}function ii(t,p){if(t&1&&(i(0,"div",11)(1,"div",16)(2,"span",45),r(3),n()(),i(4,"div")(5,"span"),r(6,"-"),n()(),i(7,"div",16)(8,"span",46),r(9),n()()()),t&2){let e=p.$implicit;l(3),D("(",e.code,")"),l(6),u(e.name)}}function ni(t,p){if(t&1&&(i(0,"div",47)(1,"div"),r(2),n()()),t&2){let e=p.$implicit;l(2),u(e.value)}}function oi(t,p){if(t&1){let e=L();i(0,"div",31)(1,"label",32),r(2,"Customer"),n(),i(3,"p-autocomplete",48),w("completeMethod",function(o){y(e);let m=d(2);return b(m.searchCustomer(o))}),n()()}if(t&2){let e=d(2);l(3),c("suggestions",e.customerSuggestions())}}function ri(t,p){if(t&1){let e=L();i(0,"div",31)(1,"label",32),r(2,"Supplier"),n(),i(3,"p-autocomplete",48),w("completeMethod",function(o){y(e);let m=d(2);return b(m.searchSupplier(o))}),n()()}if(t&2){let e=d(2);l(3),c("suggestions",e.supplierSuggestions())}}function ai(t,p){if(t&1){let e=L();i(0,"form",30)(1,"div",31)(2,"label",32),r(3,"Accounts"),n(),i(4,"p-multiselect",33),w("onChange",function(o){y(e);let m=d();return b(m.onAccountChange(o))}),C(5,ti,10,2,"ng-template",null,8,s)(7,ii,10,2,"ng-template",null,9,s),n()(),i(9,"div",31)(10,"label",32),r(11,"From"),n(),E(12,"p-datepicker",34),n(),i(13,"div",31)(14,"label",32),r(15,"To"),n(),E(16,"p-datepicker",35),n(),i(17,"div",31)(18,"label",32),r(19,"Outlets"),n(),i(20,"p-multiselect",36),C(21,ni,3,1,"ng-template",null,9,s),n()(),i(23,"div",31)(24,"label",32),r(25,"Category"),n(),i(26,"p-treeselect",37),w("onFocus",function(){y(e);let o=d();return b(o.onCategoryFocus())}),n()(),i(27,"div",31)(28,"label",38),r(29,"Contact Type"),n(),i(30,"div",39)(31,"div",40),E(32,"p-radiobutton",41),i(33,"label",42),r(34,"Customer"),n()(),i(35,"div",40),E(36,"p-radiobutton",43),i(37,"label",44),r(38,"Supplier"),n()()()(),C(39,oi,4,1,"div",31)(40,ri,4,1,"div",31),n()}if(t&2){let e=d();c("formGroup",e.generalLedgerFilterForm),l(4),c("virtualScroll",!0)("virtualScrollItemSize",50)("maxlength",5)("options",e.store.metadata().options.accounts)("ngClass",F(20,Ht,e.generalLedgerFilterForm.get("listAccountID").invalid&&e.generalLedgerFilterForm.get("listAccountID").touched||e.generalLedgerFilterForm.get("listAccountID").dirty)),l(8),c("iconDisplay","input")("showIcon",!0),l(4),c("iconDisplay","input")("showIcon",!0),l(4),c("virtualScroll",!0)("virtualScrollItemSize",50)("options",e.store.metadata().options.outlets),l(6),c("virtualScroll",!0)("virtualScrollItemSize",50)("virtualScrollOptions",I(22,Yt))("options",e.categoriesOptions()),l(6),c("value",0),l(4),c("value",1),l(3),O(e.generalLedgerFilterForm.get("contactType").value?40:39)}}var Rt=function(t){return t[t.Customer=0]="Customer",t[t.Supplier=1]="Supplier",t}(Rt||{}),Tt=(()=>{class t{constructor(){this.dialogFilterVisible=T(!1),this.reportService=h(B),this.coaService=h(ft),this.authService=h(Fe),this.store=h(Me),this.categoriesOptions=T([]),this.customerSuggestions=T([]),this.supplierSuggestions=T([]),this.route=h(ot),this.dayjsService=h(ye),this.initDialogVisible=T(!0),this.fb=h(we),this.toastr=h(rt)}ngOnInit(){this.generateFilterForm(),this.route.queryParamMap.pipe(We(e=>e.get("id")),k(e=>{e&&(this.initDialogVisible.update(a=>!a),this.generalLedgerFilterForm.patchValue({listAccountID:[e]}),this.store.updateFilter(v(g({},this.store.filter()),{listAccountID:[e]})))})).subscribe(),this.clearContactValueOnContactTypeChange()}clearContactValueOnContactTypeChange(){this.generalLedgerFilterForm.get("contactType")?.valueChanges.subscribe(()=>this.generalLedgerFilterForm.get("ContactID")?.setValue(""))}onAccountChange(e){console.log("Account Change Event:",e),Array.isArray(e.value)&&e.value.length>5&&this.toastr.warning("Please select at least 5 accounts for the general ledger report.","Warning")}onCategoryFocus(){this.coaService.getCachedCategoriesOptions().pipe(A("getCachedCategoriesOptions"),k(e=>this.categoriesOptions.set(e))).subscribe()}generateFilterForm(){this.generalLedgerFilterForm=this.fb.group({listAccountID:new G([],[lt.required]),categoryID:new G(null),OutletID:new G([]),ContactID:new G(""),from:new G(null),to:new G(null),contactType:[Rt.Customer]})}onFilterEvent(e){console.log(e),this.dialogFilterVisible.update(a=>!a)}onFilterOKEvent(){let f=this.generalLedgerFilterForm.value,{from:e,to:a}=f,o=Ve(f,["from","to"]);if(this.generalLedgerFilterForm.invalid){this.generalLedgerFilterForm.markAllAsTouched(),this.dialogFilterVisible.set(!0);return}let m={categoryID:o.categoryID?.key??null,ContactID:o.ContactID.length?o.ContactID:null,OutletID:o.OutletID.length?o.OutletID:null,listAccountID:o.listAccountID,from:this.dayjsService.from(e)?this.dayjsService.from(e).format():null,to:this.dayjsService.from(a)?this.dayjsService.from(a).format():null};this.dialogFilterVisible.update(_=>!_),this.store.updateFilter(m),this.dialogFilterVisible.set(!1)}searchCustomer(e){this.reportService.getCustomerSuggestions(e.query).pipe(k(a=>this.customerSuggestions.set(a))).subscribe()}searchSupplier(e){this.reportService.getSupplierSuggestions(e.query).pipe(k(a=>this.supplierSuggestions.set(a))).subscribe()}onExport(){let f=this.generalLedgerFilterForm.value,{from:e,to:a}=f,o=Ve(f,["from","to"]),m={categoryID:o.categoryID?.key??null,ContactID:o.ContactID.length?o.ContactID:null,OutletID:o.OutletID.length?o.OutletID:null,listAccountID:o.listAccountID,from:this.dayjsService.from(e)?this.dayjsService.from(e).format():null,to:this.dayjsService.from(a)?this.dayjsService.from(a).format():null};this.reportService.exportGeneralLedger(m).pipe(A("exportGeneralLedger"),k(_=>{St(_,`general-ledger-${this.dayjsService.now.format("D-MM-YYYY")}.${_.type.split("/")[1]}`,_.type)})).subscribe()}static{this.\u0275fac=function(a){return new(a||t)}}static{this.\u0275cmp=M({type:t,selectors:[["app-report-general-ledger"]],features:[U([Me])],decls:7,vars:4,consts:[["actionButton",""],["content",""],["filters",""],["caption",""],["header",""],["body",""],["footer",""],["emptymessage",""],["selectedItem",""],["item",""],[3,"isDialogFilterVisibleChange","isInitDialogFilterVisibleChange","filterConfirmed","pageTitle","isDialogFilterVisible","isFilterable","isInitDialogFilterVisible"],[1,"d-flex","gap-2"],["routerLink","/pages/chart-of-account/account",1,"p-button","p-button-secondary","p-button-outlined","fs-3"],["severity","secondary","variant","outlined","icon","fa-solid fa-download","label","Export",3,"onClick"],[3,"style",4,"ngIf"],["scrollHeight","calc(100vh - 150px)",3,"value","scrollable"],[1,""],[1,"fs-5","fw-semibold"],[2,"width","10%"],[1,"text-end",2,"width","10%"],[1,"text-end",2,"width","20%"],[1,"text-break"],["target","_blank",1,"link","link-primary",3,"routerLink"],["target","_blank",1,"link","link-primary",3,"href"],[1,"text-end","text-break"],["colspan","7",1,"text-end"],[1,"text-end"],["colspan","4"],[1,"text-end","fw-semibold"],["colspan","8"],[1,"d-flex","flex-column","row-gap-3",3,"formGroup"],[1,"d-flex","flex-column"],["for","outlet"],["showClear","","filter","","filterBy","code,name","display","chip","formControlName","listAccountID","appendTo","body","optionLabel","name","optionValue","id","placeholder","Select Accounts",3,"onChange","virtualScroll","virtualScrollItemSize","maxlength","options","ngClass"],["showClear","","formControlName","from","styleClass","w-100","appendTo","body","inputId","icondisplay",3,"iconDisplay","showIcon"],["showClear","","formControlName","to","styleClass","w-100","appendTo","body","inputId","icondisplay",3,"iconDisplay","showIcon"],["showClear","","display","chip","formControlName","OutletID","appendTo","body","optionLabel","value","optionValue","key","placeholder","Select Outlets",3,"virtualScroll","virtualScrollItemSize","options"],["showClear","","filter","","filterBy","label","formControlName","categoryID","appendTo","body","containerStyleClass","w-100","optionLabel","label","optionValue","id","placeholder","Select Category",3,"onFocus","virtualScroll","virtualScrollItemSize","virtualScrollOptions","options"],["for",""],[1,"d-flex","gap-3"],[1,"d-flex","align-items-center","gap-2"],["name","contactType","formControlName","contactType","inputId","customer",3,"value"],["for","customer",1,"m-0"],["name","contactType","formControlName","contactType","inputId","supplier",3,"value"],["for","supplier",1,"m-0"],[1,"h-full","align-middle"],[1,"text-truncate","d-inline-block","h-full","align-middle"],[1,"flex","items-center","gap-2"],["formControlName","ContactID","appendTo","body","styleClass","w-100","optionLabel","Value","optionValue","Key","inputStyleClass","w-100",3,"completeMethod","suggestions"]],template:function(a,o){if(a&1){let m=L();i(0,"app-main-panel",10),z("isDialogFilterVisibleChange",function(_){return y(m),q(o.dialogFilterVisible,_)||(o.dialogFilterVisible=_),b(_)})("isInitDialogFilterVisibleChange",function(_){return y(m),q(o.initDialogVisible,_)||(o.initDialogVisible=_),b(_)}),w("filterConfirmed",function(){return y(m),b(o.onFilterOKEvent())}),C(1,Wt,4,0,"ng-template",null,0,s)(3,ei,1,1,"ng-template",null,1,s)(5,ai,41,23,"ng-template",null,2,s),n()}a&2&&(c("pageTitle",o.store.items().pageTitle.length?o.store.items().pageTitle:"General Ledger"),W("isDialogFilterVisible",o.dialogFilterVisible),c("isFilterable",!0),W("isInitDialogFilterVisible",o.initDialogVisible))},dependencies:[_e,$,tt,Ie,K,it,fe,Se,xe,dt,ae,re,Re,he,ge,Le,Te,ne,ee,X,Z,mt,te,ie,ve,Ce,De,oe,ct,xt,ht,gt,pe,le,Q,J,_t,ut],styles:["[_nghost-%COMP%] .p-datatable .p-datatable-header{padding:.75rem 1rem .75rem 0}"],changeDetection:0})}}return t})();var li={data:{},filter:{EntityID:[],CashierID:null,Text:null,from:null,to:null},isLoading:!0,loader:{options:{outlets:[]},filter:{from:"",to:"",outletID:[]},roles:{isInRoleEmptyOutlet:!1}}},Be=me(ue(li),ce(t=>{let p={totalCOGS:R(()=>{let e=t.data()?.data?.cogs;return Array.isArray(e)?e.reduce((a,o)=>a+(o?.amount??0),0):0}),totalRevenue:R(()=>{let e=t.data()?.data?.revenue;return Array.isArray(e)?e.reduce((a,o)=>a+(o?.amount??0),0):0}),totalExpense:R(()=>{let e=t.data()?.data?.expense;return Array.isArray(e)?e.reduce((a,o)=>a+(o?.amount??0),0):0}),grossProfit:R(()=>Array.isArray(t.data()?.data?.cogs)&&Array.isArray(t.data()?.data?.revenue)?p.totalRevenue()-p.totalCOGS():0),profitOrLoss:R(()=>p.totalRevenue()-p.totalCOGS()-p.totalExpense()),isDataEmpty:R(()=>Object.keys(t.data()?.data??{}).length===0)};return p}),de(t=>{let p=h(B),e=h(ye),a={updateFilter(o){V(t,m=>v(g({},m),{filter:g(g({},m.filter),o)}))},getLoader:H(P(j(()=>p.getIncomeStatementLoader().pipe(Y({next:o=>{V(t,m=>v(g({},m),{loader:o,filter:v(g({},m.filter),{from:e.from(o.filter.from).format(),to:e.from(o.filter.to).format()})})),a.getIncomeStatement(t.filter)},error:o=>{console.error(o)}}))))),getIncomeStatement:H(P(j(o=>p.getIncomeStatement(o).pipe(Ue(()=>V(t,m=>v(g({},m),{isLoading:!0}))),Y({next:m=>{V(t,f=>v(g({},f),{data:m,isLoading:!1}))},error:m=>{console.error(m)}})))))};return a}),se({onInit:t=>{t.getLoader()}}));var pi=()=>({height:"calc(100vh - 70px)"}),mi=()=>({height:"calc(100vh - 150px)"}),ke=()=>({}),Oe=t=>["/pages/chart-of-account/account/",t],Ge=()=>["/pages/report/general-ledger"],Ae=t=>({id:t});function ci(t,p){if(t&1){let e=L();i(0,"div",8)(1,"p-button",9),w("onClick",function(){y(e);let o=d();return b(o.onExport())}),n()()}}function si(t,p){t&1&&(i(0,"tr")(1,"th",14),r(2,"Code"),n(),i(3,"th",15),r(4,"Name"),n(),i(5,"th",16),r(6,"Total"),n()())}function di(t,p){if(t&1&&(i(0,"tr")(1,"td"),r(2),n(),i(3,"td")(4,"a",17),r(5),n()(),i(6,"td",16)(7,"a",18),r(8),x(9,"number"),n()()()),t&2){let e=p.$implicit;l(2),u(e.code),l(2),c("routerLink",F(8,Oe,e.accountID)),l(),u(e.name),l(2),c("routerLink",I(10,Ge))("queryParams",F(11,Ae,e.accountID)),l(),u(S(9,6,e.amount))}}function ui(t,p){if(t&1&&(i(0,"tr"),E(1,"td",19),i(2,"td",20)(3,"div",21)(4,"span",22),r(5,"Total Revenue :"),n(),i(6,"span",23),r(7),x(8,"number"),n()()()()),t&2){let e=d(4);l(7),u(S(8,1,e.store.totalRevenue()))}}function _i(t,p){t&1&&(i(0,"tr")(1,"td",24)(2,"span"),r(3,"No revenue records available"),n()()())}function fi(t,p){if(t&1&&(i(0,"h6",12),r(1,"Revenue"),n(),i(2,"p-table",13),C(3,si,7,0,"ng-template",null,3,s)(5,di,10,13,"ng-template",null,4,s)(7,ui,9,3,"ng-template",null,5,s)(9,_i,4,0,"ng-template",null,6,s),n()),t&2){let e,a=d(3);l(2),c("value",(e=a.store.data())==null||e.data==null?null:e.data.revenue)}}function gi(t,p){t&1&&(i(0,"tr")(1,"th",14),r(2,"Code"),n(),i(3,"th",15),r(4,"Name"),n(),i(5,"th",25),r(6,"Total"),n()())}function hi(t,p){if(t&1&&(i(0,"tr")(1,"td"),r(2),n(),i(3,"td")(4,"a",17),r(5),n()(),i(6,"td",16)(7,"a",18),r(8),x(9,"number"),n()()()),t&2){let e=p.$implicit;l(2),u(e.code),l(2),c("routerLink",F(8,Oe,e.accountID)),l(),u(e.name),l(2),c("routerLink",I(10,Ge))("queryParams",F(11,Ae,e.AccountID)),l(),u(S(9,6,e.amount))}}function xi(t,p){if(t&1&&(i(0,"tr"),E(1,"td",26),i(2,"td",20)(3,"div",21)(4,"span",22),r(5,"Total COGS :"),n(),i(6,"span",23),r(7),x(8,"number"),n()()()(),i(9,"tr"),E(10,"td",26),i(11,"td",20)(12,"div",21)(13,"span",22),r(14,"Gross Profit :"),n(),i(15,"span",23),r(16),x(17,"number"),n()()()()),t&2){let e=d(4);l(7),u(S(8,2,e.store.totalCOGS())),l(9),u(S(17,4,e.store.grossProfit()))}}function Si(t,p){t&1&&(i(0,"tr")(1,"td",24)(2,"span"),r(3,"No COGS records available"),n()()())}function Ci(t,p){if(t&1&&(i(0,"h4",12),r(1,"COGS"),n(),i(2,"p-table",13),C(3,gi,7,0,"ng-template",null,3,s)(5,hi,10,13,"ng-template",null,4,s)(7,xi,18,6,"ng-template",null,5,s)(9,Si,4,0,"ng-template",null,6,s),n()),t&2){let e,a=d(3);l(2),c("value",(e=a.store.data())==null||e.data==null?null:e.data.cogs)}}function vi(t,p){t&1&&(i(0,"tr")(1,"th",14),r(2,"Code"),n(),i(3,"th",15),r(4,"Name"),n(),i(5,"th",16),r(6,"Total"),n()())}function yi(t,p){if(t&1&&(i(0,"tr")(1,"td"),r(2),n(),i(3,"td")(4,"a",17),r(5),n()(),i(6,"td",16)(7,"a",18),r(8),x(9,"number"),n()()()),t&2){let e=p.$implicit;l(2),u(e.code),l(2),c("routerLink",F(8,Oe,e.accountID)),l(),u(e.name),l(2),c("routerLink",I(10,Ge))("queryParams",F(11,Ae,e.AccountID)),l(),u(S(9,6,e.amount))}}function bi(t,p){if(t&1&&(i(0,"tr"),E(1,"td",26),i(2,"td",20)(3,"div",21)(4,"span",22),r(5,"Total Expense :"),n(),i(6,"span",23),r(7),x(8,"number"),n()()()(),i(9,"tr"),E(10,"td",26),i(11,"td",20)(12,"div",21)(13,"span",22),r(14,"Profit / Loss :"),n(),i(15,"span",23),r(16),x(17,"number"),n()()()()),t&2){let e=d(4);l(7),u(S(8,2,e.store.totalExpense())),l(9),u(S(17,4,e.store.profitOrLoss()))}}function Ei(t,p){t&1&&(i(0,"tr")(1,"td",24)(2,"span"),r(3,"No expense records available"),n()()())}function Ii(t,p){if(t&1&&(i(0,"h4",12),r(1,"Expense"),n(),i(2,"p-table",13),C(3,vi,7,0,"ng-template",null,3,s)(5,yi,10,13,"ng-template",null,4,s)(7,bi,18,6,"ng-template",null,5,s)(9,Ei,4,0,"ng-template",null,6,s),n()),t&2){let e,a=d(3);l(2),c("value",(e=a.store.data())==null||e.data==null?null:e.data.expense)}}function Fi(t,p){if(t&1&&(i(0,"p-scroll-panel")(1,"div",11),C(2,fi,11,1)(3,Ci,11,1)(4,Ii,11,1),n()()),t&2){let e,a,o,m=d(2);N(I(5,mi)),l(2),O(m.Object.keys((e=m.store.data().data)!==null&&e!==void 0?e:I(6,ke)).length>0?2:-1),l(),O(m.Object.keys((a=(a=m.store.data().data)==null?null:a.cogs)!==null&&a!==void 0?a:I(7,ke)).length>0?3:-1),l(),O(m.Object.keys((o=(o=m.store.data().data)==null?null:o.expense)!==null&&o!==void 0?o:I(8,ke)).length>0?4:-1)}}function wi(t,p){if(t&1&&(i(0,"p-panel"),C(1,Fi,5,9,"p-scroll-panel",10),n()),t&2){let e=d();N(I(3,pi)),l(),c("ngIf",e.store.data())}}function Di(t,p){if(t&1){let e=L();i(0,"form",27)(1,"div",28)(2,"label",29),r(3,"Outlet"),n(),E(4,"p-multiselect",30),n(),i(5,"div",28)(6,"label",29),r(7,"Cashier"),n(),i(8,"p-autocomplete",31),w("completeMethod",function(o){y(e);let m=d();return b(m.onCashierSearch(o))})("onSelect",function(o){y(e);let m=d();return b(m.onCashierSelect(o))}),n()(),i(9,"div",28)(10,"label",29),r(11,"From"),n(),E(12,"p-datepicker",32),n(),i(13,"div",28)(14,"label",29),r(15,"To"),n(),E(16,"p-datepicker",33),n()()}if(t&2){let e=d();c("formGroup",e.formFilter),l(4),c("virtualScroll",!0)("virtualScrollItemSize",50)("options",e.store.loader().options.outlets)("showClear",!0),l(4),c("showClear",!0)("suggestions",e.cashierSuggestions())("showClear",!0)}}var Lt=(()=>{class t{constructor(){this.dayjsService=h(ye),this.store=h(Be),this.fb=h(we),this.reportService=h(B),this.isInitDialogFilterVisible=T(!1),this.dialogFilterVisible=T(!1),this.cashierSuggestions=T([]),this.cashierHashMap=new Map,this.Object=Object,et(()=>{this.store.filter()&&this.initForm()})}ngOnInit(){this.initForm(),console.log(this.cashierHashMap.entries())}onSearch(e){this.store.updateFilter(v(g({},this.store.filter()),{Text:e}))}onCashierSearch(e){this.reportService.getCashierSuggestions(e.query).pipe(A("Cashier Suggestions"),k(a=>this.cashierSuggestions.set(a))).subscribe()}initForm(){let e=this.store.filter();console.log("initForm",this.cashierHashMap.get(e.CashierID)),this.formFilter=this.fb.group({EntityID:this.fb.control(e.EntityID??[]),CashierID:this.fb.control(this.cashierHashMap.get(e.CashierID)??""),Text:this.fb.control(e.Text??""),from:this.fb.control(e.from?this.dayjsService.from(e.from).toDate():null),to:this.fb.control(e.to?this.dayjsService.from(e.to).toDate():null)})}onFilterOK(){let e=this.formFilter.getRawValue(),a=Object.entries(e).reduce((o,[m,f])=>(m==="from"||m==="to"?f instanceof Date&&(o[m]=this.dayjsService.from(f).format()):o[m]=f||null,o),{});this.store.updateFilter(g(g({},this.store.filter()),a)),this.dialogFilterVisible.update(o=>!o),console.log("body",e)}onCashierSelect(e){console.log("Cashier selected:",e),!this.cashierHashMap.has(e.value.Key)&&(this.cashierHashMap.set(e.value.Key,e.value.Value),console.log("Cashier HashMap:",this.cashierHashMap))}onExport(){let e=v(g({},this.store.filter()),{export:!0,ExportPageNumber:1,ExportRowCount:1e4});this.reportService.getIncomeStatement(e,{responseType:"blob"}).pipe(A("Export Profit & Loss"),k(a=>{let o=a.type,m=[a],f=document.createElement("a");f.href=window.URL.createObjectURL(new Blob(m,{type:o}));let _=`profit-and-loss.${o.split("/")[1]}`;f.setAttribute("download",_),document.body.appendChild(f),f.click(),document.body.removeChild(f)})).subscribe()}static{this.\u0275fac=function(a){return new(a||t)}}static{this.\u0275cmp=M({type:t,selectors:[["app-report-income-statement"]],features:[U([Be])],decls:7,vars:4,consts:[["actionButton",""],["content",""],["filters",""],["header",""],["body",""],["footer",""],["emptymessage",""],[3,"isDialogFilterVisibleChange","isInitDialogFilterVisibleChange","filterConfirmed","isFilterable","pageTitle","isDialogFilterVisible","isInitDialogFilterVisible"],[1,"d-flex","gap-2"],["severity","secondary","variant","outlined","icon","fa-solid fa-download","label","Export",3,"onClick"],[3,"style",4,"ngIf"],[1,"d-flex","flex-column","gap-3"],[1,"fs-5","fw-semibold"],[3,"value"],[2,"width","20%"],[2,"width","30%"],[1,"text-end"],["target","_blank",1,"link","link-primary",3,"routerLink"],["target","_blank",1,"link","link-primary",3,"routerLink","queryParams"],["colspan","2 ",1,"fw-semibold","text-end",2,"width","50%"],[1,"text-end","fw-semibold"],[1,"row"],[1,"col-9"],[1,"col"],["colspan","3",1,""],[1,"text-end",2,"min-width","10%"],["colspan","2",1,"fw-semibold"],[1,"d-flex","flex-column","gap-3",3,"formGroup"],[1,"d-flex","flex-column"],["for",""],["formControlName","EntityID","filterBy","value","appendTo","body","display","chip","optionLabel","value","optionValue","key","placeholder","Select an Outlet",3,"virtualScroll","virtualScrollItemSize","options","showClear"],["appendTo","body","formControlName","CashierID","optionLabel","Value","optionValue","Key","styleClass","w-100","inputStyleClass","w-100","field","Value","placeholder","Search a cashier",3,"completeMethod","onSelect","showClear","suggestions"],["formControlName","from","styleClass","w-100","appendTo","body"],["formControlName","to","styleClass","w-100","appendTo","body"]],template:function(a,o){if(a&1){let m=L();i(0,"app-main-panel",7),z("isDialogFilterVisibleChange",function(_){return y(m),q(o.dialogFilterVisible,_)||(o.dialogFilterVisible=_),b(_)})("isInitDialogFilterVisibleChange",function(_){return y(m),q(o.isInitDialogFilterVisible,_)||(o.isInitDialogFilterVisible=_),b(_)}),w("filterConfirmed",function(){return y(m),b(o.onFilterOK())}),C(1,ci,2,0,"ng-template",null,0,s)(3,wi,2,4,"ng-template",null,1,s)(5,Di,17,8,"ng-template",null,2,s),n()}a&2&&(c("isFilterable",!0)("pageTitle",o.store.data().pageTitle),W("isDialogFilterVisible",o.dialogFilterVisible)("isInitDialogFilterVisible",o.isInitDialogFilterVisible))},dependencies:[_e,$,Ie,K,Re,he,ge,ne,ee,X,Z,te,ie,ve,Ce,fe,Se,xe,pe,le,oe,Q,J,Le,Te,ae,re],styles:["[_nghost-%COMP%]{display:block}"],changeDetection:0})}}return t})();var Pe=Ye(Ct());var Ri={metadata:{options:{outlets:[]},filter:{to:"",outletID:[]},roles:{isInRoleEmptyOutlet:!1}},data:{asset:[],liability:[],equity:[],pageTitle:""},filter:{date:(0,Pe.default)().format("YYYY-MM-DD"),listOutletParam:[]}},je=me(ue(Ri),ce(t=>({totalAsset:R(()=>t.data().asset.reduce((p,e)=>p+ +e.amount,0)),totalLiability:R(()=>t.data().liability.reduce((p,e)=>p+ +e.counterAmount,0)),totalEquity:R(()=>t.data().equity.reduce((p,e)=>p+ +e.counterAmount,0))})),de(t=>{let p=h(B),e={updateFilter:a=>{V(t,o=>v(g({},o),{filter:a}))},fetchBalanceSheet:H(P(Ee(()=>{let a=t.filter();return Object.entries(a).every(([o,m])=>m!=null&&m!=="")}),j(a=>p.getBalanceSheet(a).pipe(Y({next:o=>{V(t,m=>v(g({},m),{data:o}))},error:o=>{console.error(o)}}))),ze(1))),fetchLoader:H(P(j(()=>p.getBalanceSheetLoader().pipe(Y({next:a=>{V(t,o=>v(g({},o),{metadata:a,filter:{date:(0,Pe.default)(a.filter.to).format("YYYY-MM-DD")}})),e.fetchBalanceSheet(t.filter)},error:a=>{console.error(a)}})))))};return e}),se(t=>({onInit:()=>{t.fetchLoader()}})));var Vt=Ye(Ct());var Ti=()=>({height:"calc(100vh - 70px)"}),Li=()=>({height:"calc(100vh - 100px)"}),Ne=t=>["/pages/chart-of-account/account/",t],qe=()=>["/pages/report/general-ledger"],He=t=>({id:t});function Vi(t,p){if(t&1){let e=L();i(0,"div",9)(1,"p-button",10),w("onClick",function(){y(e);let o=d();return b(o.onExport())}),n()()}}function Mi(t,p){t&1&&(i(0,"tr")(1,"th",15),r(2,"Code"),n(),i(3,"th"),r(4,"Asset"),n(),i(5,"th",16),r(6,"Total"),n()())}function Bi(t,p){if(t&1&&(i(0,"tr")(1,"td"),r(2),n(),i(3,"td")(4,"a",17),r(5),n()(),i(6,"td",18)(7,"a",19),r(8),x(9,"number"),n()()()),t&2){let e=p.$implicit;l(2),u(e.code),l(2),c("routerLink",F(8,Ne,e.accountID)),l(),u(e.name),l(2),c("routerLink",I(10,qe))("queryParams",F(11,He,e.accountID)),l(),u(S(9,6,e.amount))}}function ki(t,p){if(t&1&&(i(0,"tr")(1,"td",20),r(2,"Total Asset"),n(),i(3,"td",21),r(4),x(5,"number"),n()()),t&2){let e=d(3);l(4),D(" ",S(5,1,e.store.totalAsset())," ")}}function Oi(t,p){t&1&&(i(0,"tr")(1,"td",22)(2,"span"),r(3,"No asset records found."),n()()())}function Gi(t,p){if(t&1&&(i(0,"h4",13),r(1,"Asset"),n(),i(2,"p-table",14),C(3,Mi,7,0,"ng-template",null,3,s)(5,Bi,10,13,"ng-template",null,4,s)(7,ki,6,3,"ng-template",null,5,s)(9,Oi,4,0,"ng-template",null,6,s),n()),t&2){let e=d(2);l(2),c("value",e.store.data().asset)}}function Ai(t,p){t&1&&(i(0,"tr")(1,"th",15),r(2,"Code"),n(),i(3,"th"),r(4,"Liability"),n(),i(5,"th",16),r(6,"Total"),n()())}function Pi(t,p){if(t&1&&(i(0,"tr")(1,"td"),r(2),n(),i(3,"td")(4,"a",24),r(5),n()(),i(6,"td",18)(7,"a",19),r(8),x(9,"number"),n()()()),t&2){let e=p.$implicit;l(2),u(e.code),l(2),c("routerLink",F(8,Ne,e.accountID)),l(),u(e.name),l(2),c("routerLink",I(10,qe))("queryParams",F(11,He,e.accountID)),l(),u(S(9,6,e.counterAmount))}}function ji(t,p){if(t&1&&(i(0,"tr")(1,"td",20),r(2," Total Liability "),n(),i(3,"td",21),r(4),x(5,"number"),n()()),t&2){let e=d(3);l(4),D(" ",S(5,1,e.store.totalLiability())," ")}}function Ni(t,p){t&1&&(i(0,"tr")(1,"td",22)(2,"span"),r(3,"No liability records found."),n()()())}function qi(t,p){if(t&1&&(i(0,"h4",23),r(1,"Liability"),n(),i(2,"p-table",14),C(3,Ai,7,0,"ng-template",null,3,s)(5,Pi,10,13,"ng-template",null,4,s)(7,ji,6,3,"ng-template",null,5,s)(9,Ni,4,0,"ng-template",null,6,s),n()),t&2){let e=d(2);l(2),c("value",e.store.data().liability)}}function Hi(t,p){t&1&&(i(0,"tr")(1,"th",15),r(2,"Code"),n(),i(3,"th"),r(4,"Equity"),n(),i(5,"th",16),r(6,"Total"),n()())}function Yi(t,p){if(t&1&&(i(0,"tr")(1,"td"),r(2),n(),i(3,"td")(4,"a",17),r(5),n()(),i(6,"td",18)(7,"a",19),r(8),x(9,"number"),n()()()),t&2){let e=p.$implicit;l(2),u(e.code),l(2),c("routerLink",F(8,Ne,e.accountID)),l(),u(e.name),l(2),c("routerLink",I(10,qe))("queryParams",F(11,He,e.accountID)),l(),u(S(9,6,e.counterAmount))}}function Wi(t,p){if(t&1&&(i(0,"tr")(1,"td",20),r(2,"Total Equity"),n(),i(3,"td",21),r(4),x(5,"number"),n()(),i(6,"tr")(7,"td",20),r(8," Total Liability + Equity "),n(),i(9,"td",21),r(10),x(11,"number"),n()()),t&2){let e=d(3);l(4),D(" ",S(5,2,e.store.totalEquity())," "),l(6),D(" ",S(11,4,e.store.totalLiability()+e.store.totalEquity())," ")}}function zi(t,p){t&1&&(i(0,"tr")(1,"td",22)(2,"span"),r(3,"No equity records found."),n()()())}function Ui(t,p){if(t&1&&(i(0,"h4",23),r(1,"Equity"),n(),i(2,"p-table",14),C(3,Hi,7,0,"ng-template",null,3,s)(5,Yi,10,13,"ng-template",null,4,s),r(7," <"),C(8,Wi,12,6,"ng-template",null,5,s)(10,zi,4,0,"ng-template",null,6,s),n()),t&2){let e=d(2);l(2),c("value",e.store.data().equity)}}function Ki(t,p){if(t&1&&(i(0,"p-panel",11)(1,"p-scroll-panel")(2,"div",12),C(3,Gi,11,1)(4,qi,11,1)(5,Ui,12,1),n()()()),t&2){let e=d();N(I(8,Ti)),c("showHeader",!1),l(),N(I(9,Li)),l(2),O(e.Object.keys(e.store.data().asset).length>0?3:-1),l(),O(e.Object.keys(e.store.data().liability).length>0?4:-1),l(),O(e.Object.keys(e.store.data().equity).length>0?5:-1)}}function $i(t,p){if(t&1&&(i(0,"div",30)(1,"div"),r(2),n()()),t&2){let e=p.$implicit;l(2),u(e.value)}}function Ji(t,p){if(t&1&&(i(0,"form",25)(1,"div",26)(2,"label",27),r(3,"Outlet"),n(),i(4,"p-multiselect",28),C(5,$i,3,1,"ng-template",null,7,s),n()(),i(7,"div",26)(8,"label",27),r(9,"From"),n(),E(10,"p-datepicker",29),n()()),t&2){let e=d();c("formGroup",e.filterForm),l(4),c("virtualScroll",!0)("virtualScrollItemSize",50)("options",e.store.metadata().options.outlets)("showClear",!0),l(6),c("iconDisplay","input")("showIcon",!0)}}var Mt=(()=>{class t{constructor(){this.store=h(je),this.ReportServiceStore=h(B),this.dialogFilterVisible=T(!1),this.isInitDialogFilterVisible=T(!1),this.Object=Object}ngOnInit(){this.generateFilterForm()}generateFilterForm(){this.filterForm=new pt({date:new G(new Date),outletID:new G([])})}onFilterOKEvent(){let{date:e,outletID:a}=this.filterForm.value;this.store.updateFilter({date:(0,Vt.default)(e).format("YYYY-MM-DD"),listOutletParam:a}),this.dialogFilterVisible.update(o=>!o)}onExport(){let e=v(g({},this.store.filter()),{export:!0,ExportPageNumber:1,ExportRowCount:1e4});this.ReportServiceStore.getBalanceSheet(e,{responseType:"blob"}).pipe(A("Export Balance Sheet"),k(a=>{let o=a.type,m=[a],f=document.createElement("a");f.href=window.URL.createObjectURL(new Blob(m,{type:o}));let _=`balance-sheet.${o.split("/")[1]}`;f.setAttribute("download",_),document.body.appendChild(f),f.click(),document.body.removeChild(f)})).subscribe()}static{this.\u0275fac=function(a){return new(a||t)}}static{this.\u0275cmp=M({type:t,selectors:[["app-report-balance-sheet"]],features:[U([je])],decls:7,vars:4,consts:[["actionButton",""],["content",""],["filters",""],["header",""],["body",""],["footer",""],["emptymessage",""],["item",""],[3,"isDialogFilterVisibleChange","isInitDialogFilterVisibleChange","filterConfirmed","pageTitle","isFilterable","isDialogFilterVisible","isInitDialogFilterVisible"],[1,"d-flex","gap-2"],["severity","secondary","variant","outlined","icon","fa-solid fa-download","label","Export",3,"onClick"],[3,"showHeader"],[1,"d-flex","flex-column","gap-3"],[1,"fs-5","fw-semibold","mt-3"],[3,"value"],[2,"width","20%"],[1,"text-end",2,"width","5%"],["target","_blank",1,"link","link-primary",3,"routerLink"],[1,"text-end"],["target","_blank",1,"link","link-primary",3,"routerLink","queryParams"],["colspan","2",1,"fw-semibold","text-end"],[1,"text-end","fw-semibold"],["colspan","3",1,""],[1,"fs-5","fw-semibold"],["target","_blank",1,"link","link-primary","d-flex","align-items-center",3,"routerLink"],[1,"d-flex","flex-column","row-gap-3",3,"formGroup"],[1,"d-flex","flex-column"],["for","outlet"],["formControlName","outletID","display","chip","appendTo","body","optionLabel","value","optionValue","key","placeholder","Select Outlet",3,"virtualScroll","virtualScrollItemSize","options","showClear"],["formControlName","date","styleClass","w-100","appendTo","body","inputId","icondisplay",3,"iconDisplay","showIcon"],[1,"flex","items-center","gap-2"]],template:function(a,o){if(a&1){let m=L();i(0,"app-main-panel",8),z("isDialogFilterVisibleChange",function(_){return y(m),q(o.dialogFilterVisible,_)||(o.dialogFilterVisible=_),b(_)})("isInitDialogFilterVisibleChange",function(_){return y(m),q(o.isInitDialogFilterVisible,_)||(o.isInitDialogFilterVisible=_),b(_)}),w("filterConfirmed",function(){return y(m),b(o.onFilterOKEvent())}),C(1,Vi,2,0,"ng-template",null,0,s)(3,Ki,6,10,"ng-template",null,1,s)(5,Ji,11,7,"ng-template",null,2,s),n()}a&2&&(c("pageTitle",o.store.data().pageTitle)("isFilterable",!0),W("isDialogFilterVisible",o.dialogFilterVisible)("isInitDialogFilterVisible",o.isInitDialogFilterVisible))},dependencies:[_e,$,K,Se,xe,fe,ae,re,ne,ee,X,Z,te,ie,ve,Ce,he,ge,De,oe,pe,le,Q,J],styles:["[_nghost-%COMP%]{display:block}"],changeDetection:0})}}return t})();var Bt=(()=>{class t{static{this.\u0275fac=function(a){return new(a||t)}}static{this.\u0275cmp=M({type:t,selectors:[["app-report-comparative-balance"]],decls:3,vars:0,template:function(a,o){a&1&&(i(0,"p"),r(1,"report-comparative-balance works!"),n(),r(2,`
|
|
2
|
+
,
|
|
3
|
+
`))},styles:["[_nghost-%COMP%]{display:block}"],changeDetection:0})}}return t})();var kt=(()=>{class t{static{this.\u0275fac=function(a){return new(a||t)}}static{this.\u0275cmp=M({type:t,selectors:[["app-report-cash-flow"]],decls:3,vars:0,template:function(a,o){a&1&&(i(0,"p"),r(1,"report-cash-flow works!"),n(),r(2,`
|
|
4
|
+
,
|
|
5
|
+
`))},styles:["[_nghost-%COMP%]{display:block}"],changeDetection:0})}}return t})();var Ot=(()=>{class t{static{this.\u0275fac=function(a){return new(a||t)}}static{this.\u0275cmp=M({type:t,selectors:[["app-report-trial-balance"]],decls:3,vars:0,template:function(a,o){a&1&&(i(0,"p"),r(1,"report-trial-balance works!"),n(),r(2,`
|
|
6
|
+
,
|
|
7
|
+
`))},styles:["[_nghost-%COMP%]{display:block}"],changeDetection:0})}}return t})();var sr=[{path:"",redirectTo:"general-ledger",pathMatch:"full"},{path:"",children:[{path:"general-ledger",component:Tt},{path:"profit-loss",component:Lt},{path:"balance-sheet",component:Mt},{path:"comparative-balance",component:Bt},{path:"trial-balance",component:Ot},{path:"cash-flow",component:kt}]}];export{sr as REPORTS_ROUTES};
|