marketplacepos 5.46.1 → 5.46.2

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 (55) hide show
  1. package/Marketplace/{chunk-YB4KXB2C.js → chunk-3434HH7H.js} +1 -1
  2. package/Marketplace/{chunk-DZEO4HK4.js → chunk-3GRC47DP.js} +1 -1
  3. package/Marketplace/chunk-45FZJ4W3.js +1 -0
  4. package/Marketplace/{chunk-EI65NYTN.js → chunk-4DMKVXM7.js} +1 -1
  5. package/Marketplace/{chunk-FTWATKXK.js → chunk-4JQLXONG.js} +1 -1
  6. package/Marketplace/{chunk-6VYFG4AQ.js → chunk-6RMBCW2O.js} +1 -1
  7. package/Marketplace/{chunk-DB7C3AL2.js → chunk-6VZVNRUE.js} +2 -2
  8. package/Marketplace/{chunk-V6UNCLNJ.js → chunk-72OHPB5Q.js} +1 -1
  9. package/Marketplace/{chunk-3VUO4APC.js → chunk-7AZDAPB7.js} +1 -1
  10. package/Marketplace/{chunk-7DJXZQ7M.js → chunk-7F74QXF6.js} +1 -1
  11. package/Marketplace/{chunk-26ZM2UD3.js → chunk-7VLMA7MW.js} +1 -1
  12. package/Marketplace/{chunk-UGG2CIUU.js → chunk-A57T33JT.js} +1 -1
  13. package/Marketplace/{chunk-FB2AEPXA.js → chunk-AMYZMAYI.js} +1 -1
  14. package/Marketplace/{chunk-TGQ5CJ3A.js → chunk-B2WOBUES.js} +1 -1
  15. package/Marketplace/{chunk-4TDVVQ64.js → chunk-BDKGOINV.js} +1 -1
  16. package/Marketplace/{chunk-ZUYGRGXM.js → chunk-CBAQUD22.js} +1 -1
  17. package/Marketplace/{chunk-TE5EYKIN.js → chunk-CBJR2A72.js} +1 -1
  18. package/Marketplace/{chunk-NLPXBGIX.js → chunk-CIPLCKUF.js} +1 -1
  19. package/Marketplace/{chunk-HHO2NGCF.js → chunk-CWXOXH6M.js} +1 -1
  20. package/Marketplace/{chunk-4LZODV4E.js → chunk-FNU2TKTQ.js} +1 -1
  21. package/Marketplace/{chunk-T43QRQH5.js → chunk-FYRDNKYT.js} +1 -1
  22. package/Marketplace/{chunk-OAG6OVUY.js → chunk-GPX77ZSI.js} +1 -1
  23. package/Marketplace/{chunk-MJNFY4NT.js → chunk-GRQD4D2I.js} +1 -1
  24. package/Marketplace/{chunk-2XWZQCUR.js → chunk-HGZ5B6WR.js} +1 -1
  25. package/Marketplace/{chunk-2SGPD432.js → chunk-II5QZVLR.js} +1 -1
  26. package/Marketplace/{chunk-CRKCNTXF.js → chunk-LCZ6SUUA.js} +1 -1
  27. package/Marketplace/{chunk-FIAI5SPR.js → chunk-NDLOPOFD.js} +1 -1
  28. package/Marketplace/{chunk-JYCBJ7CC.js → chunk-OEAOBG75.js} +1 -1
  29. package/Marketplace/{chunk-6CIQBRO4.js → chunk-OHSVQSCM.js} +1 -1
  30. package/Marketplace/{chunk-VIDSOLHF.js → chunk-P5YM6T6I.js} +1 -1
  31. package/Marketplace/{chunk-KRQHTRFM.js → chunk-PE4SWUEZ.js} +1 -1
  32. package/Marketplace/{chunk-ORLTYLPA.js → chunk-PL3Q6PGC.js} +1 -1
  33. package/Marketplace/{chunk-6U4YIJLC.js → chunk-PLHWGG4D.js} +2 -2
  34. package/Marketplace/{chunk-OJZ7NGRW.js → chunk-Q2B5GUDO.js} +1 -1
  35. package/Marketplace/{chunk-GKRWJPI3.js → chunk-QSHR75ZI.js} +1 -1
  36. package/Marketplace/{chunk-ISUN5G42.js → chunk-QVP2CM7Y.js} +1 -1
  37. package/Marketplace/chunk-TM6DZ3ZF.js +1 -0
  38. package/Marketplace/{chunk-ZXTHWBJ4.js → chunk-UX3OTI5X.js} +1 -1
  39. package/Marketplace/{chunk-KCFCXS2F.js → chunk-V6GFM5AQ.js} +1 -1
  40. package/Marketplace/{chunk-ZVKOEYH7.js → chunk-WAKKUK6E.js} +1 -1
  41. package/Marketplace/chunk-WEYKQCVQ.js +1 -0
  42. package/Marketplace/{chunk-FHWKSD5A.js → chunk-WWLC64XZ.js} +1 -1
  43. package/Marketplace/{chunk-F2533PAC.js → chunk-XPBMYV5W.js} +1 -1
  44. package/Marketplace/{chunk-GPGD3XQH.js → chunk-XXAV6VNB.js} +1 -1
  45. package/Marketplace/{chunk-LOU3DIPY.js → chunk-YA3VMYDA.js} +1 -1
  46. package/Marketplace/{chunk-L7TKCTLD.js → chunk-YXBR6VYQ.js} +1 -1
  47. package/Marketplace/{chunk-M7LXGXUM.js → chunk-Z3J3CSGS.js} +1 -1
  48. package/Marketplace/{chunk-DSYYZDXI.js → chunk-Z67623R4.js} +1 -1
  49. package/Marketplace/{chunk-IWKRZSYG.js → chunk-ZLNAFA4X.js} +1 -1
  50. package/Marketplace/index.html +2 -2
  51. package/Marketplace/{main-RRL4BIVO.js → main-FUX6VJVF.js} +1 -1
  52. package/package.json +1 -1
  53. package/Marketplace/chunk-2Z7CPNRS.js +0 -1
  54. package/Marketplace/chunk-EFI2CLNP.js +0 -1
  55. package/Marketplace/chunk-KFOHH7PE.js +0 -1
@@ -1 +1 @@
1
- import{a as mt}from"./chunk-7KG3DC5J.js";import{b as lt}from"./chunk-6VYFG4AQ.js";import{a as st}from"./chunk-LDL3A7NM.js";import{i as it}from"./chunk-FHWKSD5A.js";import"./chunk-Z3ITXK3D.js";import"./chunk-ACIMXBIC.js";import"./chunk-TGMCGROM.js";import"./chunk-CGOB6Y3X.js";import{e as et}from"./chunk-WN5DZGA4.js";import"./chunk-4NEKWRL7.js";import{a as nt,b as ot,d as at,e as rt}from"./chunk-PYXL7UF7.js";import{c as tt}from"./chunk-PW42BQIY.js";import{m as ct,n as pt}from"./chunk-HJXYT6MI.js";import{A as Z,h as X,m as Y}from"./chunk-5PS6ZS3N.js";import"./chunk-V3USB3ZU.js";import"./chunk-ERXVXBTU.js";import"./chunk-MFQQEEHJ.js";import"./chunk-GZKOMS4T.js";import{H as K,J as Q,d as A,f as j,g as U,j as W,k as q,m as J,n as G}from"./chunk-FXQKRJWU.js";import{$c as s,Fc as R,Gb as L,Gc as l,Hc as N,Ic as y,Kc as $,Lc as O,Mb as d,Mc as V,Rc as B,Sc as k,Tc as H,Yb as c,Z as b,ad as u,bd as T,ca as D,cd as z,f as w,ic as n,jc as o,kc as v,lc as f,mc as g,ob as M,oc as P,pb as I,rb as a,tc as E,uc as m,v as _,xb as S,xc as F,ya as h,za as C}from"./chunk-OJMQBH6T.js";import"./chunk-EU2KAMEK.js";import"./chunk-66YHNWRR.js";var ft=(i,p)=>({"bg-gradient-danger":i,"bg-gradient-warning":p}),gt=()=>["/menu/products/status/notification/detail"],ut=i=>({ID:i});function _t(i,p){if(i&1&&(n(0,"span",15),v(1,"img",16),o(),l(2)),i&2){let t=p.item;a(),c("src",t.Img,I)("alt",t.Name),a(),y(" ",t.Name," ")}}function ht(i,p){if(i&1&&(f(0),l(1),s(2,"number"),n(3,"span"),l(4,"s"),o(),g()),i&2){let t=m().$implicit;a(),y(" ",T(2,1,t.DurationInSecond,"1.1-1")," ")}}function Ct(i,p){i&1&&l(0," - ")}function St(i,p){if(i&1&&(f(0),n(1,"tr",17)(2,"td")(3,"a",18),v(4,"img",19),n(5,"span"),l(6),o()()(),n(7,"td")(8,"b"),l(9),o(),v(10,"div",20),o(),n(11,"td"),d(12,ht,5,4,"ng-container",21)(13,Ct,1,0,"ng-template",null,0,z),o(),n(15,"td"),l(16),o(),n(17,"td"),l(18),s(19,"date"),o()(),g()),i&2){let t=p.$implicit,e=R(14);a(),c("ngClass",H(14,ft,t.Status==1,t.Status==0)),a(2),c("routerLink",B(17,gt))("queryParams",k(18,ut,t.ID)),a(),F("src",t.Img,I),a(2),N(t.Name),a(3),N(t.Label),a(),c("innerHTML",t.Message,M),a(2),c("ngIf",t.DurationInSecond)("ngIfElse",e),a(4),N(t.StatusLabel),a(2),y(" ",T(19,11,t.Created,"dd MMM yyyy HH:mm")," ")}}function vt(i,p){if(i&1){let t=P();f(0),n(1,"div",7)(2,"div",22)(3,"app-custom-paginator",23),s(4,"async"),s(5,"async"),E("total",function(){h(t);let r=m(2);return C(r.getRowCount())})("next",function(){h(t);let r=m(2);return C(r.getNotifications())})("previous",function(){h(t);let r=m(2);return C(r.getNotifications())}),o()()(),g()}if(i&2){let t=m().ngIf,e=m();a(3),c("filter",e.filter)("totaldata",t==null?null:t.length)("paginationTotal",u(4,4,e.rowCount$))("hasClicked",u(5,6,e.rowCount$))}}function Nt(i,p){if(i&1&&(f(0),d(1,vt,6,8,"ng-container",14),g()),i&2){let t=p.ngIf;a(),c("ngIf",t.length>0)}}var Ht=(()=>{class i{constructor(t,e,r){this.http=t,this.notificationService=e,this.authService=r,this.filter=new mt,this.destroy$=new w,this.channelOptions=r.getChannels()}ngOnInit(){this.notificationService.clearNotification(),this.initPageLoader(),this.subscribeNotification()}subscribeNotification(){this.notificationService.getNotification().pipe(D(this.destroy$)).subscribe(t=>{t.length>0&&(this.getNotifications(),this.notificationService.clearNotification())})}initPageLoader(){this.http.post("/api/notification/Load",{}).subscribe(t=>{this.filter=t.Filter,this.filter.PageSize=this.filter.RowCount,this.getNotifications()})}onFilter(){this.rowCount$=null,this.getNotifications()}getNotifications(){let t={ChannelID:this.filter.ChannelID,RowCount:this.filter.PageSize,PageNumber:this.filter.PageNumber};this.notifications$=this.http.post("/api/notification/Get",t).pipe(_(e=>e.Data),_(e=>(e=this.setChannelLogoToNotifications(e),e=this.setTimeToSecond(e),e)),b(1))}setTimeToSecond(t){return t=t.map(e=>(e.DurationInSecond=parseInt(e.Duration)/1e3,e)),t}setChannelLogoToNotifications(t){return t=t.map(e=>(e.Img=tt.getChannelLogoByTypeId(e.TypeID),e)),t}getRowCount(){let t={ChannelID:this.filter.ChannelID};this.rowCount$=this.http.post("/api/notification/RowCount",t).pipe(_(e=>e.Count),b(1))}ngOnDestroy(){this.destroy$.next(!0),this.destroy$.complete()}static{this.\u0275fac=function(e){return new(e||i)(S(et),S(lt),S(it))}}static{this.\u0275cmp=L({type:i,selectors:[["app-notification"]],decls:33,vars:9,consts:[["timeNotAvailable",""],["headerTitle","Product Scan Job","hideSearchBox","true",3,"onSubmit"],["routerLink","/menu/products/status/notificationV2",1,"btn","btn-outline-secondary","btn-lg"],[1,"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,"table","table-hover"],[1,"sticky-top-thead"],[1,"table-light"],[4,"ngFor","ngForOf"],[4,"ngIf"],[1,"me-2"],[2,"width","18px",3,"src","alt"],[3,"ngClass"],[3,"routerLink","queryParams"],["alt","",1,"channelLogo-md","me-4",3,"src"],[3,"innerHTML"],[4,"ngIf","ngIfElse"],[1,"col-12"],[3,"total","next","previous","filter","totaldata","paginationTotal","hasClicked"]],template:function(e,r){e&1&&(n(0,"mainpanel",1),E("onSubmit",function(){return r.onFilter()}),n(1,"actions")(2,"a",2),l(3," Job Scan V2 "),o()(),n(4,"filters")(5,"div")(6,"h6",3),l(7,"Channel"),o(),n(8,"ng-select",4),V("ngModelChange",function(x){return O(r.filter.ChannelID,x)||(r.filter.ChannelID=x),x}),d(9,_t,3,3,"ng-template",5),o()()(),n(10,"content")(11,"div",6)(12,"div",7)(13,"div",8)(14,"div",9)(15,"table",10)(16,"thead",11)(17,"tr",12)(18,"th"),l(19,"Channel"),o(),n(20,"th"),l(21,"Process"),o(),n(22,"th"),l(23,"Duration"),o(),n(24,"th"),l(25,"Status"),o(),n(26,"th"),l(27,"Created"),o()()(),n(28,"tbody"),d(29,St,20,20,"ng-container",13),s(30,"async"),o()()()()(),d(31,Nt,2,1,"ng-container",14),s(32,"async"),o()()()),e&2&&(a(8),c("clearable",!0)("items",r.channelOptions),$("ngModel",r.filter.ChannelID),a(21),c("ngForOf",u(30,5,r.notifications$)),a(2),c("ngIf",u(32,7,r.notifications$)))},dependencies:[G,A,j,U,W,J,q,Z,X,Y,pt,ct,st,rt,at,nt,ot,Q,K],encapsulation:2})}}return i})();export{Ht as NotificationComponent};
1
+ import{a as mt}from"./chunk-7KG3DC5J.js";import{b as lt}from"./chunk-6RMBCW2O.js";import{a as st}from"./chunk-LDL3A7NM.js";import{i as it}from"./chunk-WWLC64XZ.js";import"./chunk-Z3ITXK3D.js";import"./chunk-ACIMXBIC.js";import"./chunk-TGMCGROM.js";import"./chunk-CGOB6Y3X.js";import{e as et}from"./chunk-WN5DZGA4.js";import"./chunk-4NEKWRL7.js";import{a as nt,b as ot,d as at,e as rt}from"./chunk-PYXL7UF7.js";import{c as tt}from"./chunk-PW42BQIY.js";import{m as ct,n as pt}from"./chunk-HJXYT6MI.js";import{A as Z,h as X,m as Y}from"./chunk-5PS6ZS3N.js";import"./chunk-V3USB3ZU.js";import"./chunk-ERXVXBTU.js";import"./chunk-MFQQEEHJ.js";import"./chunk-GZKOMS4T.js";import{H as K,J as Q,d as A,f as j,g as U,j as W,k as q,m as J,n as G}from"./chunk-FXQKRJWU.js";import{$c as s,Fc as R,Gb as L,Gc as l,Hc as N,Ic as y,Kc as $,Lc as O,Mb as d,Mc as V,Rc as B,Sc as k,Tc as H,Yb as c,Z as b,ad as u,bd as T,ca as D,cd as z,f as w,ic as n,jc as o,kc as v,lc as f,mc as g,ob as M,oc as P,pb as I,rb as a,tc as E,uc as m,v as _,xb as S,xc as F,ya as h,za as C}from"./chunk-OJMQBH6T.js";import"./chunk-EU2KAMEK.js";import"./chunk-66YHNWRR.js";var ft=(i,p)=>({"bg-gradient-danger":i,"bg-gradient-warning":p}),gt=()=>["/menu/products/status/notification/detail"],ut=i=>({ID:i});function _t(i,p){if(i&1&&(n(0,"span",15),v(1,"img",16),o(),l(2)),i&2){let t=p.item;a(),c("src",t.Img,I)("alt",t.Name),a(),y(" ",t.Name," ")}}function ht(i,p){if(i&1&&(f(0),l(1),s(2,"number"),n(3,"span"),l(4,"s"),o(),g()),i&2){let t=m().$implicit;a(),y(" ",T(2,1,t.DurationInSecond,"1.1-1")," ")}}function Ct(i,p){i&1&&l(0," - ")}function St(i,p){if(i&1&&(f(0),n(1,"tr",17)(2,"td")(3,"a",18),v(4,"img",19),n(5,"span"),l(6),o()()(),n(7,"td")(8,"b"),l(9),o(),v(10,"div",20),o(),n(11,"td"),d(12,ht,5,4,"ng-container",21)(13,Ct,1,0,"ng-template",null,0,z),o(),n(15,"td"),l(16),o(),n(17,"td"),l(18),s(19,"date"),o()(),g()),i&2){let t=p.$implicit,e=R(14);a(),c("ngClass",H(14,ft,t.Status==1,t.Status==0)),a(2),c("routerLink",B(17,gt))("queryParams",k(18,ut,t.ID)),a(),F("src",t.Img,I),a(2),N(t.Name),a(3),N(t.Label),a(),c("innerHTML",t.Message,M),a(2),c("ngIf",t.DurationInSecond)("ngIfElse",e),a(4),N(t.StatusLabel),a(2),y(" ",T(19,11,t.Created,"dd MMM yyyy HH:mm")," ")}}function vt(i,p){if(i&1){let t=P();f(0),n(1,"div",7)(2,"div",22)(3,"app-custom-paginator",23),s(4,"async"),s(5,"async"),E("total",function(){h(t);let r=m(2);return C(r.getRowCount())})("next",function(){h(t);let r=m(2);return C(r.getNotifications())})("previous",function(){h(t);let r=m(2);return C(r.getNotifications())}),o()()(),g()}if(i&2){let t=m().ngIf,e=m();a(3),c("filter",e.filter)("totaldata",t==null?null:t.length)("paginationTotal",u(4,4,e.rowCount$))("hasClicked",u(5,6,e.rowCount$))}}function Nt(i,p){if(i&1&&(f(0),d(1,vt,6,8,"ng-container",14),g()),i&2){let t=p.ngIf;a(),c("ngIf",t.length>0)}}var Ht=(()=>{class i{constructor(t,e,r){this.http=t,this.notificationService=e,this.authService=r,this.filter=new mt,this.destroy$=new w,this.channelOptions=r.getChannels()}ngOnInit(){this.notificationService.clearNotification(),this.initPageLoader(),this.subscribeNotification()}subscribeNotification(){this.notificationService.getNotification().pipe(D(this.destroy$)).subscribe(t=>{t.length>0&&(this.getNotifications(),this.notificationService.clearNotification())})}initPageLoader(){this.http.post("/api/notification/Load",{}).subscribe(t=>{this.filter=t.Filter,this.filter.PageSize=this.filter.RowCount,this.getNotifications()})}onFilter(){this.rowCount$=null,this.getNotifications()}getNotifications(){let t={ChannelID:this.filter.ChannelID,RowCount:this.filter.PageSize,PageNumber:this.filter.PageNumber};this.notifications$=this.http.post("/api/notification/Get",t).pipe(_(e=>e.Data),_(e=>(e=this.setChannelLogoToNotifications(e),e=this.setTimeToSecond(e),e)),b(1))}setTimeToSecond(t){return t=t.map(e=>(e.DurationInSecond=parseInt(e.Duration)/1e3,e)),t}setChannelLogoToNotifications(t){return t=t.map(e=>(e.Img=tt.getChannelLogoByTypeId(e.TypeID),e)),t}getRowCount(){let t={ChannelID:this.filter.ChannelID};this.rowCount$=this.http.post("/api/notification/RowCount",t).pipe(_(e=>e.Count),b(1))}ngOnDestroy(){this.destroy$.next(!0),this.destroy$.complete()}static{this.\u0275fac=function(e){return new(e||i)(S(et),S(lt),S(it))}}static{this.\u0275cmp=L({type:i,selectors:[["app-notification"]],decls:33,vars:9,consts:[["timeNotAvailable",""],["headerTitle","Product Scan Job","hideSearchBox","true",3,"onSubmit"],["routerLink","/menu/products/status/notificationV2",1,"btn","btn-outline-secondary","btn-lg"],[1,"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,"table","table-hover"],[1,"sticky-top-thead"],[1,"table-light"],[4,"ngFor","ngForOf"],[4,"ngIf"],[1,"me-2"],[2,"width","18px",3,"src","alt"],[3,"ngClass"],[3,"routerLink","queryParams"],["alt","",1,"channelLogo-md","me-4",3,"src"],[3,"innerHTML"],[4,"ngIf","ngIfElse"],[1,"col-12"],[3,"total","next","previous","filter","totaldata","paginationTotal","hasClicked"]],template:function(e,r){e&1&&(n(0,"mainpanel",1),E("onSubmit",function(){return r.onFilter()}),n(1,"actions")(2,"a",2),l(3," Scan Job V2 "),o()(),n(4,"filters")(5,"div")(6,"h6",3),l(7,"Channel"),o(),n(8,"ng-select",4),V("ngModelChange",function(x){return O(r.filter.ChannelID,x)||(r.filter.ChannelID=x),x}),d(9,_t,3,3,"ng-template",5),o()()(),n(10,"content")(11,"div",6)(12,"div",7)(13,"div",8)(14,"div",9)(15,"table",10)(16,"thead",11)(17,"tr",12)(18,"th"),l(19,"Channel"),o(),n(20,"th"),l(21,"Process"),o(),n(22,"th"),l(23,"Duration"),o(),n(24,"th"),l(25,"Status"),o(),n(26,"th"),l(27,"Created"),o()()(),n(28,"tbody"),d(29,St,20,20,"ng-container",13),s(30,"async"),o()()()()(),d(31,Nt,2,1,"ng-container",14),s(32,"async"),o()()()),e&2&&(a(8),c("clearable",!0)("items",r.channelOptions),$("ngModel",r.filter.ChannelID),a(21),c("ngForOf",u(30,5,r.notifications$)),a(2),c("ngIf",u(32,7,r.notifications$)))},dependencies:[G,A,j,U,W,J,q,Z,X,Y,pt,ct,st,rt,at,nt,ot,Q,K],encapsulation:2})}}return i})();export{Ht as NotificationComponent};
@@ -1 +1 @@
1
- import{a as pe,b as me,c as de}from"./chunk-UHJEXTOG.js";import{a as ce}from"./chunk-ZVKOEYH7.js";import{a as T}from"./chunk-GKRWJPI3.js";import{a as se}from"./chunk-67HPC5Y3.js";import{a as oe}from"./chunk-OLANEXLB.js";import"./chunk-PFY5UG5D.js";import"./chunk-KS7ACI26.js";import"./chunk-3GDM5JNY.js";import"./chunk-XXT6F2ZS.js";import"./chunk-QS22J2SC.js";import"./chunk-EHUVS2VB.js";import"./chunk-IHSGQFDX.js";import"./chunk-MO53T3IK.js";import"./chunk-W3JTS22H.js";import"./chunk-SDUUFQUI.js";import"./chunk-6L7TD5DW.js";import"./chunk-6OMSPZZC.js";import"./chunk-3RK6DDJD.js";import"./chunk-HIC5QC3Y.js";import"./chunk-JBT7GBCM.js";import"./chunk-JVNHFIYT.js";import{a as le}from"./chunk-HHO2NGCF.js";import"./chunk-3YP6ORBR.js";import{a as ae}from"./chunk-LDL3A7NM.js";import"./chunk-FHWKSD5A.js";import"./chunk-Z3ITXK3D.js";import"./chunk-ACIMXBIC.js";import"./chunk-TGMCGROM.js";import"./chunk-CGOB6Y3X.js";import"./chunk-WN5DZGA4.js";import"./chunk-4NEKWRL7.js";import"./chunk-PYXL7UF7.js";import"./chunk-PW42BQIY.js";import{m as ne,n as re}from"./chunk-HJXYT6MI.js";import{A as ee,c as X,h as Y,m as Z,o as $}from"./chunk-5PS6ZS3N.js";import"./chunk-V3USB3ZU.js";import"./chunk-ERXVXBTU.js";import{r as te,s as ie}from"./chunk-MFQQEEHJ.js";import"./chunk-GZKOMS4T.js";import{j as G,k as J,m as K,n as Q}from"./chunk-FXQKRJWU.js";import{$c as w,Gb as W,Gc as l,Hc as v,Ic as b,Kc as _,Lc as g,Mb as x,Mc as f,Nc as z,Oc as A,Pc as R,Qc as H,Ra as N,Rc as j,Sc as U,Yb as c,ac as I,ad as E,bd as q,dc as y,ec as D,gc as B,hc as k,ic as t,jc as i,kc as u,oc as V,pa as O,pb as F,rb as o,tc as M,uc as h,ya as m,za as d}from"./chunk-OJMQBH6T.js";import"./chunk-EU2KAMEK.js";import{a as P,b as L}from"./chunk-66YHNWRR.js";var ue=()=>[],he=r=>({"td-cell-hover":r});function _e(r,S){if(r&1&&u(0,"variants-dropdown",31),r&2){let e=h().$implicit;c("variants",e==null?null:e.Variants)}}function ge(r,S){if(r&1&&u(0,"variant-with-image",32),r&2){let e=h().$implicit;c("variant",e==null?null:e.Variants[0])}}function fe(r,S){if(r&1&&(t(0,"span"),l(1),i()),r&2){let e=h().$implicit;o(),b("(",e.LogisticService==null?null:e.LogisticService.Option,")")}}function Se(r,S){if(r&1&&(t(0,"tr")(1,"td")(2,"div",24),u(3,"img",25),w(4,"channelImage"),t(5,"div",26)(6,"div"),l(7),i(),t(8,"small",27)(9,"span"),l(10),i()()()()(),t(11,"td")(12,"div",28)(13,"div",29)(14,"div"),u(15,"order-link",30),i()(),t(16,"small"),l(17),w(18,"date"),i()()(),t(19,"td"),l(20),i(),t(21,"td"),x(22,_e,1,1,"variants-dropdown",31)(23,ge,1,1,"variant-with-image",32),i(),t(24,"td",33),l(25),w(26,"number"),i(),t(27,"td")(28,"div",28)(29,"div",29)(30,"span"),l(31),i(),x(32,fe,2,1,"span"),i(),t(33,"small"),l(34),i()()()()),r&2){let e=S.$implicit;o(3),c("src",E(4,14,e==null?null:e.MarketType),F)("alt",e==null||e.Variants[0]==null?null:e.Variants[0].Name),o(4),v(e.Outlet),o(3),v(e.ChannelName),o(5),c("order",e),o(2),b(" ",q(18,16,e==null?null:e.Created,"dd/MM/yyyy HH:mm:ss")," "),o(3),v(e.Customer),o(),I(U(21,he,(e.Variants==null?null:e.Variants.length)>1)),o(),y((e.Variants==null?null:e.Variants.length)>1?22:23),o(3),v(E(26,19,e.Amount)),o(6),v(e.LogisticService!=null&&e.LogisticService.Name?e.LogisticService==null?null:e.LogisticService.Name:"-"),o(),y(e.LogisticService!=null&&e.LogisticService.Option&&(e.LogisticService==null?null:e.LogisticService.Option)!="Default"?32:-1),o(2),b(" ",e.ReferenceNumber?e.ReferenceNumber:"-"," ")}}function Ce(r,S){if(r&1){let e=V();t(0,"div",15)(1,"table",17)(2,"thead",18)(3,"tr",19)(4,"th",20),l(5,"Outlet"),i(),t(6,"th",20),l(7,"Number"),i(),t(8,"th",20),l(9,"Customer"),i(),t(10,"th"),l(11,"Items"),i(),t(12,"th",21),l(13,"Amount"),i(),t(14,"th",22),l(15,"Shipping"),i()()(),t(16,"tbody"),B(17,Se,35,23,"tr",null,D),i()(),t(19,"app-custom-paginator",23),M("next",function(){m(e);let n=h();return d(n.initShippedOrders())})("previous",function(){m(e);let n=h();return d(n.initShippedOrders())}),i()()}if(r&2){let e=h(),p=R(0);o(17),k(p),o(2),c("filter",e.filter())("totaldata",p==null?null:p.length)}}function ve(r,S){r&1&&(t(0,"div",16),u(1,"app-empty-state"),i())}var He=(()=>{class r{constructor(){this.orderService=O(T),this.filter=N({PageNumber:1,PageSize:20,ListChannelID:[],From:null,To:null,Number:null})}ngOnInit(){this.orderService.getOrderDefaultValue().subscribe({next:e=>{this.initFromDate(e)},error:e=>{console.error("Error fetching default date:",e),this.initFromDate(null)}})}initFromDate(e){this.filter.update(p=>L(P({},p),{From:e})),this.initShippedOrders()}initShippedOrders(){this.shippedOrders$=this.orderService.getShippedOrders(this.filter())}static{this.\u0275fac=function(p){return new(p||r)}}static{this.\u0275cmp=W({type:r,selectors:[["app-shipped"]],features:[H([T])],decls:34,vars:12,consts:[["headerTitle","Shipped","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"],[1,"sticky-top-thead"],[1,"table-light"],[2,"width","200px"],[1,"text-end",2,"width","100px"],[2,"width","100px"],["rowCountApi","/api/orders/shippedcount",3,"next","previous","filter","totaldata"],[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"],[1,"d-flex","align-items-end","gap-2"],[2,"font-size","14px",3,"order"],[3,"variants"],[3,"variant"],[1,"text-end"]],template:function(p,n){if(p&1){let s=V();z(0),w(1,"async"),t(2,"mainpanel",0),M("onSubmit",function(){return m(s),d(n.initShippedOrders())}),f("textChange",function(a){return m(s),g(n.filter().Number,a)||(n.filter().Number=a),d(a)}),t(3,"actions")(4,"a",1),u(5,"i",2),t(6,"span"),l(7,"Order Fulfillment Display"),i()()(),t(8,"filters")(9,"div")(10,"label",3),l(11,"Channel"),i(),t(12,"channel-select-options",4),f("ngModelChange",function(a){return m(s),g(n.filter().ListChannelID,a)||(n.filter().ListChannelID=a),d(a)}),i()(),t(13,"div",5)(14,"label",3),l(15,"From/To"),i(),t(16,"div",6)(17,"datepicker",7),f("dateChange",function(a){return m(s),g(n.filter().From,a)||(n.filter().From=a),d(a)}),i()(),t(18,"div")(19,"datepicker",8),f("dateChange",function(a){return m(s),g(n.filter().To,a)||(n.filter().To=a),d(a)}),i()()(),t(20,"div",5)(21,"label",9),l(22,"Page Number"),i(),t(23,"input",10),f("ngModelChange",function(a){return m(s),g(n.filter().PageNumber,a)||(n.filter().PageNumber=a),d(a)}),i()(),t(24,"div",5)(25,"label",9),l(26,"Page Size"),i(),t(27,"input",11),f("ngModelChange",function(a){return m(s),g(n.filter().PageSize,a)||(n.filter().PageSize=a),d(a)}),i()()(),t(28,"content")(29,"div",12)(30,"div",13)(31,"div",14),x(32,Ce,20,2,"div",15)(33,ve,2,0,"div",16),i()()()()()}if(p&2){let s=A(E(1,8,n.shippedOrders$)||j(11,ue));o(2),_("text",n.filter().Number),o(10),c("multiple",!0),_("ngModel",n.filter().ListChannelID),o(5),_("date",n.filter().From),o(2),_("date",n.filter().To),o(4),_("ngModel",n.filter().PageNumber),o(4),_("ngModel",n.filter().PageSize),o(5),y(s.length>0?32:33)}},dependencies:[Q,G,K,J,re,ne,oe,ae,ee,X,$,Y,Z,pe,me,de,se,le,ie,te,ce],encapsulation:2})}}return r})();export{He as ShippedComponent};
1
+ import{a as pe,b as me,c as de}from"./chunk-UHJEXTOG.js";import{a as ce}from"./chunk-WAKKUK6E.js";import{a as T}from"./chunk-QSHR75ZI.js";import{a as se}from"./chunk-67HPC5Y3.js";import{a as oe}from"./chunk-OLANEXLB.js";import"./chunk-PFY5UG5D.js";import"./chunk-KS7ACI26.js";import"./chunk-3GDM5JNY.js";import"./chunk-XXT6F2ZS.js";import"./chunk-QS22J2SC.js";import"./chunk-EHUVS2VB.js";import"./chunk-IHSGQFDX.js";import"./chunk-MO53T3IK.js";import"./chunk-W3JTS22H.js";import"./chunk-SDUUFQUI.js";import"./chunk-6L7TD5DW.js";import"./chunk-6OMSPZZC.js";import"./chunk-3RK6DDJD.js";import"./chunk-HIC5QC3Y.js";import"./chunk-JBT7GBCM.js";import"./chunk-JVNHFIYT.js";import{a as le}from"./chunk-CWXOXH6M.js";import"./chunk-3YP6ORBR.js";import{a as ae}from"./chunk-LDL3A7NM.js";import"./chunk-WWLC64XZ.js";import"./chunk-Z3ITXK3D.js";import"./chunk-ACIMXBIC.js";import"./chunk-TGMCGROM.js";import"./chunk-CGOB6Y3X.js";import"./chunk-WN5DZGA4.js";import"./chunk-4NEKWRL7.js";import"./chunk-PYXL7UF7.js";import"./chunk-PW42BQIY.js";import{m as ne,n as re}from"./chunk-HJXYT6MI.js";import{A as ee,c as X,h as Y,m as Z,o as $}from"./chunk-5PS6ZS3N.js";import"./chunk-V3USB3ZU.js";import"./chunk-ERXVXBTU.js";import{r as te,s as ie}from"./chunk-MFQQEEHJ.js";import"./chunk-GZKOMS4T.js";import{j as G,k as J,m as K,n as Q}from"./chunk-FXQKRJWU.js";import{$c as w,Gb as W,Gc as l,Hc as v,Ic as b,Kc as _,Lc as g,Mb as x,Mc as f,Nc as z,Oc as A,Pc as R,Qc as H,Ra as N,Rc as j,Sc as U,Yb as c,ac as I,ad as E,bd as q,dc as y,ec as D,gc as B,hc as k,ic as t,jc as i,kc as u,oc as V,pa as O,pb as F,rb as o,tc as M,uc as h,ya as m,za as d}from"./chunk-OJMQBH6T.js";import"./chunk-EU2KAMEK.js";import{a as P,b as L}from"./chunk-66YHNWRR.js";var ue=()=>[],he=r=>({"td-cell-hover":r});function _e(r,S){if(r&1&&u(0,"variants-dropdown",31),r&2){let e=h().$implicit;c("variants",e==null?null:e.Variants)}}function ge(r,S){if(r&1&&u(0,"variant-with-image",32),r&2){let e=h().$implicit;c("variant",e==null?null:e.Variants[0])}}function fe(r,S){if(r&1&&(t(0,"span"),l(1),i()),r&2){let e=h().$implicit;o(),b("(",e.LogisticService==null?null:e.LogisticService.Option,")")}}function Se(r,S){if(r&1&&(t(0,"tr")(1,"td")(2,"div",24),u(3,"img",25),w(4,"channelImage"),t(5,"div",26)(6,"div"),l(7),i(),t(8,"small",27)(9,"span"),l(10),i()()()()(),t(11,"td")(12,"div",28)(13,"div",29)(14,"div"),u(15,"order-link",30),i()(),t(16,"small"),l(17),w(18,"date"),i()()(),t(19,"td"),l(20),i(),t(21,"td"),x(22,_e,1,1,"variants-dropdown",31)(23,ge,1,1,"variant-with-image",32),i(),t(24,"td",33),l(25),w(26,"number"),i(),t(27,"td")(28,"div",28)(29,"div",29)(30,"span"),l(31),i(),x(32,fe,2,1,"span"),i(),t(33,"small"),l(34),i()()()()),r&2){let e=S.$implicit;o(3),c("src",E(4,14,e==null?null:e.MarketType),F)("alt",e==null||e.Variants[0]==null?null:e.Variants[0].Name),o(4),v(e.Outlet),o(3),v(e.ChannelName),o(5),c("order",e),o(2),b(" ",q(18,16,e==null?null:e.Created,"dd/MM/yyyy HH:mm:ss")," "),o(3),v(e.Customer),o(),I(U(21,he,(e.Variants==null?null:e.Variants.length)>1)),o(),y((e.Variants==null?null:e.Variants.length)>1?22:23),o(3),v(E(26,19,e.Amount)),o(6),v(e.LogisticService!=null&&e.LogisticService.Name?e.LogisticService==null?null:e.LogisticService.Name:"-"),o(),y(e.LogisticService!=null&&e.LogisticService.Option&&(e.LogisticService==null?null:e.LogisticService.Option)!="Default"?32:-1),o(2),b(" ",e.ReferenceNumber?e.ReferenceNumber:"-"," ")}}function Ce(r,S){if(r&1){let e=V();t(0,"div",15)(1,"table",17)(2,"thead",18)(3,"tr",19)(4,"th",20),l(5,"Outlet"),i(),t(6,"th",20),l(7,"Number"),i(),t(8,"th",20),l(9,"Customer"),i(),t(10,"th"),l(11,"Items"),i(),t(12,"th",21),l(13,"Amount"),i(),t(14,"th",22),l(15,"Shipping"),i()()(),t(16,"tbody"),B(17,Se,35,23,"tr",null,D),i()(),t(19,"app-custom-paginator",23),M("next",function(){m(e);let n=h();return d(n.initShippedOrders())})("previous",function(){m(e);let n=h();return d(n.initShippedOrders())}),i()()}if(r&2){let e=h(),p=R(0);o(17),k(p),o(2),c("filter",e.filter())("totaldata",p==null?null:p.length)}}function ve(r,S){r&1&&(t(0,"div",16),u(1,"app-empty-state"),i())}var He=(()=>{class r{constructor(){this.orderService=O(T),this.filter=N({PageNumber:1,PageSize:20,ListChannelID:[],From:null,To:null,Number:null})}ngOnInit(){this.orderService.getOrderDefaultValue().subscribe({next:e=>{this.initFromDate(e)},error:e=>{console.error("Error fetching default date:",e),this.initFromDate(null)}})}initFromDate(e){this.filter.update(p=>L(P({},p),{From:e})),this.initShippedOrders()}initShippedOrders(){this.shippedOrders$=this.orderService.getShippedOrders(this.filter())}static{this.\u0275fac=function(p){return new(p||r)}}static{this.\u0275cmp=W({type:r,selectors:[["app-shipped"]],features:[H([T])],decls:34,vars:12,consts:[["headerTitle","Shipped","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"],[1,"sticky-top-thead"],[1,"table-light"],[2,"width","200px"],[1,"text-end",2,"width","100px"],[2,"width","100px"],["rowCountApi","/api/orders/shippedcount",3,"next","previous","filter","totaldata"],[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"],[1,"d-flex","align-items-end","gap-2"],[2,"font-size","14px",3,"order"],[3,"variants"],[3,"variant"],[1,"text-end"]],template:function(p,n){if(p&1){let s=V();z(0),w(1,"async"),t(2,"mainpanel",0),M("onSubmit",function(){return m(s),d(n.initShippedOrders())}),f("textChange",function(a){return m(s),g(n.filter().Number,a)||(n.filter().Number=a),d(a)}),t(3,"actions")(4,"a",1),u(5,"i",2),t(6,"span"),l(7,"Order Fulfillment Display"),i()()(),t(8,"filters")(9,"div")(10,"label",3),l(11,"Channel"),i(),t(12,"channel-select-options",4),f("ngModelChange",function(a){return m(s),g(n.filter().ListChannelID,a)||(n.filter().ListChannelID=a),d(a)}),i()(),t(13,"div",5)(14,"label",3),l(15,"From/To"),i(),t(16,"div",6)(17,"datepicker",7),f("dateChange",function(a){return m(s),g(n.filter().From,a)||(n.filter().From=a),d(a)}),i()(),t(18,"div")(19,"datepicker",8),f("dateChange",function(a){return m(s),g(n.filter().To,a)||(n.filter().To=a),d(a)}),i()()(),t(20,"div",5)(21,"label",9),l(22,"Page Number"),i(),t(23,"input",10),f("ngModelChange",function(a){return m(s),g(n.filter().PageNumber,a)||(n.filter().PageNumber=a),d(a)}),i()(),t(24,"div",5)(25,"label",9),l(26,"Page Size"),i(),t(27,"input",11),f("ngModelChange",function(a){return m(s),g(n.filter().PageSize,a)||(n.filter().PageSize=a),d(a)}),i()()(),t(28,"content")(29,"div",12)(30,"div",13)(31,"div",14),x(32,Ce,20,2,"div",15)(33,ve,2,0,"div",16),i()()()()()}if(p&2){let s=A(E(1,8,n.shippedOrders$)||j(11,ue));o(2),_("text",n.filter().Number),o(10),c("multiple",!0),_("ngModel",n.filter().ListChannelID),o(5),_("date",n.filter().From),o(2),_("date",n.filter().To),o(4),_("ngModel",n.filter().PageNumber),o(4),_("ngModel",n.filter().PageSize),o(5),y(s.length>0?32:33)}},dependencies:[Q,G,K,J,re,ne,oe,ae,ee,X,$,Y,Z,pe,me,de,se,le,ie,te,ce],encapsulation:2})}}return r})();export{He as ShippedComponent};
@@ -1,4 +1,4 @@
1
- import{a as tt,b as it,c as nt}from"./chunk-6H2KAYSB.js";import"./chunk-EYONZQ2W.js";import{a as pe}from"./chunk-GKRWJPI3.js";import"./chunk-MX5SR3SR.js";import{a as Qe,b as Ze,c as qe,e as Je,f as Xe,g as et}from"./chunk-BMYBLBSP.js";import{e as Ye,k as $e,l as Ge,m as je,n as He,o as Ke}from"./chunk-KS7ACI26.js";import"./chunk-PHUHUFYL.js";import{a as Le,b as Ae,c as ze}from"./chunk-KSHWHTCH.js";import"./chunk-HVCIQI7B.js";import"./chunk-3GDM5JNY.js";import"./chunk-XXT6F2ZS.js";import"./chunk-QS22J2SC.js";import"./chunk-EHUVS2VB.js";import"./chunk-VFATXJRG.js";import"./chunk-T2OSIFLN.js";import"./chunk-QW4EOJRM.js";import{a as Ue}from"./chunk-KRQHTRFM.js";import"./chunk-Q4N2QUV6.js";import"./chunk-7G6GQTSH.js";import"./chunk-MO53T3IK.js";import"./chunk-W3JTS22H.js";import"./chunk-SDUUFQUI.js";import"./chunk-6L7TD5DW.js";import"./chunk-6OMSPZZC.js";import"./chunk-JBT7GBCM.js";import"./chunk-OZ7LWNOK.js";import"./chunk-YFDFIBAG.js";import{ma as Be}from"./chunk-RC5PUUVM.js";import"./chunk-JVNHFIYT.js";import"./chunk-6VYFG4AQ.js";import{h as Ve,i as re}from"./chunk-FHWKSD5A.js";import"./chunk-Z3ITXK3D.js";import"./chunk-ACIMXBIC.js";import"./chunk-TGMCGROM.js";import{a as oe}from"./chunk-CGOB6Y3X.js";import{b as Pe,e as Ie}from"./chunk-WN5DZGA4.js";import"./chunk-4NEKWRL7.js";import{c as ke,d as Fe,e as Oe}from"./chunk-PYXL7UF7.js";import{b as ne,c as D}from"./chunk-PW42BQIY.js";import{m as Re,n as We}from"./chunk-HJXYT6MI.js";import{A as ie,b as be,c as Me,h as ee,m as te,x as Ee}from"./chunk-5PS6ZS3N.js";import"./chunk-V3USB3ZU.js";import"./chunk-ERXVXBTU.js";import{r as Ne,s as ae}from"./chunk-MFQQEEHJ.js";import"./chunk-GZKOMS4T.js";import{J as Te,d as F,f as L,g as A,j as X,k as z,n as I}from"./chunk-FXQKRJWU.js";import{$c as W,Ac as Ce,Bc as Se,Cc as ve,Fc as x,Gb as P,Gc as p,Hc as k,Ic as S,Ka as B,Kc as T,Lc as b,Mb as w,Mc as M,Na as ue,Oa as O,Qc as Q,Ra as f,Rc as ye,Sc as Z,Tc as De,Yb as d,Z as $,aa as ce,ad as j,bd as xe,cd as q,dc as V,ea as G,ic as o,ja as he,jc as r,kc as C,lc as N,m as me,mc as R,oc as v,pa as y,pb as fe,rb as l,sd as J,tc as g,uc as _,v as K,xb as _e,xc as ge,ya as c,yc as we,za as h}from"./chunk-OJMQBH6T.js";import"./chunk-EU2KAMEK.js";import{a as se,b as de}from"./chunk-66YHNWRR.js";var pt=t=>({"over-due":t});function st(t,m){if(t&1&&(o(0,"tr",8)(1,"td"),p(2),r(),o(3,"td"),p(4),r(),o(5,"td"),p(6),r(),o(7,"td"),p(8),r()()),t&2){let e=m.$implicit,n=m.index;d("ngClass",Z(5,pt,e.Exception)),l(2),k(n+1),l(2),k(e.Number),l(2),k(e.Status),l(2),k(e.Exception)}}function dt(t,m){if(t&1&&(N(0),w(1,st,9,7,"tr",7),R()),t&2){let e,n=_();l(),d("ngForOf",(e=n.downloadResult())==null?null:e.Body)}}function mt(t,m){t&1&&(o(0,"tr",9)(1,"td",10)(2,"div",11),C(3,"i",12),r(),o(4,"h4",13),p(5," There is no order to processed "),r()()())}var ot=(()=>{class t{constructor(){this.downloadResult=O()}ngOnInit(){}static{this.\u0275fac=function(n){return new(n||t)}}static{this.\u0275cmp=P({type:t,selectors:[["complete-step"]],inputs:{downloadResult:[1,"downloadResult"]},decls:16,vars:2,consts:[["EMPTY_DOWNLOAD",""],[1,"row","pt-2"],[1,"col-md-12"],[1,"table"],[1,"thead-light"],["width","1%"],[4,"ngIf","ngIfElse"],[3,"ngClass",4,"ngFor","ngForOf"],[3,"ngClass"],[1,"text-center"],["colspan","10",1,"border-0"],[2,"margin-top","16vh"],[1,"far","fa-file","text-secondary",2,"font-size","95px"],[1,"text-secondary","mt-6"]],template:function(n,i){if(n&1&&(o(0,"div",1)(1,"div",2)(2,"table",3)(3,"thead",4)(4,"tr"),C(5,"th",5),o(6,"th"),p(7,"Order Number"),r(),o(8,"th"),p(9,"Status"),r(),o(10,"th"),p(11,"Exception"),r()()(),o(12,"tbody"),w(13,dt,2,1,"ng-container",6)(14,mt,6,0,"ng-template",null,0,q),r()()()()),n&2){let a,u=x(15);l(13),d("ngIf",((a=i.downloadResult())==null||a.Body==null?null:a.Body.length)>0)("ngIfElse",u)}},dependencies:[I,F,L,A],encapsulation:2})}}return t})();var ht=t=>({"full-width":t}),ut=()=>({standalone:!0}),rt=(()=>{class t{constructor(e){this.datePipe=e,this.fullWidth=!1,this.timeChange=new B}ngOnInit(){}onTimeChange(e){let n=null;e&&(n=this.datePipe.transform(e,"HH:mm")),this.timeChange.emit(n),this.onTimePickerChange()}onShowCalendar(){let e=document.getElementById("dropdown-filter");if(e){var n=new bootstrap.Dropdown(e);n&&(n._config.autoClose="inside")}}onTimePickerChange(){let e=document.getElementById("dropdown-filter");if(e){var n=new bootstrap.Dropdown(e);n&&(n._config.autoClose="outside")}}static{this.\u0275fac=function(n){return new(n||t)(_e(z))}}static{this.\u0275cmp=P({type:t,selectors:[["app-timepicker"]],inputs:{time:"time",fullWidth:"fullWidth"},outputs:{timeChange:"timeChange"},decls:4,vars:8,consts:[["myCalendar",""],["styleClass","custom-height","id","shippingTime","appendTo","body",3,"ngModelChange","onSelect","ngClass","baseZIndex","ngModel","timeOnly","ngModelOptions"],["size","small","label","Close",3,"click"]],template:function(n,i){if(n&1){let a=v();o(0,"p-datepicker",1,0),M("ngModelChange",function(s){return c(a),b(i.time,s)||(i.time=s),h(s)}),g("ngModelChange",function(s){return c(a),h(i.onTimeChange(s))})("onSelect",function(){return c(a),h(i.onShowCalendar())}),o(2,"p-footer")(3,"p-button",2),g("click",function(){return c(a),x(1).hideOverlay(),h(i.onShowCalendar())}),r()()()}n&2&&(d("ngClass",Z(5,ht,i.fullWidth))("baseZIndex",1100),T("ngModel",i.time),d("timeOnly",!0)("ngModelOptions",ye(7,ut)))},dependencies:[I,F,ie,ee,te,nt,it,tt,Be],styles:["p-datepicker span.p-datepicker.custom-height{height:44px;width:70px} p-datepicker.full-width span.p-datepicker.custom-height{height:44px;width:100%!important}"]})}}return t})();var Y=(()=>{class t{constructor(){this.httpService=y(Ie),this.toastr=y(Pe),this.datePipe=y(z)}gerChannelDetailById(e){return this.httpService.post(oe.GetChannelDetail,{ID:e})}getOrderPreview(e){return this.httpService.post(oe.GetOrderPreviewV2,e)}getDownloadOrder(e){return this.httpService.post(oe.GetDownloadOrderV2,e)}onPreviewOrder(e){return this.validateDatePreview(e)?this.getOrderPreview(e).pipe(G(n=>{n.Data?.length===0&&this.toastrEmptyPreview(e)})):me}toastrEmptyPreview(e){let n=this.datePipe.transform(e.From,"dd MMM yyyy"),i=this.datePipe.transform(e.To,"dd MMM yyyy"),a=e.TimeFrom?e.TimeFrom:"",u=e.TimeTo?e.TimeTo:"";this.toastr.info(`There is no orders from ${n} ${a} to ${i} ${u}!`,"No Orders!")}validateDatePreview(e){let n=!0;return e.downloadType==!0?D.getDaysDiff(e?.From,e?.To)+1>7&&(this.toastr.warning("Dates cannot be more than 7 days apart!","Warning"),n=!1):D.getDaysDiff(e?.From,e?.To)+1>14&&(this.toastr.warning("Dates cannot be more than 14 days apart!","Warning"),n=!1),n}getDateTitle(e,n){let i=D.formatTitleFromDate(new Date(e),new Date(n)),a=this.datePipe.transform(e,i),u=this.datePipe.transform(n,"dd MMM yyyy");return`${i==null?"":a+"-"} ${u}`}static{this.\u0275fac=function(n){return new(n||t)}}static{this.\u0275prov=he({token:t,factory:t.\u0275fac})}}return t})();function ft(t,m){if(t&1&&(o(0,"ng-option",16),C(1,"img",17),p(2),r()),t&2){let e=m.$implicit;d("value",e.ID),l(),d("src",e==null?null:e.Img,fe),l(),S("",e.Name," ")}}function _t(t,m){if(t&1){let e=v();o(0,"div",8)(1,"div",4)(2,"h5"),p(3,"Type"),r(),o(4,"p",5),p(5,"Select Type want to download"),r()(),o(6,"div",4)(7,"div",18)(8,"div")(9,"mat-radio-group",19),M("ngModelChange",function(i){c(e);let a=_();return b(a.downloadType,i)||(a.downloadType=i),h(i)}),g("ngModelChange",function(){c(e);let i=_();return h(i.onDownloadTypeChange())}),o(10,"mat-radio-button",20),p(11," Orders "),r(),o(12,"mat-radio-button",21),p(13," Disbursement "),r()()()(),o(14,"div",22)(15,"div",23),C(16,"i",24),r(),o(17,"p",25),p(18," If there are completed transactions, to obtain payment and service fee, you need to download disbursement. "),r()()()()}if(t&2){let e=_();l(9),T("ngModel",e.downloadType),l(),d("value",!1),l(2),d("value",!0)}}function gt(t,m){t&1&&(o(0,"p",5),p(1," Select Disbursement date "),o(2,"span",26),p(3,"(payment date / order complete date)"),r(),p(4," of the channel you want to download (Max 1 Week). "),r())}function wt(t,m){t&1&&(o(0,"p",5),p(1," Select transaction date of the channel you want to download (Max 2 Weeks) "),r())}function Ct(t,m){if(t&1){let e=v();o(0,"div",12)(1,"app-timepicker",27),M("timeChange",function(i){c(e);let a=_();return b(a.startTime,i)||(a.startTime=i),h(i)}),g("timeChange",function(){c(e);let i=_();return h(i.onStartTimeChange())}),r(),o(2,"span",28),p(3,"-"),r(),o(4,"app-timepicker",27),M("timeChange",function(i){c(e);let a=_();return b(a.endTime,i)||(a.endTime=i),h(i)}),g("timeChange",function(){c(e);let i=_();return h(i.onEndTimeChange())}),r()()}if(t&2){let e=_();l(),T("time",e.startTime),l(3),T("time",e.endTime)}}var at=(()=>{class t{constructor(){this.reset=O(!1),this.authService=y(re),this.tokenService=y(Ve),this.downloadService=y(Y),this.downloadType=f(!1),this.selectedChannelId=f(null),this.channelOptions=f(this.authService.getChannels()),this.channelType=ne,this.selectedChannel=f(null),this.showTimePicker=f(!1),this.startDate=f(null),this.endDate=f(null),this.startTime=f("00:00"),this.endTime=f("23:59"),this.minDate=f(new Date),this.maxDate=f(new Date),this.filterData=new B,this._onRememberMeChange=ue({alias:"onRememberMeChange"}),this.rememberMe=f(!1),J(()=>{this.reset()&&this.resetFilter()},{allowSignalWrites:!0}),this.initDateValidation()}initDateValidation(){let e=this.tokenService?.getTokenValue(),n=e?.DownloadRange?JSON.parse(e?.DownloadRange):0;if(n<=0)this.minDate.set(null),this.maxDate.set(null);else{let i=new Date,a=D.addDays(i,n-1);this.minDate.set(a)}}resetFilter(){this.selectedChannelId.update(()=>null),this.startDate.update(()=>null),this.endDate.update(()=>null),this.startTime.update(()=>null),this.endTime.update(()=>null),this.downloadType.update(()=>!1),this.selectedChannel.update(()=>null),this.showTimePicker.update(()=>!1),this.channelDetail$=null}onSelectChannel(){this.selectedChannel.update(()=>this.channelOptions().find(e=>e.ID===this.selectedChannelId())),this.selectedChannel()?this.channelDetail$=this.downloadService.gerChannelDetailById(this.selectedChannelId()).pipe(K(e=>e?.Model),$(1)):this.channelDetail$=null,this.emitFilterData()}onFilterDateChange(){let e=1;this.startDate()&&this.endDate()&&(e=D.getDaysDiff(this.startDate(),this.endDate())),this.showTimePicker.update(()=>e==0),this.emitFilterData()}onDownloadTypeChange(){this.emitFilterData()}onStartTimeChange(){this.emitFilterData()}onEndTimeChange(){this.emitFilterData()}emitFilterData(){this.filterData.emit({channelId:this.selectedChannelId(),startDate:this.startDate(),endDate:this.endDate(),downloadType:this.downloadType(),startTime:this.startTime(),endTime:this.endTime()})}onChangeRememberMe(e){this._onRememberMeChange.emit(e)}static{this.\u0275fac=function(n){return new(n||t)}}static{this.\u0275cmp=P({type:t,selectors:[["filter-step"]],inputs:{reset:[1,"reset"]},outputs:{filterData:"onFilterChange",_onRememberMeChange:"onRememberMeChange"},features:[Q([Y,Ye()])],decls:32,vars:14,consts:[["picker",""],[1,"row","pt-2",2,"width","63%","margin-right","40px"],[1,"col-12"],[1,"row"],[1,"col-6"],[1,"text-muted"],["appendTo","body","placeholder","Select Channel",3,"ngModelChange","clearable","ngModel"],[3,"value",4,"ngFor","ngForOf"],[1,"row","mt-6"],["id","dates",1,"form-control","rounded","dateRange",3,"rangePicker","min","max"],["matStartDate","","placeholder","Start date",3,"ngModelChange","click","ngModel","maxlength"],["matEndDate","","placeholder","End date",3,"ngModelChange","click","ngModel"],[1,"mt-8"],[1,"col-6","d-flex","align-items-center","gap-2"],["type","checkbox",2,"width","16px","height","16px",3,"ngModelChange","ngModel"],[1,"ms-2","fw-bold"],[3,"value"],[2,"width","18px","margin-right","10px",3,"src"],[1,"form-label-group","radio","download-type",2,"margin-bottom","0px"],["name","dowloadType",3,"ngModelChange","ngModel"],["matTooltip","Download from Create sales order until create logistics status",1,"me-5",3,"value"],["matTooltip","Download only Payment and write off",1,"me-5",3,"value"],[1,"d-flex","border","mb-4","pt-6","px-6","mt-3",2,"background","#1f87ac0a","border-radius","5px"],[1,"me-3","pt-1"],[1,"fa","fa-lightbulb","fs-5"],[1,"mb-6"],[1,"fw-bold"],[3,"timeChange","time"],[1,"mx-4"]],template:function(n,i){if(n&1){let a=v();o(0,"div",1)(1,"div",2)(2,"div",3)(3,"div",4)(4,"h5"),p(5,"Select a Channel"),r(),o(6,"p",5),p(7,"Select Channel want to download order"),r()(),o(8,"div",4)(9,"ng-select",6),M("ngModelChange",function(s){return c(a),b(i.selectedChannelId,s)||(i.selectedChannelId=s),h(s)}),g("ngModelChange",function(){return c(a),h(i.onSelectChannel())}),w(10,ft,3,3,"ng-option",7),r()()(),w(11,_t,19,3,"div",8),W(12,"async"),o(13,"div",8)(14,"div",4)(15,"h5"),p(16,"Date Range"),r(),w(17,gt,5,0,"p",5)(18,wt,2,0,"p",5),r(),o(19,"div",4)(20,"div",2)(21,"mat-date-range-input",9)(22,"input",10),M("ngModelChange",function(s){return c(a),b(i.startDate,s)||(i.startDate=s),h(s)}),g("click",function(){c(a);let s=x(25);return h(s.open())}),r(),o(23,"input",11),M("ngModelChange",function(s){return c(a),b(i.endDate,s)||(i.endDate=s),h(s)}),g("click",function(){c(a);let s=x(25);return h(s.open())})("ngModelChange",function(){return c(a),h(i.onFilterDateChange())}),r()(),C(24,"mat-date-range-picker",null,0),r(),w(26,Ct,5,2,"div",12),r()(),o(27,"div",8)(28,"div",13)(29,"input",14),M("ngModelChange",function(s){return c(a),b(i.rememberMe,s)||(i.rememberMe=s),h(s)}),g("ngModelChange",function(s){return c(a),h(i.onChangeRememberMe(s))}),r(),o(30,"h5",15),p(31,"Remember Me"),r()()()()()}if(n&2){let a,u,s=x(25);l(9),d("clearable",!1),T("ngModel",i.selectedChannelId),l(),d("ngForOf",i.channelOptions()),l(),V((a=j(12,12,i.channelDetail$))!=null&&a.ServiceFeeWriteOff&&((a=i.selectedChannel())==null?null:a.TypeID)==i.channelType.Tokopedia?11:-1),l(6),V(i.downloadType()&&((u=i.selectedChannel())==null?null:u.TypeID)==i.channelType.Tokopedia?17:18),l(4),d("rangePicker",s)("min",i.minDate())("max",i.maxDate()),l(),T("ngModel",i.startDate),l(),T("ngModel",i.endDate),l(3),V(i.showTimePicker()?26:-1),l(3),T("ngModel",i.rememberMe)}},dependencies:[I,L,X,Oe,Fe,ke,ze,Le,Ae,ie,Me,be,ee,Ee,te,rt,He,$e,Ke,Ge,je],styles:[".vertical-radio[_ngcontent-%COMP%]{display:flex;flex-direction:column;margin:15px 0}.mt-1rem[_ngcontent-%COMP%]{margin-top:1rem}.dateRange[_ngcontent-%COMP%]{padding-top:.8rem;padding-bottom:.8rem}.form-label-group.radio.download-type[_ngcontent-%COMP%]{height:45.5938px!important;border-radius:.375rem!important}"]})}}return t})();var E=function(t){return t.ALL="all",t.SYNC="sync",t.WRONG="wrong",t.UNSYNC="unsync",t}(E||{});var U=function(t){return t[t.DoNothing=0]="DoNothing",t[t.New=1]="New",t[t.Update=2]="Update",t}(U||{});var St=(t,m)=>({"over-due-today":t,"over-due":m});function vt(t,m){if(t&1&&(o(0,"th",21),p(1),r()),t&2){let e=_();l(),S(" ",e.selectedChannel()?"Created Date":"Last Status Update"," ")}}function yt(t,m){if(t&1&&(o(0,"td"),p(1),W(2,"date"),r()),t&2){let e=_().$implicit;l(),S(" ",xe(2,1,e.Modified,"dd MMM yyyy HH:mm:ss")," ")}}function Dt(t,m){if(t&1&&(o(0,"span"),p(1),r()),t&2){let e=_().$implicit;l(),S(" ",e.ActionString," ")}}function xt(t,m){if(t&1&&(o(0,"li"),p(1),r()),t&2){let e=m.$implicit;l(),S(" ",e," ")}}function Tt(t,m){if(t&1&&(o(0,"ul",27),w(1,xt,2,1,"li",22),r()),t&2){let e=_().$implicit;l(),d("ngForOf",e.ActionString)}}function bt(t,m){if(t&1&&(o(0,"span",28),C(1,"i",29),r()),t&2){let e=_().$implicit;we("title","Delivery : ",e.DeliveryState,`
1
+ import{a as tt,b as it,c as nt}from"./chunk-6H2KAYSB.js";import"./chunk-EYONZQ2W.js";import{a as pe}from"./chunk-QSHR75ZI.js";import"./chunk-MX5SR3SR.js";import{a as Qe,b as Ze,c as qe,e as Je,f as Xe,g as et}from"./chunk-BMYBLBSP.js";import{e as Ye,k as $e,l as Ge,m as je,n as He,o as Ke}from"./chunk-KS7ACI26.js";import"./chunk-PHUHUFYL.js";import{a as Le,b as Ae,c as ze}from"./chunk-KSHWHTCH.js";import"./chunk-HVCIQI7B.js";import"./chunk-3GDM5JNY.js";import"./chunk-XXT6F2ZS.js";import"./chunk-QS22J2SC.js";import"./chunk-EHUVS2VB.js";import"./chunk-VFATXJRG.js";import"./chunk-T2OSIFLN.js";import"./chunk-QW4EOJRM.js";import{a as Ue}from"./chunk-PE4SWUEZ.js";import"./chunk-Q4N2QUV6.js";import"./chunk-7G6GQTSH.js";import"./chunk-MO53T3IK.js";import"./chunk-W3JTS22H.js";import"./chunk-SDUUFQUI.js";import"./chunk-6L7TD5DW.js";import"./chunk-6OMSPZZC.js";import"./chunk-JBT7GBCM.js";import"./chunk-OZ7LWNOK.js";import"./chunk-YFDFIBAG.js";import{ma as Be}from"./chunk-RC5PUUVM.js";import"./chunk-JVNHFIYT.js";import"./chunk-6RMBCW2O.js";import{h as Ve,i as re}from"./chunk-WWLC64XZ.js";import"./chunk-Z3ITXK3D.js";import"./chunk-ACIMXBIC.js";import"./chunk-TGMCGROM.js";import{a as oe}from"./chunk-CGOB6Y3X.js";import{b as Pe,e as Ie}from"./chunk-WN5DZGA4.js";import"./chunk-4NEKWRL7.js";import{c as ke,d as Fe,e as Oe}from"./chunk-PYXL7UF7.js";import{b as ne,c as D}from"./chunk-PW42BQIY.js";import{m as Re,n as We}from"./chunk-HJXYT6MI.js";import{A as ie,b as be,c as Me,h as ee,m as te,x as Ee}from"./chunk-5PS6ZS3N.js";import"./chunk-V3USB3ZU.js";import"./chunk-ERXVXBTU.js";import{r as Ne,s as ae}from"./chunk-MFQQEEHJ.js";import"./chunk-GZKOMS4T.js";import{J as Te,d as F,f as L,g as A,j as X,k as z,n as I}from"./chunk-FXQKRJWU.js";import{$c as W,Ac as Ce,Bc as Se,Cc as ve,Fc as x,Gb as P,Gc as p,Hc as k,Ic as S,Ka as B,Kc as T,Lc as b,Mb as w,Mc as M,Na as ue,Oa as O,Qc as Q,Ra as f,Rc as ye,Sc as Z,Tc as De,Yb as d,Z as $,aa as ce,ad as j,bd as xe,cd as q,dc as V,ea as G,ic as o,ja as he,jc as r,kc as C,lc as N,m as me,mc as R,oc as v,pa as y,pb as fe,rb as l,sd as J,tc as g,uc as _,v as K,xb as _e,xc as ge,ya as c,yc as we,za as h}from"./chunk-OJMQBH6T.js";import"./chunk-EU2KAMEK.js";import{a as se,b as de}from"./chunk-66YHNWRR.js";var pt=t=>({"over-due":t});function st(t,m){if(t&1&&(o(0,"tr",8)(1,"td"),p(2),r(),o(3,"td"),p(4),r(),o(5,"td"),p(6),r(),o(7,"td"),p(8),r()()),t&2){let e=m.$implicit,n=m.index;d("ngClass",Z(5,pt,e.Exception)),l(2),k(n+1),l(2),k(e.Number),l(2),k(e.Status),l(2),k(e.Exception)}}function dt(t,m){if(t&1&&(N(0),w(1,st,9,7,"tr",7),R()),t&2){let e,n=_();l(),d("ngForOf",(e=n.downloadResult())==null?null:e.Body)}}function mt(t,m){t&1&&(o(0,"tr",9)(1,"td",10)(2,"div",11),C(3,"i",12),r(),o(4,"h4",13),p(5," There is no order to processed "),r()()())}var ot=(()=>{class t{constructor(){this.downloadResult=O()}ngOnInit(){}static{this.\u0275fac=function(n){return new(n||t)}}static{this.\u0275cmp=P({type:t,selectors:[["complete-step"]],inputs:{downloadResult:[1,"downloadResult"]},decls:16,vars:2,consts:[["EMPTY_DOWNLOAD",""],[1,"row","pt-2"],[1,"col-md-12"],[1,"table"],[1,"thead-light"],["width","1%"],[4,"ngIf","ngIfElse"],[3,"ngClass",4,"ngFor","ngForOf"],[3,"ngClass"],[1,"text-center"],["colspan","10",1,"border-0"],[2,"margin-top","16vh"],[1,"far","fa-file","text-secondary",2,"font-size","95px"],[1,"text-secondary","mt-6"]],template:function(n,i){if(n&1&&(o(0,"div",1)(1,"div",2)(2,"table",3)(3,"thead",4)(4,"tr"),C(5,"th",5),o(6,"th"),p(7,"Order Number"),r(),o(8,"th"),p(9,"Status"),r(),o(10,"th"),p(11,"Exception"),r()()(),o(12,"tbody"),w(13,dt,2,1,"ng-container",6)(14,mt,6,0,"ng-template",null,0,q),r()()()()),n&2){let a,u=x(15);l(13),d("ngIf",((a=i.downloadResult())==null||a.Body==null?null:a.Body.length)>0)("ngIfElse",u)}},dependencies:[I,F,L,A],encapsulation:2})}}return t})();var ht=t=>({"full-width":t}),ut=()=>({standalone:!0}),rt=(()=>{class t{constructor(e){this.datePipe=e,this.fullWidth=!1,this.timeChange=new B}ngOnInit(){}onTimeChange(e){let n=null;e&&(n=this.datePipe.transform(e,"HH:mm")),this.timeChange.emit(n),this.onTimePickerChange()}onShowCalendar(){let e=document.getElementById("dropdown-filter");if(e){var n=new bootstrap.Dropdown(e);n&&(n._config.autoClose="inside")}}onTimePickerChange(){let e=document.getElementById("dropdown-filter");if(e){var n=new bootstrap.Dropdown(e);n&&(n._config.autoClose="outside")}}static{this.\u0275fac=function(n){return new(n||t)(_e(z))}}static{this.\u0275cmp=P({type:t,selectors:[["app-timepicker"]],inputs:{time:"time",fullWidth:"fullWidth"},outputs:{timeChange:"timeChange"},decls:4,vars:8,consts:[["myCalendar",""],["styleClass","custom-height","id","shippingTime","appendTo","body",3,"ngModelChange","onSelect","ngClass","baseZIndex","ngModel","timeOnly","ngModelOptions"],["size","small","label","Close",3,"click"]],template:function(n,i){if(n&1){let a=v();o(0,"p-datepicker",1,0),M("ngModelChange",function(s){return c(a),b(i.time,s)||(i.time=s),h(s)}),g("ngModelChange",function(s){return c(a),h(i.onTimeChange(s))})("onSelect",function(){return c(a),h(i.onShowCalendar())}),o(2,"p-footer")(3,"p-button",2),g("click",function(){return c(a),x(1).hideOverlay(),h(i.onShowCalendar())}),r()()()}n&2&&(d("ngClass",Z(5,ht,i.fullWidth))("baseZIndex",1100),T("ngModel",i.time),d("timeOnly",!0)("ngModelOptions",ye(7,ut)))},dependencies:[I,F,ie,ee,te,nt,it,tt,Be],styles:["p-datepicker span.p-datepicker.custom-height{height:44px;width:70px} p-datepicker.full-width span.p-datepicker.custom-height{height:44px;width:100%!important}"]})}}return t})();var Y=(()=>{class t{constructor(){this.httpService=y(Ie),this.toastr=y(Pe),this.datePipe=y(z)}gerChannelDetailById(e){return this.httpService.post(oe.GetChannelDetail,{ID:e})}getOrderPreview(e){return this.httpService.post(oe.GetOrderPreviewV2,e)}getDownloadOrder(e){return this.httpService.post(oe.GetDownloadOrderV2,e)}onPreviewOrder(e){return this.validateDatePreview(e)?this.getOrderPreview(e).pipe(G(n=>{n.Data?.length===0&&this.toastrEmptyPreview(e)})):me}toastrEmptyPreview(e){let n=this.datePipe.transform(e.From,"dd MMM yyyy"),i=this.datePipe.transform(e.To,"dd MMM yyyy"),a=e.TimeFrom?e.TimeFrom:"",u=e.TimeTo?e.TimeTo:"";this.toastr.info(`There is no orders from ${n} ${a} to ${i} ${u}!`,"No Orders!")}validateDatePreview(e){let n=!0;return e.downloadType==!0?D.getDaysDiff(e?.From,e?.To)+1>7&&(this.toastr.warning("Dates cannot be more than 7 days apart!","Warning"),n=!1):D.getDaysDiff(e?.From,e?.To)+1>14&&(this.toastr.warning("Dates cannot be more than 14 days apart!","Warning"),n=!1),n}getDateTitle(e,n){let i=D.formatTitleFromDate(new Date(e),new Date(n)),a=this.datePipe.transform(e,i),u=this.datePipe.transform(n,"dd MMM yyyy");return`${i==null?"":a+"-"} ${u}`}static{this.\u0275fac=function(n){return new(n||t)}}static{this.\u0275prov=he({token:t,factory:t.\u0275fac})}}return t})();function ft(t,m){if(t&1&&(o(0,"ng-option",16),C(1,"img",17),p(2),r()),t&2){let e=m.$implicit;d("value",e.ID),l(),d("src",e==null?null:e.Img,fe),l(),S("",e.Name," ")}}function _t(t,m){if(t&1){let e=v();o(0,"div",8)(1,"div",4)(2,"h5"),p(3,"Type"),r(),o(4,"p",5),p(5,"Select Type want to download"),r()(),o(6,"div",4)(7,"div",18)(8,"div")(9,"mat-radio-group",19),M("ngModelChange",function(i){c(e);let a=_();return b(a.downloadType,i)||(a.downloadType=i),h(i)}),g("ngModelChange",function(){c(e);let i=_();return h(i.onDownloadTypeChange())}),o(10,"mat-radio-button",20),p(11," Orders "),r(),o(12,"mat-radio-button",21),p(13," Disbursement "),r()()()(),o(14,"div",22)(15,"div",23),C(16,"i",24),r(),o(17,"p",25),p(18," If there are completed transactions, to obtain payment and service fee, you need to download disbursement. "),r()()()()}if(t&2){let e=_();l(9),T("ngModel",e.downloadType),l(),d("value",!1),l(2),d("value",!0)}}function gt(t,m){t&1&&(o(0,"p",5),p(1," Select Disbursement date "),o(2,"span",26),p(3,"(payment date / order complete date)"),r(),p(4," of the channel you want to download (Max 1 Week). "),r())}function wt(t,m){t&1&&(o(0,"p",5),p(1," Select transaction date of the channel you want to download (Max 2 Weeks) "),r())}function Ct(t,m){if(t&1){let e=v();o(0,"div",12)(1,"app-timepicker",27),M("timeChange",function(i){c(e);let a=_();return b(a.startTime,i)||(a.startTime=i),h(i)}),g("timeChange",function(){c(e);let i=_();return h(i.onStartTimeChange())}),r(),o(2,"span",28),p(3,"-"),r(),o(4,"app-timepicker",27),M("timeChange",function(i){c(e);let a=_();return b(a.endTime,i)||(a.endTime=i),h(i)}),g("timeChange",function(){c(e);let i=_();return h(i.onEndTimeChange())}),r()()}if(t&2){let e=_();l(),T("time",e.startTime),l(3),T("time",e.endTime)}}var at=(()=>{class t{constructor(){this.reset=O(!1),this.authService=y(re),this.tokenService=y(Ve),this.downloadService=y(Y),this.downloadType=f(!1),this.selectedChannelId=f(null),this.channelOptions=f(this.authService.getChannels()),this.channelType=ne,this.selectedChannel=f(null),this.showTimePicker=f(!1),this.startDate=f(null),this.endDate=f(null),this.startTime=f("00:00"),this.endTime=f("23:59"),this.minDate=f(new Date),this.maxDate=f(new Date),this.filterData=new B,this._onRememberMeChange=ue({alias:"onRememberMeChange"}),this.rememberMe=f(!1),J(()=>{this.reset()&&this.resetFilter()},{allowSignalWrites:!0}),this.initDateValidation()}initDateValidation(){let e=this.tokenService?.getTokenValue(),n=e?.DownloadRange?JSON.parse(e?.DownloadRange):0;if(n<=0)this.minDate.set(null),this.maxDate.set(null);else{let i=new Date,a=D.addDays(i,n-1);this.minDate.set(a)}}resetFilter(){this.selectedChannelId.update(()=>null),this.startDate.update(()=>null),this.endDate.update(()=>null),this.startTime.update(()=>null),this.endTime.update(()=>null),this.downloadType.update(()=>!1),this.selectedChannel.update(()=>null),this.showTimePicker.update(()=>!1),this.channelDetail$=null}onSelectChannel(){this.selectedChannel.update(()=>this.channelOptions().find(e=>e.ID===this.selectedChannelId())),this.selectedChannel()?this.channelDetail$=this.downloadService.gerChannelDetailById(this.selectedChannelId()).pipe(K(e=>e?.Model),$(1)):this.channelDetail$=null,this.emitFilterData()}onFilterDateChange(){let e=1;this.startDate()&&this.endDate()&&(e=D.getDaysDiff(this.startDate(),this.endDate())),this.showTimePicker.update(()=>e==0),this.emitFilterData()}onDownloadTypeChange(){this.emitFilterData()}onStartTimeChange(){this.emitFilterData()}onEndTimeChange(){this.emitFilterData()}emitFilterData(){this.filterData.emit({channelId:this.selectedChannelId(),startDate:this.startDate(),endDate:this.endDate(),downloadType:this.downloadType(),startTime:this.startTime(),endTime:this.endTime()})}onChangeRememberMe(e){this._onRememberMeChange.emit(e)}static{this.\u0275fac=function(n){return new(n||t)}}static{this.\u0275cmp=P({type:t,selectors:[["filter-step"]],inputs:{reset:[1,"reset"]},outputs:{filterData:"onFilterChange",_onRememberMeChange:"onRememberMeChange"},features:[Q([Y,Ye()])],decls:32,vars:14,consts:[["picker",""],[1,"row","pt-2",2,"width","63%","margin-right","40px"],[1,"col-12"],[1,"row"],[1,"col-6"],[1,"text-muted"],["appendTo","body","placeholder","Select Channel",3,"ngModelChange","clearable","ngModel"],[3,"value",4,"ngFor","ngForOf"],[1,"row","mt-6"],["id","dates",1,"form-control","rounded","dateRange",3,"rangePicker","min","max"],["matStartDate","","placeholder","Start date",3,"ngModelChange","click","ngModel","maxlength"],["matEndDate","","placeholder","End date",3,"ngModelChange","click","ngModel"],[1,"mt-8"],[1,"col-6","d-flex","align-items-center","gap-2"],["type","checkbox",2,"width","16px","height","16px",3,"ngModelChange","ngModel"],[1,"ms-2","fw-bold"],[3,"value"],[2,"width","18px","margin-right","10px",3,"src"],[1,"form-label-group","radio","download-type",2,"margin-bottom","0px"],["name","dowloadType",3,"ngModelChange","ngModel"],["matTooltip","Download from Create sales order until create logistics status",1,"me-5",3,"value"],["matTooltip","Download only Payment and write off",1,"me-5",3,"value"],[1,"d-flex","border","mb-4","pt-6","px-6","mt-3",2,"background","#1f87ac0a","border-radius","5px"],[1,"me-3","pt-1"],[1,"fa","fa-lightbulb","fs-5"],[1,"mb-6"],[1,"fw-bold"],[3,"timeChange","time"],[1,"mx-4"]],template:function(n,i){if(n&1){let a=v();o(0,"div",1)(1,"div",2)(2,"div",3)(3,"div",4)(4,"h5"),p(5,"Select a Channel"),r(),o(6,"p",5),p(7,"Select Channel want to download order"),r()(),o(8,"div",4)(9,"ng-select",6),M("ngModelChange",function(s){return c(a),b(i.selectedChannelId,s)||(i.selectedChannelId=s),h(s)}),g("ngModelChange",function(){return c(a),h(i.onSelectChannel())}),w(10,ft,3,3,"ng-option",7),r()()(),w(11,_t,19,3,"div",8),W(12,"async"),o(13,"div",8)(14,"div",4)(15,"h5"),p(16,"Date Range"),r(),w(17,gt,5,0,"p",5)(18,wt,2,0,"p",5),r(),o(19,"div",4)(20,"div",2)(21,"mat-date-range-input",9)(22,"input",10),M("ngModelChange",function(s){return c(a),b(i.startDate,s)||(i.startDate=s),h(s)}),g("click",function(){c(a);let s=x(25);return h(s.open())}),r(),o(23,"input",11),M("ngModelChange",function(s){return c(a),b(i.endDate,s)||(i.endDate=s),h(s)}),g("click",function(){c(a);let s=x(25);return h(s.open())})("ngModelChange",function(){return c(a),h(i.onFilterDateChange())}),r()(),C(24,"mat-date-range-picker",null,0),r(),w(26,Ct,5,2,"div",12),r()(),o(27,"div",8)(28,"div",13)(29,"input",14),M("ngModelChange",function(s){return c(a),b(i.rememberMe,s)||(i.rememberMe=s),h(s)}),g("ngModelChange",function(s){return c(a),h(i.onChangeRememberMe(s))}),r(),o(30,"h5",15),p(31,"Remember Me"),r()()()()()}if(n&2){let a,u,s=x(25);l(9),d("clearable",!1),T("ngModel",i.selectedChannelId),l(),d("ngForOf",i.channelOptions()),l(),V((a=j(12,12,i.channelDetail$))!=null&&a.ServiceFeeWriteOff&&((a=i.selectedChannel())==null?null:a.TypeID)==i.channelType.Tokopedia?11:-1),l(6),V(i.downloadType()&&((u=i.selectedChannel())==null?null:u.TypeID)==i.channelType.Tokopedia?17:18),l(4),d("rangePicker",s)("min",i.minDate())("max",i.maxDate()),l(),T("ngModel",i.startDate),l(),T("ngModel",i.endDate),l(3),V(i.showTimePicker()?26:-1),l(3),T("ngModel",i.rememberMe)}},dependencies:[I,L,X,Oe,Fe,ke,ze,Le,Ae,ie,Me,be,ee,Ee,te,rt,He,$e,Ke,Ge,je],styles:[".vertical-radio[_ngcontent-%COMP%]{display:flex;flex-direction:column;margin:15px 0}.mt-1rem[_ngcontent-%COMP%]{margin-top:1rem}.dateRange[_ngcontent-%COMP%]{padding-top:.8rem;padding-bottom:.8rem}.form-label-group.radio.download-type[_ngcontent-%COMP%]{height:45.5938px!important;border-radius:.375rem!important}"]})}}return t})();var E=function(t){return t.ALL="all",t.SYNC="sync",t.WRONG="wrong",t.UNSYNC="unsync",t}(E||{});var U=function(t){return t[t.DoNothing=0]="DoNothing",t[t.New=1]="New",t[t.Update=2]="Update",t}(U||{});var St=(t,m)=>({"over-due-today":t,"over-due":m});function vt(t,m){if(t&1&&(o(0,"th",21),p(1),r()),t&2){let e=_();l(),S(" ",e.selectedChannel()?"Created Date":"Last Status Update"," ")}}function yt(t,m){if(t&1&&(o(0,"td"),p(1),W(2,"date"),r()),t&2){let e=_().$implicit;l(),S(" ",xe(2,1,e.Modified,"dd MMM yyyy HH:mm:ss")," ")}}function Dt(t,m){if(t&1&&(o(0,"span"),p(1),r()),t&2){let e=_().$implicit;l(),S(" ",e.ActionString," ")}}function xt(t,m){if(t&1&&(o(0,"li"),p(1),r()),t&2){let e=m.$implicit;l(),S(" ",e," ")}}function Tt(t,m){if(t&1&&(o(0,"ul",27),w(1,xt,2,1,"li",22),r()),t&2){let e=_().$implicit;l(),d("ngForOf",e.ActionString)}}function bt(t,m){if(t&1&&(o(0,"span",28),C(1,"i",29),r()),t&2){let e=_().$implicit;we("title","Delivery : ",e.DeliveryState,`
2
2
  Payment : `,e.PaymentState,"")}}function Mt(t,m){if(t&1&&(o(0,"tr")(1,"td"),p(2),r(),o(3,"td"),p(4),r(),w(5,yt,3,4,"td",23),o(6,"td")(7,"span"),p(8),r(),p(9),r(),o(10,"td",24)(11,"span"),p(12),r(),p(13),r(),o(14,"td"),w(15,Dt,2,1,"span",23)(16,Tt,2,1,"ul",25),r(),o(17,"td"),w(18,bt,2,3,"span",26),r()()),t&2){let e,n=m.$implicit,i=m.index,a=_(2);l(2),k(i+1),l(2),k(n.Number),l(),d("ngIf",((e=a.selectedChannel())==null?null:e.TypeID)!=a.channelType.Shopee&&((e=a.selectedChannel())==null?null:e.TypeID)!==a.channelType.Tiktok),l(3),S("",n.ChannelStatus," - "),l(),S("",n.ChannelStatusDescription," "),l(),d("ngClass",De(12,St,(n==null?null:n.Action)==a.actionPreviewOrder.Update,(n==null?null:n.Action)==a.actionPreviewOrder.New))("matTooltip",n.POSStatus==91||n.POSStatusDescription=="Conflict"?"There is a missed status at POS, usually fulfillment has not been recorded but the payment has been recorded":""),l(2),S("",n.POSStatus," - "),l(),S("",n.POSStatusDescription," "),l(2),d("ngIf",n.ActionString.length==1),l(),d("ngIf",n.ActionString.length>1),l(2),d("ngIf",n.ChannelStatus!=99&&n.POSStatus!=99)}}function Et(t,m){if(t&1&&(N(0),w(1,Mt,19,15,"tr",22),R()),t&2){let e=_();l(),d("ngForOf",e.displayPreviewData())}}function Pt(t,m){t&1&&(o(0,"tr",30)(1,"td",31)(2,"div",32),C(3,"i",33),r(),o(4,"h4",34),p(5," There is no order to processed "),r()()())}var lt=(()=>{class t{constructor(){this.orderPreview=O(),this.selectedChannel=O(),this.channelType=ne,this.allData=f(0),this.syncData=f(0),this.wrongData=f(0),this.unsyncData=f(0),this.pillStatus=f(E.ALL),this.actionPreviewOrder=U,this.previewStatus=E,this.displayPreviewData=f([]),this.exportOrders=new B,J(()=>{this.orderPreview()&&(this.filterPreviewData(E.ALL),this.initLengthStatusData())},{allowSignalWrites:!0})}filterPreviewData(e){this.pillStatus.update(()=>e),this.displayPreviewData.update(()=>this.filterDataByStatus(e))}initLengthStatusData(){this.wrongData.update(()=>this.filterDataByStatus(E.WRONG).length),this.syncData.update(()=>this.filterDataByStatus(E.SYNC).length),this.allData.update(()=>this.orderPreview().length),this.unsyncData.update(()=>this.filterDataByStatus(E.UNSYNC).length)}filterDataByStatus(e){let n=[];switch(e){case E.ALL:n=this.orderPreview();break;case E.SYNC:n=this.orderPreview().filter(i=>i.Action==U.DoNothing);break;case E.WRONG:n=this.orderPreview().filter(i=>i.Action==U.Update);break;case E.UNSYNC:n=this.orderPreview().filter(i=>i.Action==U.New);break}return n}onExportOrders(){this.exportOrders.emit()}static{this.\u0275fac=function(n){return new(n||t)}}static{this.\u0275cmp=P({type:t,selectors:[["preview-step"]],inputs:{orderPreview:[1,"orderPreview"],selectedChannel:[1,"selectedChannel"]},outputs:{exportOrders:"onExportOrders"},decls:41,vars:11,consts:[["EMPTY",""],[1,"row","pt-2"],[1,"col-md-12"],[1,"row","mx-1","mb-5"],[1,"col-12","d-flex","justify-content-between","align-items-end",2,"padding-left","0px","padding-right","0px"],[1,"nav","nav-pills"],[1,"nav-item","me-3"],[1,"btn","btn-sm","rounded-pill",3,"click","ngClass"],[1,"nav-item","mx-3"],["matTooltip","All Invoice which is already available in POS",1,"btn","btn-sm","rounded-pill",3,"click","ngClass"],["matTooltip","Invoices that have different status between marketplace and POS",1,"btn","btn-sm","rounded-pill",3,"click","ngClass"],["matTooltip","Invoices which is not exist in POS",1,"btn","btn-sm","rounded-pill",3,"click","ngClass"],["type","button",1,"btn","btn-outline-secondary",3,"click"],[1,"fa-solid","fa-print","me-3"],[1,"table"],[1,"thead-light"],["width","1%"],["width","25%"],["width","15%",4,"ngIf"],["width","10%"],[4,"ngIf","ngIfElse"],["width","15%"],[4,"ngFor","ngForOf"],[4,"ngIf"],["matTooltipClass","custom-width-tooltip",3,"ngClass","matTooltip"],["class","ps-5",4,"ngIf"],[3,"title",4,"ngIf"],[1,"ps-5"],[3,"title"],[1,"fas","fa-info-circle","ms-2"],[1,"text-center"],["colspan","10",1,"border-0"],[2,"margin-top","16vh"],[1,"far","fa-file","text-secondary",2,"font-size","95px"],[1,"text-secondary","mt-6"]],template:function(n,i){if(n&1){let a=v();o(0,"div",1)(1,"div",2)(2,"div",3)(3,"div",4)(4,"div")(5,"ul",5)(6,"li",6)(7,"button",7),g("click",function(){return c(a),h(i.filterPreviewData(i.previewStatus.ALL))}),p(8),r()(),o(9,"li",8)(10,"button",9),g("click",function(){return c(a),h(i.filterPreviewData(i.previewStatus.SYNC))}),p(11),r()(),o(12,"li",8)(13,"button",10),g("click",function(){return c(a),h(i.filterPreviewData(i.previewStatus.WRONG))}),p(14),r()(),o(15,"li",8)(16,"button",11),g("click",function(){return c(a),h(i.filterPreviewData(i.previewStatus.UNSYNC))}),p(17),r()()()(),o(18,"div")(19,"button",12),g("click",function(){return c(a),h(i.onExportOrders())}),C(20,"i",13),o(21,"span"),p(22,"Export"),r()()()()(),o(23,"table",14)(24,"thead",15)(25,"tr"),C(26,"th",16),o(27,"th",17),p(28,"Number"),r(),w(29,vt,2,1,"th",18),o(30,"th",19),p(31,"Channel Status"),r(),o(32,"th",19),p(33,"POS Status"),r(),o(34,"th"),p(35,"Action"),r(),C(36,"th",16),r()(),o(37,"tbody"),w(38,Et,2,1,"ng-container",20)(39,Pt,6,0,"ng-template",null,0,q),r()()()()}if(n&2){let a,u,s=x(40);l(7),d("ngClass",i.pillStatus()=="all"?"btn-secondary text-white":"btn-outline-dark"),l(),S(" All (",i.allData(),") "),l(2),d("ngClass",i.pillStatus()=="sync"?"btn-success":"btn-outline-success"),l(),S(" Existing (",i.syncData(),") "),l(2),d("ngClass",i.pillStatus()=="wrong"?"btn-warning text-white":"btn-outline-warning"),l(),S(" Wrong Status (",i.wrongData(),") "),l(2),d("ngClass",i.pillStatus()=="unsync"?"btn-danger":"btn-outline-danger"),l(),S(" Missing (",i.unsyncData(),") "),l(12),d("ngIf",((a=i.selectedChannel())==null?null:a.TypeID)!=i.channelType.Shopee&&((a=i.selectedChannel())==null?null:a.TypeID)!==i.channelType.Tiktok),l(9),d("ngIf",((u=i.displayPreviewData())==null?null:u.length)>0)("ngIfElse",s)}},dependencies:[I,F,L,A,z,ae,Ne],encapsulation:2})}}return t})();var It=["stepper"];function Vt(t,m){if(t&1){let e=v();o(0,"div",2)(1,"button",19),g("click",function(){c(e);let i=_();return h(i.onStepperBack())}),p(2," Back "),r(),o(3,"button",20),g("click",function(){c(e);let i=_();return h(i.onNextStep())}),p(4," Next "),r()()}if(t&2){let e=_();l(3),d("disabled",e.disabledNextFilter())}}function kt(t,m){if(t&1){let e=v();o(0,"button",21),g("click",function(){c(e);let i=_();return h(i.onNextStep())}),p(1," Next "),r()}if(t&2){let e=_();d("disabled",e.disabledNextFilter())}}function Ft(t,m){if(t&1){let e=v();o(0,"button",22),g("click",function(){c(e);let i=_();return h(i.onNewDownload())}),C(1,"i",23),p(2," New "),r()}}function Ot(t,m){t&1&&(C(0,"i",24),o(1,"span"),p(2,"Filter"),r())}function Nt(t,m){t&1&&(C(0,"i",25),o(1,"span"),p(2,"Preview"),r())}function Rt(t,m){if(t&1){let e=v();N(0),o(1,"preview-step",26),g("onExportOrders",function(){c(e);let i=_();return h(i.onExportOrders())}),r(),R()}if(t&2){let e=m.ngIf;l(),d("orderPreview",e)}}function Wt(t,m){t&1&&(C(0,"i",27),o(1,"span"),p(2,"Finish"),r())}function Bt(t,m){if(t&1&&(N(0),C(1,"complete-step",28),R()),t&2){let e=m.ngIf;l(),d("downloadResult",e)}}function Lt(t,m){t&1&&(o(0,"h6"),p(1,"1"),r())}function At(t,m){t&1&&(o(0,"h6"),p(1,"2"),r())}function zt(t,m){t&1&&(o(0,"h6"),p(1,"3"),r())}var hn=(()=>{class t{constructor(){this.downloadService=y(Y),this.orderService=y(pe),this.productService=y(Ue),this.authService=y(re),this.stepperSelectedIndex=f(0),this.disabledNextFilter=f(!0),this.isResetFilter=f(!1),this.pageTitle=f("Download to POS"),this.cacheKey=f(D.GuidEMpty),this.rememberMe=f(!1)}onFilterChange(e){this.filter=e,this.validateDisabledNext()}validateDisabledNext(){this.disabledNextFilter.update(()=>D.IsEmpty(this.filter?.channelId)||!D.isValidDate(this.filter.startDate)||!D.isValidDate(this.filter.endDate))}onNextStep(){switch(this.stepper.selectedIndex){case 0:this.onPreview();let e=this.productService.findChannelById(this.filter.channelId,this.authService.getChannels());this.setPageTitle(`Preview ${e?.Name}`);break;case 1:this.onDownload(),this.setPageTitle("Download");break}}onStepperNext(){this.stepper.selected.completed=!0,this.stepper.next()}onPreview(){let e={ID:this.filter.channelId,From:this.filter.startDate,To:this.filter.endDate,IsDisbursement:this.filter.downloadType};D.IsNotEmpty(this.filter.startTime)&&(e=de(se({},e),{TimeFrom:this.filter.startTime+":00",TimeTo:this.filter.endTime+":00"})),this.orderPreview$=this.downloadService.onPreviewOrder(e).pipe(G(n=>{n.Data?.length>0&&(this.cacheKey.update(()=>n.CacheKey),this.onStepperNext())}),K(n=>n.Data),$(1))}onExportOrders(){let e={ID:this.filter.channelId,From:this.filter.startDate?this.filter.startDate:null,To:this.filter.endDate?this.filter.endDate:null},n=`Orders ${this.downloadService.getDateTitle(this.filter.startDate,this.filter.endDate)}`;this.orderService.exportOrders(e,n).subscribe()}onDownload(){let e={ID:this.filter.channelId,From:this.filter.startDate,To:this.filter.endDate,ListPreview:[],IsDisbursement:this.filter.downloadType,CacheKey:this.cacheKey()};this.downloadPreview$=this.orderPreview$.pipe(ce(n=>(e.ListPreview=n,this.downloadService.getDownloadOrder(e))),G(()=>{this.onStepperNext()}),$(1))}setPageTitle(e){this.pageTitle.update(()=>`
3
3
  ${e} (${this.downloadService.getDateTitle(this.filter.startDate,this.filter.endDate)})
4
4
  `)}onStepperBack(){this.stepper.previous(),this.pageTitle.update(()=>"Download to POS")}onNewDownload(){this.isResetFilter.update(()=>!this.rememberMe()),this.stepper.reset(),this.stepperSelectedIndex.update(()=>0),this.orderPreview$=null,this.downloadPreview$=null,this.pageTitle.update(()=>"Download to POS")}static{this.\u0275fac=function(n){return new(n||t)}}static{this.\u0275cmp=P({type:t,selectors:[["app-download-v2"]],viewQuery:function(n,i){if(n&1&&Ce(It,5),n&2){let a;Se(a=ve())&&(i.stepper=a.first)}},features:[Q([Y,pe,{provide:Qe,useValue:{displayDefaultIndicatorType:!1}}])],decls:26,vars:20,consts:[["stepper",""],[3,"hideSearchBox","hideSearchDropdown","headerTitle","description"],[1,"btn-group","me-3"],["type","button",1,"btn","btn-outline-secondary","btn-fill","me-3","bg-success","text-white",3,"disabled"],[1,"btn","btn-outline-secondary","btn-fill","d-flex","align-items-center","gap-2"],[1,"container-fluid","pt-5","mt-5"],[1,"row"],[1,"col-12"],[1,"d-flex","justify-content-center"],["linear","",1,"w-100","stepper-download",3,"selectedIndexChange","ngClass","selectedIndex"],["state","filter",3,"completed","editable"],["matStepLabel",""],[1,"w-100",3,"onFilterChange","onRememberMeChange","reset"],["state","preview",3,"editable","completed"],[4,"ngIf"],["state","finish"],["matStepperIcon","filter"],["matStepperIcon","preview"],["matStepperIcon","finish"],[1,"btn","btn-outline-secondary",3,"click"],["type","button",1,"btn","btn-outline-secondary","bg-success","text-white",3,"click","disabled"],["type","button",1,"btn","btn-outline-secondary","btn-fill","me-3","bg-success","text-white",3,"click","disabled"],[1,"btn","btn-outline-secondary","btn-fill","d-flex","align-items-center","gap-2",3,"click"],["aria-hidden","true",1,"fa","fa-file-alt"],[1,"fa-solid","fa-filter","me-3"],[1,"fa-solid","fa-file","me-3"],[3,"onExportOrders","orderPreview"],[1,"fa-solid","fa-flag","me-3"],[3,"downloadResult"]],template:function(n,i){if(n&1){let a=v();o(0,"mainpanel",1)(1,"actions"),w(2,Vt,5,1,"div",2)(3,kt,2,1,"button",3)(4,Ft,3,0,"button",4),r(),o(5,"content")(6,"div",5)(7,"div",6)(8,"div",7)(9,"div",8)(10,"mat-stepper",9,0),M("selectedIndexChange",function(s){return c(a),b(i.stepperSelectedIndex,s)||(i.stepperSelectedIndex=s),h(s)}),o(12,"mat-step",10),w(13,Ot,3,0,"ng-template",11),o(14,"filter-step",12),g("onFilterChange",function(s){return c(a),h(i.onFilterChange(s))})("onRememberMeChange",function(s){return c(a),h(i.rememberMe.set(s))}),r()(),o(15,"mat-step",13),w(16,Nt,3,0,"ng-template",11)(17,Rt,2,1,"ng-container",14),W(18,"async"),r(),o(19,"mat-step",15),w(20,Wt,3,0,"ng-template",11)(21,Bt,2,1,"ng-container",14),W(22,"async"),r(),w(23,Lt,2,0,"ng-template",16)(24,At,2,0,"ng-template",17)(25,zt,2,0,"ng-template",18),r()()()()()()()}if(n&2){let a=x(11);d("hideSearchBox",!0)("hideSearchDropdown",!0)("headerTitle",i.pageTitle())("description",i.pageTitle()),l(2),V(i.stepperSelectedIndex()==1?2:-1),l(),V(i.stepperSelectedIndex()==0?3:-1),l(),V(i.stepperSelectedIndex()==2?4:-1),l(6),ge("ngClass","last-edited-step-"+a.selectedIndex),T("selectedIndex",i.stepperSelectedIndex),l(2),d("completed",!1)("editable",i.stepperSelectedIndex()!=2),l(2),d("reset",i.isResetFilter()),l(),d("editable",i.stepperSelectedIndex()!=2)("completed",!1),l(2),d("ngIf",j(18,16,i.orderPreview$)),l(4),d("ngIf",j(22,18,i.downloadPreview$))}},dependencies:[I,F,A,X,ot,at,lt,et,Je,Ze,Xe,qe,We,Re,Te,ae],styles:[`@import"https://fonts.googleapis.com/icon?family=Material+Icons";.vertical-radio{display:flex;flex-direction:column;margin:15px 0}.mt-1rem{margin-top:1rem}.dateRange{padding-top:.8rem;padding-bottom:.8rem}mat-stepper.stepper-download>div.mat-horizontal-stepper-wrapper>div.mat-horizontal-stepper-header-container{position:relative;width:60%;left:18%}mat-stepper.stepper-download>div.mat-horizontal-stepper-wrapper>div.mat-horizontal-content-container>div.mat-horizontal-stepper-content:nth-child(1){display:flex;justify-content:left}mat-stepper.stepper-download>div.mat-horizontal-stepper-wrapper>div.mat-horizontal-content-container{margin-top:30px}mat-stepper.stepper-download>div.mat-horizontal-stepper-wrapper>div.mat-horizontal-stepper-header-container>mat-step-header.mat-horizontal-stepper-header{pointer-events:none!important}.form-label-group.radio.download-type{height:45.5938px!important;border-radius:.375rem!important}
@@ -1 +1 @@
1
- import{a as x}from"./chunk-PE5AFID4.js";import{h as u}from"./chunk-FHWKSD5A.js";import{b as h,d as C,i as M,j as v,k as S}from"./chunk-HJXYT6MI.js";import{G as g,n as p}from"./chunk-FXQKRJWU.js";import{Gb as m,Gc as t,Yb as d,ic as i,ja as s,jc as n,kc as f,pa as o,tc as c}from"./chunk-OJMQBH6T.js";var y=(()=>{class e{constructor(){this.dialogRef=o(h),this.route=o(g),this.modalConfig=new v,this.modalConfig.title="Switch to modern authorization",this.modalConfig.customWidth="450px",this.modalConfig.hideCancel=!0,this.modalConfig.headerType=M.Warning,this.modalConfig.okText="Setup"}onClose(){this.dialogRef.close()}onOk(){this.dialogRef.close(),this.route.navigate(["/menu/users"])}static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275cmp=m({type:e,selectors:[["app-modal-user-migration-confirmation"]],decls:19,vars:1,consts:[[3,"onOk","onCancel","config"],["content",""],[1,"d-flex","align-items-center","justify-content-between","gap-6"],[1,"text-center",2,"width","300px"],[1,"fa-solid","fa-users-gear","fa-6x"],[1,"lh-base"],["href","https://support.dealpos.com/en/articles/12636364-how-to-migrate-user-in-dealpos-omnichannel","target","_blank"]],template:function(r,l){r&1&&(i(0,"modal-material",0),c("onOk",function(){return l.onOk()})("onCancel",function(){return l.onClose()}),i(1,"div",1)(2,"div",2)(3,"div",3),f(4,"i",4),n(),i(5,"div",5)(6,"p"),t(7," We have introduced a new Modern Authorization, Please switch from "),i(8,"b"),t(9,"legacy"),n(),t(10," to "),i(11,"b"),t(12,"modern"),n(),t(13," authorization by inviting your users. "),n(),i(14,"div"),t(15," Please refer to this "),i(16,"a",6),t(17,"article"),n(),t(18," for more information "),n()()()()()),r&2&&d("config",l.modalConfig)},dependencies:[p,S],encapsulation:2})}}return e})();var R=(()=>{class e{constructor(){this.dialog=o(C),this.tokenService=o(u),this.dialogRef=null}openDialogMigrationConfirmation(){this.tokenService.getUser()?.AuthorizationMode===x.Legacy&&!this.dialogRef&&(this.dialogRef=this.dialog.open(y),this.dialogRef.afterClosed().subscribe(()=>{this.dialogRef=null}))}resetDialogState(){this.dialogRef&&(this.dialogRef.close(),this.dialogRef=null)}static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275prov=s({token:e,factory:e.\u0275fac,providedIn:"root"})}}return e})();var B=(e,b)=>(o(R).openDialogMigrationConfirmation(),!0);export{B as a};
1
+ import{a as x}from"./chunk-PE5AFID4.js";import{h as u}from"./chunk-WWLC64XZ.js";import{b as h,d as C,i as M,j as v,k as S}from"./chunk-HJXYT6MI.js";import{G as g,n as p}from"./chunk-FXQKRJWU.js";import{Gb as m,Gc as t,Yb as d,ic as i,ja as s,jc as n,kc as f,pa as o,tc as c}from"./chunk-OJMQBH6T.js";var y=(()=>{class e{constructor(){this.dialogRef=o(h),this.route=o(g),this.modalConfig=new v,this.modalConfig.title="Switch to modern authorization",this.modalConfig.customWidth="450px",this.modalConfig.hideCancel=!0,this.modalConfig.headerType=M.Warning,this.modalConfig.okText="Setup"}onClose(){this.dialogRef.close()}onOk(){this.dialogRef.close(),this.route.navigate(["/menu/users"])}static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275cmp=m({type:e,selectors:[["app-modal-user-migration-confirmation"]],decls:19,vars:1,consts:[[3,"onOk","onCancel","config"],["content",""],[1,"d-flex","align-items-center","justify-content-between","gap-6"],[1,"text-center",2,"width","300px"],[1,"fa-solid","fa-users-gear","fa-6x"],[1,"lh-base"],["href","https://support.dealpos.com/en/articles/12636364-how-to-migrate-user-in-dealpos-omnichannel","target","_blank"]],template:function(r,l){r&1&&(i(0,"modal-material",0),c("onOk",function(){return l.onOk()})("onCancel",function(){return l.onClose()}),i(1,"div",1)(2,"div",2)(3,"div",3),f(4,"i",4),n(),i(5,"div",5)(6,"p"),t(7," We have introduced a new Modern Authorization, Please switch from "),i(8,"b"),t(9,"legacy"),n(),t(10," to "),i(11,"b"),t(12,"modern"),n(),t(13," authorization by inviting your users. "),n(),i(14,"div"),t(15," Please refer to this "),i(16,"a",6),t(17,"article"),n(),t(18," for more information "),n()()()()()),r&2&&d("config",l.modalConfig)},dependencies:[p,S],encapsulation:2})}}return e})();var R=(()=>{class e{constructor(){this.dialog=o(C),this.tokenService=o(u),this.dialogRef=null}openDialogMigrationConfirmation(){this.tokenService.getUser()?.AuthorizationMode===x.Legacy&&!this.dialogRef&&(this.dialogRef=this.dialog.open(y),this.dialogRef.afterClosed().subscribe(()=>{this.dialogRef=null}))}resetDialogState(){this.dialogRef&&(this.dialogRef.close(),this.dialogRef=null)}static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275prov=s({token:e,factory:e.\u0275fac,providedIn:"root"})}}return e})();var B=(e,b)=>(o(R).openDialogMigrationConfirmation(),!0);export{B as a};
@@ -1 +1 @@
1
- import{i as k}from"./chunk-FHWKSD5A.js";import{a as A,b as F,d as U,e as W}from"./chunk-PYXL7UF7.js";import{A as L,a as D,h as V,m as I}from"./chunk-5PS6ZS3N.js";import{n as E}from"./chunk-FXQKRJWU.js";import{Gb as M,Gc as p,Ic as f,Kc as O,Lc as T,Mb as u,Mc as N,Oa as d,Qc as w,Yb as s,dc as y,ic as a,jc as o,kc as h,oc as x,pa as S,pb as g,rb as r,tc as C,uc as _,ya as v,za as b}from"./chunk-OJMQBH6T.js";function z(t,m){if(t&1&&(a(0,"span",3),h(1,"img",4),o(),a(2,"span"),p(3),o()),t&2){let e=m.item;r(),s("src",e==null?null:e.Img,g),r(2),f(" ",e.Name," ")}}function P(t,m){if(t&1){let e=x();a(0,"span",6),C("click",function(){v(e);let n=_(),c=n.item,l=n.clear;return b(l(c))}),p(1,"x"),o()}}function j(t,m){if(t&1&&(a(0,"span",3),h(1,"img",4),o(),a(2,"span"),p(3),o(),u(4,P,2,0,"span",5)),t&2){let e=m.item,i=_();r(),s("src",e==null?null:e.Img,g),r(2),f(" ",e.Name," "),r(),y(i.clearable()?4:-1)}}var Y=(()=>{class t{constructor(){this.authService=S(k),this.multiple=d(!1),this.clearable=d(!0),this.options=this.authService.getChannels(),this.onChange=e=>{}}onChannelChange(e){this.onChange(e)}writeValue(e){this.selectedChannels=e}registerOnChange(e){this.onChange=e}registerOnTouched(e){}setDisabledState(e){}static{this.\u0275fac=function(i){return new(i||t)}}static{this.\u0275cmp=M({type:t,selectors:[["channel-select-options"]],inputs:{multiple:[1,"multiple"],clearable:[1,"clearable"]},features:[w([{provide:D,multi:!0,useExisting:t}])],decls:3,vars:4,consts:[["bindLabel","Name","name","channelid","bindValue","ID","placeholder","Select Channel","appendTo","body",1,"center-text",3,"ngModelChange","clearable","items","ngModel","multiple"],["ng-option-tmp",""],["ng-label-tmp",""],[1,"me-2"],[2,"width","18px",3,"src"],["aria-hidden","true",1,"ng-value-icon","right"],["aria-hidden","true",1,"ng-value-icon","right",3,"click"]],template:function(i,n){i&1&&(a(0,"ng-select",0),N("ngModelChange",function(l){return T(n.selectedChannels,l)||(n.selectedChannels=l),l}),C("ngModelChange",function(l){return n.onChannelChange(l)}),u(1,z,4,2,"ng-template",1)(2,j,5,3,"ng-template",2),o()),i&2&&(s("clearable",n.clearable())("items",n.options),O("ngModel",n.selectedChannels),s("multiple",n.multiple()))},dependencies:[E,W,U,A,F,L,V,I],encapsulation:2})}}return t})();export{Y as a};
1
+ import{i as k}from"./chunk-WWLC64XZ.js";import{a as A,b as F,d as U,e as W}from"./chunk-PYXL7UF7.js";import{A as L,a as D,h as V,m as I}from"./chunk-5PS6ZS3N.js";import{n as E}from"./chunk-FXQKRJWU.js";import{Gb as M,Gc as p,Ic as f,Kc as O,Lc as T,Mb as u,Mc as N,Oa as d,Qc as w,Yb as s,dc as y,ic as a,jc as o,kc as h,oc as x,pa as S,pb as g,rb as r,tc as C,uc as _,ya as v,za as b}from"./chunk-OJMQBH6T.js";function z(t,m){if(t&1&&(a(0,"span",3),h(1,"img",4),o(),a(2,"span"),p(3),o()),t&2){let e=m.item;r(),s("src",e==null?null:e.Img,g),r(2),f(" ",e.Name," ")}}function P(t,m){if(t&1){let e=x();a(0,"span",6),C("click",function(){v(e);let n=_(),c=n.item,l=n.clear;return b(l(c))}),p(1,"x"),o()}}function j(t,m){if(t&1&&(a(0,"span",3),h(1,"img",4),o(),a(2,"span"),p(3),o(),u(4,P,2,0,"span",5)),t&2){let e=m.item,i=_();r(),s("src",e==null?null:e.Img,g),r(2),f(" ",e.Name," "),r(),y(i.clearable()?4:-1)}}var Y=(()=>{class t{constructor(){this.authService=S(k),this.multiple=d(!1),this.clearable=d(!0),this.options=this.authService.getChannels(),this.onChange=e=>{}}onChannelChange(e){this.onChange(e)}writeValue(e){this.selectedChannels=e}registerOnChange(e){this.onChange=e}registerOnTouched(e){}setDisabledState(e){}static{this.\u0275fac=function(i){return new(i||t)}}static{this.\u0275cmp=M({type:t,selectors:[["channel-select-options"]],inputs:{multiple:[1,"multiple"],clearable:[1,"clearable"]},features:[w([{provide:D,multi:!0,useExisting:t}])],decls:3,vars:4,consts:[["bindLabel","Name","name","channelid","bindValue","ID","placeholder","Select Channel","appendTo","body",1,"center-text",3,"ngModelChange","clearable","items","ngModel","multiple"],["ng-option-tmp",""],["ng-label-tmp",""],[1,"me-2"],[2,"width","18px",3,"src"],["aria-hidden","true",1,"ng-value-icon","right"],["aria-hidden","true",1,"ng-value-icon","right",3,"click"]],template:function(i,n){i&1&&(a(0,"ng-select",0),N("ngModelChange",function(l){return T(n.selectedChannels,l)||(n.selectedChannels=l),l}),C("ngModelChange",function(l){return n.onChannelChange(l)}),u(1,z,4,2,"ng-template",1)(2,j,5,3,"ng-template",2),o()),i&2&&(s("clearable",n.clearable())("items",n.options),O("ngModel",n.selectedChannels),s("multiple",n.multiple()))},dependencies:[E,W,U,A,F,L,V,I],encapsulation:2})}}return t})();export{Y as a};
@@ -1,2 +1,2 @@
1
- import{a as R}from"./chunk-EHBCYQSG.js";import{b as ze}from"./chunk-GRYGUILI.js";import"./chunk-HVCIQI7B.js";import"./chunk-QS22J2SC.js";import"./chunk-EHUVS2VB.js";import{a as Ze}from"./chunk-OHVOVAKD.js";import"./chunk-IITU3NV6.js";import{a as ee}from"./chunk-XHAXYWZ7.js";import{a as Ge,b as Ye,c as Ke,d as J,e as te}from"./chunk-NWWYOZ4V.js";import{a as Qe,b as He}from"./chunk-YTCIQBSO.js";import"./chunk-2O4IEGGR.js";import"./chunk-VFATXJRG.js";import"./chunk-EPBVNII2.js";import"./chunk-UZWED4UK.js";import"./chunk-4YRBARG2.js";import"./chunk-5CKVZBHM.js";import"./chunk-BKRCW7SH.js";import"./chunk-RGAKHXPF.js";import"./chunk-T2OSIFLN.js";import"./chunk-QW4EOJRM.js";import"./chunk-RHHHL4OR.js";import{a as We}from"./chunk-KRQHTRFM.js";import"./chunk-Q4N2QUV6.js";import"./chunk-7G6GQTSH.js";import"./chunk-IHSGQFDX.js";import"./chunk-MO53T3IK.js";import"./chunk-W3JTS22H.js";import"./chunk-SDUUFQUI.js";import"./chunk-6L7TD5DW.js";import"./chunk-6OMSPZZC.js";import"./chunk-3RK6DDJD.js";import"./chunk-HIC5QC3Y.js";import"./chunk-JBT7GBCM.js";import{a as q}from"./chunk-UMP6ZMEJ.js";import"./chunk-OZ7LWNOK.js";import"./chunk-YFDFIBAG.js";import"./chunk-RC5PUUVM.js";import{a as Ue,b as Be,c as $e}from"./chunk-GHVAGYK3.js";import"./chunk-JVNHFIYT.js";import{a as je}from"./chunk-3YP6ORBR.js";import"./chunk-6VYFG4AQ.js";import{i as Te}from"./chunk-FHWKSD5A.js";import"./chunk-Z3ITXK3D.js";import"./chunk-ACIMXBIC.js";import"./chunk-TGMCGROM.js";import{a as X}from"./chunk-CGOB6Y3X.js";import{b as ve,e as Ie}from"./chunk-WN5DZGA4.js";import"./chunk-4NEKWRL7.js";import{e as De}from"./chunk-PYXL7UF7.js";import{c as f}from"./chunk-PW42BQIY.js";import{b as Me,c as Ve,d as ke,j as Re,k as Le,l as Ne,m as Ae,n as Oe}from"./chunk-HJXYT6MI.js";import{A as ye,b as Ce,c as ge,h as fe,m as xe,o as Se}from"./chunk-5PS6ZS3N.js";import"./chunk-V3USB3ZU.js";import{a as we,b as be,c as Fe}from"./chunk-ERXVXBTU.js";import{r as Pe,s as Ee}from"./chunk-MFQQEEHJ.js";import"./chunk-GZKOMS4T.js";import{H as ue,J as he,d as me,g as de,j as $,k as W,m as _e,n as j}from"./chunk-FXQKRJWU.js";import{$c as g,Fc as K,G as Q,Gb as U,Gc as c,Hc as O,Ic as I,Kc as b,Lc as F,Mb as h,Mc as T,Nc as re,Oc as se,Pc as ce,Qc as B,Ra as V,Rc as pe,Sc as M,Yb as m,Z as N,ac as ae,ad as y,bd as k,cd as Z,dc as v,ea as H,ec as z,gc as G,hc as Y,ic as a,jc as l,kc as x,lc as P,mc as E,oc as S,pa as w,pb as A,rb as s,tc as C,uc as r,v as L,xb as D,xc as le,ya as d,za as _}from"./chunk-OJMQBH6T.js";import"./chunk-EU2KAMEK.js";import{a as oe}from"./chunk-66YHNWRR.js";var tt=()=>["/menu/order/download"];function nt(n,p){if(n&1&&(a(0,"li",4)(1,"div"),c(2," The last time you manually download your order is on "),a(3,"span",8),c(4),g(5,"date"),l()(),a(6,"div",9),c(7),l()()),n&2){r();let e=ce(0);s(4),I(" ",k(5,2,e==null?null:e.OrderDownloadLatestOn,"dd MMM yyyy HH:mm")," "),s(3),I("(",e==null?null:e.calculatedDate,")")}}function it(n,p){n&1&&(a(0,"li",4),c(1," The last time you manually download your order is on (-) "),l())}var qe=(()=>{class n{constructor(){this.dialogRef=w(Me),this.data=w(Ve),this.modalConfig=new Re,this.inventoryService=w(R),this.lastDownloadInfo$=this.inventoryService.getLastInfoDownloadInventory(this.data.channelId).pipe(L(e=>{let o=e.OrderDownloadLatestOn!=f.MinDate,t=null,i=null;return o&&(t=new Date(e.OrderDownloadLatestOn),i=f.convertToReadableDate(t)),{OrderDownloadLatestOn:t,calculatedDate:i}}),N(1)),this.selectedProducts=V(this.data.selectedProducts||[]),this.modalConfig.title="Manual Inventory Sync",this.modalConfig.customWidth="500px",this.modalConfig.bodyScrollable=!0,this.modalConfig.hideOk=!0,this.modalConfig.hideCancel=!0}onUpdate(){this.dialogRef.close(!0)}onCancel(){this.dialogRef.close(!1)}static{this.\u0275fac=function(o){return new(o||n)}}static{this.\u0275cmp=U({type:n,selectors:[["app-dialog-update-product-info"]],features:[B([R])],decls:16,vars:8,consts:[[3,"onCancel","config"],["content",""],[1,"container"],[1,"mt-8"],[1,"lh-base"],["footer",""],[1,"btn","btn-light-blue","me-6","text-primary","btn-lg","fw-bold","mx-3","py-8",3,"click","routerLink"],[1,"btn","btn-light-blue","me-6","text-primary","btn-lg","fw-bold","mx-3","py-8",3,"click","keyup.F2"],[1,"fw-bold","me-1"],[1,"fw-bold"]],template:function(o,t){if(o&1){let i=S();re(0),g(1,"async"),a(2,"modal-material",0),C("onCancel",function(){return d(i),_(t.onCancel())}),a(3,"div",1)(4,"div",2)(5,"h4"),c(6),l(),a(7,"div",3)(8,"ul"),h(9,nt,8,5,"li",4)(10,it,2,0,"li",4),l()()()(),a(11,"div",5)(12,"a",6),C("click",function(){return d(i),_(t.onCancel())}),c(13," Download "),l(),a(14,"button",7),C("click",function(){return d(i),_(t.onUpdate())})("keyup.F2",function(){return d(i),_(t.onUpdate())}),c(15," Update Anyway "),l()()()}if(o&2){let i=se(y(1,4,t.lastDownloadInfo$));s(2),m("config",t.modalConfig),s(4),I("",t.selectedProducts().length," Product(s) will be updated."),s(3),v(i!=null&&i.OrderDownloadLatestOn?9:10),s(3),m("routerLink",pe(7,tt))}},dependencies:[Le,j,$,W,he,ue],encapsulation:2})}}return n})();var ne=n=>[n],ot=n=>({"text-decoration-line-through":n}),at=n=>({"me-10":n}),lt=n=>({"bg-gradient-warning":n}),rt=n=>({cursor:n});function st(n,p){if(n&1){let e=S();a(0,"button",39),C("click",function(){d(e);let t=r().ngIf,i=r(2);return _(i.onScanInventory(t))}),x(1,"i",40),c(2,"Refresh "),l()}}function ct(n,p){if(n&1){let e=S();a(0,"div",37)(1,"button",41),C("click",function(){d(e);let t=r().ngIf,i=r(2);return _(i.onOpenDialogUpdateStockInfo(t))}),x(2,"i",42),c(3," Update "),l(),x(4,"button",43),a(5,"ul",44)(6,"a",45),C("click",function(){d(e);let t=r(3);return _(t.openExportDialog())}),x(7,"i",46),a(8,"span"),c(9,"Export"),l()()()()}}function pt(n,p){if(n&1){let e=S();a(0,"button",47),C("click",function(){d(e);let t=r(3);return _(t.openExportDialog())}),x(1,"i",46),a(2,"span"),c(3,"Export"),l()()}}function mt(n,p){if(n&1&&(a(0,"div"),h(1,st,3,0,"button",36)(2,ct,10,0,"div",37)(3,pt,4,0,"button",38),l()),n&2){let e=p.ngIf,o=r(2);s(),m("ngIf",o.productService.hasSelectionVariant(e)),s(),v(o.productService.hasSelectionVariant(e)?2:3)}}function dt(n,p){n&1&&(a(0,"div",48)(1,"span"),c(2," showing only different stock, please press next to populate more data "),l()())}function _t(n,p){if(n&1){let e=S();a(0,"th")(1,"input",49),T("ngModelChange",function(t){d(e);let i=r(3);return F(i.checkboxState,t)||(i.checkboxState=t),_(t)}),C("ngModelChange",function(){let t=d(e).ngIf,i=r(3);return _(i.onCheckboxStateChange(t))}),l()()}if(n&2){let e=r(3);s(),b("ngModel",e.checkboxState)}}function ut(n,p){if(n&1&&(P(0),h(1,_t,2,1,"th",5),g(2,"async"),E()),n&2){let e=r(2);s(),m("ngIf",y(2,1,e.products$))}}function ht(n,p){n&1&&(a(0,"th",33),c(1," Reserved "),l())}function Ct(n,p){if(n&1){let e=S();a(0,"input",65),T("ngModelChange",function(t){d(e);let i=r(4).$implicit;return F(i.selected,t)||(i.selected=t),_(t)}),C("ngModelChange",function(){d(e);let t=r(4).$implicit,i=r(2);return _(i.onCheckboxStateProduct(t))}),l()}if(n&2){let e=r(4).$implicit;b("ngModel",e.selected)}}function gt(n,p){if(n&1&&(P(0),a(1,"div",63),h(2,Ct,1,1,"input",64),l(),E()),n&2){let e=r(3).$implicit;s(),m("ngClass",M(2,at,e.Variants.length<=1)),s(),v(e.Variants.length>1?2:-1)}}function ft(n,p){if(n&1){let e=S();a(0,"img",66),C("click",function(t){d(e);let i=r(3).$implicit,u=r(2);return _(u.onZoomImage(t,i==null?null:i.ImageUrl))}),l()}if(n&2){let e=r(3).$implicit;le("src",e==null?null:e.ThumbnailUrl,A)}}function xt(n,p){n&1&&x(0,"img",60)}function St(n,p){if(n&1&&(x(0,"br"),a(1,"div",67),x(2,"i",68),a(3,"small"),c(4),l()()),n&2){let e=r(3).$implicit;s(4),I("(",e==null?null:e.Category,")")}}function yt(n,p){if(n&1&&(a(0,"td",58)(1,"div",14),h(2,gt,3,4,"ng-container",27),a(3,"div"),h(4,ft,1,1,"img",59)(5,xt,1,0,"img",60),l()()(),a(6,"td",61)(7,"span",62),c(8),l(),h(9,St,5,1),l()),n&2){let e=r(2).$implicit,o=r(2);m("rowSpan",e==null?null:e.Variants.length),s(2),m("ngxPermissionsOnly",M(6,ne,o.inventoryUpdateRole)),s(2),v(e!=null&&e.ThumbnailUrl?4:5),s(2),m("rowSpan",e==null?null:e.Variants.length),s(2),O(e==null?null:e.Name),s(),v(e.CategoryID!==null&&e.CategoryID!=o.guidEmpty?9:-1)}}function vt(n,p){if(n&1){let e=S();a(0,"input",49),T("ngModelChange",function(t){d(e);let i=r(3).$implicit;return F(i.selected,t)||(i.selected=t),_(t)}),l()}if(n&2){let e=r(3).$implicit;b("ngModel",e.selected)}}function It(n,p){if(n&1&&h(0,vt,1,1,"input",70),n&2){let e=r(2).$implicit;v((e==null?null:e.Inventory)<=1e5?0:-1)}}function wt(n,p){if(n&1){let e=S();a(0,"input",49),T("ngModelChange",function(t){d(e);let i=r(2).$implicit;return F(i.selected,t)||(i.selected=t),_(t)}),l()}if(n&2){let e=r(2).$implicit;b("ngModel",e.selected)}}function bt(n,p){if(n&1&&(P(0),a(1,"td",69),h(2,It,1,1)(3,wt,1,1,"input",70),l(),E()),n&2){let e=r().$implicit;s(2),v((e==null?null:e.Channel[0].TypeID)==1?2:(e==null?null:e.Inventory)>=0?3:-1)}}function Ft(n,p){n&1&&(a(0,"div",71),c(1," Not Found "),l())}function Tt(n,p){if(n&1&&(a(0,"div")(1,"span",72),c(2),g(3,"number"),l(),c(4," => "),a(5,"span",73),c(6),g(7,"number"),l()()),n&2){let e=r().$implicit;s(2),I(" ",y(3,2,e==null||e.I==null?null:e.I.Available),""),s(4),O(y(7,4,e==null?null:e.Inventory))}}function Dt(n,p){if(n&1&&(c(0),g(1,"number")),n&2){let e=r().$implicit;I(" ",y(1,1,e==null?null:e.Inventory)," ")}}function Pt(n,p){if(n&1&&(P(0),a(1,"div",74)(2,"a",75),x(3,"i",76),l()(),E()),n&2){let e=r().$implicit,o=r(3);s(2),m("href",o.hostName+"/menu/Products/Catalog/Variants/Info?ID="+(e==null?null:e.ID),A)}}function Et(n,p){if(n&1){let e=S();a(0,"span",81),C("click",function(){d(e);let t=r(2).$implicit,i=r().$implicit,u=r(2);return _(u.openTableDialog(i,t))}),c(1),g(2,"number"),l()}if(n&2){let e=r(2).$implicit,o=r(3);ae(M(5,rt,o.hasInventoryEdit())),s(),I(" ",y(2,3,e==null||e.Channel[0]==null?null:e.Channel[0].Inventory)," ")}}function Mt(n,p){if(n&1){let e=S();a(0,"td",77)(1,"div",53)(2,"div"),h(3,Et,3,7,"span",78),g(4,"async"),l(),a(5,"div",74)(6,"a",75),x(7,"i",76),l()(),a(8,"div",74)(9,"span",79),C("click",function(){d(e);let t=r().$implicit,i=r(3);return _(i.refreshInventory(t==null||t.Channel[0]==null?null:t.Channel[0].ChannelItemID,t==null||t.Channel[0]==null?null:t.Channel[0].ChannelVariationID,t==null||t.Channel[0]==null?null:t.Channel[0].ChannelID,t==null?null:t.ID))}),x(10,"i",80),l()()()()}if(n&2){let e=r().$implicit,o=r(3);m("ngClass",M(5,lt,(e==null?null:e.Inventory)!=(e==null||e.Channel[0]==null?null:e.Channel[0].Inventory))),s(3),m("ngIf",y(4,3,o.products$)),s(3),m("href",e==null||e.Channel[0]==null?null:e.Channel[0].Url,A)}}function Vt(n,p){if(n&1&&(P(0),a(1,"span",82),c(2),g(3,"number"),l(),E()),n&2){let e=r(2).$implicit;s(2),I(" (",y(3,1,e==null||e.Channel[0]==null?null:e.Channel[0].InventoryReserved),") ")}}function kt(n,p){n&1&&c(0," - ")}function Rt(n,p){if(n&1&&(P(0),a(1,"td",51),h(2,Vt,4,3,"ng-container",57)(3,kt,1,0,"ng-template",null,1,Z),l(),E()),n&2){let e=K(4),o=r().$implicit;s(2),m("ngIf",o==null||o.Channel[0]==null?null:o.Channel[0].InventoryReserved)("ngIfElse",e)}}function Lt(n,p){n&1&&(P(0),c(1," - "),E())}function Nt(n,p){if(n&1&&(a(0,"span",83),g(1,"date"),c(2),g(3,"date"),l()),n&2){let e=r().$implicit;m("matTooltip",k(1,2,e==null||e.Channel[0]==null?null:e.Channel[0].LastInventorySync,"dd MMMM yyyy HH:mm:ss")),s(2),I(" ",k(3,5,e==null||e.Channel[0]==null?null:e.Channel[0].LastInventorySync,"dd MMM yy HH:mm")," ")}}function At(n,p){if(n&1&&(a(0,"tr"),h(1,yt,10,8),a(2,"td",50),c(3),l(),a(4,"td",51)(5,"span",52),c(6),l()(),h(7,bt,4,1,"ng-container",27),a(8,"td")(9,"div",53),h(10,Ft,2,0,"div",54)(11,Tt,8,6,"div")(12,Dt,2,3)(13,Pt,4,1,"ng-container",5),l()(),h(14,Mt,11,7,"td",55)(15,Rt,5,2,"ng-container",5),a(16,"td",56),h(17,Lt,2,0,"ng-container",57)(18,Nt,4,8,"ng-template",null,0,Z),l()()),n&2){let e=p.$implicit,o=p.$index,t=K(19),i=r(3);s(),v(o==0?1:-1),s(2),O(e==null?null:e.Model),s(2),m("matTooltip",e.Discontinued?i.discontinuedVariantMsg:"")("ngClass",M(14,ot,e.Discontinued)),s(),O(e==null?null:e.Code),s(),m("ngxPermissionsOnly",M(16,ne,i.inventoryUpdateRole)),s(3),m("ngIf",(e==null?null:e.I)==null),s(),v((e==null?null:e.I)!=null&&(e==null?null:e.Inventory)!=(e==null||e.I==null?null:e.I.Available)?11:-1),s(),v((e==null?null:e.Inventory)==(e==null||e.I==null?null:e.I.Available)?12:-1),s(),m("ngIf",(e==null?null:e.I)!=null),s(),m("ngIf",e==null?null:e.Channel),s(),m("ngIf",i.isShowReservedColumn),s(2),m("ngIf",(e==null||e.Channel[0]==null?null:e.Channel[0].LastInventorySync)==i.minDate)("ngIfElse",t)}}function Ot(n,p){if(n&1&&(a(0,"tbody"),G(1,At,20,18,"tr",null,z),l()),n&2){let e=p.$implicit;s(),Y(e.Variants)}}function Ut(n,p){if(n&1){let e=S();a(0,"mainpanel",3),C("onSubmit",function(t){d(e);let i=r();return _(i.onSearch(t))}),a(1,"actions")(2,"div",4),h(3,mt,4,2,"div",5),g(4,"async"),l()(),a(5,"filters")(6,"div")(7,"label",6),c(8,"Channel"),l(),a(9,"multiwarehouse-tree-select",7),C("onChannelChange",function(t){d(e);let i=r();return _(i.onChannelChange(t))}),l()(),a(10,"div",8)(11,"label",9),c(12,"PageNumber"),l(),a(13,"input",10),T("ngModelChange",function(t){d(e);let i=r();return F(i.searchFilter.PageNumber,t)||(i.searchFilter.PageNumber=t),_(t)}),l()(),a(14,"div",8)(15,"label",11),c(16,"Page Size"),l(),a(17,"input",12),T("ngModelChange",function(t){d(e);let i=r();return F(i.searchFilter.RowCount,t)||(i.searchFilter.RowCount=t),_(t)}),l()(),a(18,"div",8)(19,"label",13),c(20,"Quantity From - To"),l(),a(21,"div",14)(22,"input",15),T("ngModelChange",function(t){d(e);let i=r();return F(i.searchFilter.QuantityFrom,t)||(i.searchFilter.QuantityFrom=t),_(t)}),l(),c(23," - "),a(24,"input",16),T("ngModelChange",function(t){d(e);let i=r();return F(i.searchFilter.QuantityTo,t)||(i.searchFilter.QuantityTo=t),_(t)}),l()()()(),a(25,"content")(26,"div",17)(27,"div",18)(28,"div",19),h(29,dt,3,0,"div",20),a(30,"table",21),C("matSortChange",function(t){d(e);let i=r();return _(i.onSortVariant(t))}),a(31,"thead",22)(32,"tr")(33,"th",23),c(34," Product "),x(35,"br"),a(36,"mat-slide-toggle",24),C("toggleChange",function(){d(e);let t=r();return t.showDifferenceStock=!t.showDifferenceStock,_(t.onShowDifferenceStock())}),a(37,"small",13),c(38,"FILTER DIFFERENT INVENTORY"),l()()(),a(39,"th",25),c(40,"Variant"),l(),a(41,"th",26),c(42,"SKU"),l(),h(43,ut,3,3,"ng-container",27),a(44,"th",28),c(45," POS "),l(),a(46,"th",29)(47,"div",30),C("click",function(){d(e);let t=r();return _(t.openModalFilter())}),x(48,"img",31),a(49,"span",32),c(50),g(51,"stringLimit"),l()()(),h(52,ht,2,0,"th",33),a(53,"th",34),c(54,"Last Sync"),l()()(),G(55,Ot,3,0,"tbody",null,z),g(57,"async"),l(),a(58,"infinite-paginator",35),g(59,"async"),C("onNextPage",function(){d(e);let t=r();return _(t.infinitePagination.onNextPage(t.searchFilter))})("onLastPage",function(){d(e);let t=r();return _(t.infinitePagination.onLastPage(t.searchFilter))})("onGetRowCount",function(){d(e);let t=r();return _(t.infinitePagination.getRowCount(t.searchFilter))}),l()()()()()()}if(n&2){let e,o,t,i=r();m("headerTitle","Inventory Comparison")("pageData",i.pageData)("hideSearchBox",!1),s(3),m("ngIf",y(4,21,i.products$)),s(6),m("ngModel",(i.searchFilter==null?null:i.searchFilter.LocationID)||(i.searchFilter==null?null:i.searchFilter.ChannelID)),s(4),b("ngModel",i.searchFilter.PageNumber),s(4),b("ngModel",i.searchFilter.RowCount),s(5),b("ngModel",i.searchFilter.QuantityFrom),s(2),b("ngModel",i.searchFilter.QuantityTo),s(5),m("ngIf",(i.searchFilter==null?null:i.searchFilter.filterModel)==3),s(14),m("ngxPermissionsOnly",M(30,ne,i.inventoryUpdateRole)),s(4),m("matTooltip",((e=i.channelIdentity())==null||e.label==null?null:e.label.length)>13?(e=i.channelIdentity())==null?null:e.label:""),s(),m("src",(o=i.channelIdentity())==null?null:o.img,A),s(2),I(" ",k(51,23,(t=i.channelIdentity())==null?null:t.label,13)," "),s(2),v(i.isShowReservedColumn?52:-1),s(3),Y(y(57,26,i.products$)),s(3),m("totalData",i.infinitePagination.totalData())("hideCount",i.infinitePagination.hideCount())("rowCount",y(59,28,i.infinitePagination.totalRowCount$))("pageNumber",i.infinitePagination.pageNumber())("disableNextButton",i.infinitePagination.disableNextButton())("goToLastPage",i.infinitePagination.isLastPage())}}var An=(()=>{class n{constructor(e,o,t,i,u,ie,Xe){this.http=e,this.toastr=o,this.dialog=t,this.productService=i,this.authService=u,this.biggerPictureService=ie,this.mainPanelService=Xe,this.infinitePagination=w(J),this.ngxPermissionsService=w(we),this.updateResHandling=w(te),this.inventoryService=w(R),this.checkboxState=!1,this.showDifferenceStock=!1,this.loaderApi="InventoryLoader/Load",this.fetchApi="Inventory/GetSingleChannelComparison",this.rowCountApi="Inventory/GetInventoryByChannelRowCount",this.minDate=f.MinDate,this.isShowReservedColumn=!0,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.guidEmpty=f.GuidEMpty,this.selectedChannel=V(null),this.channelIdentity=V({img:null,label:null}),this.inventoryUpdateRole=q.InventoryUpdate,this.hasInventoryEdit=V(!0),this.pageData={Title:"Inventory Realtime",Nav:[{Title:"Inventory Cache",Url:"/menu/inventory",Active:!1},{Title:"Inventory Realtime",Url:"/menu/inventory/realtime",Active:!0}]}}ngOnInit(){this.initRoles(),this.hostName=this.authService.getDomain(),this.initPageLoader(),this.sourceObs$=this.infinitePagination.data$.pipe(H(e=>{this.checkShowReservedColumn(e)}),L(e=>(e=this.calculateAvailableStock(e),e)),N(1)),this.products$=this.sourceObs$}initRoles(){this.ngxPermissionsService.hasPermission(q.InventoryUpdate).then(e=>this.hasInventoryEdit.set(e))}calculateAvailableStock(e){return e.map(t=>(t.totalAvailable=t.Variants.reduce((i,u)=>(i+=u.I?.Available||0,i),0),t))}checkShowReservedColumn(e){let o=0,t;e.forEach(i=>{t=i.Variants.find(u=>f.IsNotEmpty(u?.Channel[0]?.InventoryReserved)),t&&(o+=1)}),this.isShowReservedColumn=o>0}initPageLoader(){this.infinitePagination.fetchDataEndpoint=this.fetchApi,this.infinitePagination.fethRowCountEndpoint=this.rowCountApi,this.loader$=this.http.post(`/api/${this.loaderApi}`,{}).pipe(N(1),H(e=>{this.searchFilter={RowCount:e.Filter.PageSize,filterModel:1,PageNumber:1,ChannelID:e.Filter.ChannelID,LocationID:e.Filter.LocationID},this.initReloadData(),this.showToastrMarketplaceInactive(!e.Filter.IsMarketplaceAppActive)}))}onChannelChange(e){let o=Object.assign({},e);this.selectedChannel.set(o),f.IsEmpty(this.channelIdentity()?.label)&&this.setChannelFilter()}setChannelFilter(){if(this.selectedChannel()){let e=Object.assign({},this.selectedChannel());f.IsNotEmpty(e.parent)?(this.searchFilter.LocationID=e.id,this.searchFilter.ChannelID=e?.parent?.id,e.label=e?.parent?.label+" - "+e?.label,e.img=f.getChannelLogoByTypeId(e?.parent?.typeid)):(this.searchFilter.LocationID=null,e.img=f.getChannelLogoByTypeId(e?.typeid),this.searchFilter.ChannelID=e?.id,this.selectedChannel.set(e)),this.channelIdentity.update(()=>({img:e.img,label:e.label}))}}initReloadData(){this.infinitePagination.reloadPagination(this.searchFilter)}showToastrMarketplaceInactive(e){e&&this.toastr.warning(`Automatic inventory sync disabled.
1
+ import{a as R}from"./chunk-EHBCYQSG.js";import{b as ze}from"./chunk-GRYGUILI.js";import"./chunk-HVCIQI7B.js";import"./chunk-QS22J2SC.js";import"./chunk-EHUVS2VB.js";import{a as Ze}from"./chunk-OHVOVAKD.js";import"./chunk-IITU3NV6.js";import{a as ee}from"./chunk-XHAXYWZ7.js";import{a as Ge,b as Ye,c as Ke,d as J,e as te}from"./chunk-NWWYOZ4V.js";import{a as Qe,b as He}from"./chunk-YTCIQBSO.js";import"./chunk-2O4IEGGR.js";import"./chunk-VFATXJRG.js";import"./chunk-EPBVNII2.js";import"./chunk-UZWED4UK.js";import"./chunk-4YRBARG2.js";import"./chunk-5CKVZBHM.js";import"./chunk-BKRCW7SH.js";import"./chunk-RGAKHXPF.js";import"./chunk-T2OSIFLN.js";import"./chunk-QW4EOJRM.js";import"./chunk-RHHHL4OR.js";import{a as We}from"./chunk-PE4SWUEZ.js";import"./chunk-Q4N2QUV6.js";import"./chunk-7G6GQTSH.js";import"./chunk-IHSGQFDX.js";import"./chunk-MO53T3IK.js";import"./chunk-W3JTS22H.js";import"./chunk-SDUUFQUI.js";import"./chunk-6L7TD5DW.js";import"./chunk-6OMSPZZC.js";import"./chunk-3RK6DDJD.js";import"./chunk-HIC5QC3Y.js";import"./chunk-JBT7GBCM.js";import{a as q}from"./chunk-UMP6ZMEJ.js";import"./chunk-OZ7LWNOK.js";import"./chunk-YFDFIBAG.js";import"./chunk-RC5PUUVM.js";import{a as Ue,b as Be,c as $e}from"./chunk-GHVAGYK3.js";import"./chunk-JVNHFIYT.js";import{a as je}from"./chunk-3YP6ORBR.js";import"./chunk-6RMBCW2O.js";import{i as Te}from"./chunk-WWLC64XZ.js";import"./chunk-Z3ITXK3D.js";import"./chunk-ACIMXBIC.js";import"./chunk-TGMCGROM.js";import{a as X}from"./chunk-CGOB6Y3X.js";import{b as ve,e as Ie}from"./chunk-WN5DZGA4.js";import"./chunk-4NEKWRL7.js";import{e as De}from"./chunk-PYXL7UF7.js";import{c as f}from"./chunk-PW42BQIY.js";import{b as Me,c as Ve,d as ke,j as Re,k as Le,l as Ne,m as Ae,n as Oe}from"./chunk-HJXYT6MI.js";import{A as ye,b as Ce,c as ge,h as fe,m as xe,o as Se}from"./chunk-5PS6ZS3N.js";import"./chunk-V3USB3ZU.js";import{a as we,b as be,c as Fe}from"./chunk-ERXVXBTU.js";import{r as Pe,s as Ee}from"./chunk-MFQQEEHJ.js";import"./chunk-GZKOMS4T.js";import{H as ue,J as he,d as me,g as de,j as $,k as W,m as _e,n as j}from"./chunk-FXQKRJWU.js";import{$c as g,Fc as K,G as Q,Gb as U,Gc as c,Hc as O,Ic as I,Kc as b,Lc as F,Mb as h,Mc as T,Nc as re,Oc as se,Pc as ce,Qc as B,Ra as V,Rc as pe,Sc as M,Yb as m,Z as N,ac as ae,ad as y,bd as k,cd as Z,dc as v,ea as H,ec as z,gc as G,hc as Y,ic as a,jc as l,kc as x,lc as P,mc as E,oc as S,pa as w,pb as A,rb as s,tc as C,uc as r,v as L,xb as D,xc as le,ya as d,za as _}from"./chunk-OJMQBH6T.js";import"./chunk-EU2KAMEK.js";import{a as oe}from"./chunk-66YHNWRR.js";var tt=()=>["/menu/order/download"];function nt(n,p){if(n&1&&(a(0,"li",4)(1,"div"),c(2," The last time you manually download your order is on "),a(3,"span",8),c(4),g(5,"date"),l()(),a(6,"div",9),c(7),l()()),n&2){r();let e=ce(0);s(4),I(" ",k(5,2,e==null?null:e.OrderDownloadLatestOn,"dd MMM yyyy HH:mm")," "),s(3),I("(",e==null?null:e.calculatedDate,")")}}function it(n,p){n&1&&(a(0,"li",4),c(1," The last time you manually download your order is on (-) "),l())}var qe=(()=>{class n{constructor(){this.dialogRef=w(Me),this.data=w(Ve),this.modalConfig=new Re,this.inventoryService=w(R),this.lastDownloadInfo$=this.inventoryService.getLastInfoDownloadInventory(this.data.channelId).pipe(L(e=>{let o=e.OrderDownloadLatestOn!=f.MinDate,t=null,i=null;return o&&(t=new Date(e.OrderDownloadLatestOn),i=f.convertToReadableDate(t)),{OrderDownloadLatestOn:t,calculatedDate:i}}),N(1)),this.selectedProducts=V(this.data.selectedProducts||[]),this.modalConfig.title="Manual Inventory Sync",this.modalConfig.customWidth="500px",this.modalConfig.bodyScrollable=!0,this.modalConfig.hideOk=!0,this.modalConfig.hideCancel=!0}onUpdate(){this.dialogRef.close(!0)}onCancel(){this.dialogRef.close(!1)}static{this.\u0275fac=function(o){return new(o||n)}}static{this.\u0275cmp=U({type:n,selectors:[["app-dialog-update-product-info"]],features:[B([R])],decls:16,vars:8,consts:[[3,"onCancel","config"],["content",""],[1,"container"],[1,"mt-8"],[1,"lh-base"],["footer",""],[1,"btn","btn-light-blue","me-6","text-primary","btn-lg","fw-bold","mx-3","py-8",3,"click","routerLink"],[1,"btn","btn-light-blue","me-6","text-primary","btn-lg","fw-bold","mx-3","py-8",3,"click","keyup.F2"],[1,"fw-bold","me-1"],[1,"fw-bold"]],template:function(o,t){if(o&1){let i=S();re(0),g(1,"async"),a(2,"modal-material",0),C("onCancel",function(){return d(i),_(t.onCancel())}),a(3,"div",1)(4,"div",2)(5,"h4"),c(6),l(),a(7,"div",3)(8,"ul"),h(9,nt,8,5,"li",4)(10,it,2,0,"li",4),l()()()(),a(11,"div",5)(12,"a",6),C("click",function(){return d(i),_(t.onCancel())}),c(13," Download "),l(),a(14,"button",7),C("click",function(){return d(i),_(t.onUpdate())})("keyup.F2",function(){return d(i),_(t.onUpdate())}),c(15," Update Anyway "),l()()()}if(o&2){let i=se(y(1,4,t.lastDownloadInfo$));s(2),m("config",t.modalConfig),s(4),I("",t.selectedProducts().length," Product(s) will be updated."),s(3),v(i!=null&&i.OrderDownloadLatestOn?9:10),s(3),m("routerLink",pe(7,tt))}},dependencies:[Le,j,$,W,he,ue],encapsulation:2})}}return n})();var ne=n=>[n],ot=n=>({"text-decoration-line-through":n}),at=n=>({"me-10":n}),lt=n=>({"bg-gradient-warning":n}),rt=n=>({cursor:n});function st(n,p){if(n&1){let e=S();a(0,"button",39),C("click",function(){d(e);let t=r().ngIf,i=r(2);return _(i.onScanInventory(t))}),x(1,"i",40),c(2,"Refresh "),l()}}function ct(n,p){if(n&1){let e=S();a(0,"div",37)(1,"button",41),C("click",function(){d(e);let t=r().ngIf,i=r(2);return _(i.onOpenDialogUpdateStockInfo(t))}),x(2,"i",42),c(3," Update "),l(),x(4,"button",43),a(5,"ul",44)(6,"a",45),C("click",function(){d(e);let t=r(3);return _(t.openExportDialog())}),x(7,"i",46),a(8,"span"),c(9,"Export"),l()()()()}}function pt(n,p){if(n&1){let e=S();a(0,"button",47),C("click",function(){d(e);let t=r(3);return _(t.openExportDialog())}),x(1,"i",46),a(2,"span"),c(3,"Export"),l()()}}function mt(n,p){if(n&1&&(a(0,"div"),h(1,st,3,0,"button",36)(2,ct,10,0,"div",37)(3,pt,4,0,"button",38),l()),n&2){let e=p.ngIf,o=r(2);s(),m("ngIf",o.productService.hasSelectionVariant(e)),s(),v(o.productService.hasSelectionVariant(e)?2:3)}}function dt(n,p){n&1&&(a(0,"div",48)(1,"span"),c(2," showing only different stock, please press next to populate more data "),l()())}function _t(n,p){if(n&1){let e=S();a(0,"th")(1,"input",49),T("ngModelChange",function(t){d(e);let i=r(3);return F(i.checkboxState,t)||(i.checkboxState=t),_(t)}),C("ngModelChange",function(){let t=d(e).ngIf,i=r(3);return _(i.onCheckboxStateChange(t))}),l()()}if(n&2){let e=r(3);s(),b("ngModel",e.checkboxState)}}function ut(n,p){if(n&1&&(P(0),h(1,_t,2,1,"th",5),g(2,"async"),E()),n&2){let e=r(2);s(),m("ngIf",y(2,1,e.products$))}}function ht(n,p){n&1&&(a(0,"th",33),c(1," Reserved "),l())}function Ct(n,p){if(n&1){let e=S();a(0,"input",65),T("ngModelChange",function(t){d(e);let i=r(4).$implicit;return F(i.selected,t)||(i.selected=t),_(t)}),C("ngModelChange",function(){d(e);let t=r(4).$implicit,i=r(2);return _(i.onCheckboxStateProduct(t))}),l()}if(n&2){let e=r(4).$implicit;b("ngModel",e.selected)}}function gt(n,p){if(n&1&&(P(0),a(1,"div",63),h(2,Ct,1,1,"input",64),l(),E()),n&2){let e=r(3).$implicit;s(),m("ngClass",M(2,at,e.Variants.length<=1)),s(),v(e.Variants.length>1?2:-1)}}function ft(n,p){if(n&1){let e=S();a(0,"img",66),C("click",function(t){d(e);let i=r(3).$implicit,u=r(2);return _(u.onZoomImage(t,i==null?null:i.ImageUrl))}),l()}if(n&2){let e=r(3).$implicit;le("src",e==null?null:e.ThumbnailUrl,A)}}function xt(n,p){n&1&&x(0,"img",60)}function St(n,p){if(n&1&&(x(0,"br"),a(1,"div",67),x(2,"i",68),a(3,"small"),c(4),l()()),n&2){let e=r(3).$implicit;s(4),I("(",e==null?null:e.Category,")")}}function yt(n,p){if(n&1&&(a(0,"td",58)(1,"div",14),h(2,gt,3,4,"ng-container",27),a(3,"div"),h(4,ft,1,1,"img",59)(5,xt,1,0,"img",60),l()()(),a(6,"td",61)(7,"span",62),c(8),l(),h(9,St,5,1),l()),n&2){let e=r(2).$implicit,o=r(2);m("rowSpan",e==null?null:e.Variants.length),s(2),m("ngxPermissionsOnly",M(6,ne,o.inventoryUpdateRole)),s(2),v(e!=null&&e.ThumbnailUrl?4:5),s(2),m("rowSpan",e==null?null:e.Variants.length),s(2),O(e==null?null:e.Name),s(),v(e.CategoryID!==null&&e.CategoryID!=o.guidEmpty?9:-1)}}function vt(n,p){if(n&1){let e=S();a(0,"input",49),T("ngModelChange",function(t){d(e);let i=r(3).$implicit;return F(i.selected,t)||(i.selected=t),_(t)}),l()}if(n&2){let e=r(3).$implicit;b("ngModel",e.selected)}}function It(n,p){if(n&1&&h(0,vt,1,1,"input",70),n&2){let e=r(2).$implicit;v((e==null?null:e.Inventory)<=1e5?0:-1)}}function wt(n,p){if(n&1){let e=S();a(0,"input",49),T("ngModelChange",function(t){d(e);let i=r(2).$implicit;return F(i.selected,t)||(i.selected=t),_(t)}),l()}if(n&2){let e=r(2).$implicit;b("ngModel",e.selected)}}function bt(n,p){if(n&1&&(P(0),a(1,"td",69),h(2,It,1,1)(3,wt,1,1,"input",70),l(),E()),n&2){let e=r().$implicit;s(2),v((e==null?null:e.Channel[0].TypeID)==1?2:(e==null?null:e.Inventory)>=0?3:-1)}}function Ft(n,p){n&1&&(a(0,"div",71),c(1," Not Found "),l())}function Tt(n,p){if(n&1&&(a(0,"div")(1,"span",72),c(2),g(3,"number"),l(),c(4," => "),a(5,"span",73),c(6),g(7,"number"),l()()),n&2){let e=r().$implicit;s(2),I(" ",y(3,2,e==null||e.I==null?null:e.I.Available),""),s(4),O(y(7,4,e==null?null:e.Inventory))}}function Dt(n,p){if(n&1&&(c(0),g(1,"number")),n&2){let e=r().$implicit;I(" ",y(1,1,e==null?null:e.Inventory)," ")}}function Pt(n,p){if(n&1&&(P(0),a(1,"div",74)(2,"a",75),x(3,"i",76),l()(),E()),n&2){let e=r().$implicit,o=r(3);s(2),m("href",o.hostName+"/menu/Products/Catalog/Variants/Info?ID="+(e==null?null:e.ID),A)}}function Et(n,p){if(n&1){let e=S();a(0,"span",81),C("click",function(){d(e);let t=r(2).$implicit,i=r().$implicit,u=r(2);return _(u.openTableDialog(i,t))}),c(1),g(2,"number"),l()}if(n&2){let e=r(2).$implicit,o=r(3);ae(M(5,rt,o.hasInventoryEdit())),s(),I(" ",y(2,3,e==null||e.Channel[0]==null?null:e.Channel[0].Inventory)," ")}}function Mt(n,p){if(n&1){let e=S();a(0,"td",77)(1,"div",53)(2,"div"),h(3,Et,3,7,"span",78),g(4,"async"),l(),a(5,"div",74)(6,"a",75),x(7,"i",76),l()(),a(8,"div",74)(9,"span",79),C("click",function(){d(e);let t=r().$implicit,i=r(3);return _(i.refreshInventory(t==null||t.Channel[0]==null?null:t.Channel[0].ChannelItemID,t==null||t.Channel[0]==null?null:t.Channel[0].ChannelVariationID,t==null||t.Channel[0]==null?null:t.Channel[0].ChannelID,t==null?null:t.ID))}),x(10,"i",80),l()()()()}if(n&2){let e=r().$implicit,o=r(3);m("ngClass",M(5,lt,(e==null?null:e.Inventory)!=(e==null||e.Channel[0]==null?null:e.Channel[0].Inventory))),s(3),m("ngIf",y(4,3,o.products$)),s(3),m("href",e==null||e.Channel[0]==null?null:e.Channel[0].Url,A)}}function Vt(n,p){if(n&1&&(P(0),a(1,"span",82),c(2),g(3,"number"),l(),E()),n&2){let e=r(2).$implicit;s(2),I(" (",y(3,1,e==null||e.Channel[0]==null?null:e.Channel[0].InventoryReserved),") ")}}function kt(n,p){n&1&&c(0," - ")}function Rt(n,p){if(n&1&&(P(0),a(1,"td",51),h(2,Vt,4,3,"ng-container",57)(3,kt,1,0,"ng-template",null,1,Z),l(),E()),n&2){let e=K(4),o=r().$implicit;s(2),m("ngIf",o==null||o.Channel[0]==null?null:o.Channel[0].InventoryReserved)("ngIfElse",e)}}function Lt(n,p){n&1&&(P(0),c(1," - "),E())}function Nt(n,p){if(n&1&&(a(0,"span",83),g(1,"date"),c(2),g(3,"date"),l()),n&2){let e=r().$implicit;m("matTooltip",k(1,2,e==null||e.Channel[0]==null?null:e.Channel[0].LastInventorySync,"dd MMMM yyyy HH:mm:ss")),s(2),I(" ",k(3,5,e==null||e.Channel[0]==null?null:e.Channel[0].LastInventorySync,"dd MMM yy HH:mm")," ")}}function At(n,p){if(n&1&&(a(0,"tr"),h(1,yt,10,8),a(2,"td",50),c(3),l(),a(4,"td",51)(5,"span",52),c(6),l()(),h(7,bt,4,1,"ng-container",27),a(8,"td")(9,"div",53),h(10,Ft,2,0,"div",54)(11,Tt,8,6,"div")(12,Dt,2,3)(13,Pt,4,1,"ng-container",5),l()(),h(14,Mt,11,7,"td",55)(15,Rt,5,2,"ng-container",5),a(16,"td",56),h(17,Lt,2,0,"ng-container",57)(18,Nt,4,8,"ng-template",null,0,Z),l()()),n&2){let e=p.$implicit,o=p.$index,t=K(19),i=r(3);s(),v(o==0?1:-1),s(2),O(e==null?null:e.Model),s(2),m("matTooltip",e.Discontinued?i.discontinuedVariantMsg:"")("ngClass",M(14,ot,e.Discontinued)),s(),O(e==null?null:e.Code),s(),m("ngxPermissionsOnly",M(16,ne,i.inventoryUpdateRole)),s(3),m("ngIf",(e==null?null:e.I)==null),s(),v((e==null?null:e.I)!=null&&(e==null?null:e.Inventory)!=(e==null||e.I==null?null:e.I.Available)?11:-1),s(),v((e==null?null:e.Inventory)==(e==null||e.I==null?null:e.I.Available)?12:-1),s(),m("ngIf",(e==null?null:e.I)!=null),s(),m("ngIf",e==null?null:e.Channel),s(),m("ngIf",i.isShowReservedColumn),s(2),m("ngIf",(e==null||e.Channel[0]==null?null:e.Channel[0].LastInventorySync)==i.minDate)("ngIfElse",t)}}function Ot(n,p){if(n&1&&(a(0,"tbody"),G(1,At,20,18,"tr",null,z),l()),n&2){let e=p.$implicit;s(),Y(e.Variants)}}function Ut(n,p){if(n&1){let e=S();a(0,"mainpanel",3),C("onSubmit",function(t){d(e);let i=r();return _(i.onSearch(t))}),a(1,"actions")(2,"div",4),h(3,mt,4,2,"div",5),g(4,"async"),l()(),a(5,"filters")(6,"div")(7,"label",6),c(8,"Channel"),l(),a(9,"multiwarehouse-tree-select",7),C("onChannelChange",function(t){d(e);let i=r();return _(i.onChannelChange(t))}),l()(),a(10,"div",8)(11,"label",9),c(12,"PageNumber"),l(),a(13,"input",10),T("ngModelChange",function(t){d(e);let i=r();return F(i.searchFilter.PageNumber,t)||(i.searchFilter.PageNumber=t),_(t)}),l()(),a(14,"div",8)(15,"label",11),c(16,"Page Size"),l(),a(17,"input",12),T("ngModelChange",function(t){d(e);let i=r();return F(i.searchFilter.RowCount,t)||(i.searchFilter.RowCount=t),_(t)}),l()(),a(18,"div",8)(19,"label",13),c(20,"Quantity From - To"),l(),a(21,"div",14)(22,"input",15),T("ngModelChange",function(t){d(e);let i=r();return F(i.searchFilter.QuantityFrom,t)||(i.searchFilter.QuantityFrom=t),_(t)}),l(),c(23," - "),a(24,"input",16),T("ngModelChange",function(t){d(e);let i=r();return F(i.searchFilter.QuantityTo,t)||(i.searchFilter.QuantityTo=t),_(t)}),l()()()(),a(25,"content")(26,"div",17)(27,"div",18)(28,"div",19),h(29,dt,3,0,"div",20),a(30,"table",21),C("matSortChange",function(t){d(e);let i=r();return _(i.onSortVariant(t))}),a(31,"thead",22)(32,"tr")(33,"th",23),c(34," Product "),x(35,"br"),a(36,"mat-slide-toggle",24),C("toggleChange",function(){d(e);let t=r();return t.showDifferenceStock=!t.showDifferenceStock,_(t.onShowDifferenceStock())}),a(37,"small",13),c(38,"FILTER DIFFERENT INVENTORY"),l()()(),a(39,"th",25),c(40,"Variant"),l(),a(41,"th",26),c(42,"SKU"),l(),h(43,ut,3,3,"ng-container",27),a(44,"th",28),c(45," POS "),l(),a(46,"th",29)(47,"div",30),C("click",function(){d(e);let t=r();return _(t.openModalFilter())}),x(48,"img",31),a(49,"span",32),c(50),g(51,"stringLimit"),l()()(),h(52,ht,2,0,"th",33),a(53,"th",34),c(54,"Last Sync"),l()()(),G(55,Ot,3,0,"tbody",null,z),g(57,"async"),l(),a(58,"infinite-paginator",35),g(59,"async"),C("onNextPage",function(){d(e);let t=r();return _(t.infinitePagination.onNextPage(t.searchFilter))})("onLastPage",function(){d(e);let t=r();return _(t.infinitePagination.onLastPage(t.searchFilter))})("onGetRowCount",function(){d(e);let t=r();return _(t.infinitePagination.getRowCount(t.searchFilter))}),l()()()()()()}if(n&2){let e,o,t,i=r();m("headerTitle","Inventory Comparison")("pageData",i.pageData)("hideSearchBox",!1),s(3),m("ngIf",y(4,21,i.products$)),s(6),m("ngModel",(i.searchFilter==null?null:i.searchFilter.LocationID)||(i.searchFilter==null?null:i.searchFilter.ChannelID)),s(4),b("ngModel",i.searchFilter.PageNumber),s(4),b("ngModel",i.searchFilter.RowCount),s(5),b("ngModel",i.searchFilter.QuantityFrom),s(2),b("ngModel",i.searchFilter.QuantityTo),s(5),m("ngIf",(i.searchFilter==null?null:i.searchFilter.filterModel)==3),s(14),m("ngxPermissionsOnly",M(30,ne,i.inventoryUpdateRole)),s(4),m("matTooltip",((e=i.channelIdentity())==null||e.label==null?null:e.label.length)>13?(e=i.channelIdentity())==null?null:e.label:""),s(),m("src",(o=i.channelIdentity())==null?null:o.img,A),s(2),I(" ",k(51,23,(t=i.channelIdentity())==null?null:t.label,13)," "),s(2),v(i.isShowReservedColumn?52:-1),s(3),Y(y(57,26,i.products$)),s(3),m("totalData",i.infinitePagination.totalData())("hideCount",i.infinitePagination.hideCount())("rowCount",y(59,28,i.infinitePagination.totalRowCount$))("pageNumber",i.infinitePagination.pageNumber())("disableNextButton",i.infinitePagination.disableNextButton())("goToLastPage",i.infinitePagination.isLastPage())}}var An=(()=>{class n{constructor(e,o,t,i,u,ie,Xe){this.http=e,this.toastr=o,this.dialog=t,this.productService=i,this.authService=u,this.biggerPictureService=ie,this.mainPanelService=Xe,this.infinitePagination=w(J),this.ngxPermissionsService=w(we),this.updateResHandling=w(te),this.inventoryService=w(R),this.checkboxState=!1,this.showDifferenceStock=!1,this.loaderApi="InventoryLoader/Load",this.fetchApi="Inventory/GetSingleChannelComparison",this.rowCountApi="Inventory/GetInventoryByChannelRowCount",this.minDate=f.MinDate,this.isShowReservedColumn=!0,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.guidEmpty=f.GuidEMpty,this.selectedChannel=V(null),this.channelIdentity=V({img:null,label:null}),this.inventoryUpdateRole=q.InventoryUpdate,this.hasInventoryEdit=V(!0),this.pageData={Title:"Inventory Realtime",Nav:[{Title:"Inventory Cache",Url:"/menu/inventory",Active:!1},{Title:"Inventory Realtime",Url:"/menu/inventory/realtime",Active:!0}]}}ngOnInit(){this.initRoles(),this.hostName=this.authService.getDomain(),this.initPageLoader(),this.sourceObs$=this.infinitePagination.data$.pipe(H(e=>{this.checkShowReservedColumn(e)}),L(e=>(e=this.calculateAvailableStock(e),e)),N(1)),this.products$=this.sourceObs$}initRoles(){this.ngxPermissionsService.hasPermission(q.InventoryUpdate).then(e=>this.hasInventoryEdit.set(e))}calculateAvailableStock(e){return e.map(t=>(t.totalAvailable=t.Variants.reduce((i,u)=>(i+=u.I?.Available||0,i),0),t))}checkShowReservedColumn(e){let o=0,t;e.forEach(i=>{t=i.Variants.find(u=>f.IsNotEmpty(u?.Channel[0]?.InventoryReserved)),t&&(o+=1)}),this.isShowReservedColumn=o>0}initPageLoader(){this.infinitePagination.fetchDataEndpoint=this.fetchApi,this.infinitePagination.fethRowCountEndpoint=this.rowCountApi,this.loader$=this.http.post(`/api/${this.loaderApi}`,{}).pipe(N(1),H(e=>{this.searchFilter={RowCount:e.Filter.PageSize,filterModel:1,PageNumber:1,ChannelID:e.Filter.ChannelID,LocationID:e.Filter.LocationID},this.initReloadData(),this.showToastrMarketplaceInactive(!e.Filter.IsMarketplaceAppActive)}))}onChannelChange(e){let o=Object.assign({},e);this.selectedChannel.set(o),f.IsEmpty(this.channelIdentity()?.label)&&this.setChannelFilter()}setChannelFilter(){if(this.selectedChannel()){let e=Object.assign({},this.selectedChannel());f.IsNotEmpty(e.parent)?(this.searchFilter.LocationID=e.id,this.searchFilter.ChannelID=e?.parent?.id,e.label=e?.parent?.label+" - "+e?.label,e.img=f.getChannelLogoByTypeId(e?.parent?.typeid)):(this.searchFilter.LocationID=null,e.img=f.getChannelLogoByTypeId(e?.typeid),this.searchFilter.ChannelID=e?.id,this.selectedChannel.set(e)),this.channelIdentity.update(()=>({img:e.img,label:e.label}))}}initReloadData(){this.infinitePagination.reloadPagination(this.searchFilter)}showToastrMarketplaceInactive(e){e&&this.toastr.warning(`Automatic inventory sync disabled.
2
2
  Please enable Dealpos X Marketplace Apps integration in POS Configuration`,"Warning")}onSearch(e){this.searchFilter.text=e,this.setChannelFilter(),this.initReloadData()}openModalFilter(){this.mainPanelService.openModalFilter()}onOpenDialogUpdateStockInfo(e){let o=this.productService.selectedVariantProduct(e);this.dialog.open(qe,{data:{channelId:o[0]?.Channel[0]?.ChannelID,selectedProducts:o}}).afterClosed().pipe(Q(t=>t===!0)).subscribe(()=>{this.updateStock(o)})}updateStock(e){if(e.length>0){let o=this.searchFilter.LocationID,t=e.map(u=>oe({ChannelItemID:u?.Channel[0]?.ChannelItemID,ChannelVariationID:u?.Channel[0]?.ChannelVariationID,Inventory:u.Inventory},f.IsNotEmpty(o)&&{LocationID:o})),i={ListChannelID:[this.searchFilter.ChannelID],List:t};this.http.post(X.UpdateInventoryChannel,i).subscribe(u=>{this.initReloadData(),this.checkboxState=!1,this.handlingUpdateStock(u)})}}handlingUpdateStock(e){if(e[0]?.Response){let o=e[0]?.Response?.Fail_list,t=e[0]?.Response?.Success_list;this.updateResHandling.responseHandling(t,o,"Stock")}else this.toastr.error(e[0]?.Exception,"Error")}refreshInventory(e,o,t,i){let u={ChannelItemID:e,ChannelVariationID:o,ChannelID:t,VariantID:i};this.http.post("/api/Inventory/RefreshInventoryChannel",u).subscribe(ie=>{this.toastr.success("Successfully updated","Success"),this.initReloadData()})}onCheckboxStateProduct(e){e.Variants=e.Variants.map(o=>(o.Inventory>=0&&(o.selected=e.selected),o))}onCheckboxStateChange(e){e=e.map(o=>(o.Variants=o.Variants.map(t=>(t.selected=this.checkboxState,t)),o))}openTableDialog(e,o){this.hasInventoryEdit()&&this.dialog.open(Ge,{data:{Name:e.Name,Variant:o,ChannelID:o?.Channel[0]?.ChannelID,Table:"inventory",ChannelItemID:e.ChannelItemID}}).afterClosed().pipe(Q(i=>f.IsNotEmpty(i))).subscribe(i=>{this.updateItemAfterDialog(i)})}updateItemAfterDialog(e){let o=e.InventoryMultiwarehouse[0]?.LocationID,t={ID:e.ChannelID,ChannelItemID:e.ChannelItemID,ChannelVariantID:e.ChannelVariationID,NewQuantity:e?.Inventory,VariantID:e.ID,SKU:e?.Sku,LocationID:o};this.http.post(X.UpdateUpdateQuantityByItem,t).subscribe(i=>{this.searchFilter.PageNumber=1,this.initReloadData(),this.handlingUpdateStock([i])})}onScanInventory(e){let o=this.productService.selectedVariantProduct(e);this.inventoryService.refreshInventory(o).subscribe(()=>{this.initReloadData(),this.toastr.success("Inventory refreshed successfully","Success")})}openExportDialog(){this.dialog.open(ze,{data:{title:"Export Inventory Single Channel Comparison",pageNumber:this.searchFilter.PageNumber,rowCount:this.searchFilter.RowCount,filterExport:this.searchFilter,getRowCountApi:this.rowCountApi,QuantityFrom:this.searchFilter.QuantityFrom,QuantityTo:this.searchFilter.QuantityTo,exportApi:"Inventory/GetExportSingleChannelComparison"}}).afterClosed().subscribe()}onShowDifferenceStock(){this.showDifferenceStock?this.searchFilter.filterModel=ee.DIFFERENCE:this.searchFilter.filterModel=ee.ALL,this.initReloadData()}onZoomImage(e,o){this.biggerPictureService.openBiggerPicture(e,o)}onSortVariant(e){if(e.direction==""){this.products$=this.sourceObs$;return}this.products$=this.products$.pipe(L(o=>o.map(t=>(t.Variants=t.Variants.sort((i,u)=>f.compare(i.I?.Available,u.I?.Available,e.direction==="asc")),t)).sort((t,i)=>f.compare(t.totalAvailable,i.totalAvailable,e.direction==="asc"))))}static{this.\u0275fac=function(o){return new(o||n)(D(Ie),D(ve),D(ke),D(We),D(Te),D(je),D(Ne))}}static{this.\u0275cmp=U({type:n,selectors:[["app-single-channel-comparison"]],features:[B([J,R,te])],decls:2,vars:3,consts:[["SYNCDATE",""],["EMPTY_RESERVED",""],["textButton","Search",3,"headerTitle","pageData","hideSearchBox","onSubmit",4,"ngIf"],["textButton","Search",3,"onSubmit","headerTitle","pageData","hideSearchBox"],[1,"d-flex"],[4,"ngIf"],["for","channelOptions",1,"fw-bold","mb-2"],["id","channelOptions",3,"onChannelChange","ngModel"],[1,"mt-5"],["for","PageNumber",1,"fw-bold"],["type","number","id","PageNumber","placeholder","PageNumber","name","PageNumber","data-toggle","tooltip","matTooltip","Page Number",1,"mat-mdc-tooltip-trigger","form-control","ng-pristine","ng-valid","ng-touched","mt-3",3,"ngModelChange","ngModel"],["for","RowCount",1,"fw-bold"],["type","number","id","RowCount","placeholder","Page Size","name","RowCount","data-toggle","tooltip","matTooltip","Page Size",1,"mat-mdc-tooltip-trigger","form-control","ng-pristine","ng-valid","ng-touched","mt-3",3,"ngModelChange","ngModel"],[1,"fw-bold"],[1,"d-flex","align-items-center","justify-content-start"],["type","number","name","QuantityFrom",1,"w-25","me-2","mt-3","form-control",3,"ngModelChange","ngModel"],["type","number","name","QuantityTo",1,"w-25","ms-2","form-control","mt-2",3,"ngModelChange","ngModel"],[1,"container-fluid","mt-3"],[1,"row"],[1,"col-md-12"],["class","alert alert-warning d-flex justify-content-between text-dark","role","alert",4,"ngIf"],["matSort","",1,"table","border-bottom",3,"matSortChange"],[1,"thead-light","sticky-top-thead"],["scope","col","colspan","2",1,"text-center","ps-12",2,"width","25%"],[3,"toggleChange"],["scope","col",1,"text-start"],["scope","col",1,"text-end",2,"width","10%"],[4,"ngxPermissionsOnly"],["scope","col","mat-sort-header","Available","arrowPosition","before",1,"text-end","w-10",2,"width","8%"],[1,"text-end",2,"width","150px"],["role","button","matTooltipPosition","above",1,"d-inline-block",3,"click","matTooltip"],[2,"width","16px",3,"src"],[1,"ms-1"],["matTooltip","Reserved Stock","matTooltipPosition","above",1,"text-end",2,"width","80px"],[1,"text-center",2,"width","145px"],[3,"onNextPage","onLastPage","onGetRowCount","totalData","hideCount","rowCount","pageNumber","disableNextButton","goToLastPage"],["class","btn btn-outline-dark me-3","matTooltip","Fetch the latest stock directly from the channel",3,"click",4,"ngIf"],[1,"btn-group"],[1,"btn","btn-outline-secondary","shadow","rounded"],["matTooltip","Fetch the latest stock directly from the channel",1,"btn","btn-outline-dark","me-3",3,"click"],[1,"fa-solid","fa-arrows-rotate","me-3"],[1,"btn","btn-success",3,"click"],[1,"fas","fa-chevron-circle-up"],["data-bs-toggle","dropdown","aria-expanded","false",1,"btn","btn-success","btn-sm","dropdown-toggle","border-start"],[1,"dropdown-menu","dropdown-menu-end","pointer"],["role","button",1,"dropdown-item","cursor-pointer","fs-5",3,"click"],[1,"fa-solid","fa-print","me-3"],[1,"btn","btn-outline-secondary","shadow","rounded",3,"click"],["role","alert",1,"alert","alert-warning","d-flex","justify-content-between","text-dark"],["type","checkbox",3,"ngModelChange","ngModel"],[1,"text-start"],[1,"text-end"],["matTooltipPosition","above",3,"matTooltip","ngClass"],[1,"d-flex","align-items-center","justify-content-end"],["class","text-danger","matTooltip","This product is no longer available in POS","matTooltipPosition","above",4,"ngIf"],["class","text-end",3,"ngClass",4,"ngIf"],[1,"text-center"],[4,"ngIf","ngIfElse"],[1,"text-start",2,"width","0%",3,"rowSpan"],[1,"border","rounded","w-img","cursor-pointer",2,"margin-left","20px",3,"src"],["src","//res.cloudinary.com/pos/image/upload/w_40/POS/Images/Icon/products_thumb.png",1,"border","rounded","w-img",2,"margin-left","20px"],[1,"text-start",3,"rowSpan"],[1,"item-name","mb-0"],[3,"ngClass"],["type","checkbox",1,"me-3",3,"ngModel"],["type","checkbox",1,"me-3",3,"ngModelChange","ngModel"],[1,"border","rounded","w-img","cursor-pointer",2,"margin-left","20px",3,"click","src"],[1,"d-flex","align-items-center"],["title","Category",1,"fa-solid","fa-tags","me-2",2,"opacity","60%"],[1,"align-middle"],["type","checkbox",3,"ngModel"],["matTooltip","This product is no longer available in POS","matTooltipPosition","above",1,"text-danger"],["title","Stock Available"],["title","Inventory below minimum inventory"],[1,"ms-3"],["target","_blank",3,"href"],[1,"fa-solid","fa-arrow-up-right-from-square","external-link-custom"],[1,"text-end",3,"ngClass"],[3,"class","click",4,"ngIf"],["matTooltip","Refresh stock according to seller center",1,"pl-5","cursor-pointer",2,"color","var(--bs-link-color)",3,"click"],[1,"fas","fa-sync","fa-lg","external-link-custom","pt-1"],[3,"click"],[1,"text-danger"],["matTooltipShowDelay","500",3,"matTooltip"]],template:function(o,t){o&1&&(h(0,Ut,60,32,"mainpanel",2),g(1,"async")),o&2&&m("ngIf",y(1,1,t.loader$))},dependencies:[j,me,de,$,_e,W,Oe,Ae,De,ye,ge,Se,Ce,fe,xe,Ye,Ke,Fe,be,He,Qe,Ee,Pe,$e,Ue,Be,Ze],styles:[".w-10[_ngcontent-%COMP%]{width:10%}.w-img[_ngcontent-%COMP%]{width:40px;height:40px}.item-name[_ngcontent-%COMP%]{margin-bottom:-14px!important;font-size:larger}input[type=checkbox][_ngcontent-%COMP%]{width:15px;height:15px}"]})}}return n})();export{An as SingleChannelComparisonComponent};
@@ -1 +1 @@
1
- import{a as ae}from"./chunk-ZVKOEYH7.js";import{a as M}from"./chunk-GKRWJPI3.js";import{a as le}from"./chunk-67HPC5Y3.js";import{a as ne}from"./chunk-OLANEXLB.js";import"./chunk-PFY5UG5D.js";import"./chunk-KS7ACI26.js";import"./chunk-3GDM5JNY.js";import"./chunk-XXT6F2ZS.js";import"./chunk-QS22J2SC.js";import"./chunk-EHUVS2VB.js";import"./chunk-IHSGQFDX.js";import"./chunk-MO53T3IK.js";import"./chunk-W3JTS22H.js";import"./chunk-SDUUFQUI.js";import"./chunk-6L7TD5DW.js";import"./chunk-6OMSPZZC.js";import"./chunk-3RK6DDJD.js";import"./chunk-HIC5QC3Y.js";import"./chunk-JBT7GBCM.js";import"./chunk-JVNHFIYT.js";import{a as re}from"./chunk-HHO2NGCF.js";import{a as te}from"./chunk-RM2OSYMV.js";import{a as ie}from"./chunk-LDL3A7NM.js";import"./chunk-FHWKSD5A.js";import"./chunk-Z3ITXK3D.js";import"./chunk-ACIMXBIC.js";import"./chunk-TGMCGROM.js";import"./chunk-CGOB6Y3X.js";import"./chunk-WN5DZGA4.js";import"./chunk-4NEKWRL7.js";import"./chunk-PYXL7UF7.js";import"./chunk-PW42BQIY.js";import{m as $,n as ee}from"./chunk-HJXYT6MI.js";import{A as X,c as J,h as K,m as Q,o as U}from"./chunk-5PS6ZS3N.js";import"./chunk-V3USB3ZU.js";import"./chunk-ERXVXBTU.js";import{r as Y,s as Z}from"./chunk-MFQQEEHJ.js";import"./chunk-GZKOMS4T.js";import{j as R,k as j,m as q,n as G}from"./chunk-FXQKRJWU.js";import{$c as w,Gb as W,Gc as a,Hc as h,Kc as c,Lc as u,Mb as D,Mc as C,Nc as I,Oc as k,Pc as A,Qc as z,Ra as O,Yb as g,Z as P,ad as v,bd as H,dc as F,ec as L,gc as N,hc as B,ic as e,jc as t,kc as _,oc as b,pa as V,rb as l,tc as x,uc as y,ya as p,za as s}from"./chunk-OJMQBH6T.js";import"./chunk-EU2KAMEK.js";import{a as E,b as T}from"./chunk-66YHNWRR.js";function oe(m,S){if(m&1&&(e(0,"tr")(1,"td"),a(2),t(),e(3,"td"),_(4,"order-link",26),t(),e(5,"td"),a(6),t(),e(7,"td"),a(8),w(9,"number"),t(),e(10,"td"),a(11),w(12,"date"),t(),e(13,"td"),_(14,"app-channel-logo",27),t()()),m&2){let r=S.$implicit;l(2),h(r.Outlet),l(2),g("order",r),l(2),h(r.Customer),l(2),h(v(9,6,r.Amount)),l(3),h(H(12,8,r.Created,"dd MMM yyyy HH:mm")),l(3),g("typeId",r==null?null:r.TypeID)}}function me(m,S){if(m&1){let r=b();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"),N(17,oe,15,11,"tr",null,L),t()(),e(19,"app-custom-paginator",25),x("next",function(){p(r);let i=y();return s(i.initCancelledOrders())})("previous",function(){p(r);let i=y();return s(i.initCancelledOrders())}),t()()}if(m&2){let r=y(),o=A(0);l(17),B(o),l(2),g("filter",r.filter())("totaldata",o==null?null:o.length)("paginationTotal",o==null?null:o.length)("hasClicked",!0)("nextButtonAlwaysVisible",!0)}}function de(m,S){m&1&&(e(0,"div",16),_(1,"app-empty-state"),t())}var Oe=(()=>{class m{constructor(){this.orderService=V(M),this.filter=O({PageNumber:1,PageSize:20,ListChannelID:[],From:null,To:null,Number:null})}ngOnInit(){this.orderService.getOrderDefaultValue().subscribe({next:r=>{this.initFromDate(r)},error:r=>{console.error("Error fetching default date:",r),this.initFromDate(null)}})}initFromDate(r){this.filter.update(o=>T(E({},o),{From:r})),this.initCancelledOrders()}initCancelledOrders(){this.cancelledOrders$=this.orderService.getCancelledOrders(this.filter()).pipe(P(1))}static{this.\u0275fac=function(o){return new(o||m)}}static{this.\u0275cmp=W({type:m,selectors:[["app-cancelled"]],features:[z([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(o,i){if(o&1){let d=b();I(0),w(1,"async"),e(2,"mainpanel",0),x("onSubmit",function(){return p(d),s(i.initCancelledOrders())}),C("textChange",function(n){return p(d),u(i.filter().Number,n)||(i.filter().Number=n),s(n)}),e(3,"actions")(4,"a",1),_(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,"channel-select-options",4),C("ngModelChange",function(n){return p(d),u(i.filter().ListChannelID,n)||(i.filter().ListChannelID=n),s(n)}),t()(),e(13,"div",5)(14,"label",3),a(15,"From/To"),t(),e(16,"div",6)(17,"datepicker",7),C("dateChange",function(n){return p(d),u(i.filter().From,n)||(i.filter().From=n),s(n)}),t()(),e(18,"div")(19,"datepicker",8),C("dateChange",function(n){return p(d),u(i.filter().To,n)||(i.filter().To=n),s(n)}),t()()(),e(20,"div",5)(21,"label",9),a(22,"Page Number"),t(),e(23,"input",10),C("ngModelChange",function(n){return p(d),u(i.filter().PageNumber,n)||(i.filter().PageNumber=n),s(n)}),t()(),e(24,"div",5)(25,"label",9),a(26,"Page Size"),t(),e(27,"input",11),C("ngModelChange",function(n){return p(d),u(i.filter().PageSize,n)||(i.filter().PageSize=n),s(n)}),t()()(),e(28,"content")(29,"div",12)(30,"div",13)(31,"div",14),D(32,me,20,5,"div",15)(33,de,2,0,"div",16),t()()()()()}if(o&2){let d=k(v(1,8,i.cancelledOrders$));l(2),c("text",i.filter().Number),l(10),g("multiple",!0),c("ngModel",i.filter().ListChannelID),l(5),c("date",i.filter().From),l(2),c("date",i.filter().To),l(4),c("ngModel",i.filter().PageNumber),l(4),c("ngModel",i.filter().PageSize),l(5),F((d==null?null:d.length)>0?32:33)}},dependencies:[G,R,q,j,ee,$,ne,ie,X,J,U,K,Q,le,re,Z,Y,ae,te],encapsulation:2})}}return m})();export{Oe as CancelledComponent};
1
+ import{a as ae}from"./chunk-WAKKUK6E.js";import{a as M}from"./chunk-QSHR75ZI.js";import{a as le}from"./chunk-67HPC5Y3.js";import{a as ne}from"./chunk-OLANEXLB.js";import"./chunk-PFY5UG5D.js";import"./chunk-KS7ACI26.js";import"./chunk-3GDM5JNY.js";import"./chunk-XXT6F2ZS.js";import"./chunk-QS22J2SC.js";import"./chunk-EHUVS2VB.js";import"./chunk-IHSGQFDX.js";import"./chunk-MO53T3IK.js";import"./chunk-W3JTS22H.js";import"./chunk-SDUUFQUI.js";import"./chunk-6L7TD5DW.js";import"./chunk-6OMSPZZC.js";import"./chunk-3RK6DDJD.js";import"./chunk-HIC5QC3Y.js";import"./chunk-JBT7GBCM.js";import"./chunk-JVNHFIYT.js";import{a as re}from"./chunk-CWXOXH6M.js";import{a as te}from"./chunk-RM2OSYMV.js";import{a as ie}from"./chunk-LDL3A7NM.js";import"./chunk-WWLC64XZ.js";import"./chunk-Z3ITXK3D.js";import"./chunk-ACIMXBIC.js";import"./chunk-TGMCGROM.js";import"./chunk-CGOB6Y3X.js";import"./chunk-WN5DZGA4.js";import"./chunk-4NEKWRL7.js";import"./chunk-PYXL7UF7.js";import"./chunk-PW42BQIY.js";import{m as $,n as ee}from"./chunk-HJXYT6MI.js";import{A as X,c as J,h as K,m as Q,o as U}from"./chunk-5PS6ZS3N.js";import"./chunk-V3USB3ZU.js";import"./chunk-ERXVXBTU.js";import{r as Y,s as Z}from"./chunk-MFQQEEHJ.js";import"./chunk-GZKOMS4T.js";import{j as R,k as j,m as q,n as G}from"./chunk-FXQKRJWU.js";import{$c as w,Gb as W,Gc as a,Hc as h,Kc as c,Lc as u,Mb as D,Mc as C,Nc as I,Oc as k,Pc as A,Qc as z,Ra as O,Yb as g,Z as P,ad as v,bd as H,dc as F,ec as L,gc as N,hc as B,ic as e,jc as t,kc as _,oc as b,pa as V,rb as l,tc as x,uc as y,ya as p,za as s}from"./chunk-OJMQBH6T.js";import"./chunk-EU2KAMEK.js";import{a as E,b as T}from"./chunk-66YHNWRR.js";function oe(m,S){if(m&1&&(e(0,"tr")(1,"td"),a(2),t(),e(3,"td"),_(4,"order-link",26),t(),e(5,"td"),a(6),t(),e(7,"td"),a(8),w(9,"number"),t(),e(10,"td"),a(11),w(12,"date"),t(),e(13,"td"),_(14,"app-channel-logo",27),t()()),m&2){let r=S.$implicit;l(2),h(r.Outlet),l(2),g("order",r),l(2),h(r.Customer),l(2),h(v(9,6,r.Amount)),l(3),h(H(12,8,r.Created,"dd MMM yyyy HH:mm")),l(3),g("typeId",r==null?null:r.TypeID)}}function me(m,S){if(m&1){let r=b();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"),N(17,oe,15,11,"tr",null,L),t()(),e(19,"app-custom-paginator",25),x("next",function(){p(r);let i=y();return s(i.initCancelledOrders())})("previous",function(){p(r);let i=y();return s(i.initCancelledOrders())}),t()()}if(m&2){let r=y(),o=A(0);l(17),B(o),l(2),g("filter",r.filter())("totaldata",o==null?null:o.length)("paginationTotal",o==null?null:o.length)("hasClicked",!0)("nextButtonAlwaysVisible",!0)}}function de(m,S){m&1&&(e(0,"div",16),_(1,"app-empty-state"),t())}var Oe=(()=>{class m{constructor(){this.orderService=V(M),this.filter=O({PageNumber:1,PageSize:20,ListChannelID:[],From:null,To:null,Number:null})}ngOnInit(){this.orderService.getOrderDefaultValue().subscribe({next:r=>{this.initFromDate(r)},error:r=>{console.error("Error fetching default date:",r),this.initFromDate(null)}})}initFromDate(r){this.filter.update(o=>T(E({},o),{From:r})),this.initCancelledOrders()}initCancelledOrders(){this.cancelledOrders$=this.orderService.getCancelledOrders(this.filter()).pipe(P(1))}static{this.\u0275fac=function(o){return new(o||m)}}static{this.\u0275cmp=W({type:m,selectors:[["app-cancelled"]],features:[z([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(o,i){if(o&1){let d=b();I(0),w(1,"async"),e(2,"mainpanel",0),x("onSubmit",function(){return p(d),s(i.initCancelledOrders())}),C("textChange",function(n){return p(d),u(i.filter().Number,n)||(i.filter().Number=n),s(n)}),e(3,"actions")(4,"a",1),_(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,"channel-select-options",4),C("ngModelChange",function(n){return p(d),u(i.filter().ListChannelID,n)||(i.filter().ListChannelID=n),s(n)}),t()(),e(13,"div",5)(14,"label",3),a(15,"From/To"),t(),e(16,"div",6)(17,"datepicker",7),C("dateChange",function(n){return p(d),u(i.filter().From,n)||(i.filter().From=n),s(n)}),t()(),e(18,"div")(19,"datepicker",8),C("dateChange",function(n){return p(d),u(i.filter().To,n)||(i.filter().To=n),s(n)}),t()()(),e(20,"div",5)(21,"label",9),a(22,"Page Number"),t(),e(23,"input",10),C("ngModelChange",function(n){return p(d),u(i.filter().PageNumber,n)||(i.filter().PageNumber=n),s(n)}),t()(),e(24,"div",5)(25,"label",9),a(26,"Page Size"),t(),e(27,"input",11),C("ngModelChange",function(n){return p(d),u(i.filter().PageSize,n)||(i.filter().PageSize=n),s(n)}),t()()(),e(28,"content")(29,"div",12)(30,"div",13)(31,"div",14),D(32,me,20,5,"div",15)(33,de,2,0,"div",16),t()()()()()}if(o&2){let d=k(v(1,8,i.cancelledOrders$));l(2),c("text",i.filter().Number),l(10),g("multiple",!0),c("ngModel",i.filter().ListChannelID),l(5),c("date",i.filter().From),l(2),c("date",i.filter().To),l(4),c("ngModel",i.filter().PageNumber),l(4),c("ngModel",i.filter().PageSize),l(5),F((d==null?null:d.length)>0?32:33)}},dependencies:[G,R,q,j,ee,$,ne,ie,X,J,U,K,Q,le,re,Z,Y,ae,te],encapsulation:2})}}return m})();export{Oe as CancelledComponent};
@@ -1 +1 @@
1
- import{a as l}from"./chunk-ORLTYLPA.js";import{b as u}from"./chunk-WRJFUNM3.js";import"./chunk-FHWKSD5A.js";import"./chunk-Z3ITXK3D.js";import"./chunk-ACIMXBIC.js";import"./chunk-TGMCGROM.js";import"./chunk-CGOB6Y3X.js";import"./chunk-WN5DZGA4.js";import"./chunk-4NEKWRL7.js";import"./chunk-PW42BQIY.js";import{n as c}from"./chunk-HJXYT6MI.js";import{A as s}from"./chunk-5PS6ZS3N.js";import"./chunk-V3USB3ZU.js";import"./chunk-ERXVXBTU.js";import"./chunk-MFQQEEHJ.js";import"./chunk-GZKOMS4T.js";import{F as a,J as n,n as i}from"./chunk-FXQKRJWU.js";import{Gb as p,Hb as r,ka as e,kc as d}from"./chunk-OJMQBH6T.js";import"./chunk-EU2KAMEK.js";import"./chunk-66YHNWRR.js";var M=(()=>{class t{constructor(){}static{this.\u0275fac=function(o){return new(o||t)}}static{this.\u0275cmp=p({type:t,selectors:[["app-report"]],standalone:!1,decls:1,vars:0,template:function(o,C){o&1&&d(0,"router-outlet")},dependencies:[a],styles:["ul[_ngcontent-%COMP%] > li.dropdown-item[_ngcontent-%COMP%]{font-size:.6875rem!important}"]})}}return t})();var R=[{path:"",component:M,children:[{path:"",redirectTo:"order",pathMatch:"full"},{path:"order",loadChildren:()=>import("./chunk-DSYYZDXI.js").then(t=>t.OrderModule),canActivate:[l]}]}],h=(()=>{class t{static{this.\u0275fac=function(o){return new(o||t)}}static{this.\u0275mod=r({type:t})}static{this.\u0275inj=e({imports:[i,n.forChild(R)]})}}return t})();var S=(()=>{class t{static{this.\u0275fac=function(o){return new(o||t)}}static{this.\u0275mod=r({type:t})}static{this.\u0275inj=e({imports:[i,u,h,s,c,n]})}}return t})();export{S as ReportModule};
1
+ import{a as l}from"./chunk-PL3Q6PGC.js";import{b as u}from"./chunk-WRJFUNM3.js";import"./chunk-WWLC64XZ.js";import"./chunk-Z3ITXK3D.js";import"./chunk-ACIMXBIC.js";import"./chunk-TGMCGROM.js";import"./chunk-CGOB6Y3X.js";import"./chunk-WN5DZGA4.js";import"./chunk-4NEKWRL7.js";import"./chunk-PW42BQIY.js";import{n as c}from"./chunk-HJXYT6MI.js";import{A as s}from"./chunk-5PS6ZS3N.js";import"./chunk-V3USB3ZU.js";import"./chunk-ERXVXBTU.js";import"./chunk-MFQQEEHJ.js";import"./chunk-GZKOMS4T.js";import{F as a,J as n,n as i}from"./chunk-FXQKRJWU.js";import{Gb as p,Hb as r,ka as e,kc as d}from"./chunk-OJMQBH6T.js";import"./chunk-EU2KAMEK.js";import"./chunk-66YHNWRR.js";var M=(()=>{class t{constructor(){}static{this.\u0275fac=function(o){return new(o||t)}}static{this.\u0275cmp=p({type:t,selectors:[["app-report"]],standalone:!1,decls:1,vars:0,template:function(o,C){o&1&&d(0,"router-outlet")},dependencies:[a],styles:["ul[_ngcontent-%COMP%] > li.dropdown-item[_ngcontent-%COMP%]{font-size:.6875rem!important}"]})}}return t})();var R=[{path:"",component:M,children:[{path:"",redirectTo:"order",pathMatch:"full"},{path:"order",loadChildren:()=>import("./chunk-Z67623R4.js").then(t=>t.OrderModule),canActivate:[l]}]}],h=(()=>{class t{static{this.\u0275fac=function(o){return new(o||t)}}static{this.\u0275mod=r({type:t})}static{this.\u0275inj=e({imports:[i,n.forChild(R)]})}}return t})();var S=(()=>{class t{static{this.\u0275fac=function(o){return new(o||t)}}static{this.\u0275mod=r({type:t})}static{this.\u0275inj=e({imports:[i,u,h,s,c,n]})}}return t})();export{S as ReportModule};
@@ -1 +1 @@
1
- import{a as Q}from"./chunk-HHO2NGCF.js";import{a as J}from"./chunk-3YP6ORBR.js";import{a as z}from"./chunk-RM2OSYMV.js";import{a as q}from"./chunk-LDL3A7NM.js";import"./chunk-FHWKSD5A.js";import"./chunk-Z3ITXK3D.js";import"./chunk-ACIMXBIC.js";import"./chunk-TGMCGROM.js";import{a as y}from"./chunk-CGOB6Y3X.js";import{e as H}from"./chunk-WN5DZGA4.js";import"./chunk-4NEKWRL7.js";import"./chunk-PYXL7UF7.js";import"./chunk-PW42BQIY.js";import{m as Z,n as j}from"./chunk-HJXYT6MI.js";import{A as G,h as W,m as $}from"./chunk-5PS6ZS3N.js";import"./chunk-V3USB3ZU.js";import"./chunk-ERXVXBTU.js";import"./chunk-MFQQEEHJ.js";import"./chunk-GZKOMS4T.js";import{H as N,J as O,j as A,m as R,n as F}from"./chunk-FXQKRJWU.js";import{$c as w,Gb as b,Gc as a,Hc as g,Kc as K,Lc as P,Mb as k,Mc as T,Nc as B,Ra as D,Yb as s,Z as V,ad as v,dc as U,ec as I,gc as E,hc as L,ic as e,jc as t,kc as c,oc as x,pa as C,pb as M,rb as l,tc as S,uc as _,ya as m,za as u}from"./chunk-OJMQBH6T.js";import"./chunk-EU2KAMEK.js";import"./chunk-66YHNWRR.js";function X(o,h){if(o&1){let i=x();e(0,"img",21),S("click",function(r){m(i);let n=_().$implicit,d=_();return u(d.onZoomImage(r,n==null?null:n.ImageUrl))}),t()}if(o&2){let i=_().$implicit;s("src",i==null?null:i.ThumbnailUrl,M)}}function Y(o,h){o&1&&c(0,"img",17)}function ee(o,h){if(o&1&&(e(0,"tr")(1,"td")(2,"div",15),k(3,X,1,1,"img",16)(4,Y,1,0,"img",17),t()(),e(5,"td"),a(6),t(),e(7,"td"),a(8),t(),e(9,"td")(10,"div",18),c(11,"app-channel-logo",19),e(12,"span"),a(13),t()()(),e(14,"td",20),a(15),w(16,"number"),t()()),o&2){let i=h.$implicit;l(3),U(i.ImageUrl?3:4),l(3),g(i.Name),l(2),g(i.SKU),l(3),s("typeId",i.TypeID),l(2),g(i.ChannelName),l(2),g(v(16,6,i.Count))}}var xe=(()=>{class o{constructor(){this.httpService=C(H),this.biggerPictureService=C(J),this.filter=D({PageNumber:1,RowCount:20,ListChannelID:[]}),this.rowCountApi=y.GetMultilistingSKUCount,this.initMultipleListingSKU()}initMultipleListingSKU(){this.multipleListingSKU$=this.httpService.post(y.GetMultiListingSKU,this.filter()).pipe(V(1))}onZoomImage(i,p){this.biggerPictureService.openBiggerPicture(i,p)}static{this.\u0275fac=function(p){return new(p||o)}}static{this.\u0275cmp=b({type:o,selectors:[["app-duplicate-sku-v2"]],decls:33,vars:8,consts:[["headerTitle","Duplicate SKU","description","SKU(s) which is listed more than one time (one to many)",3,"onSubmit","hideSearchBox"],["routerLink","/menu/products/status/duplicate-sku",1,"d-flex","align-items-center","gap-2","btn","btn-outline-secondary","btn-lg"],[1,"fa-solid","fa-credit-card"],[1,"fw-bold","mb-2"],[3,"ngModelChange","multiple","ngModel"],[1,"container-fluid"],[1,"row","mt-6"],[1,"col-12"],[1,"table"],[1,"thead-light","sticky-top-thead"],[2,"width","40px"],[2,"width","200px"],[2,"width","250px"],[1,"text-end",2,"width","50px"],[3,"next","previous","filter","totaldata","rowCountApi"],[2,"padding-right","0px"],[1,"border","rounded","cursor-pointer",2,"max-width","40px",3,"src"],["src","//res.cloudinary.com/pos/image/upload/w_40/POS/Images/Icon/products_thumb.png",1,"border","rounded",2,"max-width","40px"],[1,"d-flex","align-items-center"],[3,"typeId"],[1,"text-end"],[1,"border","rounded","cursor-pointer",2,"max-width","40px",3,"click","src"]],template:function(p,r){if(p&1){let n=x();B(0),w(1,"async"),e(2,"mainpanel",0),S("onSubmit",function(){return m(n),u(r.initMultipleListingSKU())}),e(3,"actions")(4,"a",1),c(5,"i",2),e(6,"span"),a(7,"Card View"),t()()(),e(8,"filters")(9,"div")(10,"label",3),a(11,"Channel"),t(),e(12,"channel-select-options",4),T("ngModelChange",function(f){return m(n),P(r.filter().ListChannelID,f)||(r.filter().ListChannelID=f),u(f)}),t()()(),e(13,"content")(14,"div",5)(15,"div",6)(16,"div",7)(17,"table",8)(18,"thead",9)(19,"tr"),c(20,"th",10),e(21,"th"),a(22,"Product"),t(),e(23,"th",11),a(24,"SKU"),t(),e(25,"th",12),a(26,"Channel"),t(),e(27,"th",13),a(28,"Count"),t()()(),e(29,"tbody"),E(30,ee,17,8,"tr",null,I),t()(),e(32,"app-custom-paginator",14),S("next",function(){return m(n),u(r.initMultipleListingSKU())})("previous",function(){return m(n),u(r.initMultipleListingSKU())}),t()()()()()()}if(p&2){let n=v(1,6,r.multipleListingSKU$);l(2),s("hideSearchBox",!0),l(10),s("multiple",!0),K("ngModel",r.filter().ListChannelID),l(18),L(n==null?null:n.Data),l(2),s("filter",r.filter())("totaldata",n==null||n.Data==null?null:n.Data.length)("rowCountApi",r.rowCountApi)}},dependencies:[F,A,R,j,Z,q,O,N,z,Q,G,W,$],encapsulation:2})}}return o})();export{xe as DuplicateSkuV2Component};
1
+ import{a as Q}from"./chunk-CWXOXH6M.js";import{a as J}from"./chunk-3YP6ORBR.js";import{a as z}from"./chunk-RM2OSYMV.js";import{a as q}from"./chunk-LDL3A7NM.js";import"./chunk-WWLC64XZ.js";import"./chunk-Z3ITXK3D.js";import"./chunk-ACIMXBIC.js";import"./chunk-TGMCGROM.js";import{a as y}from"./chunk-CGOB6Y3X.js";import{e as H}from"./chunk-WN5DZGA4.js";import"./chunk-4NEKWRL7.js";import"./chunk-PYXL7UF7.js";import"./chunk-PW42BQIY.js";import{m as Z,n as j}from"./chunk-HJXYT6MI.js";import{A as G,h as W,m as $}from"./chunk-5PS6ZS3N.js";import"./chunk-V3USB3ZU.js";import"./chunk-ERXVXBTU.js";import"./chunk-MFQQEEHJ.js";import"./chunk-GZKOMS4T.js";import{H as N,J as O,j as A,m as R,n as F}from"./chunk-FXQKRJWU.js";import{$c as w,Gb as b,Gc as a,Hc as g,Kc as K,Lc as P,Mb as k,Mc as T,Nc as B,Ra as D,Yb as s,Z as V,ad as v,dc as U,ec as I,gc as E,hc as L,ic as e,jc as t,kc as c,oc as x,pa as C,pb as M,rb as l,tc as S,uc as _,ya as m,za as u}from"./chunk-OJMQBH6T.js";import"./chunk-EU2KAMEK.js";import"./chunk-66YHNWRR.js";function X(o,h){if(o&1){let i=x();e(0,"img",21),S("click",function(r){m(i);let n=_().$implicit,d=_();return u(d.onZoomImage(r,n==null?null:n.ImageUrl))}),t()}if(o&2){let i=_().$implicit;s("src",i==null?null:i.ThumbnailUrl,M)}}function Y(o,h){o&1&&c(0,"img",17)}function ee(o,h){if(o&1&&(e(0,"tr")(1,"td")(2,"div",15),k(3,X,1,1,"img",16)(4,Y,1,0,"img",17),t()(),e(5,"td"),a(6),t(),e(7,"td"),a(8),t(),e(9,"td")(10,"div",18),c(11,"app-channel-logo",19),e(12,"span"),a(13),t()()(),e(14,"td",20),a(15),w(16,"number"),t()()),o&2){let i=h.$implicit;l(3),U(i.ImageUrl?3:4),l(3),g(i.Name),l(2),g(i.SKU),l(3),s("typeId",i.TypeID),l(2),g(i.ChannelName),l(2),g(v(16,6,i.Count))}}var xe=(()=>{class o{constructor(){this.httpService=C(H),this.biggerPictureService=C(J),this.filter=D({PageNumber:1,RowCount:20,ListChannelID:[]}),this.rowCountApi=y.GetMultilistingSKUCount,this.initMultipleListingSKU()}initMultipleListingSKU(){this.multipleListingSKU$=this.httpService.post(y.GetMultiListingSKU,this.filter()).pipe(V(1))}onZoomImage(i,p){this.biggerPictureService.openBiggerPicture(i,p)}static{this.\u0275fac=function(p){return new(p||o)}}static{this.\u0275cmp=b({type:o,selectors:[["app-duplicate-sku-v2"]],decls:33,vars:8,consts:[["headerTitle","Duplicate SKU","description","SKU(s) which is listed more than one time (one to many)",3,"onSubmit","hideSearchBox"],["routerLink","/menu/products/status/duplicate-sku",1,"d-flex","align-items-center","gap-2","btn","btn-outline-secondary","btn-lg"],[1,"fa-solid","fa-credit-card"],[1,"fw-bold","mb-2"],[3,"ngModelChange","multiple","ngModel"],[1,"container-fluid"],[1,"row","mt-6"],[1,"col-12"],[1,"table"],[1,"thead-light","sticky-top-thead"],[2,"width","40px"],[2,"width","200px"],[2,"width","250px"],[1,"text-end",2,"width","50px"],[3,"next","previous","filter","totaldata","rowCountApi"],[2,"padding-right","0px"],[1,"border","rounded","cursor-pointer",2,"max-width","40px",3,"src"],["src","//res.cloudinary.com/pos/image/upload/w_40/POS/Images/Icon/products_thumb.png",1,"border","rounded",2,"max-width","40px"],[1,"d-flex","align-items-center"],[3,"typeId"],[1,"text-end"],[1,"border","rounded","cursor-pointer",2,"max-width","40px",3,"click","src"]],template:function(p,r){if(p&1){let n=x();B(0),w(1,"async"),e(2,"mainpanel",0),S("onSubmit",function(){return m(n),u(r.initMultipleListingSKU())}),e(3,"actions")(4,"a",1),c(5,"i",2),e(6,"span"),a(7,"Card View"),t()()(),e(8,"filters")(9,"div")(10,"label",3),a(11,"Channel"),t(),e(12,"channel-select-options",4),T("ngModelChange",function(f){return m(n),P(r.filter().ListChannelID,f)||(r.filter().ListChannelID=f),u(f)}),t()()(),e(13,"content")(14,"div",5)(15,"div",6)(16,"div",7)(17,"table",8)(18,"thead",9)(19,"tr"),c(20,"th",10),e(21,"th"),a(22,"Product"),t(),e(23,"th",11),a(24,"SKU"),t(),e(25,"th",12),a(26,"Channel"),t(),e(27,"th",13),a(28,"Count"),t()()(),e(29,"tbody"),E(30,ee,17,8,"tr",null,I),t()(),e(32,"app-custom-paginator",14),S("next",function(){return m(n),u(r.initMultipleListingSKU())})("previous",function(){return m(n),u(r.initMultipleListingSKU())}),t()()()()()()}if(p&2){let n=v(1,6,r.multipleListingSKU$);l(2),s("hideSearchBox",!0),l(10),s("multiple",!0),K("ngModel",r.filter().ListChannelID),l(18),L(n==null?null:n.Data),l(2),s("filter",r.filter())("totaldata",n==null||n.Data==null?null:n.Data.length)("rowCountApi",r.rowCountApi)}},dependencies:[F,A,R,j,Z,q,O,N,z,Q,G,W,$],encapsulation:2})}}return o})();export{xe as DuplicateSkuV2Component};
@@ -1 +1 @@
1
- import{a as be,b as ye}from"./chunk-NWWYOZ4V.js";import{a as fe,b as Te}from"./chunk-YTCIQBSO.js";import{b as he}from"./chunk-IHSGQFDX.js";import{a as xe}from"./chunk-HIC5QC3Y.js";import{a as F}from"./chunk-UMP6ZMEJ.js";import{a as Ce}from"./chunk-3YP6ORBR.js";import{i as pe}from"./chunk-FHWKSD5A.js";import{c as z}from"./chunk-PW42BQIY.js";import{d as ge,h as ue}from"./chunk-HJXYT6MI.js";import{A as le,b as oe,h as re,m as ae}from"./chunk-5PS6ZS3N.js";import{a as ce,b as _e,c as se}from"./chunk-ERXVXBTU.js";import{r as me,s as de}from"./chunk-MFQQEEHJ.js";import{d as J,f as Q,g as ee,i as te,m as ne,n as ie}from"./chunk-FXQKRJWU.js";import{$c as $,Fc as b,G as H,Gb as K,Gc as m,Hc as O,Ic as y,Ka as R,Kc as k,Lc as D,Mb as p,Mc as N,Oa as j,Ra as B,Sc as T,Tc as Y,Yb as s,ad as W,bd as G,ca as Z,cd as w,dc as S,ec as E,f as A,gc as M,hc as V,ic as c,jc as _,kc as I,lc as x,mc as h,nc as L,oc as C,pa as q,pb as v,rb as a,tc as f,uc as o,xb as P,xc as X,ya as d,za as g}from"./chunk-OJMQBH6T.js";var U=t=>[t],Se=t=>({"text-decoration-line-through":t}),Ie=t=>({"text-danger":t}),we=(t,l)=>({"bg-gradient-warning":t,"cell-hover pointer":l});function Fe(t,l){if(t&1){let e=C();c(0,"mat-slide-toggle",13),f("toggleChange",function(){d(e);let n=o();return n.toggleStatus=!n.toggleStatus,g(n.onToggle())}),c(1,"small",14),m(2),_()()}if(t&2){let e=o();a(2),y(" ",e.productToggleTitle?e.productToggleTitle:"FILTER DIFFERENT INVENTORY"," ")}}function Pe(t,l){if(t&1){let e=C();c(0,"th")(1,"input",16),N("ngModelChange",function(n){d(e);let r=o(2);return D(r.checkboxState,n)||(r.checkboxState=n),g(n)}),f("ngModelChange",function(){d(e);let n=o(2);return g(n.onCheckboxStateChange())}),_()()}if(t&2){let e=o(2);a(),k("ngModel",e.checkboxState)}}function Ee(t,l){if(t&1&&(p(0,Pe,2,1,"ng-template",15),c(1,"th",11),m(2,"POS"),_()),t&2){let e=o();s("ngxPermissionsOnly",T(1,U,e.rolePriceEdit))}}function Me(t,l){if(t&1&&(x(0),c(1,"th",17)(2,"div",18)(3,"div",19),I(4,"img",20),c(5,"div",21),m(6),$(7,"stringLimit"),_()()()(),h()),t&2){let e=l.$implicit;a(3),s("matTooltip",(e.Name==null?null:e.Name.length)>20?e.Name:""),a(),s("src",e==null?null:e.Img,v),a(2),y(" ",G(7,3,e.Name,20)," ")}}function Ve(t,l){t&1&&L(0)}function Oe(t,l){if(t&1&&p(0,Ve,1,0,"ng-container",33),t&2){o(2);let e=b(7);s("ngTemplateOutlet",e)}}function ke(t,l){if(t&1&&(x(0),p(1,Oe,1,1,"ng-template",15),h()),t&2){let e=o(4);a(),s("ngxPermissionsOnly",T(1,U,e.roleInventoryUpdate))}}function De(t,l){t&1&&L(0)}function Ne(t,l){if(t&1&&p(0,De,1,0,"ng-container",33),t&2){o(2);let e=b(7);s("ngTemplateOutlet",e)}}function $e(t,l){if(t&1&&p(0,Ne,1,1,"ng-template",15),t&2){let e=o(4);s("ngxPermissionsOnly",T(1,U,e.rolePriceEdit))}}function Ue(t,l){if(t&1){let e=C();x(0),c(1,"div")(2,"input",34),N("ngModelChange",function(n){d(e);let r=o(4).$implicit;return D(r.selected,n)||(r.selected=n),g(n)}),f("ngModelChange",function(){d(e);let n=o(4).$implicit,r=o();return g(r.onCheckboxStateProduct(n.ID))}),_()(),h()}if(t&2){let e=o(4).$implicit;a(2),k("ngModel",e.selected),s("disabled",!(e!=null&&e.Category))}}function Re(t,l){if(t&1&&p(0,Ue,3,2,"ng-container",22),t&2){let e=o(3).$implicit;s("ngIf",(e==null||e.Variants==null?null:e.Variants.length)>1)}}function je(t,l){if(t&1){let e=C();x(0),c(1,"img",35),f("click",function(n){d(e);let r=o(3).$implicit,u=o();return g(u.onZoomImage(n,r==null?null:r.ImageUrl))}),_(),h()}if(t&2){let e=o(3).$implicit;a(),X("src",e==null?null:e.ThumbnailUrl,v)}}function Be(t,l){t&1&&I(0,"img",36)}function Le(t,l){if(t&1&&(x(0),c(1,"td",28)(2,"div",29),p(3,ke,2,3,"ng-container",30)(4,$e,1,3,"ng-template",null,0,w)(6,Re,1,1,"ng-template",null,1,w),c(8,"div"),p(9,je,2,1,"ng-container",30)(10,Be,1,0,"ng-template",null,2,w),_()()(),c(12,"td",31)(13,"div"),m(14),_(),c(15,"small",32),m(16),_()(),h()),t&2){let e=b(5),i=b(11),n=o(2).$implicit,r=o();a(),s("rowSpan",n==null?null:n.Variants.length),a(2),s("ngIf",r.table=="inventory")("ngIfElse",e),a(6),s("ngIf",n==null?null:n.ThumbnailUrl)("ngIfElse",i),a(3),s("rowSpan",n==null?null:n.Variants.length),a(2),O(n==null?null:n.Name),a(),s("ngClass",T(9,Ie,!(n!=null&&n.Category))),a(),y("(",n!=null&&n.Category?n==null?null:n.Category:"Not Found In POS",")")}}function We(t,l){if(t&1&&(c(0,"a",27),I(1,"i",37),_()),t&2){let e=o().$implicit,i=o(2);s("href",i.hostName+"/menu/Products/Catalog/Variants/Info?ID="+(e==null?null:e.ID),v)}}function ze(t,l){if(t&1){let e=C();c(0,"input",40),N("ngModelChange",function(n){d(e);let r=o(3).$implicit;return D(r.selected,n)||(r.selected=n),g(n)}),_()}if(t&2){let e=o(3).$implicit,i=o().$implicit;k("ngModel",e.selected),s("disabled",!(i!=null&&i.Category))}}function Ae(t,l){if(t&1&&(c(0,"td",38),p(1,ze,1,2,"input",39),_()),t&2){let e=o(2).$implicit,i=o(2);a(),s("ngIf",i.printPOS(e)>=0||i.table=="price")}}function He(t,l){if(t&1&&(p(0,Ae,2,1,"ng-template",15),c(1,"td",24),m(2),$(3,"number"),_()),t&2){let e=o().$implicit,i=o(2);s("ngxPermissionsOnly",T(4,U,i.rolePriceEdit)),a(2),O(W(3,2,i.printPOS(e)))}}function Ze(t,l){if(t&1){let e=C();x(0),c(1,"td",41),f("click",function(){d(e);let n=o().$implicit,r=o().$implicit,u=o().$implicit,ve=o();return g(ve.onUpdateData(u.Name,r,n.ID,u.ChannelItemID))}),c(2,"div",42)(3,"div",43),m(4),$(5,"number"),_(),c(6,"a",44),f("click",function(n){return d(e),g(n==null?null:n.stopPropagation())}),I(7,"i",37),_()()(),h()}if(t&2){let e=l.$implicit,i=o(2).$implicit,n=o(2);a(),s("ngClass",Y(5,we,n.printPOS(i)!=n.printItem(e)&&n.hiddenIPOSInventory()==!1,n.hasPriceEdit()&&n.table=="price"||n.hasInventoryEdit()&&n.table=="inventory")),a(3),y(" ",W(5,3,n.printItem(e))," "),a(2),s("href",e.Url,v)}}function qe(t,l){t&1&&(c(0,"td",45)(1,"div",42)(2,"span"),m(3,"X"),_()()())}function Ke(t,l){if(t&1&&p(0,Ze,8,8,"ng-container",30)(1,qe,4,0,"ng-template",null,3,w),t&2){let e=l.$implicit,i=b(2),n=o().$implicit,r=o(2);s("ngIf",r.getItemFromChannel(n,e))("ngIfElse",i)}}function Xe(t,l){if(t&1&&(c(0,"tr"),p(1,Le,17,11,"ng-container",22),c(2,"td",23),m(3),_(),c(4,"td",24)(5,"div",25)(6,"div",26),m(7),_(),c(8,"div",21),p(9,We,2,1,"a",27),_()()(),p(10,He,4,6),M(11,Ke,3,2,null,null,E),_()),t&2){let e=l.$implicit,i=l.$index,n=o().$implicit,r=o();a(),s("ngIf",i==0),a(2),O(e==null?null:e.Model),a(2),s("matTooltip",e.Discontinued?r.discontinuedVariantMsg:""),a(),s("ngClass",T(7,Se,e.Discontinued)),a(),y(" ",e.Code," "),a(2),S(n.Category?9:-1),a(),S(r.hiddenIPOSInventory()==!1?10:-1),a(),V(r.channel)}}function Ye(t,l){if(t&1&&(c(0,"tbody"),M(1,Xe,13,9,"tr",null,E),_()),t&2){let e=l.$implicit;a(),V(e.Variants)}}var vt=(()=>{class t{constructor(e,i,n){this.dialog=e,this.biggerPictureService=i,this.authService=n,this.permissionsService=q(ce),this.showProductToggle=!1,this.multiwarehouse=j(!1),this.hiddenIPOSInventory=j(!1),this.toggleStatus=!1,this.checkboxState=!1,this.rolePriceEdit=F.PriceUpdate,this.roleInventoryUpdate=F.InventoryUpdate,this.hasPriceEdit=B(!1),this.hasInventoryEdit=B(!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 R,this.destroy$=new A,this.toggle=new R,this.hostName=this.authService.getDomain()}ngOnInit(){this.initRoles(),this.table=="inventory"?this.stockHeader="Stock":this.table=="price"&&(this.stockHeader="Price")}initRoles(){this.permissionsService.hasPermission(F.InventoryUpdate).then(e=>this.hasInventoryEdit.set(e)),this.permissionsService.hasPermission(F.PriceUpdate).then(e=>this.hasPriceEdit.set(e))}onCheckboxStateProduct(e){let i=this.data.filter(n=>n.ID==e);i.length>0&&(i=i.map(n=>(n.Variants=n.Variants.map(r=>(r.selected=n.selected,r)),n)))}onCheckboxStateChange(){this.data=this.data.map(e=>(e.Variants=e.Variants.map(i=>(i.selected=this.checkboxState,i)),e))}getItemFromChannel(e,i){return e.Channel.find(r=>z.IsNotEmpty(i.LocationID)?r.LocationID==i.LocationID:r.ChannelID==i.ID)}printItem(e){if(this.table=="inventory")return e.Inventory;if(this.table=="price")return e.Price}onUpdateData(e,i,n,r){this.hasPriceEdit()&&this.table=="price"&&this.onOpenDialogUpdate(e,i,n,r),this.hasInventoryEdit()&&this.table=="inventory"&&this.onOpenDialogUpdate(e,i,n,r)}onOpenDialogUpdate(e,i,n,r){this.dialog.open(be,{data:{Name:e,Variant:i,ChannelID:n,Table:this.table,ChannelItemID:r}}).afterClosed().pipe(H(u=>z.IsNotEmpty(u)),Z(this.destroy$)).subscribe(u=>{this.onSubmit.emit(u)})}printPOS(e){return this.table=="inventory"?e.Inventory?e.Inventory:0:this.table=="price"?e.UnitPrice:null}onToggle(){this.toggle.emit(this.toggleStatus)}onZoomImage(e,i){this.biggerPictureService.openBiggerPicture(e,i)}ngOnDestroy(){this.destroy$.next(!0),this.destroy$.complete()}static{this.\u0275fac=function(i){return new(i||t)(P(ge),P(Ce),P(pe))}}static{this.\u0275cmp=K({type:t,selectors:[["app-table"]],inputs:{data:"data",table:"table",channel:"channel",showProductToggle:"showProductToggle",productToggleTitle:"productToggleTitle",multiwarehouse:[1,"multiwarehouse"],hiddenIPOSInventory:[1,"hiddenIPOSInventory"]},outputs:{onSubmit:"onSubmit",toggle:"onToggle"},decls:17,vars:3,consts:[["PRICE",""],["checkbox_update",""],["elsePic",""],["elseCol",""],[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"],[4,"ngFor","ngForOf"],[2,"width","200px",3,"toggleChange"],[1,"fw-bold"],[3,"ngxPermissionsOnly"],["type","checkbox",3,"ngModelChange","ngModel"],["scope","col"],[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"],[4,"ngIf"],[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"],[4,"ngIf","ngIfElse"],[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"],["src","//res.cloudinary.com/pos/image/upload/w_40/POS/Images/Icon/products_thumb.png",1,"border","rounded","w-img"],[1,"fas","fa-solid","fa-arrow-up-right-from-square","external-link-custom"],[1,"align-middle"],["type","checkbox",3,"ngModel","disabled","ngModelChange",4,"ngIf"],["type","checkbox",3,"ngModelChange","ngModel","disabled"],[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"],[1,"table-white","text-center",2,"color","red"]],template:function(i,n){i&1&&(c(0,"div",4)(1,"table",5)(2,"thead",6)(3,"tr")(4,"th",7)(5,"div",8)(6,"div"),m(7,"Product"),_(),p(8,Fe,3,1,"mat-slide-toggle",9),_()(),c(9,"th",10),m(10,"Variant"),_(),c(11,"th",11),m(12,"SKU"),_(),p(13,Ee,3,3)(14,Me,8,6,"ng-container",12),_()(),M(15,Ye,3,0,"tbody",null,E),_()()),i&2&&(a(8),S(n.showProductToggle?8:-1),a(5),S(n.hiddenIPOSInventory()==!1?13:-1),a(),s("ngForOf",n.channel),a(),V(n.data))},dependencies:[ie,J,Q,ee,te,ne,le,oe,re,ae,Te,fe,ue,xe,he,se,_e,de,me,ye],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}"]})}}return t})();export{vt as a};
1
+ import{a as be,b as ye}from"./chunk-NWWYOZ4V.js";import{a as fe,b as Te}from"./chunk-YTCIQBSO.js";import{b as he}from"./chunk-IHSGQFDX.js";import{a as xe}from"./chunk-HIC5QC3Y.js";import{a as F}from"./chunk-UMP6ZMEJ.js";import{a as Ce}from"./chunk-3YP6ORBR.js";import{i as pe}from"./chunk-WWLC64XZ.js";import{c as z}from"./chunk-PW42BQIY.js";import{d as ge,h as ue}from"./chunk-HJXYT6MI.js";import{A as le,b as oe,h as re,m as ae}from"./chunk-5PS6ZS3N.js";import{a as ce,b as _e,c as se}from"./chunk-ERXVXBTU.js";import{r as me,s as de}from"./chunk-MFQQEEHJ.js";import{d as J,f as Q,g as ee,i as te,m as ne,n as ie}from"./chunk-FXQKRJWU.js";import{$c as $,Fc as b,G as H,Gb as K,Gc as m,Hc as O,Ic as y,Ka as R,Kc as k,Lc as D,Mb as p,Mc as N,Oa as j,Ra as B,Sc as T,Tc as Y,Yb as s,ad as W,bd as G,ca as Z,cd as w,dc as S,ec as E,f as A,gc as M,hc as V,ic as c,jc as _,kc as I,lc as x,mc as h,nc as L,oc as C,pa as q,pb as v,rb as a,tc as f,uc as o,xb as P,xc as X,ya as d,za as g}from"./chunk-OJMQBH6T.js";var U=t=>[t],Se=t=>({"text-decoration-line-through":t}),Ie=t=>({"text-danger":t}),we=(t,l)=>({"bg-gradient-warning":t,"cell-hover pointer":l});function Fe(t,l){if(t&1){let e=C();c(0,"mat-slide-toggle",13),f("toggleChange",function(){d(e);let n=o();return n.toggleStatus=!n.toggleStatus,g(n.onToggle())}),c(1,"small",14),m(2),_()()}if(t&2){let e=o();a(2),y(" ",e.productToggleTitle?e.productToggleTitle:"FILTER DIFFERENT INVENTORY"," ")}}function Pe(t,l){if(t&1){let e=C();c(0,"th")(1,"input",16),N("ngModelChange",function(n){d(e);let r=o(2);return D(r.checkboxState,n)||(r.checkboxState=n),g(n)}),f("ngModelChange",function(){d(e);let n=o(2);return g(n.onCheckboxStateChange())}),_()()}if(t&2){let e=o(2);a(),k("ngModel",e.checkboxState)}}function Ee(t,l){if(t&1&&(p(0,Pe,2,1,"ng-template",15),c(1,"th",11),m(2,"POS"),_()),t&2){let e=o();s("ngxPermissionsOnly",T(1,U,e.rolePriceEdit))}}function Me(t,l){if(t&1&&(x(0),c(1,"th",17)(2,"div",18)(3,"div",19),I(4,"img",20),c(5,"div",21),m(6),$(7,"stringLimit"),_()()()(),h()),t&2){let e=l.$implicit;a(3),s("matTooltip",(e.Name==null?null:e.Name.length)>20?e.Name:""),a(),s("src",e==null?null:e.Img,v),a(2),y(" ",G(7,3,e.Name,20)," ")}}function Ve(t,l){t&1&&L(0)}function Oe(t,l){if(t&1&&p(0,Ve,1,0,"ng-container",33),t&2){o(2);let e=b(7);s("ngTemplateOutlet",e)}}function ke(t,l){if(t&1&&(x(0),p(1,Oe,1,1,"ng-template",15),h()),t&2){let e=o(4);a(),s("ngxPermissionsOnly",T(1,U,e.roleInventoryUpdate))}}function De(t,l){t&1&&L(0)}function Ne(t,l){if(t&1&&p(0,De,1,0,"ng-container",33),t&2){o(2);let e=b(7);s("ngTemplateOutlet",e)}}function $e(t,l){if(t&1&&p(0,Ne,1,1,"ng-template",15),t&2){let e=o(4);s("ngxPermissionsOnly",T(1,U,e.rolePriceEdit))}}function Ue(t,l){if(t&1){let e=C();x(0),c(1,"div")(2,"input",34),N("ngModelChange",function(n){d(e);let r=o(4).$implicit;return D(r.selected,n)||(r.selected=n),g(n)}),f("ngModelChange",function(){d(e);let n=o(4).$implicit,r=o();return g(r.onCheckboxStateProduct(n.ID))}),_()(),h()}if(t&2){let e=o(4).$implicit;a(2),k("ngModel",e.selected),s("disabled",!(e!=null&&e.Category))}}function Re(t,l){if(t&1&&p(0,Ue,3,2,"ng-container",22),t&2){let e=o(3).$implicit;s("ngIf",(e==null||e.Variants==null?null:e.Variants.length)>1)}}function je(t,l){if(t&1){let e=C();x(0),c(1,"img",35),f("click",function(n){d(e);let r=o(3).$implicit,u=o();return g(u.onZoomImage(n,r==null?null:r.ImageUrl))}),_(),h()}if(t&2){let e=o(3).$implicit;a(),X("src",e==null?null:e.ThumbnailUrl,v)}}function Be(t,l){t&1&&I(0,"img",36)}function Le(t,l){if(t&1&&(x(0),c(1,"td",28)(2,"div",29),p(3,ke,2,3,"ng-container",30)(4,$e,1,3,"ng-template",null,0,w)(6,Re,1,1,"ng-template",null,1,w),c(8,"div"),p(9,je,2,1,"ng-container",30)(10,Be,1,0,"ng-template",null,2,w),_()()(),c(12,"td",31)(13,"div"),m(14),_(),c(15,"small",32),m(16),_()(),h()),t&2){let e=b(5),i=b(11),n=o(2).$implicit,r=o();a(),s("rowSpan",n==null?null:n.Variants.length),a(2),s("ngIf",r.table=="inventory")("ngIfElse",e),a(6),s("ngIf",n==null?null:n.ThumbnailUrl)("ngIfElse",i),a(3),s("rowSpan",n==null?null:n.Variants.length),a(2),O(n==null?null:n.Name),a(),s("ngClass",T(9,Ie,!(n!=null&&n.Category))),a(),y("(",n!=null&&n.Category?n==null?null:n.Category:"Not Found In POS",")")}}function We(t,l){if(t&1&&(c(0,"a",27),I(1,"i",37),_()),t&2){let e=o().$implicit,i=o(2);s("href",i.hostName+"/menu/Products/Catalog/Variants/Info?ID="+(e==null?null:e.ID),v)}}function ze(t,l){if(t&1){let e=C();c(0,"input",40),N("ngModelChange",function(n){d(e);let r=o(3).$implicit;return D(r.selected,n)||(r.selected=n),g(n)}),_()}if(t&2){let e=o(3).$implicit,i=o().$implicit;k("ngModel",e.selected),s("disabled",!(i!=null&&i.Category))}}function Ae(t,l){if(t&1&&(c(0,"td",38),p(1,ze,1,2,"input",39),_()),t&2){let e=o(2).$implicit,i=o(2);a(),s("ngIf",i.printPOS(e)>=0||i.table=="price")}}function He(t,l){if(t&1&&(p(0,Ae,2,1,"ng-template",15),c(1,"td",24),m(2),$(3,"number"),_()),t&2){let e=o().$implicit,i=o(2);s("ngxPermissionsOnly",T(4,U,i.rolePriceEdit)),a(2),O(W(3,2,i.printPOS(e)))}}function Ze(t,l){if(t&1){let e=C();x(0),c(1,"td",41),f("click",function(){d(e);let n=o().$implicit,r=o().$implicit,u=o().$implicit,ve=o();return g(ve.onUpdateData(u.Name,r,n.ID,u.ChannelItemID))}),c(2,"div",42)(3,"div",43),m(4),$(5,"number"),_(),c(6,"a",44),f("click",function(n){return d(e),g(n==null?null:n.stopPropagation())}),I(7,"i",37),_()()(),h()}if(t&2){let e=l.$implicit,i=o(2).$implicit,n=o(2);a(),s("ngClass",Y(5,we,n.printPOS(i)!=n.printItem(e)&&n.hiddenIPOSInventory()==!1,n.hasPriceEdit()&&n.table=="price"||n.hasInventoryEdit()&&n.table=="inventory")),a(3),y(" ",W(5,3,n.printItem(e))," "),a(2),s("href",e.Url,v)}}function qe(t,l){t&1&&(c(0,"td",45)(1,"div",42)(2,"span"),m(3,"X"),_()()())}function Ke(t,l){if(t&1&&p(0,Ze,8,8,"ng-container",30)(1,qe,4,0,"ng-template",null,3,w),t&2){let e=l.$implicit,i=b(2),n=o().$implicit,r=o(2);s("ngIf",r.getItemFromChannel(n,e))("ngIfElse",i)}}function Xe(t,l){if(t&1&&(c(0,"tr"),p(1,Le,17,11,"ng-container",22),c(2,"td",23),m(3),_(),c(4,"td",24)(5,"div",25)(6,"div",26),m(7),_(),c(8,"div",21),p(9,We,2,1,"a",27),_()()(),p(10,He,4,6),M(11,Ke,3,2,null,null,E),_()),t&2){let e=l.$implicit,i=l.$index,n=o().$implicit,r=o();a(),s("ngIf",i==0),a(2),O(e==null?null:e.Model),a(2),s("matTooltip",e.Discontinued?r.discontinuedVariantMsg:""),a(),s("ngClass",T(7,Se,e.Discontinued)),a(),y(" ",e.Code," "),a(2),S(n.Category?9:-1),a(),S(r.hiddenIPOSInventory()==!1?10:-1),a(),V(r.channel)}}function Ye(t,l){if(t&1&&(c(0,"tbody"),M(1,Xe,13,9,"tr",null,E),_()),t&2){let e=l.$implicit;a(),V(e.Variants)}}var vt=(()=>{class t{constructor(e,i,n){this.dialog=e,this.biggerPictureService=i,this.authService=n,this.permissionsService=q(ce),this.showProductToggle=!1,this.multiwarehouse=j(!1),this.hiddenIPOSInventory=j(!1),this.toggleStatus=!1,this.checkboxState=!1,this.rolePriceEdit=F.PriceUpdate,this.roleInventoryUpdate=F.InventoryUpdate,this.hasPriceEdit=B(!1),this.hasInventoryEdit=B(!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 R,this.destroy$=new A,this.toggle=new R,this.hostName=this.authService.getDomain()}ngOnInit(){this.initRoles(),this.table=="inventory"?this.stockHeader="Stock":this.table=="price"&&(this.stockHeader="Price")}initRoles(){this.permissionsService.hasPermission(F.InventoryUpdate).then(e=>this.hasInventoryEdit.set(e)),this.permissionsService.hasPermission(F.PriceUpdate).then(e=>this.hasPriceEdit.set(e))}onCheckboxStateProduct(e){let i=this.data.filter(n=>n.ID==e);i.length>0&&(i=i.map(n=>(n.Variants=n.Variants.map(r=>(r.selected=n.selected,r)),n)))}onCheckboxStateChange(){this.data=this.data.map(e=>(e.Variants=e.Variants.map(i=>(i.selected=this.checkboxState,i)),e))}getItemFromChannel(e,i){return e.Channel.find(r=>z.IsNotEmpty(i.LocationID)?r.LocationID==i.LocationID:r.ChannelID==i.ID)}printItem(e){if(this.table=="inventory")return e.Inventory;if(this.table=="price")return e.Price}onUpdateData(e,i,n,r){this.hasPriceEdit()&&this.table=="price"&&this.onOpenDialogUpdate(e,i,n,r),this.hasInventoryEdit()&&this.table=="inventory"&&this.onOpenDialogUpdate(e,i,n,r)}onOpenDialogUpdate(e,i,n,r){this.dialog.open(be,{data:{Name:e,Variant:i,ChannelID:n,Table:this.table,ChannelItemID:r}}).afterClosed().pipe(H(u=>z.IsNotEmpty(u)),Z(this.destroy$)).subscribe(u=>{this.onSubmit.emit(u)})}printPOS(e){return this.table=="inventory"?e.Inventory?e.Inventory:0:this.table=="price"?e.UnitPrice:null}onToggle(){this.toggle.emit(this.toggleStatus)}onZoomImage(e,i){this.biggerPictureService.openBiggerPicture(e,i)}ngOnDestroy(){this.destroy$.next(!0),this.destroy$.complete()}static{this.\u0275fac=function(i){return new(i||t)(P(ge),P(Ce),P(pe))}}static{this.\u0275cmp=K({type:t,selectors:[["app-table"]],inputs:{data:"data",table:"table",channel:"channel",showProductToggle:"showProductToggle",productToggleTitle:"productToggleTitle",multiwarehouse:[1,"multiwarehouse"],hiddenIPOSInventory:[1,"hiddenIPOSInventory"]},outputs:{onSubmit:"onSubmit",toggle:"onToggle"},decls:17,vars:3,consts:[["PRICE",""],["checkbox_update",""],["elsePic",""],["elseCol",""],[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"],[4,"ngFor","ngForOf"],[2,"width","200px",3,"toggleChange"],[1,"fw-bold"],[3,"ngxPermissionsOnly"],["type","checkbox",3,"ngModelChange","ngModel"],["scope","col"],[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"],[4,"ngIf"],[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"],[4,"ngIf","ngIfElse"],[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"],["src","//res.cloudinary.com/pos/image/upload/w_40/POS/Images/Icon/products_thumb.png",1,"border","rounded","w-img"],[1,"fas","fa-solid","fa-arrow-up-right-from-square","external-link-custom"],[1,"align-middle"],["type","checkbox",3,"ngModel","disabled","ngModelChange",4,"ngIf"],["type","checkbox",3,"ngModelChange","ngModel","disabled"],[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"],[1,"table-white","text-center",2,"color","red"]],template:function(i,n){i&1&&(c(0,"div",4)(1,"table",5)(2,"thead",6)(3,"tr")(4,"th",7)(5,"div",8)(6,"div"),m(7,"Product"),_(),p(8,Fe,3,1,"mat-slide-toggle",9),_()(),c(9,"th",10),m(10,"Variant"),_(),c(11,"th",11),m(12,"SKU"),_(),p(13,Ee,3,3)(14,Me,8,6,"ng-container",12),_()(),M(15,Ye,3,0,"tbody",null,E),_()()),i&2&&(a(8),S(n.showProductToggle?8:-1),a(5),S(n.hiddenIPOSInventory()==!1?13:-1),a(),s("ngForOf",n.channel),a(),V(n.data))},dependencies:[ie,J,Q,ee,te,ne,le,oe,re,ae,Te,fe,ue,xe,he,se,_e,de,me,ye],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}"]})}}return t})();export{vt as a};