marketplacepos 2.6.7 → 2.6.9
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/Marketplace/174.082310afa1c1c06a.js +1 -0
- package/Marketplace/369.c0ac32f6e9f87caa.js +1 -0
- package/Marketplace/{463.411bab8a037e3617.js → 463.d4a9bce757f2c5a7.js} +1 -1
- package/Marketplace/475.74988a4c87dd8e84.js +1 -0
- package/Marketplace/index.html +2 -2
- package/Marketplace/{main.67da24f0e6bf7361.js → main.b3c6f53f4a9e3265.js} +1 -1
- package/Marketplace/{runtime.0d6b9fd7b3cbc365.js → runtime.220b1b862137e8cd.js} +1 -1
- package/package.json +1 -1
- package/Marketplace/174.fb88c636b62288f3.js +0 -1
- package/Marketplace/369.ffbe0e365353db54.js +0 -1
- package/Marketplace/475.40ab6c8d730cafca.js +0 -1
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";(self.webpackChunkpos_marketplace=self.webpackChunkpos_marketplace||[]).push([[475],{9475:(ce,I,c)=>{c.r(I),c.d(I,{OrdersModule:()=>hn});var u=c(6895),v=c(6806),e=c(4650),w=c(7398);let L=(()=>{class i{constructor(){this.ObjectOrderTabs=[{Title:"1 - New Order",Url:"/menu/Order/new"},{Title:"2 - Ready to Ship",Url:"/menu/Order/ready_to_ship"},{Title:"3 - Shipped",Url:"/menu/Order/Shipped"},{Title:"4 - Completed",Url:"/menu/Order/Delivered"},{Title:"All",Url:"/menu/Order/All"},{Title:"99 - Cancelled",Url:"/menu/Order/Cancelled"},{Title:"Download",Url:"/menu/Order/Download"}]}ngOnInit(){}}return i.\u0275fac=function(t){return new(t||i)},i.\u0275cmp=e.Xpm({type:i,selectors:[["app-orders"]],decls:5,vars:1,consts:[[1,"navbar","page-nav","navbar-default","py-0","navbar-expand-lg"],[1,"container-fluid"],[3,"Tabs"]],template:function(t,n){1&t&&(e.TgZ(0,"nav",0)(1,"div",1)(2,"div"),e._UZ(3,"nav-tab",2),e.qZA()()(),e._UZ(4,"router-outlet")),2&t&&(e.xp6(3),e.Q6J("Tabs",n.ObjectOrderTabs))},dependencies:[w.e,v.lC]}),i})();var f=c(3154),S=c(1318),C=c(7185),D=c(9568),s=c(4006),l=c(7481),p=c(8796),d=c(2594);function h(i,o){if(1&i&&(e.TgZ(0,"span"),e._uU(1),e.qZA()),2&i){const t=e.oxw().$implicit;e.xp6(1),e.Oqu(t.Number)}}function T(i,o){if(1&i&&(e.TgZ(0,"a",16),e._uU(1),e.qZA()),2&i){const t=e.oxw().$implicit,n=e.oxw();e.Q6J("href",n.domain+t.ID,e.LSH),e.xp6(1),e.Oqu(t.Number)}}function E(i,o){if(1&i&&(e.TgZ(0,"tr")(1,"td"),e._uU(2),e.qZA(),e.TgZ(3,"td"),e.YNc(4,h,2,1,"span",14),e.YNc(5,T,2,2,"a",15),e.qZA(),e.TgZ(6,"td"),e._uU(7),e.qZA(),e.TgZ(8,"td"),e._uU(9),e.ALo(10,"date"),e.qZA()()),2&i){const t=o.$implicit,n=e.oxw();e.xp6(2),e.Oqu(t.Outlet),e.xp6(2),e.Q6J("ngIf",n.hasGuidEmpty(t.ID)),e.xp6(1),e.Q6J("ngIf",!n.hasGuidEmpty(t.ID)),e.xp6(2),e.Oqu(t.Customer),e.xp6(2),e.Oqu(e.xi3(10,5,t.Created,"dd MMM yyyy HH:mm"))}}let ue=(()=>{class i{constructor(t,n,a){this.http=t,this.toastr=n,this.localDataService=a,this.filter={PageNumber:null,PageSize:null},this.totaldata=0,this.paginationTotal=0,this.checkboxState=!1}ngOnInit(){this.Load()}Load(){this.http.post("/api/ordersLoader/GetOrder",{}).subscribe(t=>{this.filter.PageNumber=t.Filter.PageNumber,this.filter.PageSize=t.Filter.RowCount,this.outlets=t.Options.Outlet,this.domain=`https://${this.localDataService.getHostName()}/menu/Orders/Order/Sales_Order/Info?ID=`,this.Get()})}Get(t){this.http.post("api/orders/GetNewOrder",{Number:t,PageNumber:this.filter.PageNumber,PageSize:this.filter.PageSize,Outlet:null!=this.selectedOutlets?this.selectedOutlets:this.outlets}).subscribe(a=>{this.data=a.Data,this.totaldata=this.data.length})}UpdateDelivery(){let t=this.getSelected();if(t.length>0){let n=[];t.forEach(a=>n.push(a)),this.http.post("/api/Orders/UpdateStateDelivery",n).subscribe(a=>{this.toastr.success("Successfully updated","Success")})}}getRowCount(){this.http.post("api/orders/GetRowCount",{Outlet:null!=this.selectedOutlets?this.selectedOutlets:this.outlets}).subscribe(n=>{this.paginationTotal=n.Total})}onCheckboxStateProduct(t){let n=this.data.filter(a=>a.Number==t);if(n.length>0)for(let a of n)a.selected=a.selected}onCheckboxStateChange(){for(let t of this.data)t.selected=this.checkboxState}getSelected(){let t=[];if(this.data){for(let n of this.data)n.selected&&t.push(n);return t}return[]}hasGuidEmpty(t){return t==f.g.GuidEMpty}hasSelection(){return!!this.data&&this.getSelected().length>0}NextPage(){this.filter.PageNumber=this.filter.PageNumber+1,this.Get()}PreviousPage(){this.filter.PageNumber=this.filter.PageNumber-1,this.Get()}}return i.\u0275fac=function(t){return new(t||i)(e.Y36(S.O),e.Y36(C._W),e.Y36(D.T))},i.\u0275cmp=e.Xpm({type:i,selectors:[["app-new-order"]],decls:34,vars:11,consts:[["searchBoxPlaceHolder","Search Orders...",3,"headerTitle","hideSearchBox","onSubmit"],["container","",1,""],["bindLabel","Name","bindValue","ID","placeholder","Choose...",1,"outlet-multiple",3,"multiple","ngModel","items","ngModelChange"],["type","number","name","PageNumber",1,"w-100",3,"ngModel","ngModelChange"],["type","number","name","PageSize",1,"w-100",3,"ngModel","ngModelChange"],[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"],[3,"filter","totaldata","paginationTotal","total","next","previous"],[4,"ngIf"],["target","_blank",3,"href",4,"ngIf"],["target","_blank",3,"href"]],template:function(t,n){1&t&&(e.TgZ(0,"mainpanel",0),e.NdJ("onSubmit",function(r){return n.Get(r)}),e.TgZ(1,"filters")(2,"div",1)(3,"div")(4,"h6"),e._uU(5,"Outlet"),e.qZA(),e.TgZ(6,"ng-select",2),e.NdJ("ngModelChange",function(r){return n.selectedOutlets=r}),e.qZA()(),e.TgZ(7,"div")(8,"h6"),e._uU(9,"Page Number"),e.qZA(),e.TgZ(10,"input",3),e.NdJ("ngModelChange",function(r){return n.filter.PageNumber=r}),e.qZA()(),e.TgZ(11,"div")(12,"h6"),e._uU(13,"Page Size"),e.qZA(),e.TgZ(14,"input",4),e.NdJ("ngModelChange",function(r){return n.filter.PageSize=r}),e.qZA()()()(),e.TgZ(15,"content")(16,"div",5)(17,"div",6)(18,"div",7)(19,"div",8)(20,"table",9)(21,"thead",10)(22,"tr",11)(23,"th"),e._uU(24,"Outlet"),e.qZA(),e.TgZ(25,"th"),e._uU(26,"Order number"),e.qZA(),e.TgZ(27,"th"),e._uU(28,"Customer"),e.qZA(),e.TgZ(29,"th"),e._uU(30,"Created On"),e.qZA()()(),e.TgZ(31,"tbody"),e.YNc(32,E,11,8,"tr",12),e.qZA()(),e.TgZ(33,"app-mat-paginator-no-count",13),e.NdJ("total",function(){return n.getRowCount()})("next",function(){return n.NextPage()})("previous",function(){return n.PreviousPage()}),e.qZA()()()()()()()),2&t&&(e.Q6J("headerTitle","1 - New Order")("hideSearchBox",!0),e.xp6(6),e.Q6J("multiple",!0)("ngModel",n.selectedOutlets)("items",n.outlets),e.xp6(4),e.Q6J("ngModel",n.filter.PageNumber),e.xp6(4),e.Q6J("ngModel",n.filter.PageSize),e.xp6(18),e.Q6J("ngForOf",n.data),e.xp6(1),e.Q6J("filter",n.filter)("totaldata",n.totaldata)("paginationTotal",n.paginationTotal))},dependencies:[u.sg,u.O5,s.Fj,s.wV,s.JJ,s.On,l.p,p.w9,d.n,u.uU]}),i})();function he(i,o){if(1&i&&(e.TgZ(0,"tr")(1,"td"),e._uU(2),e.qZA(),e.TgZ(3,"td"),e._uU(4),e.ALo(5,"number"),e.qZA(),e.TgZ(6,"td"),e._uU(7),e.ALo(8,"number"),e.qZA()()),2&i){const t=o.$implicit;e.xp6(2),e.Oqu(t.Code),e.xp6(2),e.Oqu(e.lcZ(5,3,t.Quantity)),e.xp6(3),e.Oqu(e.lcZ(8,5,t.Price))}}function me(i,o){if(1&i&&(e.TgZ(0,"div",4)(1,"div",5)(2,"div",6)(3,"div",7)(4,"h3",8),e._uU(5,"Outlet Info"),e.qZA()(),e.TgZ(6,"div",4)(7,"div",9),e._uU(8," Outlet : "),e.qZA(),e.TgZ(9,"div",9),e._uU(10),e.qZA()(),e.TgZ(11,"div",4)(12,"div",9),e._uU(13," Date : "),e.qZA(),e.TgZ(14,"div",9),e._uU(15),e.ALo(16,"date"),e.qZA()(),e.TgZ(17,"div",4)(18,"div",9),e._uU(19," Status : "),e.qZA(),e.TgZ(20,"div",9),e._uU(21),e.qZA()(),e.TgZ(22,"div",4)(23,"div",9),e._uU(24," Tax Type : "),e.qZA(),e.TgZ(25,"div",9),e._uU(26),e.qZA()(),e.TgZ(27,"div",4)(28,"div",9),e._uU(29," Due Date : "),e.qZA(),e.TgZ(30,"div",9),e._uU(31),e.ALo(32,"date"),e.qZA()()(),e.TgZ(33,"div",6)(34,"div",7)(35,"h3",8),e._uU(36,"Customer Info"),e.qZA()(),e.TgZ(37,"div",4)(38,"div",9),e._uU(39," Name : "),e.qZA(),e.TgZ(40,"div",9),e._uU(41),e.qZA()(),e.TgZ(42,"div",4)(43,"div",9),e._uU(44," Email : "),e.qZA(),e.TgZ(45,"div",9),e._uU(46),e.qZA()(),e.TgZ(47,"div",4)(48,"div",9),e._uU(49," Mobile : "),e.qZA(),e.TgZ(50,"div",9),e._uU(51),e.qZA()()()(),e.TgZ(52,"div",10)(53,"h3",11),e._uU(54,"Products Sold"),e.qZA(),e.TgZ(55,"div",12)(56,"table",13)(57,"thead",14)(58,"tr",15)(59,"th"),e._uU(60,"Code"),e.qZA(),e.TgZ(61,"th"),e._uU(62,"Quantity"),e.qZA(),e.TgZ(63,"th"),e._uU(64,"Price"),e.qZA()()(),e.TgZ(65,"tbody"),e.YNc(66,he,9,7,"tr",16),e.qZA()()()()()),2&i){const t=e.oxw();e.xp6(10),e.hij(" ",t.model.Outlet," "),e.xp6(5),e.hij(" ",e.xi3(16,9,t.model.Date,"dd MMM yyyy")," "),e.xp6(6),e.hij(" ",t.model.Delivery," "),e.xp6(5),e.hij(" ",t.model.TaxType," "),e.xp6(5),e.hij(" ",e.xi3(32,12,t.model.DueDate,"dd MMM yyyy")," "),e.xp6(10),e.hij(" ",t.model.Customer.Name," "),e.xp6(5),e.hij(" ",t.model.Customer.Email," "),e.xp6(5),e.hij(" ",t.model.Customer.Mobile," "),e.xp6(15),e.Q6J("ngForOf",t.model.Variants)}}const ge=function(){return["/menu/Order"]};let _e=(()=>{class i{constructor(t,n){this.http=t,this.url=n,this.number=this.url.snapshot.queryParams.Number,this.outlet=this.url.snapshot.queryParams.Outlet}ngOnInit(){this.Load()}Load(){this.http.post("/api/orders/GetInvoiceDetail",{Number:this.number,Outlet:this.outlet}).subscribe(n=>{this.model=n})}}return i.\u0275fac=function(t){return new(t||i)(e.Y36(S.O),e.Y36(v.gz))},i.\u0275cmp=e.Xpm({type:i,selectors:[["app-detail-order"]],decls:7,vars:6,consts:[[3,"headerTitle","hideSearchBox","hideSearchDropdown"],["role","button",1,"btn","btn-secondary","btn-fill","btn-lg","me-3",3,"routerLink"],[1,"container"],["class","row",4,"ngIf"],[1,"row"],[1,"col-4"],[1,"border","my-3","py-3","col-12"],[1,"row","m-2"],[1,"text-center"],[1,"col"],[1,"col-8"],[1,"text-center","my-3","py-3"],[1,"table-responsive"],[1,"table"],[1,"sticky-top-thead"],[1,"table-light"],[4,"ngFor","ngForOf"]],template:function(t,n){1&t&&(e.TgZ(0,"mainpanel",0)(1,"actions")(2,"a",1),e._uU(3,"Back"),e.qZA()(),e.TgZ(4,"content")(5,"div",2),e.YNc(6,me,67,15,"div",3),e.qZA()()()),2&t&&(e.Q6J("headerTitle","Order #"+n.number)("hideSearchBox",!0)("hideSearchDropdown",!0),e.xp6(2),e.Q6J("routerLink",e.DdM(5,ge)),e.xp6(4),e.Q6J("ngIf",n.model))},dependencies:[u.sg,u.O5,l.p,v.yS,u.JJ,u.uU]}),i})();var g=c(9694),O=c(5412),$=c(6709);let fe=(()=>{class i{constructor(t){this.dialogRef=t,this.tandaiSudahDicetak=!1}onCancel(){this.dialogRef.close()}onPrint(){this.dialogRef.close(this.tandaiSudahDicetak?1:0)}}return i.\u0275fac=function(t){return new(t||i)(e.Y36(O.so))},i.\u0275cmp=e.Xpm({type:i,selectors:[["app-print-tokopedia"]],decls:17,vars:1,consts:[[1,"container-fluid"],["mat-dialog-title","",1,"text-center","mb-8","fw-bold"],[1,"row"],[1,"col-12"],[1,"fs-5"],[1,"d-flex","align-items-center","text-center","justify-content-center","mb-8"],[1,"me-2",3,"ngModel","ngModelChange"],[1,"fs-5","pt-1"],[1,"d-flex","align-items-center","justify-content-center","mt-6"],[1,"btn","btn-light-blue","text-primary","btn-lg","fw-bold","mx-3",3,"click"],[1,"btn","btn-light-blue","me-6","text-primary","btn-lg","fw-bold","mx-3",3,"click"]],template:function(t,n){1&t&&(e.TgZ(0,"div",0)(1,"h2",1),e._uU(2,"Cetak label pesanan"),e.qZA(),e.TgZ(3,"mat-dialog-content")(4,"div",2)(5,"div",3)(6,"p",4),e._uU(7,"Kamu akan mencetak label yang berisi detail pesanan"),e.qZA(),e.TgZ(8,"div",5)(9,"mat-checkbox",6),e.NdJ("ngModelChange",function(r){return n.tandaiSudahDicetak=r}),e.qZA(),e.TgZ(10,"span",7),e._uU(11,'Pesanan telah ditandai sebagai "Sudah Dicetak"'),e.qZA()()()()(),e.TgZ(12,"mat-dialog-actions",8)(13,"button",9),e.NdJ("click",function(){return n.onCancel()}),e._uU(14,"Cancel"),e.qZA(),e.TgZ(15,"button",10),e.NdJ("click",function(){return n.onPrint()}),e._uU(16,"Cetak Pesanan"),e.qZA()()()),2&t&&(e.xp6(9),e.Q6J("ngModel",n.tandaiSudahDicetak))},dependencies:[s.JJ,s.On,$.oG,O.uh,O.xY,O.H8]}),i})();var ve=c(9300),V=c(3900);let k=(()=>{class i{constructor(t,n,a){this.http=t,this.dialog=n,this.toastr=a}printShippingLabelTokopedia(t){const n={OrderNumber:t,Printed:!0};this.dialog.open(fe).afterClosed().pipe((0,ve.h)(a=>void 0!==a),(0,V.w)(a=>(n.Printed=a,this.http.post("api/v1/Shippinglabel/Tokopedia",n)))).subscribe(a=>{const r=window.open("about:blank","_blank");r.document.write(a),r.document.close()})}printShippingLabelTiktok(t,n){this.http.post("api/v1/Shippinglabel/Tiktok",{ShopID:n,OrderNumber:t}).subscribe(r=>{null!=r.data?window.open(r.data.doc_url,"_blank"):this.toastr.error("Cannot Print the Shipping Label,The invoice Number is not set to Pickup","Cannot Print")})}printShippingLabelShopee(t,n){this.http.post("api/v1/Shippinglabel/shopee/DownloadShipping",{ShopID:n,OrderNumber:t},{responseType:"blob"}).subscribe(r=>{f.g.openDownloadFile(r,`${t}.pdf`)})}}return i.\u0275fac=function(t){return new(t||i)(e.LFG(S.O),e.LFG(O.uw),e.LFG(C._W))},i.\u0275prov=e.Yz7({token:i,factory:i.\u0275fac}),i})(),R=(()=>{class i{constructor(){}set typeId(t){this.channelLogo=f.g.getChannelLogoByTypeId(t),this.initChannelName(t)}initChannelName(t){switch(t){case g.x.Tokopedia:this.channelName="Tokopedia";break;case g.x.Tiktok:this.channelName="Tiktok";break;case g.x.WooCommerce:this.channelName="WooCommerce";break;case g.x.ShopeeV2:this.channelName="Shopee";break;case g.x.Lazada:this.channelName="Lazada";break;case g.x.KalCare:this.channelName="Kalcare"}}}return i.\u0275fac=function(t){return new(t||i)},i.\u0275cmp=e.Xpm({type:i,selectors:[["app-channel-logo"]],inputs:{typeId:"typeId"},decls:4,vars:2,consts:[[1,"d-flex","align-items-center"],[2,"width","20px",3,"src"],[1,"ms-2","fw-bold"]],template:function(t,n){1&t&&(e.TgZ(0,"div",0),e._UZ(1,"img",1),e.TgZ(2,"span",2),e._uU(3),e.qZA()()),2&t&&(e.xp6(1),e.Q6J("src",n.channelLogo,e.LSH),e.xp6(2),e.Oqu(n.channelName))}}),i})();const be=function(){return["/menu/Order/detail"]},Te=function(i,o){return{Number:i,Outlet:o}};function Se(i,o){if(1&i&&(e.TgZ(0,"a",23),e._uU(1),e.qZA()),2&i){const t=e.oxw().$implicit;e.Q6J("routerLink",e.DdM(3,be))("queryParams",e.WLB(4,Te,t.Number,t.Outlet)),e.xp6(1),e.Oqu(t.Number)}}function Ce(i,o){if(1&i&&(e.TgZ(0,"a",24),e._uU(1),e.qZA()),2&i){const t=e.oxw().$implicit,n=e.oxw();e.Q6J("href",n.domain+t.ID,e.LSH),e.xp6(1),e.Oqu(t.Number)}}function xe(i,o){if(1&i){const t=e.EpF();e.TgZ(0,"a",25),e.NdJ("click",function(){e.CHM(t);const a=e.oxw().$implicit,r=e.oxw();return e.KtG(r.onPrintShippingLabel(a.Number,a.ShopID,a.TypeID))}),e._UZ(1,"i",26),e.qZA()}}function ye(i,o){if(1&i){const t=e.EpF();e.TgZ(0,"tr")(1,"td")(2,"input",17),e.NdJ("ngModelChange",function(a){const m=e.CHM(t).$implicit;return e.KtG(m.selected=a)})("ngModelChange",function(){const r=e.CHM(t).$implicit,m=e.oxw();return e.KtG(m.onCheckboxStateProduct(r.Number))}),e.qZA()(),e.TgZ(3,"td"),e._uU(4),e.qZA(),e.TgZ(5,"td"),e.YNc(6,Se,2,7,"a",18),e.YNc(7,Ce,2,2,"a",19),e.qZA(),e.TgZ(8,"td"),e._uU(9),e.qZA(),e.TgZ(10,"td"),e._uU(11),e.ALo(12,"number"),e.qZA(),e.TgZ(13,"td"),e._uU(14),e.ALo(15,"date"),e.qZA(),e.TgZ(16,"td"),e._UZ(17,"app-channel-logo",20),e.qZA(),e.TgZ(18,"td",21),e.YNc(19,xe,2,0,"a",22),e.qZA()()}if(2&i){const t=o.$implicit,n=e.oxw();e.xp6(2),e.Q6J("ngModel",t.selected),e.xp6(2),e.Oqu(t.Outlet),e.xp6(2),e.Q6J("ngIf",n.hasGuidEmpty(t.ID)),e.xp6(1),e.Q6J("ngIf",!n.hasGuidEmpty(t.ID)),e.xp6(2),e.Oqu(t.Customer),e.xp6(2),e.Oqu(e.lcZ(12,9,t.Amount)),e.xp6(3),e.Oqu(e.xi3(15,11,t.Created,"dd MMM yyyy HH:mm")),e.xp6(3),e.Q6J("typeId",t.TypeID),e.xp6(2),e.Q6J("ngIf",t.TypeID==n.channelType.ShopeeV2||t.TypeID==n.channelType.Tokopedia||t.TypeID==n.channelType.Tiktok)}}let Ze=(()=>{class i{constructor(t,n,a,r,m){this.http=t,this.toastr=n,this.localDataService=a,this.dialog=r,this.orderService=m,this.filter={PageNumber:null,PageSize:null},this.totaldata=0,this.paginationTotal=0,this.checkboxState=!1,this.channelType=g.x}ngOnInit(){this.Load()}hasGuidEmpty(t){return t==f.g.GuidEMpty}Load(){this.http.post("/api/ordersLoader/GetOrder",{}).subscribe(t=>{this.filter.PageNumber=t.Filter.PageNumber,this.filter.PageSize=t.Filter.RowCount,this.outlets=t.Options.Outlet,this.domain=`https://${this.localDataService.getHostName()}/menu/Orders/Orders/Customer_Invoice/Info?ID=`,this.Get()})}Get(t){this.http.post("api/orders/GetReadyToShip",{Number:t,PageNumber:this.filter.PageNumber,PageSize:this.filter.PageSize,Outlet:null!=this.selectedOutlets?this.selectedOutlets:this.outlets}).subscribe(a=>{this.data=a.Data,this.totaldata=this.data.length})}onPrintShippingLabel(t,n,a){switch(a){case g.x.Tokopedia:this.orderService.printShippingLabelTokopedia(t);break;case g.x.Tiktok:this.orderService.printShippingLabelTiktok(t,n);break;case g.x.ShopeeV2:this.orderService.printShippingLabelShopee(t,n)}}updateDelivery(){let t=this.getSelected();if(t.length>0){let n=[];t.forEach(a=>n.push(a)),this.http.post("/api/Orders/UpdateStateDelivery",n).subscribe(a=>{this.toastr.success("Successfully updated","Success")})}}StoreRowsCountAPIResult(){this.http.post("api/orders/GetRowCount",{PaymentState:"Unpaid",DeliveryState:"Unsent",Outlet:null!=this.selectedOutlets?this.selectedOutlets:this.outlets}).subscribe(n=>{this.paginationTotal=n.Total})}onCheckboxStateProduct(t){let n=this.data.filter(a=>a.Number==t);if(n.length>0)for(let a of n)a.selected=a.selected}onCheckboxStateChange(){for(let t of this.data)t.selected=this.checkboxState}getSelected(){let t=[];if(this.data){for(let n of this.data)n.selected&&t.push(n);return t}return[]}hasSelection(){return!!this.data&&this.getSelected().length>0}NextPage(){this.filter.PageNumber=this.filter.PageNumber+1,this.Get()}PreviousPage(){this.filter.PageNumber=this.filter.PageNumber-1,this.Get()}}return i.\u0275fac=function(t){return new(t||i)(e.Y36(S.O),e.Y36(C._W),e.Y36(D.T),e.Y36(O.uw),e.Y36(k))},i.\u0275cmp=e.Xpm({type:i,selectors:[["app-ready-to-ship"]],decls:44,vars:12,consts:[["searchBoxPlaceHolder","Search Ready To Ship...",3,"headerTitle","onSubmit"],["container","",1,""],["bindLabel","Name","bindValue","ID","placeholder","Choose...",1,"outlet-multiple",3,"multiple","ngModel","items","ngModelChange"],["type","number","name","PageNumber",1,"w-100",3,"ngModel","ngModelChange"],["type","number","name","PageSize",1,"w-100",3,"ngModel","ngModelChange"],["type","button",1,"btn","btn-success","shadow-sm","rounded","me-3",3,"hidden","click"],[1,"container-fluid","mt-3"],[1,"row"],[1,"col-md-12"],[1,"table-responsive"],[1,"table","table-hover"],[1,"sticky-top-thead"],[1,"table-light"],[2,"width","5px"],["type","checkbox",3,"ngModel","ngModelChange"],[4,"ngFor","ngForOf"],[3,"filter","totaldata","paginationTotal","total","next","previous"],["type","checkbox",1,"me-3",3,"ngModel","ngModelChange"],[3,"routerLink","queryParams",4,"ngIf"],["target","_blank",3,"href",4,"ngIf"],[3,"typeId"],[1,"text-center","text-primary"],["title","Print shipping label",3,"click",4,"ngIf"],[3,"routerLink","queryParams"],["target","_blank",3,"href"],["title","Print shipping label",3,"click"],[1,"fa-solid","fa-print","fs-3","cursor"]],template:function(t,n){1&t&&(e.TgZ(0,"mainpanel",0),e.NdJ("onSubmit",function(r){return n.Get(r)}),e.TgZ(1,"filters")(2,"div",1)(3,"div")(4,"h6"),e._uU(5,"Outlet"),e.qZA(),e.TgZ(6,"ng-select",2),e.NdJ("ngModelChange",function(r){return n.selectedOutlets=r}),e.qZA()(),e.TgZ(7,"div")(8,"h6"),e._uU(9,"Page Number"),e.qZA(),e.TgZ(10,"input",3),e.NdJ("ngModelChange",function(r){return n.filter.PageNumber=r}),e.qZA()(),e.TgZ(11,"div")(12,"h6"),e._uU(13,"Page Size"),e.qZA(),e.TgZ(14,"input",4),e.NdJ("ngModelChange",function(r){return n.filter.PageSize=r}),e.qZA()()()(),e.TgZ(15,"actions")(16,"button",5),e.NdJ("click",function(){return n.updateDelivery()}),e._uU(17," Dispatch "),e.qZA()(),e.TgZ(18,"content")(19,"div",6)(20,"div",7)(21,"div",8)(22,"div",9)(23,"table",10)(24,"thead",11)(25,"tr",12)(26,"th",13)(27,"input",14),e.NdJ("ngModelChange",function(r){return n.checkboxState=r})("ngModelChange",function(){return n.onCheckboxStateChange()}),e.qZA()(),e.TgZ(28,"th"),e._uU(29,"Outlet"),e.qZA(),e.TgZ(30,"th"),e._uU(31,"Order number"),e.qZA(),e.TgZ(32,"th"),e._uU(33,"Customer"),e.qZA(),e.TgZ(34,"th"),e._uU(35,"Amount"),e.qZA(),e.TgZ(36,"th"),e._uU(37,"Created On"),e.qZA(),e.TgZ(38,"th"),e._uU(39,"Channel Name"),e.qZA(),e._UZ(40,"th"),e.qZA()(),e.TgZ(41,"tbody"),e.YNc(42,ye,20,14,"tr",15),e.qZA()(),e.TgZ(43,"app-mat-paginator-no-count",16),e.NdJ("total",function(){return n.StoreRowsCountAPIResult()})("next",function(){return n.NextPage()})("previous",function(){return n.PreviousPage()}),e.qZA()()()()()()()),2&t&&(e.Q6J("headerTitle","2 - Ready to Ship"),e.xp6(6),e.Q6J("multiple",!0)("ngModel",n.selectedOutlets)("items",n.outlets),e.xp6(4),e.Q6J("ngModel",n.filter.PageNumber),e.xp6(4),e.Q6J("ngModel",n.filter.PageSize),e.xp6(2),e.Q6J("hidden",!n.hasSelection()),e.xp6(11),e.Q6J("ngModel",n.checkboxState),e.xp6(15),e.Q6J("ngForOf",n.data),e.xp6(1),e.Q6J("filter",n.filter)("totaldata",n.totaldata)("paginationTotal",n.paginationTotal))},dependencies:[u.sg,u.O5,s.Fj,s.wV,s.Wl,s.JJ,s.On,l.p,v.yS,p.w9,d.n,R,u.JJ,u.uU]}),i})();const De=function(){return["/menu/Order/detail"]},Oe=function(i,o){return{Number:i,Outlet:o}};function Me(i,o){if(1&i&&(e.TgZ(0,"a",19),e._uU(1),e.qZA()),2&i){const t=e.oxw().$implicit;e.Q6J("routerLink",e.DdM(3,De))("queryParams",e.WLB(4,Oe,t.Number,t.Outlet)),e.xp6(1),e.Oqu(t.Number)}}function we(i,o){if(1&i&&(e.TgZ(0,"a",20),e._uU(1),e.qZA()),2&i){const t=e.oxw().$implicit,n=e.oxw();e.Q6J("href",n.domain+t.ID,e.LSH),e.xp6(1),e.Oqu(t.Number)}}function Pe(i,o){if(1&i){const t=e.EpF();e.TgZ(0,"a",21),e.NdJ("click",function(){e.CHM(t);const a=e.oxw().$implicit,r=e.oxw();return e.KtG(r.onPrintShippingLabel(a.Number,a.ShopID,a.TypeID))}),e._UZ(1,"i",22),e.qZA()}}function Ne(i,o){if(1&i&&(e.TgZ(0,"tr")(1,"td"),e._uU(2),e.qZA(),e.TgZ(3,"td"),e.YNc(4,Me,2,7,"a",14),e.YNc(5,we,2,2,"a",15),e.qZA(),e.TgZ(6,"td"),e._uU(7),e.qZA(),e.TgZ(8,"td"),e._uU(9),e.ALo(10,"number"),e.qZA(),e.TgZ(11,"td"),e._uU(12),e.ALo(13,"date"),e.qZA(),e.TgZ(14,"td"),e._UZ(15,"app-channel-logo",16),e.qZA(),e.TgZ(16,"td",17),e.YNc(17,Pe,2,0,"a",18),e.qZA()()),2&i){const t=o.$implicit,n=e.oxw();e.xp6(2),e.Oqu(t.Outlet),e.xp6(2),e.Q6J("ngIf",n.hasGuidEmpty(t.ID)),e.xp6(1),e.Q6J("ngIf",!n.hasGuidEmpty(t.ID)),e.xp6(2),e.Oqu(t.Customer),e.xp6(2),e.Oqu(e.lcZ(10,8,t.Amount)),e.xp6(3),e.Oqu(e.xi3(13,10,t.Created,"dd MMM yyyy HH:mm")),e.xp6(3),e.Q6J("typeId",t.TypeID),e.xp6(2),e.Q6J("ngIf",t.TypeID==n.channelType.ShopeeV2||t.TypeID==n.channelType.Tokopedia||t.TypeID==n.channelType.Tiktok)}}let Ae=(()=>{class i{constructor(t,n,a){this.http=t,this.localDataService=n,this.orderService=a,this.filter={PageNumber:null,PageSize:null},this.totaldata=0,this.paginationTotal=0,this.channelType=g.x}ngOnInit(){this.Load()}Load(){this.http.post("/api/ordersLoader/GetOrder",{}).subscribe(t=>{this.filter.PageNumber=t.Filter.PageNumber,this.filter.PageSize=t.Filter.RowCount,this.outlets=t.Options.Outlet,this.domain=`https://${this.localDataService.getHostName()}/menu/Orders/Orders/Customer_Invoice/Info?ID=`,this.Get()})}hasGuidEmpty(t){return t==f.g.GuidEMpty}Get(t){this.http.post("api/orders/GetShipped",{Number:t,PageNumber:this.filter.PageNumber,PageSize:this.filter.PageSize,Outlet:null!=this.selectedOutlets?this.selectedOutlets:this.outlets}).subscribe(a=>{this.data=a.Data,this.totaldata=this.data.length})}changePage(t){this.filter.PageNumber=t.pageIndex+1,this.Get()}StoreRowsCountAPIResult(){this.http.post("api/orders/GetRowCount",{PaymentState:"Unpaid",DeliveryState:"Sent",Outlet:null!=this.selectedOutlets?this.selectedOutlets:this.outlets}).subscribe(n=>{this.paginationTotal=n.Total})}onPrintShippingLabel(t,n,a){switch(a){case g.x.Tokopedia:this.orderService.printShippingLabelTokopedia(t);break;case g.x.Tiktok:this.orderService.printShippingLabelTiktok(t,n);break;case g.x.ShopeeV2:this.orderService.printShippingLabelShopee(t,n)}}NextPage(){this.filter.PageNumber=this.filter.PageNumber+1,this.Get()}PreviousPage(){this.filter.PageNumber=this.filter.PageNumber-1,this.Get()}}return i.\u0275fac=function(t){return new(t||i)(e.Y36(S.O),e.Y36(D.T),e.Y36(k))},i.\u0275cmp=e.Xpm({type:i,selectors:[["app-shipped"]],decls:39,vars:10,consts:[["searchBoxPlaceHolder","Search Orders...",3,"headerTitle","onSubmit"],["container",""],["bindLabel","Name","bindValue","ID","placeholder","Choose...",1,"outlet-multiple",3,"multiple","ngModel","items","ngModelChange"],["type","number","name","PageNumber",1,"w-100",3,"ngModel","ngModelChange"],["type","number","name","PageSize",1,"w-100",3,"ngModel","ngModelChange"],[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"],[3,"filter","totaldata","paginationTotal","total","next","previous"],[3,"routerLink","queryParams",4,"ngIf"],["target","_blank",3,"href",4,"ngIf"],[3,"typeId"],[1,"text-center","text-primary"],["title","Print shipping label",3,"click",4,"ngIf"],[3,"routerLink","queryParams"],["target","_blank",3,"href"],["title","Print shipping label",3,"click"],[1,"fa-solid","fa-print","fs-3","cursor"]],template:function(t,n){1&t&&(e.TgZ(0,"mainpanel",0),e.NdJ("onSubmit",function(r){return n.Get(r)}),e.TgZ(1,"filters")(2,"div",1)(3,"div")(4,"h6"),e._uU(5,"Outlet"),e.qZA(),e.TgZ(6,"ng-select",2),e.NdJ("ngModelChange",function(r){return n.selectedOutlets=r}),e.qZA()(),e.TgZ(7,"div")(8,"h6"),e._uU(9,"Page Number"),e.qZA(),e.TgZ(10,"input",3),e.NdJ("ngModelChange",function(r){return n.filter.PageNumber=r}),e.qZA()(),e.TgZ(11,"div")(12,"h6"),e._uU(13,"Page Size"),e.qZA(),e.TgZ(14,"input",4),e.NdJ("ngModelChange",function(r){return n.filter.PageSize=r}),e.qZA()()()(),e.TgZ(15,"content")(16,"div",5)(17,"div",6)(18,"div",7)(19,"div",8)(20,"table",9)(21,"thead",10)(22,"tr",11)(23,"th"),e._uU(24,"Outlet"),e.qZA(),e.TgZ(25,"th"),e._uU(26,"Order number"),e.qZA(),e.TgZ(27,"th"),e._uU(28,"Customer"),e.qZA(),e.TgZ(29,"th"),e._uU(30,"Amount"),e.qZA(),e.TgZ(31,"th"),e._uU(32,"Created On"),e.qZA(),e.TgZ(33,"th"),e._uU(34,"Channel Name"),e.qZA(),e._UZ(35,"th"),e.qZA()(),e.TgZ(36,"tbody"),e.YNc(37,Ne,18,13,"tr",12),e.qZA()(),e.TgZ(38,"app-mat-paginator-no-count",13),e.NdJ("total",function(){return n.StoreRowsCountAPIResult()})("next",function(){return n.NextPage()})("previous",function(){return n.PreviousPage()}),e.qZA()()()()()()()),2&t&&(e.Q6J("headerTitle","3 - Shipped"),e.xp6(6),e.Q6J("multiple",!0)("ngModel",n.selectedOutlets)("items",n.outlets),e.xp6(4),e.Q6J("ngModel",n.filter.PageNumber),e.xp6(4),e.Q6J("ngModel",n.filter.PageSize),e.xp6(23),e.Q6J("ngForOf",n.data),e.xp6(1),e.Q6J("filter",n.filter)("totaldata",n.totaldata)("paginationTotal",n.paginationTotal))},dependencies:[u.sg,u.O5,s.Fj,s.wV,s.JJ,s.On,l.p,v.yS,p.w9,d.n,R,u.JJ,u.uU]}),i})();var Ie=c(501);const ke=function(){return["/menu/Order/detail"]},qe=function(i,o){return{Number:i,Outlet:o}};function Ue(i,o){if(1&i&&(e.TgZ(0,"a",19),e._uU(1),e.qZA()),2&i){const t=e.oxw().$implicit;e.Q6J("routerLink",e.DdM(3,ke))("queryParams",e.WLB(4,qe,t.Number,t.Outlet)),e.xp6(1),e.Oqu(t.Number)}}function Je(i,o){if(1&i&&(e.TgZ(0,"a",20),e._uU(1),e.qZA()),2&i){const t=e.oxw().$implicit,n=e.oxw();e.Q6J("href",n.customerInfoUrl+t.ID,e.LSH),e.xp6(1),e.Oqu(t.Number)}}function Le(i,o){if(1&i){const t=e.EpF();e.TgZ(0,"a",21),e.NdJ("click",function(){e.CHM(t);const a=e.oxw().$implicit,r=e.oxw();return e.KtG(r.onPrintShippingLabel(a.Number,a.ShopID,a.TypeID))}),e._UZ(1,"i",22),e.qZA()}}function Ee(i,o){if(1&i&&(e.TgZ(0,"tr")(1,"td"),e._uU(2),e.qZA(),e.TgZ(3,"td"),e.YNc(4,Ue,2,7,"a",14),e.YNc(5,Je,2,2,"a",15),e.qZA(),e.TgZ(6,"td"),e._uU(7),e.qZA(),e.TgZ(8,"td"),e._uU(9),e.ALo(10,"number"),e.qZA(),e.TgZ(11,"td"),e._uU(12),e.ALo(13,"date"),e.qZA(),e.TgZ(14,"td"),e._UZ(15,"app-channel-logo",16),e.qZA(),e.TgZ(16,"td",17),e.YNc(17,Le,2,0,"a",18),e.qZA()()),2&i){const t=o.$implicit,n=e.oxw();e.xp6(2),e.Oqu(t.Outlet),e.xp6(2),e.Q6J("ngIf",n.hasGuidEmpty(t.ID)),e.xp6(1),e.Q6J("ngIf",!n.hasGuidEmpty(t.ID)),e.xp6(2),e.Oqu(t.Customer),e.xp6(2),e.Oqu(e.lcZ(10,8,t.Amount)),e.xp6(3),e.Oqu(e.xi3(13,10,t.Created,"dd MMM yyyy HH:mm")),e.xp6(3),e.Q6J("typeId",t.TypeID),e.xp6(2),e.Q6J("ngIf",t.TypeID==n.channelType.ShopeeV2||t.TypeID==n.channelType.Tokopedia||t.TypeID==n.channelType.Tiktok)}}let Re=(()=>{class i{constructor(t,n,a){this.http=t,this.orderService=n,this.authService=a,this.filter={PageNumber:null,PageSize:null},this.totaldata=0,this.paginationTotal=0,this.channelType=g.x}ngOnInit(){this.Load()}hasGuidEmpty(t){return t==f.g.GuidEMpty}Load(){this.http.post("/api/ordersLoader/GetOrder",{}).subscribe(t=>{this.filter.PageNumber=t.Filter.PageNumber,this.filter.PageSize=t.Filter.RowCount,this.outlets=t.Options.Outlet,this.customerInfoUrl=`${this.authService.getDomain()}/menu/Orders/Orders/Customer_Invoice/Info?ID=`,this.Get()})}Get(t){this.http.post("api/orders/GetDelivered ",{Number:t,PageNumber:this.filter.PageNumber,PageSize:this.filter.PageSize,Outlet:null!=this.selectedOutlets?this.selectedOutlets:this.outlets}).subscribe(a=>{this.data=a.Data,this.totaldata=this.data.length})}changePage(t){this.filter.PageNumber=t.pageIndex+1,this.Get()}StoreRowsCountAPIResult(){this.http.post("api/orders/GetRowCount",{PaymentState:"Paid",DeliveryState:"Sent",Outlet:null!=this.selectedOutlets?this.selectedOutlets:this.outlets}).subscribe(n=>{this.paginationTotal=n.Total})}onPrintShippingLabel(t,n,a){switch(a){case g.x.Tokopedia:this.orderService.printShippingLabelTokopedia(t);break;case g.x.Tiktok:this.orderService.printShippingLabelTiktok(t,n);break;case g.x.ShopeeV2:this.orderService.printShippingLabelShopee(t,n)}}NextPage(){this.filter.PageNumber=this.filter.PageNumber+1,this.Get()}PreviousPage(){this.filter.PageNumber=this.filter.PageNumber-1,this.Get()}}return i.\u0275fac=function(t){return new(t||i)(e.Y36(S.O),e.Y36(k),e.Y36(Ie.e))},i.\u0275cmp=e.Xpm({type:i,selectors:[["app-delivered"]],decls:39,vars:11,consts:[["searchBoxPlaceHolder","Search Orders...",3,"headerTitle","hideSearchBox","onSubmit"],["container","",1,""],["bindLabel","Name","bindValue","ID","placeholder","Choose...",1,"outlet-multiple",3,"multiple","ngModel","items","ngModelChange"],["type","number","name","PageNumber",1,"w-100",3,"ngModel","ngModelChange"],["type","number","name","PageSize",1,"w-100",3,"ngModel","ngModelChange"],[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"],[3,"filter","totaldata","paginationTotal","total","next","previous"],[3,"routerLink","queryParams",4,"ngIf"],["target","_blank",3,"href",4,"ngIf"],[3,"typeId"],[1,"text-center","text-primary"],["title","Print shipping label",3,"click",4,"ngIf"],[3,"routerLink","queryParams"],["target","_blank",3,"href"],["title","Print shipping label",3,"click"],[1,"fa-solid","fa-print","fs-3","cursor"]],template:function(t,n){1&t&&(e.TgZ(0,"mainpanel",0),e.NdJ("onSubmit",function(r){return n.Get(r)}),e.TgZ(1,"filters")(2,"div",1)(3,"div")(4,"h6"),e._uU(5,"Outlet"),e.qZA(),e.TgZ(6,"ng-select",2),e.NdJ("ngModelChange",function(r){return n.selectedOutlets=r}),e.qZA()(),e.TgZ(7,"div")(8,"h6"),e._uU(9,"Page Number"),e.qZA(),e.TgZ(10,"input",3),e.NdJ("ngModelChange",function(r){return n.filter.PageNumber=r}),e.qZA()(),e.TgZ(11,"div")(12,"h6"),e._uU(13,"Page Size"),e.qZA(),e.TgZ(14,"input",4),e.NdJ("ngModelChange",function(r){return n.filter.PageSize=r}),e.qZA()()()(),e.TgZ(15,"content")(16,"div",5)(17,"div",6)(18,"div",7)(19,"div",8)(20,"table",9)(21,"thead",10)(22,"tr",11)(23,"th"),e._uU(24,"Outlet"),e.qZA(),e.TgZ(25,"th"),e._uU(26,"Order number"),e.qZA(),e.TgZ(27,"th"),e._uU(28,"Customer"),e.qZA(),e.TgZ(29,"th"),e._uU(30,"Amount"),e.qZA(),e.TgZ(31,"th"),e._uU(32,"Created On"),e.qZA(),e.TgZ(33,"th"),e._uU(34,"Channel Name"),e.qZA(),e._UZ(35,"th"),e.qZA()(),e.TgZ(36,"tbody"),e.YNc(37,Ee,18,13,"tr",12),e.qZA()(),e.TgZ(38,"app-mat-paginator-no-count",13),e.NdJ("total",function(){return n.StoreRowsCountAPIResult()})("next",function(){return n.NextPage()})("previous",function(){return n.PreviousPage()}),e.qZA()()()()()()()),2&t&&(e.Q6J("headerTitle","4 - Completed")("hideSearchBox",!0),e.xp6(6),e.Q6J("multiple",!0)("ngModel",n.selectedOutlets)("items",n.outlets),e.xp6(4),e.Q6J("ngModel",n.filter.PageNumber),e.xp6(4),e.Q6J("ngModel",n.filter.PageSize),e.xp6(23),e.Q6J("ngForOf",n.data),e.xp6(1),e.Q6J("filter",n.filter)("totaldata",n.totaldata)("paginationTotal",n.paginationTotal))},dependencies:[u.sg,u.O5,s.Fj,s.wV,s.JJ,s.On,l.p,v.yS,p.w9,d.n,R,u.JJ,u.uU]}),i})();const Fe=function(){return["/menu/Order/detail"]},Qe=function(i,o){return{Number:i,Outlet:o}};function ze(i,o){if(1&i&&(e.TgZ(0,"a",16),e._uU(1),e.qZA()),2&i){const t=e.oxw().$implicit;e.Q6J("routerLink",e.DdM(3,Fe))("queryParams",e.WLB(4,Qe,t.Number,t.Outlet)),e.xp6(1),e.Oqu(t.Number)}}function Ge(i,o){if(1&i&&(e.TgZ(0,"a",17),e._uU(1),e.qZA()),2&i){const t=e.oxw().$implicit,n=e.oxw();e.Q6J("href",n.domain+t.ID,e.LSH),e.xp6(1),e.Oqu(t.Number)}}function Ye(i,o){if(1&i&&(e.TgZ(0,"tr")(1,"td"),e._uU(2),e.qZA(),e.TgZ(3,"td"),e.YNc(4,ze,2,7,"a",14),e.YNc(5,Ge,2,2,"a",15),e.qZA(),e.TgZ(6,"td"),e._uU(7),e.qZA(),e.TgZ(8,"td"),e._uU(9),e.ALo(10,"number"),e.qZA(),e.TgZ(11,"td"),e._uU(12),e.ALo(13,"date"),e.qZA(),e.TgZ(14,"td"),e._uU(15),e.qZA()()),2&i){const t=o.$implicit,n=e.oxw();e.xp6(2),e.Oqu(t.Outlet),e.xp6(2),e.Q6J("ngIf",n.hasGuidEmpty(t.ID)),e.xp6(1),e.Q6J("ngIf",!n.hasGuidEmpty(t.ID)),e.xp6(2),e.Oqu(t.Customer),e.xp6(2),e.Oqu(e.lcZ(10,7,t.Amount)),e.xp6(3),e.Oqu(e.xi3(13,9,t.Created,"dd MMM yyyy HH:mm")),e.xp6(3),e.Oqu(t.State)}}let He=(()=>{class i{constructor(t,n){this.http=t,this.localDataService=n,this.filter={PageNumber:null,PageSize:null},this.totaldata=0,this.paginationTotal=0}ngOnInit(){this.Load()}hasGuidEmpty(t){return t==f.g.GuidEMpty}Load(){this.http.post("/api/ordersLoader/GetOrder",{}).subscribe(t=>{this.filter.PageNumber=t.Filter.PageNumber,this.filter.PageSize=t.Filter.RowCount,this.outlets=t.Options.Outlet,this.domain=`https://${this.localDataService.getHostName()}/menu/Orders/Orders/Customer_Invoice/Info?ID=`,this.Get()})}Get(t){this.http.post("api/orders/GetAll ",{Number:t,PageNumber:this.filter.PageNumber,PageSize:this.filter.PageSize,Outlet:null!=this.selectedOutlets?this.selectedOutlets:this.outlets}).subscribe(a=>{this.data=a.Data,this.totaldata=this.data.length})}changePage(t){this.filter=t,this.Get()}StoreRowsCountAPIResult(){this.http.post("api/orders/GetRowCount",{PaymentState:"",DeliveryState:"",Bin:!1,Outlet:null!=this.selectedOutlets?this.selectedOutlets:this.outlets}).subscribe(n=>{this.paginationTotal=n.Total})}NextPage(){this.filter.PageNumber=this.filter.PageNumber+1,this.Get()}PreviousPage(){this.filter.PageNumber=this.filter.PageNumber-1,this.Get()}}return i.\u0275fac=function(t){return new(t||i)(e.Y36(S.O),e.Y36(D.T))},i.\u0275cmp=e.Xpm({type:i,selectors:[["app-all-order"]],decls:38,vars:10,consts:[["searchBoxPlaceHolder","Search Orders...",3,"headerTitle","onSubmit"],["container","",1,""],["bindLabel","Name","bindValue","ID","placeholder","Choose...",1,"outlet-multiple",3,"multiple","ngModel","items","ngModelChange"],["type","number","name","PageNumber",1,"w-100",3,"ngModel","ngModelChange"],["type","number","name","PageSize",1,"w-100",3,"ngModel","ngModelChange"],[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"],[3,"filter","totaldata","paginationTotal","total","next","previous"],[3,"routerLink","queryParams",4,"ngIf"],["target","_blank",3,"href",4,"ngIf"],[3,"routerLink","queryParams"],["target","_blank",3,"href"]],template:function(t,n){1&t&&(e.TgZ(0,"mainpanel",0),e.NdJ("onSubmit",function(r){return n.Get(r)}),e.TgZ(1,"filters")(2,"div",1)(3,"div")(4,"h6"),e._uU(5,"Outlet"),e.qZA(),e.TgZ(6,"ng-select",2),e.NdJ("ngModelChange",function(r){return n.selectedOutlets=r}),e.qZA()(),e.TgZ(7,"div")(8,"h6"),e._uU(9,"Page Number"),e.qZA(),e.TgZ(10,"input",3),e.NdJ("ngModelChange",function(r){return n.filter.PageNumber=r}),e.qZA()(),e.TgZ(11,"div")(12,"h6"),e._uU(13,"Page Size"),e.qZA(),e.TgZ(14,"input",4),e.NdJ("ngModelChange",function(r){return n.filter.PageSize=r}),e.qZA()()()(),e.TgZ(15,"content")(16,"div",5)(17,"div",6)(18,"div",7)(19,"div",8)(20,"table",9)(21,"thead",10)(22,"tr",11)(23,"th"),e._uU(24,"Outlet"),e.qZA(),e.TgZ(25,"th"),e._uU(26,"Order number"),e.qZA(),e.TgZ(27,"th"),e._uU(28,"Customer"),e.qZA(),e.TgZ(29,"th"),e._uU(30,"Amount"),e.qZA(),e.TgZ(31,"th"),e._uU(32,"Created On"),e.qZA(),e.TgZ(33,"th"),e._uU(34,"Status"),e.qZA()()(),e.TgZ(35,"tbody"),e.YNc(36,Ye,16,12,"tr",12),e.qZA()(),e.TgZ(37,"app-mat-paginator-no-count",13),e.NdJ("total",function(){return n.StoreRowsCountAPIResult()})("next",function(){return n.NextPage()})("previous",function(){return n.PreviousPage()}),e.qZA()()()()()()()),2&t&&(e.Q6J("headerTitle","All"),e.xp6(6),e.Q6J("multiple",!0)("ngModel",n.selectedOutlets)("items",n.outlets),e.xp6(4),e.Q6J("ngModel",n.filter.PageNumber),e.xp6(4),e.Q6J("ngModel",n.filter.PageSize),e.xp6(22),e.Q6J("ngForOf",n.data),e.xp6(1),e.Q6J("filter",n.filter)("totaldata",n.totaldata)("paginationTotal",n.paginationTotal))},dependencies:[u.sg,u.O5,s.Fj,s.wV,s.JJ,s.On,l.p,v.yS,p.w9,d.n,u.JJ,u.uU]}),i})();const Be=function(){return["/menu/Order/detail"]},$e=function(i,o){return{Number:i,Outlet:o}};function Ve(i,o){if(1&i&&(e.TgZ(0,"a",16),e._uU(1),e.qZA()),2&i){const t=e.oxw().$implicit;e.Q6J("routerLink",e.DdM(3,Be))("queryParams",e.WLB(4,$e,t.Number,t.Outlet)),e.xp6(1),e.Oqu(t.Number)}}function je(i,o){if(1&i&&(e.TgZ(0,"a",17),e._uU(1),e.qZA()),2&i){const t=e.oxw().$implicit,n=e.oxw();e.Q6J("href",n.domain+t.ID,e.LSH),e.xp6(1),e.Oqu(t.Number)}}function We(i,o){if(1&i&&(e.TgZ(0,"tr")(1,"td"),e._uU(2),e.qZA(),e.TgZ(3,"td"),e.YNc(4,Ve,2,7,"a",14),e.YNc(5,je,2,2,"a",15),e.qZA(),e.TgZ(6,"td"),e._uU(7),e.qZA(),e.TgZ(8,"td"),e._uU(9),e.ALo(10,"number"),e.qZA(),e.TgZ(11,"td"),e._uU(12),e.ALo(13,"date"),e.qZA()()),2&i){const t=o.$implicit,n=e.oxw();e.xp6(2),e.Oqu(t.Outlet),e.xp6(2),e.Q6J("ngIf",n.hasGuidEmpty(t.ID)),e.xp6(1),e.Q6J("ngIf",!n.hasGuidEmpty(t.ID)),e.xp6(2),e.Oqu(t.Customer),e.xp6(2),e.Oqu(e.lcZ(10,6,t.Amount)),e.xp6(3),e.Oqu(e.xi3(13,8,t.Created,"dd MMM yyyy HH:mm"))}}let Ke=(()=>{class i{constructor(t,n){this.http=t,this.localDataService=n,this.filter={PageNumber:null,PageSize:null},this.totaldata=0,this.paginationTotal=0}ngOnInit(){this.Load()}hasGuidEmpty(t){return t==f.g.GuidEMpty}Load(){this.http.post("/api/ordersLoader/GetOrder",{}).subscribe(t=>{this.filter.PageNumber=t.Filter.PageNumber,this.filter.PageSize=t.Filter.RowCount,this.outlets=t.Options.Outlet,this.domain=`https://${this.localDataService.getHostName()}/menu/Orders/Orders/Customer_Invoice/Info?ID=`,this.Get()})}Get(t){this.http.post("api/orders/GetCancelled ",{Number:t,PageNumber:this.filter.PageNumber,PageSize:this.filter.PageSize,Outlet:null!=this.selectedOutlets?this.selectedOutlets:this.outlets}).subscribe(a=>{this.data=a.Data,this.totaldata=this.data.length})}changePage(t){this.filter.PageNumber=t.pageIndex+1,this.Get()}StoreRowsCountAPIResult(){this.http.post("api/orders/GetRowCount",{PaymentState:"",DeliveryState:"",Bin:!0,Outlet:null!=this.selectedOutlets?this.selectedOutlets:this.outlets}).subscribe(n=>{this.paginationTotal=n.Total})}NextPage(){this.filter.PageNumber=this.filter.PageNumber+1,this.Get()}PreviousPage(){this.filter.PageNumber=this.filter.PageNumber-1,this.Get()}}return i.\u0275fac=function(t){return new(t||i)(e.Y36(S.O),e.Y36(D.T))},i.\u0275cmp=e.Xpm({type:i,selectors:[["app-cancelled"]],decls:36,vars:10,consts:[["searchBoxPlaceHolder","Search Orders...",3,"headerTitle","onSubmit"],["container","",1,""],["bindLabel","Name","bindValue","ID","placeholder","Choose...",1,"outlet-multiple",3,"multiple","ngModel","items","ngModelChange"],["type","number","name","PageNumber",1,"w-100",3,"ngModel","ngModelChange"],["type","number","name","PageSize",1,"w-100",3,"ngModel","ngModelChange"],[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"],[3,"filter","totaldata","paginationTotal","total","next","previous"],[3,"routerLink","queryParams",4,"ngIf"],["target","_blank",3,"href",4,"ngIf"],[3,"routerLink","queryParams"],["target","_blank",3,"href"]],template:function(t,n){1&t&&(e.TgZ(0,"mainpanel",0),e.NdJ("onSubmit",function(r){return n.Get(r)}),e.TgZ(1,"filters")(2,"div",1)(3,"div")(4,"h6"),e._uU(5,"Outlet"),e.qZA(),e.TgZ(6,"ng-select",2),e.NdJ("ngModelChange",function(r){return n.selectedOutlets=r}),e.qZA()(),e.TgZ(7,"div")(8,"h6"),e._uU(9,"Page Number"),e.qZA(),e.TgZ(10,"input",3),e.NdJ("ngModelChange",function(r){return n.filter.PageNumber=r}),e.qZA()(),e.TgZ(11,"div")(12,"h6"),e._uU(13,"Page Size"),e.qZA(),e.TgZ(14,"input",4),e.NdJ("ngModelChange",function(r){return n.filter.PageSize=r}),e.qZA()()()(),e.TgZ(15,"content")(16,"div",5)(17,"div",6)(18,"div",7)(19,"div",8)(20,"table",9)(21,"thead",10)(22,"tr",11)(23,"th"),e._uU(24,"Outlet"),e.qZA(),e.TgZ(25,"th"),e._uU(26,"Order number"),e.qZA(),e.TgZ(27,"th"),e._uU(28,"Customer"),e.qZA(),e.TgZ(29,"th"),e._uU(30,"Amount"),e.qZA(),e.TgZ(31,"th"),e._uU(32,"Created On"),e.qZA()()(),e.TgZ(33,"tbody"),e.YNc(34,We,14,11,"tr",12),e.qZA()(),e.TgZ(35,"app-mat-paginator-no-count",13),e.NdJ("total",function(){return n.StoreRowsCountAPIResult()})("next",function(){return n.NextPage()})("previous",function(){return n.PreviousPage()}),e.qZA()()()()()()()),2&t&&(e.Q6J("headerTitle","99 - Cancelled"),e.xp6(6),e.Q6J("multiple",!0)("ngModel",n.selectedOutlets)("items",n.outlets),e.xp6(4),e.Q6J("ngModel",n.filter.PageNumber),e.xp6(4),e.Q6J("ngModel",n.filter.PageSize),e.xp6(20),e.Q6J("ngForOf",n.data),e.xp6(1),e.Q6J("filter",n.filter)("totaldata",n.totaldata)("paginationTotal",n.paginationTotal))},dependencies:[u.sg,u.O5,s.Fj,s.wV,s.JJ,s.On,l.p,v.yS,p.w9,d.n,u.JJ,u.uU]}),i})();var j=c(2687),F=c(445),P=c(1281),Q=c(9521),Xe=c(3353),z=c(7579),et=c(9646),q=c(8675),N=c(2722);function tt(i,o){1&i&&e.Hsn(0)}const nt=["*"];let W=(()=>{class i{constructor(t){this._elementRef=t}focus(){this._elementRef.nativeElement.focus()}}return i.\u0275fac=function(t){return new(t||i)(e.Y36(e.SBq))},i.\u0275dir=e.lG2({type:i,selectors:[["","cdkStepHeader",""]],hostAttrs:["role","tab"]}),i})(),K=(()=>{class i{constructor(t){this.template=t}}return i.\u0275fac=function(t){return new(t||i)(e.Y36(e.Rgc))},i.\u0275dir=e.lG2({type:i,selectors:[["","cdkStepLabel",""]]}),i})(),it=0;const G=new e.OlP("STEPPER_GLOBAL_OPTIONS");let Y=(()=>{class i{constructor(t,n){this._stepper=t,this.interacted=!1,this.interactedStream=new e.vpe,this._editable=!0,this._optional=!1,this._completedOverride=null,this._customError=null,this._stepperOptions=n||{},this._displayDefaultIndicatorType=!1!==this._stepperOptions.displayDefaultIndicatorType}get editable(){return this._editable}set editable(t){this._editable=(0,P.Ig)(t)}get optional(){return this._optional}set optional(t){this._optional=(0,P.Ig)(t)}get completed(){return this._completedOverride??this._getDefaultCompleted()}set completed(t){this._completedOverride=(0,P.Ig)(t)}_getDefaultCompleted(){return this.stepControl?this.stepControl.valid&&this.interacted:this.interacted}get hasError(){return this._customError??this._getDefaultError()}set hasError(t){this._customError=(0,P.Ig)(t)}_getDefaultError(){return this.stepControl&&this.stepControl.invalid&&this.interacted}select(){this._stepper.selected=this}reset(){this.interacted=!1,null!=this._completedOverride&&(this._completedOverride=!1),null!=this._customError&&(this._customError=!1),this.stepControl&&this.stepControl.reset()}ngOnChanges(){this._stepper._stateChanged()}_markAsInteracted(){this.interacted||(this.interacted=!0,this.interactedStream.emit(this))}_showError(){return this._stepperOptions.showError??null!=this._customError}}return i.\u0275fac=function(t){return new(t||i)(e.Y36((0,e.Gpc)(()=>H)),e.Y36(G,8))},i.\u0275cmp=e.Xpm({type:i,selectors:[["cdk-step"]],contentQueries:function(t,n,a){if(1&t&&e.Suo(a,K,5),2&t){let r;e.iGM(r=e.CRH())&&(n.stepLabel=r.first)}},viewQuery:function(t,n){if(1&t&&e.Gf(e.Rgc,7),2&t){let a;e.iGM(a=e.CRH())&&(n.content=a.first)}},inputs:{stepControl:"stepControl",label:"label",errorMessage:"errorMessage",ariaLabel:["aria-label","ariaLabel"],ariaLabelledby:["aria-labelledby","ariaLabelledby"],state:"state",editable:"editable",optional:"optional",completed:"completed",hasError:"hasError"},outputs:{interactedStream:"interacted"},exportAs:["cdkStep"],features:[e.TTD],ngContentSelectors:nt,decls:1,vars:0,template:function(t,n){1&t&&(e.F$t(),e.YNc(0,tt,1,0,"ng-template"))},encapsulation:2,changeDetection:0}),i})(),H=(()=>{class i{constructor(t,n,a){this._dir=t,this._changeDetectorRef=n,this._elementRef=a,this._destroyed=new z.x,this.steps=new e.n_E,this._sortedHeaders=new e.n_E,this._linear=!1,this._selectedIndex=0,this.selectionChange=new e.vpe,this._orientation="horizontal",this._groupId=it++}get linear(){return this._linear}set linear(t){this._linear=(0,P.Ig)(t)}get selectedIndex(){return this._selectedIndex}set selectedIndex(t){const n=(0,P.su)(t);this.steps&&this._steps?(this._isValidIndex(n),this.selected?._markAsInteracted(),this._selectedIndex!==n&&!this._anyControlsInvalidOrPending(n)&&(n>=this._selectedIndex||this.steps.toArray()[n].editable)&&this._updateSelectedItemIndex(n)):this._selectedIndex=n}get selected(){return this.steps?this.steps.toArray()[this.selectedIndex]:void 0}set selected(t){this.selectedIndex=t&&this.steps?this.steps.toArray().indexOf(t):-1}get orientation(){return this._orientation}set orientation(t){this._orientation=t,this._keyManager&&this._keyManager.withVerticalOrientation("vertical"===t)}ngAfterContentInit(){this._steps.changes.pipe((0,q.O)(this._steps),(0,N.R)(this._destroyed)).subscribe(t=>{this.steps.reset(t.filter(n=>n._stepper===this)),this.steps.notifyOnChanges()})}ngAfterViewInit(){this._stepHeader.changes.pipe((0,q.O)(this._stepHeader),(0,N.R)(this._destroyed)).subscribe(t=>{this._sortedHeaders.reset(t.toArray().sort((n,a)=>n._elementRef.nativeElement.compareDocumentPosition(a._elementRef.nativeElement)&Node.DOCUMENT_POSITION_FOLLOWING?-1:1)),this._sortedHeaders.notifyOnChanges()}),this._keyManager=new j.Em(this._sortedHeaders).withWrap().withHomeAndEnd().withVerticalOrientation("vertical"===this._orientation),(this._dir?this._dir.change:(0,et.of)()).pipe((0,q.O)(this._layoutDirection()),(0,N.R)(this._destroyed)).subscribe(t=>this._keyManager.withHorizontalOrientation(t)),this._keyManager.updateActiveItem(this._selectedIndex),this.steps.changes.subscribe(()=>{this.selected||(this._selectedIndex=Math.max(this._selectedIndex-1,0))}),this._isValidIndex(this._selectedIndex)||(this._selectedIndex=0)}ngOnDestroy(){this.steps.destroy(),this._sortedHeaders.destroy(),this._destroyed.next(),this._destroyed.complete()}next(){this.selectedIndex=Math.min(this._selectedIndex+1,this.steps.length-1)}previous(){this.selectedIndex=Math.max(this._selectedIndex-1,0)}reset(){this._updateSelectedItemIndex(0),this.steps.forEach(t=>t.reset()),this._stateChanged()}_getStepLabelId(t){return`cdk-step-label-${this._groupId}-${t}`}_getStepContentId(t){return`cdk-step-content-${this._groupId}-${t}`}_stateChanged(){this._changeDetectorRef.markForCheck()}_getAnimationDirection(t){const n=t-this._selectedIndex;return n<0?"rtl"===this._layoutDirection()?"next":"previous":n>0?"rtl"===this._layoutDirection()?"previous":"next":"current"}_getIndicatorType(t,n="number"){const a=this.steps.toArray()[t],r=this._isCurrentStep(t);return a._displayDefaultIndicatorType?this._getDefaultIndicatorLogic(a,r):this._getGuidelineLogic(a,r,n)}_getDefaultIndicatorLogic(t,n){return t._showError()&&t.hasError&&!n?"error":!t.completed||n?"number":t.editable?"edit":"done"}_getGuidelineLogic(t,n,a="number"){return t._showError()&&t.hasError&&!n?"error":t.completed&&!n?"done":t.completed&&n?a:t.editable&&n?"edit":a}_isCurrentStep(t){return this._selectedIndex===t}_getFocusIndex(){return this._keyManager?this._keyManager.activeItemIndex:this._selectedIndex}_updateSelectedItemIndex(t){const n=this.steps.toArray();this.selectionChange.emit({selectedIndex:t,previouslySelectedIndex:this._selectedIndex,selectedStep:n[t],previouslySelectedStep:n[this._selectedIndex]}),this._containsFocus()?this._keyManager.setActiveItem(t):this._keyManager.updateActiveItem(t),this._selectedIndex=t,this._stateChanged()}_onKeydown(t){const n=(0,Q.Vb)(t),a=t.keyCode,r=this._keyManager;null==r.activeItemIndex||n||a!==Q.L_&&a!==Q.K5?r.onKeydown(t):(this.selectedIndex=r.activeItemIndex,t.preventDefault())}_anyControlsInvalidOrPending(t){return!!(this._linear&&t>=0)&&this.steps.toArray().slice(0,t).some(n=>{const a=n.stepControl;return(a?a.invalid||a.pending||!n.interacted:!n.completed)&&!n.optional&&!n._completedOverride})}_layoutDirection(){return this._dir&&"rtl"===this._dir.value?"rtl":"ltr"}_containsFocus(){const t=this._elementRef.nativeElement,n=(0,Xe.ht)();return t===n||t.contains(n)}_isValidIndex(t){return t>-1&&(!this.steps||t<this.steps.length)}}return i.\u0275fac=function(t){return new(t||i)(e.Y36(F.Is,8),e.Y36(e.sBO),e.Y36(e.SBq))},i.\u0275dir=e.lG2({type:i,selectors:[["","cdkStepper",""]],contentQueries:function(t,n,a){if(1&t&&(e.Suo(a,Y,5),e.Suo(a,W,5)),2&t){let r;e.iGM(r=e.CRH())&&(n._steps=r),e.iGM(r=e.CRH())&&(n._stepHeader=r)}},inputs:{linear:"linear",selectedIndex:"selectedIndex",selected:"selected",orientation:"orientation"},outputs:{selectionChange:"selectionChange"},exportAs:["cdkStepper"]}),i})(),at=(()=>{class i{}return i.\u0275fac=function(t){return new(t||i)},i.\u0275mod=e.oAB({type:i}),i.\u0275inj=e.cJS({imports:[F.vT]}),i})();var M=(()=>{return(i=M||(M={}))[i.DoNothing=0]="DoNothing",i[i.New=1]="New",i[i.Update=2]="Update",M;var i})(),ot=c(6082),A=c(9602),B=c(4080),rt=c(9101),y=c(3238),X=c(7392),st=c(727),lt=c(4004),pt=c(1884),_=c(7340);function dt(i,o){if(1&i&&e.GkF(0,8),2&i){const t=e.oxw();e.Q6J("ngTemplateOutlet",t.iconOverrides[t.state])("ngTemplateOutletContext",t._getIconContext())}}function ct(i,o){if(1&i&&(e.TgZ(0,"span",13),e._uU(1),e.qZA()),2&i){const t=e.oxw(2);e.xp6(1),e.Oqu(t._getDefaultTextForState(t.state))}}function ut(i,o){if(1&i&&(e.TgZ(0,"span",14),e._uU(1),e.qZA()),2&i){const t=e.oxw(2);e.xp6(1),e.Oqu(t._intl.completedLabel)}}function ht(i,o){if(1&i&&(e.TgZ(0,"span",14),e._uU(1),e.qZA()),2&i){const t=e.oxw(2);e.xp6(1),e.Oqu(t._intl.editableLabel)}}function mt(i,o){if(1&i&&(e.TgZ(0,"mat-icon",13),e._uU(1),e.qZA()),2&i){const t=e.oxw(2);e.xp6(1),e.Oqu(t._getDefaultTextForState(t.state))}}function gt(i,o){if(1&i&&(e.ynx(0,9),e.YNc(1,ct,2,1,"span",10),e.YNc(2,ut,2,1,"span",11),e.YNc(3,ht,2,1,"span",11),e.YNc(4,mt,2,1,"mat-icon",12),e.BQk()),2&i){const t=e.oxw();e.Q6J("ngSwitch",t.state),e.xp6(1),e.Q6J("ngSwitchCase","number"),e.xp6(1),e.Q6J("ngIf","done"===t.state),e.xp6(1),e.Q6J("ngIf","edit"===t.state)}}function _t(i,o){if(1&i&&(e.TgZ(0,"div",15),e.GkF(1,16),e.qZA()),2&i){const t=e.oxw();e.xp6(1),e.Q6J("ngTemplateOutlet",t._templateLabel().template)}}function ft(i,o){if(1&i&&(e.TgZ(0,"div",15),e._uU(1),e.qZA()),2&i){const t=e.oxw();e.xp6(1),e.Oqu(t.label)}}function vt(i,o){if(1&i&&(e.TgZ(0,"div",17),e._uU(1),e.qZA()),2&i){const t=e.oxw();e.xp6(1),e.Oqu(t._intl.optionalLabel)}}function bt(i,o){if(1&i&&(e.TgZ(0,"div",18),e._uU(1),e.qZA()),2&i){const t=e.oxw();e.xp6(1),e.Oqu(t.errorMessage)}}function Tt(i,o){}function St(i,o){if(1&i&&(e.Hsn(0),e.YNc(1,Tt,0,0,"ng-template",0)),2&i){const t=e.oxw();e.xp6(1),e.Q6J("cdkPortalOutlet",t._portal)}}const Ct=["*"];function xt(i,o){1&i&&e._UZ(0,"div",11)}const ee=function(i,o){return{step:i,i:o}};function yt(i,o){if(1&i&&(e.ynx(0),e.GkF(1,9),e.YNc(2,xt,1,0,"div",10),e.BQk()),2&i){const t=o.$implicit,n=o.index,a=o.last;e.oxw(2);const r=e.MAs(4);e.xp6(1),e.Q6J("ngTemplateOutlet",r)("ngTemplateOutletContext",e.WLB(3,ee,t,n)),e.xp6(1),e.Q6J("ngIf",!a)}}const te=function(i){return{animationDuration:i}},ne=function(i,o){return{value:i,params:o}};function Zt(i,o){if(1&i){const t=e.EpF();e.TgZ(0,"div",12),e.NdJ("@horizontalStepTransition.done",function(a){e.CHM(t);const r=e.oxw(2);return e.KtG(r._animationDone.next(a))}),e.GkF(1,13),e.qZA()}if(2&i){const t=o.$implicit,n=o.index,a=e.oxw(2);e.Q6J("@horizontalStepTransition",e.WLB(7,ne,a._getAnimationDirection(n),e.VKq(5,te,a._getAnimationDuration())))("id",a._getStepContentId(n)),e.uIk("aria-labelledby",a._getStepLabelId(n))("aria-expanded",a.selectedIndex===n),e.xp6(1),e.Q6J("ngTemplateOutlet",t.content)}}function Dt(i,o){if(1&i&&(e.TgZ(0,"div",4)(1,"div",5),e.YNc(2,yt,3,6,"ng-container",6),e.qZA(),e.TgZ(3,"div",7),e.YNc(4,Zt,2,10,"div",8),e.qZA()()),2&i){const t=e.oxw();e.xp6(2),e.Q6J("ngForOf",t.steps),e.xp6(2),e.Q6J("ngForOf",t.steps)}}function Ot(i,o){if(1&i){const t=e.EpF();e.TgZ(0,"div",15),e.GkF(1,9),e.TgZ(2,"div",16)(3,"div",17),e.NdJ("@verticalStepTransition.done",function(a){e.CHM(t);const r=e.oxw(2);return e.KtG(r._animationDone.next(a))}),e.TgZ(4,"div",18),e.GkF(5,13),e.qZA()()()()}if(2&i){const t=o.$implicit,n=o.index,a=o.last,r=e.oxw(2),m=e.MAs(4);e.xp6(1),e.Q6J("ngTemplateOutlet",m)("ngTemplateOutletContext",e.WLB(9,ee,t,n)),e.xp6(1),e.ekj("mat-stepper-vertical-line",!a),e.xp6(1),e.Q6J("@verticalStepTransition",e.WLB(14,ne,r._getAnimationDirection(n),e.VKq(12,te,r._getAnimationDuration())))("id",r._getStepContentId(n)),e.uIk("aria-labelledby",r._getStepLabelId(n))("aria-expanded",r.selectedIndex===n),e.xp6(2),e.Q6J("ngTemplateOutlet",t.content)}}function Mt(i,o){if(1&i&&(e.ynx(0),e.YNc(1,Ot,6,17,"div",14),e.BQk()),2&i){const t=e.oxw();e.xp6(1),e.Q6J("ngForOf",t.steps)}}function wt(i,o){if(1&i){const t=e.EpF();e.TgZ(0,"mat-step-header",19),e.NdJ("click",function(){const r=e.CHM(t).step;return e.KtG(r.select())})("keydown",function(a){e.CHM(t);const r=e.oxw();return e.KtG(r._onKeydown(a))}),e.qZA()}if(2&i){const t=o.step,n=o.i,a=e.oxw();e.ekj("mat-horizontal-stepper-header","horizontal"===a.orientation)("mat-vertical-stepper-header","vertical"===a.orientation),e.Q6J("tabIndex",a._getFocusIndex()===n?0:-1)("id",a._getStepLabelId(n))("index",n)("state",a._getIndicatorType(n,t.state))("label",t.stepLabel||t.label)("selected",a.selectedIndex===n)("active",a._stepIsNavigable(n,t))("optional",t.optional)("errorMessage",t.errorMessage)("iconOverrides",a._iconOverrides)("disableRipple",a.disableRipple||!a._stepIsNavigable(n,t))("color",t.color||a.color),e.uIk("aria-posinset",n+1)("aria-setsize",a.steps.length)("aria-controls",a._getStepContentId(n))("aria-selected",a.selectedIndex==n)("aria-label",t.ariaLabel||null)("aria-labelledby",!t.ariaLabel&&t.ariaLabelledby?t.ariaLabelledby:null)("aria-disabled",!a._stepIsNavigable(n,t)||null)}}let U=(()=>{class i extends K{}return i.\u0275fac=function(){let o;return function(n){return(o||(o=e.n5z(i)))(n||i)}}(),i.\u0275dir=e.lG2({type:i,selectors:[["","matStepLabel",""]],features:[e.qOj]}),i})(),J=(()=>{class i{constructor(){this.changes=new z.x,this.optionalLabel="Optional",this.completedLabel="Completed",this.editableLabel="Editable"}}return i.\u0275fac=function(t){return new(t||i)},i.\u0275prov=e.Yz7({token:i,factory:i.\u0275fac,providedIn:"root"}),i})();const Nt={provide:J,deps:[[new e.FiY,new e.tp0,J]],useFactory:function Pt(i){return i||new J}},At=(0,y.pj)(class extends W{constructor(o){super(o)}},"primary");let ie=(()=>{class i extends At{constructor(t,n,a,r){super(a),this._intl=t,this._focusMonitor=n,this._intlSubscription=t.changes.subscribe(()=>r.markForCheck())}ngAfterViewInit(){this._focusMonitor.monitor(this._elementRef,!0)}ngOnDestroy(){this._intlSubscription.unsubscribe(),this._focusMonitor.stopMonitoring(this._elementRef)}focus(t,n){t?this._focusMonitor.focusVia(this._elementRef,t,n):this._elementRef.nativeElement.focus(n)}_stringLabel(){return this.label instanceof U?null:this.label}_templateLabel(){return this.label instanceof U?this.label:null}_getHostElement(){return this._elementRef.nativeElement}_getIconContext(){return{index:this.index,active:this.active,optional:this.optional}}_getDefaultTextForState(t){return"number"==t?`${this.index+1}`:"edit"==t?"create":"error"==t?"warning":t}}return i.\u0275fac=function(t){return new(t||i)(e.Y36(J),e.Y36(j.tE),e.Y36(e.SBq),e.Y36(e.sBO))},i.\u0275cmp=e.Xpm({type:i,selectors:[["mat-step-header"]],hostAttrs:["role","tab",1,"mat-step-header"],inputs:{color:"color",state:"state",label:"label",errorMessage:"errorMessage",iconOverrides:"iconOverrides",index:"index",selected:"selected",active:"active",optional:"optional",disableRipple:"disableRipple"},features:[e.qOj],decls:10,vars:19,consts:[["matRipple","",1,"mat-step-header-ripple","mat-focus-indicator",3,"matRippleTrigger","matRippleDisabled"],[1,"mat-step-icon-content",3,"ngSwitch"],[3,"ngTemplateOutlet","ngTemplateOutletContext",4,"ngSwitchCase"],[3,"ngSwitch",4,"ngSwitchDefault"],[1,"mat-step-label"],["class","mat-step-text-label",4,"ngIf"],["class","mat-step-optional",4,"ngIf"],["class","mat-step-sub-label-error",4,"ngIf"],[3,"ngTemplateOutlet","ngTemplateOutletContext"],[3,"ngSwitch"],["aria-hidden","true",4,"ngSwitchCase"],["class","cdk-visually-hidden",4,"ngIf"],["aria-hidden","true",4,"ngSwitchDefault"],["aria-hidden","true"],[1,"cdk-visually-hidden"],[1,"mat-step-text-label"],[3,"ngTemplateOutlet"],[1,"mat-step-optional"],[1,"mat-step-sub-label-error"]],template:function(t,n){1&t&&(e._UZ(0,"div",0),e.TgZ(1,"div")(2,"div",1),e.YNc(3,dt,1,2,"ng-container",2),e.YNc(4,gt,5,4,"ng-container",3),e.qZA()(),e.TgZ(5,"div",4),e.YNc(6,_t,2,1,"div",5),e.YNc(7,ft,2,1,"div",5),e.YNc(8,vt,2,1,"div",6),e.YNc(9,bt,2,1,"div",7),e.qZA()),2&t&&(e.Q6J("matRippleTrigger",n._getHostElement())("matRippleDisabled",n.disableRipple),e.xp6(1),e.Gre("mat-step-icon-state-",n.state," mat-step-icon"),e.ekj("mat-step-icon-selected",n.selected),e.xp6(1),e.Q6J("ngSwitch",!(!n.iconOverrides||!n.iconOverrides[n.state])),e.xp6(1),e.Q6J("ngSwitchCase",!0),e.xp6(2),e.ekj("mat-step-label-active",n.active)("mat-step-label-selected",n.selected)("mat-step-label-error","error"==n.state),e.xp6(1),e.Q6J("ngIf",n._templateLabel()),e.xp6(1),e.Q6J("ngIf",n._stringLabel()),e.xp6(1),e.Q6J("ngIf",n.optional&&"error"!=n.state),e.xp6(1),e.Q6J("ngIf","error"==n.state))},dependencies:[u.O5,u.tP,u.RF,u.n9,u.ED,X.Hw,y.wG],styles:[".mat-step-header{overflow:hidden;outline:none;cursor:pointer;position:relative;box-sizing:content-box;-webkit-tap-highlight-color:rgba(0,0,0,0)}.cdk-high-contrast-active .mat-step-header{outline:solid 1px}.cdk-high-contrast-active .mat-step-header.cdk-keyboard-focused,.cdk-high-contrast-active .mat-step-header.cdk-program-focused{outline:solid 3px}.cdk-high-contrast-active .mat-step-header[aria-selected=true] .mat-step-label{text-decoration:underline}.mat-step-optional,.mat-step-sub-label-error{font-size:12px}.mat-step-icon{border-radius:50%;height:24px;width:24px;flex-shrink:0;position:relative}.mat-step-icon-content{position:absolute;top:50%;left:50%;transform:translate(-50%, -50%);display:flex}.mat-step-icon .mat-icon{font-size:16px;height:16px;width:16px}.mat-step-icon-state-error .mat-icon{font-size:24px;height:24px;width:24px}.mat-step-label{display:inline-block;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;min-width:50px;vertical-align:middle}.mat-step-text-label{text-overflow:ellipsis;overflow:hidden}.mat-step-header .mat-step-header-ripple{top:0;left:0;right:0;bottom:0;position:absolute;pointer-events:none}"],encapsulation:2,changeDetection:0}),i})();const re={horizontalStepTransition:(0,_.X$)("horizontalStepTransition",[(0,_.SB)("previous",(0,_.oB)({transform:"translate3d(-100%, 0, 0)",visibility:"hidden"})),(0,_.SB)("current",(0,_.oB)({transform:"none",visibility:"inherit"})),(0,_.SB)("next",(0,_.oB)({transform:"translate3d(100%, 0, 0)",visibility:"hidden"})),(0,_.eR)("* => *",(0,_.jt)("{{animationDuration}} cubic-bezier(0.35, 0, 0.25, 1)"),{params:{animationDuration:"500ms"}})]),verticalStepTransition:(0,_.X$)("verticalStepTransition",[(0,_.SB)("previous",(0,_.oB)({height:"0px",visibility:"hidden"})),(0,_.SB)("next",(0,_.oB)({height:"0px",visibility:"hidden"})),(0,_.SB)("current",(0,_.oB)({height:"*",visibility:"inherit"})),(0,_.eR)("* <=> current",(0,_.jt)("{{animationDuration}} cubic-bezier(0.4, 0.0, 0.2, 1)"),{params:{animationDuration:"225ms"}})])};let se=(()=>{class i{constructor(t){this.templateRef=t}}return i.\u0275fac=function(t){return new(t||i)(e.Y36(e.Rgc))},i.\u0275dir=e.lG2({type:i,selectors:[["ng-template","matStepperIcon",""]],inputs:{name:["matStepperIcon","name"]}}),i})(),It=(()=>{class i{constructor(t){this._template=t}}return i.\u0275fac=function(t){return new(t||i)(e.Y36(e.Rgc))},i.\u0275dir=e.lG2({type:i,selectors:[["ng-template","matStepContent",""]]}),i})(),le=(()=>{class i extends Y{constructor(t,n,a,r){super(t,r),this._errorStateMatcher=n,this._viewContainerRef=a,this._isSelected=st.w0.EMPTY}ngAfterContentInit(){this._isSelected=this._stepper.steps.changes.pipe((0,V.w)(()=>this._stepper.selectionChange.pipe((0,lt.U)(t=>t.selectedStep===this),(0,q.O)(this._stepper.selected===this)))).subscribe(t=>{t&&this._lazyContent&&!this._portal&&(this._portal=new B.UE(this._lazyContent._template,this._viewContainerRef))})}ngOnDestroy(){this._isSelected.unsubscribe()}isErrorState(t,n){return this._errorStateMatcher.isErrorState(t,n)||!!(t&&t.invalid&&this.interacted)}}return i.\u0275fac=function(t){return new(t||i)(e.Y36((0,e.Gpc)(()=>pe)),e.Y36(y.rD,4),e.Y36(e.s_b),e.Y36(G,8))},i.\u0275cmp=e.Xpm({type:i,selectors:[["mat-step"]],contentQueries:function(t,n,a){if(1&t&&(e.Suo(a,U,5),e.Suo(a,It,5)),2&t){let r;e.iGM(r=e.CRH())&&(n.stepLabel=r.first),e.iGM(r=e.CRH())&&(n._lazyContent=r.first)}},inputs:{color:"color"},exportAs:["matStep"],features:[e._Bn([{provide:y.rD,useExisting:i},{provide:Y,useExisting:i}]),e.qOj],ngContentSelectors:Ct,decls:1,vars:0,consts:[[3,"cdkPortalOutlet"]],template:function(t,n){1&t&&(e.F$t(),e.YNc(0,St,2,1,"ng-template"))},dependencies:[B.Pl],encapsulation:2,changeDetection:0}),i})(),pe=(()=>{class i extends H{constructor(t,n,a){super(t,n,a),this.steps=new e.n_E,this.animationDone=new e.vpe,this.labelPosition="end",this.headerPosition="top",this._iconOverrides={},this._animationDone=new z.x,this._animationDuration="";const r=a.nativeElement.nodeName.toLowerCase();this.orientation="mat-vertical-stepper"===r?"vertical":"horizontal"}get animationDuration(){return this._animationDuration}set animationDuration(t){this._animationDuration=/^\d+$/.test(t)?t+"ms":t}ngAfterContentInit(){super.ngAfterContentInit(),this._icons.forEach(({name:t,templateRef:n})=>this._iconOverrides[t]=n),this.steps.changes.pipe((0,N.R)(this._destroyed)).subscribe(()=>{this._stateChanged()}),this._animationDone.pipe((0,pt.x)((t,n)=>t.fromState===n.fromState&&t.toState===n.toState),(0,N.R)(this._destroyed)).subscribe(t=>{"current"===t.toState&&this.animationDone.emit()})}_stepIsNavigable(t,n){return n.completed||this.selectedIndex===t||!this.linear}_getAnimationDuration(){return this.animationDuration?this.animationDuration:"horizontal"===this.orientation?"500ms":"225ms"}}return i.\u0275fac=function(t){return new(t||i)(e.Y36(F.Is,8),e.Y36(e.sBO),e.Y36(e.SBq))},i.\u0275cmp=e.Xpm({type:i,selectors:[["mat-stepper"],["mat-vertical-stepper"],["mat-horizontal-stepper"],["","matStepper",""]],contentQueries:function(t,n,a){if(1&t&&(e.Suo(a,le,5),e.Suo(a,se,5)),2&t){let r;e.iGM(r=e.CRH())&&(n._steps=r),e.iGM(r=e.CRH())&&(n._icons=r)}},viewQuery:function(t,n){if(1&t&&e.Gf(ie,5),2&t){let a;e.iGM(a=e.CRH())&&(n._stepHeader=a)}},hostAttrs:["role","tablist"],hostVars:11,hostBindings:function(t,n){2&t&&(e.uIk("aria-orientation",n.orientation),e.ekj("mat-stepper-horizontal","horizontal"===n.orientation)("mat-stepper-vertical","vertical"===n.orientation)("mat-stepper-label-position-end","horizontal"===n.orientation&&"end"==n.labelPosition)("mat-stepper-label-position-bottom","horizontal"===n.orientation&&"bottom"==n.labelPosition)("mat-stepper-header-position-bottom","bottom"===n.headerPosition))},inputs:{selectedIndex:"selectedIndex",disableRipple:"disableRipple",color:"color",labelPosition:"labelPosition",headerPosition:"headerPosition",animationDuration:"animationDuration"},outputs:{animationDone:"animationDone"},exportAs:["matStepper","matVerticalStepper","matHorizontalStepper"],features:[e._Bn([{provide:H,useExisting:i}]),e.qOj],decls:5,vars:3,consts:[[3,"ngSwitch"],["class","mat-horizontal-stepper-wrapper",4,"ngSwitchCase"],[4,"ngSwitchCase"],["stepTemplate",""],[1,"mat-horizontal-stepper-wrapper"],[1,"mat-horizontal-stepper-header-container"],[4,"ngFor","ngForOf"],[1,"mat-horizontal-content-container"],["class","mat-horizontal-stepper-content","role","tabpanel",3,"id",4,"ngFor","ngForOf"],[3,"ngTemplateOutlet","ngTemplateOutletContext"],["class","mat-stepper-horizontal-line",4,"ngIf"],[1,"mat-stepper-horizontal-line"],["role","tabpanel",1,"mat-horizontal-stepper-content",3,"id"],[3,"ngTemplateOutlet"],["class","mat-step",4,"ngFor","ngForOf"],[1,"mat-step"],[1,"mat-vertical-content-container"],["role","tabpanel",1,"mat-vertical-stepper-content",3,"id"],[1,"mat-vertical-content"],[3,"tabIndex","id","index","state","label","selected","active","optional","errorMessage","iconOverrides","disableRipple","color","click","keydown"]],template:function(t,n){1&t&&(e.ynx(0,0),e.YNc(1,Dt,5,2,"div",1),e.YNc(2,Mt,2,1,"ng-container",2),e.BQk(),e.YNc(3,wt,1,23,"ng-template",null,3,e.W1O)),2&t&&(e.Q6J("ngSwitch",n.orientation),e.xp6(1),e.Q6J("ngSwitchCase","horizontal"),e.xp6(1),e.Q6J("ngSwitchCase","vertical"))},dependencies:[u.sg,u.O5,u.tP,u.RF,u.n9,ie],styles:['.mat-stepper-vertical,.mat-stepper-horizontal{display:block}.mat-horizontal-stepper-header-container{white-space:nowrap;display:flex;align-items:center}.mat-stepper-label-position-bottom .mat-horizontal-stepper-header-container{align-items:flex-start}.mat-stepper-header-position-bottom .mat-horizontal-stepper-header-container{order:1}.mat-stepper-horizontal-line{border-top-width:1px;border-top-style:solid;flex:auto;height:0;margin:0 -16px;min-width:32px}.mat-stepper-label-position-bottom .mat-stepper-horizontal-line{margin:0;min-width:0;position:relative}.mat-stepper-label-position-bottom .mat-horizontal-stepper-header:not(:first-child)::before,[dir=rtl] .mat-stepper-label-position-bottom .mat-horizontal-stepper-header:not(:last-child)::before,.mat-stepper-label-position-bottom .mat-horizontal-stepper-header:not(:last-child)::after,[dir=rtl] .mat-stepper-label-position-bottom .mat-horizontal-stepper-header:not(:first-child)::after{border-top-width:1px;border-top-style:solid;content:"";display:inline-block;height:0;position:absolute;width:calc(50% - 20px)}.mat-horizontal-stepper-header{display:flex;height:72px;overflow:hidden;align-items:center;padding:0 24px}.mat-horizontal-stepper-header .mat-step-icon{margin-right:8px;flex:none}[dir=rtl] .mat-horizontal-stepper-header .mat-step-icon{margin-right:0;margin-left:8px}.mat-stepper-label-position-bottom .mat-horizontal-stepper-header{box-sizing:border-box;flex-direction:column;height:auto}.mat-stepper-label-position-bottom .mat-horizontal-stepper-header:not(:last-child)::after,[dir=rtl] .mat-stepper-label-position-bottom .mat-horizontal-stepper-header:not(:first-child)::after{right:0}.mat-stepper-label-position-bottom .mat-horizontal-stepper-header:not(:first-child)::before,[dir=rtl] .mat-stepper-label-position-bottom .mat-horizontal-stepper-header:not(:last-child)::before{left:0}[dir=rtl] .mat-stepper-label-position-bottom .mat-horizontal-stepper-header:last-child::before,[dir=rtl] .mat-stepper-label-position-bottom .mat-horizontal-stepper-header:first-child::after{display:none}.mat-stepper-label-position-bottom .mat-horizontal-stepper-header .mat-step-icon{margin-right:0;margin-left:0}.mat-stepper-label-position-bottom .mat-horizontal-stepper-header .mat-step-label{padding:16px 0 0 0;text-align:center;width:100%}.mat-vertical-stepper-header{display:flex;align-items:center;height:24px}.mat-vertical-stepper-header .mat-step-icon{margin-right:12px}[dir=rtl] .mat-vertical-stepper-header .mat-step-icon{margin-right:0;margin-left:12px}.mat-horizontal-stepper-wrapper{display:flex;flex-direction:column}.mat-horizontal-stepper-content{outline:0}.mat-horizontal-stepper-content[aria-expanded=false]{height:0;overflow:hidden}.mat-horizontal-content-container{overflow:hidden;padding:0 24px 24px 24px}.cdk-high-contrast-active .mat-horizontal-content-container{outline:solid 1px}.mat-stepper-header-position-bottom .mat-horizontal-content-container{padding:24px 24px 0 24px}.mat-vertical-content-container{margin-left:36px;border:0;position:relative}.cdk-high-contrast-active .mat-vertical-content-container{outline:solid 1px}[dir=rtl] .mat-vertical-content-container{margin-left:0;margin-right:36px}.mat-stepper-vertical-line::before{content:"";position:absolute;left:0;border-left-width:1px;border-left-style:solid}[dir=rtl] .mat-stepper-vertical-line::before{left:auto;right:0}.mat-vertical-stepper-content{overflow:hidden;outline:0}.mat-vertical-content{padding:0 24px 24px 24px}.mat-step:last-child .mat-vertical-content-container{border:none}'],encapsulation:2,data:{animation:[re.horizontalStepTransition,re.verticalStepTransition]},changeDetection:0}),i})(),kt=(()=>{class i{}return i.\u0275fac=function(t){return new(t||i)},i.\u0275mod=e.oAB({type:i}),i.\u0275inj=e.cJS({providers:[Nt,y.rD],imports:[y.BQ,u.ez,B.eL,rt.ot,at,X.Ps,y.si,y.BQ]}),i})();var de=c(266);function qt(i,o){if(1&i){const t=e.EpF();e.TgZ(0,"button",27),e.NdJ("click",function(){e.CHM(t),e.oxw();const a=e.MAs(11);return e.KtG(a.previous())}),e._uU(1," Back "),e.qZA()}}function Ut(i,o){if(1&i){const t=e.EpF();e.TgZ(0,"button",28),e.NdJ("click",function(){e.CHM(t);const a=e.oxw(),r=e.MAs(11);return e.KtG(a.onNext(r))}),e._uU(1," Next "),e.qZA()}if(2&i){const t=e.oxw();e.Q6J("disabled",t.checkDisabledNextFilter())}}function Jt(i,o){if(1&i){const t=e.EpF();e.TgZ(0,"button",27),e.NdJ("click",function(){e.CHM(t);const a=e.oxw(),r=e.MAs(11);return e.KtG(a.onNew(r))}),e._UZ(1,"i",29),e._uU(2," New "),e.qZA()}}function Lt(i,o){1&i&&e._uU(0,"Filter")}function Et(i,o){if(1&i&&(e.TgZ(0,"ng-option",30),e._UZ(1,"img",31),e._uU(2),e.qZA()),2&i){const t=o.$implicit;e.Q6J("value",t.ID),e.xp6(1),e.s9C("src",t.Img,e.LSH),e.xp6(1),e.hij("",t.Name," ")}}function Rt(i,o){1&i&&e._uU(0,"Preview")}function Ft(i,o){if(1&i&&(e.TgZ(0,"th",49),e._uU(1),e.qZA()),2&i){const t=e.oxw(2);e.xp6(1),e.Oqu(0==t.getTypeID()?"Last Status Update":"Created Date")}}function Qt(i,o){if(1&i&&(e.TgZ(0,"td"),e._uU(1),e.ALo(2,"date"),e.qZA()),2&i){const t=e.oxw().$implicit;e.xp6(1),e.hij(" ",e.xi3(2,1,t.Date,"dd MMM yyyy HH:mm:ss"),"")}}function zt(i,o){if(1&i&&(e.TgZ(0,"span"),e._uU(1),e.qZA()),2&i){const t=e.oxw().$implicit;e.xp6(1),e.hij(" ",t.ActionString," ")}}function Gt(i,o){if(1&i&&(e.TgZ(0,"li"),e._uU(1),e.qZA()),2&i){const t=o.$implicit;e.xp6(1),e.hij("",t," ")}}function Yt(i,o){if(1&i&&(e.TgZ(0,"ul",55),e.YNc(1,Gt,2,1,"li",50),e.qZA()),2&i){const t=e.oxw().$implicit;e.xp6(1),e.Q6J("ngForOf",t.ActionString)}}function Ht(i,o){if(1&i&&(e.TgZ(0,"span",56),e._UZ(1,"i",57),e.qZA()),2&i){const t=e.oxw().$implicit;e.hYB("title","Delivery : ",t.DeliveryState," \nPayment : ",t.PaymentState,"")}}const Bt=function(i,o){return{"over-due-today":i,"over-due":o}};function $t(i,o){if(1&i&&(e.TgZ(0,"tr")(1,"td"),e._uU(2),e.qZA(),e.TgZ(3,"td"),e._uU(4),e.qZA(),e.YNc(5,Qt,3,4,"td",51),e.TgZ(6,"td")(7,"span"),e._uU(8),e.qZA(),e._uU(9),e.qZA(),e.TgZ(10,"td",52)(11,"span"),e._uU(12),e.qZA(),e._uU(13),e.qZA(),e.TgZ(14,"td"),e.YNc(15,zt,2,1,"span",51),e.YNc(16,Yt,2,1,"ul",53),e.qZA(),e.TgZ(17,"td"),e.YNc(18,Ht,2,2,"span",54),e.qZA()()),2&i){const t=o.$implicit,n=o.index,a=e.oxw(3);e.xp6(2),e.Oqu(n+1),e.xp6(2),e.Oqu(t.Number),e.xp6(1),e.Q6J("ngIf",a.getTypeID()!=a.channelType.ShopeeV2),e.xp6(3),e.hij("",t.ChannelStatus," - "),e.xp6(1),e.Oqu(t.ChannelStatusDescription),e.xp6(1),e.Q6J("ngClass",e.WLB(11,Bt,(null==t?null:t.Action)==a.actionPreviewOrder.Update,(null==t?null:t.Action)==a.actionPreviewOrder.New)),e.xp6(2),e.hij("",t.POSStatus," - "),e.xp6(1),e.hij("",t.POSStatusDescription," "),e.xp6(2),e.Q6J("ngIf",1==t.ActionString.length),e.xp6(1),e.Q6J("ngIf",t.ActionString.length>1),e.xp6(2),e.Q6J("ngIf",99!=t.ChannelStatus&&99!=t.POSStatus)}}function Vt(i,o){if(1&i&&(e.ynx(0),e.YNc(1,$t,19,14,"tr",50),e.BQk()),2&i){const t=e.oxw(2);e.xp6(1),e.Q6J("ngForOf",t.displayedPreviewData)}}function jt(i,o){1&i&&(e.TgZ(0,"tr",58)(1,"td",59)(2,"div",60),e._UZ(3,"i",61),e.qZA(),e.TgZ(4,"h4",62),e._uU(5,"There is no order to processed"),e.qZA()()())}function Wt(i,o){if(1&i){const t=e.EpF();e.TgZ(0,"div",32)(1,"div",33)(2,"div",34)(3,"ul",35)(4,"li",36)(5,"button",37),e.NdJ("click",function(){e.CHM(t);const a=e.oxw();return e.KtG(a.filterPreviewData(a.previewStatus.ALL))}),e._uU(6),e.qZA()(),e.TgZ(7,"li",36)(8,"button",38),e.NdJ("click",function(){e.CHM(t);const a=e.oxw();return e.KtG(a.filterPreviewData(a.previewStatus.SYNC))}),e._uU(9),e.qZA()(),e.TgZ(10,"li",36)(11,"button",39),e.NdJ("click",function(){e.CHM(t);const a=e.oxw();return e.KtG(a.filterPreviewData(a.previewStatus.WRONG))}),e._uU(12),e.qZA()(),e.TgZ(13,"li",36)(14,"button",40),e.NdJ("click",function(){e.CHM(t);const a=e.oxw();return e.KtG(a.filterPreviewData(a.previewStatus.UNSYNC))}),e._uU(15),e.qZA()()()(),e.TgZ(16,"table",41)(17,"thead",42)(18,"tr"),e._UZ(19,"th",43),e.TgZ(20,"th",44),e._uU(21,"Number"),e.qZA(),e.YNc(22,Ft,2,1,"th",45),e.TgZ(23,"th",46),e._uU(24,"Channel Status"),e.qZA(),e.TgZ(25,"th",46),e._uU(26,"POS Status"),e.qZA(),e.TgZ(27,"th"),e._uU(28,"Action"),e.qZA(),e._UZ(29,"th",43),e.qZA()(),e.TgZ(30,"tbody"),e.YNc(31,Vt,2,1,"ng-container",47),e.YNc(32,jt,6,0,"ng-template",null,48,e.W1O),e.qZA()()()()}if(2&i){const t=e.MAs(33),n=e.oxw();e.xp6(5),e.Q6J("ngClass","all"==n.pillStatus?"btn-secondary text-white":"btn-outline-dark"),e.xp6(1),e.hij("All (",n.allData,")"),e.xp6(2),e.Q6J("ngClass","sync"==n.pillStatus?"btn-success":"btn-outline-success"),e.xp6(1),e.hij("Existing (",n.syncData,")"),e.xp6(2),e.Q6J("ngClass","wrong"==n.pillStatus?"btn-warning text-white":"btn-outline-warning"),e.xp6(1),e.hij("Wrong Status (",n.wrongData,")"),e.xp6(2),e.Q6J("ngClass","unsync"==n.pillStatus?"btn-danger":"btn-outline-danger"),e.xp6(1),e.hij("Missing (",n.unsyncData,")"),e.xp6(7),e.Q6J("ngIf",n.getTypeID()!=n.channelType.ShopeeV2),e.xp6(9),e.Q6J("ngIf",n.displayedPreviewData.length>0)("ngIfElse",t)}}function Kt(i,o){1&i&&e._uU(0,"Finish")}const Xt=function(i){return{"over-due":i}};function en(i,o){if(1&i&&(e.TgZ(0,"tr",52)(1,"td"),e._uU(2),e.qZA(),e.TgZ(3,"td"),e._uU(4),e.qZA(),e.TgZ(5,"td"),e._uU(6),e.qZA(),e.TgZ(7,"td"),e._uU(8),e.qZA()()),2&i){const t=o.$implicit,n=o.index;e.Q6J("ngClass",e.VKq(5,Xt,t.Exception)),e.xp6(2),e.Oqu(n+1),e.xp6(2),e.Oqu(t.Number),e.xp6(2),e.Oqu(t.Status),e.xp6(2),e.Oqu(t.Exception)}}function tn(i,o){if(1&i&&(e.ynx(0),e.YNc(1,en,9,7,"tr",64),e.BQk()),2&i){const t=e.oxw(2);e.xp6(1),e.Q6J("ngForOf",t.downloadData)}}function nn(i,o){1&i&&(e.TgZ(0,"tr",58)(1,"td",59)(2,"div",60),e._UZ(3,"i",61),e.qZA(),e.TgZ(4,"h4",62),e._uU(5,"There is no order to processed"),e.qZA()()())}function an(i,o){if(1&i&&(e.TgZ(0,"div",32)(1,"div",33)(2,"table",41)(3,"thead",42)(4,"tr"),e._UZ(5,"th",43),e.TgZ(6,"th"),e._uU(7,"Order Number"),e.qZA(),e.TgZ(8,"th"),e._uU(9,"Status"),e.qZA(),e.TgZ(10,"th"),e._uU(11,"Exception"),e.qZA()()(),e.TgZ(12,"tbody"),e.YNc(13,tn,2,1,"ng-container",47),e.YNc(14,nn,6,0,"ng-template",null,63,e.W1O),e.qZA()()()()),2&i){const t=e.MAs(15),n=e.oxw();e.xp6(13),e.Q6J("ngIf",(null==n.downloadData?null:n.downloadData.length)>0)("ngIfElse",t)}}function on(i,o){1&i&&e._UZ(0,"i",65)}function rn(i,o){1&i&&e._UZ(0,"i",66)}function sn(i,o){1&i&&e._UZ(0,"i",67)}var b=(()=>{return(i=b||(b={})).ALL="all",i.SYNC="sync",i.WRONG="wrong",i.UNSYNC="unsync",b;var i})();let ln=(()=>{class i{constructor(t,n,a,r,m){this.http=t,this.toastr=n,this.datePipe=a,this.url=r,this.productService=m,this.pageTitle="Download to POS",this.pillStatus="all",this.displayedPreviewData=[],this.previewData=[],this.channelType=g.x,this.previewStatus=b,this.currentState="filter",this.wrongData=0,this.unsyncData=0,this.syncData=0,this.allData=0,this.actionPreviewOrder=M}ngOnInit(){this.initPageLoader(),this.url.queryParams.subscribe(t=>{this.channelID=t.ChannelID,this.startDate=new Date(t.Date),this.endDate=new Date(t.Date)})}initPageLoader(){this.productService.loader().subscribe(t=>{this.channelOptions=t.Options.Channel})}onDownload(t){this.http.post("/api/Orders/Download",{ID:this.channelID,From:this.startDate,To:this.endDate,ListPreview:this.downloadedPreviewData}).subscribe(a=>{this.downloadData=a.Body,this.onStepperNext(t)})}onPreview(t){this.validateDatePreview()&&this.http.post("/api/Orders/Preview",{ID:this.channelID,From:this.startDate,To:this.endDate}).subscribe(a=>{0!=a.length?(this.previewData=a,this.groupingPreviewData(),this.filterPreviewData(b.ALL),this.initLengthStatusData(),this.onStepperNext(t)):this.toastrEmptyPreview()})}toastrEmptyPreview(){this.toastr.info("There is no orders from "+this.datePipe.transform(this.startDate,"dd MMM yyyy")+" to "+this.datePipe.transform(this.endDate,"dd MMM yyyy")+" !","No Orders!")}validateDatePreview(){let t=!0;return f.g.getDaysDiff(this.startDate,this.endDate)>14&&(this.toastr.warning("Dates cannot be more than 14 days apart!","Failed"),t=!1),t}setPageTitle(t){const n=f.g.formatTitleForFromDate(new Date(this.startDate),new Date(this.endDate));this.pageTitle=`\n ${t} (${this.datePipe.transform(this.startDate,n)} - ${this.datePipe.transform(this.endDate,"dd MMM yyyy")})\n `}onNew(t){this.channelID=null,this.startDate=null,this.endDate=null,this.pageTitle="Download to POS",t.reset()}groupingPreviewData(){let t=this.filterDataByStatus(b.UNSYNC),n=this.filterDataByStatus(b.WRONG);this.downloadedPreviewData=[...t,...n]}filterDataByStatus(t){let n=[];switch(t){case b.ALL:n=this.previewData;break;case b.SYNC:n=this.previewData.filter(a=>a.Action==M.DoNothing);break;case b.WRONG:n=this.previewData.filter(a=>a.Action==M.Update);break;case b.UNSYNC:n=this.previewData.filter(a=>a.Action==M.New)}return n}filterPreviewData(t){this.pillStatus=t,this.displayedPreviewData=this.filterDataByStatus(t)}initLengthStatusData(){this.wrongData=this.filterDataByStatus(b.WRONG).length,this.allData=this.previewData.length,this.syncData=this.filterDataByStatus(b.SYNC).length,this.unsyncData=this.filterDataByStatus(b.UNSYNC).length}getTypeID(){var t=this.channelOptions.find(n=>n.ID==this.channelID)?.TypeID;return t??0}onStepperChange(t){this.currentState=t.selectedStep.state}onStepperNext(t){t.selected.completed=!0,t.next()}onNext(t){switch(this.currentState){case"filter":this.onPreview(t);break;case"preview":this.onDownload(t)}}stepChange(t){switch(t?.selectedStep?.state){case"filter":this.pageTitle="Download To POS",this.resetPreviewData();break;case"preview":let n=this.productService.findChannelById(this.channelID,this.channelOptions);this.setPageTitle(`Preview ${n?.Name}`);break;case"finish":this.setPageTitle("Download")}}resetPreviewData(){this.displayedPreviewData=[],this.previewData=[],this.initLengthStatusData()}checkDisabledNextFilter(){let t=!f.g.isValidDate(this.startDate)||!f.g.isValidDate(this.endDate),n=f.g.IsEmpty(this.channelID);return t||n}}return i.\u0275fac=function(t){return new(t||i)(e.Y36(S.O),e.Y36(C._W),e.Y36(u.uU),e.Y36(v.gz),e.Y36(ot.M))},i.\u0275cmp=e.Xpm({type:i,selectors:[["app-download"]],features:[e._Bn([{provide:G,useValue:{displayDefaultIndicatorType:!1}}])],decls:47,vars:20,consts:[[3,"headerTitle","description","hideSearchBox","hideSearchDropdown"],["class","btn btn-outline-secondary btn-fill btn-lg ms-2",3,"click",4,"ngIf"],["class","btn btn-outline-secondary btn-fill btn-lg ms-2","type","button",3,"disabled","click",4,"ngIf"],[1,"container-fluid","pt-5","mt-5"],[1,"row"],[1,"col-12"],[1,"d-flex","justify-content-center"],["labelPosition","bottom","linear","",1,"w-100","stepper-download",3,"ngClass","selectionChange"],["stepper",""],["state","filter",3,"editable","completed"],["matStepLabel",""],[1,"row","pt-2",2,"width","63%","margin-right","40px"],[1,"col-6"],[1,"text-muted"],["appendTo","body",3,"clearable","ngModel","ngModelChange"],[3,"value",4,"ngFor","ngForOf"],[1,"row","mt-1rem"],["id","dates",1,"form-control","rounded","dateRange",3,"rangePicker"],["matStartDate","","placeholder","Start date",3,"ngModel","ngModelChange","click"],["matEndDate","","placeholder","End date",3,"ngModel","ngModelChange","click"],["picker",""],["state","preview",3,"editable","completed"],["class","row pt-2",4,"ngIf"],["state","finish"],["matStepperIcon","filter"],["matStepperIcon","preview"],["matStepperIcon","finish"],[1,"btn","btn-outline-secondary","btn-fill","btn-lg","ms-2",3,"click"],["type","button",1,"btn","btn-outline-secondary","btn-fill","btn-lg","ms-2",3,"disabled","click"],["aria-hidden","true",1,"fa","fa-file-alt","me-2"],[3,"value"],[2,"width","18px","margin-right","10px",3,"src"],[1,"row","pt-2"],[1,"col-md-12"],[1,"row","mx-1","mb-5"],[1,"nav","nav-pills"],[1,"nav-item","mx-3"],[1,"btn","btn-sm","rounded-pill",3,"ngClass","click"],["matTooltip","All Invoice which is already available in POS",1,"btn","btn-sm","rounded-pill",3,"ngClass","click"],["matTooltip","Invoices that have different status between marketplace and POS",1,"btn","btn-sm","rounded-pill",3,"ngClass","click"],["matTooltip","Invoices which is not exist in POS",1,"btn","btn-sm","rounded-pill",3,"ngClass","click"],[1,"table"],[1,"thead-light"],["width","1%"],["width","25%"],["width","15%",4,"ngIf"],["width","10%"],[4,"ngIf","ngIfElse"],["EMPTY",""],["width","15%"],[4,"ngFor","ngForOf"],[4,"ngIf"],[3,"ngClass"],["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"],["EMPTY_DOWNLOAD",""],[3,"ngClass",4,"ngFor","ngForOf"],[1,"fa-solid","fa-filter"],[1,"fa-solid","fa-file"],[1,"fa-sharp","fa-solid","fa-flag"]],template:function(t,n){if(1&t){const a=e.EpF();e.TgZ(0,"mainpanel",0)(1,"actions"),e.YNc(2,qt,2,0,"button",1),e.YNc(3,Ut,2,1,"button",2),e.YNc(4,Jt,3,0,"button",1),e.qZA(),e.TgZ(5,"content")(6,"div",3)(7,"div",4)(8,"div",5)(9,"div",6)(10,"mat-stepper",7,8),e.NdJ("selectionChange",function(m){return n.stepChange(m)})("selectionChange",function(m){return n.onStepperChange(m)}),e.TgZ(12,"mat-step",9),e.YNc(13,Lt,1,0,"ng-template",10),e.TgZ(14,"div",11)(15,"div",5)(16,"div",4)(17,"div",12)(18,"h5"),e._uU(19,"Select a Channel"),e.qZA(),e.TgZ(20,"p",13),e._uU(21,"Select Channel want to download order"),e.qZA()(),e.TgZ(22,"div",12)(23,"ng-select",14),e.NdJ("ngModelChange",function(m){return n.channelID=m}),e.YNc(24,Et,3,3,"ng-option",15),e.qZA()()(),e.TgZ(25,"div",16)(26,"div",12)(27,"h5"),e._uU(28,"Date Range"),e.qZA(),e.TgZ(29,"p",13),e._uU(30,"Select transaction date of the channel you want to download (Max 2 Weeks)"),e.qZA()(),e.TgZ(31,"div",12)(32,"div",5)(33,"mat-date-range-input",17)(34,"input",18),e.NdJ("ngModelChange",function(m){return n.startDate=m})("click",function(){e.CHM(a);const m=e.MAs(37);return e.KtG(m.open())}),e.qZA(),e.TgZ(35,"input",19),e.NdJ("ngModelChange",function(m){return n.endDate=m})("click",function(){e.CHM(a);const m=e.MAs(37);return e.KtG(m.open())}),e.qZA()(),e._UZ(36,"mat-date-range-picker",null,20),e.qZA()()()()()(),e.TgZ(38,"mat-step",21),e.YNc(39,Rt,1,0,"ng-template",10),e.YNc(40,Wt,34,11,"div",22),e.qZA(),e.TgZ(41,"mat-step",23),e.YNc(42,Kt,1,0,"ng-template",10),e.YNc(43,an,16,2,"div",22),e.qZA(),e.YNc(44,on,1,0,"ng-template",24),e.YNc(45,rn,1,0,"ng-template",25),e.YNc(46,sn,1,0,"ng-template",26),e.qZA()()()()()()()}if(2&t){const a=e.MAs(11),r=e.MAs(37);e.Q6J("headerTitle",n.pageTitle)("description",n.pageTitle)("hideSearchBox",!0)("hideSearchDropdown",!0),e.xp6(2),e.Q6J("ngIf","preview"==n.currentState),e.xp6(1),e.Q6J("ngIf","finish"!=n.currentState),e.xp6(1),e.Q6J("ngIf","finish"==n.currentState),e.xp6(6),e.s9C("ngClass","last-edited-step-"+a.selectedIndex),e.xp6(2),e.Q6J("editable","finish"!=n.currentState)("completed",!1),e.xp6(11),e.Q6J("clearable",!1)("ngModel",n.channelID),e.xp6(1),e.Q6J("ngForOf",n.channelOptions),e.xp6(9),e.Q6J("rangePicker",r),e.xp6(1),e.Q6J("ngModel",n.startDate),e.xp6(1),e.Q6J("ngModel",n.endDate),e.xp6(3),e.Q6J("editable","finish"!=n.currentState)("completed",!1),e.xp6(2),e.Q6J("ngIf","preview"==n.currentState),e.xp6(3),e.Q6J("ngIf","finish"==n.currentState)}},dependencies:[u.mk,u.sg,u.O5,s.Fj,s.JJ,s.On,l.p,p.w9,p.jq,A.wx,A.zY,A.By,A._g,le,U,pe,se,de.gM,u.uU],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} mat-stepper.stepper-download>div.mat-horizontal-stepper-wrapper>div.mat-horizontal-stepper-header-container{width:60%;left:18%;position:relative} mat-stepper.stepper-download>div.mat-horizontal-stepper-wrapper>div.mat-horizontal-stepper-header-container mat-step-header>div.mat-step-label{padding-top:8px} 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:center} 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}"]}),i})();var Z=c(8063);const pn=[{path:"",component:L,children:[{path:"",redirectTo:"new",pathMatch:"full"},{path:"new",component:ue,canActivate:[Z.a],data:{title:"New Order"}},{path:"detail",component:_e,canActivate:[Z.a],data:{title:"Orders detail"}},{path:"ready_to_ship",component:Ze,canActivate:[Z.a],data:{title:"Ready To Ship"}},{path:"Shipped",component:Ae,canActivate:[Z.a],data:{title:"Shipped"}},{path:"Delivered",component:Re,canActivate:[Z.a],data:{title:"Delivered"}},{path:"All",component:He,canActivate:[Z.a],data:{title:"All Order"}},{path:"Cancelled",component:Ke,canActivate:[Z.a],data:{title:"Cancelled"}},{path:"Download",component:ln,canActivate:[Z.a],data:{title:"Download"}}]}];let dn=(()=>{class i{}return i.\u0275fac=function(t){return new(t||i)},i.\u0275mod=e.oAB({type:i}),i.\u0275inj=e.cJS({imports:[u.ez,v.Bz.forChild(pn)]}),i})();var cn=c(8739);let un=(()=>{class i{}return i.\u0275fac=function(t){return new(t||i)},i.\u0275mod=e.oAB({type:i}),i.\u0275inj=e.cJS({imports:[u.ez]}),i})(),hn=(()=>{class i{}return i.\u0275fac=function(t){return new(t||i)},i.\u0275mod=e.oAB({type:i}),i.\u0275inj=e.cJS({providers:[k],imports:[u.ez,s.u5,dn,w.Z,l.R,cn.TU,v.Bz,p.A0,A.FA,y.XK,d.K,kt,de.AV,un,$.p9,O.Is]}),i})()},6082:(ce,I,c)=>{c.d(I,{M:()=>S});var u=c(8505),v=c(9694),e=c(3154),w=c(4650),L=c(1318),f=c(7185);let S=(()=>{class C{constructor(s,l){this.httpService=s,this.toastrService=l}loader(s=e.g.GuidEMpty){return this.httpService.post("/api/product/Load",{ID:s})}filterChannelByTypeId(s,l){return s.filter(p=>-1!==l.findIndex(d=>p.TypeID==d))}getProductStatistic(){return this.httpService.post("/api/product/ProductStatistic",{})}getTotalProductLive(s){return this.httpService.post("/api/product/TotalProductLive",{ID:s})}clearCacheChannel(s){return this.httpService.post("/api/Channel/ClearCacheChannel",{ID:s})}uploadToMultipleChannel(s,l){return this.httpService.post("api/product/UploadMultipleChannel",{Channel:l,Products:s})}uploadMultipleProduct(s,l,p){return this.httpService.post("/api/product/UploadToMarketplace",{ChannelID:l,Products:s,CategoryID:p||0})}scanSingle(s,l){return this.httpService.post("/api/product/ScanSingle",{ID:s,SKU:l})}scanNotInChannel(s){return this.httpService.post("/api/product/ScanNotinChannel",{ID:s})}findAllSoldInChannel(s){return this.httpService.post("/api/product/GetSoldInChannel",s)}scanAll(s,l,p,d=!1){return this.httpService.post("/api/product/ScanOptimized",{ID:s,ScanFull:l,UpdatedProduct:p,Async:d})}scanCompareToPos(s){return this.httpService.post("/api/product/CompareMarketplaceToPOS",s)}getVariantCodesProduct(s){return s.Variants.map(p=>p.Code)}downloadMultipleProduct(s){let l=s.map(p=>({ChannelItemID:p.ChannelItemID,ChannelID:p.ChannelID}));return this.httpService.post("/api/product/DownloadMultipleProductFromChannel",l).pipe((0,u.b)(p=>{this.toastrService.success(`${p.Count} products downloaded to POS`,"Download Complete")}))}downloadProduct(s){return this.httpService.post("/api/product/DownloadProductFromChannel",{ChannelItemID:s.ChannelItemID,ChannelID:s.ChannelID}).pipe((0,u.b)(()=>{this.toastrService.success("Product successfully downloaded to POS","Download Complete")}))}getVariantCodesProducts(s=[]){let l=[];return s.forEach(p=>{p.Variants.forEach(d=>{l=[...l,d.Code]})}),l}filterUnselectedChannel(s,l){let p;return p=s.Channel&&0!=s.Channel.length?l.filter(d=>-1===s.Channel.findIndex(h=>h.ChannelID==d.ID)):l,p}findChannelById(s,l){return l.find(p=>p.ID==s)}sortChannel(s=[]){return s.sort((l,p)=>l.TypeID<p.TypeID?1:l.TypeID===p.TypeID?0:-1)}hasSelection(s=[]){return this.selectedProduct(s).length>0}selectedProduct(s=[]){return s.filter(l=>l.selected)}hasSelectionVariant(s){return this.selectedVariantProduct(s).length>0}selectedVariantProduct(s){let l=[];return s.forEach(p=>{l=[...l,...null!=p.Variants?p.Variants.filter(d=>d.selected):""]}),l}getChannelProduct(s){const l=s.Variants;let p=[];for(let d of l)if(null!=d.Channel)for(let h of d.Channel)0==p.filter(T=>T.ChannelID==h.ChannelID).length&&p.push(h);return this.sortChannel(p)}successToastrScanAllProduct(s,l,p){if(p){const d=s?.NotInPOS?.Product?s?.NotInPOS?.Product:0,h=s?.InChannel?.Product?s?.InChannel?.Product:0;this.toastrService.success(`\n ${d+h} found in ${l.Name} </br>\n (${h} In POS + ${d} Not In Pos)\n `,"Scan Complete!",{enableHtml:!0})}else this.toastrService.success(`${s.InChannel?s.InChannel.Product:0} product updates in ${l.Name} </br> \n since ${s.LastUpdate}`,"Scan Complete!",{enableHtml:!0})}checkProductHasScanButton(s,l){let p,d;return s.map(h=>(h.Channel=this.getChannelProduct(h),p=this.filterUnselectedChannel(h,l),d=this.filterChannelByTypeId(p,[v.x.Tiktok,v.x.Tokopedia]),h.hasScan=d.length>0,h))}checkProductHasUploadBtn(s,l){let p;return s.map(d=>(d.Channel=this.getChannelProduct(d),p=this.filterUnselectedChannel(d,l),d.hasUpload=p.length>0,d))}showToastrSuccessUploadMultiple(s,l){let p=s.filter(T=>0==T.Status),d=s.filter(T=>1==T.Status),h=this.generateToastrMessage(p,d,l);this.toastrService.success(h.message,"Success",{enableHtml:!0})}showToastErrorUploadMultiple(s,l){let p=s?.error?.Message.filter(T=>0==T.Status),d=s?.error?.Message.filter(T=>1==T.Status),h=this.generateToastrMessage(p,d,l);"WARNING"==h.status?this.toastrService.warning(h.message,"Warning!",{enableHtml:!0}):this.toastrService.error(h.message,`Error - ${s.status}`,{enableHtml:!0})}generateToastrMessage(s,l,p){let h,d="";return 0==s.length&&l.length>0?(h="SUCCESS",d=this.createSuccessResponse(l,p)):s.length>0&&0==l.length?(h="ERROR",d=this.createErrResponse(s,p)):(h="WARNING",d=`${this.createSuccessResponse(l,p)} ${this.createErrResponse(s,p)}`),d=`<ol>${d}</ol>`,{status:h,message:d}}createErrResponse(s,l){let p="";return s.forEach((d,h)=>{p+=`<li><b>${d.Response}</b> for ${l.Name} in ${d.Name}</li>`}),p}createSuccessResponse(s,l){let p="";return s.forEach((d,h)=>{p+=`<li>Product ${l.Name} was <b>successfully</b> uploaded to ${d.Name}</li>`}),p}getHostName(){if(e.g.IsEmpty(this.hostName)){const s=localStorage.getItem("Authorization");this.hostName=JSON.parse(s)?.Host}return this.hostName}}return C.\u0275fac=function(s){return new(s||C)(w.LFG(L.O),w.LFG(f._W))},C.\u0275prov=w.Yz7({token:C,factory:C.\u0275fac,providedIn:"root"}),C})()}}]);
|
package/Marketplace/index.html
CHANGED
|
@@ -14,9 +14,9 @@
|
|
|
14
14
|
<script>
|
|
15
15
|
(function () { var w = window; var ic = w.Intercom; if (typeof ic === "function") { ic('reattach_activator'); ic('update', w.intercomSettings); } else { var d = document; var i = function () { i.c(arguments); }; i.q = []; i.c = function (args) { i.q.push(args); }; w.Intercom = i; var l = function () { var s = d.createElement('script'); s.type = 'text/javascript'; s.async = true; s.src = 'https://widget.intercom.io/widget/xv1oomgl'; var x = d.getElementsByTagName('script')[0]; x.parentNode.insertBefore(s, x); }; if (w.attachEvent) { w.attachEvent('onload', l); } else { w.addEventListener('load', l, false); } } })();
|
|
16
16
|
</script>
|
|
17
|
-
<style>@charset "UTF-8";:root{--bs-blue:#337ab7;--bs-indigo:#6610f2;--bs-purple:#6f42c1;--bs-pink:#d63384;--bs-red:#c9302c;--bs-orange:#f6a828;--bs-yellow:#ffc107;--bs-green:#89b03e;--bs-teal:#20c997;--bs-cyan:#0dcaf0;--bs-black:#000;--bs-white:#ffffff;--bs-gray:#cccccc;--bs-gray-dark:#343a40;--bs-gray-100:#dddddd;--bs-gray-200:#e9ecef;--bs-gray-300:#dee2e6;--bs-gray-400:#ced4da;--bs-gray-500:#adb5bd;--bs-gray-600:#cccccc;--bs-gray-700:#495057;--bs-gray-800:#343a40;--bs-gray-900:#4d4d4d;--bs-primary:#337ab7;--bs-success:#89b03e;--bs-secondary:#cccccc;--bs-dark:#4d4d4d;--bs-light:#dddddd;--bs-light-gray:rgba(203, 203, 210, .15);--bs-light-blue:#dfeffc;--bs-danger:#c9302c;--bs-warning:#f6a828;--bs-primary-rgb:51, 122, 183;--bs-success-rgb:137, 176, 62;--bs-secondary-rgb:204, 204, 204;--bs-dark-rgb:77, 77, 77;--bs-light-rgb:221, 221, 221;--bs-light-gray-rgb:203, 203, 210;--bs-light-blue-rgb:223, 239, 252;--bs-danger-rgb:201, 48, 44;--bs-warning-rgb:246, 168, 40;--bs-white-rgb:255, 255, 255;--bs-black-rgb:0, 0, 0;--bs-body-color-rgb:51, 51, 51;--bs-body-bg-rgb:255, 255, 255;--bs-font-sans-serif:system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", "Noto Sans", "Liberation Sans", Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji";--bs-font-monospace:SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;--bs-gradient:linear-gradient(180deg, rgba(255, 255, 255, .15), rgba(255, 255, 255, 0));--bs-body-font-family:Roboto, sans-serif;--bs-body-font-size:.75rem;--bs-body-font-weight:400;--bs-body-line-height:1.5;--bs-body-color:#333333;--bs-body-bg:#ffffff;--bs-border-width:1px;--bs-border-style:solid;--bs-border-color:#dee2e6;--bs-border-color-translucent:rgba(0, 0, 0, .175);--bs-border-radius:.375rem;--bs-border-radius-sm:.25rem;--bs-border-radius-lg:.5rem;--bs-border-radius-xl:1rem;--bs-border-radius-2xl:2rem;--bs-border-radius-pill:50rem;--bs-link-color:#0976b4;--bs-link-hover-color:#075e90;--bs-code-color:#d63384;--bs-highlight-bg:#fff3cd}*,*:before,*:after{box-sizing:border-box}@media (prefers-reduced-motion: no-preference){:root{scroll-behavior:smooth}}body{margin:0;font-family:var(--bs-body-font-family);font-size:var(--bs-body-font-size);font-weight:var(--bs-body-font-weight);line-height:var(--bs-body-line-height);color:var(--bs-body-color);text-align:var(--bs-body-text-align);background-color:var(--bs-body-bg);-webkit-text-size-adjust:100%;-webkit-tap-highlight-color:rgba(0,0,0,0)}@media (max-width: 991px){body{position:relative}}html,body{height:100%}@media print{html,body{height:auto}body{color:#000!important}}</style><link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/marketplacepos@2.6.
|
|
17
|
+
<style>@charset "UTF-8";:root{--bs-blue:#337ab7;--bs-indigo:#6610f2;--bs-purple:#6f42c1;--bs-pink:#d63384;--bs-red:#c9302c;--bs-orange:#f6a828;--bs-yellow:#ffc107;--bs-green:#89b03e;--bs-teal:#20c997;--bs-cyan:#0dcaf0;--bs-black:#000;--bs-white:#ffffff;--bs-gray:#cccccc;--bs-gray-dark:#343a40;--bs-gray-100:#dddddd;--bs-gray-200:#e9ecef;--bs-gray-300:#dee2e6;--bs-gray-400:#ced4da;--bs-gray-500:#adb5bd;--bs-gray-600:#cccccc;--bs-gray-700:#495057;--bs-gray-800:#343a40;--bs-gray-900:#4d4d4d;--bs-primary:#337ab7;--bs-success:#89b03e;--bs-secondary:#cccccc;--bs-dark:#4d4d4d;--bs-light:#dddddd;--bs-light-gray:rgba(203, 203, 210, .15);--bs-light-blue:#dfeffc;--bs-danger:#c9302c;--bs-warning:#f6a828;--bs-primary-rgb:51, 122, 183;--bs-success-rgb:137, 176, 62;--bs-secondary-rgb:204, 204, 204;--bs-dark-rgb:77, 77, 77;--bs-light-rgb:221, 221, 221;--bs-light-gray-rgb:203, 203, 210;--bs-light-blue-rgb:223, 239, 252;--bs-danger-rgb:201, 48, 44;--bs-warning-rgb:246, 168, 40;--bs-white-rgb:255, 255, 255;--bs-black-rgb:0, 0, 0;--bs-body-color-rgb:51, 51, 51;--bs-body-bg-rgb:255, 255, 255;--bs-font-sans-serif:system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", "Noto Sans", "Liberation Sans", Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji";--bs-font-monospace:SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;--bs-gradient:linear-gradient(180deg, rgba(255, 255, 255, .15), rgba(255, 255, 255, 0));--bs-body-font-family:Roboto, sans-serif;--bs-body-font-size:.75rem;--bs-body-font-weight:400;--bs-body-line-height:1.5;--bs-body-color:#333333;--bs-body-bg:#ffffff;--bs-border-width:1px;--bs-border-style:solid;--bs-border-color:#dee2e6;--bs-border-color-translucent:rgba(0, 0, 0, .175);--bs-border-radius:.375rem;--bs-border-radius-sm:.25rem;--bs-border-radius-lg:.5rem;--bs-border-radius-xl:1rem;--bs-border-radius-2xl:2rem;--bs-border-radius-pill:50rem;--bs-link-color:#0976b4;--bs-link-hover-color:#075e90;--bs-code-color:#d63384;--bs-highlight-bg:#fff3cd}*,*:before,*:after{box-sizing:border-box}@media (prefers-reduced-motion: no-preference){:root{scroll-behavior:smooth}}body{margin:0;font-family:var(--bs-body-font-family);font-size:var(--bs-body-font-size);font-weight:var(--bs-body-font-weight);line-height:var(--bs-body-line-height);color:var(--bs-body-color);text-align:var(--bs-body-text-align);background-color:var(--bs-body-bg);-webkit-text-size-adjust:100%;-webkit-tap-highlight-color:rgba(0,0,0,0)}@media (max-width: 991px){body{position:relative}}html,body{height:100%}@media print{html,body{height:auto}body{color:#000!important}}</style><link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/marketplacepos@2.6.9/Marketplace/styles.dff58ae3c0783953.css" media="print" onload="this.media='all'"><noscript><link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/marketplacepos@2.6.9/Marketplace/styles.dff58ae3c0783953.css"></noscript></head>
|
|
18
18
|
<body>
|
|
19
19
|
<app-root></app-root>
|
|
20
|
-
<script src="https://cdn.jsdelivr.net/npm/marketplacepos@2.6.
|
|
20
|
+
<script src="https://cdn.jsdelivr.net/npm/marketplacepos@2.6.9/Marketplace/runtime.220b1b862137e8cd.js" type="module"></script><script src="https://cdn.jsdelivr.net/npm/marketplacepos@2.6.9/Marketplace/polyfills.8d85b0533e3f867a.js" type="module"></script><script src="https://cdn.jsdelivr.net/npm/marketplacepos@2.6.9/Marketplace/scripts.09af772bfa77d50d.js" defer></script><script src="https://cdn.jsdelivr.net/npm/marketplacepos@2.6.9/Marketplace/main.b3c6f53f4a9e3265.js" type="module"></script>
|
|
21
21
|
|
|
22
22
|
</body></html>
|