marketplacepos 5.44.1 → 5.45.0
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/Marketplace/3rdpartylicenses.txt +31 -31
- package/Marketplace/{chunk-IA6KOBDJ.js → chunk-2HNZ6XV3.js} +1 -1
- package/Marketplace/chunk-2I7ZZ3F2.js +1 -0
- package/Marketplace/chunk-2LK24YA5.js +1 -0
- package/Marketplace/chunk-2TN45S53.js +1 -0
- package/Marketplace/{chunk-2XV6YOOU.js → chunk-37L3YDKT.js} +1 -1
- package/Marketplace/chunk-3E7JHNVC.js +5 -0
- package/Marketplace/{chunk-F63CEOOT.js → chunk-3FPEQHTI.js} +1 -1
- package/Marketplace/{chunk-SJU6ZU2K.js → chunk-3LN6RMRN.js} +1 -1
- package/Marketplace/{chunk-5JQJRPL3.js → chunk-3TYYN7ZX.js} +1 -1
- package/Marketplace/{chunk-CUB2QFUO.js → chunk-3UN6FPMN.js} +1 -1
- package/Marketplace/{chunk-SYUFPF3D.js → chunk-3YP6ORBR.js} +1 -1
- package/Marketplace/chunk-42MFOGHP.js +5 -0
- package/Marketplace/{chunk-E4Z7OR75.js → chunk-4KHHGHFJ.js} +1 -1
- package/Marketplace/chunk-4Q5ZSKVO.js +1 -0
- package/Marketplace/{chunk-MS3ZBCON.js → chunk-4VITMSIA.js} +1 -1
- package/Marketplace/{chunk-VWNEJWLI.js → chunk-4ZQCJGTZ.js} +1 -1
- package/Marketplace/{chunk-IIZDEGGW.js → chunk-5LQRO4AI.js} +1 -1
- package/Marketplace/{chunk-6QYD6NIJ.js → chunk-5PS6ZS3N.js} +1 -1
- package/Marketplace/{chunk-35XX6SQT.js → chunk-6KBMGQMI.js} +1 -1
- package/Marketplace/{chunk-IL5JIRWJ.js → chunk-6L7TD5DW.js} +1 -1
- package/Marketplace/{chunk-SDVWA7KM.js → chunk-6NUQGKRV.js} +1 -1
- package/Marketplace/{chunk-PNITO7BE.js → chunk-6RLISMEX.js} +1 -1
- package/Marketplace/{chunk-EGFBMQKW.js → chunk-6V4LFY52.js} +1 -1
- package/Marketplace/chunk-6VDV7CA2.js +2 -0
- package/Marketplace/chunk-6VHVQEVM.js +3 -0
- package/Marketplace/chunk-6WCXK7FR.js +2 -0
- package/Marketplace/chunk-6ZOHSFR5.js +1 -0
- package/Marketplace/{chunk-G7R7LUW4.js → chunk-74ELVGDK.js} +1 -1
- package/Marketplace/{chunk-LZCEM2PC.js → chunk-7AE3725T.js} +1 -1
- package/Marketplace/{chunk-H3IVI3LN.js → chunk-A44LN77B.js} +1 -1
- package/Marketplace/{chunk-IMK2JGZA.js → chunk-A64VIOKR.js} +1 -1
- package/Marketplace/{chunk-L3FX4O3H.js → chunk-B67DSLBY.js} +1 -1
- package/Marketplace/chunk-B7JSVIVV.js +1 -0
- package/Marketplace/{chunk-PFIBU2IX.js → chunk-BBQGPXDH.js} +1 -1
- package/Marketplace/{chunk-E66C2WAS.js → chunk-BERZDE6Y.js} +1 -1
- package/Marketplace/{chunk-WVQIS27J.js → chunk-BFPMFJI7.js} +1 -1
- package/Marketplace/{chunk-EQIFZBRG.js → chunk-BJUPMCEP.js} +2 -2
- package/Marketplace/{chunk-DL66NZ2A.js → chunk-BQIB3N6V.js} +1 -1
- package/Marketplace/chunk-BYSLV4DQ.js +2 -0
- package/Marketplace/chunk-BZBQHO76.js +1 -0
- package/Marketplace/{chunk-LA6B2JGP.js → chunk-CHWXOJDB.js} +1 -1
- package/Marketplace/chunk-CNJDARBM.js +1 -0
- package/Marketplace/{chunk-SBZNADRN.js → chunk-D5YID4W4.js} +1 -1
- package/Marketplace/{chunk-KWX3WSCT.js → chunk-DDVDUCPY.js} +1 -1
- package/Marketplace/{chunk-SM3P57SO.js → chunk-DFGZ4L65.js} +1 -1
- package/Marketplace/chunk-DSQSL5VX.js +15 -0
- package/Marketplace/{chunk-YM4TJJMM.js → chunk-DZYBXWL2.js} +1 -1
- package/Marketplace/{chunk-RZZKFTCX.js → chunk-ELSSXU6Y.js} +1 -1
- package/Marketplace/{chunk-SWQXSJ7O.js → chunk-ERXVXBTU.js} +1 -1
- package/Marketplace/chunk-EVQLTXB7.js +1 -0
- package/Marketplace/{chunk-IM4DS3UA.js → chunk-FAMP5PPX.js} +1 -1
- package/Marketplace/{chunk-NOP5P5R5.js → chunk-FESS3PG3.js} +1 -1
- package/Marketplace/{chunk-WW22F76D.js → chunk-FFCWYWBW.js} +1 -1
- package/Marketplace/{chunk-J5OHT4GM.js → chunk-FJ455ZYZ.js} +1 -1
- package/Marketplace/{chunk-UGVEAL7H.js → chunk-FO7G4GMY.js} +1 -1
- package/Marketplace/{chunk-XMIUIAY2.js → chunk-FOFXARTB.js} +1 -1
- package/Marketplace/{chunk-OC2FBL33.js → chunk-FPYZBABH.js} +1 -1
- package/Marketplace/{chunk-Z5GRNGHJ.js → chunk-FVORY74O.js} +1 -1
- package/Marketplace/{chunk-M2FCTYGU.js → chunk-FXQKRJWU.js} +1 -1
- package/Marketplace/{chunk-B5VBBEEN.js → chunk-G7T42LFR.js} +1 -1
- package/Marketplace/{chunk-AJL3CYNX.js → chunk-GH5FTODR.js} +1 -1
- package/Marketplace/{chunk-JUL73DOX.js → chunk-GLVYOZA4.js} +1 -1
- package/Marketplace/chunk-H46SHHXR.js +1 -0
- package/Marketplace/{chunk-B5V5KFQU.js → chunk-HFCAD7GH.js} +1 -1
- package/Marketplace/{chunk-KIIVJXDR.js → chunk-HPFBJL3A.js} +1 -1
- package/Marketplace/{chunk-3LRWABHB.js → chunk-HVCIQI7B.js} +1 -1
- package/Marketplace/{chunk-GCDQNJQN.js → chunk-ID2YZPRH.js} +1 -1
- package/Marketplace/{chunk-6ZVBRMK4.js → chunk-IML3KYQE.js} +1 -1
- package/Marketplace/{chunk-CIAZIJGR.js → chunk-IQ4AFE6X.js} +1 -1
- package/Marketplace/{chunk-AEOSNAHH.js → chunk-J53BPEDH.js} +1 -1
- package/Marketplace/{chunk-F7QBIR6G.js → chunk-JBNND5FL.js} +1 -1
- package/Marketplace/chunk-JFS634DA.js +1 -0
- package/Marketplace/{chunk-JPYSXZZO.js → chunk-JJKMVDXR.js} +1 -1
- package/Marketplace/{chunk-CMTBBXR5.js → chunk-JVNHFIYT.js} +1 -1
- package/Marketplace/{chunk-6INFVQEU.js → chunk-KUUDZPGN.js} +1 -1
- package/Marketplace/{chunk-OAOQONOA.js → chunk-KXEADFBM.js} +1 -1
- package/Marketplace/{chunk-ZXQNMGQG.js → chunk-L7EQZACZ.js} +1 -1
- package/Marketplace/{chunk-4KKT6FMN.js → chunk-L7KCZLIM.js} +1 -1
- package/Marketplace/chunk-LBXSZJDS.js +1 -0
- package/Marketplace/{chunk-CSP6M3TO.js → chunk-LCRPUAWG.js} +1 -1
- package/Marketplace/{chunk-OLOIQI4D.js → chunk-LDD4NVMB.js} +1 -1
- package/Marketplace/{chunk-KALG6D6L.js → chunk-LDPDLCRL.js} +1 -1
- package/Marketplace/{chunk-HFKZOM4I.js → chunk-LF6HWNC2.js} +1 -1
- package/Marketplace/chunk-LHX4ZOLA.js +2 -0
- package/Marketplace/chunk-LK2PMDRL.js +1 -0
- package/Marketplace/chunk-LQ2NLQKV.js +1 -0
- package/Marketplace/{chunk-E3ROEHBW.js → chunk-LRUVI2Z3.js} +1 -1
- package/Marketplace/{chunk-SB7NWPDS.js → chunk-M7V7A7Z6.js} +1 -1
- package/Marketplace/{chunk-WHDFRUFN.js → chunk-MBBQZFI4.js} +1 -1
- package/Marketplace/{chunk-2SCXTEPT.js → chunk-MMUSTFHH.js} +1 -1
- package/Marketplace/chunk-MO53T3IK.js +1 -0
- package/Marketplace/chunk-MWTFYMKY.js +1 -0
- package/Marketplace/{chunk-PAEIUO2F.js → chunk-N2SPK2VI.js} +1 -1
- package/Marketplace/{chunk-IHNN4Q2N.js → chunk-NNRBGHXB.js} +1 -1
- package/Marketplace/{chunk-W6FZQ6XT.js → chunk-OFZOAEW5.js} +1 -1
- package/Marketplace/{chunk-B7KTCPKC.js → chunk-OJMQBH6T.js} +3 -3
- package/Marketplace/{chunk-K5GEJ2GZ.js → chunk-OK3LLCAK.js} +1 -1
- package/Marketplace/{chunk-EPVCMYCI.js → chunk-OLANEXLB.js} +1 -1
- package/Marketplace/{chunk-E2SXYIML.js → chunk-ORDCBJ4G.js} +1 -1
- package/Marketplace/{chunk-2ODVHD2K.js → chunk-PFXOFSJG.js} +1 -1
- package/Marketplace/{chunk-YPWHTELF.js → chunk-PPHTN2H6.js} +1 -1
- package/Marketplace/{chunk-YXGO35YT.js → chunk-PQGPOOCK.js} +1 -1
- package/Marketplace/{chunk-5JVEEL2T.js → chunk-PYXL7UF7.js} +1 -1
- package/Marketplace/{chunk-AYPY47VM.js → chunk-QBL6V7QF.js} +1 -1
- package/Marketplace/{chunk-4WI2DOJ7.js → chunk-QE3IIBDW.js} +1 -1
- package/Marketplace/{chunk-CCWNSX4Y.js → chunk-QHE3PKRD.js} +1 -1
- package/Marketplace/{chunk-AO46RPZ4.js → chunk-QK4BGDSS.js} +1 -1
- package/Marketplace/chunk-QP4C4R4W.js +1 -0
- package/Marketplace/{chunk-74IXJYWO.js → chunk-QS22J2SC.js} +1 -1
- package/Marketplace/chunk-QUKRHI5J.js +1 -0
- package/Marketplace/{chunk-OTDC2LYA.js → chunk-R7INAZCD.js} +1 -1
- package/Marketplace/{chunk-KMJM6UVY.js → chunk-RDRNWLJI.js} +1 -1
- package/Marketplace/chunk-RHF7TPRF.js +1 -0
- package/Marketplace/{chunk-M5XGP4SG.js → chunk-RHHHL4OR.js} +1 -1
- package/Marketplace/{chunk-6IYLH3EV.js → chunk-RLBTXXCD.js} +1 -1
- package/Marketplace/{chunk-6BIM4KEI.js → chunk-RNTPX24O.js} +1 -1
- package/Marketplace/{chunk-Z5OLAUH6.js → chunk-RQEQPIMI.js} +1 -1
- package/Marketplace/{chunk-M7NQID2Z.js → chunk-RTT3JVJM.js} +1 -1
- package/Marketplace/chunk-SHRLQGK3.js +1 -0
- package/Marketplace/{chunk-Y42GRQNF.js → chunk-TC4JRJQL.js} +1 -1
- package/Marketplace/{chunk-E4KNET2R.js → chunk-TH6VZX34.js} +1 -1
- package/Marketplace/{chunk-WUHNNJ2C.js → chunk-TYG67JH3.js} +1 -1
- package/Marketplace/{chunk-YZLHRAEO.js → chunk-TZEINVZY.js} +1 -1
- package/Marketplace/chunk-UHJEXTOG.js +1 -0
- package/Marketplace/{chunk-ECRWEMEV.js → chunk-UHTMVOX6.js} +1 -1
- package/Marketplace/{chunk-UEPQYAWE.js → chunk-UIFPDTMW.js} +1 -1
- package/Marketplace/{chunk-NXI7PMGL.js → chunk-UML74HNB.js} +1 -1
- package/Marketplace/{chunk-D6URDVES.js → chunk-UXPULNCR.js} +1 -1
- package/Marketplace/{chunk-SN4AOGQK.js → chunk-UYLSZYOD.js} +1 -1
- package/Marketplace/{chunk-ATZ475FN.js → chunk-V3USB3ZU.js} +1 -1
- package/Marketplace/{chunk-77JJJNRM.js → chunk-V5KHEF77.js} +1 -1
- package/Marketplace/chunk-VVX6LRMW.js +1 -0
- package/Marketplace/{chunk-5OHRA4AS.js → chunk-W3JTS22H.js} +1 -1
- package/Marketplace/{chunk-JXSBFTQM.js → chunk-W5L6FMO3.js} +1 -1
- package/Marketplace/{chunk-EH6HWI3G.js → chunk-WFT47MCY.js} +1 -1
- package/Marketplace/{chunk-NS46QSCM.js → chunk-WJAE4LW2.js} +1 -1
- package/Marketplace/{chunk-MH4SJTQX.js → chunk-WLRPCY65.js} +1 -1
- package/Marketplace/{chunk-VIMB2VWB.js → chunk-WPELZYFP.js} +1 -1
- package/Marketplace/{chunk-RECNBAEB.js → chunk-WWISWZF5.js} +1 -1
- package/Marketplace/{chunk-57UYCHCW.js → chunk-XNVULGQ3.js} +1 -1
- package/Marketplace/{chunk-OA5PCIIS.js → chunk-XP6R2ZYJ.js} +1 -1
- package/Marketplace/{chunk-5KS4WK6H.js → chunk-XXWBR6S5.js} +1 -1
- package/Marketplace/{chunk-ZQ5EGXEB.js → chunk-YIXZLIPA.js} +1 -1
- package/Marketplace/{chunk-KAQL5LN5.js → chunk-YNJPF4PB.js} +1 -1
- package/Marketplace/{chunk-QIALMLQK.js → chunk-YWSUS64O.js} +1 -1
- package/Marketplace/{chunk-QJJ2WFVX.js → chunk-Z3ZYINRX.js} +1 -1
- package/Marketplace/chunk-ZBKUZ4CN.js +1 -0
- package/Marketplace/{chunk-NZUPRMOX.js → chunk-ZKXPDUO4.js} +1 -1
- package/Marketplace/index.html +2 -2
- package/Marketplace/{main-AS37EDUH.js → main-ZZ76NVAH.js} +1 -1
- package/Marketplace/{styles-X3FXEB7T.css → styles-EW2SXTVD.css} +1 -1
- package/package.json +1 -1
- package/Marketplace/chunk-3OIE7ARG.js +0 -1
- package/Marketplace/chunk-3ONIF6WO.js +0 -1
- package/Marketplace/chunk-4JS5MYC3.js +0 -1
- package/Marketplace/chunk-5TKBTQTA.js +0 -2
- package/Marketplace/chunk-6RKA4STM.js +0 -1
- package/Marketplace/chunk-7PSP3KRN.js +0 -1
- package/Marketplace/chunk-7T2AVFH5.js +0 -2
- package/Marketplace/chunk-AQTXFEBA.js +0 -1
- package/Marketplace/chunk-B5BDARIM.js +0 -1
- package/Marketplace/chunk-BOGJ2QV5.js +0 -4
- package/Marketplace/chunk-BU5LUO3S.js +0 -1
- package/Marketplace/chunk-C5JZPXEW.js +0 -1
- package/Marketplace/chunk-DAVYBR3Z.js +0 -5
- package/Marketplace/chunk-DHOJLUJI.js +0 -1
- package/Marketplace/chunk-DRTTCT2P.js +0 -1
- package/Marketplace/chunk-EJG33GYS.js +0 -15
- package/Marketplace/chunk-ETOKAGEB.js +0 -2
- package/Marketplace/chunk-EWYAB244.js +0 -1
- package/Marketplace/chunk-G6VH553U.js +0 -1
- package/Marketplace/chunk-GIRXMYNI.js +0 -1
- package/Marketplace/chunk-I6VSPSNT.js +0 -1
- package/Marketplace/chunk-K5VFEHP7.js +0 -1
- package/Marketplace/chunk-K77RTNG2.js +0 -1
- package/Marketplace/chunk-K7ZFPSOU.js +0 -1
- package/Marketplace/chunk-LDHQNVI5.js +0 -1
- package/Marketplace/chunk-MS4AQ6UA.js +0 -0
- package/Marketplace/chunk-MSQ7Z3W2.js +0 -1
- package/Marketplace/chunk-OPFENZ3W.js +0 -1
- package/Marketplace/chunk-OPYO4NH2.js +0 -5
- package/Marketplace/chunk-P7NATRFC.js +0 -1
- package/Marketplace/chunk-SLI26GUH.js +0 -1
- package/Marketplace/chunk-UBXKO4QI.js +0 -1
- package/Marketplace/chunk-V2SXQQLG.js +0 -1
- package/Marketplace/chunk-V5BKQSAT.js +0 -1
- package/Marketplace/chunk-WMYSG6O7.js +0 -1
- package/Marketplace/chunk-XHYJOIC5.js +0 -3
- package/Marketplace/chunk-YZKPQRLO.js +0 -2
|
@@ -30,6 +30,32 @@ Package: @dealpos-npm/ng-dealpos-library
|
|
|
30
30
|
License: "ISC"
|
|
31
31
|
|
|
32
32
|
|
|
33
|
+
--------------------------------------------------------------------------------
|
|
34
|
+
Package: @angular/cdk
|
|
35
|
+
License: "MIT"
|
|
36
|
+
|
|
37
|
+
The MIT License
|
|
38
|
+
|
|
39
|
+
Copyright (c) 2025 Google LLC.
|
|
40
|
+
|
|
41
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
42
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
43
|
+
in the Software without restriction, including without limitation the rights
|
|
44
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
45
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
46
|
+
furnished to do so, subject to the following conditions:
|
|
47
|
+
|
|
48
|
+
The above copyright notice and this permission notice shall be included in
|
|
49
|
+
all copies or substantial portions of the Software.
|
|
50
|
+
|
|
51
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
52
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
53
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
54
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
55
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
56
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
|
57
|
+
THE SOFTWARE.
|
|
58
|
+
|
|
33
59
|
--------------------------------------------------------------------------------
|
|
34
60
|
Package: primeng
|
|
35
61
|
License: "SEE LICENSE IN LICENSE.md"
|
|
@@ -112,32 +138,6 @@ The term “Software” includes all source and object code, in whole and/or par
|
|
|
112
138
|
9. **Indemnification:** Licensee hereby warrants to hold Licensor harmless and indemnify Licensor for any lawsuit brought against it in regards to Licensee’s use of The Software in means that violate, breach or otherwise circumvent this license, Licensor's intellectual property rights or Licensor's title in The Software. Licensor shall promptly notify Licensee in case of such legal action and request Licensee’s consent prior to any settlement in relation to such lawsuit or claim.
|
|
113
139
|
10. **Governing Law, Jurisdiction:** Licensee hereby agrees not to initiate class-action lawsuits against Licensor in relation to this license and to compensate Licensor for any legal fees, cost or attorney fees should any claim brought by Licensee against Licensor be denied, in part or in full.
|
|
114
140
|
|
|
115
|
-
--------------------------------------------------------------------------------
|
|
116
|
-
Package: @angular/cdk
|
|
117
|
-
License: "MIT"
|
|
118
|
-
|
|
119
|
-
The MIT License
|
|
120
|
-
|
|
121
|
-
Copyright (c) 2025 Google LLC.
|
|
122
|
-
|
|
123
|
-
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
124
|
-
of this software and associated documentation files (the "Software"), to deal
|
|
125
|
-
in the Software without restriction, including without limitation the rights
|
|
126
|
-
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
127
|
-
copies of the Software, and to permit persons to whom the Software is
|
|
128
|
-
furnished to do so, subject to the following conditions:
|
|
129
|
-
|
|
130
|
-
The above copyright notice and this permission notice shall be included in
|
|
131
|
-
all copies or substantial portions of the Software.
|
|
132
|
-
|
|
133
|
-
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
134
|
-
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
135
|
-
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
136
|
-
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
137
|
-
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
138
|
-
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
|
139
|
-
THE SOFTWARE.
|
|
140
|
-
|
|
141
141
|
--------------------------------------------------------------------------------
|
|
142
142
|
Package: moment
|
|
143
143
|
License: "MIT"
|
|
@@ -219,11 +219,6 @@ WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
|
|
|
219
219
|
FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
|
|
220
220
|
OTHER DEALINGS IN THE SOFTWARE.
|
|
221
221
|
|
|
222
|
-
--------------------------------------------------------------------------------
|
|
223
|
-
Package: bigger-picture
|
|
224
|
-
License: "MIT"
|
|
225
|
-
|
|
226
|
-
|
|
227
222
|
--------------------------------------------------------------------------------
|
|
228
223
|
Package: ng-http-loader
|
|
229
224
|
License: "MIT"
|
|
@@ -471,6 +466,11 @@ CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
|
|
|
471
466
|
TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
|
|
472
467
|
SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
|
473
468
|
|
|
469
|
+
--------------------------------------------------------------------------------
|
|
470
|
+
Package: bigger-picture
|
|
471
|
+
License: "MIT"
|
|
472
|
+
|
|
473
|
+
|
|
474
474
|
--------------------------------------------------------------------------------
|
|
475
475
|
Package: @microsoft/signalr
|
|
476
476
|
License: "MIT"
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{a as u,b as de,c as f,e as C}from"./chunk-OZ7LWNOK.js";import{a as ae}from"./chunk-
|
|
1
|
+
import{a as u,b as de,c as f,e as C}from"./chunk-OZ7LWNOK.js";import{a as ae}from"./chunk-UHTMVOX6.js";import{C as ne,H as m,b as A,ba as oe,d as ie,fa as se,ia as re,ja as le,r as j}from"./chunk-7AE3725T.js";import{c as te,d as L,f as R,i as I,j as V,k as M}from"./chunk-K5XRGNWG.js";import{d as Y,g as G,h as J,i as W,n as X,o as ee}from"./chunk-FXQKRJWU.js";import{Ac as D,Bc as v,Ca as H,Cc as y,Gb as B,Ka as s,Kb as Q,La as F,Mb as g,Qc as q,Sc as _,Uc as U,Yb as d,_c as $,ac as x,ic as w,ja as Z,jc as T,nc as K,oc as S,pa as z,rb as b,tc as E,uc as r,vc as N,wc as P,xb as O,ya as h,za as p,zc as k}from"./chunk-OJMQBH6T.js";import{a as c}from"./chunk-66YHNWRR.js";var ce=["content"],_e=["overlay"],Ce=["*"],be=(i,l,e,t,n,o,a,pe,ve,ye,me,ue,fe,ge)=>({"p-overlay p-component":!0,"p-overlay-modal p-overlay-mask p-overlay-mask-enter":i,"p-overlay-center":l,"p-overlay-top":e,"p-overlay-top-start":t,"p-overlay-top-end":n,"p-overlay-bottom":o,"p-overlay-bottom-start":a,"p-overlay-bottom-end":pe,"p-overlay-left":ve,"p-overlay-left-start":ye,"p-overlay-left-end":me,"p-overlay-right":ue,"p-overlay-right-start":fe,"p-overlay-right-end":ge}),Oe=(i,l,e)=>({showTransitionParams:i,hideTransitionParams:l,transform:e}),xe=i=>({value:"visible",params:i}),we=i=>({mode:i}),Te=i=>({$implicit:i});function Se(i,l){i&1&&K(0)}function Ee(i,l){if(i&1){let e=S();w(0,"div",3,1),E("click",function(n){h(e);let o=r(2);return p(o.onOverlayContentClick(n))})("@overlayContentAnimation.start",function(n){h(e);let o=r(2);return p(o.onOverlayContentAnimationStart(n))})("@overlayContentAnimation.done",function(n){h(e);let o=r(2);return p(o.onOverlayContentAnimationDone(n))}),P(2),g(3,Se,1,0,"ng-container",4),T()}if(i&2){let e=r(2);x(e.contentStyleClass),d("ngStyle",e.contentStyle)("ngClass","p-overlay-content")("@overlayContentAnimation",_(11,xe,U(7,Oe,e.showTransitionOptions,e.hideTransitionOptions,e.transformOptions[e.modal?e.overlayResponsiveDirection:"default"]))),b(3),d("ngTemplateOutlet",e.contentTemplate||e._contentTemplate)("ngTemplateOutletContext",_(15,Te,_(13,we,e.overlayMode)))}}function ke(i,l){if(i&1){let e=S();w(0,"div",3,0),E("click",function(){h(e);let n=r();return p(n.onOverlayClick())}),g(2,Ee,4,17,"div",2),T()}if(i&2){let e=r();x(e.styleClass),d("ngStyle",e.style)("ngClass",$(5,be,[e.modal,e.modal&&e.overlayResponsiveDirection==="center",e.modal&&e.overlayResponsiveDirection==="top",e.modal&&e.overlayResponsiveDirection==="top-start",e.modal&&e.overlayResponsiveDirection==="top-end",e.modal&&e.overlayResponsiveDirection==="bottom",e.modal&&e.overlayResponsiveDirection==="bottom-start",e.modal&&e.overlayResponsiveDirection==="bottom-end",e.modal&&e.overlayResponsiveDirection==="left",e.modal&&e.overlayResponsiveDirection==="left-start",e.modal&&e.overlayResponsiveDirection==="left-end",e.modal&&e.overlayResponsiveDirection==="right",e.modal&&e.overlayResponsiveDirection==="right-start",e.modal&&e.overlayResponsiveDirection==="right-end"])),b(2),d("ngIf",e.visible)}}var De=({dt:i})=>`
|
|
2
2
|
.p-overlay {
|
|
3
3
|
position: absolute;
|
|
4
4
|
top: 0;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{a}from"./chunk-RDRNWLJI.js";import{b as h,e as p}from"./chunk-W5L6FMO3.js";import{ja as I,oa as o}from"./chunk-OJMQBH6T.js";var D=(()=>{class r{constructor(n,e){this.toastrService=n,this.http=e}getLastInfoDownloadInventory(n){return this.http.post(a.GetLastInfoDownloadInventory,{ChannelID:n})}refreshInventory(n){let e=n.map(t=>t.Channel.map(s=>(s.VariantID=t.ID,s))).reduce((t,i)=>(t=t.concat(i),t),[]).map(t=>({ChannelItemID:t.ChannelItemID,ChannelID:t.ChannelID,VariantID:t.VariantID,ChannelVariationID:t.ChannelVariationID}));return this.http.post(a.RefreshInventory,e)}static{this.\u0275fac=function(e){return new(e||r)(o(h),o(p))}}static{this.\u0275prov=I({token:r,factory:r.\u0275fac})}}return r})();export{D as a};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{a as re}from"./chunk-2I7ZZ3F2.js";import{b as ee}from"./chunk-YIXZLIPA.js";import"./chunk-HVCIQI7B.js";import"./chunk-QS22J2SC.js";import"./chunk-QP4C4R4W.js";import{a as ne}from"./chunk-B7JSVIVV.js";import{a as ie}from"./chunk-ZBKUZ4CN.js";import{c as oe,d as F,e as V}from"./chunk-3E7JHNVC.js";import"./chunk-PPHTN2H6.js";import"./chunk-DZYBXWL2.js";import"./chunk-RHHHL4OR.js";import{a as Z}from"./chunk-3FPEQHTI.js";import"./chunk-5LQRO4AI.js";import"./chunk-MO53T3IK.js";import"./chunk-W3JTS22H.js";import"./chunk-SDUUFQUI.js";import"./chunk-6L7TD5DW.js";import"./chunk-WLRPCY65.js";import"./chunk-3RK6DDJD.js";import"./chunk-3UN6FPMN.js";import"./chunk-LDPDLCRL.js";import"./chunk-UMP6ZMEJ.js";import"./chunk-JVNHFIYT.js";import{a as te}from"./chunk-FESS3PG3.js";import"./chunk-3YP6ORBR.js";import"./chunk-FJ455ZYZ.js";import{h as z}from"./chunk-6VHVQEVM.js";import"./chunk-Z3ITXK3D.js";import"./chunk-ACIMXBIC.js";import"./chunk-J53BPEDH.js";import"./chunk-TGMCGROM.js";import{a as D}from"./chunk-RDRNWLJI.js";import{b as $,e as q}from"./chunk-W5L6FMO3.js";import"./chunk-K5XRGNWG.js";import"./chunk-PYXL7UF7.js";import"./chunk-PW42BQIY.js";import{d as K,l as Q,m as X,n as Y}from"./chunk-FO7G4GMY.js";import{A as J,c as k,h as j,m as G,o as H}from"./chunk-5PS6ZS3N.js";import"./chunk-V3USB3ZU.js";import"./chunk-ERXVXBTU.js";import"./chunk-NNRBGHXB.js";import"./chunk-BJUPMCEP.js";import{g as B,j as U,m as x,n as W}from"./chunk-FXQKRJWU.js";import{$c as P,G as R,Gb as L,Gc as g,Kc as w,Lc as b,Mb as v,Mc as I,Nc as A,Qc as O,Ra as S,Yb as m,Z as T,ad as f,ea as N,ic as r,jc as p,kc as y,oc as M,pa as C,rb as d,tc as u,uc as _,xb as h,ya as s,za as l}from"./chunk-OJMQBH6T.js";import"./chunk-EU2KAMEK.js";import"./chunk-66YHNWRR.js";function ae(c,E){if(c&1){let t=M();r(0,"button",16),u("click",function(){s(t);let e=_().ngIf,o=_();return l(o.onUpdateItems(e))}),y(1,"i",17),g(2," Update "),p()}}function se(c,E){if(c&1&&(r(0,"div"),v(1,ae,3,0,"button",15),p()),c&2){let t=E.ngIf,i=_();d(),m("ngIf",i.productService.hasSelectionVariant(t))}}var Le=(()=>{class c{constructor(t,i,e,o,a){this.http=t,this.toastr=i,this.dialog=e,this.productService=o,this.authService=a,this.infinitePagination=C(F),this.updateResHandling=C(V),this.mainPanelService=C(Q),this.channelOptions=S([]),this.searchFilter=S({PageNumber:1,RowCount:50,filterModel:1,text:"",ListChannelID:[]}),this.loaderAPI="PriceLoader/LoadMultiple",this.getDataAPI="Price/GetMultipleChannelComparison",this.rowCountAPI="Inventory/GetMultipleChannelComparisonRowCount",this.data$=this.infinitePagination.data$.pipe(T())}ngOnInit(){this.initPageLoader()}initPageLoader(){this.infinitePagination.fetchDataEndpoint=this.getDataAPI,this.infinitePagination.fethRowCountEndpoint=this.rowCountAPI,this.loader$=this.http.post(`/api/${this.loaderAPI}`).pipe(N(t=>{t.Filter={PageNumber:t.Filter.PageNumber,RowCount:t.Filter.RowCount,filterModel:1},this.searchFilter.set(t.Filter),this.mainPanelService.openModalFilter()}))}onShowDifferencePrice(t){let i=1;t&&(i=3),this.searchFilter.update(e=>(e.filterModel=i,e)),this.infinitePagination.reloadPagination(this.searchFilter())}onSearch(t){this.searchFilter.update(i=>(i.text=t,i)),this.infinitePagination.reloadPagination(this.searchFilter()),this.filterSelectedChannels()}filterSelectedChannels(){let i=this.authService.getChannels().filter(e=>this.searchFilter().ListChannelID?.indexOf(e.ID)!==-1);this.channelOptions.set(i)}updatePrice(t){let i=this.productService.selectedVariantProduct(t);if(i.length>0){let e=i.map(n=>({ID:n.ID,Code:n.Code,Price:n.UnitPrice})),a={ListChannelID:this.channelOptions().filter(n=>n.selected).map(n=>n.ID),ListPrice:e};this.http.post(D.UpdateChannelPrice,a).subscribe(n=>{this.infinitePagination.reloadPagination(this.searchFilter()),this.handlingUpdatePrice(n)})}}updatePriceByVariant(t){let i={ID:t.ChannelID,ChannelItemID:t.ChannelItemID,ChannelVariantID:t.ChannelVariationID,Price:t.Price-0,VariantID:t.ID};this.http.post(D.UpdatePriceById,i).subscribe(e=>{this.infinitePagination.reloadPagination(this.searchFilter()),this.handlingUpdatePrice(e)})}handlingUpdatePrice(t){let i=t?.Response?.success_list,e=t?.Response?.failure_list;i?.length>0||e?.length>0?this.updateResHandling.responseHandling(i,e,"Price"):this.toastr.error(t[0]?.Exception,"Error")}onUpdateItems(t){let i=JSON.parse(JSON.stringify(this.channelOptions())),e=this.productService.selectedVariantProduct(t);this.dialog.open(ie,{data:{title:"Updating Price",selectedItems:e,channels:i},width:"400px"}).afterClosed().pipe(R(o=>o!==void 0)).subscribe(()=>{this.updatePrice(t)})}openExportDialog(){this.dialog.open(ee,{data:{title:"Export Multi Channel Comparison",pageNumber:this.searchFilter().PageNumber,rowCount:this.searchFilter().RowCount,filterExport:this.searchFilter(),getRowCountApi:this.rowCountAPI,exportApi:"price/GetExportMultipleChannelComparison"}}).afterClosed().subscribe()}static{this.\u0275fac=function(i){return new(i||c)(h(q),h($),h(K),h(Z),h(z))}}static{this.\u0275cmp=L({type:c,selectors:[["app-price-pos-channel"]],features:[O([F,x,re,V])],decls:32,vars:23,consts:[["headerTitle","Price Comparison","textButton","Search",3,"onSubmit"],[1,"d-flex"],[4,"ngIf"],[1,"btn","btn-outline-secondary","shadow","rounded","ms-2",3,"click"],[1,"fa-solid","fa-print","me-3"],[1,"mb-5"],[1,"fw-bold","mb-2"],[3,"ngModelChange","multiple","ngModel"],[1,"fw-bold"],["type","number",1,"form-control","mt-2",3,"ngModelChange","ngModel"],[1,"container-fluid","mt-3"],[1,"row"],[1,"col-md-12"],["productToggleTitle","FILTER DIFFERENT PRICE","table","price",3,"onToggle","onSubmit","showProductToggle","data","channel","hiddenIPOSInventory"],[3,"onNextPage","onLastPage","onGetRowCount","totalData","hideCount","rowCount","pageNumber","disableNextButton","goToLastPage"],["type","button","class","btn btn-success shadow rounded","data-toggle","modal",3,"click",4,"ngIf"],["type","button","data-toggle","modal",1,"btn","btn-success","shadow","rounded",3,"click"],[1,"fas","fa-chevron-circle-up"]],template:function(i,e){if(i&1){let o=M();A(0),P(1,"async"),r(2,"mainpanel",0),u("onSubmit",function(n){return s(o),l(e.onSearch(n))}),r(3,"actions")(4,"div",1),v(5,se,2,1,"div",2),P(6,"async"),r(7,"button",3),u("click",function(){return s(o),l(e.openExportDialog())}),y(8,"i",4),r(9,"span"),g(10,"Export"),p()()()(),r(11,"filters")(12,"div",5)(13,"label",6),g(14,"Channel"),p(),r(15,"channel-select-options",7),I("ngModelChange",function(n){return s(o),b(e.searchFilter().ListChannelID,n)||(e.searchFilter().ListChannelID=n),l(n)}),p()(),r(16,"div",5)(17,"label",8),g(18,"Page Number"),p(),r(19,"input",9),I("ngModelChange",function(n){return s(o),b(e.searchFilter().PageNumber,n)||(e.searchFilter().PageNumber=n),l(n)}),p()(),r(20,"div")(21,"label",8),g(22,"Page Size"),p(),r(23,"input",9),I("ngModelChange",function(n){return s(o),b(e.searchFilter().RowCount,n)||(e.searchFilter().RowCount=n),l(n)}),p()()(),r(24,"content")(25,"div",10)(26,"div",11)(27,"div",12)(28,"app-table",13),P(29,"async"),u("onToggle",function(n){return s(o),l(e.onShowDifferencePrice(n))})("onSubmit",function(n){return s(o),l(e.updatePriceByVariant(n))}),p(),r(30,"infinite-paginator",14),P(31,"async"),u("onNextPage",function(){return s(o),l(e.infinitePagination.onNextPage(e.searchFilter()))})("onLastPage",function(){return s(o),l(e.infinitePagination.onLastPage(e.searchFilter()))})("onGetRowCount",function(){return s(o),l(e.infinitePagination.getRowCount(e.searchFilter()))}),p()()()()()()}i&2&&(f(1,15,e.loader$),d(5),m("ngIf",f(6,17,e.data$)),d(10),m("multiple",!0),w("ngModel",e.searchFilter().ListChannelID),d(4),w("ngModel",e.searchFilter().PageNumber),d(4),w("ngModel",e.searchFilter().RowCount),d(5),m("showProductToggle",!0)("data",f(29,19,e.data$))("channel",e.channelOptions())("hiddenIPOSInventory",!1),d(2),m("totalData",e.infinitePagination.totalData())("hideCount",e.infinitePagination.hideCount())("rowCount",f(31,21,e.infinitePagination.totalRowCount$))("pageNumber",e.infinitePagination.pageNumber())("disableNextButton",e.infinitePagination.disableNextButton())("goToLastPage",e.infinitePagination.isLastPage()))},dependencies:[W,B,U,J,k,H,j,G,oe,Y,X,ne,te],styles:[".no-bullet[_ngcontent-%COMP%]{list-style-type:none}"]})}}return c})();export{Le as PricePosChannelComponent};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{a as E}from"./chunk-6KBMGQMI.js";import{a as T}from"./chunk-3FPEQHTI.js";import{h as w}from"./chunk-6VHVQEVM.js";import{a as D}from"./chunk-RDRNWLJI.js";import{b as j,e as s}from"./chunk-W5L6FMO3.js";import{b as i,c as m}from"./chunk-PW42BQIY.js";import{G as C}from"./chunk-FXQKRJWU.js";import{B as A,G as U,J as u,Ra as I,g as k,ja as c,pa as a,q as d,v as b}from"./chunk-OJMQBH6T.js";var F=(()=>{class o{constructor(){this.httpService=a(s)}getAttributes(t,e){return this.httpService.get("api/product/shopee/GetAttributesTree",[{key:"ID",value:t},{key:"CategoryID",value:e}])}getCategories(t){return this.httpService.get("api/product/shopee/GetCategories",[{key:"ID",value:t}])}uploadProduct(t){return this.httpService.post("api/product/shopee/AddProduct",t).pipe(u(r=>d(null)))}generateAttribute(t){return t.map(e=>({attribute_id:e.attribute_id,attribute_value_list:e.attribute_value_list.map(r=>({value_id:r.value_id,name:r.name}))})),t}static{this.\u0275fac=function(e){return new(e||o)}}static{this.\u0275prov=c({token:o,factory:o.\u0275fac,providedIn:"root"})}}return o})();var x=(()=>{class o{constructor(){this.httpService=a(s)}getCategories(t){return this.httpService.get("api/product/tiktok/GetCategories",[{key:"ID",value:t}])}uploadProduct(t){return this.httpService.post("api/product/tiktok/AddProduct",t).pipe(u(r=>d(null)))}generateAttribute(t){let e;return t.map(r=>(r.type=="PRODUCT_PROPERTY"?e={id:r.id,name:r.name,type:r.type,values:r.values}:e={id:r.id,name:r.values[0].id,type:r.type},e))}static{this.\u0275fac=function(e){return new(e||o)}}static{this.\u0275prov=c({token:o,factory:o.\u0275fac,providedIn:"root"})}}return o})();var H=(()=>{class o{constructor(){this.httpService=a(s)}getAttributes(t,e){return this.httpService.get("api/product/lazada/GetAttributes",[{key:"ID",value:t},{key:"CategoryID",value:e}])}getCategories(t){return this.httpService.get("api/product/lazada/GetCategories",[{key:"ID",value:t}])}uploadProduct(t){return this.httpService.post("api/product/lazada/AddProduct",t).pipe(u(r=>d(null)))}static{this.\u0275fac=function(e){return new(e||o)}}static{this.\u0275prov=c({token:o,factory:o.\u0275fac,providedIn:"root"})}}return o})();var R=(()=>{class o{constructor(){this.httpService=a(s)}getAttributes(t,e){return this.httpService.get("api/product/woo/GetAttributes",[{key:"ID",value:t},{key:"CategoryID",value:e}])}getCategories(t){return this.httpService.get("api/product/woo/GetCategories",[{key:"ID",value:t}])}uploadProduct(t){return this.httpService.post("api/product/woo/AddProduct",t).pipe(u(r=>d(null)))}static{this.\u0275fac=function(e){return new(e||o)}}static{this.\u0275prov=c({token:o,factory:o.\u0275fac,providedIn:"root"})}}return o})();var g=class{};var v=class{};var z=(()=>{class o{constructor(){this.httpService=a(s)}getCategories(t){return this.httpService.get("api/product/tokopedia/GetCategories",[{key:"ID",value:t}])}uploadProduct(t){return this.httpService.post("api/product/tokopedia/AddProduct",t).pipe(u(r=>d(null)))}static{this.\u0275fac=function(e){return new(e||o)}}static{this.\u0275prov=c({token:o,factory:o.\u0275fac,providedIn:"root"})}}return o})();var G=(()=>{class o{constructor(){this.httpService=a(s)}uploadProduct(t){return this.httpService.post("api/product/shopify/AddProduct",t).pipe(u(r=>d(null)))}static{this.\u0275fac=function(e){return new(e||o)}}static{this.\u0275prov=c({token:o,factory:o.\u0275fac,providedIn:"root"})}}return o})();var N=(()=>{class o{constructor(){this.httpService=a(s)}uploadProduct(t){return this.httpService.post(D.UploadPlugoProduct,t).pipe(u(e=>d(null)))}static{this.\u0275fac=function(e){return new(e||o)}}static{this.\u0275prov=c({token:o,factory:o.\u0275fac,providedIn:"root"})}}return o})();var Vt=(()=>{class o{constructor(){this.authService=a(w),this.productService=a(T),this.shoppeUploadService=a(F),this.tiktokUploadService=a(x),this.lazadaUploadService=a(H),this.tokopediaUploadService=a(z),this.wooUploadService=a(R),this.shopifyUploadService=a(G),this.plugoUploadService=a(N),this.toastrHandlingService=a(E),this.toastr=a(j),this.router=a(C),this.httpService=a(s),this._selectedProduct=new k(this.getStoredProducts()),this.selectedProduct$=this._selectedProduct.asObservable().pipe(U(t=>t&&t.length>0))}getStoredProducts(){let t=localStorage.getItem("productsUpload");if(t){let e=JSON.parse(t);return e&&e.length>0?e:[]}else return[]}setSelectedProduct(t){localStorage.setItem("productsUpload",JSON.stringify(t)),this._selectedProduct.next(t)}clearSelectedProduct(){localStorage.removeItem("productsUpload"),this._selectedProduct.next([])}getUnselectedChannels(){let t=this.authService.getChannels(),e=this._selectedProduct.getValue();return this.productService.filterUnselectedChannel(e,t)}getDefaultCategory(){return this.httpService.get("api/v1/Channel/ProductCategory/Default")}get channelProductUpload(){let t=this.getUnselectedChannels();return I(t.map(r=>{let p=new g;return p.id=r.ID,p.name=r.Name,p.type=r.TypeID,p.categoryId=null,p.attributes=[],p.selected=!1,p}))}onUploadProduct(t){let e=t.filter(r=>r.selected&&m.IsNotEmpty(r.categoryId)||r.selected&&(r.type==i.Shopify||r.type==i.Plugo));if(e.length>0){let r=this.generateDataForUpload(e);this.uploadProduct(r)}else this.toastr.warning("Please select a channel and category to upload the product.","Warning!")}uploadProduct(t){let e=this.generateObservableForUpload(t);A(e).pipe(b(r=>{let p=[];return r.filter(h=>m.IsNotEmpty(h)).forEach(h=>{p=[...p,...h]}),p})).subscribe({next:(r=[])=>{m.IsNotEmpty(r)&&this.toastrHandlingService.showToastrUploadMultiple(r),this.hasSuccessRes(r)&&this.onSuccessUpload()}})}hasSuccessRes(t){let e=!1;return t.forEach(r=>{r?.Response.Success_list?.length>0&&m.IsNotEmpty(r)&&(e=!0)}),e}onSuccessUpload(){this.router.navigate(["/menu/products/status/sold-in-channel"]),this.clearSelectedProduct()}generateObservableForUpload(t){let e=[],r=[],p=[],h=[],S=[],y=[],P=[];t.forEach(l=>{switch(l.ChannelType){case i.Shopee:r.push(l);break;case i.Tiktok:e.push(l);break;case i.Lazada:p.push(l);break;case i.Tokopedia:h.push(l);break;case i.WooCommerce:S.push(l);break;case i.Shopify:y.push(l);break;case i.Plugo:P.push(l);break}});let n=[];return[{type:i.Shopee,data:r},{type:i.Tiktok,data:e},{type:i.Lazada,data:p},{type:i.Tokopedia,data:h},{type:i.WooCommerce,data:S},{type:i.Shopify,data:y},{type:i.Plugo,data:P}].filter(l=>l.data.length>0).forEach(l=>{switch(l.type){case i.Shopee:n.push(this.shoppeUploadService.uploadProduct(r));break;case i.Tiktok:n.push(this.tiktokUploadService.uploadProduct(e));break;case i.Lazada:n.push(this.lazadaUploadService.uploadProduct(p));break;case i.Tokopedia:n.push(this.tokopediaUploadService.uploadProduct(h));break;case i.WooCommerce:n.push(this.wooUploadService.uploadProduct(S));break;case i.Shopify:n.push(this.shopifyUploadService.uploadProduct(y));break;case i.Plugo:n.push(this.plugoUploadService.uploadProduct(P));break}}),n}generateDataForUpload(t){let e=[];return t.forEach(r=>{let p=new v;p.ChannelID=r.id,p.ChannelType=r.type,p.Products=this._selectedProduct.getValue(),r.type==i.Shopify?delete p.CategoryID:p.CategoryID=r.categoryId,p=this.generateAttributeHttpRequest(r,p),e.push(p)}),e}generateAttributeHttpRequest(t,e){return t.type==i.WooCommerce||t.type==i.Shopify?e.Attribute=t.attributes[0]:t.type==i.Tiktok?(e.Attributes=this.formatAttributes(t.type,t.attributes),e.listing_platforms=t.listing_platforms):e.Attributes=this.formatAttributes(t.type,t.attributes),e}formatAttributes(t,e){let r;switch(t){case i.Shopee:r=this.shoppeUploadService.generateAttribute(e);break;case i.Tiktok:r=this.tiktokUploadService.generateAttribute(e);break;case i.WooCommerce:r=this.tiktokUploadService.generateAttribute(e);break;case i.Tokopedia:r=e;break;case i.Shopify:r=e;break;default:r=[];break}return r}static{this.\u0275fac=function(e){return new(e||o)}}static{this.\u0275prov=c({token:o,factory:o.\u0275fac,providedIn:"root"})}}return o})();export{F as a,x as b,H as c,R as d,Vt as e};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as _}from"./chunk-2ODVHD2K.js";import"./chunk-DL66NZ2A.js";import"./chunk-L3FX4O3H.js";import{a as R}from"./chunk-KWX3WSCT.js";import"./chunk-PNITO7BE.js";import"./chunk-E4KNET2R.js";import"./chunk-74IXJYWO.js";import"./chunk-GIRXMYNI.js";import"./chunk-IIZDEGGW.js";import"./chunk-AQTXFEBA.js";import"./chunk-SDUUFQUI.js";import"./chunk-5OHRA4AS.js";import"./chunk-IL5JIRWJ.js";import"./chunk-MH4SJTQX.js";import"./chunk-3RK6DDJD.js";import"./chunk-CUB2QFUO.js";import"./chunk-KALG6D6L.js";import{a as ue,b as ye}from"./chunk-IMK2JGZA.js";import"./chunk-CMTBBXR5.js";import"./chunk-XHYJOIC5.js";import"./chunk-Z3ITXK3D.js";import"./chunk-ACIMXBIC.js";import"./chunk-AEOSNAHH.js";import"./chunk-TGMCGROM.js";import"./chunk-KMJM6UVY.js";import{e as he}from"./chunk-JXSBFTQM.js";import"./chunk-K5XRGNWG.js";import{c as d}from"./chunk-PW42BQIY.js";import{m as w,n as ge}from"./chunk-UGVEAL7H.js";import{A as fe}from"./chunk-6QYD6NIJ.js";import"./chunk-ATZ475FN.js";import"./chunk-SWQXSJ7O.js";import"./chunk-IHNN4Q2N.js";import"./chunk-EQIFZBRG.js";import{F as pe,H as de,J as ce,f as ae,g as F,j as le,k as P,m as me,n as se}from"./chunk-M2FCTYGU.js";import{$c as k,Gb as T,Gc as p,Hb as Z,Hc as j,Ic as J,Kc as y,Lc as g,Mb as h,Mc as C,Oa as V,Rc as re,Wc as oe,Yb as m,Z as Q,ac as $,ad as B,dc as H,ea as z,ec as ee,gc as te,hc as ie,ic as r,ja as q,jc as a,ka as X,kc as v,nc as ne,oa as Y,pb as G,rb as l,rd as U,tc as b,uc as u,xb as f,xc as K}from"./chunk-B7KTCPKC.js";import"./chunk-EU2KAMEK.js";import"./chunk-66YHNWRR.js";var Ce=(()=>{class n{constructor(){this.reportTabs=[{Title:"1.Create Order",Url:"/menu/sync-log/order/sync-order"},{Title:"2.Convert Order To Invoice",Url:"/menu/sync-log/order/convert-to-invoice"},{Title:"3.Create Invoice",Url:"/menu/sync-log/order/invoice"},{Title:"4.Create Outbound Logistic",Url:"/menu/sync-log/order/delivery"},{Title:"5.Add Payment",Url:"/menu/sync-log/order/payment"},{Title:"6.Void Invoice",Url:"/menu/sync-log/order/void-invoice"},{Title:"All",Url:"/menu/sync-log/order/all"}]}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275cmp=T({type:n,selectors:[["app-order"]],standalone:!1,decls:5,vars:1,consts:[[1,"navbar","page-nav","navbar-default","py-0","navbar-expand-lg"],[1,"container-fluid"],[3,"Tabs"]],template:function(i,t){i&1&&(r(0,"nav",0)(1,"div",1)(2,"div"),v(3,"nav-tab",2),a()()(),v(4,"router-outlet")),i&2&&(l(3),m("Tabs",t.reportTabs))},dependencies:[ue,pe],styles:[".dropdown[_ngcontent-%COMP%] .dropdown-menu.report.show[_ngcontent-%COMP%]{top:100%!important;transform:none!important;z-index:10000;cursor:pointer;right:-50%}"]})}}return n})();var S=class{};var I=(()=>{class n{constructor(e){this.http=e}GetLoader(){return this.http.post("/api/Report/GetLoader",{})}GetSyncOrder(e){return new Promise((i,t)=>{this.http.post("/api/Report/Salesorder",JSON.stringify(e)).subscribe(s=>{i(s)})})}GetSyncInvoice(e){return new Promise((i,t)=>{this.http.post("/api/Report/CreateInvoice",JSON.stringify(e)).subscribe(s=>{i(s)})})}GetSyncVoidInvoice(e){return new Promise((i,t)=>{this.http.post("/api/Report/Void",JSON.stringify(e)).subscribe(s=>{i(s)})})}GetSyncConvertInvoice(e){return new Promise((i,t)=>{this.http.post("/api/Report/ConvertToInvoice",JSON.stringify(e)).subscribe(s=>{i(s)})})}GetSyncDelivery(e){return new Promise((i,t)=>{this.http.post("/api/Report/Delivery",JSON.stringify(e)).subscribe(s=>{i(s)})})}GetSyncPayment(e){return new Promise((i,t)=>{this.http.post("/api/Report/Payment",JSON.stringify(e)).subscribe(s=>{i(s)})})}getAllReport(e){return this.http.post("/api/Report/all",JSON.stringify(e))}static{this.\u0275fac=function(i){return new(i||n)(Y(he))}}static{this.\u0275prov=q({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();var O=function(n){return n[n.OK=200]="OK",n[n.BAD_REQUEST=400]="BAD_REQUEST",n[n.CONFLICT=409]="CONFLICT",n[n.NOT_FOUND=404]="NOT_FOUND",n[n.INTERNAL_SERVER_ERROR=500]="INTERNAL_SERVER_ERROR",n}(O||{});var De=()=>["/menu/log/order"],Ee=(n,c,e,i,t)=>({responseCode:n,From:c,to:e,actionType:i,ChannelID:t});function Oe(n,c){if(n&1&&(r(0,"th",6)(1,"div",7)(2,"h4"),p(3),a(),r(4,"small",8),p(5),a()()()),n&2){let e=c.$implicit,i=u();l(3),j(e),l(),$(i.getTextBgColor(e)),l(),j(i.getHeaderStatusDesc(e))}}function Re(n,c){if(n&1&&(r(0,"a",12),p(1),k(2,"number"),a()),n&2){let e=u().$implicit,i=u().$implicit,t=u();m("routerLink",re(5,De))("queryParams",oe(6,Ee,e.Key,t.fromQueryParam,t.toQueryParam,t.type,i.ChannelID)),l(),J(" ",B(2,3,e.Value)," ")}}function Le(n,c){n&1&&(r(0,"span",13),p(1,"-"),a())}function xe(n,c){if(n&1&&(r(0,"td",11),h(1,Re,3,12,"a",12)(2,Le,2,0,"span",13),a()),n&2){let e=c.$implicit;l(),H(e.Value?1:2)}}function Me(n,c){if(n&1&&(r(0,"tr")(1,"td")(2,"a",9),v(3,"img",10),a()(),r(4,"td")(5,"div")(6,"a",9),p(7),a()(),r(8,"div"),p(9),a()(),te(10,xe,3,1,"td",11,ee),a()),n&2){let e=c.$implicit,i=u();l(2),K("href",e.Url,G),l(),m("src",i.getChannelLogo(e.Type),G),l(3),K("href",e.Url,G),l(),j(e.Name),l(2),j(e.Url),l(),ie(e.list)}}function ke(n,c){if(n&1&&(r(0,"td",11)(1,"div",17),p(2),k(3,"number"),a()()),n&2){let e=c.$implicit;l(2),J(" ",B(3,1,e.total)," ")}}function Be(n,c){if(n&1&&(r(0,"tfoot")(1,"tr")(2,"td",14)(3,"div",15),p(4,"Total"),a()(),h(5,ke,4,3,"td",16),a()()),n&2){let e=u();l(5),m("ngForOf",e.logsCalculation())}}var D=(()=>{class n{constructor(){this.header=V(),this.result=V(),this.orderedHeader=U(()=>this.header().sort((e,i)=>e-i)),this.logsOrdered=U(()=>{let e=this.result();return e=e.map(i=>(this.orderedHeader().forEach(t=>{i.list.findIndex(o=>o.Key===t)===-1&&i.list.push({Key:t,Value:0}),i.list.sort((o,A)=>o.Key-A.Key)}),i)),e}),this.logsCalculation=U(()=>{let e=this.concatStatusCode(),i=[];return this.orderedHeader().forEach(t=>{let o=e.filter(A=>A.Key===t).reduce((A,we)=>A+we.Value,0);i.push({status:t,total:o})}),i}),this.type=null,this.headerStatus=O,this.listCalculationStatusCode=[]}set from(e){e&&(this.fromQueryParam=new Date(e).toJSON().toString())}set to(e){e&&(this.toQueryParam=new Date(e).toJSON().toString())}getHeaderStatusDesc(e){let i=null;switch(e){case O.BAD_REQUEST:i="BAD REQUEST";break;case O.CONFLICT:i="CONFLICT";break;case O.INTERNAL_SERVER_ERROR:i="INTERNAL SERVER ERROR";break;case O.NOT_FOUND:i="NOT FOUND";break;default:i="OK";break}return i}getTextBgColor(e){let i=null;switch(e){case O.OK:i="bg-success";break;case O.INTERNAL_SERVER_ERROR:i="bg-danger";break;default:i="bg-warning";break}return i}getChannelLogo(e){return d.getChannelLogoByTypeId(e)}concatStatusCode(){return this.logsOrdered().map(e=>e.list).reduce((e,i)=>[...e,...i],[])}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275cmp=T({type:n,selectors:[["app-table-report"]],inputs:{header:[1,"header"],result:[1,"result"],from:"from",to:"to",type:"type"},standalone:!1,decls:10,vars:3,consts:[[1,"table"],[1,"thead-light","sticky-top-thead"],[2,"width","0%"],[2,"width","5%"],["class","text-start","style","width: 10%",4,"ngFor","ngForOf"],[4,"ngFor","ngForOf"],[1,"text-start",2,"width","10%"],[1,"d-block"],[1,"text-white","p-1","rounded","response-desc"],["target","_blank",3,"href"],[2,"width","24px","height","24px",3,"src"],[1,"text-start"],[1,"h3","text-primary","fw-bold","ms-1",3,"routerLink","queryParams"],[1,"h3","fw-bold","ms-1"],["colspan","2"],[1,"text-center","h3","fw-bold"],["class","text-start",4,"ngFor","ngForOf"],[1,"d-inline-block","h3","text-primary","fw-bold","ms-1"]],template:function(i,t){i&1&&(r(0,"table",0)(1,"thead",1)(2,"tr"),v(3,"th",2),r(4,"th",3),p(5,"Channel"),a(),h(6,Oe,6,4,"th",4),a()(),r(7,"tbody"),h(8,Me,12,5,"tr",5),a(),h(9,Be,6,1,"tfoot"),a()),i&2&&(l(6),m("ngForOf",t.orderedHeader()),l(2),m("ngForOf",t.logsOrdered()),l(),H(t.logsCalculation().length>0?9:-1))},dependencies:[ae,de,me],styles:[".response-desc[_ngcontent-%COMP%]{font-size:12px}"]})}}return n})();function Ne(n,c){if(n&1&&(r(0,"div",7)(1,"div",8),v(2,"app-table-report",9),a()()),n&2){let e=u();l(2),m("result",e.result)("header",e.header)("from",e.filter.From)("to",e.filter.To)("type",0)}}var ve=(()=>{class n{constructor(e,i){this.http=e,this.datePipe=i,this.filter=new S,this.pageTitle="New Order";let t=new Date;this.maxDate=t,this.minDate=d.addDays(t,6),this.filter.From=t,this.filter.To=t,this.updatePageTitle()}ngOnInit(){this.initPageLoader()}updatePageTitle(){let e=d.formatTitleFromDate(this.filter.From,this.filter.To),i=this.datePipe.transform(this.filter.From,e),t=this.datePipe.transform(this.filter.To,"dd MMM yyyy");this.pageTitle=`New Order (${e==null?"":i+"-"} ${t})`}initPageLoader(){this.http.GetLoader().subscribe(e=>{this.filter=e,this.getChannelLogs()})}getChannelLogs(){this.updatePageTitle(),this.http.GetSyncOrder(this.filter).then(e=>{this.header=e.Header,this.result=e.Body})}onFilter(){this.getChannelLogs()}static{this.\u0275fac=function(i){return new(i||n)(f(I),f(P))}}static{this.\u0275cmp=T({type:n,selectors:[["app-sales-order"]],standalone:!1,decls:12,vars:5,consts:[[3,"onSubmit","headerTitle","hideSearchBox"],[1,"fw-bold","mb-1"],[1,"mb-4"],["name","From",3,"dateChange","date"],["name","To",3,"dateChange","date"],[1,"container-fluid"],["class","row mt-4",4,"ngIf"],[1,"row","mt-4"],[1,"col-md-12"],[3,"result","header","from","to","type"]],template:function(i,t){i&1&&(r(0,"mainpanel",0),b("onSubmit",function(){return t.getChannelLogs()}),r(1,"filters")(2,"div")(3,"label",1),p(4,"From/To"),a(),r(5,"div",2)(6,"datepicker",3),C("dateChange",function(o){return g(t.filter.From,o)||(t.filter.From=o),o}),a()(),r(7,"div")(8,"datepicker",4),C("dateChange",function(o){return g(t.filter.To,o)||(t.filter.To=o),o}),a()()()(),r(9,"content")(10,"div",5),h(11,Ne,3,5,"div",6),a()()()),i&2&&(m("headerTitle",t.pageTitle)("hideSearchBox",!0),l(6),y("date",t.filter.From),l(2),y("date",t.filter.To),l(3),m("ngIf",t.result))},dependencies:[F,w,_,D],encapsulation:2})}}return n})();function We(n,c){if(n&1&&(r(0,"div",7)(1,"div",8),v(2,"app-table-report",9),a()()),n&2){let e=u();l(2),m("result",e.result)("header",e.header)("from",e.filter.From)("to",e.filter.To)("type",1)}}var Te=(()=>{class n{constructor(e,i){this.http=e,this.datePipe=i,this.filter=new S,this.PageTitle="Ready to Ship";let t=new Date;this.maxDate=t,this.minDate=d.addDays(t,6),this.filter.From=t,this.filter.To=t,this.updatePageTitle()}ngOnInit(){this.initPageLoader()}updatePageTitle(){let e=d.formatTitleFromDate(this.filter.From,this.filter.To),i=this.datePipe.transform(this.filter.From,e),t=this.datePipe.transform(this.filter.To,"dd MMM yyyy");this.PageTitle=`Ready to Ship (${e==null?"":i+"-"} ${t})`}initPageLoader(){this.http.GetLoader().subscribe(e=>{this.filter=e,this.getChannelLogs()})}getChannelLogs(){this.updatePageTitle(),this.http.GetSyncInvoice(this.filter).then(e=>{this.header=e.Header,this.result=e.Body})}onFilter(){this.getChannelLogs()}static{this.\u0275fac=function(i){return new(i||n)(f(I),f(P))}}static{this.\u0275cmp=T({type:n,selectors:[["app-invoice"]],standalone:!1,decls:12,vars:5,consts:[[3,"onSubmit","headerTitle","hideSearchBox"],[1,"fw-bold","mb-1"],[1,"mb-4"],["name","From",3,"dateChange","date"],["name","To",3,"dateChange","date"],[1,"container-fluid"],["class","row mt-4",4,"ngIf"],[1,"row","mt-4"],[1,"col-md-12"],[3,"result","header","from","to","type"]],template:function(i,t){i&1&&(r(0,"mainpanel",0),b("onSubmit",function(){return t.onFilter()}),r(1,"filters")(2,"div")(3,"label",1),p(4,"From/To"),a(),r(5,"div",2)(6,"datepicker",3),C("dateChange",function(o){return g(t.filter.From,o)||(t.filter.From=o),o}),a()(),r(7,"div")(8,"datepicker",4),C("dateChange",function(o){return g(t.filter.To,o)||(t.filter.To=o),o}),a()()()(),r(9,"content")(10,"div",5),h(11,We,3,5,"div",6),a()()()),i&2&&(m("headerTitle",t.PageTitle)("hideSearchBox",!0),l(6),y("date",t.filter.From),l(2),y("date",t.filter.To),l(3),m("ngIf",t.result))},dependencies:[F,w,_,D],encapsulation:2})}}return n})();function Ae(n,c){if(n&1&&(r(0,"div",8)(1,"div",9),v(2,"app-table-report",10),a()()),n&2){let e=u();l(2),m("result",e.result)("header",e.header)("from",e.filter.From)("to",e.filter.To)("type",3)}}var _e=(()=>{class n{constructor(e,i){this.http=e,this.datePipe=i,this.filter=new S;let t=new Date;this.maxDate=t,this.minDate=d.addDays(t,6),this.filter.From=t,this.filter.To=t,this.updatePageTitle()}ngOnInit(){this.initPageLoader()}updatePageTitle(){let e=d.formatTitleFromDate(this.filter.From,this.filter.To),i=this.datePipe.transform(this.filter.From,e),t=this.datePipe.transform(this.filter.To,"dd MMM yyyy");this.PageTitle=`Shipped (${e==null?"":i+"-"} ${t})`}initPageLoader(){this.http.GetLoader().subscribe(e=>{this.filter=e,this.getChannelLogs()})}getChannelLogs(){this.updatePageTitle(),this.http.GetSyncDelivery(this.filter).then(e=>{this.header=e.Header,this.result=e.Body})}onFilter(){this.getChannelLogs()}static{this.\u0275fac=function(i){return new(i||n)(f(I),f(P))}}static{this.\u0275cmp=T({type:n,selectors:[["app-delivery"]],standalone:!1,decls:12,vars:5,consts:[[3,"onSubmit","headerTitle","hideSearchBox"],[1,"filterDate"],[1,"fw-bold","mb-1"],[1,"mb-4"],["name","From",3,"dateChange","date"],["name","To",3,"dateChange","date"],[1,"container-fluid"],["class","row mt-4",4,"ngIf"],[1,"row","mt-4"],[1,"col-md-12"],[3,"result","header","from","to","type"]],template:function(i,t){i&1&&(r(0,"mainpanel",0),b("onSubmit",function(){return t.onFilter()}),r(1,"filters")(2,"div",1)(3,"label",2),p(4,"From/To"),a(),r(5,"div",3)(6,"datepicker",4),C("dateChange",function(o){return g(t.filter.From,o)||(t.filter.From=o),o}),a()(),r(7,"div")(8,"datepicker",5),C("dateChange",function(o){return g(t.filter.To,o)||(t.filter.To=o),o}),a()()()(),r(9,"content")(10,"div",6),h(11,Ae,3,5,"div",7),a()()()),i&2&&(m("headerTitle",t.PageTitle)("hideSearchBox",!0),l(6),y("date",t.filter.From),l(2),y("date",t.filter.To),l(3),m("ngIf",t.result))},dependencies:[F,w,_,D],encapsulation:2})}}return n})();function je(n,c){if(n&1&&(r(0,"div",7)(1,"div",8),v(2,"app-table-report",9),a()()),n&2){let e=u();l(2),m("result",e.result)("header",e.header)("from",e.filter.From)("to",e.filter.To)("type",4)}}var Se=(()=>{class n{constructor(e,i){this.http=e,this.datePipe=i,this.filter=new S,this.PageTitle="Completed";let t=new Date;this.minDate=d.addDays(t,6),this.filter.From=t,this.filter.To=t,this.updatePageTitle()}ngOnInit(){this.initPageLoader()}updatePageTitle(){let e=d.formatTitleFromDate(this.filter.From,this.filter.To),i=this.datePipe.transform(this.filter.From,e),t=this.datePipe.transform(this.filter.To,"dd MMM yyyy");this.PageTitle=`Completed (${e==null?"":i+"-"} ${t})`}initPageLoader(){this.http.GetLoader().subscribe(e=>{this.filter=e,this.getChannelLogs()})}getChannelLogs(){this.updatePageTitle(),this.http.GetSyncPayment(this.filter).then(e=>{this.header=e.Header,this.result=e.Body})}onFilter(){this.getChannelLogs()}static{this.\u0275fac=function(i){return new(i||n)(f(I),f(P))}}static{this.\u0275cmp=T({type:n,selectors:[["app-payment"]],standalone:!1,decls:12,vars:5,consts:[[3,"onSubmit","headerTitle","hideSearchBox"],[1,"fw-bold","mb-1"],[1,"mb-4"],["name","From",3,"dateChange","date"],["name","To",3,"dateChange","date"],[1,"container-fluid"],["class","row mt-4",4,"ngIf"],[1,"row","mt-4"],[1,"col-md-12"],[3,"result","header","from","to","type"]],template:function(i,t){i&1&&(r(0,"mainpanel",0),b("onSubmit",function(){return t.onFilter()}),r(1,"filters")(2,"div")(3,"label",1),p(4,"From/To"),a(),r(5,"div",2)(6,"datepicker",3),C("dateChange",function(o){return g(t.filter.From,o)||(t.filter.From=o),o}),a()(),r(7,"div")(8,"datepicker",4),C("dateChange",function(o){return g(t.filter.To,o)||(t.filter.To=o),o}),a()()()(),r(9,"content")(10,"div",5),h(11,je,3,5,"div",6),a()()()),i&2&&(m("headerTitle",t.PageTitle)("hideSearchBox",!0),l(6),y("date",t.filter.From),l(2),y("date",t.filter.To),l(3),m("ngIf",t.result))},dependencies:[F,w,_,D],encapsulation:2})}}return n})();function Ge(n,c){n&1&&ne(0)}function Ue(n,c){if(n&1&&(r(0,"div",8)(1,"div",9),v(2,"app-table-report",10),a()()),n&2){let e=c.ngIf,i=u();l(2),m("result",e.Body)("header",e.Header)("from",i.filter==null?null:i.filter.From)("to",i.filter==null?null:i.filter.To)}}var be=(()=>{class n{constructor(e,i){this.reportOrderService=e,this.datePipe=i,this.filter=new S}ngOnInit(){this.initFilter(),this.initLoader()}initFilter(){let e=new Date;this.minDate=d.addDays(e,6),this.filter.From=e,this.filter.To=e,this.updatePageTitle()}updatePageTitle(){let e=d.formatTitleFromDate(this.filter.From,this.filter.To),i=this.datePipe.transform(this.filter.From,e),t=this.datePipe.transform(this.filter.To,"dd MMM yyyy");this.pageTitle=`All (${e==null?"":i+"-"} ${t})`}initLoader(){this.pageLoader$=this.reportOrderService.GetLoader().pipe(z(e=>{this.filter=e,this.updatePageTitle(),this.initData()}))}initData(){this.reportData$=this.reportOrderService.getAllReport(this.filter).pipe(Q())}onFilter(){this.updatePageTitle(),this.initData()}static{this.\u0275fac=function(i){return new(i||n)(f(I),f(P))}}static{this.\u0275cmp=T({type:n,selectors:[["app-all"]],standalone:!1,decls:15,vars:10,consts:[[3,"onSubmit","headerTitle","hideSearchBox"],[1,"fw-bold","mb-1"],[1,"mb-4"],["name","From",3,"dateChange","date"],["name","To",3,"dateChange","date"],[1,"container-fluid"],[4,"ngIf"],["class","row mt-4",4,"ngIf"],[1,"row","mt-4"],[1,"col-md-12"],[3,"result","header","from","to"]],template:function(i,t){i&1&&(r(0,"mainpanel",0),b("onSubmit",function(){return t.onFilter()}),r(1,"filters")(2,"div")(3,"label",1),p(4,"From/To"),a(),r(5,"div",2)(6,"datepicker",3),C("dateChange",function(o){return g(t.filter.From,o)||(t.filter.From=o),o}),a()(),r(7,"div")(8,"datepicker",4),C("dateChange",function(o){return g(t.filter.To,o)||(t.filter.To=o),o}),a()()()(),r(9,"content")(10,"div",5),h(11,Ge,1,0,"ng-container",6),k(12,"async"),h(13,Ue,3,4,"div",7),k(14,"async"),a()()()),i&2&&(m("headerTitle",t.pageTitle)("hideSearchBox",!0),l(6),y("date",t.filter.From),l(2),y("date",t.filter.To),l(3),m("ngIf",B(12,6,t.pageLoader$)),l(2),m("ngIf",B(14,8,t.reportData$)))},dependencies:[F,w,_,D,le],encapsulation:2})}}return n})();function Ve(n,c){if(n&1&&(r(0,"div",7)(1,"div",8),v(2,"app-table-report",9),a()()),n&2){let e=u();l(2),m("result",e.result)("header",e.header)("from",e.filter.From)("to",e.filter.To)("type",1)}}var Fe=(()=>{class n{constructor(e,i){this.http=e,this.datePipe=i,this.filter=new S,this.PageTitle="Convert Sales Order To Invoice";let t=new Date;this.maxDate=t,this.minDate=d.addDays(t,6),this.filter.From=t,this.filter.To=t,this.updatePageTitle()}ngOnInit(){this.initPageLoader()}updatePageTitle(){let e=d.formatTitleFromDate(this.filter.From,this.filter.To),i=this.datePipe.transform(this.filter.From,e),t=this.datePipe.transform(this.filter.To,"dd MMM yyyy");this.PageTitle=`Convert Sales Order To Invoice (${e==null?"":i+"-"} ${t})`}initPageLoader(){this.http.GetLoader().subscribe(e=>{this.filter=e,this.getChannelLogs()})}getChannelLogs(){this.updatePageTitle(),this.http.GetSyncInvoice(this.filter).then(e=>{this.header=e.Header,this.result=e.Body})}onFilter(){this.getChannelLogs()}static{this.\u0275fac=function(i){return new(i||n)(f(I),f(P))}}static{this.\u0275cmp=T({type:n,selectors:[["app-convert-invoice"]],standalone:!1,decls:12,vars:5,consts:[[3,"onSubmit","headerTitle","hideSearchBox"],[1,"fw-bold","mb-1"],[1,"mb-4"],["name","From",3,"dateChange","date"],["name","To",3,"dateChange","date"],[1,"container-fluid"],["class","row mt-4",4,"ngIf"],[1,"row","mt-4"],[1,"col-md-12"],[3,"result","header","from","to","type"]],template:function(i,t){i&1&&(r(0,"mainpanel",0),b("onSubmit",function(){return t.onFilter()}),r(1,"filters")(2,"div")(3,"label",1),p(4,"From/To"),a(),r(5,"div",2)(6,"datepicker",3),C("dateChange",function(o){return g(t.filter.From,o)||(t.filter.From=o),o}),a()(),r(7,"div")(8,"datepicker",4),C("dateChange",function(o){return g(t.filter.To,o)||(t.filter.To=o),o}),a()()()(),r(9,"content")(10,"div",5),h(11,Ve,3,5,"div",6),a()()()),i&2&&(m("headerTitle",t.PageTitle)("hideSearchBox",!0),l(6),y("date",t.filter.From),l(2),y("date",t.filter.To),l(3),m("ngIf",t.result))},dependencies:[F,w,_,D],encapsulation:2})}}return n})();function He(n,c){if(n&1&&(r(0,"div",7)(1,"div",8),v(2,"app-table-report",9),a()()),n&2){let e=u();l(2),m("result",e.result)("header",e.header)("from",e.filter.From)("to",e.filter.To)("type",1)}}var Pe=(()=>{class n{constructor(e,i){this.http=e,this.datePipe=i,this.filter=new S,this.PageTitle="Ready to Ship";let t=new Date;this.maxDate=t,this.minDate=d.addDays(t,6),this.filter.From=t,this.filter.To=t,this.updatePageTitle()}ngOnInit(){this.initPageLoader()}updatePageTitle(){let e=d.formatTitleFromDate(this.filter.From,this.filter.To),i=this.datePipe.transform(this.filter.From,e),t=this.datePipe.transform(this.filter.To,"dd MMM yyyy");this.PageTitle=`Ready to Ship (${e==null?"":i+"-"} ${t})`}initPageLoader(){this.http.GetLoader().subscribe(e=>{this.filter=e,this.getChannelLogs()})}getChannelLogs(){this.updatePageTitle(),this.http.GetSyncInvoice(this.filter).then(e=>{this.header=e.Header,this.result=e.Body})}onFilter(){this.getChannelLogs()}static{this.\u0275fac=function(i){return new(i||n)(f(I),f(P))}}static{this.\u0275cmp=T({type:n,selectors:[["app-void-invoice"]],standalone:!1,decls:12,vars:5,consts:[[3,"onSubmit","headerTitle","hideSearchBox"],[1,"fw-bold","mb-1"],[1,"mb-4"],["name","From",3,"dateChange","date"],["name","To",3,"dateChange","date"],[1,"container-fluid"],["class","row mt-4",4,"ngIf"],[1,"row","mt-4"],[1,"col-md-12"],[3,"result","header","from","to","type"]],template:function(i,t){i&1&&(r(0,"mainpanel",0),b("onSubmit",function(){return t.onFilter()}),r(1,"filters")(2,"div")(3,"label",1),p(4,"From/To"),a(),r(5,"div",2)(6,"datepicker",3),C("dateChange",function(o){return g(t.filter.From,o)||(t.filter.From=o),o}),a()(),r(7,"div")(8,"datepicker",4),C("dateChange",function(o){return g(t.filter.To,o)||(t.filter.To=o),o}),a()()()(),r(9,"content")(10,"div",5),h(11,He,3,5,"div",6),a()()()),i&2&&(m("headerTitle",t.PageTitle)("hideSearchBox",!0),l(6),y("date",t.filter.From),l(2),y("date",t.filter.To),l(3),m("ngIf",t.result))},dependencies:[F,w,_,D],encapsulation:2})}}return n})();var Ke=[{path:"",component:Ce,children:[{path:"",redirectTo:"all",pathMatch:"full"},{path:"sync-order",component:ve,canActivate:[R],data:{title:"Sync Order"}},{path:"convert-to-invoice",component:Fe,canActivate:[R],data:{title:"Sync Convert to Invoice"}},{path:"invoice",component:Te,canActivate:[R],data:{title:"Sync Invoice"}},{path:"delivery",component:_e,canActivate:[R],data:{title:"Sync Delivery"}},{path:"payment",component:Se,canActivate:[R],data:{title:"Sync Payment"}},{path:"void-invoice",component:Pe,canActivate:[R],data:{title:"Sync void invoice"}},{path:"all",component:be,canActivate:[R],data:{title:"All Report"}}]}],Gt=(()=>{class n{static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275mod=Z({type:n})}static{this.\u0275inj=X({imports:[se,ye,fe,ge,_,ce.forChild(Ke)]})}}return n})();export{Gt as OrderModule};
|
|
1
|
+
import{a as _}from"./chunk-PFXOFSJG.js";import"./chunk-BQIB3N6V.js";import"./chunk-B67DSLBY.js";import{a as R}from"./chunk-DDVDUCPY.js";import"./chunk-6RLISMEX.js";import"./chunk-TH6VZX34.js";import"./chunk-QS22J2SC.js";import"./chunk-QP4C4R4W.js";import"./chunk-5LQRO4AI.js";import"./chunk-MO53T3IK.js";import"./chunk-W3JTS22H.js";import"./chunk-SDUUFQUI.js";import"./chunk-6L7TD5DW.js";import"./chunk-WLRPCY65.js";import"./chunk-3RK6DDJD.js";import"./chunk-3UN6FPMN.js";import"./chunk-LDPDLCRL.js";import{a as ue,b as ye}from"./chunk-A64VIOKR.js";import"./chunk-JVNHFIYT.js";import"./chunk-6VHVQEVM.js";import"./chunk-Z3ITXK3D.js";import"./chunk-ACIMXBIC.js";import"./chunk-J53BPEDH.js";import"./chunk-TGMCGROM.js";import"./chunk-RDRNWLJI.js";import{e as he}from"./chunk-W5L6FMO3.js";import"./chunk-K5XRGNWG.js";import{c as d}from"./chunk-PW42BQIY.js";import{m as w,n as ge}from"./chunk-FO7G4GMY.js";import{A as fe}from"./chunk-5PS6ZS3N.js";import"./chunk-V3USB3ZU.js";import"./chunk-ERXVXBTU.js";import"./chunk-NNRBGHXB.js";import"./chunk-BJUPMCEP.js";import{F as pe,H as de,J as ce,f as ae,g as F,j as le,k as P,m as me,n as se}from"./chunk-FXQKRJWU.js";import{$c as k,Gb as T,Gc as p,Hb as Z,Hc as j,Ic as J,Kc as y,Lc as g,Mb as h,Mc as C,Oa as V,Rc as re,Wc as oe,Yb as m,Z as Q,ac as $,ad as B,dc as H,ea as z,ec as ee,gc as te,hc as ie,ic as r,ja as q,jc as a,ka as X,kc as v,nc as ne,oa as Y,pb as G,rb as l,rd as U,tc as b,uc as u,xb as f,xc as K}from"./chunk-OJMQBH6T.js";import"./chunk-EU2KAMEK.js";import"./chunk-66YHNWRR.js";var Ce=(()=>{class n{constructor(){this.reportTabs=[{Title:"1.Create Order",Url:"/menu/sync-log/order/sync-order"},{Title:"2.Convert Order To Invoice",Url:"/menu/sync-log/order/convert-to-invoice"},{Title:"3.Create Invoice",Url:"/menu/sync-log/order/invoice"},{Title:"4.Create Outbound Logistic",Url:"/menu/sync-log/order/delivery"},{Title:"5.Add Payment",Url:"/menu/sync-log/order/payment"},{Title:"6.Void Invoice",Url:"/menu/sync-log/order/void-invoice"},{Title:"All",Url:"/menu/sync-log/order/all"}]}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275cmp=T({type:n,selectors:[["app-order"]],standalone:!1,decls:5,vars:1,consts:[[1,"navbar","page-nav","navbar-default","py-0","navbar-expand-lg"],[1,"container-fluid"],[3,"Tabs"]],template:function(i,t){i&1&&(r(0,"nav",0)(1,"div",1)(2,"div"),v(3,"nav-tab",2),a()()(),v(4,"router-outlet")),i&2&&(l(3),m("Tabs",t.reportTabs))},dependencies:[ue,pe],styles:[".dropdown[_ngcontent-%COMP%] .dropdown-menu.report.show[_ngcontent-%COMP%]{top:100%!important;transform:none!important;z-index:10000;cursor:pointer;right:-50%}"]})}}return n})();var S=class{};var I=(()=>{class n{constructor(e){this.http=e}GetLoader(){return this.http.post("/api/Report/GetLoader",{})}GetSyncOrder(e){return new Promise((i,t)=>{this.http.post("/api/Report/Salesorder",JSON.stringify(e)).subscribe(s=>{i(s)})})}GetSyncInvoice(e){return new Promise((i,t)=>{this.http.post("/api/Report/CreateInvoice",JSON.stringify(e)).subscribe(s=>{i(s)})})}GetSyncVoidInvoice(e){return new Promise((i,t)=>{this.http.post("/api/Report/Void",JSON.stringify(e)).subscribe(s=>{i(s)})})}GetSyncConvertInvoice(e){return new Promise((i,t)=>{this.http.post("/api/Report/ConvertToInvoice",JSON.stringify(e)).subscribe(s=>{i(s)})})}GetSyncDelivery(e){return new Promise((i,t)=>{this.http.post("/api/Report/Delivery",JSON.stringify(e)).subscribe(s=>{i(s)})})}GetSyncPayment(e){return new Promise((i,t)=>{this.http.post("/api/Report/Payment",JSON.stringify(e)).subscribe(s=>{i(s)})})}getAllReport(e){return this.http.post("/api/Report/all",JSON.stringify(e))}static{this.\u0275fac=function(i){return new(i||n)(Y(he))}}static{this.\u0275prov=q({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();var O=function(n){return n[n.OK=200]="OK",n[n.BAD_REQUEST=400]="BAD_REQUEST",n[n.CONFLICT=409]="CONFLICT",n[n.NOT_FOUND=404]="NOT_FOUND",n[n.INTERNAL_SERVER_ERROR=500]="INTERNAL_SERVER_ERROR",n}(O||{});var De=()=>["/menu/log/order"],Ee=(n,c,e,i,t)=>({responseCode:n,From:c,to:e,actionType:i,ChannelID:t});function Oe(n,c){if(n&1&&(r(0,"th",6)(1,"div",7)(2,"h4"),p(3),a(),r(4,"small",8),p(5),a()()()),n&2){let e=c.$implicit,i=u();l(3),j(e),l(),$(i.getTextBgColor(e)),l(),j(i.getHeaderStatusDesc(e))}}function Re(n,c){if(n&1&&(r(0,"a",12),p(1),k(2,"number"),a()),n&2){let e=u().$implicit,i=u().$implicit,t=u();m("routerLink",re(5,De))("queryParams",oe(6,Ee,e.Key,t.fromQueryParam,t.toQueryParam,t.type,i.ChannelID)),l(),J(" ",B(2,3,e.Value)," ")}}function Le(n,c){n&1&&(r(0,"span",13),p(1,"-"),a())}function xe(n,c){if(n&1&&(r(0,"td",11),h(1,Re,3,12,"a",12)(2,Le,2,0,"span",13),a()),n&2){let e=c.$implicit;l(),H(e.Value?1:2)}}function Me(n,c){if(n&1&&(r(0,"tr")(1,"td")(2,"a",9),v(3,"img",10),a()(),r(4,"td")(5,"div")(6,"a",9),p(7),a()(),r(8,"div"),p(9),a()(),te(10,xe,3,1,"td",11,ee),a()),n&2){let e=c.$implicit,i=u();l(2),K("href",e.Url,G),l(),m("src",i.getChannelLogo(e.Type),G),l(3),K("href",e.Url,G),l(),j(e.Name),l(2),j(e.Url),l(),ie(e.list)}}function ke(n,c){if(n&1&&(r(0,"td",11)(1,"div",17),p(2),k(3,"number"),a()()),n&2){let e=c.$implicit;l(2),J(" ",B(3,1,e.total)," ")}}function Be(n,c){if(n&1&&(r(0,"tfoot")(1,"tr")(2,"td",14)(3,"div",15),p(4,"Total"),a()(),h(5,ke,4,3,"td",16),a()()),n&2){let e=u();l(5),m("ngForOf",e.logsCalculation())}}var D=(()=>{class n{constructor(){this.header=V(),this.result=V(),this.orderedHeader=U(()=>this.header().sort((e,i)=>e-i)),this.logsOrdered=U(()=>{let e=this.result();return e=e.map(i=>(this.orderedHeader().forEach(t=>{i.list.findIndex(o=>o.Key===t)===-1&&i.list.push({Key:t,Value:0}),i.list.sort((o,A)=>o.Key-A.Key)}),i)),e}),this.logsCalculation=U(()=>{let e=this.concatStatusCode(),i=[];return this.orderedHeader().forEach(t=>{let o=e.filter(A=>A.Key===t).reduce((A,we)=>A+we.Value,0);i.push({status:t,total:o})}),i}),this.type=null,this.headerStatus=O,this.listCalculationStatusCode=[]}set from(e){e&&(this.fromQueryParam=new Date(e).toJSON().toString())}set to(e){e&&(this.toQueryParam=new Date(e).toJSON().toString())}getHeaderStatusDesc(e){let i=null;switch(e){case O.BAD_REQUEST:i="BAD REQUEST";break;case O.CONFLICT:i="CONFLICT";break;case O.INTERNAL_SERVER_ERROR:i="INTERNAL SERVER ERROR";break;case O.NOT_FOUND:i="NOT FOUND";break;default:i="OK";break}return i}getTextBgColor(e){let i=null;switch(e){case O.OK:i="bg-success";break;case O.INTERNAL_SERVER_ERROR:i="bg-danger";break;default:i="bg-warning";break}return i}getChannelLogo(e){return d.getChannelLogoByTypeId(e)}concatStatusCode(){return this.logsOrdered().map(e=>e.list).reduce((e,i)=>[...e,...i],[])}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275cmp=T({type:n,selectors:[["app-table-report"]],inputs:{header:[1,"header"],result:[1,"result"],from:"from",to:"to",type:"type"},standalone:!1,decls:10,vars:3,consts:[[1,"table"],[1,"thead-light","sticky-top-thead"],[2,"width","0%"],[2,"width","5%"],["class","text-start","style","width: 10%",4,"ngFor","ngForOf"],[4,"ngFor","ngForOf"],[1,"text-start",2,"width","10%"],[1,"d-block"],[1,"text-white","p-1","rounded","response-desc"],["target","_blank",3,"href"],[2,"width","24px","height","24px",3,"src"],[1,"text-start"],[1,"h3","text-primary","fw-bold","ms-1",3,"routerLink","queryParams"],[1,"h3","fw-bold","ms-1"],["colspan","2"],[1,"text-center","h3","fw-bold"],["class","text-start",4,"ngFor","ngForOf"],[1,"d-inline-block","h3","text-primary","fw-bold","ms-1"]],template:function(i,t){i&1&&(r(0,"table",0)(1,"thead",1)(2,"tr"),v(3,"th",2),r(4,"th",3),p(5,"Channel"),a(),h(6,Oe,6,4,"th",4),a()(),r(7,"tbody"),h(8,Me,12,5,"tr",5),a(),h(9,Be,6,1,"tfoot"),a()),i&2&&(l(6),m("ngForOf",t.orderedHeader()),l(2),m("ngForOf",t.logsOrdered()),l(),H(t.logsCalculation().length>0?9:-1))},dependencies:[ae,de,me],styles:[".response-desc[_ngcontent-%COMP%]{font-size:12px}"]})}}return n})();function Ne(n,c){if(n&1&&(r(0,"div",7)(1,"div",8),v(2,"app-table-report",9),a()()),n&2){let e=u();l(2),m("result",e.result)("header",e.header)("from",e.filter.From)("to",e.filter.To)("type",0)}}var ve=(()=>{class n{constructor(e,i){this.http=e,this.datePipe=i,this.filter=new S,this.pageTitle="New Order";let t=new Date;this.maxDate=t,this.minDate=d.addDays(t,6),this.filter.From=t,this.filter.To=t,this.updatePageTitle()}ngOnInit(){this.initPageLoader()}updatePageTitle(){let e=d.formatTitleFromDate(this.filter.From,this.filter.To),i=this.datePipe.transform(this.filter.From,e),t=this.datePipe.transform(this.filter.To,"dd MMM yyyy");this.pageTitle=`New Order (${e==null?"":i+"-"} ${t})`}initPageLoader(){this.http.GetLoader().subscribe(e=>{this.filter=e,this.getChannelLogs()})}getChannelLogs(){this.updatePageTitle(),this.http.GetSyncOrder(this.filter).then(e=>{this.header=e.Header,this.result=e.Body})}onFilter(){this.getChannelLogs()}static{this.\u0275fac=function(i){return new(i||n)(f(I),f(P))}}static{this.\u0275cmp=T({type:n,selectors:[["app-sales-order"]],standalone:!1,decls:12,vars:5,consts:[[3,"onSubmit","headerTitle","hideSearchBox"],[1,"fw-bold","mb-1"],[1,"mb-4"],["name","From",3,"dateChange","date"],["name","To",3,"dateChange","date"],[1,"container-fluid"],["class","row mt-4",4,"ngIf"],[1,"row","mt-4"],[1,"col-md-12"],[3,"result","header","from","to","type"]],template:function(i,t){i&1&&(r(0,"mainpanel",0),b("onSubmit",function(){return t.getChannelLogs()}),r(1,"filters")(2,"div")(3,"label",1),p(4,"From/To"),a(),r(5,"div",2)(6,"datepicker",3),C("dateChange",function(o){return g(t.filter.From,o)||(t.filter.From=o),o}),a()(),r(7,"div")(8,"datepicker",4),C("dateChange",function(o){return g(t.filter.To,o)||(t.filter.To=o),o}),a()()()(),r(9,"content")(10,"div",5),h(11,Ne,3,5,"div",6),a()()()),i&2&&(m("headerTitle",t.pageTitle)("hideSearchBox",!0),l(6),y("date",t.filter.From),l(2),y("date",t.filter.To),l(3),m("ngIf",t.result))},dependencies:[F,w,_,D],encapsulation:2})}}return n})();function We(n,c){if(n&1&&(r(0,"div",7)(1,"div",8),v(2,"app-table-report",9),a()()),n&2){let e=u();l(2),m("result",e.result)("header",e.header)("from",e.filter.From)("to",e.filter.To)("type",1)}}var Te=(()=>{class n{constructor(e,i){this.http=e,this.datePipe=i,this.filter=new S,this.PageTitle="Ready to Ship";let t=new Date;this.maxDate=t,this.minDate=d.addDays(t,6),this.filter.From=t,this.filter.To=t,this.updatePageTitle()}ngOnInit(){this.initPageLoader()}updatePageTitle(){let e=d.formatTitleFromDate(this.filter.From,this.filter.To),i=this.datePipe.transform(this.filter.From,e),t=this.datePipe.transform(this.filter.To,"dd MMM yyyy");this.PageTitle=`Ready to Ship (${e==null?"":i+"-"} ${t})`}initPageLoader(){this.http.GetLoader().subscribe(e=>{this.filter=e,this.getChannelLogs()})}getChannelLogs(){this.updatePageTitle(),this.http.GetSyncInvoice(this.filter).then(e=>{this.header=e.Header,this.result=e.Body})}onFilter(){this.getChannelLogs()}static{this.\u0275fac=function(i){return new(i||n)(f(I),f(P))}}static{this.\u0275cmp=T({type:n,selectors:[["app-invoice"]],standalone:!1,decls:12,vars:5,consts:[[3,"onSubmit","headerTitle","hideSearchBox"],[1,"fw-bold","mb-1"],[1,"mb-4"],["name","From",3,"dateChange","date"],["name","To",3,"dateChange","date"],[1,"container-fluid"],["class","row mt-4",4,"ngIf"],[1,"row","mt-4"],[1,"col-md-12"],[3,"result","header","from","to","type"]],template:function(i,t){i&1&&(r(0,"mainpanel",0),b("onSubmit",function(){return t.onFilter()}),r(1,"filters")(2,"div")(3,"label",1),p(4,"From/To"),a(),r(5,"div",2)(6,"datepicker",3),C("dateChange",function(o){return g(t.filter.From,o)||(t.filter.From=o),o}),a()(),r(7,"div")(8,"datepicker",4),C("dateChange",function(o){return g(t.filter.To,o)||(t.filter.To=o),o}),a()()()(),r(9,"content")(10,"div",5),h(11,We,3,5,"div",6),a()()()),i&2&&(m("headerTitle",t.PageTitle)("hideSearchBox",!0),l(6),y("date",t.filter.From),l(2),y("date",t.filter.To),l(3),m("ngIf",t.result))},dependencies:[F,w,_,D],encapsulation:2})}}return n})();function Ae(n,c){if(n&1&&(r(0,"div",8)(1,"div",9),v(2,"app-table-report",10),a()()),n&2){let e=u();l(2),m("result",e.result)("header",e.header)("from",e.filter.From)("to",e.filter.To)("type",3)}}var _e=(()=>{class n{constructor(e,i){this.http=e,this.datePipe=i,this.filter=new S;let t=new Date;this.maxDate=t,this.minDate=d.addDays(t,6),this.filter.From=t,this.filter.To=t,this.updatePageTitle()}ngOnInit(){this.initPageLoader()}updatePageTitle(){let e=d.formatTitleFromDate(this.filter.From,this.filter.To),i=this.datePipe.transform(this.filter.From,e),t=this.datePipe.transform(this.filter.To,"dd MMM yyyy");this.PageTitle=`Shipped (${e==null?"":i+"-"} ${t})`}initPageLoader(){this.http.GetLoader().subscribe(e=>{this.filter=e,this.getChannelLogs()})}getChannelLogs(){this.updatePageTitle(),this.http.GetSyncDelivery(this.filter).then(e=>{this.header=e.Header,this.result=e.Body})}onFilter(){this.getChannelLogs()}static{this.\u0275fac=function(i){return new(i||n)(f(I),f(P))}}static{this.\u0275cmp=T({type:n,selectors:[["app-delivery"]],standalone:!1,decls:12,vars:5,consts:[[3,"onSubmit","headerTitle","hideSearchBox"],[1,"filterDate"],[1,"fw-bold","mb-1"],[1,"mb-4"],["name","From",3,"dateChange","date"],["name","To",3,"dateChange","date"],[1,"container-fluid"],["class","row mt-4",4,"ngIf"],[1,"row","mt-4"],[1,"col-md-12"],[3,"result","header","from","to","type"]],template:function(i,t){i&1&&(r(0,"mainpanel",0),b("onSubmit",function(){return t.onFilter()}),r(1,"filters")(2,"div",1)(3,"label",2),p(4,"From/To"),a(),r(5,"div",3)(6,"datepicker",4),C("dateChange",function(o){return g(t.filter.From,o)||(t.filter.From=o),o}),a()(),r(7,"div")(8,"datepicker",5),C("dateChange",function(o){return g(t.filter.To,o)||(t.filter.To=o),o}),a()()()(),r(9,"content")(10,"div",6),h(11,Ae,3,5,"div",7),a()()()),i&2&&(m("headerTitle",t.PageTitle)("hideSearchBox",!0),l(6),y("date",t.filter.From),l(2),y("date",t.filter.To),l(3),m("ngIf",t.result))},dependencies:[F,w,_,D],encapsulation:2})}}return n})();function je(n,c){if(n&1&&(r(0,"div",7)(1,"div",8),v(2,"app-table-report",9),a()()),n&2){let e=u();l(2),m("result",e.result)("header",e.header)("from",e.filter.From)("to",e.filter.To)("type",4)}}var Se=(()=>{class n{constructor(e,i){this.http=e,this.datePipe=i,this.filter=new S,this.PageTitle="Completed";let t=new Date;this.minDate=d.addDays(t,6),this.filter.From=t,this.filter.To=t,this.updatePageTitle()}ngOnInit(){this.initPageLoader()}updatePageTitle(){let e=d.formatTitleFromDate(this.filter.From,this.filter.To),i=this.datePipe.transform(this.filter.From,e),t=this.datePipe.transform(this.filter.To,"dd MMM yyyy");this.PageTitle=`Completed (${e==null?"":i+"-"} ${t})`}initPageLoader(){this.http.GetLoader().subscribe(e=>{this.filter=e,this.getChannelLogs()})}getChannelLogs(){this.updatePageTitle(),this.http.GetSyncPayment(this.filter).then(e=>{this.header=e.Header,this.result=e.Body})}onFilter(){this.getChannelLogs()}static{this.\u0275fac=function(i){return new(i||n)(f(I),f(P))}}static{this.\u0275cmp=T({type:n,selectors:[["app-payment"]],standalone:!1,decls:12,vars:5,consts:[[3,"onSubmit","headerTitle","hideSearchBox"],[1,"fw-bold","mb-1"],[1,"mb-4"],["name","From",3,"dateChange","date"],["name","To",3,"dateChange","date"],[1,"container-fluid"],["class","row mt-4",4,"ngIf"],[1,"row","mt-4"],[1,"col-md-12"],[3,"result","header","from","to","type"]],template:function(i,t){i&1&&(r(0,"mainpanel",0),b("onSubmit",function(){return t.onFilter()}),r(1,"filters")(2,"div")(3,"label",1),p(4,"From/To"),a(),r(5,"div",2)(6,"datepicker",3),C("dateChange",function(o){return g(t.filter.From,o)||(t.filter.From=o),o}),a()(),r(7,"div")(8,"datepicker",4),C("dateChange",function(o){return g(t.filter.To,o)||(t.filter.To=o),o}),a()()()(),r(9,"content")(10,"div",5),h(11,je,3,5,"div",6),a()()()),i&2&&(m("headerTitle",t.PageTitle)("hideSearchBox",!0),l(6),y("date",t.filter.From),l(2),y("date",t.filter.To),l(3),m("ngIf",t.result))},dependencies:[F,w,_,D],encapsulation:2})}}return n})();function Ge(n,c){n&1&&ne(0)}function Ue(n,c){if(n&1&&(r(0,"div",8)(1,"div",9),v(2,"app-table-report",10),a()()),n&2){let e=c.ngIf,i=u();l(2),m("result",e.Body)("header",e.Header)("from",i.filter==null?null:i.filter.From)("to",i.filter==null?null:i.filter.To)}}var be=(()=>{class n{constructor(e,i){this.reportOrderService=e,this.datePipe=i,this.filter=new S}ngOnInit(){this.initFilter(),this.initLoader()}initFilter(){let e=new Date;this.minDate=d.addDays(e,6),this.filter.From=e,this.filter.To=e,this.updatePageTitle()}updatePageTitle(){let e=d.formatTitleFromDate(this.filter.From,this.filter.To),i=this.datePipe.transform(this.filter.From,e),t=this.datePipe.transform(this.filter.To,"dd MMM yyyy");this.pageTitle=`All (${e==null?"":i+"-"} ${t})`}initLoader(){this.pageLoader$=this.reportOrderService.GetLoader().pipe(z(e=>{this.filter=e,this.updatePageTitle(),this.initData()}))}initData(){this.reportData$=this.reportOrderService.getAllReport(this.filter).pipe(Q())}onFilter(){this.updatePageTitle(),this.initData()}static{this.\u0275fac=function(i){return new(i||n)(f(I),f(P))}}static{this.\u0275cmp=T({type:n,selectors:[["app-all"]],standalone:!1,decls:15,vars:10,consts:[[3,"onSubmit","headerTitle","hideSearchBox"],[1,"fw-bold","mb-1"],[1,"mb-4"],["name","From",3,"dateChange","date"],["name","To",3,"dateChange","date"],[1,"container-fluid"],[4,"ngIf"],["class","row mt-4",4,"ngIf"],[1,"row","mt-4"],[1,"col-md-12"],[3,"result","header","from","to"]],template:function(i,t){i&1&&(r(0,"mainpanel",0),b("onSubmit",function(){return t.onFilter()}),r(1,"filters")(2,"div")(3,"label",1),p(4,"From/To"),a(),r(5,"div",2)(6,"datepicker",3),C("dateChange",function(o){return g(t.filter.From,o)||(t.filter.From=o),o}),a()(),r(7,"div")(8,"datepicker",4),C("dateChange",function(o){return g(t.filter.To,o)||(t.filter.To=o),o}),a()()()(),r(9,"content")(10,"div",5),h(11,Ge,1,0,"ng-container",6),k(12,"async"),h(13,Ue,3,4,"div",7),k(14,"async"),a()()()),i&2&&(m("headerTitle",t.pageTitle)("hideSearchBox",!0),l(6),y("date",t.filter.From),l(2),y("date",t.filter.To),l(3),m("ngIf",B(12,6,t.pageLoader$)),l(2),m("ngIf",B(14,8,t.reportData$)))},dependencies:[F,w,_,D,le],encapsulation:2})}}return n})();function Ve(n,c){if(n&1&&(r(0,"div",7)(1,"div",8),v(2,"app-table-report",9),a()()),n&2){let e=u();l(2),m("result",e.result)("header",e.header)("from",e.filter.From)("to",e.filter.To)("type",1)}}var Fe=(()=>{class n{constructor(e,i){this.http=e,this.datePipe=i,this.filter=new S,this.PageTitle="Convert Sales Order To Invoice";let t=new Date;this.maxDate=t,this.minDate=d.addDays(t,6),this.filter.From=t,this.filter.To=t,this.updatePageTitle()}ngOnInit(){this.initPageLoader()}updatePageTitle(){let e=d.formatTitleFromDate(this.filter.From,this.filter.To),i=this.datePipe.transform(this.filter.From,e),t=this.datePipe.transform(this.filter.To,"dd MMM yyyy");this.PageTitle=`Convert Sales Order To Invoice (${e==null?"":i+"-"} ${t})`}initPageLoader(){this.http.GetLoader().subscribe(e=>{this.filter=e,this.getChannelLogs()})}getChannelLogs(){this.updatePageTitle(),this.http.GetSyncInvoice(this.filter).then(e=>{this.header=e.Header,this.result=e.Body})}onFilter(){this.getChannelLogs()}static{this.\u0275fac=function(i){return new(i||n)(f(I),f(P))}}static{this.\u0275cmp=T({type:n,selectors:[["app-convert-invoice"]],standalone:!1,decls:12,vars:5,consts:[[3,"onSubmit","headerTitle","hideSearchBox"],[1,"fw-bold","mb-1"],[1,"mb-4"],["name","From",3,"dateChange","date"],["name","To",3,"dateChange","date"],[1,"container-fluid"],["class","row mt-4",4,"ngIf"],[1,"row","mt-4"],[1,"col-md-12"],[3,"result","header","from","to","type"]],template:function(i,t){i&1&&(r(0,"mainpanel",0),b("onSubmit",function(){return t.onFilter()}),r(1,"filters")(2,"div")(3,"label",1),p(4,"From/To"),a(),r(5,"div",2)(6,"datepicker",3),C("dateChange",function(o){return g(t.filter.From,o)||(t.filter.From=o),o}),a()(),r(7,"div")(8,"datepicker",4),C("dateChange",function(o){return g(t.filter.To,o)||(t.filter.To=o),o}),a()()()(),r(9,"content")(10,"div",5),h(11,Ve,3,5,"div",6),a()()()),i&2&&(m("headerTitle",t.PageTitle)("hideSearchBox",!0),l(6),y("date",t.filter.From),l(2),y("date",t.filter.To),l(3),m("ngIf",t.result))},dependencies:[F,w,_,D],encapsulation:2})}}return n})();function He(n,c){if(n&1&&(r(0,"div",7)(1,"div",8),v(2,"app-table-report",9),a()()),n&2){let e=u();l(2),m("result",e.result)("header",e.header)("from",e.filter.From)("to",e.filter.To)("type",1)}}var Pe=(()=>{class n{constructor(e,i){this.http=e,this.datePipe=i,this.filter=new S,this.PageTitle="Ready to Ship";let t=new Date;this.maxDate=t,this.minDate=d.addDays(t,6),this.filter.From=t,this.filter.To=t,this.updatePageTitle()}ngOnInit(){this.initPageLoader()}updatePageTitle(){let e=d.formatTitleFromDate(this.filter.From,this.filter.To),i=this.datePipe.transform(this.filter.From,e),t=this.datePipe.transform(this.filter.To,"dd MMM yyyy");this.PageTitle=`Ready to Ship (${e==null?"":i+"-"} ${t})`}initPageLoader(){this.http.GetLoader().subscribe(e=>{this.filter=e,this.getChannelLogs()})}getChannelLogs(){this.updatePageTitle(),this.http.GetSyncInvoice(this.filter).then(e=>{this.header=e.Header,this.result=e.Body})}onFilter(){this.getChannelLogs()}static{this.\u0275fac=function(i){return new(i||n)(f(I),f(P))}}static{this.\u0275cmp=T({type:n,selectors:[["app-void-invoice"]],standalone:!1,decls:12,vars:5,consts:[[3,"onSubmit","headerTitle","hideSearchBox"],[1,"fw-bold","mb-1"],[1,"mb-4"],["name","From",3,"dateChange","date"],["name","To",3,"dateChange","date"],[1,"container-fluid"],["class","row mt-4",4,"ngIf"],[1,"row","mt-4"],[1,"col-md-12"],[3,"result","header","from","to","type"]],template:function(i,t){i&1&&(r(0,"mainpanel",0),b("onSubmit",function(){return t.onFilter()}),r(1,"filters")(2,"div")(3,"label",1),p(4,"From/To"),a(),r(5,"div",2)(6,"datepicker",3),C("dateChange",function(o){return g(t.filter.From,o)||(t.filter.From=o),o}),a()(),r(7,"div")(8,"datepicker",4),C("dateChange",function(o){return g(t.filter.To,o)||(t.filter.To=o),o}),a()()()(),r(9,"content")(10,"div",5),h(11,He,3,5,"div",6),a()()()),i&2&&(m("headerTitle",t.PageTitle)("hideSearchBox",!0),l(6),y("date",t.filter.From),l(2),y("date",t.filter.To),l(3),m("ngIf",t.result))},dependencies:[F,w,_,D],encapsulation:2})}}return n})();var Ke=[{path:"",component:Ce,children:[{path:"",redirectTo:"all",pathMatch:"full"},{path:"sync-order",component:ve,canActivate:[R],data:{title:"Sync Order"}},{path:"convert-to-invoice",component:Fe,canActivate:[R],data:{title:"Sync Convert to Invoice"}},{path:"invoice",component:Te,canActivate:[R],data:{title:"Sync Invoice"}},{path:"delivery",component:_e,canActivate:[R],data:{title:"Sync Delivery"}},{path:"payment",component:Se,canActivate:[R],data:{title:"Sync Payment"}},{path:"void-invoice",component:Pe,canActivate:[R],data:{title:"Sync void invoice"}},{path:"all",component:be,canActivate:[R],data:{title:"All Report"}}]}],Gt=(()=>{class n{static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275mod=Z({type:n})}static{this.\u0275inj=X({imports:[se,ye,fe,ge,_,ce.forChild(Ke)]})}}return n})();export{Gt as OrderModule};
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import{a as vt}from"./chunk-RHHHL4OR.js";import{b as Tt}from"./chunk-5LQRO4AI.js";import{a as Pt}from"./chunk-3UN6FPMN.js";import{a as lt}from"./chunk-UMP6ZMEJ.js";import{b as ct,e as pt}from"./chunk-W5L6FMO3.js";import{b as mt}from"./chunk-PW42BQIY.js";import{b as ut,c as ht,h as ft,j as _t,k as Ct}from"./chunk-FO7G4GMY.js";import{A as st,c as ot,h as at,m as rt}from"./chunk-5PS6ZS3N.js";import{a as dt,c as gt}from"./chunk-ERXVXBTU.js";import{r as bt,s as xt}from"./chunk-NNRBGHXB.js";import{g as L,i as nt,m as $,n as R}from"./chunk-FXQKRJWU.js";import{$c as I,Fc as V,G,Gb as S,Gc as m,Hc as w,Ic as j,Jb as X,K as W,Ka as D,Kc as tt,Lc as et,Mb as u,Mc as it,Oa as f,Ra as C,X as z,Yb as h,Z as J,ad as y,ca as Y,cd as A,dc as P,ea as B,f as U,fa as q,g as H,ic as r,ja as M,jc as s,kc as F,lc as T,mc as v,nc as Z,oa as K,oc as _,pa as Q,rb as a,rd as N,tc as b,uc as l,v as x,xb as E,ya as d,za as g}from"./chunk-OJMQBH6T.js";function Nt(e,p){e&1&&Z(0)}function Mt(e,p){if(e&1&&(T(0),u(1,Nt,1,0,"ng-container",5),v()),e&2){l(2);let t=V(4);a(),h("ngTemplateOutlet",t)}}function Dt(e,p){if(e&1&&(r(0,"div",6)(1,"label"),m(2,"Editing Data"),s(),r(3,"div")(4,"span"),m(5),I(6,"number"),s()()()),e&2){let t=l(2);a(5),w(y(6,1,t.value))}}function Et(e,p){if(e&1&&(T(0),u(1,Mt,2,1,"ng-container",4)(2,Dt,7,3,"ng-template",null,1,A),v()),e&2){let t=V(3),i=l();a(),h("ngIf",i.hasPriceEdit)("ngIfElse",t)}}function St(e,p){if(e&1){let t=_();r(0,"div",7)(1,"input",8),it("ngModelChange",function(n){d(t);let o=l();return et(o.value,n)||(o.value=n),g(n)}),s(),r(2,"label",9),m(3),s()()}if(e&2){let t=l();a(),tt("ngModel",t.value),h("max",t.maxEditInventory),a(2),w(t.item.Table)}}var Zt=(()=>{class e{constructor(t,i,n){this.dialogRef=t,this.item=i,this.permissionService=n,this.maxEditInventory=1e5,this.permissionService.hasPermission(lt.PriceUpdate).then(o=>this.hasPriceEdit=o)}ngOnInit(){this.selectedChannel=this.item.Variant.Channel.find(t=>t.ChannelID==this.item.ChannelID),this.selectedChannel.ID=this.item.Variant.ID,this.selectedChannel.Sku=this.item.Variant.Code,this.item.Table=="inventory"?(this.value=this.selectedChannel.Inventory,this.maxEditInventory=this.selectedChannel?.TypeID==mt.Tokopedia?1e5:null):this.item.Table=="price"&&(this.value=this.selectedChannel.Price,this.maxEditInventory=null),this.selectedChannel.ItemName=this.item.Name,this.selectedChannel.VarName=this.item.Variant.Model,this.initModalConfig()}initModalConfig(){let t=this.item.Table=="inventory"?"Update Inventory":"Update Price";this.modalConfig=new _t,this.modalConfig.title=`${t} ${this.item?.Name} in ${this.selectedChannel?.Title}`}onSubmit(){this.item.Table=="inventory"?this.selectedChannel.Inventory=this.value:this.item.Table=="price"&&(this.selectedChannel.Price=this.value),this.dialogRef.close(this.selectedChannel)}onClose(){this.dialogRef.close()}static{this.\u0275fac=function(i){return new(i||e)(E(ut),E(ht),E(dt))}}static{this.\u0275cmp=S({type:e,selectors:[["app-table-dialog"]],decls:5,vars:4,consts:[["INVENTORY",""],["DISABLED",""],[3,"onClose","onCancel","onOk","dynamicValidated","config"],["content",""],[4,"ngIf","ngIfElse"],[4,"ngTemplateOutlet"],["matTooltipPosition","above","matTooltip","Cannot edit Unit Price because you dont have access ProductEditor role",1,"info-label-group","mt-3",2,"background","#e9ecef","opacity","1"],[1,"form-label-group","mt-3"],["type","text","name","edit","autoNum","",1,"form-control",3,"ngModelChange","ngModel","max"],["for","edit",1,"text-capitalize"]],template:function(i,n){if(i&1){let o=_();r(0,"modal-material",2),b("onClose",function(){return d(o),g(n.onClose())})("onCancel",function(){return d(o),g(n.onClose())})("onOk",function(){return d(o),g(n.onSubmit())}),r(1,"div",3),u(2,Et,4,2,"ng-container",4)(3,St,4,3,"ng-template",null,0,A),s()()}if(i&2){let o=V(4);h("dynamicValidated",n.value)("config",n.modalConfig),a(2),h("ngIf",n.item.Table=="price")("ngIfElse",o)}},dependencies:[R,L,nt,$,ft,Pt,Tt,vt,Ct,st,ot,at,rt,gt,xt,bt],styles:["mat-form-field[_ngcontent-%COMP%]{width:100%;height:100%}.mat-dialog-title[_ngcontent-%COMP%]{margin-left:1rem;margin-right:1rem}.mat-dialog-content[_ngcontent-%COMP%]{padding-left:.5rem;padding-right:.5rem;margin-left:.5rem;margin-right:.5rem}.font-lg[_ngcontent-%COMP%]{font-size:large}.font-lgr[_ngcontent-%COMP%]{font-size:larger}"]})}}return e})();var ee=(()=>{class e{transform(t,i,n=0){if(!t)return t;let o=i?parseInt(i,10):10;return t.length>o?t.substring(n,o)+"...":t}static{this.\u0275fac=function(i){return new(i||e)}}static{this.\u0275pipe=X({name:"stringLimit",type:e,pure:!0})}}return e})();function Vt(e,p){if(e&1){let t=_();r(0,"span",6),b("click",function(){d(t);let n=l();return g(n.onGetRowCount())}),r(1,"i",7),m(2,"?"),s()()}}function Lt(e,p){if(e&1&&(T(0),r(1,"span"),m(2),I(3,"number"),s(),v()),e&2){let t=l();a(2),w(y(3,1,t.rowCount()))}}function $t(e,p){if(e&1){let t=_();r(0,"a",10),b("click",function(){d(t);let n=l(2);return g(n.onNextPage())}),F(1,"i",11),m(2," Next"),s()}}function Rt(e,p){if(e&1){let t=_();r(0,"a",12),b("click",function(){d(t);let n=l(2);return g(n.onLastPage())}),F(1,"i",13),m(2," Last"),s()}}function Ot(e,p){if(e&1&&(r(0,"div",5),u(1,$t,3,0,"a",8)(2,Rt,3,0,"a",9),s()),e&2){let t=l();a(),P(t.disableNextButton()&&!t.goToLastPage()?1:-1),a(),P(t.disableNextButton()&&!t.goToLastPage()?2:-1)}}var se=(()=>{class e{constructor(){this.totalData=f(0),this.rowCount=f(),this.pageNumber=f(),this.disableNextButton=f(),this.goToLastPage=f(),this.hideCount=f(),this.nextPage=new D,this.lastPage=new D,this.getRowCount=new D}onNextPage(){this.nextPage.emit()}onLastPage(){this.lastPage.emit()}onGetRowCount(){this.getRowCount.emit()}static{this.\u0275fac=function(i){return new(i||e)}}static{this.\u0275cmp=S({type:e,selectors:[["infinite-paginator"]],inputs:{totalData:[1,"totalData"],rowCount:[1,"rowCount"],pageNumber:[1,"pageNumber"],disableNextButton:[1,"disableNextButton"],goToLastPage:[1,"goToLastPage"],hideCount:[1,"hideCount"]},outputs:{nextPage:"onNextPage",lastPage:"onLastPage",getRowCount:"onGetRowCount"},decls:9,vars:7,consts:[[1,"d-flex","justify-content-between","mt-5"],[1,"me-auto","d-sm-block","collapse","mt-3"],[1,"font-weight-bold","font-italic","hidden-xxs"],[2,"cursor","pointer"],[4,"ngIf"],[1,"btn-group"],[2,"cursor","pointer",3,"click"],["title","Retreive rows count",1,"border","p-3"],["role","button","title","Load more for 20 products",1,"btn","btn-outline-secondary","btn-sm","text-primary"],["role","button","title","Load all products",1,"btn","btn-outline-secondary","btn-sm","text-primary","border-start-0"],["role","button","title","Load more for 20 products",1,"btn","btn-outline-secondary","btn-sm","text-primary",3,"click"],[1,"fas","fa-arrow-right"],["role","button","title","Load all products",1,"btn","btn-outline-secondary","btn-sm","text-primary","border-start-0",3,"click"],[1,"fas","fa-share"]],template:function(i,n){i&1&&(r(0,"div",0)(1,"div",1)(2,"div",2),m(3),I(4,"number"),u(5,Vt,3,0,"span",3)(6,Lt,4,3,"ng-container",4),m(7),s()(),u(8,Ot,3,2,"div",5),s()),i&2&&(a(3),j(" Showing 1 - ",y(4,5,n.totalData())," of "),a(2),P(n.hideCount()?5:-1),a(),h("ngIf",!n.hideCount()&&n.rowCount()),a(),j(" records ~ ",n.pageNumber()," Page "),a(),P(n.totalData()>0?8:-1))},dependencies:[R,L,$],encapsulation:2})}}return e})();var ge=(()=>{class e{constructor(t){this.http=t,this.pagination$=new H(null),this._pageNumber=C(1),this.pageNumber=N(()=>this._pageNumber()),this._hideCount=C(!0),this.hideCount=N(()=>this._hideCount()),this._disableNextButton=C(!0),this.disableNextButton=N(()=>this._disableNextButton()),this._goToLastPage=C(!1),this.isLastPage=N(()=>this._goToLastPage()),this.totalData=C(0),this.destroy$=new U,this.data$=this.paginationFunction()}onNextPage(t){t.PageNumber+=1,this.pagination$.next(t)}setPageNumberFooter(t){this._pageNumber.set(t.PageNumber)}setPaginationButtonState(t,i){i==0?this._disableNextButton.set(!0):this._disableNextButton.set(!(i<t.RowCount*t.PageNumber))}reloadPagination(t){t.PageNumber=1,this.pagination$.next(t),this._hideCount.set(!0),this._goToLastPage.set(!1)}onLastPage(t={}){let i=JSON.parse(JSON.stringify(t));this.totalRowCount$=this.http.post(`/api/${this.fethRowCountEndpoint}`,i).pipe(x(n=>n.Total),B(n=>{this._hideCount.set(!1),i.RowCount=n,i.PageNumber=1,this.pagination$.next(i),this._goToLastPage.set(!0)}))}paginationFunction(){return this.pagination$.pipe(Y(this.destroy$),G(t=>t!=null),W(t=>this.http.post(`/API/${this.fetchDataEndpoint}`,JSON.stringify(t)).pipe(x(i=>i.Data?i.Data:[]))),q(this.pagination$),z((t,i)=>{let[n,o]=t,[c]=i;return o.PageNumber==1?[c,o]:[n.concat(c),o]}),B(([t,i])=>{this.setPageNumberFooter(i);let n=this.calculateProductLength(t);this.totalData.set(n),this.setPaginationButtonState(i,n)}),x(([t])=>t),J())}getRowCount(t){this._hideCount.set(!1),this.totalRowCount$=this.http.post(`/API/${this.fethRowCountEndpoint}`,t).pipe(x(i=>i.Total))}calculateProductLength(t=[]){return t.reduce((n,o)=>n+(o.Variants?.length?o.Variants?.length:0),0)}static{this.\u0275fac=function(i){return new(i||e)(K(pt))}}static{this.\u0275prov=M({token:e,factory:e.\u0275fac})}}return e})();var Ce=(()=>{class e{constructor(){this.toastr=Q(ct)}responseHandling(t=[],i=[],n){let o=t.length>0,c=i.length>0;if(!c&&o&&this.toastr.success(`${this.generateSuccessMessage(t.length)}`,"Success",{enableHtml:!0}),c&&o){let k=`<li>${this.generateSuccessMessage(t.length)}</li>`,wt=this.generateErrorMessage(n,i),It=`<ol>${k} ${wt}</ol>`;this.toastr.warning(It,"Warning",{enableHtml:!0})}if(c&&!o){let k=`<ol>${this.generateErrorMessage(n,i)}</ol>`;this.toastr.error(k,"Error",{enableHtml:!0})}}generateSuccessMessage(t){return`
|
|
2
|
+
<div>
|
|
3
|
+
<span class="fw-bold">Successfully</span> updated ${t} variants in 1 channels
|
|
4
|
+
</div>
|
|
5
|
+
`}generateErrorMessage(t,i=[]){let n="";return i.forEach((o,c)=>{n+=`<li><span class="fw-bold">Error</span> Updating ${t} for [${o.Name} - ${o.Code}] - <b>${o.Message}</b></li>`}),n}static{this.\u0275fac=function(i){return new(i||e)}}static{this.\u0275prov=M({token:e,factory:e.\u0275fac})}}return e})();export{Zt as a,ee as b,se as c,ge as d,Ce as e};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{a as I}from"./chunk-
|
|
1
|
+
import{a as I}from"./chunk-FJ455ZYZ.js";import{h as m}from"./chunk-6VHVQEVM.js";import{a as d}from"./chunk-RDRNWLJI.js";import{b as g,e as C}from"./chunk-W5L6FMO3.js";import{c as o}from"./chunk-PW42BQIY.js";import{J as h,ea as l,ja as S,oa as u,pa as f,r as c}from"./chunk-OJMQBH6T.js";var N=(()=>{class i{constructor(t,e,s){this.httpService=t,this.toastrService=e,this.notificationService=s,this.authService=f(m),this.channelOptions=this.authService.getChannels()}loader(t=o.GuidEMpty){return this.httpService.post("/api/product/Load",{ID:t})}LoadInPOS(t=o.GuidEMpty){return this.httpService.post("/api/product/LoadInPOS",{ID:t})}filterChannelByTypeId(t,e){return t.filter(s=>e.findIndex(n=>s.TypeID==n)!==-1)}getProductStatistic(){return this.httpService.post("/api/product/ProductStatistic",{})}getTotalProductLive(t){let e={ID:t};return this.httpService.post("/api/product/TotalProductLive",e)}clearCacheChannel(t){let e={ID:t};return this.httpService.post("/api/Channel/ClearCacheChannel",e)}detachProduct(t){return this.httpService.post("/api/product/Detach",t)}uploadSingleProduct(t,e){let s={Channel:e,Products:t};return this.httpService.post("api/product/UploadMultipleChannel",s).pipe(l(n=>{this.showToastrSuccessUploadSingle(n,t[0])}),h(n=>(this.showToastErrorUploadSingle(n,t[0]),c(()=>new Error(n)))))}uploadMultipleProduct(t,e){let s={Channel:e,Products:t};return this.httpService.post("api/product/UploadMultipleProductAndMultipleChannel",s).pipe(l(n=>{this.showToastrUploadMultiple(n.Message)}),h(n=>(this.showToastrUploadMultiple(n.error?.Message),c(()=>new Error(n)))))}uploadNotInChannel(t,e){let s={Products:t,Channel:e};return this.httpService.post("/api/product/UploadProductNotInChannelToChannel",s).pipe(l(n=>{this.showToastrUploadMultiple(n)}),h(n=>(this.showToastrUploadMultiple(n.error?.Message),c(()=>new Error(n)))))}scanSingle(t,e){let s={ID:t,SKU:e};return this.httpService.post("/api/product/ScanSingle",s)}scanNotInChannel(t){let e={ID:t};return this.httpService.post("/api/product/ScanNotinChannel",e)}findAllSoldInChannel(t){return this.httpService.post("/api/product/GetSoldInChannel",t)}scanAll(t,e,s,n=!1){let a={ID:t,ScanFull:e,UpdatedProduct:s,Async:n};return this.httpService.post("/api/product/ScanOptimized",a)}scanAsyncProductV2(t,e,s){let n={ID:t,ScanFull:e,UpdatedProduct:s,Async:!0};return this.httpService.post(d.ScanAsyncProductV2,n).pipe(l(a=>{this.notificationService.subscribeToJobGroup(a.JobID)}))}scanSyncProductV2(t,e,s){let n={ID:t,ScanFull:e,UpdatedProduct:s,Async:!1};return this.httpService.post(d.ScanSyncProductV2,n)}scanProductV2(t,e,s,n=!1){return n?this.scanAsyncProductV2(t,e,s).pipe(l(()=>{this.toastrService.warning("You will be notified when the scan is completed.","Scan In Progress",{toastClass:"ngx-toastr toast-waiting"})})):this.scanSyncProductV2(t,e,s).pipe(l(a=>{let r=this.findChannelById(t,this.channelOptions);this.successToastrScanAllProduct(a,r,!s)}))}scanCompareToPos(t){return this.httpService.post("/api/product/CompareMarketplaceToPOS",t)}getVariantCodesProduct(t){return(t.Variants||[]).map(n=>n.Code)}downloadMultipleProduct(t){let e=t.map(s=>({ChannelItemID:s.ChannelItemID,ChannelID:s.ChannelID}));return this.httpService.post("/api/product/DownloadMultipleProductFromChannel",e).pipe(l(s=>{this.toastrService.success(`${s.Count} products downloaded to POS`,"Download Complete")}))}downloadProduct(t){let e={ChannelItemID:t.ChannelItemID,ChannelID:t.ChannelID};return this.httpService.post("/api/product/DownloadProductFromChannel",e).pipe(l(()=>{this.toastrService.success("Product successfully downloaded to POS","Download Complete")}))}getVariantCodesProducts(t=[]){let e=[];return t.forEach(s=>{s.Variants.forEach(n=>{e=[...e,n.Code]})}),e}filterUnselectedChannel(t,e){let s=[];t.forEach(a=>{s=[...s,...a.Channel]});let n;if(!s||s.length==0)n=e;else{let a=[];n=e.filter(r=>(a=s.filter(p=>p.ChannelID==r.ID),a.length!==t.length))}return n}findChannelById(t,e){return e.find(s=>s.ID==t)}sortChannel(t=[]){return t.sort((e,s)=>e.TypeID<s.TypeID?1:e.TypeID===s.TypeID?0:-1)}hasSelection(t=[]){return this.selectedProduct(t).length>0}selectedProduct(t=[]){return t.filter(e=>e.selected)}hasSelectionVariant(t){return this.selectedVariantProduct(t).length>0}selectedVariantProduct(t){let e=[];return t.forEach(s=>{e=[...e,...s.Variants!=null?s.Variants.filter(n=>n.selected):""]}),e}getChannelProduct(t){let e=t.Variants||[],s=[];for(let n of e)if(n.Channel!=null)for(let a of n.Channel)s.filter(r=>r.ChannelID==a.ChannelID).length==0&&s.push(a);return this.sortChannel(s)}successToastrScanAllProduct(t,e,s){let n=t.InChannel?t?.InChannel?.Product:0,a=t?.NotInPOS?.Product?t?.NotInPOS?.Product:0,r=o.IsNotEmpty(t.LastUpdate)?o.convertToReadableDate(t.LastUpdate):null;s?this.toastrService.success(`
|
|
2
2
|
${a+n} product updates in ${e.Name} </br>
|
|
3
3
|
(${n} In Channel + ${a} Not In Pos)
|
|
4
4
|
${o.IsNotEmpty(r)?"since "+r:""}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as Z,b as ee,c as te,d as oe,e as ie,f as ne}from"./chunk-
|
|
1
|
+
import{a as Z,b as ee,c as te,d as oe,e as ie,f as ne}from"./chunk-WPELZYFP.js";import{a as R}from"./chunk-6V4LFY52.js";import"./chunk-G7T42LFR.js";import"./chunk-LRUVI2Z3.js";import"./chunk-QBL6V7QF.js";import"./chunk-DFGZ4L65.js";import{a as T}from"./chunk-UMP6ZMEJ.js";import{a as X,b as Y}from"./chunk-N2SPK2VI.js";import"./chunk-OZ7LWNOK.js";import"./chunk-UHTMVOX6.js";import"./chunk-7AE3725T.js";import"./chunk-RDRNWLJI.js";import{b as H}from"./chunk-W5L6FMO3.js";import"./chunk-K5XRGNWG.js";import{m as Q,n as W}from"./chunk-FO7G4GMY.js";import"./chunk-5PS6ZS3N.js";import"./chunk-V3USB3ZU.js";import{b as J,c as K}from"./chunk-ERXVXBTU.js";import"./chunk-NNRBGHXB.js";import"./chunk-BJUPMCEP.js";import{E as q,G as U,H as V,J as z,j as B,n as j}from"./chunk-FXQKRJWU.js";import{$c as N,Gb as E,Gc as d,Hc as k,Ic as O,Mb as u,Nc as F,Oc as $,Pc as g,Qc as L,Sc as S,Yb as s,aa as I,ac as G,ad as A,dc as _,ec as b,gc as h,hc as v,ic as r,jc as a,kc as f,lc as C,mc as y,oc as w,pa as m,rb as l,tc as M,uc as c,v as x,ya as P,za as D}from"./chunk-OJMQBH6T.js";import"./chunk-EU2KAMEK.js";import"./chunk-66YHNWRR.js";var re=t=>({ID:t}),ae=t=>({"border-end-0":t});function le(t,p){if(t&1){let e=w();C(0),r(1,"button",11),M("click",function(){P(e);let n=c(),o=g(0);return D(n.onDeleteGroup(o==null?null:o.id))}),f(2,"i",12),d(3," Delete "),a(),y()}}function pe(t,p){if(t&1&&(C(0),r(1,"a",13),f(2,"i",14),d(3," Edit "),a(),y()),t&2){c();let e=g(0);l(),s("queryParams",S(1,re,e==null?null:e.id))}}function se(t,p){if(t&1&&(r(0,"div",21)(1,"div",22)(2,"p",23),d(3),a()()()),t&2){let e=c(),i=e.$implicit,n=e.$index,o=c(2).$implicit;G(S(4,ae,n!==o.Roles.length-1)),s("pTooltip",i.Description),l(3),O(" ",i.Name," ")}}function ce(t,p){if(t&1&&u(0,se,4,6,"div",20),t&2){let e=p.$implicit;_(e.checked?0:-1)}}function de(t,p){if(t&1&&(r(0,"div",15)(1,"div",16)(2,"div",17)(3,"span",18),d(4),a()()(),r(5,"div",19)(6,"div",15),h(7,ce,1,1,null,null,b),a()()()),t&2){let e=c().$implicit;l(4),k(e.Name),l(3),v(e==null?null:e.Roles)}}function me(t,p){if(t&1&&u(0,de,9,1,"div",15),t&2){let e=p.$implicit;_((e==null||e.Roles==null?null:e.Roles.length)>0?0:-1)}}function ue(t,p){if(t&1&&(r(0,"div",9),h(1,me,1,1,null,null,b),a()),t&2){c();let e=g(0);l(),v(e.groups)}}var Oe=(()=>{class t{constructor(){this.groupService=m(R),this.activatedRoute=m(q),this.toastr=m(H),this.route=m(U),this.group$=this.activatedRoute.queryParams.pipe(I(e=>this.groupService.getGroupsForm(e.ID).pipe(x(i=>(i.ID=e.ID,i)))),x(e=>({id:e.ID,name:e.Group.Name,groups:this.mapSelectedRoles(e.Options,e.RoleSelected),description:e.Group.Description}))),this.userEditRole=T.UserEdit,this.userDeleteRole=T.UserDelete}mapSelectedRoles(e,i){return e.map(n=>(n.Roles=n.Roles.map(o=>(o.checked=i.includes(o.ID),o)).filter(o=>o.checked),n.checked=n.Roles.some(o=>o.checked),n))}onDeleteGroup(e){confirm("Are you sure you want to delete this group?")&&this.groupService.deleteGroups([e]).subscribe(()=>{this.toastr.success("Group deleted successfully","Success"),this.route.navigate(["/menu/users/groups"])})}static{this.\u0275fac=function(i){return new(i||t)}}static{this.\u0275cmp=E({type:t,selectors:[["app-group-info"]],features:[L([R])],decls:23,vars:11,consts:[[3,"headerTitle","hideSearchBox","hideSearchDropdown"],["role","group","aria-label","User Group Actions",1,"btn-group"],[4,"ngxPermissionsOnly"],[1,"container-fluid"],[1,"row","mt-8"],[1,"col-12"],["type","text","pInputText","","placeholder","Group Name","readonly","",1,"w-100","form-control","rounded-1",2,"padding-top","12px","padding-bottom","12px","font-size","14px",3,"value"],["value","0"],["value","1"],[1,"d-flex","flex-column","row-gap-6","ps-8"],["pInputTextarea","","rows","10","placeholder","Description","readonly","",1,"w-100","form-control","rounded-1",3,"value"],[1,"btn","btn-outline-secondary",3,"click"],[1,"fa","fa-trash","me-1"],["role","button","routerLink","/menu/users/groups/form",1,"btn","btn-outline-secondary",3,"queryParams"],[1,"fa","fa-edit","me-1"],[1,"row"],[1,"col-2","border","d-flex","align-items-center","justify-content-between","border-end-0",2,"height","40px","background","#f6f6f6"],[1,"d-flex","justify-content-center","w-100","align-items-center","gap-4"],[1,"fs-5","w-100","text-center"],[1,"col"],["tooltipPosition","top",1,"col-3","border","p-0","bg-white",2,"height","40px",3,"class","pTooltip"],["tooltipPosition","top",1,"col-3","border","p-0","bg-white",2,"height","40px",3,"pTooltip"],[1,"d-flex","h-100","align-items-center","gap-4","px-2"],[1,"fs-6","text-dark",2,"margin","0"]],template:function(i,n){if(i&1&&(F(0),N(1,"async"),r(2,"mainpanel",0)(3,"actions")(4,"div",1),u(5,le,4,0,"ng-container",2)(6,pe,4,3,"ng-container",2),a()(),r(7,"content")(8,"div",3)(9,"div",4)(10,"div",5),f(11,"input",6),a()(),r(12,"p-tabs",7)(13,"p-tablist")(14,"p-tab",7),d(15,"Permission"),a(),r(16,"p-tab",8),d(17,"Description"),a()(),r(18,"p-tabpanels")(19,"p-tabpanel",7),u(20,ue,3,0,"div",9),a(),r(21,"p-tabpanel",8),f(22,"textarea",10),a()()()()()()),i&2){let o=$(A(1,8,n.group$));l(2),s("headerTitle",(o==null?null:o.name)+" Info")("hideSearchBox",!0)("hideSearchDropdown",!0),l(3),s("ngxPermissionsOnly",n.userDeleteRole),l(),s("ngxPermissionsOnly",n.userEditRole),l(5),s("value",o==null?null:o.name),l(9),_(o?20:-1),l(2),s("value",o==null?null:o.description)}},dependencies:[j,B,W,Q,ne,ie,oe,te,Z,ee,Y,X,K,J,z,V],styles:["[_nghost-%COMP%] .p-tabs{--p-tabs-tab-active-color: #555555;--p-tabs-tab-color: #0976b4}[_nghost-%COMP%] .p-tabs .p-tabpanels{padding-left:0!important}[_nghost-%COMP%] .p-tabs .p-tablist-active-bar{background-color:#555!important}[_nghost-%COMP%] .p-panel .p-panel-header{display:none!important}[_nghost-%COMP%] .btn-outline-secondary{background-color:#fff;border-color:#ccc;color:#000}[_nghost-%COMP%] .btn-outline-secondary:hover{background-color:#f8f9fa;border-color:#b3b3b3;color:#000}"]})}}return t})();export{Oe as GroupInfoComponent};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as j}from"./chunk-
|
|
1
|
+
import{a as j}from"./chunk-BBQGPXDH.js";import{a as z}from"./chunk-PFXOFSJG.js";import"./chunk-BQIB3N6V.js";import"./chunk-B67DSLBY.js";import{a as H,b as q}from"./chunk-HFCAD7GH.js";import"./chunk-4KHHGHFJ.js";import"./chunk-HVCIQI7B.js";import"./chunk-6RLISMEX.js";import"./chunk-TH6VZX34.js";import"./chunk-QS22J2SC.js";import"./chunk-QP4C4R4W.js";import"./chunk-5LQRO4AI.js";import"./chunk-MO53T3IK.js";import"./chunk-W3JTS22H.js";import"./chunk-SDUUFQUI.js";import"./chunk-6L7TD5DW.js";import"./chunk-WLRPCY65.js";import"./chunk-3RK6DDJD.js";import"./chunk-3UN6FPMN.js";import"./chunk-LDPDLCRL.js";import"./chunk-JVNHFIYT.js";import"./chunk-ACIMXBIC.js";import"./chunk-W5L6FMO3.js";import"./chunk-K5XRGNWG.js";import{m as J,n as O}from"./chunk-FO7G4GMY.js";import{A as N,c as W,h as R,m as k}from"./chunk-5PS6ZS3N.js";import"./chunk-V3USB3ZU.js";import"./chunk-NNRBGHXB.js";import"./chunk-BJUPMCEP.js";import{H as T,J as B,f as w,j as E,k as A,m as F,n as D}from"./chunk-FXQKRJWU.js";import{$c as p,Gb as b,Gc as a,Ic as f,Kc as g,Lc as u,Mb as I,Mc as y,Rc as M,Sc as P,Yb as d,Z as h,ac as L,ad as c,bd as S,ic as n,jc as o,rb as r,tc as C,v,xb as _}from"./chunk-OJMQBH6T.js";import"./chunk-EU2KAMEK.js";import"./chunk-66YHNWRR.js";var G=()=>["/menu/log/inventory/detail"],K=l=>({ID:l});function Q(l,V){if(l&1&&(n(0,"tr")(1,"td")(2,"a",18),a(3),p(4,"date"),o()(),n(5,"td"),a(6),p(7,"number"),o(),n(8,"td")(9,"span",19),a(10),o()()()),l&2){let t=V.$implicit;r(2),d("routerLink",M(13,G))("queryParams",P(14,K,t._id)),r(),f(" ",S(4,7,t==null?null:t._source["@timestamp"],"dd MMM yyyy HH:mm:ss")," "),r(3),f("",S(7,10,t.DurationInSecond,"1.1-1")," s"),r(3),L((t==null?null:t.respCode)===200||(t==null?null:t.respCode)===202?"bg-success":"bg-warning"),r(),f(" ",t==null?null:t.respCode," ")}}var me=(()=>{class l{constructor(t){this.inventoryAsyncServiceLog=t,this.filters={PageNumber:1,RowCount:100,From:null,To:null,StatusCode:"",JobID:""}}ngOnInit(){this.initInventoryLog()}initInventoryLog(){let t=this.inventoryAsyncServiceLog.getInventoryAsyncLog(this.filters).pipe(h(1));this.inventoryLog$=t.pipe(v(m=>m?.hits)),this.totalPagination$=t.pipe(v(m=>m?.total.value))}onPaginationChange(t){this.filters.PageNumber=t.pageIndex+1,this.initInventoryLog()}onSubmitFilter(){this.initInventoryLog()}static{this.\u0275fac=function(m){return new(m||l)(_(j))}}static{this.\u0275cmp=b({type:l,selectors:[["app-inventory-async-log"]],decls:42,vars:17,consts:[["headerTitle","Order Inventory Sync Job",3,"onSubmit","hideSearchBox"],["role","button","routerLink","/menu/log/inventory/sync-inventory",1,"btn","btn-success"],["container",""],[1,"fw-bold","mb-1"],[1,"mb-4"],["name","From",3,"dateChange","date"],["name","To",3,"dateChange","date"],[1,"mt-5"],["type","text","name","StatusCode",1,"w-100","mt-2","form-control",3,"ngModelChange","ngModel"],["type","text","name","JobID",1,"w-100","mt-2","form-control",3,"ngModelChange","ngModel"],[1,"container-fluid","mt-3"],[1,"row"],[1,"col"],[1,"table-responsive"],[1,"table","table-hover"],[1,"table-light"],[4,"ngFor","ngForOf"],[3,"page","length","pageSize","pageIndex"],[3,"routerLink","queryParams"],[1,"text-white","p-2","rounded","response-desc"]],template:function(m,e){m&1&&(n(0,"mainpanel",0),C("onSubmit",function(){return e.onSubmitFilter()}),n(1,"actions")(2,"a",1),a(3," Channel Inventory Sync "),o()(),n(4,"filters")(5,"div",2)(6,"div")(7,"label",3),a(8,"From/To"),o(),n(9,"div",4)(10,"datepicker",5),y("dateChange",function(i){return u(e.filters.From,i)||(e.filters.From=i),i}),o()(),n(11,"div")(12,"datepicker",6),y("dateChange",function(i){return u(e.filters.To,i)||(e.filters.To=i),i}),o()()(),n(13,"div",7)(14,"label"),a(15,"Response Code"),o(),n(16,"input",8),y("ngModelChange",function(i){return u(e.filters.StatusCode,i)||(e.filters.StatusCode=i),i}),o()(),n(17,"div",7)(18,"label"),a(19,"JobID"),o(),n(20,"input",9),y("ngModelChange",function(i){return u(e.filters.JobID,i)||(e.filters.JobID=i),i}),o()()()(),n(21,"content")(22,"div",10)(23,"div",11)(24,"div",12)(25,"div",13)(26,"table",14)(27,"thead")(28,"tr",15)(29,"th"),a(30,"Created"),o(),n(31,"th"),a(32,"Duration"),o(),n(33,"th"),a(34,"Response code"),o()()(),n(35,"tbody"),I(36,Q,11,16,"tr",16),p(37,"async"),o()(),n(38,"mat-paginator",17),p(39,"async"),p(40,"async"),p(41,"async"),C("page",function(i){return e.onPaginationChange(i)}),o()()()()()()()),m&2&&(d("hideSearchBox",!0),r(10),g("date",e.filters.From),r(2),g("date",e.filters.To),r(4),g("ngModel",e.filters.StatusCode),r(4),g("ngModel",e.filters.JobID),r(16),d("ngForOf",c(37,9,e.inventoryLog$)),r(2),d("length",c(39,11,e.totalPagination$))("pageSize",e.filters.RowCount>c(40,13,e.totalPagination$)?c(41,15,e.totalPagination$):e.filters.RowCount)("pageIndex",(e.filters==null?null:e.filters.PageNumber)==0?0:(e.filters==null?null:e.filters.PageNumber)-1))},dependencies:[N,W,R,k,D,w,E,F,A,O,J,q,H,z,B,T],encapsulation:2})}}return l})();export{me as InventoryAsyncLogComponent};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{L as o,p as a}from"./chunk-
|
|
1
|
+
import{L as o,p as a}from"./chunk-BJUPMCEP.js";import{Hb as r,ka as t}from"./chunk-OJMQBH6T.js";var n=(()=>{class e{static \u0275fac=function(i){return new(i||e)};static \u0275mod=r({type:e});static \u0275inj=t({imports:[o,a,o]})}return e})();export{n as a};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{c as mt}from"./chunk-PW42BQIY.js";import{ja as dt}from"./chunk-
|
|
1
|
+
import{c as mt}from"./chunk-PW42BQIY.js";import{ja as dt}from"./chunk-OJMQBH6T.js";import{a as We,b as ut,i as at}from"./chunk-66YHNWRR.js";function L(){}var Ge=e=>e;function pt(e,t){for(let n in t)e[n]=t[n];return e}function Mt(e){return e()}function Y(e){e.forEach(Mt)}function Ye(e){return typeof e=="function"}function oe(e,t){return e!=e?t==t:e!==t}function Ot(e){return Object.keys(e).length===0}function Rt(e,...t){if(e==null)return L;let n=e.subscribe(...t);return n.unsubscribe?()=>n.unsubscribe():n}function me(e,t,n){e.$$.on_destroy.push(Rt(t,n))}function Ce(e){return e&&Ye(e.destroy)?e.destroy:L}var Qe=()=>globalThis.performance.now(),xe=e=>requestAnimationFrame(e),he=new Set;function Et(e){he.forEach(t=>{t.c(e)||(he.delete(t),t.f())}),he.size!==0&&xe(Et)}function et(e){let t;return he.size===0&&xe(Et),{promise:new Promise(n=>{he.add(t={c:e,f:n})}),abort(){he.delete(t)}}}function ge(e,t){e.appendChild(t)}function P(e,t,n){e.insertBefore(t,n||null)}function S(e){e.parentNode.removeChild(e)}function C(e){return document.createElement(e)}function At(e){return document.createTextNode(e)}function Ee(){return At("")}function N(e,t,n,i){return e.addEventListener(t,n,i),()=>e.removeEventListener(t,n,i)}function I(e,t,n){n==null?e.removeAttribute(t):e.getAttribute(t)!==n&&e.setAttribute(t,n)}function E(e,t,n,i){n===null?e.style.removeProperty(t):e.style.setProperty(t,n)}function R(e,t,n){e.classList[n?"add":"remove"](t)}function Nt(e,t,n=!1){let i=document.createEvent("CustomEvent");return i.initCustomEvent(e,n,!1,t),i}var pe,tt=0,Ze={};function $t(e,t,n,i,o,r,s,c=0){let l=16.666/i,f=`{
|
|
2
2
|
`;for(let a=0;a<=1;a+=l){let p=t+(n-t)*r(a);f+=a*100+`%{${s(p,1-p)}}
|
|
3
3
|
`}let d=f+`100% {${s(n,1-n)}}
|
|
4
4
|
}`,u=`_bp_${Math.round(Math.random()*1e9)}_${c}`;if(!Ze[u]){if(!pe){let a=C("style");document.head.appendChild(a),pe=a.sheet}Ze[u]=!0,pe.insertRule(`@keyframes ${u} ${d}`,pe.cssRules.length)}let h=e.style.animation||"";return e.style.animation=`${h?`${h}, `:""}${u} ${i}ms linear ${o}ms 1 both`,tt+=1,u}function qe(e,t){e.style.animation=(e.style.animation||"").split(", ").filter(t?n=>n.indexOf(t)<0:n=>n.indexOf("_bp")===-1).join(", "),t&&!--tt&&Yt()}function Yt(){xe(()=>{if(tt)return;let e=pe.cssRules.length;for(;e--;)pe.deleteRule(e);Ze={}})}var nt;function Ie(e){nt=e}var ze=[],ht=[],Oe=[],gt=[],Xt=Promise.resolve(),je=!1;function Wt(){je||(je=!0,Xt.then(Ct))}function ee(e){Oe.push(e)}var Fe=new Set,Le=0;function Ct(){let e=nt;do{for(;Le<ze.length;){let t=ze[Le];Le++,Ie(t),Ft(t.$$)}for(Ie(null),ze.length=0,Le=0;ht.length;)ht.pop()();for(let t=0;t<Oe.length;t+=1){let n=Oe[t];Fe.has(n)||(Fe.add(n),n())}Oe.length=0}while(ze.length);for(;gt.length;)gt.pop()();je=!1,Fe.clear(),Ie(e)}function Ft(e){if(e.fragment!==null){e.update(),Y(e.before_update);let t=e.dirty;e.dirty=[-1],e.fragment&&e.fragment.p(e.ctx,t),e.after_update.forEach(ee)}}var Te;function Dt(){return Te||(Te=Promise.resolve(),Te.then(()=>{Te=null})),Te}function Ae(e,t,n){e.dispatchEvent(Nt(`${t?"intro":"outro"}${n}`))}var Re=new Set,U;function te(){U={r:0,c:[],p:U}}function ne(){U.r||Y(U.c),U=U.p}function v(e,t){e&&e.i&&(Re.delete(e),e.i(t))}function $(e,t,n,i){if(e&&e.o){if(Re.has(e))return;Re.add(e),U.c.push(()=>{Re.delete(e),i&&(n&&e.d(1),i())}),e.o(t)}}var Pt={duration:0};function St(e,t,n){let i=t(e,n),o=!1,r,s,c=0;function l(){r&&qe(e,r)}function f(){let{delay:u=0,duration:h=300,easing:a=Ge,tick:p=L,css:g}=i||Pt;g&&(r=$t(e,0,1,h,u,a,g,c++)),p(0,1);let k=Qe()+u,H=k+h;s&&s.abort(),o=!0,ee(()=>Ae(e,!0,"start")),s=et(X=>{if(o){if(X>=H)return p(1,0),Ae(e,!0,"end"),l(),o=!1;if(X>=k){let y=a((X-k)/h);p(y,1-y)}}return o})}let d=!1;return{start(){d||(d=!0,qe(e),Ye(i)?(i=i(),Dt().then(f)):f())},invalidate(){d=!1},end(){o&&(l(),o=!1)}}}function _e(e,t,n){let i=t(e,n),o=!0,r,s=U;s.r+=1;function c(){let{delay:l=0,duration:f=300,easing:d=Ge,tick:u=L,css:h}=i||Pt;h&&(r=$t(e,1,0,f,l,d,h));let a=Qe()+l,p=a+f;ee(()=>Ae(e,!1,"start")),et(g=>{if(o){if(g>=p)return u(0,1),Ae(e,!1,"end"),--s.r||Y(s.c),!1;if(g>=a){let k=d((g-a)/f);u(1-k,k)}}return o})}return Ye(i)?Dt().then(()=>{i=i(),c()}):c(),{end(l){l&&i.tick&&i.tick(1,0),o&&(r&&qe(e,r),o=!1)}}}function ke(e){e&&e.c()}function re(e,t,n,i){let{fragment:o,on_mount:r,on_destroy:s,after_update:c}=e.$$;o&&o.m(t,n),i||ee(()=>{let l=r.map(Mt).filter(Ye);s?s.push(...l):Y(l),e.$$.on_mount=[]}),c.forEach(ee)}function se(e,t){let n=e.$$;n.fragment!==null&&(Y(n.on_destroy),n.fragment&&n.fragment.d(t),n.on_destroy=n.fragment=null,n.ctx=[])}function Bt(e,t){e.$$.dirty[0]===-1&&(ze.push(e),Wt(),e.$$.dirty.fill(0)),e.$$.dirty[t/31|0]|=1<<t%31}function De(e,t,n,i,o,r,s,c=[-1]){let l=nt;Ie(e);let f=e.$$={fragment:null,ctx:null,props:r,update:L,not_equal:o,bound:{},on_mount:[],on_destroy:[],on_disconnect:[],before_update:[],after_update:[],context:new Map(t.context||(l?l.$$.context:[])),callbacks:{},dirty:c,skip_bound:!1,root:t.target||l.$$.root};s&&s(f.root);let d=!1;f.ctx=n?n(e,t.props||{},(u,h,...a)=>{let p=a.length?a[0]:h;return f.ctx&&o(f.ctx[u],f.ctx[u]=p)&&(!f.skip_bound&&f.bound[u]&&f.bound[u](p),d&&Bt(e,u)),h}):[],f.update(),d=!0,Y(f.before_update),f.fragment=i?i(f.ctx):!1,t.target&&(f.fragment&&f.fragment.c(),re(e,t.target,t.anchor,t.customElement),Ct()),Ie(l)}var ie=class{$destroy(){se(this,1),this.$destroy=L}$on(t,n){let i=this.$$.callbacks[t]||(this.$$.callbacks[t]=[]);return i.push(n),()=>{let o=i.indexOf(n);o!==-1&&i.splice(o,1)}}$set(t){this.$$set&&!Ot(t)&&(this.$$.skip_bound=!0,this.$$set(t),this.$$.skip_bound=!1)}};function it(e){let t=e-1;return t*t*t+1}function V(e,{delay:t=0,duration:n=400,easing:i=it,x:o=0,y:r=0,opacity:s=0}={}){let c=getComputedStyle(e),l=+c.opacity,f=c.transform==="none"?"":c.transform,d=l*(1-s);return{delay:t,duration:n,easing:i,css:(u,h)=>`
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import{a as Xe,b as et,c as tt}from"./chunk-FFCWYWBW.js";import"./chunk-G7T42LFR.js";import{a as se}from"./chunk-LHX4ZOLA.js";import{a as He,b as Ke,c as Qe,e as Ze,f as qe,g as Je}from"./chunk-IQ4AFE6X.js";import{e as Ae,k as Ye,l as $e,m as Ue,n as Ge,o as je}from"./chunk-B67DSLBY.js";import"./chunk-74ELVGDK.js";import{a as Re,b as Be,c as Le}from"./chunk-OK3LLCAK.js";import"./chunk-HVCIQI7B.js";import"./chunk-6RLISMEX.js";import"./chunk-TH6VZX34.js";import"./chunk-QS22J2SC.js";import"./chunk-QP4C4R4W.js";import"./chunk-LRUVI2Z3.js";import"./chunk-UYLSZYOD.js";import"./chunk-M7V7A7Z6.js";import"./chunk-QBL6V7QF.js";import"./chunk-DFGZ4L65.js";import{a as ze}from"./chunk-3FPEQHTI.js";import"./chunk-MO53T3IK.js";import"./chunk-W3JTS22H.js";import"./chunk-SDUUFQUI.js";import"./chunk-6L7TD5DW.js";import"./chunk-WLRPCY65.js";import"./chunk-LDPDLCRL.js";import"./chunk-OZ7LWNOK.js";import"./chunk-UHTMVOX6.js";import{ha as We}from"./chunk-7AE3725T.js";import"./chunk-JVNHFIYT.js";import"./chunk-FJ455ZYZ.js";import{g as Me,h as re}from"./chunk-6VHVQEVM.js";import"./chunk-Z3ITXK3D.js";import"./chunk-ACIMXBIC.js";import"./chunk-J53BPEDH.js";import"./chunk-TGMCGROM.js";import{a as oe}from"./chunk-RDRNWLJI.js";import{b as Pe,e as Ie}from"./chunk-W5L6FMO3.js";import"./chunk-K5XRGNWG.js";import{c as Ve,d as ke,e as Fe}from"./chunk-PYXL7UF7.js";import{b as ne,c as x}from"./chunk-PW42BQIY.js";import{m as Oe,n as Ne}from"./chunk-FO7G4GMY.js";import{A as ie,c as be,h as ee,m as te,x as Ee}from"./chunk-5PS6ZS3N.js";import"./chunk-V3USB3ZU.js";import"./chunk-ERXVXBTU.js";import{r as ae,s as le}from"./chunk-NNRBGHXB.js";import"./chunk-BJUPMCEP.js";import{J as Te,d as F,f as L,g as A,j as X,k as z,n as M}from"./chunk-FXQKRJWU.js";import{$c as R,Ac as Ce,Bc as Se,Cc as ve,Fc as D,Gb as I,Gc as p,Hc as k,Ic as S,Ka as B,Kc as b,Lc as E,Mb as w,Mc as P,Oa as O,Qc as Q,Ra as _,Rc as ye,Sc as Z,Tc as xe,Yb as s,Z as U,aa as ue,ad as j,bd as De,cd as q,dc as V,ea as G,ic as o,ja as he,jc as r,kc as C,lc as N,m as ce,mc as W,oc as v,pa as y,pb as fe,rb as a,sd as J,tc as g,uc as f,v as K,xb as _e,xc as ge,ya as m,yc as we,za as c}from"./chunk-OJMQBH6T.js";import"./chunk-EU2KAMEK.js";import{a as de,b as me}from"./chunk-66YHNWRR.js";var at=t=>({"over-due":t});function lt(t,d){if(t&1&&(o(0,"tr",8)(1,"td"),p(2),r(),o(3,"td"),p(4),r(),o(5,"td"),p(6),r(),o(7,"td"),p(8),r()()),t&2){let e=d.$implicit,n=d.index;s("ngClass",Z(5,at,e.Exception)),a(2),k(n+1),a(2),k(e.Number),a(2),k(e.Status),a(2),k(e.Exception)}}function pt(t,d){if(t&1&&(N(0),w(1,lt,9,7,"tr",7),W()),t&2){let e,n=f();a(),s("ngForOf",(e=n.downloadResult())==null?null:e.Body)}}function st(t,d){t&1&&(o(0,"tr",9)(1,"td",10)(2,"div",11),C(3,"i",12),r(),o(4,"h4",13),p(5," There is no order to processed "),r()()())}var it=(()=>{class t{constructor(){this.downloadResult=O()}ngOnInit(){}static{this.\u0275fac=function(n){return new(n||t)}}static{this.\u0275cmp=I({type:t,selectors:[["complete-step"]],inputs:{downloadResult:[1,"downloadResult"]},decls:16,vars:2,consts:[["EMPTY_DOWNLOAD",""],[1,"row","pt-2"],[1,"col-md-12"],[1,"table"],[1,"thead-light"],["width","1%"],[4,"ngIf","ngIfElse"],[3,"ngClass",4,"ngFor","ngForOf"],[3,"ngClass"],[1,"text-center"],["colspan","10",1,"border-0"],[2,"margin-top","16vh"],[1,"far","fa-file","text-secondary",2,"font-size","95px"],[1,"text-secondary","mt-6"]],template:function(n,i){if(n&1&&(o(0,"div",1)(1,"div",2)(2,"table",3)(3,"thead",4)(4,"tr"),C(5,"th",5),o(6,"th"),p(7,"Order Number"),r(),o(8,"th"),p(9,"Status"),r(),o(10,"th"),p(11,"Exception"),r()()(),o(12,"tbody"),w(13,pt,2,1,"ng-container",6)(14,st,6,0,"ng-template",null,0,q),r()()()()),n&2){let l,h=D(15);a(13),s("ngIf",((l=i.downloadResult())==null||l.Body==null?null:l.Body.length)>0)("ngIfElse",h)}},dependencies:[M,F,L,A],encapsulation:2})}}return t})();var mt=t=>({"full-width":t}),ct=()=>({standalone:!0}),nt=(()=>{class t{constructor(e){this.datePipe=e,this.fullWidth=!1,this.timeChange=new B}ngOnInit(){}onTimeChange(e){let n=null;e&&(n=this.datePipe.transform(e,"HH:mm")),this.timeChange.emit(n),this.onTimePickerChange()}onShowCalendar(){let e=document.getElementById("dropdown-filter");if(e){var n=new bootstrap.Dropdown(e);n&&(n._config.autoClose="inside")}}onTimePickerChange(){let e=document.getElementById("dropdown-filter");if(e){var n=new bootstrap.Dropdown(e);n&&(n._config.autoClose="outside")}}static{this.\u0275fac=function(n){return new(n||t)(_e(z))}}static{this.\u0275cmp=I({type:t,selectors:[["app-timepicker"]],inputs:{time:"time",fullWidth:"fullWidth"},outputs:{timeChange:"timeChange"},decls:4,vars:8,consts:[["myCalendar",""],["styleClass","custom-height","id","shippingTime","appendTo","body",3,"ngModelChange","onSelect","ngClass","baseZIndex","ngModel","timeOnly","ngModelOptions"],["size","small","label","Close",3,"click"]],template:function(n,i){if(n&1){let l=v();o(0,"p-datepicker",1,0),P("ngModelChange",function(u){return m(l),E(i.time,u)||(i.time=u),c(u)}),g("ngModelChange",function(u){return m(l),c(i.onTimeChange(u))})("onSelect",function(){return m(l),c(i.onShowCalendar())}),o(2,"p-footer")(3,"p-button",2),g("click",function(){return m(l),D(1).hideOverlay(),c(i.onShowCalendar())}),r()()()}n&2&&(s("ngClass",Z(5,mt,i.fullWidth))("baseZIndex",1100),b("ngModel",i.time),s("timeOnly",!0)("ngModelOptions",ye(7,ct)))},dependencies:[M,F,ie,ee,te,tt,et,Xe,We],styles:["p-datepicker span.p-datepicker.custom-height{height:44px;width:70px} p-datepicker.full-width span.p-datepicker.custom-height{height:44px;width:100%!important}"]})}}return t})();var Y=(()=>{class t{constructor(){this.httpService=y(Ie),this.toastr=y(Pe),this.datePipe=y(z)}gerChannelDetailById(e){return this.httpService.post(oe.GetChannelDetail,{ID:e})}getOrderPreview(e){return this.httpService.post(oe.GetOrderPreviewV2,e)}getDownloadOrder(e){return this.httpService.post(oe.GetDownloadOrderV2,e)}onPreviewOrder(e){return this.validateDatePreview(e)?this.getOrderPreview(e).pipe(G(n=>{n.Data?.length===0&&this.toastrEmptyPreview(e)})):ce}toastrEmptyPreview(e){let n=this.datePipe.transform(e.From,"dd MMM yyyy"),i=this.datePipe.transform(e.To,"dd MMM yyyy"),l=e.TimeFrom?e.TimeFrom:"",h=e.TimeTo?e.TimeTo:"";this.toastr.info(`There is no orders from ${n} ${l} to ${i} ${h}!`,"No Orders!")}validateDatePreview(e){let n=!0;return e.downloadType==!0?x.getDaysDiff(e?.From,e?.To)+1>7&&(this.toastr.warning("Dates cannot be more than 7 days apart!","Warning"),n=!1):x.getDaysDiff(e?.From,e?.To)+1>14&&(this.toastr.warning("Dates cannot be more than 14 days apart!","Warning"),n=!1),n}getDateTitle(e,n){let i=x.formatTitleFromDate(new Date(e),new Date(n)),l=this.datePipe.transform(e,i),h=this.datePipe.transform(n,"dd MMM yyyy");return`${i==null?"":l+"-"} ${h}`}static{this.\u0275fac=function(n){return new(n||t)}}static{this.\u0275prov=he({token:t,factory:t.\u0275fac})}}return t})();function ut(t,d){if(t&1&&(o(0,"ng-option",13),C(1,"img",14),p(2),r()),t&2){let e=d.$implicit;s("value",e.ID),a(),s("src",e==null?null:e.Img,fe),a(),S("",e.Name," ")}}function ht(t,d){if(t&1){let e=v();o(0,"div",8)(1,"div",4)(2,"h5"),p(3,"Type"),r(),o(4,"p",5),p(5,"Select Type want to download"),r()(),o(6,"div",4)(7,"div",15)(8,"div")(9,"mat-radio-group",16),P("ngModelChange",function(i){m(e);let l=f();return E(l.downloadType,i)||(l.downloadType=i),c(i)}),g("ngModelChange",function(){m(e);let i=f();return c(i.onDownloadTypeChange())}),o(10,"mat-radio-button",17),p(11," Orders "),r(),o(12,"mat-radio-button",18),p(13," Disbursement "),r()()()(),o(14,"div",19)(15,"div",20),C(16,"i",21),r(),o(17,"p",22),p(18," If there are completed transactions, to obtain payment and service fee, you need to download disbursement. "),r()()()()}if(t&2){let e=f();a(9),b("ngModel",e.downloadType),a(),s("value",!1),a(2),s("value",!0)}}function ft(t,d){t&1&&(o(0,"p",5),p(1," Select Disbursement date "),o(2,"span",23),p(3,"(payment date / order complete date)"),r(),p(4," of the channel you want to download (Max 1 Week). "),r())}function _t(t,d){t&1&&(o(0,"p",5),p(1," Select transaction date of the channel you want to download (Max 2 Weeks) "),r())}function gt(t,d){if(t&1){let e=v();o(0,"div",12)(1,"app-timepicker",24),P("timeChange",function(i){m(e);let l=f();return E(l.startTime,i)||(l.startTime=i),c(i)}),g("timeChange",function(){m(e);let i=f();return c(i.onStartTimeChange())}),r(),o(2,"span",25),p(3,"-"),r(),o(4,"app-timepicker",24),P("timeChange",function(i){m(e);let l=f();return E(l.endTime,i)||(l.endTime=i),c(i)}),g("timeChange",function(){m(e);let i=f();return c(i.onEndTimeChange())}),r()()}if(t&2){let e=f();a(),b("time",e.startTime),a(3),b("time",e.endTime)}}var ot=(()=>{class t{constructor(){this.reset=O(!1),this.authService=y(re),this.tokenService=y(Me),this.downloadService=y(Y),this.downloadType=_(!1),this.selectedChannelId=_(null),this.channelOptions=_(this.authService.getChannels()),this.channelType=ne,this.selectedChannel=_(null),this.showTimePicker=_(!1),this.startDate=_(null),this.endDate=_(null),this.startTime=_("00:00"),this.endTime=_("23:59"),this.minDate=_(new Date),this.maxDate=_(new Date),this.filterData=new B,J(()=>{this.reset()&&this.resetFilter()},{allowSignalWrites:!0}),this.initDateValidation()}initDateValidation(){let e=this.tokenService?.getTokenValue(),n=e?.DownloadRange?JSON.parse(e?.DownloadRange):0;if(n<=0)this.minDate.set(null),this.maxDate.set(null);else{let i=new Date,l=x.addDays(i,n-1);this.minDate.set(l)}}resetFilter(){this.selectedChannelId.update(()=>null),this.startDate.update(()=>null),this.endDate.update(()=>null),this.startTime.update(()=>null),this.endTime.update(()=>null),this.downloadType.update(()=>!1),this.selectedChannel.update(()=>null),this.showTimePicker.update(()=>!1),this.channelDetail$=null}onSelectChannel(){this.selectedChannel.update(()=>this.channelOptions().find(e=>e.ID===this.selectedChannelId())),this.selectedChannel()?this.channelDetail$=this.downloadService.gerChannelDetailById(this.selectedChannelId()).pipe(K(e=>e?.Model),U(1)):this.channelDetail$=null,this.emitFilterData()}onFilterDateChange(){let e=1;this.startDate()&&this.endDate()&&(e=x.getDaysDiff(this.startDate(),this.endDate())),this.showTimePicker.update(()=>e==0),this.emitFilterData()}onDownloadTypeChange(){this.emitFilterData()}onStartTimeChange(){this.emitFilterData()}onEndTimeChange(){this.emitFilterData()}emitFilterData(){this.filterData.emit({channelId:this.selectedChannelId(),startDate:this.startDate(),endDate:this.endDate(),downloadType:this.downloadType(),startTime:this.startTime(),endTime:this.endTime()})}static{this.\u0275fac=function(n){return new(n||t)}}static{this.\u0275cmp=I({type:t,selectors:[["filter-step"]],inputs:{reset:[1,"reset"]},outputs:{filterData:"onFilterChange"},features:[Q([Y,Ae()])],decls:27,vars:13,consts:[["picker",""],[1,"row","pt-2",2,"width","63%","margin-right","40px"],[1,"col-12"],[1,"row"],[1,"col-6"],[1,"text-muted"],["appendTo","body","placeholder","Select Channel",3,"ngModelChange","clearable","ngModel"],[3,"value",4,"ngFor","ngForOf"],[1,"row","mt-6"],["id","dates",1,"form-control","rounded","dateRange",3,"rangePicker","min","max"],["matStartDate","","placeholder","Start date",3,"ngModelChange","click","ngModel","maxlength"],["matEndDate","","placeholder","End date",3,"ngModelChange","click","ngModel"],[1,"mt-8"],[3,"value"],[2,"width","18px","margin-right","10px",3,"src"],[1,"form-label-group","radio","download-type",2,"margin-bottom","0px"],["name","dowloadType",3,"ngModelChange","ngModel"],["matTooltip","Download from Create sales order until create logistics status",1,"me-5",3,"value"],["matTooltip","Download only Payment and write off",1,"me-5",3,"value"],[1,"d-flex","border","mb-4","pt-6","px-6","mt-3",2,"background","#1f87ac0a","border-radius","5px"],[1,"me-3","pt-1"],[1,"fa","fa-lightbulb","fs-5"],[1,"mb-6"],[1,"fw-bold"],[3,"timeChange","time"],[1,"mx-4"]],template:function(n,i){if(n&1){let l=v();o(0,"div",1)(1,"div",2)(2,"div",3)(3,"div",4)(4,"h5"),p(5,"Select a Channel"),r(),o(6,"p",5),p(7,"Select Channel want to download order"),r()(),o(8,"div",4)(9,"ng-select",6),P("ngModelChange",function(u){return m(l),E(i.selectedChannelId,u)||(i.selectedChannelId=u),c(u)}),g("ngModelChange",function(){return m(l),c(i.onSelectChannel())}),w(10,ut,3,3,"ng-option",7),r()()(),w(11,ht,19,3,"div",8),R(12,"async"),o(13,"div",8)(14,"div",4)(15,"h5"),p(16,"Date Range"),r(),w(17,ft,5,0,"p",5)(18,_t,2,0,"p",5),r(),o(19,"div",4)(20,"div",2)(21,"mat-date-range-input",9)(22,"input",10),P("ngModelChange",function(u){return m(l),E(i.startDate,u)||(i.startDate=u),c(u)}),g("click",function(){m(l);let u=D(25);return c(u.open())}),r(),o(23,"input",11),P("ngModelChange",function(u){return m(l),E(i.endDate,u)||(i.endDate=u),c(u)}),g("click",function(){m(l);let u=D(25);return c(u.open())})("ngModelChange",function(){return m(l),c(i.onFilterDateChange())}),r()(),C(24,"mat-date-range-picker",null,0),r(),w(26,gt,5,2,"div",12),r()()()()}if(n&2){let l,h,u=D(25);a(9),s("clearable",!1),b("ngModel",i.selectedChannelId),a(),s("ngForOf",i.channelOptions()),a(),V((l=j(12,11,i.channelDetail$))!=null&&l.ServiceFeeWriteOff&&((l=i.selectedChannel())==null?null:l.TypeID)==i.channelType.Tokopedia?11:-1),a(6),V(i.downloadType()&&((h=i.selectedChannel())==null?null:h.TypeID)==i.channelType.Tokopedia?17:18),a(4),s("rangePicker",u)("min",i.minDate())("max",i.maxDate()),a(),b("ngModel",i.startDate),a(),b("ngModel",i.endDate),a(3),V(i.showTimePicker()?26:-1)}},dependencies:[M,L,X,Fe,ke,Ve,Le,Re,Be,ie,be,ee,Ee,te,nt,Ge,Ye,je,$e,Ue],styles:[".vertical-radio[_ngcontent-%COMP%]{display:flex;flex-direction:column;margin:15px 0}.mt-1rem[_ngcontent-%COMP%]{margin-top:1rem}.dateRange[_ngcontent-%COMP%]{padding-top:.8rem;padding-bottom:.8rem}.form-label-group.radio.download-type[_ngcontent-%COMP%]{height:45.5938px!important;border-radius:.375rem!important}"]})}}return t})();var T=function(t){return t.ALL="all",t.SYNC="sync",t.WRONG="wrong",t.UNSYNC="unsync",t}(T||{});var $=function(t){return t[t.DoNothing=0]="DoNothing",t[t.New=1]="New",t[t.Update=2]="Update",t}($||{});var Ct=(t,d)=>({"over-due-today":t,"over-due":d});function St(t,d){if(t&1&&(o(0,"th",21),p(1),r()),t&2){let e=f();a(),S(" ",e.selectedChannel()?"Created Date":"Last Status Update"," ")}}function vt(t,d){if(t&1&&(o(0,"td"),p(1),R(2,"date"),r()),t&2){let e=f().$implicit;a(),S(" ",De(2,1,e.Modified,"dd MMM yyyy HH:mm:ss")," ")}}function yt(t,d){if(t&1&&(o(0,"span"),p(1),r()),t&2){let e=f().$implicit;a(),S(" ",e.ActionString," ")}}function xt(t,d){if(t&1&&(o(0,"li"),p(1),r()),t&2){let e=d.$implicit;a(),S(" ",e," ")}}function Dt(t,d){if(t&1&&(o(0,"ul",27),w(1,xt,2,1,"li",22),r()),t&2){let e=f().$implicit;a(),s("ngForOf",e.ActionString)}}function Tt(t,d){if(t&1&&(o(0,"span",28),C(1,"i",29),r()),t&2){let e=f().$implicit;we("title","Delivery : ",e.DeliveryState,`
|
|
2
|
+
Payment : `,e.PaymentState,"")}}function bt(t,d){if(t&1&&(o(0,"tr")(1,"td"),p(2),r(),o(3,"td"),p(4),r(),w(5,vt,3,4,"td",23),o(6,"td")(7,"span"),p(8),r(),p(9),r(),o(10,"td",24)(11,"span"),p(12),r(),p(13),r(),o(14,"td"),w(15,yt,2,1,"span",23)(16,Dt,2,1,"ul",25),r(),o(17,"td"),w(18,Tt,2,3,"span",26),r()()),t&2){let e,n=d.$implicit,i=d.index,l=f(2);a(2),k(i+1),a(2),k(n.Number),a(),s("ngIf",((e=l.selectedChannel())==null?null:e.TypeID)!=l.channelType.Shopee&&((e=l.selectedChannel())==null?null:e.TypeID)!==l.channelType.Tiktok),a(3),S("",n.ChannelStatus," - "),a(),S("",n.ChannelStatusDescription," "),a(),s("ngClass",xe(12,Ct,(n==null?null:n.Action)==l.actionPreviewOrder.Update,(n==null?null:n.Action)==l.actionPreviewOrder.New))("matTooltip",n.POSStatus==91||n.POSStatusDescription=="Conflict"?"There is a missed status at POS, usually fulfillment has not been recorded but the payment has been recorded":""),a(2),S("",n.POSStatus," - "),a(),S("",n.POSStatusDescription," "),a(2),s("ngIf",n.ActionString.length==1),a(),s("ngIf",n.ActionString.length>1),a(2),s("ngIf",n.ChannelStatus!=99&&n.POSStatus!=99)}}function Et(t,d){if(t&1&&(N(0),w(1,bt,19,15,"tr",22),W()),t&2){let e=f();a(),s("ngForOf",e.displayPreviewData())}}function Pt(t,d){t&1&&(o(0,"tr",30)(1,"td",31)(2,"div",32),C(3,"i",33),r(),o(4,"h4",34),p(5," There is no order to processed "),r()()())}var rt=(()=>{class t{constructor(){this.orderPreview=O(),this.selectedChannel=O(),this.channelType=ne,this.allData=_(0),this.syncData=_(0),this.wrongData=_(0),this.unsyncData=_(0),this.pillStatus=_(T.ALL),this.actionPreviewOrder=$,this.previewStatus=T,this.displayPreviewData=_([]),this.exportOrders=new B,J(()=>{this.orderPreview()&&(this.filterPreviewData(T.ALL),this.initLengthStatusData())},{allowSignalWrites:!0})}filterPreviewData(e){this.pillStatus.update(()=>e),this.displayPreviewData.update(()=>this.filterDataByStatus(e))}initLengthStatusData(){this.wrongData.update(()=>this.filterDataByStatus(T.WRONG).length),this.syncData.update(()=>this.filterDataByStatus(T.SYNC).length),this.allData.update(()=>this.orderPreview().length),this.unsyncData.update(()=>this.filterDataByStatus(T.UNSYNC).length)}filterDataByStatus(e){let n=[];switch(e){case T.ALL:n=this.orderPreview();break;case T.SYNC:n=this.orderPreview().filter(i=>i.Action==$.DoNothing);break;case T.WRONG:n=this.orderPreview().filter(i=>i.Action==$.Update);break;case T.UNSYNC:n=this.orderPreview().filter(i=>i.Action==$.New);break}return n}onExportOrders(){this.exportOrders.emit()}static{this.\u0275fac=function(n){return new(n||t)}}static{this.\u0275cmp=I({type:t,selectors:[["preview-step"]],inputs:{orderPreview:[1,"orderPreview"],selectedChannel:[1,"selectedChannel"]},outputs:{exportOrders:"onExportOrders"},decls:41,vars:11,consts:[["EMPTY",""],[1,"row","pt-2"],[1,"col-md-12"],[1,"row","mx-1","mb-5"],[1,"col-12","d-flex","justify-content-between","align-items-end",2,"padding-left","0px","padding-right","0px"],[1,"nav","nav-pills"],[1,"nav-item","me-3"],[1,"btn","btn-sm","rounded-pill",3,"click","ngClass"],[1,"nav-item","mx-3"],["matTooltip","All Invoice which is already available in POS",1,"btn","btn-sm","rounded-pill",3,"click","ngClass"],["matTooltip","Invoices that have different status between marketplace and POS",1,"btn","btn-sm","rounded-pill",3,"click","ngClass"],["matTooltip","Invoices which is not exist in POS",1,"btn","btn-sm","rounded-pill",3,"click","ngClass"],["type","button",1,"btn","btn-outline-secondary",3,"click"],[1,"fa-solid","fa-print","me-3"],[1,"table"],[1,"thead-light"],["width","1%"],["width","25%"],["width","15%",4,"ngIf"],["width","10%"],[4,"ngIf","ngIfElse"],["width","15%"],[4,"ngFor","ngForOf"],[4,"ngIf"],["matTooltipClass","custom-width-tooltip",3,"ngClass","matTooltip"],["class","ps-5",4,"ngIf"],[3,"title",4,"ngIf"],[1,"ps-5"],[3,"title"],[1,"fas","fa-info-circle","ms-2"],[1,"text-center"],["colspan","10",1,"border-0"],[2,"margin-top","16vh"],[1,"far","fa-file","text-secondary",2,"font-size","95px"],[1,"text-secondary","mt-6"]],template:function(n,i){if(n&1){let l=v();o(0,"div",1)(1,"div",2)(2,"div",3)(3,"div",4)(4,"div")(5,"ul",5)(6,"li",6)(7,"button",7),g("click",function(){return m(l),c(i.filterPreviewData(i.previewStatus.ALL))}),p(8),r()(),o(9,"li",8)(10,"button",9),g("click",function(){return m(l),c(i.filterPreviewData(i.previewStatus.SYNC))}),p(11),r()(),o(12,"li",8)(13,"button",10),g("click",function(){return m(l),c(i.filterPreviewData(i.previewStatus.WRONG))}),p(14),r()(),o(15,"li",8)(16,"button",11),g("click",function(){return m(l),c(i.filterPreviewData(i.previewStatus.UNSYNC))}),p(17),r()()()(),o(18,"div")(19,"button",12),g("click",function(){return m(l),c(i.onExportOrders())}),C(20,"i",13),o(21,"span"),p(22,"Export"),r()()()()(),o(23,"table",14)(24,"thead",15)(25,"tr"),C(26,"th",16),o(27,"th",17),p(28,"Number"),r(),w(29,St,2,1,"th",18),o(30,"th",19),p(31,"Channel Status"),r(),o(32,"th",19),p(33,"POS Status"),r(),o(34,"th"),p(35,"Action"),r(),C(36,"th",16),r()(),o(37,"tbody"),w(38,Et,2,1,"ng-container",20)(39,Pt,6,0,"ng-template",null,0,q),r()()()()}if(n&2){let l,h,u=D(40);a(7),s("ngClass",i.pillStatus()=="all"?"btn-secondary text-white":"btn-outline-dark"),a(),S(" All (",i.allData(),") "),a(2),s("ngClass",i.pillStatus()=="sync"?"btn-success":"btn-outline-success"),a(),S(" Existing (",i.syncData(),") "),a(2),s("ngClass",i.pillStatus()=="wrong"?"btn-warning text-white":"btn-outline-warning"),a(),S(" Wrong Status (",i.wrongData(),") "),a(2),s("ngClass",i.pillStatus()=="unsync"?"btn-danger":"btn-outline-danger"),a(),S(" Missing (",i.unsyncData(),") "),a(12),s("ngIf",((l=i.selectedChannel())==null?null:l.TypeID)!=i.channelType.Shopee&&((l=i.selectedChannel())==null?null:l.TypeID)!==i.channelType.Tiktok),a(9),s("ngIf",((h=i.displayPreviewData())==null?null:h.length)>0)("ngIfElse",u)}},dependencies:[M,F,L,A,z,le,ae],encapsulation:2})}}return t})();var It=["stepper"];function Mt(t,d){if(t&1){let e=v();o(0,"div",2)(1,"button",18),g("click",function(){m(e);let i=f();return c(i.onStepperBack())}),p(2," Back "),r(),o(3,"button",19),g("click",function(){m(e);let i=f();return c(i.onNextStep())}),p(4," Next "),r()()}if(t&2){let e=f();a(3),s("disabled",e.disabledNextFilter())}}function Vt(t,d){if(t&1){let e=v();o(0,"button",20),g("click",function(){m(e);let i=f();return c(i.onNextStep())}),p(1," Next "),r()}if(t&2){let e=f();s("disabled",e.disabledNextFilter())}}function kt(t,d){if(t&1){let e=v();o(0,"div",2)(1,"button",21),g("click",function(){m(e);let i=f();return c(i.onNewDownload(!1))}),C(2,"i",22),p(3," Repeat Last "),r(),o(4,"button",23),g("click",function(){m(e);let i=f();return c(i.onNewDownload())}),C(5,"i",24),p(6," New "),r()()}}function Ft(t,d){t&1&&(C(0,"i",25),o(1,"span"),p(2,"Filter"),r())}function Ot(t,d){t&1&&(C(0,"i",26),o(1,"span"),p(2,"Preview"),r())}function Nt(t,d){if(t&1){let e=v();N(0),o(1,"preview-step",27),g("onExportOrders",function(){m(e);let i=f();return c(i.onExportOrders())}),r(),W()}if(t&2){let e=d.ngIf;a(),s("orderPreview",e)}}function Wt(t,d){t&1&&(C(0,"i",28),o(1,"span"),p(2,"Finish"),r())}function Rt(t,d){if(t&1&&(N(0),C(1,"complete-step",29),W()),t&2){let e=d.ngIf;a(),s("downloadResult",e)}}function Bt(t,d){t&1&&(o(0,"h6"),p(1,"1"),r())}function Lt(t,d){t&1&&(o(0,"h6"),p(1,"2"),r())}function At(t,d){t&1&&(o(0,"h6"),p(1,"3"),r())}var mn=(()=>{class t{constructor(){this.downloadService=y(Y),this.orderService=y(se),this.productService=y(ze),this.authService=y(re),this.stepperSelectedIndex=_(0),this.disabledNextFilter=_(!0),this.isResetFilter=_(!1),this.pageTitle=_("Download to POS"),this.cacheKey=_(x.GuidEMpty)}onFilterChange(e){this.filter=e,this.validateDisabledNext()}validateDisabledNext(){this.disabledNextFilter.update(()=>x.IsEmpty(this.filter?.channelId)||!x.isValidDate(this.filter.startDate)||!x.isValidDate(this.filter.endDate))}onNextStep(){switch(this.stepper.selectedIndex){case 0:this.onPreview();let e=this.productService.findChannelById(this.filter.channelId,this.authService.getChannels());this.setPageTitle(`Preview ${e?.Name}`);break;case 1:this.onDownload(),this.setPageTitle("Download");break}}onStepperNext(){this.stepper.selected.completed=!0,this.stepper.next()}onPreview(){let e={ID:this.filter.channelId,From:this.filter.startDate,To:this.filter.endDate,IsDisbursement:this.filter.downloadType};x.IsNotEmpty(this.filter.startTime)&&(e=me(de({},e),{TimeFrom:this.filter.startTime+":00",TimeTo:this.filter.endTime+":00"})),this.orderPreview$=this.downloadService.onPreviewOrder(e).pipe(G(n=>{n.Data?.length>0&&(this.cacheKey.update(()=>n.CacheKey),this.onStepperNext())}),K(n=>n.Data),U(1))}onExportOrders(){let e={ID:this.filter.channelId,From:this.filter.startDate?this.filter.startDate:null,To:this.filter.endDate?this.filter.endDate:null},n=`Orders ${this.downloadService.getDateTitle(this.filter.startDate,this.filter.endDate)}`;this.orderService.exportOrders(e,n).subscribe()}onDownload(){let e={ID:this.filter.channelId,From:this.filter.startDate,To:this.filter.endDate,ListPreview:[],IsDisbursement:this.filter.downloadType,CacheKey:this.cacheKey()};this.downloadPreview$=this.orderPreview$.pipe(ue(n=>(e.ListPreview=n,this.downloadService.getDownloadOrder(e))),G(()=>{this.onStepperNext()}),U(1))}setPageTitle(e){this.pageTitle.update(()=>`
|
|
3
|
+
${e} (${this.downloadService.getDateTitle(this.filter.startDate,this.filter.endDate)})
|
|
4
|
+
`)}onStepperBack(){this.stepper.previous(),this.pageTitle.update(()=>"Download to POS")}onNewDownload(e=!0){this.isResetFilter.update(()=>e),this.stepper.reset(),this.stepperSelectedIndex.update(()=>0),this.orderPreview$=null,this.downloadPreview$=null,this.pageTitle.update(()=>"Download to POS")}static{this.\u0275fac=function(n){return new(n||t)}}static{this.\u0275cmp=I({type:t,selectors:[["app-download-v2"]],viewQuery:function(n,i){if(n&1&&Ce(It,5),n&2){let l;Se(l=ve())&&(i.stepper=l.first)}},features:[Q([Y,se,{provide:He,useValue:{displayDefaultIndicatorType:!1}}])],decls:26,vars:20,consts:[["stepper",""],[3,"hideSearchBox","hideSearchDropdown","headerTitle","description"],[1,"btn-group","me-3"],["type","button",1,"btn","btn-outline-secondary","btn-fill","me-3","bg-success","text-white",3,"disabled"],[1,"container-fluid","pt-5","mt-5"],[1,"row"],[1,"col-12"],[1,"d-flex","justify-content-center"],["linear","",1,"w-100","stepper-download",3,"selectedIndexChange","ngClass","selectedIndex"],["state","filter",3,"completed","editable"],["matStepLabel",""],[1,"w-100",3,"onFilterChange","reset"],["state","preview",3,"editable","completed"],[4,"ngIf"],["state","finish"],["matStepperIcon","filter"],["matStepperIcon","preview"],["matStepperIcon","finish"],[1,"btn","btn-outline-secondary",3,"click"],["type","button",1,"btn","btn-outline-secondary","bg-success","text-white",3,"click","disabled"],["type","button",1,"btn","btn-outline-secondary","btn-fill","me-3","bg-success","text-white",3,"click","disabled"],["matTooltip","Creates a new download order using previous channel and date settings.",1,"btn","btn-outline-secondary","border-end-0","d-flex","align-items-center","gap-2",3,"click"],[1,"fa-solid","fa-rotate"],[1,"btn","btn-outline-secondary","btn-fill","d-flex","align-items-center","gap-2",3,"click"],["aria-hidden","true",1,"fa","fa-file-alt"],[1,"fa-solid","fa-filter","me-3"],[1,"fa-solid","fa-file","me-3"],[3,"onExportOrders","orderPreview"],[1,"fa-solid","fa-flag","me-3"],[3,"downloadResult"]],template:function(n,i){if(n&1){let l=v();o(0,"mainpanel",1)(1,"actions"),w(2,Mt,5,1,"div",2)(3,Vt,2,1,"button",3)(4,kt,7,0,"div",2),r(),o(5,"content")(6,"div",4)(7,"div",5)(8,"div",6)(9,"div",7)(10,"mat-stepper",8,0),P("selectedIndexChange",function(u){return m(l),E(i.stepperSelectedIndex,u)||(i.stepperSelectedIndex=u),c(u)}),o(12,"mat-step",9),w(13,Ft,3,0,"ng-template",10),o(14,"filter-step",11),g("onFilterChange",function(u){return m(l),c(i.onFilterChange(u))}),r()(),o(15,"mat-step",12),w(16,Ot,3,0,"ng-template",10)(17,Nt,2,1,"ng-container",13),R(18,"async"),r(),o(19,"mat-step",14),w(20,Wt,3,0,"ng-template",10)(21,Rt,2,1,"ng-container",13),R(22,"async"),r(),w(23,Bt,2,0,"ng-template",15)(24,Lt,2,0,"ng-template",16)(25,At,2,0,"ng-template",17),r()()()()()()()}if(n&2){let l=D(11);s("hideSearchBox",!0)("hideSearchDropdown",!0)("headerTitle",i.pageTitle())("description",i.pageTitle()),a(2),V(i.stepperSelectedIndex()==1?2:-1),a(),V(i.stepperSelectedIndex()==0?3:-1),a(),V(i.stepperSelectedIndex()==2?4:-1),a(6),ge("ngClass","last-edited-step-"+l.selectedIndex),b("selectedIndex",i.stepperSelectedIndex),a(2),s("completed",!1)("editable",i.stepperSelectedIndex()!=2),a(2),s("reset",i.isResetFilter()),a(),s("editable",i.stepperSelectedIndex()!=2)("completed",!1),a(2),s("ngIf",j(18,16,i.orderPreview$)),a(4),s("ngIf",j(22,18,i.downloadPreview$))}},dependencies:[M,F,A,X,it,ot,rt,Je,Ze,Ke,qe,Qe,Ne,Oe,Te,le,ae],styles:[`@import"https://fonts.googleapis.com/icon?family=Material+Icons";.vertical-radio{display:flex;flex-direction:column;margin:15px 0}.mt-1rem{margin-top:1rem}.dateRange{padding-top:.8rem;padding-bottom:.8rem}mat-stepper.stepper-download>div.mat-horizontal-stepper-wrapper>div.mat-horizontal-stepper-header-container{position:relative;width:60%;left:18%}mat-stepper.stepper-download>div.mat-horizontal-stepper-wrapper>div.mat-horizontal-content-container>div.mat-horizontal-stepper-content:nth-child(1){display:flex;justify-content:left}mat-stepper.stepper-download>div.mat-horizontal-stepper-wrapper>div.mat-horizontal-content-container{margin-top:30px}mat-stepper.stepper-download>div.mat-horizontal-stepper-wrapper>div.mat-horizontal-stepper-header-container>mat-step-header.mat-horizontal-stepper-header{pointer-events:none!important}.form-label-group.radio.download-type{height:45.5938px!important;border-radius:.375rem!important}
|
|
5
|
+
`],encapsulation:2})}}return t})();export{mn as DownloadV2Component};
|