marketplacepos 5.50.0 → 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.
Files changed (59) hide show
  1. package/Marketplace/{chunk-35N7HHLQ.js → chunk-2UNT2DUM.js} +1 -1
  2. package/Marketplace/{chunk-NMFPLAWN.js → chunk-3PIHLKK3.js} +1 -1
  3. package/Marketplace/{chunk-5ZS5MEG7.js → chunk-44KIXUU2.js} +1 -1
  4. package/Marketplace/{chunk-NQVNAQCL.js → chunk-4G46574H.js} +1 -1
  5. package/Marketplace/{chunk-S4JKTHY2.js → chunk-4YKPN3RV.js} +1 -1
  6. package/Marketplace/{chunk-BKZIKCX7.js → chunk-67LUKQJC.js} +1 -1
  7. package/Marketplace/{chunk-WQHFRJZZ.js → chunk-6GNIJWEX.js} +1 -1
  8. package/Marketplace/{chunk-7IOQ6VVF.js → chunk-AJSJJV2I.js} +1 -1
  9. package/Marketplace/{chunk-G6O6VFLS.js → chunk-BXNDE6NQ.js} +1 -1
  10. package/Marketplace/{chunk-BYX6HZW7.js → chunk-E4RY2MK5.js} +1 -1
  11. package/Marketplace/{chunk-IBE5KBZU.js → chunk-EGLM6YK5.js} +1 -1
  12. package/Marketplace/{chunk-NY2YBW66.js → chunk-ENYJ4KAM.js} +1 -1
  13. package/Marketplace/{chunk-JSQ7SYYK.js → chunk-ESBL3IFN.js} +1 -1
  14. package/Marketplace/{chunk-PWCN6GJX.js → chunk-FMXX7QB5.js} +1 -1
  15. package/Marketplace/{chunk-55E6VHIU.js → chunk-FNOENLVR.js} +1 -1
  16. package/Marketplace/{chunk-7E53IHXI.js → chunk-GBF6A3MS.js} +1 -1
  17. package/Marketplace/{chunk-DI2VKA4Z.js → chunk-GDHNMHJZ.js} +1 -1
  18. package/Marketplace/{chunk-X35EOX3B.js → chunk-GJC736LV.js} +1 -1
  19. package/Marketplace/{chunk-4PG2EBJQ.js → chunk-H6YNHOUQ.js} +1 -1
  20. package/Marketplace/{chunk-EBXGQWOL.js → chunk-HGVFXR6T.js} +1 -1
  21. package/Marketplace/{chunk-4ORO4H6Z.js → chunk-HJZ3XPSH.js} +1 -1
  22. package/Marketplace/{chunk-ZMQQVXQU.js → chunk-HNDBAXI5.js} +1 -1
  23. package/Marketplace/{chunk-PGX5ZJ6P.js → chunk-IIJEILDV.js} +1 -1
  24. package/Marketplace/{chunk-IKC5WEP5.js → chunk-IV5IPY6H.js} +1 -1
  25. package/Marketplace/{chunk-LAMGWNDE.js → chunk-JYP3Z3TV.js} +1 -1
  26. package/Marketplace/{chunk-RTLTTFZ7.js → chunk-KNBXCPTA.js} +1 -1
  27. package/Marketplace/{chunk-P6RAMHDB.js → chunk-KTTKHI2N.js} +1 -1
  28. package/Marketplace/{chunk-QJ55WDGL.js → chunk-KUKTPGJ2.js} +1 -1
  29. package/Marketplace/{chunk-BL6MPO6D.js → chunk-LQ3VUWFK.js} +2 -2
  30. package/Marketplace/{chunk-JZ3E5MLG.js → chunk-LYN2PNQK.js} +1 -1
  31. package/Marketplace/{chunk-XPA7U45N.js → chunk-M7TUSCXB.js} +1 -1
  32. package/Marketplace/{chunk-KDIXLH2S.js → chunk-MIGPO7BO.js} +1 -1
  33. package/Marketplace/{chunk-SZ33XJ4F.js → chunk-MV2PLTWF.js} +1 -1
  34. package/Marketplace/{chunk-CZWUOW55.js → chunk-NTU64XT4.js} +1 -1
  35. package/Marketplace/{chunk-QMQCIH3X.js → chunk-O3QPBAV5.js} +1 -1
  36. package/Marketplace/{chunk-47Q5JJIA.js → chunk-OVZRFDFO.js} +1 -1
  37. package/Marketplace/{chunk-47JP6ZSE.js → chunk-QOSWDELZ.js} +1 -1
  38. package/Marketplace/{chunk-654AVLKM.js → chunk-RFWRWMRC.js} +1 -1
  39. package/Marketplace/{chunk-EHND5PFE.js → chunk-RHMSGY7X.js} +1 -1
  40. package/Marketplace/{chunk-UE2QO2Y4.js → chunk-RWPLFNHT.js} +1 -1
  41. package/Marketplace/{chunk-SS6PBSX7.js → chunk-S5D64XYA.js} +1 -1
  42. package/Marketplace/{chunk-YLQU53ID.js → chunk-S5XYWXXP.js} +1 -1
  43. package/Marketplace/{chunk-AUEWKPWQ.js → chunk-SN5AD4QE.js} +1 -1
  44. package/Marketplace/{chunk-VVTBM3Z5.js → chunk-TDP3PQDA.js} +1 -1
  45. package/Marketplace/{chunk-PUCIZX6E.js → chunk-TMBZ4K5S.js} +1 -1
  46. package/Marketplace/{chunk-4Q4I4JG4.js → chunk-TYNQDFOT.js} +1 -1
  47. package/Marketplace/{chunk-VWMEDVEG.js → chunk-U5DJYZUI.js} +1 -1
  48. package/Marketplace/{chunk-NRSDIDOP.js → chunk-UMMQ62IZ.js} +1 -1
  49. package/Marketplace/{chunk-4XENFCCZ.js → chunk-VV4G5VL5.js} +1 -1
  50. package/Marketplace/{chunk-ZVNZGCYO.js → chunk-VVAEM355.js} +1 -1
  51. package/Marketplace/{chunk-HFGQAVIU.js → chunk-VZ7Q4WN7.js} +1 -1
  52. package/Marketplace/{chunk-FJU2CZTJ.js → chunk-WIBWF333.js} +1 -1
  53. package/Marketplace/{chunk-PSJVP2XO.js → chunk-YMAKW4QT.js} +1 -1
  54. package/Marketplace/{chunk-J3QDFXZ7.js → chunk-YUPBZXLS.js} +1 -1
  55. package/Marketplace/{chunk-CC7KUBNZ.js → chunk-ZRTUQNSQ.js} +1 -1
  56. package/Marketplace/{chunk-ZQHOCT7I.js → chunk-ZXP3XYSZ.js} +1 -1
  57. package/Marketplace/index.html +2 -2
  58. package/Marketplace/{main-IQOLSEWV.js → main-RFMKGIMO.js} +1 -1
  59. package/package.json +1 -1
@@ -1,4 +1,4 @@
1
- import{a as nt}from"./chunk-YYV4FSYQ.js";import{a as ee}from"./chunk-QXRG5XYP.js";import{a as rt}from"./chunk-5UFP37GQ.js";import{b as we,c as te}from"./chunk-UPRDDI4K.js";import{b as Qe}from"./chunk-RQUCYFCB.js";import{a as Ge,b as fe,c as Ze,d as Je,e as ge,f as Xe,g as me,h as Ye,i as J,j as ye,k as x}from"./chunk-RXLMJGUY.js";import{e as et}from"./chunk-MM7SAZOU.js";import{d as tt}from"./chunk-NQLMPUSB.js";import{C as qe,D as Ve}from"./chunk-JNRCB7N3.js";import{Da as Ue,F as Ne,G as Fe,Ib as z,Ma as ze,O as le,S as Le,T as $e,Wa as K,Z as ue,aa as O,ba as de,c as m,ea as he,f as je,ga as We,ha as He,j as Oe,k as Be,ma as D,n as G,na as H,o as Q,p as B,pa as P,q as Z,qa as g,ra as M,ub as U,v as _,va as pe,w as Me,xa as Ke,zd as L}from"./chunk-OHGMB7HJ.js";import{b as w}from"./chunk-WFMAM73Y.js";import{a as ce,i as k}from"./chunk-66YHNWRR.js";var ot={production:!0,version:"5.50.0",firebaseConfig:{apiKey:"AIzaSyDnnitFXpM8TglWKNpzu4ChgF98n25Rgvw",authDomain:"auth.dealpos.com",projectId:"devops-signin",storageBucket:"devops-signin.appspot.com",messagingSenderId:"412465165194",appId:"1:412465165194:web:03d806f6b6ab6f8b460e73",measurementId:"G-MNDBRJ5XZD"},news:"https://changelog.dealpos.app/umbraco/delivery/api/v2/content?fetch=children:omni&sort=sortOrder:asc"};var it=(()=>{let o=class o{constructor(){}getParseToken(){let e=JSON.parse(window.localStorage.getItem("user"));return this.ParseToken(e.Token.access_token)}GetRoles(){let r=this.getParseToken()["http://schemas.microsoft.com/ws/2008/06/identity/claims/role"];return typeof r=="string"&&(r=[r]),r||[]}ParseToken(e){try{let n=e.split(".")[0].replace("-","+").replace("_","/"),i=JSON.parse(window.atob(n)),l=e.split(".")[1].replace("-","+").replace("_","/"),c=JSON.parse(window.atob(l));return c.header=i,c}catch{return!1}}};o.\u0275fac=function(r){return new(r||o)},o.\u0275prov=D({token:o,factory:o.\u0275fac,providedIn:"root"});let t=o;return t})();var Tt="firebase",Ct="11.10.0";J(Tt,Ct,"app");var q=new We("ANGULARFIRE2_VERSION");var st=(t,o)=>{let s=o?[o]:Ye(),e=[];return s.forEach(r=>{r.container.getProvider(t).instances.forEach(i=>{e.includes(i)||e.push(i)})}),e},Ae=(function(t){return t[t.SILENT=0]="SILENT",t[t.WARN=1]="WARN",t[t.VERBOSE=2]="VERBOSE",t})(Ae||{}),Mr=L()&&typeof Zone<"u"?Ae.WARN:Ae.SILENT;var re=class{zone;delegate;constructor(o,s=Be){this.zone=o,this.delegate=s}now(){return this.delegate.now()}schedule(o,s,e){let r=this.zone,n=function(i){r?r.runGuarded(()=>{o.apply(this,[i])}):o.apply(this,[i])};return this.delegate.schedule(n,s,e)}},ve=(()=>{class t{outsideAngular;insideAngular;constructor(){let s=M(U);this.outsideAngular=s.runOutsideAngular(()=>new re(typeof Zone>"u"?void 0:Zone.current)),this.insideAngular=s.run(()=>new re(typeof Zone>"u"?void 0:Zone.current,Oe))}static \u0275fac=function(e){return new(e||t)};static \u0275prov=D({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})();var Pt="firebase",xt="11.10.0";x.registerVersion(Pt,xt,"app-compat");var Rt=["ngOnDestroy"],ct=(t,o,s,e={})=>new Proxy(t,{get:(r,n)=>s.runOutsideAngular(()=>{if(t[n])return e?.spy?.get&&e.spy.get(n,t[n]),t[n];if(Rt.indexOf(n)>-1)return()=>{};let i=o.toPromise().then(a=>{let l=a?.[n];return typeof l=="function"?l.bind(a):l?.then?l.then(c=>s.run(()=>c)):s.run(()=>l)});return new Proxy(()=>{},{get:(a,l)=>i[l],apply:(a,l,c)=>i.then(u=>{let f=u?.(...c);return e?.spy?.apply&&e.spy.apply(n,c,f),f})})})});var ne=class{constructor(o){return o}},oe=new P("angularfire2.app.options"),ie=new P("angularfire2.app.name");function ke(t,o,s){let e=typeof s=="string"&&s||"[DEFAULT]",r=typeof s=="object"&&s||{};r.name=r.name||e;let i=x.apps.filter(a=>a&&a.name===r.name)[0]||o.runOutsideAngular(()=>x.initializeApp(t,r));try{if(JSON.stringify(t)!==JSON.stringify(i.options)){let a=!!module.hot;_t("error",`${i.name} Firebase App already initialized with different options${a?", you may need to reload as Firebase is not HMR aware.":"."}`)}}catch{}return new ne(i)}var _t=(t,...o)=>{L()&&typeof console<"u"&&console[t](...o)},jt={provide:ne,useFactory:ke,deps:[oe,U,[new ze,ie]]},zr=(()=>{class t{static initializeApp(s,e){return{ngModule:t,providers:[{provide:oe,useValue:s},{provide:ie,useValue:e}]}}constructor(s){x.registerVersion("angularfire",q.full,"core"),x.registerVersion("angularfire",q.full,"app-compat"),x.registerVersion("angular",He.full,s.toString())}static \u0275fac=function(e){return new(e||t)(g(K))};static \u0275mod=z({type:t});static \u0275inj=H({providers:[jt]})}return t})();function lt(t,o,s,e,r){let[,n,i]=globalThis.\u0275AngularfireInstanceCache.find(a=>a[0]===t)||[];if(n)return Ot(r,i)||(at("error",`${o} was already initialized on the ${s} Firebase App with different settings.${Bt?" You may need to reload as Firebase is not HMR aware.":""}`),at("warn",{is:r,was:i})),n;{let a=e();return globalThis.\u0275AngularfireInstanceCache.push([t,a,r]),a}}function Ot(t,o){try{return t.toString()===o.toString()}catch{return t===o}}var Bt=typeof module<"u"&&!!module.hot,at=(t,...o)=>{L()&&typeof console<"u"&&console[t](...o)};globalThis.\u0275AngularfireInstanceCache||=[];var Mt=new Map,Nt={activated:!1,tokenObservers:[]},Ft={initialized:!1,enabled:!1};function R(t){return Mt.get(t)||Object.assign({},Nt)}function pt(){return Ft}var Lt="https://content-firebaseappcheck.googleapis.com/v1";var $t="exchangeDebugToken",ut={OFFSET_DURATION:300*1e3,RETRIAL_MIN_WAIT:30*1e3,RETRIAL_MAX_WAIT:960*1e3},nn=1440*60*1e3;var Ee=class{constructor(o,s,e,r,n){if(this.operation=o,this.retryPolicy=s,this.getWaitDuration=e,this.lowerBound=r,this.upperBound=n,this.pending=null,this.nextErrorWaitInterval=r,r>n)throw new Error("Proactive refresh lower bound greater than upper bound!")}start(){this.nextErrorWaitInterval=this.lowerBound,this.process(!0).catch(()=>{})}stop(){this.pending&&(this.pending.reject("cancelled"),this.pending=null)}isRunning(){return!!this.pending}process(o){return k(this,null,function*(){this.stop();try{this.pending=new fe,this.pending.promise.catch(s=>{}),yield Wt(this.getNextRun(o)),this.pending.resolve(),yield this.pending.promise,this.pending=new fe,this.pending.promise.catch(s=>{}),yield this.operation(),this.pending.resolve(),yield this.pending.promise,this.process(!0).catch(()=>{})}catch(s){this.retryPolicy(s)?this.process(!1).catch(()=>{}):this.stop()}})}getNextRun(o){if(o)return this.nextErrorWaitInterval=this.lowerBound,this.getWaitDuration();{let s=this.nextErrorWaitInterval;return this.nextErrorWaitInterval*=2,this.nextErrorWaitInterval>this.upperBound&&(this.nextErrorWaitInterval=this.upperBound),s}}};function Wt(t){return new Promise(o=>{setTimeout(o,t)})}var Ht={"already-initialized":"You have already called initializeAppCheck() for FirebaseApp {$appName} with different options. To avoid this error, call initializeAppCheck() with the same options as when it was originally called. This will return the already initialized instance.","use-before-activation":"App Check is being used before initializeAppCheck() is called for FirebaseApp {$appName}. Call initializeAppCheck() before instantiating other Firebase services.","fetch-network-error":"Fetch failed to connect to a network. Check Internet connection. Original error: {$originalErrorMessage}.","fetch-parse-error":"Fetch client could not parse response. Original error: {$originalErrorMessage}.","fetch-status-error":"Fetch server returned an HTTP error status. HTTP status: {$httpStatus}.","storage-open":"Error thrown when opening storage. Original error: {$originalErrorMessage}.","storage-get":"Error thrown when reading from storage. Original error: {$originalErrorMessage}.","storage-set":"Error thrown when writing to storage. Original error: {$originalErrorMessage}.","recaptcha-error":"ReCAPTCHA error.","initial-throttle":"{$httpStatus} error. Attempts allowed again after {$time}",throttled:"Requests throttled due to previous {$httpStatus} error. Attempts allowed again after {$time}"},N=new Je("appCheck","AppCheck",Ht);function ft(t){if(!R(t).activated)throw N.create("use-before-activation",{appName:t.name})}function gt(e,r){return k(this,arguments,function*({url:t,body:o},s){let n={"Content-Type":"application/json"},i=s.getImmediate({optional:!0});if(i){let h=yield i.getHeartbeatsHeader();h&&(n["X-Firebase-Client"]=h)}let a={method:"POST",body:JSON.stringify(o),headers:n},l;try{l=yield fetch(t,a)}catch(h){throw N.create("fetch-network-error",{originalErrorMessage:h?.message})}if(l.status!==200)throw N.create("fetch-status-error",{httpStatus:l.status});let c;try{c=yield l.json()}catch(h){throw N.create("fetch-parse-error",{originalErrorMessage:h?.message})}let u=c.ttl.match(/^([\d.]+)(s)$/);if(!u||!u[2]||isNaN(Number(u[1])))throw N.create("fetch-parse-error",{originalErrorMessage:`ttl field (timeToLive) is not in standard Protobuf Duration format: ${c.ttl}`});let f=Number(u[1])*1e3,d=Date.now();return{token:c.token,expireTimeMillis:d+f,issuedAtTimeMillis:d}})}function mt(t,o){let{projectId:s,appId:e,apiKey:r}=t.options;return{url:`${Lt}/projects/${s}/apps/${e}:${$t}?key=${r}`,body:{debug_token:o}}}var Kt="firebase-app-check-database",Ut=1,Ie="firebase-app-check-store";var se=null;function zt(){return se||(se=new Promise((t,o)=>{try{let s=indexedDB.open(Kt,Ut);s.onsuccess=e=>{t(e.target.result)},s.onerror=e=>{var r;o(N.create("storage-open",{originalErrorMessage:(r=e.target.error)===null||r===void 0?void 0:r.message}))},s.onupgradeneeded=e=>{let r=e.target.result;switch(e.oldVersion){case 0:r.createObjectStore(Ie,{keyPath:"compositeKey"})}}}catch(s){o(N.create("storage-open",{originalErrorMessage:s?.message}))}}),se)}function qt(t,o){return Vt(Gt(t),o)}function Vt(t,o){return k(this,null,function*(){let e=(yield zt()).transaction(Ie,"readwrite"),n=e.objectStore(Ie).put({compositeKey:t,value:o});return new Promise((i,a)=>{n.onsuccess=l=>{i()},e.onerror=l=>{var c;a(N.create("storage-set",{originalErrorMessage:(c=l.target.error)===null||c===void 0?void 0:c.message}))}})})}function Gt(t){return`${t.options.appId}-${t.name}`}var X=new Xe("@firebase/app-check");function be(t,o){return Ze()?qt(t,o).catch(s=>{X.warn(`Failed to write token to IndexedDB. Error: ${s}`)}):Promise.resolve()}function yt(){return pt().enabled}function wt(){return k(this,null,function*(){let t=pt();if(t.enabled&&t.token)return t.token.promise;throw Error(`
1
+ import{a as nt}from"./chunk-YYV4FSYQ.js";import{a as ee}from"./chunk-QXRG5XYP.js";import{a as rt}from"./chunk-5UFP37GQ.js";import{b as we,c as te}from"./chunk-UPRDDI4K.js";import{b as Qe}from"./chunk-RQUCYFCB.js";import{a as Ge,b as fe,c as Ze,d as Je,e as ge,f as Xe,g as me,h as Ye,i as J,j as ye,k as x}from"./chunk-RXLMJGUY.js";import{e as et}from"./chunk-MM7SAZOU.js";import{d as tt}from"./chunk-NQLMPUSB.js";import{C as qe,D as Ve}from"./chunk-JNRCB7N3.js";import{Da as Ue,F as Ne,G as Fe,Ib as z,Ma as ze,O as le,S as Le,T as $e,Wa as K,Z as ue,aa as O,ba as de,c as m,ea as he,f as je,ga as We,ha as He,j as Oe,k as Be,ma as D,n as G,na as H,o as Q,p as B,pa as P,q as Z,qa as g,ra as M,ub as U,v as _,va as pe,w as Me,xa as Ke,zd as L}from"./chunk-OHGMB7HJ.js";import{b as w}from"./chunk-WFMAM73Y.js";import{a as ce,i as k}from"./chunk-66YHNWRR.js";var ot={production:!0,version:"5.50.1",firebaseConfig:{apiKey:"AIzaSyDnnitFXpM8TglWKNpzu4ChgF98n25Rgvw",authDomain:"auth.dealpos.com",projectId:"devops-signin",storageBucket:"devops-signin.appspot.com",messagingSenderId:"412465165194",appId:"1:412465165194:web:03d806f6b6ab6f8b460e73",measurementId:"G-MNDBRJ5XZD"},news:"https://changelog.dealpos.app/umbraco/delivery/api/v2/content?fetch=children:omni&sort=sortOrder:asc"};var it=(()=>{let o=class o{constructor(){}getParseToken(){let e=JSON.parse(window.localStorage.getItem("user"));return this.ParseToken(e.Token.access_token)}GetRoles(){let r=this.getParseToken()["http://schemas.microsoft.com/ws/2008/06/identity/claims/role"];return typeof r=="string"&&(r=[r]),r||[]}ParseToken(e){try{let n=e.split(".")[0].replace("-","+").replace("_","/"),i=JSON.parse(window.atob(n)),l=e.split(".")[1].replace("-","+").replace("_","/"),c=JSON.parse(window.atob(l));return c.header=i,c}catch{return!1}}};o.\u0275fac=function(r){return new(r||o)},o.\u0275prov=D({token:o,factory:o.\u0275fac,providedIn:"root"});let t=o;return t})();var Tt="firebase",Ct="11.10.0";J(Tt,Ct,"app");var q=new We("ANGULARFIRE2_VERSION");var st=(t,o)=>{let s=o?[o]:Ye(),e=[];return s.forEach(r=>{r.container.getProvider(t).instances.forEach(i=>{e.includes(i)||e.push(i)})}),e},Ae=(function(t){return t[t.SILENT=0]="SILENT",t[t.WARN=1]="WARN",t[t.VERBOSE=2]="VERBOSE",t})(Ae||{}),Mr=L()&&typeof Zone<"u"?Ae.WARN:Ae.SILENT;var re=class{zone;delegate;constructor(o,s=Be){this.zone=o,this.delegate=s}now(){return this.delegate.now()}schedule(o,s,e){let r=this.zone,n=function(i){r?r.runGuarded(()=>{o.apply(this,[i])}):o.apply(this,[i])};return this.delegate.schedule(n,s,e)}},ve=(()=>{class t{outsideAngular;insideAngular;constructor(){let s=M(U);this.outsideAngular=s.runOutsideAngular(()=>new re(typeof Zone>"u"?void 0:Zone.current)),this.insideAngular=s.run(()=>new re(typeof Zone>"u"?void 0:Zone.current,Oe))}static \u0275fac=function(e){return new(e||t)};static \u0275prov=D({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})();var Pt="firebase",xt="11.10.0";x.registerVersion(Pt,xt,"app-compat");var Rt=["ngOnDestroy"],ct=(t,o,s,e={})=>new Proxy(t,{get:(r,n)=>s.runOutsideAngular(()=>{if(t[n])return e?.spy?.get&&e.spy.get(n,t[n]),t[n];if(Rt.indexOf(n)>-1)return()=>{};let i=o.toPromise().then(a=>{let l=a?.[n];return typeof l=="function"?l.bind(a):l?.then?l.then(c=>s.run(()=>c)):s.run(()=>l)});return new Proxy(()=>{},{get:(a,l)=>i[l],apply:(a,l,c)=>i.then(u=>{let f=u?.(...c);return e?.spy?.apply&&e.spy.apply(n,c,f),f})})})});var ne=class{constructor(o){return o}},oe=new P("angularfire2.app.options"),ie=new P("angularfire2.app.name");function ke(t,o,s){let e=typeof s=="string"&&s||"[DEFAULT]",r=typeof s=="object"&&s||{};r.name=r.name||e;let i=x.apps.filter(a=>a&&a.name===r.name)[0]||o.runOutsideAngular(()=>x.initializeApp(t,r));try{if(JSON.stringify(t)!==JSON.stringify(i.options)){let a=!!module.hot;_t("error",`${i.name} Firebase App already initialized with different options${a?", you may need to reload as Firebase is not HMR aware.":"."}`)}}catch{}return new ne(i)}var _t=(t,...o)=>{L()&&typeof console<"u"&&console[t](...o)},jt={provide:ne,useFactory:ke,deps:[oe,U,[new ze,ie]]},zr=(()=>{class t{static initializeApp(s,e){return{ngModule:t,providers:[{provide:oe,useValue:s},{provide:ie,useValue:e}]}}constructor(s){x.registerVersion("angularfire",q.full,"core"),x.registerVersion("angularfire",q.full,"app-compat"),x.registerVersion("angular",He.full,s.toString())}static \u0275fac=function(e){return new(e||t)(g(K))};static \u0275mod=z({type:t});static \u0275inj=H({providers:[jt]})}return t})();function lt(t,o,s,e,r){let[,n,i]=globalThis.\u0275AngularfireInstanceCache.find(a=>a[0]===t)||[];if(n)return Ot(r,i)||(at("error",`${o} was already initialized on the ${s} Firebase App with different settings.${Bt?" You may need to reload as Firebase is not HMR aware.":""}`),at("warn",{is:r,was:i})),n;{let a=e();return globalThis.\u0275AngularfireInstanceCache.push([t,a,r]),a}}function Ot(t,o){try{return t.toString()===o.toString()}catch{return t===o}}var Bt=typeof module<"u"&&!!module.hot,at=(t,...o)=>{L()&&typeof console<"u"&&console[t](...o)};globalThis.\u0275AngularfireInstanceCache||=[];var Mt=new Map,Nt={activated:!1,tokenObservers:[]},Ft={initialized:!1,enabled:!1};function R(t){return Mt.get(t)||Object.assign({},Nt)}function pt(){return Ft}var Lt="https://content-firebaseappcheck.googleapis.com/v1";var $t="exchangeDebugToken",ut={OFFSET_DURATION:300*1e3,RETRIAL_MIN_WAIT:30*1e3,RETRIAL_MAX_WAIT:960*1e3},nn=1440*60*1e3;var Ee=class{constructor(o,s,e,r,n){if(this.operation=o,this.retryPolicy=s,this.getWaitDuration=e,this.lowerBound=r,this.upperBound=n,this.pending=null,this.nextErrorWaitInterval=r,r>n)throw new Error("Proactive refresh lower bound greater than upper bound!")}start(){this.nextErrorWaitInterval=this.lowerBound,this.process(!0).catch(()=>{})}stop(){this.pending&&(this.pending.reject("cancelled"),this.pending=null)}isRunning(){return!!this.pending}process(o){return k(this,null,function*(){this.stop();try{this.pending=new fe,this.pending.promise.catch(s=>{}),yield Wt(this.getNextRun(o)),this.pending.resolve(),yield this.pending.promise,this.pending=new fe,this.pending.promise.catch(s=>{}),yield this.operation(),this.pending.resolve(),yield this.pending.promise,this.process(!0).catch(()=>{})}catch(s){this.retryPolicy(s)?this.process(!1).catch(()=>{}):this.stop()}})}getNextRun(o){if(o)return this.nextErrorWaitInterval=this.lowerBound,this.getWaitDuration();{let s=this.nextErrorWaitInterval;return this.nextErrorWaitInterval*=2,this.nextErrorWaitInterval>this.upperBound&&(this.nextErrorWaitInterval=this.upperBound),s}}};function Wt(t){return new Promise(o=>{setTimeout(o,t)})}var Ht={"already-initialized":"You have already called initializeAppCheck() for FirebaseApp {$appName} with different options. To avoid this error, call initializeAppCheck() with the same options as when it was originally called. This will return the already initialized instance.","use-before-activation":"App Check is being used before initializeAppCheck() is called for FirebaseApp {$appName}. Call initializeAppCheck() before instantiating other Firebase services.","fetch-network-error":"Fetch failed to connect to a network. Check Internet connection. Original error: {$originalErrorMessage}.","fetch-parse-error":"Fetch client could not parse response. Original error: {$originalErrorMessage}.","fetch-status-error":"Fetch server returned an HTTP error status. HTTP status: {$httpStatus}.","storage-open":"Error thrown when opening storage. Original error: {$originalErrorMessage}.","storage-get":"Error thrown when reading from storage. Original error: {$originalErrorMessage}.","storage-set":"Error thrown when writing to storage. Original error: {$originalErrorMessage}.","recaptcha-error":"ReCAPTCHA error.","initial-throttle":"{$httpStatus} error. Attempts allowed again after {$time}",throttled:"Requests throttled due to previous {$httpStatus} error. Attempts allowed again after {$time}"},N=new Je("appCheck","AppCheck",Ht);function ft(t){if(!R(t).activated)throw N.create("use-before-activation",{appName:t.name})}function gt(e,r){return k(this,arguments,function*({url:t,body:o},s){let n={"Content-Type":"application/json"},i=s.getImmediate({optional:!0});if(i){let h=yield i.getHeartbeatsHeader();h&&(n["X-Firebase-Client"]=h)}let a={method:"POST",body:JSON.stringify(o),headers:n},l;try{l=yield fetch(t,a)}catch(h){throw N.create("fetch-network-error",{originalErrorMessage:h?.message})}if(l.status!==200)throw N.create("fetch-status-error",{httpStatus:l.status});let c;try{c=yield l.json()}catch(h){throw N.create("fetch-parse-error",{originalErrorMessage:h?.message})}let u=c.ttl.match(/^([\d.]+)(s)$/);if(!u||!u[2]||isNaN(Number(u[1])))throw N.create("fetch-parse-error",{originalErrorMessage:`ttl field (timeToLive) is not in standard Protobuf Duration format: ${c.ttl}`});let f=Number(u[1])*1e3,d=Date.now();return{token:c.token,expireTimeMillis:d+f,issuedAtTimeMillis:d}})}function mt(t,o){let{projectId:s,appId:e,apiKey:r}=t.options;return{url:`${Lt}/projects/${s}/apps/${e}:${$t}?key=${r}`,body:{debug_token:o}}}var Kt="firebase-app-check-database",Ut=1,Ie="firebase-app-check-store";var se=null;function zt(){return se||(se=new Promise((t,o)=>{try{let s=indexedDB.open(Kt,Ut);s.onsuccess=e=>{t(e.target.result)},s.onerror=e=>{var r;o(N.create("storage-open",{originalErrorMessage:(r=e.target.error)===null||r===void 0?void 0:r.message}))},s.onupgradeneeded=e=>{let r=e.target.result;switch(e.oldVersion){case 0:r.createObjectStore(Ie,{keyPath:"compositeKey"})}}}catch(s){o(N.create("storage-open",{originalErrorMessage:s?.message}))}}),se)}function qt(t,o){return Vt(Gt(t),o)}function Vt(t,o){return k(this,null,function*(){let e=(yield zt()).transaction(Ie,"readwrite"),n=e.objectStore(Ie).put({compositeKey:t,value:o});return new Promise((i,a)=>{n.onsuccess=l=>{i()},e.onerror=l=>{var c;a(N.create("storage-set",{originalErrorMessage:(c=l.target.error)===null||c===void 0?void 0:c.message}))}})})}function Gt(t){return`${t.options.appId}-${t.name}`}var X=new Xe("@firebase/app-check");function be(t,o){return Ze()?qt(t,o).catch(s=>{X.warn(`Failed to write token to IndexedDB. Error: ${s}`)}):Promise.resolve()}function yt(){return pt().enabled}function wt(){return k(this,null,function*(){let t=pt();if(t.enabled&&t.token)return t.token.promise;throw Error(`
2
2
  Can't get debug token in production mode.
3
3
  `)})}var Zt={error:"UNKNOWN_ERROR"};function Jt(t){return Ge.encodeString(JSON.stringify(t),!1)}function Te(t,o=!1,s=!1){return k(this,null,function*(){let e=t.app;ft(e);let r=R(e),n=r.token,i;if(n&&!Y(n)&&(r.token=void 0,n=void 0),!n){let c=yield r.cachedTokenPromise;c&&(Y(c)?n=c:yield be(e,void 0))}if(!o&&n&&Y(n))return{token:n.token};let a=!1;if(yt())try{r.exchangeTokenPromise||(r.exchangeTokenPromise=gt(mt(e,yield wt()),t.heartbeatServiceProvider).finally(()=>{r.exchangeTokenPromise=void 0}),a=!0);let c=yield r.exchangeTokenPromise;return yield be(e,c),r.token=c,{token:c.token}}catch(c){return c.code==="appCheck/throttled"||c.code==="appCheck/initial-throttle"?X.warn(c.message):s&&X.error(c),Se(c)}try{r.exchangeTokenPromise||(r.exchangeTokenPromise=r.provider.getToken().finally(()=>{r.exchangeTokenPromise=void 0}),a=!0),n=yield R(e).exchangeTokenPromise}catch(c){c.code==="appCheck/throttled"||c.code==="appCheck/initial-throttle"?X.warn(c.message):s&&X.error(c),i=c}let l;return n?i?Y(n)?l={token:n.token,internalError:i}:l=Se(i):(l={token:n.token},r.token=n,yield be(e,n)):l=Se(i),a&&er(e,l),l})}function Xt(t){return k(this,null,function*(){let o=t.app;ft(o);let{provider:s}=R(o);if(yt()){let e=yield wt(),{token:r}=yield gt(mt(o,e),t.heartbeatServiceProvider);return{token:r}}else{let{token:e}=yield s.getToken();return{token:e}}})}function Yt(t,o,s,e){let{app:r}=t,n=R(r),i={next:s,error:e,type:o};if(n.tokenObservers=[...n.tokenObservers,i],n.token&&Y(n.token)){let a=n.token;Promise.resolve().then(()=>{s({token:a.token}),dt(t)}).catch(()=>{})}n.cachedTokenPromise.then(()=>dt(t))}function At(t,o){let s=R(t),e=s.tokenObservers.filter(r=>r.next!==o);e.length===0&&s.tokenRefresher&&s.tokenRefresher.isRunning()&&s.tokenRefresher.stop(),s.tokenObservers=e}function dt(t){let{app:o}=t,s=R(o),e=s.tokenRefresher;e||(e=Qt(t),s.tokenRefresher=e),!e.isRunning()&&s.isTokenAutoRefreshEnabled&&e.start()}function Qt(t){let{app:o}=t;return new Ee(()=>k(null,null,function*(){let s=R(o),e;if(s.token?e=yield Te(t,!0):e=yield Te(t),e.error)throw e.error;if(e.internalError)throw e.internalError}),()=>!0,()=>{let s=R(o);if(s.token){let e=s.token.issuedAtTimeMillis+(s.token.expireTimeMillis-s.token.issuedAtTimeMillis)*.5+3e5,r=s.token.expireTimeMillis-300*1e3;return e=Math.min(e,r),Math.max(0,e-Date.now())}else return 0},ut.RETRIAL_MIN_WAIT,ut.RETRIAL_MAX_WAIT)}function er(t,o){let s=R(t).tokenObservers;for(let e of s)try{e.type==="EXTERNAL"&&o.error!=null?e.error(o.error):e.next(o)}catch{}}function Y(t){return t.expireTimeMillis-Date.now()>0}function Se(t){return{token:Jt(Zt),error:t}}var Ce=class{constructor(o,s){this.app=o,this.heartbeatServiceProvider=s}_delete(){let{tokenObservers:o}=R(this.app);for(let s of o)At(this.app,s.next);return Promise.resolve()}};function tr(t,o){return new Ce(t,o)}function rr(t){return{getToken:o=>Te(t,o),getLimitedUseToken:()=>Xt(t),addTokenListener:o=>Yt(t,"INTERNAL",o),removeTokenListener:o=>At(t.app,o)}}var nr="@firebase/app-check",or="0.10.1";var ir="app-check",ht="app-check-internal";function sr(){me(new ge(ir,t=>{let o=t.getProvider("app").getImmediate(),s=t.getProvider("heartbeat");return tr(o,s)},"PUBLIC").setInstantiationMode("EXPLICIT").setInstanceCreatedCallback((t,o,s)=>{t.getProvider(ht).initialize()})),me(new ge(ht,t=>{let o=t.getProvider("app-check").getImmediate();return rr(o)},"PUBLIC").setInstantiationMode("EXPLICIT")),J(nr,or)}sr();var ar="app-check";var ae=class{constructor(){return st(ar)}};var cr=["localhost","0.0.0.0","127.0.0.1"],An=typeof window<"u"&&cr.includes(window.location.hostname);var ur=new P("angularfire2.auth.use-emulator"),dr=new P("angularfire2.auth.settings"),hr=new P("angularfire2.auth.tenant-id"),pr=new P("angularfire2.auth.langugage-code"),fr=new P("angularfire2.auth.use-device-language"),gr=new P("angularfire.auth.persistence"),mr=(t,o,s,e,r,n,i,a)=>lt(`${t.name}.auth`,"AngularFireAuth",t.name,()=>{let l=o.runOutsideAngular(()=>t.auth());if(s&&l.useEmulator(...s),e&&(l.tenantId=e),l.languageCode=r,n&&l.useDeviceLanguage(),i)for(let[c,u]of Object.entries(i))l.settings[c]=u;return a&&l.setPersistence(a),l},[s,e,r,n,i,a]),De=(()=>{class t{injector=M(pe);authState;idToken;user;idTokenResult;credential;constructor(s,e,r,n,i,a,l,c,u,f,d,h){let p=new je,y=Z(void 0).pipe(G(i.outsideAngular),O(()=>n.runOutsideAngular(()=>import("./chunk-XRLXIT7I.js"))),_(()=>ke(s,n,e)),_(T=>mr(T,n,a,c,u,f,l,d)),ue({bufferSize:1,refCount:!1}));if(Ve(r))this.authState=this.user=this.idToken=this.idTokenResult=this.credential=Z(null);else{y.pipe($e()).subscribe();let T=y.pipe(O(I=>I.getRedirectResult().then(j=>j,()=>null)),Qe(this.injector),ue({bufferSize:1,refCount:!1})),W=y.pipe(O(I=>new m(j=>({unsubscribe:n.runOutsideAngular(()=>I.onAuthStateChanged(F=>j.next(F),F=>j.error(F),()=>j.complete()))})))),V=y.pipe(O(I=>new m(j=>({unsubscribe:n.runOutsideAngular(()=>I.onIdTokenChanged(F=>j.next(F),F=>j.error(F),()=>j.complete()))}))));this.authState=T.pipe(de(W),Q(i.outsideAngular),G(i.insideAngular)),this.user=T.pipe(de(V),Q(i.outsideAngular),G(i.insideAngular)),this.idToken=this.user.pipe(O(I=>I?B(I.getIdToken()):Z(null))),this.idTokenResult=this.user.pipe(O(I=>I?B(I.getIdTokenResult()):Z(null))),this.credential=Ne(T,p,this.authState.pipe(Fe(I=>!I))).pipe(_(I=>I?.user?I:null),Q(i.outsideAngular),G(i.insideAngular))}return ct(this,y,n,{spy:{apply:(T,W,V)=>{(T.startsWith("signIn")||T.startsWith("createUser"))&&V.then(I=>p.next(I))}}})}static \u0275fac=function(e){return new(e||t)(g(oe),g(ie,8),g(K),g(U),g(ve),g(ur,8),g(dr,8),g(hr,8),g(pr,8),g(fr,8),g(gr,8),g(ae,8))};static \u0275prov=D({token:t,factory:t.\u0275fac,providedIn:"any"})}return t})(),Bn=(()=>{class t{constructor(){x.registerVersion("angularfire",q.full,"auth-compat")}static \u0275fac=function(e){return new(e||t)};static \u0275mod=z({type:t});static \u0275inj=H({providers:[De]})}return t})();var b=(function(t){return t.readonly="readonly",t.readwrite="readwrite",t})(b||{}),vt=new P(null),kt=new P("Indexed DB"),wr=new P("Server Indexed DB");function Ar(t,o){return t.objectStoreNames.contains(o)}function C(t,o,s){if(!t){s("You need to use the openDatabase function to create a database before you query it!");return}Ar(t,o)||s(`objectStore does not exists: ${o}`)}function S(t,o){let s=t.transaction(o.storeName,o.dbMode);return s.onerror=o.error,s.onabort=o.abort,s}function E(t,o,s,e){return{storeName:o,dbMode:t,error:r=>{s(r)},abort:r=>{s(r)}}}var xe=[];function A(t,o,s,e){return new Promise((r,n)=>{t||n("IndexedDB not available");let i=t.open(o,s),a;i.onsuccess=()=>{a=i.result,xe.push(a),r(a)},i.onerror=()=>{n(`IndexedDB error: ${i.error}`)},typeof e=="function"&&(i.onupgradeneeded=l=>{e(l,a)})})}function Pe(t,o,s,e,r){return k(this,null,function*(){return new Promise((n,i)=>{if(!t)return;let a=t.open(o,s);a.onupgradeneeded=l=>k(null,null,function*(){let c=l.target.result,u=e.map(d=>k(null,null,function*(){if(!c.objectStoreNames.contains(d.store)){let h=c.createObjectStore(d.store,d.storeConfig);for(let p of d.storeSchema)h.createIndex(p.name,p.keypath,p.options)}}));yield Promise.all(u);let f=r&&r();if(f){let d=Object.keys(f).map(h=>parseInt(h,10)).filter(h=>h>l.oldVersion).sort((h,p)=>h-p);for(let h of d)f[h](c,a.transaction)}c.close(),n()}),a.onsuccess=l=>{l.target.result.close(),n()},a.onerror=l=>{i(l)}})})}function vr(t,o,s){if(!t||!o||!s)throw Error('Params: "dbName", "version", "storeName" are mandatory.');return new m(e=>{try{let r=o+1,n=indexedDB.open(t,r);n.onupgradeneeded=i=>{let a=i.target.result;a.deleteObjectStore(s),a.close(),console.log("onupgradeneeded"),e.next(),e.complete()},n.onerror=i=>e.error(i)}catch(r){e.error(r)}})}function kr(t){return new Promise((o,s)=>{if(!t){s(new Error("No database to close"));return}try{t.close(),o()}catch(e){s(`Error closing database: ${e}`)}})}function v(){return function(t,o,s){let e=s.value;return s.value=function(...r){let n=e.apply(this,r);return n instanceof m?n.pipe(Le(()=>k(this,null,function*(){let i=xe.map(a=>k(this,null,function*(){yield kr(a)}));yield Promise.all(i),xe.length=0}))):n},s}}var _e=(()=>{let o=class o{constructor(e,r){this.dbConfigs=e,this.indexedDB=r,this.defaultDatabaseName=null,Object.values(this.dbConfigs).forEach((n,i,a)=>this.instanciateConfig(n,a.length===1))}instanciateConfig(e,r){return k(this,null,function*(){if(!e.name)throw new Error("NgxIndexedDB: Please, provide the dbName in the configuration");if((e.isDefault??!1)&&this.defaultDatabaseName)throw new Error("NgxIndexedDB: Only one database can be set as default");((e.isDefault??!1)&&!this.defaultDatabaseName||r)&&(this.defaultDatabaseName=e.name,this.selectedDb=e.name),yield Pe(this.indexedDB,e.name,e.version,e.objectStoresMeta,e.migrationFactory),A(this.indexedDB,e.name).then(n=>{n.version!==e.version&&(L()&&(console.warn(`
4
4
  Your DB Config doesn't match the most recent version of the DB with name ${e.name}, please update it
@@ -1 +1 @@
1
- import{a as ve,b as xe}from"./chunk-PWOKOWVV.js";import{a as ge}from"./chunk-JWDQVXQP.js";import{a as Ce,b as Se}from"./chunk-K5WSFDNA.js";import{a as be}from"./chunk-NRSDIDOP.js";import{a as N}from"./chunk-SMZOSLIK.js";import{a as ye}from"./chunk-XLQGQESJ.js";import"./chunk-Z2XRGVGT.js";import"./chunk-ZGIYCORM.js";import"./chunk-C2LAQOUW.js";import{a as fe}from"./chunk-UE2QO2Y4.js";import"./chunk-MT3CWRVG.js";import"./chunk-W33M7S2S.js";import"./chunk-MTVUPPAN.js";import"./chunk-2NRHX6CZ.js";import{a as he}from"./chunk-5WQ3LCWP.js";import"./chunk-DLHIDOS3.js";import{a as _e}from"./chunk-27DIE2YS.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-A6QXXKPR.js";import"./chunk-ZDBFIPDM.js";import"./chunk-DDFP4CNP.js";import"./chunk-RBZU7OVM.js";import{b as ue}from"./chunk-BUMWMFHU.js";import"./chunk-ROS2QMKF.js";import"./chunk-5WT456T7.js";import{a as ce}from"./chunk-YNL43MLU.js";import"./chunk-3SCX7IMW.js";import"./chunk-6C4UBIZK.js";import"./chunk-SPLGZRGH.js";import"./chunk-4S4BOPUV.js";import"./chunk-TBVMCNS2.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 pe}from"./chunk-O4D64GHO.js";import"./chunk-7R2D2JZ6.js";import"./chunk-QMQCIH3X.js";import"./chunk-YYV4FSYQ.js";import"./chunk-QXRG5XYP.js";import"./chunk-AGBJEXIM.js";import"./chunk-5UFP37GQ.js";import{b as ne}from"./chunk-UPRDDI4K.js";import{A as me,b as re,c as le,h as ae,m as se,o as de}from"./chunk-WAXAIL2I.js";import"./chunk-RQUCYFCB.js";import"./chunk-RXLMJGUY.js";import{b as oe}from"./chunk-MM7SAZOU.js";import"./chunk-NQLMPUSB.js";import"./chunk-OSGPJXJZ.js";import{A as ie,w as $,x as ee,z as te}from"./chunk-JNRCB7N3.js";import"./chunk-XBIHN6D3.js";import{$c as K,Cc as H,Dc as Q,Ec as j,Hb as D,Ia as P,Mc as q,Nc as d,Oc as w,Pc as M,Rc as C,Sc as S,Tc as y,Uc as U,Vc as G,Wc as F,Z as I,_c as J,ac as v,ad as X,cc as x,dc as B,ea as k,fc as A,gc as z,hc as f,ic as t,id as V,jc as n,jd as O,kc as h,kd as Y,mb as W,ob as a,pd as Z,ra as E,rc as T,wc as g,ya as p,yc as u,za as c}from"./chunk-OHGMB7HJ.js";import"./chunk-WFMAM73Y.js";import{a as R,b as L}from"./chunk-66YHNWRR.js";var Te=["contextMenu"],we=()=>[],Me=l=>({"td-cell-hover":l});function Ve(l,m){if(l&1){let e=T();t(0,"button",20),g("click",function(){p(e);let r=u();return c(r.setMultipleFulfillment())}),d(1," Set Fulfillment "),n()}}function Re(l,m){if(l&1&&h(0,"variants-dropdown",38),l&2){let e=u().$implicit;f("variants",e==null?null:e.Variants)}}function Ee(l,m){if(l&1&&h(0,"variant-with-image",39),l&2){let e=u().$implicit;f("variant",e==null?null:e.Variants[0])}}function Oe(l,m){if(l&1&&(t(0,"span"),d(1),n()),l&2){let e=u().$implicit;a(),M("(",e.LogisticService==null?null:e.LogisticService.Option,")")}}function Pe(l,m){if(l&1){let e=T();t(0,"div",41)(1,"button",45),g("click",function(){p(e);let r=u().$implicit,o=u(2);return c(o.refreshShippingAndRefNumber(r))}),h(2,"i",46),n()()}}function Fe(l,m){if(l&1){let e=T();t(0,"button",47),g("click",function(){p(e);let r=u().$implicit,o=u(2);return c(o.onSetFulfillment(r))}),d(1," Set Fulfillment "),n()}}function Ne(l,m){if(l&1){let e=T();t(0,"tr")(1,"td")(2,"input",30),y("ngModelChange",function(r){let o=p(e).$implicit;return S(o.selected,r)||(o.selected=r),c(r)}),g("ngModelChange",function(){p(e);let r=u(2),o=F(0);return c(r.onSelectOrder(o))}),n()(),t(3,"td")(4,"div",31),h(5,"img",32),V(6,"channelImage"),t(7,"div",33)(8,"div"),d(9),n(),t(10,"small",34)(11,"span"),d(12),n()()()()(),t(13,"td")(14,"div",35)(15,"div"),h(16,"order-link",36),n(),t(17,"small"),d(18),V(19,"date"),n(),h(20,"br"),t(21,"small"),h(22,"i",37),d(23),n()()(),t(24,"td"),v(25,Re,1,1,"variants-dropdown",38)(26,Ee,1,1,"variant-with-image",39),n(),t(27,"td",40),d(28),V(29,"number"),n(),t(30,"td",41)(31,"div",42)(32,"div",35)(33,"div",43)(34,"span"),d(35),n(),v(36,Oe,2,1,"span"),n(),t(37,"small"),d(38),n()(),v(39,Pe,3,0,"div",41),n()(),t(40,"td",41),v(41,Fe,2,0,"button",44),n()()}if(l&2){let e=m.$implicit,i=u(2);a(2),C("ngModel",e.selected),f("disabled",i.selectedChannelType()!=null&&i.selectedChannelType()!=e.MarketType),a(3),f("src",O(6,18,e==null?null:e.MarketType),W)("alt",e==null||e.Variants[0]==null?null:e.Variants[0].Name),a(4),w(e.Outlet),a(3),w(e.ChannelName),a(4),f("order",e),a(2),M(" ",Y(19,20,e==null?null:e.Created,"dd/MM/yyyy HH:mm:ss")," "),a(5),M(" ",e.Customer," "),a(),q(X(25,Me,(e.Variants==null?null:e.Variants.length)>1)),a(),x((e.Variants==null?null:e.Variants.length)>1?25:26),a(3),w(O(29,23,e.Amount)),a(7),w(e.LogisticService!=null&&e.LogisticService.Name?e.LogisticService==null?null:e.LogisticService.Name:"-"),a(),x(e.LogisticService!=null&&e.LogisticService.Option&&(e.LogisticService==null?null:e.LogisticService.Option)!="Default"?36:-1),a(2),M(" ",e.ReferenceNumber?e.ReferenceNumber:"-"," "),a(),x(!(e.LogisticService!=null&&e.LogisticService.Name)||!e.ReferenceNumber?39:-1),a(2),x((e==null?null:e.MarketType)!=i.channelType.WooCommerce?41:-1)}}function Le(l,m){if(l&1){let e=T();t(0,"div",17)(1,"table",21)(2,"thead",22)(3,"tr",23),h(4,"th",24),t(5,"th",25),d(6,"Outlet"),n(),t(7,"th",25),d(8,"Number"),n(),t(9,"th"),d(10,"Items"),n(),t(11,"th",26),d(12,"Amount"),n(),t(13,"th",27),d(14,"Shipping"),n(),h(15,"th",28),n()(),t(16,"tbody"),A(17,Ne,42,27,"tr",null,B),n()(),t(19,"app-custom-paginator",29),g("next",function(){p(e);let r=u();return c(r.initReadyToShip())})("previous",function(){p(e);let r=u();return c(r.initReadyToShip())}),n()()}if(l&2){let e=u(),i=F(0);a(17),z(i),a(2),f("filter",e.filter())("totaldata",i==null?null:i.length)}}function Ie(l,m){l&1&&(t(0,"div",18),h(1,"app-empty-state"),n())}var st=(()=>{let m=class m{constructor(){this.toastr=E(oe),this.orderService=E(N),this.fulfillmentService=E(ve),this.channelType=ne,this.selectedOrders=P([]),this.selectedChannelType=Z(()=>{let i=null;return this.selectedOrders().length>0&&(i=this.selectedOrders()[0].MarketType),i}),this.filter=P({PageNumber:1,PageSize:20,ListChannelID:[],From:null,To:null,Number:null}),this.contextMenuItems=[{id:"refresh",label:"Refresh Shipping",icon:"fa-solid fa-arrows-rotate"}]}ngOnInit(){this.orderService.getOrderDefaultValue().subscribe({next:i=>{this.initFromDate(i)},error:i=>{console.error("Error fetching default date:",i),this.initFromDate(null)}})}initFromDate(i){this.filter.update(r=>L(R({},r),{From:i})),this.initReadyToShip()}initReadyToShip(){this.readyToShip$=this.orderService.getReadyToShipOrders(this.filter()).pipe(k(()=>{this.selectedOrders.set([])}),I(1))}onFilterChange(i){this.filter.update(r=>R(R({},r),i))}onSetFulfillment(i){this.fulfillmentService.setFulfillmentOrder(i).subscribe(()=>{this.toastr.success("Fulfillment set successfully","Success"),this.initReadyToShip()})}refreshShippingAndRefNumber(i){this.orderService.refreshShippingCourier(i.ShopID,i.Number).subscribe(()=>{this.toastr.success("Shipping courier and reference number refreshed","Success"),this.initReadyToShip()})}setMultipleFulfillment(){this.fulfillmentService.setFulfillmentMultipleOrders(this.selectedOrders()).subscribe(()=>{this.toastr.success("Fulfillment set successfully","Success"),this.initReadyToShip()})}onSelectOrder(i){let r=i.filter(o=>o.selected);this.selectedOrders.set(r)}onMouseHover(i,r){(!r.LogisticService?.Name||!r.ReferenceNumber)&&this.contextMenuEl.show(i,r)}onSelectContextItem(i){i.item?.id==="refresh"&&this.refreshShippingAndRefNumber(i.data)}};m.\u0275fac=function(r){return new(r||m)},m.\u0275cmp=D({type:m,selectors:[["app-ready-to-ship"]],viewQuery:function(r,o){if(r&1&&H(Te,5),r&2){let _;Q(_=j())&&(o.contextMenuEl=_.first)}},features:[J([N])],decls:37,vars:14,consts:[["contextMenu",""],["headerTitle","To Ship","searchBoxPlaceHolder","Order Number...",3,"onSubmit","textChange","text"],[1,"btn","btn-outline-secondary","shadow","rounded"],["href","https://ods.dealpos.app","target","_blank","matTooltip","Monitor your Order & Fulfillment in real-time from TV!",1,"btn","btn-outline-secondary","shadow","rounded","ms-2"],[1,"fa-regular","fa-tv","me-3"],[1,"fw-bold","mb-2"],[3,"ngModelChange","multiple","ngModel"],[1,"mt-5"],[1,"mb-4"],["name","From",3,"dateChange","date"],["name","To",3,"dateChange","date"],[1,"fw-bold"],["type","number","name","PageNumber",1,"w-100","mt-2","form-control",3,"ngModelChange","ngModel"],["type","number","name","PageSize",1,"w-100","mt-2","form-control",3,"ngModelChange","ngModel"],[1,"container-fluid","mt-3"],[1,"row"],[1,"col-md-12"],[1,"table-responsive"],[1,"d-flex","flex-column","justify-content-center","align-items-center",2,"margin-top","26vh"],[3,"onSelectItem","items"],[1,"btn","btn-outline-secondary","shadow","rounded",3,"click"],[1,"table"],[1,"sticky-top-thead"],[1,"table-light"],[2,"width","5px"],[2,"width","200px"],[1,"text-end",2,"width","100px"],[2,"width","80px"],[2,"width","150px"],["rowCountApi","/api/orders/toshipcount",3,"next","previous","filter","totaldata"],["type","checkbox",3,"ngModelChange","ngModel","disabled"],[1,"d-flex","align-items-center","gap-3"],[2,"width","20px","height","20px",3,"src","alt"],[1,"lh-base"],[1,"d-flex","align-items-center","gap-2"],[1,"lh-sm"],[2,"font-size","14px",3,"order"],[1,"fa-solid","fa-user"],[3,"variants"],[3,"variant"],[1,"text-end"],[1,"actions-cell"],[1,"d-flex","align-items-center","gap-6"],[1,"d-flex","align-items-end","gap-2"],[1,"btn","btn-success","btn-sm",2,"--bs-btn-padding-y","0.25rem","--bs-btn-padding-x","0.5rem","--bs-btn-font-size","0.75rem"],["matTooltip","Retrieve shipping courier and reference number",1,"btn","btn-icon-only",3,"click"],[1,"fa-solid","fa-arrows-rotate","fs-6"],[1,"btn","btn-success","btn-sm",2,"--bs-btn-padding-y","0.25rem","--bs-btn-padding-x","0.5rem","--bs-btn-font-size","0.75rem",3,"click"]],template:function(r,o){if(r&1){let _=T();U(0),V(1,"async"),t(2,"mainpanel",1),g("onSubmit",function(){return p(_),c(o.initReadyToShip())}),y("textChange",function(s){return p(_),S(o.filter().Number,s)||(o.filter().Number=s),c(s)}),t(3,"actions"),v(4,Ve,2,0,"button",2),t(5,"a",3),h(6,"i",4),t(7,"span"),d(8,"Order Fulfillment Display"),n()()(),t(9,"filters")(10,"div")(11,"label",5),d(12,"Channel"),n(),t(13,"app-channel-options-v2",6),y("ngModelChange",function(s){return p(_),S(o.filter().ListChannelID,s)||(o.filter().ListChannelID=s),c(s)}),n()(),t(14,"div",7)(15,"label",5),d(16,"From/To"),n(),t(17,"div",8)(18,"datepicker",9),y("dateChange",function(s){return p(_),S(o.filter().From,s)||(o.filter().From=s),c(s)}),n()(),t(19,"div")(20,"datepicker",10),y("dateChange",function(s){return p(_),S(o.filter().To,s)||(o.filter().To=s),c(s)}),n()()(),t(21,"div",7)(22,"label",11),d(23,"Page Number"),n(),t(24,"input",12),y("ngModelChange",function(s){return p(_),S(o.filter().PageNumber,s)||(o.filter().PageNumber=s),c(s)}),n()(),t(25,"div",7)(26,"label",11),d(27,"Page Size"),n(),t(28,"input",13),y("ngModelChange",function(s){return p(_),S(o.filter().PageSize,s)||(o.filter().PageSize=s),c(s)}),n()()(),t(29,"content")(30,"div",14)(31,"div",15)(32,"div",16),v(33,Le,20,2,"div",17)(34,Ie,2,0,"div",18),n()()()()(),t(35,"app-context-menu",19,0),g("onSelectItem",function(s){return p(_),c(o.onSelectContextItem(s))}),n()}if(r&2){let _=G(O(1,10,o.readyToShip$)||K(13,we));a(2),C("text",o.filter().Number),a(2),x(o.selectedOrders().length>0?4:-1),a(9),f("multiple",!0),C("ngModel",o.filter().ListChannelID),a(5),C("date",o.filter().From),a(2),C("date",o.filter().To),a(4),C("ngModel",o.filter().PageNumber),a(4),C("ngModel",o.filter().PageSize),a(5),x(_.length>0?33:34),a(2),f("items",o.contextMenuItems)}},dependencies:[ie,ue,_e,he,me,le,de,re,ae,se,Ce,Se,ye,be,ce,pe,xe,fe,$,te,ee,ge],styles:[".actions-cell[_ngcontent-%COMP%] .btn[_ngcontent-%COMP%]{opacity:0;visibility:hidden;transition:opacity .12s ease-in-out}tr[_ngcontent-%COMP%]:hover .actions-cell[_ngcontent-%COMP%] .btn[_ngcontent-%COMP%], div[_ngcontent-%COMP%]:hover.actions-cell .btn[_ngcontent-%COMP%], .actions-cell[_ngcontent-%COMP%]:hover .btn[_ngcontent-%COMP%], .actions-cell[_ngcontent-%COMP%]:focus-within .btn[_ngcontent-%COMP%], .actions-cell[_ngcontent-%COMP%] .btn[_ngcontent-%COMP%]:focus{opacity:1;visibility:visible}"]});let l=m;return l})();export{st as ReadyToShipComponent};
1
+ import{a as ve,b as xe}from"./chunk-PWOKOWVV.js";import{a as ge}from"./chunk-JWDQVXQP.js";import{a as Ce,b as Se}from"./chunk-K5WSFDNA.js";import{a as be}from"./chunk-UMMQ62IZ.js";import{a as N}from"./chunk-SMZOSLIK.js";import{a as ye}from"./chunk-XLQGQESJ.js";import"./chunk-Z2XRGVGT.js";import"./chunk-ZGIYCORM.js";import"./chunk-C2LAQOUW.js";import{a as fe}from"./chunk-RWPLFNHT.js";import"./chunk-MT3CWRVG.js";import"./chunk-W33M7S2S.js";import"./chunk-MTVUPPAN.js";import"./chunk-2NRHX6CZ.js";import{a as he}from"./chunk-5WQ3LCWP.js";import"./chunk-DLHIDOS3.js";import{a as _e}from"./chunk-27DIE2YS.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-A6QXXKPR.js";import"./chunk-ZDBFIPDM.js";import"./chunk-DDFP4CNP.js";import"./chunk-RBZU7OVM.js";import{b as ue}from"./chunk-BUMWMFHU.js";import"./chunk-ROS2QMKF.js";import"./chunk-5WT456T7.js";import{a as ce}from"./chunk-YNL43MLU.js";import"./chunk-3SCX7IMW.js";import"./chunk-6C4UBIZK.js";import"./chunk-SPLGZRGH.js";import"./chunk-4S4BOPUV.js";import"./chunk-TBVMCNS2.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 pe}from"./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{b as ne}from"./chunk-UPRDDI4K.js";import{A as me,b as re,c as le,h as ae,m as se,o as de}from"./chunk-WAXAIL2I.js";import"./chunk-RQUCYFCB.js";import"./chunk-RXLMJGUY.js";import{b as oe}from"./chunk-MM7SAZOU.js";import"./chunk-NQLMPUSB.js";import"./chunk-OSGPJXJZ.js";import{A as ie,w as $,x as ee,z as te}from"./chunk-JNRCB7N3.js";import"./chunk-XBIHN6D3.js";import{$c as K,Cc as H,Dc as Q,Ec as j,Hb as D,Ia as P,Mc as q,Nc as d,Oc as w,Pc as M,Rc as C,Sc as S,Tc as y,Uc as U,Vc as G,Wc as F,Z as I,_c as J,ac as v,ad as X,cc as x,dc as B,ea as k,fc as A,gc as z,hc as f,ic as t,id as V,jc as n,jd as O,kc as h,kd as Y,mb as W,ob as a,pd as Z,ra as E,rc as T,wc as g,ya as p,yc as u,za as c}from"./chunk-OHGMB7HJ.js";import"./chunk-WFMAM73Y.js";import{a as R,b as L}from"./chunk-66YHNWRR.js";var Te=["contextMenu"],we=()=>[],Me=l=>({"td-cell-hover":l});function Ve(l,m){if(l&1){let e=T();t(0,"button",20),g("click",function(){p(e);let r=u();return c(r.setMultipleFulfillment())}),d(1," Set Fulfillment "),n()}}function Re(l,m){if(l&1&&h(0,"variants-dropdown",38),l&2){let e=u().$implicit;f("variants",e==null?null:e.Variants)}}function Ee(l,m){if(l&1&&h(0,"variant-with-image",39),l&2){let e=u().$implicit;f("variant",e==null?null:e.Variants[0])}}function Oe(l,m){if(l&1&&(t(0,"span"),d(1),n()),l&2){let e=u().$implicit;a(),M("(",e.LogisticService==null?null:e.LogisticService.Option,")")}}function Pe(l,m){if(l&1){let e=T();t(0,"div",41)(1,"button",45),g("click",function(){p(e);let r=u().$implicit,o=u(2);return c(o.refreshShippingAndRefNumber(r))}),h(2,"i",46),n()()}}function Fe(l,m){if(l&1){let e=T();t(0,"button",47),g("click",function(){p(e);let r=u().$implicit,o=u(2);return c(o.onSetFulfillment(r))}),d(1," Set Fulfillment "),n()}}function Ne(l,m){if(l&1){let e=T();t(0,"tr")(1,"td")(2,"input",30),y("ngModelChange",function(r){let o=p(e).$implicit;return S(o.selected,r)||(o.selected=r),c(r)}),g("ngModelChange",function(){p(e);let r=u(2),o=F(0);return c(r.onSelectOrder(o))}),n()(),t(3,"td")(4,"div",31),h(5,"img",32),V(6,"channelImage"),t(7,"div",33)(8,"div"),d(9),n(),t(10,"small",34)(11,"span"),d(12),n()()()()(),t(13,"td")(14,"div",35)(15,"div"),h(16,"order-link",36),n(),t(17,"small"),d(18),V(19,"date"),n(),h(20,"br"),t(21,"small"),h(22,"i",37),d(23),n()()(),t(24,"td"),v(25,Re,1,1,"variants-dropdown",38)(26,Ee,1,1,"variant-with-image",39),n(),t(27,"td",40),d(28),V(29,"number"),n(),t(30,"td",41)(31,"div",42)(32,"div",35)(33,"div",43)(34,"span"),d(35),n(),v(36,Oe,2,1,"span"),n(),t(37,"small"),d(38),n()(),v(39,Pe,3,0,"div",41),n()(),t(40,"td",41),v(41,Fe,2,0,"button",44),n()()}if(l&2){let e=m.$implicit,i=u(2);a(2),C("ngModel",e.selected),f("disabled",i.selectedChannelType()!=null&&i.selectedChannelType()!=e.MarketType),a(3),f("src",O(6,18,e==null?null:e.MarketType),W)("alt",e==null||e.Variants[0]==null?null:e.Variants[0].Name),a(4),w(e.Outlet),a(3),w(e.ChannelName),a(4),f("order",e),a(2),M(" ",Y(19,20,e==null?null:e.Created,"dd/MM/yyyy HH:mm:ss")," "),a(5),M(" ",e.Customer," "),a(),q(X(25,Me,(e.Variants==null?null:e.Variants.length)>1)),a(),x((e.Variants==null?null:e.Variants.length)>1?25:26),a(3),w(O(29,23,e.Amount)),a(7),w(e.LogisticService!=null&&e.LogisticService.Name?e.LogisticService==null?null:e.LogisticService.Name:"-"),a(),x(e.LogisticService!=null&&e.LogisticService.Option&&(e.LogisticService==null?null:e.LogisticService.Option)!="Default"?36:-1),a(2),M(" ",e.ReferenceNumber?e.ReferenceNumber:"-"," "),a(),x(!(e.LogisticService!=null&&e.LogisticService.Name)||!e.ReferenceNumber?39:-1),a(2),x((e==null?null:e.MarketType)!=i.channelType.WooCommerce?41:-1)}}function Le(l,m){if(l&1){let e=T();t(0,"div",17)(1,"table",21)(2,"thead",22)(3,"tr",23),h(4,"th",24),t(5,"th",25),d(6,"Outlet"),n(),t(7,"th",25),d(8,"Number"),n(),t(9,"th"),d(10,"Items"),n(),t(11,"th",26),d(12,"Amount"),n(),t(13,"th",27),d(14,"Shipping"),n(),h(15,"th",28),n()(),t(16,"tbody"),A(17,Ne,42,27,"tr",null,B),n()(),t(19,"app-custom-paginator",29),g("next",function(){p(e);let r=u();return c(r.initReadyToShip())})("previous",function(){p(e);let r=u();return c(r.initReadyToShip())}),n()()}if(l&2){let e=u(),i=F(0);a(17),z(i),a(2),f("filter",e.filter())("totaldata",i==null?null:i.length)}}function Ie(l,m){l&1&&(t(0,"div",18),h(1,"app-empty-state"),n())}var st=(()=>{let m=class m{constructor(){this.toastr=E(oe),this.orderService=E(N),this.fulfillmentService=E(ve),this.channelType=ne,this.selectedOrders=P([]),this.selectedChannelType=Z(()=>{let i=null;return this.selectedOrders().length>0&&(i=this.selectedOrders()[0].MarketType),i}),this.filter=P({PageNumber:1,PageSize:20,ListChannelID:[],From:null,To:null,Number:null}),this.contextMenuItems=[{id:"refresh",label:"Refresh Shipping",icon:"fa-solid fa-arrows-rotate"}]}ngOnInit(){this.orderService.getOrderDefaultValue().subscribe({next:i=>{this.initFromDate(i)},error:i=>{console.error("Error fetching default date:",i),this.initFromDate(null)}})}initFromDate(i){this.filter.update(r=>L(R({},r),{From:i})),this.initReadyToShip()}initReadyToShip(){this.readyToShip$=this.orderService.getReadyToShipOrders(this.filter()).pipe(k(()=>{this.selectedOrders.set([])}),I(1))}onFilterChange(i){this.filter.update(r=>R(R({},r),i))}onSetFulfillment(i){this.fulfillmentService.setFulfillmentOrder(i).subscribe(()=>{this.toastr.success("Fulfillment set successfully","Success"),this.initReadyToShip()})}refreshShippingAndRefNumber(i){this.orderService.refreshShippingCourier(i.ShopID,i.Number).subscribe(()=>{this.toastr.success("Shipping courier and reference number refreshed","Success"),this.initReadyToShip()})}setMultipleFulfillment(){this.fulfillmentService.setFulfillmentMultipleOrders(this.selectedOrders()).subscribe(()=>{this.toastr.success("Fulfillment set successfully","Success"),this.initReadyToShip()})}onSelectOrder(i){let r=i.filter(o=>o.selected);this.selectedOrders.set(r)}onMouseHover(i,r){(!r.LogisticService?.Name||!r.ReferenceNumber)&&this.contextMenuEl.show(i,r)}onSelectContextItem(i){i.item?.id==="refresh"&&this.refreshShippingAndRefNumber(i.data)}};m.\u0275fac=function(r){return new(r||m)},m.\u0275cmp=D({type:m,selectors:[["app-ready-to-ship"]],viewQuery:function(r,o){if(r&1&&H(Te,5),r&2){let _;Q(_=j())&&(o.contextMenuEl=_.first)}},features:[J([N])],decls:37,vars:14,consts:[["contextMenu",""],["headerTitle","To Ship","searchBoxPlaceHolder","Order Number...",3,"onSubmit","textChange","text"],[1,"btn","btn-outline-secondary","shadow","rounded"],["href","https://ods.dealpos.app","target","_blank","matTooltip","Monitor your Order & Fulfillment in real-time from TV!",1,"btn","btn-outline-secondary","shadow","rounded","ms-2"],[1,"fa-regular","fa-tv","me-3"],[1,"fw-bold","mb-2"],[3,"ngModelChange","multiple","ngModel"],[1,"mt-5"],[1,"mb-4"],["name","From",3,"dateChange","date"],["name","To",3,"dateChange","date"],[1,"fw-bold"],["type","number","name","PageNumber",1,"w-100","mt-2","form-control",3,"ngModelChange","ngModel"],["type","number","name","PageSize",1,"w-100","mt-2","form-control",3,"ngModelChange","ngModel"],[1,"container-fluid","mt-3"],[1,"row"],[1,"col-md-12"],[1,"table-responsive"],[1,"d-flex","flex-column","justify-content-center","align-items-center",2,"margin-top","26vh"],[3,"onSelectItem","items"],[1,"btn","btn-outline-secondary","shadow","rounded",3,"click"],[1,"table"],[1,"sticky-top-thead"],[1,"table-light"],[2,"width","5px"],[2,"width","200px"],[1,"text-end",2,"width","100px"],[2,"width","80px"],[2,"width","150px"],["rowCountApi","/api/orders/toshipcount",3,"next","previous","filter","totaldata"],["type","checkbox",3,"ngModelChange","ngModel","disabled"],[1,"d-flex","align-items-center","gap-3"],[2,"width","20px","height","20px",3,"src","alt"],[1,"lh-base"],[1,"d-flex","align-items-center","gap-2"],[1,"lh-sm"],[2,"font-size","14px",3,"order"],[1,"fa-solid","fa-user"],[3,"variants"],[3,"variant"],[1,"text-end"],[1,"actions-cell"],[1,"d-flex","align-items-center","gap-6"],[1,"d-flex","align-items-end","gap-2"],[1,"btn","btn-success","btn-sm",2,"--bs-btn-padding-y","0.25rem","--bs-btn-padding-x","0.5rem","--bs-btn-font-size","0.75rem"],["matTooltip","Retrieve shipping courier and reference number",1,"btn","btn-icon-only",3,"click"],[1,"fa-solid","fa-arrows-rotate","fs-6"],[1,"btn","btn-success","btn-sm",2,"--bs-btn-padding-y","0.25rem","--bs-btn-padding-x","0.5rem","--bs-btn-font-size","0.75rem",3,"click"]],template:function(r,o){if(r&1){let _=T();U(0),V(1,"async"),t(2,"mainpanel",1),g("onSubmit",function(){return p(_),c(o.initReadyToShip())}),y("textChange",function(s){return p(_),S(o.filter().Number,s)||(o.filter().Number=s),c(s)}),t(3,"actions"),v(4,Ve,2,0,"button",2),t(5,"a",3),h(6,"i",4),t(7,"span"),d(8,"Order Fulfillment Display"),n()()(),t(9,"filters")(10,"div")(11,"label",5),d(12,"Channel"),n(),t(13,"app-channel-options-v2",6),y("ngModelChange",function(s){return p(_),S(o.filter().ListChannelID,s)||(o.filter().ListChannelID=s),c(s)}),n()(),t(14,"div",7)(15,"label",5),d(16,"From/To"),n(),t(17,"div",8)(18,"datepicker",9),y("dateChange",function(s){return p(_),S(o.filter().From,s)||(o.filter().From=s),c(s)}),n()(),t(19,"div")(20,"datepicker",10),y("dateChange",function(s){return p(_),S(o.filter().To,s)||(o.filter().To=s),c(s)}),n()()(),t(21,"div",7)(22,"label",11),d(23,"Page Number"),n(),t(24,"input",12),y("ngModelChange",function(s){return p(_),S(o.filter().PageNumber,s)||(o.filter().PageNumber=s),c(s)}),n()(),t(25,"div",7)(26,"label",11),d(27,"Page Size"),n(),t(28,"input",13),y("ngModelChange",function(s){return p(_),S(o.filter().PageSize,s)||(o.filter().PageSize=s),c(s)}),n()()(),t(29,"content")(30,"div",14)(31,"div",15)(32,"div",16),v(33,Le,20,2,"div",17)(34,Ie,2,0,"div",18),n()()()()(),t(35,"app-context-menu",19,0),g("onSelectItem",function(s){return p(_),c(o.onSelectContextItem(s))}),n()}if(r&2){let _=G(O(1,10,o.readyToShip$)||K(13,we));a(2),C("text",o.filter().Number),a(2),x(o.selectedOrders().length>0?4:-1),a(9),f("multiple",!0),C("ngModel",o.filter().ListChannelID),a(5),C("date",o.filter().From),a(2),C("date",o.filter().To),a(4),C("ngModel",o.filter().PageNumber),a(4),C("ngModel",o.filter().PageSize),a(5),x(_.length>0?33:34),a(2),f("items",o.contextMenuItems)}},dependencies:[ie,ue,_e,he,me,le,de,re,ae,se,Ce,Se,ye,be,ce,pe,xe,fe,$,te,ee,ge],styles:[".actions-cell[_ngcontent-%COMP%] .btn[_ngcontent-%COMP%]{opacity:0;visibility:hidden;transition:opacity .12s ease-in-out}tr[_ngcontent-%COMP%]:hover .actions-cell[_ngcontent-%COMP%] .btn[_ngcontent-%COMP%], div[_ngcontent-%COMP%]:hover.actions-cell .btn[_ngcontent-%COMP%], .actions-cell[_ngcontent-%COMP%]:hover .btn[_ngcontent-%COMP%], .actions-cell[_ngcontent-%COMP%]:focus-within .btn[_ngcontent-%COMP%], .actions-cell[_ngcontent-%COMP%] .btn[_ngcontent-%COMP%]:focus{opacity:1;visibility:visible}"]});let l=m;return l})();export{st as ReadyToShipComponent};
@@ -1 +1 @@
1
- import{a as le}from"./chunk-NRSDIDOP.js";import{a as M}from"./chunk-SMZOSLIK.js";import{a as ae}from"./chunk-XLQGQESJ.js";import{a as re}from"./chunk-YKKHSYDW.js";import{a as ne}from"./chunk-UE2QO2Y4.js";import"./chunk-MT3CWRVG.js";import"./chunk-W33M7S2S.js";import"./chunk-MTVUPPAN.js";import"./chunk-2NRHX6CZ.js";import{a as ie}from"./chunk-5WQ3LCWP.js";import{a as te}from"./chunk-27DIE2YS.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-A6QXXKPR.js";import"./chunk-ZDBFIPDM.js";import"./chunk-DDFP4CNP.js";import"./chunk-RBZU7OVM.js";import{b as ee}from"./chunk-BUMWMFHU.js";import"./chunk-ROS2QMKF.js";import"./chunk-5WT456T7.js";import{a as $}from"./chunk-YNL43MLU.js";import"./chunk-3SCX7IMW.js";import"./chunk-6C4UBIZK.js";import"./chunk-SPLGZRGH.js";import"./chunk-4S4BOPUV.js";import"./chunk-TBVMCNS2.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 Z}from"./chunk-O4D64GHO.js";import"./chunk-7R2D2JZ6.js";import"./chunk-QMQCIH3X.js";import"./chunk-YYV4FSYQ.js";import"./chunk-QXRG5XYP.js";import"./chunk-AGBJEXIM.js";import"./chunk-5UFP37GQ.js";import"./chunk-UPRDDI4K.js";import{A as Y,c as K,h as Q,m as U,o as X}from"./chunk-WAXAIL2I.js";import"./chunk-RQUCYFCB.js";import"./chunk-RXLMJGUY.js";import"./chunk-MM7SAZOU.js";import"./chunk-NQLMPUSB.js";import"./chunk-OSGPJXJZ.js";import{A as J,w as j,x as q,z as G}from"./chunk-JNRCB7N3.js";import"./chunk-XBIHN6D3.js";import{Hb as D,Ia as W,Nc as a,Oc as w,Rc as C,Sc as f,Tc as g,Uc as k,Vc as A,Wc as z,Z as P,_c as H,ac as F,cc as N,dc as L,fc as B,gc as I,hc as h,ic as e,id as b,jc as t,jd as E,kc as y,kd as R,ob as r,ra as O,rc as v,wc as x,ya as u,yc as S,za as c}from"./chunk-OHGMB7HJ.js";import"./chunk-WFMAM73Y.js";import{a as T,b as V}from"./chunk-66YHNWRR.js";function oe(d,m){if(d&1&&(e(0,"tr")(1,"td"),a(2),t(),e(3,"td"),y(4,"order-link",26),t(),e(5,"td"),a(6),t(),e(7,"td"),a(8),b(9,"number"),t(),e(10,"td"),a(11),b(12,"date"),t(),e(13,"td"),y(14,"app-channel-logo",27),t()()),d&2){let o=m.$implicit;r(2),w(o.Outlet),r(2),h("order",o),r(2),w(o.Customer),r(2),w(E(9,6,o.Amount)),r(3),w(R(12,8,o.Created,"dd MMM yyyy HH:mm")),r(3),h("typeId",o==null?null:o.TypeID)}}function de(d,m){if(d&1){let o=v();e(0,"div",15)(1,"table",17)(2,"thead",18)(3,"tr",19)(4,"th",20),a(5,"Outlet"),t(),e(6,"th",21),a(7,"Order number"),t(),e(8,"th"),a(9,"Customer"),t(),e(10,"th",22),a(11,"Amount"),t(),e(12,"th",23),a(13," Created On "),t(),e(14,"th",24),a(15,"Channel"),t()()(),e(16,"tbody"),B(17,oe,15,11,"tr",null,L),t()(),e(19,"app-custom-paginator",25),x("next",function(){u(o);let p=S();return c(p.initCancelledOrders())})("previous",function(){u(o);let p=S();return c(p.initCancelledOrders())}),t()()}if(d&2){let o=S(),l=z(0);r(17),I(l),r(2),h("filter",o.filter())("totaldata",l==null?null:l.length)("paginationTotal",l==null?null:l.length)("hasClicked",!0)("nextButtonAlwaysVisible",!0)}}function me(d,m){d&1&&(e(0,"div",16),y(1,"app-empty-state"),t())}var Pe=(()=>{let m=class m{constructor(){this.orderService=O(M),this.filter=W({PageNumber:1,PageSize:20,ListChannelID:[],From:null,To:null,Number:null})}ngOnInit(){this.orderService.getOrderDefaultValue().subscribe({next:l=>{this.initFromDate(l)},error:l=>{console.error("Error fetching default date:",l),this.initFromDate(null)}})}initFromDate(l){this.filter.update(p=>V(T({},p),{From:l})),this.initCancelledOrders()}initCancelledOrders(){this.cancelledOrders$=this.orderService.getCancelledOrders(this.filter()).pipe(P(1))}};m.\u0275fac=function(p){return new(p||m)},m.\u0275cmp=D({type:m,selectors:[["app-cancelled"]],features:[H([M])],decls:34,vars:11,consts:[["headerTitle","Cancelled","searchBoxPlaceHolder","Order Number...",3,"onSubmit","textChange","text"],["href","https://ods.dealpos.app","target","_blank","matTooltip","Monitor your Order & Fulfillment in real-time from TV!",1,"btn","btn-outline-secondary","shadow","rounded","ms-2"],[1,"fa-regular","fa-tv","me-3"],[1,"fw-bold","mb-2"],[3,"ngModelChange","multiple","ngModel"],[1,"mt-5"],[1,"mb-4"],["name","From",3,"dateChange","date"],["name","To",3,"dateChange","date"],[1,"fw-bold"],["type","number","name","PageNumber",1,"w-100","mt-2","form-control",3,"ngModelChange","ngModel"],["type","number","name","PageSize",1,"w-100","mt-2","form-control",3,"ngModelChange","ngModel"],[1,"container-fluid","mt-3"],[1,"row"],[1,"col-md-12"],[1,"table-responsive"],[1,"d-flex","flex-column","justify-content-center","align-items-center",2,"margin-top","26vh"],[1,"table","table-hover"],[1,"sticky-top-thead"],[1,"table-light"],[2,"width","120px"],[2,"width","220px"],[2,"width","100px"],["mat-sort-header","created",2,"width","130px"],[2,"width","130px"],[3,"next","previous","filter","totaldata","paginationTotal","hasClicked","nextButtonAlwaysVisible"],[3,"order"],[3,"typeId"]],template:function(p,n){if(p&1){let s=v();k(0),b(1,"async"),e(2,"mainpanel",0),x("onSubmit",function(){return u(s),c(n.initCancelledOrders())}),g("textChange",function(i){return u(s),f(n.filter().Number,i)||(n.filter().Number=i),c(i)}),e(3,"actions")(4,"a",1),y(5,"i",2),e(6,"span"),a(7,"Order Fulfillment Display"),t()()(),e(8,"filters")(9,"div")(10,"label",3),a(11,"Channel"),t(),e(12,"app-channel-options-v2",4),g("ngModelChange",function(i){return u(s),f(n.filter().ListChannelID,i)||(n.filter().ListChannelID=i),c(i)}),t()(),e(13,"div",5)(14,"label",3),a(15,"From/To"),t(),e(16,"div",6)(17,"datepicker",7),g("dateChange",function(i){return u(s),f(n.filter().From,i)||(n.filter().From=i),c(i)}),t()(),e(18,"div")(19,"datepicker",8),g("dateChange",function(i){return u(s),f(n.filter().To,i)||(n.filter().To=i),c(i)}),t()()(),e(20,"div",5)(21,"label",9),a(22,"Page Number"),t(),e(23,"input",10),g("ngModelChange",function(i){return u(s),f(n.filter().PageNumber,i)||(n.filter().PageNumber=i),c(i)}),t()(),e(24,"div",5)(25,"label",9),a(26,"Page Size"),t(),e(27,"input",11),g("ngModelChange",function(i){return u(s),f(n.filter().PageSize,i)||(n.filter().PageSize=i),c(i)}),t()()(),e(28,"content")(29,"div",12)(30,"div",13)(31,"div",14),F(32,de,20,5,"div",15)(33,me,2,0,"div",16),t()()()()()}if(p&2){let s=A(E(1,8,n.cancelledOrders$));r(2),C("text",n.filter().Number),r(10),h("multiple",!0),C("ngModel",n.filter().ListChannelID),r(5),C("date",n.filter().From),r(2),C("date",n.filter().To),r(4),C("ngModel",n.filter().PageNumber),r(4),C("ngModel",n.filter().PageSize),r(5),N((s==null?null:s.length)>0?32:33)}},dependencies:[J,ee,te,ie,Y,K,X,Q,U,ae,$,Z,le,re,ne,j,G,q],encapsulation:2});let d=m;return d})();export{Pe as CancelledComponent};
1
+ import{a as le}from"./chunk-UMMQ62IZ.js";import{a as M}from"./chunk-SMZOSLIK.js";import{a as ae}from"./chunk-XLQGQESJ.js";import{a as re}from"./chunk-YKKHSYDW.js";import{a as ne}from"./chunk-RWPLFNHT.js";import"./chunk-MT3CWRVG.js";import"./chunk-W33M7S2S.js";import"./chunk-MTVUPPAN.js";import"./chunk-2NRHX6CZ.js";import{a as ie}from"./chunk-5WQ3LCWP.js";import{a as te}from"./chunk-27DIE2YS.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-A6QXXKPR.js";import"./chunk-ZDBFIPDM.js";import"./chunk-DDFP4CNP.js";import"./chunk-RBZU7OVM.js";import{b as ee}from"./chunk-BUMWMFHU.js";import"./chunk-ROS2QMKF.js";import"./chunk-5WT456T7.js";import{a as $}from"./chunk-YNL43MLU.js";import"./chunk-3SCX7IMW.js";import"./chunk-6C4UBIZK.js";import"./chunk-SPLGZRGH.js";import"./chunk-4S4BOPUV.js";import"./chunk-TBVMCNS2.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 Z}from"./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{A as Y,c as K,h as Q,m as U,o as X}from"./chunk-WAXAIL2I.js";import"./chunk-RQUCYFCB.js";import"./chunk-RXLMJGUY.js";import"./chunk-MM7SAZOU.js";import"./chunk-NQLMPUSB.js";import"./chunk-OSGPJXJZ.js";import{A as J,w as j,x as q,z as G}from"./chunk-JNRCB7N3.js";import"./chunk-XBIHN6D3.js";import{Hb as D,Ia as W,Nc as a,Oc as w,Rc as C,Sc as f,Tc as g,Uc as k,Vc as A,Wc as z,Z as P,_c as H,ac as F,cc as N,dc as L,fc as B,gc as I,hc as h,ic as e,id as b,jc as t,jd as E,kc as y,kd as R,ob as r,ra as O,rc as v,wc as x,ya as u,yc as S,za as c}from"./chunk-OHGMB7HJ.js";import"./chunk-WFMAM73Y.js";import{a as T,b as V}from"./chunk-66YHNWRR.js";function oe(d,m){if(d&1&&(e(0,"tr")(1,"td"),a(2),t(),e(3,"td"),y(4,"order-link",26),t(),e(5,"td"),a(6),t(),e(7,"td"),a(8),b(9,"number"),t(),e(10,"td"),a(11),b(12,"date"),t(),e(13,"td"),y(14,"app-channel-logo",27),t()()),d&2){let o=m.$implicit;r(2),w(o.Outlet),r(2),h("order",o),r(2),w(o.Customer),r(2),w(E(9,6,o.Amount)),r(3),w(R(12,8,o.Created,"dd MMM yyyy HH:mm")),r(3),h("typeId",o==null?null:o.TypeID)}}function de(d,m){if(d&1){let o=v();e(0,"div",15)(1,"table",17)(2,"thead",18)(3,"tr",19)(4,"th",20),a(5,"Outlet"),t(),e(6,"th",21),a(7,"Order number"),t(),e(8,"th"),a(9,"Customer"),t(),e(10,"th",22),a(11,"Amount"),t(),e(12,"th",23),a(13," Created On "),t(),e(14,"th",24),a(15,"Channel"),t()()(),e(16,"tbody"),B(17,oe,15,11,"tr",null,L),t()(),e(19,"app-custom-paginator",25),x("next",function(){u(o);let p=S();return c(p.initCancelledOrders())})("previous",function(){u(o);let p=S();return c(p.initCancelledOrders())}),t()()}if(d&2){let o=S(),l=z(0);r(17),I(l),r(2),h("filter",o.filter())("totaldata",l==null?null:l.length)("paginationTotal",l==null?null:l.length)("hasClicked",!0)("nextButtonAlwaysVisible",!0)}}function me(d,m){d&1&&(e(0,"div",16),y(1,"app-empty-state"),t())}var Pe=(()=>{let m=class m{constructor(){this.orderService=O(M),this.filter=W({PageNumber:1,PageSize:20,ListChannelID:[],From:null,To:null,Number:null})}ngOnInit(){this.orderService.getOrderDefaultValue().subscribe({next:l=>{this.initFromDate(l)},error:l=>{console.error("Error fetching default date:",l),this.initFromDate(null)}})}initFromDate(l){this.filter.update(p=>V(T({},p),{From:l})),this.initCancelledOrders()}initCancelledOrders(){this.cancelledOrders$=this.orderService.getCancelledOrders(this.filter()).pipe(P(1))}};m.\u0275fac=function(p){return new(p||m)},m.\u0275cmp=D({type:m,selectors:[["app-cancelled"]],features:[H([M])],decls:34,vars:11,consts:[["headerTitle","Cancelled","searchBoxPlaceHolder","Order Number...",3,"onSubmit","textChange","text"],["href","https://ods.dealpos.app","target","_blank","matTooltip","Monitor your Order & Fulfillment in real-time from TV!",1,"btn","btn-outline-secondary","shadow","rounded","ms-2"],[1,"fa-regular","fa-tv","me-3"],[1,"fw-bold","mb-2"],[3,"ngModelChange","multiple","ngModel"],[1,"mt-5"],[1,"mb-4"],["name","From",3,"dateChange","date"],["name","To",3,"dateChange","date"],[1,"fw-bold"],["type","number","name","PageNumber",1,"w-100","mt-2","form-control",3,"ngModelChange","ngModel"],["type","number","name","PageSize",1,"w-100","mt-2","form-control",3,"ngModelChange","ngModel"],[1,"container-fluid","mt-3"],[1,"row"],[1,"col-md-12"],[1,"table-responsive"],[1,"d-flex","flex-column","justify-content-center","align-items-center",2,"margin-top","26vh"],[1,"table","table-hover"],[1,"sticky-top-thead"],[1,"table-light"],[2,"width","120px"],[2,"width","220px"],[2,"width","100px"],["mat-sort-header","created",2,"width","130px"],[2,"width","130px"],[3,"next","previous","filter","totaldata","paginationTotal","hasClicked","nextButtonAlwaysVisible"],[3,"order"],[3,"typeId"]],template:function(p,n){if(p&1){let s=v();k(0),b(1,"async"),e(2,"mainpanel",0),x("onSubmit",function(){return u(s),c(n.initCancelledOrders())}),g("textChange",function(i){return u(s),f(n.filter().Number,i)||(n.filter().Number=i),c(i)}),e(3,"actions")(4,"a",1),y(5,"i",2),e(6,"span"),a(7,"Order Fulfillment Display"),t()()(),e(8,"filters")(9,"div")(10,"label",3),a(11,"Channel"),t(),e(12,"app-channel-options-v2",4),g("ngModelChange",function(i){return u(s),f(n.filter().ListChannelID,i)||(n.filter().ListChannelID=i),c(i)}),t()(),e(13,"div",5)(14,"label",3),a(15,"From/To"),t(),e(16,"div",6)(17,"datepicker",7),g("dateChange",function(i){return u(s),f(n.filter().From,i)||(n.filter().From=i),c(i)}),t()(),e(18,"div")(19,"datepicker",8),g("dateChange",function(i){return u(s),f(n.filter().To,i)||(n.filter().To=i),c(i)}),t()()(),e(20,"div",5)(21,"label",9),a(22,"Page Number"),t(),e(23,"input",10),g("ngModelChange",function(i){return u(s),f(n.filter().PageNumber,i)||(n.filter().PageNumber=i),c(i)}),t()(),e(24,"div",5)(25,"label",9),a(26,"Page Size"),t(),e(27,"input",11),g("ngModelChange",function(i){return u(s),f(n.filter().PageSize,i)||(n.filter().PageSize=i),c(i)}),t()()(),e(28,"content")(29,"div",12)(30,"div",13)(31,"div",14),F(32,de,20,5,"div",15)(33,me,2,0,"div",16),t()()()()()}if(p&2){let s=A(E(1,8,n.cancelledOrders$));r(2),C("text",n.filter().Number),r(10),h("multiple",!0),C("ngModel",n.filter().ListChannelID),r(5),C("date",n.filter().From),r(2),C("date",n.filter().To),r(4),C("ngModel",n.filter().PageNumber),r(4),C("ngModel",n.filter().PageSize),r(5),N((s==null?null:s.length)>0?32:33)}},dependencies:[J,ee,te,ie,Y,K,X,Q,U,ae,$,Z,le,re,ne,j,G,q],encapsulation:2});let d=m;return d})();export{Pe as CancelledComponent};
@@ -1 +1 @@
1
- import{a as re}from"./chunk-RUYX7KTP.js";import{a as oe}from"./chunk-AHMFSCTX.js";import{a as ie}from"./chunk-XLQGQESJ.js";import"./chunk-6F62N7RZ.js";import"./chunk-LR2YCE6M.js";import{a as $,b as ee,d as te}from"./chunk-C2LAQOUW.js";import{a as ne}from"./chunk-27DIE2YS.js";import"./chunk-A6QXXKPR.js";import{b as Z}from"./chunk-BUMWMFHU.js";import"./chunk-ROS2QMKF.js";import"./chunk-5WT456T7.js";import"./chunk-YNL43MLU.js";import"./chunk-3SCX7IMW.js";import"./chunk-6C4UBIZK.js";import"./chunk-SPLGZRGH.js";import"./chunk-4S4BOPUV.js";import"./chunk-TBVMCNS2.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{c as Y}from"./chunk-O4D64GHO.js";import"./chunk-7R2D2JZ6.js";import{h as H}from"./chunk-QMQCIH3X.js";import"./chunk-YYV4FSYQ.js";import"./chunk-QXRG5XYP.js";import"./chunk-AGBJEXIM.js";import"./chunk-5UFP37GQ.js";import"./chunk-UPRDDI4K.js";import{A as X,c as q,h as j,m as K,o as U,u as J,v as Q}from"./chunk-WAXAIL2I.js";import"./chunk-RQUCYFCB.js";import"./chunk-RXLMJGUY.js";import{e as k}from"./chunk-MM7SAZOU.js";import{b as z,e as G}from"./chunk-NQLMPUSB.js";import"./chunk-OSGPJXJZ.js";import{q as F,x as V}from"./chunk-JNRCB7N3.js";import"./chunk-XBIHN6D3.js";import{$c as L,Hb as x,Mc as I,Nb as N,Nc as l,Oc as S,Pc as b,Rc as g,Sc as c,Tc as u,ac as h,ad as T,cc as C,ec as B,fc as O,gc as R,hc as _,ic as i,id as A,jc as n,kc as w,kd as D,mb as E,ob as a,ra as y,rc as P,wc as v,ya as W,yc as f,za as M}from"./chunk-OHGMB7HJ.js";import"./chunk-WFMAM73Y.js";import"./chunk-66YHNWRR.js";var ae=()=>["/menu/log/order/detail-user"],le=r=>({ID:r}),de=r=>({"bg-warning":r});function se(r,d){if(r&1&&(i(0,"span",22),w(1,"img",23),n(),l(2)),r&2){let o=d.item;a(),_("src",o.Img,E)("alt",o.Name),a(),b(" ",o.Name," ")}}function me(r,d){r&1&&(i(0,"th",26)(1,"span",29),l(2," Response Body Warning "),n()())}function pe(r,d){r&1&&(i(0,"th")(1,"span",29),l(2," Number Override "),n()())}function ge(r,d){if(r&1&&(i(0,"td",26)(1,"span",32),l(2),n()()),r&2){let o=f().$implicit;a(),_("ngClass",T(2,de,o.responseBodyWarning!=null)),a(),S(o.responseBodyWarning)}}function ce(r,d){if(r&1&&(i(0,"td"),l(1),n()),r&2){let o=f().$implicit;a(),b(" ",o.ResponseBodyWarningReference," ")}}function ue(r,d){if(r&1&&(i(0,"tr")(1,"td")(2,"a",30),l(3),A(4,"date"),n()(),i(5,"td"),l(6),n(),i(7,"td"),l(8),n(),i(9,"td"),l(10),n(),i(11,"td",26)(12,"span",31),l(13),n()(),h(14,ge,3,4,"td",26),h(15,ce,2,1,"td"),n()),r&2){let o=d.$implicit,s=f(2);a(2),_("routerLink",L(14,ae))("queryParams",T(15,le,o.ID)),a(),b(" ",D(4,11,o.Created,"dd MMM yyyy HH:mm:ss")," "),a(3),S(o.ChannelName),a(2),S(o.POSActionTypeString),a(2),S(o.Number),a(2),I(o.ResponseCode===200||o.ResponseCode===202?"bg-success":"bg-warning"),a(),b(" ",o.ResponseCode," "),a(),C(s.responseBodyWarningVisible?14:-1),a(),C(s.responseBodyWarningVisible?15:-1)}}function _e(r,d){if(r&1){let o=P();i(0,"div",20)(1,"table",24)(2,"thead")(3,"tr",25)(4,"th"),l(5,"Date"),n(),i(6,"th"),l(7,"Channel"),n(),i(8,"th"),l(9,"Actions"),n(),i(10,"th"),l(11,"Number"),n(),i(12,"th",26)(13,"span",27),l(14," Response Code "),n()(),h(15,me,3,0,"th",26),h(16,pe,3,0,"th"),n()(),i(17,"tbody"),O(18,ue,16,17,"tr",null,B),n()(),i(20,"mat-paginator",28),v("page",function(m){W(o);let e=f();return M(e.changePage(m))}),n()()}if(r&2){let o=f();a(15),C(o.responseBodyWarningVisible?15:-1),a(),C(o.responseBodyWarningVisible?16:-1),a(2),R(o.Result),a(2),_("length",o.paginationTotal)("pageSize",o.paginationPageSize)("pageIndex",(o.filter==null?null:o.filter.PageNumber)==0?0:(o.filter==null?null:o.filter.PageNumber)-1)}}function he(r,d){r&1&&(i(0,"div",21),w(1,"app-empty-state"),n())}var Ie=(()=>{let d=class d{constructor(){this.http=y(k),this._RawLogService=y(re),this.route=y(z),this.authService=y(H),this.Result=Array(),this.filter={RowCount:20,Number:"",PageNumber:1,ActionType:"",ChannelID:"",StatusCode:"",From:"",To:"",responseBodyWarning:""},this.responseBodyWarningVisible=!1,this.channelOptions=this.authService.getChannels()}ngOnInit(){this.route.queryParams.subscribe(s=>{this.responseCode=s.responseCode,this.responseCode!=null?this.Load(s):this.Load()})}Load(s={}){this.http.post("/api/OrdersLoader/Get",s).subscribe(m=>{this.filter=m.Filter,this.ActionTypeList=m.Options.ActionTypeList,this.Get()})}Get(s){this.filter.Number=s,this.http.post("/api/Orders/Get",this.filter).subscribe(m=>{this._RawLogService.Data=m.hits,this.Result=Array();for(let e of m.hits){e._source.log.responseBodyWarning!=null&&(this.responseBodyWarningVisible=!0);let p={ID:e._id,Created:e._source["@timestamp_received"],shopId:e._source.shopId,MarketTypeString:e._source.log.type,ChannelName:e._source?.channelId!=null?this.channelOptions.find(t=>t.ID===e._source?.channelId)?.Name:"",POSActionTypeString:e._source.message,Number:e._source.log.number,ResponseCode:e._source.log.responseCode,responseBodyWarning:e._source.log.responseBodyWarning,ResponseBodyWarningReference:e._source.log.ResponseBodyWarningReference};this.Result.push(p)}this.paginationTotal=m.total.value,this.paginationPageSize=this.filter.RowCount>this.paginationTotal?this.paginationTotal:this.filter.RowCount})}changePage(s){this.filter.PageNumber=s.pageIndex+1,this.Get()}};d.\u0275fac=function(m){return new(m||d)},d.\u0275cmp=x({type:d,selectors:[["app-order"]],decls:42,vars:14,consts:[["headerTitle","Order Log","searchBoxPlaceHolder","Invoice Number..",3,"textChange","onSubmit","text"],[1,"fw-bold","mb-2"],["appendTo","body","bindLabel","Name","name","channelid","bindValue","ID","placeholder","Select Channel",1,"center-text",3,"ngModelChange","clearable","items","ngModel"],["ng-option-tmp","","ng-label-tmp",""],[1,"mt-5"],["bindLabel","Value","name","ActionType","bindValue","Key","placeholder","Action Type",1,"center-text",3,"ngModelChange","clearable","items","ngModel"],[1,"fw-bold","mb-1"],[1,"mb-4"],["name","From",3,"dateChange","date"],["name","To",3,"dateChange","date"],[1,"fw-bold"],["type","text","name","StatusCode",1,"w-100","mt-2","form-control",3,"ngModelChange","ngModel"],["type","text","name","responseBodyWarning","list","listresponseBodyWarning",1,"w-100","mt-2","form-control",3,"ngModelChange","ngModel"],["id","listresponseBodyWarning"],["value","number-override"],["type","number","name","PageNumber",1,"w-100","mt-2","form-control",3,"ngModelChange","ngModel"],["type","number","name","RowCount",1,"w-100","mt-2","form-control",3,"ngModelChange","ngModel"],[1,"container-fluid","mt-3"],[1,"row"],[1,"col-md-12"],[1,"table-responsive"],[1,"d-flex","flex-column","justify-content-center","align-items-center",2,"margin-top","26vh"],[1,"me-2"],[2,"width","18px",3,"src","alt"],[1,"table","table-hover"],[1,"table-light"],[1,"text-center"],["matTooltip","Http Status Code from developer.dealpos.com."],[3,"page","length","pageSize","pageIndex"],["matTooltip","ex: when payload.Number != response.Number value will be number-override"],[3,"routerLink","queryParams"],[1,"text-white","p-2","rounded","response-desc"],[1,"text-white","p-2","rounded","response-desc",3,"ngClass"]],template:function(m,e){m&1&&(i(0,"mainpanel",0),u("textChange",function(t){return c(e.Number,t)||(e.Number=t),t}),v("onSubmit",function(t){return e.Get(t)}),i(1,"filters")(2,"div")(3,"label",1),l(4,"Channel"),n(),i(5,"ng-select",2),u("ngModelChange",function(t){return c(e.filter.ChannelID,t)||(e.filter.ChannelID=t),t}),N(6,se,3,3,"ng-template",3),n()(),i(7,"div",4)(8,"label",1),l(9,"Action"),n(),i(10,"ng-select",5),u("ngModelChange",function(t){return c(e.filter.ActionType,t)||(e.filter.ActionType=t),t}),n()(),i(11,"div",4)(12,"label",6),l(13,"From/To"),n(),i(14,"div",7)(15,"datepicker",8),u("dateChange",function(t){return c(e.filter.From,t)||(e.filter.From=t),t}),n()(),i(16,"div")(17,"datepicker",9),u("dateChange",function(t){return c(e.filter.To,t)||(e.filter.To=t),t}),n()()(),i(18,"div",4)(19,"label",10),l(20,"Response Code"),n(),i(21,"input",11),u("ngModelChange",function(t){return c(e.filter.StatusCode,t)||(e.filter.StatusCode=t),t}),n()(),i(22,"div",4)(23,"label",10),l(24,"Response Body Warning"),n(),i(25,"input",12),u("ngModelChange",function(t){return c(e.filter.responseBodyWarning,t)||(e.filter.responseBodyWarning=t),t}),n(),i(26,"datalist",13),w(27,"option",14),n()(),i(28,"div",4)(29,"label",10),l(30,"Page Number"),n(),i(31,"input",15),u("ngModelChange",function(t){return c(e.filter.PageNumber,t)||(e.filter.PageNumber=t),t}),n()(),i(32,"div",4)(33,"label",10),l(34,"Page Size"),n(),i(35,"input",16),u("ngModelChange",function(t){return c(e.filter.RowCount,t)||(e.filter.RowCount=t),t}),n()()(),i(36,"content")(37,"div",17)(38,"div",18)(39,"div",19),h(40,_e,21,5,"div",20)(41,he,2,0,"div",21),n()()()()()),m&2&&(g("text",e.Number),a(5),_("clearable",!0)("items",e.channelOptions),g("ngModel",e.filter.ChannelID),a(5),_("clearable",!0)("items",e.ActionTypeList),g("ngModel",e.filter.ActionType),a(5),g("date",e.filter.From),a(2),g("date",e.filter.To),a(4),g("ngModel",e.filter.StatusCode),a(4),g("ngModel",e.filter.responseBodyWarning),a(6),g("ngModel",e.filter.PageNumber),a(4),g("ngModel",e.filter.RowCount),a(5),C((e.Result==null?null:e.Result.length)>0?40:41))},dependencies:[Z,te,X,J,Q,q,U,j,K,$,ee,ie,Y,G,F,oe,ne,V],encapsulation:2});let r=d;return r})();export{Ie as OrderComponent};
1
+ import{a as re}from"./chunk-RUYX7KTP.js";import{a as oe}from"./chunk-AHMFSCTX.js";import{a as ie}from"./chunk-XLQGQESJ.js";import"./chunk-6F62N7RZ.js";import"./chunk-LR2YCE6M.js";import{a as $,b as ee,d as te}from"./chunk-C2LAQOUW.js";import{a as ne}from"./chunk-27DIE2YS.js";import"./chunk-A6QXXKPR.js";import{b as Z}from"./chunk-BUMWMFHU.js";import"./chunk-ROS2QMKF.js";import"./chunk-5WT456T7.js";import"./chunk-YNL43MLU.js";import"./chunk-3SCX7IMW.js";import"./chunk-6C4UBIZK.js";import"./chunk-SPLGZRGH.js";import"./chunk-4S4BOPUV.js";import"./chunk-TBVMCNS2.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{c as Y}from"./chunk-O4D64GHO.js";import"./chunk-7R2D2JZ6.js";import{h as H}from"./chunk-O3QPBAV5.js";import"./chunk-YYV4FSYQ.js";import"./chunk-QXRG5XYP.js";import"./chunk-AGBJEXIM.js";import"./chunk-5UFP37GQ.js";import"./chunk-UPRDDI4K.js";import{A as X,c as q,h as j,m as K,o as U,u as J,v as Q}from"./chunk-WAXAIL2I.js";import"./chunk-RQUCYFCB.js";import"./chunk-RXLMJGUY.js";import{e as k}from"./chunk-MM7SAZOU.js";import{b as z,e as G}from"./chunk-NQLMPUSB.js";import"./chunk-OSGPJXJZ.js";import{q as F,x as V}from"./chunk-JNRCB7N3.js";import"./chunk-XBIHN6D3.js";import{$c as L,Hb as x,Mc as I,Nb as N,Nc as l,Oc as S,Pc as b,Rc as g,Sc as c,Tc as u,ac as h,ad as T,cc as C,ec as B,fc as O,gc as R,hc as _,ic as i,id as A,jc as n,kc as w,kd as D,mb as E,ob as a,ra as y,rc as P,wc as v,ya as W,yc as f,za as M}from"./chunk-OHGMB7HJ.js";import"./chunk-WFMAM73Y.js";import"./chunk-66YHNWRR.js";var ae=()=>["/menu/log/order/detail-user"],le=r=>({ID:r}),de=r=>({"bg-warning":r});function se(r,d){if(r&1&&(i(0,"span",22),w(1,"img",23),n(),l(2)),r&2){let o=d.item;a(),_("src",o.Img,E)("alt",o.Name),a(),b(" ",o.Name," ")}}function me(r,d){r&1&&(i(0,"th",26)(1,"span",29),l(2," Response Body Warning "),n()())}function pe(r,d){r&1&&(i(0,"th")(1,"span",29),l(2," Number Override "),n()())}function ge(r,d){if(r&1&&(i(0,"td",26)(1,"span",32),l(2),n()()),r&2){let o=f().$implicit;a(),_("ngClass",T(2,de,o.responseBodyWarning!=null)),a(),S(o.responseBodyWarning)}}function ce(r,d){if(r&1&&(i(0,"td"),l(1),n()),r&2){let o=f().$implicit;a(),b(" ",o.ResponseBodyWarningReference," ")}}function ue(r,d){if(r&1&&(i(0,"tr")(1,"td")(2,"a",30),l(3),A(4,"date"),n()(),i(5,"td"),l(6),n(),i(7,"td"),l(8),n(),i(9,"td"),l(10),n(),i(11,"td",26)(12,"span",31),l(13),n()(),h(14,ge,3,4,"td",26),h(15,ce,2,1,"td"),n()),r&2){let o=d.$implicit,s=f(2);a(2),_("routerLink",L(14,ae))("queryParams",T(15,le,o.ID)),a(),b(" ",D(4,11,o.Created,"dd MMM yyyy HH:mm:ss")," "),a(3),S(o.ChannelName),a(2),S(o.POSActionTypeString),a(2),S(o.Number),a(2),I(o.ResponseCode===200||o.ResponseCode===202?"bg-success":"bg-warning"),a(),b(" ",o.ResponseCode," "),a(),C(s.responseBodyWarningVisible?14:-1),a(),C(s.responseBodyWarningVisible?15:-1)}}function _e(r,d){if(r&1){let o=P();i(0,"div",20)(1,"table",24)(2,"thead")(3,"tr",25)(4,"th"),l(5,"Date"),n(),i(6,"th"),l(7,"Channel"),n(),i(8,"th"),l(9,"Actions"),n(),i(10,"th"),l(11,"Number"),n(),i(12,"th",26)(13,"span",27),l(14," Response Code "),n()(),h(15,me,3,0,"th",26),h(16,pe,3,0,"th"),n()(),i(17,"tbody"),O(18,ue,16,17,"tr",null,B),n()(),i(20,"mat-paginator",28),v("page",function(m){W(o);let e=f();return M(e.changePage(m))}),n()()}if(r&2){let o=f();a(15),C(o.responseBodyWarningVisible?15:-1),a(),C(o.responseBodyWarningVisible?16:-1),a(2),R(o.Result),a(2),_("length",o.paginationTotal)("pageSize",o.paginationPageSize)("pageIndex",(o.filter==null?null:o.filter.PageNumber)==0?0:(o.filter==null?null:o.filter.PageNumber)-1)}}function he(r,d){r&1&&(i(0,"div",21),w(1,"app-empty-state"),n())}var Ie=(()=>{let d=class d{constructor(){this.http=y(k),this._RawLogService=y(re),this.route=y(z),this.authService=y(H),this.Result=Array(),this.filter={RowCount:20,Number:"",PageNumber:1,ActionType:"",ChannelID:"",StatusCode:"",From:"",To:"",responseBodyWarning:""},this.responseBodyWarningVisible=!1,this.channelOptions=this.authService.getChannels()}ngOnInit(){this.route.queryParams.subscribe(s=>{this.responseCode=s.responseCode,this.responseCode!=null?this.Load(s):this.Load()})}Load(s={}){this.http.post("/api/OrdersLoader/Get",s).subscribe(m=>{this.filter=m.Filter,this.ActionTypeList=m.Options.ActionTypeList,this.Get()})}Get(s){this.filter.Number=s,this.http.post("/api/Orders/Get",this.filter).subscribe(m=>{this._RawLogService.Data=m.hits,this.Result=Array();for(let e of m.hits){e._source.log.responseBodyWarning!=null&&(this.responseBodyWarningVisible=!0);let p={ID:e._id,Created:e._source["@timestamp_received"],shopId:e._source.shopId,MarketTypeString:e._source.log.type,ChannelName:e._source?.channelId!=null?this.channelOptions.find(t=>t.ID===e._source?.channelId)?.Name:"",POSActionTypeString:e._source.message,Number:e._source.log.number,ResponseCode:e._source.log.responseCode,responseBodyWarning:e._source.log.responseBodyWarning,ResponseBodyWarningReference:e._source.log.ResponseBodyWarningReference};this.Result.push(p)}this.paginationTotal=m.total.value,this.paginationPageSize=this.filter.RowCount>this.paginationTotal?this.paginationTotal:this.filter.RowCount})}changePage(s){this.filter.PageNumber=s.pageIndex+1,this.Get()}};d.\u0275fac=function(m){return new(m||d)},d.\u0275cmp=x({type:d,selectors:[["app-order"]],decls:42,vars:14,consts:[["headerTitle","Order Log","searchBoxPlaceHolder","Invoice Number..",3,"textChange","onSubmit","text"],[1,"fw-bold","mb-2"],["appendTo","body","bindLabel","Name","name","channelid","bindValue","ID","placeholder","Select Channel",1,"center-text",3,"ngModelChange","clearable","items","ngModel"],["ng-option-tmp","","ng-label-tmp",""],[1,"mt-5"],["bindLabel","Value","name","ActionType","bindValue","Key","placeholder","Action Type",1,"center-text",3,"ngModelChange","clearable","items","ngModel"],[1,"fw-bold","mb-1"],[1,"mb-4"],["name","From",3,"dateChange","date"],["name","To",3,"dateChange","date"],[1,"fw-bold"],["type","text","name","StatusCode",1,"w-100","mt-2","form-control",3,"ngModelChange","ngModel"],["type","text","name","responseBodyWarning","list","listresponseBodyWarning",1,"w-100","mt-2","form-control",3,"ngModelChange","ngModel"],["id","listresponseBodyWarning"],["value","number-override"],["type","number","name","PageNumber",1,"w-100","mt-2","form-control",3,"ngModelChange","ngModel"],["type","number","name","RowCount",1,"w-100","mt-2","form-control",3,"ngModelChange","ngModel"],[1,"container-fluid","mt-3"],[1,"row"],[1,"col-md-12"],[1,"table-responsive"],[1,"d-flex","flex-column","justify-content-center","align-items-center",2,"margin-top","26vh"],[1,"me-2"],[2,"width","18px",3,"src","alt"],[1,"table","table-hover"],[1,"table-light"],[1,"text-center"],["matTooltip","Http Status Code from developer.dealpos.com."],[3,"page","length","pageSize","pageIndex"],["matTooltip","ex: when payload.Number != response.Number value will be number-override"],[3,"routerLink","queryParams"],[1,"text-white","p-2","rounded","response-desc"],[1,"text-white","p-2","rounded","response-desc",3,"ngClass"]],template:function(m,e){m&1&&(i(0,"mainpanel",0),u("textChange",function(t){return c(e.Number,t)||(e.Number=t),t}),v("onSubmit",function(t){return e.Get(t)}),i(1,"filters")(2,"div")(3,"label",1),l(4,"Channel"),n(),i(5,"ng-select",2),u("ngModelChange",function(t){return c(e.filter.ChannelID,t)||(e.filter.ChannelID=t),t}),N(6,se,3,3,"ng-template",3),n()(),i(7,"div",4)(8,"label",1),l(9,"Action"),n(),i(10,"ng-select",5),u("ngModelChange",function(t){return c(e.filter.ActionType,t)||(e.filter.ActionType=t),t}),n()(),i(11,"div",4)(12,"label",6),l(13,"From/To"),n(),i(14,"div",7)(15,"datepicker",8),u("dateChange",function(t){return c(e.filter.From,t)||(e.filter.From=t),t}),n()(),i(16,"div")(17,"datepicker",9),u("dateChange",function(t){return c(e.filter.To,t)||(e.filter.To=t),t}),n()()(),i(18,"div",4)(19,"label",10),l(20,"Response Code"),n(),i(21,"input",11),u("ngModelChange",function(t){return c(e.filter.StatusCode,t)||(e.filter.StatusCode=t),t}),n()(),i(22,"div",4)(23,"label",10),l(24,"Response Body Warning"),n(),i(25,"input",12),u("ngModelChange",function(t){return c(e.filter.responseBodyWarning,t)||(e.filter.responseBodyWarning=t),t}),n(),i(26,"datalist",13),w(27,"option",14),n()(),i(28,"div",4)(29,"label",10),l(30,"Page Number"),n(),i(31,"input",15),u("ngModelChange",function(t){return c(e.filter.PageNumber,t)||(e.filter.PageNumber=t),t}),n()(),i(32,"div",4)(33,"label",10),l(34,"Page Size"),n(),i(35,"input",16),u("ngModelChange",function(t){return c(e.filter.RowCount,t)||(e.filter.RowCount=t),t}),n()()(),i(36,"content")(37,"div",17)(38,"div",18)(39,"div",19),h(40,_e,21,5,"div",20)(41,he,2,0,"div",21),n()()()()()),m&2&&(g("text",e.Number),a(5),_("clearable",!0)("items",e.channelOptions),g("ngModel",e.filter.ChannelID),a(5),_("clearable",!0)("items",e.ActionTypeList),g("ngModel",e.filter.ActionType),a(5),g("date",e.filter.From),a(2),g("date",e.filter.To),a(4),g("ngModel",e.filter.StatusCode),a(4),g("ngModel",e.filter.responseBodyWarning),a(6),g("ngModel",e.filter.PageNumber),a(4),g("ngModel",e.filter.RowCount),a(5),C((e.Result==null?null:e.Result.length)>0?40:41))},dependencies:[Z,te,X,J,Q,q,U,j,K,$,ee,ie,Y,G,F,oe,ne,V],encapsulation:2});let r=d;return r})();export{Ie as OrderComponent};
@@ -1 +1 @@
1
- import{a}from"./chunk-QJ55WDGL.js";import{a as d,b as u}from"./chunk-J6HA4ZHH.js";import"./chunk-YNL43MLU.js";import"./chunk-O4D64GHO.js";import"./chunk-7R2D2JZ6.js";import"./chunk-QMQCIH3X.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,g as s}from"./chunk-NQLMPUSB.js";import"./chunk-OSGPJXJZ.js";import"./chunk-JNRCB7N3.js";import"./chunk-XBIHN6D3.js";import{Hb as r,hc as p,ic as l,jc as m,kc as o,ob as i}from"./chunk-OHGMB7HJ.js";import"./chunk-WFMAM73Y.js";import"./chunk-66YHNWRR.js";var h=(()=>{let t=class t{constructor(){this.priceTabs=[{Title:"Single Channel Comparison",Url:"/menu/price/SingleChannel"},{Title:"Multi Channel Comparison",Url:"/menu/price/pos"}]}};t.\u0275fac=function(n){return new(n||t)},t.\u0275cmp=r({type:t,selectors:[["app-price"]],decls:5,vars:1,consts:[[1,"navbar","page-nav","navbar-default","py-0","navbar-expand-lg"],[1,"container-fluid"],[3,"Tabs"]],template:function(n,f){n&1&&(l(0,"nav",0)(1,"div",1)(2,"div"),o(3,"nav-tab",2),m()()(),o(4,"router-outlet")),n&2&&(i(3),p("Tabs",f.priceTabs))},dependencies:[u,d,s,c],encapsulation:2});let e=t;return e})();var x=[{path:"",component:h,children:[{path:"",redirectTo:"SingleChannel",pathMatch:"full"},{path:"pos",loadComponent(){return import("./chunk-NY2YBW66.js").then(e=>e.PricePosChannelComponent)},canActivate:[a],data:{title:"Global Price Comparison"}},{path:"SingleChannel",loadComponent(){return import("./chunk-J3QDFXZ7.js").then(e=>e.PriceSingleChannelComponent)},canActivate:[a],data:{title:"Price Single Channel Comparison"}}]}];export{x as routes};
1
+ import{a}from"./chunk-KUKTPGJ2.js";import{a as d,b as u}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,g as s}from"./chunk-NQLMPUSB.js";import"./chunk-OSGPJXJZ.js";import"./chunk-JNRCB7N3.js";import"./chunk-XBIHN6D3.js";import{Hb as r,hc as p,ic as l,jc as m,kc as o,ob as i}from"./chunk-OHGMB7HJ.js";import"./chunk-WFMAM73Y.js";import"./chunk-66YHNWRR.js";var h=(()=>{let t=class t{constructor(){this.priceTabs=[{Title:"Single Channel Comparison",Url:"/menu/price/SingleChannel"},{Title:"Multi Channel Comparison",Url:"/menu/price/pos"}]}};t.\u0275fac=function(n){return new(n||t)},t.\u0275cmp=r({type:t,selectors:[["app-price"]],decls:5,vars:1,consts:[[1,"navbar","page-nav","navbar-default","py-0","navbar-expand-lg"],[1,"container-fluid"],[3,"Tabs"]],template:function(n,f){n&1&&(l(0,"nav",0)(1,"div",1)(2,"div"),o(3,"nav-tab",2),m()()(),o(4,"router-outlet")),n&2&&(i(3),p("Tabs",f.priceTabs))},dependencies:[u,d,s,c],encapsulation:2});let e=t;return e})();var x=[{path:"",component:h,children:[{path:"",redirectTo:"SingleChannel",pathMatch:"full"},{path:"pos",loadComponent(){return import("./chunk-ENYJ4KAM.js").then(e=>e.PricePosChannelComponent)},canActivate:[a],data:{title:"Global Price Comparison"}},{path:"SingleChannel",loadComponent(){return import("./chunk-YUPBZXLS.js").then(e=>e.PriceSingleChannelComponent)},canActivate:[a],data:{title:"Price Single Channel Comparison"}}]}];export{x as routes};
@@ -1 +1 @@
1
- import{a as z,b as B}from"./chunk-MT3CWRVG.js";import{b as j}from"./chunk-W33M7S2S.js";import{a as W,b as A,c as U}from"./chunk-NVPT5BF2.js";import{a as P}from"./chunk-A6QXXKPR.js";import{la as N}from"./chunk-RXC5D64C.js";import{h as D}from"./chunk-QMQCIH3X.js";import{A as I,a as F,h as k,m as E}from"./chunk-WAXAIL2I.js";import{Hb as V,Lb as v,Nb as _,Nc as x,Oc as S,Rc as w,Sc as b,Tc as y,_c as O,ac as T,cc as L,hc as p,ic as c,jc as u,kc as g,mb as h,ob as m,ra as M,rc as f,ud as d,wc as C,ya as r,yc as a,za as s}from"./chunk-OHGMB7HJ.js";function G(n,o){if(n&1&&(c(0,"div",6),g(1,"img",7),c(2,"div"),x(3),u()()),n&2){let e=o.$implicit;m(),p("src",e.logo,h),m(2),S(e.Name)}}function R(n,o){if(n&1){let e=f();c(0,"p-multiselect",4,0),C("click",function(){r(e);let i=a();return s(i.onClickSelect())}),y("ngModelChange",function(i){r(e);let l=a();return b(l.selectedChannels,i)||(l.selectedChannels=i),s(i)}),C("ngModelChange",function(i){r(e);let l=a();return s(l.onChannelChange(i))}),_(2,G,4,2,"ng-template",5),u()}if(n&2){let e=a();p("options",e.options())("placeholder",e.placeholder()),w("ngModel",e.selectedChannels),p("showClear",e.clearable())("autofocusFilter",!0)("maxSelectedLabels",e.maxSelectedLabels())}}function q(n,o){if(n&1&&(c(0,"div",6),g(1,"img",7),c(2,"div"),x(3),u()()),n&2){let e=o.$implicit;m(),p("src",e.logo,h),m(2),S(e.Name)}}function H(n,o){if(n&1){let e=f();c(0,"p-select",8,1),C("click",function(){r(e);let i=a();return s(i.onClickSelect())}),y("ngModelChange",function(i){r(e);let l=a();return b(l.selectedChannels,i)||(l.selectedChannels=i),s(i)}),C("ngModelChange",function(i){r(e);let l=a();return s(l.onChannelChange(i))}),_(2,q,4,2,"ng-template",5),u()}if(n&2){let e=a();p("options",e.options())("placeholder",e.placeholder()),w("ngModel",e.selectedChannels),p("showClear",e.clearable())("autofocusFilter",!0)("filter",!0)}}var re=(()=>{let o=class o extends U{constructor(){super(),this.authService=M(D),this.multiple=d(!1),this.clearable=d(!0),this.placeholder=d("Select Channels"),this.options=d(this.authService.getChannels()),this.maxSelectedLabels=d(6),this.onChange=t=>{}}onChannelChange(t){this.multiple()?t=t||[]:t=t||P.GuidEmpty,this.onChange(t)}onClickSelect(){this.initTopPosition(),setTimeout(()=>{this.adjustOverlayPosition()},0)}writeValue(t){this.selectedChannels=t}registerOnChange(t){this.onChange=t}registerOnTouched(t){}setDisabledState(t){}};o.\u0275fac=function(i){return new(i||o)},o.\u0275cmp=V({type:o,selectors:[["app-channel-options-v2"]],inputs:{multiple:[1,"multiple"],clearable:[1,"clearable"],placeholder:[1,"placeholder"],options:[1,"options"],maxSelectedLabels:[1,"maxSelectedLabels"]},features:[O([{provide:F,multi:!0,useExisting:o}]),v],decls:2,vars:1,consts:[["multiSelect",""],["select",""],["optionLabel","Name","optionValue","ID","display","chip","id","multiSelect","appendTo","body",1,"w-100",2,"--p-multiselect-padding-y","12px",3,"options","placeholder","ngModel","showClear","autofocusFilter","maxSelectedLabels"],["optionLabel","Name","optionValue","ID","appendTo","body",1,"w-100",2,"--p-select-padding-y","12px",3,"options","placeholder","ngModel","showClear","autofocusFilter","filter"],["optionLabel","Name","optionValue","ID","display","chip","id","multiSelect","appendTo","body",1,"w-100",2,"--p-multiselect-padding-y","12px",3,"click","ngModelChange","options","placeholder","ngModel","showClear","autofocusFilter","maxSelectedLabels"],["pTemplate","item"],[1,"d-flex","align-items-center","gap-2"],[2,"width","18px",3,"src"],["optionLabel","Name","optionValue","ID","appendTo","body",1,"w-100",2,"--p-select-padding-y","12px",3,"click","ngModelChange","options","placeholder","ngModel","showClear","autofocusFilter","filter"]],template:function(i,l){i&1&&T(0,R,3,6,"p-multiselect",2)(1,H,3,6,"p-select",3),i&2&&L(l.multiple()?0:1)},dependencies:[B,z,N,j,I,k,E,A,W],encapsulation:2});let n=o;return n})();export{re as a};
1
+ import{a as z,b as B}from"./chunk-MT3CWRVG.js";import{b as j}from"./chunk-W33M7S2S.js";import{a as W,b as A,c as U}from"./chunk-NVPT5BF2.js";import{a as P}from"./chunk-A6QXXKPR.js";import{la as N}from"./chunk-RXC5D64C.js";import{h as D}from"./chunk-O3QPBAV5.js";import{A as I,a as F,h as k,m as E}from"./chunk-WAXAIL2I.js";import{Hb as V,Lb as v,Nb as _,Nc as x,Oc as S,Rc as w,Sc as b,Tc as y,_c as O,ac as T,cc as L,hc as p,ic as c,jc as u,kc as g,mb as h,ob as m,ra as M,rc as f,ud as d,wc as C,ya as r,yc as a,za as s}from"./chunk-OHGMB7HJ.js";function G(n,o){if(n&1&&(c(0,"div",6),g(1,"img",7),c(2,"div"),x(3),u()()),n&2){let e=o.$implicit;m(),p("src",e.logo,h),m(2),S(e.Name)}}function R(n,o){if(n&1){let e=f();c(0,"p-multiselect",4,0),C("click",function(){r(e);let i=a();return s(i.onClickSelect())}),y("ngModelChange",function(i){r(e);let l=a();return b(l.selectedChannels,i)||(l.selectedChannels=i),s(i)}),C("ngModelChange",function(i){r(e);let l=a();return s(l.onChannelChange(i))}),_(2,G,4,2,"ng-template",5),u()}if(n&2){let e=a();p("options",e.options())("placeholder",e.placeholder()),w("ngModel",e.selectedChannels),p("showClear",e.clearable())("autofocusFilter",!0)("maxSelectedLabels",e.maxSelectedLabels())}}function q(n,o){if(n&1&&(c(0,"div",6),g(1,"img",7),c(2,"div"),x(3),u()()),n&2){let e=o.$implicit;m(),p("src",e.logo,h),m(2),S(e.Name)}}function H(n,o){if(n&1){let e=f();c(0,"p-select",8,1),C("click",function(){r(e);let i=a();return s(i.onClickSelect())}),y("ngModelChange",function(i){r(e);let l=a();return b(l.selectedChannels,i)||(l.selectedChannels=i),s(i)}),C("ngModelChange",function(i){r(e);let l=a();return s(l.onChannelChange(i))}),_(2,q,4,2,"ng-template",5),u()}if(n&2){let e=a();p("options",e.options())("placeholder",e.placeholder()),w("ngModel",e.selectedChannels),p("showClear",e.clearable())("autofocusFilter",!0)("filter",!0)}}var re=(()=>{let o=class o extends U{constructor(){super(),this.authService=M(D),this.multiple=d(!1),this.clearable=d(!0),this.placeholder=d("Select Channels"),this.options=d(this.authService.getChannels()),this.maxSelectedLabels=d(6),this.onChange=t=>{}}onChannelChange(t){this.multiple()?t=t||[]:t=t||P.GuidEmpty,this.onChange(t)}onClickSelect(){this.initTopPosition(),setTimeout(()=>{this.adjustOverlayPosition()},0)}writeValue(t){this.selectedChannels=t}registerOnChange(t){this.onChange=t}registerOnTouched(t){}setDisabledState(t){}};o.\u0275fac=function(i){return new(i||o)},o.\u0275cmp=V({type:o,selectors:[["app-channel-options-v2"]],inputs:{multiple:[1,"multiple"],clearable:[1,"clearable"],placeholder:[1,"placeholder"],options:[1,"options"],maxSelectedLabels:[1,"maxSelectedLabels"]},features:[O([{provide:F,multi:!0,useExisting:o}]),v],decls:2,vars:1,consts:[["multiSelect",""],["select",""],["optionLabel","Name","optionValue","ID","display","chip","id","multiSelect","appendTo","body",1,"w-100",2,"--p-multiselect-padding-y","12px",3,"options","placeholder","ngModel","showClear","autofocusFilter","maxSelectedLabels"],["optionLabel","Name","optionValue","ID","appendTo","body",1,"w-100",2,"--p-select-padding-y","12px",3,"options","placeholder","ngModel","showClear","autofocusFilter","filter"],["optionLabel","Name","optionValue","ID","display","chip","id","multiSelect","appendTo","body",1,"w-100",2,"--p-multiselect-padding-y","12px",3,"click","ngModelChange","options","placeholder","ngModel","showClear","autofocusFilter","maxSelectedLabels"],["pTemplate","item"],[1,"d-flex","align-items-center","gap-2"],[2,"width","18px",3,"src"],["optionLabel","Name","optionValue","ID","appendTo","body",1,"w-100",2,"--p-select-padding-y","12px",3,"click","ngModelChange","options","placeholder","ngModel","showClear","autofocusFilter","filter"]],template:function(i,l){i&1&&T(0,R,3,6,"p-multiselect",2)(1,H,3,6,"p-select",3),i&2&&L(l.multiple()?0:1)},dependencies:[B,z,N,j,I,k,E,A,W],encapsulation:2});let n=o;return n})();export{re as a};
@@ -1 +1 @@
1
- import{a as me,b as de}from"./chunk-K5WSFDNA.js";import{a as se}from"./chunk-NRSDIDOP.js";import{a as T}from"./chunk-SMZOSLIK.js";import{a as pe}from"./chunk-XLQGQESJ.js";import{a as ae}from"./chunk-UE2QO2Y4.js";import"./chunk-MT3CWRVG.js";import"./chunk-W33M7S2S.js";import"./chunk-MTVUPPAN.js";import"./chunk-2NRHX6CZ.js";import{a as le}from"./chunk-5WQ3LCWP.js";import"./chunk-DLHIDOS3.js";import{a as oe}from"./chunk-27DIE2YS.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-A6QXXKPR.js";import"./chunk-ZDBFIPDM.js";import"./chunk-DDFP4CNP.js";import"./chunk-RBZU7OVM.js";import{b as re}from"./chunk-BUMWMFHU.js";import"./chunk-ROS2QMKF.js";import"./chunk-5WT456T7.js";import{a as ne}from"./chunk-YNL43MLU.js";import"./chunk-3SCX7IMW.js";import"./chunk-6C4UBIZK.js";import"./chunk-SPLGZRGH.js";import"./chunk-4S4BOPUV.js";import"./chunk-TBVMCNS2.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 ie}from"./chunk-O4D64GHO.js";import"./chunk-7R2D2JZ6.js";import"./chunk-QMQCIH3X.js";import"./chunk-YYV4FSYQ.js";import"./chunk-QXRG5XYP.js";import"./chunk-AGBJEXIM.js";import"./chunk-5UFP37GQ.js";import"./chunk-UPRDDI4K.js";import{A as te,c as Y,h as Z,m as $,o as ee}from"./chunk-WAXAIL2I.js";import"./chunk-RQUCYFCB.js";import"./chunk-RXLMJGUY.js";import"./chunk-MM7SAZOU.js";import"./chunk-NQLMPUSB.js";import"./chunk-OSGPJXJZ.js";import{A as X,w as K,x as Q,z as U}from"./chunk-JNRCB7N3.js";import"./chunk-XBIHN6D3.js";import{$c as q,Hb as W,Ia as O,Mc as k,Nc as a,Oc as M,Pc as w,Rc as g,Sc as C,Tc as h,Uc as z,Vc as R,Wc as H,Z as F,_c as j,ac as y,ad as G,cc as b,dc as D,fc as I,gc as B,hc as v,ic as t,id as x,jc as i,jd as A,kc as _,kd as J,ob as l,ra as N,rc as V,wc as E,ya as c,yc as f,za as u}from"./chunk-OHGMB7HJ.js";import"./chunk-WFMAM73Y.js";import{a as P,b as L}from"./chunk-66YHNWRR.js";var ce=()=>[],ue=r=>({"td-cell-hover":r});function _e(r,m){if(r&1&&_(0,"variants-dropdown",26),r&2){let e=f().$implicit;v("variants",e==null?null:e.Variants)}}function fe(r,m){if(r&1&&_(0,"variant-with-image",27),r&2){let e=f().$implicit;v("variant",e==null?null:e.Variants[0])}}function ge(r,m){if(r&1&&(t(0,"span"),a(1),i()),r&2){let e=f().$implicit;l(),w("(",e.LogisticService==null?null:e.LogisticService.Option,")")}}function Ce(r,m){if(r&1&&(t(0,"tr")(1,"td")(2,"div",23)(3,"div"),_(4,"order-link",24),i(),t(5,"small"),a(6),x(7,"date"),i(),_(8,"br"),t(9,"small"),_(10,"i",25),a(11),i()()(),t(12,"td"),y(13,_e,1,1,"variants-dropdown",26)(14,fe,1,1,"variant-with-image",27),i(),t(15,"td"),a(16),x(17,"number"),i(),t(18,"td")(19,"div",23)(20,"div",28)(21,"span"),a(22),i(),y(23,ge,2,1,"span"),i(),t(24,"small"),a(25),i()()()()),r&2){let e=m.$implicit;l(4),v("order",e),l(2),w(" ",J(7,10,e==null?null:e.Created,"dd/MM/yyyy HH:mm:ss")," "),l(5),w(" ",e.Customer," "),l(),k(G(15,ue,(e.Variants==null?null:e.Variants.length)>1)),l(),b((e.Variants==null?null:e.Variants.length)>1?13:14),l(3),M(A(17,13,e.Amount)),l(6),M(e.LogisticService!=null&&e.LogisticService.Name?e.LogisticService==null?null:e.LogisticService.Name:"-"),l(),b(e.LogisticService!=null&&e.LogisticService.Option&&(e.LogisticService==null?null:e.LogisticService.Option)!="Default"?23:-1),l(2),w(" ",e.ReferenceNumber?e.ReferenceNumber:"-"," ")}}function he(r,m){if(r&1){let e=V();t(0,"div",15)(1,"table",17)(2,"thead",18)(3,"tr",19)(4,"th",20),a(5,"Number"),i(),t(6,"th"),a(7,"Items"),i(),t(8,"th",21),a(9,"Amount"),i(),t(10,"th",21),a(11,"Shipping"),i()()(),t(12,"tbody"),I(13,Ce,26,17,"tr",null,D),i()(),t(15,"app-custom-paginator",22),E("next",function(){c(e);let p=f();return u(p.initAllOrders())})("previous",function(){c(e);let p=f();return u(p.initAllOrders())}),i()()}if(r&2){let e=f(),d=H(0);l(13),B(d),l(2),v("filter",e.filter())("totaldata",d==null?null:d.length)}}function Se(r,m){r&1&&(t(0,"div",16),_(1,"app-empty-state"),i())}var ze=(()=>{let m=class m{constructor(){this.orderService=N(T),this.filter=O({PageNumber:1,PageSize:20,ListChannelID:[],From:null,To:null,Number:null})}ngOnInit(){this.orderService.getOrderDefaultValue().subscribe({next:d=>{this.initFromDate(d)},error:d=>{console.error("Error fetching default date:",d),this.initFromDate(null)}})}initFromDate(d){this.filter.update(p=>L(P({},p),{From:d})),this.initAllOrders()}initAllOrders(){this.allOrders$=this.orderService.getAllOrders(this.filter()).pipe(F(1))}};m.\u0275fac=function(p){return new(p||m)},m.\u0275cmp=W({type:m,selectors:[["app-all"]],features:[j([T])],decls:34,vars:12,consts:[["headerTitle","Completed","searchBoxPlaceHolder","Order Number...",3,"onSubmit","textChange","text"],["href","https://ods.dealpos.app","target","_blank","matTooltip","Monitor your Order & Fulfillment in real-time from TV!",1,"btn","btn-outline-secondary","shadow","rounded","ms-2"],[1,"fa-solid","fa-clipboard-list","me-3"],[1,"fw-bold","mb-2"],[3,"ngModelChange","multiple","ngModel"],[1,"mt-5"],[1,"mb-4"],["name","From",3,"dateChange","date"],["name","To",3,"dateChange","date"],[1,"fw-bold"],["type","number","name","PageNumber",1,"w-100","mt-2","form-control",3,"ngModelChange","ngModel"],["type","number","name","PageSize",1,"w-100","mt-2","form-control",3,"ngModelChange","ngModel"],[1,"container-fluid","mt-3"],[1,"row"],[1,"col-md-12"],[1,"table-responsive"],[1,"d-flex","flex-column","justify-content-center","align-items-center",2,"margin-top","26vh"],[1,"table"],[1,"sticky-top-thead"],[1,"table-light"],[2,"width","250px"],[2,"width","150px"],["rowCountApi","/api/orders/allcount",3,"next","previous","filter","totaldata"],[1,"lh-sm"],[2,"font-size","14px",3,"order"],[1,"fa-solid","fa-user"],[3,"variants"],[3,"variant"],[1,"d-flex","align-items-end","gap-2"]],template:function(p,o){if(p&1){let s=V();z(0),x(1,"async"),t(2,"mainpanel",0),E("onSubmit",function(){return c(s),u(o.initAllOrders())}),h("textChange",function(n){return c(s),C(o.filter().Number,n)||(o.filter().Number=n),u(n)}),t(3,"actions")(4,"a",1),_(5,"i",2),t(6,"span"),a(7,"Order Fulfillment Display"),i()()(),t(8,"filters")(9,"div")(10,"label",3),a(11,"Channel"),i(),t(12,"app-channel-options-v2",4),h("ngModelChange",function(n){return c(s),C(o.filter().ListChannelID,n)||(o.filter().ListChannelID=n),u(n)}),i()(),t(13,"div",5)(14,"label",3),a(15,"From/To"),i(),t(16,"div",6)(17,"datepicker",7),h("dateChange",function(n){return c(s),C(o.filter().From,n)||(o.filter().From=n),u(n)}),i()(),t(18,"div")(19,"datepicker",8),h("dateChange",function(n){return c(s),C(o.filter().To,n)||(o.filter().To=n),u(n)}),i()()(),t(20,"div",5)(21,"label",9),a(22,"Page Number"),i(),t(23,"input",10),h("ngModelChange",function(n){return c(s),C(o.filter().PageNumber,n)||(o.filter().PageNumber=n),u(n)}),i()(),t(24,"div",5)(25,"label",9),a(26,"Page Size"),i(),t(27,"input",11),h("ngModelChange",function(n){return c(s),C(o.filter().PageSize,n)||(o.filter().PageSize=n),u(n)}),i()()(),t(28,"content")(29,"div",12)(30,"div",13)(31,"div",14),y(32,he,16,2,"div",15)(33,Se,2,0,"div",16),i()()()()()}if(p&2){let s=R(A(1,8,o.allOrders$)||q(11,ce));l(2),g("text",o.filter().Number),l(10),v("multiple",!0),g("ngModel",o.filter().ListChannelID),l(5),g("date",o.filter().From),l(2),g("date",o.filter().To),l(4),g("ngModel",o.filter().PageNumber),l(4),g("ngModel",o.filter().PageSize),l(5),b((s==null?null:s.length)>0?32:33)}},dependencies:[X,re,oe,le,te,Y,ee,Z,$,me,de,pe,ne,ie,se,ae,K,U,Q],encapsulation:2});let r=m;return r})();export{ze as AllComponent};
1
+ import{a as me,b as de}from"./chunk-K5WSFDNA.js";import{a as se}from"./chunk-UMMQ62IZ.js";import{a as T}from"./chunk-SMZOSLIK.js";import{a as pe}from"./chunk-XLQGQESJ.js";import{a as ae}from"./chunk-RWPLFNHT.js";import"./chunk-MT3CWRVG.js";import"./chunk-W33M7S2S.js";import"./chunk-MTVUPPAN.js";import"./chunk-2NRHX6CZ.js";import{a as le}from"./chunk-5WQ3LCWP.js";import"./chunk-DLHIDOS3.js";import{a as oe}from"./chunk-27DIE2YS.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-A6QXXKPR.js";import"./chunk-ZDBFIPDM.js";import"./chunk-DDFP4CNP.js";import"./chunk-RBZU7OVM.js";import{b as re}from"./chunk-BUMWMFHU.js";import"./chunk-ROS2QMKF.js";import"./chunk-5WT456T7.js";import{a as ne}from"./chunk-YNL43MLU.js";import"./chunk-3SCX7IMW.js";import"./chunk-6C4UBIZK.js";import"./chunk-SPLGZRGH.js";import"./chunk-4S4BOPUV.js";import"./chunk-TBVMCNS2.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 ie}from"./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{A as te,c as Y,h as Z,m as $,o as ee}from"./chunk-WAXAIL2I.js";import"./chunk-RQUCYFCB.js";import"./chunk-RXLMJGUY.js";import"./chunk-MM7SAZOU.js";import"./chunk-NQLMPUSB.js";import"./chunk-OSGPJXJZ.js";import{A as X,w as K,x as Q,z as U}from"./chunk-JNRCB7N3.js";import"./chunk-XBIHN6D3.js";import{$c as q,Hb as W,Ia as O,Mc as k,Nc as a,Oc as M,Pc as w,Rc as g,Sc as C,Tc as h,Uc as z,Vc as R,Wc as H,Z as F,_c as j,ac as y,ad as G,cc as b,dc as D,fc as I,gc as B,hc as v,ic as t,id as x,jc as i,jd as A,kc as _,kd as J,ob as l,ra as N,rc as V,wc as E,ya as c,yc as f,za as u}from"./chunk-OHGMB7HJ.js";import"./chunk-WFMAM73Y.js";import{a as P,b as L}from"./chunk-66YHNWRR.js";var ce=()=>[],ue=r=>({"td-cell-hover":r});function _e(r,m){if(r&1&&_(0,"variants-dropdown",26),r&2){let e=f().$implicit;v("variants",e==null?null:e.Variants)}}function fe(r,m){if(r&1&&_(0,"variant-with-image",27),r&2){let e=f().$implicit;v("variant",e==null?null:e.Variants[0])}}function ge(r,m){if(r&1&&(t(0,"span"),a(1),i()),r&2){let e=f().$implicit;l(),w("(",e.LogisticService==null?null:e.LogisticService.Option,")")}}function Ce(r,m){if(r&1&&(t(0,"tr")(1,"td")(2,"div",23)(3,"div"),_(4,"order-link",24),i(),t(5,"small"),a(6),x(7,"date"),i(),_(8,"br"),t(9,"small"),_(10,"i",25),a(11),i()()(),t(12,"td"),y(13,_e,1,1,"variants-dropdown",26)(14,fe,1,1,"variant-with-image",27),i(),t(15,"td"),a(16),x(17,"number"),i(),t(18,"td")(19,"div",23)(20,"div",28)(21,"span"),a(22),i(),y(23,ge,2,1,"span"),i(),t(24,"small"),a(25),i()()()()),r&2){let e=m.$implicit;l(4),v("order",e),l(2),w(" ",J(7,10,e==null?null:e.Created,"dd/MM/yyyy HH:mm:ss")," "),l(5),w(" ",e.Customer," "),l(),k(G(15,ue,(e.Variants==null?null:e.Variants.length)>1)),l(),b((e.Variants==null?null:e.Variants.length)>1?13:14),l(3),M(A(17,13,e.Amount)),l(6),M(e.LogisticService!=null&&e.LogisticService.Name?e.LogisticService==null?null:e.LogisticService.Name:"-"),l(),b(e.LogisticService!=null&&e.LogisticService.Option&&(e.LogisticService==null?null:e.LogisticService.Option)!="Default"?23:-1),l(2),w(" ",e.ReferenceNumber?e.ReferenceNumber:"-"," ")}}function he(r,m){if(r&1){let e=V();t(0,"div",15)(1,"table",17)(2,"thead",18)(3,"tr",19)(4,"th",20),a(5,"Number"),i(),t(6,"th"),a(7,"Items"),i(),t(8,"th",21),a(9,"Amount"),i(),t(10,"th",21),a(11,"Shipping"),i()()(),t(12,"tbody"),I(13,Ce,26,17,"tr",null,D),i()(),t(15,"app-custom-paginator",22),E("next",function(){c(e);let p=f();return u(p.initAllOrders())})("previous",function(){c(e);let p=f();return u(p.initAllOrders())}),i()()}if(r&2){let e=f(),d=H(0);l(13),B(d),l(2),v("filter",e.filter())("totaldata",d==null?null:d.length)}}function Se(r,m){r&1&&(t(0,"div",16),_(1,"app-empty-state"),i())}var ze=(()=>{let m=class m{constructor(){this.orderService=N(T),this.filter=O({PageNumber:1,PageSize:20,ListChannelID:[],From:null,To:null,Number:null})}ngOnInit(){this.orderService.getOrderDefaultValue().subscribe({next:d=>{this.initFromDate(d)},error:d=>{console.error("Error fetching default date:",d),this.initFromDate(null)}})}initFromDate(d){this.filter.update(p=>L(P({},p),{From:d})),this.initAllOrders()}initAllOrders(){this.allOrders$=this.orderService.getAllOrders(this.filter()).pipe(F(1))}};m.\u0275fac=function(p){return new(p||m)},m.\u0275cmp=W({type:m,selectors:[["app-all"]],features:[j([T])],decls:34,vars:12,consts:[["headerTitle","Completed","searchBoxPlaceHolder","Order Number...",3,"onSubmit","textChange","text"],["href","https://ods.dealpos.app","target","_blank","matTooltip","Monitor your Order & Fulfillment in real-time from TV!",1,"btn","btn-outline-secondary","shadow","rounded","ms-2"],[1,"fa-solid","fa-clipboard-list","me-3"],[1,"fw-bold","mb-2"],[3,"ngModelChange","multiple","ngModel"],[1,"mt-5"],[1,"mb-4"],["name","From",3,"dateChange","date"],["name","To",3,"dateChange","date"],[1,"fw-bold"],["type","number","name","PageNumber",1,"w-100","mt-2","form-control",3,"ngModelChange","ngModel"],["type","number","name","PageSize",1,"w-100","mt-2","form-control",3,"ngModelChange","ngModel"],[1,"container-fluid","mt-3"],[1,"row"],[1,"col-md-12"],[1,"table-responsive"],[1,"d-flex","flex-column","justify-content-center","align-items-center",2,"margin-top","26vh"],[1,"table"],[1,"sticky-top-thead"],[1,"table-light"],[2,"width","250px"],[2,"width","150px"],["rowCountApi","/api/orders/allcount",3,"next","previous","filter","totaldata"],[1,"lh-sm"],[2,"font-size","14px",3,"order"],[1,"fa-solid","fa-user"],[3,"variants"],[3,"variant"],[1,"d-flex","align-items-end","gap-2"]],template:function(p,o){if(p&1){let s=V();z(0),x(1,"async"),t(2,"mainpanel",0),E("onSubmit",function(){return c(s),u(o.initAllOrders())}),h("textChange",function(n){return c(s),C(o.filter().Number,n)||(o.filter().Number=n),u(n)}),t(3,"actions")(4,"a",1),_(5,"i",2),t(6,"span"),a(7,"Order Fulfillment Display"),i()()(),t(8,"filters")(9,"div")(10,"label",3),a(11,"Channel"),i(),t(12,"app-channel-options-v2",4),h("ngModelChange",function(n){return c(s),C(o.filter().ListChannelID,n)||(o.filter().ListChannelID=n),u(n)}),i()(),t(13,"div",5)(14,"label",3),a(15,"From/To"),i(),t(16,"div",6)(17,"datepicker",7),h("dateChange",function(n){return c(s),C(o.filter().From,n)||(o.filter().From=n),u(n)}),i()(),t(18,"div")(19,"datepicker",8),h("dateChange",function(n){return c(s),C(o.filter().To,n)||(o.filter().To=n),u(n)}),i()()(),t(20,"div",5)(21,"label",9),a(22,"Page Number"),i(),t(23,"input",10),h("ngModelChange",function(n){return c(s),C(o.filter().PageNumber,n)||(o.filter().PageNumber=n),u(n)}),i()(),t(24,"div",5)(25,"label",9),a(26,"Page Size"),i(),t(27,"input",11),h("ngModelChange",function(n){return c(s),C(o.filter().PageSize,n)||(o.filter().PageSize=n),u(n)}),i()()(),t(28,"content")(29,"div",12)(30,"div",13)(31,"div",14),y(32,he,16,2,"div",15)(33,Se,2,0,"div",16),i()()()()()}if(p&2){let s=R(A(1,8,o.allOrders$)||q(11,ce));l(2),g("text",o.filter().Number),l(10),v("multiple",!0),g("ngModel",o.filter().ListChannelID),l(5),g("date",o.filter().From),l(2),g("date",o.filter().To),l(4),g("ngModel",o.filter().PageNumber),l(4),g("ngModel",o.filter().PageSize),l(5),b((s==null?null:s.length)>0?32:33)}},dependencies:[X,re,oe,le,te,Y,ee,Z,$,me,de,pe,ne,ie,se,ae,K,U,Q],encapsulation:2});let r=m;return r})();export{ze as AllComponent};
@@ -1 +1 @@
1
- import{a as b,b as ct}from"./chunk-G4T4VM5E.js";import"./chunk-BKR7YPEW.js";import{a as lt}from"./chunk-UE2QO2Y4.js";import"./chunk-MT3CWRVG.js";import"./chunk-W33M7S2S.js";import"./chunk-MTVUPPAN.js";import"./chunk-2NRHX6CZ.js";import{a as rt}from"./chunk-5WQ3LCWP.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-A6QXXKPR.js";import"./chunk-ZDBFIPDM.js";import"./chunk-DDFP4CNP.js";import"./chunk-RBZU7OVM.js";import{b as at}from"./chunk-BUMWMFHU.js";import"./chunk-ROS2QMKF.js";import"./chunk-5WT456T7.js";import"./chunk-YNL43MLU.js";import"./chunk-RXC5D64C.js";import"./chunk-O4D64GHO.js";import"./chunk-7R2D2JZ6.js";import"./chunk-QMQCIH3X.js";import"./chunk-YYV4FSYQ.js";import"./chunk-QXRG5XYP.js";import"./chunk-AGBJEXIM.js";import"./chunk-5UFP37GQ.js";import"./chunk-UPRDDI4K.js";import{A as ot,h as it,m as nt}from"./chunk-WAXAIL2I.js";import"./chunk-RQUCYFCB.js";import"./chunk-RXLMJGUY.js";import"./chunk-MM7SAZOU.js";import{e as tt,g as et}from"./chunk-NQLMPUSB.js";import"./chunk-OSGPJXJZ.js";import{A as Z,q as Y,w as G,x as Q,z as X}from"./chunk-JNRCB7N3.js";import"./chunk-XBIHN6D3.js";import{$c as j,Hb as M,Ia as w,Mc as $,Nc as n,Oc as x,Pc as C,Qc as O,Rc as H,Sc as J,Tc as W,Uc as q,Z as P,_c as A,ac as f,ad as z,bd as K,cc as _,cd as U,dc as L,ec as k,fc as I,gc as N,hc as m,ic as e,id as v,jc as i,jd as D,kc as B,kd as V,mb as T,ob as l,ra as F,rc as R,v as E,wc as y,ya as p,yc as S,za as u}from"./chunk-OHGMB7HJ.js";import"./chunk-WFMAM73Y.js";import"./chunk-66YHNWRR.js";var st=(t,o)=>({"bg-gradient-danger":t,"bg-gradient-warning":o}),dt=()=>["/menu/products/status/notificationV2/detailV2"],mt=t=>({ID:t}),pt=(t,o,a)=>({"text-warning":t,"text-success":o,"text-danger":a});function ut(t,o){t&1&&(e(0,"div"),n(1," Scan in progress. You will be notified once it is complete. "),i())}function ft(t,o){if(t&1&&(e(0,"div"),n(1),v(2,"number"),i()),t&2){let a=o.$implicit;l(),O(" ",a.Key,": ",D(2,2,a.Value)," ")}}function _t(t,o){if(t&1&&(e(0,"div",19)(1,"div",18),n(2,"Status Product:"),i(),I(3,ft,3,4,"div",null,L),i()),t&2){let a=S(2).$implicit;l(3),N(a.ParsedStatus)}}function St(t,o){if(t&1&&(e(0,"div",18),n(1),i(),e(2,"div"),n(3),i(),f(4,_t,5,0,"div",19)),t&2){let a=S().$implicit;l(),C(" ",a.ProcessLabel," "),l(2),x(a.ProcessDescription),l(),_(a!=null&&a.ParsedStatus&&(a==null||a.ParsedStatus==null?null:a.ParsedStatus.length)>0?4:-1)}}function Ct(t,o){if(t&1&&(n(0),v(1,"number"),e(2,"span"),n(3,"s"),i()),t&2){let a=S().$implicit;C(" ",V(1,1,a.DurationInSecond,"1.1-1")," ")}}function vt(t,o){t&1&&n(0," - ")}function xt(t,o){t&1&&n(0," In Progress ")}function gt(t,o){t&1&&n(0," Completed ")}function ht(t,o){t&1&&n(0," Failed ")}function It(t,o){if(t&1&&(e(0,"tr",12)(1,"td")(2,"a",15),n(3),i()(),e(4,"td")(5,"div",16),B(6,"img",17),e(7,"span"),n(8),i()()(),e(9,"td"),f(10,ut,2,0,"div")(11,St,5,3),i(),e(12,"td"),f(13,Ct,4,4)(14,vt,1,0),i(),e(15,"td")(16,"div",18),f(17,xt,1,0)(18,gt,1,0)(19,ht,1,0),i()(),e(20,"td",19)(21,"div"),n(22),i(),e(23,"div"),n(24),v(25,"date"),i()()()),t&2){let a,r=o.$implicit,c=S();m("ngClass",K(16,st,r.Status==1,r.Status==0)),l(2),m("routerLink",j(19,dt))("queryParams",z(20,mt,r.ID)),l(),C(" ",r.ID," "),l(3),m("src",r.Img,T),l(2),x(r.ChannelName),l(2),_(r.StateID==c.scanState.InProgress?10:11),l(3),_(r.DurationInSecond?13:14),l(3),$(U(22,pt,r.StateID==c.scanState.InProgress,r.StateID==c.scanState.Completed,r.StateID==c.scanState.Failed)),l(),_((a=r.StateID)===c.scanState.InProgress?17:a===c.scanState.Completed?18:a===c.scanState.Failed?19:-1),l(5),x(r.LoginID),l(2),C(" ",V(25,13,r.Created,"dd MMM yyyy HH:mm")," ")}}var Ot=(()=>{let o=class o{constructor(){this.notificationService=F(b),this.filter=w({RowCount:20,PageNumber:1,ChannelID:null}),this.scanState=ct,this.initNotifications()}initNotifications(){this.notifications$=this.notificationService.getNotificationList(this.filter()).pipe(E(r=>(r.Data=r.Data.map(c=>(c.StatusProduct&&(c.ParsedStatus=JSON.parse(c.StatusProduct)),c)),r)),P(1))}onFilter(){this.initNotifications()}};o.\u0275fac=function(c){return new(c||o)},o.\u0275cmp=M({type:o,selectors:[["app-notificationV2"]],features:[A([b])],decls:37,vars:8,consts:[["headerTitle","Notification",3,"onSubmit","hideSearchBox"],["routerLink","/menu/products/status/notification",1,"btn","btn-outline-secondary","btn-lg"],[1,"fw-bold","mb-2"],[3,"ngModelChange","ngModel"],[1,"container-fluid","mt-3"],[1,"row"],[1,"col-md-12"],[1,"table-responsive"],[1,"table","table-hover"],[1,"sticky-top-thead"],[1,"table-light"],[2,"width","260px"],[3,"ngClass"],[1,"col-12"],[3,"next","previous","filter","totaldata","paginationTotal","hasClicked"],[3,"routerLink","queryParams"],[1,"d-flex","align-items-center","gap-3"],[1,"channelLogo-md",3,"src","alt"],[1,"fw-bold"],[1,"lh-base"]],template:function(c,d){if(c&1){let s=R();q(0),v(1,"async"),e(2,"mainpanel",0),y("onSubmit",function(){return p(s),u(d.onFilter())}),e(3,"actions")(4,"a",1),n(5," Scan Job "),i()(),e(6,"filters")(7,"div")(8,"label",2),n(9,"Channel"),i(),e(10,"app-channel-options-v2",3),W("ngModelChange",function(h){return p(s),J(d.filter().ChannelID,h)||(d.filter().ChannelID=h),u(h)}),i()()(),e(11,"content")(12,"div",4)(13,"div",5)(14,"div",6)(15,"div",7)(16,"table",8)(17,"thead",9)(18,"tr",10)(19,"th",11),n(20,"Job ID"),i(),e(21,"th"),n(22,"Channel"),i(),e(23,"th"),n(24,"Process"),i(),e(25,"th"),n(26,"Duration"),i(),e(27,"th"),n(28,"Status"),i(),e(29,"th"),n(30,"Creator"),i()()(),e(31,"tbody"),I(32,It,26,26,"tr",12,k),i()()()()(),e(34,"div",5)(35,"div",13)(36,"app-custom-paginator",14),y("next",function(){return p(s),u(d.initNotifications())})("previous",function(){return p(s),u(d.initNotifications())}),i()()()()()()}if(c&2){let s=D(1,6,d.notifications$);l(2),m("hideSearchBox",!0),l(8),H("ngModel",d.filter().ChannelID),l(22),N(s==null?null:s.Data),l(4),m("filter",d.filter())("totaldata",s==null||s.Data==null?null:s.Data.length)("paginationTotal",s==null?null:s.Count)("hasClicked",!0)}},dependencies:[Z,Y,ot,it,nt,at,rt,et,tt,lt,G,X,Q],encapsulation:2});let t=o;return t})();export{Ot as NotificationV2Component};
1
+ import{a as b,b as ct}from"./chunk-G4T4VM5E.js";import"./chunk-BKR7YPEW.js";import{a as lt}from"./chunk-RWPLFNHT.js";import"./chunk-MT3CWRVG.js";import"./chunk-W33M7S2S.js";import"./chunk-MTVUPPAN.js";import"./chunk-2NRHX6CZ.js";import{a as rt}from"./chunk-5WQ3LCWP.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-A6QXXKPR.js";import"./chunk-ZDBFIPDM.js";import"./chunk-DDFP4CNP.js";import"./chunk-RBZU7OVM.js";import{b as at}from"./chunk-BUMWMFHU.js";import"./chunk-ROS2QMKF.js";import"./chunk-5WT456T7.js";import"./chunk-YNL43MLU.js";import"./chunk-RXC5D64C.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{A as ot,h as it,m as nt}from"./chunk-WAXAIL2I.js";import"./chunk-RQUCYFCB.js";import"./chunk-RXLMJGUY.js";import"./chunk-MM7SAZOU.js";import{e as tt,g as et}from"./chunk-NQLMPUSB.js";import"./chunk-OSGPJXJZ.js";import{A as Z,q as Y,w as G,x as Q,z as X}from"./chunk-JNRCB7N3.js";import"./chunk-XBIHN6D3.js";import{$c as j,Hb as M,Ia as w,Mc as $,Nc as n,Oc as x,Pc as C,Qc as O,Rc as H,Sc as J,Tc as W,Uc as q,Z as P,_c as A,ac as f,ad as z,bd as K,cc as _,cd as U,dc as L,ec as k,fc as I,gc as N,hc as m,ic as e,id as v,jc as i,jd as D,kc as B,kd as V,mb as T,ob as l,ra as F,rc as R,v as E,wc as y,ya as p,yc as S,za as u}from"./chunk-OHGMB7HJ.js";import"./chunk-WFMAM73Y.js";import"./chunk-66YHNWRR.js";var st=(t,o)=>({"bg-gradient-danger":t,"bg-gradient-warning":o}),dt=()=>["/menu/products/status/notificationV2/detailV2"],mt=t=>({ID:t}),pt=(t,o,a)=>({"text-warning":t,"text-success":o,"text-danger":a});function ut(t,o){t&1&&(e(0,"div"),n(1," Scan in progress. You will be notified once it is complete. "),i())}function ft(t,o){if(t&1&&(e(0,"div"),n(1),v(2,"number"),i()),t&2){let a=o.$implicit;l(),O(" ",a.Key,": ",D(2,2,a.Value)," ")}}function _t(t,o){if(t&1&&(e(0,"div",19)(1,"div",18),n(2,"Status Product:"),i(),I(3,ft,3,4,"div",null,L),i()),t&2){let a=S(2).$implicit;l(3),N(a.ParsedStatus)}}function St(t,o){if(t&1&&(e(0,"div",18),n(1),i(),e(2,"div"),n(3),i(),f(4,_t,5,0,"div",19)),t&2){let a=S().$implicit;l(),C(" ",a.ProcessLabel," "),l(2),x(a.ProcessDescription),l(),_(a!=null&&a.ParsedStatus&&(a==null||a.ParsedStatus==null?null:a.ParsedStatus.length)>0?4:-1)}}function Ct(t,o){if(t&1&&(n(0),v(1,"number"),e(2,"span"),n(3,"s"),i()),t&2){let a=S().$implicit;C(" ",V(1,1,a.DurationInSecond,"1.1-1")," ")}}function vt(t,o){t&1&&n(0," - ")}function xt(t,o){t&1&&n(0," In Progress ")}function gt(t,o){t&1&&n(0," Completed ")}function ht(t,o){t&1&&n(0," Failed ")}function It(t,o){if(t&1&&(e(0,"tr",12)(1,"td")(2,"a",15),n(3),i()(),e(4,"td")(5,"div",16),B(6,"img",17),e(7,"span"),n(8),i()()(),e(9,"td"),f(10,ut,2,0,"div")(11,St,5,3),i(),e(12,"td"),f(13,Ct,4,4)(14,vt,1,0),i(),e(15,"td")(16,"div",18),f(17,xt,1,0)(18,gt,1,0)(19,ht,1,0),i()(),e(20,"td",19)(21,"div"),n(22),i(),e(23,"div"),n(24),v(25,"date"),i()()()),t&2){let a,r=o.$implicit,c=S();m("ngClass",K(16,st,r.Status==1,r.Status==0)),l(2),m("routerLink",j(19,dt))("queryParams",z(20,mt,r.ID)),l(),C(" ",r.ID," "),l(3),m("src",r.Img,T),l(2),x(r.ChannelName),l(2),_(r.StateID==c.scanState.InProgress?10:11),l(3),_(r.DurationInSecond?13:14),l(3),$(U(22,pt,r.StateID==c.scanState.InProgress,r.StateID==c.scanState.Completed,r.StateID==c.scanState.Failed)),l(),_((a=r.StateID)===c.scanState.InProgress?17:a===c.scanState.Completed?18:a===c.scanState.Failed?19:-1),l(5),x(r.LoginID),l(2),C(" ",V(25,13,r.Created,"dd MMM yyyy HH:mm")," ")}}var Ot=(()=>{let o=class o{constructor(){this.notificationService=F(b),this.filter=w({RowCount:20,PageNumber:1,ChannelID:null}),this.scanState=ct,this.initNotifications()}initNotifications(){this.notifications$=this.notificationService.getNotificationList(this.filter()).pipe(E(r=>(r.Data=r.Data.map(c=>(c.StatusProduct&&(c.ParsedStatus=JSON.parse(c.StatusProduct)),c)),r)),P(1))}onFilter(){this.initNotifications()}};o.\u0275fac=function(c){return new(c||o)},o.\u0275cmp=M({type:o,selectors:[["app-notificationV2"]],features:[A([b])],decls:37,vars:8,consts:[["headerTitle","Notification",3,"onSubmit","hideSearchBox"],["routerLink","/menu/products/status/notification",1,"btn","btn-outline-secondary","btn-lg"],[1,"fw-bold","mb-2"],[3,"ngModelChange","ngModel"],[1,"container-fluid","mt-3"],[1,"row"],[1,"col-md-12"],[1,"table-responsive"],[1,"table","table-hover"],[1,"sticky-top-thead"],[1,"table-light"],[2,"width","260px"],[3,"ngClass"],[1,"col-12"],[3,"next","previous","filter","totaldata","paginationTotal","hasClicked"],[3,"routerLink","queryParams"],[1,"d-flex","align-items-center","gap-3"],[1,"channelLogo-md",3,"src","alt"],[1,"fw-bold"],[1,"lh-base"]],template:function(c,d){if(c&1){let s=R();q(0),v(1,"async"),e(2,"mainpanel",0),y("onSubmit",function(){return p(s),u(d.onFilter())}),e(3,"actions")(4,"a",1),n(5," Scan Job "),i()(),e(6,"filters")(7,"div")(8,"label",2),n(9,"Channel"),i(),e(10,"app-channel-options-v2",3),W("ngModelChange",function(h){return p(s),J(d.filter().ChannelID,h)||(d.filter().ChannelID=h),u(h)}),i()()(),e(11,"content")(12,"div",4)(13,"div",5)(14,"div",6)(15,"div",7)(16,"table",8)(17,"thead",9)(18,"tr",10)(19,"th",11),n(20,"Job ID"),i(),e(21,"th"),n(22,"Channel"),i(),e(23,"th"),n(24,"Process"),i(),e(25,"th"),n(26,"Duration"),i(),e(27,"th"),n(28,"Status"),i(),e(29,"th"),n(30,"Creator"),i()()(),e(31,"tbody"),I(32,It,26,26,"tr",12,k),i()()()()(),e(34,"div",5)(35,"div",13)(36,"app-custom-paginator",14),y("next",function(){return p(s),u(d.initNotifications())})("previous",function(){return p(s),u(d.initNotifications())}),i()()()()()()}if(c&2){let s=D(1,6,d.notifications$);l(2),m("hideSearchBox",!0),l(8),H("ngModel",d.filter().ChannelID),l(22),N(s==null?null:s.Data),l(4),m("filter",d.filter())("totaldata",s==null||s.Data==null?null:s.Data.length)("paginationTotal",s==null?null:s.Count)("hasClicked",!0)}},dependencies:[Z,Y,ot,it,nt,at,rt,et,tt,lt,G,X,Q],encapsulation:2});let t=o;return t})();export{Ot as NotificationV2Component};
@@ -1 +1 @@
1
- import{a as G}from"./chunk-UE2QO2Y4.js";import"./chunk-MT3CWRVG.js";import"./chunk-W33M7S2S.js";import"./chunk-MTVUPPAN.js";import"./chunk-2NRHX6CZ.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-A6QXXKPR.js";import"./chunk-ZDBFIPDM.js";import"./chunk-DDFP4CNP.js";import"./chunk-RBZU7OVM.js";import{b as J}from"./chunk-BUMWMFHU.js";import"./chunk-ROS2QMKF.js";import"./chunk-5WT456T7.js";import"./chunk-YNL43MLU.js";import"./chunk-RXC5D64C.js";import"./chunk-O4D64GHO.js";import"./chunk-7R2D2JZ6.js";import"./chunk-QMQCIH3X.js";import"./chunk-YYV4FSYQ.js";import"./chunk-QXRG5XYP.js";import{a as I}from"./chunk-AGBJEXIM.js";import"./chunk-5UFP37GQ.js";import"./chunk-UPRDDI4K.js";import{A as H,c as R,h as j,m as F}from"./chunk-WAXAIL2I.js";import"./chunk-RQUCYFCB.js";import"./chunk-RXLMJGUY.js";import{e as W}from"./chunk-MM7SAZOU.js";import"./chunk-NQLMPUSB.js";import"./chunk-OSGPJXJZ.js";import{A as B,w as k,y as P}from"./chunk-JNRCB7N3.js";import"./chunk-XBIHN6D3.js";import{Hb as x,Ia as h,Nc as i,Oc as V,Rc as f,Sc as C,Tc as b,Uc as O,Vc as D,Wc as _,Z as S,ac as M,cc as N,hc as g,ic as e,id as v,jc as t,jd as y,kc as L,ob as d,ra as E,rc as T,wc as w,ya as p,yc as A,za as m}from"./chunk-OHGMB7HJ.js";import"./chunk-WFMAM73Y.js";import"./chunk-66YHNWRR.js";function Y(r,l){if(r&1&&(e(0,"pre",21),i(1),v(2,"json"),t()),r&2){A();let U=_(25);d(),V(y(2,1,U))}}function q(r,l){r&1&&(e(0,"p",22),i(1," Your data will be shown here once it's available "),t())}var ae=(()=>{let l=class l{constructor(){this.httpService=E(W),this.selectedChannel=h(null),this.orderNumber=h(null)}initEscrowLog(){this.escrowLog$=this.httpService.post(I.GetEscrowDetail,{ChannelID:this.selectedChannel(),OrderNumber:this.orderNumber()}).pipe(S(1))}copyToClipboard(c){if(!c)return;let s=typeof c=="string"?c:JSON.stringify(c,null,2);navigator.clipboard.writeText(s),alert("Copied to clipboard!")}};l.\u0275fac=function(s){return new(s||l)},l.\u0275cmp=x({type:l,selectors:[["app-escrow-api"]],decls:40,vars:9,consts:[["headerTitle","Origin Escrow Api",3,"hideSearchBox","hideSearchDropdown"],[1,"btn","btn-success","btn-fill","me-3",3,"click"],[1,"fa","fa-search"],[1,"container-fluid","mt-8","px-10"],[1,"row"],[1,"col-7"],[1,"d-flex","align-items-center"],[1,"w-75"],[1,"mb-0","text-muted","fst-italic"],[1,"w-100"],[3,"ngModelChange","ngModel"],[1,"d-flex","align-items-center","mt-3"],["type","text","placeholder","Order Number or Invoice Number",1,"form-control","rounded-1",2,"height","40px",3,"ngModelChange","ngModel"],[1,"row","mt-6"],[1,"col-12"],[1,"card"],[1,"card-header","d-flex","justify-content-between","align-items-center"],["type","button",1,"btn","btn-sm","btn-outline-primary",3,"click","disabled"],[1,"card-body"],[1,"col-sm-12"],[1,"form-group","position-relative"],["id","escrowLogText"],[1,"text-center","my-12","text-muted"]],template:function(s,n){if(s&1){let a=T();e(0,"mainpanel",0)(1,"actions")(2,"button",1),w("click",function(){return p(a),m(n.initEscrowLog())}),L(3,"i",2),i(4," Search "),t()(),e(5,"content")(6,"div",3)(7,"div",4)(8,"div",5)(9,"div",6)(10,"div",7)(11,"h6"),i(12,"Channel"),t(),e(13,"p",8),i(14," View logs related to Escrow API "),t()(),e(15,"div",9)(16,"app-channel-options-v2",10),b("ngModelChange",function(o){return p(a),C(n.selectedChannel,o)||(n.selectedChannel=o),m(o)}),t()()(),e(17,"div",11)(18,"div",7)(19,"h6"),i(20,"Order Number"),t(),e(21,"p",8),i(22," Order or Invoice number from Channel. "),t()(),e(23,"div",9)(24,"input",12),b("ngModelChange",function(o){return p(a),C(n.orderNumber,o)||(n.orderNumber=o),m(o)}),t()()()()(),O(25),v(26,"async"),e(27,"div",13)(28,"div",14)(29,"div",15)(30,"div",16)(31,"h5"),i(32,"Response"),t(),e(33,"button",17),w("click",function(){p(a);let o=_(25);return m(n.copyToClipboard(o))}),i(34," Copy "),t()(),e(35,"div",18)(36,"div",19)(37,"div",20),M(38,Y,3,3,"pre",21)(39,q,2,0,"p",22),t()()()()()()()()()}if(s&2){g("hideSearchBox",!0)("hideSearchDropdown",!0),d(16),f("ngModel",n.selectedChannel),d(8),f("ngModel",n.orderNumber),d();let a=D(y(26,6,n.escrowLog$));d(8),g("disabled",!a),d(5),N(a?38:39)}},dependencies:[B,H,R,j,F,J,G,k,P],styles:[".container-fluid[_ngcontent-%COMP%]{padding-bottom:1rem}#escrowLogText[_ngcontent-%COMP%]{white-space:pre-wrap;word-break:break-word}"]});let r=l;return r})();export{ae as EscrowApiComponent};
1
+ import{a as G}from"./chunk-RWPLFNHT.js";import"./chunk-MT3CWRVG.js";import"./chunk-W33M7S2S.js";import"./chunk-MTVUPPAN.js";import"./chunk-2NRHX6CZ.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-A6QXXKPR.js";import"./chunk-ZDBFIPDM.js";import"./chunk-DDFP4CNP.js";import"./chunk-RBZU7OVM.js";import{b as J}from"./chunk-BUMWMFHU.js";import"./chunk-ROS2QMKF.js";import"./chunk-5WT456T7.js";import"./chunk-YNL43MLU.js";import"./chunk-RXC5D64C.js";import"./chunk-O4D64GHO.js";import"./chunk-7R2D2JZ6.js";import"./chunk-O3QPBAV5.js";import"./chunk-YYV4FSYQ.js";import"./chunk-QXRG5XYP.js";import{a as I}from"./chunk-AGBJEXIM.js";import"./chunk-5UFP37GQ.js";import"./chunk-UPRDDI4K.js";import{A as H,c as R,h as j,m as F}from"./chunk-WAXAIL2I.js";import"./chunk-RQUCYFCB.js";import"./chunk-RXLMJGUY.js";import{e as W}from"./chunk-MM7SAZOU.js";import"./chunk-NQLMPUSB.js";import"./chunk-OSGPJXJZ.js";import{A as B,w as k,y as P}from"./chunk-JNRCB7N3.js";import"./chunk-XBIHN6D3.js";import{Hb as x,Ia as h,Nc as i,Oc as V,Rc as f,Sc as C,Tc as b,Uc as O,Vc as D,Wc as _,Z as S,ac as M,cc as N,hc as g,ic as e,id as v,jc as t,jd as y,kc as L,ob as d,ra as E,rc as T,wc as w,ya as p,yc as A,za as m}from"./chunk-OHGMB7HJ.js";import"./chunk-WFMAM73Y.js";import"./chunk-66YHNWRR.js";function Y(r,l){if(r&1&&(e(0,"pre",21),i(1),v(2,"json"),t()),r&2){A();let U=_(25);d(),V(y(2,1,U))}}function q(r,l){r&1&&(e(0,"p",22),i(1," Your data will be shown here once it's available "),t())}var ae=(()=>{let l=class l{constructor(){this.httpService=E(W),this.selectedChannel=h(null),this.orderNumber=h(null)}initEscrowLog(){this.escrowLog$=this.httpService.post(I.GetEscrowDetail,{ChannelID:this.selectedChannel(),OrderNumber:this.orderNumber()}).pipe(S(1))}copyToClipboard(c){if(!c)return;let s=typeof c=="string"?c:JSON.stringify(c,null,2);navigator.clipboard.writeText(s),alert("Copied to clipboard!")}};l.\u0275fac=function(s){return new(s||l)},l.\u0275cmp=x({type:l,selectors:[["app-escrow-api"]],decls:40,vars:9,consts:[["headerTitle","Origin Escrow Api",3,"hideSearchBox","hideSearchDropdown"],[1,"btn","btn-success","btn-fill","me-3",3,"click"],[1,"fa","fa-search"],[1,"container-fluid","mt-8","px-10"],[1,"row"],[1,"col-7"],[1,"d-flex","align-items-center"],[1,"w-75"],[1,"mb-0","text-muted","fst-italic"],[1,"w-100"],[3,"ngModelChange","ngModel"],[1,"d-flex","align-items-center","mt-3"],["type","text","placeholder","Order Number or Invoice Number",1,"form-control","rounded-1",2,"height","40px",3,"ngModelChange","ngModel"],[1,"row","mt-6"],[1,"col-12"],[1,"card"],[1,"card-header","d-flex","justify-content-between","align-items-center"],["type","button",1,"btn","btn-sm","btn-outline-primary",3,"click","disabled"],[1,"card-body"],[1,"col-sm-12"],[1,"form-group","position-relative"],["id","escrowLogText"],[1,"text-center","my-12","text-muted"]],template:function(s,n){if(s&1){let a=T();e(0,"mainpanel",0)(1,"actions")(2,"button",1),w("click",function(){return p(a),m(n.initEscrowLog())}),L(3,"i",2),i(4," Search "),t()(),e(5,"content")(6,"div",3)(7,"div",4)(8,"div",5)(9,"div",6)(10,"div",7)(11,"h6"),i(12,"Channel"),t(),e(13,"p",8),i(14," View logs related to Escrow API "),t()(),e(15,"div",9)(16,"app-channel-options-v2",10),b("ngModelChange",function(o){return p(a),C(n.selectedChannel,o)||(n.selectedChannel=o),m(o)}),t()()(),e(17,"div",11)(18,"div",7)(19,"h6"),i(20,"Order Number"),t(),e(21,"p",8),i(22," Order or Invoice number from Channel. "),t()(),e(23,"div",9)(24,"input",12),b("ngModelChange",function(o){return p(a),C(n.orderNumber,o)||(n.orderNumber=o),m(o)}),t()()()()(),O(25),v(26,"async"),e(27,"div",13)(28,"div",14)(29,"div",15)(30,"div",16)(31,"h5"),i(32,"Response"),t(),e(33,"button",17),w("click",function(){p(a);let o=_(25);return m(n.copyToClipboard(o))}),i(34," Copy "),t()(),e(35,"div",18)(36,"div",19)(37,"div",20),M(38,Y,3,3,"pre",21)(39,q,2,0,"p",22),t()()()()()()()()()}if(s&2){g("hideSearchBox",!0)("hideSearchDropdown",!0),d(16),f("ngModel",n.selectedChannel),d(8),f("ngModel",n.orderNumber),d();let a=D(y(26,6,n.escrowLog$));d(8),g("disabled",!a),d(5),N(a?38:39)}},dependencies:[B,H,R,j,F,J,G,k,P],styles:[".container-fluid[_ngcontent-%COMP%]{padding-bottom:1rem}#escrowLogText[_ngcontent-%COMP%]{white-space:pre-wrap;word-break:break-word}"]});let r=l;return r})();export{ae as EscrowApiComponent};
@@ -1 +1 @@
1
- import{a as ve}from"./chunk-QQF5ZMGS.js";import{a as Se,b as we}from"./chunk-6NS3D6KQ.js";import{a as Te,b as ye}from"./chunk-LUJ3SHSP.js";import{a as fe}from"./chunk-DLHIDOS3.js";import{a as pe,b as ge,c as ue,g as he,i as Ce,j as xe}from"./chunk-5WT456T7.js";import{a as _e}from"./chunk-YNL43MLU.js";import{b as be}from"./chunk-4S4BOPUV.js";import{a as le}from"./chunk-A2RTZANN.js";import{c as me}from"./chunk-O4D64GHO.js";import{a as D}from"./chunk-ZSUWHVKX.js";import{h as se}from"./chunk-QMQCIH3X.js";import{a as ae,b as re,c as ce}from"./chunk-5UFP37GQ.js";import{c as Z}from"./chunk-UPRDDI4K.js";import{A as L,b as de,h as $,m as B}from"./chunk-WAXAIL2I.js";import{A as oe,q as te,v as ne,z as ie}from"./chunk-JNRCB7N3.js";import{G,Hb as N,Ia as R,Ic as z,Nb as T,Nc as _,Oc as F,Pc as P,Rc as E,Sc as k,Tc as O,Xc as Y,ac as u,ad as M,bd as J,ca as K,cc as h,dc as I,ec as X,f as q,fc as v,gc as S,hc as d,ic as r,id as U,jc as s,jd as H,kc as w,kd as Q,ld as ee,mb as y,ob as c,qc as j,ra as b,rc as C,tb as A,ud as V,wc as x,ya as p,yc as a,za as g}from"./chunk-OHGMB7HJ.js";function Fe(t,l){if(t&1){let e=C();r(0,"span")(1,"mat-checkbox",4),x("change",function(n){p(e);let o=a();return g(o.onSelectAll(n==null?null:n.checked))}),r(2,"h5",5),_(3,"Select All"),s()()()}}function Pe(t,l){if(t&1){let e=C();r(0,"li")(1,"mat-checkbox",6),O("ngModelChange",function(n){let o=p(e).$implicit;return k(o.selected,n)||(o.selected=n),g(n)}),r(2,"div",7),w(3,"img",8),r(4,"h5",9),_(5),s()()()()}if(t&2){let e=l.$implicit;c(),E("ngModel",e.selected),c(2),d("src",e.Img,y),c(2),F(e.Name)}}var dt=(()=>{let l=class l{constructor(){this.data=b(ge),this.dialogRef=b(pe),this.selectedItems=this.data.selectedItems,this.channels=this.data.channels}ngOnInit(){this.initModalConfig()}initModalConfig(){let i=this.data.title?this.data.title:"Updating Inventory";this.modalConfig=new Ce,this.modalConfig.title=i}onSelectAll(i){this.channels=this.channels.map(n=>(n.selected=i,n))}onOk(){this.dialogRef.close(this.channels)}onClose(){this.dialogRef.close()}get getSelectedChannel(){return this.channels.filter(i=>i.selected)}};l.\u0275fac=function(n){return new(n||l)},l.\u0275cmp=N({type:l,selectors:[["app-modal-update-channels"]],decls:7,vars:3,consts:[[3,"onOk","onClose","onCancel","dynamicValidated","config"],["content",""],[2,"overflow-y","auto","max-height","28rem"],[1,"no-bullet",2,"margin-bottom","0px !important","overflow","hidden"],["color","primary",1,"me-6",3,"change"],[1,"fw-light"],["color","primary",3,"ngModelChange","ngModel"],[1,"d-flex","align-items-center"],[1,"channelLogo-md",3,"src"],[1,"fw-light","ms-2","my-auto"]],template:function(n,o){n&1&&(r(0,"modal-material",0),x("onOk",function(){return o.onOk()})("onClose",function(){return o.onClose()})("onCancel",function(){return o.onClose()}),r(1,"div",1)(2,"div",2),u(3,Fe,4,0,"span"),r(4,"ul",3),v(5,Pe,6,3,"li",null,I),s()()()()),n&2&&(d("dynamicValidated",(o.getSelectedChannel==null?null:o.getSelectedChannel.length)>0)("config",o.modalConfig),c(3),h((o.channels==null?null:o.channels.length)>1?3:-1),c(2),S(o.channels))},dependencies:[xe,ve,L,$,B],styles:[".no-bullet[_ngcontent-%COMP%]{list-style-type:none}mat-form-field[_ngcontent-%COMP%]{width:100%;height:100%}.mat-dialog-title[_ngcontent-%COMP%]{margin-bottom:0%;margin-left:24px}.vertical-radio[_ngcontent-%COMP%]{display:flex;flex-direction:column;margin:15px 0}"]});let t=l;return t})();var W=t=>[t],Ee=t=>({"text-decoration-line-through":t}),ke=t=>({"text-danger":t}),Oe=(t,l)=>({"bg-gradient-warning":t,"cell-hover pointer":l});function Ve(t,l){if(t&1){let e=C();r(0,"mat-slide-toggle",10),x("toggleChange",function(){p(e);let n=a();return n.toggleStatus=!n.toggleStatus,g(n.onToggle())}),r(1,"small",11),_(2),s()()}if(t&2){let e=a();c(2),P(" ",e.productToggleTitle?e.productToggleTitle:"FILTER DIFFERENT INVENTORY"," ")}}function De(t,l){if(t&1){let e=C();r(0,"th")(1,"input",13),O("ngModelChange",function(n){p(e);let o=a(2);return k(o.checkboxState,n)||(o.checkboxState=n),g(n)}),x("ngModelChange",function(){p(e);let n=a(2);return g(n.onCheckboxStateChange())}),s()()}if(t&2){let e=a(2);c(),E("ngModel",e.checkboxState)}}function Ne(t,l){if(t&1&&(T(0,De,2,1,"ng-template",12),r(1,"th",8),_(2,"POS"),s()),t&2){let e=a();d("ngxPermissionsOnly",M(1,W,e.rolePriceEdit))}}function Ue(t,l){if(t&1&&(r(0,"th",9)(1,"div",14)(2,"div",15),w(3,"img",16),r(4,"div",17),_(5),U(6,"stringLimit"),s()()()()),t&2){let e=l.$implicit;c(2),d("matTooltip",(e.Name==null?null:e.Name.length)>20?e.Name:""),c(),d("src",e==null?null:e.Img,y),c(2),P(" ",Q(6,3,e.Name,20)," ")}}function $e(t,l){t&1&&j(0)}function Be(t,l){if(t&1&&T(0,$e,1,0,"ng-container",29),t&2){a(2);let e=z(5);d("ngTemplateOutlet",e)}}function Le(t,l){if(t&1&&T(0,Be,1,1,"ng-template",12),t&2){let e=a(4);d("ngxPermissionsOnly",M(1,W,e.roleInventoryUpdate))}}function We(t,l){t&1&&j(0)}function Re(t,l){if(t&1&&T(0,We,1,0,"ng-container",29),t&2){a(2);let e=z(5);d("ngTemplateOutlet",e)}}function Ae(t,l){if(t&1&&T(0,Re,1,1,"ng-template",12),t&2){let e=a(4);d("ngxPermissionsOnly",M(1,W,e.rolePriceEdit))}}function je(t,l){if(t&1){let e=C();r(0,"div")(1,"input",30),O("ngModelChange",function(n){p(e);let o=a(4).$implicit;return k(o.selected,n)||(o.selected=n),g(n)}),x("ngModelChange",function(){p(e);let n=a(4).$implicit,o=a();return g(o.onCheckboxStateProduct(n.ID))}),s()()}if(t&2){let e=a(4).$implicit;c(),E("ngModel",e.selected),d("disabled",!(e!=null&&e.Category))}}function ze(t,l){if(t&1&&u(0,je,2,2,"div"),t&2){let e=a(3).$implicit;h((e==null||e.Variants==null?null:e.Variants.length)>1?0:-1)}}function He(t,l){if(t&1){let e=C();r(0,"img",31),x("click",function(n){p(e);let o=a(3).$implicit,m=a();return g(m.onZoomImage(n,o==null?null:o.ImageUrl))}),s()}if(t&2){let e=a(3).$implicit;d("src",Y(e==null?null:e.ThumbnailUrl),y)}}function Ze(t,l){t&1&&w(0,"img",26)}function qe(t,l){if(t&1&&(r(0,"td",23)(1,"div",24),u(2,Le,1,3,null,12)(3,Ae,1,3,null,12),T(4,ze,1,1,"ng-template",null,0,ee),r(6,"div"),u(7,He,1,2,"img",25)(8,Ze,1,0,"img",26),s()()(),r(9,"td",27)(10,"div"),_(11),s(),r(12,"small",28),_(13),s()()),t&2){let e=a(2).$implicit,i=a();d("rowSpan",e==null?null:e.Variants.length),c(2),h(i.table()=="inventory"?2:3),c(5),h(e!=null&&e.ThumbnailUrl?7:8),c(2),d("rowSpan",e==null?null:e.Variants.length),c(2),F(e==null?null:e.Name),c(),d("ngClass",M(7,ke,!(e!=null&&e.Category))),c(),P("(",e!=null&&e.Category?e==null?null:e.Category:"Not Found In POS",")")}}function Ge(t,l){if(t&1&&(r(0,"a",22),w(1,"i",32),s()),t&2){let e=a().$implicit,i=a(2);d("href",i.hostName+"/menu/Products/Catalog/Variants/Info?ID="+(e==null?null:e.ID),y)}}function Ke(t,l){if(t&1){let e=C();r(0,"input",35),O("ngModelChange",function(n){p(e);let o=a(3).$implicit;return k(o.selected,n)||(o.selected=n),g(n)}),s()}if(t&2){let e=a(3).$implicit,i=a().$implicit;E("ngModel",e.selected),d("disabled",!(i!=null&&i.Category))}}function Xe(t,l){if(t&1&&(r(0,"td",33),u(1,Ke,1,2,"input",34),s()),t&2){let e=a(2).$implicit,i=a(2);c(),h(i.printPOS(e)>=0||i.table()=="price"?1:-1)}}function Ye(t,l){if(t&1&&(T(0,Xe,2,1,"ng-template",12),r(1,"td",19),_(2),U(3,"number"),s()),t&2){let e=a().$implicit,i=a(2);d("ngxPermissionsOnly",M(4,W,i.rolePriceEdit)),c(2),F(H(3,2,i.printPOS(e)))}}function Je(t,l){if(t&1){let e=C();r(0,"td",38),x("click",function(){p(e);let n=a().$implicit,o=a().$implicit,m=a().$implicit,f=a();return g(f.onUpdateData(m.Name,o,n.ID,m.ChannelItemID))}),r(1,"div",39)(2,"div",40),_(3),U(4,"number"),s(),r(5,"a",41),x("click",function(n){return p(e),g(n==null?null:n.stopPropagation())}),w(6,"i",32),s()()()}if(t&2){let e=l,i=a(2).$implicit,n=a(2);d("ngClass",J(5,Oe,n.printPOS(i)!=n.printItem(e)&&n.hiddenIPOSInventory()==!1,n.hasPriceEdit()&&n.table()=="price"||n.hasInventoryEdit()&&n.table()=="inventory")),c(3),P(" ",H(4,3,n.printItem(e))," "),c(2),d("href",e.Url,y)}}function Qe(t,l){t&1&&(r(0,"td",37)(1,"div",39)(2,"span"),_(3,"X"),s()()())}function et(t,l){if(t&1&&u(0,Je,7,8,"td",36)(1,Qe,4,0,"td",37),t&2){let e,i=l.$implicit,n=a().$implicit,o=a(2);h((e=o.getItemFromChannel(n,i))?0:1,e)}}function tt(t,l){if(t&1&&(r(0,"tr"),u(1,qe,14,9),r(2,"td",18),_(3),s(),r(4,"td",19)(5,"div",20)(6,"div",21),_(7),s(),r(8,"div",17),u(9,Ge,2,1,"a",22),s()()(),u(10,Ye,4,6),v(11,et,2,1,null,null,I),s()),t&2){let e=l.$implicit,i=l.$index,n=a().$implicit,o=a();c(),h(i==0?1:-1),c(2),F(e==null?null:e.Model),c(2),d("matTooltip",e.Discontinued?o.discontinuedVariantMsg:""),c(),d("ngClass",M(7,Ee,e.Discontinued)),c(),P(" ",e.Code," "),c(2),h(n.Category?9:-1),c(),h(o.hiddenIPOSInventory()==!1?10:-1),c(),S(o.channel())}}function nt(t,l){if(t&1&&(r(0,"tbody"),v(1,tt,13,9,"tr",null,I),s()),t&2){let e=l.$implicit;c(),S(e.Variants)}}var Nt=(()=>{let l=class l{constructor(){this.dialog=b(ue),this.biggerPictureService=b(fe),this.authService=b(se),this.permissionsService=b(ae),this.table=V(void 0),this.channel=V(void 0),this.showProductToggle=V(!1),this.multiwarehouse=V(!1),this.hiddenIPOSInventory=V(!1),this.toggleStatus=!1,this.checkboxState=!1,this.rolePriceEdit=D.PriceUpdate,this.roleInventoryUpdate=D.InventoryUpdate,this.hasPriceEdit=R(!1),this.hasInventoryEdit=R(!1),this.discontinuedVariantMsg="This Variant is discontinued from POS, you must Non Active manually at the seller center so that it is not sold again on the channel.",this.onSubmit=new A,this.destroy$=new q,this.toggle=new A,this.hostName=this.authService.getDomain()}ngOnInit(){this.initRoles();let i=this.table();i=="inventory"?this.stockHeader="Stock":i=="price"&&(this.stockHeader="Price")}initRoles(){this.permissionsService.hasPermission(D.InventoryUpdate).then(i=>this.hasInventoryEdit.set(i)),this.permissionsService.hasPermission(D.PriceUpdate).then(i=>this.hasPriceEdit.set(i))}onCheckboxStateProduct(i){let n=this.data.filter(o=>o.ID==i);n.length>0&&(n=n.map(o=>(o.Variants=o.Variants.map(m=>(m.selected=o.selected,m)),o)))}onCheckboxStateChange(){this.data=this.data.map(i=>(i.Variants=i.Variants.map(n=>(n.selected=this.checkboxState,n)),i))}getItemFromChannel(i,n){return i.Channel.find(m=>Z.IsNotEmpty(n.LocationID)?m.LocationID==n.LocationID:m.ChannelID==n.ID)}printItem(i){let n=this.table();if(n=="inventory")return i.Inventory;if(n=="price")return i.Price}onUpdateData(i,n,o,m){let f=this.table();this.hasPriceEdit()&&f=="price"&&this.onOpenDialogUpdate(i,n,o,m),this.hasInventoryEdit()&&f=="inventory"&&this.onOpenDialogUpdate(i,n,o,m)}onOpenDialogUpdate(i,n,o,m){this.dialog.open(Se,{data:{Name:i,Variant:n,ChannelID:o,Table:this.table(),ChannelItemID:m}}).afterClosed().pipe(G(f=>Z.IsNotEmpty(f)),K(this.destroy$)).subscribe(f=>{this.onSubmit.emit(f)})}printPOS(i){let n=this.table();return n=="inventory"?i.Inventory?i.Inventory:0:n=="price"?i.UnitPrice:null}onToggle(){this.toggle.emit(this.toggleStatus)}onZoomImage(i,n){this.biggerPictureService.openBiggerPicture(i,n)}ngOnDestroy(){this.destroy$.next(!0),this.destroy$.complete()}};l.\u0275fac=function(n){return new(n||l)},l.\u0275cmp=N({type:l,selectors:[["app-table"]],inputs:{data:"data",table:[1,"table"],channel:[1,"channel"],showProductToggle:[1,"showProductToggle"],productToggleTitle:"productToggleTitle",multiwarehouse:[1,"multiwarehouse"],hiddenIPOSInventory:[1,"hiddenIPOSInventory"]},outputs:{onSubmit:"onSubmit",toggle:"onToggle"},decls:18,vars:2,consts:[["checkbox_update",""],[1,"table-responsive"],[1,"table"],[1,"thead-light","sticky-top-thead"],["scope","col","colspan","2",1,"text-center","w-25"],[1,"w-100"],[2,"width","200px"],["scope","col",1,"text-start","w-20"],["scope","col",1,"text-end","w-10"],["scope","col"],[2,"width","200px",3,"toggleChange"],[1,"fw-bold"],[3,"ngxPermissionsOnly"],["type","checkbox",3,"ngModelChange","ngModel"],[1,"w-100","d-flex","align-items-center","justify-content-center"],["matTooltipPosition","above",1,"d-flex","align-items-center","justify-content-center",2,"width","180px",3,"matTooltip"],[2,"width","16px","height","16px",3,"src"],[1,"ms-2"],[1,"text-start"],[1,"text-end"],["matTooltipPosition","above",1,"d-flex","align-items-center","justify-content-end",3,"matTooltip"],[3,"ngClass"],["target","_blank",3,"href"],[1,"text-center",3,"rowSpan"],[1,"d-flex","align-items-center","justify-content-end"],[1,"border","rounded","w-img","cursor-pointer",3,"src"],["src","//res.cloudinary.com/pos/image/upload/w_40/POS/Images/Icon/products_thumb.png",1,"border","rounded","w-img"],[1,"text-start",2,"padding-left","0px",3,"rowSpan"],[1,"mt-1",3,"ngClass"],[4,"ngTemplateOutlet"],["type","checkbox",1,"me-3",3,"ngModelChange","ngModel","disabled"],[1,"border","rounded","w-img","cursor-pointer",3,"click","src"],[1,"fas","fa-solid","fa-arrow-up-right-from-square","external-link-custom"],[1,"align-middle"],["type","checkbox",3,"ngModel","disabled"],["type","checkbox",3,"ngModelChange","ngModel","disabled"],[1,"p-0",3,"ngClass"],[1,"table-white","text-center",2,"color","red"],[1,"p-0",3,"click","ngClass"],[1,"d-flex","align-items-center","justify-content-center"],[1,"me-2","mt-1"],["target","_blank",3,"click","href"]],template:function(n,o){n&1&&(r(0,"div",1)(1,"table",2)(2,"thead",3)(3,"tr")(4,"th",4)(5,"div",5)(6,"div"),_(7,"Product"),s(),u(8,Ve,3,1,"mat-slide-toggle",6),s()(),r(9,"th",7),_(10,"Variant"),s(),r(11,"th",8),_(12,"SKU"),s(),u(13,Ne,3,3),v(14,Ue,7,6,"th",9,X),s()(),v(16,nt,3,0,"tbody",null,I),s()()),n&2&&(c(8),h(o.showProductToggle()?8:-1),c(5),h(o.hiddenIPOSInventory()==!1?13:-1),c(),S(o.channel()),c(2),S(o.data))},dependencies:[oe,te,ne,L,de,$,B,ye,Te,he,le,be,ce,re,_e,me,ie,we],styles:[".w-10[_ngcontent-%COMP%]{width:10%}.w-20[_ngcontent-%COMP%]{width:20%}.w-img[_ngcontent-%COMP%]{width:40px;height:40px}.item-name[_ngcontent-%COMP%]{margin-bottom:-14px!important;font-size:larger}.cell-hover[_ngcontent-%COMP%]:hover{background-color:#c9c9c9!important}.text-wrapping[_ngcontent-%COMP%]{text-overflow:ellipsis;white-space:nowrap;overflow:hidden;width:88px}.cell-hover[_ngcontent-%COMP%]{width:400px!important}"]});let t=l;return t})();export{dt as a,Nt as b};
1
+ import{a as ve}from"./chunk-QQF5ZMGS.js";import{a as Se,b as we}from"./chunk-6NS3D6KQ.js";import{a as Te,b as ye}from"./chunk-LUJ3SHSP.js";import{a as fe}from"./chunk-DLHIDOS3.js";import{a as pe,b as ge,c as ue,g as he,i as Ce,j as xe}from"./chunk-5WT456T7.js";import{a as _e}from"./chunk-YNL43MLU.js";import{b as be}from"./chunk-4S4BOPUV.js";import{a as le}from"./chunk-A2RTZANN.js";import{c as me}from"./chunk-O4D64GHO.js";import{a as D}from"./chunk-ZSUWHVKX.js";import{h as se}from"./chunk-O3QPBAV5.js";import{a as ae,b as re,c as ce}from"./chunk-5UFP37GQ.js";import{c as Z}from"./chunk-UPRDDI4K.js";import{A as L,b as de,h as $,m as B}from"./chunk-WAXAIL2I.js";import{A as oe,q as te,v as ne,z as ie}from"./chunk-JNRCB7N3.js";import{G,Hb as N,Ia as R,Ic as z,Nb as T,Nc as _,Oc as F,Pc as P,Rc as E,Sc as k,Tc as O,Xc as Y,ac as u,ad as M,bd as J,ca as K,cc as h,dc as I,ec as X,f as q,fc as v,gc as S,hc as d,ic as r,id as U,jc as s,jd as H,kc as w,kd as Q,ld as ee,mb as y,ob as c,qc as j,ra as b,rc as C,tb as A,ud as V,wc as x,ya as p,yc as a,za as g}from"./chunk-OHGMB7HJ.js";function Fe(t,l){if(t&1){let e=C();r(0,"span")(1,"mat-checkbox",4),x("change",function(n){p(e);let o=a();return g(o.onSelectAll(n==null?null:n.checked))}),r(2,"h5",5),_(3,"Select All"),s()()()}}function Pe(t,l){if(t&1){let e=C();r(0,"li")(1,"mat-checkbox",6),O("ngModelChange",function(n){let o=p(e).$implicit;return k(o.selected,n)||(o.selected=n),g(n)}),r(2,"div",7),w(3,"img",8),r(4,"h5",9),_(5),s()()()()}if(t&2){let e=l.$implicit;c(),E("ngModel",e.selected),c(2),d("src",e.Img,y),c(2),F(e.Name)}}var dt=(()=>{let l=class l{constructor(){this.data=b(ge),this.dialogRef=b(pe),this.selectedItems=this.data.selectedItems,this.channels=this.data.channels}ngOnInit(){this.initModalConfig()}initModalConfig(){let i=this.data.title?this.data.title:"Updating Inventory";this.modalConfig=new Ce,this.modalConfig.title=i}onSelectAll(i){this.channels=this.channels.map(n=>(n.selected=i,n))}onOk(){this.dialogRef.close(this.channels)}onClose(){this.dialogRef.close()}get getSelectedChannel(){return this.channels.filter(i=>i.selected)}};l.\u0275fac=function(n){return new(n||l)},l.\u0275cmp=N({type:l,selectors:[["app-modal-update-channels"]],decls:7,vars:3,consts:[[3,"onOk","onClose","onCancel","dynamicValidated","config"],["content",""],[2,"overflow-y","auto","max-height","28rem"],[1,"no-bullet",2,"margin-bottom","0px !important","overflow","hidden"],["color","primary",1,"me-6",3,"change"],[1,"fw-light"],["color","primary",3,"ngModelChange","ngModel"],[1,"d-flex","align-items-center"],[1,"channelLogo-md",3,"src"],[1,"fw-light","ms-2","my-auto"]],template:function(n,o){n&1&&(r(0,"modal-material",0),x("onOk",function(){return o.onOk()})("onClose",function(){return o.onClose()})("onCancel",function(){return o.onClose()}),r(1,"div",1)(2,"div",2),u(3,Fe,4,0,"span"),r(4,"ul",3),v(5,Pe,6,3,"li",null,I),s()()()()),n&2&&(d("dynamicValidated",(o.getSelectedChannel==null?null:o.getSelectedChannel.length)>0)("config",o.modalConfig),c(3),h((o.channels==null?null:o.channels.length)>1?3:-1),c(2),S(o.channels))},dependencies:[xe,ve,L,$,B],styles:[".no-bullet[_ngcontent-%COMP%]{list-style-type:none}mat-form-field[_ngcontent-%COMP%]{width:100%;height:100%}.mat-dialog-title[_ngcontent-%COMP%]{margin-bottom:0%;margin-left:24px}.vertical-radio[_ngcontent-%COMP%]{display:flex;flex-direction:column;margin:15px 0}"]});let t=l;return t})();var W=t=>[t],Ee=t=>({"text-decoration-line-through":t}),ke=t=>({"text-danger":t}),Oe=(t,l)=>({"bg-gradient-warning":t,"cell-hover pointer":l});function Ve(t,l){if(t&1){let e=C();r(0,"mat-slide-toggle",10),x("toggleChange",function(){p(e);let n=a();return n.toggleStatus=!n.toggleStatus,g(n.onToggle())}),r(1,"small",11),_(2),s()()}if(t&2){let e=a();c(2),P(" ",e.productToggleTitle?e.productToggleTitle:"FILTER DIFFERENT INVENTORY"," ")}}function De(t,l){if(t&1){let e=C();r(0,"th")(1,"input",13),O("ngModelChange",function(n){p(e);let o=a(2);return k(o.checkboxState,n)||(o.checkboxState=n),g(n)}),x("ngModelChange",function(){p(e);let n=a(2);return g(n.onCheckboxStateChange())}),s()()}if(t&2){let e=a(2);c(),E("ngModel",e.checkboxState)}}function Ne(t,l){if(t&1&&(T(0,De,2,1,"ng-template",12),r(1,"th",8),_(2,"POS"),s()),t&2){let e=a();d("ngxPermissionsOnly",M(1,W,e.rolePriceEdit))}}function Ue(t,l){if(t&1&&(r(0,"th",9)(1,"div",14)(2,"div",15),w(3,"img",16),r(4,"div",17),_(5),U(6,"stringLimit"),s()()()()),t&2){let e=l.$implicit;c(2),d("matTooltip",(e.Name==null?null:e.Name.length)>20?e.Name:""),c(),d("src",e==null?null:e.Img,y),c(2),P(" ",Q(6,3,e.Name,20)," ")}}function $e(t,l){t&1&&j(0)}function Be(t,l){if(t&1&&T(0,$e,1,0,"ng-container",29),t&2){a(2);let e=z(5);d("ngTemplateOutlet",e)}}function Le(t,l){if(t&1&&T(0,Be,1,1,"ng-template",12),t&2){let e=a(4);d("ngxPermissionsOnly",M(1,W,e.roleInventoryUpdate))}}function We(t,l){t&1&&j(0)}function Re(t,l){if(t&1&&T(0,We,1,0,"ng-container",29),t&2){a(2);let e=z(5);d("ngTemplateOutlet",e)}}function Ae(t,l){if(t&1&&T(0,Re,1,1,"ng-template",12),t&2){let e=a(4);d("ngxPermissionsOnly",M(1,W,e.rolePriceEdit))}}function je(t,l){if(t&1){let e=C();r(0,"div")(1,"input",30),O("ngModelChange",function(n){p(e);let o=a(4).$implicit;return k(o.selected,n)||(o.selected=n),g(n)}),x("ngModelChange",function(){p(e);let n=a(4).$implicit,o=a();return g(o.onCheckboxStateProduct(n.ID))}),s()()}if(t&2){let e=a(4).$implicit;c(),E("ngModel",e.selected),d("disabled",!(e!=null&&e.Category))}}function ze(t,l){if(t&1&&u(0,je,2,2,"div"),t&2){let e=a(3).$implicit;h((e==null||e.Variants==null?null:e.Variants.length)>1?0:-1)}}function He(t,l){if(t&1){let e=C();r(0,"img",31),x("click",function(n){p(e);let o=a(3).$implicit,m=a();return g(m.onZoomImage(n,o==null?null:o.ImageUrl))}),s()}if(t&2){let e=a(3).$implicit;d("src",Y(e==null?null:e.ThumbnailUrl),y)}}function Ze(t,l){t&1&&w(0,"img",26)}function qe(t,l){if(t&1&&(r(0,"td",23)(1,"div",24),u(2,Le,1,3,null,12)(3,Ae,1,3,null,12),T(4,ze,1,1,"ng-template",null,0,ee),r(6,"div"),u(7,He,1,2,"img",25)(8,Ze,1,0,"img",26),s()()(),r(9,"td",27)(10,"div"),_(11),s(),r(12,"small",28),_(13),s()()),t&2){let e=a(2).$implicit,i=a();d("rowSpan",e==null?null:e.Variants.length),c(2),h(i.table()=="inventory"?2:3),c(5),h(e!=null&&e.ThumbnailUrl?7:8),c(2),d("rowSpan",e==null?null:e.Variants.length),c(2),F(e==null?null:e.Name),c(),d("ngClass",M(7,ke,!(e!=null&&e.Category))),c(),P("(",e!=null&&e.Category?e==null?null:e.Category:"Not Found In POS",")")}}function Ge(t,l){if(t&1&&(r(0,"a",22),w(1,"i",32),s()),t&2){let e=a().$implicit,i=a(2);d("href",i.hostName+"/menu/Products/Catalog/Variants/Info?ID="+(e==null?null:e.ID),y)}}function Ke(t,l){if(t&1){let e=C();r(0,"input",35),O("ngModelChange",function(n){p(e);let o=a(3).$implicit;return k(o.selected,n)||(o.selected=n),g(n)}),s()}if(t&2){let e=a(3).$implicit,i=a().$implicit;E("ngModel",e.selected),d("disabled",!(i!=null&&i.Category))}}function Xe(t,l){if(t&1&&(r(0,"td",33),u(1,Ke,1,2,"input",34),s()),t&2){let e=a(2).$implicit,i=a(2);c(),h(i.printPOS(e)>=0||i.table()=="price"?1:-1)}}function Ye(t,l){if(t&1&&(T(0,Xe,2,1,"ng-template",12),r(1,"td",19),_(2),U(3,"number"),s()),t&2){let e=a().$implicit,i=a(2);d("ngxPermissionsOnly",M(4,W,i.rolePriceEdit)),c(2),F(H(3,2,i.printPOS(e)))}}function Je(t,l){if(t&1){let e=C();r(0,"td",38),x("click",function(){p(e);let n=a().$implicit,o=a().$implicit,m=a().$implicit,f=a();return g(f.onUpdateData(m.Name,o,n.ID,m.ChannelItemID))}),r(1,"div",39)(2,"div",40),_(3),U(4,"number"),s(),r(5,"a",41),x("click",function(n){return p(e),g(n==null?null:n.stopPropagation())}),w(6,"i",32),s()()()}if(t&2){let e=l,i=a(2).$implicit,n=a(2);d("ngClass",J(5,Oe,n.printPOS(i)!=n.printItem(e)&&n.hiddenIPOSInventory()==!1,n.hasPriceEdit()&&n.table()=="price"||n.hasInventoryEdit()&&n.table()=="inventory")),c(3),P(" ",H(4,3,n.printItem(e))," "),c(2),d("href",e.Url,y)}}function Qe(t,l){t&1&&(r(0,"td",37)(1,"div",39)(2,"span"),_(3,"X"),s()()())}function et(t,l){if(t&1&&u(0,Je,7,8,"td",36)(1,Qe,4,0,"td",37),t&2){let e,i=l.$implicit,n=a().$implicit,o=a(2);h((e=o.getItemFromChannel(n,i))?0:1,e)}}function tt(t,l){if(t&1&&(r(0,"tr"),u(1,qe,14,9),r(2,"td",18),_(3),s(),r(4,"td",19)(5,"div",20)(6,"div",21),_(7),s(),r(8,"div",17),u(9,Ge,2,1,"a",22),s()()(),u(10,Ye,4,6),v(11,et,2,1,null,null,I),s()),t&2){let e=l.$implicit,i=l.$index,n=a().$implicit,o=a();c(),h(i==0?1:-1),c(2),F(e==null?null:e.Model),c(2),d("matTooltip",e.Discontinued?o.discontinuedVariantMsg:""),c(),d("ngClass",M(7,Ee,e.Discontinued)),c(),P(" ",e.Code," "),c(2),h(n.Category?9:-1),c(),h(o.hiddenIPOSInventory()==!1?10:-1),c(),S(o.channel())}}function nt(t,l){if(t&1&&(r(0,"tbody"),v(1,tt,13,9,"tr",null,I),s()),t&2){let e=l.$implicit;c(),S(e.Variants)}}var Nt=(()=>{let l=class l{constructor(){this.dialog=b(ue),this.biggerPictureService=b(fe),this.authService=b(se),this.permissionsService=b(ae),this.table=V(void 0),this.channel=V(void 0),this.showProductToggle=V(!1),this.multiwarehouse=V(!1),this.hiddenIPOSInventory=V(!1),this.toggleStatus=!1,this.checkboxState=!1,this.rolePriceEdit=D.PriceUpdate,this.roleInventoryUpdate=D.InventoryUpdate,this.hasPriceEdit=R(!1),this.hasInventoryEdit=R(!1),this.discontinuedVariantMsg="This Variant is discontinued from POS, you must Non Active manually at the seller center so that it is not sold again on the channel.",this.onSubmit=new A,this.destroy$=new q,this.toggle=new A,this.hostName=this.authService.getDomain()}ngOnInit(){this.initRoles();let i=this.table();i=="inventory"?this.stockHeader="Stock":i=="price"&&(this.stockHeader="Price")}initRoles(){this.permissionsService.hasPermission(D.InventoryUpdate).then(i=>this.hasInventoryEdit.set(i)),this.permissionsService.hasPermission(D.PriceUpdate).then(i=>this.hasPriceEdit.set(i))}onCheckboxStateProduct(i){let n=this.data.filter(o=>o.ID==i);n.length>0&&(n=n.map(o=>(o.Variants=o.Variants.map(m=>(m.selected=o.selected,m)),o)))}onCheckboxStateChange(){this.data=this.data.map(i=>(i.Variants=i.Variants.map(n=>(n.selected=this.checkboxState,n)),i))}getItemFromChannel(i,n){return i.Channel.find(m=>Z.IsNotEmpty(n.LocationID)?m.LocationID==n.LocationID:m.ChannelID==n.ID)}printItem(i){let n=this.table();if(n=="inventory")return i.Inventory;if(n=="price")return i.Price}onUpdateData(i,n,o,m){let f=this.table();this.hasPriceEdit()&&f=="price"&&this.onOpenDialogUpdate(i,n,o,m),this.hasInventoryEdit()&&f=="inventory"&&this.onOpenDialogUpdate(i,n,o,m)}onOpenDialogUpdate(i,n,o,m){this.dialog.open(Se,{data:{Name:i,Variant:n,ChannelID:o,Table:this.table(),ChannelItemID:m}}).afterClosed().pipe(G(f=>Z.IsNotEmpty(f)),K(this.destroy$)).subscribe(f=>{this.onSubmit.emit(f)})}printPOS(i){let n=this.table();return n=="inventory"?i.Inventory?i.Inventory:0:n=="price"?i.UnitPrice:null}onToggle(){this.toggle.emit(this.toggleStatus)}onZoomImage(i,n){this.biggerPictureService.openBiggerPicture(i,n)}ngOnDestroy(){this.destroy$.next(!0),this.destroy$.complete()}};l.\u0275fac=function(n){return new(n||l)},l.\u0275cmp=N({type:l,selectors:[["app-table"]],inputs:{data:"data",table:[1,"table"],channel:[1,"channel"],showProductToggle:[1,"showProductToggle"],productToggleTitle:"productToggleTitle",multiwarehouse:[1,"multiwarehouse"],hiddenIPOSInventory:[1,"hiddenIPOSInventory"]},outputs:{onSubmit:"onSubmit",toggle:"onToggle"},decls:18,vars:2,consts:[["checkbox_update",""],[1,"table-responsive"],[1,"table"],[1,"thead-light","sticky-top-thead"],["scope","col","colspan","2",1,"text-center","w-25"],[1,"w-100"],[2,"width","200px"],["scope","col",1,"text-start","w-20"],["scope","col",1,"text-end","w-10"],["scope","col"],[2,"width","200px",3,"toggleChange"],[1,"fw-bold"],[3,"ngxPermissionsOnly"],["type","checkbox",3,"ngModelChange","ngModel"],[1,"w-100","d-flex","align-items-center","justify-content-center"],["matTooltipPosition","above",1,"d-flex","align-items-center","justify-content-center",2,"width","180px",3,"matTooltip"],[2,"width","16px","height","16px",3,"src"],[1,"ms-2"],[1,"text-start"],[1,"text-end"],["matTooltipPosition","above",1,"d-flex","align-items-center","justify-content-end",3,"matTooltip"],[3,"ngClass"],["target","_blank",3,"href"],[1,"text-center",3,"rowSpan"],[1,"d-flex","align-items-center","justify-content-end"],[1,"border","rounded","w-img","cursor-pointer",3,"src"],["src","//res.cloudinary.com/pos/image/upload/w_40/POS/Images/Icon/products_thumb.png",1,"border","rounded","w-img"],[1,"text-start",2,"padding-left","0px",3,"rowSpan"],[1,"mt-1",3,"ngClass"],[4,"ngTemplateOutlet"],["type","checkbox",1,"me-3",3,"ngModelChange","ngModel","disabled"],[1,"border","rounded","w-img","cursor-pointer",3,"click","src"],[1,"fas","fa-solid","fa-arrow-up-right-from-square","external-link-custom"],[1,"align-middle"],["type","checkbox",3,"ngModel","disabled"],["type","checkbox",3,"ngModelChange","ngModel","disabled"],[1,"p-0",3,"ngClass"],[1,"table-white","text-center",2,"color","red"],[1,"p-0",3,"click","ngClass"],[1,"d-flex","align-items-center","justify-content-center"],[1,"me-2","mt-1"],["target","_blank",3,"click","href"]],template:function(n,o){n&1&&(r(0,"div",1)(1,"table",2)(2,"thead",3)(3,"tr")(4,"th",4)(5,"div",5)(6,"div"),_(7,"Product"),s(),u(8,Ve,3,1,"mat-slide-toggle",6),s()(),r(9,"th",7),_(10,"Variant"),s(),r(11,"th",8),_(12,"SKU"),s(),u(13,Ne,3,3),v(14,Ue,7,6,"th",9,X),s()(),v(16,nt,3,0,"tbody",null,I),s()()),n&2&&(c(8),h(o.showProductToggle()?8:-1),c(5),h(o.hiddenIPOSInventory()==!1?13:-1),c(),S(o.channel()),c(2),S(o.data))},dependencies:[oe,te,ne,L,de,$,B,ye,Te,he,le,be,ce,re,_e,me,ie,we],styles:[".w-10[_ngcontent-%COMP%]{width:10%}.w-20[_ngcontent-%COMP%]{width:20%}.w-img[_ngcontent-%COMP%]{width:40px;height:40px}.item-name[_ngcontent-%COMP%]{margin-bottom:-14px!important;font-size:larger}.cell-hover[_ngcontent-%COMP%]:hover{background-color:#c9c9c9!important}.text-wrapping[_ngcontent-%COMP%]{text-overflow:ellipsis;white-space:nowrap;overflow:hidden;width:88px}.cell-hover[_ngcontent-%COMP%]{width:400px!important}"]});let t=l;return t})();export{dt as a,Nt as b};
@@ -1 +1 @@
1
- import{a as re,b as pe}from"./chunk-AHMFSCTX.js";import"./chunk-6F62N7RZ.js";import"./chunk-LR2YCE6M.js";import{a as ne,b as ie,d as ae,e as oe}from"./chunk-C2LAQOUW.js";import{a as le}from"./chunk-27DIE2YS.js";import{b as te}from"./chunk-BUMWMFHU.js";import"./chunk-ROS2QMKF.js";import"./chunk-5WT456T7.js";import"./chunk-YNL43MLU.js";import"./chunk-SPLGZRGH.js";import"./chunk-2ST3DMR6.js";import"./chunk-24KZDZKS.js";import"./chunk-A2RTZANN.js";import"./chunk-N3E43QWK.js";import"./chunk-YD6BNJ2B.js";import"./chunk-XUDE7VBC.js";import"./chunk-X52ZT4MU.js";import"./chunk-BMOMTOEW.js";import"./chunk-HO2TMGLM.js";import"./chunk-O4D64GHO.js";import"./chunk-7R2D2JZ6.js";import{h as X}from"./chunk-QMQCIH3X.js";import"./chunk-YYV4FSYQ.js";import"./chunk-QXRG5XYP.js";import"./chunk-AGBJEXIM.js";import"./chunk-5UFP37GQ.js";import{c as K}from"./chunk-UPRDDI4K.js";import{A as ee,h as Y,m as Z}from"./chunk-WAXAIL2I.js";import"./chunk-RQUCYFCB.js";import"./chunk-RXLMJGUY.js";import{e as Q}from"./chunk-MM7SAZOU.js";import"./chunk-NQLMPUSB.js";import"./chunk-OSGPJXJZ.js";import{A as G,w as k,x as H,y as U}from"./chunk-JNRCB7N3.js";import"./chunk-XBIHN6D3.js";import{Hb as B,Nb as P,Nc as s,Oc as f,Pc as y,Rc as z,Sc as A,Tc as V,Z as D,_c as J,aa as M,ac as R,bc as T,cc as $,dc as F,fc as j,g as L,gc as O,hc as h,ic as a,id as c,jc as o,jd as d,kc as u,kd as W,ma as w,mb as S,ob as p,ra as g,rc as q,v as I,wc as v,ya as E,yc as x,za as N}from"./chunk-OHGMB7HJ.js";import"./chunk-WFMAM73Y.js";import{a as _}from"./chunk-66YHNWRR.js";var b=(()=>{let t=class t{constructor(){this.httpService=g(Q),this._pageination=new L({PageNumber:1,RowCount:100,ChannelID:null}),this.filter$=this._pageination.asObservable(),this.log$=this.filter$.pipe(M(n=>this.getLogs$(n).pipe()))}getLogs$(n){return this.httpService.post("/api/Channel/GetChannelLogPaged",n)}onPaginationChange(n){let e=this._pageination.value;e.PageNumber=n.pageIndex+1,this._pageination.next(e)}onFilter(n){let e=this._pageination.value;e.PageNumber=1,e=_(_({},e),n),this._pageination.next(e)}};t.\u0275fac=function(e){return new(e||t)},t.\u0275prov=w({token:t,factory:t.\u0275fac});let i=t;return i})();function se(i,t){if(i&1&&(a(0,"span",10),u(1,"img",11),o(),s(2)),i&2){let l=t.item;p(),h("src",l.Img,S)("alt",l.Name),p(),y(" ",l.Name," ")}}function ce(i,t){if(i&1&&(a(0,"tr")(1,"td"),u(2,"img",17),a(3,"span"),s(4),o()(),a(5,"td")(6,"span",18),s(7),c(8,"json"),o()(),a(9,"td"),s(10),c(11,"json"),o(),a(12,"td"),s(13),c(14,"date"),o()()),i&2){let l=t.$implicit;p(2),h("src",l.Img,S),p(2),y(" ",l.ChannelName," "),p(3),f(d(8,5,l.Request)),p(3),f(d(11,7,l.Response)),p(3),f(W(14,9,l.Created,"dd-MM-yyyy hh:mm:ss"))}}function de(i,t){if(i&1){let l=q();a(0,"div",8)(1,"table",12)(2,"thead")(3,"tr",13)(4,"th",14),s(5,"Channel"),o(),a(6,"th"),s(7,"Request"),o(),a(8,"th"),s(9,"Response"),o(),a(10,"th",15),s(11,"Created"),o()()(),a(12,"tbody"),j(13,ce,15,12,"tr",null,F),c(15,"async"),o()(),a(16,"mat-paginator",16),c(17,"async"),c(18,"async"),c(19,"async"),c(20,"async"),v("page",function(e){E(l);let r=x();return N(r.channelLogService.onPaginationChange(e))}),o()()}if(i&2){let l,n,e,r,m=x();p(13),O((l=d(15,3,m.channelLogs$))==null?null:l.Data),p(3),h("length",(n=d(17,5,m.channelLogs$))==null?null:n.Count)("pageSize",(e=d(18,7,m.filter$))==null?null:e.RowCount)("pageIndex",(r=d(19,9,m.filter$))!=null&&r.PageNumber?0:((r=d(20,11,m.filter$))==null?null:r.PageNumber)-1)}}function he(i,t){i&1&&(a(0,"div",9),u(1,"app-empty-state"),o())}var je=(()=>{let t=class t{constructor(){this.channelLogService=g(b),this.authService=g(X),this.channelOptions=this.authService.getChannels(),this.channelLogs$=this.channelLogService.log$.pipe(I(n=>(n.Data?n.Data=n.Data.map(e=>(e.Response=e.Response?JSON.parse(e.Response):"",e.Request=e.Request?JSON.parse(e.Request):"",e.Img=K.getChannelLogoByTypeId(e.TypeID),e)):n.Data=[],n)),D(1)),this.filter$=this.channelLogService.filter$}onSubmitFilter(){this.channelLogService.onFilter({ChannelID:this.channelID})}};t.\u0275fac=function(e){return new(e||t)},t.\u0275cmp=B({type:t,selectors:[["app-channel-log"]],features:[J([b])],decls:15,vars:7,consts:[["headerTitle","Authorization Log",3,"onSubmit","hideSearchBox"],["container",""],[1,"fw-bold","mb-2"],["appendTo","body","bindLabel","Name","name","channelid","bindValue","ID","placeholder","Select Channel",1,"center-text",3,"ngModelChange","clearable","items","ngModel"],["ng-option-tmp","","ng-label-tmp",""],[1,"container-fluid","mt-3"],[1,"row"],[1,"col-md-12"],[1,"table-responsive"],[1,"d-flex","flex-column","justify-content-center","align-items-center",2,"margin-top","26vh"],[1,"me-2"],[2,"width","18px",3,"src","alt"],[1,"table","table-hover"],[1,"table-light"],[2,"width","250px"],[2,"width","150px"],[3,"page","length","pageSize","pageIndex"],[1,"me-2",2,"width","25px",3,"src"],[1,""]],template:function(e,r){if(e&1&&(a(0,"mainpanel",0),v("onSubmit",function(){return r.onSubmitFilter()}),a(1,"filters")(2,"div",1)(3,"div")(4,"label",2),s(5,"Channel"),o(),a(6,"ng-select",3),V("ngModelChange",function(C){return A(r.channelID,C)||(r.channelID=C),C}),P(7,se,3,3,"ng-template",4),o()()()(),a(8,"content")(9,"div",5)(10,"div",6)(11,"div",7),R(12,de,21,13,"div",8),c(13,"async"),T(14,he,2,0,"div",9),o()()()()()),e&2){let m;h("hideSearchBox",!0),p(6),h("clearable",!0)("items",r.channelOptions),z("ngModel",r.channelID),p(6),$(((m=d(13,5,r.channelLogs$))==null||m.Data==null?null:m.Data.length)>0?12:14)}},dependencies:[G,te,le,pe,re,oe,ae,ne,ie,ee,Y,Z,k,U,H],encapsulation:2});let i=t;return i})();export{je as ChannelLogComponent};
1
+ import{a as re,b as pe}from"./chunk-AHMFSCTX.js";import"./chunk-6F62N7RZ.js";import"./chunk-LR2YCE6M.js";import{a as ne,b as ie,d as ae,e as oe}from"./chunk-C2LAQOUW.js";import{a as le}from"./chunk-27DIE2YS.js";import{b as te}from"./chunk-BUMWMFHU.js";import"./chunk-ROS2QMKF.js";import"./chunk-5WT456T7.js";import"./chunk-YNL43MLU.js";import"./chunk-SPLGZRGH.js";import"./chunk-2ST3DMR6.js";import"./chunk-24KZDZKS.js";import"./chunk-A2RTZANN.js";import"./chunk-N3E43QWK.js";import"./chunk-YD6BNJ2B.js";import"./chunk-XUDE7VBC.js";import"./chunk-X52ZT4MU.js";import"./chunk-BMOMTOEW.js";import"./chunk-HO2TMGLM.js";import"./chunk-O4D64GHO.js";import"./chunk-7R2D2JZ6.js";import{h as X}from"./chunk-O3QPBAV5.js";import"./chunk-YYV4FSYQ.js";import"./chunk-QXRG5XYP.js";import"./chunk-AGBJEXIM.js";import"./chunk-5UFP37GQ.js";import{c as K}from"./chunk-UPRDDI4K.js";import{A as ee,h as Y,m as Z}from"./chunk-WAXAIL2I.js";import"./chunk-RQUCYFCB.js";import"./chunk-RXLMJGUY.js";import{e as Q}from"./chunk-MM7SAZOU.js";import"./chunk-NQLMPUSB.js";import"./chunk-OSGPJXJZ.js";import{A as G,w as k,x as H,y as U}from"./chunk-JNRCB7N3.js";import"./chunk-XBIHN6D3.js";import{Hb as B,Nb as P,Nc as s,Oc as f,Pc as y,Rc as z,Sc as A,Tc as V,Z as D,_c as J,aa as M,ac as R,bc as T,cc as $,dc as F,fc as j,g as L,gc as O,hc as h,ic as a,id as c,jc as o,jd as d,kc as u,kd as W,ma as w,mb as S,ob as p,ra as g,rc as q,v as I,wc as v,ya as E,yc as x,za as N}from"./chunk-OHGMB7HJ.js";import"./chunk-WFMAM73Y.js";import{a as _}from"./chunk-66YHNWRR.js";var b=(()=>{let t=class t{constructor(){this.httpService=g(Q),this._pageination=new L({PageNumber:1,RowCount:100,ChannelID:null}),this.filter$=this._pageination.asObservable(),this.log$=this.filter$.pipe(M(n=>this.getLogs$(n).pipe()))}getLogs$(n){return this.httpService.post("/api/Channel/GetChannelLogPaged",n)}onPaginationChange(n){let e=this._pageination.value;e.PageNumber=n.pageIndex+1,this._pageination.next(e)}onFilter(n){let e=this._pageination.value;e.PageNumber=1,e=_(_({},e),n),this._pageination.next(e)}};t.\u0275fac=function(e){return new(e||t)},t.\u0275prov=w({token:t,factory:t.\u0275fac});let i=t;return i})();function se(i,t){if(i&1&&(a(0,"span",10),u(1,"img",11),o(),s(2)),i&2){let l=t.item;p(),h("src",l.Img,S)("alt",l.Name),p(),y(" ",l.Name," ")}}function ce(i,t){if(i&1&&(a(0,"tr")(1,"td"),u(2,"img",17),a(3,"span"),s(4),o()(),a(5,"td")(6,"span",18),s(7),c(8,"json"),o()(),a(9,"td"),s(10),c(11,"json"),o(),a(12,"td"),s(13),c(14,"date"),o()()),i&2){let l=t.$implicit;p(2),h("src",l.Img,S),p(2),y(" ",l.ChannelName," "),p(3),f(d(8,5,l.Request)),p(3),f(d(11,7,l.Response)),p(3),f(W(14,9,l.Created,"dd-MM-yyyy hh:mm:ss"))}}function de(i,t){if(i&1){let l=q();a(0,"div",8)(1,"table",12)(2,"thead")(3,"tr",13)(4,"th",14),s(5,"Channel"),o(),a(6,"th"),s(7,"Request"),o(),a(8,"th"),s(9,"Response"),o(),a(10,"th",15),s(11,"Created"),o()()(),a(12,"tbody"),j(13,ce,15,12,"tr",null,F),c(15,"async"),o()(),a(16,"mat-paginator",16),c(17,"async"),c(18,"async"),c(19,"async"),c(20,"async"),v("page",function(e){E(l);let r=x();return N(r.channelLogService.onPaginationChange(e))}),o()()}if(i&2){let l,n,e,r,m=x();p(13),O((l=d(15,3,m.channelLogs$))==null?null:l.Data),p(3),h("length",(n=d(17,5,m.channelLogs$))==null?null:n.Count)("pageSize",(e=d(18,7,m.filter$))==null?null:e.RowCount)("pageIndex",(r=d(19,9,m.filter$))!=null&&r.PageNumber?0:((r=d(20,11,m.filter$))==null?null:r.PageNumber)-1)}}function he(i,t){i&1&&(a(0,"div",9),u(1,"app-empty-state"),o())}var je=(()=>{let t=class t{constructor(){this.channelLogService=g(b),this.authService=g(X),this.channelOptions=this.authService.getChannels(),this.channelLogs$=this.channelLogService.log$.pipe(I(n=>(n.Data?n.Data=n.Data.map(e=>(e.Response=e.Response?JSON.parse(e.Response):"",e.Request=e.Request?JSON.parse(e.Request):"",e.Img=K.getChannelLogoByTypeId(e.TypeID),e)):n.Data=[],n)),D(1)),this.filter$=this.channelLogService.filter$}onSubmitFilter(){this.channelLogService.onFilter({ChannelID:this.channelID})}};t.\u0275fac=function(e){return new(e||t)},t.\u0275cmp=B({type:t,selectors:[["app-channel-log"]],features:[J([b])],decls:15,vars:7,consts:[["headerTitle","Authorization Log",3,"onSubmit","hideSearchBox"],["container",""],[1,"fw-bold","mb-2"],["appendTo","body","bindLabel","Name","name","channelid","bindValue","ID","placeholder","Select Channel",1,"center-text",3,"ngModelChange","clearable","items","ngModel"],["ng-option-tmp","","ng-label-tmp",""],[1,"container-fluid","mt-3"],[1,"row"],[1,"col-md-12"],[1,"table-responsive"],[1,"d-flex","flex-column","justify-content-center","align-items-center",2,"margin-top","26vh"],[1,"me-2"],[2,"width","18px",3,"src","alt"],[1,"table","table-hover"],[1,"table-light"],[2,"width","250px"],[2,"width","150px"],[3,"page","length","pageSize","pageIndex"],[1,"me-2",2,"width","25px",3,"src"],[1,""]],template:function(e,r){if(e&1&&(a(0,"mainpanel",0),v("onSubmit",function(){return r.onSubmitFilter()}),a(1,"filters")(2,"div",1)(3,"div")(4,"label",2),s(5,"Channel"),o(),a(6,"ng-select",3),V("ngModelChange",function(C){return A(r.channelID,C)||(r.channelID=C),C}),P(7,se,3,3,"ng-template",4),o()()()(),a(8,"content")(9,"div",5)(10,"div",6)(11,"div",7),R(12,de,21,13,"div",8),c(13,"async"),T(14,he,2,0,"div",9),o()()()()()),e&2){let m;h("hideSearchBox",!0),p(6),h("clearable",!0)("items",r.channelOptions),z("ngModel",r.channelID),p(6),$(((m=d(13,5,r.channelLogs$))==null||m.Data==null?null:m.Data.length)>0?12:14)}},dependencies:[G,te,le,pe,re,oe,ae,ne,ie,ee,Y,Z,k,U,H],encapsulation:2});let i=t;return i})();export{je as ChannelLogComponent};