dealpos 26.30.1 → 26.30.3

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.
Files changed (203) hide show
  1. package/browser/chunk-234IZ6JB.js +1 -0
  2. package/browser/{chunk-VUJYUW4B.js → chunk-24YLKMEJ.js} +1 -1
  3. package/browser/{chunk-SW36JALL.js → chunk-267KXOLJ.js} +1 -1
  4. package/browser/{chunk-OOZY7ONY.js → chunk-2AW77P5H.js} +1 -1
  5. package/browser/chunk-2BQDYASI.js +1 -0
  6. package/browser/{chunk-O7ZKLROG.js → chunk-2HN5GR2B.js} +1 -1
  7. package/browser/chunk-2VKPS7IO.js +1 -0
  8. package/browser/{chunk-YKDUJRJQ.js → chunk-3FFHADFC.js} +1 -1
  9. package/browser/{chunk-6UDJPNWQ.js → chunk-3N4VJXET.js} +2 -2
  10. package/browser/{chunk-EYZCE4MR.js → chunk-3SJFBB7T.js} +2 -2
  11. package/browser/chunk-3UEEGXMJ.js +1 -0
  12. package/browser/{chunk-7S2DSZZ5.js → chunk-3Z7HLWOO.js} +1 -1
  13. package/browser/{chunk-2G5ITVJD.js → chunk-4JAMO4DO.js} +1 -1
  14. package/browser/chunk-4TMVB2O5.js +1 -0
  15. package/browser/{chunk-FP32CB7R.js → chunk-4XSFWZ7K.js} +1 -1
  16. package/browser/{chunk-VOSUH2FH.js → chunk-4ZS5NPJA.js} +1 -1
  17. package/browser/{chunk-XJQK2FZL.js → chunk-5D2W2SP5.js} +1 -1
  18. package/browser/{chunk-HSPAVM3N.js → chunk-5TCU5VOU.js} +1 -1
  19. package/browser/{chunk-LXJGF6NW.js → chunk-63NBDUGE.js} +1 -1
  20. package/browser/chunk-6F5OU4FC.js +1 -0
  21. package/browser/{chunk-CP43G63M.js → chunk-6QO26KHZ.js} +1 -1
  22. package/browser/chunk-6UB2ORU6.js +1 -0
  23. package/browser/{chunk-32J765VE.js → chunk-6ZV2PHVD.js} +1 -1
  24. package/browser/chunk-7ALV5US7.js +1 -0
  25. package/browser/{chunk-TH4JMDG5.js → chunk-7N6KQX2C.js} +1 -1
  26. package/browser/chunk-7Q4RQO3T.js +1 -0
  27. package/browser/{chunk-P3ETYZDG.js → chunk-7QR74VBK.js} +1 -1
  28. package/browser/chunk-7QZC7EHM.js +1 -0
  29. package/browser/chunk-ABFEL75N.js +1 -0
  30. package/browser/{chunk-5N7G4FFD.js → chunk-ADCYV4TJ.js} +1 -1
  31. package/browser/{chunk-FVI5SC7Q.js → chunk-AHCUPROT.js} +1 -1
  32. package/browser/{chunk-NXP2YOF7.js → chunk-AQSP7KZF.js} +1 -1
  33. package/browser/{chunk-2TSNPNEF.js → chunk-AUDHO5BS.js} +1 -1
  34. package/browser/{chunk-6IJFHLF4.js → chunk-AXSGDNS3.js} +1 -1
  35. package/browser/{chunk-G76SIH77.js → chunk-BBDLBM57.js} +1 -1
  36. package/browser/{chunk-372I7ODN.js → chunk-BJBRXOGP.js} +1 -1
  37. package/browser/{chunk-SGDQUOYW.js → chunk-BLQ56J33.js} +1 -1
  38. package/browser/{chunk-UECJXUUG.js → chunk-BM54M3ZV.js} +1 -1
  39. package/browser/chunk-BML2AY2C.js +1 -0
  40. package/browser/chunk-BTYRA5DH.js +1 -0
  41. package/browser/{chunk-R4LZL5Y2.js → chunk-BUCTARFG.js} +1 -1
  42. package/browser/{chunk-JIFAA6T5.js → chunk-BXF5MZD5.js} +1 -1
  43. package/browser/chunk-BZRKNHOX.js +1 -0
  44. package/browser/{chunk-OEXZJIMU.js → chunk-C62BA3B5.js} +1 -1
  45. package/browser/{chunk-H2ZMJAQR.js → chunk-CCIW6FD2.js} +9 -9
  46. package/browser/{chunk-Y2DFS7SX.js → chunk-CFCLB4UL.js} +1 -1
  47. package/browser/chunk-CPETONXN.js +1 -0
  48. package/browser/chunk-CPMYAEHS.js +1 -0
  49. package/browser/{chunk-F3BFPEBH.js → chunk-D44RJQYD.js} +1 -1
  50. package/browser/chunk-D4JH7FVI.js +1 -0
  51. package/browser/{chunk-67THCBL2.js → chunk-DC4EEAY2.js} +1 -1
  52. package/browser/{chunk-QEPS52TW.js → chunk-DNYF7RWP.js} +1 -1
  53. package/browser/chunk-E2FZODHQ.js +1 -0
  54. package/browser/chunk-ED3UKGGI.js +1 -0
  55. package/browser/{chunk-QKENASDA.js → chunk-EHBSNGFA.js} +1 -1
  56. package/browser/chunk-ERVAGC2M.js +1 -0
  57. package/browser/{chunk-HRBJPZYS.js → chunk-EY3OGCXT.js} +1 -1
  58. package/browser/{chunk-3UYX5VKU.js → chunk-F7VCZNZA.js} +1 -1
  59. package/browser/{chunk-IM2IJNVE.js → chunk-FI7CDHP2.js} +1 -1
  60. package/browser/{chunk-U4JQYTWC.js → chunk-FPHH3KEE.js} +1 -1
  61. package/browser/{chunk-NR5UTV5U.js → chunk-G2B2G6M2.js} +1 -1
  62. package/browser/{chunk-YWNZKVYV.js → chunk-G2L3TRZ4.js} +1 -1
  63. package/browser/{chunk-IAVFD3N7.js → chunk-GDMVDLQL.js} +1 -1
  64. package/browser/{chunk-7LAP5RUT.js → chunk-GG5OI4YH.js} +1 -1
  65. package/browser/chunk-GOIHN3D3.js +1 -0
  66. package/browser/{chunk-5IMVRDTX.js → chunk-GTOCPV7W.js} +1 -1
  67. package/browser/{chunk-5XSMBDBM.js → chunk-GXHORCDU.js} +1 -1
  68. package/browser/chunk-HL3ZTS2Q.js +1 -0
  69. package/browser/{chunk-NZTQJSEP.js → chunk-I5JH4FHZ.js} +1 -1
  70. package/browser/{chunk-ZX5GTIAE.js → chunk-IIARVTAV.js} +1 -1
  71. package/browser/{chunk-FIQNUVMF.js → chunk-ILBK4QJU.js} +1 -1
  72. package/browser/chunk-INDAHAW2.js +1 -0
  73. package/browser/{chunk-VEGZNPXT.js → chunk-INWOK4UB.js} +1 -1
  74. package/browser/chunk-IYDU3AE2.js +1 -0
  75. package/browser/{chunk-UGRPPHDO.js → chunk-JDGHR27I.js} +1 -1
  76. package/browser/{chunk-4EBPNVWA.js → chunk-JG644ODH.js} +1 -1
  77. package/browser/{chunk-HSVOXLBX.js → chunk-JLSA27FL.js} +1 -1
  78. package/browser/{chunk-2Y3DZIBX.js → chunk-JUW73YUO.js} +1 -1
  79. package/browser/chunk-KGAHREO6.js +1 -0
  80. package/browser/{chunk-KIIQEUSN.js → chunk-KYQBB6FB.js} +1 -1
  81. package/browser/{chunk-Q5UPNW6B.js → chunk-LBMNHT4D.js} +1 -1
  82. package/browser/chunk-LC5WF2P3.js +1 -0
  83. package/browser/{chunk-ULI2FUQF.js → chunk-LPX5PQK3.js} +1 -1
  84. package/browser/chunk-LRI4FYQL.js +1 -0
  85. package/browser/chunk-LUB27447.js +1 -0
  86. package/browser/{chunk-WIRN7ZRP.js → chunk-LYSVMNCT.js} +1 -1
  87. package/browser/{chunk-FWZX7JYG.js → chunk-M2XJN3EA.js} +1 -1
  88. package/browser/{chunk-RPODM7L6.js → chunk-M3YZKABE.js} +1 -1
  89. package/browser/{chunk-LOQIFT7X.js → chunk-M65CFXIN.js} +2 -2
  90. package/browser/chunk-MFACJXXS.js +1 -0
  91. package/browser/chunk-MZRMVLSE.js +1 -0
  92. package/browser/chunk-NHLHHX2K.js +1 -0
  93. package/browser/{chunk-FSWCGQV3.js → chunk-NNN6BME2.js} +1 -1
  94. package/browser/{chunk-WEK5HY23.js → chunk-NTNQHEGU.js} +1 -1
  95. package/browser/{chunk-F62EEI7V.js → chunk-NVSZUDQ3.js} +1 -1
  96. package/browser/{chunk-KHSBIFF7.js → chunk-OJ7VTWPV.js} +1 -1
  97. package/browser/{chunk-YCJSC27J.js → chunk-OQL3WWEJ.js} +1 -1
  98. package/browser/{chunk-2O7IVX3Q.js → chunk-P3Y5AQLZ.js} +1 -1
  99. package/browser/{chunk-5L7XD2GC.js → chunk-PW3MBJLX.js} +1 -1
  100. package/browser/{chunk-VYJIQZSD.js → chunk-QHOC7DPY.js} +1 -1
  101. package/browser/{chunk-CFGMBTZN.js → chunk-QKLRCAYM.js} +2 -1
  102. package/browser/{chunk-JEDBCM6K.js → chunk-QMWH3WHD.js} +2 -2
  103. package/browser/chunk-R4YS2IS7.js +1 -0
  104. package/browser/{chunk-VBLTDQN5.js → chunk-R4ZDB744.js} +1 -1
  105. package/browser/{chunk-LPUQAFVP.js → chunk-RCBOZX2E.js} +1 -1
  106. package/browser/{chunk-ZFUGHOEG.js → chunk-RDURQRVN.js} +1 -1
  107. package/browser/chunk-RHYAC3BP.js +1 -0
  108. package/browser/{chunk-DKC2333V.js → chunk-RIYY3QQM.js} +1 -1
  109. package/browser/{chunk-V267DI7N.js → chunk-RJDXGATF.js} +1 -1
  110. package/browser/{chunk-PU6ABESZ.js → chunk-RLLTMUIE.js} +1 -1
  111. package/browser/chunk-RNEV3ORY.js +1 -0
  112. package/browser/chunk-RQ6DQAQE.js +1 -0
  113. package/browser/{chunk-VY2MUXC2.js → chunk-RXTLYS3E.js} +1 -1
  114. package/browser/{chunk-JW6IPMHK.js → chunk-SK7ARU4O.js} +1 -1
  115. package/browser/{chunk-5RQPTRUE.js → chunk-SXIGGHCM.js} +2 -2
  116. package/browser/{chunk-6EUXVAG7.js → chunk-T5POZFJR.js} +1 -1
  117. package/browser/chunk-TGVKI45P.js +1 -0
  118. package/browser/chunk-TP5QNVUY.js +1 -0
  119. package/browser/{chunk-HU4EIZBQ.js → chunk-TS3T4RUV.js} +1 -1
  120. package/browser/{chunk-CSC7GRMN.js → chunk-TU65CJU6.js} +1 -1
  121. package/browser/chunk-TWKXHHO2.js +1 -0
  122. package/browser/{chunk-3SGQRG2L.js → chunk-TXTMOYXQ.js} +1 -1
  123. package/browser/{chunk-IQCCGJQT.js → chunk-TYA4ZZGP.js} +1 -1
  124. package/browser/{chunk-7TZA224I.js → chunk-TYDYN2JU.js} +1 -1
  125. package/browser/chunk-U5ZTPMEI.js +1 -0
  126. package/browser/{chunk-F6EZLQKU.js → chunk-U7YB5QYB.js} +1 -1
  127. package/browser/chunk-UBR2AQFM.js +1 -0
  128. package/browser/{chunk-SAE4L6UB.js → chunk-UO6VYPQB.js} +1 -1
  129. package/browser/{chunk-LMFSJKRH.js → chunk-UQWOSVAY.js} +2 -2
  130. package/browser/{chunk-Y6TPKHHE.js → chunk-US4LHROB.js} +1 -1
  131. package/browser/{chunk-2KDC3AVY.js → chunk-USXXWE3L.js} +1 -1
  132. package/browser/chunk-UV57IZAS.js +1 -0
  133. package/browser/chunk-V7LHTJAP.js +1 -0
  134. package/browser/{chunk-SDP33H3D.js → chunk-VG7AM63M.js} +1 -1
  135. package/browser/{chunk-IV6WUDI3.js → chunk-W33LB7GX.js} +1 -1
  136. package/browser/chunk-W4Z2HLSS.js +1 -0
  137. package/browser/{chunk-4PW65MBC.js → chunk-WBUZCVFS.js} +1 -1
  138. package/browser/{chunk-U4BKVMJO.js → chunk-WE7MAWON.js} +1 -1
  139. package/browser/{chunk-RCJSPD2P.js → chunk-WF4CWM6A.js} +1 -1
  140. package/browser/{chunk-RHSAPRE2.js → chunk-WYDVIMXE.js} +1 -1
  141. package/browser/{chunk-TV5CE6P6.js → chunk-XDXFOB74.js} +1 -1
  142. package/browser/{chunk-FX37N6ZC.js → chunk-XGLKE2VY.js} +1 -1
  143. package/browser/chunk-XILOY4YC.js +1 -0
  144. package/browser/{chunk-2WIQ2YXK.js → chunk-XOYAX2XN.js} +1 -1
  145. package/browser/chunk-YW56WULM.js +1 -0
  146. package/browser/{chunk-ZM6RNK6V.js → chunk-YZJ46NPL.js} +1 -1
  147. package/browser/{chunk-ZAENGBV2.js → chunk-ZBXFSNXW.js} +1 -1
  148. package/browser/{chunk-HVQK2POK.js → chunk-ZG7JV4Z6.js} +1 -1
  149. package/browser/chunk-ZPEHL67E.js +1 -0
  150. package/browser/{chunk-EMTKOY7E.js → chunk-ZQVSSHSG.js} +1 -1
  151. package/browser/chunk-ZV4UJN6M.js +1 -0
  152. package/browser/{chunk-G4KXN4G4.js → chunk-ZWRKBAF7.js} +1 -1
  153. package/browser/index.html +2 -2
  154. package/browser/{main-O7WFIM44.js → main-KDGMS2WN.js} +1 -1
  155. package/package.json +1 -1
  156. package/browser/chunk-2GPXOOW7.js +0 -1
  157. package/browser/chunk-2P2S4KQ5.js +0 -1
  158. package/browser/chunk-2Z42KXEY.js +0 -1
  159. package/browser/chunk-3YO25AQ7.js +0 -1
  160. package/browser/chunk-46XIBH65.js +0 -1
  161. package/browser/chunk-5VINLXSF.js +0 -1
  162. package/browser/chunk-6JXM74BJ.js +0 -1
  163. package/browser/chunk-6LQMEQEU.js +0 -1
  164. package/browser/chunk-6S4E47O4.js +0 -1
  165. package/browser/chunk-73NHYAR5.js +0 -1
  166. package/browser/chunk-7F7RAG76.js +0 -1
  167. package/browser/chunk-7KT2XXNE.js +0 -1
  168. package/browser/chunk-7UBQEOQE.js +0 -1
  169. package/browser/chunk-B4M62NJ2.js +0 -1
  170. package/browser/chunk-B4P5T3NY.js +0 -1
  171. package/browser/chunk-B4PI75AJ.js +0 -1
  172. package/browser/chunk-CLXPTAPF.js +0 -1
  173. package/browser/chunk-CQWNK2TW.js +0 -1
  174. package/browser/chunk-CTFBNPAW.js +0 -1
  175. package/browser/chunk-DHSTO6XC.js +0 -1
  176. package/browser/chunk-DLHZIL46.js +0 -1
  177. package/browser/chunk-DPFPMNIJ.js +0 -1
  178. package/browser/chunk-E5E54PMX.js +0 -1
  179. package/browser/chunk-FFLQ2JKL.js +0 -1
  180. package/browser/chunk-H3PXDCCM.js +0 -1
  181. package/browser/chunk-I25GGOTU.js +0 -1
  182. package/browser/chunk-IAAZRGSS.js +0 -1
  183. package/browser/chunk-J43YMK3G.js +0 -1
  184. package/browser/chunk-J5G5NUTY.js +0 -1
  185. package/browser/chunk-LBEMHG6A.js +0 -1
  186. package/browser/chunk-LDF4RZGO.js +0 -1
  187. package/browser/chunk-LN7R5WBC.js +0 -1
  188. package/browser/chunk-LUNRPOUW.js +0 -1
  189. package/browser/chunk-NDGM7I2C.js +0 -1
  190. package/browser/chunk-NM5KK7IO.js +0 -1
  191. package/browser/chunk-OR552VFU.js +0 -1
  192. package/browser/chunk-P2SIRK4S.js +0 -1
  193. package/browser/chunk-PI7VHFOF.js +0 -1
  194. package/browser/chunk-PWBYG5MY.js +0 -1
  195. package/browser/chunk-Q6BCS47I.js +0 -1
  196. package/browser/chunk-ROXQFPIN.js +0 -1
  197. package/browser/chunk-RUU2GOJ2.js +0 -1
  198. package/browser/chunk-UKB6BG2N.js +0 -1
  199. package/browser/chunk-WET67EGX.js +0 -1
  200. package/browser/chunk-XGOLB5BG.js +0 -1
  201. package/browser/chunk-Y5637KXK.js +0 -1
  202. package/browser/chunk-YI6XI2ZF.js +0 -1
  203. package/browser/chunk-YPTEYATZ.js +0 -1
@@ -0,0 +1 @@
1
+ import{a as P}from"./chunk-TUL4SCIV.js";import{a as c}from"./chunk-KGAHREO6.js";import{a as b}from"./chunk-UWUSG6X7.js";import{a as S}from"./chunk-L2AMDQ4D.js";import"./chunk-FBXWSJGZ.js";import"./chunk-2PUGC5XR.js";import"./chunk-TDI2ZUL6.js";import"./chunk-CNBTTBK3.js";import"./chunk-CCLE2IVS.js";import"./chunk-7VXCKSAE.js";import"./chunk-KFWGALIF.js";import"./chunk-Z7UCI72M.js";import"./chunk-PPMQE2JW.js";import"./chunk-DU6XSMWH.js";import"./chunk-RJDDPGUV.js";import"./chunk-OTSIIVCA.js";import"./chunk-QSBTT5BF.js";import"./chunk-IX2NXO5F.js";import"./chunk-ZRB4EZI3.js";import"./chunk-3MLD6BQG.js";import"./chunk-LUUIBDJG.js";import"./chunk-R7VXUOCU.js";import"./chunk-NYN3E7NN.js";import{E as _,h as D,o as C}from"./chunk-R36OIJC7.js";import"./chunk-AGPZGAMV.js";import"./chunk-PPTZHIIZ.js";import"./chunk-ETYXTCKV.js";import{Db as n,Eb as o,Fb as a,Nd as y,Oc as g,Ua as i,db as s,mc as l,na as u,nc as r,oc as d}from"./chunk-DUSKF5IQ.js";import"./chunk-NF7PG5F2.js";var M=class f{activatedRoute=u(y);settings=u(S);formData=g(()=>this.settings.formData());options=g(()=>this.settings.options());configDefault=g(()=>this.settings.configDefault());constructor(){this.settings.initFormData(this.activatedRoute)}static \u0275fac=function(m){return new(m||f)};static \u0275cmp=s({type:f,selectors:[["POS-debt"]],decls:26,vars:37,consts:[["cardTitle","Header","id","headerDebt"],[1,"row"],[1,"col-6"],[3,"ngModelChange","label","tooltip","type","ngModel"],["cardTitle","Join Invoice","id","joinInvoiceDebt"],[1,"col-12"],[3,"ngModelChange","label","description","ngModel","defaultConfig"],["cardTitle","Signature","id","signatureDebt"],["cardTitle","Footer Label","id","footerLabelDebt"],[3,"ngModelChange","label","type","ngModel","isHorizontalLayout","description"]],template:function(m,t){m&1&&(o(0,"POS-card",0)(1,"div",1)(2,"div",2)(3,"POS-input-field",3),d("ngModelChange",function(e){return r(t.formData().HeaderTitleAR,e)||(t.formData().HeaderTitleAR=e),e}),a()(),o(4,"div",2)(5,"POS-input-field",3),d("ngModelChange",function(e){return r(t.formData().HeaderTitleAP,e)||(t.formData().HeaderTitleAP=e),e}),a()()()(),o(6,"POS-card",4)(7,"div",1)(8,"div",5)(9,"POS-input-toggle",6),d("ngModelChange",function(e){return r(t.formData().ARColletion.InvoiceDetailVisible,e)||(t.formData().ARColletion.InvoiceDetailVisible=e),e}),a()(),o(10,"div",5)(11,"POS-input-toggle",6),d("ngModelChange",function(e){return r(t.formData().ARColletion.DueDateVisible,e)||(t.formData().ARColletion.DueDateVisible=e),e}),a()()()(),o(12,"POS-card",7)(13,"div",1)(14,"div",2)(15,"POS-input-field",3),d("ngModelChange",function(e){return r(t.formData().Signature.Column1,e)||(t.formData().Signature.Column1=e),e}),a()(),o(16,"div",2)(17,"POS-input-field",3),d("ngModelChange",function(e){return r(t.formData().Signature.Column2,e)||(t.formData().Signature.Column2=e),e}),a()(),o(18,"div",2)(19,"POS-input-field",3),d("ngModelChange",function(e){return r(t.formData().Signature.Column3,e)||(t.formData().Signature.Column3=e),e}),a()(),o(20,"div",2)(21,"POS-input-field",3),d("ngModelChange",function(e){return r(t.formData().Signature.Column4,e)||(t.formData().Signature.Column4=e),e}),a()()()(),o(22,"POS-card",8)(23,"div",1)(24,"div",5)(25,"POS-input-field",9),d("ngModelChange",function(e){return r(t.formData().FooterLabel.RemainingLabel,e)||(t.formData().FooterLabel.RemainingLabel=e),e}),a()()()()),m&2&&(i(3),n("label","Title Join Invoice")("tooltip"," Default Label on Join Invoice Print Header")("type","text"),l("ngModel",t.formData().HeaderTitleAR),i(2),n("label","Tittle Join Bill")("tooltip","Default Label on Join Bill Print Header")("type","text"),l("ngModel",t.formData().HeaderTitleAP),i(4),n("label","Product Visible")("description","Display Product from Invoice on Join Invoice Printing"),l("ngModel",t.formData().ARColletion.InvoiceDetailVisible),n("defaultConfig",t.configDefault().ARColletion.InvoiceDetailVisible),i(2),n("label","Due Date Visible")("description","Display Due date on Join Invoice Printing"),l("ngModel",t.formData().ARColletion.DueDateVisible),n("defaultConfig",t.configDefault().ARColletion.DueDateVisible),i(4),n("label","Column 1")("tooltip"," Join Invoice Signature - First Column ")("type","text"),l("ngModel",t.formData().Signature.Column1),i(2),n("label","Column 2")("tooltip"," Join Invoice Signature - Second Column ")("type","text"),l("ngModel",t.formData().Signature.Column2),i(2),n("label","Column 3")("tooltip"," Join Invoice Signature - Third Column ")("type","text"),l("ngModel",t.formData().Signature.Column3),i(2),n("label","Column 4")("tooltip"," Join Invoice Signature - Fourth Column ")("type","text"),l("ngModel",t.formData().Signature.Column4),i(4),n("label","Join Invoice Remaining Amount")("type","text"),l("ngModel",t.formData().FooterLabel.RemainingLabel),n("isHorizontalLayout",!0)("description","Configure default label for remaining amount in join invoice printing."))},dependencies:[b,c,P,_,D,C],encapsulation:2})};export{M as DebtComponent};
@@ -1,4 +1,4 @@
1
- import{a as se}from"./chunk-Y6TPKHHE.js";import{a as _t}from"./chunk-JI7J6USO.js";import{a as kt,b as ce}from"./chunk-KIONH5BK.js";import{b as wt,c as St,f as Vt}from"./chunk-NZTQJSEP.js";import{a as re,b as le}from"./chunk-Z7UCI72M.js";import{N as xt,n as yt}from"./chunk-7OCVKGLK.js";import{c as vt}from"./chunk-LCBHD53Y.js";import{b as Tt,c as Mt,f as pe}from"./chunk-C6TJ57ES.js";import{a as Ge}from"./chunk-VUC4E73K.js";import{u as Ct}from"./chunk-OTSIIVCA.js";import{d as bt}from"./chunk-R7VXUOCU.js";import{B as lt,Ca as mt,Da as ft,Fa as gt,G as oe,Ga as ht,Ha as j,N as st,X as ve,ca as ct,da as pt,oa as dt,ra as ut,s as rt,sa as ae}from"./chunk-NYN3E7NN.js";import{E as ie,c as et,h as te,i as tt,k as nt,o as ne,p as it}from"./chunk-R36OIJC7.js";import{a as Je,c as at}from"./chunk-DKC2333V.js";import{a as ot}from"./chunk-FX37N6ZC.js";import{a as Xe}from"./chunk-PPTZHIIZ.js";import{$ as Ve,$a as y,$c as ze,Ab as V,Ba as De,Bb as k,Cb as T,Da as ge,Db as g,Eb as r,Fa as he,Fb as l,Fc as Y,Gb as h,Gc as Ne,Hc as Re,M as fe,Oc as Ce,Pb as b,Qd as Ze,Rd as qe,Sb as f,Sc as He,Sd as Ye,Ta as Ie,Tc as w,Ua as s,Ub as c,Uc as G,Vb as U,Wb as M,Xb as Z,Xc as je,Zb as D,_b as I,ac as Oe,ad as X,ba as ke,bc as Ke,bd as Qe,d as we,db as K,eb as $,ec as R,fc as Le,gb as Ee,gc as _e,hb as Fe,hc as _,ib as Pe,ic as L,id as We,ja as B,jb as be,jc as A,ka as W,la as Te,mc as E,md as $e,na as O,nc as F,nd as Ue,oc as P,r as Se,ra as p,sa as d,sb as Be,sc as H,vd as J,wb as u,wc as Ae,wd as ee,xc as q,ya as v,yb as m,yc as x,za as Me}from"./chunk-DUSKF5IQ.js";import{a as S,b as Q}from"./chunk-NF7PG5F2.js";var de=class t{_openDialog=new we;openDialog$=this._openDialog.asObservable();openDialog(o){this._openDialog.next(o??{})}static \u0275fac=function(e){return new(e||t)};static \u0275prov=B({token:t,factory:t.\u0275fac,providedIn:"root"})};var Dt=`
1
+ import{a as se}from"./chunk-US4LHROB.js";import{a as _t}from"./chunk-JI7J6USO.js";import{a as kt,b as ce}from"./chunk-KIONH5BK.js";import{b as wt,c as St,f as Vt}from"./chunk-I5JH4FHZ.js";import{a as re,b as le}from"./chunk-Z7UCI72M.js";import{N as xt,n as yt}from"./chunk-7OCVKGLK.js";import{c as vt}from"./chunk-LCBHD53Y.js";import{b as Tt,c as Mt,f as pe}from"./chunk-C6TJ57ES.js";import{a as Ge}from"./chunk-VUC4E73K.js";import{u as Ct}from"./chunk-OTSIIVCA.js";import{d as bt}from"./chunk-R7VXUOCU.js";import{B as lt,Ca as mt,Da as ft,Fa as gt,G as oe,Ga as ht,Ha as j,N as st,X as ve,ca as ct,da as pt,oa as dt,ra as ut,s as rt,sa as ae}from"./chunk-NYN3E7NN.js";import{E as ie,c as et,h as te,i as tt,k as nt,o as ne,p as it}from"./chunk-R36OIJC7.js";import{a as Je,c as at}from"./chunk-RIYY3QQM.js";import{a as ot}from"./chunk-XGLKE2VY.js";import{a as Xe}from"./chunk-PPTZHIIZ.js";import{$ as Ve,$a as y,$c as ze,Ab as V,Ba as De,Bb as k,Cb as T,Da as ge,Db as g,Eb as r,Fa as he,Fb as l,Fc as Y,Gb as h,Gc as Ne,Hc as Re,M as fe,Oc as Ce,Pb as b,Qd as Ze,Rd as qe,Sb as f,Sc as He,Sd as Ye,Ta as Ie,Tc as w,Ua as s,Ub as c,Uc as G,Vb as U,Wb as M,Xb as Z,Xc as je,Zb as D,_b as I,ac as Oe,ad as X,ba as ke,bc as Ke,bd as Qe,d as we,db as K,eb as $,ec as R,fc as Le,gb as Ee,gc as _e,hb as Fe,hc as _,ib as Pe,ic as L,id as We,ja as B,jb as be,jc as A,ka as W,la as Te,mc as E,md as $e,na as O,nc as F,nd as Ue,oc as P,r as Se,ra as p,sa as d,sb as Be,sc as H,vd as J,wb as u,wc as Ae,wd as ee,xc as q,ya as v,yb as m,yc as x,za as Me}from"./chunk-DUSKF5IQ.js";import{a as S,b as Q}from"./chunk-NF7PG5F2.js";var de=class t{_openDialog=new we;openDialog$=this._openDialog.asObservable();openDialog(o){this._openDialog.next(o??{})}static \u0275fac=function(e){return new(e||t)};static \u0275prov=B({token:t,factory:t.\u0275fac,providedIn:"root"})};var Dt=`
2
2
  .p-popover {
3
3
  margin-block-start: dt('popover.gutter');
4
4
  background: dt('popover.background');
@@ -1 +1 @@
1
- import{a as J}from"./chunk-6EUXVAG7.js";import"./chunk-UXZTZFCB.js";import"./chunk-ORJAUIF4.js";import{a as G}from"./chunk-F62EEI7V.js";import"./chunk-4EBPNVWA.js";import"./chunk-LZBHDTSD.js";import{g as q,h as z}from"./chunk-VUJYUW4B.js";import"./chunk-VU5DCR4V.js";import"./chunk-WURU2W3C.js";import"./chunk-UEFG7JV5.js";import"./chunk-ZSK2V6PP.js";import"./chunk-2KEPYDRB.js";import"./chunk-EUIKMR24.js";import"./chunk-7VXCKSAE.js";import"./chunk-3GAEZ6NJ.js";import"./chunk-SLMXA7HD.js";import"./chunk-Y6TPKHHE.js";import{a as A}from"./chunk-RHSAPRE2.js";import"./chunk-JI7J6USO.js";import"./chunk-KIONH5BK.js";import"./chunk-NZTQJSEP.js";import"./chunk-W7I2IWJP.js";import"./chunk-HPCTP4FD.js";import"./chunk-KFWGALIF.js";import{a as j,b as k}from"./chunk-Z7UCI72M.js";import"./chunk-PPMQE2JW.js";import"./chunk-7OCVKGLK.js";import"./chunk-NF7H3LPQ.js";import"./chunk-YKDUJRJQ.js";import"./chunk-OKQYRKDJ.js";import"./chunk-ZX5GTIAE.js";import"./chunk-DU6XSMWH.js";import"./chunk-RCJSPD2P.js";import"./chunk-LCBHD53Y.js";import"./chunk-IKV23X6H.js";import"./chunk-C6TJ57ES.js";import"./chunk-RJDDPGUV.js";import"./chunk-VUC4E73K.js";import"./chunk-OTSIIVCA.js";import"./chunk-DUAKLYOO.js";import"./chunk-QSBTT5BF.js";import"./chunk-IX2NXO5F.js";import"./chunk-ZRB4EZI3.js";import"./chunk-KXQJYBG5.js";import"./chunk-3MLD6BQG.js";import"./chunk-LUUIBDJG.js";import"./chunk-R7VXUOCU.js";import"./chunk-NYN3E7NN.js";import{E as R,h as V,o as W}from"./chunk-R36OIJC7.js";import"./chunk-DKC2333V.js";import"./chunk-FX37N6ZC.js";import"./chunk-AGPZGAMV.js";import"./chunk-K74WZXBF.js";import"./chunk-PPTZHIIZ.js";import"./chunk-NR5UTV5U.js";import{n as B,q as H}from"./chunk-ETYXTCKV.js";import{$a as p,Bb as M,Cb as N,Db as s,Eb as i,Fb as n,Fc as h,Gc as F,Hc as T,Lc as E,Pb as v,Sb as w,Ua as l,Ub as S,db as C,hc as a,ib as D,ic as c,jb as I,mc as _,nc as b,oc as y,qd as P,ra as g,sa as f,sd as L,vd as O,zb as x}from"./chunk-DUSKF5IQ.js";import"./chunk-NF7PG5F2.js";function U(r,u){if(r&1){let e=v();i(0,"div")(1,"div",9)(2,"h6"),a(3,"Outlet"),n(),i(4,"outlet-selector",10),y("ngModelChange",function(t){g(e);let m=S();return b(m.pageData.Filter.ListIDs,t)||(m.pageData.Filter.ListIDs=t),f(t)}),n()()()}if(r&2){let e=S();l(4),s("accessType",2),_("ngModel",e.pageData.Filter.ListIDs),s("multiple",!0)}}function X(r,u){if(r&1&&(i(0,"tr")(1,"td"),a(2),n(),i(3,"td"),a(4),h(5,"number"),n(),i(6,"td"),a(7),h(8,"date"),n()()),r&2){let e=u.$implicit;l(2),c(e==null?null:e.EntityName),l(2),c(F(5,3,e==null?null:e.Number)),l(3),c(T(8,5,e==null?null:e.Modified,"dd MMM yyyy HH:mm"))}}var K=class r extends G{constructor(e,o,t){super(e,o,"Setup/Data/TransactionInvoiceNumber",null,t);this.httpService=o}httpService;preGetList(){let e=this.pageData.Filter?.ListIDs?this.pageData.Filter?.ListIDs:[];this.pageData.Filter={ListIDs:e}}static \u0275fac=function(o){return new(o||r)(p(A),p(H),p(B))};static \u0275cmp=C({type:r,selectors:[["app-invoice-numbering"]],features:[D],decls:19,vars:4,consts:[["pageFilterTemplate",""],[3,"onSubmit","filterChange","pageData","isFilterOnDropdown","hideSearchBox","filter"],[1,"container-fluid","mt-5"],[1,"table-responsive"],["id","tableGrid",1,"table"],[1,"thead-light","sticky-top-thead"],[1,"header"],["matTooltip","Next invoice number index to be generated",2,"width","200px"],[2,"width","200px"],[1,"dialog-filter"],["placeholder","Choose Outlet",3,"ngModelChange","accessType","ngModel","multiple"]],template:function(o,t){if(o&1){let m=v();i(0,"mainpanel-cmp",1),w("onSubmit",function(){return t.searchFromPageOne()}),y("filterChange",function(d){return g(m),b(t.pageData.Filter,d)||(t.pageData.Filter=d),f(d)}),i(1,"filters"),I(2,U,5,3,"ng-template",null,0,E),n(),i(4,"content")(5,"div",2)(6,"div",3)(7,"table",4)(8,"thead",5)(9,"tr",6)(10,"th"),a(11,"Outlet"),n(),i(12,"th",7),a(13," Next Number "),n(),i(14,"th",8),a(15,"Modified"),n()()(),i(16,"tbody"),M(17,X,9,8,"tr",null,x),n()()()()()()}o&2&&(s("pageData",t.menuData)("isFilterOnDropdown",!1)("hideSearchBox",!0),_("filter",t.pageData.Filter),l(17),N(t.data==null?null:t.data.Data))},dependencies:[O,z,q,J,R,V,W,k,j,L,P],encapsulation:2})};export{K as InvoiceNumberingComponent};
1
+ import{a as J}from"./chunk-T5POZFJR.js";import"./chunk-UXZTZFCB.js";import"./chunk-ORJAUIF4.js";import{a as G}from"./chunk-NVSZUDQ3.js";import"./chunk-JG644ODH.js";import"./chunk-LZBHDTSD.js";import{g as q,h as z}from"./chunk-24YLKMEJ.js";import"./chunk-VU5DCR4V.js";import"./chunk-WURU2W3C.js";import"./chunk-UEFG7JV5.js";import"./chunk-ZSK2V6PP.js";import"./chunk-2KEPYDRB.js";import"./chunk-EUIKMR24.js";import"./chunk-7VXCKSAE.js";import"./chunk-3GAEZ6NJ.js";import"./chunk-SLMXA7HD.js";import"./chunk-US4LHROB.js";import{a as A}from"./chunk-WYDVIMXE.js";import"./chunk-JI7J6USO.js";import"./chunk-KIONH5BK.js";import"./chunk-I5JH4FHZ.js";import"./chunk-W7I2IWJP.js";import"./chunk-HPCTP4FD.js";import"./chunk-KFWGALIF.js";import{a as j,b as k}from"./chunk-Z7UCI72M.js";import"./chunk-PPMQE2JW.js";import"./chunk-7OCVKGLK.js";import"./chunk-NF7H3LPQ.js";import"./chunk-3FFHADFC.js";import"./chunk-OKQYRKDJ.js";import"./chunk-IIARVTAV.js";import"./chunk-DU6XSMWH.js";import"./chunk-WF4CWM6A.js";import"./chunk-LCBHD53Y.js";import"./chunk-IKV23X6H.js";import"./chunk-C6TJ57ES.js";import"./chunk-RJDDPGUV.js";import"./chunk-VUC4E73K.js";import"./chunk-OTSIIVCA.js";import"./chunk-DUAKLYOO.js";import"./chunk-QSBTT5BF.js";import"./chunk-IX2NXO5F.js";import"./chunk-ZRB4EZI3.js";import"./chunk-KXQJYBG5.js";import"./chunk-3MLD6BQG.js";import"./chunk-LUUIBDJG.js";import"./chunk-R7VXUOCU.js";import"./chunk-NYN3E7NN.js";import{E as R,h as V,o as W}from"./chunk-R36OIJC7.js";import"./chunk-RIYY3QQM.js";import"./chunk-XGLKE2VY.js";import"./chunk-AGPZGAMV.js";import"./chunk-K74WZXBF.js";import"./chunk-PPTZHIIZ.js";import"./chunk-G2B2G6M2.js";import{n as B,q as H}from"./chunk-ETYXTCKV.js";import{$a as p,Bb as M,Cb as N,Db as s,Eb as i,Fb as n,Fc as h,Gc as F,Hc as T,Lc as E,Pb as v,Sb as w,Ua as l,Ub as S,db as C,hc as a,ib as D,ic as c,jb as I,mc as _,nc as b,oc as y,qd as P,ra as g,sa as f,sd as L,vd as O,zb as x}from"./chunk-DUSKF5IQ.js";import"./chunk-NF7PG5F2.js";function U(r,u){if(r&1){let e=v();i(0,"div")(1,"div",9)(2,"h6"),a(3,"Outlet"),n(),i(4,"outlet-selector",10),y("ngModelChange",function(t){g(e);let m=S();return b(m.pageData.Filter.ListIDs,t)||(m.pageData.Filter.ListIDs=t),f(t)}),n()()()}if(r&2){let e=S();l(4),s("accessType",2),_("ngModel",e.pageData.Filter.ListIDs),s("multiple",!0)}}function X(r,u){if(r&1&&(i(0,"tr")(1,"td"),a(2),n(),i(3,"td"),a(4),h(5,"number"),n(),i(6,"td"),a(7),h(8,"date"),n()()),r&2){let e=u.$implicit;l(2),c(e==null?null:e.EntityName),l(2),c(F(5,3,e==null?null:e.Number)),l(3),c(T(8,5,e==null?null:e.Modified,"dd MMM yyyy HH:mm"))}}var K=class r extends G{constructor(e,o,t){super(e,o,"Setup/Data/TransactionInvoiceNumber",null,t);this.httpService=o}httpService;preGetList(){let e=this.pageData.Filter?.ListIDs?this.pageData.Filter?.ListIDs:[];this.pageData.Filter={ListIDs:e}}static \u0275fac=function(o){return new(o||r)(p(A),p(H),p(B))};static \u0275cmp=C({type:r,selectors:[["app-invoice-numbering"]],features:[D],decls:19,vars:4,consts:[["pageFilterTemplate",""],[3,"onSubmit","filterChange","pageData","isFilterOnDropdown","hideSearchBox","filter"],[1,"container-fluid","mt-5"],[1,"table-responsive"],["id","tableGrid",1,"table"],[1,"thead-light","sticky-top-thead"],[1,"header"],["matTooltip","Next invoice number index to be generated",2,"width","200px"],[2,"width","200px"],[1,"dialog-filter"],["placeholder","Choose Outlet",3,"ngModelChange","accessType","ngModel","multiple"]],template:function(o,t){if(o&1){let m=v();i(0,"mainpanel-cmp",1),w("onSubmit",function(){return t.searchFromPageOne()}),y("filterChange",function(d){return g(m),b(t.pageData.Filter,d)||(t.pageData.Filter=d),f(d)}),i(1,"filters"),I(2,U,5,3,"ng-template",null,0,E),n(),i(4,"content")(5,"div",2)(6,"div",3)(7,"table",4)(8,"thead",5)(9,"tr",6)(10,"th"),a(11,"Outlet"),n(),i(12,"th",7),a(13," Next Number "),n(),i(14,"th",8),a(15,"Modified"),n()()(),i(16,"tbody"),M(17,X,9,8,"tr",null,x),n()()()()()()}o&2&&(s("pageData",t.menuData)("isFilterOnDropdown",!1)("hideSearchBox",!0),_("filter",t.pageData.Filter),l(17),N(t.data==null?null:t.data.Data))},dependencies:[O,z,q,J,R,V,W,k,j,L,P],encapsulation:2})};export{K as InvoiceNumberingComponent};
@@ -1 +1 @@
1
- import{a as A}from"./chunk-4EBPNVWA.js";import{a as M}from"./chunk-KTMZNXL5.js";import{a as x}from"./chunk-VUJYUW4B.js";import{a as w}from"./chunk-3GAEZ6NJ.js";import{a as F}from"./chunk-VUC4E73K.js";import{a as h}from"./chunk-KXQJYBG5.js";import{a as g}from"./chunk-PPTZHIIZ.js";import{Ba as p,da as C,na as y,r as P,x as I}from"./chunk-DUSKF5IQ.js";import{a as D,b as v}from"./chunk-NF7PG5F2.js";var b=class{enabledDragItem=p(!1);constructor(){}drop(o,t){w(t.Data,o.previousIndex,o.currentIndex)}toggleEnabledDragItem(){this.enabledDragItem.set(!this.enabledDragItem())}onSaveDragAndDrop(o,t){this.enabledDragItem.set(!this.enabledDragItem()),this.enabledDragItem()||t.postListID(o,t.data().Data)}onPutSaveDragAndDrop(o,t){this.enabledDragItem.set(!this.enabledDragItem()),this.enabledDragItem()||t.putListID(o,t.data().Data)}};var m=class{constructor(o){this.httpService=o}httpService;exportCSV(o,t,e,i){e.pageData().Filter.Export=!0,e.pageData().Filter.FormatType=0,i=i||"export.csv",this.httpService.post(`/api/${t}`,e.pageData().Filter).subscribe(r=>{o.convertToCSV(r,i),e.pageData().Filter.Export=!1})}convertToCSV(o,t=!1,e){let i=this.ExportDataFromUI2(t);o.convertToCSV(i,e)}ExportDataFromUI2(o=!1){let t=document.getElementById("tableGrid"),e=[];return g.IsNotEmpty(t)&&t.querySelectorAll("tr").forEach(r=>{let a=new Object,s=0;r.querySelectorAll("th, td").forEach(n=>{s++;let L=parseInt(n.getAttribute("colspan"));for(let d=1;d<L;d++)a["column"+s]="",s++;let l=n.innerText,u=l.toString().split("");if(o&&u[0]==="0"&&u.length>1){let d="'"+l.trim();a["column"+s]=d}else a["column"+s]=l.trim()}),e.push(a)}),e}};var S=class{listTotal=p(0);pageSize=p(0);show=p(!1);constructor(){}changePaginationData(o){let t=o.pageData().Filter.RowCount;this.pageSize.set(t);let e=o.data(),i=e?.ListTotal??e?.Data?.total?.value??0;this.listTotal.set(i),this.show.set(this.pageSize()<=this.listTotal())}changePage(o,t,e){t().Filter.PageNumber=o.pageIndex+1,e.getListData()}};var T=class extends M{constructor(t,e,i,r,a,s,c,n="post",L="post"){super(t);this.httpService=e;this.dataAPI=i;this.pageAPI=r;this.toastrService=a;this.route=s;this.initOpenDialog=c;this.dataMethod=n;this.loaderMethod=L;this.exportHandler=new m(e),r?(s&&this.loaderPayload.set(D({ListIDs:this.reportFilterService?.initOutletFilter()},s.snapshot.queryParams)),this.preInitLoader(),I([this.menuData$,this.callApi("/api/"+this.pageAPI,this.loaderPayload(),this.loaderMethod)]).pipe(P(([l,u])=>u)).pipe(F()).subscribe(l=>{this.pageData.set(l),this.pageData().Filter||(this.pageData().Filter={},this.pageData().Filter.RowCount=20),this.pageData().Filter.PageNumber=1,this.pageData().Filter.ID=this.loaderPayload()?.ID,this.preInitList(),c?this.openDialogFilter.openDialog(this.getOpenDialogOptions()):this.getListData()})):(this.pageData().Filter.RowCount=20,this.pageData().Filter.PageNumber=1,this.preInitList(),I({menuData:this.menuData$,listData:this.getListData$()}).pipe(F()).subscribe())}httpService;dataAPI;pageAPI;toastrService;route;initOpenDialog;dataMethod;loaderMethod;openDialogFilter=y(x);reportFilterService=y(A);pageData=p({Filter:{},Options:{},Roles:{},Config:{}});data=p(null);pagination=new S;dragDrop=new b;exportHandler;comparation=p(0);loaderPayload=p({});reloadRowCount=p(!1);mapToKeyValueArray(t){return t?Object.keys(t).map(e=>({key:e,value:t[e]})):[]}callApi(t,e,i="post"){let r=t;if(i==="get"){let a=this.mapToKeyValueArray(e);return this.httpService.get(r,a)}return this.httpService[i](r,e)}preInitLoader(){}preInitList(){}getListData(t){this.preGetList(),this.dataAPI&&this.callApi("/api/"+this.dataAPI,this.pageData().Filter,this.dataMethod).subscribe(e=>{e.PageSubTitle&&this.menuData.update(i=>v(D({},i),{SH:e.PageSubTitle})),this.data.set(e),this.postInit(e),this.reloadRowCount.set(!0),this.pagination.changePaginationData(this),t&&this.pageData.update(i=>v(D({},i),{HideStoreApiCount:!1}))})}getListData$(t){return this.preGetList(),this.callApi("/api/"+this.dataAPI,this.pageData().Filter,this.dataMethod).pipe(C(e=>{this.data.set(e),this.postInit(e),this.pagination.changePaginationData(this),t&&(this.pageData().HideStoreApiCount=!1)}))}searchFromPageOne(){this.preSearchFromPageOne(),this.pageData().Filter.PageNumber=1,this.getListData("filterMode")}getOpenDialogOptions(){}postInit(t){t.PageTitle!=null&&(this.menuData().H=t.PageTitle)}preGetList(){this.pageData().Filter.From==null&&(this.pageData().Filter.From=g.MinDate),this.pageData().Filter.To==null&&(this.pageData().Filter.To=g.MinDate)}preSearchFromPageOne(){}onPaginationChange(t){this.pagination.changePage(t,this.pageData,this)}onSelectAllData(t){this.data().Data=this.data().Data.map(e=>(e.selected=t,e))}getSelectedData(){let t=[];return this.data()&&(t=this.data().Data.filter(e=>e.selected)),t}httpPostListID(t,e,i){if(e||(e="Are you sure you want to selected record/s?"),confirm(e)==!1)return;let r=this.getSelectedData();r.length>0&&this.postListID(t,r,i)}httpPutListID(t,e,i){if(e||(e="Are you sure you want to selected record/s?"),confirm(e)==!1)return;let r=this.getSelectedData();r.length>0&&this.putListID(t,r,i)}httpDeleteListID(t,e,i){if(e||(e="Are you sure you want to delete selected record/s?"),confirm(e)==!1)return;let r=this.getSelectedData();r.length>0&&this.DeleteListID(t,r,i)}onSaveDragAndDrop(t){this.dragDrop.onSaveDragAndDrop(t,this)}onPutSaveDragAndDrop(t){this.dragDrop.onPutSaveDragAndDrop(t,this)}postListID(t,e,i){let r=e.map(a=>i?a[i]:a.ID);this.httpService.post(`/api/${t}`,r,1e6,!0).subscribe(a=>{this.toastrService.success(a.Message?a.Message:a,h.Success),this.getListData()},a=>{let s=a.status+" "+a.statusText;this.toastrService.error(a.error.Message!=""?a.error.Message:"An unknown error has occured!",s,{enableHtml:!0})})}putListID(t,e,i){let r=e.map(a=>i?a[i]:a.ID);this.httpService.put(`/api/${t}`,r).subscribe(a=>{this.toastrService.success(a.Message?a.Message:a,h.Success),this.afterPutListSuccess(),this.getListData()})}afterPutListSuccess(){}DeleteListID(t,e,i){let r=e.map(a=>i?a[i]:a.ID);this.httpService.delete(`/api/${t}`,{body:r}).subscribe(a=>{this.toastrService.success(a.Message?a.Message:a,h.Success),this.getListData()})}postData(t,e){this.httpService.post("/API/"+t,e).subscribe(i=>{this.getListData(),this.toastrService.success(i.Message?i.Message:i,h.Success)})}compare(t,e,i){return(t<e?-1:1)*(i?1:-1)}exportCSV(t,e,i){this.exportHandler.exportCSV(t,e,this,i)}s2ab(t){for(var e=new ArrayBuffer(t.length),i=new Uint8Array(e),r=0;r!=t.length;++r)i[r]=t.charCodeAt(r)&255;return e}exportXlsx(t,e){this.pageData().Filter.FormatType=1,this.pageData().Filter.Export=!0,this.httpService.post(`/api/${t}`,this.pageData().Filter).subscribe(i=>{e=decodeURI(e);let r=window.URL.createObjectURL(new Blob([this.s2ab(atob(i))],{type:"application/vnd.openxmlformats-officedocument.spreadsheetml.sheet;base64,"})),a=document.createElement("a");a.href=r,a.setAttribute("download",e),document.body.appendChild(a),a.click(),window.URL.revokeObjectURL(r),a.remove()})}convertToCSV(t,e=!1,i){let r=this.exportHandler.ExportDataFromUI2(e);t.convertToCSV(r,i)}OnCompare(t){let e=t?this.data()[t]:this.data();if(e.length<1)return;let i=Object.assign({},this.pageData().Filter);i.From=new Date(new Date(this.pageData().Filter.From).getFullYear(),new Date(this.pageData().Filter.From).getMonth()-1,1),i.To=new Date(new Date(this.pageData().Filter.To).getFullYear(),new Date(this.pageData().Filter.To).getMonth(),0).toDateString(),this.httpService.post("/API/"+this.dataAPI,i).subscribe(r=>{let a=t?r[t]:r;this.comparation.set(0),e.forEach(s=>{s.PrevIndex="-",s.CurrentIndex="-",s.Increase="-";let c=a.filter(n=>n.EntityID==s.EntityID);if(s.CurrentIndex=s.Rank,c.length>0){let n=c[0];s.PrevIndex=n.Rank,n.SalesNet?s.Increase=(s.SalesNet-n.SalesNet)/n.SalesNet*100:n.Sales&&(s.Increase=(s.Sales-n.Sales)/n.Sales*100),s.IsPositive=s.Increase>0,s.IsNegative=s.Increase<0,this.comparation.set(this.comparation()+s.Increase)}})})}};export{T as a};
1
+ import{a as A}from"./chunk-JG644ODH.js";import{a as M}from"./chunk-KTMZNXL5.js";import{a as x}from"./chunk-24YLKMEJ.js";import{a as w}from"./chunk-3GAEZ6NJ.js";import{a as F}from"./chunk-VUC4E73K.js";import{a as h}from"./chunk-KXQJYBG5.js";import{a as g}from"./chunk-PPTZHIIZ.js";import{Ba as p,da as C,na as y,r as P,x as I}from"./chunk-DUSKF5IQ.js";import{a as D,b as v}from"./chunk-NF7PG5F2.js";var b=class{enabledDragItem=p(!1);constructor(){}drop(o,t){w(t.Data,o.previousIndex,o.currentIndex)}toggleEnabledDragItem(){this.enabledDragItem.set(!this.enabledDragItem())}onSaveDragAndDrop(o,t){this.enabledDragItem.set(!this.enabledDragItem()),this.enabledDragItem()||t.postListID(o,t.data().Data)}onPutSaveDragAndDrop(o,t){this.enabledDragItem.set(!this.enabledDragItem()),this.enabledDragItem()||t.putListID(o,t.data().Data)}};var m=class{constructor(o){this.httpService=o}httpService;exportCSV(o,t,e,i){e.pageData().Filter.Export=!0,e.pageData().Filter.FormatType=0,i=i||"export.csv",this.httpService.post(`/api/${t}`,e.pageData().Filter).subscribe(r=>{o.convertToCSV(r,i),e.pageData().Filter.Export=!1})}convertToCSV(o,t=!1,e){let i=this.ExportDataFromUI2(t);o.convertToCSV(i,e)}ExportDataFromUI2(o=!1){let t=document.getElementById("tableGrid"),e=[];return g.IsNotEmpty(t)&&t.querySelectorAll("tr").forEach(r=>{let a=new Object,s=0;r.querySelectorAll("th, td").forEach(n=>{s++;let L=parseInt(n.getAttribute("colspan"));for(let d=1;d<L;d++)a["column"+s]="",s++;let l=n.innerText,u=l.toString().split("");if(o&&u[0]==="0"&&u.length>1){let d="'"+l.trim();a["column"+s]=d}else a["column"+s]=l.trim()}),e.push(a)}),e}};var S=class{listTotal=p(0);pageSize=p(0);show=p(!1);constructor(){}changePaginationData(o){let t=o.pageData().Filter.RowCount;this.pageSize.set(t);let e=o.data(),i=e?.ListTotal??e?.Data?.total?.value??0;this.listTotal.set(i),this.show.set(this.pageSize()<=this.listTotal())}changePage(o,t,e){t().Filter.PageNumber=o.pageIndex+1,e.getListData()}};var T=class extends M{constructor(t,e,i,r,a,s,c,n="post",L="post"){super(t);this.httpService=e;this.dataAPI=i;this.pageAPI=r;this.toastrService=a;this.route=s;this.initOpenDialog=c;this.dataMethod=n;this.loaderMethod=L;this.exportHandler=new m(e),r?(s&&this.loaderPayload.set(D({ListIDs:this.reportFilterService?.initOutletFilter()},s.snapshot.queryParams)),this.preInitLoader(),I([this.menuData$,this.callApi("/api/"+this.pageAPI,this.loaderPayload(),this.loaderMethod)]).pipe(P(([l,u])=>u)).pipe(F()).subscribe(l=>{this.pageData.set(l),this.pageData().Filter||(this.pageData().Filter={},this.pageData().Filter.RowCount=20),this.pageData().Filter.PageNumber=1,this.pageData().Filter.ID=this.loaderPayload()?.ID,this.preInitList(),c?this.openDialogFilter.openDialog(this.getOpenDialogOptions()):this.getListData()})):(this.pageData().Filter.RowCount=20,this.pageData().Filter.PageNumber=1,this.preInitList(),I({menuData:this.menuData$,listData:this.getListData$()}).pipe(F()).subscribe())}httpService;dataAPI;pageAPI;toastrService;route;initOpenDialog;dataMethod;loaderMethod;openDialogFilter=y(x);reportFilterService=y(A);pageData=p({Filter:{},Options:{},Roles:{},Config:{}});data=p(null);pagination=new S;dragDrop=new b;exportHandler;comparation=p(0);loaderPayload=p({});reloadRowCount=p(!1);mapToKeyValueArray(t){return t?Object.keys(t).map(e=>({key:e,value:t[e]})):[]}callApi(t,e,i="post"){let r=t;if(i==="get"){let a=this.mapToKeyValueArray(e);return this.httpService.get(r,a)}return this.httpService[i](r,e)}preInitLoader(){}preInitList(){}getListData(t){this.preGetList(),this.dataAPI&&this.callApi("/api/"+this.dataAPI,this.pageData().Filter,this.dataMethod).subscribe(e=>{e.PageSubTitle&&this.menuData.update(i=>v(D({},i),{SH:e.PageSubTitle})),this.data.set(e),this.postInit(e),this.reloadRowCount.set(!0),this.pagination.changePaginationData(this),t&&this.pageData.update(i=>v(D({},i),{HideStoreApiCount:!1}))})}getListData$(t){return this.preGetList(),this.callApi("/api/"+this.dataAPI,this.pageData().Filter,this.dataMethod).pipe(C(e=>{this.data.set(e),this.postInit(e),this.pagination.changePaginationData(this),t&&(this.pageData().HideStoreApiCount=!1)}))}searchFromPageOne(){this.preSearchFromPageOne(),this.pageData().Filter.PageNumber=1,this.getListData("filterMode")}getOpenDialogOptions(){}postInit(t){t.PageTitle!=null&&(this.menuData().H=t.PageTitle)}preGetList(){this.pageData().Filter.From==null&&(this.pageData().Filter.From=g.MinDate),this.pageData().Filter.To==null&&(this.pageData().Filter.To=g.MinDate)}preSearchFromPageOne(){}onPaginationChange(t){this.pagination.changePage(t,this.pageData,this)}onSelectAllData(t){this.data().Data=this.data().Data.map(e=>(e.selected=t,e))}getSelectedData(){let t=[];return this.data()&&(t=this.data().Data.filter(e=>e.selected)),t}httpPostListID(t,e,i){if(e||(e="Are you sure you want to selected record/s?"),confirm(e)==!1)return;let r=this.getSelectedData();r.length>0&&this.postListID(t,r,i)}httpPutListID(t,e,i){if(e||(e="Are you sure you want to selected record/s?"),confirm(e)==!1)return;let r=this.getSelectedData();r.length>0&&this.putListID(t,r,i)}httpDeleteListID(t,e,i){if(e||(e="Are you sure you want to delete selected record/s?"),confirm(e)==!1)return;let r=this.getSelectedData();r.length>0&&this.DeleteListID(t,r,i)}onSaveDragAndDrop(t){this.dragDrop.onSaveDragAndDrop(t,this)}onPutSaveDragAndDrop(t){this.dragDrop.onPutSaveDragAndDrop(t,this)}postListID(t,e,i){let r=e.map(a=>i?a[i]:a.ID);this.httpService.post(`/api/${t}`,r,1e6,!0).subscribe(a=>{this.toastrService.success(a.Message?a.Message:a,h.Success),this.getListData()},a=>{let s=a.status+" "+a.statusText;this.toastrService.error(a.error.Message!=""?a.error.Message:"An unknown error has occured!",s,{enableHtml:!0})})}putListID(t,e,i){let r=e.map(a=>i?a[i]:a.ID);this.httpService.put(`/api/${t}`,r).subscribe(a=>{this.toastrService.success(a.Message?a.Message:a,h.Success),this.afterPutListSuccess(),this.getListData()})}afterPutListSuccess(){}DeleteListID(t,e,i){let r=e.map(a=>i?a[i]:a.ID);this.httpService.delete(`/api/${t}`,{body:r}).subscribe(a=>{this.toastrService.success(a.Message?a.Message:a,h.Success),this.getListData()})}postData(t,e){this.httpService.post("/API/"+t,e).subscribe(i=>{this.getListData(),this.toastrService.success(i.Message?i.Message:i,h.Success)})}compare(t,e,i){return(t<e?-1:1)*(i?1:-1)}exportCSV(t,e,i){this.exportHandler.exportCSV(t,e,this,i)}s2ab(t){for(var e=new ArrayBuffer(t.length),i=new Uint8Array(e),r=0;r!=t.length;++r)i[r]=t.charCodeAt(r)&255;return e}exportXlsx(t,e){this.pageData().Filter.FormatType=1,this.pageData().Filter.Export=!0,this.httpService.post(`/api/${t}`,this.pageData().Filter).subscribe(i=>{e=decodeURI(e);let r=window.URL.createObjectURL(new Blob([this.s2ab(atob(i))],{type:"application/vnd.openxmlformats-officedocument.spreadsheetml.sheet;base64,"})),a=document.createElement("a");a.href=r,a.setAttribute("download",e),document.body.appendChild(a),a.click(),window.URL.revokeObjectURL(r),a.remove()})}convertToCSV(t,e=!1,i){let r=this.exportHandler.ExportDataFromUI2(e);t.convertToCSV(r,i)}OnCompare(t){let e=t?this.data()[t]:this.data();if(e.length<1)return;let i=Object.assign({},this.pageData().Filter);i.From=new Date(new Date(this.pageData().Filter.From).getFullYear(),new Date(this.pageData().Filter.From).getMonth()-1,1),i.To=new Date(new Date(this.pageData().Filter.To).getFullYear(),new Date(this.pageData().Filter.To).getMonth(),0).toDateString(),this.httpService.post("/API/"+this.dataAPI,i).subscribe(r=>{let a=t?r[t]:r;this.comparation.set(0),e.forEach(s=>{s.PrevIndex="-",s.CurrentIndex="-",s.Increase="-";let c=a.filter(n=>n.EntityID==s.EntityID);if(s.CurrentIndex=s.Rank,c.length>0){let n=c[0];s.PrevIndex=n.Rank,n.SalesNet?s.Increase=(s.SalesNet-n.SalesNet)/n.SalesNet*100:n.Sales&&(s.Increase=(s.Sales-n.Sales)/n.Sales*100),s.IsPositive=s.Increase>0,s.IsNegative=s.Increase<0,this.comparation.set(this.comparation()+s.Increase)}})})}};export{T as a};
@@ -0,0 +1 @@
1
+ import{a as L}from"./chunk-VB77KJKE.js";import{a as O}from"./chunk-TUL4SCIV.js";import{a as W}from"./chunk-KGAHREO6.js";import{a as h}from"./chunk-UWUSG6X7.js";import{a as V}from"./chunk-L2AMDQ4D.js";import"./chunk-FBXWSJGZ.js";import"./chunk-2PUGC5XR.js";import{a as M}from"./chunk-DUBSPAA2.js";import"./chunk-TDI2ZUL6.js";import"./chunk-CKHJNQTW.js";import"./chunk-CNBTTBK3.js";import"./chunk-CCLE2IVS.js";import"./chunk-BF42EMHQ.js";import"./chunk-EUIKMR24.js";import"./chunk-7VXCKSAE.js";import"./chunk-KFWGALIF.js";import"./chunk-Z7UCI72M.js";import"./chunk-PPMQE2JW.js";import"./chunk-DU6XSMWH.js";import"./chunk-RJDDPGUV.js";import"./chunk-OTSIIVCA.js";import"./chunk-QSBTT5BF.js";import"./chunk-IX2NXO5F.js";import"./chunk-ZRB4EZI3.js";import"./chunk-3MLD6BQG.js";import"./chunk-LUUIBDJG.js";import"./chunk-R7VXUOCU.js";import"./chunk-NYN3E7NN.js";import{E as T,h as P,o as w}from"./chunk-R36OIJC7.js";import"./chunk-AGPZGAMV.js";import"./chunk-PPTZHIIZ.js";import"./chunk-ETYXTCKV.js";import{Db as o,Eb as r,Fb as a,Nd as S,Oc as _,Pb as I,Ua as t,Ub as u,db as v,hc as D,mc as l,na as b,nc as m,oc as s,ra as g,sa as c,wb as f,yb as C}from"./chunk-DUSKF5IQ.js";import"./chunk-NF7PG5F2.js";function B(p,y){if(p&1){let d=I();r(0,"div",2)(1,"POS-input-field",3),s("ngModelChange",function(n){g(d);let e=u();return m(e.formData().Invoice.FooterLabel.CopyLabelText,n)||(e.formData().Invoice.FooterLabel.CopyLabelText=n),c(n)}),a()()}if(p&2){let d=u();t(),o("label","Receipt Copy Label Text")("type","text"),l("ngModel",d.formData().Invoice.FooterLabel.CopyLabelText),o("isHorizontalLayout",!0)("description","Customize label for receipt copy on invoice mini.")}}function A(p,y){if(p&1){let d=I();r(0,"div",2)(1,"POS-input-field",21),s("ngModelChange",function(n){g(d);let e=u();return m(e.formData().Invoice.Header.SalesReturnLabelText,n)||(e.formData().Invoice.Header.SalesReturnLabelText=n),c(n)}),a()()}if(p&2){let d=u();t(),o("label","Sales Return Label Text")("tooltip","Label for return invoice")("type","text"),l("ngModel",d.formData().Invoice.Header.SalesReturnLabelText),o("isHorizontalLayout",!0)("description","Customize default label for sales return")}}function R(p,y){if(p&1){let d=I();r(0,"div",2)(1,"POS-input-toggle",4),s("ngModelChange",function(n){g(d);let e=u();return m(e.formData().Invoice.DocumentVisibility.OrderTimeVisible,n)||(e.formData().Invoice.DocumentVisibility.OrderTimeVisible=n),c(n)}),a()()}if(p&2){let d=u();t(),o("label","Time Visible")("description","Display Time on invoice according CustomerEntryTime or InvoiceCreatedTime in Invoice mini"),l("ngModel",d.formData().Invoice.DocumentVisibility.OrderTimeVisible),o("defaultConfig",d.configDefault().Invoice.DocumentVisibility.OrderTimeVisible)}}function F(p,y){if(p&1){let d=I();r(0,"div",2)(1,"POS-input-toggle",4),s("ngModelChange",function(n){g(d);let e=u();return m(e.formData().Invoice.ItemsTable.AlwaysShowQuantity,n)||(e.formData().Invoice.ItemsTable.AlwaysShowQuantity=n),c(n)}),a()(),r(2,"div",2)(3,"POS-input-toggle",4),s("ngModelChange",function(n){g(d);let e=u();return m(e.formData().Invoice.ItemsTable.SeparateTaxable,n)||(e.formData().Invoice.ItemsTable.SeparateTaxable=n),c(n)}),a()()}if(p&2){let d=u();t(),o("label","Always Show Quantity")("description","Display Items Quantity = 1 in Invoice mini"),l("ngModel",d.formData().Invoice.ItemsTable.AlwaysShowQuantity),o("defaultConfig",d.configDefault().Invoice.ItemsTable.AlwaysShowQuantity),t(2),o("label","Separate Taxable Item")("description","Show Different item Between Taxable and Non-Taxable only on LX300"),l("ngModel",d.formData().Invoice.ItemsTable.SeparateTaxable),o("defaultConfig",d.configDefault().Invoice.ItemsTable.SeparateTaxable)}}function Q(p,y){if(p&1){let d=I();r(0,"div",2)(1,"POS-input-toggle",4),s("ngModelChange",function(n){g(d);let e=u();return m(e.formData().Invoice.ItemsTable.UnitQuantity.Multiply,n)||(e.formData().Invoice.ItemsTable.UnitQuantity.Multiply=n),c(n)}),a()()}if(p&2){let d=u();t(),o("label","Multiply")("description","Show total quantity x unit quantity value"),l("ngModel",d.formData().Invoice.ItemsTable.UnitQuantity.Multiply),o("defaultConfig",d.configDefault().Invoice.ItemsTable.UnitQuantity.Multiply)}}function N(p,y){if(p&1){let d=I();r(0,"div",2)(1,"POS-button-group",16),s("ngModelChange",function(n){g(d);let e=u();return m(e.formData().Invoice.InvoiceQR.A4PrintingContent,n)||(e.formData().Invoice.InvoiceQR.A4PrintingContent=n),c(n)}),a()()}if(p&2){let d=u();t(),o("label","A4 Invoice QR Content")("description","Result which will appear after scan")("options",d.options().Content)("defaultConfig",d.configDefault().Invoice.InvoiceQR.A4PrintingContent),l("ngModel",d.formData().Invoice.InvoiceQR.A4PrintingContent)}}function U(p,y){if(p&1){let d=I();r(0,"div",2)(1,"POS-button-group",16),s("ngModelChange",function(n){g(d);let e=u();return m(e.formData().Invoice.InvoiceQR.MiniPrintingContent,n)||(e.formData().Invoice.InvoiceQR.MiniPrintingContent=n),c(n)}),a()(),r(2,"div",2)(3,"POS-input-field",3),s("ngModelChange",function(n){g(d);let e=u();return m(e.formData().Invoice.InvoiceQR.QRCodeSize,n)||(e.formData().Invoice.InvoiceQR.QRCodeSize=n),c(n)}),D(4,' [value]="formData().Invoice.InvoiceQR.QRCodeSize" >'),a()()}if(p&2){let d=u();t(),o("label","Invoice Mini QR Content")("description","Result which will appear after scan")("options",d.options().Content)("defaultConfig",d.configDefault().Invoice.InvoiceQR.MiniPrintingContent),l("ngModel",d.formData().Invoice.InvoiceQR.MiniPrintingContent),t(2),o("label","Invoice Mini QR Code Size")("type","number"),l("ngModel",d.formData().Invoice.InvoiceQR.QRCodeSize),o("isHorizontalLayout",!0)("description","Customize the QR code size for Invoice Mini (width and height in pixels).")}}var E=class p{activatedRoute=b(S);settings=b(V);formData=_(()=>this.settings.formData());options=_(()=>this.settings.options());configDefault=_(()=>this.settings.configDefault());qrType=M;constructor(){this.settings.initFormData(this.activatedRoute)}static \u0275fac=function(d){return new(d||p)};static \u0275cmp=v({type:p,selectors:[["POS-customer-invoice"]],decls:183,vars:321,consts:[["cardTitle","Header","id","headerCustomerInvoice"],[1,"row"],[1,"col-12"],[3,"ngModelChange","label","type","ngModel","isHorizontalLayout","description"],[3,"ngModelChange","label","description","ngModel","defaultConfig"],["cardTitle","Document Label","id","documentLabelCustomerInvoice"],[1,"col-6"],[3,"ngModelChange","label","tooltip","type","ngModel"],["cardTitle","Document Visibility","id","documentVisibilityCustomerInvoice"],["keyLabel","Value","keyValue","Key",3,"ngModelChange","label","description","options","ngModel","defaultConfig"],["cardTitle","Items Table","id","itemsTableCustomerInvoice"],["cardTitle","Unit Quantity","id","unitQuantityCustomerInvoice",3,"description"],["cardTitle","Items Footer","id","itemsFooterCustomerInvoice"],["cardTitle","Invoice Footer","id","invoiceFooterCustomerInvoice"],["cardTitle","Footer Label","id","footerLabelCustomerInvoice"],["cardTitle","Invoice QR","id","invoiceQrCustomerInvoice"],["keyLabel","Value","keyValue","Key",3,"ngModelChange","label","description","options","defaultConfig","ngModel"],["cardTitle","Signature","id","signatureCustomerInvoice"],["cardTitle","A4 Paper Size Configuration","id","a4PaperSizeConfigurationCustomerInvoice"],["cardTitle","Receipt Template","id","receiptTemplateCustomerInvoice"],["cardTitle","Advanced","id","advancedCustomerInvoice"],[3,"ngModelChange","label","tooltip","type","ngModel","isHorizontalLayout","description"]],template:function(d,i){d&1&&(r(0,"POS-card",0)(1,"div",1)(2,"div",2)(3,"POS-input-field",3),s("ngModelChange",function(e){return m(i.formData().Invoice.HeaderTitle,e)||(i.formData().Invoice.HeaderTitle=e),e}),a()(),r(4,"div",2)(5,"POS-input-toggle",4),s("ngModelChange",function(e){return m(i.formData().Invoice.Footer.CopyLabelEnabled,e)||(i.formData().Invoice.Footer.CopyLabelEnabled=e),e}),a()(),r(6,"div",2)(7,"POS-input-toggle",4),s("ngModelChange",function(e){return m(i.formData().Invoice.Header.SalesReturnLabel,e)||(i.formData().Invoice.Header.SalesReturnLabel=e),e}),a()(),f(8,B,2,5,"div",2),f(9,A,2,6,"div",2),a()(),r(10,"POS-card",5)(11,"div",1)(12,"div",6)(13,"POS-input-field",7),s("ngModelChange",function(e){return m(i.formData().Invoice.DocumentLabel.Customer,e)||(i.formData().Invoice.DocumentLabel.Customer=e),e}),a()(),r(14,"div",6)(15,"POS-input-field",7),s("ngModelChange",function(e){return m(i.formData().Invoice.DocumentLabel.ShippingAddress,e)||(i.formData().Invoice.DocumentLabel.ShippingAddress=e),e}),a()(),r(16,"div",6)(17,"POS-input-field",7),s("ngModelChange",function(e){return m(i.formData().Invoice.DocumentLabel.SalesPerson,e)||(i.formData().Invoice.DocumentLabel.SalesPerson=e),e}),a()(),r(18,"div",6)(19,"POS-input-field",7),s("ngModelChange",function(e){return m(i.formData().Invoice.DocumentLabel.BillLabel,e)||(i.formData().Invoice.DocumentLabel.BillLabel=e),e}),a()()()(),r(20,"POS-card",8)(21,"div",1)(22,"div",2)(23,"POS-input-toggle",4),s("ngModelChange",function(e){return m(i.formData().Invoice.DocumentVisibility.NumberVisible,e)||(i.formData().Invoice.DocumentVisibility.NumberVisible=e),e}),a()(),r(24,"div",2)(25,"POS-input-toggle",4),s("ngModelChange",function(e){return m(i.formData().Invoice.DocumentVisibility.CustomerVisible,e)||(i.formData().Invoice.DocumentVisibility.CustomerVisible=e),e}),a()(),r(26,"div",2)(27,"POS-input-toggle",4),s("ngModelChange",function(e){return m(i.formData().Invoice.DocumentVisibility.CustomerAddressVisible,e)||(i.formData().Invoice.DocumentVisibility.CustomerAddressVisible=e),e}),a()(),r(28,"div",2)(29,"POS-input-toggle",4),s("ngModelChange",function(e){return m(i.formData().Invoice.DocumentVisibility.CompanyVisible,e)||(i.formData().Invoice.DocumentVisibility.CompanyVisible=e),e}),a()(),r(30,"div",2)(31,"POS-input-toggle",4),s("ngModelChange",function(e){return m(i.formData().Invoice.DocumentVisibility.SalesPersonVisible,e)||(i.formData().Invoice.DocumentVisibility.SalesPersonVisible=e),e}),a()(),r(32,"div",2)(33,"POS-input-toggle",4),s("ngModelChange",function(e){return m(i.formData().Invoice.DocumentVisibility.CustomerEmailVisible,e)||(i.formData().Invoice.DocumentVisibility.CustomerEmailVisible=e),e}),a()(),r(34,"div",2)(35,"POS-input-toggle",4),s("ngModelChange",function(e){return m(i.formData().Invoice.DocumentVisibility.CustomerCodeVisible,e)||(i.formData().Invoice.DocumentVisibility.CustomerCodeVisible=e),e}),a()(),r(36,"div",2)(37,"POS-input-toggle",4),s("ngModelChange",function(e){return m(i.formData().Invoice.DocumentVisibility.CustomerEntryTimeVisible,e)||(i.formData().Invoice.DocumentVisibility.CustomerEntryTimeVisible=e),e}),a()(),r(38,"div",2)(39,"POS-input-toggle",4),s("ngModelChange",function(e){return m(i.formData().Invoice.DocumentVisibility.InvoiceCreatedTimeVisible,e)||(i.formData().Invoice.DocumentVisibility.InvoiceCreatedTimeVisible=e),e}),a()(),f(40,R,2,4,"div",2),r(41,"div",2)(42,"POS-input-toggle",4),s("ngModelChange",function(e){return m(i.formData().Invoice.DocumentVisibility.PrintPackingslipAftersell,e)||(i.formData().Invoice.DocumentVisibility.PrintPackingslipAftersell=e),e}),a()(),r(43,"div",2)(44,"POS-input-toggle",4),s("ngModelChange",function(e){return m(i.formData().Invoice.DocumentVisibility.InvoicePaymentTermsVisible,e)||(i.formData().Invoice.DocumentVisibility.InvoicePaymentTermsVisible=e),e}),a()(),r(45,"div",2)(46,"POS-input-toggle",4),s("ngModelChange",function(e){return m(i.formData().Invoice.DocumentVisibility.PaymentNoteVisible,e)||(i.formData().Invoice.DocumentVisibility.PaymentNoteVisible=e),e}),a()(),r(47,"div",2)(48,"POS-input-toggle",4),s("ngModelChange",function(e){return m(i.formData().Invoice.DocumentVisibility.RegisterCode,e)||(i.formData().Invoice.DocumentVisibility.RegisterCode=e),e}),a()(),r(49,"div",2)(50,"POS-input-toggle",4),s("ngModelChange",function(e){return m(i.formData().Invoice.DocumentVisibility.IdentificationVisible,e)||(i.formData().Invoice.DocumentVisibility.IdentificationVisible=e),e}),a()(),r(51,"div",2)(52,"POS-button-group",9),s("ngModelChange",function(e){return m(i.formData().Invoice.DocumentVisibility.PhoneCustomerVisibility,e)||(i.formData().Invoice.DocumentVisibility.PhoneCustomerVisibility=e),e}),a()(),r(53,"div",2)(54,"POS-button-group",9),s("ngModelChange",function(e){return m(i.formData().Invoice.DocumentVisibility.PromotionCoupon,e)||(i.formData().Invoice.DocumentVisibility.PromotionCoupon=e),e}),a()(),r(55,"div",2)(56,"POS-button-group",9),s("ngModelChange",function(e){return m(i.formData().Invoice.DocumentVisibility.PaymentCode,e)||(i.formData().Invoice.DocumentVisibility.PaymentCode=e),e}),a()()()(),r(57,"POS-card",10)(58,"div",1)(59,"div",2)(60,"POS-input-toggle",4),s("ngModelChange",function(e){return m(i.formData().Invoice.ItemsTable.CodeVisible,e)||(i.formData().Invoice.ItemsTable.CodeVisible=e),e}),a()(),r(61,"div",2)(62,"POS-input-field",3),s("ngModelChange",function(e){return m(i.formData().Invoice.ItemsTable.CodeVisibleTitle,e)||(i.formData().Invoice.ItemsTable.CodeVisibleTitle=e),e}),a()(),r(63,"div",2)(64,"POS-input-toggle",4),s("ngModelChange",function(e){return m(i.formData().Invoice.ItemsTable.UOMVisible,e)||(i.formData().Invoice.ItemsTable.UOMVisible=e),e}),a()(),r(65,"div",2)(66,"POS-input-toggle",4),s("ngModelChange",function(e){return m(i.formData().Invoice.ItemsTable.SubUOMVisible,e)||(i.formData().Invoice.ItemsTable.SubUOMVisible=e),e}),a()(),r(67,"div",2)(68,"POS-input-field",3),s("ngModelChange",function(e){return m(i.formData().Invoice.ItemsTable.UOMVisibleTitle,e)||(i.formData().Invoice.ItemsTable.UOMVisibleTitle=e),e}),a()(),r(69,"div",2)(70,"POS-input-toggle",4),s("ngModelChange",function(e){return m(i.formData().Invoice.ItemsTable.ProductCodeWithCodeVariantVisible,e)||(i.formData().Invoice.ItemsTable.ProductCodeWithCodeVariantVisible=e),e}),a()(),r(71,"div",2)(72,"POS-input-toggle",4),s("ngModelChange",function(e){return m(i.formData().Invoice.ItemsTable.ItemWithoutPriceVisible,e)||(i.formData().Invoice.ItemsTable.ItemWithoutPriceVisible=e),e}),a()(),r(73,"div",2)(74,"POS-input-toggle",4),s("ngModelChange",function(e){return m(i.formData().Invoice.ItemsTable.QuantityVisible,e)||(i.formData().Invoice.ItemsTable.QuantityVisible=e),e}),a()(),f(75,F,4,8),r(76,"div",2)(77,"POS-input-toggle",4),s("ngModelChange",function(e){return m(i.formData().Invoice.ItemsTable.SeparateRetur,e)||(i.formData().Invoice.ItemsTable.SeparateRetur=e),e}),a()(),r(78,"div",2)(79,"POS-input-toggle",4),s("ngModelChange",function(e){return m(i.formData().Invoice.ItemsTable.UnitPriceVisible,e)||(i.formData().Invoice.ItemsTable.UnitPriceVisible=e),e}),a()(),r(80,"div",2)(81,"POS-input-toggle",4),s("ngModelChange",function(e){return m(i.formData().Invoice.ItemsTable.PercentageVisible,e)||(i.formData().Invoice.ItemsTable.PercentageVisible=e),e}),a()(),r(82,"div",2)(83,"POS-input-toggle",4),s("ngModelChange",function(e){return m(i.formData().Invoice.ItemsTable.TaxableVisible,e)||(i.formData().Invoice.ItemsTable.TaxableVisible=e),e}),a()(),r(84,"div",2)(85,"POS-input-toggle",4),s("ngModelChange",function(e){return m(i.formData().Invoice.ItemsTable.NoteItemVisible,e)||(i.formData().Invoice.ItemsTable.NoteItemVisible=e),e}),a()(),r(86,"div",2)(87,"POS-input-toggle",4),s("ngModelChange",function(e){return m(i.formData().Invoice.ItemsTable.NonInventoryCount,e)||(i.formData().Invoice.ItemsTable.NonInventoryCount=e),e}),a()(),r(88,"div",2)(89,"POS-input-field",3),s("ngModelChange",function(e){return m(i.formData().Invoice.ItemsTable.TaxableLabel,e)||(i.formData().Invoice.ItemsTable.TaxableLabel=e),e}),a()(),r(90,"div",2)(91,"POS-input-field",3),s("ngModelChange",function(e){return m(i.formData().Invoice.ItemsTable.ProductCodeVisibleTitle,e)||(i.formData().Invoice.ItemsTable.ProductCodeVisibleTitle=e),e}),a()()()(),r(92,"POS-card",11)(93,"div",1)(94,"div",2)(95,"POS-input-toggle",4),s("ngModelChange",function(e){return m(i.formData().Invoice.ItemsTable.UnitQuantity.Visible,e)||(i.formData().Invoice.ItemsTable.UnitQuantity.Visible=e),e}),a()(),f(96,Q,2,4,"div",2),a()(),r(97,"POS-card",12)(98,"div",1)(99,"div",2)(100,"POS-input-toggle",4),s("ngModelChange",function(e){return m(i.formData().Invoice.ItemsFooter.TotalQuantityVisible,e)||(i.formData().Invoice.ItemsFooter.TotalQuantityVisible=e),e}),a()(),r(101,"div",2)(102,"POS-input-toggle",4),s("ngModelChange",function(e){return m(i.formData().Invoice.ItemsFooter.BaseCurrencyConversionVisible,e)||(i.formData().Invoice.ItemsFooter.BaseCurrencyConversionVisible=e),e}),a()(),r(103,"div",2)(104,"POS-input-toggle",4),s("ngModelChange",function(e){return m(i.formData().Invoice.ItemsFooter.DiscountAmountVisible,e)||(i.formData().Invoice.ItemsFooter.DiscountAmountVisible=e),e}),a()(),r(105,"div",2)(106,"POS-input-toggle",4),s("ngModelChange",function(e){return m(i.formData().Invoice.ItemsFooter.TaxIncludeBeforeTotalAmount,e)||(i.formData().Invoice.ItemsFooter.TaxIncludeBeforeTotalAmount=e),e}),a()(),r(107,"div",2)(108,"POS-input-toggle",4),s("ngModelChange",function(e){return m(i.formData().Invoice.ItemsFooter.CurrencyVisible,e)||(i.formData().Invoice.ItemsFooter.CurrencyVisible=e),e}),a()()()(),r(109,"POS-card",13)(110,"div",1)(111,"div",2)(112,"POS-input-toggle",4),s("ngModelChange",function(e){return m(i.formData().Invoice.Footer.NoteVisible,e)||(i.formData().Invoice.Footer.NoteVisible=e),e}),a()(),r(113,"div",2)(114,"POS-input-toggle",4),s("ngModelChange",function(e){return m(i.formData().Invoice.Footer.ParkNoteVisible,e)||(i.formData().Invoice.Footer.ParkNoteVisible=e),e}),a()(),r(115,"div",2)(116,"POS-input-toggle",4),s("ngModelChange",function(e){return m(i.formData().Invoice.Footer.PaymentMethodVisible,e)||(i.formData().Invoice.Footer.PaymentMethodVisible=e),e}),a()(),r(117,"div",2)(118,"POS-input-toggle",4),s("ngModelChange",function(e){return m(i.formData().Invoice.Footer.DeliveryInfoVisible,e)||(i.formData().Invoice.Footer.DeliveryInfoVisible=e),e}),a()(),r(119,"div",2)(120,"POS-input-toggle",4),s("ngModelChange",function(e){return m(i.formData().Invoice.Footer.TaxDetailVisible,e)||(i.formData().Invoice.Footer.TaxDetailVisible=e),e}),a()(),r(121,"div",2)(122,"POS-input-toggle",4),s("ngModelChange",function(e){return m(i.formData().Invoice.Footer.DiscountIgnoredDecimal,e)||(i.formData().Invoice.Footer.DiscountIgnoredDecimal=e),e}),a()(),r(123,"div",2)(124,"POS-input-toggle",4),s("ngModelChange",function(e){return m(i.formData().Invoice.Footer.ShowLoyaltyPoint,e)||(i.formData().Invoice.Footer.ShowLoyaltyPoint=e),e}),a()(),r(125,"div",2)(126,"POS-input-toggle",4),s("ngModelChange",function(e){return m(i.formData().Invoice.DocumentVisibility.TraceID,e)||(i.formData().Invoice.DocumentVisibility.TraceID=e),e}),a()(),r(127,"div",2)(128,"POS-button-group",9),s("ngModelChange",function(e){return m(i.formData().Invoice.Footer.CreatorVisiblePosition,e)||(i.formData().Invoice.Footer.CreatorVisiblePosition=e),e}),a()()()(),r(129,"POS-card",14)(130,"div",1)(131,"div",6)(132,"POS-input-field",7),s("ngModelChange",function(e){return m(i.formData().Alias.Discount1,e)||(i.formData().Alias.Discount1=e),e}),a()(),r(133,"div",6)(134,"POS-input-field",7),s("ngModelChange",function(e){return m(i.formData().Alias.Discount2,e)||(i.formData().Alias.Discount2=e),e}),a()(),r(135,"div",6)(136,"POS-input-field",7),s("ngModelChange",function(e){return m(i.formData().Alias.DiscountAmount,e)||(i.formData().Alias.DiscountAmount=e),e}),a()(),r(137,"div",6)(138,"POS-input-field",7),s("ngModelChange",function(e){return m(i.formData().Alias.SurchargePcg,e)||(i.formData().Alias.SurchargePcg=e),e}),a()(),r(139,"div",6)(140,"POS-input-field",7),s("ngModelChange",function(e){return m(i.formData().Invoice.Footer.TaxableSales,e)||(i.formData().Invoice.Footer.TaxableSales=e),e}),a()(),r(141,"div",6)(142,"POS-input-field",7),s("ngModelChange",function(e){return m(i.formData().Invoice.Footer.TaxExemptSales,e)||(i.formData().Invoice.Footer.TaxExemptSales=e),e}),a()(),r(143,"div",6)(144,"POS-input-field",7),s("ngModelChange",function(e){return m(i.formData().Invoice.Footer.LabelWithZeroAmount,e)||(i.formData().Invoice.Footer.LabelWithZeroAmount=e),e}),a()(),r(145,"div",6)(146,"POS-input-field",7),s("ngModelChange",function(e){return m(i.formData().Invoice.Footer.Tax,e)||(i.formData().Invoice.Footer.Tax=e),e}),a()(),r(147,"div",6)(148,"POS-input-field",7),s("ngModelChange",function(e){return m(i.formData().Invoice.Footer.LabelRemaining,e)||(i.formData().Invoice.Footer.LabelRemaining=e),e}),a()()()(),r(149,"POS-card",15)(150,"div",1)(151,"div",2)(152,"POS-button-group",16),s("ngModelChange",function(e){return m(i.formData().Invoice.InvoiceQR.A4PrintingType,e)||(i.formData().Invoice.InvoiceQR.A4PrintingType=e),e}),a()(),f(153,N,2,5,"div",2),r(154,"div",2)(155,"POS-button-group",16),s("ngModelChange",function(e){return m(i.formData().Invoice.InvoiceQR.MiniPrintingType,e)||(i.formData().Invoice.InvoiceQR.MiniPrintingType=e),e}),a()(),f(156,U,5,10),a()(),r(157,"POS-card",17)(158,"div",1)(159,"div",6)(160,"POS-input-field",7),s("ngModelChange",function(e){return m(i.formData().Invoice.Signature.Column1,e)||(i.formData().Invoice.Signature.Column1=e),e}),a()(),r(161,"div",6)(162,"POS-input-field",7),s("ngModelChange",function(e){return m(i.formData().Invoice.Signature.Column2,e)||(i.formData().Invoice.Signature.Column2=e),e}),a()(),r(163,"div",6)(164,"POS-input-field",7),s("ngModelChange",function(e){return m(i.formData().Invoice.Signature.Column3,e)||(i.formData().Invoice.Signature.Column3=e),e}),a()(),r(165,"div",6)(166,"POS-input-field",7),s("ngModelChange",function(e){return m(i.formData().Invoice.Signature.Column4,e)||(i.formData().Invoice.Signature.Column4=e),e}),a()()()(),r(167,"POS-card",18)(168,"div",1)(169,"div",2)(170,"POS-input-toggle",4),s("ngModelChange",function(e){return m(i.formData().Invoice.A4PaperConfig.DockBottom,e)||(i.formData().Invoice.A4PaperConfig.DockBottom=e),e}),a()(),r(171,"div",2)(172,"POS-input-toggle",4),s("ngModelChange",function(e){return m(i.formData().Invoice.A4PaperConfig.PaymentChangeVisible,e)||(i.formData().Invoice.A4PaperConfig.PaymentChangeVisible=e),e}),a()()()(),r(173,"POS-card",19)(174,"div",1)(175,"div",2)(176,"POS-input-field",3),s("ngModelChange",function(e){return m(i.formData().Invoice.LogoConfig.ReceiptLogoResizedWidth,e)||(i.formData().Invoice.LogoConfig.ReceiptLogoResizedWidth=e),e}),a()()()(),r(177,"POS-card",20)(178,"div",1)(179,"div",2)(180,"POS-input-field",3),s("ngModelChange",function(e){return m(i.formData().Invoice.ReprintAllowedIn,e)||(i.formData().Invoice.ReprintAllowedIn=e),e}),a()(),r(181,"div",2)(182,"POS-input-toggle",4),s("ngModelChange",function(e){return m(i.formData().Invoice.PrintDialogOnReprint,e)||(i.formData().Invoice.PrintDialogOnReprint=e),e}),a()()()()),d&2&&(t(3),o("label","Title Invoice")("type","text"),l("ngModel",i.formData().Invoice.HeaderTitle),o("isHorizontalLayout",!0)("description","Configure default label for the invoice header."),t(2),o("label","Receipt Invoice Label")("description","Display Copy Sign on Re-Print Invoice Mini"),l("ngModel",i.formData().Invoice.Footer.CopyLabelEnabled),o("defaultConfig",i.configDefault().Invoice.Footer.CopyLabelEnabled),t(2),o("label","Sales Return Label")("description","Customize label for sales return on invoice mini"),l("ngModel",i.formData().Invoice.Header.SalesReturnLabel),o("defaultConfig",i.configDefault().Invoice.Header.SalesReturnLabel),t(),C(i.formData().Invoice.Footer.CopyLabelEnabled?8:-1),t(),C(i.formData().Invoice.Header.SalesReturnLabel?9:-1),t(4),o("label","Customer")("tooltip","Default Label for Customer Purpose in invoice Lx300")("type","text"),l("ngModel",i.formData().Invoice.DocumentLabel.Customer),t(2),o("label","Shipping Address")("tooltip","Default Label for Shipping Address in Invoice LX300")("type","text"),l("ngModel",i.formData().Invoice.DocumentLabel.ShippingAddress),t(2),o("label","Sales Person")("tooltip","Default Label for Sales Person in Invoice mini")("type","text"),l("ngModel",i.formData().Invoice.DocumentLabel.SalesPerson),t(2),o("label","Unpaid Invoice Label")("tooltip","Custom label for Unpaid Invoice in Invoice Mini")("type","text"),l("ngModel",i.formData().Invoice.DocumentLabel.BillLabel),t(4),o("label","Number Visible")("description","Display Invoice Number in Invoice"),l("ngModel",i.formData().Invoice.DocumentVisibility.NumberVisible),o("defaultConfig",i.configDefault().Invoice.DocumentVisibility.NumberVisible),t(2),o("label","Customer Visible")("description","Display Customer on Invoice"),l("ngModel",i.formData().Invoice.DocumentVisibility.CustomerVisible),o("defaultConfig",i.configDefault().Invoice.DocumentVisibility.CustomerVisible),t(2),o("label","Customer Address Visible")("description","Display Customer Address in Invoice"),l("ngModel",i.formData().Invoice.DocumentVisibility.CustomerAddressVisible),o("defaultConfig",i.configDefault().Invoice.DocumentVisibility.CustomerAddressVisible),t(2),o("label","Company Visible")("description","Display Company Name in Invoice LX300"),l("ngModel",i.formData().Invoice.DocumentVisibility.CompanyVisible),o("defaultConfig",i.configDefault().Invoice.DocumentVisibility.CompanyVisible),t(2),o("label","Sales Person Visible")("description","Display Sales Person in Invoice"),l("ngModel",i.formData().Invoice.DocumentVisibility.SalesPersonVisible),o("defaultConfig",i.configDefault().Invoice.DocumentVisibility.SalesPersonVisible),t(2),o("label","Customer Email Visible")("description","Display Customer Email in Invoice"),l("ngModel",i.formData().Invoice.DocumentVisibility.CustomerEmailVisible),o("defaultConfig",i.configDefault().Invoice.DocumentVisibility.CustomerEmailVisible),t(2),o("label","Customer Code Visible")("description","Display Customer Member code in Invoice"),l("ngModel",i.formData().Invoice.DocumentVisibility.CustomerCodeVisible),o("defaultConfig",i.configDefault().Invoice.DocumentVisibility.CustomerCodeVisible),t(2),o("label","Print Time Visible")("description","Display Invoice Print Time in invoice mini"),l("ngModel",i.formData().Invoice.DocumentVisibility.CustomerEntryTimeVisible),o("defaultConfig",i.configDefault().Invoice.DocumentVisibility.CustomerEntryTimeVisible),t(2),o("label","Invoice Create Time Visible")("description","Display Invoice Created Time in invoice mini"),l("ngModel",i.formData().Invoice.DocumentVisibility.InvoiceCreatedTimeVisible),o("defaultConfig",i.configDefault().Invoice.DocumentVisibility.InvoiceCreatedTimeVisible),t(),C(i.formData().Invoice.DocumentVisibility.InvoiceCreatedTimeVisible?40:-1),t(2),o("label","Print Packing Slip After Sell")("description","Show Packing Slip sheet in Invoice mini"),l("ngModel",i.formData().Invoice.DocumentVisibility.PrintPackingslipAftersell),o("defaultConfig",i.configDefault().Invoice.DocumentVisibility.PrintPackingslipAftersell),t(2),o("label","Invoice Payment Terms Visible")("description","Only show if payment later, Display Payment Terms in Invoice"),l("ngModel",i.formData().Invoice.DocumentVisibility.InvoicePaymentTermsVisible),o("defaultConfig",i.configDefault().Invoice.DocumentVisibility.InvoicePaymentTermsVisible),t(2),o("label","Payment Note Visible")("description","Display Payment Note in Invoice mini"),l("ngModel",i.formData().Invoice.DocumentVisibility.PaymentNoteVisible),o("defaultConfig",i.configDefault().Invoice.DocumentVisibility.PaymentNoteVisible),t(2),o("label","Register Code Visible")("description","Display Register Code in Invoice Mini"),l("ngModel",i.formData().Invoice.DocumentVisibility.RegisterCode),o("defaultConfig",i.configDefault().Invoice.DocumentVisibility.RegisterCode),t(2),o("label","Identification Visible")("description","Display Customer's Identification in invoice"),l("ngModel",i.formData().Invoice.DocumentVisibility.IdentificationVisible),o("defaultConfig",i.configDefault().Invoice.DocumentVisibility.IdentificationVisible),t(2),o("label","Phone Number Visible")("description","Display Customer Phone Number in Invoice")("options",i.options().PhoneNumberVisibility),l("ngModel",i.formData().Invoice.DocumentVisibility.PhoneCustomerVisibility),o("defaultConfig",i.configDefault().Invoice.DocumentVisibility.PhoneCustomerVisibility),t(2),o("label","Promotion Coupon Visible")("description","Show Coupon Code in Invoice mini (none/show/last4)")("options",i.options().PromotionCoupon),l("ngModel",i.formData().Invoice.DocumentVisibility.PromotionCoupon),o("defaultConfig",i.configDefault().Invoice.DocumentVisibility.PromotionCoupon),t(2),o("label","Payment Code Visible")("description","Display Payment Code in Invoice Mini (none/show/last4)")("options",i.options().PaymentCode),l("ngModel",i.formData().Invoice.DocumentVisibility.PaymentCode),o("defaultConfig",i.configDefault().Invoice.DocumentVisibility.PaymentCode),t(4),o("label","Code Visible")("description","Display Variant Code in Invoice Cart"),l("ngModel",i.formData().Invoice.ItemsTable.CodeVisible),o("defaultConfig",i.configDefault().Invoice.ItemsTable.CodeVisible),t(2),o("label","Custom Code Header")("type","text"),l("ngModel",i.formData().Invoice.ItemsTable.CodeVisibleTitle),o("isHorizontalLayout",!0)("description","Customize label for code column header on A4 invoice print."),t(2),o("label","UOM Visible")("description","Display Variant UOM in Invoice in A4 Invoice"),l("ngModel",i.formData().Invoice.ItemsTable.UOMVisible),o("defaultConfig",i.configDefault().Invoice.ItemsTable.UOMVisible),t(2),o("label","Sub UOM Visible")("description","Display Variant Sub UOM in A4 Invoice"),l("ngModel",i.formData().Invoice.ItemsTable.SubUOMVisible),o("defaultConfig",i.configDefault().Invoice.ItemsTable.SubUOMVisible),t(2),o("label","Custom UOM Header")("type","text"),l("ngModel",i.formData().Invoice.ItemsTable.UOMVisibleTitle),o("isHorizontalLayout",!0)("description","Customize label for UOM column header on A4 invoice print."),t(2),o("label","Product Code Visible")("description","Show Product Code in Invoice LX300"),l("ngModel",i.formData().Invoice.ItemsTable.ProductCodeWithCodeVariantVisible),o("defaultConfig",i.configDefault().Invoice.ItemsTable.ProductCodeWithCodeVariantVisible),t(2),o("label","Item Without Price Visible")("description","Display Item with '0' price in Invoice"),l("ngModel",i.formData().Invoice.ItemsTable.ItemWithoutPriceVisible),o("defaultConfig",i.configDefault().Invoice.ItemsTable.ItemWithoutPriceVisible),t(2),o("label","Quantity Visible")("description","Display Quantity Items on Cart"),l("ngModel",i.formData().Invoice.ItemsTable.QuantityVisible),o("defaultConfig",i.configDefault().Invoice.ItemsTable.QuantityVisible),t(),C(i.formData().Invoice.ItemsTable.QuantityVisible?75:-1),t(2),o("label","Separate Return Item")("description","Show Different item Between return and item normal only on Invoice LX300"),l("ngModel",i.formData().Invoice.ItemsTable.SeparateRetur),o("defaultConfig",i.configDefault().Invoice.ItemsTable.SeparateRetur),t(2),o("label","Unit Price Visible")("description","Display Items Sold UnitPrice in Invoice LX300"),l("ngModel",i.formData().Invoice.ItemsTable.UnitPriceVisible),o("defaultConfig",i.configDefault().Invoice.ItemsTable.UnitPriceVisible),t(2),o("label","Percentage(%) Visible")("description","Display Discount Percentage(%) per items in Invoice Cart in Invoice LX300"),l("ngModel",i.formData().Invoice.ItemsTable.PercentageVisible),o("defaultConfig",i.configDefault().Invoice.ItemsTable.PercentageVisible),t(2),o("label","Taxable Visible")("description","Display info for Taxable/Non-Taxable Items"),l("ngModel",i.formData().Invoice.ItemsTable.TaxableVisible),o("defaultConfig",i.configDefault().Invoice.ItemsTable.TaxableVisible),t(2),o("label","Note Visible")("description","Display Items Notes in Invoice"),l("ngModel",i.formData().Invoice.ItemsTable.NoteItemVisible),o("defaultConfig",i.configDefault().Invoice.ItemsTable.NoteItemVisible),t(2),o("label","Non Inventory Count")("description","Count product type non-inventory as total product too"),l("ngModel",i.formData().Invoice.ItemsTable.NonInventoryCount),o("defaultConfig",i.configDefault().Invoice.ItemsTable.NonInventoryCount),t(2),o("label","Taxable Label")("type","text"),l("ngModel",i.formData().Invoice.ItemsTable.TaxableLabel),o("isHorizontalLayout",!0)("description","Customize label for taxable items on invoice."),t(2),o("label","Custom Product Code Header")("type","text"),l("ngModel",i.formData().Invoice.ItemsTable.ProductCodeVisibleTitle),o("isHorizontalLayout",!0)("description","Customize label for product code column header on A4 invoice print."),t(),o("description","Config related to SalesOrderItem.UnitQuantity usually used combined with ProductDialog.UnitQtyLabel (when not empty)"),t(3),o("label","Visible")("description","Show unit quantity number"),l("ngModel",i.formData().Invoice.ItemsTable.UnitQuantity.Visible),o("defaultConfig",i.configDefault().Invoice.ItemsTable.UnitQuantity.Visible),t(),C(i.formData().Invoice.ItemsTable.UnitQuantity.Visible?96:-1),t(4),o("label","Total Quantity Visible")("description","Display Total Quantity of Cart in Invoice in LX300"),l("ngModel",i.formData().Invoice.ItemsFooter.TotalQuantityVisible),o("defaultConfig",i.configDefault().Invoice.ItemsFooter.TotalQuantityVisible),t(2),o("label","Base Currency Conversion Visible for A4")("description","Shown if tax assigned and Primary Currency different with Base Currency for A4"),l("ngModel",i.formData().Invoice.ItemsFooter.BaseCurrencyConversionVisible),o("defaultConfig",i.configDefault().Invoice.ItemsFooter.BaseCurrencyConversionVisible),t(2),o("label","Discount Amount Visible")("description","Display Discount Amount in Invoice mini"),l("ngModel",i.formData().Invoice.ItemsFooter.DiscountAmountVisible),o("defaultConfig",i.configDefault().Invoice.ItemsFooter.DiscountAmountVisible),t(2),o("label","Tax Include Before Total Amount")("description","Display Tax Include Before Total Amount"),l("ngModel",i.formData().Invoice.ItemsFooter.TaxIncludeBeforeTotalAmount),o("defaultConfig",i.configDefault().Invoice.ItemsFooter.TaxIncludeBeforeTotalAmount),t(2),o("label","Currency Visible")("description","Show Currency in Amount Summary"),l("ngModel",i.formData().Invoice.ItemsFooter.CurrencyVisible),o("defaultConfig",i.configDefault().Invoice.ItemsFooter.CurrencyVisible),t(4),o("label","Note Visible")("description","Display Invoice Note"),l("ngModel",i.formData().Invoice.Footer.NoteVisible),o("defaultConfig",i.configDefault().Invoice.Footer.NoteVisible),t(2),o("label","Park Name Visible")("description","Show Park Name which tagged by user when want to park in invoice Mini"),l("ngModel",i.formData().Invoice.Footer.ParkNoteVisible),o("defaultConfig",i.configDefault().Invoice.Footer.ParkNoteVisible),t(2),o("label","Payment Method Visible")("description","Display Payment Method in Invoice"),l("ngModel",i.formData().Invoice.Footer.PaymentMethodVisible),o("defaultConfig",i.configDefault().Invoice.Footer.PaymentMethodVisible),t(2),o("label","Delivery Info Visible")("description","Display Delivery Status in Invoice"),l("ngModel",i.formData().Invoice.Footer.DeliveryInfoVisible),o("defaultConfig",i.configDefault().Invoice.Footer.DeliveryInfoVisible),t(2),o("label","Taxable + Tax Exempt Visible")("description","Display Tax Exempt Sales in Invoice"),l("ngModel",i.formData().Invoice.Footer.TaxDetailVisible),o("defaultConfig",i.configDefault().Invoice.Footer.TaxDetailVisible),t(2),o("label","Discount Ignored Decimal")("description","if config YES, value of discount with decimal is disappear the value in invoice."),l("ngModel",i.formData().Invoice.Footer.DiscountIgnoredDecimal),o("defaultConfig",i.configDefault().Invoice.Footer.DiscountIgnoredDecimal),t(2),o("label","Loyalty Point Visible")("description","Display Loyalty Point in Invoice"),l("ngModel",i.formData().Invoice.Footer.ShowLoyaltyPoint),o("defaultConfig",i.configDefault().Invoice.Footer.ShowLoyaltyPoint),t(2),o("label","Trace Number Visible")("description","Display Tracking Number on Invoice"),l("ngModel",i.formData().Invoice.DocumentVisibility.TraceID),o("defaultConfig",i.configDefault().Invoice.DocumentVisibility.TraceID),t(2),o("label","Creator Visible")("description","Display Creator of Invoice")("options",i.options().CreatorVisibility),l("ngModel",i.formData().Invoice.Footer.CreatorVisiblePosition),o("defaultConfig",i.configDefault().Invoice.Footer.CreatorVisiblePosition),t(4),o("label","Discount")("tooltip","Custom label for discount")("type","text"),l("ngModel",i.formData().Alias.Discount1),t(2),o("label","Discount 2")("tooltip","Custom label for second discount")("type","text"),l("ngModel",i.formData().Alias.Discount2),t(2),o("label","Discount Amount")("tooltip","Custom label for discount amount")("type","text"),l("ngModel",i.formData().Alias.DiscountAmount),t(2),o("label","Surcharge")("tooltip","Custom label for surcharge")("type","text"),l("ngModel",i.formData().Alias.SurchargePcg),t(2),o("label","Taxable")("tooltip","Custom label for taxable amount")("type","text"),l("ngModel",i.formData().Invoice.Footer.TaxableSales),t(2),o("label","Tax Exempt Sales")("tooltip","Custom label for tax exempt sales")("type","text"),l("ngModel",i.formData().Invoice.Footer.TaxExemptSales),t(2),o("label","Label With Zero Amount")("tooltip","Show if Config Taxable + Tax Exempt Visible: YES, only Invoice mini")("type","text"),l("ngModel",i.formData().Invoice.Footer.LabelWithZeroAmount),t(2),o("label","Label Tax")("tooltip","Default label for tax in invoice")("type","text"),l("ngModel",i.formData().Invoice.Footer.Tax),t(2),o("label","Remaining Amount")("tooltip","Custom label for remaining amount")("type","text"),l("ngModel",i.formData().Invoice.Footer.LabelRemaining),t(4),o("label","A4 Invoice QR Type")("description","Select QR code type for A4 Invoice")("options",i.options().QRTypes)("defaultConfig",i.configDefault().Invoice.InvoiceQR.A4PrintingType),l("ngModel",i.formData().Invoice.InvoiceQR.A4PrintingType),t(),C(i.formData().Invoice.InvoiceQR.A4PrintingType==i.qrType.QRCode?153:-1),t(2),o("label","Invoice Mini QR Type")("description","Select QR code type for Invoice Mini")("options",i.options().QRTypes)("defaultConfig",i.configDefault().Invoice.InvoiceQR.MiniPrintingType),l("ngModel",i.formData().Invoice.InvoiceQR.MiniPrintingType),t(),C(i.formData().Invoice.InvoiceQR.MiniPrintingType==i.qrType.QRCode?156:-1),t(4),o("label","Column 1")("tooltip","First signature column label")("type","text"),l("ngModel",i.formData().Invoice.Signature.Column1),t(2),o("label","Column 2")("tooltip","Second signature column label")("type","text"),l("ngModel",i.formData().Invoice.Signature.Column2),t(2),o("label","Column 3")("tooltip","Third signature column label")("type","text"),l("ngModel",i.formData().Invoice.Signature.Column3),t(2),o("label","Column 4")("tooltip","Fourth signature column label")("type","text"),l("ngModel",i.formData().Invoice.Signature.Column4),t(4),o("label","Dock Bottom")("description","Enable dock bottom for A4 paper"),l("ngModel",i.formData().Invoice.A4PaperConfig.DockBottom),o("defaultConfig",i.configDefault().Invoice.A4PaperConfig.DockBottom),t(2),o("label","Payment Change Visible")("description","Show payment change information"),l("ngModel",i.formData().Invoice.A4PaperConfig.PaymentChangeVisible),o("defaultConfig",i.configDefault().Invoice.A4PaperConfig.PaymentChangeVisible),t(4),o("label","Receipt Template Logo")("type","number"),l("ngModel",i.formData().Invoice.LogoConfig.ReceiptLogoResizedWidth),o("isHorizontalLayout",!0)("description","Customize the size of the receipt template logo image (width in pixels)."),t(4),o("label","Reprint Allowed In")("type","number"),l("ngModel",i.formData().Invoice.ReprintAllowedIn),o("isHorizontalLayout",!0)("description","Configure maximum time in seconds allowed for unauthorized users to reprint the invoice."),t(2),o("label","Print Dialog On Re-Print")("description","When enabled, the browser print dialog will automatically appear when re-printing"),l("ngModel",i.formData().Invoice.PrintDialogOnReprint),o("defaultConfig",i.configDefault().Invoice.PrintDialogOnReprint))},dependencies:[h,W,O,L,T,P,w],encapsulation:2})};export{E as CustomerInvoiceComponent};
@@ -1 +1 @@
1
- import{a as je}from"./chunk-RMPCUE2N.js";import{a as Le}from"./chunk-I7CB3WMS.js";import{d as Ue}from"./chunk-K2BCWJSV.js";import"./chunk-TDI2ZUL6.js";import{b as Pe,c as be,d as Me}from"./chunk-7GBU7E7F.js";import{a as Be,b as Qe}from"./chunk-EHCELKQF.js";import{b as Ae}from"./chunk-32J765VE.js";import"./chunk-6QINUZF2.js";import"./chunk-ZKLLTU3R.js";import"./chunk-JTZLL5AS.js";import"./chunk-CKHJNQTW.js";import{a as A}from"./chunk-6EUXVAG7.js";import"./chunk-UXZTZFCB.js";import"./chunk-LC65V6UK.js";import"./chunk-CNBTTBK3.js";import"./chunk-6QDAWGFY.js";import"./chunk-CCLE2IVS.js";import{a as we}from"./chunk-OOZY7ONY.js";import{b as Fe}from"./chunk-6623DFFS.js";import"./chunk-ORJAUIF4.js";import"./chunk-F62EEI7V.js";import"./chunk-4EBPNVWA.js";import"./chunk-KTMZNXL5.js";import"./chunk-LZBHDTSD.js";import{a as ke}from"./chunk-B5AGSH45.js";import{g as Ne,h as We}from"./chunk-VUJYUW4B.js";import"./chunk-ZT6YAUVX.js";import{a as Re}from"./chunk-ESWYZY2G.js";import"./chunk-MF3BDWCO.js";import"./chunk-BF42EMHQ.js";import"./chunk-VU5DCR4V.js";import"./chunk-WURU2W3C.js";import"./chunk-UEFG7JV5.js";import"./chunk-ZSK2V6PP.js";import"./chunk-2KEPYDRB.js";import"./chunk-EUIKMR24.js";import"./chunk-7VXCKSAE.js";import"./chunk-3GAEZ6NJ.js";import"./chunk-MOV2FQBP.js";import"./chunk-W4DKC5G3.js";import"./chunk-SLMXA7HD.js";import"./chunk-Y6TPKHHE.js";import{a as Ee}from"./chunk-RHSAPRE2.js";import"./chunk-JI7J6USO.js";import"./chunk-KIONH5BK.js";import"./chunk-NZTQJSEP.js";import"./chunk-W7I2IWJP.js";import"./chunk-HPCTP4FD.js";import"./chunk-KFWGALIF.js";import{a as De,b as ve}from"./chunk-Z7UCI72M.js";import"./chunk-PPMQE2JW.js";import"./chunk-7OCVKGLK.js";import"./chunk-NF7H3LPQ.js";import"./chunk-YKDUJRJQ.js";import"./chunk-OKQYRKDJ.js";import"./chunk-ZX5GTIAE.js";import{d as Se,e as Ve}from"./chunk-ULWLSYED.js";import"./chunk-DU6XSMWH.js";import"./chunk-RCJSPD2P.js";import{a as Te,c as Ie}from"./chunk-LCBHD53Y.js";import"./chunk-IKV23X6H.js";import"./chunk-C6TJ57ES.js";import"./chunk-RJDDPGUV.js";import"./chunk-VUC4E73K.js";import"./chunk-OTSIIVCA.js";import{a as q}from"./chunk-DUAKLYOO.js";import"./chunk-QSBTT5BF.js";import"./chunk-IX2NXO5F.js";import"./chunk-ZRB4EZI3.js";import{b as xe,c as Oe}from"./chunk-KXQJYBG5.js";import"./chunk-3MLD6BQG.js";import"./chunk-LUUIBDJG.js";import"./chunk-R7VXUOCU.js";import"./chunk-NYN3E7NN.js";import{E as U,F as fe,c as ye,h as N,o as W}from"./chunk-R36OIJC7.js";import"./chunk-DKC2333V.js";import"./chunk-FX37N6ZC.js";import{a as Ce}from"./chunk-AGPZGAMV.js";import{b as he}from"./chunk-K74WZXBF.js";import{a as k}from"./chunk-PPTZHIIZ.js";import"./chunk-NR5UTV5U.js";import{n as S,q as _e}from"./chunk-ETYXTCKV.js";import{$ as Y,$a as M,Ba as V,D as G,Db as c,Eb as o,Fb as r,Fc as T,Gb as w,Gc as R,Hc as H,Kb as Q,Lb as j,Lc as ae,Mc as oe,Nd as me,Oc as re,Pb as D,Qd as ue,Sb as y,Sd as ge,Ua as l,Ub as s,Xc as le,da as J,db as L,ec as $,hc as d,hd as se,ib as X,ic as ee,jb as O,jc as x,kc as te,kd as pe,ld as ce,mc as f,na as v,nc as h,oc as C,ra as u,sa as g,sd as de,vd as E,wb as Z,xc as ne,yb as K,yc as ie}from"./chunk-DUSKF5IQ.js";import{a as P,b}from"./chunk-NF7PG5F2.js";var B=class a{dialogRef=v(Te);toastrService=v(S);modalConfig;selectedOutlets=[];constructor(){this.modalConfig=new xe,this.modalConfig.title="Update ROP",this.modalConfig.customWidth="350px"}onOk(){if(this.selectedOutlets.length===0){this.toastrService.warning("Please select at least one outlet","Warning");return}this.dialogRef.close(this.selectedOutlets)}onClose(){this.dialogRef.close()}static \u0275fac=function(e){return new(e||a)};static \u0275cmp=L({type:a,selectors:[["app-modal-update-rop"]],decls:6,vars:3,consts:[[3,"onOk","onCancel","onClose","config"],[1,"container"],[1,"row"],[1,"col-12"],[3,"ngModelChange","ngModel","multiple"]],template:function(e,t){e&1&&(o(0,"modal-material",0),y("onOk",function(){return t.onOk()})("onCancel",function(){return t.onClose()})("onClose",function(){return t.onClose()}),o(1,"content")(2,"div",1)(3,"div",2)(4,"div",3)(5,"outlet-selector",4),C("ngModelChange",function(i){return h(t.selectedOutlets,i)||(t.selectedOutlets=i),i}),r()()()()()()),e&2&&(c("config",t.modalConfig),l(5),f("ngModel",t.selectedOutlets),c("multiple",!0))},dependencies:[E,Oe,A,U,N,W],encapsulation:2})};var z=(i=>(i[i.negative=0]="negative",i[i.empty=1]="empty",i[i.critical=2]="critical",i[i.optimal=3]="optimal",i[i.overstock=4]="overstock",i))(z||{});var Je=()=>[],Xe=a=>({ID:a});function Ze(a,m){if(a&1){let e=D();o(0,"button",7),y("click",function(){u(e);let n=s();return g(n.openExportModal())}),w(1,"i",8),d(2," Export "),r()}}function Ke(a,m){if(a&1){let e=D();o(0,"button",9),y("click",function(){u(e);let n=s();return g(n.onSubmitROP())}),w(1,"i",10),d(2," Save ROP "),r()}if(a&2){let e=s();c("matTooltip","Save ROP to Outlet "+e.outletSelected)}}function $e(a,m){if(a&1){let e=D();o(0,"h6"),d(1,"Show Inventory & Sales for Outlet"),r(),o(2,"outlet-selector",11),C("ngModelChange",function(n){u(e);let i=s();return h(i.pageData().Filter.ListIDs,n)||(i.pageData().Filter.ListIDs=n),g(n)}),r(),o(3,"h6"),d(4,"Category"),r(),o(5,"POS-product-category-select",12),C("selectedCategoryIDChange",function(n){u(e);let i=s();return h(i.pageData().Filter.CategoryID,n)||(i.pageData().Filter.CategoryID=n),g(n)}),r(),o(6,"h6"),d(7," Product Sold Within Days "),w(8,"i",13),r(),o(9,"input",14),C("ngModelChange",function(n){u(e);let i=s();return h(i.pageData().Filter.NumberOfDays,n)||(i.pageData().Filter.NumberOfDays=n),g(n)}),r(),o(10,"h6"),d(11,"Inventory Threshold"),r(),o(12,"div",15)(13,"div",16)(14,"input",17),C("ngModelChange",function(n){u(e);let i=s();return h(i.pageData().Filter.CriticalDaysThreshold,n)||(i.pageData().Filter.CriticalDaysThreshold=n),g(n)}),y("ngModelChange",function(n){u(e);let i=s();return g(i.onCriticalChange(n))}),r(),o(15,"div",18)(16,"div",19),w(17,"div",20)(18,"div",21)(19,"div",22),r(),o(20,"div",23)(21,"span"),d(22),r(),o(23,"span"),d(24),r(),o(25,"span"),d(26),r()()(),o(27,"input",24),C("ngModelChange",function(n){u(e);let i=s();return h(i.pageData().Filter.OverstockDaysThreshold,n)||(i.pageData().Filter.OverstockDaysThreshold=n),g(n)}),y("ngModelChange",function(n){u(e);let i=s();return g(i.onOverstockChange(n))}),r()()(),o(28,"h6"),d(29,"Days Of Risk"),r(),o(30,"ng-select",25),C("ngModelChange",function(n){u(e);let i=s();return h(i.pageData().Filter.DaysOfRisk,n)||(i.pageData().Filter.DaysOfRisk=n),g(n)}),r(),o(31,"h6"),d(32,"Set ROP for Outlet"),r(),o(33,"outlet-selector",26),C("ngModelChange",function(n){u(e);let i=s();return h(i.pageData().Filter.TargetOutlet,n)||(i.pageData().Filter.TargetOutlet=n),g(n)}),y("onListOutlets",function(n){u(e);let i=s();return g(i.getOutlets(n))}),r(),o(34,"h6"),d(35,"Count Indirect Allocated"),r(),o(36,"radio-options",27),C("modelChange",function(n){u(e);let i=s();return h(i.pageData().Filter.CalculateIndirectAllocated,n)||(i.pageData().Filter.CalculateIndirectAllocated=n),g(n)}),r()}if(a&2){let e,t=s();l(2),c("multiple",!0)("accessType",2),f("ngModel",t.pageData().Filter.ListIDs),l(3),f("selectedCategoryID",t.pageData().Filter.CategoryID),c("showClear",!0),l(4),f("ngModel",t.pageData().Filter.NumberOfDays),l(5),f("ngModel",t.pageData().Filter.CriticalDaysThreshold),l(8),x("\u2264",t.pageData().Filter.CriticalDaysThreshold," Days"),l(2),te("",t.pageData().Filter.CriticalDaysThreshold+1,"-",t.pageData().Filter.OverstockDaysThreshold," Days"),l(2),x(">",t.pageData().Filter.OverstockDaysThreshold," Days"),l(),f("ngModel",t.pageData().Filter.OverstockDaysThreshold),l(3),c("items",((e=t.pageData().Options)==null?null:e.DaysOfRisks)||ne(19,Je))("clearable",!0),f("ngModel",t.pageData().Filter.DaysOfRisk),l(3),c("multiple",!1)("accessType",2),f("ngModel",t.pageData().Filter.TargetOutlet),l(3),f("model",t.pageData().Filter.CalculateIndirectAllocated)}}function et(a,m){a&1&&(o(0,"th",43),d(1," LT "),r())}function tt(a,m){if(a&1&&(o(0,"th",44),d(1," ROP "),r()),a&2){let e=s(2);c("matTooltip","Based on "+e.outletSelected+" ROP")}}function nt(a,m){if(a&1){let e=D();o(0,"td",46)(1,"input",47),C("ngModelChange",function(n){u(e);let i=s().$implicit;return h(i.LeadTime,n)||(i.LeadTime=n),g(n)}),y("ngModelChange",function(n){u(e);let i=s().$implicit,p=s(2);return g(p.onInputLeadTime(n,i))}),r()()}if(a&2){let e=s(),t=e.$implicit,n=e.index;l(),c("name","LeadTime"+n),f("ngModel",t.LeadTime),c("id","leadTime"+n)}}function it(a,m){if(a&1){let e=D();o(0,"div",49)(1,"div",50)(2,"span",51),d(3),T(4,"number"),r(),w(5,"i",52),o(6,"div",53)(7,"input",54),T(8,"quantityFraction"),y("ngModelChange",function(n){u(e);let i=s(2).$implicit,p=s(2);return g(p.onInputROP(n,i))}),r()()()()}if(a&2){let e=s(2),t=e.$implicit,n=e.index,i=s(2);l(3),x(" ",R(4,5,i.getOriginalROP(t))," "),l(4),c("decimalPlaces",i.ropDecimalPlaces)("name","ROP"+n)("ngModel",R(8,7,t.ROP))("id","ROP"+n)}}function at(a,m){if(a&1&&(o(0,"span",46),d(1),T(2,"number"),r()),a&2){let e=s(2).$implicit;l(),x(" ",R(2,1,e.ROP)," ")}}function ot(a,m){if(a&1&&(o(0,"td",46),O(1,it,9,9,"div",48)(2,at,3,3,"span",41),r()),a&2){let e=s().$implicit;l(),c("ngIf",e.LeadTime),l(),c("ngIf",!e.LeadTime)}}function rt(a,m){if(a&1&&(o(0,"tr")(1,"td")(2,"a",45),d(3),r()(),o(4,"td"),d(5),r(),o(6,"td",46),d(7),T(8,"quantityFraction"),r(),o(9,"td",46),d(10),T(11,"number"),r(),o(12,"td",46),d(13),T(14,"number"),r(),o(15,"td",46)(16,"div"),d(17),r()(),O(18,nt,2,3,"td",41)(19,ot,3,2,"td",41),r()),a&2){let e=m.$implicit,t=s(2);l(2),c("queryParams",ie(27,Xe,e.ID)),l(),x(" ",e.Name," "),l(2),ee(e.Code),l(2),x(" ",R(8,19,e.Available)," "),l(3),x(" ",H(11,21,e.QtySoldPerDay,"1.0-2")," "),l(3),x(" ",e.QtySoldPerDay<0?"-":H(14,24,e.DaysOf,"1.0-0")," "),l(3),$("text-negative",e.DaysOfRiskType===t.riskType.negative)("text-empty",e.DaysOfRiskType===t.riskType.empty)("text-critical",e.DaysOfRiskType===t.riskType.critical)("text-optimal",e.DaysOfRiskType===t.riskType.optimal)("text-overstock",e.DaysOfRiskType===t.riskType.overstock),l(),x(" ",e.DaysOfRisk," "),l(),c("ngIf",t.pageData().Filter.TargetOutlet),l(),c("ngIf",t.pageData().Filter.TargetOutlet)}}function lt(a,m){a&1&&(o(0,"td",46)(1,"span"),d(2,"Bulk Lead Time "),r()())}function st(a,m){if(a&1){let e=D();o(0,"td")(1,"input",55),y("ngModelChange",function(n){u(e);let i=s(2);return g(i.onBulkUpdateLT(n))}),r()()}if(a&2){let e=s(2);l(),c("ngModel",e.bulkUpdateLTValue())("id","LT")}}function pt(a,m){if(a&1){let e=D();o(0,"div",28)(1,"div",29)(2,"table",30),y("matSortChange",function(n){u(e);let i=s();return g(i.sortData(n))}),o(3,"thead",31)(4,"tr")(5,"th",32),d(6,"Product"),r(),o(7,"th",33),d(8,"Code"),r(),o(9,"th",34),d(10," Available "),r(),o(11,"th",35),d(12," SOLD/DAY "),r(),o(13,"th",36),d(14," Days Of "),r(),o(15,"th",37),d(16," Risk "),r(),O(17,et,2,0,"th",38)(18,tt,2,1,"th",39),r()(),o(19,"tbody"),O(20,rt,20,29,"tr",40),r(),o(21,"tfoot")(22,"tr"),w(23,"td")(24,"td")(25,"td")(26,"td")(27,"td"),O(28,lt,3,0,"td",41),Z(29,st,2,2,"td"),r()()()(),o(30,"div")(31,"POS-complex-pagination",42),y("jumpToPage",function(){u(e);let n=s();return g(n.getListData())})("previousPage",function(){u(e);let n=s();return g(n.getListData())})("nextPage",function(){u(e);let n=s();return g(n.getListData())}),C("reloadRowCountChange",function(n){u(e);let i=s();return h(i.reloadRowCount,n)||(i.reloadRowCount=n),g(n)}),r()()()}if(a&2){let e,t=s();l(11),c("matTooltip","Based on Last "+t.pageData().Filter.NumberOfDays+" Days Sold"),l(6),c("ngIf",t.pageData().Filter.TargetOutlet),l(),c("ngIf",t.pageData().Filter.TargetOutlet),l(2),c("ngForOf",t.data().Data),l(8),c("ngIf",t.pageData().Filter.TargetOutlet&&t.data().Data.length>0),l(),K(t.pageData().Filter.TargetOutlet&&t.data().Data.length>0?29:-1),l(2),c("total",t.data().Data.length)("totalAllData",(e=t.data())==null?null:e.ListTotal)("pageData",t.pageData()),f("reloadRowCount",t.reloadRowCount)}}var He=class a extends we{constructor(e,t,n,i,p,_){super(e,t,"Inventory/DayOf","InventoryLoader/DaysOf",void 0,_,!0);this.httpService=t;this.csvConverter=i;this.roleService=p}httpService;csvConverter;roleService;dialog=v(Ie);fractionData=v(Ce);locale=v(oe);riskType=z;get ropDecimalPlaces(){return this.fractionData.quantity.maximumFraction}formatQuantityFraction(e){let t=`1.${this.fractionData.quantity.minimumFraction}-${this.fractionData.quantity.maximumFraction}`;return se(e,this.locale,t)}ListUpdateROP=V([]);listOutlet=V([]);bulkUpdateLTValue=le("");toastr=v(S);originalROPValues=V(new Map);rawROPValues=V([]);subTotalROP=re(()=>this.ListUpdateROP()?this.ListUpdateROP().reduce((e,t)=>e+Number(t.Value),0).toFixed(3):0);postInit(e){this.rawROPValues.set(e.Data),this.ListUpdateROP.set([]),this.originalROPValues.set(new Map)}preInitList(){this.menuData().H="Days of Inventory"}onInputLeadTime(e,t){if(k.IsEmpty(e)||e===0){this.rawROPValues().find(F=>F.ID===t.ID)&&(t.LeadTime="",t.ROP=this.getOriginalROP(t)),this.data.set(b(P({},this.data()),{Data:[...this.data().Data]}));return}let n=this.originalROPValues();n.has(t.ID)||(n.set(t.ID,t.ROP),this.originalROPValues.set(new Map(n)));let i=this.fractionData.quantity.maximumFraction,p=e*t.QtySoldPerDay;t.ROP=parseFloat(p.toFixed(i)),this.ListUpdateROP.update(_=>[..._.filter(qe=>qe.Key!==t.ID),{Key:t.ID,Value:this.formatQuantityFraction(t.ROP)}])}onInputROP(e,t){if(e){let n=this.fractionData.quantity.maximumFraction,i=parseFloat(e.toFixed(n));t.ROP=i,this.ListUpdateROP.update(p=>[...p.filter(F=>F.Key!==t.ID),{Key:t.ID,Value:this.formatQuantityFraction(i)}])}}getOriginalROP(e){return this.originalROPValues().get(e.ID)||e.ROP}get outletSelected(){if(this.listOutlet().length>0&&this.pageData().Filter.TargetOutlet){let e=this.listOutlet().findIndex(t=>t.k===this.pageData().Filter.TargetOutlet);if(e!==-1)return this.listOutlet()[e].v}return""}getOutlets(e){console.log(e),this.listOutlet.set(e)}onSubmitROP(){let e={ListUpdateROP:[...this.ListUpdateROP()],EntityID:this.pageData().Filter.TargetOutlet};this.httpService.post(q.UpdateROP,e).pipe(je("response"),J(t=>{this.toastr.success("ROP has been updated successfully.","Success!"),this.originalROPValues.set(new Map),this.getListData(),this.ListUpdateROP.set([]),this.bulkUpdateLTValue.set("")})).subscribe()}resetOriginalROP(e){let t=this.originalROPValues();t.has(e.ID)&&(t.delete(e.ID),this.originalROPValues.set(new Map(t)))}updateRop(e,t){this.dialog.open(B).afterClosed().pipe(G(n=>k.IsNotEmpty(n)),Y(n=>{let i={VariantID:e.ID,ListEntityID:n,ROP:e.ROP};return this.httpService.post(q.UpdateROP,i)})).subscribe(()=>{this.clearInput(`leadTime${t}`),this.toastr.success("ROP has been updated successfully.","Success!"),this.getListData()})}clearInput(e){let t=document.getElementById(e);t&&(t.value="")}openExportModal(){this.dialog.open(Fe,{data:{title:"Days of Inventory",exportTypes:[{ID:"InventoryExport/GetDaysOfExport",Value:"Default",FileName:"Days of Inventory"}],filterExport:this.pageData().Filter,getAllDataLengthAPI:"Inventory/DayOfCount",pagination:!0}})}sortData(e){let t=[...this.data().Data];if(!e.active||e.direction===""){this.data.set(b(P({},this.data()),{Data:[...t]}));return}let n=t.sort((i,p)=>{let _=e.direction==="asc";switch(e.active){case"Name":return I(i.Name,p.Name,_);case"Code":return I(i.Code,p.Code,_);case"QtySold":return I(i.QtySold,p.QtySold,_);case"QtySoldPerDay":return I(i.QtySoldPerDay,p.QtySoldPerDay,_);case"OnHand":return I(i.OnHand,p.OnHand,_);case"Available":return I(i.Available,p.Available,_);case"DaysOf":return I(i.DaysOf,p.DaysOf,_);default:return 0}});this.data.set(b(P({},this.data()),{Data:[...n]}))}onBulkUpdateLT(e){let t=this.originalROPValues(),n=this.rawROPValues();if(k.IsEmpty(e)){this.bulkUpdateLTValue.set(""),this.data.set(b(P({},this.data()),{Data:n.map(p=>b(P({},p),{LeadTime:null}))}));return}let i=+e;if(this.bulkUpdateLTValue.set(i),!!this.data()?.Data){for(let p of this.data().Data)t.has(p.ID)||t.set(p.ID,p.ROP),p.LeadTime=i,p.ROP=i*(p.QtySoldPerDay||0);this.originalROPValues.set(new Map(t)),this.ListUpdateROP.set(this.data().Data.map(p=>({Key:p.ID,Value:this.formatQuantityFraction(p.ROP)}))),this.data.set(b(P({},this.data()),{Data:[...this.data().Data]}))}}onCriticalChange(e){let t=this.pageData().Filter.ExceedDaysThreshold;e>=t&&(this.pageData().Filter.ExceedDaysThreshold=e+1)}onOverstockChange(e){let t=this.pageData().Filter.CriticalDaysThreshold;e<=t&&(this.pageData().Filter.ExceedDaysThreshold=t+1)}static \u0275fac=function(t){return new(t||a)(M(Ee),M(_e),M(S),M(ke),M(he),M(me))};static \u0275cmp=L({type:a,selectors:[["app-days-of-inventory"]],inputs:{bulkUpdateLTValue:[1,"bulkUpdateLTValue"]},outputs:{bulkUpdateLTValue:"bulkUpdateLTValueChange"},features:[X],decls:9,vars:6,consts:[["pageFilterTemplate",""],[3,"onSubmit","textChange","pageData","text","isFilterOnDropdown"],["ngProjectAs","actions",5,["actions"]],["class","btn btn-outline-secondary me-2",3,"click",4,"ngIf"],["class","btn btn-outline-secondary","role","button",3,"matTooltip","click",4,"ngIf"],["ngProjectAs","filters",5,["filters"]],["class","container-fluid mt-5",4,"ngIf"],[1,"btn","btn-outline-secondary","me-2",3,"click"],["aria-hidden","true",1,"fa-solid","fa-upload"],["role","button",1,"btn","btn-outline-secondary",3,"click","matTooltip"],[1,"fa-solid","fa-save","me-3"],["placeholder","Choose Outlets",1,"ng-select-multiple",3,"ngModelChange","multiple","accessType","ngModel"],[1,"tree-select-as-filter",3,"selectedCategoryIDChange","selectedCategoryID","showClear"],["matTooltip","Number of past days used to calculate average daily sales for inventory planning","matTooltipPosition","above",1,"fa-light","fa-circle-info",2,"cursor","pointer"],["autoNum","","min","1",1,"form-control",3,"ngModelChange","ngModel"],[1,"threshold-compact-wrapper"],[1,"threshold-row"],["type","text","autoNum","","min","1",1,"threshold-input-mini","input-critical",3,"ngModelChange","ngModel"],[1,"threshold-bar-container"],[1,"threshold-bar"],["matTooltip","Critical","matTooltipPosition","above",1,"bar-segment","seg-critical"],["matTooltip","Optimal","matTooltipPosition","above",1,"bar-segment","seg-optimal"],["matTooltip","Overstock","matTooltipPosition","above",1,"bar-segment","seg-overstock"],[1,"threshold-bar-labels"],["type","text","autoNum","","min","1",1,"threshold-input-mini","input-overstock",3,"ngModelChange","ngModel"],["bindLabel","Value","bindValue","Key","placeholder","All",1,"ng-select",3,"ngModelChange","items","clearable","ngModel"],["placeholder","Choose Outlet",1,"ng-select-multiple",3,"ngModelChange","onListOutlets","multiple","accessType","ngModel"],["name","IndirectAllocated",3,"modelChange","model"],[1,"container-fluid","mt-5"],[1,"table-responsive"],["matSort","",1,"table","custom-table","mt-5",3,"matSortChange"],[1,"thead-light","sticky-top-thead"],["mat-sort-header","Name"],["mat-sort-header","Code",2,"width","125px"],["mat-sort-header","Available","matTooltip","Inventory available for sale","arrowPosition","before",1,"text-end",2,"width","100px"],["mat-sort-header","QtySoldPerDay","arrowPosition","before",1,"text-end",2,"width","100px",3,"matTooltip"],["mat-sort-header","DaysOf","arrowPosition","before","matTooltip","How many days left until you run out of inventory",1,"text-end",2,"width","100px"],["mat-sort-header","DaysOfRisk","arrowPosition","before",1,"text-end",2,"width","120px"],["style","width: 80px","matTooltip","The LEAD TIME (in days) it takes to receive the inventory after placing an order","class","text-end",4,"ngIf"],["class","text-end","style","width: 120px",3,"matTooltip",4,"ngIf"],[4,"ngFor","ngForOf"],["class","text-end",4,"ngIf"],["api","Inventory/DayOfCount",3,"jumpToPage","previousPage","nextPage","reloadRowCountChange","total","totalAllData","pageData","reloadRowCount"],["matTooltip","The LEAD TIME (in days) it takes to receive the inventory after placing an order",1,"text-end",2,"width","80px"],[1,"text-end",2,"width","120px",3,"matTooltip"],["routerLink","/menu/Products/Catalog/Variants/Info","target","_blank",3,"queryParams"],[1,"text-end"],["autoNum","","type","text",1,"form-control","text-end",3,"ngModelChange","name","ngModel","id"],["class","rop-comparison",4,"ngIf"],[1,"rop-comparison"],[1,"d-flex","align-items-center","justify-content-end","gap-2"],[1,"old-value"],[1,"fa-solid","fa-arrow-right","text-muted"],[1,"input-group","input-group-sm",2,"width","70px"],["autoNum","","type","text",1,"form-control","text-end",3,"ngModelChange","decimalPlaces","name","ngModel","id"],["autoNum","","type","text",1,"form-control","text-end",3,"ngModelChange","ngModel","id"]],template:function(t,n){if(t&1){let i=D();o(0,"mainpanel-cmp",1),y("onSubmit",function(){return n.getListData()}),C("textChange",function(_){return u(i),h(n.pageData().Filter.FilterText,_)||(n.pageData().Filter.FilterText=_),g(_)}),Q(1,2),O(2,Ze,3,0,"button",3)(3,Ke,3,1,"button",4),j(),Q(4,5),O(5,$e,37,20,"ng-template",null,0,ae),j(),o(7,"content"),O(8,pt,32,10,"div",6),r()()}t&2&&(c("pageData",n.menuData()),f("text",n.pageData().Filter.FilterText),c("isFilterOnDropdown",!1),l(2),c("ngIf",n.roleService.global.Export),l(),c("ngIf",n.ListUpdateROP().length>0),l(5),c("ngIf",n.data()))},dependencies:[E,pe,ce,We,Ne,Re,U,ye,N,W,A,ge,ue,Qe,Be,Ae,ve,De,fe,Me,Pe,be,Ue,Ve,Se,de,Le],styles:[".threshold-compact-wrapper[_ngcontent-%COMP%]{background:#f8f9fa;border-radius:8px;padding:.6rem .75rem;margin:.25rem 0 1rem;border:1px solid #e9ecef}.threshold-compact-wrapper[_ngcontent-%COMP%] .threshold-row[_ngcontent-%COMP%]{display:flex;align-items:center;gap:.6rem}.threshold-compact-wrapper[_ngcontent-%COMP%] .threshold-input-mini[_ngcontent-%COMP%]{width:48px;text-align:center;font-size:.75rem;font-weight:600;border-radius:6px;border:1.5px solid #e5e7eb;padding:.3rem .15rem;background:#fff;color:#374151;flex-shrink:0;transition:all .15s ease}.threshold-compact-wrapper[_ngcontent-%COMP%] .threshold-input-mini[_ngcontent-%COMP%]:focus{outline:none}.threshold-compact-wrapper[_ngcontent-%COMP%] .threshold-input-mini.input-critical[_ngcontent-%COMP%]{border-color:#f5f0a6}.threshold-compact-wrapper[_ngcontent-%COMP%] .threshold-input-mini.input-critical[_ngcontent-%COMP%]:focus{border-color:#fff44f;box-shadow:0 0 0 2px #fff44f1f}.threshold-compact-wrapper[_ngcontent-%COMP%] .threshold-input-mini.input-overstock[_ngcontent-%COMP%]{border-color:#96b0f7}.threshold-compact-wrapper[_ngcontent-%COMP%] .threshold-input-mini.input-overstock[_ngcontent-%COMP%]:focus{border-color:#3581d8;box-shadow:0 0 0 2px #3581d81f}.threshold-compact-wrapper[_ngcontent-%COMP%] .threshold-bar-container[_ngcontent-%COMP%]{flex:1;display:flex;flex-direction:column;gap:.25rem;min-width:0}.threshold-compact-wrapper[_ngcontent-%COMP%] .threshold-bar[_ngcontent-%COMP%]{display:flex;height:10px;border-radius:5px;overflow:hidden;box-shadow:inset 0 1px 2px #00000014}.threshold-compact-wrapper[_ngcontent-%COMP%] .threshold-bar[_ngcontent-%COMP%] .bar-segment[_ngcontent-%COMP%]{flex:1;transition:background .3s ease;cursor:pointer}.threshold-compact-wrapper[_ngcontent-%COMP%] .threshold-bar[_ngcontent-%COMP%] .bar-segment.seg-critical[_ngcontent-%COMP%]{background:#fff44f}.threshold-compact-wrapper[_ngcontent-%COMP%] .threshold-bar[_ngcontent-%COMP%] .bar-segment.seg-critical[_ngcontent-%COMP%]:hover{background:#f7e817}.threshold-compact-wrapper[_ngcontent-%COMP%] .threshold-bar[_ngcontent-%COMP%] .bar-segment.seg-optimal[_ngcontent-%COMP%]{background:#28cc2d}.threshold-compact-wrapper[_ngcontent-%COMP%] .threshold-bar[_ngcontent-%COMP%] .bar-segment.seg-optimal[_ngcontent-%COMP%]:hover{background:#388e3c}.threshold-compact-wrapper[_ngcontent-%COMP%] .threshold-bar[_ngcontent-%COMP%] .bar-segment.seg-overstock[_ngcontent-%COMP%]{background:#3581d8}.threshold-compact-wrapper[_ngcontent-%COMP%] .threshold-bar[_ngcontent-%COMP%] .bar-segment.seg-overstock[_ngcontent-%COMP%]:hover{background:#2c58af}.threshold-compact-wrapper[_ngcontent-%COMP%] .threshold-bar-labels[_ngcontent-%COMP%]{display:flex;justify-content:space-between;font-size:.55rem;font-weight:500;color:#9ca3af;padding:0 2px}.threshold-compact-wrapper[_ngcontent-%COMP%] .threshold-bar-labels[_ngcontent-%COMP%] span[_ngcontent-%COMP%]:nth-child(1){color:#a39800}.threshold-compact-wrapper[_ngcontent-%COMP%] .threshold-bar-labels[_ngcontent-%COMP%] span[_ngcontent-%COMP%]:nth-child(2){color:#28cc2d}.threshold-compact-wrapper[_ngcontent-%COMP%] .threshold-bar-labels[_ngcontent-%COMP%] span[_ngcontent-%COMP%]:nth-child(3){color:#3581d8}.text-negative[_ngcontent-%COMP%]{color:#a61b29}.text-empty[_ngcontent-%COMP%]{color:#d82e3f}.text-critical[_ngcontent-%COMP%]{color:#e8c73a}.text-optimal[_ngcontent-%COMP%]{color:#28cc2d}.text-overstock[_ngcontent-%COMP%]{color:#3581d8}"],changeDetection:0})};function I(a,m,e){return a===null||a===""?e?-1:1:m===null||m===""?e?1:-1:typeof a=="string"&&typeof m=="string"?a.localeCompare(m)*(e?1:-1):typeof a=="number"&&typeof m=="number"?(a<m?-1:1)*(e?1:-1):typeof a=="string"&&typeof m=="number"?e?-1:1:typeof a=="number"&&typeof m=="string"?e?1:-1:0}export{He as DaysOfInventoryComponent};
1
+ import{a as je}from"./chunk-RMPCUE2N.js";import{a as Le}from"./chunk-I7CB3WMS.js";import{d as Ue}from"./chunk-K2BCWJSV.js";import"./chunk-TDI2ZUL6.js";import{b as Pe,c as be,d as Me}from"./chunk-7GBU7E7F.js";import{a as Be,b as Qe}from"./chunk-EHCELKQF.js";import{b as Ae}from"./chunk-6ZV2PHVD.js";import"./chunk-6QINUZF2.js";import"./chunk-ZKLLTU3R.js";import"./chunk-JTZLL5AS.js";import"./chunk-CKHJNQTW.js";import{a as A}from"./chunk-T5POZFJR.js";import"./chunk-UXZTZFCB.js";import"./chunk-LC65V6UK.js";import"./chunk-CNBTTBK3.js";import"./chunk-6QDAWGFY.js";import"./chunk-CCLE2IVS.js";import{a as we}from"./chunk-2AW77P5H.js";import{b as Fe}from"./chunk-6623DFFS.js";import"./chunk-ORJAUIF4.js";import"./chunk-NVSZUDQ3.js";import"./chunk-JG644ODH.js";import"./chunk-KTMZNXL5.js";import"./chunk-LZBHDTSD.js";import{a as ke}from"./chunk-B5AGSH45.js";import{g as Ne,h as We}from"./chunk-24YLKMEJ.js";import"./chunk-ZT6YAUVX.js";import{a as Re}from"./chunk-ESWYZY2G.js";import"./chunk-MF3BDWCO.js";import"./chunk-BF42EMHQ.js";import"./chunk-VU5DCR4V.js";import"./chunk-WURU2W3C.js";import"./chunk-UEFG7JV5.js";import"./chunk-ZSK2V6PP.js";import"./chunk-2KEPYDRB.js";import"./chunk-EUIKMR24.js";import"./chunk-7VXCKSAE.js";import"./chunk-3GAEZ6NJ.js";import"./chunk-MOV2FQBP.js";import"./chunk-W4DKC5G3.js";import"./chunk-SLMXA7HD.js";import"./chunk-US4LHROB.js";import{a as Ee}from"./chunk-WYDVIMXE.js";import"./chunk-JI7J6USO.js";import"./chunk-KIONH5BK.js";import"./chunk-I5JH4FHZ.js";import"./chunk-W7I2IWJP.js";import"./chunk-HPCTP4FD.js";import"./chunk-KFWGALIF.js";import{a as De,b as ve}from"./chunk-Z7UCI72M.js";import"./chunk-PPMQE2JW.js";import"./chunk-7OCVKGLK.js";import"./chunk-NF7H3LPQ.js";import"./chunk-3FFHADFC.js";import"./chunk-OKQYRKDJ.js";import"./chunk-IIARVTAV.js";import{d as Se,e as Ve}from"./chunk-ULWLSYED.js";import"./chunk-DU6XSMWH.js";import"./chunk-WF4CWM6A.js";import{a as Te,c as Ie}from"./chunk-LCBHD53Y.js";import"./chunk-IKV23X6H.js";import"./chunk-C6TJ57ES.js";import"./chunk-RJDDPGUV.js";import"./chunk-VUC4E73K.js";import"./chunk-OTSIIVCA.js";import{a as q}from"./chunk-DUAKLYOO.js";import"./chunk-QSBTT5BF.js";import"./chunk-IX2NXO5F.js";import"./chunk-ZRB4EZI3.js";import{b as xe,c as Oe}from"./chunk-KXQJYBG5.js";import"./chunk-3MLD6BQG.js";import"./chunk-LUUIBDJG.js";import"./chunk-R7VXUOCU.js";import"./chunk-NYN3E7NN.js";import{E as U,F as fe,c as ye,h as N,o as W}from"./chunk-R36OIJC7.js";import"./chunk-RIYY3QQM.js";import"./chunk-XGLKE2VY.js";import{a as Ce}from"./chunk-AGPZGAMV.js";import{b as he}from"./chunk-K74WZXBF.js";import{a as k}from"./chunk-PPTZHIIZ.js";import"./chunk-G2B2G6M2.js";import{n as S,q as _e}from"./chunk-ETYXTCKV.js";import{$ as Y,$a as M,Ba as V,D as G,Db as c,Eb as o,Fb as r,Fc as T,Gb as w,Gc as R,Hc as H,Kb as Q,Lb as j,Lc as ae,Mc as oe,Nd as me,Oc as re,Pb as D,Qd as ue,Sb as y,Sd as ge,Ua as l,Ub as s,Xc as le,da as J,db as L,ec as $,hc as d,hd as se,ib as X,ic as ee,jb as O,jc as x,kc as te,kd as pe,ld as ce,mc as f,na as v,nc as h,oc as C,ra as u,sa as g,sd as de,vd as E,wb as Z,xc as ne,yb as K,yc as ie}from"./chunk-DUSKF5IQ.js";import{a as P,b}from"./chunk-NF7PG5F2.js";var B=class a{dialogRef=v(Te);toastrService=v(S);modalConfig;selectedOutlets=[];constructor(){this.modalConfig=new xe,this.modalConfig.title="Update ROP",this.modalConfig.customWidth="350px"}onOk(){if(this.selectedOutlets.length===0){this.toastrService.warning("Please select at least one outlet","Warning");return}this.dialogRef.close(this.selectedOutlets)}onClose(){this.dialogRef.close()}static \u0275fac=function(e){return new(e||a)};static \u0275cmp=L({type:a,selectors:[["app-modal-update-rop"]],decls:6,vars:3,consts:[[3,"onOk","onCancel","onClose","config"],[1,"container"],[1,"row"],[1,"col-12"],[3,"ngModelChange","ngModel","multiple"]],template:function(e,t){e&1&&(o(0,"modal-material",0),y("onOk",function(){return t.onOk()})("onCancel",function(){return t.onClose()})("onClose",function(){return t.onClose()}),o(1,"content")(2,"div",1)(3,"div",2)(4,"div",3)(5,"outlet-selector",4),C("ngModelChange",function(i){return h(t.selectedOutlets,i)||(t.selectedOutlets=i),i}),r()()()()()()),e&2&&(c("config",t.modalConfig),l(5),f("ngModel",t.selectedOutlets),c("multiple",!0))},dependencies:[E,Oe,A,U,N,W],encapsulation:2})};var z=(i=>(i[i.negative=0]="negative",i[i.empty=1]="empty",i[i.critical=2]="critical",i[i.optimal=3]="optimal",i[i.overstock=4]="overstock",i))(z||{});var Je=()=>[],Xe=a=>({ID:a});function Ze(a,m){if(a&1){let e=D();o(0,"button",7),y("click",function(){u(e);let n=s();return g(n.openExportModal())}),w(1,"i",8),d(2," Export "),r()}}function Ke(a,m){if(a&1){let e=D();o(0,"button",9),y("click",function(){u(e);let n=s();return g(n.onSubmitROP())}),w(1,"i",10),d(2," Save ROP "),r()}if(a&2){let e=s();c("matTooltip","Save ROP to Outlet "+e.outletSelected)}}function $e(a,m){if(a&1){let e=D();o(0,"h6"),d(1,"Show Inventory & Sales for Outlet"),r(),o(2,"outlet-selector",11),C("ngModelChange",function(n){u(e);let i=s();return h(i.pageData().Filter.ListIDs,n)||(i.pageData().Filter.ListIDs=n),g(n)}),r(),o(3,"h6"),d(4,"Category"),r(),o(5,"POS-product-category-select",12),C("selectedCategoryIDChange",function(n){u(e);let i=s();return h(i.pageData().Filter.CategoryID,n)||(i.pageData().Filter.CategoryID=n),g(n)}),r(),o(6,"h6"),d(7," Product Sold Within Days "),w(8,"i",13),r(),o(9,"input",14),C("ngModelChange",function(n){u(e);let i=s();return h(i.pageData().Filter.NumberOfDays,n)||(i.pageData().Filter.NumberOfDays=n),g(n)}),r(),o(10,"h6"),d(11,"Inventory Threshold"),r(),o(12,"div",15)(13,"div",16)(14,"input",17),C("ngModelChange",function(n){u(e);let i=s();return h(i.pageData().Filter.CriticalDaysThreshold,n)||(i.pageData().Filter.CriticalDaysThreshold=n),g(n)}),y("ngModelChange",function(n){u(e);let i=s();return g(i.onCriticalChange(n))}),r(),o(15,"div",18)(16,"div",19),w(17,"div",20)(18,"div",21)(19,"div",22),r(),o(20,"div",23)(21,"span"),d(22),r(),o(23,"span"),d(24),r(),o(25,"span"),d(26),r()()(),o(27,"input",24),C("ngModelChange",function(n){u(e);let i=s();return h(i.pageData().Filter.OverstockDaysThreshold,n)||(i.pageData().Filter.OverstockDaysThreshold=n),g(n)}),y("ngModelChange",function(n){u(e);let i=s();return g(i.onOverstockChange(n))}),r()()(),o(28,"h6"),d(29,"Days Of Risk"),r(),o(30,"ng-select",25),C("ngModelChange",function(n){u(e);let i=s();return h(i.pageData().Filter.DaysOfRisk,n)||(i.pageData().Filter.DaysOfRisk=n),g(n)}),r(),o(31,"h6"),d(32,"Set ROP for Outlet"),r(),o(33,"outlet-selector",26),C("ngModelChange",function(n){u(e);let i=s();return h(i.pageData().Filter.TargetOutlet,n)||(i.pageData().Filter.TargetOutlet=n),g(n)}),y("onListOutlets",function(n){u(e);let i=s();return g(i.getOutlets(n))}),r(),o(34,"h6"),d(35,"Count Indirect Allocated"),r(),o(36,"radio-options",27),C("modelChange",function(n){u(e);let i=s();return h(i.pageData().Filter.CalculateIndirectAllocated,n)||(i.pageData().Filter.CalculateIndirectAllocated=n),g(n)}),r()}if(a&2){let e,t=s();l(2),c("multiple",!0)("accessType",2),f("ngModel",t.pageData().Filter.ListIDs),l(3),f("selectedCategoryID",t.pageData().Filter.CategoryID),c("showClear",!0),l(4),f("ngModel",t.pageData().Filter.NumberOfDays),l(5),f("ngModel",t.pageData().Filter.CriticalDaysThreshold),l(8),x("\u2264",t.pageData().Filter.CriticalDaysThreshold," Days"),l(2),te("",t.pageData().Filter.CriticalDaysThreshold+1,"-",t.pageData().Filter.OverstockDaysThreshold," Days"),l(2),x(">",t.pageData().Filter.OverstockDaysThreshold," Days"),l(),f("ngModel",t.pageData().Filter.OverstockDaysThreshold),l(3),c("items",((e=t.pageData().Options)==null?null:e.DaysOfRisks)||ne(19,Je))("clearable",!0),f("ngModel",t.pageData().Filter.DaysOfRisk),l(3),c("multiple",!1)("accessType",2),f("ngModel",t.pageData().Filter.TargetOutlet),l(3),f("model",t.pageData().Filter.CalculateIndirectAllocated)}}function et(a,m){a&1&&(o(0,"th",43),d(1," LT "),r())}function tt(a,m){if(a&1&&(o(0,"th",44),d(1," ROP "),r()),a&2){let e=s(2);c("matTooltip","Based on "+e.outletSelected+" ROP")}}function nt(a,m){if(a&1){let e=D();o(0,"td",46)(1,"input",47),C("ngModelChange",function(n){u(e);let i=s().$implicit;return h(i.LeadTime,n)||(i.LeadTime=n),g(n)}),y("ngModelChange",function(n){u(e);let i=s().$implicit,p=s(2);return g(p.onInputLeadTime(n,i))}),r()()}if(a&2){let e=s(),t=e.$implicit,n=e.index;l(),c("name","LeadTime"+n),f("ngModel",t.LeadTime),c("id","leadTime"+n)}}function it(a,m){if(a&1){let e=D();o(0,"div",49)(1,"div",50)(2,"span",51),d(3),T(4,"number"),r(),w(5,"i",52),o(6,"div",53)(7,"input",54),T(8,"quantityFraction"),y("ngModelChange",function(n){u(e);let i=s(2).$implicit,p=s(2);return g(p.onInputROP(n,i))}),r()()()()}if(a&2){let e=s(2),t=e.$implicit,n=e.index,i=s(2);l(3),x(" ",R(4,5,i.getOriginalROP(t))," "),l(4),c("decimalPlaces",i.ropDecimalPlaces)("name","ROP"+n)("ngModel",R(8,7,t.ROP))("id","ROP"+n)}}function at(a,m){if(a&1&&(o(0,"span",46),d(1),T(2,"number"),r()),a&2){let e=s(2).$implicit;l(),x(" ",R(2,1,e.ROP)," ")}}function ot(a,m){if(a&1&&(o(0,"td",46),O(1,it,9,9,"div",48)(2,at,3,3,"span",41),r()),a&2){let e=s().$implicit;l(),c("ngIf",e.LeadTime),l(),c("ngIf",!e.LeadTime)}}function rt(a,m){if(a&1&&(o(0,"tr")(1,"td")(2,"a",45),d(3),r()(),o(4,"td"),d(5),r(),o(6,"td",46),d(7),T(8,"quantityFraction"),r(),o(9,"td",46),d(10),T(11,"number"),r(),o(12,"td",46),d(13),T(14,"number"),r(),o(15,"td",46)(16,"div"),d(17),r()(),O(18,nt,2,3,"td",41)(19,ot,3,2,"td",41),r()),a&2){let e=m.$implicit,t=s(2);l(2),c("queryParams",ie(27,Xe,e.ID)),l(),x(" ",e.Name," "),l(2),ee(e.Code),l(2),x(" ",R(8,19,e.Available)," "),l(3),x(" ",H(11,21,e.QtySoldPerDay,"1.0-2")," "),l(3),x(" ",e.QtySoldPerDay<0?"-":H(14,24,e.DaysOf,"1.0-0")," "),l(3),$("text-negative",e.DaysOfRiskType===t.riskType.negative)("text-empty",e.DaysOfRiskType===t.riskType.empty)("text-critical",e.DaysOfRiskType===t.riskType.critical)("text-optimal",e.DaysOfRiskType===t.riskType.optimal)("text-overstock",e.DaysOfRiskType===t.riskType.overstock),l(),x(" ",e.DaysOfRisk," "),l(),c("ngIf",t.pageData().Filter.TargetOutlet),l(),c("ngIf",t.pageData().Filter.TargetOutlet)}}function lt(a,m){a&1&&(o(0,"td",46)(1,"span"),d(2,"Bulk Lead Time "),r()())}function st(a,m){if(a&1){let e=D();o(0,"td")(1,"input",55),y("ngModelChange",function(n){u(e);let i=s(2);return g(i.onBulkUpdateLT(n))}),r()()}if(a&2){let e=s(2);l(),c("ngModel",e.bulkUpdateLTValue())("id","LT")}}function pt(a,m){if(a&1){let e=D();o(0,"div",28)(1,"div",29)(2,"table",30),y("matSortChange",function(n){u(e);let i=s();return g(i.sortData(n))}),o(3,"thead",31)(4,"tr")(5,"th",32),d(6,"Product"),r(),o(7,"th",33),d(8,"Code"),r(),o(9,"th",34),d(10," Available "),r(),o(11,"th",35),d(12," SOLD/DAY "),r(),o(13,"th",36),d(14," Days Of "),r(),o(15,"th",37),d(16," Risk "),r(),O(17,et,2,0,"th",38)(18,tt,2,1,"th",39),r()(),o(19,"tbody"),O(20,rt,20,29,"tr",40),r(),o(21,"tfoot")(22,"tr"),w(23,"td")(24,"td")(25,"td")(26,"td")(27,"td"),O(28,lt,3,0,"td",41),Z(29,st,2,2,"td"),r()()()(),o(30,"div")(31,"POS-complex-pagination",42),y("jumpToPage",function(){u(e);let n=s();return g(n.getListData())})("previousPage",function(){u(e);let n=s();return g(n.getListData())})("nextPage",function(){u(e);let n=s();return g(n.getListData())}),C("reloadRowCountChange",function(n){u(e);let i=s();return h(i.reloadRowCount,n)||(i.reloadRowCount=n),g(n)}),r()()()}if(a&2){let e,t=s();l(11),c("matTooltip","Based on Last "+t.pageData().Filter.NumberOfDays+" Days Sold"),l(6),c("ngIf",t.pageData().Filter.TargetOutlet),l(),c("ngIf",t.pageData().Filter.TargetOutlet),l(2),c("ngForOf",t.data().Data),l(8),c("ngIf",t.pageData().Filter.TargetOutlet&&t.data().Data.length>0),l(),K(t.pageData().Filter.TargetOutlet&&t.data().Data.length>0?29:-1),l(2),c("total",t.data().Data.length)("totalAllData",(e=t.data())==null?null:e.ListTotal)("pageData",t.pageData()),f("reloadRowCount",t.reloadRowCount)}}var He=class a extends we{constructor(e,t,n,i,p,_){super(e,t,"Inventory/DayOf","InventoryLoader/DaysOf",void 0,_,!0);this.httpService=t;this.csvConverter=i;this.roleService=p}httpService;csvConverter;roleService;dialog=v(Ie);fractionData=v(Ce);locale=v(oe);riskType=z;get ropDecimalPlaces(){return this.fractionData.quantity.maximumFraction}formatQuantityFraction(e){let t=`1.${this.fractionData.quantity.minimumFraction}-${this.fractionData.quantity.maximumFraction}`;return se(e,this.locale,t)}ListUpdateROP=V([]);listOutlet=V([]);bulkUpdateLTValue=le("");toastr=v(S);originalROPValues=V(new Map);rawROPValues=V([]);subTotalROP=re(()=>this.ListUpdateROP()?this.ListUpdateROP().reduce((e,t)=>e+Number(t.Value),0).toFixed(3):0);postInit(e){this.rawROPValues.set(e.Data),this.ListUpdateROP.set([]),this.originalROPValues.set(new Map)}preInitList(){this.menuData().H="Days of Inventory"}onInputLeadTime(e,t){if(k.IsEmpty(e)||e===0){this.rawROPValues().find(F=>F.ID===t.ID)&&(t.LeadTime="",t.ROP=this.getOriginalROP(t)),this.data.set(b(P({},this.data()),{Data:[...this.data().Data]}));return}let n=this.originalROPValues();n.has(t.ID)||(n.set(t.ID,t.ROP),this.originalROPValues.set(new Map(n)));let i=this.fractionData.quantity.maximumFraction,p=e*t.QtySoldPerDay;t.ROP=parseFloat(p.toFixed(i)),this.ListUpdateROP.update(_=>[..._.filter(qe=>qe.Key!==t.ID),{Key:t.ID,Value:this.formatQuantityFraction(t.ROP)}])}onInputROP(e,t){if(e){let n=this.fractionData.quantity.maximumFraction,i=parseFloat(e.toFixed(n));t.ROP=i,this.ListUpdateROP.update(p=>[...p.filter(F=>F.Key!==t.ID),{Key:t.ID,Value:this.formatQuantityFraction(i)}])}}getOriginalROP(e){return this.originalROPValues().get(e.ID)||e.ROP}get outletSelected(){if(this.listOutlet().length>0&&this.pageData().Filter.TargetOutlet){let e=this.listOutlet().findIndex(t=>t.k===this.pageData().Filter.TargetOutlet);if(e!==-1)return this.listOutlet()[e].v}return""}getOutlets(e){console.log(e),this.listOutlet.set(e)}onSubmitROP(){let e={ListUpdateROP:[...this.ListUpdateROP()],EntityID:this.pageData().Filter.TargetOutlet};this.httpService.post(q.UpdateROP,e).pipe(je("response"),J(t=>{this.toastr.success("ROP has been updated successfully.","Success!"),this.originalROPValues.set(new Map),this.getListData(),this.ListUpdateROP.set([]),this.bulkUpdateLTValue.set("")})).subscribe()}resetOriginalROP(e){let t=this.originalROPValues();t.has(e.ID)&&(t.delete(e.ID),this.originalROPValues.set(new Map(t)))}updateRop(e,t){this.dialog.open(B).afterClosed().pipe(G(n=>k.IsNotEmpty(n)),Y(n=>{let i={VariantID:e.ID,ListEntityID:n,ROP:e.ROP};return this.httpService.post(q.UpdateROP,i)})).subscribe(()=>{this.clearInput(`leadTime${t}`),this.toastr.success("ROP has been updated successfully.","Success!"),this.getListData()})}clearInput(e){let t=document.getElementById(e);t&&(t.value="")}openExportModal(){this.dialog.open(Fe,{data:{title:"Days of Inventory",exportTypes:[{ID:"InventoryExport/GetDaysOfExport",Value:"Default",FileName:"Days of Inventory"}],filterExport:this.pageData().Filter,getAllDataLengthAPI:"Inventory/DayOfCount",pagination:!0}})}sortData(e){let t=[...this.data().Data];if(!e.active||e.direction===""){this.data.set(b(P({},this.data()),{Data:[...t]}));return}let n=t.sort((i,p)=>{let _=e.direction==="asc";switch(e.active){case"Name":return I(i.Name,p.Name,_);case"Code":return I(i.Code,p.Code,_);case"QtySold":return I(i.QtySold,p.QtySold,_);case"QtySoldPerDay":return I(i.QtySoldPerDay,p.QtySoldPerDay,_);case"OnHand":return I(i.OnHand,p.OnHand,_);case"Available":return I(i.Available,p.Available,_);case"DaysOf":return I(i.DaysOf,p.DaysOf,_);default:return 0}});this.data.set(b(P({},this.data()),{Data:[...n]}))}onBulkUpdateLT(e){let t=this.originalROPValues(),n=this.rawROPValues();if(k.IsEmpty(e)){this.bulkUpdateLTValue.set(""),this.data.set(b(P({},this.data()),{Data:n.map(p=>b(P({},p),{LeadTime:null}))}));return}let i=+e;if(this.bulkUpdateLTValue.set(i),!!this.data()?.Data){for(let p of this.data().Data)t.has(p.ID)||t.set(p.ID,p.ROP),p.LeadTime=i,p.ROP=i*(p.QtySoldPerDay||0);this.originalROPValues.set(new Map(t)),this.ListUpdateROP.set(this.data().Data.map(p=>({Key:p.ID,Value:this.formatQuantityFraction(p.ROP)}))),this.data.set(b(P({},this.data()),{Data:[...this.data().Data]}))}}onCriticalChange(e){let t=this.pageData().Filter.ExceedDaysThreshold;e>=t&&(this.pageData().Filter.ExceedDaysThreshold=e+1)}onOverstockChange(e){let t=this.pageData().Filter.CriticalDaysThreshold;e<=t&&(this.pageData().Filter.ExceedDaysThreshold=t+1)}static \u0275fac=function(t){return new(t||a)(M(Ee),M(_e),M(S),M(ke),M(he),M(me))};static \u0275cmp=L({type:a,selectors:[["app-days-of-inventory"]],inputs:{bulkUpdateLTValue:[1,"bulkUpdateLTValue"]},outputs:{bulkUpdateLTValue:"bulkUpdateLTValueChange"},features:[X],decls:9,vars:6,consts:[["pageFilterTemplate",""],[3,"onSubmit","textChange","pageData","text","isFilterOnDropdown"],["ngProjectAs","actions",5,["actions"]],["class","btn btn-outline-secondary me-2",3,"click",4,"ngIf"],["class","btn btn-outline-secondary","role","button",3,"matTooltip","click",4,"ngIf"],["ngProjectAs","filters",5,["filters"]],["class","container-fluid mt-5",4,"ngIf"],[1,"btn","btn-outline-secondary","me-2",3,"click"],["aria-hidden","true",1,"fa-solid","fa-upload"],["role","button",1,"btn","btn-outline-secondary",3,"click","matTooltip"],[1,"fa-solid","fa-save","me-3"],["placeholder","Choose Outlets",1,"ng-select-multiple",3,"ngModelChange","multiple","accessType","ngModel"],[1,"tree-select-as-filter",3,"selectedCategoryIDChange","selectedCategoryID","showClear"],["matTooltip","Number of past days used to calculate average daily sales for inventory planning","matTooltipPosition","above",1,"fa-light","fa-circle-info",2,"cursor","pointer"],["autoNum","","min","1",1,"form-control",3,"ngModelChange","ngModel"],[1,"threshold-compact-wrapper"],[1,"threshold-row"],["type","text","autoNum","","min","1",1,"threshold-input-mini","input-critical",3,"ngModelChange","ngModel"],[1,"threshold-bar-container"],[1,"threshold-bar"],["matTooltip","Critical","matTooltipPosition","above",1,"bar-segment","seg-critical"],["matTooltip","Optimal","matTooltipPosition","above",1,"bar-segment","seg-optimal"],["matTooltip","Overstock","matTooltipPosition","above",1,"bar-segment","seg-overstock"],[1,"threshold-bar-labels"],["type","text","autoNum","","min","1",1,"threshold-input-mini","input-overstock",3,"ngModelChange","ngModel"],["bindLabel","Value","bindValue","Key","placeholder","All",1,"ng-select",3,"ngModelChange","items","clearable","ngModel"],["placeholder","Choose Outlet",1,"ng-select-multiple",3,"ngModelChange","onListOutlets","multiple","accessType","ngModel"],["name","IndirectAllocated",3,"modelChange","model"],[1,"container-fluid","mt-5"],[1,"table-responsive"],["matSort","",1,"table","custom-table","mt-5",3,"matSortChange"],[1,"thead-light","sticky-top-thead"],["mat-sort-header","Name"],["mat-sort-header","Code",2,"width","125px"],["mat-sort-header","Available","matTooltip","Inventory available for sale","arrowPosition","before",1,"text-end",2,"width","100px"],["mat-sort-header","QtySoldPerDay","arrowPosition","before",1,"text-end",2,"width","100px",3,"matTooltip"],["mat-sort-header","DaysOf","arrowPosition","before","matTooltip","How many days left until you run out of inventory",1,"text-end",2,"width","100px"],["mat-sort-header","DaysOfRisk","arrowPosition","before",1,"text-end",2,"width","120px"],["style","width: 80px","matTooltip","The LEAD TIME (in days) it takes to receive the inventory after placing an order","class","text-end",4,"ngIf"],["class","text-end","style","width: 120px",3,"matTooltip",4,"ngIf"],[4,"ngFor","ngForOf"],["class","text-end",4,"ngIf"],["api","Inventory/DayOfCount",3,"jumpToPage","previousPage","nextPage","reloadRowCountChange","total","totalAllData","pageData","reloadRowCount"],["matTooltip","The LEAD TIME (in days) it takes to receive the inventory after placing an order",1,"text-end",2,"width","80px"],[1,"text-end",2,"width","120px",3,"matTooltip"],["routerLink","/menu/Products/Catalog/Variants/Info","target","_blank",3,"queryParams"],[1,"text-end"],["autoNum","","type","text",1,"form-control","text-end",3,"ngModelChange","name","ngModel","id"],["class","rop-comparison",4,"ngIf"],[1,"rop-comparison"],[1,"d-flex","align-items-center","justify-content-end","gap-2"],[1,"old-value"],[1,"fa-solid","fa-arrow-right","text-muted"],[1,"input-group","input-group-sm",2,"width","70px"],["autoNum","","type","text",1,"form-control","text-end",3,"ngModelChange","decimalPlaces","name","ngModel","id"],["autoNum","","type","text",1,"form-control","text-end",3,"ngModelChange","ngModel","id"]],template:function(t,n){if(t&1){let i=D();o(0,"mainpanel-cmp",1),y("onSubmit",function(){return n.getListData()}),C("textChange",function(_){return u(i),h(n.pageData().Filter.FilterText,_)||(n.pageData().Filter.FilterText=_),g(_)}),Q(1,2),O(2,Ze,3,0,"button",3)(3,Ke,3,1,"button",4),j(),Q(4,5),O(5,$e,37,20,"ng-template",null,0,ae),j(),o(7,"content"),O(8,pt,32,10,"div",6),r()()}t&2&&(c("pageData",n.menuData()),f("text",n.pageData().Filter.FilterText),c("isFilterOnDropdown",!1),l(2),c("ngIf",n.roleService.global.Export),l(),c("ngIf",n.ListUpdateROP().length>0),l(5),c("ngIf",n.data()))},dependencies:[E,pe,ce,We,Ne,Re,U,ye,N,W,A,ge,ue,Qe,Be,Ae,ve,De,fe,Me,Pe,be,Ue,Ve,Se,de,Le],styles:[".threshold-compact-wrapper[_ngcontent-%COMP%]{background:#f8f9fa;border-radius:8px;padding:.6rem .75rem;margin:.25rem 0 1rem;border:1px solid #e9ecef}.threshold-compact-wrapper[_ngcontent-%COMP%] .threshold-row[_ngcontent-%COMP%]{display:flex;align-items:center;gap:.6rem}.threshold-compact-wrapper[_ngcontent-%COMP%] .threshold-input-mini[_ngcontent-%COMP%]{width:48px;text-align:center;font-size:.75rem;font-weight:600;border-radius:6px;border:1.5px solid #e5e7eb;padding:.3rem .15rem;background:#fff;color:#374151;flex-shrink:0;transition:all .15s ease}.threshold-compact-wrapper[_ngcontent-%COMP%] .threshold-input-mini[_ngcontent-%COMP%]:focus{outline:none}.threshold-compact-wrapper[_ngcontent-%COMP%] .threshold-input-mini.input-critical[_ngcontent-%COMP%]{border-color:#f5f0a6}.threshold-compact-wrapper[_ngcontent-%COMP%] .threshold-input-mini.input-critical[_ngcontent-%COMP%]:focus{border-color:#fff44f;box-shadow:0 0 0 2px #fff44f1f}.threshold-compact-wrapper[_ngcontent-%COMP%] .threshold-input-mini.input-overstock[_ngcontent-%COMP%]{border-color:#96b0f7}.threshold-compact-wrapper[_ngcontent-%COMP%] .threshold-input-mini.input-overstock[_ngcontent-%COMP%]:focus{border-color:#3581d8;box-shadow:0 0 0 2px #3581d81f}.threshold-compact-wrapper[_ngcontent-%COMP%] .threshold-bar-container[_ngcontent-%COMP%]{flex:1;display:flex;flex-direction:column;gap:.25rem;min-width:0}.threshold-compact-wrapper[_ngcontent-%COMP%] .threshold-bar[_ngcontent-%COMP%]{display:flex;height:10px;border-radius:5px;overflow:hidden;box-shadow:inset 0 1px 2px #00000014}.threshold-compact-wrapper[_ngcontent-%COMP%] .threshold-bar[_ngcontent-%COMP%] .bar-segment[_ngcontent-%COMP%]{flex:1;transition:background .3s ease;cursor:pointer}.threshold-compact-wrapper[_ngcontent-%COMP%] .threshold-bar[_ngcontent-%COMP%] .bar-segment.seg-critical[_ngcontent-%COMP%]{background:#fff44f}.threshold-compact-wrapper[_ngcontent-%COMP%] .threshold-bar[_ngcontent-%COMP%] .bar-segment.seg-critical[_ngcontent-%COMP%]:hover{background:#f7e817}.threshold-compact-wrapper[_ngcontent-%COMP%] .threshold-bar[_ngcontent-%COMP%] .bar-segment.seg-optimal[_ngcontent-%COMP%]{background:#28cc2d}.threshold-compact-wrapper[_ngcontent-%COMP%] .threshold-bar[_ngcontent-%COMP%] .bar-segment.seg-optimal[_ngcontent-%COMP%]:hover{background:#388e3c}.threshold-compact-wrapper[_ngcontent-%COMP%] .threshold-bar[_ngcontent-%COMP%] .bar-segment.seg-overstock[_ngcontent-%COMP%]{background:#3581d8}.threshold-compact-wrapper[_ngcontent-%COMP%] .threshold-bar[_ngcontent-%COMP%] .bar-segment.seg-overstock[_ngcontent-%COMP%]:hover{background:#2c58af}.threshold-compact-wrapper[_ngcontent-%COMP%] .threshold-bar-labels[_ngcontent-%COMP%]{display:flex;justify-content:space-between;font-size:.55rem;font-weight:500;color:#9ca3af;padding:0 2px}.threshold-compact-wrapper[_ngcontent-%COMP%] .threshold-bar-labels[_ngcontent-%COMP%] span[_ngcontent-%COMP%]:nth-child(1){color:#a39800}.threshold-compact-wrapper[_ngcontent-%COMP%] .threshold-bar-labels[_ngcontent-%COMP%] span[_ngcontent-%COMP%]:nth-child(2){color:#28cc2d}.threshold-compact-wrapper[_ngcontent-%COMP%] .threshold-bar-labels[_ngcontent-%COMP%] span[_ngcontent-%COMP%]:nth-child(3){color:#3581d8}.text-negative[_ngcontent-%COMP%]{color:#a61b29}.text-empty[_ngcontent-%COMP%]{color:#d82e3f}.text-critical[_ngcontent-%COMP%]{color:#e8c73a}.text-optimal[_ngcontent-%COMP%]{color:#28cc2d}.text-overstock[_ngcontent-%COMP%]{color:#3581d8}"],changeDetection:0})};function I(a,m,e){return a===null||a===""?e?-1:1:m===null||m===""?e?1:-1:typeof a=="string"&&typeof m=="string"?a.localeCompare(m)*(e?1:-1):typeof a=="number"&&typeof m=="number"?(a<m?-1:1)*(e?1:-1):typeof a=="string"&&typeof m=="number"?e?-1:1:typeof a=="number"&&typeof m=="string"?e?1:-1:0}export{He as DaysOfInventoryComponent};
@@ -0,0 +1 @@
1
+ import{a as w}from"./chunk-VB77KJKE.js";import{a as h}from"./chunk-TUL4SCIV.js";import{a as M}from"./chunk-KGAHREO6.js";import{a as v}from"./chunk-3X7WTMVL.js";import{a as b}from"./chunk-UWUSG6X7.js";import{a as _}from"./chunk-L2AMDQ4D.js";import"./chunk-FBXWSJGZ.js";import"./chunk-2PUGC5XR.js";import"./chunk-TDI2ZUL6.js";import"./chunk-CKHJNQTW.js";import"./chunk-CNBTTBK3.js";import"./chunk-CCLE2IVS.js";import"./chunk-BF42EMHQ.js";import"./chunk-EUIKMR24.js";import"./chunk-7VXCKSAE.js";import"./chunk-KFWGALIF.js";import"./chunk-Z7UCI72M.js";import"./chunk-PPMQE2JW.js";import"./chunk-ULWLSYED.js";import"./chunk-DU6XSMWH.js";import"./chunk-RJDDPGUV.js";import"./chunk-VUC4E73K.js";import"./chunk-OTSIIVCA.js";import"./chunk-QSBTT5BF.js";import"./chunk-IX2NXO5F.js";import"./chunk-ZRB4EZI3.js";import"./chunk-3MLD6BQG.js";import"./chunk-LUUIBDJG.js";import"./chunk-R7VXUOCU.js";import"./chunk-NYN3E7NN.js";import{E as D,h as S,o as C}from"./chunk-R36OIJC7.js";import"./chunk-AGPZGAMV.js";import"./chunk-PPTZHIIZ.js";import"./chunk-ETYXTCKV.js";import{Db as o,Eb as n,Fb as a,Nd as y,Oc as u,Ua as i,db as c,hc as s,mc as r,na as g,nc as l,oc as d}from"./chunk-DUSKF5IQ.js";import"./chunk-NF7PG5F2.js";var A=class f{activatedRoute=g(y);settings=g(_);formData=u(()=>this.settings.formData());options=u(()=>this.settings.options());configDefault=u(()=>this.settings.configDefault());constructor(){this.settings.initFormData(this.activatedRoute)}static \u0275fac=function(m){return new(m||f)};static \u0275cmp=c({type:f,selectors:[["POS-adjustment"]],decls:28,vars:36,consts:[["cardTitle","Basic","id","basicAdjustment"],[1,"row"],[1,"col-12"],["keyLabel","Value","keyValue","Key",3,"ngModelChange","label","description","options","defaultConfig","ngModel","tooltipKey"],["cardTitle","Stock Take by CSV","id","stockTakeByCsvAdjustment"],[3,"ngModelChange","label","description","defaultConfig","ngModel"],["cardTitle","Advance","id","advanceAdjustment",3,"description"],["bindLabel","Value","bindValue","Key",3,"ngModelChange","label","options","ngModel","isHorizontalLayout","description"],["cardTitle","Digital Scale","id","digitalScaleAdjustment",3,"description"],[3,"ngModelChange","label","type","ngModel","isHorizontalLayout","description"],[1,"col-6"],[3,"ngModelChange","label","tooltip","type","ngModel"],[1,"text-end"],["href","https://support.dealpos.com/en/articles/4773806-how-to-set-up-digital-scale","target","_blank"]],template:function(m,e){m&1&&(n(0,"POS-card",0)(1,"div",1)(2,"div",2)(3,"POS-button-group",3),d("ngModelChange",function(t){return l(e.formData().Basic.Workflow,t)||(e.formData().Basic.Workflow=t),t}),a()()()(),n(4,"POS-card",4)(5,"div",1)(6,"div",2)(7,"POS-input-toggle",5),d("ngModelChange",function(t){return l(e.formData().StocktakeByCSV.ExportOrderedVisible,t)||(e.formData().StocktakeByCSV.ExportOrderedVisible=t),t}),a()()()(),n(8,"POS-card",6)(9,"div",1)(10,"div",2)(11,"POS-button-group",3),d("ngModelChange",function(t){return l(e.formData().Advance.AdjustmentInputType,t)||(e.formData().Advance.AdjustmentInputType=t),t}),a()(),n(12,"div",2)(13,"POS-input-select",7),d("ngModelChange",function(t){return l(e.formData().Advance.NumberFilterComparator,t)||(e.formData().Advance.NumberFilterComparator=t),t}),a()()()(),n(14,"POS-card",8)(15,"div",1)(16,"div",2)(17,"POS-input-field",9),d("ngModelChange",function(t){return l(e.formData().DigitalScale.Regex,t)||(e.formData().DigitalScale.Regex=t),t}),a()(),n(18,"div",10)(19,"POS-input-field",11),d("ngModelChange",function(t){return l(e.formData().DigitalScale.Digit,t)||(e.formData().DigitalScale.Digit=t),t}),a()(),n(20,"div",10)(21,"POS-input-field",11),d("ngModelChange",function(t){return l(e.formData().DigitalScale.QuantityDivider,t)||(e.formData().DigitalScale.QuantityDivider=t),t}),a()(),n(22,"div",12)(23,"i"),s(24," *Please refer this "),n(25,"a",13),s(26,"Article"),a(),s(27," for more information"),a()()()()),m&2&&(i(3),o("label","WorkFlow")("description","Step for doing adjustment")("options",e.options().AdjustmentWorkflow)("defaultConfig",e.configDefault().Basic.Workflow),r("ngModel",e.formData().Basic.Workflow),o("tooltipKey","Description"),i(4),o("label","Export Ordered Visible")("description","Show Colomn Ordered in CSV")("defaultConfig",e.configDefault().StocktakeByCSV.ExportOrderedVisible),r("ngModel",e.formData().StocktakeByCSV.ExportOrderedVisible),i(),o("description","Default"),i(3),o("label","Adjustment Input Type")("description","Environment to do adjustment from differences or overwrite")("options",e.options().AdjustmentTypes)("defaultConfig",e.configDefault().Advance.AdjustmentInputType),r("ngModel",e.formData().Advance.AdjustmentInputType),o("tooltipKey","Description"),i(2),o("label","Number Filter Comparator")("options",e.options().SearchComparatorTypeOption),r("ngModel",e.formData().Advance.NumberFilterComparator),o("isHorizontalLayout",!0)("description","Configure default value for number filter comparator."),i(),o("description","Connection Digital scale with POS"),i(3),o("label","Regex")("type","text"),r("ngModel",e.formData().DigitalScale.Regex),o("isHorizontalLayout",!0)("description","Configure the regular expression used for the digital scale input.."),i(2),o("label","Digit")("tooltip","Set digit for digital scalling")("type","number"),r("ngModel",e.formData().DigitalScale.Digit),i(2),o("label","Quantity Divider")("tooltip","Divider count for quantity")("type","number"),r("ngModel",e.formData().DigitalScale.QuantityDivider))},dependencies:[b,w,h,M,D,S,C,v],encapsulation:2})};export{A as AdjustmentComponent};
@@ -1 +1 @@
1
- import{a as S,b as n,c as g}from"./chunk-OKQYRKDJ.js";import{a as f}from"./chunk-ZX5GTIAE.js";import{a}from"./chunk-PPTZHIIZ.js";import{n as v}from"./chunk-ETYXTCKV.js";import{H as h,M as r,d as i,e as o,ja as u,k as l,m as c,ma as b,na as C}from"./chunk-DUSKF5IQ.js";var p=class s{constructor(e){this.toastr=e;this.socketConnection=new g().withUrl("/POSHub").withAutomaticReconnect().configureLogging(S.Information).build(),this.registerEventHandler(),this.connectivity.online$.subscribe(t=>{t&&this.socketConnection.state===n.Disconnected&&(console.log("Internet back online, reconnecting SignalR..."),this.startConnection())})}toastr;lastGroupID;OnPaymentReceived=new i;OnReceivePushNotification=new i;OnContactReceive=new i;OnPromotionEventChange=new i;_recacheOutlet=new o(!1);recacheOutlet$=this._recacheOutlet.asObservable();_recacheCategory=new o(!1);recacheCategory$=this._recacheCategory.asObservable();_recacheSalesPerson=new o(!1);recacheSalesPerson$=this._recacheSalesPerson.asObservable();socketConnection;connectionStateSubject=new i;connectivity=C(f);startConnection(){if(!this.connectivity.isOnline){console.warn("SignalR: Skipping connection, app is offline.");return}this.socketConnection.state==n.Disconnected&&this.socketConnection.start().then(()=>{console.info("SignalR Connected"),this.connectionStateSubject.next(!0)}).catch(e=>console.error("SignalR Start Error:",e))}SubscribeGroup(e,t=null){if(e!=this.lastGroupID){if(!this.connectivity.isOnline){console.warn("SignalR: Cannot subscribe group while offline.");return}this.socketConnection.state==n.Disconnected?(this.startConnection(),this.connectionStateSubject.pipe(r(1)).subscribe(()=>{this.invokeSubscribe(e,t)})):this.socketConnection.state==n.Connecting?this.connectionStateSubject.pipe(r(1)).subscribe(()=>{this.invokeSubscribe(e,t)}):this.socketConnection.state==n.Connected&&this.invokeSubscribe(e,t)}}invokeSubscribe(e,t){let k={CurrentID:e,PreviousID:t};this.socketConnection.invoke("SubscribeGroup",k).then(()=>{console.info(`SignalR Subscribed to Group: [${e}]`),this.lastGroupID=e}).catch(m=>{console.error(m)})}registerEventHandler(){this.socketConnection.on("ReceiveMobilePaymentSignal",e=>{this.OnPaymentReceived.next(e)}),this.socketConnection.on("OnContactReceive",e=>{this.OnContactReceive.next(e)}),this.socketConnection.on("ReceiveNewPromotionSignal",e=>{this.OnPromotionEventChange.next(e)}),this.socketConnection.on("ReceivePushNotificationSignal",e=>{this.OnReceivePushNotification.next(e)}),this.socketConnection.on("ReceiveOutletChanges",()=>{this._recacheOutlet.next(!0)}),this.socketConnection.on("ReceiveProductCategoryChanges",()=>{this._recacheCategory.next(!0)}),this.socketConnection.on("ReceiveSalesPersonChanges",()=>{this._recacheSalesPerson.next(!0)})}isSocketConnected(){return a.IsEmpty(this.socketConnection)?!1:this.socketConnection.state==n.Connected&&a.IsNotEmpty(this.socketConnection.connectionId)}broadcast(e){return this.connectivity.isOnline?this.isSocketConnected()?l(this.socketConnection.invoke("BroadCast",e)).pipe(h(t=>(this.toastr.error(t,"Error"),c(()=>t)))):c(()=>"SignalR is not connected"):c(()=>"Anda sedang offline. Broadcast tidak dapat dikirim.")}resetOutletCache(){this._recacheOutlet.next(!1)}resetCategoryCache(){this._recacheCategory.next(!1)}resetSalesPersonCache(){this._recacheSalesPerson.next(!1)}static \u0275fac=function(t){return new(t||s)(b(v))};static \u0275prov=u({token:s,factory:s.\u0275fac,providedIn:"root"})};export{p as a};
1
+ import{a as S,b as n,c as g}from"./chunk-OKQYRKDJ.js";import{a as f}from"./chunk-IIARVTAV.js";import{a}from"./chunk-PPTZHIIZ.js";import{n as v}from"./chunk-ETYXTCKV.js";import{H as h,M as r,d as i,e as o,ja as u,k as l,m as c,ma as b,na as C}from"./chunk-DUSKF5IQ.js";var p=class s{constructor(e){this.toastr=e;this.socketConnection=new g().withUrl("/POSHub").withAutomaticReconnect().configureLogging(S.Information).build(),this.registerEventHandler(),this.connectivity.online$.subscribe(t=>{t&&this.socketConnection.state===n.Disconnected&&(console.log("Internet back online, reconnecting SignalR..."),this.startConnection())})}toastr;lastGroupID;OnPaymentReceived=new i;OnReceivePushNotification=new i;OnContactReceive=new i;OnPromotionEventChange=new i;_recacheOutlet=new o(!1);recacheOutlet$=this._recacheOutlet.asObservable();_recacheCategory=new o(!1);recacheCategory$=this._recacheCategory.asObservable();_recacheSalesPerson=new o(!1);recacheSalesPerson$=this._recacheSalesPerson.asObservable();socketConnection;connectionStateSubject=new i;connectivity=C(f);startConnection(){if(!this.connectivity.isOnline){console.warn("SignalR: Skipping connection, app is offline.");return}this.socketConnection.state==n.Disconnected&&this.socketConnection.start().then(()=>{console.info("SignalR Connected"),this.connectionStateSubject.next(!0)}).catch(e=>console.error("SignalR Start Error:",e))}SubscribeGroup(e,t=null){if(e!=this.lastGroupID){if(!this.connectivity.isOnline){console.warn("SignalR: Cannot subscribe group while offline.");return}this.socketConnection.state==n.Disconnected?(this.startConnection(),this.connectionStateSubject.pipe(r(1)).subscribe(()=>{this.invokeSubscribe(e,t)})):this.socketConnection.state==n.Connecting?this.connectionStateSubject.pipe(r(1)).subscribe(()=>{this.invokeSubscribe(e,t)}):this.socketConnection.state==n.Connected&&this.invokeSubscribe(e,t)}}invokeSubscribe(e,t){let k={CurrentID:e,PreviousID:t};this.socketConnection.invoke("SubscribeGroup",k).then(()=>{console.info(`SignalR Subscribed to Group: [${e}]`),this.lastGroupID=e}).catch(m=>{console.error(m)})}registerEventHandler(){this.socketConnection.on("ReceiveMobilePaymentSignal",e=>{this.OnPaymentReceived.next(e)}),this.socketConnection.on("OnContactReceive",e=>{this.OnContactReceive.next(e)}),this.socketConnection.on("ReceiveNewPromotionSignal",e=>{this.OnPromotionEventChange.next(e)}),this.socketConnection.on("ReceivePushNotificationSignal",e=>{this.OnReceivePushNotification.next(e)}),this.socketConnection.on("ReceiveOutletChanges",()=>{this._recacheOutlet.next(!0)}),this.socketConnection.on("ReceiveProductCategoryChanges",()=>{this._recacheCategory.next(!0)}),this.socketConnection.on("ReceiveSalesPersonChanges",()=>{this._recacheSalesPerson.next(!0)})}isSocketConnected(){return a.IsEmpty(this.socketConnection)?!1:this.socketConnection.state==n.Connected&&a.IsNotEmpty(this.socketConnection.connectionId)}broadcast(e){return this.connectivity.isOnline?this.isSocketConnected()?l(this.socketConnection.invoke("BroadCast",e)).pipe(h(t=>(this.toastr.error(t,"Error"),c(()=>t)))):c(()=>"SignalR is not connected"):c(()=>"Anda sedang offline. Broadcast tidak dapat dikirim.")}resetOutletCache(){this._recacheOutlet.next(!1)}resetCategoryCache(){this._recacheCategory.next(!1)}resetSalesPersonCache(){this._recacheSalesPerson.next(!1)}static \u0275fac=function(t){return new(t||s)(b(v))};static \u0275prov=u({token:s,factory:s.\u0275fac,providedIn:"root"})};export{p as a};