marketplacepos 5.48.6 → 5.50.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/Marketplace/3rdpartylicenses.txt +214 -214
- package/Marketplace/{chunk-SHUYFOQI.js → chunk-24KZDZKS.js} +1 -1
- package/Marketplace/{chunk-7JQEF4XX.js → chunk-27DIE2YS.js} +1 -1
- package/Marketplace/chunk-2AXBEVQ7.js +4 -0
- package/Marketplace/chunk-2K5AP6IZ.js +1 -0
- package/Marketplace/{chunk-4RG5YR7N.js → chunk-2NRHX6CZ.js} +2 -2
- package/Marketplace/{chunk-ZTHO6JJM.js → chunk-2ST3DMR6.js} +1 -1
- package/Marketplace/chunk-2UNT2DUM.js +1 -0
- package/Marketplace/chunk-34ZZ4GCS.js +1 -0
- package/Marketplace/{chunk-5X2E3W32.js → chunk-3HME327V.js} +1 -1
- package/Marketplace/chunk-3NAMEVOB.js +1 -0
- package/Marketplace/chunk-3PIHLKK3.js +1 -0
- package/Marketplace/{chunk-AFIF6VRM.js → chunk-3SCX7IMW.js} +1 -1
- package/Marketplace/chunk-44KIXUU2.js +1 -0
- package/Marketplace/chunk-4G46574H.js +1 -0
- package/Marketplace/chunk-4KGXKQPG.js +1 -0
- package/Marketplace/{chunk-QFSA7CU4.js → chunk-4S4BOPUV.js} +2 -2
- package/Marketplace/chunk-4YKPN3RV.js +1 -0
- package/Marketplace/chunk-52YCKO3Z.js +1 -0
- package/Marketplace/{chunk-5BSPSA4O.js → chunk-5C24BA5F.js} +1 -1
- package/Marketplace/{chunk-PMVDQ2OP.js → chunk-5QDH4ZNS.js} +1 -1
- package/Marketplace/{chunk-ZETUYNFJ.js → chunk-5UFP37GQ.js} +1 -1
- package/Marketplace/{chunk-PDCVMSLL.js → chunk-5WQ3LCWP.js} +1 -1
- package/Marketplace/chunk-5WT456T7.js +3 -0
- package/Marketplace/chunk-67LUKQJC.js +1 -0
- package/Marketplace/chunk-6C4UBIZK.js +10 -0
- package/Marketplace/{chunk-ZKIO2ZQ6.js → chunk-6F62N7RZ.js} +2 -2
- package/Marketplace/chunk-6GNIJWEX.js +1 -0
- package/Marketplace/chunk-6NS3D6KQ.js +5 -0
- package/Marketplace/{chunk-RQQWNLDZ.js → chunk-7HRL6MHY.js} +1 -1
- package/Marketplace/chunk-7QP3VZ6H.js +1 -0
- package/Marketplace/chunk-7R2D2JZ6.js +3 -0
- package/Marketplace/{chunk-5MV3UFJQ.js → chunk-7X4B2T6C.js} +2 -2
- package/Marketplace/chunk-A2RTZANN.js +1 -0
- package/Marketplace/chunk-A53NYS6S.js +1 -0
- package/Marketplace/chunk-AHMFSCTX.js +2 -0
- package/Marketplace/{chunk-LEUBNBGC.js → chunk-AJSJJV2I.js} +1 -1
- package/Marketplace/chunk-ALLZQ6Y3.js +1 -0
- package/Marketplace/chunk-AQVMOA6Z.js +1 -0
- package/Marketplace/chunk-B5ZK5TGW.js +1 -0
- package/Marketplace/chunk-BAW6PICI.js +2 -0
- package/Marketplace/{chunk-DTAHV4GM.js → chunk-BC6LHZWP.js} +1 -1
- package/Marketplace/{chunk-GPHNPV7O.js → chunk-BMOMTOEW.js} +2 -2
- package/Marketplace/chunk-BUMWMFHU.js +2 -0
- package/Marketplace/{chunk-OQM7K2EA.js → chunk-BXNDE6NQ.js} +1 -1
- package/Marketplace/chunk-BYL4N2KB.js +1 -0
- package/Marketplace/{chunk-6KWG6O5L.js → chunk-C2LAQOUW.js} +1 -1
- package/Marketplace/{chunk-L7WZ6U4T.js → chunk-DDFP4CNP.js} +1 -1
- package/Marketplace/{chunk-6OJQRHIZ.js → chunk-DLHIDOS3.js} +1 -1
- package/Marketplace/chunk-DPB2343S.js +1 -0
- package/Marketplace/chunk-E4RY2MK5.js +1 -0
- package/Marketplace/chunk-EGLM6YK5.js +1 -0
- package/Marketplace/{chunk-IM5M2CAI.js → chunk-EH3PIGLJ.js} +1 -1
- package/Marketplace/chunk-ENYJ4KAM.js +1 -0
- package/Marketplace/chunk-ESBL3IFN.js +1 -0
- package/Marketplace/{chunk-2J7P6ENI.js → chunk-F26O6FCO.js} +1 -1
- package/Marketplace/chunk-FEQXCPQI.js +2 -0
- package/Marketplace/chunk-FFJXYPVA.js +1 -0
- package/Marketplace/chunk-FLNIURLD.js +1 -0
- package/Marketplace/chunk-FMXX7QB5.js +5 -0
- package/Marketplace/chunk-FNOENLVR.js +2 -0
- package/Marketplace/{chunk-4ILDFTIG.js → chunk-FOKLBUX6.js} +1 -1
- package/Marketplace/chunk-FTIUJUXI.js +1 -0
- package/Marketplace/{chunk-WNUTNP6I.js → chunk-G3B6ETBU.js} +5 -5
- package/Marketplace/{chunk-VWX2IX64.js → chunk-G4T4VM5E.js} +1 -1
- package/Marketplace/chunk-GBF6A3MS.js +1 -0
- package/Marketplace/chunk-GDHNMHJZ.js +1 -0
- package/Marketplace/chunk-GG3X4R7G.js +1 -0
- package/Marketplace/chunk-GJC736LV.js +1 -0
- package/Marketplace/chunk-GVJLKDIO.js +1 -0
- package/Marketplace/chunk-H6YNHOUQ.js +1 -0
- package/Marketplace/chunk-HGVFXR6T.js +1 -0
- package/Marketplace/chunk-HJZ3XPSH.js +266 -0
- package/Marketplace/chunk-HNDBAXI5.js +1 -0
- package/Marketplace/{chunk-N5AE5WMQ.js → chunk-HO2TMGLM.js} +1 -1
- package/Marketplace/chunk-HORS2MKK.js +1 -0
- package/Marketplace/chunk-IDGK6BMG.js +1 -0
- package/Marketplace/chunk-IF7EJSQG.js +1 -0
- package/Marketplace/chunk-IIJEILDV.js +1 -0
- package/Marketplace/{chunk-3L7Y6LG6.js → chunk-IM7YH54S.js} +1 -1
- package/Marketplace/chunk-IV5IPY6H.js +1 -0
- package/Marketplace/{chunk-63I3I3MX.js → chunk-IVKFEOCB.js} +1 -1
- package/Marketplace/chunk-J6HA4ZHH.js +1 -0
- package/Marketplace/chunk-JM3NLPH4.js +9 -0
- package/Marketplace/chunk-JNRCB7N3.js +2 -0
- package/Marketplace/chunk-JV4F6ZYF.js +1 -0
- package/Marketplace/chunk-JWDQVXQP.js +1 -0
- package/Marketplace/{chunk-3664K4KH.js → chunk-JYP3Z3TV.js} +19 -19
- package/Marketplace/chunk-JYSOUJ42.js +1 -0
- package/Marketplace/chunk-K5WSFDNA.js +1 -0
- package/Marketplace/chunk-KNBXCPTA.js +1 -0
- package/Marketplace/chunk-KR6UNAIL.js +3 -0
- package/Marketplace/chunk-KSRL7Y2J.js +2 -0
- package/Marketplace/{chunk-ODLI42YV.js → chunk-KTTKHI2N.js} +1 -1
- package/Marketplace/chunk-KUKTPGJ2.js +1 -0
- package/Marketplace/chunk-LKJCOEGO.js +1 -0
- package/Marketplace/chunk-LQ3VUWFK.js +2 -0
- package/Marketplace/chunk-LQPY6AYJ.js +1 -0
- package/Marketplace/{chunk-FULVA6QB.js → chunk-LR2YCE6M.js} +1 -1
- package/Marketplace/{chunk-DXYMG6QK.js → chunk-LUJ3SHSP.js} +1 -1
- package/Marketplace/chunk-LYN2PNQK.js +1 -0
- package/Marketplace/{chunk-J6CZKQ53.js → chunk-M3DUXHYE.js} +4 -4
- package/Marketplace/chunk-M7TUSCXB.js +1 -0
- package/Marketplace/{chunk-6PW6S7MI.js → chunk-MAQQQB3T.js} +1 -1
- package/Marketplace/chunk-MIGPO7BO.js +1 -0
- package/Marketplace/chunk-MM7SAZOU.js +1 -0
- package/Marketplace/{chunk-CM3B2UZ7.js → chunk-MPFJ7FBJ.js} +1 -1
- package/Marketplace/{chunk-SJ5MC42H.js → chunk-MT3CWRVG.js} +2 -2
- package/Marketplace/chunk-MTVUPPAN.js +149 -0
- package/Marketplace/chunk-MV2PLTWF.js +1 -0
- package/Marketplace/{chunk-WHHW4IZT.js → chunk-N3E43QWK.js} +2 -2
- package/Marketplace/{chunk-AFDI4TD4.js → chunk-NIJCYMZM.js} +3 -3
- package/Marketplace/chunk-NQLMPUSB.js +1 -0
- package/Marketplace/chunk-NTU64XT4.js +1 -0
- package/Marketplace/{chunk-3JRUKSV3.js → chunk-NVPT5BF2.js} +2 -2
- package/Marketplace/chunk-O3QPBAV5.js +7 -0
- package/Marketplace/chunk-O4D64GHO.js +2 -0
- package/Marketplace/{chunk-UH5C5HXK.js → chunk-O4U34AC7.js} +1 -1
- package/Marketplace/chunk-OCXIDX74.js +1 -0
- package/Marketplace/chunk-OGF4VFSK.js +1 -0
- package/Marketplace/chunk-OHGMB7HJ.js +4 -0
- package/Marketplace/chunk-OIWQSDTS.js +1 -0
- package/Marketplace/chunk-OSGPJXJZ.js +1 -0
- package/Marketplace/chunk-OVZRFDFO.js +1 -0
- package/Marketplace/chunk-P3XVM6DH.js +1 -0
- package/Marketplace/chunk-PBAFAOKJ.js +1 -0
- package/Marketplace/{chunk-IGKMJFKP.js → chunk-PN3KM4M4.js} +2 -2
- package/Marketplace/{chunk-L76NLJD7.js → chunk-PWOKOWVV.js} +2 -2
- package/Marketplace/chunk-QJCYEP2A.js +1 -0
- package/Marketplace/{chunk-4RLWHMI6.js → chunk-QMHG3QTI.js} +1 -1
- package/Marketplace/chunk-QMIL5QUX.js +1 -0
- package/Marketplace/chunk-QOSWDELZ.js +1 -0
- package/Marketplace/chunk-QQF5ZMGS.js +2 -0
- package/Marketplace/{chunk-6XDT56RT.js → chunk-R3WIWDSP.js} +2 -2
- package/Marketplace/{chunk-LOWGZOML.js → chunk-RBZU7OVM.js} +1 -1
- package/Marketplace/chunk-RFWRWMRC.js +1 -0
- package/Marketplace/chunk-RHMSGY7X.js +1 -0
- package/Marketplace/chunk-RM6ZXD3O.js +1 -0
- package/Marketplace/chunk-RN5CI3LE.js +1 -0
- package/Marketplace/chunk-ROS2QMKF.js +1 -0
- package/Marketplace/{chunk-YTHY4IFS.js → chunk-RQUCYFCB.js} +1 -1
- package/Marketplace/chunk-RUYX7KTP.js +1 -0
- package/Marketplace/{chunk-L22SKCLL.js → chunk-RWPLFNHT.js} +1 -1
- package/Marketplace/{chunk-5PMKN6PM.js → chunk-RXC5D64C.js} +2 -2
- package/Marketplace/chunk-RZ5N5JLA.js +1 -0
- package/Marketplace/chunk-S5D64XYA.js +1 -0
- package/Marketplace/chunk-S5XYWXXP.js +1 -0
- package/Marketplace/chunk-SABMHH6B.js +1 -0
- package/Marketplace/{chunk-TXOZULMZ.js → chunk-SIPZP62B.js} +1 -1
- package/Marketplace/{chunk-6CM22SKR.js → chunk-SMZOSLIK.js} +1 -1
- package/Marketplace/chunk-SN5AD4QE.js +1 -0
- package/Marketplace/chunk-SPLGZRGH.js +5 -0
- package/Marketplace/chunk-TBVMCNS2.js +1 -0
- package/Marketplace/{chunk-3WRXJBHF.js → chunk-TDMNVEUU.js} +3 -3
- package/Marketplace/chunk-TDP3PQDA.js +1 -0
- package/Marketplace/{chunk-RUBV3KX2.js → chunk-TKZ74HJD.js} +1 -1
- package/Marketplace/chunk-TMBZ4K5S.js +1 -0
- package/Marketplace/chunk-TOK5EWN4.js +1 -0
- package/Marketplace/chunk-TYNQDFOT.js +5 -0
- package/Marketplace/{chunk-7GY4O2UX.js → chunk-TYQYNICX.js} +3 -3
- package/Marketplace/{chunk-VX75I7HA.js → chunk-TZTW72NT.js} +1 -1
- package/Marketplace/chunk-U5DJYZUI.js +1 -0
- package/Marketplace/{chunk-AZOCRKXK.js → chunk-UB62TZOI.js} +1 -1
- package/Marketplace/chunk-UE5E7JXK.js +1 -0
- package/Marketplace/chunk-UMLV2ZUF.js +1 -0
- package/Marketplace/{chunk-DUXKDRDP.js → chunk-UMMQ62IZ.js} +1 -1
- package/Marketplace/{chunk-JBEKD57G.js → chunk-UPRDDI4K.js} +1 -1
- package/Marketplace/{chunk-MDP2SGJI.js → chunk-V6QH3IVL.js} +1 -1
- package/Marketplace/chunk-VH7JZJ2B.js +1 -0
- package/Marketplace/chunk-VOONKP66.js +1 -0
- package/Marketplace/chunk-VP3XO25X.js +2 -0
- package/Marketplace/{chunk-KTLMPVSK.js → chunk-VV4G5VL5.js} +1 -1
- package/Marketplace/chunk-VVAEM355.js +1 -0
- package/Marketplace/chunk-VZ7Q4WN7.js +1 -0
- package/Marketplace/{chunk-NWB7EVME.js → chunk-W33M7S2S.js} +1 -1
- package/Marketplace/{chunk-L3W6SG2T.js → chunk-WAXAIL2I.js} +1 -1
- package/Marketplace/chunk-WIBWF333.js +1 -0
- package/Marketplace/{chunk-HK5FXZE4.js → chunk-WIRBYT7F.js} +1 -1
- package/Marketplace/{chunk-KJE5GRQ4.js → chunk-WVA5LYVE.js} +1 -1
- package/Marketplace/chunk-X52ZT4MU.js +1 -0
- package/Marketplace/chunk-XLQGQESJ.js +2 -0
- package/Marketplace/{chunk-6Q6L5NUD.js → chunk-XUDE7VBC.js} +1 -1
- package/Marketplace/{chunk-DHPNXR6E.js → chunk-Y3O22N4P.js} +1 -1
- package/Marketplace/{chunk-Q2QX5AAJ.js → chunk-YABJCAAL.js} +4 -4
- package/Marketplace/{chunk-WFVK32EW.js → chunk-YAWT3CLI.js} +1 -1
- package/Marketplace/chunk-YD6BNJ2B.js +1 -0
- package/Marketplace/{chunk-FHER4TFY.js → chunk-YKKHSYDW.js} +1 -1
- package/Marketplace/chunk-YMAKW4QT.js +1 -0
- package/Marketplace/chunk-YNL43MLU.js +1 -0
- package/Marketplace/chunk-YQZHIZHO.js +6 -0
- package/Marketplace/chunk-YUPBZXLS.js +1 -0
- package/Marketplace/chunk-YX65R6YJ.js +1 -0
- package/Marketplace/chunk-YYV4FSYQ.js +1 -0
- package/Marketplace/{chunk-EYT2YJGK.js → chunk-Z2XRGVGT.js} +1 -1
- package/Marketplace/chunk-Z6LN3X5Q.js +1 -0
- package/Marketplace/{chunk-HPINZVE4.js → chunk-ZC526ERX.js} +1 -1
- package/Marketplace/{chunk-M4ZE35XK.js → chunk-ZDBFIPDM.js} +1 -1
- package/Marketplace/{chunk-RNWHARPK.js → chunk-ZGIYCORM.js} +1 -1
- package/Marketplace/chunk-ZRTUQNSQ.js +1 -0
- package/Marketplace/{chunk-ITGVXYDV.js → chunk-ZWUYPYHD.js} +1 -1
- package/Marketplace/chunk-ZXP3XYSZ.js +1 -0
- package/Marketplace/index.html +2 -2
- package/Marketplace/main-RFMKGIMO.js +1 -0
- package/package.json +1 -1
- package/Marketplace/chunk-2B5DXBBJ.js +0 -1
- package/Marketplace/chunk-2F4DTZCZ.js +0 -2
- package/Marketplace/chunk-2MEVIFIA.js +0 -1
- package/Marketplace/chunk-2USFVKEX.js +0 -1
- package/Marketplace/chunk-36U7D4LI.js +0 -1
- package/Marketplace/chunk-4JDI3AL5.js +0 -1
- package/Marketplace/chunk-4LQREJ6J.js +0 -1
- package/Marketplace/chunk-4YCSITNV.js +0 -1
- package/Marketplace/chunk-5A3P2NB3.js +0 -1
- package/Marketplace/chunk-6EORXONU.js +0 -4
- package/Marketplace/chunk-6LRZDPE5.js +0 -1
- package/Marketplace/chunk-6UOPF4ZP.js +0 -1
- package/Marketplace/chunk-7Z5X4HRT.js +0 -1
- package/Marketplace/chunk-A7PUMY67.js +0 -1
- package/Marketplace/chunk-BQEBDVGB.js +0 -7
- package/Marketplace/chunk-BXYXVBXP.js +0 -1
- package/Marketplace/chunk-C4VD7LDS.js +0 -266
- package/Marketplace/chunk-C6JVY2ER.js +0 -1
- package/Marketplace/chunk-C7N6EI73.js +0 -1
- package/Marketplace/chunk-CBD25LAJ.js +0 -5
- package/Marketplace/chunk-CT6UFONR.js +0 -1
- package/Marketplace/chunk-D2J64VUP.js +0 -1
- package/Marketplace/chunk-DAUML5UD.js +0 -2
- package/Marketplace/chunk-DDV2A3Y2.js +0 -1
- package/Marketplace/chunk-E32KODU7.js +0 -1
- package/Marketplace/chunk-E3EBAWLJ.js +0 -1
- package/Marketplace/chunk-E66QUDQF.js +0 -1
- package/Marketplace/chunk-E6AMKEQR.js +0 -149
- package/Marketplace/chunk-E6ZWL77N.js +0 -1
- package/Marketplace/chunk-EDEZ3JLR.js +0 -4
- package/Marketplace/chunk-ESXDXSQ3.js +0 -1
- package/Marketplace/chunk-FCEXPGTK.js +0 -5
- package/Marketplace/chunk-FKGKMEDE.js +0 -2
- package/Marketplace/chunk-FKPDG4AM.js +0 -1
- package/Marketplace/chunk-GG3MDS4C.js +0 -1
- package/Marketplace/chunk-GURSK3ZV.js +0 -1
- package/Marketplace/chunk-HNFW4VQS.js +0 -1
- package/Marketplace/chunk-HSQHQZV7.js +0 -1
- package/Marketplace/chunk-I3R7CC6J.js +0 -1
- package/Marketplace/chunk-I7C6W3RB.js +0 -1
- package/Marketplace/chunk-ICE4DSEP.js +0 -1
- package/Marketplace/chunk-ILW6ZFFV.js +0 -1
- package/Marketplace/chunk-JW7NES7L.js +0 -1
- package/Marketplace/chunk-JWK3HR6P.js +0 -1
- package/Marketplace/chunk-K2BII75W.js +0 -15
- package/Marketplace/chunk-KSR5TQDN.js +0 -1
- package/Marketplace/chunk-KUBWQQZK.js +0 -1
- package/Marketplace/chunk-KUNITWR6.js +0 -1
- package/Marketplace/chunk-KVDREHOE.js +0 -1
- package/Marketplace/chunk-LNJUGHOX.js +0 -2
- package/Marketplace/chunk-LY32FUZ4.js +0 -2
- package/Marketplace/chunk-M2BYW5SR.js +0 -1
- package/Marketplace/chunk-MTPSSM64.js +0 -2
- package/Marketplace/chunk-N5VHHR26.js +0 -1
- package/Marketplace/chunk-NBCUYSP7.js +0 -1
- package/Marketplace/chunk-NCKPMA6Q.js +0 -1
- package/Marketplace/chunk-NH6QGSVC.js +0 -1
- package/Marketplace/chunk-O2YF5VGD.js +0 -2
- package/Marketplace/chunk-O4EO3YBL.js +0 -1
- package/Marketplace/chunk-OBF4XVU7.js +0 -1
- package/Marketplace/chunk-ONPG3DER.js +0 -2
- package/Marketplace/chunk-OPXITNRF.js +0 -1
- package/Marketplace/chunk-OXWPYJNB.js +0 -1
- package/Marketplace/chunk-Q4TAOZ73.js +0 -1
- package/Marketplace/chunk-Q56RJPES.js +0 -1
- package/Marketplace/chunk-R2XT5M5F.js +0 -3
- package/Marketplace/chunk-RI7L4QSY.js +0 -5
- package/Marketplace/chunk-RWVVRZJY.js +0 -1
- package/Marketplace/chunk-S5R6MCNP.js +0 -5
- package/Marketplace/chunk-S7CKRTJV.js +0 -2
- package/Marketplace/chunk-STYL7ETF.js +0 -3
- package/Marketplace/chunk-T5IUZ6UD.js +0 -1
- package/Marketplace/chunk-TAITBX62.js +0 -1
- package/Marketplace/chunk-TJYYRHZZ.js +0 -1
- package/Marketplace/chunk-TYQY4WPY.js +0 -1
- package/Marketplace/chunk-UQK5JNU2.js +0 -1
- package/Marketplace/chunk-XLIPGDSC.js +0 -2
- package/Marketplace/chunk-ZLBPUHTQ.js +0 -1
- package/Marketplace/chunk-ZME22WYI.js +0 -1
- package/Marketplace/chunk-ZW2TMVZP.js +0 -10
- package/Marketplace/chunk-ZYJ6LAJ3.js +0 -4
- package/Marketplace/main-K3MDOIIF.js +0 -1
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{a as Me}from"./chunk-
|
|
1
|
+
import{a as Me}from"./chunk-7HRL6MHY.js";import{a as St}from"./chunk-5QDH4ZNS.js";import{a as Ot}from"./chunk-Z2XRGVGT.js";import{a as It}from"./chunk-7X4B2T6C.js";import{a as wt}from"./chunk-WIRBYT7F.js";import{a as yt,c as vt,d as Ct,e as xt}from"./chunk-ZWUYPYHD.js";import{b as bt}from"./chunk-WVA5LYVE.js";import"./chunk-FOKLBUX6.js";import"./chunk-DDFP4CNP.js";import{b as st,c as Ve,d as _t,e as N}from"./chunk-RBZU7OVM.js";import{b as gt}from"./chunk-BUMWMFHU.js";import"./chunk-ROS2QMKF.js";import"./chunk-5WT456T7.js";import"./chunk-YNL43MLU.js";import{B as it,E as ot,Q as de,T as v,U as k,V as Se,X as Te,ca as at,g as Ze,ia as ct,la as lt,m as et,ma as J,na as rt,q as tt,u as nt,ua as pt,v as pe}from"./chunk-RXC5D64C.js";import"./chunk-O4D64GHO.js";import"./chunk-7R2D2JZ6.js";import{a as ue}from"./chunk-ZSUWHVKX.js";import"./chunk-AGBJEXIM.js";import{a as Xe,b as Je,c as Ye}from"./chunk-5UFP37GQ.js";import{A as ft,a as dt,b as ut,h as ht,m as mt}from"./chunk-WAXAIL2I.js";import"./chunk-RQUCYFCB.js";import{b as We}from"./chunk-MM7SAZOU.js";import{e as Ue,g as je}from"./chunk-NQLMPUSB.js";import"./chunk-OSGPJXJZ.js";import{A as X,s as He,t as Ie,u as qe,v as we,w as ze,z as Qe}from"./chunk-JNRCB7N3.js";import"./chunk-XBIHN6D3.js";import{$c as Oe,Aa as ne,Ab as fe,Bc as V,Cc as oe,Dc as C,Ec as x,Fd as M,Gd as xe,Hb as $,Ia as E,Ib as De,Ic as ae,Lb as ge,Lc as se,Mb as Be,Mc as g,Nb as f,Nc as y,Oc as R,Pa as Pe,Pc as A,Rc as H,Sc as q,Tc as z,Uc as be,Vc as Ne,Wc as ve,Z as me,_b as D,_c as Q,ac as _e,ad as ce,bd as Ce,cc as ye,dc as Ae,fc as Ke,gc as Re,hc as c,ic as d,id as le,jc as u,jd as re,kc as B,la as Ee,ld as W,ma as Le,na as Fe,ob as l,oc as I,pa as Ge,pc as w,pd as U,q as ke,qc as ie,qd as $e,ra as T,rc as S,tb as O,ud as j,wc as b,ya as h,yc as p,za as m}from"./chunk-OHGMB7HJ.js";import"./chunk-WFMAM73Y.js";import{a as F,b as G}from"./chunk-66YHNWRR.js";var Tt=`
|
|
2
2
|
.p-cascadeselect {
|
|
3
3
|
display: inline-flex;
|
|
4
4
|
cursor: pointer;
|
|
@@ -250,8 +250,8 @@ import{a as Me}from"./chunk-RQQWNLDZ.js";import{a as Ct}from"./chunk-EYT2YJGK.js
|
|
|
250
250
|
.p-cascadeselect-fluid .p-cascadeselect-overlay .p-cascadeselect-overlay {
|
|
251
251
|
min-width: 12.5rem;
|
|
252
252
|
}
|
|
253
|
-
`;var
|
|
254
|
-
${
|
|
253
|
+
`;var Lt=["pCascadeSelectSub",""],Ft=i=>({processedOption:i}),Gt=(i,s)=>({$implicit:i,level:s});function Pt(i,s){i&1&&ie(0)}function Dt(i,s){if(i&1&&(I(0),f(1,Pt,1,0,"ng-container",7),w()),i&2){let e=p().$implicit,t=p();l(),c("ngTemplateOutlet",t.optionTemplate)("ngTemplateOutletContext",Ce(2,Gt,e==null?null:e.option,t.level))}}function Bt(i,s){if(i&1&&(d(0,"span",8),y(1),u()),i&2){let e=p(),t=e.$implicit,n=e.index,o=p();g(o.cx("optionText")),c("pBind",o.getPTOptions(t,n,"optionText")),l(),R(o.getOptionLabelToRender(t))}}function At(i,s){if(i&1&&(ne(),B(0,"svg",11)),i&2){let e=p(2).$implicit,t=p();c("pBind",t.getPTOptions(e,t.index,"groupIcon"))}}function Kt(i,s){}function Rt(i,s){i&1&&f(0,Kt,0,0,"ng-template")}function Nt(i,s){if(i&1&&(d(0,"span",8),f(1,At,1,1,"svg",9)(2,Rt,1,0,null,10),u()),i&2){let e=p(),t=e.$implicit,n=e.index,o=p();g(o.cx("groupIcon")),c("pBind",o.getPTOptions(t,n,"groupIcon")),l(),c("ngIf",!o.groupicon),l(),c("ngTemplateOutlet",o.groupicon)}}function $t(i,s){if(i&1){let e=S();d(0,"ul",12),b("onChange",function(n){h(e);let o=p(2);return m(o.onChange.emit(n))})("onFocusChange",function(n){h(e);let o=p(2);return m(o.onFocusChange.emit(n))})("onFocusEnterChange",function(n){h(e);let o=p(2);return m(o.onFocusEnterChange.emit(n))}),u()}if(i&2){let e=p().$implicit,t=p();g(t.cx("optionList")),c("attrrole","group")("selectId",t.selectId)("focusedOptionId",t.focusedOptionId)("activeOptionPath",t.activeOptionPath)("options",t.getOptionGroupChildren(e))("optionLabel",t.optionLabel)("optionValue",t.optionValue)("level",t.level+1)("optionGroupLabel",t.optionGroupLabel)("optionGroupChildren",t.optionGroupChildren)("dirty",t.dirty)("optionTemplate",t.optionTemplate)("pBind",t.ptm("optionList"))("pt",t.pt)}}function Ht(i,s){if(i&1){let e=S();d(0,"li",2)(1,"div",3),b("click",function(n){let o=h(e).$implicit,a=p();return m(a.onOptionClick(n,o))})("mouseenter",function(n){let o=h(e).$implicit,a=p();return m(a.onOptionMouseEnter(n,o))})("mousemove",function(n){let o=h(e).$implicit,a=p();return m(a.onOptionMouseMove(n,o))}),f(2,Dt,2,5,"ng-container",4)(3,Bt,2,4,"ng-template",null,0,W)(5,Nt,3,5,"span",5),u(),f(6,$t,1,16,"ul",6),u()}if(i&2){let e=s.$implicit,t=s.index,n=ae(4),o=p();g(o.cx("option",ce(16,Ft,e))),c("pBind",o.getPTOptions(e,t,"option"))("id",o.getOptionId(e)),D("aria-level",o.level+1)("aria-setsize",o.options.length)("aria-label",o.getOptionLabelToRender(e))("aria-selected",o.isOptionGroup(e)?void 0:o.isOptionSelected(e))("aria-posinset",t+1),l(),g(o.cx("optionContent")),c("pBind",o.getPTOptions(e,t,"optionContent")),l(),c("ngIf",o.optionTemplate)("ngIfElse",n),l(3),c("ngIf",o.isOptionGroup(e)),l(),c("ngIf",o.isOptionGroup(e)&&o.isOptionActive(e))}}var qt=["value"],zt=["option"],Qt=["header"],Wt=["footer"],Ut=["triggericon"],jt=["loadingicon"],Xt=["optiongroupicon"],Jt=["clearicon"],Yt=["focusInput"],Zt=["panel"],en=["overlay"],tn=(i,s)=>({$implicit:i,placeholder:s});function nn(i,s){i&1&&ie(0)}function on(i,s){if(i&1&&(I(0),f(1,nn,1,0,"ng-container",14),w()),i&2){let e=p();l(),c("ngTemplateOutlet",e.valueTemplate||e._valueTemplate)("ngTemplateOutletContext",Ce(2,tn,e.value,e.placeholder))}}function an(i,s){if(i&1&&y(0),i&2){let e=p();A(" ",e.label()," ")}}function sn(i,s){if(i&1){let e=S();ne(),d(0,"svg",17),b("click",function(n){h(e);let o=p(2);return m(o.clear(n))}),u()}if(i&2){let e=p(2);g(e.cx("clearIcon")),c("pBind",e.ptm("clearIcon")),D("aria-hidden",!0)}}function cn(i,s){}function ln(i,s){i&1&&f(0,cn,0,0,"ng-template")}function rn(i,s){if(i&1){let e=S();d(0,"span",18),b("click",function(n){h(e);let o=p(2);return m(o.clear(n))}),f(1,ln,1,0,null,19),u()}if(i&2){let e=p(2);g(e.cx("clearIcon")),c("pBind",e.ptm("clearIcon")),D("aria-hidden",!0),l(),c("ngTemplateOutlet",e.clearIconTemplate||e._clearIconTemplate)}}function pn(i,s){if(i&1&&(I(0),f(1,sn,1,4,"svg",15)(2,rn,2,5,"span",16),w()),i&2){let e=p();l(),c("ngIf",!e.clearIconTemplate&&!e._clearIconTemplate),l(),c("ngIf",e.clearIconTemplate||e._clearIconTemplate)}}function dn(i,s){i&1&&ie(0)}function un(i,s){if(i&1&&(I(0),f(1,dn,1,0,"ng-container",19),w()),i&2){let e=p(2);l(),c("ngTemplateOutlet",e.loadingIconTemplate||e._loadingIconTemplate)}}function hn(i,s){if(i&1&&B(0,"span",21),i&2){let e=p(3);g(e.cn(e.cx("loadingIcon"),e.loadingIcon+"pi-spin")),c("pBind",e.ptm("loadingIcon"))}}function mn(i,s){if(i&1&&B(0,"span",21),i&2){let e=p(3);g(e.cn(e.cx("loadingIcon"),e.loadingIcon+" pi pi-spinner pi-spin")),c("pBind",e.ptm("loadingIcon"))}}function fn(i,s){if(i&1&&(I(0),f(1,hn,1,3,"span",20)(2,mn,1,3,"span",20),w()),i&2){let e=p(2);l(),c("ngIf",e.loadingIcon),l(),c("ngIf",!e.loadingIcon)}}function gn(i,s){if(i&1&&(I(0),f(1,un,2,1,"ng-container",10)(2,fn,3,2,"ng-container",10),w()),i&2){let e=p();l(),c("ngIf",e.loadingIconTemplate||e._loadingIconTemplate),l(),c("ngIf",!e.loadingIconTemplate&&!e._loadingIconTemplate)}}function _n(i,s){if(i&1&&(ne(),B(0,"svg",24)),i&2){let e=p(2);g(e.cx("dropdownIcon")),c("pBind",e.ptm("dropdownIcon"))}}function yn(i,s){}function bn(i,s){i&1&&f(0,yn,0,0,"ng-template")}function vn(i,s){if(i&1&&(d(0,"span",8),f(1,bn,1,0,null,19),u()),i&2){let e=p(2);g(e.cx("dropdownIcon")),c("pBind",e.ptm("dropdownIcon")),l(),c("ngTemplateOutlet",e.triggerIconTemplate||e._triggerIconTemplate)}}function On(i,s){if(i&1&&f(0,_n,1,3,"svg",22)(1,vn,2,4,"span",23),i&2){let e=p();c("ngIf",!e.triggerIconTemplate&&!e._triggerIconTemplate),l(),c("ngIf",e.triggerIconTemplate||e._triggerIconTemplate)}}function Cn(i,s){}function xn(i,s){i&1&&f(0,Cn,0,0,"ng-template")}function In(i,s){}function wn(i,s){i&1&&f(0,In,0,0,"ng-template")}function Sn(i,s){if(i&1){let e=S();d(0,"div",25,5),f(2,xn,1,0,null,19),d(3,"div",8)(4,"ul",26),b("onChange",function(n){h(e);let o=p();return m(o.onOptionClick(n))})("onFocusChange",function(n){h(e);let o=p();return m(o.onOptionMouseMove(n))})("onFocusEnterChange",function(n){h(e);let o=p();return m(o.onOptionMouseEnter(n))}),u()(),d(5,"span",12),y(6),u(),f(7,wn,1,0,null,19),u()}if(i&2){let e=p();g(e.cn(e.cx("overlay"),e.panelStyleClass)),c("ngStyle",e.panelStyle)("pBind",e.ptm("overlay")),l(2),c("ngTemplateOutlet",e.headerTemplate||e._headerTemplate),l(),g(e.cx("listContainer")),c("pBind",e.ptm("listContainer")),l(),g(e.cx("list")),c("options",e.processedOptions)("selectId",e.id)("focusedOptionId",e.focused?e.focusedOptionId:void 0)("activeOptionPath",e.activeOptionPath())("optionLabel",e.optionLabel)("optionValue",e.optionValue)("level",0)("optionTemplate",e.optionTemplate||e._optionTemplate)("groupicon",e.groupIconTemplate||e.groupIconTemplate)("optionGroupLabel",e.optionGroupLabel)("optionGroupChildren",e.optionGroupChildren)("optionDisabled",e.optionDisabled)("root",!0)("dirty",e.dirty)("pBind",e.ptm("list"))("pt",e.pt),D("role","tree")("aria-orientation","horizontal")("aria-label",e.listlabel),l(),c("pBind",e.ptm("selectedMessageText")),l(),A(" ",e.selectedMessageText," "),l(),c("ngTemplateOutlet",e.footerTemplate||e._footerTemplate)}}var Tn=`
|
|
254
|
+
${Tt}
|
|
255
255
|
|
|
256
256
|
/* For PrimeNG */
|
|
257
257
|
.p-cascadeselect.ng-invalid.ng-dirty:not(.ng-untouched):not(.ng-pristine) {
|
|
@@ -261,4 +261,4 @@ import{a as Me}from"./chunk-RQQWNLDZ.js";import{a as Ct}from"./chunk-EYT2YJGK.js
|
|
|
261
261
|
.p-cascadeselect.ng-invalid.ng-dirty:not(.ng-untouched):not(.ng-pristine) .p-cascadeselect-label.p-placeholder {
|
|
262
262
|
color: dt('cascadeselect.invalid.placeholder.color');
|
|
263
263
|
}
|
|
264
|
-
`,Mn={root:({instance:i})=>({position:i.$appendTo()==="self"?"relative":void 0})},kn={root:({instance:i})=>["p-cascadeselect p-component p-inputwrapper",{"p-cascadeselect p-component p-inputwrapper":!0,"p-cascadeselect-clearable":i.showClear&&!i.$disabled(),"p-cascadeselect-mobile":i.queryMatches(),"p-disabled":i.$disabled(),"p-invalid":i.invalid(),"p-focus":i.focused,"p-inputwrapper-filled":i.modelValue(),"p-variant-filled":i.$variant()==="filled","p-inputwrapper-focus":i.focused||i.overlayVisible,"p-cascadeselect-open":i.overlayVisible,"p-cascadeselect-fluid":i.hasFluid,"p-cascadeselect-sm p-inputfield-sm":i.size()==="small","p-cascadeselect-lg p-inputfield-lg":i.size()==="large"}],label:({instance:i})=>["p-cascadeselect-label",{"p-placeholder":i.label()===i.placeholder,"p-cascadeselect-label-empty":!i.value&&(i.label()==="p-emptylabel"||i.label().length===0)}],clearIcon:"p-cascadeselect-clear-icon",dropdown:"p-cascadeselect-dropdown",loadingIcon:"p-cascadeselect-loading-icon",dropdownIcon:"p-cascadeselect-dropdown-icon",overlay:({instance:i})=>["p-cascadeselect-overlay p-component-overlay p-component",{"p-cascadeselect-mobile-active":i.queryMatches()}],listContainer:"p-cascadeselect-list-container",list:"p-cascadeselect-list",option:({instance:i,processedOption:s})=>["p-cascadeselect-option",{"p-cascadeselect-option-group":i.isOptionGroup(s),"p-cascadeselect-option-active":i.isOptionActive(s),"p-cascadeselect-option-selected":i.isOptionSelected(s),"p-focus":i.isOptionFocused(s),"p-disabled":i.isOptionDisabled(s)}],optionContent:"p-cascadeselect-option-content",optionText:"p-cascadeselect-option-text",groupIcon:"p-cascadeselect-group-icon",optionList:"p-cascadeselect-list p-cascadeselect-overlay p-cascadeselect-option-list"},he=(()=>{class i extends mt{name="cascadeselect";style=Vn;classes=kn;inlineStyles=Mn;static \u0275fac=(()=>{let e;return function(n){return(e||(e=Ge(i)))(n||i)}})();static \u0275prov=Le({token:i,factory:i.\u0275fac})}return i})();var Mt=new Pe("CASCADESELECT_INSTANCE"),En={provide:je,useExisting:Ee(()=>Y),multi:!0},Ln=(()=>{class i extends yt{cascadeselect;selectId;activeOptionPath;optionDisabled;focusedOptionId;options;optionGroupChildren;optionTemplate;groupicon;level=0;optionLabel;optionValue;optionGroupLabel;dirty;root;onChange=new O;onFocusChange=new O;onFocusEnterChange=new O;_componentStyle=T(he);constructor(e){super(),this.cascadeselect=e}getPTOptions(e,t,n){return this.ptm(n,{context:{option:e,index:t,level:this.level,optionGroup:this.isOptionGroup(e),active:this.isOptionActive(e),focused:this.isOptionFocused(e),disabled:this.isOptionDisabled(e)}})}onInit(){this.root||this.position()}onOptionClick(e,t){this.onChange.emit({originalEvent:e,processedOption:t,isFocus:!0})}onOptionMouseEnter(e,t){this.onFocusEnterChange.emit({originalEvent:e,processedOption:t})}onOptionMouseMove(e,t){this.onFocusChange.emit({originalEvent:e,processedOption:t})}getOptionId(e){return`${this.selectId}_${e.key}`}getOptionLabel(e){return this.optionLabel?k(e.option,this.optionLabel):e.option}getOptionValue(e){return this.optionValue?k(e.option,this.optionValue):e.option}getOptionLabelToRender(e){return this.isOptionGroup(e)?this.getOptionGroupLabel(e):this.getOptionLabel(e)}isOptionDisabled(e){return this.optionDisabled?k(e.option,this.optionDisabled):!1}getOptionGroupLabel(e){return this.optionGroupLabel?k(e.option,this.optionGroupLabel):null}getOptionGroupChildren(e){return e.children}isOptionGroup(e){return v(e.children)}isOptionSelected(e){return Se(this.cascadeselect?.modelValue(),e?.option)}isOptionActive(e){return this.activeOptionPath.some(t=>t.key===e.key)}isOptionFocused(e){return this.focusedOptionId===this.getOptionId(e)}position(){let e=this.el.nativeElement.parentElement,t=dt(e),n=st(),o=this.el.nativeElement.childNodes[0].offsetParent?this.el.nativeElement.children[0].offsetWidth:pt(this.el.nativeElement.children[0]),a=ct(e.children[0]);parseInt(t.left,10)+a+o>n.width-lt()&&(this.el.nativeElement.children[0].style.left="-200%")}static \u0275fac=function(t){return new(t||i)(fe(Y))};static \u0275cmp=$({type:i,selectors:[["ul","pCascadeSelectSub",""]],inputs:{selectId:"selectId",activeOptionPath:"activeOptionPath",optionDisabled:"optionDisabled",focusedOptionId:"focusedOptionId",options:"options",optionGroupChildren:"optionGroupChildren",optionTemplate:"optionTemplate",groupicon:"groupicon",level:[2,"level","level",xe],optionLabel:"optionLabel",optionValue:"optionValue",optionGroupLabel:"optionGroupLabel",dirty:[2,"dirty","dirty",M],root:[2,"root","root",M]},outputs:{onChange:"onChange",onFocusChange:"onFocusChange",onFocusEnterChange:"onFocusEnterChange"},features:[Q([he,{provide:Ve,useExisting:i}]),ge],attrs:Ft,decls:1,vars:1,consts:[["defaultOptionTemplate",""],["ngFor","",3,"ngForOf"],["role","treeitem",3,"pBind","id"],["pRipple","",3,"click","mouseenter","mousemove","pBind"],[4,"ngIf","ngIfElse"],[3,"class","pBind",4,"ngIf"],["pCascadeSelectSub","",3,"attrrole","class","selectId","focusedOptionId","activeOptionPath","options","optionLabel","optionValue","level","optionGroupLabel","optionGroupChildren","dirty","optionTemplate","pBind","pt","onChange","onFocusChange","onFocusEnterChange",4,"ngIf"],[4,"ngTemplateOutlet","ngTemplateOutletContext"],[3,"pBind"],["data-p-icon","angle-right",3,"pBind",4,"ngIf"],[4,"ngTemplateOutlet"],["data-p-icon","angle-right",3,"pBind"],["pCascadeSelectSub","",3,"onChange","onFocusChange","onFocusEnterChange","attrrole","selectId","focusedOptionId","activeOptionPath","options","optionLabel","optionValue","level","optionGroupLabel","optionGroupChildren","dirty","optionTemplate","pBind","pt"]],template:function(t,n){t&1&&f(0,qt,7,18,"ng-template",1),t&2&&c("ngForOf",n.options)},dependencies:[i,X,He,Ie,we,St,Ct,J,N],encapsulation:2,changeDetection:0})}return i})(),Y=(()=>{class i extends vt{overlayService;$pcCascadeSelect=T(Mt,{optional:!0,skipSelf:!0})??void 0;bindDirectiveInstance=T(N,{self:!0});onAfterViewChecked(){this.bindDirectiveInstance.setAttrs(this.ptms(["host","root"]))}id;searchMessage;emptyMessage;selectionMessage;emptySearchMessage;emptySelectionMessage;searchLocale;optionDisabled;focusOnHover=!0;selectOnFocus=!1;autoOptionFocus=!1;styleClass;options;optionLabel;optionValue;optionGroupLabel;optionGroupChildren;placeholder;value;dataKey;inputId;tabindex=0;ariaLabelledBy;inputLabel;ariaLabel;showClear=!1;panelStyleClass;panelStyle;overlayOptions;autofocus;loading=!1;loadingIcon;breakpoint="960px";size=j();variant=j();fluid=j(void 0,{transform:M});appendTo=j(void 0);onChange=new O;onGroupChange=new O;onShow=new O;onHide=new O;onClear=new O;onBeforeShow=new O;onBeforeHide=new O;onFocus=new O;onBlur=new O;focusInputViewChild;panelViewChild;overlayViewChild;valueTemplate;optionTemplate;headerTemplate;footerTemplate;triggerIconTemplate;loadingIconTemplate;groupIconTemplate;clearIconTemplate;_valueTemplate;_optionTemplate;_headerTemplate;_footerTemplate;_triggerIconTemplate;_loadingIconTemplate;_groupIconTemplate;_clearIconTemplate;selectionPath=null;focused=!1;overlayVisible=!1;clicked=!1;dirty=!1;searchValue;searchTimeout;focusedOptionInfo=E({index:-1,level:0,parentKey:""});activeOptionPath=E([]);processedOptions=[];_componentStyle=T(he);initialized=!1;$variant=U(()=>this.variant()||this.config.inputStyle()||this.config.inputVariant());$appendTo=U(()=>this.appendTo()||this.config.overlayAppendTo());pcFluid=T(Ot,{optional:!0,host:!0,skipSelf:!0});get hasFluid(){return this.fluid()??!!this.pcFluid}onHostClick(e){this.onContainerClick(e)}get listLabel(){return this.config.getTranslation(_t.ARIA).listLabel}get focusedOptionId(){return this.focusedOptionInfo().index!==-1?`${this.id}${v(this.focusedOptionInfo().parentKey)?"_"+this.focusedOptionInfo().parentKey:""}_${this.focusedOptionInfo().index}`:null}get searchResultMessageText(){return v(this.visibleOptions())?this.searchMessageText.replaceAll("{0}",this.visibleOptions().length):this.emptySearchMessageText}get searchMessageText(){return this.searchMessage||this.config.translation.searchMessage||""}get emptySearchMessageText(){return this.emptySearchMessage||this.config.translation.emptySearchMessage||""}get emptyMessageText(){return this.emptyMessage||this.config.translation.emptyMessage||""}get selectionMessageText(){return this.selectionMessage||this.config.translation.selectionMessage||""}get emptySelectionMessageText(){return this.emptySelectionMessage||this.config.translation.emptySelectionMessage||""}get selectedMessageText(){return this.hasSelectedOption()?this.selectionMessageText.replaceAll("{0}","1"):this.emptySelectionMessageText}visibleOptions=U(()=>{let e=this.activeOptionPath().find(t=>t.key===this.focusedOptionInfo().parentKey);return e?e.children:this.processedOptions});label=U(()=>{let e=this.placeholder||"p-emptylabel";if(this.hasSelectedOption()){let t=this.findOptionPathByValue(this.modelValue(),null),n=v(t)?t[t.length-1]:null;return n?this.getOptionLabel(n.option):e}return e});get _label(){let e=this.placeholder||"p-emptylabel";if(this.hasSelectedOption()){let t=this.findOptionPathByValue(this.modelValue(),null),n=v(t)?t[t.length-1]:null;return n?this.getOptionLabel(n.option):e}return e}templates;onAfterContentInit(){this.templates.forEach(e=>{switch(e.getType()){case"value":this._valueTemplate=e.template;break;case"option":this._optionTemplate=e.template;break;case"header":this._headerTemplate=e.template;break;case"footer":this._footerTemplate=e.template;break;case"triggericon":this._triggerIconTemplate=e.template;break;case"loadingicon":this._loadingIconTemplate=e.template;break;case"clearicon":this._clearIconTemplate=e.template;break;case"optiongroupicon":this._groupIconTemplate=e.template;break}})}onChanges(e){e.options&&(this.processedOptions=this.createProcessedOptions(e.options.currentValue||[]),this.updateModel(null))}hasSelectedOption(){return v(this.modelValue())}createProcessedOptions(e,t=0,n={},o=""){let a=[];return e&&e.forEach((r,_)=>{let G=(o!==""?o+"_":"")+_,L={option:r,index:_,level:t,key:G,parent:n,parentKey:o};L.children=this.createProcessedOptions(this.getOptionGroupChildren(r,t),t+1,L,G),a.push(L)}),a}onInputFocus(e){this.$disabled()||(this.focused=!0,this.onFocus.emit(e))}onInputBlur(e){this.focused=!1,this.focusedOptionInfo.set({indeX:-1,level:0,parentKey:""}),this.searchValue="",this.onModelTouched(),this.onBlur.emit(e)}onInputKeyDown(e){if(this.$disabled()||this.loading){e.preventDefault();return}let t=e.metaKey||e.ctrlKey;switch(e.code){case"ArrowDown":this.onArrowDownKey(e);break;case"ArrowUp":this.onArrowUpKey(e);break;case"ArrowLeft":this.onArrowLeftKey(e);break;case"ArrowRight":this.onArrowRightKey(e);break;case"Home":this.onHomeKey(e);break;case"End":this.onEndKey(e);break;case"Space":this.onSpaceKey(e);break;case"Enter":case"NumpadEnter":this.onEnterKey(e);break;case"Escape":this.onEscapeKey(e);break;case"Tab":this.onTabKey(e);break;case"Backspace":this.onBackspaceKey(e);break;case"PageDown":case"PageUp":case"ShiftLeft":case"ShiftRight":break;default:!t&&ut(e.key)&&(!this.overlayVisible&&this.show(),this.searchOptions(e,e.key));break}this.clicked=!1}onArrowDownKey(e){if(!this.overlayVisible)this.show();else{let t=this.focusedOptionInfo().index!==-1?this.findNextOptionIndex(this.focusedOptionInfo().index):this.clicked?this.findFirstOptionIndex():this.findFirstFocusedOptionIndex();this.changeFocusedOptionIndex(e,t,!0)}e.preventDefault()}onArrowUpKey(e){if(e.altKey){if(this.focusedOptionInfo().index!==-1){let t=this.visibleOptions[this.focusedOptionInfo().index];!this.isProccessedOptionGroup(t)&&this.onOptionChange({originalEvent:e,processedOption:t})}this.overlayVisible&&this.hide(),e.preventDefault()}else{let t=this.focusedOptionInfo().index!==-1?this.findPrevOptionIndex(this.focusedOptionInfo().index):this.clicked?this.findLastOptionIndex():this.findLastFocusedOptionIndex();this.changeFocusedOptionIndex(e,t,!0),!this.overlayVisible&&this.show(),e.preventDefault()}}onArrowLeftKey(e){if(this.overlayVisible){let t=this.visibleOptions()[this.focusedOptionInfo().index],n=this.activeOptionPath().find(r=>r.key===t.parentKey),o=this.focusedOptionInfo().parentKey===""||n&&n.key===this.focusedOptionInfo().parentKey,a=ue(t.parent);if(o){let r=this.activeOptionPath().filter(_=>_.parentKey!==this.focusedOptionInfo().parentKey);this.activeOptionPath.set(r)}a||(this.focusedOptionInfo.set({index:-1,parentKey:n?n.parentKey:""}),this.searchValue="",this.onArrowDownKey(e)),e.preventDefault()}}onArrowRightKey(e){if(this.overlayVisible){let t=this.visibleOptions()[this.focusedOptionInfo().index];this.isProccessedOptionGroup(t)&&(this.activeOptionPath().some(a=>t.key===a.key)?(this.focusedOptionInfo.set({index:-1,parentKey:t.key}),this.searchValue="",this.onArrowDownKey(e)):this.onOptionChange({originalEvent:e,processedOption:t})),e.preventDefault()}}onHomeKey(e){this.changeFocusedOptionIndex(e,this.findFirstOptionIndex()),!this.overlayVisible&&this.show(),e.preventDefault()}onEndKey(e){this.changeFocusedOptionIndex(e,this.findLastOptionIndex()),!this.overlayVisible&&this.show(),e.preventDefault()}onEnterKey(e){if(!this.overlayVisible)this.focusedOptionInfo.set(P(F({},this.focusedOptionInfo()),{index:-1})),this.onArrowDownKey(e);else if(this.focusedOptionInfo().index!==-1){let t=this.visibleOptions()[this.focusedOptionInfo().index],n=this.isProccessedOptionGroup(t);this.onOptionClick({originalEvent:e,processedOption:t}),!n&&this.hide()}e.preventDefault()}onSpaceKey(e){this.onEnterKey(e)}onEscapeKey(e){this.overlayVisible&&this.hide(e,!0),e.preventDefault()}onTabKey(e){if(this.focusedOptionInfo().index!==-1){let t=this.visibleOptions()[this.focusedOptionInfo().index];!this.isProccessedOptionGroup(t)&&this.onOptionChange({originalEvent:e,processedOption:t})}this.overlayVisible&&this.hide()}onBackspaceKey(e){v(this.modelValue())&&this.showClear&&this.clear(),e.stopPropagation()}equalityKey(){return this.optionValue?void 0:this.dataKey}updateModel(e,t){this.value=e,this.onModelChange(e),this.writeModelValue(e),this.initialized&&this.onChange.emit({originalEvent:t,value:e})}autoUpdateModel(){this.selectOnFocus&&this.autoOptionFocus&&!this.hasSelectedOption()&&(this.focusedOptionInfo().index=this.findFirstFocusedOptionIndex(),this.onOptionChange({originalEvent:null,processedOption:this.visibleOptions()[this.focusedOptionInfo().index],isHide:!1}),!this.overlayVisible&&this.focusedOptionInfo.set({index:-1,level:0,parentKey:""}))}scrollInView(e=-1){let t=e!==-1?`${this.id}_${e}`:this.focusedOptionId,n=rt(this.panelViewChild?.nativeElement,`li[id="${t}"]`);n&&n.scrollIntoView&&n.scrollIntoView({block:"nearest",inline:"start"})}changeFocusedOptionIndex(e,t,n){let o=this.focusedOptionInfo();o.index!==t&&(this.focusedOptionInfo.set(P(F({},o),{index:t})),this.scrollInView(),this.focusOnHover&&this.onOptionClick({originalEvent:e,processedOption:this.visibleOptions()[t],isHide:!1,preventSelection:n}),this.selectOnFocus&&this.onOptionChange({originalEvent:e,processedOption:this.visibleOptions()[t],isHide:!1}))}matchMediaListener;onOptionSelect(e){let{originalEvent:t,value:n,isHide:o}=e,a=this.getOptionValue(n),r=this.activeOptionPath();r.forEach(_=>_.selected=!0),this.activeOptionPath.set(r),this.updateModel(a,t),o&&this.hide(e,!0)}onOptionGroupSelect(e){this.dirty=!0,this.onGroupChange.emit(e)}onContainerClick(e){this.$disabled()||this.loading||(this.overlayViewChild?.el?.nativeElement?.contains(e.target)||(this.overlayVisible?this.hide():this.show(),this.focusInputViewChild?.nativeElement.focus()),this.clicked=!0)}isOptionMatched(e){return this.isValidOption(e)&&this.getProccessedOptionLabel(e).toLocaleLowerCase(this.searchLocale).startsWith(this.searchValue?.toLocaleLowerCase(this.searchLocale))}isOptionDisabled(e){return this.optionDisabled?k(e,this.optionDisabled):!1}isValidOption(e){return!!e&&!this.isOptionDisabled(e.option)}isValidSelectedOption(e){return this.isValidOption(e)&&this.isSelected(e)}isSelected(e){return this.activeOptionPath().some(t=>t.key===e.key)}findOptionPathByValue(e,t,n=0){if(t=t||n===0&&this.processedOptions,!t)return null;if(ue(e))return[];for(let o=0;o<t.length;o++){let a=t[o];if(Se(e,this.getOptionValue(a.option),this.equalityKey()))return[a];let r=this.findOptionPathByValue(e,a.children,n+1);if(r)return r.unshift(a),r}}findFirstOptionIndex(){return this.visibleOptions().findIndex(e=>this.isValidOption(e))}findLastOptionIndex(){return Te(this.visibleOptions(),e=>this.isValidOption(e))}findNextOptionIndex(e){let t=e<this.visibleOptions().length-1?this.visibleOptions().slice(e+1).findIndex(n=>this.isValidOption(n)):-1;return t>-1?t+e+1:e}findPrevOptionIndex(e){let t=e>0?Te(this.visibleOptions().slice(0,e),n=>this.isValidOption(n)):-1;return t>-1?t:e}findSelectedOptionIndex(){return this.visibleOptions().findIndex(e=>this.isValidSelectedOption(e))}findFirstFocusedOptionIndex(){let e=this.findSelectedOptionIndex();return e<0?this.findFirstOptionIndex():e}findLastFocusedOptionIndex(){let e=this.findSelectedOptionIndex();return e<0?this.findLastOptionIndex():e}searchOptions(e,t){this.searchValue=(this.searchValue||"")+t;let n=-1,o=!1,a=this.focusedOptionInfo();return a.index!==-1?(n=this.visibleOptions().slice(a.index).findIndex(r=>this.isOptionMatched(r)),n=n===-1?this.visibleOptions().slice(0,a.index).findIndex(r=>this.isOptionMatched(r)):n+a.index):n=this.visibleOptions().findIndex(r=>this.isOptionMatched(r)),n!==-1&&(o=!0),n===-1&&a.index===-1&&(n=this.findFirstFocusedOptionIndex()),n!==-1&&this.changeFocusedOptionIndex(e,n),this.searchTimeout&&clearTimeout(this.searchTimeout),this.searchTimeout=setTimeout(()=>{this.searchValue="",this.searchTimeout=null},500),o}hide(e,t=!1){let n=()=>{this.overlayVisible=!1,this.clicked=!1,this.activeOptionPath.set([]),this.focusedOptionInfo.set({index:-1,level:0,parentKey:""}),t&&de(this.focusInputViewChild?.nativeElement),this.onHide.emit(e),this.cd.markForCheck()};setTimeout(()=>{n()},0)}show(e,t=!1){this.onShow.emit(e),this.overlayVisible=!0;let n=this.hasSelectedOption()?this.findOptionPathByValue(this.modelValue()):this.activeOptionPath();this.activeOptionPath.set(n);let o;if(this.hasSelectedOption()&&v(this.activeOptionPath())){let a=this.activeOptionPath()[this.activeOptionPath().length-1];o={index:a.index,level:a.level,parentKey:a.parentKey}}else o={index:this.autoOptionFocus?this.findFirstFocusedOptionIndex():this.findSelectedOptionIndex(),level:0,parentKey:""};this.focusedOptionInfo.set(o),t&&de(this.focusInputViewChild?.nativeElement)}clear(e){v(this.modelValue())&&this.showClear&&(this.updateModel(null),this.focusedOptionInfo.set({index:-1,level:0,parentKey:""}),this.activeOptionPath.set([]),this.onClear.emit(e)),e&&e.stopPropagation()}getOptionLabel(e){return this.optionLabel?k(e,this.optionLabel):e}getOptionValue(e){return this.optionValue?k(e,this.optionValue):e}getOptionGroupLabel(e){return this.optionGroupLabel?k(e,this.optionGroupLabel):null}getOptionGroupChildren(e,t){return k(e,this.optionGroupChildren?.[t])}isOptionGroup(e,t){return Object.prototype.hasOwnProperty.call(e,this.optionGroupChildren?.[t])}isProccessedOptionGroup(e){return v(e?.children)}getProccessedOptionLabel(e){return this.isProccessedOptionGroup(e)?this.getOptionGroupLabel(e.option):this.getOptionLabel(e.option)}constructor(e){super(),this.overlayService=e,$e(()=>{let t=this.activeOptionPath();v(t)&&this.overlayViewChild?.alignOverlay()})}query;queryMatches=E(!1);mobileActive=E(!1);onOptionChange(e){let{processedOption:t,type:n}=e;if(ue(t))return;let{index:o,key:a,level:r,parentKey:_,children:G}=t,L=v(G),K=this.activeOptionPath().filter(Z=>Z.parentKey!==_&&Z.parentKey!==a);this.focusedOptionInfo.set({index:o,level:r,parentKey:_}),!(n=="hover"&&this.queryMatches())&&(L&&K.push(t),this.activeOptionPath.set([...K]))}onOptionClick(e){let{originalEvent:t,processedOption:n,isFocus:o,isHide:a,preventSelection:r}=e,{index:_,key:G,level:L,parentKey:K}=n,Z=this.isProccessedOptionGroup(n);if(this.isSelected(n)){let ee=this.activeOptionPath().filter(te=>G!==te.key&&G.startsWith(te.key));this.activeOptionPath.set([...ee]),this.focusedOptionInfo.set({index:_,level:L,parentKey:K})}else if(Z)this.onOptionChange(e),this.onOptionGroupSelect({originalEvent:t,value:n.option,isFocus:!1});else{let ee=this.activeOptionPath().filter(te=>te.parentKey!==K);ee.push(n),this.focusedOptionInfo.set({index:_,level:L,parentKey:K}),(!r||n?.children.length!==0)&&(this.activeOptionPath.set([...ee]),this.onOptionSelect({originalEvent:t,value:n.option,isHide:o}))}o&&de(this.focusInputViewChild?.nativeElement)}onOptionMouseEnter(e){this.focusOnHover&&(this.dirty||!this.dirty&&v(this.modelValue())?this.onOptionChange(P(F({},e),{type:"hover"})):!this.dirty&&e.processedOption.level===0&&this.onOptionClick(P(F({},e),{type:"hover"})))}onOptionMouseMove(e){this.focused&&this.focusOnHover&&this.changeFocusedOptionIndex(e,e.processedOption.index)}onInit(){this.id=this.id||ht("pn_id_"),this.autoUpdateModel(),this.bindMatchMediaListener()}onAfterViewInit(){this.initialized=!0}bindMatchMediaListener(){if(!this.matchMediaListener){let e=this.document.defaultView;if(e&&e.matchMedia){let t=e.matchMedia(`(max-width: ${this.breakpoint})`);this.query=t,this.queryMatches.set(t?.matches),this.matchMediaListener=()=>{this.queryMatches.set(t?.matches),this.mobileActive.set(!1)},this.query.addEventListener("change",this.matchMediaListener)}}}unbindMatchMediaListener(){this.matchMediaListener&&(this.query.removeEventListener("change",this.matchMediaListener),this.matchMediaListener=null)}onOverlayAnimationDone(e){switch(e.toState){case"void":this.dirty=!1;break}}writeControlValue(e,t){this.value=e,t(e),this.cd.markForCheck()}onDestroy(){this.matchMediaListener&&this.unbindMatchMediaListener()}static \u0275fac=function(t){return new(t||i)(fe(ft))};static \u0275cmp=$({type:i,selectors:[["p-cascadeSelect"],["p-cascadeselect"],["p-cascade-select"]],contentQueries:function(t,n,o){if(t&1&&(V(o,zt,4),V(o,Qt,4),V(o,Wt,4),V(o,Ut,4),V(o,jt,4),V(o,Xt,4),V(o,Jt,4),V(o,Yt,4),V(o,gt,4)),t&2){let a;C(a=x())&&(n.valueTemplate=a.first),C(a=x())&&(n.optionTemplate=a.first),C(a=x())&&(n.headerTemplate=a.first),C(a=x())&&(n.footerTemplate=a.first),C(a=x())&&(n.triggerIconTemplate=a.first),C(a=x())&&(n.loadingIconTemplate=a.first),C(a=x())&&(n.groupIconTemplate=a.first),C(a=x())&&(n.clearIconTemplate=a.first),C(a=x())&&(n.templates=a)}},viewQuery:function(t,n){if(t&1&&(oe(Zt,5),oe(en,5),oe(tn,5)),t&2){let o;C(o=x())&&(n.focusInputViewChild=o.first),C(o=x())&&(n.panelViewChild=o.first),C(o=x())&&(n.overlayViewChild=o.first)}},hostVars:4,hostBindings:function(t,n){t&1&&b("click",function(a){return n.onHostClick(a)}),t&2&&(se(n.sx("root")),g(n.cn(n.cx("root"),n.styleClass)))},inputs:{id:"id",searchMessage:"searchMessage",emptyMessage:"emptyMessage",selectionMessage:"selectionMessage",emptySearchMessage:"emptySearchMessage",emptySelectionMessage:"emptySelectionMessage",searchLocale:"searchLocale",optionDisabled:"optionDisabled",focusOnHover:[2,"focusOnHover","focusOnHover",M],selectOnFocus:[2,"selectOnFocus","selectOnFocus",M],autoOptionFocus:[2,"autoOptionFocus","autoOptionFocus",M],styleClass:"styleClass",options:"options",optionLabel:"optionLabel",optionValue:"optionValue",optionGroupLabel:"optionGroupLabel",optionGroupChildren:"optionGroupChildren",placeholder:"placeholder",value:"value",dataKey:"dataKey",inputId:"inputId",tabindex:[2,"tabindex","tabindex",xe],ariaLabelledBy:"ariaLabelledBy",inputLabel:"inputLabel",ariaLabel:"ariaLabel",showClear:[2,"showClear","showClear",M],panelStyleClass:"panelStyleClass",panelStyle:"panelStyle",overlayOptions:"overlayOptions",autofocus:[2,"autofocus","autofocus",M],loading:[2,"loading","loading",M],loadingIcon:"loadingIcon",breakpoint:"breakpoint",size:[1,"size"],variant:[1,"variant"],fluid:[1,"fluid"],appendTo:[1,"appendTo"]},outputs:{onChange:"onChange",onGroupChange:"onGroupChange",onShow:"onShow",onHide:"onHide",onClear:"onClear",onBeforeShow:"onBeforeShow",onBeforeHide:"onBeforeHide",onFocus:"onFocus",onBlur:"onBlur"},features:[Q([En,he,{provide:Ve,useExisting:i},{provide:Mt,useExisting:i}]),Be([N]),ge],decls:18,vars:36,consts:[["focusInput",""],["defaultValueTemplate",""],["elseBlock",""],["overlay",""],["content",""],["panel",""],[1,"p-hidden-accessible",3,"pBind"],["readonly","","type","text","role","combobox",3,"focus","blur","keydown","pAutoFocus","pBind"],[3,"pBind"],[4,"ngIf","ngIfElse"],[4,"ngIf"],["role","button","aria-haspopup","listbox",3,"pBind"],["role","status","aria-live","polite",1,"p-hidden-accessible",3,"pBind"],[3,"visibleChange","onAnimationDone","onBeforeShow","onShow","onBeforeHide","onHide","hostAttrSelector","visible","options","target","appendTo","pt"],[4,"ngTemplateOutlet","ngTemplateOutletContext"],["data-p-icon","times",3,"class","pBind","click",4,"ngIf"],[3,"class","pBind","click",4,"ngIf"],["data-p-icon","times",3,"click","pBind"],[3,"click","pBind"],[4,"ngTemplateOutlet"],["aria-hidden","true",3,"class","pBind",4,"ngIf"],["aria-hidden","true",3,"pBind"],["data-p-icon","chevron-down",3,"class","pBind",4,"ngIf"],[3,"class","pBind",4,"ngIf"],["data-p-icon","chevron-down",3,"pBind"],[3,"ngStyle","pBind"],["pCascadeSelectSub","",3,"onChange","onFocusChange","onFocusEnterChange","options","selectId","focusedOptionId","activeOptionPath","optionLabel","optionValue","level","optionTemplate","groupicon","optionGroupLabel","optionGroupChildren","optionDisabled","root","dirty","pBind","pt"]],template:function(t,n){if(t&1){let o=S();d(0,"div",6)(1,"input",7,0),b("focus",function(r){return h(o),m(n.onInputFocus(r))})("blur",function(r){return h(o),m(n.onInputBlur(r))})("keydown",function(r){return h(o),m(n.onInputKeyDown(r))}),u()(),d(3,"span",8),f(4,an,2,5,"ng-container",9)(5,sn,1,1,"ng-template",null,1,W),u(),f(7,dn,3,2,"ng-container",10),d(8,"div",11),f(9,_n,3,2,"ng-container",9)(10,Cn,2,2,"ng-template",null,2,W),u(),d(12,"span",12),y(13),u(),d(14,"p-overlay",13,3),z("visibleChange",function(r){return h(o),q(n.overlayVisible,r)||(n.overlayVisible=r),m(r)}),b("onAnimationDone",function(r){return h(o),m(n.onOverlayAnimationDone(r))})("onBeforeShow",function(r){return h(o),m(n.onBeforeShow.emit(r))})("onShow",function(r){return h(o),m(n.show(r))})("onBeforeHide",function(r){return h(o),m(n.onBeforeHide.emit(r))})("onHide",function(r){return h(o),m(n.hide(r))}),f(16,Tn,8,32,"ng-template",null,4,W),u()}if(t&2){let o=ae(6),a=ae(11);c("pBind",n.ptm("hiddenInputWrapper")),l(),c("pAutoFocus",n.autofocus)("pBind",n.ptm("hiddenInput")),D("name",n.name())("required",n.required()?"":void 0)("disabled",n.$disabled()?"":void 0)("placeholder",n.placeholder)("tabindex",n.$disabled()?-1:n.tabindex)("id",n.inputId)("aria-label",n.ariaLabel)("aria-labelledby",n.ariaLabelledBy)("aria-haspopup","tree")("aria-expanded",n.overlayVisible??!1)("aria-controls",n.overlayVisible?n.id+"_tree":null)("aria-activedescendant",n.focused?n.focusedOptionId:void 0),l(2),g(n.cx("label")),c("pBind",n.ptm("label")),l(),c("ngIf",n.valueTemplate||n._valueTemplate)("ngIfElse",o),l(3),c("ngIf",n.$filled()&&!n.$disabled()&&n.showClear),l(),g(n.cx("dropdown")),c("pBind",n.ptm("dropdown")),D("aria-expanded",n.overlayVisible??!1)("aria-hidden",!0),l(),c("ngIf",n.loading)("ngIfElse",a),l(3),c("pBind",n.ptm("hiddenSearchResult")),l(),A(" ",n.searchResultMessageText," "),l(),c("hostAttrSelector",n.$attrSelector),H("visible",n.overlayVisible),c("options",n.overlayOptions)("target","@parent")("appendTo",n.$appendTo())("pt",n.ptm("pcOverlay"))}},dependencies:[X,Ie,we,qe,wt,bt,Ln,xt,It,J,N],encapsulation:2,changeDetection:0})}return i})(),kt=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275mod=De({type:i});static \u0275inj=Fe({imports:[Y,J,J]})}return i})();var Pn=()=>({minWidth:"100%"}),Gn=()=>["Roles"],Dn=i=>({ID:i});function Bn(i,s){if(i&1){let e=S();d(0,"button",13),b("click",function(){h(e);let n=p(2);return m(n.onDeleteGroup())}),B(1,"i",14),y(2),u()}if(i&2){let e,t=p(2);l(2),A(" Delete (",(e=t.selectedGroups())==null?null:e.length,") ")}}function An(i,s){if(i&1&&(I(0),_e(1,Bn,3,1,"button",12),w()),i&2){let e,t=p();l(),ye(((e=t.selectedGroups())==null?null:e.length)>0?1:-1)}}function Kn(i,s){i&1&&(I(0),d(1,"a",15),y(2," Add"),u(),w())}function Rn(i,s){if(i&1){let e=S();I(0),d(1,"th",16)(2,"div",17)(3,"input",18),b("change",function(n){h(e);let o=p(),a=ve(0);return m(o.onCheckAllGroups(n==null||n.target==null?null:n.target.checked,a==null?null:a.Data))}),u()()(),w()}}function Nn(i,s){if(i&1){let e=S();I(0),d(1,"td")(2,"div",17)(3,"input",20),z("ngModelChange",function(n){h(e);let o=p().$implicit;return q(o.checked,n)||(o.checked=n),m(n)}),b("ngModelChange",function(){h(e);let n=p(2),o=ve(0);return m(n.onSelectGroup(o==null?null:o.Data))}),u()()(),w()}if(i&2){let e=p().$implicit;l(3),H("ngModel",e.checked)}}function $n(i,s){if(i&1&&(d(0,"a",19),y(1),u()),i&2){let e=p().$implicit;c("queryParams",ce(2,Dn,e.ID)),l(),A(" ",e.Name," ")}}function Hn(i,s){if(i&1&&(d(0,"span"),y(1),u()),i&2){let e=p().$implicit;l(),R(e.Name)}}function qn(i,s){if(i&1&&(d(0,"tr"),f(1,Nn,4,1,"ng-container",1),d(2,"td"),_e(3,$n,2,4,"a",19)(4,Hn,2,1,"span"),u(),d(5,"td"),y(6),u(),d(7,"td"),y(8),le(9,"number"),u()()),i&2){let e=s.$implicit,t=p();l(),c("ngxPermissionsOnly",t.userDeleteRole),l(2),ye(t.hasUserEditRole()?3:4),l(3),R(e.Description),l(2),R(re(9,4,e.Count))}}var Ni=(()=>{let s=class s{constructor(){this.permissionService=T(tt),this.groupsService=T(Me),this.toastr=T(et),this.groupLoader$=this.groupsService.getGroupsLoader().pipe(me(1)),this.groups$=ke({Count:0,Data:[]}),this.filter=E({PageNumber:1,PageSize:100,Role:null}),this.selectedGroups=E([]),this.userCreateRole=pe.UserInvite,this.userDeleteRole=pe.UserDelete,this.hasUserEditRole=E(!1),this.initGroup(),this.permissionService.hasPermission(pe.UserEdit).then(t=>{this.hasUserEditRole.set(t)})}initGroup(){this.groups$=this.groupsService.getGroups(this.filter()).pipe(me(1))}onCheckAllGroups(t,n){n.forEach(a=>{a.checked=t});let o=n.filter(a=>a.checked);this.selectedGroups.set(o)}onSelectGroup(t){this.selectedGroups.set(t.filter(n=>n.checked))}onDeleteGroup(){if(confirm("Are you sure you want to delete the selected groups?")){let n=this.selectedGroups().map(o=>o.ID);this.groupsService.deleteGroups(n).subscribe({next:()=>{this.selectedGroups.set([]),this.toastr.success("Groups deleted successfully","Success"),this.initGroup()}})}}onNextPage(){this.filter.update(t=>P(F({},t),{PageNumber:t.PageNumber+1})),this.initGroup()}onPrevPage(){this.filter.update(t=>P(F({},t),{PageNumber:t.PageNumber-1})),this.initGroup()}onFilter(){this.initGroup()}};s.\u0275fac=function(n){return new(n||s)},s.\u0275cmp=$({type:s,selectors:[["app-groups"]],features:[Q([Me])],decls:31,vars:21,consts:[["headerTitle","Groups",3,"onSubmit","hideSearchBox","hideSearchDropdown"],[4,"ngxPermissionsOnly"],[1,"w-100"],[1,"d-block","fs-5","mb-2"],["appendTo","body","optionLabel","Name","optionGroupLabel","Name","optionValue","ID","placeholder","Select a Role",3,"ngModelChange","options","ngModel","optionGroupChildren"],[1,"container-fluid"],[1,"row","mt-6"],[1,"col-12"],[1,"table"],[1,"thead-light","sticky-top-thead"],[2,"width","15%"],[3,"next","previous","filter","totaldata","paginationTotal","hasClicked"],[1,"btn","btn-danger","me-3"],[1,"btn","btn-danger","me-3",3,"click"],[1,"fa","fa-trash","me-1"],["routerLink","/menu/users/groups/form",1,"btn","btn-success"],[2,"width","5px"],[1,"d-flex"],["type","checkbox",3,"change"],["routerLink","/menu/users/groups/info",3,"queryParams"],["type","checkbox",3,"ngModelChange","ngModel"]],template:function(n,o){if(n&1){let a=S();be(0),le(1,"async"),be(2),le(3,"async"),d(4,"mainpanel",0),b("onSubmit",function(){return h(a),m(o.onFilter())}),d(5,"actions"),f(6,An,2,1,"ng-container",1)(7,Kn,3,0,"ng-container",1),u(),d(8,"filters")(9,"div",2)(10,"span",3),y(11,"Roles"),u(),d(12,"p-cascadeselect",4),z("ngModelChange",function(_){return h(a),q(o.filter().Role,_)||(o.filter().Role=_),m(_)}),u()()(),d(13,"content")(14,"div",5)(15,"div",6)(16,"div",7)(17,"table",8)(18,"thead",9)(19,"tr"),f(20,Rn,4,0,"ng-container",1),d(21,"th",10),y(22,"Name"),u(),d(23,"th"),y(24,"Description"),u(),d(25,"th"),y(26,"Role Count"),u()()(),d(27,"tbody"),Ke(28,qn,10,6,"tr",null,Ae),u()(),d(30,"app-mat-paginator-no-count",11),b("next",function(){return h(a),m(o.onNextPage())})("previous",function(){return h(a),m(o.onPrevPage())}),u()()()()()()}if(n&2){let a=Ne(re(1,14,o.groups$)),r=re(3,17,o.groupLoader$);l(4),c("hideSearchBox",!0)("hideSearchDropdown",!0),l(2),c("ngxPermissionsOnly",o.userDeleteRole),l(),c("ngxPermissionsOnly",o.userCreateRole),l(5),se(Oe(19,Pn)),c("options",r==null?null:r.Options),H("ngModel",o.filter().Role),c("optionGroupChildren",Oe(20,Gn)),l(8),c("ngxPermissionsOnly",o.userDeleteRole),l(8),Re(a==null?null:a.Data),l(2),c("filter",o.filter())("totaldata",a==null||a.Data==null?null:a.Data.length)("paginationTotal",a==null?null:a.Count)("hasClicked",!0)}},dependencies:[X,at,ot,Ue,We,Tt,kt,Y,it,nt,Ze,Xe,Je,Ye,ze,Qe],styles:["p-cascadeselect>.p-cascadeselect{width:100%}"]});let i=s;return i})();export{Ni as GroupsComponent};
|
|
264
|
+
`,Vn={root:({instance:i})=>({position:i.$appendTo()==="self"?"relative":void 0})},Mn={root:({instance:i})=>["p-cascadeselect p-component p-inputwrapper",{"p-cascadeselect p-component p-inputwrapper":!0,"p-cascadeselect-clearable":i.showClear&&!i.$disabled(),"p-cascadeselect-mobile":i.queryMatches(),"p-disabled":i.$disabled(),"p-invalid":i.invalid(),"p-focus":i.focused,"p-inputwrapper-filled":i.modelValue(),"p-variant-filled":i.$variant()==="filled","p-inputwrapper-focus":i.focused||i.overlayVisible,"p-cascadeselect-open":i.overlayVisible,"p-cascadeselect-fluid":i.hasFluid,"p-cascadeselect-sm p-inputfield-sm":i.size()==="small","p-cascadeselect-lg p-inputfield-lg":i.size()==="large"}],label:({instance:i})=>["p-cascadeselect-label",{"p-placeholder":i.label()===i.placeholder,"p-cascadeselect-label-empty":!i.value&&(i.label()==="p-emptylabel"||i.label().length===0)}],clearIcon:"p-cascadeselect-clear-icon",dropdown:"p-cascadeselect-dropdown",loadingIcon:"p-cascadeselect-loading-icon",dropdownIcon:"p-cascadeselect-dropdown-icon",overlay:({instance:i})=>["p-cascadeselect-overlay p-component-overlay p-component",{"p-cascadeselect-mobile-active":i.queryMatches()}],listContainer:"p-cascadeselect-list-container",list:"p-cascadeselect-list",option:({instance:i,processedOption:s})=>["p-cascadeselect-option",{"p-cascadeselect-option-group":i.isOptionGroup(s),"p-cascadeselect-option-active":i.isOptionActive(s),"p-cascadeselect-option-selected":i.isOptionSelected(s),"p-focus":i.isOptionFocused(s),"p-disabled":i.isOptionDisabled(s)}],optionContent:"p-cascadeselect-option-content",optionText:"p-cascadeselect-option-text",groupIcon:"p-cascadeselect-group-icon",optionList:"p-cascadeselect-list p-cascadeselect-overlay p-cascadeselect-option-list"},he=(()=>{class i extends pt{name="cascadeselect";style=Tn;classes=Mn;inlineStyles=Vn;static \u0275fac=(()=>{let e;return function(n){return(e||(e=Pe(i)))(n||i)}})();static \u0275prov=Le({token:i,factory:i.\u0275fac})}return i})();var Vt=new Ge("CASCADESELECT_INSTANCE"),kn={provide:dt,useExisting:Ee(()=>Y),multi:!0},En=(()=>{class i extends _t{cascadeselect;selectId;activeOptionPath;optionDisabled;focusedOptionId;options;optionGroupChildren;optionTemplate;groupicon;level=0;optionLabel;optionValue;optionGroupLabel;dirty;root;onChange=new O;onFocusChange=new O;onFocusEnterChange=new O;_componentStyle=T(he);constructor(e){super(),this.cascadeselect=e}getPTOptions(e,t,n){return this.ptm(n,{context:{option:e,index:t,level:this.level,optionGroup:this.isOptionGroup(e),active:this.isOptionActive(e),focused:this.isOptionFocused(e),disabled:this.isOptionDisabled(e)}})}onInit(){this.root||this.position()}onOptionClick(e,t){this.onChange.emit({originalEvent:e,processedOption:t,isFocus:!0})}onOptionMouseEnter(e,t){this.onFocusEnterChange.emit({originalEvent:e,processedOption:t})}onOptionMouseMove(e,t){this.onFocusChange.emit({originalEvent:e,processedOption:t})}getOptionId(e){return`${this.selectId}_${e.key}`}getOptionLabel(e){return this.optionLabel?k(e.option,this.optionLabel):e.option}getOptionValue(e){return this.optionValue?k(e.option,this.optionValue):e.option}getOptionLabelToRender(e){return this.isOptionGroup(e)?this.getOptionGroupLabel(e):this.getOptionLabel(e)}isOptionDisabled(e){return this.optionDisabled?k(e.option,this.optionDisabled):!1}getOptionGroupLabel(e){return this.optionGroupLabel?k(e.option,this.optionGroupLabel):null}getOptionGroupChildren(e){return e.children}isOptionGroup(e){return v(e.children)}isOptionSelected(e){return Se(this.cascadeselect?.modelValue(),e?.option)}isOptionActive(e){return this.activeOptionPath.some(t=>t.key===e.key)}isOptionFocused(e){return this.focusedOptionId===this.getOptionId(e)}position(){let e=this.el.nativeElement.parentElement,t=ot(e),n=Ze(),o=this.el.nativeElement.childNodes[0].offsetParent?this.el.nativeElement.children[0].offsetWidth:it(this.el.nativeElement.children[0]),a=et(e.children[0]);parseInt(t.left,10)+a+o>n.width-tt()&&(this.el.nativeElement.children[0].style.left="-200%")}static \u0275fac=function(t){return new(t||i)(fe(Y))};static \u0275cmp=$({type:i,selectors:[["ul","pCascadeSelectSub",""]],inputs:{selectId:"selectId",activeOptionPath:"activeOptionPath",optionDisabled:"optionDisabled",focusedOptionId:"focusedOptionId",options:"options",optionGroupChildren:"optionGroupChildren",optionTemplate:"optionTemplate",groupicon:"groupicon",level:[2,"level","level",xe],optionLabel:"optionLabel",optionValue:"optionValue",optionGroupLabel:"optionGroupLabel",dirty:[2,"dirty","dirty",M],root:[2,"root","root",M]},outputs:{onChange:"onChange",onFocusChange:"onFocusChange",onFocusEnterChange:"onFocusEnterChange"},features:[Q([he,{provide:Ve,useExisting:i}]),ge],attrs:Lt,decls:1,vars:1,consts:[["defaultOptionTemplate",""],["ngFor","",3,"ngForOf"],["role","treeitem",3,"pBind","id"],["pRipple","",3,"click","mouseenter","mousemove","pBind"],[4,"ngIf","ngIfElse"],[3,"class","pBind",4,"ngIf"],["pCascadeSelectSub","",3,"attrrole","class","selectId","focusedOptionId","activeOptionPath","options","optionLabel","optionValue","level","optionGroupLabel","optionGroupChildren","dirty","optionTemplate","pBind","pt","onChange","onFocusChange","onFocusEnterChange",4,"ngIf"],[4,"ngTemplateOutlet","ngTemplateOutletContext"],[3,"pBind"],["data-p-icon","angle-right",3,"pBind",4,"ngIf"],[4,"ngTemplateOutlet"],["data-p-icon","angle-right",3,"pBind"],["pCascadeSelectSub","",3,"onChange","onFocusChange","onFocusEnterChange","attrrole","selectId","focusedOptionId","activeOptionPath","options","optionLabel","optionValue","level","optionGroupLabel","optionGroupChildren","dirty","optionTemplate","pBind","pt"]],template:function(t,n){t&1&&f(0,Ht,7,18,"ng-template",1),t&2&&c("ngForOf",n.options)},dependencies:[i,X,He,Ie,we,wt,Ot,J,N],encapsulation:2,changeDetection:0})}return i})(),Y=(()=>{class i extends bt{overlayService;$pcCascadeSelect=T(Vt,{optional:!0,skipSelf:!0})??void 0;bindDirectiveInstance=T(N,{self:!0});onAfterViewChecked(){this.bindDirectiveInstance.setAttrs(this.ptms(["host","root"]))}id;searchMessage;emptyMessage;selectionMessage;emptySearchMessage;emptySelectionMessage;searchLocale;optionDisabled;focusOnHover=!0;selectOnFocus=!1;autoOptionFocus=!1;styleClass;options;optionLabel;optionValue;optionGroupLabel;optionGroupChildren;placeholder;value;dataKey;inputId;tabindex=0;ariaLabelledBy;inputLabel;ariaLabel;showClear=!1;panelStyleClass;panelStyle;overlayOptions;autofocus;loading=!1;loadingIcon;breakpoint="960px";size=j();variant=j();fluid=j(void 0,{transform:M});appendTo=j(void 0);onChange=new O;onGroupChange=new O;onShow=new O;onHide=new O;onClear=new O;onBeforeShow=new O;onBeforeHide=new O;onFocus=new O;onBlur=new O;focusInputViewChild;panelViewChild;overlayViewChild;valueTemplate;optionTemplate;headerTemplate;footerTemplate;triggerIconTemplate;loadingIconTemplate;groupIconTemplate;clearIconTemplate;_valueTemplate;_optionTemplate;_headerTemplate;_footerTemplate;_triggerIconTemplate;_loadingIconTemplate;_groupIconTemplate;_clearIconTemplate;selectionPath=null;focused=!1;overlayVisible=!1;clicked=!1;dirty=!1;searchValue;searchTimeout;focusedOptionInfo=E({index:-1,level:0,parentKey:""});activeOptionPath=E([]);processedOptions=[];_componentStyle=T(he);initialized=!1;$variant=U(()=>this.variant()||this.config.inputStyle()||this.config.inputVariant());$appendTo=U(()=>this.appendTo()||this.config.overlayAppendTo());pcFluid=T(vt,{optional:!0,host:!0,skipSelf:!0});get hasFluid(){return this.fluid()??!!this.pcFluid}onHostClick(e){this.onContainerClick(e)}get listLabel(){return this.config.getTranslation(rt.ARIA).listLabel}get focusedOptionId(){return this.focusedOptionInfo().index!==-1?`${this.id}${v(this.focusedOptionInfo().parentKey)?"_"+this.focusedOptionInfo().parentKey:""}_${this.focusedOptionInfo().index}`:null}get searchResultMessageText(){return v(this.visibleOptions())?this.searchMessageText.replaceAll("{0}",this.visibleOptions().length):this.emptySearchMessageText}get searchMessageText(){return this.searchMessage||this.config.translation.searchMessage||""}get emptySearchMessageText(){return this.emptySearchMessage||this.config.translation.emptySearchMessage||""}get emptyMessageText(){return this.emptyMessage||this.config.translation.emptyMessage||""}get selectionMessageText(){return this.selectionMessage||this.config.translation.selectionMessage||""}get emptySelectionMessageText(){return this.emptySelectionMessage||this.config.translation.emptySelectionMessage||""}get selectedMessageText(){return this.hasSelectedOption()?this.selectionMessageText.replaceAll("{0}","1"):this.emptySelectionMessageText}visibleOptions=U(()=>{let e=this.activeOptionPath().find(t=>t.key===this.focusedOptionInfo().parentKey);return e?e.children:this.processedOptions});label=U(()=>{let e=this.placeholder||"p-emptylabel";if(this.hasSelectedOption()){let t=this.findOptionPathByValue(this.modelValue(),null),n=v(t)?t[t.length-1]:null;return n?this.getOptionLabel(n.option):e}return e});get _label(){let e=this.placeholder||"p-emptylabel";if(this.hasSelectedOption()){let t=this.findOptionPathByValue(this.modelValue(),null),n=v(t)?t[t.length-1]:null;return n?this.getOptionLabel(n.option):e}return e}templates;onAfterContentInit(){this.templates.forEach(e=>{switch(e.getType()){case"value":this._valueTemplate=e.template;break;case"option":this._optionTemplate=e.template;break;case"header":this._headerTemplate=e.template;break;case"footer":this._footerTemplate=e.template;break;case"triggericon":this._triggerIconTemplate=e.template;break;case"loadingicon":this._loadingIconTemplate=e.template;break;case"clearicon":this._clearIconTemplate=e.template;break;case"optiongroupicon":this._groupIconTemplate=e.template;break}})}onChanges(e){e.options&&(this.processedOptions=this.createProcessedOptions(e.options.currentValue||[]),this.updateModel(null))}hasSelectedOption(){return v(this.modelValue())}createProcessedOptions(e,t=0,n={},o=""){let a=[];return e&&e.forEach((r,_)=>{let P=(o!==""?o+"_":"")+_,L={option:r,index:_,level:t,key:P,parent:n,parentKey:o};L.children=this.createProcessedOptions(this.getOptionGroupChildren(r,t),t+1,L,P),a.push(L)}),a}onInputFocus(e){this.$disabled()||(this.focused=!0,this.onFocus.emit(e))}onInputBlur(e){this.focused=!1,this.focusedOptionInfo.set({indeX:-1,level:0,parentKey:""}),this.searchValue="",this.onModelTouched(),this.onBlur.emit(e)}onInputKeyDown(e){if(this.$disabled()||this.loading){e.preventDefault();return}let t=e.metaKey||e.ctrlKey;switch(e.code){case"ArrowDown":this.onArrowDownKey(e);break;case"ArrowUp":this.onArrowUpKey(e);break;case"ArrowLeft":this.onArrowLeftKey(e);break;case"ArrowRight":this.onArrowRightKey(e);break;case"Home":this.onHomeKey(e);break;case"End":this.onEndKey(e);break;case"Space":this.onSpaceKey(e);break;case"Enter":case"NumpadEnter":this.onEnterKey(e);break;case"Escape":this.onEscapeKey(e);break;case"Tab":this.onTabKey(e);break;case"Backspace":this.onBackspaceKey(e);break;case"PageDown":case"PageUp":case"ShiftLeft":case"ShiftRight":break;default:!t&&at(e.key)&&(!this.overlayVisible&&this.show(),this.searchOptions(e,e.key));break}this.clicked=!1}onArrowDownKey(e){if(!this.overlayVisible)this.show();else{let t=this.focusedOptionInfo().index!==-1?this.findNextOptionIndex(this.focusedOptionInfo().index):this.clicked?this.findFirstOptionIndex():this.findFirstFocusedOptionIndex();this.changeFocusedOptionIndex(e,t,!0)}e.preventDefault()}onArrowUpKey(e){if(e.altKey){if(this.focusedOptionInfo().index!==-1){let t=this.visibleOptions[this.focusedOptionInfo().index];!this.isProccessedOptionGroup(t)&&this.onOptionChange({originalEvent:e,processedOption:t})}this.overlayVisible&&this.hide(),e.preventDefault()}else{let t=this.focusedOptionInfo().index!==-1?this.findPrevOptionIndex(this.focusedOptionInfo().index):this.clicked?this.findLastOptionIndex():this.findLastFocusedOptionIndex();this.changeFocusedOptionIndex(e,t,!0),!this.overlayVisible&&this.show(),e.preventDefault()}}onArrowLeftKey(e){if(this.overlayVisible){let t=this.visibleOptions()[this.focusedOptionInfo().index],n=this.activeOptionPath().find(r=>r.key===t.parentKey),o=this.focusedOptionInfo().parentKey===""||n&&n.key===this.focusedOptionInfo().parentKey,a=de(t.parent);if(o){let r=this.activeOptionPath().filter(_=>_.parentKey!==this.focusedOptionInfo().parentKey);this.activeOptionPath.set(r)}a||(this.focusedOptionInfo.set({index:-1,parentKey:n?n.parentKey:""}),this.searchValue="",this.onArrowDownKey(e)),e.preventDefault()}}onArrowRightKey(e){if(this.overlayVisible){let t=this.visibleOptions()[this.focusedOptionInfo().index];this.isProccessedOptionGroup(t)&&(this.activeOptionPath().some(a=>t.key===a.key)?(this.focusedOptionInfo.set({index:-1,parentKey:t.key}),this.searchValue="",this.onArrowDownKey(e)):this.onOptionChange({originalEvent:e,processedOption:t})),e.preventDefault()}}onHomeKey(e){this.changeFocusedOptionIndex(e,this.findFirstOptionIndex()),!this.overlayVisible&&this.show(),e.preventDefault()}onEndKey(e){this.changeFocusedOptionIndex(e,this.findLastOptionIndex()),!this.overlayVisible&&this.show(),e.preventDefault()}onEnterKey(e){if(!this.overlayVisible)this.focusedOptionInfo.set(G(F({},this.focusedOptionInfo()),{index:-1})),this.onArrowDownKey(e);else if(this.focusedOptionInfo().index!==-1){let t=this.visibleOptions()[this.focusedOptionInfo().index],n=this.isProccessedOptionGroup(t);this.onOptionClick({originalEvent:e,processedOption:t}),!n&&this.hide()}e.preventDefault()}onSpaceKey(e){this.onEnterKey(e)}onEscapeKey(e){this.overlayVisible&&this.hide(e,!0),e.preventDefault()}onTabKey(e){if(this.focusedOptionInfo().index!==-1){let t=this.visibleOptions()[this.focusedOptionInfo().index];!this.isProccessedOptionGroup(t)&&this.onOptionChange({originalEvent:e,processedOption:t})}this.overlayVisible&&this.hide()}onBackspaceKey(e){v(this.modelValue())&&this.showClear&&this.clear(),e.stopPropagation()}equalityKey(){return this.optionValue?void 0:this.dataKey}updateModel(e,t){this.value=e,this.onModelChange(e),this.writeModelValue(e),this.initialized&&this.onChange.emit({originalEvent:t,value:e})}autoUpdateModel(){this.selectOnFocus&&this.autoOptionFocus&&!this.hasSelectedOption()&&(this.focusedOptionInfo().index=this.findFirstFocusedOptionIndex(),this.onOptionChange({originalEvent:null,processedOption:this.visibleOptions()[this.focusedOptionInfo().index],isHide:!1}),!this.overlayVisible&&this.focusedOptionInfo.set({index:-1,level:0,parentKey:""}))}scrollInView(e=-1){let t=e!==-1?`${this.id}_${e}`:this.focusedOptionId,n=nt(this.panelViewChild?.nativeElement,`li[id="${t}"]`);n&&n.scrollIntoView&&n.scrollIntoView({block:"nearest",inline:"start"})}changeFocusedOptionIndex(e,t,n){let o=this.focusedOptionInfo();o.index!==t&&(this.focusedOptionInfo.set(G(F({},o),{index:t})),this.scrollInView(),this.focusOnHover&&this.onOptionClick({originalEvent:e,processedOption:this.visibleOptions()[t],isHide:!1,preventSelection:n}),this.selectOnFocus&&this.onOptionChange({originalEvent:e,processedOption:this.visibleOptions()[t],isHide:!1}))}matchMediaListener;onOptionSelect(e){let{originalEvent:t,value:n,isHide:o}=e,a=this.getOptionValue(n),r=this.activeOptionPath();r.forEach(_=>_.selected=!0),this.activeOptionPath.set(r),this.updateModel(a,t),o&&this.hide(e,!0)}onOptionGroupSelect(e){this.dirty=!0,this.onGroupChange.emit(e)}onContainerClick(e){this.$disabled()||this.loading||(this.overlayViewChild?.el?.nativeElement?.contains(e.target)||(this.overlayVisible?this.hide():this.show(),this.focusInputViewChild?.nativeElement.focus()),this.clicked=!0)}isOptionMatched(e){return this.isValidOption(e)&&this.getProccessedOptionLabel(e).toLocaleLowerCase(this.searchLocale).startsWith(this.searchValue?.toLocaleLowerCase(this.searchLocale))}isOptionDisabled(e){return this.optionDisabled?k(e,this.optionDisabled):!1}isValidOption(e){return!!e&&!this.isOptionDisabled(e.option)}isValidSelectedOption(e){return this.isValidOption(e)&&this.isSelected(e)}isSelected(e){return this.activeOptionPath().some(t=>t.key===e.key)}findOptionPathByValue(e,t,n=0){if(t=t||n===0&&this.processedOptions,!t)return null;if(de(e))return[];for(let o=0;o<t.length;o++){let a=t[o];if(Se(e,this.getOptionValue(a.option),this.equalityKey()))return[a];let r=this.findOptionPathByValue(e,a.children,n+1);if(r)return r.unshift(a),r}}findFirstOptionIndex(){return this.visibleOptions().findIndex(e=>this.isValidOption(e))}findLastOptionIndex(){return Te(this.visibleOptions(),e=>this.isValidOption(e))}findNextOptionIndex(e){let t=e<this.visibleOptions().length-1?this.visibleOptions().slice(e+1).findIndex(n=>this.isValidOption(n)):-1;return t>-1?t+e+1:e}findPrevOptionIndex(e){let t=e>0?Te(this.visibleOptions().slice(0,e),n=>this.isValidOption(n)):-1;return t>-1?t:e}findSelectedOptionIndex(){return this.visibleOptions().findIndex(e=>this.isValidSelectedOption(e))}findFirstFocusedOptionIndex(){let e=this.findSelectedOptionIndex();return e<0?this.findFirstOptionIndex():e}findLastFocusedOptionIndex(){let e=this.findSelectedOptionIndex();return e<0?this.findLastOptionIndex():e}searchOptions(e,t){this.searchValue=(this.searchValue||"")+t;let n=-1,o=!1,a=this.focusedOptionInfo();return a.index!==-1?(n=this.visibleOptions().slice(a.index).findIndex(r=>this.isOptionMatched(r)),n=n===-1?this.visibleOptions().slice(0,a.index).findIndex(r=>this.isOptionMatched(r)):n+a.index):n=this.visibleOptions().findIndex(r=>this.isOptionMatched(r)),n!==-1&&(o=!0),n===-1&&a.index===-1&&(n=this.findFirstFocusedOptionIndex()),n!==-1&&this.changeFocusedOptionIndex(e,n),this.searchTimeout&&clearTimeout(this.searchTimeout),this.searchTimeout=setTimeout(()=>{this.searchValue="",this.searchTimeout=null},500),o}hide(e,t=!1){let n=()=>{this.overlayVisible=!1,this.clicked=!1,this.activeOptionPath.set([]),this.focusedOptionInfo.set({index:-1,level:0,parentKey:""}),t&&pe(this.focusInputViewChild?.nativeElement),this.onHide.emit(e),this.cd.markForCheck()};setTimeout(()=>{n()},0)}show(e,t=!1){this.onShow.emit(e),this.overlayVisible=!0;let n=this.hasSelectedOption()?this.findOptionPathByValue(this.modelValue()):this.activeOptionPath();this.activeOptionPath.set(n);let o;if(this.hasSelectedOption()&&v(this.activeOptionPath())){let a=this.activeOptionPath()[this.activeOptionPath().length-1];o={index:a.index,level:a.level,parentKey:a.parentKey}}else o={index:this.autoOptionFocus?this.findFirstFocusedOptionIndex():this.findSelectedOptionIndex(),level:0,parentKey:""};this.focusedOptionInfo.set(o),t&&pe(this.focusInputViewChild?.nativeElement)}clear(e){v(this.modelValue())&&this.showClear&&(this.updateModel(null),this.focusedOptionInfo.set({index:-1,level:0,parentKey:""}),this.activeOptionPath.set([]),this.onClear.emit(e)),e&&e.stopPropagation()}getOptionLabel(e){return this.optionLabel?k(e,this.optionLabel):e}getOptionValue(e){return this.optionValue?k(e,this.optionValue):e}getOptionGroupLabel(e){return this.optionGroupLabel?k(e,this.optionGroupLabel):null}getOptionGroupChildren(e,t){return k(e,this.optionGroupChildren?.[t])}isOptionGroup(e,t){return Object.prototype.hasOwnProperty.call(e,this.optionGroupChildren?.[t])}isProccessedOptionGroup(e){return v(e?.children)}getProccessedOptionLabel(e){return this.isProccessedOptionGroup(e)?this.getOptionGroupLabel(e.option):this.getOptionLabel(e.option)}constructor(e){super(),this.overlayService=e,$e(()=>{let t=this.activeOptionPath();v(t)&&this.overlayViewChild?.alignOverlay()})}query;queryMatches=E(!1);mobileActive=E(!1);onOptionChange(e){let{processedOption:t,type:n}=e;if(de(t))return;let{index:o,key:a,level:r,parentKey:_,children:P}=t,L=v(P),K=this.activeOptionPath().filter(Z=>Z.parentKey!==_&&Z.parentKey!==a);this.focusedOptionInfo.set({index:o,level:r,parentKey:_}),!(n=="hover"&&this.queryMatches())&&(L&&K.push(t),this.activeOptionPath.set([...K]))}onOptionClick(e){let{originalEvent:t,processedOption:n,isFocus:o,isHide:a,preventSelection:r}=e,{index:_,key:P,level:L,parentKey:K}=n,Z=this.isProccessedOptionGroup(n);if(this.isSelected(n)){let ee=this.activeOptionPath().filter(te=>P!==te.key&&P.startsWith(te.key));this.activeOptionPath.set([...ee]),this.focusedOptionInfo.set({index:_,level:L,parentKey:K})}else if(Z)this.onOptionChange(e),this.onOptionGroupSelect({originalEvent:t,value:n.option,isFocus:!1});else{let ee=this.activeOptionPath().filter(te=>te.parentKey!==K);ee.push(n),this.focusedOptionInfo.set({index:_,level:L,parentKey:K}),(!r||n?.children.length!==0)&&(this.activeOptionPath.set([...ee]),this.onOptionSelect({originalEvent:t,value:n.option,isHide:o}))}o&&pe(this.focusInputViewChild?.nativeElement)}onOptionMouseEnter(e){this.focusOnHover&&(this.dirty||!this.dirty&&v(this.modelValue())?this.onOptionChange(G(F({},e),{type:"hover"})):!this.dirty&&e.processedOption.level===0&&this.onOptionClick(G(F({},e),{type:"hover"})))}onOptionMouseMove(e){this.focused&&this.focusOnHover&&this.changeFocusedOptionIndex(e,e.processedOption.index)}onInit(){this.id=this.id||st("pn_id_"),this.autoUpdateModel(),this.bindMatchMediaListener()}onAfterViewInit(){this.initialized=!0}bindMatchMediaListener(){if(!this.matchMediaListener){let e=this.document.defaultView;if(e&&e.matchMedia){let t=e.matchMedia(`(max-width: ${this.breakpoint})`);this.query=t,this.queryMatches.set(t?.matches),this.matchMediaListener=()=>{this.queryMatches.set(t?.matches),this.mobileActive.set(!1)},this.query.addEventListener("change",this.matchMediaListener)}}}unbindMatchMediaListener(){this.matchMediaListener&&(this.query.removeEventListener("change",this.matchMediaListener),this.matchMediaListener=null)}onOverlayAnimationDone(e){switch(e.toState){case"void":this.dirty=!1;break}}writeControlValue(e,t){this.value=e,t(e),this.cd.markForCheck()}onDestroy(){this.matchMediaListener&&this.unbindMatchMediaListener()}static \u0275fac=function(t){return new(t||i)(fe(ct))};static \u0275cmp=$({type:i,selectors:[["p-cascadeSelect"],["p-cascadeselect"],["p-cascade-select"]],contentQueries:function(t,n,o){if(t&1&&(V(o,qt,4),V(o,zt,4),V(o,Qt,4),V(o,Wt,4),V(o,Ut,4),V(o,jt,4),V(o,Xt,4),V(o,Jt,4),V(o,lt,4)),t&2){let a;C(a=x())&&(n.valueTemplate=a.first),C(a=x())&&(n.optionTemplate=a.first),C(a=x())&&(n.headerTemplate=a.first),C(a=x())&&(n.footerTemplate=a.first),C(a=x())&&(n.triggerIconTemplate=a.first),C(a=x())&&(n.loadingIconTemplate=a.first),C(a=x())&&(n.groupIconTemplate=a.first),C(a=x())&&(n.clearIconTemplate=a.first),C(a=x())&&(n.templates=a)}},viewQuery:function(t,n){if(t&1&&(oe(Yt,5),oe(Zt,5),oe(en,5)),t&2){let o;C(o=x())&&(n.focusInputViewChild=o.first),C(o=x())&&(n.panelViewChild=o.first),C(o=x())&&(n.overlayViewChild=o.first)}},hostVars:4,hostBindings:function(t,n){t&1&&b("click",function(a){return n.onHostClick(a)}),t&2&&(se(n.sx("root")),g(n.cn(n.cx("root"),n.styleClass)))},inputs:{id:"id",searchMessage:"searchMessage",emptyMessage:"emptyMessage",selectionMessage:"selectionMessage",emptySearchMessage:"emptySearchMessage",emptySelectionMessage:"emptySelectionMessage",searchLocale:"searchLocale",optionDisabled:"optionDisabled",focusOnHover:[2,"focusOnHover","focusOnHover",M],selectOnFocus:[2,"selectOnFocus","selectOnFocus",M],autoOptionFocus:[2,"autoOptionFocus","autoOptionFocus",M],styleClass:"styleClass",options:"options",optionLabel:"optionLabel",optionValue:"optionValue",optionGroupLabel:"optionGroupLabel",optionGroupChildren:"optionGroupChildren",placeholder:"placeholder",value:"value",dataKey:"dataKey",inputId:"inputId",tabindex:[2,"tabindex","tabindex",xe],ariaLabelledBy:"ariaLabelledBy",inputLabel:"inputLabel",ariaLabel:"ariaLabel",showClear:[2,"showClear","showClear",M],panelStyleClass:"panelStyleClass",panelStyle:"panelStyle",overlayOptions:"overlayOptions",autofocus:[2,"autofocus","autofocus",M],loading:[2,"loading","loading",M],loadingIcon:"loadingIcon",breakpoint:"breakpoint",size:[1,"size"],variant:[1,"variant"],fluid:[1,"fluid"],appendTo:[1,"appendTo"]},outputs:{onChange:"onChange",onGroupChange:"onGroupChange",onShow:"onShow",onHide:"onHide",onClear:"onClear",onBeforeShow:"onBeforeShow",onBeforeHide:"onBeforeHide",onFocus:"onFocus",onBlur:"onBlur"},features:[Q([kn,he,{provide:Ve,useExisting:i},{provide:Vt,useExisting:i}]),Be([N]),ge],decls:18,vars:36,consts:[["focusInput",""],["defaultValueTemplate",""],["elseBlock",""],["overlay",""],["content",""],["panel",""],[1,"p-hidden-accessible",3,"pBind"],["readonly","","type","text","role","combobox",3,"focus","blur","keydown","pAutoFocus","pBind"],[3,"pBind"],[4,"ngIf","ngIfElse"],[4,"ngIf"],["role","button","aria-haspopup","listbox",3,"pBind"],["role","status","aria-live","polite",1,"p-hidden-accessible",3,"pBind"],[3,"visibleChange","onAnimationDone","onBeforeShow","onShow","onBeforeHide","onHide","hostAttrSelector","visible","options","target","appendTo","pt"],[4,"ngTemplateOutlet","ngTemplateOutletContext"],["data-p-icon","times",3,"class","pBind","click",4,"ngIf"],[3,"class","pBind","click",4,"ngIf"],["data-p-icon","times",3,"click","pBind"],[3,"click","pBind"],[4,"ngTemplateOutlet"],["aria-hidden","true",3,"class","pBind",4,"ngIf"],["aria-hidden","true",3,"pBind"],["data-p-icon","chevron-down",3,"class","pBind",4,"ngIf"],[3,"class","pBind",4,"ngIf"],["data-p-icon","chevron-down",3,"pBind"],[3,"ngStyle","pBind"],["pCascadeSelectSub","",3,"onChange","onFocusChange","onFocusEnterChange","options","selectId","focusedOptionId","activeOptionPath","optionLabel","optionValue","level","optionTemplate","groupicon","optionGroupLabel","optionGroupChildren","optionDisabled","root","dirty","pBind","pt"]],template:function(t,n){if(t&1){let o=S();d(0,"div",6)(1,"input",7,0),b("focus",function(r){return h(o),m(n.onInputFocus(r))})("blur",function(r){return h(o),m(n.onInputBlur(r))})("keydown",function(r){return h(o),m(n.onInputKeyDown(r))}),u()(),d(3,"span",8),f(4,on,2,5,"ng-container",9)(5,an,1,1,"ng-template",null,1,W),u(),f(7,pn,3,2,"ng-container",10),d(8,"div",11),f(9,gn,3,2,"ng-container",9)(10,On,2,2,"ng-template",null,2,W),u(),d(12,"span",12),y(13),u(),d(14,"p-overlay",13,3),z("visibleChange",function(r){return h(o),q(n.overlayVisible,r)||(n.overlayVisible=r),m(r)}),b("onAnimationDone",function(r){return h(o),m(n.onOverlayAnimationDone(r))})("onBeforeShow",function(r){return h(o),m(n.onBeforeShow.emit(r))})("onShow",function(r){return h(o),m(n.show(r))})("onBeforeHide",function(r){return h(o),m(n.onBeforeHide.emit(r))})("onHide",function(r){return h(o),m(n.hide(r))}),f(16,Sn,8,32,"ng-template",null,4,W),u()}if(t&2){let o=ae(6),a=ae(11);c("pBind",n.ptm("hiddenInputWrapper")),l(),c("pAutoFocus",n.autofocus)("pBind",n.ptm("hiddenInput")),D("name",n.name())("required",n.required()?"":void 0)("disabled",n.$disabled()?"":void 0)("placeholder",n.placeholder)("tabindex",n.$disabled()?-1:n.tabindex)("id",n.inputId)("aria-label",n.ariaLabel)("aria-labelledby",n.ariaLabelledBy)("aria-haspopup","tree")("aria-expanded",n.overlayVisible??!1)("aria-controls",n.overlayVisible?n.id+"_tree":null)("aria-activedescendant",n.focused?n.focusedOptionId:void 0),l(2),g(n.cx("label")),c("pBind",n.ptm("label")),l(),c("ngIf",n.valueTemplate||n._valueTemplate)("ngIfElse",o),l(3),c("ngIf",n.$filled()&&!n.$disabled()&&n.showClear),l(),g(n.cx("dropdown")),c("pBind",n.ptm("dropdown")),D("aria-expanded",n.overlayVisible??!1)("aria-hidden",!0),l(),c("ngIf",n.loading)("ngIfElse",a),l(3),c("pBind",n.ptm("hiddenSearchResult")),l(),A(" ",n.searchResultMessageText," "),l(),c("hostAttrSelector",n.$attrSelector),H("visible",n.overlayVisible),c("options",n.overlayOptions)("target","@parent")("appendTo",n.$appendTo())("pt",n.ptm("pcOverlay"))}},dependencies:[X,Ie,we,qe,It,yt,En,Ct,xt,J,N],encapsulation:2,changeDetection:0})}return i})(),Mt=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275mod=De({type:i});static \u0275inj=Fe({imports:[Y,J,J]})}return i})();var Fn=()=>({minWidth:"100%"}),Gn=()=>["Roles"],Pn=i=>({ID:i});function Dn(i,s){if(i&1){let e=S();d(0,"button",13),b("click",function(){h(e);let n=p(2);return m(n.onDeleteGroup())}),B(1,"i",14),y(2),u()}if(i&2){let e,t=p(2);l(2),A(" Delete (",(e=t.selectedGroups())==null?null:e.length,") ")}}function Bn(i,s){if(i&1&&(I(0),_e(1,Dn,3,1,"button",12),w()),i&2){let e,t=p();l(),ye(((e=t.selectedGroups())==null?null:e.length)>0?1:-1)}}function An(i,s){i&1&&(I(0),d(1,"a",15),y(2," Add"),u(),w())}function Kn(i,s){if(i&1){let e=S();I(0),d(1,"th",16)(2,"div",17)(3,"input",18),b("change",function(n){h(e);let o=p(),a=ve(0);return m(o.onCheckAllGroups(n==null||n.target==null?null:n.target.checked,a==null?null:a.Data))}),u()()(),w()}}function Rn(i,s){if(i&1){let e=S();I(0),d(1,"td")(2,"div",17)(3,"input",20),z("ngModelChange",function(n){h(e);let o=p().$implicit;return q(o.checked,n)||(o.checked=n),m(n)}),b("ngModelChange",function(){h(e);let n=p(2),o=ve(0);return m(n.onSelectGroup(o==null?null:o.Data))}),u()()(),w()}if(i&2){let e=p().$implicit;l(3),H("ngModel",e.checked)}}function Nn(i,s){if(i&1&&(d(0,"a",19),y(1),u()),i&2){let e=p().$implicit;c("queryParams",ce(2,Pn,e.ID)),l(),A(" ",e.Name," ")}}function $n(i,s){if(i&1&&(d(0,"span"),y(1),u()),i&2){let e=p().$implicit;l(),R(e.Name)}}function Hn(i,s){if(i&1&&(d(0,"tr"),f(1,Rn,4,1,"ng-container",1),d(2,"td"),_e(3,Nn,2,4,"a",19)(4,$n,2,1,"span"),u(),d(5,"td"),y(6),u(),d(7,"td"),y(8),le(9,"number"),u()()),i&2){let e=s.$implicit,t=p();l(),c("ngxPermissionsOnly",t.userDeleteRole),l(2),ye(t.hasUserEditRole()?3:4),l(3),R(e.Description),l(2),R(re(9,4,e.Count))}}var Ki=(()=>{let s=class s{constructor(){this.permissionService=T(Xe),this.groupsService=T(Me),this.toastr=T(We),this.groupLoader$=this.groupsService.getGroupsLoader().pipe(me(1)),this.groups$=ke({Count:0,Data:[]}),this.filter=E({PageNumber:1,PageSize:100,Role:null}),this.selectedGroups=E([]),this.userCreateRole=ue.UserInvite,this.userDeleteRole=ue.UserDelete,this.hasUserEditRole=E(!1),this.initGroup(),this.permissionService.hasPermission(ue.UserEdit).then(t=>{this.hasUserEditRole.set(t)})}initGroup(){this.groups$=this.groupsService.getGroups(this.filter()).pipe(me(1))}onCheckAllGroups(t,n){n.forEach(a=>{a.checked=t});let o=n.filter(a=>a.checked);this.selectedGroups.set(o)}onSelectGroup(t){this.selectedGroups.set(t.filter(n=>n.checked))}onDeleteGroup(){if(confirm("Are you sure you want to delete the selected groups?")){let n=this.selectedGroups().map(o=>o.ID);this.groupsService.deleteGroups(n).subscribe({next:()=>{this.selectedGroups.set([]),this.toastr.success("Groups deleted successfully","Success"),this.initGroup()}})}}onNextPage(){this.filter.update(t=>G(F({},t),{PageNumber:t.PageNumber+1})),this.initGroup()}onPrevPage(){this.filter.update(t=>G(F({},t),{PageNumber:t.PageNumber-1})),this.initGroup()}onFilter(){this.initGroup()}};s.\u0275fac=function(n){return new(n||s)},s.\u0275cmp=$({type:s,selectors:[["app-groups"]],features:[Q([Me])],decls:31,vars:21,consts:[["headerTitle","Groups",3,"onSubmit","hideSearchBox","hideSearchDropdown"],[4,"ngxPermissionsOnly"],[1,"w-100"],[1,"d-block","fs-5","mb-2"],["appendTo","body","optionLabel","Name","optionGroupLabel","Name","optionValue","ID","placeholder","Select a Role",3,"ngModelChange","options","ngModel","optionGroupChildren"],[1,"container-fluid"],[1,"row","mt-6"],[1,"col-12"],[1,"table"],[1,"thead-light","sticky-top-thead"],[2,"width","15%"],[3,"next","previous","filter","totaldata","paginationTotal","hasClicked"],[1,"btn","btn-danger","me-3"],[1,"btn","btn-danger","me-3",3,"click"],[1,"fa","fa-trash","me-1"],["routerLink","/menu/users/groups/form",1,"btn","btn-success"],[2,"width","5px"],[1,"d-flex"],["type","checkbox",3,"change"],["routerLink","/menu/users/groups/info",3,"queryParams"],["type","checkbox",3,"ngModelChange","ngModel"]],template:function(n,o){if(n&1){let a=S();be(0),le(1,"async"),be(2),le(3,"async"),d(4,"mainpanel",0),b("onSubmit",function(){return h(a),m(o.onFilter())}),d(5,"actions"),f(6,Bn,2,1,"ng-container",1)(7,An,3,0,"ng-container",1),u(),d(8,"filters")(9,"div",2)(10,"span",3),y(11,"Roles"),u(),d(12,"p-cascadeselect",4),z("ngModelChange",function(_){return h(a),q(o.filter().Role,_)||(o.filter().Role=_),m(_)}),u()()(),d(13,"content")(14,"div",5)(15,"div",6)(16,"div",7)(17,"table",8)(18,"thead",9)(19,"tr"),f(20,Kn,4,0,"ng-container",1),d(21,"th",10),y(22,"Name"),u(),d(23,"th"),y(24,"Description"),u(),d(25,"th"),y(26,"Role Count"),u()()(),d(27,"tbody"),Ke(28,Hn,10,6,"tr",null,Ae),u()(),d(30,"app-mat-paginator-no-count",11),b("next",function(){return h(a),m(o.onNextPage())})("previous",function(){return h(a),m(o.onPrevPage())}),u()()()()()()}if(n&2){let a=Ne(re(1,14,o.groups$)),r=re(3,17,o.groupLoader$);l(4),c("hideSearchBox",!0)("hideSearchDropdown",!0),l(2),c("ngxPermissionsOnly",o.userDeleteRole),l(),c("ngxPermissionsOnly",o.userCreateRole),l(5),se(Oe(19,Fn)),c("options",r==null?null:r.Options),H("ngModel",o.filter().Role),c("optionGroupChildren",Oe(20,Gn)),l(8),c("ngxPermissionsOnly",o.userDeleteRole),l(8),Re(a==null?null:a.Data),l(2),c("filter",o.filter())("totaldata",a==null||a.Data==null?null:a.Data.length)("paginationTotal",a==null?null:a.Count)("hasClicked",!0)}},dependencies:[X,gt,je,Ue,St,Mt,Y,Ye,Je,ft,ut,ht,mt,ze,Qe],styles:["p-cascadeselect>.p-cascadeselect{width:100%}"]});let i=s;return i})();export{Ki as GroupsComponent};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{a as bt}from"./chunk-TOK5EWN4.js";import{c as Mt,d as Ft}from"./chunk-TZTW72NT.js";import"./chunk-VP3XO25X.js";import{a as Pt}from"./chunk-SABMHH6B.js";import"./chunk-YAWT3CLI.js";import{a as ft,b as St}from"./chunk-5C24BA5F.js";import"./chunk-LR2YCE6M.js";import"./chunk-BKR7YPEW.js";import"./chunk-C2LAQOUW.js";import{a as Ot}from"./chunk-RWPLFNHT.js";import"./chunk-MT3CWRVG.js";import"./chunk-W33M7S2S.js";import"./chunk-MTVUPPAN.js";import"./chunk-2NRHX6CZ.js";import{a as wt}from"./chunk-7KG3DC5J.js";import{a as xt}from"./chunk-5WQ3LCWP.js";import"./chunk-DLHIDOS3.js";import{a as vt}from"./chunk-27DIE2YS.js";import{a as yt}from"./chunk-AJSJJV2I.js";import"./chunk-NVPT5BF2.js";import"./chunk-QMHG3QTI.js";import"./chunk-NIJCYMZM.js";import"./chunk-UMLV2ZUF.js";import"./chunk-7X4B2T6C.js";import"./chunk-PN3KM4M4.js";import"./chunk-WIRBYT7F.js";import"./chunk-ZWUYPYHD.js";import"./chunk-WVA5LYVE.js";import"./chunk-FOKLBUX6.js";import"./chunk-BXNDE6NQ.js";import"./chunk-A6QXXKPR.js";import"./chunk-ZDBFIPDM.js";import"./chunk-DDFP4CNP.js";import"./chunk-RBZU7OVM.js";import{b as _t}from"./chunk-BUMWMFHU.js";import"./chunk-ROS2QMKF.js";import{a as mt,b as ht,c as ut,i as Ct,j as gt}from"./chunk-5WT456T7.js";import"./chunk-YNL43MLU.js";import"./chunk-RM6ZXD3O.js";import"./chunk-2ST3DMR6.js";import"./chunk-24KZDZKS.js";import"./chunk-3RK6DDJD.js";import"./chunk-A2RTZANN.js";import"./chunk-N3E43QWK.js";import"./chunk-ZC526ERX.js";import"./chunk-YD6BNJ2B.js";import"./chunk-XUDE7VBC.js";import"./chunk-X52ZT4MU.js";import"./chunk-BMOMTOEW.js";import"./chunk-HO2TMGLM.js";import"./chunk-RXC5D64C.js";import{c as pt}from"./chunk-O4D64GHO.js";import"./chunk-7R2D2JZ6.js";import{a as U}from"./chunk-ZSUWHVKX.js";import{h as at}from"./chunk-O3QPBAV5.js";import"./chunk-YYV4FSYQ.js";import"./chunk-QXRG5XYP.js";import{a as rt}from"./chunk-AGBJEXIM.js";import{a as nt,b as it,c as ot}from"./chunk-5UFP37GQ.js";import{c as f}from"./chunk-UPRDDI4K.js";import{A as dt,c as lt,h as st,m as ct}from"./chunk-WAXAIL2I.js";import"./chunk-RQUCYFCB.js";import"./chunk-RXLMJGUY.js";import{b as X,e as tt}from"./chunk-MM7SAZOU.js";import{b as et}from"./chunk-NQLMPUSB.js";import"./chunk-OSGPJXJZ.js";import{q as Z,w as Q}from"./chunk-JNRCB7N3.js";import"./chunk-XBIHN6D3.js";import{$c as q,G as L,Hb as I,Ia as x,Nb as G,Nc as g,Oc as R,Pc as $,Rc as y,Sc as w,Tc as F,Uc as j,ac as M,ad as b,cc as O,dc as H,ea as W,ec as J,fc as N,gc as V,hc as u,ic as a,id as z,jc as s,jd as Y,kc as T,ob as l,oc as E,pc as k,ra as _,rc as P,wc as S,ya as m,yc as C,za as h}from"./chunk-OHGMB7HJ.js";import"./chunk-WFMAM73Y.js";import"./chunk-66YHNWRR.js";var Tt=o=>({"bg-gradient-warning":o});function Dt(o,c){if(o&1&&(a(0,"tr",5)(1,"td"),g(2),s(),a(3,"td",6),g(4),s()()),o&2){let n=c.$implicit;u("matTooltip",n.duplicateMessage),l(2),R(n==null?null:n.Name),l(),u("ngClass",b(4,Tt,n.isDuplicate)),l(),R(n!=null&&n.ChannelVariationSKU?n==null?null:n.ChannelVariationSKU:"Not Assigned")}}var It=(()=>{let c=class c{constructor(){this.data=_(ht),this.dialogRef=_(mt),this.variants=x([])}ngOnInit(){this.initModalConfig(),this.initVariants()}initVariants(){let t=this.data?.variants,e={},i=[],d=t.filter(p=>f.IsEmpty(p.ChannelVariationSKU));t.filter(p=>f.IsNotEmpty(p.ChannelVariationSKU)).forEach((p,r,K)=>{e[p.ChannelVariationSKU]=K.filter(v=>v.ChannelVariationSKU===p.ChannelVariationSKU)}),Object.keys(e).forEach(p=>{e[p].length>1&&(e[p]=e[p].map((r,K,v)=>{let B=`SKU ${r.ChannelVariationSKU} is duplicated with variant`;return v.forEach((D,Nt)=>{D.Name!==r.Name&&(B+=` ${v.length>2?D.Name+(Nt!==v.length-1?",":""):D.Name}`)}),r.duplicateMessage=B,r.isDuplicate=!0,r})),i.push(...e[p])}),i.push(...d),this.variants.set(i)}initModalConfig(){this.modalConfig=new Ct,this.modalConfig.title=this.data?.title,this.modalConfig.hideOk=!0,this.modalConfig.hideCancel=!0,this.modalConfig.bodyScrollable=!0}};c.\u0275fac=function(e){return new(e||c)},c.\u0275cmp=I({type:c,selectors:[["app-modal-variants"]],decls:12,vars:1,consts:[[3,"onCancel","config"],["content",""],[1,"table"],[1,"sticky-top-thead","variant-modal"],[1,"sticky-top"],["matTooltipPosition","above",3,"matTooltip"],[3,"ngClass"]],template:function(e,i){e&1&&(a(0,"modal-material",0),S("onCancel",function(){return i.dialogRef.close()}),a(1,"div",1)(2,"table",2)(3,"thead",3)(4,"tr")(5,"th",4),g(6,"Variant"),s(),a(7,"th",4),g(8,"SKU"),s()()(),a(9,"tbody"),N(10,Dt,5,6,"tr",5,H),s()()()()),e&2&&(u("config",i.modalConfig),l(10),V(i.variants()))},dependencies:[gt,pt,Z],styles:[".mat-dialog-title[_ngcontent-%COMP%]{margin-bottom:0%;margin-left:24px}.sticky-top-thead[_ngcontent-%COMP%] th.sticky-top[_ngcontent-%COMP%]{top:0}.table[_ngcontent-%COMP%] thead[_ngcontent-%COMP%] tr.sticky-top[_ngcontent-%COMP%]{border:none!important;border-bottom:1px solid!important}table[_ngcontent-%COMP%] > thead[_ngcontent-%COMP%] > tr[_ngcontent-%COMP%]{border-top:none!important;border-left:none!important;border-right:none!important}.table[_ngcontent-%COMP%] thead[_ngcontent-%COMP%] th[_ngcontent-%COMP%]{background-color:#f6f6f6!important}.sticky-top-thead.variant-modal[_ngcontent-%COMP%] th[_ngcontent-%COMP%]:last-child:after{border-right:0px!important}.sticky-top-thead.variant-modal[_ngcontent-%COMP%] th[_ngcontent-%COMP%]:first-child:before{border-left:0px!important}.sticky-top-thead.variant-modal[_ngcontent-%COMP%] th[_ngcontent-%COMP%]:before{border-top:0px}"]});let o=c;return o})();var A=o=>[o],Et=()=>[];function kt(o,c){if(o&1){let n=P();a(0,"button",16),S("click",function(){m(n);let e=C(2);return h(e.openScanDialog())}),T(1,"i",17),g(2," Scan Channel "),s()}}function Rt(o,c){if(o&1&&(E(0),M(1,kt,3,0,"button",15),k()),o&2){let n=C();l(),O(n.productService.hasSelection(n.products)?-1:1)}}function Ut(o,c){if(o&1){let n=P();a(0,"button",19),S("click",function(){m(n);let e=C(2);return h(e.onDownloadAllProduct("SELECTED"))}),T(1,"i",20),g(2),s()}if(o&2){let n,t=C(2);l(2),$(" Download (",(n=t.productService.selectedProduct(t.products))==null?null:n.length,") ")}}function At(o,c){if(o&1&&(E(0),M(1,Ut,3,1,"button",18),k()),o&2){let n=C();l(),O(n.productService.hasSelection(n.products)?1:-1)}}function Kt(o,c){if(o&1){let n=P();a(0,"div",12)(1,"app-product-card",21),S("onCheckBoxChange",function(e){let i=m(n).$index,d=C();return h(d.onSelectProduct(e,i))})("onDescEvent",function(){let e=m(n).$index,i=C();return h(i.onShowVariantDetail(e))})("onDownload",function(){let e=m(n).$implicit,i=C();return h(i.onDownloadProduct(e))})("onScan",function(){let e=m(n).$implicit,i=C();return h(i.onScanChannel(e))}),s()()}if(o&2){let n=c.$implicit,t=C();l(),u("showRedirectIcon",!1)("title",n==null?null:n.Name)("image",n==null?null:n.Image)("imageForZoom",n==null?null:n.Image)("code",n==null?null:n.SKU)("description",(n==null||n.Variant==null?null:n.Variant.length)>0?(n==null||n.Variant==null?null:n.Variant.length)+" Variants":null)("downloadButton",!0)("channels",n!=null&&n.Channel?b(10,A,n==null?null:n.Channel):q(12,Et))("showCheckBox",t.hasDownloadRole())("scanButton",!0)}}function Bt(o,c){o&1&&(a(0,"div",13),T(1,"app-empty-state"),s())}function Lt(o,c){if(o&1){let n=P();a(0,"div",14)(1,"div",22)(2,"app-custom-paginator",23),S("total",function(){m(n);let e=C();return h(e.getRowCount())})("next",function(){m(n);let e=C();return h(e.getProducts())})("previous",function(){m(n);let e=C();return h(e.getProducts())}),s()()()}if(o&2){let n=C();l(2),u("filter",n.searchFilter)("totaldata",n.products==null?null:n.products.length)("paginationTotal",n.rowCount)("hasClicked",n.hasClickRowCount)}}var Me=(()=>{let c=class c{constructor(){this.http=_(tt),this.dialog=_(ut),this.productService=_(yt),this.toastrService=_(X),this.activateRouter=_(et),this.authService=_(at),this.placeholderService=_(Mt),this.permissionService=_(nt),this.searchFilter=new wt,this.products=[],this.hasClickRowCount=!1,this.scanProductRole=U.ProductScan,this.downloadProductRole=U.ProductDownload,this.hasDownloadRole=x(!0),this.searchPlaceholder=x("Search ..."),this.channelOptions=this.authService.getChannels(),this.permissionService.hasPermission(this.downloadProductRole).then(t=>{this.hasDownloadRole.set(t)})}ngOnInit(){this.activateRouter.queryParams.subscribe(t=>{t.ID?this.initPageLoader(t.ID):this.initPageLoader(f.GuidEMpty)})}initPageLoader(t){this.loader$=this.productService.loader(t).pipe(W(e=>{this.searchFilter=e.Filter,this.searchFilter.PageSize=e.Filter.RowCount,this.getProducts(),this.initSearchPlaceholder()}))}initSearchPlaceholder(){this.searchPlaceholder.set(this.placeholderService.generatePlaceholderBySearchType(this.searchFilter.SearchType,this.searchFilter.NumberFilterComparator))}getProducts(){this.http.post("/api/product/GetProductChannelNotPOS",this.searchFilter).subscribe(t=>{this.products=t.Data,this.mapChannelToProduct(),this.setSkuProduct()})}mapChannelToProduct(){let t;this.products=this.products.map(e=>(t=this.channelOptions.find(i=>i.ID==e.ChannelID),t?e.Channel=JSON.parse(JSON.stringify(t)):e.Channel=null,e)).map(e=>(e.Channel&&(e.Channel.Url=e.Url),e))}setSkuProduct(){this.products=this.products.map(t=>(t?.Variant?.length==0?f.IsNotEmpty(t?.ChannelItemSKU)?t.SKU=t?.ChannelItemSKU:t.SKU="SKU not assigned":t.SKU=t?.Variant[0]?.ChannelVariationSKU?t?.Variant[0]?.ChannelVariationSKU:"SKU not assigned",t))}onSearch(t){this.searchFilter.text=t,this.hasClickRowCount=!1,this.getProducts(),this.initSearchPlaceholder()}onClearChannelFilter(){this.searchFilter.ChannelID=f.GuidEMpty}onScanAll(){let t=this.productService.findChannelById(this.searchFilter.ChannelID,this.channelOptions);this.productService.scanAll(this.searchFilter.ChannelID,this.searchFilter.ScanFull,this.searchFilter.UpdatedProduct,this.searchFilter.Async).subscribe(e=>{this.searchFilter.Async?this.toastrService.warning("You will be notified when the scan is completed.","Scan In Progress",{toastClass:"ngx-toastr toast-waiting"}):(this.initPageLoader(f.GuidEMpty),this.productService.successToastrScanAllProduct(e,t,!this.searchFilter.UpdatedProduct)),this.searchFilter.ChannelID=f.GuidEMpty})}openScanDialog(){let t=JSON.parse(JSON.stringify(this.searchFilter));t.ChannelID=f.GuidEMpty,this.dialog.open(Pt,{data:{filter:t,channelOptions:this.channelOptions},width:"600px"}).afterClosed().pipe(L(i=>f.IsNotEmpty(i))).subscribe(i=>{this.searchFilter.ChannelID=i.ChannelID,this.searchFilter.UpdatedProduct=i.UpdatedProduct,this.searchFilter.ScanFull=i.ScanFull,this.searchFilter.Async=i.Async,this.onScanAll()})}onDownloadAllProduct(t){let e;t=="ALL"?e=this.products:e=this.productService.selectedProduct(this.products),e.length>0&&this.productService.downloadMultipleProduct(e).subscribe({next:()=>{this.getProducts()}})}onSelectProduct(t,e){this.products[e].selected=t}onDownloadProduct(t){confirm(`Are you sure you want to Retrieve product ${t?.Name} from ${t?.Channel.Name} to POS?`)&&this.productService.downloadProduct(t).subscribe({next:()=>{this.getProducts()}})}onScanChannel(t){let e=JSON.parse(JSON.stringify(t));delete e.Channel,this.productService.scanCompareToPos([e]).subscribe(i=>{i.Status?(this.initPageLoader(f.GuidEMpty),this.toastrService.success(`product ${t.Name} have been successfully scanned and synchronized with POS`,"Success")):this.toastrService.error(`Product ${t.Name} is not existed in POS`,"Error")})}onShowVariantDetail(t){let e=this.products[t].Variant;e.length>0&&this.dialog.open(It,{data:{title:this.products[t].Name,variants:e},width:"30%"})}getRowCount(){let t={ChannelID:this.searchFilter.ChannelID,text:this.searchFilter.text,HaveSku:parseInt(this.searchFilter.HaveSku),SearchType:this.searchFilter.SearchType,NumberFilterComparator:this.searchFilter.NumberFilterComparator};this.http.post(rt.GetNotInPosRowCount,t).subscribe(e=>{this.hasClickRowCount=!0,this.rowCount=e.Count})}};c.\u0275fac=function(e){return new(e||c)},c.\u0275cmp=I({type:c,selectors:[["app-not-in-pos"]],decls:34,vars:21,consts:[["headerTitle","Not in POS","textButton","Search","description","SKU sold in Marketplace but not exist in DEALPOS",3,"onSubmit","searchBoxPlaceHolder"],[4,"ngxPermissionsOnly"],[1,"mb-5"],[1,"fw-bold","mb-2"],[3,"ngModelChange","ngModel"],[1,"fw-bold"],["name","haveSKU",1,"form-control","h-100","pt-3","rounded","mt-2",3,"ngModelChange","ngModel"],[1,"me-5",3,"value"],["type","text","name","Item_id","id","Item_id","placeholder","item id",1,"form-control","mt-2",3,"ngModelChange","ngModel"],[3,"numberFilterComparatorChange","searchTypeChange","numberFilterComparatorOptions","numberFilterComparator","searchTypeOptions","searchType"],[1,"container-fluid","mt-3"],[1,"row","mt-8"],[1,"col-12","col-md-6","col-xl-4","px-3","my-3"],[1,"d-flex","flex-column","justify-content-center","align-items-center",2,"margin-top","26vh"],[1,"row"],["type","button","data-cy","scanNotInPos",1,"btn","btn-outline-secondary","shadow","rounded"],["type","button","data-cy","scanNotInPos",1,"btn","btn-outline-secondary","shadow","rounded",3,"click"],[1,"fas","fa-lg","fa-crosshairs"],["type","button",1,"btn","btn-success","shadow-sm","rounded","ms-3"],["type","button",1,"btn","btn-success","shadow-sm","rounded","ms-3",3,"click"],[1,"fa","fa-download"],[3,"onCheckBoxChange","onDescEvent","onDownload","onScan","showRedirectIcon","title","image","imageForZoom","code","description","downloadButton","channels","showCheckBox","scanButton"],[1,"col-12"],[3,"total","next","previous","filter","totaldata","paginationTotal","hasClicked"]],template:function(e,i){if(e&1){let d=P();j(0),z(1,"async"),a(2,"mainpanel",0),S("onSubmit",function(r){return m(d),h(i.onSearch(r))}),a(3,"actions"),G(4,Rt,2,1,"ng-container",1)(5,At,2,1,"ng-container",1),s(),a(6,"filters")(7,"div",2)(8,"label",3),g(9,"Channel"),s(),a(10,"app-channel-options-v2",4),F("ngModelChange",function(r){return m(d),w(i.searchFilter.ChannelID,r)||(i.searchFilter.ChannelID=r),h(r)}),s()(),a(11,"div",2)(12,"label",5),g(13,"SKU Assigned"),s(),a(14,"mat-radio-group",6),F("ngModelChange",function(r){return m(d),w(i.searchFilter.HaveSku,r)||(i.searchFilter.HaveSku=r),h(r)}),a(15,"mat-radio-button",7),g(16," All "),s(),a(17,"mat-radio-button",7),g(18," Yes "),s(),a(19,"mat-radio-button",7),g(20," No "),s()()(),a(21,"div",2)(22,"label",5),g(23,"Item ID"),s(),a(24,"input",8),F("ngModelChange",function(r){return m(d),w(i.searchFilter.Item_id,r)||(i.searchFilter.Item_id=r),h(r)}),s()(),a(25,"div")(26,"filter-query-type",9),F("numberFilterComparatorChange",function(r){return m(d),w(i.searchFilter.NumberFilterComparator,r)||(i.searchFilter.NumberFilterComparator=r),h(r)})("searchTypeChange",function(r){return m(d),w(i.searchFilter.SearchType,r)||(i.searchFilter.SearchType=r),h(r)}),s()()(),a(27,"content")(28,"div",10)(29,"div",11),N(30,Kt,2,13,"div",12,J),M(32,Bt,2,0,"div",13),s(),M(33,Lt,3,4,"div",14),s()()()}if(e&2){let d=Y(1,15,i.loader$);l(2),u("searchBoxPlaceHolder",i.searchPlaceholder()),l(2),u("ngxPermissionsOnly",b(17,A,i.scanProductRole)),l(),u("ngxPermissionsOnly",b(19,A,i.downloadProductRole)),l(5),y("ngModel",i.searchFilter.ChannelID),l(4),y("ngModel",i.searchFilter.HaveSku),l(),u("value",0),l(2),u("value",1),l(2),u("value",2),l(5),y("ngModel",i.searchFilter.Item_id),l(2),u("numberFilterComparatorOptions",d==null||d.Options==null?null:d.Options.SearchComparatorTypeOptions),y("numberFilterComparator",i.searchFilter.NumberFilterComparator),u("searchTypeOptions",d==null||d.Options==null?null:d.Options.SearchSKUOnlyOrSKUNameOptions),y("searchType",i.searchFilter.SearchType),l(4),V(i.products),l(2),O(i.products.length==0?32:-1),l(),O((i.products==null?null:i.products.length)>0?33:-1)}},dependencies:[_t,ot,it,Ot,dt,lt,st,ct,ft,St,Ft,bt,vt,xt,Q],styles:[".badge-pill[_ngcontent-%COMP%]{padding-bottom:16px!important}.rad-btn[_ngcontent-%COMP%] input[type=radio][_ngcontent-%COMP%]:checked + label[_ngcontent-%COMP%]{background:#dfeffc;border:1px solid #dfeffc}.rad-btn[_ngcontent-%COMP%] input[type=radio][_ngcontent-%COMP%]{visibility:hidden;position:absolute;left:0;top:0}.rad-btn[_ngcontent-%COMP%] label[_ngcontent-%COMP%]{border:1px solid #ddd;border-radius:3px;margin-right:10px;cursor:pointer;padding:10px;margin-bottom:10px;color:#000;width:80px;text-align:center}.modal-dialog[_ngcontent-%COMP%]{max-width:30%!important}.product[_ngcontent-%COMP%]{height:100%!important}.row[_ngcontent-%COMP%]{margin-left:0;margin-right:0}ul[_ngcontent-%COMP%]{list-style-type:none}.link[_ngcontent-%COMP%]{color:#0202ab;cursor:pointer}.px-1[_ngcontent-%COMP%]{padding-left:5px!important}.sku[_ngcontent-%COMP%]{color:#696969;font-style:italic}.badge-pill[_ngcontent-%COMP%]{height:16px}.itemTitle[_ngcontent-%COMP%]{text-overflow:ellipsis;white-space:nowrap;overflow:hidden}.no-title[_ngcontent-%COMP%]{margin-top:.33em;margin-bottom:.33rem}.mb-upload[_ngcontent-%COMP%]{padding-bottom:.625rem}.my-1rem[_ngcontent-%COMP%]{margin-bottom:1rem!important;margin-top:1rem!important}.pr-rem[_ngcontent-%COMP%]{padding-right:.6rem}.text-larger[_ngcontent-%COMP%]{font-size:larger}.bg-lightpink[_ngcontent-%COMP%]{background-color:#f9dede}.bottom-buttons[_ngcontent-%COMP%]{margin-left:97px}@media (min-width: 1200px){.max-w-xl[_ngcontent-%COMP%]{max-width:205px}}.navbar-toggler[_ngcontent-%COMP%]:focus{box-shadow:none!important}.itemTitle[_ngcontent-%COMP%]{cursor:pointer}"]});let o=c;return o})();export{Me as NotInPosComponent};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a as V}from"./chunk-
|
|
1
|
+
import{a as V}from"./chunk-HO2TMGLM.js";import{B as j,H as F,I as L,j as N,l as B}from"./chunk-7R2D2JZ6.js";import{Aa as b,Ab as A,Ac as Y,Ad as z,F as u,Fd as a,Hb as O,Ia as v,Ib as I,Jb as x,Kc as p,Ma as D,Na as S,Oa as w,Ra as C,_b as m,ac as H,cc as R,f as l,h as f,lc as n,ma as y,mc as d,na as _,nc as P,ob as M,pa as g,ra as o,tb as E,wc as T,zc as k}from"./chunk-OHGMB7HJ.js";var K=["mat-sort-header",""],W=["*"];function Z(e,h){e&1&&(n(0,"div",2),b(),n(1,"svg",3),P(2,"path",4),d()())}var U=new g("MAT_SORT_DEFAULT_OPTIONS"),$=(()=>{class e{_defaultOptions;_initializedStream=new f(1);sortables=new Map;_stateChanges=new l;active;start="asc";get direction(){return this._direction}set direction(t){this._direction=t}_direction="";disableClear;disabled=!1;sortChange=new E;initialized=this._initializedStream;constructor(t){this._defaultOptions=t}register(t){this.sortables.set(t.id,t)}deregister(t){this.sortables.delete(t.id)}sort(t){this.active!=t.id?(this.active=t.id,this.direction=t.start?t.start:this.start):this.direction=this.getNextSortDirection(t),this.sortChange.emit({active:this.active,direction:this.direction})}getNextSortDirection(t){if(!t)return"";let i=t?.disableClear??this.disableClear??!!this._defaultOptions?.disableClear,r=G(t.start||this.start,i),s=r.indexOf(this.direction)+1;return s>=r.length&&(s=0),r[s]}ngOnInit(){this._initializedStream.next()}ngOnChanges(){this._stateChanges.next()}ngOnDestroy(){this._stateChanges.complete(),this._initializedStream.complete()}static \u0275fac=function(i){return new(i||e)(A(U,8))};static \u0275dir=x({type:e,selectors:[["","matSort",""]],hostAttrs:[1,"mat-sort"],inputs:{active:[0,"matSortActive","active"],start:[0,"matSortStart","start"],direction:[0,"matSortDirection","direction"],disableClear:[2,"matSortDisableClear","disableClear",a],disabled:[2,"matSortDisabled","disabled",a]},outputs:{sortChange:"matSortChange"},exportAs:["matSort"],features:[w]})}return e})();function G(e,h){let t=["asc","desc"];return e=="desc"&&t.reverse(),h||t.push(""),t}var c=(()=>{class e{changes=new l;static \u0275fac=function(i){return new(i||e)};static \u0275prov=y({token:e,factory:e.\u0275fac,providedIn:"root"})}return e})();function J(e){return e||new c}var Q={provide:c,deps:[[new D,new S,c]],useFactory:J},gt=(()=>{class e{_intl=o(c);_sort=o($,{optional:!0});_columnDef=o("MAT_SORT_HEADER_COLUMN_DEF",{optional:!0});_changeDetectorRef=o(z);_focusMonitor=o(N);_elementRef=o(C);_ariaDescriber=o(j,{optional:!0});_renderChanges;_animationsDisabled=F();_recentlyCleared=v(null);_sortButton;id;arrowPosition="after";start;disabled=!1;get sortActionDescription(){return this._sortActionDescription}set sortActionDescription(t){this._updateSortActionDescription(t)}_sortActionDescription="Sort";disableClear;constructor(){o(B).load(V);let t=o(U,{optional:!0});this._sort,t?.arrowPosition&&(this.arrowPosition=t?.arrowPosition)}ngOnInit(){!this.id&&this._columnDef&&(this.id=this._columnDef.name),this._sort.register(this),this._renderChanges=u(this._sort._stateChanges,this._sort.sortChange).subscribe(()=>this._changeDetectorRef.markForCheck()),this._sortButton=this._elementRef.nativeElement.querySelector(".mat-sort-header-container"),this._updateSortActionDescription(this._sortActionDescription)}ngAfterViewInit(){this._focusMonitor.monitor(this._elementRef,!0).subscribe(()=>{Promise.resolve().then(()=>this._recentlyCleared.set(null))})}ngOnDestroy(){this._focusMonitor.stopMonitoring(this._elementRef),this._sort.deregister(this),this._renderChanges?.unsubscribe(),this._sortButton&&this._ariaDescriber?.removeDescription(this._sortButton,this._sortActionDescription)}_toggleOnInteraction(){if(!this._isDisabled()){let t=this._isSorted(),i=this._sort.direction;this._sort.sort(this),this._recentlyCleared.set(t&&!this._isSorted()?i:null)}}_handleKeydown(t){(t.keyCode===32||t.keyCode===13)&&(t.preventDefault(),this._toggleOnInteraction())}_isSorted(){return this._sort.active==this.id&&(this._sort.direction==="asc"||this._sort.direction==="desc")}_isDisabled(){return this._sort.disabled||this.disabled}_getAriaSortAttribute(){return this._isSorted()?this._sort.direction=="asc"?"ascending":"descending":"none"}_renderArrow(){return!this._isDisabled()||this._isSorted()}_updateSortActionDescription(t){this._sortButton&&(this._ariaDescriber?.removeDescription(this._sortButton,this._sortActionDescription),this._ariaDescriber?.describe(this._sortButton,t)),this._sortActionDescription=t}static \u0275fac=function(i){return new(i||e)};static \u0275cmp=O({type:e,selectors:[["","mat-sort-header",""]],hostAttrs:[1,"mat-sort-header"],hostVars:3,hostBindings:function(i,r){i&1&&T("click",function(){return r._toggleOnInteraction()})("keydown",function(q){return r._handleKeydown(q)})("mouseleave",function(){return r._recentlyCleared.set(null)}),i&2&&(m("aria-sort",r._getAriaSortAttribute()),p("mat-sort-header-disabled",r._isDisabled()))},inputs:{id:[0,"mat-sort-header","id"],arrowPosition:"arrowPosition",start:"start",disabled:[2,"disabled","disabled",a],sortActionDescription:"sortActionDescription",disableClear:[2,"disableClear","disableClear",a]},exportAs:["matSortHeader"],attrs:K,ngContentSelectors:W,decls:4,vars:17,consts:[[1,"mat-sort-header-container","mat-focus-indicator"],[1,"mat-sort-header-content"],[1,"mat-sort-header-arrow"],["viewBox","0 -960 960 960","focusable","false","aria-hidden","true"],["d","M440-240v-368L296-464l-56-56 240-240 240 240-56 56-144-144v368h-80Z"]],template:function(i,r){i&1&&(k(),n(0,"div",0)(1,"div",1),Y(2),d(),H(3,Z,3,0,"div",2),d()),i&2&&(p("mat-sort-header-sorted",r._isSorted())("mat-sort-header-position-before",r.arrowPosition==="before")("mat-sort-header-descending",r._sort.direction==="desc")("mat-sort-header-ascending",r._sort.direction==="asc")("mat-sort-header-recently-cleared-ascending",r._recentlyCleared()==="asc")("mat-sort-header-recently-cleared-descending",r._recentlyCleared()==="desc")("mat-sort-header-animations-disabled",r._animationsDisabled),m("tabindex",r._isDisabled()?null:0)("role",r._isDisabled()?null:"button"),M(3),R(r._renderArrow()?3:-1))},styles:[`.mat-sort-header{cursor:pointer}.mat-sort-header-disabled{cursor:default}.mat-sort-header-container{display:flex;align-items:center;letter-spacing:normal;outline:0}[mat-sort-header].cdk-keyboard-focused .mat-sort-header-container,[mat-sort-header].cdk-program-focused .mat-sort-header-container{border-bottom:solid 1px currentColor}.mat-sort-header-container::before{margin:calc(calc(var(--mat-focus-indicator-border-width, 3px) + 2px)*-1)}.mat-sort-header-content{display:flex;align-items:center}.mat-sort-header-position-before{flex-direction:row-reverse}@keyframes _mat-sort-header-recently-cleared-ascending{from{transform:translateY(0);opacity:1}to{transform:translateY(-25%);opacity:0}}@keyframes _mat-sort-header-recently-cleared-descending{from{transform:translateY(0) rotate(180deg);opacity:1}to{transform:translateY(25%) rotate(180deg);opacity:0}}.mat-sort-header-arrow{height:12px;width:12px;position:relative;transition:transform 225ms cubic-bezier(0.4, 0, 0.2, 1),opacity 225ms cubic-bezier(0.4, 0, 0.2, 1);opacity:0;overflow:visible;color:var(--mat-sort-arrow-color, var(--mat-sys-on-surface))}.mat-sort-header.cdk-keyboard-focused .mat-sort-header-arrow,.mat-sort-header.cdk-program-focused .mat-sort-header-arrow,.mat-sort-header:hover .mat-sort-header-arrow{opacity:.54}.mat-sort-header .mat-sort-header-sorted .mat-sort-header-arrow{opacity:1}.mat-sort-header-descending .mat-sort-header-arrow{transform:rotate(180deg)}.mat-sort-header-recently-cleared-ascending .mat-sort-header-arrow{transform:translateY(-25%)}.mat-sort-header-recently-cleared-ascending .mat-sort-header-arrow{transition:none;animation:_mat-sort-header-recently-cleared-ascending 225ms cubic-bezier(0.4, 0, 0.2, 1) forwards}.mat-sort-header-recently-cleared-descending .mat-sort-header-arrow{transition:none;animation:_mat-sort-header-recently-cleared-descending 225ms cubic-bezier(0.4, 0, 0.2, 1) forwards}.mat-sort-header-animations-disabled .mat-sort-header-arrow{transition-duration:0ms;animation-duration:0ms}.mat-sort-header-arrow svg{width:24px;height:24px;fill:currentColor;position:absolute;top:50%;left:50%;margin:-12px 0 0 -12px;transform:translateZ(0)}.mat-sort-header-arrow,[dir=rtl] .mat-sort-header-position-before .mat-sort-header-arrow{margin:0 0 0 6px}.mat-sort-header-position-before .mat-sort-header-arrow,[dir=rtl] .mat-sort-header-arrow{margin:0 6px 0 0}
|
|
2
2
|
`],encapsulation:2,changeDetection:0})}return e})(),bt=(()=>{class e{static \u0275fac=function(i){return new(i||e)};static \u0275mod=I({type:e});static \u0275inj=_({providers:[Q],imports:[L]})}return e})();export{$ as a,gt as b,bt as c};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{a as t}from"./chunk-KUKTPGJ2.js";import{a as m,b as v}from"./chunk-J6HA4ZHH.js";import"./chunk-YNL43MLU.js";import"./chunk-O4D64GHO.js";import"./chunk-7R2D2JZ6.js";import"./chunk-O3QPBAV5.js";import"./chunk-YYV4FSYQ.js";import"./chunk-QXRG5XYP.js";import"./chunk-AGBJEXIM.js";import"./chunk-5UFP37GQ.js";import"./chunk-UPRDDI4K.js";import"./chunk-RQUCYFCB.js";import"./chunk-RXLMJGUY.js";import"./chunk-MM7SAZOU.js";import{c as d}from"./chunk-NQLMPUSB.js";import"./chunk-OSGPJXJZ.js";import"./chunk-JNRCB7N3.js";import"./chunk-XBIHN6D3.js";import{Hb as a,hc as l,ic as c,jc as p,kc as r,ob as i}from"./chunk-OHGMB7HJ.js";import"./chunk-WFMAM73Y.js";import"./chunk-66YHNWRR.js";var s=(()=>{let n=class n{constructor(){this.reportTabs=[{Title:"1.Create Order",Url:"/menu/sync-log/order/sync-order"},{Title:"2.Convert Order To Invoice",Url:"/menu/sync-log/order/convert-to-invoice"},{Title:"3.Create Invoice",Url:"/menu/sync-log/order/invoice"},{Title:"4.Create Outbound Logistic",Url:"/menu/sync-log/order/delivery"},{Title:"5.Add Payment",Url:"/menu/sync-log/order/payment"},{Title:"6.Void Invoice",Url:"/menu/sync-log/order/void-invoice"},{Title:"All",Url:"/menu/sync-log/order/all"}]}};n.\u0275fac=function(o){return new(o||n)},n.\u0275cmp=a({type:n,selectors:[["app-order"]],decls:5,vars:1,consts:[[1,"navbar","page-nav","navbar-default","py-0","navbar-expand-lg"],[1,"container-fluid"],[3,"Tabs"]],template:function(o,y){o&1&&(c(0,"nav",0)(1,"div",1)(2,"div"),r(3,"nav-tab",2),p()()(),r(4,"router-outlet")),o&2&&(i(3),l("Tabs",y.reportTabs))},dependencies:[v,m,d],styles:[".dropdown[_ngcontent-%COMP%] .dropdown-menu.report.show[_ngcontent-%COMP%]{top:100%!important;transform:none!important;z-index:10000;cursor:pointer;right:-50%}"]});let e=n;return e})();var O=[{path:"",component:s,children:[{path:"",redirectTo:"all",pathMatch:"full"},{path:"sync-order",loadComponent(){return import("./chunk-OGF4VFSK.js").then(e=>e.SalesOrderComponent)},canActivate:[t],data:{title:"Sync Order"}},{path:"convert-to-invoice",loadComponent(){return import("./chunk-IDGK6BMG.js").then(e=>e.ConvertInvoiceComponent)},canActivate:[t],data:{title:"Sync Convert to Invoice"}},{path:"invoice",loadComponent(){return import("./chunk-P3XVM6DH.js").then(e=>e.InvoiceComponent)},canActivate:[t],data:{title:"Sync Invoice"}},{path:"delivery",loadComponent(){return import("./chunk-RZ5N5JLA.js").then(e=>e.DeliveryComponent)},canActivate:[t],data:{title:"Sync Delivery"}},{path:"payment",loadComponent(){return import("./chunk-VH7JZJ2B.js").then(e=>e.PaymentComponent)},canActivate:[t],data:{title:"Sync Payment"}},{path:"void-invoice",loadComponent(){return import("./chunk-LQPY6AYJ.js").then(e=>e.VoidInvoiceComponent)},canActivate:[t],data:{title:"Sync void invoice"}},{path:"all",loadComponent(){return import("./chunk-LKJCOEGO.js").then(e=>e.AllComponent)},canActivate:[t],data:{title:"All Report"}}]}];export{O as routes};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{e as bt}from"./chunk-OSGPJXJZ.js";import{c as _t,d as Tt,e as yt,t as X}from"./chunk-JNRCB7N3.js";import{c as tt,d as F,f as N,g as S,i as k}from"./chunk-XBIHN6D3.js";import{Ab as y,Ca as P,Da as U,Hb as Q,Ia as O,Ib as vt,J as ut,Jc as j,Mc as v,Nb as M,Nc as g,Pc as b,Yb as B,_b as E,c as ct,f as _,hc as c,ic as h,jc as f,kb as mt,kc as H,lb as Y,m as lt,ma as I,na as dt,ob as a,oc as J,pa as ht,pc as K,qa as m,ra as w,rc as W,sa as pt,tc as gt,u as Z,ub as q,wc as R,xb as ft,ya as $,yc as u,za as G}from"./chunk-OHGMB7HJ.js";import{a as d,b as C}from"./chunk-66YHNWRR.js";var Ct=["toast-component",""];function At(s,n){if(s&1){let e=W();h(0,"button",5),R("click",function(){$(e);let i=u();return G(i.remove())}),h(1,"span",6),g(2,"\xD7"),f()()}}function Ot(s,n){if(s&1&&(J(0),g(1),K()),s&2){let e=u(2);a(),b("[",e.duplicatesCount+1,"]")}}function Mt(s,n){if(s&1&&(h(0,"div"),g(1),M(2,Ot,2,1,"ng-container",4),f()),s&2){let e=u();v(e.options.titleClass),E("aria-label",e.title),a(),b(" ",e.title," "),a(),c("ngIf",e.duplicatesCount)}}function Et(s,n){if(s&1&&H(0,"div",7),s&2){let e=u();v(e.options.messageClass),c("innerHTML",e.message,Y)}}function Ht(s,n){if(s&1&&(h(0,"div",8),g(1),f()),s&2){let e=u();v(e.options.messageClass),E("aria-label",e.message),a(),b(" ",e.message," ")}}function Rt(s,n){if(s&1&&(h(0,"div"),H(1,"div",9),f()),s&2){let e=u();a(),j("width",e.width()+"%")}}function jt(s,n){if(s&1){let e=W();h(0,"button",5),R("click",function(){$(e);let i=u();return G(i.remove())}),h(1,"span",6),g(2,"\xD7"),f()()}}function Nt(s,n){if(s&1&&(J(0),g(1),K()),s&2){let e=u(2);a(),b("[",e.duplicatesCount+1,"]")}}function St(s,n){if(s&1&&(h(0,"div"),g(1),M(2,Nt,2,1,"ng-container",4),f()),s&2){let e=u();v(e.options.titleClass),E("aria-label",e.title),a(),b(" ",e.title," "),a(),c("ngIf",e.duplicatesCount)}}function Pt(s,n){if(s&1&&H(0,"div",7),s&2){let e=u();v(e.options.messageClass),c("innerHTML",e.message,Y)}}function Bt(s,n){if(s&1&&(h(0,"div",8),g(1),f()),s&2){let e=u();v(e.options.messageClass),E("aria-label",e.message),a(),b(" ",e.message," ")}}function Ft(s,n){if(s&1&&(h(0,"div"),H(1,"div",9),f()),s&2){let e=u();a(),j("width",e.width()+"%")}}var et=class{_attachedHost;component;viewContainerRef;injector;constructor(n,e){this.component=n,this.injector=e}attach(n,e){return this._attachedHost=n,n.attach(this,e)}detach(){let n=this._attachedHost;if(n)return this._attachedHost=void 0,n.detach()}get isAttached(){return this._attachedHost!=null}setAttachedHost(n){this._attachedHost=n}},it=class{_attachedPortal;_disposeFn;attach(n,e){return this._attachedPortal=n,this.attachComponentPortal(n,e)}detach(){this._attachedPortal&&this._attachedPortal.setAttachedHost(),this._attachedPortal=void 0,this._disposeFn&&(this._disposeFn(),this._disposeFn=void 0)}setDisposeFn(n){this._disposeFn=n}},st=class{_overlayRef;componentInstance;duplicatesCount=0;_afterClosed=new _;_activate=new _;_manualClose=new _;_resetTimeout=new _;_countDuplicate=new _;constructor(n){this._overlayRef=n}manualClose(){this._manualClose.next(),this._manualClose.complete()}manualClosed(){return this._manualClose.asObservable()}timeoutReset(){return this._resetTimeout.asObservable()}countDuplicate(){return this._countDuplicate.asObservable()}close(){this._overlayRef.detach(),this._afterClosed.next(),this._manualClose.next(),this._afterClosed.complete(),this._manualClose.complete(),this._activate.complete(),this._resetTimeout.complete(),this._countDuplicate.complete()}afterClosed(){return this._afterClosed.asObservable()}isInactive(){return this._activate.isStopped}activate(){this._activate.next(),this._activate.complete()}afterActivate(){return this._activate.asObservable()}onDuplicate(n,e){n&&this._resetTimeout.next(),e&&this._countDuplicate.next(++this.duplicatesCount)}},x=class{toastId;config;message;title;toastType;toastRef;_onTap=new _;_onAction=new _;constructor(n,e,t,i,o,r){this.toastId=n,this.config=e,this.message=t,this.title=i,this.toastType=o,this.toastRef=r,this.toastRef.afterClosed().subscribe(()=>{this._onAction.complete(),this._onTap.complete()})}triggerTap(){this._onTap.next(),this.config.tapToDismiss&&this._onTap.complete()}onTap(){return this._onTap.asObservable()}triggerAction(n){this._onAction.next(n)}onAction(){return this._onAction.asObservable()}},It={maxOpened:0,autoDismiss:!1,newestOnTop:!0,preventDuplicates:!1,countDuplicates:!1,resetTimeoutOnDuplicate:!1,includeTitleDuplicates:!1,iconClasses:{error:"toast-error",info:"toast-info",success:"toast-success",warning:"toast-warning"},closeButton:!1,disableTimeOut:!1,timeOut:5e3,extendedTimeOut:1e3,enableHtml:!1,progressBar:!1,toastClass:"ngx-toastr",positionClass:"toast-top-right",titleClass:"toast-title",messageClass:"toast-message",easing:"ease-in",easeTime:300,tapToDismiss:!0,onActivateTick:!1,progressAnimation:"decreasing"},wt=new ht("ToastConfig"),nt=class extends it{_hostDomElement;_componentFactoryResolver;_appRef;constructor(n,e,t){super(),this._hostDomElement=n,this._componentFactoryResolver=e,this._appRef=t}attachComponentPortal(n,e){let t=this._componentFactoryResolver.resolveComponentFactory(n.component),i;return i=t.create(n.injector),this._appRef.attachView(i.hostView),this.setDisposeFn(()=>{this._appRef.detachView(i.hostView),i.destroy()}),e?this._hostDomElement.insertBefore(this._getComponentRootNode(i),this._hostDomElement.firstChild):this._hostDomElement.appendChild(this._getComponentRootNode(i)),i}_getComponentRootNode(n){return n.hostView.rootNodes[0]}},kt=(()=>{class s{_document=w(U);_containerElement;ngOnDestroy(){this._containerElement&&this._containerElement.parentNode&&this._containerElement.parentNode.removeChild(this._containerElement)}getContainerElement(){return this._containerElement||this._createContainer(),this._containerElement}_createContainer(){let e=this._document.createElement("div");e.classList.add("overlay-container"),e.setAttribute("aria-live","polite"),this._document.body.appendChild(e),this._containerElement=e}static \u0275fac=function(t){return new(t||s)};static \u0275prov=I({token:s,factory:s.\u0275fac,providedIn:"root"})}return s})(),ot=class{_portalHost;constructor(n){this._portalHost=n}attach(n,e=!0){return this._portalHost.attach(n,e)}detach(){return this._portalHost.detach()}},Vt=(()=>{class s{_overlayContainer=w(kt);_componentFactoryResolver=w(ft);_appRef=w(B);_document=w(U);_paneElements=new Map;create(e,t){return this._createOverlayRef(this.getPaneElement(e,t))}getPaneElement(e="",t){return this._paneElements.get(t)||this._paneElements.set(t,{}),this._paneElements.get(t)[e]||(this._paneElements.get(t)[e]=this._createPaneElement(e,t)),this._paneElements.get(t)[e]}_createPaneElement(e,t){let i=this._document.createElement("div");return i.id="toast-container",i.classList.add(e),i.classList.add("toast-container"),t?t.getContainerElement().appendChild(i):this._overlayContainer.getContainerElement().appendChild(i),i}_createPortalHost(e){return new nt(e,this._componentFactoryResolver,this._appRef)}_createOverlayRef(e){return new ot(this._createPortalHost(e))}static \u0275fac=function(t){return new(t||s)};static \u0275prov=I({token:s,factory:s.\u0275fac,providedIn:"root"})}return s})(),V=(()=>{class s{overlay;_injector;sanitizer;ngZone;toastrConfig;currentlyActive=0;toasts=[];overlayContainer;previousToastMessage;index=0;constructor(e,t,i,o,r){this.overlay=t,this._injector=i,this.sanitizer=o,this.ngZone=r,this.toastrConfig=d(d({},e.default),e.config),e.config.iconClasses&&(this.toastrConfig.iconClasses=d(d({},e.default.iconClasses),e.config.iconClasses))}show(e,t,i={},o=""){return this._preBuildNotification(o,e,t,this.applyConfig(i))}success(e,t,i={}){let o=this.toastrConfig.iconClasses.success||"";return this._preBuildNotification(o,e,t,this.applyConfig(i))}error(e,t,i={}){let o=this.toastrConfig.iconClasses.error||"";return this._preBuildNotification(o,e,t,this.applyConfig(i))}info(e,t,i={}){let o=this.toastrConfig.iconClasses.info||"";return this._preBuildNotification(o,e,t,this.applyConfig(i))}warning(e,t,i={}){let o=this.toastrConfig.iconClasses.warning||"";return this._preBuildNotification(o,e,t,this.applyConfig(i))}clear(e){for(let t of this.toasts)if(e!==void 0){if(t.toastId===e){t.toastRef.manualClose();return}}else t.toastRef.manualClose()}remove(e){let t=this._findToast(e);if(!t||(t.activeToast.toastRef.close(),this.toasts.splice(t.index,1),this.currentlyActive=this.currentlyActive-1,!this.toastrConfig.maxOpened||!this.toasts.length))return!1;if(this.currentlyActive<this.toastrConfig.maxOpened&&this.toasts[this.currentlyActive]){let i=this.toasts[this.currentlyActive].toastRef;i.isInactive()||(this.currentlyActive=this.currentlyActive+1,i.activate())}return!0}findDuplicate(e="",t="",i,o){let{includeTitleDuplicates:r}=this.toastrConfig;for(let p of this.toasts){let l=r&&p.title===e;if((!r||l)&&p.message===t)return p.toastRef.onDuplicate(i,o),p}return null}applyConfig(e={}){return d(d({},this.toastrConfig),e)}_findToast(e){for(let t=0;t<this.toasts.length;t++)if(this.toasts[t].toastId===e)return{index:t,activeToast:this.toasts[t]};return null}_preBuildNotification(e,t,i,o){return o.onActivateTick?this.ngZone.run(()=>this._buildNotification(e,t,i,o)):this._buildNotification(e,t,i,o)}_buildNotification(e,t,i,o){if(!o.toastComponent)throw new Error("toastComponent required");let r=this.findDuplicate(i,t,this.toastrConfig.resetTimeoutOnDuplicate&&o.timeOut>0,this.toastrConfig.countDuplicates);if((this.toastrConfig.includeTitleDuplicates&&i||t)&&this.toastrConfig.preventDuplicates&&r!==null)return r;this.previousToastMessage=t;let p=!1;this.toastrConfig.maxOpened&&this.currentlyActive>=this.toastrConfig.maxOpened&&(p=!0,this.toastrConfig.autoDismiss&&this.clear(this.toasts[0].toastId));let l=this.overlay.create(o.positionClass,this.overlayContainer);this.index=this.index+1;let D=t;t&&o.enableHtml&&(D=this.sanitizer.sanitize(mt.HTML,t));let T=new st(l),A=new x(this.index,o,D,i,e,T),at=[{provide:x,useValue:A}],L=P.create({providers:at,parent:this._injector}),xt=new et(o.toastComponent,L),rt=l.attach(xt,o.newestOnTop);T.componentInstance=rt.instance;let z={toastId:this.index,title:i||"",message:t||"",toastRef:T,onShown:T.afterActivate(),onHidden:T.afterClosed(),onTap:A.onTap(),onAction:A.onAction(),portal:rt};return p||(this.currentlyActive=this.currentlyActive+1,setTimeout(()=>{z.toastRef.activate()})),this.toasts.push(z),z}static \u0275fac=function(t){return new(t||s)(m(wt),m(Vt),m(P),m(bt),m(q))};static \u0275prov=I({token:s,factory:s.\u0275fac,providedIn:"root"})}return s})(),Lt=(()=>{class s{toastrService;toastPackage;ngZone;message;title;options;duplicatesCount;originalTimeout;width=O(-1);toastClasses="";state;get _state(){return this.state()}get displayStyle(){if(this.state().value==="inactive")return"none"}timeout;intervalId;hideTime;sub;sub1;sub2;sub3;constructor(e,t,i){this.toastrService=e,this.toastPackage=t,this.ngZone=i,this.message=t.message,this.title=t.title,this.options=t.config,this.originalTimeout=t.config.timeOut,this.toastClasses=`${t.toastType} ${t.config.toastClass}`,this.sub=t.toastRef.afterActivate().subscribe(()=>{this.activateToast()}),this.sub1=t.toastRef.manualClosed().subscribe(()=>{this.remove()}),this.sub2=t.toastRef.timeoutReset().subscribe(()=>{this.resetTimeout()}),this.sub3=t.toastRef.countDuplicate().subscribe(o=>{this.duplicatesCount=o}),this.state=O({value:"inactive",params:{easeTime:this.toastPackage.config.easeTime,easing:"ease-in"}})}ngOnDestroy(){this.sub.unsubscribe(),this.sub1.unsubscribe(),this.sub2.unsubscribe(),this.sub3.unsubscribe(),clearInterval(this.intervalId),clearTimeout(this.timeout)}activateToast(){this.state.update(e=>C(d({},e),{value:"active"})),!(this.options.disableTimeOut===!0||this.options.disableTimeOut==="timeOut")&&this.options.timeOut&&(this.outsideTimeout(()=>this.remove(),this.options.timeOut),this.hideTime=new Date().getTime()+this.options.timeOut,this.options.progressBar&&this.outsideInterval(()=>this.updateProgress(),10))}updateProgress(){if(this.width()===0||this.width()===100||!this.options.timeOut)return;let e=new Date().getTime(),t=this.hideTime-e;this.width.set(t/this.options.timeOut*100),this.options.progressAnimation==="increasing"&&this.width.update(i=>100-i),this.width()<=0&&this.width.set(0),this.width()>=100&&this.width.set(100)}resetTimeout(){clearTimeout(this.timeout),clearInterval(this.intervalId),this.state.update(e=>C(d({},e),{value:"active"})),this.outsideTimeout(()=>this.remove(),this.originalTimeout),this.options.timeOut=this.originalTimeout,this.hideTime=new Date().getTime()+(this.options.timeOut||0),this.width.set(-1),this.options.progressBar&&this.outsideInterval(()=>this.updateProgress(),10)}remove(){this.state().value!=="removed"&&(clearTimeout(this.timeout),this.state.update(e=>C(d({},e),{value:"removed"})),this.outsideTimeout(()=>this.toastrService.remove(this.toastPackage.toastId),+this.toastPackage.config.easeTime))}tapToast(){this.state().value!=="removed"&&(this.toastPackage.triggerTap(),this.options.tapToDismiss&&this.remove())}stickAround(){this.state().value!=="removed"&&this.options.disableTimeOut!=="extendedTimeOut"&&(clearTimeout(this.timeout),this.options.timeOut=0,this.hideTime=0,clearInterval(this.intervalId),this.width.set(0))}delayedHideToast(){this.options.disableTimeOut===!0||this.options.disableTimeOut==="extendedTimeOut"||this.options.extendedTimeOut===0||this.state().value==="removed"||(this.outsideTimeout(()=>this.remove(),this.options.extendedTimeOut),this.options.timeOut=this.options.extendedTimeOut,this.hideTime=new Date().getTime()+(this.options.timeOut||0),this.width.set(-1),this.options.progressBar&&this.outsideInterval(()=>this.updateProgress(),10))}outsideTimeout(e,t){this.ngZone?this.ngZone.runOutsideAngular(()=>this.timeout=setTimeout(()=>this.runInsideAngular(e),t)):this.timeout=setTimeout(()=>e(),t)}outsideInterval(e,t){this.ngZone?this.ngZone.runOutsideAngular(()=>this.intervalId=setInterval(()=>this.runInsideAngular(e),t)):this.intervalId=setInterval(()=>e(),t)}runInsideAngular(e){this.ngZone?this.ngZone.run(()=>e()):e()}static \u0275fac=function(t){return new(t||s)(y(V),y(x),y(q))};static \u0275cmp=Q({type:s,selectors:[["","toast-component",""]],hostVars:5,hostBindings:function(t,i){t&1&&R("click",function(){return i.tapToast()})("mouseenter",function(){return i.stickAround()})("mouseleave",function(){return i.delayedHideToast()}),t&2&&(gt("@flyInOut",i._state),v(i.toastClasses),j("display",i.displayStyle))},attrs:Ct,decls:5,vars:5,consts:[["type","button","class","toast-close-button","aria-label","Close",3,"click",4,"ngIf"],[3,"class",4,"ngIf"],["role","alert",3,"class","innerHTML",4,"ngIf"],["role","alert",3,"class",4,"ngIf"],[4,"ngIf"],["type","button","aria-label","Close",1,"toast-close-button",3,"click"],["aria-hidden","true"],["role","alert",3,"innerHTML"],["role","alert"],[1,"toast-progress"]],template:function(t,i){t&1&&M(0,At,3,0,"button",0)(1,Mt,3,5,"div",1)(2,Et,1,3,"div",2)(3,Ht,2,4,"div",3)(4,Rt,2,2,"div",4),t&2&&(c("ngIf",i.options.closeButton),a(),c("ngIf",i.title),a(),c("ngIf",i.message&&i.options.enableHtml),a(),c("ngIf",i.message&&!i.options.enableHtml),a(),c("ngIf",i.options.progressBar))},dependencies:[X],encapsulation:2,data:{animation:[tt("flyInOut",[S("inactive",N({opacity:0})),S("active",N({opacity:1})),S("removed",N({opacity:0})),k("inactive => active",F("{{ easeTime }}ms {{ easing }}")),k("active => removed",F("{{ easeTime }}ms {{ easing }}"))])]},changeDetection:0})}return s})(),zt=C(d({},It),{toastComponent:Lt}),Zt=(s={})=>pt([{provide:wt,useValue:{default:zt,config:s}}]),be=(()=>{class s{static forRoot(e={}){return{ngModule:s,providers:[Zt(e)]}}static \u0275fac=function(t){return new(t||s)};static \u0275mod=vt({type:s});static \u0275inj=dt({})}return s})();var $t=(()=>{class s{toastrService;toastPackage;appRef;message;title;options;duplicatesCount;originalTimeout;width=O(-1);toastClasses="";get displayStyle(){return this.state()==="inactive"?"none":null}state=O("inactive");timeout;intervalId;hideTime;sub;sub1;sub2;sub3;constructor(e,t,i){this.toastrService=e,this.toastPackage=t,this.appRef=i,this.message=t.message,this.title=t.title,this.options=t.config,this.originalTimeout=t.config.timeOut,this.toastClasses=`${t.toastType} ${t.config.toastClass}`,this.sub=t.toastRef.afterActivate().subscribe(()=>{this.activateToast()}),this.sub1=t.toastRef.manualClosed().subscribe(()=>{this.remove()}),this.sub2=t.toastRef.timeoutReset().subscribe(()=>{this.resetTimeout()}),this.sub3=t.toastRef.countDuplicate().subscribe(o=>{this.duplicatesCount=o})}ngOnDestroy(){this.sub.unsubscribe(),this.sub1.unsubscribe(),this.sub2.unsubscribe(),this.sub3.unsubscribe(),clearInterval(this.intervalId),clearTimeout(this.timeout)}activateToast(){this.state.set("active"),!(this.options.disableTimeOut===!0||this.options.disableTimeOut==="timeOut")&&this.options.timeOut&&(this.timeout=setTimeout(()=>{this.remove()},this.options.timeOut),this.hideTime=new Date().getTime()+this.options.timeOut,this.options.progressBar&&(this.intervalId=setInterval(()=>this.updateProgress(),10))),this.options.onActivateTick&&this.appRef.tick()}updateProgress(){if(this.width()===0||this.width()===100||!this.options.timeOut)return;let e=new Date().getTime(),t=this.hideTime-e;this.width.set(t/this.options.timeOut*100),this.options.progressAnimation==="increasing"&&this.width.update(i=>100-i),this.width()<=0&&this.width.set(0),this.width()>=100&&this.width.set(100)}resetTimeout(){clearTimeout(this.timeout),clearInterval(this.intervalId),this.state.set("active"),this.options.timeOut=this.originalTimeout,this.timeout=setTimeout(()=>this.remove(),this.originalTimeout),this.hideTime=new Date().getTime()+(this.originalTimeout||0),this.width.set(-1),this.options.progressBar&&(this.intervalId=setInterval(()=>this.updateProgress(),10))}remove(){this.state()!=="removed"&&(clearTimeout(this.timeout),this.state.set("removed"),this.timeout=setTimeout(()=>this.toastrService.remove(this.toastPackage.toastId)))}tapToast(){this.state()!=="removed"&&(this.toastPackage.triggerTap(),this.options.tapToDismiss&&this.remove())}stickAround(){this.state()!=="removed"&&(clearTimeout(this.timeout),this.options.timeOut=0,this.hideTime=0,clearInterval(this.intervalId),this.width.set(0))}delayedHideToast(){this.options.disableTimeOut===!0||this.options.disableTimeOut==="extendedTimeOut"||this.options.extendedTimeOut===0||this.state()==="removed"||(this.timeout=setTimeout(()=>this.remove(),this.options.extendedTimeOut),this.options.timeOut=this.options.extendedTimeOut,this.hideTime=new Date().getTime()+(this.options.timeOut||0),this.width.set(-1),this.options.progressBar&&(this.intervalId=setInterval(()=>this.updateProgress(),10)))}static \u0275fac=function(t){return new(t||s)(y(V),y(x),y(B))};static \u0275cmp=Q({type:s,selectors:[["","toast-component",""]],hostVars:4,hostBindings:function(t,i){t&1&&R("click",function(){return i.tapToast()})("mouseenter",function(){return i.stickAround()})("mouseleave",function(){return i.delayedHideToast()}),t&2&&(v(i.toastClasses),j("display",i.displayStyle))},attrs:Ct,decls:5,vars:5,consts:[["type","button","class","toast-close-button","aria-label","Close",3,"click",4,"ngIf"],[3,"class",4,"ngIf"],["role","alert",3,"class","innerHTML",4,"ngIf"],["role","alert",3,"class",4,"ngIf"],[4,"ngIf"],["type","button","aria-label","Close",1,"toast-close-button",3,"click"],["aria-hidden","true"],["role","alert",3,"innerHTML"],["role","alert"],[1,"toast-progress"]],template:function(t,i){t&1&&M(0,jt,3,0,"button",0)(1,St,3,5,"div",1)(2,Pt,1,3,"div",2)(3,Bt,2,4,"div",3)(4,Ft,2,2,"div",4),t&2&&(c("ngIf",i.options.closeButton),a(),c("ngIf",i.title),a(),c("ngIf",i.message&&i.options.enableHtml),a(),c("ngIf",i.message&&!i.options.enableHtml),a(),c("ngIf",i.options.progressBar))},dependencies:[X],encapsulation:2,changeDetection:0})}return s})(),Ce=C(d({},It),{toastComponent:$t});var Oe=(()=>{let n=class n{constructor(t,i){this.http=t,this.toastr=i}get(t,i){let o=this.generateQueryParams(i);return this.http.get(t,{params:o}).pipe(ut(r=>lt))}generateQueryParams(t=[]){let i=new Tt;return t.forEach(o=>{i=i.append(o.key,o.value)}),i}post(t,i={},o={},r=1e5){return this.http.post(t,i,o).pipe(Z(r))}postFile(t,i,o=1e5){return new ct(r=>{let p=new _t({"Content-Type":"application/json","Cache-Control":"no-cache"});this.http.post(t,i,{headers:p,observe:"response",responseType:"blob"}).pipe(Z(o)).subscribe({next:l=>{r.next({title:l.headers.get("Content-Disposition"),file:l.body}),r.complete()},error:l=>{if(l.headers.get("Content-Type")==="application/json; charset=utf-8"){let D=new FileReader;D.addEventListener("loadend",T=>{let A=JSON.parse(T.srcElement.result)?.Message;if(!this.unauthorizedErrorHandling(l)){let L=this.errorMessageHandling(l);this.toastr.error(A??"An unknown error has occured!",L.header,{enableHtml:!0})}}),D.readAsText(l.error)}r.error(l)}})})}unauthorizedErrorHandling(t){let i=!1;return(t.status==401||t.status==403)&&(localStorage.getItem("Token")?this.toastr.error("Your session has expired. Please login again.","Unauthorized",{enableHtml:!0}):window.location.href="/",i=!0),i}errorMessageHandling(t){let i="API Error",o="Exception Message";return t.error?(i="API Error - "+t.status,t.status==451&&(i="Error"),t.error&&(o=t.error.Message)):t.Message&&(i="API Error - "+t.name,o=t.Message),{header:i,Message:o}}delete(t,i){return this.http.delete(t,i)}};n.\u0275fac=function(i){return new(i||n)(m(yt),m(V))},n.\u0275prov=I({token:n,factory:n.\u0275fac,providedIn:"root"});let s=n;return s})();export{x as a,V as b,Lt as c,be as d,Oe as e};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s,t,u,v,w,x}from"./chunk-
|
|
1
|
+
import{a,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s,t,u,v,w,x}from"./chunk-F26O6FCO.js";import"./chunk-XBIHN6D3.js";import"./chunk-OHGMB7HJ.js";import"./chunk-WFMAM73Y.js";import"./chunk-66YHNWRR.js";export{l as AnimationDriver,k as NoopAnimationDriver,u as \u0275Animation,q as \u0275AnimationEngine,w as \u0275AnimationRenderer,x as \u0275AnimationRendererFactory,m as \u0275AnimationStyleNormalizer,v as \u0275BaseAnimationRenderer,f as \u0275ENTER_CLASSNAME,g as \u0275LEAVE_CLASSNAME,n as \u0275NoopAnimationStyleNormalizer,p as \u0275TransitionAnimationPlayer,s as \u0275WebAnimationsDriver,r as \u0275WebAnimationsPlayer,o as \u0275WebAnimationsStyleNormalizer,j as \u0275allowPreviousPlayerStylesMerge,i as \u0275camelCaseToDashCase,d as \u0275containsElement,t as \u0275createEngine,a as \u0275getParentElement,e as \u0275invokeQuery,h as \u0275normalizeKeyframes,b as \u0275validateStyleProperty,c as \u0275validateWebAnimatableStyleProperty};
|