dealpos 11.3.6 → 11.3.7

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.
@@ -0,0 +1 @@
1
+ "use strict";(self.webpackChunkPOS=self.webpackChunkPOS||[]).push([[273],{30273:(k,b,p)=>{p.d(b,{p:()=>B,R:()=>Q});var e=p(5e3),a=p(69808),u=p(93075),h=p(93669),C=p(68555),x=p(58393),T=p(35078);function O(o,c){if(1&o){const n=e.EpF();e.ynx(0),e.TgZ(1,"autocompleteV2",22),e.NdJ("optionSelected",function(s){return e.CHM(n),e.oxw().onAutoCompleteChange(s)})("onInputEnter",function(s){return e.CHM(n),e.oxw().onAutoCompleteEnter(s)}),e.qZA(),e.TgZ(2,"div")(3,"button",23),e.NdJ("click",function(){return e.CHM(n),e.oxw().submit()}),e._UZ(4,"i",24),e.qZA()(),e.BQk()}if(2&o){const n=e.oxw();e.xp6(1),e.Q6J("requestUrl",n.requestUrl)("customClass","autocomplete-mainpanel")("placeholder",n.searchBoxPlaceholder||"Search..")("inputTextValue",n.text)}}const f=function(){return{standalone:!0}};function y(o,c){if(1&o){const n=e.EpF();e.ynx(0),e.TgZ(1,"input",25),e.NdJ("ngModelChange",function(s){return e.CHM(n),e.oxw().text=s})("keyup",function(){return e.CHM(n),e.oxw().onTextChange()}),e.qZA(),e.TgZ(2,"div")(3,"button",23),e.NdJ("click",function(){return e.CHM(n),e.oxw().submit()}),e._UZ(4,"i",24),e.qZA()(),e.BQk()}if(2&o){const n=e.oxw();e.xp6(1),e.s9C("placeholder",n.searchBoxPlaceholder),e.Q6J("ngModelOptions",e.DdM(3,f))("ngModel",n.text)}}function w(o,c){if(1&o){const n=e.EpF();e.ynx(0),e.TgZ(1,"input",26),e.NdJ("ngModelChange",function(s){return e.CHM(n),e.oxw().barcodeQuery=s})("keyup.enter",function(){return e.CHM(n),e.oxw().onBarcodeQueryChange()}),e.qZA(),e.TgZ(2,"div")(3,"button",27),e.NdJ("click",function(){return e.CHM(n),e.oxw().onBarcodeQueryChange()}),e._UZ(4,"i",28),e.qZA()(),e.BQk()}if(2&o){const n=e.oxw();e.xp6(1),e.Q6J("ngModelOptions",e.DdM(2,f))("ngModel",n.barcodeQuery)}}const P=function(o){return{width:o}};function S(o,c){if(1&o){const n=e.EpF();e.TgZ(0,"div",29)(1,"a",30)(2,"i",31),e._UZ(3,"i",32),e.qZA()(),e.TgZ(4,"form",33),e.NdJ("click",function(s){return e.CHM(n),e.oxw().toggleDropdown(s)}),e.Hsn(5,2),e.TgZ(6,"button",34),e.NdJ("click",function(){return e.CHM(n),e.oxw().submit()}),e._UZ(7,"i",35),e._uU(8,"Search "),e.qZA()()()}if(2&o){const n=e.oxw();e.xp6(4),e.Akn(e.VKq(2,P,n.filterWidth))}}const v=function(o){return[o]};function E(o,c){if(1&o&&(e.TgZ(0,"li")(1,"a",40),e._uU(2),e.qZA()()),2&o){const n=c.$implicit;e.Tol(n.A?"active nav-item me-6":" nav-item me-6"),e.xp6(1),e.Q6J("routerLink",e.VKq(4,v,"/menu/"+n.U)),e.xp6(1),e.hij(" ",n.T," ")}}function I(o,c){if(1&o&&(e.TgZ(0,"nav",36)(1,"div",37)(2,"div")(3,"ul",38),e.YNc(4,E,3,6,"li",39),e.qZA()()()()),2&o){const n=e.oxw();e.xp6(4),e.Q6J("ngForOf",n.pageData.N.TM)}}function A(o,c){if(1&o&&(e.TgZ(0,"a",56),e._UZ(1,"i",57),e._uU(2),e.qZA()),2&o){const n=e.oxw().$implicit;e.s9C("target",n.Ta),e.Q6J("routerLink",e.VKq(3,v,"/menu/"+(n.U?n.U:"#"))),e.xp6(2),e.hij(" ",n.T," ")}}function Z(o,c){if(1&o){const n=e.EpF();e.TgZ(0,"div",54),e.NdJ("mouseenter",function(){return e.CHM(n),e.oxw(4).hover=!0})("mouseleave",function(){return e.CHM(n),e.oxw(4).hover=!1}),e.YNc(1,A,3,5,"a",55),e.qZA()}if(2&o){const n=c.$implicit;e.xp6(1),e.Q6J("ngIf",n.U)}}function r(o,c){if(1&o&&(e.TgZ(0,"a",61),e._UZ(1,"i",57),e._uU(2),e.qZA()),2&o){const n=c.$implicit;e.Q6J("routerLink",e.VKq(2,v,"/menu/"+(null==n?null:n.U))),e.xp6(2),e.hij(" ",null==n?null:n.T," ")}}function g(o,c){if(1&o&&(e.TgZ(0,"div")(1,"div",59),e._uU(2),e.qZA(),e.TgZ(3,"div"),e.YNc(4,r,3,4,"a",60),e.qZA()()),2&o){const n=e.oxw().$implicit;e.xp6(2),e.Oqu(n.T),e.xp6(2),e.Q6J("ngForOf",n.SI)}}const t=function(o){return{show:o}};function l(o,c){if(1&o){const n=e.EpF();e.TgZ(0,"div",58),e.NdJ("mouseenter",function(){return e.CHM(n),e.oxw(4).hover=!0})("mouseleave",function(){return e.CHM(n),e.oxw(4).hover=!1}),e.YNc(1,g,5,2,"div",9),e.qZA()}if(2&o){const n=c.$implicit,i=e.oxw(4);e.Q6J("ngClass",e.VKq(2,t,i.hover)),e.xp6(1),e.Q6J("ngIf",(null==n?null:n.SI)&&0!=(null==n?null:n.SI.length))}}function _(o,c){if(1&o&&(e.ynx(0),e.TgZ(1,"div",49),e._uU(2),e.qZA(),e._UZ(3,"div",50),e.YNc(4,Z,2,1,"div",51),e.TgZ(5,"div",52),e.YNc(6,l,2,4,"div",53),e.qZA(),e.BQk()),2&o){const n=e.oxw().$implicit;e.xp6(2),e.Oqu(n.T),e.xp6(2),e.Q6J("ngForOf",n.SI),e.xp6(2),e.Q6J("ngForOf",n.SI)}}function d(o,c){if(1&o&&(e.TgZ(0,"div",48),e.YNc(1,_,7,3,"ng-container",9),e.qZA()),2&o){const n=c.$implicit;e.xp6(1),e.Q6J("ngIf",n.SI)}}function M(o,c){if(1&o&&(e.TgZ(0,"div",41)(1,"div",42)(2,"a",43),e._UZ(3,"i",44),e.qZA(),e.TgZ(4,"div",45)(5,"div",46),e.YNc(6,d,2,1,"div",47),e.qZA()()()()),2&o){const n=e.oxw();e.xp6(6),e.Q6J("ngForOf",n.pageData.N.SM)}}const D=[[["actions"]],[["content"]],[["filters"]]],U=function(o){return{offline:o}},J=["actions","content","filters"];let B=(()=>{class o{constructor(n){this.toggleSidebar=n,this.textChange=new e.vpe,this.showBarcodeScanner=!1,this.barcodeQueryChange=new e.vpe,this.filterWidth="auto",this.hideMoreMenu=!1,this.filterAutoComplete=!1,this.onSelect=new e.vpe,this.onEnter=new e.vpe,this.onSubmit=new e.vpe,this.searchBoxPlaceholder=this.searchBoxPlaceholder||"Search..",this.toggleSidebar.toggleState$.subscribe(i=>this.isChange=i)}ngOnInit(){(null!=this.pageData.HelpCenterSuggestion||null!=this.pageData.HelpCenterSuggestion)&&window.zE("webWidget","helpCenter:setSuggestions",{labels:this.pageData.HelpCenterSuggestion})}submit(){this.onSubmit.emit()}onTextChange(){this.textChange.emit(this.text)}onBarcodeQueryChange(){this.barcodeQueryChange.emit(this.barcodeQuery),this.barcodeQuery=""}toggleDropdown(n){n.stopPropagation()}toggleMenu(){this.toggleSidebar.toggleSidebar()}onAutoCompleteChange(n){this.onSelect.emit(n)}onAutoCompleteEnter(n){this.onEnter.emit(n)}}return o.\u0275fac=function(n){return new(n||o)(e.Y36(T.g))},o.\u0275cmp=e.Xpm({type:o,selectors:[["mainpanel-cmp"]],inputs:{text:"text",showBarcodeScanner:"showBarcodeScanner",offline:"offline",filterWidth:"filterWidth",pageData:"pageData",hideSearchBox:"hideSearchBox",hideSearchDropdown:"hideSearchDropdown",searchBoxPlaceholder:"searchBoxPlaceholder",hideMoreMenu:"hideMoreMenu",filterAutoComplete:"filterAutoComplete",requestUrl:"requestUrl"},outputs:{textChange:"textChange",barcodeQueryChange:"barcodeQueryChange",onSelect:"onSelect",onEnter:"onEnter",onSubmit:"onSubmit"},ngContentSelectors:J,decls:32,vars:15,consts:[[1,"navbar","navbar-default","navbar-expand-lg","fixed-top","d-block","d-print-none",3,"ngClass"],[1,"row","px-7",2,"margin-top","9px"],[1,"col-auto","pe-0","order-0"],[1,"navbar-brand","me-5","float-start","my-1",3,"title"],["id","action-filter",1,"col-lg-auto","col-12","d-lg-block","collapse","order-lg-1","ps-0","order-2"],[1,"d-flex","h-100","align-items-center","justify-content-lg-start","justify-content-end"],[3,"ngSubmit"],["form","ngForm"],[1,"input-group"],[4,"ngIf"],["class","dropdown text-secondary ps-5",4,"ngIf"],[1,"col","d-lg-none","d-flex","justify-content-end","align-items-center","order-lg-2","order-1"],["type","button","data-bs-toggle","collapse","data-bs-target","#action-button","aria-expanded","false","aria-controls","collapseExample",1,"btn","btn-lg","btn-outline-secondary","d-lg-none","me-2"],["aria-hidden","true",1,"fa-solid","fa-sort-down"],["type","button","data-bs-toggle","collapse","data-bs-target","#action-filter","aria-expanded","false","aria-controls","collapseExample",1,"btn","btn-lg","btn-outline-secondary","d-sm-none","me-2"],["aria-hidden","true",1,"fa-solid","fa-search"],["type","button","aria-controls","navigation-index","aria-expanded","false","aria-label","Toggle navigation",1,"navbar-toggler","navbar-toggler-right","float-end","toggle-menu","ps-2","pe-0",2,"width","max-content","height","max-content",3,"click"],[1,"navbar-toggler-bar","burger-lines"],["id","action-button",1,"col-lg","col-12","d-lg-flex","justify-content-end","collapse","order-3"],["class","navbar page-nav navbar-default py-0 navbar-expand-lg",4,"ngIf"],[1,"main-panel-content"],["class","navbar more_menu","id","divSideMenu",4,"ngIf"],[1,"input-left",3,"requestUrl","customClass","placeholder","inputTextValue","optionSelected","onInputEnter"],["type","button",1,"btn","btn-outline-secondary","fw-bold","rounded-0","border-start-0",3,"click"],[1,"fa","fa-search"],["type","text",1,"form-control",2,"width","9.375rem","font-size","1rem",3,"ngModelOptions","ngModel","placeholder","ngModelChange","keyup"],["type","text","placeholder","Barcode Counter",1,"form-control",2,"width","9.375rem","font-size","1rem",3,"ngModelOptions","ngModel","ngModelChange","keyup.enter"],["type","button",1,"btn","btn-outline-secondary","fw-bold",3,"click"],[1,"fa","fa-barcode"],[1,"dropdown","text-secondary","ps-5"],["role","button","data-bs-toggle","dropdown","aria-expanded","false",1,"text-muted","h5"],[1,"fa","fa-filter"],[1,"fa-solid","fa-caret-down"],[1,"dropdown-menu",2,"left","auto !important",3,"click"],["title","Click to filter!",1,"btn","btn-outline-secondary",3,"click"],[1,"fa-solid","fa-search","pointer"],[1,"navbar","page-nav","navbar-default","py-0","navbar-expand-lg"],[1,"container-fluid"],[1,"nav","navbar-nav","navbar-left","nav-tab-arrow"],[3,"class",4,"ngFor","ngForOf"],[1,"nav-link","nav-link-arrow","mb-0",3,"routerLink"],["id","divSideMenu",1,"navbar","more_menu"],[1,"dropdown"],["href","#","role","button","data-bs-toggle","dropdown","aria-expanded","false",1,"text-dark"],[1,"fa-solid","fa-bars","fa-lg"],[1,"dropdown-menu","dropdown-menu-end","row"],[1,"d-flex"],["class","dropdown-header text-dark col",4,"ngFor","ngForOf"],[1,"dropdown-header","text-dark","col"],[1,"h5","mb-4"],[1,"dropdown-divider","m-0"],["class","dropdown ",3,"mouseenter","mouseleave",4,"ngFor","ngForOf"],[1,"d-flex","flex-row"],["class","dropdown",3,"ngClass","mouseenter","mouseleave",4,"ngFor","ngForOf"],[1,"dropdown",3,"mouseenter","mouseleave"],["class","dropdown-item ",3,"target","routerLink",4,"ngIf"],[1,"dropdown-item",3,"target","routerLink"],["aria-hidden","true",1,"fa-regular","fa-file"],[1,"dropdown",3,"ngClass","mouseenter","mouseleave"],[1,"my-3"],["class","dropdown-item",3,"routerLink",4,"ngFor","ngForOf"],[1,"dropdown-item",3,"routerLink"]],template:function(n,i){1&n&&(e.F$t(D),e.TgZ(0,"nav",0)(1,"div",1)(2,"div",2)(3,"h1",3),e._uU(4),e.qZA()(),e.TgZ(5,"div",4)(6,"search-box")(7,"div",5)(8,"div")(9,"form",6,7),e.NdJ("ngSubmit",function(){return i.submit()}),e.TgZ(11,"div",8),e.YNc(12,O,5,4,"ng-container",9),e.YNc(13,y,5,4,"ng-container",9),e.YNc(14,w,5,3,"ng-container",9),e.qZA()()(),e.YNc(15,S,9,4,"div",10),e.qZA()()(),e.TgZ(16,"div",11)(17,"button",12),e._UZ(18,"i",13),e.qZA(),e.TgZ(19,"button",14),e._UZ(20,"i",15),e.qZA(),e.TgZ(21,"button",16),e.NdJ("click",function(){return i.toggleMenu()}),e._UZ(22,"span",17)(23,"span",17)(24,"span",17),e.qZA()(),e.TgZ(25,"div",18),e.Hsn(26),e.qZA()()(),e.YNc(27,I,5,1,"nav",19),e.TgZ(28,"div",20),e.YNc(29,M,7,1,"div",21),e.TgZ(30,"div"),e.Hsn(31,1),e.qZA()()),2&n&&(e.Q6J("ngClass",e.VKq(13,U,i.offline)),e.xp6(3),e.hYB("title","",null==i.pageData?null:i.pageData.H," ",null==i.pageData?null:i.pageData.SH,""),e.xp6(1),e.AsE(" ",null==i.pageData?null:i.pageData.H," ",null==i.pageData?null:i.pageData.SH," "),e.xp6(8),e.Q6J("ngIf",i.filterAutoComplete),e.xp6(1),e.Q6J("ngIf",!i.hideSearchBox),e.xp6(1),e.Q6J("ngIf",i.showBarcodeScanner),e.xp6(1),e.Q6J("ngIf",!i.hideSearchDropdown),e.xp6(6),e.ekj("change",i.isChange),e.xp6(6),e.Q6J("ngIf",i.pageData&&(null==i.pageData.N||null==i.pageData.N.TM?null:i.pageData.N.TM.length)),e.xp6(2),e.Q6J("ngIf",i.pageData&&(null==i.pageData.N||null==i.pageData.N.SM?null:i.pageData.N.SM.length)&&!i.hideMoreMenu))},directives:[a.mk,u._Y,u.JL,u.F,a.O5,x.J,u.Fj,u.JJ,u.On,a.sg,C.yS],styles:["@media (max-width: 992px) {\n .action-bar[_ngcontent-%COMP%] {\n width: 100%;\n }\n}\n.navbar-toggler[_ngcontent-%COMP%]:focus {\n box-shadow: none !important;\n}\n.change[_ngcontent-%COMP%] .burger-lines[_ngcontent-%COMP%] {\n transition: 0.4s;\n}\n.change[_ngcontent-%COMP%] .burger-lines[_ngcontent-%COMP%]:nth-child(1) {\n transform: rotate(-45deg) translate(-8px, 4px);\n}\n.change[_ngcontent-%COMP%] .burger-lines[_ngcontent-%COMP%]:nth-child(2) {\n opacity: 0;\n}\n.change[_ngcontent-%COMP%] .burger-lines[_ngcontent-%COMP%]:nth-child(3) {\n transform: rotate(45deg) translate(-5px, 0px);\n}"]}),o})(),Q=(()=>{class o{}return o.\u0275fac=function(n){return new(n||o)},o.\u0275mod=e.oAB({type:o}),o.\u0275inj=e.cJS({imports:[[C.Bz,a.ez,u.u5,h.dr,x.Q]]}),o})()},58393:(k,b,p)=>{p.d(b,{J:()=>A,Q:()=>Z});var e=p(69808),a=p(5e3),u=p(93075),h=p(91079),C=p(67327),x=p(8929),T=p(80013),O=p(75778),f=p(7625),y=p(32442),w=p(65263),P=p(90508);function S(r,g){if(1&r&&(a.TgZ(0,"label",6),a._uU(1),a.qZA()),2&r){const t=a.oxw();a.Q6J("for",t.inputID),a.xp6(1),a.Oqu(t.customLabel)}}function v(r,g){if(1&r&&a._UZ(0,"img",9),2&r){const t=a.oxw().$implicit;a.Q6J("src",t.ImgUrl,a.LSH)}}function E(r,g){if(1&r&&(a.TgZ(0,"mat-option",7),a.YNc(1,v,1,1,"img",8),a.TgZ(2,"span"),a._uU(3),a.qZA()()),2&r){const t=g.$implicit,l=a.oxw();a.Q6J("value",t),a.xp6(1),a.Q6J("ngIf",l.renderThumbnail&&t.ImgUrl),a.xp6(2),a.hij(" ",t.Value," ")}}const I=function(r){return{"form-label-group":r}};let A=(()=>{class r{constructor(t,l){this.httpService=t,this.localData=l,this.clearOnSelect=!1,this.inputLock=!1,this.readonly=!1,this.renderThumbnail=!1,this.optionSelected=new a.vpe,this.onSelect=new a.vpe,this.onInputEnter=new a.vpe,this.onInputChange=new a.vpe,this.inputControl=new u.NI,this.options=[],this.skipXHR=!1,this.onOptionsEmpty=new a.vpe,this.propagateChange=_=>{},this.destroy$=new x.xQ}set inputTextValue(t){C.gT.IsEmpty(t)||(this.skipXHR=!0),this.inputControl.setValue(t)}ngOnInit(){this.subscribeInputChanges()}ngOnChanges(t){}subscribeInputChanges(){this.inputControl.valueChanges.pipe((0,T.b)(500),(0,O.x)(),(0,f.R)(this.destroy$)).subscribe(t=>{this.requestValue=null,this.options=[],t&&t.length>2&&!this.skipXHR&&this.setOptions({prefix:t,count:100}),this.emitInputChange(t),this.skipXHR=!1})}emitInputChange(t){"object"!=typeof t&&(this.onInputChange.emit(t),this.setNgModelBlank(t))}setNgModelBlank(t){null!==t&&0===t.length&&this.clearInput()}setOptions(t){this.localData.isProductFromServer().then(l=>{l?this.httpService.post(this.requestUrl,t).pipe((0,f.R)(this.destroy$)).subscribe(_=>{this.options=_,this.requestValue=t.prefix,0==_.length&&this.onOptionsEmpty.emit(t.prefix)}):this.setOptionsWithStorage(t.prefix)})}setOptionsWithStorage(t){"products"==this.localStorage&&this.localData.getVariants().then(l=>{const _=[];for(let d of l){let M={Key:d.ID,Value:d.Name+(d.Code?" - "+d.Code:"")};JSON.stringify(M).toUpperCase().indexOf(t.toUpperCase())>-1&&_.push(M)}this.options=_})}onOptionSelected(t){let l=t.option.value;this.checkClearOnSelect(),this.emitOnOptionSelect(l)}emitOnOptionSelect(t={}){this.propagateChange(t.Key),this.onSelect.emit(t.Key),this.optionSelected.emit(JSON.stringify({Key:t.Key,Value:t.Value}))}onKeyDown(t){let l=t.key;"Enter"===l?(this.skipXHR=!0,this.requestValue||(this.onInputEnter.emit(t.target.value),this.requestValue=null),this.checkClearOnSelect()):this.inputLock&&("Backspace"===l?this.clearInput():this.validateInputLock())}checkClearOnSelect(){this.clearOnSelect&&this.clearInput()}validateInputLock(){let t=this.inputControl.value;null!==t&&(""==t||0==t.length?this.startInput=new Date:(new Date).getTime()-this.startInput.getTime()>500&&this.clearInput())}displayFn(t){let l="";return l="string"==typeof t?t:t?t.Value:"",l}clearInput(){this.inputControl.setValue(""),this.propagateChange(null)}ngOnDestroy(){this.destroy$.next(!0),this.destroy$.complete()}writeValue(t){}registerOnChange(t){this.propagateChange=t}registerOnTouched(){}}return r.\u0275fac=function(t){return new(t||r)(a.Y36(y.O),a.Y36(w.T))},r.\u0275cmp=a.Xpm({type:r,selectors:[["autocompleteV2"]],inputs:{requestUrl:"requestUrl",placeholder:"placeholder",clearOnSelect:"clearOnSelect",inputLock:"inputLock",readonly:"readonly",localStorage:"localStorage",renderThumbnail:"renderThumbnail",inputID:"inputID",inputTextValue:"inputTextValue",customStyle:"customStyle",customLabel:"customLabel",customClass:"customClass",ngModel:"ngModel"},outputs:{optionSelected:"optionSelected",onSelect:"onSelect",onInputEnter:"onInputEnter",onInputChange:"onInputChange",onOptionsEmpty:"onOptionsEmpty"},features:[a._Bn([{provide:u.JU,useExisting:(0,a.Gpc)(()=>r),multi:!0}]),a.TTD],decls:6,vars:15,consts:[[3,"ngClass"],["type","text","matInput","",1,"form-control","text-black",3,"id","readonly","matAutocomplete","placeholder","formControl","paste","keydown"],["style","width: max-content;",3,"for",4,"ngIf"],["autoActiveFirstOption","true",3,"panelWidth","displayWith","optionSelected"],["autocomplete","matAutocomplete"],[3,"value",4,"ngFor","ngForOf"],[2,"width","max-content",3,"for"],[3,"value"],["width","30","height","30","align","left","class","me-2",3,"src",4,"ngIf"],["width","30","height","30","align","left",1,"me-2",3,"src"]],template:function(t,l){if(1&t&&(a.TgZ(0,"mat-form-field",0)(1,"input",1),a.NdJ("paste",function(d){return l.inputLock?d.preventDefault():""})("keydown",function(d){return l.onKeyDown(d)}),a.qZA(),a.YNc(2,S,2,2,"label",2),a.qZA(),a.TgZ(3,"mat-autocomplete",3,4),a.NdJ("optionSelected",function(d){return l.onOptionSelected(d)}),a.YNc(5,E,4,3,"mat-option",5),a.qZA()),2&t){const _=a.MAs(4);a.Gre("w-100 ",l.customClass,""),a.Q6J("ngClass",a.VKq(13,I,l.customStyle)),a.xp6(1),a.Q6J("id",l.inputID)("readonly",l.readonly)("matAutocomplete",_)("placeholder",l.placeholder||"")("formControl",l.inputControl),a.xp6(1),a.Q6J("ngIf",l.customStyle),a.xp6(1),a.Q6J("panelWidth","30%")("displayWith",l.displayFn),a.xp6(2),a.Q6J("ngForOf",l.options)}},directives:[e.mk,h.ZL,u.Fj,u.JJ,u.oH,e.O5,h.XC,e.sg,P.ey],styles:["div.mat-autocomplete-panel mat-option {\n background-image: none !important;\n background-repeat: no-repeat !important;\n z-index: 9999999;\n}\n\ndiv.mat-autocomplete-panel mat-option.mat-option:hover {\n font-weight: bold;\n background-color: #f7fcfc;\n border: 1px solid #a6c9e2;\n width: 100%;\n}\n\ndiv.mat-autocomplete-panel mat-option.mat-option {\n margin: 0.1rem 0;\n overflow: visible;\n line-height: initial;\n word-wrap: break-word;\n white-space: pre-wrap;\n}\n\ndiv.mat-autocomplete-panel mat-option.mat-option span.mat-option-text {\n white-space: normal;\n}\n\ndiv.mat-autocomplete-panel mat-option.mat-active {\n background-color: #f7fcfc;\n border: 1px solid #a6c9e2;\n}\n\ndiv[role=listbox].mat-autocomplete-panel {\n border: 1px solid #a6c9e2;\n background-color: #fffff3;\n}\n\nmat-autocomplete.input-left > mat-form-field > input.form-control {\n padding-left: 0px !important;\n}\n\n.mat-option {\n font-size: 13px;\n height: auto !important;\n padding: 10px 6px !important;\n}"],encapsulation:2}),r})(),Z=(()=>{class r{}return r.\u0275fac=function(t){return new(t||r)},r.\u0275mod=a.oAB({type:r}),r.\u0275inj=a.cJS({imports:[[h.Bb,e.ez,u.UX]]}),r})()}}]);
@@ -0,0 +1 @@
1
+ "use strict";(self.webpackChunkPOS=self.webpackChunkPOS||[]).push([[3760],{24424:(k,N,c)=>{c.d(N,{O:()=>h});var _=c(32916),l=c(5e3);let h=(()=>{class b{constructor(){this.csvPrefixFormat=""}convertToCSV(T,m){let y;if("string"==typeof T)y=T;else{var Z="object"==typeof T?T:JSON.parse(T);y=this.transformToCSVStringFormat(Z)}this.exportCSV(y,m)}isNumeric(T){return/^-?\d+$/.test(T)}parseCSV(T){return new _.y(y=>{let Z=new FileReader;Z.onload=()=>{let q=Z.result.split(/\r\n|\n/),x=q[0].split(","),s=[];for(let t=0;t<q.length;t++){let d=q[t].split(",");if(d.length==x.length){let C=[];for(let g=0;g<x.length;g++)this.isNumeric(d[g])?C.push(parseFloat(d[g])):C.push(d[g]);s.push(C)}else{var D=q[t].split(new RegExp(',(?![^"]*"(?:(?:[^"]*"){2})*[^"]*$)'));let C=[];for(let g=0;g<D.length;g++)this.isNumeric(D[g])?C.push(parseFloat(D[g])):C.push(D[g]);s.push(C)}}y.next(s)},Z.readAsBinaryString(T)})}transformToCSVStringFormat(T){if(!T||!T.length)return;const y=Object.keys(T[0]);return T.map(I=>y.map(q=>{let x=null==I[q]?"":I[q];return x=x instanceof Date?x.toLocaleString():x.toString().replace(/"/g,'""'),x.search(/("|,|\n)/g)>=0&&(x=`"${x}"`),x}).join(",")).join("\n")}exportCSV(T,m){var y=new Blob([T],{type:"text/csv;charset=utf8;"}),Z=document.createElement("a");Z.setAttribute("href",window.URL.createObjectURL(y)),Z.setAttribute("download",m),document.body.appendChild(Z),Z.click(),document.body.removeChild(Z)}}return b.\u0275fac=function(T){return new(T||b)},b.\u0275prov=l.Yz7({token:b,factory:b.\u0275fac,providedIn:"root"}),b})()},87315:(k,N,c)=>{c.r(N),c.d(N,{InventoryModule:()=>fo});var _=c(69808),l=c(93075),h=c(84847),b=c(32075),O=c(86856),T=c(90508),m=c(79814),y=c(77531),Z=c(53251),I=c(63892),q=c(69832),x=c(68555),s=c(67327),D=c(23410),t=c(5e3),d=c(32442),C=c(24424),g=c(30273),f=c(24376),V=c(83902),M=c(11594);function at(n,i){if(1&n){const e=t.EpF();t.TgZ(0,"div",14)(1,"a",15),t.NdJ("click",function(){t.CHM(e);const a=t.oxw(2);return a.exportCSV(a.csvConverter,"InventoryExport/ByCategory",a.GetCSVName())}),t._UZ(2,"i",16),t._uU(3," Export "),t.qZA(),t._UZ(4,"button",17),t.TgZ(5,"ul",18)(6,"li",19)(7,"a",20),t.NdJ("click",function(){t.CHM(e);const a=t.oxw(2);return a.exportCSV(a.csvConverter,"InventoryExport/InventoryProductByOutlet","ProductQuantityWithOutlet.csv")}),t._uU(8,"Export With Outlet"),t.qZA()()()()}}function ot(n,i){if(1&n&&(t.TgZ(0,"span",21),t._uU(1),t.qZA()),2&n){const e=i.item;t.s9C("title",e.Value),t.xp6(1),t.Oqu(e.Value)}}function it(n,i){if(1&n&&(t.TgZ(0,"span",21),t._uU(1),t.qZA()),2&n){const e=i.item;t.s9C("title",e.Value),t.xp6(1),t.Oqu(e.Value)}}const rt=function(n){return{VariantID:n}};function lt(n,i){if(1&n&&(t.TgZ(0,"div")(1,"a",63),t._uU(2),t.ALo(3,"number"),t.qZA()()),2&n){const e=t.oxw().$implicit,o=t.oxw(5);t.xp6(1),t.Q6J("queryParams",t.VKq(5,rt,e.ID)),t.xp6(1),t.hij(" (",t.xi3(3,2,e.Allocated,"."+o.data.Decimal+"-"+o.data.Decimal)," allocated) ")}}const _t=function(){return["/menu/Products/Catalog/Variants/Info"]},Y=function(n){return{ID:n}};function pt(n,i){if(1&n&&(t.TgZ(0,"tr")(1,"td")(2,"a",58)(3,"span",57),t._uU(4),t.qZA(),t.TgZ(5,"span",57),t._uU(6),t.TgZ(7,"small",57),t._uU(8,"- "),t.qZA(),t._uU(9),t.qZA()()(),t.TgZ(10,"td",26),t._uU(11),t.qZA(),t.TgZ(12,"td",27),t._uU(13),t.ALo(14,"number"),t.YNc(15,lt,4,7,"div",48),t.qZA(),t.TgZ(16,"td",61)(17,"span",57),t._uU(18),t.ALo(19,"number"),t.qZA(),t._uU(20),t.qZA(),t.TgZ(21,"td",29),t._uU(22),t.ALo(23,"number"),t.qZA(),t.TgZ(24,"td",30),t._uU(25),t.ALo(26,"number"),t.qZA(),t.TgZ(27,"td",62),t._uU(28),t.ALo(29,"number"),t.qZA(),t.TgZ(30,"td",31),t._uU(31),t.qZA()()),2&n){const e=i.$implicit,o=t.oxw().$implicit,a=t.oxw(4);t.Tol(e.Quantity<=e.MinStock?"bg-low-danger border-bottom":"border-bottom"),t.xp6(2),t.Q6J("routerLink",t.DdM(36,_t))("queryParams",t.VKq(37,Y,e.ID)),t.xp6(1),t.Q6J("hidden",o.Variants.length<=1),t.xp6(1),t.Oqu(e.Model),t.xp6(1),t.Q6J("hidden",o.Variants.length>1),t.xp6(1),t.hij(" ",o.Name+" ("+e.Model+")"," "),t.xp6(1),t.Q6J("hidden",!o.Code),t.xp6(2),t.hij(" ",o.Code," "),t.xp6(2),t.Oqu(e.Code),t.xp6(2),t.hij(" ",t.xi3(14,24,e.Quantity,"."+a.data.Decimal+"-"+a.data.Decimal)," "),t.xp6(2),t.Q6J("ngIf",e.Allocated>0),t.xp6(2),t.Q6J("hidden",1==e.UnitQuantity),t.xp6(1),t.hij(" = \xa0 ",t.lcZ(19,27,e.Quantity*e.UnitQuantity)," "),t.xp6(2),t.hij(" ",e.UOMName," "),t.xp6(1),t.Q6J("hidden",!a.pageData.IsCostVisible),t.xp6(1),t.hij(" ",t.lcZ(23,29,e.UnitCost),""),t.xp6(2),t.Q6J("hidden",!a.pageData.IsPriceVisible),t.xp6(1),t.hij(" ",t.lcZ(26,31,e.UnitPrice),""),t.xp6(2),t.Q6J("hidden",!a.pageData.IsCostVisible),t.xp6(1),t.hij(" ",t.xi3(29,33,e.Margin,"1.0-2"),""),t.xp6(2),t.Q6J("hidden",!a.pageData.IsDiscountRole),t.xp6(1),t.hij(" ",e.Discount,"")}}const ct=function(){return["/menu/Products/Catalog/Products/Info"]};function ut(n,i){if(1&n&&(t.TgZ(0,"div",56)(1,"div",57)(2,"h4")(3,"a",58),t._uU(4),t.TgZ(5,"small",57),t._uU(6,"- "),t.qZA(),t._uU(7),t.qZA(),t.TgZ(8,"small"),t._uU(9),t.ALo(10,"number"),t.qZA()()(),t.TgZ(11,"div",23)(12,"table",59)(13,"tbody"),t.YNc(14,pt,32,39,"tr",60),t.qZA()()()()),2&n){const e=i.$implicit;t.xp6(1),t.Q6J("hidden",e.Variants.length<=1),t.xp6(2),t.Q6J("routerLink",t.DdM(10,ct))("queryParams",t.VKq(11,Y,e.ID)),t.xp6(1),t.hij(" ",e.Name," "),t.xp6(1),t.Q6J("hidden",!e.Code),t.xp6(2),t.hij(" ",e.Code," "),t.xp6(2),t.hij("[ Product Qty : ",t.lcZ(10,8,e.VariantsQuantity)," ]"),t.xp6(5),t.Q6J("ngForOf",e.Variants)}}function dt(n,i){if(1&n&&(t.TgZ(0,"div",52)(1,"div",53)(2,"h3",54),t._uU(3),t.qZA(),t.YNc(4,ut,15,13,"div",55),t.qZA()()),2&n){const e=i.$implicit;t.xp6(3),t.Oqu(e.Name),t.xp6(1),t.Q6J("ngForOf",e.Products)}}function st(n,i){if(1&n){const e=t.EpF();t.TgZ(0,"span",64),t.NdJ("click",function(){return t.CHM(e),t.oxw(3).StoreRowsCountAPIResult("Inventory/InventoryReportRowsCount")}),t.TgZ(1,"i",65),t._uU(2,"?"),t.qZA()()}}function gt(n,i){if(1&n&&(t.TgZ(0,"span"),t._uU(1),t.ALo(2,"number"),t.qZA()),2&n){const e=t.oxw(3);t.xp6(1),t.Oqu(t.lcZ(2,1,e.listTotal))}}function mt(n,i){if(1&n){const e=t.EpF();t.TgZ(0,"a",66),t.NdJ("click",function(){return t.CHM(e),t.oxw(3).NextPage(!0)}),t._UZ(1,"i",67),t._uU(2," Next"),t.qZA()}}function xt(n,i){if(1&n){const e=t.EpF();t.TgZ(0,"a",68),t.NdJ("click",function(){return t.CHM(e),t.oxw(3).StoreRowsCountAPIResult("Inventory/InventoryReportRowsCount",!0)}),t._UZ(1,"i",69),t._uU(2," Last"),t.qZA()}}const ht=function(){return["/menu/Inventory/Quantity/Valuation/Summary"]};function ft(n,i){if(1&n&&(t.TgZ(0,"div",22)(1,"div",23)(2,"table",24)(3,"thead",25)(4,"tr")(5,"th"),t._uU(6," Name "),t.qZA(),t.TgZ(7,"th",26),t._uU(8," Code "),t.qZA(),t.TgZ(9,"th",27),t._uU(10," Qty "),t.qZA(),t.TgZ(11,"th",28),t._uU(12," uom "),t.qZA(),t.TgZ(13,"th",29),t._uU(14," Cost "),t.qZA(),t.TgZ(15,"th",30),t._uU(16," Price "),t.qZA(),t.TgZ(17,"th",30),t._uU(18," Margin(%) "),t.qZA(),t.TgZ(19,"th",31),t._uU(20," Discount(%) "),t.qZA()()()(),t.YNc(21,dt,5,2,"div",32),t.TgZ(22,"div",33)(23,"div",34)(24,"p",35),t._uU(25,"*Incomplete Inventory Aggregate"),t.qZA(),t.TgZ(26,"a",36),t._uU(27,"View Total Inventory"),t.qZA()(),t.TgZ(28,"div",37)(29,"table",38)(30,"thead",25)(31,"tr")(32,"th",39),t._uU(33," Total Quantity "),t.qZA(),t.TgZ(34,"th",39),t._uU(35," Quantity * Content "),t.qZA(),t.TgZ(36,"th",40),t._uU(37," Total Inventory COST ( "),t._UZ(38,"span",41),t.ALo(39,"number"),t._uU(40,"%) "),t.qZA(),t.TgZ(41,"th",40),t._uU(42," Total Inventory Value when SOLD "),t.qZA()()(),t.TgZ(43,"tbody")(44,"tr"),t._UZ(45,"td",42),t.ALo(46,"number"),t._UZ(47,"td",42),t.ALo(48,"number"),t._UZ(49,"td",43),t.ALo(50,"number"),t._UZ(51,"td",43),t.ALo(52,"number"),t.qZA()()()()(),t.TgZ(53,"div",44)(54,"div",45)(55,"div",46),t._uU(56),t.ALo(57,"number"),t.YNc(58,st,3,0,"span",47),t.YNc(59,gt,3,3,"span",48),t._uU(60),t.qZA()(),t.TgZ(61,"div",49),t.YNc(62,mt,3,0,"a",50),t.YNc(63,xt,3,0,"a",51),t.qZA()()()()),2&n){const e=t.oxw(2);t.xp6(13),t.Q6J("hidden",!e.pageData.IsCostVisible),t.xp6(2),t.Q6J("hidden",!e.pageData.IsPriceVisible),t.xp6(2),t.Q6J("hidden",!e.pageData.IsCostVisible),t.xp6(2),t.Q6J("hidden",!e.pageData.IsDiscountRole),t.xp6(2),t.Q6J("ngForOf",e.infiniteList),t.xp6(5),t.Q6J("routerLink",t.DdM(36,ht)),t.xp6(10),t.Q6J("hidden",!e.pageData.IsCostVisible),t.xp6(2),t.Q6J("hidden",0==e.totalAggregate.TotalSales)("innerHtml",t.lcZ(39,22,e.totalAggregate.TotalCost/e.totalAggregate.TotalSales*100),t.oJD),t.xp6(3),t.Q6J("hidden",!e.pageData.IsPriceVisible),t.xp6(4),t.Q6J("innerHtml",t.xi3(46,24,e.totalAggregate.TotalQuantity,"."+e.data.Decimal+"-"+e.data.Decimal),t.oJD),t.xp6(2),t.Q6J("innerHtml",t.xi3(48,27,e.totalAggregate.TotalUnitQuantity,"."+e.data.Decimal+"-"+e.data.Decimal),t.oJD),t.xp6(2),t.Q6J("hidden",!e.pageData.IsCostVisible)("innerHtml",t.lcZ(50,30,e.totalAggregate.TotalCost),t.oJD),t.xp6(2),t.Q6J("hidden",!e.pageData.IsPriceVisible)("innerHtml",t.lcZ(52,32,e.totalAggregate.TotalSales),t.oJD),t.xp6(5),t.hij(" Showing 1 - ",t.lcZ(57,34,e.pageData.Filter.RowCount*(e.pageData.Filter.PageNumber-1)+e.data.TotalCurrentRow)," of "),t.xp6(2),t.Q6J("ngIf",!e.pageData.HideStoreApiCount),t.xp6(1),t.Q6J("ngIf",e.pageData.HideStoreApiCount),t.xp6(1),t.hij(" records ~ ",e.pageData.Filter.PageNumber," Page "),t.xp6(2),t.Q6J("ngIf",e.nextPageDisabled&&!e.goToLast),t.xp6(1),t.Q6J("ngIf",e.nextPageDisabled&&!e.goToLast)}}function Ct(n,i){if(1&n){const e=t.EpF();t.TgZ(0,"mainpanel-cmp",1),t.NdJ("textChange",function(a){return t.CHM(e),t.oxw().pageData.Filter.FilterText=a})("onSubmit",function(){return t.CHM(e),t.oxw().searchFromPageOne()}),t.TgZ(1,"actions"),t.YNc(2,at,9,0,"div",2),t.qZA(),t.TgZ(3,"filters")(4,"div",3)(5,"div")(6,"h6"),t._uU(7,"Outlet"),t.qZA(),t.TgZ(8,"ng-select",4),t.NdJ("ngModelChange",function(a){return t.CHM(e),t.oxw().pageData.Filter.EntityID=a}),t.qZA()(),t.TgZ(9,"div")(10,"h6"),t._uU(11,"Brand"),t.qZA(),t.TgZ(12,"ng-select",5),t.NdJ("ngModelChange",function(a){return t.CHM(e),t.oxw().pageData.Filter.BrandID=a}),t.YNc(13,ot,2,2,"ng-template",6),t.qZA()(),t.TgZ(14,"div")(15,"h6"),t._uU(16,"Category"),t.qZA(),t.TgZ(17,"ng-select",7),t.NdJ("ngModelChange",function(a){return t.CHM(e),t.oxw().pageData.Filter.CategoryID=a}),t.YNc(18,it,2,2,"ng-template",6),t.qZA()(),t.TgZ(19,"div",8)(20,"h6"),t._uU(21,"Quantity From - To"),t.qZA(),t.TgZ(22,"input",9),t.NdJ("ngModelChange",function(a){return t.CHM(e),t.oxw().pageData.Filter.QuantityFrom=a}),t.qZA(),t._uU(23," - "),t.TgZ(24,"input",10),t.NdJ("ngModelChange",function(a){return t.CHM(e),t.oxw().pageData.Filter.QuantityTo=a}),t.qZA()(),t.TgZ(25,"div",11)(26,"h6"),t._uU(27,"Discontinued"),t.qZA(),t.TgZ(28,"radio-options",12),t.NdJ("modelChange",function(a){return t.CHM(e),t.oxw().pageData.Filter.Discontinued=a}),t.qZA()()()(),t.TgZ(29,"content"),t.YNc(30,ft,64,37,"div",13),t.qZA()()}if(2&n){const e=t.oxw();t.Q6J("pageData",e.menuData)("text",e.pageData.Filter.FilterText),t.xp6(2),t.Q6J("ngIf",e.pageData.IsExport),t.xp6(6),t.Q6J("items",null==e.pageData.Options?null:e.pageData.Options.Entities)("ngModel",e.pageData.Filter.EntityID),t.xp6(4),t.Q6J("items",null==e.pageData.Options?null:e.pageData.Options.Brands)("ngModel",e.pageData.Filter.BrandID),t.xp6(5),t.Q6J("items",null==e.pageData.Options?null:e.pageData.Options.Categories)("ngModel",e.pageData.Filter.CategoryID),t.xp6(5),t.Q6J("ngModel",e.pageData.Filter.QuantityFrom),t.xp6(2),t.Q6J("ngModel",e.pageData.Filter.QuantityTo),t.xp6(4),t.Q6J("model",e.pageData.Filter.Discontinued),t.xp6(2),t.Q6J("ngIf",e.data)}}let H=(()=>{class n extends D.X{constructor(e,o){super(e,"Inventory/InventoryReport","InventoryLoader/InventoryReport"),this.csvConverter=o,this.totalAggregate={TotalUnitQuantity:0,TotalCost:0,TotalSales:0,TotalQuantity:0}}preGetList(){""==this.pageData.Filter.QuantityTo&&delete this.pageData.Filter.QuantityTo,""==this.pageData.Filter.QuantityFrom&&delete this.pageData.Filter.QuantityFrom,"string"==typeof this.pageData.Filter.QuantityFrom&&(this.pageData.Filter.QuantityFrom=parseFloat(this.pageData.Filter.QuantityFrom))}GetCSVName(){return s.gT.IsEmpty(this.pageData.Filter.EntityID)?"Inventory.Csv":"Inventory_"+this.pageData.Options.Entities.find(o=>o.ID==this.pageData.Filter.EntityID).Name+".Csv"}preInitList(){this.oldRowCount=this.pageData.Filter.RowCount,s.gT.IsEmpty(this.pageData.Filter.EntityID)&&delete this.pageData.Filter.EntityID,s.gT.IsEmpty(this.pageData.Filter.CategoryID)&&delete this.pageData.Filter.CategoryID}assignAggregate(e){this.totalAggregate.TotalQuantity=e.Aggregate.TotalQuantity,this.totalAggregate.TotalUnitQuantity=e.Aggregate.TotalUnitQuantity,this.totalAggregate.TotalCost=e.Aggregate.TotalCost,this.totalAggregate.TotalSales=e.Aggregate.TotalSales}postExtendData(e){this.totalAggregate.TotalQuantity+=e.Aggregate.TotalQuantity,this.totalAggregate.TotalUnitQuantity+=e.Aggregate.TotalUnitQuantity,this.totalAggregate.TotalCost+=e.Aggregate.TotalCost,this.totalAggregate.TotalSales+=e.Aggregate.TotalSales}}return n.\u0275fac=function(e){return new(e||n)(t.Y36(d.O),t.Y36(C.O))},n.\u0275cmp=t.Xpm({type:n,selectors:[["POS-detail"]],features:[t.qOj],decls:1,vars:1,consts:[["filterWidth","270px",3,"pageData","text","textChange","onSubmit",4,"ngIf"],["filterWidth","270px",3,"pageData","text","textChange","onSubmit"],["class","btn-group ms-8",4,"ngIf"],["container","",1,"w-100"],["bindLabel","Name","bindValue","ID","placeholder","Choose an outlet",3,"items","ngModel","ngModelChange"],["bindLabel","Value","bindValue","Key","placeholder","Choose a brand",3,"items","ngModel","ngModelChange"],["ng-option-tmp",""],["bindLabel","Value","bindValue","Key","placeholder","Choose a category",3,"items","ngModel","ngModelChange"],[1,"d-inline","mb-2"],["type","text","name","QuantityFrom",1,"w-25","me-2",3,"ngModel","ngModelChange"],["type","text","autoNum","","name","QuantityTo",1,"w-25",3,"ngModel","ngModelChange"],[1,"mt-5"],["name","Discontinued",3,"model","modelChange"],["class","container-fluid mt-3",4,"ngIf"],[1,"btn-group","ms-8"],["role","button",1,"btn","btn-outline-secondary",3,"click"],[1,"fa","fa-upload"],["data-bs-toggle","dropdown",1,"btn","btn-outline-secondary","btn-sm","dropdown-toggle"],[1,"dropdown-menu","dropdown-menu-end",2,"cursor","pointer"],[1,"dropdown-item"],[3,"click"],[3,"title"],[1,"container-fluid","mt-3"],[1,"table-responsive"],["id","tableGrid",1,"table"],[1,"thead-light","sticky-top-thead"],[2,"width","120px"],[1,"text-end",2,"width","100px"],[1,"fst-italic","small","fw-bold","text-end",2,"width","60px"],[1,"text-end",2,"width","120px",3,"hidden"],[1,"text-end",2,"width","80px",3,"hidden"],[1,"text-end",2,"width","100px",3,"hidden"],["class","categorypack summary table-responsive",4,"ngFor","ngForOf"],[1,"row","d-flex","justify-content-between","align-items-center"],[1,"col-md-4","text-center"],[1,"h3","text-warning"],["role","button",1,"btn","btn-outline-primary",3,"routerLink"],[1,"col-md-8"],[1,"table","table-borderless"],[1,"text-end"],[1,"text-end",3,"hidden"],[3,"hidden","innerHtml"],[1,"text-end",3,"innerHtml"],[1,"text-end",3,"hidden","innerHtml"],[1,"d-flex","justify-content-between","mt-5"],[1,"me-auto","d-sm-block","collapse","mt-3"],[1,"fw-bold","fst-italic","hidden-xxs"],["style","cursor:pointer",3,"click",4,"ngIf"],[4,"ngIf"],[1,"btn-group"],["role","button","class","btn btn-outline-secondary btn-sm text-primary","title","Load more for 500 variants",3,"click",4,"ngIf"],["role","button","class","btn btn-outline-secondary btn-sm text-primary","title","Load all products",3,"click",4,"ngIf"],[1,"categorypack","summary","table-responsive"],[1,"mt-10"],[1,"fw-normal"],["class","productpack mt-5",4,"ngFor","ngForOf"],[1,"productpack","mt-5"],[3,"hidden"],[3,"routerLink","queryParams"],[1,"table","table-borderless","mt-6"],[3,"class",4,"ngFor","ngForOf"],[1,"small","fst-italic","text-end",2,"width","60px"],["runat","server",1,"text-end",2,"width","80px",3,"hidden"],["routerLink","/menu/Fulfillment/Allocated/Unfulfilled_Products",1,"text-warning",3,"queryParams"],[2,"cursor","pointer",3,"click"],["title","Retrieve rows count",1,"border","p-3"],["role","button","title","Load more for 500 variants",1,"btn","btn-outline-secondary","btn-sm","text-primary",3,"click"],[1,"fa-solid","fa-arrow-right"],["role","button","title","Load all products",1,"btn","btn-outline-secondary","btn-sm","text-primary",3,"click"],[1,"fa-solid","fa-share"]],template:function(e,o){1&e&&t.YNc(0,Ct,31,13,"mainpanel-cmp",0),2&e&&t.Q6J("ngIf",o.pageData.Filter)},directives:[_.O5,g.p,f.w9,l.JJ,l.On,f.ir,l.Fj,V.b,M.P,_.sg,x.yS],pipes:[_.JJ],styles:[""]}),n})();var A=c(4077),w=c(22290);function yt(n,i){if(1&n&&(t.TgZ(0,"span",12),t._uU(1),t.qZA()),2&n){const e=i.item;t.s9C("title",e.Value),t.xp6(1),t.Oqu(e.Value)}}function Zt(n,i){if(1&n){const e=t.EpF();t.TgZ(0,"div",5)(1,"div")(2,"h6"),t._uU(3,"Outlet"),t.qZA(),t.TgZ(4,"ng-select",6),t.NdJ("ngModelChange",function(a){return t.CHM(e),t.oxw(2).pageData.Filter.EntityID=a}),t.qZA()(),t.TgZ(5,"div")(6,"h6"),t._uU(7,"Category"),t.qZA(),t.TgZ(8,"ng-select",7),t.NdJ("ngModelChange",function(a){return t.CHM(e),t.oxw(2).pageData.Filter.CategoryID=a}),t.YNc(9,yt,2,2,"ng-template",8),t.qZA()(),t.TgZ(10,"div")(11,"h6"),t._uU(12,"Quantity From / To"),t.qZA(),t.TgZ(13,"input",9),t.NdJ("ngModelChange",function(a){return t.CHM(e),t.oxw(2).pageData.Filter.QuantityFrom=a}),t.qZA(),t.TgZ(14,"input",10),t.NdJ("ngModelChange",function(a){return t.CHM(e),t.oxw(2).pageData.Filter.QuantityTo=a}),t.qZA()(),t.TgZ(15,"div")(16,"h6"),t._uU(17,"Discontinued"),t.qZA(),t.TgZ(18,"radio-options",11),t.NdJ("modelChange",function(a){return t.CHM(e),t.oxw(2).pageData.Filter.Discontinued=a}),t.qZA()()()}if(2&n){const e=t.oxw(2);t.xp6(4),t.Q6J("items",null==e.pageData.Options?null:e.pageData.Options.Entities)("ngModel",e.pageData.Filter.EntityID),t.xp6(4),t.Q6J("items",null==e.pageData.Options?null:e.pageData.Options.Categories)("ngModel",e.pageData.Filter.CategoryID),t.xp6(5),t.Q6J("ngModel",e.pageData.Filter.QuantityFrom),t.xp6(1),t.Q6J("ngModel",e.pageData.Filter.QuantityTo),t.xp6(4),t.Q6J("model",e.pageData.Filter.Discontinued)}}function Tt(n,i){if(1&n&&(t.TgZ(0,"div",14)(1,"div",15)(2,"table",16)(3,"thead",17)(4,"tr")(5,"th",18),t._uU(6," Total Quantity "),t.qZA(),t.TgZ(7,"th",18),t._uU(8," Quantity * Content "),t.qZA(),t.TgZ(9,"th",19),t._uU(10," Total Inventory COST ( "),t._UZ(11,"span",20),t.ALo(12,"number"),t._uU(13,"%) "),t.qZA(),t.TgZ(14,"th",19),t._uU(15," Total Inventory Value when SOLD "),t.qZA()()(),t.TgZ(16,"tbody")(17,"tr"),t._UZ(18,"td",21),t.ALo(19,"number"),t._UZ(20,"td",21),t.ALo(21,"number"),t._UZ(22,"td",22),t.ALo(23,"number"),t._UZ(24,"td",22),t.ALo(25,"number"),t.qZA()()()()()),2&n){const e=t.oxw(3);t.xp6(9),t.Q6J("hidden",!e.pageData.IsCostVisible),t.xp6(2),t.Q6J("hidden",0==(null==e.data.Data?null:e.data.Data.UnitPrice))("innerHtml",t.lcZ(12,10,e.data.Data.UnitCost/e.data.Data.UnitPrice*100),t.oJD),t.xp6(3),t.Q6J("hidden",!e.pageData.IsPriceVisible),t.xp6(4),t.Q6J("innerHtml",t.xi3(19,12,e.data.Data.Quantity,"."+e.data.Decimal+"-"+e.data.Decimal),t.oJD),t.xp6(2),t.Q6J("innerHtml",t.xi3(21,15,e.data.Data.VariantUnitQuantity,"."+e.data.Decimal+"-"+e.data.Decimal),t.oJD),t.xp6(2),t.Q6J("hidden",!e.pageData.IsCostVisible)("innerHtml",t.lcZ(23,18,e.data.Data.UnitCost),t.oJD),t.xp6(2),t.Q6J("hidden",!e.pageData.IsPriceVisible)("innerHtml",t.lcZ(25,20,e.data.Data.UnitPrice),t.oJD)}}function vt(n,i){if(1&n&&(t.TgZ(0,"content"),t.YNc(1,Tt,26,22,"div",13),t.qZA()),2&n){const e=t.oxw(2);t.xp6(1),t.Q6J("ngIf",e.data)}}const Dt=function(){return["/menu/Inventory/Quantity/Valuation"]};function At(n,i){if(1&n){const e=t.EpF();t.TgZ(0,"mainpanel-cmp",1),t.NdJ("onSubmit",function(){return t.CHM(e),t.oxw().searchFromPageOne()}),t.TgZ(1,"actions")(2,"a",2),t._uU(3," Detail"),t.qZA()(),t.TgZ(4,"filters"),t.YNc(5,Zt,19,7,"div",3),t.qZA(),t.YNc(6,vt,2,1,"content",4),t.qZA()}if(2&n){const e=t.oxw();t.Q6J("pageData",e.menuData)("hideSearchBox",!0),t.xp6(2),t.Q6J("routerLink",t.DdM(5,Dt)),t.xp6(3),t.Q6J("ngIf",e.pageData.Filter),t.xp6(1),t.Q6J("ngIf",e.pageData.Filter)}}let It=(()=>{class n extends A.n{constructor(e,o,a){super(e,"Inventory/InventorySumReport","InventoryLoader/InventoryReport",o),this.httpService=e,this.csvConverter=a}preGetList(){""==this.pageData.Filter.QuantityTo&&delete this.pageData.Filter.QuantityTo}}return n.\u0275fac=function(e){return new(e||n)(t.Y36(d.O),t.Y36(w._W),t.Y36(C.O))},n.\u0275cmp=t.Xpm({type:n,selectors:[["POS-summary"]],features:[t.qOj],decls:1,vars:1,consts:[["filterWidth","270px",3,"pageData","hideSearchBox","onSubmit",4,"ngIf"],["filterWidth","270px",3,"pageData","hideSearchBox","onSubmit"],["role","button",1,"btn","btn-success",3,"routerLink"],["container","","class","w-100",4,"ngIf"],[4,"ngIf"],["container","",1,"w-100"],["bindLabel","Name","bindValue","ID","placeholder","Choose...",3,"items","ngModel","ngModelChange"],["bindLabel","Value","bindValue","Key","placeholder","Choose...",3,"items","ngModel","ngModelChange"],["ng-option-tmp",""],["type","text","name","QuantityFrom",2,"width","40%",3,"ngModel","ngModelChange"],["type","text","name","QuantityTo",1,"ms-2",2,"width","40%",3,"ngModel","ngModelChange"],["name","Discontinued",3,"model","modelChange"],[3,"title"],["class","container-fluid mt-3",4,"ngIf"],[1,"container-fluid","mt-3"],[1,"table-responsive"],[1,"table"],[1,"thead-light","sticky-top-thead"],[1,"text-end"],[1,"text-end",3,"hidden"],[3,"hidden","innerHtml"],[1,"text-end",3,"innerHtml"],[1,"text-end",3,"hidden","innerHtml"]],template:function(e,o){1&e&&t.YNc(0,At,7,6,"mainpanel-cmp",0),2&e&&t.Q6J("ngIf",o.pageData.Filter)},directives:[_.O5,g.p,x.yS,f.w9,l.JJ,l.On,f.ir,l.Fj,M.P],pipes:[_.JJ],encapsulation:2}),n})();var F=c(93669);function bt(n,i){if(1&n){const e=t.EpF();t.TgZ(0,"div",5)(1,"div")(2,"h6"),t._uU(3,"Display Mode"),t.qZA(),t.TgZ(4,"radio-options",6),t.NdJ("modelChange",function(a){return t.CHM(e),t.oxw().pageData.Filter.TypeID=a}),t.qZA()(),t.TgZ(5,"div")(6,"h6"),t._uU(7,"Discontinued"),t.qZA(),t.TgZ(8,"radio-options",7),t.NdJ("modelChange",function(a){return t.CHM(e),t.oxw().pageData.Filter.Discontinued=a}),t.qZA()()()}if(2&n){const e=t.oxw();t.xp6(4),t.Q6J("model",e.pageData.Filter.TypeID)("options",e.Types),t.xp6(4),t.Q6J("model",e.pageData.Filter.Discontinued)}}function Ot(n,i){if(1&n&&(t.TgZ(0,"tr")(1,"td"),t._uU(2),t.qZA(),t.TgZ(3,"td"),t._uU(4),t.qZA(),t.TgZ(5,"td",21),t._uU(6),t.ALo(7,"number"),t.qZA(),t.TgZ(8,"td",21),t._uU(9),t.ALo(10,"number"),t.qZA(),t.TgZ(11,"td",21),t._uU(12),t.ALo(13,"number"),t.qZA()()),2&n){const e=i.$implicit;t.xp6(2),t.Oqu(e.Name),t.xp6(2),t.Oqu(e.Code),t.xp6(2),t.Oqu(t.xi3(7,5,e.Inventory,"0.0-4")),t.xp6(3),t.Oqu(t.xi3(10,8,e.MinimumInventory,"0.0-4")),t.xp6(3),t.Oqu(t.xi3(13,11,e.Difference,"0.0-4"))}}function qt(n,i){if(1&n){const e=t.EpF();t.TgZ(0,"div",8)(1,"div",9)(2,"table",10),t.NdJ("matSortChange",function(a){return t.CHM(e),t.oxw().sortData(a)}),t.TgZ(3,"thead",11)(4,"tr",12)(5,"th",13),t._uU(6,"Name"),t.qZA(),t.TgZ(7,"th",14),t._uU(8,"Code"),t.qZA(),t.TgZ(9,"th",15),t._uU(10,"On Hand"),t.qZA(),t.TgZ(11,"th",16),t._uU(12,"Buffer"),t.qZA(),t.TgZ(13,"th",17),t._uU(14,"Difference"),t.qZA()()(),t.TgZ(15,"tbody"),t.YNc(16,Ot,14,14,"tr",18),t.qZA(),t.TgZ(17,"tfoot")(18,"tr",19),t._UZ(19,"td",20),t.TgZ(20,"td",20),t._uU(21,"Total : "),t.qZA(),t.TgZ(22,"td",21),t._uU(23),t.ALo(24,"number"),t.ALo(25,"sum"),t.qZA(),t.TgZ(26,"td",21),t._uU(27),t.ALo(28,"number"),t.ALo(29,"sum"),t.qZA(),t.TgZ(30,"td",21),t._uU(31),t.ALo(32,"number"),t.ALo(33,"sum"),t.qZA()()()()()()}if(2&n){const e=t.oxw();t.xp6(16),t.Q6J("ngForOf",e.data),t.xp6(7),t.Oqu(t.xi3(24,4,t.xi3(25,7,e.data,"Inventory"),"0.0-4")),t.xp6(4),t.Oqu(t.xi3(28,10,t.xi3(29,13,e.data,"MinimumInventory"),"0.0-4")),t.xp6(4),t.Oqu(t.xi3(32,16,t.xi3(33,19,e.data,"Difference"),"0.0-4"))}}let Mt=(()=>{class n extends A.n{constructor(e,o,a){super(e,"Inventory/GetOutletList","InventoryLoader/InventoryReport",o),this.httpService=e,this.csvConverter=a,this.Types=[{Key:0,Value:"All"},{Key:1,Value:"Standard Inventory"}]}preInitList(){this.pageData.Filter.TypeID||(this.pageData.Filter={TypeID:1,Discontinued:!1})}postInit(e){this.originalData=e}sortData(e){const o=this.data.slice();function a(r,p,v){return(r<p?-1:1)*(v?1:-1)}this.data=e.active&&""!==e.direction?o.sort((r,p)=>{const v="asc"===e.direction;switch(r.Code=null==r.Code?"":r.Code,p.Code=null==p.Code?"":p.Code,e.active){case"Inventory":return a(r.Inventory,p.Inventory,v);case"Name":return a(r.Name.toLocaleLowerCase(),p.Name.toLocaleLowerCase(),v);case"Code":return a(r.Code.toLocaleLowerCase(),p.Code.toLocaleLowerCase(),v);case"MinimumInventory":return a(r.MinimumInventory,p.MinimumInventory,v);case"Difference":return a(r.Difference,p.Difference,v);default:return 0}}):this.originalData}export(e){this.exportCSV(this.csvConverter,"Inventory/ExportOutletInventory","outletinventory.csv")}}return n.\u0275fac=function(e){return new(e||n)(t.Y36(d.O),t.Y36(w._W),t.Y36(C.O))},n.\u0275cmp=t.Xpm({type:n,selectors:[["POS-by-outlet"]],features:[t.qOj],decls:9,vars:4,consts:[["filterWidth","270px",3,"pageData","hideSearchBox","onSubmit"],[1,"btn","btn-outline-secondary",3,"click"],[1,"fa-solid","fa-upload","me-3"],["container","","class","w-100",4,"ngIf"],["class","container-fluid mt-3",4,"ngIf"],["container","",1,"w-100"],["name","Types",3,"model","options","modelChange"],["name","Discontinued",3,"model","modelChange"],[1,"container-fluid","mt-3"],[1,"table-responsive"],["id","tableGrid","matSort","",1,"table",3,"matSortChange"],[1,"thead-light","sticky-top-thead"],[1,"header"],["mat-sort-header","Name",2,"width","66%"],["mat-sort-header","Code",2,"width","10%"],["mat-sort-header","Inventory",1,"text-start",2,"width","8%"],["mat-sort-header","MinimumInventory",1,"text-start",2,"width","9%"],["mat-sort-header","Difference",1,"text-start",2,"width","8%"],[4,"ngFor","ngForOf"],[1,"table-footer"],[1,"text-start","empty-column"],[1,"text-start"]],template:function(e,o){1&e&&(t.TgZ(0,"mainpanel-cmp",0),t.NdJ("onSubmit",function(){return o.searchFromPageOne()}),t.TgZ(1,"actions")(2,"button",1),t.NdJ("click",function(){return o.export("default")}),t._UZ(3,"i",2),t._uU(4,"Export "),t.qZA()(),t.TgZ(5,"filters"),t.YNc(6,bt,9,3,"div",3),t.qZA(),t.TgZ(7,"content"),t.YNc(8,qt,34,22,"div",4),t.qZA()()),2&e&&(t.Q6J("pageData",o.menuData)("hideSearchBox",!0),t.xp6(6),t.Q6J("ngIf",o.pageData.Filter),t.xp6(2),t.Q6J("ngIf",o.data))},directives:[g.p,_.O5,M.P,h.YE,h.nU,_.sg],pipes:[_.JJ,F.qU],styles:[""]}),n})();function wt(n,i){if(1&n&&(t.TgZ(0,"span",16),t._uU(1),t.qZA()),2&n){const e=i.item;t.s9C("title",e.Value),t.xp6(1),t.Oqu(e.Value)}}function Ft(n,i){if(1&n&&(t.TgZ(0,"th",28),t._uU(1),t.qZA()),2&n){const e=i.$implicit;t.xp6(1),t.hij(" ",e.Name," ")}}function Ut(n,i){if(1&n&&(t.TgZ(0,"td"),t._uU(1),t.qZA()),2&n){const e=t.oxw().$implicit;t.xp6(1),t.hij(" ",e.ProductCode,"")}}function Lt(n,i){if(1&n&&(t.TgZ(0,"span"),t._uU(1),t.qZA()),2&n){const e=i.$implicit,o=t.oxw().$implicit;t.xp6(1),t.hij(" ",e.Key==o.ID?e.Value:""," ")}}function Jt(n,i){if(1&n&&(t.TgZ(0,"td",31),t.YNc(1,Lt,2,1,"span",26),t.qZA()),2&n){const e=t.oxw().$implicit;t.xp6(1),t.Q6J("ngForOf",null==e?null:e.EntityStock)}}const Nt=function(n){return{ID:n}};function St(n,i){if(1&n&&(t.TgZ(0,"tr")(1,"td")(2,"a",29),t._uU(3),t.qZA()(),t.YNc(4,Ut,2,1,"td",27),t.TgZ(5,"td"),t._uU(6),t.qZA(),t.YNc(7,Jt,2,1,"td",30),t.TgZ(8,"td",31),t._uU(9),t.ALo(10,"number"),t.ALo(11,"sum"),t.qZA(),t.TgZ(12,"td"),t._uU(13),t.qZA()()),2&n){const e=i.$implicit,o=t.oxw(3);t.xp6(2),t.Q6J("queryParams",t.VKq(12,Nt,e.ID)),t.xp6(1),t.hij(" ",e.Name," "),t.xp6(1),t.Q6J("ngIf",o.pageData.IsProductCodeVisible),t.xp6(2),t.Oqu(e.Code),t.xp6(1),t.Q6J("ngForOf",null==e?null:e.Entities),t.xp6(2),t.hij(" ",t.lcZ(10,7,t.xi3(11,9,e.EntityStock,"Value"))," "),t.xp6(4),t.hij(" ",e.UOM,"")}}function Qt(n,i){1&n&&t._UZ(0,"td",33)}function Pt(n,i){if(1&n&&(t.TgZ(0,"td",31),t._uU(1),t.ALo(2,"number"),t.qZA()),2&n){const e=i.$implicit;t.xp6(1),t.hij(" ",t.lcZ(2,1,e.Quantity)," ")}}function kt(n,i){if(1&n&&(t.TgZ(0,"tfoot")(1,"tr",32),t._UZ(2,"td",33),t.YNc(3,Qt,1,0,"td",34),t._UZ(4,"td",33),t.YNc(5,Pt,3,3,"td",30),t.TgZ(6,"td",31),t._uU(7),t.ALo(8,"number"),t.ALo(9,"sum"),t.qZA(),t._UZ(10,"td",33),t.qZA()()),2&n){const e=t.oxw(3);t.xp6(3),t.Q6J("ngIf",e.pageData.IsProductCodeVisible),t.xp6(2),t.Q6J("ngForOf",null==e.data?null:e.data.Entities),t.xp6(2),t.hij(" ",t.lcZ(8,3,t.xi3(9,5,e.data.Entities,"Quantity"))," ")}}function Et(n,i){if(1&n&&(t.TgZ(0,"div",17)(1,"div",18)(2,"table",19)(3,"thead",20)(4,"tr")(5,"th"),t._uU(6," Product "),t.qZA(),t.TgZ(7,"th",21),t._uU(8," Product Code "),t.qZA(),t.TgZ(9,"th",22),t._uU(10," Code "),t.qZA(),t.YNc(11,Ft,2,1,"th",23),t.TgZ(12,"th",24),t._uU(13," Total "),t.qZA(),t._UZ(14,"th",25),t.qZA()(),t.TgZ(15,"tbody"),t.YNc(16,St,14,14,"tr",26),t.qZA(),t.YNc(17,kt,11,8,"tfoot",27),t.qZA()()()),2&n){const e=t.oxw(2);t.xp6(7),t.Q6J("hidden",!e.pageData.IsProductCodeVisible),t.xp6(4),t.Q6J("ngForOf",null==e.data?null:e.data.Entities),t.xp6(5),t.Q6J("ngForOf",null==e.data?null:e.data.Data),t.xp6(1),t.Q6J("ngIf",(null==e.data?null:e.data.Data.length)>0)}}const Bt=function(){return["/menu/Inventory/Quantity/Product_By_Outlet"]},Yt=function(){return["/menu/Inventory/Quantity/Product_By_Outlet/Category_By_Outlet"]};function Ht(n,i){if(1&n){const e=t.EpF();t.TgZ(0,"mainpanel-cmp",1),t.NdJ("onSubmit",function(){return t.CHM(e),t.oxw().searchFromPageOne()}),t.TgZ(1,"actions")(2,"a",2),t.NdJ("click",function(){t.CHM(e);const a=t.oxw();return a.exportCSV(a.csvConverter,"Inventory/OutletGroupProductList","StockByOutletGroup.csv")}),t._UZ(3,"i",3),t._uU(4,"\xa0Export "),t.qZA(),t.TgZ(5,"div",4)(6,"a",5),t._uU(7," Product by Outlet"),t.qZA(),t._UZ(8,"button",6),t.TgZ(9,"ul",7)(10,"li",8)(11,"a",9),t._uU(12,"Category by Outlet"),t.qZA()()()()(),t.TgZ(13,"filters")(14,"div",10)(15,"div")(16,"h6"),t._uU(17,"Category"),t.qZA(),t.TgZ(18,"ng-select",11),t.NdJ("ngModelChange",function(a){return t.CHM(e),t.oxw().pageData.Filter.CategoryID=a}),t.YNc(19,wt,2,2,"ng-template",12),t.qZA()(),t.TgZ(20,"div")(21,"h6"),t._uU(22,"Quantity"),t.qZA(),t.TgZ(23,"input",13),t.NdJ("ngModelChange",function(a){return t.CHM(e),t.oxw().pageData.Filter.QuantityFrom=a}),t.qZA(),t._UZ(24,"i",14),t.TgZ(25,"input",13),t.NdJ("ngModelChange",function(a){return t.CHM(e),t.oxw().pageData.Filter.QuantityTo=a}),t.qZA()()()(),t.TgZ(26,"content"),t.YNc(27,Et,18,4,"div",15),t.qZA()()}if(2&n){const e=t.oxw();t.Q6J("pageData",e.menuData)("hideSearchBox",!0),t.xp6(2),t.Q6J("hidden",!e.pageData.HasRoleExport),t.xp6(4),t.Q6J("routerLink",t.DdM(10,Bt)),t.xp6(5),t.Q6J("routerLink",t.DdM(11,Yt)),t.xp6(7),t.Q6J("items",null==e.pageData.Options?null:e.pageData.Options.Categories)("ngModel",e.pageData.Filter.CategoryID),t.xp6(5),t.Q6J("ngModel",e.pageData.Filter.QuantityFrom),t.xp6(2),t.Q6J("ngModel",e.pageData.Filter.QuantityTo),t.xp6(2),t.Q6J("ngIf",e.data)}}let Rt=(()=>{class n extends A.n{constructor(e,o,a){super(e,"Inventory/OutletGroupProductList","InventoryLoader/OutletGroupProductList",o),this.httpService=e,this.csvConverter=a}preGetList(){""==this.pageData.Filter.QuantityTo&&delete this.pageData.Filter.QuantityTo}}return n.\u0275fac=function(e){return new(e||n)(t.Y36(d.O),t.Y36(w._W),t.Y36(C.O))},n.\u0275cmp=t.Xpm({type:n,selectors:[["POS-by-outlet-group"]],features:[t.qOj],decls:1,vars:1,consts:[["filterWidth","270px",3,"pageData","hideSearchBox","onSubmit",4,"ngIf"],["filterWidth","270px",3,"pageData","hideSearchBox","onSubmit"],["value","Export","title","Export",1,"btn","btn-outline-secondary",3,"hidden","click"],[1,"fa","fa-upload"],[1,"btn-group","ms-8"],["role","button",1,"btn","btn-outline-secondary",3,"routerLink"],["data-bs-toggle","dropdown","aria-expanded","false",1,"btn","btn-outline-secondary","btn-sm","dropdown-toggle"],[1,"dropdown-menu","dropdown-menu-end",2,"cursor","pointer"],[1,"dropdown-item"],[3,"routerLink"],["container","",1,"w-100"],["bindLabel","Value","bindValue","Key","placeholder","Choose...",3,"items","ngModel","ngModelChange"],["ng-option-tmp",""],["type","text","autoNum","",1,"me-2",2,"width","65px",3,"ngModel","ngModelChange"],[1,"fa","fa-arrow-right"],["class","container-fluid mt-3",4,"ngIf"],[3,"title"],[1,"container-fluid","mt-3"],[1,"table-responsive"],["id","tableGrid",1,"table"],[1,"thead-light","sticky-top-thead"],["sorter","ProductCode",2,"width","120px",3,"hidden"],["sorter","Code",2,"width","120px"],["class","text-end small","style","width: 70px",4,"ngFor","ngForOf"],[1,"text-end",2,"width","75px"],[1,"UOMWidth"],[4,"ngFor","ngForOf"],[4,"ngIf"],[1,"text-end","small",2,"width","70px"],["routerLink","/menu/Products/Catalog/Variants/Info",3,"queryParams"],["class","text-end",4,"ngFor","ngForOf"],[1,"text-end"],[1,"table-footer"],[1,"empty-column"],["class","empty-column",4,"ngIf"]],template:function(e,o){1&e&&t.YNc(0,Ht,28,12,"mainpanel-cmp",0),2&e&&t.Q6J("ngIf",o.pageData.Filter)},directives:[_.O5,g.p,x.yS,f.w9,l.JJ,l.On,f.ir,l.Fj,V.b,_.sg],pipes:[_.JJ,F.qU],styles:[""]}),n})();function jt(n,i){if(1&n&&(t.TgZ(0,"span",18),t._uU(1),t.qZA()),2&n){const e=i.item;t.s9C("title",e.Value),t.xp6(1),t.Oqu(e.Value)}}const Gt=function(n,i){return{"ttip-before-scroll":n,"ttip-after-scroll":i}};function Wt(n,i){if(1&n&&(t.TgZ(0,"span",35),t._uU(1),t.ALo(2,"keys"),t.qZA()),2&n){const e=t.oxw().index,o=t.oxw(3);t.Tol(t.WLB(5,Gt,!o.isScroll,o.isScroll)),t.xp6(1),t.Oqu(t.lcZ(2,3,o.data.Title[0])[e].value)}}function $t(n,i){if(1&n&&(t.TgZ(0,"th",33),t.YNc(1,Wt,3,8,"span",34),t._uU(2),t.qZA()),2&n){const e=i.$implicit;t.ekj("ttip","z"==e.key[0]),t.Q6J("mat-sort-header",e.key),t.xp6(1),t.Q6J("ngIf","z"==e.key[0]),t.xp6(1),t.hij(" ",e.value," ")}}const Kt=function(n){return{ID:n}};function zt(n,i){if(1&n&&(t.TgZ(0,"td")(1,"a",36),t._uU(2),t.qZA()()),2&n){const e=i.$implicit,o=t.oxw().$implicit;t.xp6(1),t.Q6J("queryParams",t.VKq(2,Kt,o.ID)),t.xp6(1),t.Oqu(e.value)}}function Xt(n,i){if(1&n&&(t.TgZ(0,"tr"),t.YNc(1,zt,3,4,"td",24),t.ALo(2,"keys"),t.qZA()),2&n){const e=i.$implicit;t.xp6(1),t.Q6J("ngForOf",t.lcZ(2,1,e))}}function te(n,i){1&n&&t._UZ(0,"td",39)}function ee(n,i){if(1&n&&(t.ynx(0),t.YNc(1,te,1,0,"td",38),t.BQk()),2&n){const e=i.$implicit;t.xp6(1),t.Q6J("ngIf","z"!=e.key[0]&&"U"!=e.key[0])}}function ne(n,i){if(1&n&&(t.TgZ(0,"td"),t._uU(1),t.ALo(2,"number"),t.qZA()),2&n){const e=i.$implicit;t.xp6(1),t.hij(" ",t.lcZ(2,1,e.Quantity)," ")}}function ae(n,i){if(1&n&&(t.TgZ(0,"tfoot")(1,"tr",37),t.YNc(2,ee,2,1,"ng-container",24),t.ALo(3,"keys"),t.YNc(4,ne,3,3,"td",24),t.TgZ(5,"td"),t._uU(6),t.ALo(7,"number"),t.qZA(),t._UZ(8,"td"),t.qZA()()),2&n){const e=t.oxw(3);t.xp6(2),t.Q6J("ngForOf",t.lcZ(3,3,null==e.data?null:e.data.dataheader[0])),t.xp6(2),t.Q6J("ngForOf",e.Entities),t.xp6(2),t.hij(" ",t.lcZ(7,5,e.data.Total)," ")}}function oe(n,i){if(1&n){const e=t.EpF();t.TgZ(0,"span",40),t.NdJ("click",function(){return t.CHM(e),t.oxw(3).StoreRowsCountAPIResult("Inventory/InventoryOutletRowsCount")}),t.TgZ(1,"i",41),t._uU(2,"?"),t.qZA()()}}function ie(n,i){if(1&n&&(t.TgZ(0,"span"),t._uU(1),t.ALo(2,"number"),t.qZA()),2&n){const e=t.oxw(3);t.xp6(1),t.Oqu(t.lcZ(2,1,e.listTotal))}}function re(n,i){if(1&n){const e=t.EpF();t.TgZ(0,"a",42),t.NdJ("click",function(){return t.CHM(e),t.oxw(3).NextPage(!0)}),t._UZ(1,"i",43),t._uU(2," Next"),t.qZA()}}function le(n,i){if(1&n){const e=t.EpF();t.TgZ(0,"a",44),t.NdJ("click",function(){return t.CHM(e),t.oxw(3).StoreRowsCountAPIResult("Inventory/InventoryOutletRowsCount",!0)}),t._UZ(1,"i",45),t._uU(2," Last"),t.qZA()}}function _e(n,i){if(1&n){const e=t.EpF();t.TgZ(0,"div",19)(1,"div",20)(2,"table",21),t.NdJ("matSortChange",function(a){return t.CHM(e),t.oxw(2).sortData(a)}),t.TgZ(3,"thead",22)(4,"tr"),t.YNc(5,$t,3,5,"th",23),t.ALo(6,"keys"),t.qZA()(),t.TgZ(7,"tbody"),t.YNc(8,Xt,3,3,"tr",24),t.qZA(),t.YNc(9,ae,9,7,"tfoot",25),t.qZA()(),t.TgZ(10,"div",26)(11,"div",27)(12,"div",28),t._uU(13),t.ALo(14,"number"),t.YNc(15,oe,3,0,"span",29),t.YNc(16,ie,3,3,"span",25),t._uU(17),t.qZA()(),t.TgZ(18,"div",30),t.YNc(19,re,3,0,"a",31),t.YNc(20,le,3,0,"a",32),t.qZA()()()}if(2&n){const e=t.oxw(2);t.xp6(5),t.Q6J("ngForOf",t.lcZ(6,9,null==e.data?null:e.data.dataheader[0])),t.xp6(3),t.Q6J("ngForOf",e.infiniteList),t.xp6(1),t.Q6J("ngIf",(null==e.data?null:e.data.Data.length)>0),t.xp6(4),t.hij(" Showing 1 - ",t.lcZ(14,11,e.pageData.Filter.RowCount*(e.pageData.Filter.PageNumber-1)+e.data.TotalCurrentRow)," of "),t.xp6(2),t.Q6J("ngIf",!e.pageData.HideStoreApiCount),t.xp6(1),t.Q6J("ngIf",e.pageData.HideStoreApiCount),t.xp6(1),t.hij(" records ~ ",e.pageData.Filter.PageNumber," Page "),t.xp6(2),t.Q6J("ngIf",e.nextPageDisabled&&!e.goToLast),t.xp6(1),t.Q6J("ngIf",e.nextPageDisabled&&!e.goToLast)}}const ce=function(){return["/menu/Inventory/Quantity/Product_By_Outlet/Product_By_Outlet_Group"]},de=function(){return["/menu/Inventory/Quantity/Product_By_Outlet/Category_By_Outlet"]};function se(n,i){if(1&n){const e=t.EpF();t.TgZ(0,"mainpanel-cmp",1),t.NdJ("textChange",function(a){return t.CHM(e),t.oxw().pageData.Filter.FilterText=a})("onSubmit",function(){return t.CHM(e),t.oxw().searchFromPageOne()}),t.TgZ(1,"actions")(2,"a",2),t.NdJ("click",function(){t.CHM(e);const a=t.oxw();return a.exportCSV(a.csvConverter,"InventoryExport/OutletProductList","InventoryByOutlet.csv")}),t._UZ(3,"i",3),t._uU(4,"\xa0Export "),t.qZA(),t.TgZ(5,"div",4)(6,"a",5),t._uU(7," Product by Outlet Group"),t.qZA(),t._UZ(8,"button",6),t.TgZ(9,"ul",7)(10,"li",8)(11,"a",9),t._uU(12,"Category by Outlet"),t.qZA()()()()(),t.TgZ(13,"filters")(14,"div",10)(15,"div")(16,"h6"),t._uU(17,"Outlet"),t.qZA(),t.TgZ(18,"ng-select",11),t.NdJ("ngModelChange",function(a){return t.CHM(e),t.oxw().pageData.Filter.ListEntityID=a}),t.qZA()(),t.TgZ(19,"div")(20,"h6"),t._uU(21,"Category"),t.qZA(),t.TgZ(22,"ng-select",12),t.NdJ("ngModelChange",function(a){return t.CHM(e),t.oxw().pageData.Filter.CategoryID=a}),t.YNc(23,jt,2,2,"ng-template",13),t.qZA()(),t.TgZ(24,"div")(25,"h6"),t._uU(26,"Quantity From"),t.qZA(),t.TgZ(27,"input",14),t.NdJ("ngModelChange",function(a){return t.CHM(e),t.oxw().pageData.Filter.QuantityFrom=a}),t.qZA()(),t.TgZ(28,"div")(29,"h6"),t._uU(30,"Outlet Group"),t.qZA(),t.TgZ(31,"ng-select",15),t.NdJ("ngModelChange",function(a){return t.CHM(e),t.oxw().pageData.Filter.EntityGroupID=a}),t.qZA()(),t.TgZ(32,"div")(33,"h6"),t._uU(34,"Discontinued"),t.qZA(),t.TgZ(35,"radio-options",16),t.NdJ("modelChange",function(a){return t.CHM(e),t.oxw().pageData.Filter.Discontinued=a}),t.qZA()()()(),t.TgZ(36,"content"),t.YNc(37,_e,21,13,"div",17),t.qZA()()}if(2&n){const e=t.oxw();t.Q6J("pageData",e.menuData)("text",e.pageData.Filter.FilterText),t.xp6(2),t.Q6J("hidden",!e.pageData.HasRoleExport),t.xp6(4),t.Q6J("routerLink",t.DdM(15,ce)),t.xp6(5),t.Q6J("routerLink",t.DdM(16,de)),t.xp6(7),t.Q6J("multiple",!0)("items",null==e.pageData.Options?null:e.pageData.Options.Entities)("ngModel",e.pageData.Filter.ListEntityID),t.xp6(4),t.Q6J("items",null==e.pageData.Options?null:e.pageData.Options.Categories)("ngModel",e.pageData.Filter.CategoryID),t.xp6(5),t.Q6J("ngModel",e.pageData.Filter.QuantityFrom),t.xp6(4),t.Q6J("items",null==e.pageData.Options?null:e.pageData.Options.EntityGroups)("ngModel",e.pageData.Filter.EntityGroupID),t.xp6(4),t.Q6J("model",e.pageData.Filter.Discontinued),t.xp6(2),t.Q6J("ngIf",e.data)}}let ge=(()=>{class n extends D.X{constructor(e,o,a){super(e,"Inventory/OutletProductList","InventoryLoader/OutletProductList",o),this.httpService=e,this.csvConverter=a,this.Entities=[],this.isScroll=!1}assignAggregate(e){this.Entities=e.Entities}postExtendData(e){for(let o of this.Entities){const a=e.Entities.find(r=>r.ID==o.ID);a&&(o.Quantity+=a.Quantity)}}toggleTooltipPosition(){this.isScroll=document.documentElement.scrollTop>=40}preInitList(){this.oldRowCount=this.pageData.Filter.RowCount}sortData(e){const o=this.data.dataheader[0];if(o){const a=Object.keys(o),r=this.infiniteList.slice();if(!e.active||""===e.direction)return void(this.infiniteList=this.originalData);this.infiniteList=r.sort((p,v)=>{const P="asc"===e.direction;p.Code=null==p.Code?"":p.Code,v.Code=null==v.Code?"":v.Code,p.UOM=null==p.UOM?"":p.UOM,v.UOM=null==v.UOM?"":v.UOM;let S=0;return a.forEach(J=>{e.active==J&&(S="string"==typeof p[J]?this.compare(p[J].toLocaleLowerCase(),v[J].toLocaleLowerCase(),P):this.compare(p[J],v[J],P))}),S})}}}return n.\u0275fac=function(e){return new(e||n)(t.Y36(d.O),t.Y36(w._W),t.Y36(C.O))},n.\u0275cmp=t.Xpm({type:n,selectors:[["POS-by-outlet-detail"]],hostBindings:function(e,o){1&e&&t.NdJ("scroll",function(){return o.toggleTooltipPosition()},!1,t.Jf7)},features:[t.qOj],decls:1,vars:1,consts:[["filterWidth","270px",3,"pageData","text","textChange","onSubmit",4,"ngIf"],["filterWidth","270px",3,"pageData","text","textChange","onSubmit"],["title","Export",1,"btn","btn-outline-secondary",3,"hidden","click"],[1,"fa","fa-upload"],[1,"btn-group","ms-8"],["role","button",1,"btn","btn-outline-secondary",3,"routerLink"],["data-bs-toggle","dropdown","aria-expanded","false",1,"btn","btn-outline-secondary","btn-sm","dropdown-toggle"],[1,"dropdown-menu","dropdown-menu-end",2,"cursor","pointer"],[1,"dropdown-item"],[3,"routerLink"],["container","",1,"w-100"],["bindLabel","Name","bindValue","ID","placeholder","Choose an Outlet",3,"multiple","items","ngModel","ngModelChange"],["bindLabel","Value","bindValue","Key","placeholder","Choose...",3,"items","ngModel","ngModelChange"],["ng-option-tmp",""],["type","text","name","QuantityFrom",1,"w-100",3,"ngModel","ngModelChange"],["bindLabel","Name","bindValue","ID","placeholder","Choose...",3,"items","ngModel","ngModelChange"],["name","Discontinued",3,"model","modelChange"],["class","container-fluid mt-3",4,"ngIf"],[3,"title"],[1,"container-fluid","mt-3"],[1,"table-responsive"],["id","tableGrid","matSort","",1,"table","hidden-xxs",3,"matSortChange"],[1,"thead-light","sticky-top-thead"],[3,"ttip","mat-sort-header",4,"ngFor","ngForOf"],[4,"ngFor","ngForOf"],[4,"ngIf"],[1,"d-flex","justify-content-between","mt-5"],[1,"me-auto","d-sm-block","collapse","mt-3"],[1,"fw-bold","fst-italic","hidden-xxs"],["style","cursor:pointer",3,"click",4,"ngIf"],[1,"btn-group"],["role","button","class","btn btn-outline-secondary btn-sm text-primary","title","Load more for 500 variants",3,"click",4,"ngIf"],["role","button","class","btn btn-outline-secondary btn-sm text-primary","title","Load all products",3,"click",4,"ngIf"],[3,"mat-sort-header"],["class","tooltiptext",3,"class",4,"ngIf"],[1,"tooltiptext"],["routerLink","/menu/Products/Catalog/Variants/Info",2,"color","black",3,"queryParams"],[1,"table-footer"],["class","empty-column",4,"ngIf"],[1,"empty-column"],[2,"cursor","pointer",3,"click"],["title","Retreive rows count",1,"border","p-3"],["role","button","title","Load more for 500 variants",1,"btn","btn-outline-secondary","btn-sm","text-primary",3,"click"],[1,"fa-solid","fa-arrow-right"],["role","button","title","Load all products",1,"btn","btn-outline-secondary","btn-sm","text-primary",3,"click"],[1,"fa-solid","fa-share"]],template:function(e,o){1&e&&t.YNc(0,se,38,17,"mainpanel-cmp",0),2&e&&t.Q6J("ngIf",o.pageData.Filter)},directives:[_.O5,g.p,x.yS,f.w9,l.JJ,l.On,f.ir,l.Fj,M.P,h.YE,_.sg,h.nU],pipes:[F.VO,_.JJ],styles:['.table[_ngcontent-%COMP%] tbody[_ngcontent-%COMP%] tr[_ngcontent-%COMP%] td[_ngcontent-%COMP%]:last-child {\n display: none;\n}\n\n.table[_ngcontent-%COMP%] tbody[_ngcontent-%COMP%] tr[_ngcontent-%COMP%] td[_ngcontent-%COMP%]:first-child {\n color: blue !important;\n}\n\n.ttip[_ngcontent-%COMP%] .tooltiptext[_ngcontent-%COMP%] {\n visibility: hidden;\n width: 120px;\n background-color: black;\n color: #fff;\n text-align: center;\n border-radius: 6px;\n padding: 5px 0;\n position: absolute;\n z-index: 9999;\n left: 50%;\n margin-left: -60px;\n}\n\n.ttip-before-scroll[_ngcontent-%COMP%] {\n bottom: 200%;\n}\n\n.ttip-before-scroll[_ngcontent-%COMP%]:after {\n content: "";\n position: absolute;\n top: 100%;\n left: 50%;\n margin-left: -5px;\n border-width: 5px;\n border-style: solid;\n border-color: black transparent transparent transparent;\n}\n\n.ttip-after-scroll[_ngcontent-%COMP%] {\n top: 200%;\n}\n\n.ttip-after-scroll[_ngcontent-%COMP%]:after {\n content: " ";\n position: absolute;\n bottom: 100%;\n left: 50%;\n margin-left: -5px;\n border-width: 5px;\n border-style: solid;\n border-color: transparent transparent black transparent;\n}\n\n.ttip[_ngcontent-%COMP%]:hover .tooltiptext[_ngcontent-%COMP%] {\n visibility: visible;\n}']}),n})();function me(n,i){if(1&n){const e=t.EpF();t.TgZ(0,"div",11)(1,"div")(2,"h6"),t._uU(3,"Discontinued"),t.qZA(),t.TgZ(4,"radio-options",12),t.NdJ("modelChange",function(a){return t.CHM(e),t.oxw().pageData.Filter.DisplayDiscontinue=a}),t.qZA()()()}if(2&n){const e=t.oxw();t.xp6(4),t.Q6J("model",e.pageData.Filter.DisplayDiscontinue)}}function xe(n,i){if(1&n&&(t.TgZ(0,"th"),t._uU(1),t.qZA()),2&n){const e=i.$implicit;t.xp6(1),t.Oqu(e.value)}}function he(n,i){if(1&n&&(t.TgZ(0,"p",20),t._uU(1),t.qZA()),2&n){const e=t.oxw().$implicit;t.xp6(1),t.Oqu(e.value)}}function fe(n,i){if(1&n&&(t.TgZ(0,"p",20),t._uU(1),t.ALo(2,"number"),t.qZA()),2&n){const e=t.oxw().$implicit;t.xp6(1),t.Oqu(t.lcZ(2,1,e.value))}}function Ce(n,i){if(1&n&&(t.TgZ(0,"td"),t.YNc(1,he,2,1,"p",19),t.YNc(2,fe,3,3,"p",19),t.qZA()),2&n){const e=i.$implicit;t.xp6(1),t.Q6J("ngIf","Category"==e.key),t.xp6(1),t.Q6J("ngIf","Category"!=e.key)}}function ye(n,i){if(1&n&&(t.TgZ(0,"tr"),t.YNc(1,Ce,3,2,"td",17),t.ALo(2,"keys"),t.qZA()),2&n){const e=i.$implicit;t.xp6(1),t.Q6J("ngForOf",t.lcZ(2,1,e))}}function Ze(n,i){if(1&n&&(t.TgZ(0,"td"),t._uU(1),t.ALo(2,"number"),t.qZA()),2&n){const e=i.$implicit;t.xp6(1),t.Oqu(t.lcZ(2,1,e.value))}}function Te(n,i){if(1&n&&(t.TgZ(0,"tfoot")(1,"tr",21)(2,"td"),t._uU(3,"Total : "),t.qZA(),t.YNc(4,Ze,3,3,"td",17),t.ALo(5,"keys"),t.qZA()()),2&n){const e=t.oxw(2);t.xp6(4),t.Q6J("ngForOf",t.lcZ(5,1,null==e.data?null:e.data.Sum))}}function ve(n,i){if(1&n&&(t.TgZ(0,"div",13)(1,"div",14)(2,"table",15)(3,"thead",16)(4,"tr"),t.YNc(5,xe,2,1,"th",17),t.ALo(6,"keys"),t.qZA()(),t.TgZ(7,"tbody"),t.YNc(8,ye,3,3,"tr",17),t.qZA(),t.YNc(9,Te,6,3,"tfoot",18),t.qZA()()()),2&n){const e=t.oxw();t.xp6(5),t.Q6J("ngForOf",t.lcZ(6,3,null==e.data?null:e.data.Dataheader)),t.xp6(3),t.Q6J("ngForOf",null==e.data?null:e.data.Data),t.xp6(1),t.Q6J("ngIf",(null==e.data?null:e.data.Data.length)>0)}}const De=function(){return["/menu/Inventory/Quantity/Product_By_Outlet"]},Ie=function(){return["/menu/Inventory/Quantity/Product_By_Outlet/Product_By_Outlet_Group"]};let be=(()=>{class n extends A.n{constructor(e,o,a){super(e,"Inventory/GetCategoryByOutlet","InventoryLoader/OutletProductList",o),this.httpService=e,this.csvConverter=a}preInitList(){this.pageData.Filter.DisplayDiscontinue||(this.pageData.Filter={DisplayDiscontinue:!1})}}return n.\u0275fac=function(e){return new(e||n)(t.Y36(d.O),t.Y36(w._W),t.Y36(C.O))},n.\u0275cmp=t.Xpm({type:n,selectors:[["POS-Category_List_By_Outlet"]],features:[t.qOj],decls:17,vars:8,consts:[["filterWidth","270px",3,"pageData","text","textChange","onSubmit"],["role","button","value","Export","title","Export",1,"btn","btn-outline-secondary",3,"click"],["aria-hidden","true",1,"fa","fa-upload"],[1,"btn-group","ms-8"],["role","button",1,"btn","btn-outline-secondary",3,"routerLink"],["data-bs-toggle","dropdown",1,"btn","btn-outline-secondary","btn-sm","dropdown-toggle"],[1,"dropdown-menu","dropdown-menu-end",2,"cursor","pointer"],[1,"dropdown-item"],["role","button",3,"routerLink"],["container","","class","w-100",4,"ngIf"],["class","container-fluid mt-3",4,"ngIf"],["container","",1,"w-100"],["name","Discontinued",3,"model","modelChange"],[1,"container-fluid","mt-3"],[1,"table-responsive"],["id","tableGrid",1,"table"],[1,"table-light"],[4,"ngFor","ngForOf"],[4,"ngIf"],["style","color: black;",4,"ngIf"],[2,"color","black"],[1,"table-footer"]],template:function(e,o){1&e&&(t.TgZ(0,"mainpanel-cmp",0),t.NdJ("textChange",function(r){return o.pageData.Filter.FilterText=r})("onSubmit",function(){return o.searchFromPageOne()}),t.TgZ(1,"actions")(2,"a",1),t.NdJ("click",function(){return o.convertToCSV(o.csvConverter,!0,"InventoryCategoryListByOutlet.csv")}),t._UZ(3,"i",2),t._uU(4," Export "),t.qZA(),t.TgZ(5,"div",3)(6,"a",4),t._uU(7," Product by Outlet "),t.qZA(),t._UZ(8,"button",5),t.TgZ(9,"ul",6)(10,"li",7)(11,"a",8),t._uU(12," Product by Outlet Group "),t.qZA()()()()(),t.TgZ(13,"filters"),t.YNc(14,me,5,1,"div",9),t.qZA(),t.TgZ(15,"content"),t.YNc(16,ve,10,5,"div",10),t.qZA()()),2&e&&(t.Q6J("pageData",o.menuData)("text",o.pageData.Filter.FilterText),t.xp6(6),t.Q6J("routerLink",t.DdM(6,De)),t.xp6(5),t.Q6J("routerLink",t.DdM(7,Ie)),t.xp6(3),t.Q6J("ngIf",o.pageData.Filter),t.xp6(2),t.Q6J("ngIf",o.data))},directives:[g.p,x.yS,_.O5,M.P,_.sg],pipes:[F.VO,_.JJ],styles:[""]}),n})();function Oe(n,i){if(1&n&&(t.TgZ(0,"span",14),t._uU(1),t.qZA()),2&n){const e=i.item;t.s9C("title",e.Value),t.xp6(1),t.Oqu(e.Value)}}function qe(n,i){if(1&n){const e=t.EpF();t.TgZ(0,"div",5)(1,"div")(2,"h6"),t._uU(3,"Outlet"),t.qZA(),t.TgZ(4,"ng-select",6),t.NdJ("ngModelChange",function(a){return t.CHM(e),t.oxw().pageData.Filter.EntityID=a}),t.qZA()(),t.TgZ(5,"div")(6,"h6"),t._uU(7,"Category"),t.qZA(),t.TgZ(8,"ng-select",7),t.NdJ("ngModelChange",function(a){return t.CHM(e),t.oxw().pageData.Filter.CategoryID=a}),t.YNc(9,Oe,2,2,"ng-template",8),t.qZA()(),t.TgZ(10,"div")(11,"h6"),t._uU(12,"Row Count"),t.qZA(),t.TgZ(13,"input",9),t.NdJ("ngModelChange",function(a){return t.CHM(e),t.oxw().pageData.Filter.RowCount=a}),t.qZA()(),t.TgZ(14,"div")(15,"h6"),t._uU(16,"Quantity "),t.qZA(),t.TgZ(17,"input",10),t.NdJ("ngModelChange",function(a){return t.CHM(e),t.oxw().pageData.Filter.QtyForm=a}),t.qZA(),t._UZ(18,"i",11),t.TgZ(19,"input",12),t.NdJ("ngModelChange",function(a){return t.CHM(e),t.oxw().pageData.Filter.QtyTo=a}),t.qZA()(),t.TgZ(20,"div")(21,"h6"),t._uU(22,"Group By"),t.qZA(),t.TgZ(23,"radio-options",13),t.NdJ("modelChange",function(a){return t.CHM(e),t.oxw().pageData.Filter.CatalogLevel=a})("modelChange",function(){return t.CHM(e),t.oxw().getListData()}),t.qZA()()()}if(2&n){const e=t.oxw();t.xp6(4),t.Q6J("multiple",!0)("items",null==e.pageData.Options?null:e.pageData.Options.Entities)("ngModel",e.pageData.Filter.EntityID),t.xp6(4),t.Q6J("items",null==e.pageData.Options?null:e.pageData.Options.Categories)("ngModel",e.pageData.Filter.CategoryID),t.xp6(5),t.Q6J("ngModel",e.pageData.Filter.RowCount),t.xp6(4),t.Q6J("ngModel",e.pageData.Filter.QtyForm),t.xp6(2),t.Q6J("ngModel",e.pageData.Filter.QtyTo),t.xp6(4),t.Q6J("model",e.pageData.Filter.CatalogLevel)("options",e.ScopeFilter)}}const Me=function(){return["/menu/Products/Catalog/Products/Info"]},R=function(n){return{ID:n}};function we(n,i){if(1&n&&(t.TgZ(0,"td")(1,"a",29),t._uU(2),t.qZA()()),2&n){const e=t.oxw().$implicit;t.xp6(1),t.Q6J("routerLink",t.DdM(3,Me))("queryParams",t.VKq(4,R,e.ID)),t.xp6(1),t.Oqu(e.Name)}}const Fe=function(){return["/menu/Products/Catalog/Variants/Info"]};function Ue(n,i){if(1&n&&(t.TgZ(0,"td")(1,"a",29),t._uU(2),t.qZA()()),2&n){const e=t.oxw().$implicit;t.xp6(1),t.Q6J("routerLink",t.DdM(3,Fe))("queryParams",t.VKq(4,R,e.ID)),t.xp6(1),t.Oqu(e.Name)}}function Le(n,i){if(1&n&&(t.TgZ(0,"tr")(1,"td"),t._uU(2),t.qZA(),t.YNc(3,we,3,6,"td",27),t.YNc(4,Ue,3,6,"td",27),t.TgZ(5,"td"),t._uU(6),t.qZA(),t.TgZ(7,"td",28),t._uU(8),t.ALo(9,"number"),t.qZA(),t.TgZ(10,"td",28),t._uU(11),t.ALo(12,"number"),t.qZA(),t.TgZ(13,"td"),t._uU(14),t.qZA(),t.TgZ(15,"td"),t._uU(16),t.ALo(17,"date"),t.qZA()()),2&n){const e=i.$implicit,o=i.index,a=t.oxw(2);t.xp6(2),t.Oqu(o+1),t.xp6(1),t.Q6J("ngIf",a.pageData.Filter.CatalogLevel),t.xp6(1),t.Q6J("ngIf",!a.pageData.Filter.CatalogLevel),t.xp6(2),t.Oqu(e.Code),t.xp6(2),t.Oqu(t.lcZ(9,8,e.UnitsInStock)),t.xp6(3),t.Oqu(t.lcZ(12,10,e.TotalSold)),t.xp6(3),t.Oqu(e.LastPurchased),t.xp6(2),t.Oqu(t.xi3(17,12,e.Released,"dd MMM y"))}}function Je(n,i){if(1&n){const e=t.EpF();t.TgZ(0,"div",15)(1,"div",16)(2,"table",17),t.NdJ("matSortChange",function(a){return t.CHM(e),t.oxw().sortData(a)}),t.TgZ(3,"thead",18)(4,"tr")(5,"th",19),t._uU(6,"RANK"),t.qZA(),t.TgZ(7,"th",20),t._uU(8,"NAME"),t.qZA(),t.TgZ(9,"th",21),t._uU(10,"CODE"),t.qZA(),t.TgZ(11,"th",22),t._uU(12,"ON HAND"),t.qZA(),t.TgZ(13,"th",23),t._uU(14,"TOTAL SOLD"),t.qZA(),t.TgZ(15,"th",24),t._uU(16,"LAST PURCHASE"),t.qZA(),t.TgZ(17,"th",25),t._uU(18,"RELEASED"),t.qZA()()(),t.TgZ(19,"tbody"),t.YNc(20,Le,18,15,"tr",26),t.qZA()()()()}if(2&n){const e=t.oxw();t.xp6(20),t.Q6J("ngForOf",e.data)}}let Ne=(()=>{class n extends A.n{constructor(e,o){super(e,"Inventory/InventoryCountRank","InventoryLoader/InventoryCountRank"),this.httpService=e,this.csvConverter=o,this.ScopeFilter=[{Key:!0,Value:"Product"},{Key:!1,Value:"Variant"}]}postInit(){this.pageDatatemp=this.pageData,this.pageData.Filter.Text&&this.SearchProduct()}preGetList(){""==this.pageData.Filter.QtyTo&&delete this.pageData.Filter.QtyTo}SearchProduct(){null!=this.pageData.Filter.Text&&this.pageData.Filter.Text.length>=3?this.data=this.data.filter(e=>-1!==e.Name.toLowerCase().indexOf(this.pageData.Filter.Text.toLowerCase())):this.pageData=this.data}sortData(e){const o=this.pageData.slice();this.pageData=e.active&&""!==e.direction?o.sort((a,r)=>{const p="asc"===e.direction;switch(a.Code=null==a.Code?"":a.Code,r.Code=null==r.Code?"":r.Code,a.LastPurchased=null==a.LastPurchased?"":a.LastPurchased,r.LastPurchased=null==r.LastPurchased?"":r.LastPurchased,e.active){case"Rank":return this.compare(a.rank,r.rank,p);case"Name":return this.compare(a.Name.toLocaleLowerCase(),r.Name.toLocaleLowerCase(),p);case"Code":return this.compare(a.Code.toLocaleLowerCase(),r.Code.toLocaleLowerCase(),p);case"UnitsInStock":return this.compare(a.UnitsInStock,r.UnitsInStock,p);case"TotalSold":return this.compare(a.TotalSold,r.TotalSold,p);case"Released":return this.compare(a.Released,r.Released,p);case"LastPurchased":return this.compare(a.LastPurchased.toLocaleLowerCase(),r.LastPurchased.toLocaleLowerCase(),p);default:return 0}}):o}}return n.\u0275fac=function(e){return new(e||n)(t.Y36(d.O),t.Y36(C.O))},n.\u0275cmp=t.Xpm({type:n,selectors:[["POS-count-rank"]],features:[t.qOj],decls:9,vars:4,consts:[["filterWidth","270px",3,"pageData","text","textChange","onSubmit"],["role","button","value","Export","title","Export",1,"btn","btn-outline-secondary",3,"click"],["aria-hidden","true",1,"fa","fa-upload"],["container","","class","w-100",4,"ngIf"],["class","container-fluid mt-3",4,"ngIf"],["container","",1,"w-100"],["bindLabel","Name","bindValue","ID","placeholder","Choose...",1,"w-100",3,"multiple","items","ngModel","ngModelChange"],["bindLabel","Value","bindValue","Key","placeholder","Choose...",3,"items","ngModel","ngModelChange"],["ng-option-tmp",""],["type","text",3,"ngModel","ngModelChange"],["type","text","name","QtyForm",2,"width","40%","margin-right","10px",3,"ngModel","ngModelChange"],[1,"fa","fa-arrow-right"],["type","text","name","QtyTo",2,"width","40%","margin-left","10px",3,"ngModel","ngModelChange"],["name","Scope",3,"model","options","modelChange"],[3,"title"],[1,"container-fluid","mt-3"],[1,"table-responsive"],["id","tableGrid","matSort","",1,"table",3,"matSortChange"],[1,"thead-light","sticky-top-thead"],["mat-sort-header","Rank",2,"width","5px"],["mat-sort-header","Name",2,"width","400px"],["mat-sort-header","Code",2,"width","80px"],["mat-sort-header","UnitsInStock",1,"align-right",2,"width","80px"],["mat-sort-header","TotalSold",1,"align-right",2,"width","80px"],["mat-sort-header","LastPurchased",2,"width","80px"],["mat-sort-header","Released",2,"width","80px"],[4,"ngFor","ngForOf"],[4,"ngIf"],[1,"text-end","text-success"],[3,"routerLink","queryParams"]],template:function(e,o){1&e&&(t.TgZ(0,"mainpanel-cmp",0),t.NdJ("textChange",function(r){return o.pageData.Filter.Text=r})("onSubmit",function(){return o.searchFromPageOne()}),t.TgZ(1,"actions")(2,"a",1),t.NdJ("click",function(){return o.convertToCSV(o.csvConverter,o.data,"HighestQuantity.csv")}),t._UZ(3,"i",2),t._uU(4," Export "),t.qZA()(),t.TgZ(5,"filters"),t.YNc(6,qe,24,10,"div",3),t.qZA(),t.TgZ(7,"content"),t.YNc(8,Je,21,1,"div",4),t.qZA()()),2&e&&(t.Q6J("pageData",o.menuData)("text",o.pageData.Filter.Text),t.xp6(6),t.Q6J("ngIf",o.pageData.Filter),t.xp6(2),t.Q6J("ngIf",o.data))},directives:[g.p,_.O5,f.w9,l.JJ,l.On,f.ir,l.Fj,M.P,h.YE,h.nU,_.sg,x.yS],pipes:[_.JJ,_.uU],styles:[""]}),n})();var Se=c(26111),Q=c(58393);function Qe(n,i){if(1&n&&(t.TgZ(0,"span",26),t._uU(1),t.qZA()),2&n){const e=i.item;t.s9C("title",e.Value),t.xp6(1),t.Oqu(e.Value)}}function Pe(n,i){if(1&n&&(t.TgZ(0,"span"),t._uU(1),t.ALo(2,"number"),t.qZA()),2&n){const e=t.oxw(2).$implicit;t.xp6(1),t.hij("+ ",t.lcZ(2,1,e.Max-e.Inventory),"")}}const ke=function(){return["/menu/Products/Catalog/Variants/Info"]},Ee=function(n){return{ID:n}};function Be(n,i){if(1&n){const e=t.EpF();t.ynx(0),t.TgZ(1,"td")(2,"input",28),t.NdJ("ngModelChange",function(a){return t.CHM(e),t.oxw().$implicit.selected=a}),t.qZA()(),t.TgZ(3,"td"),t._uU(4),t.qZA(),t.TgZ(5,"td",29)(6,"a",30),t._uU(7),t.qZA()(),t.TgZ(8,"td"),t._uU(9),t.qZA(),t.TgZ(10,"td",31),t._uU(11),t.ALo(12,"number"),t.qZA(),t.TgZ(13,"td",32),t._uU(14),t.ALo(15,"number"),t.qZA(),t.TgZ(16,"td",33),t._uU(17),t.ALo(18,"number"),t.qZA(),t.TgZ(19,"td",34),t._uU(20),t.ALo(21,"number"),t.qZA(),t.TgZ(22,"td",33),t.YNc(23,Pe,3,3,"span",27),t.qZA(),t.BQk()}if(2&n){const e=t.oxw().$implicit;t.xp6(2),t.Q6J("ngModel",e.selected),t.xp6(2),t.hij(" ",e.Outlet," "),t.xp6(2),t.Q6J("routerLink",t.DdM(19,ke))("queryParams",t.VKq(20,Ee,e.ID)),t.xp6(1),t.Oqu(e.Product),t.xp6(2),t.hij(" ",e.Code," "),t.xp6(2),t.Oqu(t.lcZ(12,11,e.Inventory)),t.xp6(3),t.Oqu(t.lcZ(15,13,e.Min)),t.xp6(3),t.hij("+ ",t.lcZ(18,15,e.Min-e.Inventory),""),t.xp6(3),t.Oqu(t.lcZ(21,17,e.Max)),t.xp6(3),t.Q6J("ngIf",e.Max>e.Min)}}function Ve(n,i){if(1&n&&(t.TgZ(0,"tr"),t.YNc(1,Be,24,22,"ng-container",27),t.qZA()),2&n){const e=i.$implicit;t.xp6(1),t.Q6J("ngIf",e.Min-e.Inventory>0)}}function Ye(n,i){if(1&n){const e=t.EpF();t.TgZ(0,"mat-paginator",35),t.NdJ("page",function(a){return t.CHM(e),t.oxw(2).onPaginationChange(a)}),t.qZA()}if(2&n){const e=t.oxw(2);t.Q6J("length",e.pagination.listTotal)("pageSize",e.pagination.pageSize)("pageIndex",0==e.pageData.Filter.PageNumber?0:e.pageData.Filter.PageNumber-1)}}function He(n,i){if(1&n){const e=t.EpF();t.TgZ(0,"mainpanel-cmp",1),t.NdJ("textChange",function(a){return t.CHM(e),t.oxw().pageData.Filter.Text=a})("onSubmit",function(){return t.CHM(e),t.oxw().searchFromPageOne()}),t.TgZ(1,"actions")(2,"div")(3,"a",2),t.NdJ("click",function(){t.CHM(e);const a=t.oxw();return a.exportCSV(a.csvConverter,"InventoryExport/ReorderExportData","ReorderPoint.csv")}),t._UZ(4,"i",3),t._uU(5," Export "),t.qZA(),t.TgZ(6,"button",4),t.NdJ("click",function(){return t.CHM(e),t.oxw().makeLogistics()}),t._uU(7,"Make a Logistics"),t.qZA()()(),t.TgZ(8,"filters")(9,"div",5)(10,"div",6)(11,"div")(12,"h6"),t._uU(13,"Outlet"),t.qZA(),t.TgZ(14,"ng-select",7),t.NdJ("ngModelChange",function(a){return t.CHM(e),t.oxw().pageData.Filter.entityID=a}),t.qZA()(),t.TgZ(15,"div")(16,"h6"),t._uU(17,"Category"),t.qZA(),t.TgZ(18,"ng-select",8),t.NdJ("ngModelChange",function(a){return t.CHM(e),t.oxw().pageData.Filter.CategoryID=a}),t.YNc(19,Qe,2,2,"ng-template",9),t.qZA()(),t.TgZ(20,"div")(21,"h6"),t._uU(22,"Supplier"),t.qZA(),t.TgZ(23,"autocompleteV2",10),t.NdJ("ngModelChange",function(a){return t.CHM(e),t.oxw().pageData.Filter.SupplierID=a}),t.qZA()()()()(),t.TgZ(24,"content")(25,"div",11)(26,"div",12)(27,"table",13),t.NdJ("matSortChange",function(a){return t.CHM(e),t.oxw().sortData(a)}),t.TgZ(28,"thead",14)(29,"tr")(30,"th",15)(31,"input",16),t.NdJ("change",function(a){return t.CHM(e),t.oxw().onSelectAllData(a.target.checked)}),t.qZA()(),t.TgZ(32,"th",17),t._uU(33,"Outlet"),t.qZA(),t.TgZ(34,"th",18),t._uU(35,"Product"),t.qZA(),t.TgZ(36,"th",19),t._uU(37,"Code"),t.qZA(),t.TgZ(38,"th",20),t._uU(39,"On Hand"),t.qZA(),t.TgZ(40,"th",21),t._uU(41,"Buffer"),t.qZA(),t.TgZ(42,"th",22),t._uU(43,"Action"),t.qZA(),t.TgZ(44,"th",23),t._uU(45,"Threshold "),t.qZA(),t.TgZ(46,"th",22),t._uU(47,"Action"),t.qZA()()(),t.TgZ(48,"tbody"),t.YNc(49,Ve,2,1,"tr",24),t.qZA()()(),t.YNc(50,Ye,1,3,"mat-paginator",25),t.qZA()()()}if(2&n){const e=t.oxw();t.Q6J("pageData",e.menuData)("text",e.pageData.Filter.Text),t.xp6(6),t.Q6J("disabled",e.filterMakeLogistics()),t.xp6(8),t.Q6J("multiple",!0)("items",null==e.pageData.Options?null:e.pageData.Options.listEntity)("ngModel",e.pageData.Filter.entityID),t.xp6(4),t.Q6J("items",null==e.pageData.Options?null:e.pageData.Options.Categories)("ngModel",e.pageData.Filter.CategoryID),t.xp6(5),t.Q6J("ngModel",e.pageData.Filter.SupplierID),t.xp6(26),t.Q6J("ngForOf",e.data.Data),t.xp6(1),t.Q6J("ngIf",e.pagination.listTotal>0)}}let Re=(()=>{class n extends A.n{constructor(e,o,a,r){super(e,"Inventory/GetReorderList","InventoryLoader/Reorder"),this.csvConverter=o,this.cartItemService=a,this.router=r}postInit(e){this.originalData=e.Data}makeLogistics(){this.cartItemService.lowOnStock=!0,this.cartItemService.lowOnStockInfo.DeliveryOutletID=this.selectedData[0].EntityID,this.cartItemService.lowOnStockInfo.Items=this.selectedData,this.router.navigate(["/menu/Logistics/Archive/Transfer_Order/Form"])}filterMakeLogistics(){if(this.selectedData=this.data.Data.filter(e=>e.selected),this.selectedData.length>0){const e=this.selectedData[0].EntityID;return this.selectedData.filter(o=>o.EntityID==e).length!=this.selectedData.length}return!0}sortData(e){const o=this.data.Data.slice();this.data.Data=e.active&&""!==e.direction?o.sort((a,r)=>{const p="asc"===e.direction,v=typeof a[e.active];switch(s.gT.IsEmpty(a.Code)&&(a.Code=""),s.gT.IsEmpty(r.Code)&&(r.Code=""),v){case"string":return this.compare(a[e.active].toLocaleLowerCase(),r[e.active].toLocaleLowerCase(),p);case"number":return this.compare(a[e.active],r[e.active],p);default:return 0}}):this.originalData}}return n.\u0275fac=function(e){return new(e||n)(t.Y36(d.O),t.Y36(C.O),t.Y36(Se.N),t.Y36(x.F0))},n.\u0275cmp=t.Xpm({type:n,selectors:[["POS-rop"]],features:[t.qOj],decls:1,vars:1,consts:[[3,"pageData","text","textChange","onSubmit",4,"ngIf"],[3,"pageData","text","textChange","onSubmit"],[1,"btn","btn-outline-secondary",3,"click"],["aria-hidden","true",1,"fa","fa-upload"],[1,"btn","btn-success","ms-5",3,"disabled","click"],[1,"d-flex"],["container",""],["bindLabel","Name","bindValue","ID","placeholder","Choose...",3,"multiple","items","ngModel","ngModelChange"],["bindLabel","Value","bindValue","Key","placeholder","Choose...",3,"items","ngModel","ngModelChange"],["ng-option-tmp",""],["inputID","ContactID","requestUrl","/API/AC/GetSupplierSuggestion",1,"w-100",3,"ngModel","ngModelChange"],[1,"container-fluid","mt-3"],[1,"table-responsive"],["id","tableGrid","matSort","",1,"table","border-bottom",3,"matSortChange"],[1,"thead-light","sticky-top-thead"],[2,"width","32px"],["type","checkbox",3,"change"],["mat-sort-header","Outlet",2,"width","100px"],["mat-sort-header","Product"],["mat-sort-header","Code",2,"width","120px"],["mat-sort-header","Inventory",1,"text-end",2,"width","88px"],["mat-sort-header","Min",1,"align-right","border-start",2,"width","80px"],[1,"text-end",2,"width","80px"],["mat-sort-header","Max",1,"align-right","border-start",2,"width","80px"],[4,"ngFor","ngForOf"],[3,"length","pageSize","pageIndex","page",4,"ngIf"],[3,"title"],[4,"ngIf"],["type","checkbox",3,"ngModel","ngModelChange"],[1,"word-break-product"],[3,"routerLink","queryParams"],[1,"text-end","text-danger"],[1,"text-end","border-start"],[1,"text-end","text-success"],[1,"text-end","border-start","text-primary"],[3,"length","pageSize","pageIndex","page"]],template:function(e,o){1&e&&t.YNc(0,He,51,11,"mainpanel-cmp",0),2&e&&t.Q6J("ngIf",o.data)},directives:[_.O5,g.p,f.w9,l.JJ,l.On,f.ir,Q.J,h.YE,h.nU,_.sg,l.Wl,x.yS,I.NW],pipes:[_.JJ],styles:[".word-break-product[_ngcontent-%COMP%] {\n max-width: 22rem;\n word-wrap: break-word;\n}"]}),n})();var U=c(22313);function je(n,i){if(1&n){const e=t.EpF();t.TgZ(0,"div",14)(1,"div")(2,"h6"),t._uU(3,"Outlet"),t.qZA(),t.TgZ(4,"ng-select",15),t.NdJ("ngModelChange",function(a){return t.CHM(e),t.oxw(2).pageData.Filter.entityID=a}),t.qZA()(),t.TgZ(5,"div")(6,"h6"),t._uU(7,"Category"),t.qZA(),t.TgZ(8,"ng-select",16),t.NdJ("ngModelChange",function(a){return t.CHM(e),t.oxw(2).pageData.Filter.CategoryID=a}),t.qZA()()()}if(2&n){const e=t.oxw(2);t.xp6(4),t.Q6J("multiple",!0)("items",null==e.pageData.Options?null:e.pageData.Options.Entities)("ngModel",e.pageData.Filter.entityID),t.xp6(4),t.Q6J("items",null==e.pageData.Options?null:e.pageData.Options.Categories)("ngModel",e.pageData.Filter.CategoryID)}}const Ge=function(){return["/menu/Products/Catalog/Variants/Info"]},We=function(n){return{ID:n}};function $e(n,i){if(1&n&&(t.TgZ(0,"tr")(1,"td")(2,"a",17),t._uU(3),t.qZA()(),t.TgZ(4,"td"),t._uU(5),t.qZA(),t.TgZ(6,"td"),t._uU(7),t.qZA(),t.TgZ(8,"td",18),t._uU(9),t.qZA()()),2&n){const e=i.$implicit;t.xp6(2),t.Q6J("routerLink",t.DdM(6,Ge))("queryParams",t.VKq(7,We,e.ID)),t.xp6(1),t.Oqu(e.Name),t.xp6(2),t.Oqu(e.Code),t.xp6(2),t.Oqu(e.CategoryName),t.xp6(2),t.Oqu(e.UnitsInStock)}}function Ke(n,i){if(1&n){const e=t.EpF();t.TgZ(0,"mainpanel-cmp",1),t.NdJ("onSubmit",function(){return t.CHM(e),t.oxw().searchFromPageOne()}),t.TgZ(1,"actions")(2,"a",2),t.NdJ("click",function(){t.CHM(e);const a=t.oxw();return a.exportCSV(a.csvConverter,"Inventory/ExportInventoryTransit","Inventory In Transit.csv")}),t._UZ(3,"i",3),t._uU(4," Export "),t.qZA()(),t.TgZ(5,"filters"),t.YNc(6,je,9,5,"div",4),t.qZA(),t.TgZ(7,"content")(8,"div",5)(9,"div",6)(10,"table",7)(11,"thead",8)(12,"tr")(13,"th",9),t._uU(14,"Name"),t.qZA(),t.TgZ(15,"th",10),t._uU(16,"Code"),t.qZA(),t.TgZ(17,"th",11),t._uU(18,"Category"),t.qZA(),t.TgZ(19,"th",12),t._uU(20,"Transit"),t.qZA()()(),t.TgZ(21,"tbody"),t.YNc(22,$e,10,9,"tr",13),t.qZA()()()()()()}if(2&n){const e=t.oxw();t.Q6J("pageData",e.menuData)("hideSearchBox",!0),t.xp6(6),t.Q6J("ngIf",e.pageData.Filter),t.xp6(16),t.Q6J("ngForOf",null==e.data?null:e.data.Data)}}let ze=(()=>{class n extends A.n{constructor(e,o,a){super(e,"Inventory/GetInventoryTransit","InventoryLoader/GetInventoryTransit"),this.httpService=e,this.csvConverter=o,this.pageTitle=a,this.pageTitle.setTitle(this.menuData.T)}preInitList(){this.pageData.Filter={}}}return n.\u0275fac=function(e){return new(e||n)(t.Y36(d.O),t.Y36(C.O),t.Y36(U.Dx))},n.\u0275cmp=t.Xpm({type:n,selectors:[["POS-on-transit"]],features:[t.qOj],decls:1,vars:1,consts:[["filterWidth","270px",3,"pageData","hideSearchBox","onSubmit",4,"ngIf"],["filterWidth","270px",3,"pageData","hideSearchBox","onSubmit"],[1,"btn","btn-outline-secondary",3,"click"],[1,"fa","fa-upload"],["container","","class","w-100",4,"ngIf"],[1,"container-fluid","mt-3"],[1,"table-responsive"],[1,"table"],[1,"thead-light","sticky-top-thead"],[2,"width","70%"],[2,"width","7%"],[2,"width","12%"],[1,"text-end",2,"width","11%"],[4,"ngFor","ngForOf"],["container","",1,"w-100"],["bindLabel","Name","bindValue","ID","placeholder","Choose...",3,"multiple","items","ngModel","ngModelChange"],["bindLabel","Value","bindValue","Key","placeholder","Choose...",3,"items","ngModel","ngModelChange"],[3,"routerLink","queryParams"],[1,"text-end"]],template:function(e,o){1&e&&t.YNc(0,Ke,23,4,"mainpanel-cmp",0),2&e&&t.Q6J("ngIf",o.data)},directives:[_.O5,g.p,f.w9,l.JJ,l.On,_.sg,x.yS],styles:[""]}),n})();function Xe(n,i){if(1&n&&(t.TgZ(0,"span",9),t._uU(1),t.qZA()),2&n){const e=i.item;t.s9C("title",e.Value),t.xp6(1),t.Oqu(e.Value)}}function tn(n,i){if(1&n){const e=t.EpF();t.TgZ(0,"div",5)(1,"div")(2,"h6"),t._uU(3,"Outlet"),t.qZA(),t.TgZ(4,"ng-select",6),t.NdJ("ngModelChange",function(a){return t.CHM(e),t.oxw().pageData.Filter.EntityID=a}),t.qZA()(),t.TgZ(5,"div")(6,"h6"),t._uU(7,"Category"),t.qZA(),t.TgZ(8,"ng-select",7),t.NdJ("ngModelChange",function(a){return t.CHM(e),t.oxw().pageData.Filter.CategoryID=a}),t.YNc(9,Xe,2,2,"ng-template",8),t.qZA()()()}if(2&n){const e=t.oxw();t.xp6(4),t.Q6J("multiple",!0)("items",null==e.pageData.Options?null:e.pageData.Options.Entities)("ngModel",e.pageData.Filter.EntityID),t.xp6(4),t.Q6J("items",null==e.pageData.Options?null:e.pageData.Options.Categories)("ngModel",e.pageData.Filter.CategoryID)}}const en=function(){return["/menu/Products/Catalog/Variants/Info"]},nn=function(n){return{ID:n}},an=function(){return["/menu/Fulfillment/Allocated/Unfulfilled_Products"]},on=function(n,i){return{VariantID:n,OutletID:i}};function rn(n,i){if(1&n&&(t.TgZ(0,"tr")(1,"td")(2,"a",18),t._uU(3),t.qZA()(),t.TgZ(4,"td"),t._uU(5),t.qZA(),t.TgZ(6,"td"),t._uU(7),t.qZA(),t.TgZ(8,"td",19),t._uU(9),t.ALo(10,"number"),t.qZA(),t.TgZ(11,"td",19)(12,"a",20),t._uU(13),t.ALo(14,"number"),t.qZA()(),t.TgZ(15,"td",19),t._uU(16),t.ALo(17,"number"),t.qZA()()),2&n){const e=i.$implicit,o=t.oxw(2);t.xp6(2),t.Q6J("routerLink",t.DdM(16,en))("queryParams",t.VKq(17,nn,e.ID)),t.xp6(1),t.Oqu(e.Name),t.xp6(2),t.Oqu(e.Code),t.xp6(2),t.Oqu(e.CategoryName),t.xp6(2),t.Oqu(t.lcZ(10,10,e.I.OnHand)),t.xp6(3),t.Q6J("routerLink",t.DdM(19,an))("queryParams",t.WLB(20,on,e.ID,null==o.pageData||null==o.pageData.Filter?null:o.pageData.Filter.EntityID)),t.xp6(1),t.Oqu(t.lcZ(14,12,e.I.Allocated)),t.xp6(3),t.Oqu(t.lcZ(17,14,e.I.Available))}}function ln(n,i){if(1&n&&(t.TgZ(0,"div",10)(1,"div",11)(2,"table",12)(3,"thead",13)(4,"tr")(5,"th",14),t._uU(6,"Name"),t.qZA(),t.TgZ(7,"th",15),t._uU(8,"Code"),t.qZA(),t.TgZ(9,"th",15),t._uU(10,"Category"),t.qZA(),t.TgZ(11,"th",16),t._uU(12,"On Hand"),t.qZA(),t.TgZ(13,"th",16),t._uU(14,"Allocated"),t.qZA(),t.TgZ(15,"th",16),t._uU(16,"Available"),t.qZA()()(),t.TgZ(17,"tbody"),t.YNc(18,rn,18,23,"tr",17),t.qZA()()()()),2&n){const e=t.oxw();t.xp6(18),t.Q6J("ngForOf",e.data)}}let _n=(()=>{class n extends A.n{constructor(e,o,a){super(e,"Inventory/AllocatedInventory","InventoryLoader/AllocatedInventory",o),this.httpService=e,this.csvConverter=a}}return n.\u0275fac=function(e){return new(e||n)(t.Y36(d.O),t.Y36(w._W),t.Y36(C.O))},n.\u0275cmp=t.Xpm({type:n,selectors:[["allocated_inventory"]],features:[t.qOj],decls:9,vars:5,consts:[["filterWidth","270px",3,"pageData","hideSearchBox","onSubmit"],["role","button","value","Export","title","Export",1,"btn","btn-outline-secondary",3,"hidden","click"],["aria-hidden","true",1,"fa","fa-upload"],["container","","class","w-100",4,"ngIf"],["class","container-fluid mt-3",4,"ngIf"],["container","",1,"w-100"],["bindLabel","Name","bindValue","ID","placeholder","Choose...",1,"w-100",3,"multiple","items","ngModel","ngModelChange"],["bindLabel","Value","bindValue","Key","placeholder","Choose...",3,"items","ngModel","ngModelChange"],["ng-option-tmp",""],[3,"title"],[1,"container-fluid","mt-3"],[1,"table-responsive"],["id","tableGrid",1,"table","border-bottom"],[1,"thead-light","sticky-top-thead"],[2,"width","150px"],[2,"width","60px"],[1,"text-end",2,"width","60px"],[4,"ngFor","ngForOf"],[3,"routerLink","queryParams"],[1,"text-end"],["target","_blank",3,"routerLink","queryParams"]],template:function(e,o){1&e&&(t.TgZ(0,"mainpanel-cmp",0),t.NdJ("onSubmit",function(){return o.searchFromPageOne()}),t.TgZ(1,"actions")(2,"a",1),t.NdJ("click",function(){return o.convertToCSV(o.csvConverter,!0,"InventoryAllocated.csv")}),t._UZ(3,"i",2),t._uU(4," Export "),t.qZA()(),t.TgZ(5,"filters"),t.YNc(6,tn,10,5,"div",3),t.qZA(),t.TgZ(7,"content"),t.YNc(8,ln,19,1,"div",4),t.qZA()()),2&e&&(t.Q6J("pageData",o.menuData)("hideSearchBox",!0),t.xp6(2),t.Q6J("hidden",!o.pageData.IsExport),t.xp6(4),t.Q6J("ngIf",o.pageData.Filter),t.xp6(2),t.Q6J("ngIf",o.data))},directives:[g.p,_.O5,f.w9,l.JJ,l.On,f.ir,_.sg,x.yS],pipes:[_.JJ],encapsulation:2}),n})(),j=(()=>{class n{constructor(e){this.datePipe=e}ConvertDateSubTitle(e,o){return e.getMonth()==o.getMonth()&&e.getFullYear()==o.getFullYear()?`[${e.getDate()} - ${o.getDate()} ${this.datePipe.transform(e,"MMM yyyy")}]`:`[${this.datePipe.transform(e,"dd MMM yyyy")} - ${this.datePipe.transform(o,"dd MMM yyyy")}]`}}return n.\u0275fac=function(e){return new(e||n)(t.LFG(_.uU))},n.\u0275prov=t.Yz7({token:n,factory:n.\u0275fac,providedIn:"root"}),n})();var L=c(6553);function pn(n,i){if(1&n){const e=t.EpF();t.TgZ(0,"a",22),t.NdJ("click",function(){t.CHM(e);const a=t.oxw(2);return a.exportCSV(a.csvConverter,"Inventory/GetinventoryTrafficByCategory","CategorySummary.csv")}),t._UZ(1,"i",23),t._uU(2," Export "),t.qZA()}}function cn(n,i){1&n&&(t.TgZ(0,"th",13),t._uU(1,"Cost"),t.qZA())}function un(n,i){if(1&n&&(t.TgZ(0,"td",19),t._uU(1),t.ALo(2,"number"),t.qZA()),2&n){const e=t.oxw().$implicit;t.xp6(1),t.Oqu(t.xi3(2,1,e.Cost,"0.0-4"))}}function dn(n,i){if(1&n&&(t.TgZ(0,"tr")(1,"td"),t._uU(2),t.qZA(),t.TgZ(3,"td",18),t._uU(4),t.ALo(5,"number"),t.qZA(),t.TgZ(6,"td",19),t._uU(7),t.ALo(8,"number"),t.qZA(),t.YNc(9,un,3,4,"td",20),t.TgZ(10,"td",18),t._uU(11),t.ALo(12,"number"),t.qZA(),t.TgZ(13,"td",21),t._uU(14),t.ALo(15,"number"),t.qZA()()),2&n){const e=i.$implicit,o=t.oxw(2);t.xp6(2),t.Oqu(e.Name),t.xp6(2),t.Oqu(t.xi3(5,7,e.Sold,"0.0-4")),t.xp6(3),t.Oqu(t.xi3(8,10,e.Buy,"0.0-4")),t.xp6(2),t.Q6J("ngIf",o.pageData.HasRoleCost),t.xp6(2),t.Oqu(t.xi3(12,13,e.Adjust,"0.0-4")),t.xp6(2),t.Q6J("ngClass",e.Now>=0?"text-success":"text-danger"),t.xp6(1),t.Oqu(t.xi3(15,16,e.Now,"0.0-4"))}}function sn(n,i){if(1&n&&(t.TgZ(0,"td",19),t._uU(1),t.ALo(2,"number"),t.ALo(3,"sum"),t.qZA()),2&n){const e=t.oxw(2);t.xp6(1),t.Oqu(t.xi3(2,1,t.xi3(3,4,e.data.Data,"Cost"),"0.0-4"))}}function gn(n,i){if(1&n){const e=t.EpF();t.TgZ(0,"mainpanel-cmp",1),t.NdJ("onSubmit",function(){return t.CHM(e),t.oxw().searchFromPageOne()}),t.TgZ(1,"actions"),t.YNc(2,pn,3,0,"a",2),t.qZA(),t.TgZ(3,"filters")(4,"div",3)(5,"div")(6,"h6"),t._uU(7,"Outlet"),t.qZA(),t.TgZ(8,"ng-select",4),t.NdJ("ngModelChange",function(a){return t.CHM(e),t.oxw().pageData.Filter.EntityID=a}),t.qZA()(),t.TgZ(9,"div")(10,"h6"),t._uU(11,"Category"),t.qZA(),t.TgZ(12,"ng-select",5),t.NdJ("ngModelChange",function(a){return t.CHM(e),t.oxw().pageData.Filter.CategoryID=a}),t.qZA()(),t.TgZ(13,"div")(14,"h6"),t._uU(15,"From/To"),t.qZA(),t.TgZ(16,"datepicker",6),t.NdJ("dateChange",function(a){return t.CHM(e),t.oxw().pageData.Filter.From=a}),t.qZA(),t.TgZ(17,"datepicker",7),t.NdJ("dateChange",function(a){return t.CHM(e),t.oxw().pageData.Filter.To=a}),t.qZA()()()(),t.TgZ(18,"content")(19,"div",8)(20,"div",9)(21,"table",10),t.NdJ("matSortChange",function(a){return t.CHM(e),t.oxw().sortData(a)}),t.TgZ(22,"thead",11)(23,"tr")(24,"th",12),t._uU(25,"Name"),t.qZA(),t.TgZ(26,"th",13),t._uU(27,"Sold"),t.qZA(),t.TgZ(28,"th",13),t._uU(29,"Bought"),t.qZA(),t.YNc(30,cn,2,0,"th",14),t.TgZ(31,"th",13),t._uU(32,"Adjustment"),t.qZA(),t.TgZ(33,"th",13),t._uU(34,"On Hand"),t.qZA()()(),t.TgZ(35,"tbody"),t.YNc(36,dn,16,19,"tr",15),t.qZA(),t.TgZ(37,"tfoot")(38,"tr",16)(39,"td",17),t._uU(40,"Total:"),t.qZA(),t.TgZ(41,"td",18),t._uU(42),t.ALo(43,"number"),t.ALo(44,"sum"),t.qZA(),t.TgZ(45,"td",19),t._uU(46),t.ALo(47,"number"),t.ALo(48,"sum"),t.qZA(),t.YNc(49,sn,4,7,"td",20),t.TgZ(50,"td",18),t._uU(51),t.ALo(52,"number"),t.ALo(53,"sum"),t.qZA(),t.TgZ(54,"td",21),t.ALo(55,"sum"),t._uU(56),t.ALo(57,"number"),t.ALo(58,"sum"),t.qZA()()()()()()()()}if(2&n){const e=t.oxw();t.Q6J("pageData",e.menuData)("hideSearchBox",!0),t.xp6(2),t.Q6J("ngIf",e.pageData.HasRoleExport),t.xp6(6),t.Q6J("items",null==e.pageData.Options?null:e.pageData.Options.Entities)("multiple",!0)("ngModel",e.pageData.Filter.EntityID),t.xp6(4),t.Q6J("items",null==e.pageData.Options?null:e.pageData.Options.Categories)("ngModel",e.pageData.Filter.CategoryID),t.xp6(4),t.Q6J("isFloatingLabel",!1)("date",e.pageData.Filter.From),t.xp6(1),t.Q6J("isFloatingLabel",!1)("date",e.pageData.Filter.To),t.xp6(13),t.Q6J("ngIf",e.pageData.HasRoleCost),t.xp6(6),t.Q6J("ngForOf",e.data.Data),t.xp6(6),t.Oqu(t.xi3(43,20,t.xi3(44,23,e.data.Data,"Sold"),"0.0-4")),t.xp6(4),t.Oqu(t.xi3(47,26,t.xi3(48,29,e.data.Data,"Buy"),"0.0-4")),t.xp6(3),t.Q6J("ngIf",e.pageData.HasRoleCost),t.xp6(2),t.Oqu(t.xi3(52,32,t.xi3(53,35,e.data.Data,"Adjust"),"0.0-4")),t.xp6(3),t.Q6J("ngClass",t.xi3(55,38,e.data.Data,"Now")>=0?"text-success":"text-danger"),t.xp6(2),t.Oqu(t.xi3(57,41,t.xi3(58,44,e.data.Data,"Now"),"0.0-4"))}}let mn=(()=>{class n extends A.n{constructor(e,o,a,r){super(e,"Inventory/GetinventoryTrafficByCategory","InventoryLoader/GetEntitySummary"),this.httpService=e,this.csvConverter=o,this.pageTitle=a,this.converter=r,this.pageTitle.setTitle(this.menuData.T)}postInit(){this.data.Data=this.data.List,this.pageData.SubHeader=this.converter.ConvertDateSubTitle(new Date(this.pageData.Filter.From),new Date(this.pageData.Filter.To))}sortData(e){const o=this.data.Data.slice();this.data.Data=e.active&&""!==e.direction?o.sort((a,r)=>{const p="asc"===e.direction;return"Name"===e.active?this.compare(a.Name.toLocaleLowerCase(),r.Name.toLocaleLowerCase(),p):0}):o}}return n.\u0275fac=function(e){return new(e||n)(t.Y36(d.O),t.Y36(C.O),t.Y36(U.Dx),t.Y36(j))},n.\u0275cmp=t.Xpm({type:n,selectors:[["POS-rop"]],features:[t.qOj],decls:1,vars:1,consts:[["filterWidth","270px",3,"pageData","hideSearchBox","onSubmit",4,"ngIf"],["filterWidth","270px",3,"pageData","hideSearchBox","onSubmit"],["class","btn btn-outline-secondary",3,"click",4,"ngIf"],["container","",1,"w-100"],["bindLabel","Name","bindValue","ID","placeholder","Choose...",3,"items","multiple","ngModel","ngModelChange"],["bindLabel","Value","bindValue","Key","placeholder","Choose...",3,"items","ngModel","ngModelChange"],["placeholder","From","appearance","outline","name","From",3,"isFloatingLabel","date","dateChange"],["placeholder","To","appearance","outline","name","To",3,"isFloatingLabel","date","dateChange"],[1,"container-fluid","mt-3"],[1,"table-responsive"],["id","tableGrid","matSort","",1,"table","border-bottom",3,"matSortChange"],[1,"thead-light","sticky-top-thead"],["mat-sort-header","Name"],[1,"text-end",2,"width","10%"],["class","text-end","style","width: 10%",4,"ngIf"],[4,"ngFor","ngForOf"],[1,"table-footer"],[1,"text-end","empty-column"],[1,"text-end","text-success"],[1,"text-end","text-danger"],["class","text-end text-danger",4,"ngIf"],[1,"text-end",3,"ngClass"],[1,"btn","btn-outline-secondary",3,"click"],[1,"fa","fa-upload"]],template:function(e,o){1&e&&t.YNc(0,gn,59,47,"mainpanel-cmp",0),2&e&&t.Q6J("ngIf",o.data)},directives:[_.O5,g.p,f.w9,l.JJ,l.On,L.QB,h.YE,h.nU,_.sg,_.mk],pipes:[_.JJ,F.qU],styles:[""]}),n})();function xn(n,i){if(1&n){const e=t.EpF();t.TgZ(0,"a",23),t.NdJ("click",function(){t.CHM(e);const a=t.oxw(2);return a.exportCSV(a.csvConverter,"Inventory/StockTrafficEntityRecap","Stock Movement "+a.pageData.SubHeader+".csv")}),t._UZ(1,"i",24),t._uU(2," \xa0Export "),t.qZA()}}const hn=function(){return["/menu/Outlets/Master/Outlets/Form"]},fn=function(n){return{ID:n}},G=function(n,i){return{"text-danger":n,"text-success":i}};function Cn(n,i){if(1&n&&(t.TgZ(0,"tr")(1,"td")(2,"a",25),t._uU(3),t.qZA()(),t.TgZ(4,"td"),t._uU(5),t.qZA(),t.TgZ(6,"td",20),t._uU(7),t.ALo(8,"number"),t.qZA(),t.TgZ(9,"td",21),t._uU(10),t.ALo(11,"number"),t.qZA(),t.TgZ(12,"td",20),t._uU(13),t.ALo(14,"number"),t.qZA(),t.TgZ(15,"td",20),t._uU(16),t.ALo(17,"number"),t.qZA(),t.TgZ(18,"td",21),t._uU(19),t.ALo(20,"number"),t.qZA(),t.TgZ(21,"td",22),t._uU(22),t.ALo(23,"number"),t.qZA(),t.TgZ(24,"td",20),t._uU(25),t.ALo(26,"number"),t.qZA(),t.TgZ(27,"td",21),t._uU(28),t.ALo(29,"number"),t.qZA(),t.TgZ(30,"td",20),t._uU(31),t.ALo(32,"number"),t.qZA(),t.TgZ(33,"td",20),t._uU(34),t.ALo(35,"number"),t.qZA()()),2&n){const e=i.$implicit;t.xp6(2),t.Q6J("routerLink",t.DdM(45,hn))("queryParams",t.VKq(46,fn,e.ID)),t.xp6(1),t.Oqu(e.Name),t.xp6(2),t.Oqu(e.Code),t.xp6(2),t.Oqu(t.xi3(8,15,e.Start,"0.0-4")),t.xp6(3),t.Oqu(t.xi3(11,18,e.Sold,"0.0-4")),t.xp6(3),t.Oqu(t.xi3(14,21,e.Received,"0.0-4")),t.xp6(3),t.Oqu(t.xi3(17,24,e.TransferedIn,"0.0-4")),t.xp6(3),t.Oqu(t.xi3(20,27,e.TransferedOut,"0.0-4")),t.xp6(2),t.Q6J("ngClass",t.WLB(48,G,e.Adjustment<0,e.Adjustment>=0)),t.xp6(1),t.hij(" ",e.Adjustment<0?-1*e.Adjustment:t.xi3(23,30,e.Adjustment,"0.0-4"),""),t.xp6(3),t.Oqu(t.xi3(26,33,e.Produce,"0.0-4")),t.xp6(3),t.Oqu(t.xi3(29,36,e.Manufacture,"0.0-4")),t.xp6(3),t.Oqu(t.xi3(32,39,e.End,"0.0-4")),t.xp6(3),t.Oqu(t.xi3(35,42,e.Now,"0.0-4"))}}const Zn=function(){return["/menu/Inventory/Inventory_Traffic/Outlet_Inventory_Traffic/Outlet_Inventory_Traffic_Summary"]};function Tn(n,i){if(1&n){const e=t.EpF();t.TgZ(0,"mainpanel-cmp",1),t.NdJ("onSubmit",function(){return t.CHM(e),t.oxw().searchFromPageOne()}),t.TgZ(1,"actions"),t.YNc(2,xn,3,0,"a",2),t.TgZ(3,"a",3),t._uU(4,"Switch to Simple View"),t.qZA()(),t.TgZ(5,"filters")(6,"div",4)(7,"div")(8,"h6"),t._uU(9,"Outlet"),t.qZA(),t.TgZ(10,"ng-select",5),t.NdJ("ngModelChange",function(a){return t.CHM(e),t.oxw().pageData.Filter.EntityID=a}),t.qZA()(),t.TgZ(11,"div")(12,"h6"),t._uU(13,"Category"),t.qZA(),t.TgZ(14,"ng-select",6),t.NdJ("ngModelChange",function(a){return t.CHM(e),t.oxw().pageData.Filter.CategoryID=a}),t.qZA()(),t.TgZ(15,"div")(16,"h6"),t._uU(17,"From/To"),t.qZA(),t.TgZ(18,"datepicker",7),t.NdJ("dateChange",function(a){return t.CHM(e),t.oxw().pageData.Filter.From=a}),t.qZA(),t.TgZ(19,"datepicker",8),t.NdJ("dateChange",function(a){return t.CHM(e),t.oxw().pageData.Filter.To=a}),t.qZA()(),t.TgZ(20,"div")(21,"h6"),t._uU(22,"Exclude Complemantary Item"),t.qZA(),t.TgZ(23,"radio-options",9),t.NdJ("modelChange",function(a){return t.CHM(e),t.oxw().pageData.Filter.ExcludedTypeID=a}),t.qZA()()()(),t.TgZ(24,"content")(25,"div",10)(26,"div",11)(27,"table",12)(28,"thead",13)(29,"tr")(30,"th",14),t._uU(31,"Name"),t.qZA(),t.TgZ(32,"th",15),t._uU(33,"Code"),t.qZA(),t.TgZ(34,"th",16),t._uU(35,"Start"),t.qZA(),t.TgZ(36,"th",16),t._uU(37,"Sold"),t.qZA(),t.TgZ(38,"th",16),t._uU(39,"Bought"),t.qZA(),t.TgZ(40,"th",16),t._uU(41,"T.In"),t.qZA(),t.TgZ(42,"th",16),t._uU(43,"T.Out"),t.qZA(),t.TgZ(44,"th",16),t._uU(45,"Adjust"),t.qZA(),t.TgZ(46,"th",16),t._uU(47,"P"),t.qZA(),t.TgZ(48,"th",16),t._uU(49,"M"),t.qZA(),t.TgZ(50,"th",16),t._uU(51,"End"),t.qZA(),t.TgZ(52,"th",16),t._uU(53,"Now"),t.qZA()()(),t.TgZ(54,"tbody"),t.YNc(55,Cn,36,51,"tr",17),t.qZA(),t.TgZ(56,"tfoot")(57,"tr",18)(58,"th",19),t._uU(59,"Total:"),t.qZA(),t.TgZ(60,"td",20),t._uU(61),t.ALo(62,"number"),t.ALo(63,"sum"),t.qZA(),t.TgZ(64,"td",21),t._uU(65),t.ALo(66,"number"),t.ALo(67,"sum"),t.qZA(),t.TgZ(68,"td",20),t._uU(69),t.ALo(70,"number"),t.ALo(71,"sum"),t.qZA(),t.TgZ(72,"td",20),t._uU(73),t.ALo(74,"number"),t.ALo(75,"sum"),t.qZA(),t.TgZ(76,"td",21),t._uU(77),t.ALo(78,"number"),t.ALo(79,"sum"),t.qZA(),t.TgZ(80,"td",22),t.ALo(81,"sum"),t.ALo(82,"sum"),t._uU(83),t.ALo(84,"number"),t.ALo(85,"sum"),t.qZA(),t.TgZ(86,"td",20),t._uU(87),t.ALo(88,"number"),t.ALo(89,"sum"),t.qZA(),t.TgZ(90,"td",21),t._uU(91),t.ALo(92,"number"),t.ALo(93,"sum"),t.qZA(),t.TgZ(94,"td",20),t._uU(95),t.ALo(96,"number"),t.ALo(97,"sum"),t.qZA(),t.TgZ(98,"td",20),t._uU(99),t.ALo(100,"number"),t.ALo(101,"sum"),t.qZA()()()()()()()()}if(2&n){const e=t.oxw();t.Q6J("pageData",e.menuData)("hideSearchBox",!0),t.xp6(2),t.Q6J("ngIf",e.pageData.IsExport),t.xp6(1),t.Q6J("routerLink",t.DdM(92,Zn)),t.xp6(7),t.Q6J("items",null==e.pageData.Options?null:e.pageData.Options.Entities)("ngModel",e.pageData.Filter.EntityID),t.xp6(4),t.Q6J("items",null==e.pageData.Options?null:e.pageData.Options.Categories)("ngModel",e.pageData.Filter.CategoryID),t.xp6(4),t.Q6J("isFloatingLabel",!1)("date",e.pageData.Filter.From),t.xp6(1),t.Q6J("isFloatingLabel",!1)("date",e.pageData.Filter.To),t.xp6(4),t.Q6J("model",e.pageData.Filter.ExcludedTypeID)("options",e.ExcludedType),t.xp6(32),t.Q6J("ngForOf",e.data.Data),t.xp6(6),t.Oqu(t.xi3(62,26,t.xi3(63,29,e.data.Data,"Start"),"0.0-4")),t.xp6(4),t.Oqu(t.xi3(66,32,t.xi3(67,35,e.data.Data,"Sold"),"0.0-4")),t.xp6(4),t.Oqu(t.xi3(70,38,t.xi3(71,41,e.data.Data,"Received"),"0.0-4")),t.xp6(4),t.hij("",t.xi3(74,44,t.xi3(75,47,e.data.Data,"TransferedIn"),"0.0-4")," "),t.xp6(4),t.hij("",t.xi3(78,50,t.xi3(79,53,e.data.Data,"TransferedOut"),"0.0-4")," "),t.xp6(3),t.Q6J("ngClass",t.WLB(93,G,t.xi3(81,56,e.data.Data,"Adjustment")<0,t.xi3(82,59,e.data.Data,"Adjustment")>=0)),t.xp6(3),t.hij(" ",t.xi3(84,62,t.xi3(85,65,e.data.Data,"Adjustment"),"0.0-4"),""),t.xp6(4),t.Oqu(t.xi3(88,68,t.xi3(89,71,e.data.Data,"Produce"),"0.0-4")),t.xp6(4),t.Oqu(t.xi3(92,74,t.xi3(93,77,e.data.Data,"Manufacture"),"0.0-4")),t.xp6(4),t.Oqu(t.xi3(96,80,t.xi3(97,83,e.data.Data,"End"),"0.0-4")),t.xp6(4),t.Oqu(t.xi3(100,86,t.xi3(101,89,e.data.Data,"Now"),"0.0-4"))}}let vn=(()=>{class n extends A.n{constructor(e,o,a,r){super(e,"Inventory/StockTrafficEntityRecap","InventoryLoader/StockTrafficEntityRecap"),this.httpService=e,this.csvConverter=o,this.pageTitle=a,this.converter=r,this.adjTotal=0,this.ExcludedType=[{Key:0,Value:"Yes"},{Key:1,Value:"No"}],this.pageTitle.setTitle(this.menuData.T)}preGetList(){this.menuData.H="Outlet Inventory Traffic "+this.converter.ConvertDateSubTitle(new Date(this.pageData.Filter.From),new Date(this.pageData.Filter.To))}}return n.\u0275fac=function(e){return new(e||n)(t.Y36(d.O),t.Y36(C.O),t.Y36(U.Dx),t.Y36(j))},n.\u0275cmp=t.Xpm({type:n,selectors:[["POS-outlet-inventory-traffic"]],features:[t.qOj],decls:1,vars:1,consts:[["filterWidth","270px",3,"pageData","hideSearchBox","onSubmit",4,"ngIf"],["filterWidth","270px",3,"pageData","hideSearchBox","onSubmit"],["role","button","class","btn btn-outline-secondary me-6",3,"click",4,"ngIf"],["title","Switch to Simple View",1,"button","btn","btn-success",3,"routerLink"],["container","",1,"w-100"],["bindLabel","Name","bindValue","ID","placeholder","Choose...",3,"items","ngModel","ngModelChange"],["bindLabel","Value","bindValue","Key","placeholder","Choose...",3,"items","ngModel","ngModelChange"],["placeholder","From","appearance","outline","name","From",3,"isFloatingLabel","date","dateChange"],["placeholder","To","appearance","outline","name","To",3,"isFloatingLabel","date","dateChange"],["name","ExcludedTypeID",3,"model","options","modelChange"],[1,"container-fluid","mt-3"],[1,"table-responsive"],[1,"table","border-bottom"],[1,"thead-light","sticky-top-thead"],[2,"width","300px"],[2,"width","50px"],[1,"text-end",2,"width","50px"],[4,"ngFor","ngForOf"],[1,"table-footer"],["colspan","2",1,"empty-column","text-end"],[1,"text-end","text-success"],[1,"text-end","text-danger"],[1,"text-end",3,"ngClass"],["role","button",1,"btn","btn-outline-secondary","me-6",3,"click"],["aria-hidden","true",1,"fa-solid","fa-upload"],[3,"routerLink","queryParams"]],template:function(e,o){1&e&&t.YNc(0,Tn,102,96,"mainpanel-cmp",0),2&e&&t.Q6J("ngIf",o.data)},directives:[_.O5,g.p,x.yS,f.w9,l.JJ,l.On,L.QB,M.P,_.sg,_.mk],pipes:[_.JJ,F.qU],styles:[""]}),n})();function Dn(n,i){if(1&n){const e=t.EpF();t.TgZ(0,"div")(1,"h6"),t._uU(2,"Product"),t.qZA(),t.TgZ(3,"autocompleteV2",9),t.NdJ("ngModelChange",function(a){return t.CHM(e),t.oxw(2).pageData.Filter.ProductID=a}),t.qZA()()}if(2&n){const e=t.oxw(2);t.xp6(3),t.Q6J("ngModel",e.pageData.Filter.ProductID)}}function An(n,i){if(1&n){const e=t.EpF();t.TgZ(0,"div",3)(1,"div")(2,"h6"),t._uU(3,"Outlet"),t.qZA(),t.TgZ(4,"ng-select",4),t.NdJ("ngModelChange",function(a){return t.CHM(e),t.oxw().pageData.Filter.EntityID=a}),t.qZA()(),t.YNc(5,Dn,4,1,"div",5),t.TgZ(6,"div")(7,"h6"),t._uU(8,"From/To"),t.qZA(),t.TgZ(9,"datepicker",6),t.NdJ("dateChange",function(a){return t.CHM(e),t.oxw().pageData.Filter.From=a}),t.qZA(),t.TgZ(10,"datepicker",7),t.NdJ("dateChange",function(a){return t.CHM(e),t.oxw().pageData.Filter.To=a}),t.qZA()(),t.TgZ(11,"div")(12,"h6"),t._uU(13,"Note"),t.qZA(),t.TgZ(14,"input",8),t.NdJ("ngModelChange",function(a){return t.CHM(e),t.oxw().pageData.Filter.Notes=a}),t.qZA()()()}if(2&n){const e=t.oxw();t.xp6(4),t.Q6J("items",null==e.pageData.Options?null:e.pageData.Options.Entities)("ngModel",e.pageData.Filter.EntityID),t.xp6(1),t.Q6J("ngIf",e.pageData.Filter),t.xp6(4),t.Q6J("isFloatingLabel",!1)("date",e.pageData.Filter.From),t.xp6(1),t.Q6J("isFloatingLabel",!1)("date",e.pageData.Filter.To),t.xp6(4),t.Q6J("ngModel",e.pageData.Filter.Notes)}}const In=function(){return["/menu/Orders/Orders/Supplier_Bill/Info"]},bn=function(n){return{ID:n}};function On(n,i){if(1&n&&(t.TgZ(0,"tr")(1,"td"),t._uU(2),t.qZA(),t.TgZ(3,"td")(4,"a",24),t._uU(5),t.qZA()(),t.TgZ(6,"td"),t._uU(7),t.ALo(8,"date"),t.qZA(),t.TgZ(9,"td",25),t._uU(10),t.qZA(),t.TgZ(11,"td"),t._uU(12),t.qZA(),t.TgZ(13,"td"),t._uU(14),t.qZA(),t.TgZ(15,"td"),t._uU(16),t.qZA()()),2&n){const e=i.$implicit;t.xp6(2),t.Oqu(e.VariantName),t.xp6(2),t.Q6J("routerLink",t.DdM(12,In))("queryParams",t.VKq(13,bn,e.InvoiceID)),t.xp6(1),t.Oqu(e.Number),t.xp6(2),t.Oqu(t.xi3(8,9,e.Date,"dd MMM yyyy")),t.xp6(3),t.Oqu(e.LeftOverDisplay),t.xp6(2),t.Oqu(e.ProductionBatch),t.xp6(2),t.Oqu(e.ExpiredDate),t.xp6(2),t.Oqu(e.ExpiredDate)}}function qn(n,i){if(1&n){const e=t.EpF();t.TgZ(0,"mat-paginator",26),t.NdJ("page",function(a){return t.CHM(e),t.oxw(2).onPaginationChange(a)}),t.qZA()}if(2&n){const e=t.oxw(2);t.Q6J("length",e.pagination.listTotal)("pageSize",e.pagination.pageSize)("pageIndex",0==e.pageData.Filter.PageNumber?0:e.pageData.Filter.PageNumber-1)}}function Mn(n,i){if(1&n&&(t.TgZ(0,"div",10)(1,"div",11)(2,"table",12)(3,"thead",13)(4,"tr")(5,"th",14),t._uU(6,"Product"),t.qZA(),t.TgZ(7,"th",15),t._uU(8,"PO #"),t.qZA(),t.TgZ(9,"th",16),t._uU(10,"PO Date"),t.qZA(),t.TgZ(11,"th",17),t._uU(12,"Inventory X/Y"),t.qZA(),t.TgZ(13,"th",18),t._uU(14,"Production #"),t.qZA(),t.TgZ(15,"th",19),t._uU(16,"Expired"),t.qZA(),t.TgZ(17,"th",20),t._uU(18,"Note"),t.qZA()()(),t.TgZ(19,"tbody"),t.YNc(20,On,17,15,"tr",21),t.qZA()()(),t.TgZ(21,"div",22),t.YNc(22,qn,1,3,"mat-paginator",23),t.qZA()()),2&n){const e=t.oxw();t.xp6(20),t.Q6J("ngForOf",e.data.Data),t.xp6(2),t.Q6J("ngIf",e.pagination.listTotal>0)}}let wn=(()=>{class n extends A.n{constructor(e,o){super(e,"Inventory/FifoIlustration","InventoryLoader/FifoIlustration"),this.httpService=e,this.pageTitle=o,this.pageTitle.setTitle(this.pageData.Title)}}return n.\u0275fac=function(e){return new(e||n)(t.Y36(d.O),t.Y36(U.Dx))},n.\u0275cmp=t.Xpm({type:n,selectors:[["POS-FIFO_Illustration"]],features:[t.qOj],decls:6,vars:4,consts:[["filterWidth","270px",3,"pageData","hideSearchBox","onSubmit"],["container","","class","w-100",4,"ngIf"],["class","container-fluid mt-3",4,"ngIf"],["container","",1,"w-100"],["bindLabel","Name","bindValue","ID","placeholder","Choose...",3,"items","ngModel","ngModelChange"],[4,"ngIf"],["placeholder","From","appearance","outline","name","From",3,"isFloatingLabel","date","dateChange"],["placeholder","To","appearance","outline","name","To",3,"isFloatingLabel","date","dateChange"],["type","text",1,"ng-pristine","ng-valid","ng-empty","ng-touched",3,"ngModel","ngModelChange"],["inputID","productName","requestUrl","/API/AC/GetVariantSuggestionByCodeNName",1,"w-100",3,"ngModel","ngModelChange"],[1,"container-fluid","mt-3"],[1,"table-responsive"],["id","tableGrid","matSort","",1,"table"],[1,"thead-light","sticky-top-thead"],["mat-sort-header","VariantName"],["mat-sort-header","Number"],["mat-sort-header","Date"],["mat-sort-header","LeftOverDisplay",1,"align-right"],["mat-sort-header","ProductionBatch"],["mat-sort-header","ExpiredDate"],["mat-sort-header","Note"],[4,"ngFor","ngForOf"],[1,"mt-2"],[3,"length","pageSize","pageIndex","page",4,"ngIf"],[3,"routerLink","queryParams"],[1,"text-end"],[3,"length","pageSize","pageIndex","page"]],template:function(e,o){1&e&&(t.TgZ(0,"mainpanel-cmp",0),t.NdJ("onSubmit",function(){return o.searchFromPageOne()}),t._UZ(1,"actions"),t.TgZ(2,"filters"),t.YNc(3,An,15,8,"div",1),t.qZA(),t.TgZ(4,"content"),t.YNc(5,Mn,23,2,"div",2),t.qZA()()),2&e&&(t.Q6J("pageData",o.menuData)("hideSearchBox",!0),t.xp6(3),t.Q6J("ngIf",o.pageData.Filter),t.xp6(2),t.Q6J("ngIf",o.data))},directives:[g.p,_.O5,f.w9,l.JJ,l.On,Q.J,L.QB,l.Fj,h.YE,h.nU,_.sg,x.yS,I.NW],pipes:[_.uU],styles:[""]}),n})();function Fn(n,i){if(1&n){const e=t.EpF();t.TgZ(0,"a",17),t.NdJ("click",function(){t.CHM(e);const a=t.oxw(2);return a.exportCSV(a.csvConverter,"Adjustment/ExportNegativeInventory","Negative_Stock.csv")}),t._UZ(1,"i",18),t._uU(2," Export "),t.qZA()}}const Un=function(){return["/menu/Products/Catalog/Variants/Info"]},W=function(n){return{ID:n}},Ln=function(){return["/menu/Search/Main/Product/Stock_Log"]};function Jn(n,i){if(1&n&&(t.TgZ(0,"tr")(1,"td")(2,"a",19),t._uU(3),t.qZA()(),t.TgZ(4,"td"),t._uU(5),t.qZA(),t.TgZ(6,"td"),t._uU(7),t.qZA(),t.TgZ(8,"td",20),t._uU(9),t.qZA(),t.TgZ(10,"td",21),t._uU(11),t.qZA(),t.TgZ(12,"td",21)(13,"a",19),t._UZ(14,"i",22),t.qZA()()()),2&n){const e=i.$implicit;t.xp6(2),t.Q6J("routerLink",t.DdM(9,Un))("queryParams",t.VKq(10,W,e.ID)),t.xp6(1),t.Oqu(e.Name),t.xp6(2),t.Oqu(e.Code),t.xp6(2),t.Oqu(e.EntityName),t.xp6(2),t.Oqu(e.UnitsInStock),t.xp6(2),t.Oqu(e.UOMName),t.xp6(2),t.Q6J("routerLink",t.DdM(12,Ln))("queryParams",t.VKq(13,W,e.ID))}}function Nn(n,i){if(1&n){const e=t.EpF();t.TgZ(0,"mainpanel-cmp",1),t.NdJ("onSubmit",function(){return t.CHM(e),t.oxw().searchFromPageOne()}),t.TgZ(1,"actions"),t.YNc(2,Fn,3,0,"a",2),t.qZA(),t.TgZ(3,"filters")(4,"div",3)(5,"div")(6,"h6"),t._uU(7,"Outlet"),t.qZA(),t.TgZ(8,"ng-select",4),t.NdJ("ngModelChange",function(a){return t.CHM(e),t.oxw().pageData.Filter.EntityID=a}),t.qZA()(),t.TgZ(9,"div")(10,"h6"),t._uU(11,"Category"),t.qZA(),t.TgZ(12,"ng-select",5),t.NdJ("ngModelChange",function(a){return t.CHM(e),t.oxw().pageData.Filter.CategoryID=a}),t.qZA()()()(),t.TgZ(13,"content")(14,"div",6)(15,"div",7)(16,"table",8),t.NdJ("matSortChange",function(a){return t.CHM(e),t.oxw().sortData(a)}),t.TgZ(17,"thead",9)(18,"tr")(19,"th",10),t._uU(20,"Name"),t.qZA(),t.TgZ(21,"th",11),t._uU(22,"Code"),t.qZA(),t.TgZ(23,"th",12),t._uU(24,"Outlet"),t.qZA(),t.TgZ(25,"th",13),t._uU(26,"Unit Stock"),t.qZA(),t._UZ(27,"th",14)(28,"th",15),t.qZA()(),t.TgZ(29,"tbody"),t.YNc(30,Jn,15,15,"tr",16),t.qZA()()()()()()}if(2&n){const e=t.oxw();t.Q6J("pageData",e.menuData)("hideSearchBox",!0),t.xp6(2),t.Q6J("ngIf",e.pageData.IsExport),t.xp6(6),t.Q6J("items",null==e.pageData.Options?null:e.pageData.Options.Entities)("ngModel",e.pageData.Filter.EntityID),t.xp6(4),t.Q6J("items",null==e.pageData.Options?null:e.pageData.Options.Categories)("ngModel",e.pageData.Filter.CategoryID),t.xp6(18),t.Q6J("ngForOf",e.data.Data)}}let Sn=(()=>{class n extends A.n{constructor(e,o,a){super(e,"Adjustment/GetNegativeQuantity","InventoryLoader/InventoryReport"),this.httpService=e,this.pageTitle=o,this.csvConverter=a,this.pageTitle.setTitle(this.menuData.T)}sortData(e){const o=this.data.Data.slice();this.data.Data=e.active&&""!==e.direction?o.sort((a,r)=>{const p="asc"===e.direction;switch(null==a.Code&&(a.Code=""),null==r.Code&&(r.Code=""),e.active){case"Name":return this.compare(a.Name.toLocaleLowerCase(),r.Name.toLocaleLowerCase(),p);case"Code":return this.compare(a.Code.toLocaleLowerCase(),r.Code.toLocaleLowerCase(),p);default:return 0}}):o}}return n.\u0275fac=function(e){return new(e||n)(t.Y36(d.O),t.Y36(U.Dx),t.Y36(C.O))},n.\u0275cmp=t.Xpm({type:n,selectors:[["POS-negative_inventory"]],features:[t.qOj],decls:1,vars:1,consts:[["filterWidth","270px",3,"pageData","hideSearchBox","onSubmit",4,"ngIf"],["filterWidth","270px",3,"pageData","hideSearchBox","onSubmit"],["role","button","class","btn btn-outline-secondary",3,"click",4,"ngIf"],["container","",1,"w-100"],["bindLabel","Name","bindValue","ID","placeholder","Choose...",3,"items","ngModel","ngModelChange"],["bindLabel","Value","bindValue","Key","placeholder","Choose...",3,"items","ngModel","ngModelChange"],[1,"container-fluid","mt-5"],[1,"table-responsive"],["matSort","",1,"table","border-bottom","w-100",3,"matSortChange"],[1,"thead-light","sticky-top-thead"],["mat-sort-header","Name"],["mat-sort-header","Code",2,"width","70px"],[2,"width","70px"],[1,"text-end",2,"width","100px"],[1,"text-end",2,"width","50px"],[1,"text-end",2,"width","30px"],[4,"ngFor","ngForOf"],["role","button",1,"btn","btn-outline-secondary",3,"click"],[1,"fa","fa-upload"],[3,"routerLink","queryParams"],[1,"text-end","text-danger"],[1,"text-end"],["aria-hidden","true",1,"fa","fa-list-alt","fa-2x"]],template:function(e,o){1&e&&t.YNc(0,Nn,31,8,"mainpanel-cmp",0),2&e&&t.Q6J("ngIf",o.data)},directives:[_.O5,g.p,f.w9,l.JJ,l.On,h.YE,h.nU,_.sg,x.yS],styles:[""]}),n})();function Qn(n,i){if(1&n){const e=t.EpF();t.TgZ(0,"a",17),t.NdJ("click",function(){t.CHM(e);const a=t.oxw(2);return a.exportCSV(a.csvConverter,"InventoryExport/InventoryOrderByCompositeExport","InventoryComposite.csv")}),t._UZ(1,"i",18),t._uU(2," \xa0Export "),t.qZA()}}function Pn(n,i){if(1&n&&(t.TgZ(0,"tr")(1,"td"),t._uU(2),t.qZA(),t.TgZ(3,"td",19),t._uU(4),t.ALo(5,"number"),t.qZA()()),2&n){const e=i.$implicit;t.xp6(2),t.Oqu(e.Name),t.xp6(2),t.Oqu(t.lcZ(5,2,e.Quantity))}}function kn(n,i){if(1&n&&(t.TgZ(0,"tr")(1,"td"),t._uU(2),t.qZA(),t.TgZ(3,"td",19),t._uU(4),t.ALo(5,"number"),t.qZA()()),2&n){const e=i.$implicit;t.xp6(2),t.Oqu(e.Name),t.xp6(2),t.Oqu(t.lcZ(5,2,e.Quantity))}}function En(n,i){if(1&n){const e=t.EpF();t.TgZ(0,"mainpanel-cmp",1),t.NdJ("onSubmit",function(){return t.CHM(e),t.oxw().searchFromPageOne()}),t.TgZ(1,"actions"),t.YNc(2,Qn,3,0,"a",2),t.qZA(),t.TgZ(3,"filters")(4,"div",3)(5,"div",4)(6,"div")(7,"h6"),t._uU(8,"Outlet"),t.qZA(),t.TgZ(9,"ng-select",5),t.NdJ("ngModelChange",function(a){return t.CHM(e),t.oxw().pageData.Filter.EntityID=a}),t.qZA()(),t.TgZ(10,"div")(11,"h6"),t._uU(12),t.qZA(),t.TgZ(13,"datepicker",6),t.NdJ("dateChange",function(a){return t.CHM(e),t.oxw().pageData.Filter.CustomDateFrom=a}),t.qZA()(),t.TgZ(14,"div")(15,"h6"),t._uU(16),t.qZA(),t.TgZ(17,"datepicker",7),t.NdJ("dateChange",function(a){return t.CHM(e),t.oxw().pageData.Filter.CustomDateTo=a}),t.qZA()()()()(),t.TgZ(18,"content")(19,"div",8)(20,"div",9)(21,"div",10)(22,"h5",11),t._uU(23,"Product"),t.qZA()(),t.TgZ(24,"div",12)(25,"table",13)(26,"thead",14)(27,"tr")(28,"th"),t._uU(29,"Name"),t.qZA(),t.TgZ(30,"th",15),t._uU(31,"Quantity"),t.qZA()()(),t.TgZ(32,"tbody"),t.YNc(33,Pn,6,4,"tr",16),t.qZA()()()(),t.TgZ(34,"div",9)(35,"div",10)(36,"h5",11),t._uU(37,"Component"),t.qZA()(),t.TgZ(38,"div",12)(39,"table",13)(40,"thead",14)(41,"tr")(42,"th"),t._uU(43,"Name"),t.qZA(),t.TgZ(44,"th",15),t._uU(45,"Quantity"),t.qZA()()(),t.TgZ(46,"tbody"),t.YNc(47,kn,6,4,"tr",16),t.qZA()()()()()()()}if(2&n){const e=t.oxw();t.Q6J("pageData",e.menuData)("hideSearchBox",!0),t.xp6(2),t.Q6J("ngIf",null==e.pageData.Role?null:e.pageData.Role.Export),t.xp6(7),t.Q6J("items",null==e.pageData.Options?null:e.pageData.Options.Entities)("ngModel",e.pageData.Filter.EntityID),t.xp6(3),t.Oqu((e.pageData.CustomDateLabel||"Custom Date")+" From"),t.xp6(1),t.Q6J("isFloatingLabel",!1)("date",e.pageData.Filter.CustomDateFrom),t.xp6(3),t.Oqu((e.pageData.CustomDateLabel||"Custom Date")+" To"),t.xp6(1),t.Q6J("isFloatingLabel",!1)("date",e.pageData.Filter.CustomDateTo),t.xp6(16),t.Q6J("ngForOf",e.data.Data.Product),t.xp6(14),t.Q6J("ngForOf",e.data.Data.Composite)}}let Bn=(()=>{class n extends A.n{constructor(e,o,a){super(e,"Inventory/InventoryOrderByComposite","InventoryLoader/InventoryOrderByComposite"),this.httpService=e,this.csvConverter=o,this.pageTitle=a,this.pageTitle.setTitle(this.menuData.T)}}return n.\u0275fac=function(e){return new(e||n)(t.Y36(d.O),t.Y36(C.O),t.Y36(U.Dx))},n.\u0275cmp=t.Xpm({type:n,selectors:[["POS-Inventory-Order-By-Composite"]],features:[t.qOj],decls:1,vars:1,consts:[[3,"pageData","hideSearchBox","onSubmit",4,"ngIf"],[3,"pageData","hideSearchBox","onSubmit"],["class","btn btn-outline-secondary",3,"click",4,"ngIf"],[1,"d-flex"],["container",""],["bindLabel","Name","bindValue","ID","placeholder","Choose...",3,"items","ngModel","ngModelChange"],["placeholder","From","appearance","outline","name","From",3,"isFloatingLabel","date","dateChange"],["placeholder","To","appearance","outline","name","To",3,"isFloatingLabel","date","dateChange"],[1,"container-fluid","mt-3"],[1,"row","mt-7"],[1,"col-sm-2"],[1,"font-weigh-bold"],[1,"col-sm-10"],[1,"table"],[1,"thead-light","sticky-top-thead"],[1,"text-end",2,"width","100px"],[4,"ngFor","ngForOf"],[1,"btn","btn-outline-secondary",3,"click"],["aria-hidden","true",1,"fa-solid","fa-upload"],[1,"text-end"]],template:function(e,o){1&e&&t.YNc(0,En,48,13,"mainpanel-cmp",0),2&e&&t.Q6J("ngIf",o.data)},directives:[_.O5,g.p,f.w9,l.JJ,l.On,L.QB,_.sg],pipes:[_.JJ],encapsulation:2}),n})();const Vn=function(){return["/menu/Outlets/Master/Outlets/Form"]},Yn=function(n){return{ID:n}};function Hn(n,i){if(1&n&&(t.TgZ(0,"tr")(1,"td")(2,"a",22),t._uU(3),t.qZA()(),t.TgZ(4,"td"),t._uU(5),t.qZA(),t.TgZ(6,"td",20),t._uU(7),t.ALo(8,"number"),t.qZA(),t.TgZ(9,"td",20),t._uU(10),t.ALo(11,"number"),t.qZA(),t.TgZ(12,"td",21),t._uU(13),t.ALo(14,"number"),t.qZA(),t.TgZ(15,"td",20),t._uU(16),t.ALo(17,"number"),t.qZA(),t.TgZ(18,"td",20),t._uU(19),t.ALo(20,"number"),t.qZA()()),2&n){const e=i.$implicit;t.xp6(2),t.Q6J("routerLink",t.DdM(24,Vn))("queryParams",t.VKq(25,Yn,e.ID)),t.xp6(1),t.Oqu(e.Name),t.xp6(2),t.Oqu(e.Code),t.xp6(2),t.Oqu(t.xi3(8,9,e.Start,"0.0-4")),t.xp6(3),t.Oqu(t.xi3(11,12,e.InStock,"0.0-4")),t.xp6(3),t.Oqu(t.xi3(14,15,e.OutStock,"0.0-4")),t.xp6(3),t.Oqu(t.xi3(17,18,e.End,"0.0-4")),t.xp6(3),t.Oqu(t.xi3(20,21,e.Different,"0.0-4"))}}const jn=function(){return["/menu/Inventory/Inventory_Traffic/Outlet_Inventory_Traffic"]};function Gn(n,i){if(1&n){const e=t.EpF();t.TgZ(0,"mainpanel-cmp",1),t.NdJ("onSubmit",function(){return t.CHM(e),t.oxw().searchFromPageOne()}),t.TgZ(1,"actions")(2,"a",2),t.NdJ("click",function(){t.CHM(e);const a=t.oxw();return a.exportCSV(a.csvConverter,"Inventory/ExportEntitySummary","EntitySummary.csv")}),t._UZ(3,"i",3),t._uU(4," \xa0Export "),t.qZA(),t.TgZ(5,"a",4),t._uU(6,"Switch to Detail"),t.qZA()(),t.TgZ(7,"filters")(8,"div",5)(9,"div")(10,"h6"),t._uU(11,"Outlet"),t.qZA(),t.TgZ(12,"ng-select",6),t.NdJ("ngModelChange",function(a){return t.CHM(e),t.oxw().pageData.Filter.EntityID=a}),t.qZA()(),t.TgZ(13,"div")(14,"h6"),t._uU(15,"Category"),t.qZA(),t.TgZ(16,"ng-select",7),t.NdJ("ngModelChange",function(a){return t.CHM(e),t.oxw().pageData.Filter.CategoryID=a}),t.qZA()(),t.TgZ(17,"div")(18,"h6"),t._uU(19,"From/To"),t.qZA(),t.TgZ(20,"datepicker",8),t.NdJ("dateChange",function(a){return t.CHM(e),t.oxw().pageData.Filter.From=a}),t.qZA(),t.TgZ(21,"datepicker",9),t.NdJ("dateChange",function(a){return t.CHM(e),t.oxw().pageData.Filter.To=a}),t.qZA()()()(),t.TgZ(22,"content")(23,"div",10)(24,"div",11)(25,"table",12),t.NdJ("matSortChange",function(a){return t.CHM(e),t.oxw().sortData(a)}),t.TgZ(26,"thead",13)(27,"tr")(28,"th",14),t._uU(29,"Name"),t.qZA(),t.TgZ(30,"th",15),t._uU(31,"Code"),t.qZA(),t.TgZ(32,"th",16),t._uU(33,"Start"),t.qZA(),t.TgZ(34,"th",16),t._uU(35,"In"),t.qZA(),t.TgZ(36,"th",16),t._uU(37,"Out"),t.qZA(),t.TgZ(38,"th",16),t._uU(39,"End"),t.qZA(),t.TgZ(40,"th",16),t._uU(41,"Diff"),t.qZA()()(),t.TgZ(42,"tbody"),t.YNc(43,Hn,21,27,"tr",17),t.qZA(),t.TgZ(44,"tfoot")(45,"tr",18)(46,"th",19),t._uU(47,"Total:"),t.qZA(),t.TgZ(48,"td",20),t._uU(49),t.ALo(50,"number"),t.ALo(51,"sum"),t.qZA(),t.TgZ(52,"td",21),t._uU(53),t.ALo(54,"number"),t.ALo(55,"sum"),t.qZA(),t.TgZ(56,"td",20),t._uU(57),t.ALo(58,"number"),t.ALo(59,"sum"),t.qZA(),t.TgZ(60,"td",20),t._uU(61),t.ALo(62,"number"),t.ALo(63,"sum"),t.qZA(),t.TgZ(64,"td",21),t._uU(65),t.ALo(66,"number"),t.ALo(67,"sum"),t.qZA()()()()()()()()}if(2&n){const e=t.oxw();t.Q6J("pageData",e.menuData)("hideSearchBox",!0),t.xp6(5),t.Q6J("routerLink",t.DdM(47,jn)),t.xp6(7),t.Q6J("items",null==e.pageData.Options?null:e.pageData.Options.Entities)("ngModel",e.pageData.Filter.EntityID),t.xp6(4),t.Q6J("items",null==e.pageData.Options?null:e.pageData.Options.Categories)("ngModel",e.pageData.Filter.CategoryID),t.xp6(4),t.Q6J("isFloatingLabel",!1)("date",e.pageData.Filter.From),t.xp6(1),t.Q6J("isFloatingLabel",!1)("date",e.pageData.Filter.To),t.xp6(22),t.Q6J("ngForOf",e.data.Data),t.xp6(6),t.Oqu(t.xi3(50,17,t.xi3(51,20,e.data.Data,"Start"),"0.0-4")),t.xp6(4),t.Oqu(t.xi3(54,23,t.xi3(55,26,e.data.Data,"InStock"),"0.0-4")),t.xp6(4),t.Oqu(t.xi3(58,29,t.xi3(59,32,e.data.Data,"OutStock"),"0.0-4")),t.xp6(4),t.Oqu(t.xi3(62,35,t.xi3(63,38,e.data.Data,"End"),"0.0-4")),t.xp6(4),t.hij(" ",t.xi3(66,41,t.xi3(67,44,e.data.Data,"Different"),"0.0-4")," ")}}let Wn=(()=>{class n extends A.n{constructor(e,o,a){super(e,"Inventory/GetEntitySummary","InventoryLoader/GetinventoryTrafficDetailed"),this.httpService=e,this.csvConverter=o,this.pageTitle=a,this.pageTitle.setTitle(this.menuData.T)}postInit(){this.data.Data=this.data}sortData(e){const o=this.data.Data.slice();this.data.Data=e.active&&""!==e.direction?o.sort((a,r)=>{const p="asc"===e.direction;switch(null==a.Code&&(a.Code=""),null==r.Code&&(r.Code=""),e.active){case"Name":return this.compare(a.Name.toLocaleLowerCase(),r.Name.toLocaleLowerCase(),p);case"Code":return this.compare(a.Code.toLocaleLowerCase(),r.Code.toLocaleLowerCase(),p);default:return 0}}):o}}return n.\u0275fac=function(e){return new(e||n)(t.Y36(d.O),t.Y36(C.O),t.Y36(U.Dx))},n.\u0275cmp=t.Xpm({type:n,selectors:[["POS-Outlet-Inventory-traffic-Summary"]],features:[t.qOj],decls:1,vars:1,consts:[["filterWidth","270px",3,"pageData","hideSearchBox","onSubmit",4,"ngIf"],["filterWidth","270px",3,"pageData","hideSearchBox","onSubmit"],[1,"btn","btn-outline-secondary",3,"click"],["aria-hidden","true",1,"fa-solid","fa-upload"],["title","Switch to Detail",1,"button","btn","btn-success","ms-6",3,"routerLink"],["container","",1,"w-100"],["bindLabel","Name","bindValue","ID","placeholder","Choose...",3,"items","ngModel","ngModelChange"],["bindLabel","Value","bindValue","Key","placeholder","Choose...",3,"items","ngModel","ngModelChange"],["placeholder","From","appearance","outline","name","From",3,"isFloatingLabel","date","dateChange"],["placeholder","To","appearance","outline","name","To",3,"isFloatingLabel","date","dateChange"],[1,"container-fluid","mt-3"],[1,"table-responsive"],["id","tableGrid","matSort","",1,"table","border-bottom",3,"matSortChange"],[1,"thead-light","sticky-top-thead"],["mat-sort-header","Name",2,"width","35%"],["mat-sort-header","Code",2,"width","35%"],[1,"text-end",2,"width","6%"],[4,"ngFor","ngForOf"],[1,"table-footer"],["colspan","2",1,"empty-column","text-end"],[1,"text-end","text-success"],[1,"text-end","text-danger"],[3,"routerLink","queryParams"]],template:function(e,o){1&e&&t.YNc(0,Gn,68,48,"mainpanel-cmp",0),2&e&&t.Q6J("ngIf",o.data)},directives:[_.O5,g.p,x.yS,f.w9,l.JJ,l.On,L.QB,h.YE,h.nU,_.sg],pipes:[_.JJ,F.qU],encapsulation:2}),n})();function $n(n,i){if(1&n){const e=t.EpF();t.TgZ(0,"a",14),t.NdJ("click",function(){t.CHM(e);const a=t.oxw(2);return a.exportCSV(a.csvConverter,"Inventory/GetDepletingInventory","Deffered_Revenue.csv")}),t._UZ(1,"i",15),t._uU(2,"\xa0Export "),t.qZA()}}function Kn(n,i){if(1&n){const e=t.EpF();t.TgZ(0,"div",16)(1,"div")(2,"h6"),t._uU(3,"Outlet"),t.qZA(),t.TgZ(4,"ng-select",17),t.NdJ("ngModelChange",function(a){return t.CHM(e),t.oxw(2).pageData.Filter.EntityID=a}),t.qZA()(),t.TgZ(5,"div")(6,"h6"),t._uU(7,"Quantity "),t._UZ(8,"i",18),t.qZA(),t.TgZ(9,"input",19),t.NdJ("ngModelChange",function(a){return t.CHM(e),t.oxw(2).pageData.Filter.Qty=a}),t.qZA()(),t.TgZ(10,"div")(11,"h6"),t._uU(12,"From/To"),t.qZA(),t.TgZ(13,"datepicker",20),t.NdJ("dateChange",function(a){return t.CHM(e),t.oxw(2).pageData.Filter.From=a}),t.qZA(),t.TgZ(14,"datepicker",21),t.NdJ("dateChange",function(a){return t.CHM(e),t.oxw(2).pageData.Filter.To=a}),t.qZA()(),t.TgZ(15,"div")(16,"h6"),t._uU(17,"Group By"),t.qZA(),t.TgZ(18,"radio-options",22),t.NdJ("modelChange",function(a){return t.CHM(e),t.oxw(2).pageData.Filter.ByProduct=a}),t.qZA()(),t.TgZ(19,"div")(20,"h6"),t._uU(21,"Row Count"),t.qZA(),t.TgZ(22,"input",23),t.NdJ("ngModelChange",function(a){return t.CHM(e),t.oxw(2).pageData.Filter.RowCount=a}),t.qZA()()()}if(2&n){const e=t.oxw(2);t.xp6(4),t.Q6J("items",null==e.pageData.Options?null:e.pageData.Options.Entities)("multiple",!0)("ngModel",e.pageData.Filter.EntityID),t.xp6(5),t.Q6J("ngModel",e.pageData.Filter.Qty),t.xp6(4),t.Q6J("isFloatingLabel",!1)("date",e.pageData.Filter.From),t.xp6(1),t.Q6J("isFloatingLabel",!1)("date",e.pageData.Filter.To),t.xp6(4),t.Q6J("model",e.pageData.Filter.ByProduct)("options",e.GroupBy),t.xp6(4),t.Q6J("ngModel",e.pageData.Filter.RowCount)}}const zn=function(){return["/menu/Products/Catalog/Products/Info"]},Xn=function(n){return{ID:n}};function ta(n,i){if(1&n&&(t.TgZ(0,"tr")(1,"td")(2,"a",24),t._uU(3),t.qZA()(),t.TgZ(4,"td"),t._uU(5),t.qZA(),t.TgZ(6,"td",25),t._uU(7),t.ALo(8,"number"),t.qZA(),t.TgZ(9,"td",25),t._uU(10),t.ALo(11,"number"),t.qZA()()),2&n){const e=i.$implicit;t.xp6(2),t.Q6J("routerLink",t.DdM(10,zn))("queryParams",t.VKq(11,Xn,e.ID)),t.xp6(1),t.Oqu(e.Name),t.xp6(2),t.Oqu(e.Code),t.xp6(2),t.Oqu(t.lcZ(8,6,e.ItemSold)),t.xp6(3),t.Oqu(t.lcZ(11,8,e.UnitsInStock))}}function ea(n,i){if(1&n){const e=t.EpF();t.TgZ(0,"mat-paginator",26),t.NdJ("page",function(a){return t.CHM(e),t.oxw(2).onPaginationChange(a)}),t.qZA()}if(2&n){const e=t.oxw(2);t.Q6J("length",e.pagination.listTotal)("pageSize",e.pagination.pageSize)("pageIndex",0==e.pageData.Filter.PageNumber?0:e.pageData.Filter.PageNumber-1)}}function na(n,i){if(1&n){const e=t.EpF();t.TgZ(0,"mainpanel-cmp",1),t.NdJ("onSubmit",function(){return t.CHM(e),t.oxw().searchFromPageOne()}),t.TgZ(1,"actions"),t.YNc(2,$n,3,0,"a",2),t.qZA(),t.TgZ(3,"filters"),t.YNc(4,Kn,23,11,"div",3),t.qZA(),t.TgZ(5,"content")(6,"div",4)(7,"div",5)(8,"table",6),t.NdJ("matSortChange",function(a){return t.CHM(e),t.oxw().sortData(a)}),t.TgZ(9,"thead",7)(10,"tr")(11,"th",8),t._uU(12,"Name"),t.qZA(),t.TgZ(13,"th",9),t._uU(14,"Code"),t.qZA(),t.TgZ(15,"th",10),t._uU(16,"Qty Sold"),t.qZA(),t.TgZ(17,"th",11),t._uU(18,"On Hand"),t.qZA()()(),t.TgZ(19,"tbody"),t.YNc(20,ta,12,13,"tr",12),t.qZA()()(),t.TgZ(21,"div"),t.YNc(22,ea,1,3,"mat-paginator",13),t.qZA()()()()}if(2&n){const e=t.oxw();t.Q6J("pageData",e.menuData)("hideSearchBox",!0),t.xp6(2),t.Q6J("ngIf",e.pageData.IsExport),t.xp6(2),t.Q6J("ngIf",e.pageData.Filter),t.xp6(16),t.Q6J("ngForOf",e.data.List),t.xp6(2),t.Q6J("ngIf",e.pagination.listTotal>0)}}let aa=(()=>{class n extends A.n{constructor(e,o,a){super(e,"Inventory/GetDepletingInventory","InventoryLoader/GetDepletingNG"),this.httpService=e,this.pageTitle=o,this.csvConverter=a,this.GroupBy=[{Key:!0,Value:"Product"},{Key:!1,Value:"Variant"}],this.pageTitle.setTitle(this.menuData.T)}sortData(e){const o=this.data.List.slice();this.data.List=e.active&&""!==e.direction?o.sort((a,r)=>{const p="asc"===e.direction;switch(a.Code=null==a.Code?"":a.Code,r.Code=null==r.Code?"":r.Code,e.active){case"Name":return this.compare(a.Name.toLocaleLowerCase(),r.Name.toLocaleLowerCase(),p);case"Code":return this.compare(a.Code.toLocaleLowerCase(),r.Code.toLocaleLowerCase(),p);case"ItemSold":return this.compare(a.ItemSold,r.ItemSold,p);case"UnitsInStock":return this.compare(a.UnitsInStock,r.UnitsInStock,p);default:return 0}}):o}}return n.\u0275fac=function(e){return new(e||n)(t.Y36(d.O),t.Y36(U.Dx),t.Y36(C.O))},n.\u0275cmp=t.Xpm({type:n,selectors:[["POS-Depleting-Inventory"]],features:[t.qOj],decls:1,vars:1,consts:[["filterWidth","270px",3,"pageData","hideSearchBox","onSubmit",4,"ngIf"],["filterWidth","270px",3,"pageData","hideSearchBox","onSubmit"],["value","Export","title","Export","class","btn btn-outline-secondary",3,"click",4,"ngIf"],["container","","class","w-100",4,"ngIf"],[1,"container-fluid","my-3"],[1,"table-responsive"],["matSort","",1,"table",3,"matSortChange"],[1,"thead-light","sticky-top-thead"],["mat-sort-header","Name",2,"width","600px"],["mat-sort-header","Code",2,"width","80px"],["mat-sort-header","ItemSold",2,"width","72px"],["mat-sort-header","UnitsInStock",2,"width","71px"],[4,"ngFor","ngForOf"],[3,"length","pageSize","pageIndex","page",4,"ngIf"],["value","Export","title","Export",1,"btn","btn-outline-secondary",3,"click"],[1,"fa","fa-upload"],["container","",1,"w-100"],["bindLabel","Name","bindValue","ID","placeholder","Choose...",3,"items","multiple","ngModel","ngModelChange"],[1,"fa-solid","fa-less-than-equal"],["type","text","name","Qty",3,"ngModel","ngModelChange"],["placeholder","From","appearance","outline","name","From",3,"isFloatingLabel","date","dateChange"],["placeholder","To","appearance","outline","name","To",3,"isFloatingLabel","date","dateChange"],["name","ByProduct",3,"model","options","modelChange"],["type","text","name","RowCount",3,"ngModel","ngModelChange"],[3,"routerLink","queryParams"],[2,"text-align","right"],[3,"length","pageSize","pageIndex","page"]],template:function(e,o){1&e&&t.YNc(0,na,23,6,"mainpanel-cmp",0),2&e&&t.Q6J("ngIf",o.data)},directives:[_.O5,g.p,f.w9,l.JJ,l.On,l.Fj,L.QB,M.P,h.YE,h.nU,_.sg,x.yS,I.NW],pipes:[_.JJ],encapsulation:2}),n})();function oa(n,i){if(1&n){const e=t.EpF();t.TgZ(0,"a",23),t.NdJ("click",function(){t.CHM(e);const a=t.oxw(2);return a.exportCSV(a.csvConverter,"Inventory/InventorySerial","SerialInventory.csv")}),t._UZ(1,"i",24),t._uU(2," Export"),t.qZA()}}function ia(n,i){if(1&n){const e=t.EpF();t.TgZ(0,"div",25)(1,"div")(2,"h6"),t._uU(3,"Outlet"),t.qZA(),t.TgZ(4,"ng-select",26),t.NdJ("ngModelChange",function(a){return t.CHM(e),t.oxw(2).pageData.Filter.EntityID=a}),t.qZA()(),t.TgZ(5,"div")(6,"h6"),t._uU(7,"Category"),t.qZA(),t.TgZ(8,"ng-select",27),t.NdJ("ngModelChange",function(a){return t.CHM(e),t.oxw(2).pageData.Filter.CategoryID=a}),t.qZA()(),t.TgZ(9,"div")(10,"h6"),t._uU(11,"Discontinued"),t.qZA(),t.TgZ(12,"radio-options",28),t.NdJ("modelChange",function(a){return t.CHM(e),t.oxw(2).pageData.Filter.Discontinued=a}),t.qZA()()()}if(2&n){const e=t.oxw(2);t.xp6(4),t.Q6J("items",null==e.pageData.Options?null:e.pageData.Options.Entities)("multiple",!0)("ngModel",e.pageData.Filter.EntityID),t.xp6(4),t.Q6J("items",null==e.pageData.Options?null:e.pageData.Options.Categories)("ngModel",e.pageData.Filter.CategoryID),t.xp6(4),t.Q6J("model",e.pageData.Filter.Discontinued)}}function ra(n,i){1&n&&(t.TgZ(0,"th",29),t._uU(1," Cost "),t.qZA())}function la(n,i){1&n&&(t.TgZ(0,"th",12),t._uU(1," Margin(%) "),t.qZA())}function _a(n,i){if(1&n&&(t.TgZ(0,"td",29),t._uU(1),t.ALo(2,"number"),t.qZA()),2&n){const e=t.oxw().$implicit;t.xp6(1),t.Oqu(t.lcZ(2,1,e.UnitCost))}}function pa(n,i){if(1&n&&(t.TgZ(0,"td",12),t._uU(1),t.ALo(2,"number"),t.qZA()),2&n){const e=t.oxw().$implicit;t.xp6(1),t.Oqu(t.lcZ(2,1,e.Margin))}}const $=function(n){return{ID:n}};function ca(n,i){if(1&n&&(t.TgZ(0,"tr",39)(1,"td")(2,"a",40)(3,"span",35),t._uU(4),t.qZA(),t.TgZ(5,"span",35),t._uU(6),t.qZA()(),t.TgZ(7,"div"),t._uU(8),t.qZA()(),t.TgZ(9,"td",9),t._uU(10),t.qZA(),t.TgZ(11,"td",10),t._uU(12),t.ALo(13,"number"),t.qZA(),t.YNc(14,_a,3,3,"td",41),t.TgZ(15,"td",12),t._uU(16),t.ALo(17,"number"),t.qZA(),t.YNc(18,pa,3,3,"td",42),t.qZA()),2&n){const e=i.$implicit,o=t.oxw().$implicit,a=t.oxw(3);t.xp6(2),t.Q6J("queryParams",t.VKq(15,$,e.ID)),t.xp6(1),t.Q6J("hidden",o.Variants.length<=1),t.xp6(1),t.Oqu(e.Model),t.xp6(1),t.Q6J("hidden",o.Variants.length>1),t.xp6(1),t.hij(" ",o.Name+" ("+e.Model+")"," "),t.xp6(2),t.hij(" ",e.UOMName," "),t.xp6(2),t.Oqu(e.Code),t.xp6(2),t.Oqu(t.lcZ(13,11,e.Quantity)),t.xp6(2),t.Q6J("ngIf",a.pageData.Role.IsCostVisible),t.xp6(2),t.Oqu(t.lcZ(17,13,e.UnitPrice)),t.xp6(2),t.Q6J("ngIf",a.pageData.Role.IsCostVisible)}}function ua(n,i){if(1&n&&(t.TgZ(0,"div",34)(1,"div",35)(2,"h4")(3,"a",36),t._uU(4),t.qZA()()(),t.TgZ(5,"div",5)(6,"table",37)(7,"tbody"),t.YNc(8,ca,19,17,"tr",38),t.qZA()()()()),2&n){const e=i.$implicit;t.xp6(1),t.Q6J("hidden",e.Variants.length<=1),t.xp6(2),t.Q6J("queryParams",t.VKq(4,$,e.ID)),t.xp6(1),t.hij(" ",e.Name," "),t.xp6(4),t.Q6J("ngForOf",e.Variants)}}function da(n,i){if(1&n&&(t.TgZ(0,"div",30)(1,"div",31)(2,"h3",32),t._uU(3),t.qZA(),t.YNc(4,ua,9,6,"div",33),t.qZA()()),2&n){const e=i.$implicit;t.xp6(3),t.Oqu(e.Name),t.xp6(1),t.Q6J("ngForOf",e.Products)}}function sa(n,i){if(1&n){const e=t.EpF();t.TgZ(0,"mainpanel-cmp",1),t.NdJ("onSubmit",function(){return t.CHM(e),t.oxw().searchFromPageOne()}),t.TgZ(1,"actions"),t.YNc(2,oa,3,0,"a",2),t.qZA(),t.TgZ(3,"filters"),t.YNc(4,ia,13,6,"div",3),t.qZA(),t.TgZ(5,"content")(6,"div",4)(7,"div",5)(8,"table",6)(9,"thead",7)(10,"tr",8)(11,"th"),t._uU(12," Name "),t.qZA(),t.TgZ(13,"th",9),t._uU(14," Code "),t.qZA(),t.TgZ(15,"th",10),t._uU(16," Qty "),t.qZA(),t.YNc(17,ra,2,0,"th",11),t.TgZ(18,"th",12),t._uU(19," Price "),t.qZA(),t.YNc(20,la,2,0,"th",13),t.qZA()()()(),t.YNc(21,da,5,2,"div",14),t.TgZ(22,"div",15)(23,"div",16)(24,"div",5)(25,"table",17)(26,"thead",7)(27,"tr")(28,"th",18),t._uU(29," Total Quantity "),t.qZA(),t.TgZ(30,"th",19),t._uU(31," Total Inventory COST ( "),t._UZ(32,"span",20),t.ALo(33,"number"),t._uU(34,"%) "),t.qZA(),t.TgZ(35,"th",19),t._uU(36," Total Inventory Value when SOLD "),t.qZA()()(),t.TgZ(37,"tbody")(38,"tr"),t._UZ(39,"td",21),t.ALo(40,"number"),t._UZ(41,"td",22),t.ALo(42,"number"),t._UZ(43,"td",22),t.ALo(44,"number"),t.qZA()()()()()()()()()}if(2&n){const e=t.oxw();t.Q6J("pageData",e.menuData)("hideSearchBox",!0),t.xp6(2),t.Q6J("ngIf",null==e.pageData.Role?null:e.pageData.Role.Export),t.xp6(2),t.Q6J("ngIf",e.pageData.Filter),t.xp6(13),t.Q6J("ngIf",e.pageData.Role.IsCostVisible),t.xp6(3),t.Q6J("ngIf",e.pageData.Role.IsCostVisible),t.xp6(1),t.Q6J("ngForOf",e.data.Data),t.xp6(9),t.Q6J("hidden",!e.pageData.Role.IsCostVisible),t.xp6(2),t.Q6J("hidden",0==(null==e.data.Aggregate?null:e.data.Aggregate.TotalSales))("innerHtml",t.lcZ(33,16,e.data.Aggregate.TotalCost/e.data.Aggregate.TotalSales*100),t.oJD),t.xp6(3),t.Q6J("hidden",!e.pageData.Role.IsCostVisible),t.xp6(4),t.Q6J("innerHtml",t.lcZ(40,18,e.data.Aggregate.TotalQuantity),t.oJD),t.xp6(2),t.Q6J("hidden",!e.pageData.Role.IsCostVisible)("innerHtml",t.lcZ(42,20,e.data.Aggregate.TotalCost),t.oJD),t.xp6(2),t.Q6J("hidden",!e.pageData.Role.IsCostVisible)("innerHtml",t.lcZ(44,22,e.data.Aggregate.TotalSales),t.oJD)}}let ga=(()=>{class n extends A.n{constructor(e,o,a){super(e,"Inventory/InventorySerial","InventoryLoader/InventorySerial"),this.httpService=e,this.csvConverter=o,this.pageTitle=a,this.pageTitle.setTitle("Serial Inventory")}}return n.\u0275fac=function(e){return new(e||n)(t.Y36(d.O),t.Y36(C.O),t.Y36(U.Dx))},n.\u0275cmp=t.Xpm({type:n,selectors:[["POS-serial_inventory"]],features:[t.qOj],decls:1,vars:1,consts:[["filterWidth","270px",3,"pageData","hideSearchBox","onSubmit",4,"ngIf"],["filterWidth","270px",3,"pageData","hideSearchBox","onSubmit"],["class","btn btn-outline-secondary",3,"click",4,"ngIf"],["container","","class","w-100",4,"ngIf"],[1,"container-fluid","mt-5"],[1,"table-responsive"],["id","tableGrid",1,"table","table-header"],[1,"thead-light","sticky-top-thead"],["id","trStockRecap"],[2,"width","120px"],[1,"text-end",2,"width","100px"],["class","text-end","style","width: 120px",4,"ngIf"],[1,"text-end",2,"width","80px"],["class","text-end","style","width: 80px",4,"ngIf"],["class","categorypack summary",4,"ngFor","ngForOf"],[1,"row","d-flex","justify-content-end","align-items-center","mt-5"],[1,"col-md-6"],[1,"table"],[1,"text-end"],[1,"text-end",3,"hidden"],[3,"hidden","innerHtml"],[1,"text-end",3,"innerHtml"],[1,"text-end",3,"hidden","innerHtml"],[1,"btn","btn-outline-secondary",3,"click"],["aria-hidden","true",1,"fa","fa-upload"],["container","",1,"w-100"],["bindLabel","Name","bindValue","ID","placeholder","Choose...",3,"items","multiple","ngModel","ngModelChange"],["bindLabel","Value","bindValue","Key","placeholder","Choose...",3,"items","ngModel","ngModelChange"],["name","Discontinued",3,"model","modelChange"],[1,"text-end",2,"width","120px"],[1,"categorypack","summary"],[1,"mt-10"],[1,"fw-normal"],["class","productpack mt-5",4,"ngFor","ngForOf"],[1,"productpack","mt-5"],[3,"hidden"],["routerLink","/menu/Products/Catalog/Products/Info",3,"queryParams"],[1,"table","table-borderless","mt-6"],["class","border-bottom",4,"ngFor","ngForOf"],[1,"border-bottom"],["routerLink","/menu/Products/Catalog/Variants/Info",3,"queryParams"],["style","width: 120px","class","text-end",4,"ngIf"],["style","width: 80px","class","text-end",4,"ngIf"]],template:function(e,o){1&e&&t.YNc(0,sa,45,24,"mainpanel-cmp",0),2&e&&t.Q6J("ngIf",o.data)},directives:[_.O5,g.p,f.w9,l.JJ,l.On,M.P,_.sg,x.yS],pipes:[_.JJ],styles:[".table-header[_ngcontent-%COMP%] {\n top: 0;\n z-index: 10;\n position: sticky !important;\n}"]}),n})();var K=c(75652),ma=c(59783),xa=c(40845);const ha=["myCalendar"];function fa(n,i){if(1&n&&(t.TgZ(0,"span",37),t._uU(1),t.qZA()),2&n){const e=i.item;t.s9C("title",e.Value),t.xp6(1),t.Oqu(e.Value)}}const Ca=function(){return{standalone:!0}};function ya(n,i){if(1&n){const e=t.EpF();t.TgZ(0,"div",27)(1,"div")(2,"h6"),t._uU(3,"Outlet"),t.qZA(),t.TgZ(4,"ng-select",28),t.NdJ("ngModelChange",function(a){return t.CHM(e),t.oxw(2).pageData.Filter.ListEntityID=a}),t.qZA()(),t.TgZ(5,"div")(6,"h6"),t._uU(7,"Category"),t.qZA(),t.TgZ(8,"ng-select",29),t.NdJ("ngModelChange",function(a){return t.CHM(e),t.oxw(2).pageData.Filter.CategoryID=a}),t.YNc(9,fa,2,2,"ng-template",30),t.qZA()(),t.TgZ(10,"div")(11,"h6"),t._uU(12,"Date - In the morning"),t.qZA(),t.TgZ(13,"datepicker",31),t.NdJ("dateChange",function(a){return t.CHM(e),t.oxw(2).pageData.Filter.Date=a}),t.qZA()(),t.TgZ(14,"div")(15,"h6"),t._uU(16,"Time"),t.qZA(),t.TgZ(17,"p-calendar",32,33),t.NdJ("ngModelChange",function(a){return t.CHM(e),t.oxw(2).pageData.Filter.Time=a}),t.TgZ(19,"p-footer")(20,"button",34),t.NdJ("click",function(){return t.CHM(e),t.MAs(18).hideOverlay()}),t.qZA()()()(),t.TgZ(21,"div")(22,"h6"),t._uU(23,"Supplier"),t.qZA(),t.TgZ(24,"autocompleteV2",35),t.NdJ("ngModelChange",function(a){return t.CHM(e),t.oxw(2).pageData.Filter.SupplierID=a}),t.qZA()(),t.TgZ(25,"div")(26,"h6"),t._uU(27,"Discontinued"),t.qZA(),t.TgZ(28,"radio-options",36),t.NdJ("modelChange",function(a){return t.CHM(e),t.oxw(2).pageData.Filter.Discontinued=a}),t.qZA()()()}if(2&n){const e=t.oxw(2);t.xp6(4),t.Q6J("multiple",!0)("ngModel",e.pageData.Filter.ListEntityID)("items",null==e.pageData.Options?null:e.pageData.Options.Entities),t.xp6(4),t.Q6J("ngModel",e.pageData.Filter.CategoryID)("items",null==e.pageData.Options?null:e.pageData.Options.Categories),t.xp6(5),t.Q6J("date",e.pageData.Filter.Date),t.xp6(4),t.Q6J("ngModel",e.pageData.Filter.Time)("timeOnly",!0)("ngModelOptions",t.DdM(11,Ca)),t.xp6(7),t.Q6J("ngModel",e.pageData.Filter.SupplierID),t.xp6(4),t.Q6J("model",e.pageData.Filter.Discontinued)}}const z=function(){return["/menu/Products/Catalog/Variants/Info"]},X=function(n){return{ID:n}},Za=function(n,i){return{"text-danger":n,"text-success":i}};function Ta(n,i){if(1&n&&(t.TgZ(0,"tr")(1,"td",38)(2,"a",39),t._uU(3),t.qZA()(),t.TgZ(4,"td",40),t._uU(5),t.qZA(),t.TgZ(6,"td",41),t._uU(7),t.ALo(8,"number"),t.qZA(),t.TgZ(9,"td",42),t._uU(10),t.ALo(11,"number"),t.qZA(),t.TgZ(12,"td",42),t._uU(13),t.ALo(14,"number"),t.qZA(),t.TgZ(15,"td",42)(16,"a",43),t._uU(17),t.ALo(18,"number"),t.qZA()()()),2&n){const e=i.$implicit;t.xp6(1),t.ekj("bg-gradient-warning",0==e.In&&0==e.Out&&0==e.Now),t.xp6(1),t.Q6J("routerLink",t.DdM(21,z))("queryParams",t.VKq(22,X,e.ID)),t.xp6(1),t.Oqu(e.Name),t.xp6(2),t.Oqu(e.Code),t.xp6(2),t.Oqu(t.lcZ(8,13,e.Start)),t.xp6(3),t.Oqu(t.lcZ(11,15,e.In)),t.xp6(3),t.Oqu(t.lcZ(14,17,e.Out)),t.xp6(3),t.Q6J("routerLink",t.DdM(24,z))("queryParams",t.VKq(25,X,e.ID))("ngClass",t.WLB(27,Za,e.Start>e.Now,e.Now>e.Start)),t.xp6(1),t.Oqu(t.lcZ(18,19,e.Now))}}function va(n,i){if(1&n&&(t.TgZ(0,"tr",44)(1,"td",45),t._uU(2,"Total:"),t.qZA(),t.TgZ(3,"td",46),t._uU(4),t.ALo(5,"number"),t.qZA(),t.TgZ(6,"td",47),t._uU(7),t.ALo(8,"number"),t.qZA(),t.TgZ(9,"td",47),t._uU(10),t.ALo(11,"number"),t.qZA(),t.TgZ(12,"td",47),t._uU(13),t.ALo(14,"number"),t.qZA()()),2&n){const e=t.oxw(2);t.xp6(4),t.Oqu(t.lcZ(5,4,e.data.Aggregate.Start)),t.xp6(3),t.Oqu(t.lcZ(8,6,e.data.Aggregate.In)),t.xp6(3),t.Oqu(t.lcZ(11,8,e.data.Aggregate.Out)),t.xp6(3),t.Oqu(t.lcZ(14,10,e.data.Aggregate.Now))}}function Da(n,i){if(1&n){const e=t.EpF();t.TgZ(0,"span",48),t.NdJ("click",function(){return t.CHM(e),t.oxw(2).StoreRowsCountAPIResult("Inventory/InventoryByVariantLogRowsCount")}),t.TgZ(1,"i",49),t._uU(2,"?"),t.qZA()()}}function Aa(n,i){if(1&n&&(t.TgZ(0,"span"),t._uU(1),t.ALo(2,"number"),t.qZA()),2&n){const e=t.oxw(2);t.xp6(1),t.Oqu(t.lcZ(2,1,e.listTotal))}}function Ia(n,i){if(1&n){const e=t.EpF();t.TgZ(0,"a",50),t.NdJ("click",function(){return t.CHM(e),t.oxw(2).NextPage(!0)}),t._UZ(1,"i",51),t._uU(2," Next"),t.qZA()}}function ba(n,i){if(1&n){const e=t.EpF();t.TgZ(0,"a",52),t.NdJ("click",function(){return t.CHM(e),t.oxw(2).StoreRowsCountAPIResult("Inventory/InventoryByVariantLogRowsCount",!0)}),t._UZ(1,"i",53),t._uU(2," Last"),t.qZA()}}const Oa=function(){return["Detailed_Inventory_Traffic_Log"]};function qa(n,i){if(1&n){const e=t.EpF();t.TgZ(0,"mainpanel-cmp",1),t.NdJ("textChange",function(a){return t.CHM(e),t.oxw().pageData.Filter.Text=a})("onSubmit",function(){return t.CHM(e),t.oxw().searchFromPageOne()}),t.TgZ(1,"actions")(2,"div",2)(3,"a",3),t.NdJ("click",function(){t.CHM(e);const a=t.oxw();return a.exportCSV(a.csvConverter,"InventoryExport/InventoryExportByVariantLog","Inventory Timeline.csv")}),t._UZ(4,"i",4),t._uU(5," Export "),t.qZA()(),t.TgZ(6,"a",5),t._uU(7,"Breakdown"),t.qZA()(),t.TgZ(8,"filters")(9,"div",6),t.YNc(10,ya,29,12,"div",7),t.qZA()(),t.TgZ(11,"content")(12,"div",8)(13,"div",9)(14,"table",10),t.NdJ("matSortChange",function(a){return t.CHM(e),t.oxw().sortData(a)}),t.TgZ(15,"thead",11)(16,"tr")(17,"th",12),t._uU(18,"Name"),t.qZA(),t.TgZ(19,"th",13),t._uU(20,"Code"),t.qZA(),t.TgZ(21,"th",14),t._uU(22),t.ALo(23,"date"),t.qZA(),t.TgZ(24,"th",15),t._uU(25,"In"),t.qZA(),t.TgZ(26,"th",15),t._uU(27,"Out"),t.qZA(),t.TgZ(28,"th",16),t._uU(29,"Qty Now"),t.qZA()()(),t.TgZ(30,"tbody"),t.YNc(31,Ta,19,30,"tr",17),t.qZA(),t.TgZ(32,"tfoot"),t.YNc(33,va,15,12,"tr",18),t.qZA()()(),t.TgZ(34,"div",19)(35,"div",20)(36,"div",21),t._uU(37),t.ALo(38,"number"),t.YNc(39,Da,3,0,"span",22),t.YNc(40,Aa,3,3,"span",23),t._uU(41),t.qZA()(),t.TgZ(42,"div",24),t.YNc(43,Ia,3,0,"a",25),t.YNc(44,ba,3,0,"a",26),t.qZA()()()()()}if(2&n){const e=t.oxw();t.Q6J("pageData",e.menuData)("text",e.pageData.Filter.Text),t.xp6(6),t.Q6J("routerLink",t.DdM(18,Oa)),t.xp6(4),t.Q6J("ngIf",e.pageData.Filter),t.xp6(12),t.hij(" ",t.xi3(23,13,null==e.data?null:e.data.Date,"d-MMM-yy")," "),t.xp6(9),t.Q6J("ngForOf",e.infiniteList),t.xp6(2),t.Q6J("ngIf",null==e.data?null:e.data.Aggregate),t.xp6(4),t.hij(" Showing 1 - ",t.lcZ(38,16,e.pageData.Filter.RowCount*(e.pageData.Filter.PageNumber-1)+e.data.TotalCurrentRow)," of "),t.xp6(2),t.Q6J("ngIf",!e.pageData.HideStoreApiCount),t.xp6(1),t.Q6J("ngIf",e.pageData.HideStoreApiCount),t.xp6(1),t.hij(" records ~ ",e.pageData.Filter.PageNumber," Page "),t.xp6(2),t.Q6J("ngIf",e.nextPageDisabled&&!e.goToLast),t.xp6(1),t.Q6J("ngIf",e.nextPageDisabled&&!e.goToLast)}}let Ma=(()=>{class n extends D.X{constructor(e,o,a){super(e,"Inventory/InventoryByVariantLog","InventoryLoader/AtDate",o),this.httpService=e,this.csvConverter=a}close(){this.datePicker.overlayVisible=!1}preGetList(){s.gT.IsNotEmpty(this.pageData.Filter.Time)&&(this.pageData.Filter.Time=this.pageData.Filter.Time.toTimeString().slice(0,5)),this.data&&(this.pageData.Header="Inventory Timeline - "+(0,_.p6)(this.data.Date,"d MMM","en-US"))}preInitList(){this.oldRowCount=this.pageData.Filter.RowCount}sortData(e){const o=this.infiniteList.slice();this.infiniteList=e.active&&""!==e.direction?o.sort((a,r)=>{const p="asc"===e.direction;switch(e.active){case"Name":return this.compare(a.Name,r.Name,p);case"Code":return this.compare(a.Code,r.Code,p);default:return 0}}):this.originalData}exportformui(e){const o={Name:"Name",Code:"Code",QtyFrom:(0,_.p6)(this.pageData.Filter.Date,"d-MMM-yy","en-US"),In:"In",Out:"Out",QtyNow:"Qty Now",Cost:"Cost",TotalCost:"Total Cost",Price:"Price",TotalPrice:"Total Price"},a=[];let r=0,p=0,v=0,P=0,S=0,J=0,et=0,nt=0;this.data.data.forEach(u=>{const B={Name:u.Name,Code:u.Code?u.Code:"",QtyFrom:u.Start?u.Start:0,In:u.In?u.In:0,Out:u.Out?u.Out:0,QtyNow:u.Now?u.Now:0,Cost:u.UnitCost?u.UnitCost:0,TotalCost:u.Now*u.UnitCost!=0?u.Now*u.UnitCost:0,Price:u.UnitPrice?u.UnitPrice:0,TotalPrice:u.Now*u.UnitPrice?u.Now*u.UnitPrice:0};et+=u.In?u.In:0,nt+=u.Out?u.Out:0,r+=u.UnitCost?u.UnitCost:0,p+=u.Now*u.UnitCost!=0?u.Now*u.UnitCost:0,v+=u.UnitPrice?u.UnitPrice:0,P+=u.Now*u.UnitPrice!=0?u.Now*u.UnitPrice:0,S+=u.Now?u.Now:0,J+=u.Start?u.Start:0,this.pageData.CostVisible||(delete B.Cost,delete B.TotalCost),a.push(B)});const E={Name:"",Code:"Total",QtyFrom:J,In:et,Out:nt,QtyNow:S,Cost:r,TotalCost:p,Price:v,TotalPrice:P};this.pageData.CostVisible||(delete E.Cost,delete E.TotalCost,delete o.Cost,delete o.TotalCost),a.push(E),a.unshift(o)}}return n.\u0275fac=function(e){return new(e||n)(t.Y36(d.O),t.Y36(w._W),t.Y36(C.O))},n.\u0275cmp=t.Xpm({type:n,selectors:[["CustomerDisplay-inventory-by-variant-log"]],viewQuery:function(e,o){if(1&e&&t.Gf(ha,5),2&e){let a;t.iGM(a=t.CRH())&&(o.datePicker=a.first)}},features:[t.qOj],decls:1,vars:1,consts:[["filterWidth","270px",3,"pageData","text","textChange","onSubmit",4,"ngIf"],["filterWidth","270px",3,"pageData","text","textChange","onSubmit"],[1,"btn-group","me-6"],[1,"btn","btn-outline-secondary",3,"click"],["aria-hidden","true",1,"fa","fa-upload"],["title","Switch to Detail View",1,"button","btn","btn-success",3,"routerLink"],[1,"d-flex"],["container","","class","w-100",4,"ngIf"],[1,"container-fluid","mt-5"],[1,"table-responsive"],["id","tableGrid","matSort","",1,"table",3,"matSortChange"],[1,"thead-light","sticky-top-thead"],["mat-sort-header","Name",1,"border-end"],["mat-sort-header","Code",1,"border-end",2,"width","150px"],[1,"text-end","border-end","bg-orange","text-white",2,"width","150px"],[1,"text-end","border-end",2,"width","150px"],[1,"text-end",2,"width","150px"],[4,"ngFor","ngForOf"],["class","table-footer",4,"ngIf"],[1,"d-flex","justify-content-between","mt-5"],[1,"me-auto","d-sm-block","collapse","mt-3"],[1,"fw-bold","fst-italic","hidden-xxs"],["style","cursor:pointer",3,"click",4,"ngIf"],[4,"ngIf"],[1,"btn-group"],["role","button","class","btn btn-outline-secondary btn-sm text-primary","title","Load more for 500 variants",3,"click",4,"ngIf"],["role","button","class","btn btn-outline-secondary btn-sm text-primary","title","Load all products",3,"click",4,"ngIf"],["container","",1,"w-100"],["bindLabel","Name","bindValue","ID","placeholder","Choose outlet",1,"outlet-multiple",3,"multiple","ngModel","items","ngModelChange"],["bindLabel","Value","bindValue","Key","placeholder","Choose a category",1,"outlet-multiple",3,"ngModel","items","ngModelChange"],["ng-option-tmp",""],["name","Date",3,"date","dateChange"],[3,"ngModel","timeOnly","ngModelOptions","ngModelChange"],["myCalendar",""],["pButton","","type","button","label","Close",3,"click"],["inputID","Key","requestUrl","/API/AC/GetSupplierSuggestion",1,"w-100",3,"ngModel","ngModelChange"],["name","Bin",3,"model","modelChange"],[3,"title"],[1,"border-end","border-start"],[3,"routerLink","queryParams"],[1,"border-end"],[1,"text-end","border-end","bg-orange","text-white"],[1,"text-end","border-end"],[3,"routerLink","queryParams","ngClass"],[1,"table-footer"],["colspan","2",1,"text-end"],[1,"text-end","bg-orange","text-white"],[1,"text-end"],[2,"cursor","pointer",3,"click"],["title","Retreive rows count",1,"border","p-3"],["role","button","title","Load more for 500 variants",1,"btn","btn-outline-secondary","btn-sm","text-primary",3,"click"],[1,"fa-solid","fa-arrow-right"],["role","button","title","Load all products",1,"btn","btn-outline-secondary","btn-sm","text-primary",3,"click"],[1,"fa-solid","fa-share"]],template:function(e,o){1&e&&t.YNc(0,qa,45,19,"mainpanel-cmp",0),2&e&&t.Q6J("ngIf",o.data)},directives:[_.O5,g.p,x.yS,f.w9,l.JJ,l.On,f.ir,L.QB,K.f,ma.$_,xa.Hq,Q.J,M.P,h.YE,h.nU,_.sg,_.mk],pipes:[_.uU,_.JJ],styles:["datepicker[_ngcontent-%COMP%] mat-form-field.mat-form-field {\n width: 100%;\n}\n\ntable.table[_ngcontent-%COMP%] .bg-orange[_ngcontent-%COMP%] {\n color: #805715 !important;\n background-color: #fdeed4;\n border-color: #fce7c3;\n}\n\ntimepicker[_ngcontent-%COMP%] input {\n width: 100%;\n padding: 6px;\n border: 1px solid #ced4da;\n border-radius: 2px;\n}"]}),n})();function wa(n,i){if(1&n){const e=t.EpF();t.TgZ(0,"a",6),t.NdJ("click",function(){t.CHM(e);const a=t.oxw(2);return a.exportCSV(a.csvConverter,"Inventory/GetinventoryTrafficDetailedByLog","Inventory_Movement.csv")}),t._UZ(1,"i",7),t._uU(2," Export "),t.qZA()}}function Fa(n,i){if(1&n&&(t.TgZ(0,"span",17),t._uU(1),t.qZA()),2&n){const e=i.item;t.s9C("title",e.Value),t.xp6(1),t.Oqu(e.Value)}}function Ua(n,i){if(1&n){const e=t.EpF();t.TgZ(0,"div",8)(1,"div")(2,"h6"),t._uU(3,"Outlet"),t.qZA(),t.TgZ(4,"ng-select",9),t.NdJ("ngModelChange",function(a){return t.CHM(e),t.oxw(2).pageData.Filter.EntityID=a}),t.qZA()(),t.TgZ(5,"div")(6,"h6"),t._uU(7,"Category"),t.qZA(),t.TgZ(8,"ng-select",10),t.NdJ("ngModelChange",function(a){return t.CHM(e),t.oxw(2).pageData.Filter.CategoryID=a}),t.YNc(9,Fa,2,2,"ng-template",11),t.qZA()(),t.TgZ(10,"div")(11,"h6"),t._uU(12,"Group"),t.qZA(),t.TgZ(13,"ng-select",12),t.NdJ("ngModelChange",function(a){return t.CHM(e),t.oxw(2).pageData.Filter.EntityGroupID=a}),t.qZA()(),t.TgZ(14,"div")(15,"h6"),t._uU(16,"Supplier"),t.qZA(),t.TgZ(17,"autocompleteV2",13),t.NdJ("ngModelChange",function(a){return t.CHM(e),t.oxw(2).pageData.Filter.SupplierID=a}),t.qZA()(),t.TgZ(18,"div")(19,"h6"),t._uU(20,"From/To"),t.qZA(),t.TgZ(21,"datepicker",14),t.NdJ("dateChange",function(a){return t.CHM(e),t.oxw(2).pageData.Filter.From=a}),t.qZA(),t.TgZ(22,"datepicker",15),t.NdJ("dateChange",function(a){return t.CHM(e),t.oxw(2).pageData.Filter.To=a}),t.qZA()(),t.TgZ(23,"div")(24,"h6"),t._uU(25,"Options"),t.qZA(),t.TgZ(26,"radio-options",16),t.NdJ("modelChange",function(a){return t.CHM(e),t.oxw(2).pageData.Filter.DisplayMode=a}),t.qZA()()()}if(2&n){const e=t.oxw(2);t.xp6(4),t.Q6J("items",null==e.pageData.Options?null:e.pageData.Options.Entities)("multiple",!0)("ngModel",e.pageData.Filter.EntityID),t.xp6(4),t.Q6J("items",null==e.pageData.Options?null:e.pageData.Options.Categories)("ngModel",e.pageData.Filter.CategoryID),t.xp6(5),t.Q6J("items",null==e.pageData.Options?null:e.pageData.Options.EntityGroups)("ngModel",e.pageData.Filter.EntityGroupID),t.xp6(4),t.Q6J("ngModel",e.pageData.Filter.SupplierID),t.xp6(4),t.Q6J("date",e.pageData.Filter.From),t.xp6(1),t.Q6J("date",e.pageData.Filter.To),t.xp6(4),t.Q6J("model",e.pageData.Filter.DisplayMode)("options",e.pageData.Options.DisplayModes)}}function La(n,i){1&n&&(t.TgZ(0,"th",44),t._uU(1,"D - In"),t.qZA())}function Ja(n,i){1&n&&(t.TgZ(0,"th",45),t._uU(1," D - Out"),t.qZA())}function Na(n,i){1&n&&(t.TgZ(0,"th",46),t._uU(1,"M - In"),t.qZA())}function Sa(n,i){1&n&&(t.TgZ(0,"th",47),t._uU(1,"M - Out"),t.qZA())}function Qa(n,i){1&n&&(t.TgZ(0,"th",48),t._uU(1,"S +"),t.qZA())}function Pa(n,i){1&n&&(t.TgZ(0,"th",49),t._uU(1,"S -"),t.qZA())}function ka(n,i){if(1&n&&(t.TgZ(0,"td",41),t._uU(1),t.ALo(2,"number"),t.qZA()),2&n){const e=t.oxw().$implicit;t.xp6(1),t.hij(" ",t.lcZ(2,1,e.TransferedIn)," ")}}function Ea(n,i){if(1&n&&(t.TgZ(0,"td",40),t._uU(1),t.ALo(2,"number"),t.qZA()),2&n){const e=t.oxw().$implicit;t.xp6(1),t.hij(" ",t.lcZ(2,1,e.TransferedOut)," ")}}function Ba(n,i){if(1&n&&(t.TgZ(0,"td",41),t._uU(1),t.ALo(2,"number"),t.qZA()),2&n){const e=t.oxw().$implicit;t.xp6(1),t.hij(" ",t.lcZ(2,1,e.Produce)," ")}}function Va(n,i){if(1&n&&(t.TgZ(0,"td",40),t._uU(1),t.ALo(2,"number"),t.qZA()),2&n){const e=t.oxw().$implicit;t.xp6(1),t.hij(" ",t.lcZ(2,1,e.Manufacture)," ")}}function Ya(n,i){if(1&n&&(t.TgZ(0,"td",41),t._uU(1),t.ALo(2,"number"),t.qZA()),2&n){const e=t.oxw().$implicit;t.xp6(1),t.hij(" ",t.lcZ(2,1,e.SplitFromParent)," ")}}function Ha(n,i){if(1&n&&(t.TgZ(0,"td",40),t._uU(1),t.ALo(2,"number"),t.qZA()),2&n){const e=t.oxw().$implicit;t.xp6(1),t.hij(" ",t.lcZ(2,1,e.Splittochild)," ")}}const Ra=function(){return["/menu/Products/Catalog/Variants/Info"]},tt=function(n){return{ID:n}},ja=function(){return["/menu/Products/Catalog/Variants/Log"]};function Ga(n,i){if(1&n&&(t.TgZ(0,"tr")(1,"td",50)(2,"a",51),t._uU(3),t.qZA()(),t.TgZ(4,"td",52),t._uU(5),t.qZA(),t.TgZ(6,"td",39),t._uU(7),t.qZA(),t.TgZ(8,"td",40),t._uU(9),t.ALo(10,"number"),t.qZA(),t.TgZ(11,"td",41),t._uU(12),t.ALo(13,"number"),t.qZA(),t.YNc(14,ka,3,3,"td",42),t.YNc(15,Ea,3,3,"td",43),t.YNc(16,Ba,3,3,"td",42),t.YNc(17,Va,3,3,"td",43),t.TgZ(18,"td",41),t._uU(19),t.ALo(20,"number"),t.qZA(),t.YNc(21,Ya,3,3,"td",42),t.YNc(22,Ha,3,3,"td",43),t.TgZ(23,"td",39),t._uU(24),t.qZA(),t.TgZ(25,"td",39)(26,"a",51),t._uU(27),t.ALo(28,"number"),t.qZA()()()),2&n){const e=i.$implicit,o=t.oxw(3);t.xp6(2),t.Q6J("routerLink",t.DdM(26,Ra))("queryParams",t.VKq(27,tt,e.ID)),t.xp6(1),t.Oqu(e.Name),t.xp6(2),t.Oqu(e.Code),t.xp6(2),t.Oqu(e.Start),t.xp6(2),t.hij("",t.lcZ(10,18,e.Sold)," "),t.xp6(3),t.hij("",t.lcZ(13,20,e.Received)," "),t.xp6(2),t.Q6J("ngIf",o.pageData.HasRoleDelivery),t.xp6(1),t.Q6J("ngIf",o.pageData.HasRoleDelivery),t.xp6(1),t.Q6J("ngIf",o.data.ShowData.ManufactureIN&&o.pageData.HasRoleManufacture),t.xp6(1),t.Q6J("ngIf",o.data.ShowData.ManufactureOut&&o.pageData.HasRoleManufacture),t.xp6(2),t.hij("",t.lcZ(20,22,e.Adjustment)," "),t.xp6(2),t.Q6J("ngIf",o.data.ShowData.SplitFromParent),t.xp6(1),t.Q6J("ngIf",o.data.ShowData.SplitToChild),t.xp6(2),t.Oqu(e.End),t.xp6(2),t.Q6J("routerLink",t.DdM(29,ja))("queryParams",t.VKq(30,tt,e.ID)),t.xp6(1),t.Oqu(t.lcZ(28,24,e.Now))}}function Wa(n,i){if(1&n&&(t.TgZ(0,"td",41),t._uU(1),t.ALo(2,"number"),t.ALo(3,"sum"),t.qZA()),2&n){const e=t.oxw(3);t.xp6(1),t.hij(" ",t.lcZ(2,1,t.xi3(3,3,e.data.Data,"TransferedIn"))," ")}}function $a(n,i){if(1&n&&(t.TgZ(0,"td",40),t._uU(1),t.ALo(2,"number"),t.ALo(3,"sum"),t.qZA()),2&n){const e=t.oxw(3);t.xp6(1),t.hij(" ",t.lcZ(2,1,t.xi3(3,3,e.data.Data,"TransferedOut"))," ")}}function Ka(n,i){if(1&n&&(t.TgZ(0,"td",41),t._uU(1),t.ALo(2,"number"),t.ALo(3,"sum"),t.qZA()),2&n){const e=t.oxw(3);t.xp6(1),t.hij(" ",t.lcZ(2,1,t.xi3(3,3,e.data.Data,"Produce"))," ")}}function za(n,i){if(1&n&&(t.TgZ(0,"td",40),t._uU(1),t.ALo(2,"number"),t.ALo(3,"sum"),t.qZA()),2&n){const e=t.oxw(3);t.xp6(1),t.hij(" ",t.lcZ(2,1,t.xi3(3,3,e.data.Data,"Manufacture"))," ")}}function Xa(n,i){if(1&n&&(t.TgZ(0,"td",41),t._uU(1),t.ALo(2,"number"),t.ALo(3,"sum"),t.qZA()),2&n){const e=t.oxw(3);t.xp6(1),t.hij(" ",t.lcZ(2,1,t.xi3(3,3,e.data.Data,"SplitFromParent"))," ")}}function to(n,i){if(1&n&&(t.TgZ(0,"td",40),t._uU(1),t.ALo(2,"number"),t.ALo(3,"sum"),t.qZA()),2&n){const e=t.oxw(3);t.xp6(1),t.hij(" ",t.lcZ(2,1,t.xi3(3,3,e.data.Data,"Splittochild"))," ")}}function eo(n,i){if(1&n){const e=t.EpF();t.TgZ(0,"div",18)(1,"div",19)(2,"table",20),t.NdJ("matSortChange",function(a){return t.CHM(e),t.oxw(2).sortData(a)}),t.TgZ(3,"thead",21)(4,"tr")(5,"th",22),t._uU(6,"Name"),t.qZA(),t.TgZ(7,"th",23),t._uU(8,"Code"),t.qZA(),t.TgZ(9,"th",24),t._uU(10),t.ALo(11,"date"),t.qZA(),t.TgZ(12,"th",25),t._uU(13,"Sold"),t.qZA(),t.TgZ(14,"th",26),t._uU(15,"Bought"),t.qZA(),t.YNc(16,La,2,0,"th",27),t.YNc(17,Ja,2,0,"th",28),t.YNc(18,Na,2,0,"th",29),t.YNc(19,Sa,2,0,"th",30),t.TgZ(20,"th",31),t._uU(21,"Adjust"),t.qZA(),t.YNc(22,Qa,2,0,"th",32),t.YNc(23,Pa,2,0,"th",33),t.TgZ(24,"th",24),t._uU(25),t.ALo(26,"date"),t.qZA(),t.TgZ(27,"th",34),t._uU(28,"Now"),t.qZA()()(),t.TgZ(29,"tbody"),t.YNc(30,Ga,29,32,"tr",35),t.qZA(),t.TgZ(31,"tfoot")(32,"tr",36)(33,"td",37),t._uU(34),t.qZA(),t.TgZ(35,"td",38),t._uU(36,"Total:"),t.qZA(),t.TgZ(37,"td",39),t._uU(38),t.ALo(39,"number"),t.ALo(40,"sum"),t.qZA(),t.TgZ(41,"td",40),t._uU(42),t.ALo(43,"number"),t.ALo(44,"sum"),t.qZA(),t.TgZ(45,"td",41),t._uU(46),t.ALo(47,"number"),t.ALo(48,"sum"),t.qZA(),t.YNc(49,Wa,4,6,"td",42),t.YNc(50,$a,4,6,"td",43),t.YNc(51,Ka,4,6,"td",42),t.YNc(52,za,4,6,"td",43),t.TgZ(53,"td",41),t._uU(54),t.ALo(55,"number"),t.ALo(56,"sum"),t.qZA(),t.YNc(57,Xa,4,6,"td",42),t.YNc(58,to,4,6,"td",43),t.TgZ(59,"td",39),t._uU(60),t.ALo(61,"number"),t.ALo(62,"sum"),t.qZA(),t.TgZ(63,"td",41),t._uU(64),t.ALo(65,"number"),t.ALo(66,"sum"),t.qZA()()()()()()}if(2&n){const e=t.oxw(2);t.xp6(10),t.hij("",t.xi3(11,22,e.data.From,"ddMMM")," "),t.xp6(6),t.Q6J("ngIf",e.pageData.HasRoleDelivery),t.xp6(1),t.Q6J("ngIf",e.pageData.HasRoleDelivery),t.xp6(1),t.Q6J("ngIf",e.data.ShowData.ManufactureIN&&e.pageData.HasRoleManufacture),t.xp6(1),t.Q6J("ngIf",e.data.ShowData.ManufactureOut&&e.pageData.HasRoleManufacture),t.xp6(3),t.Q6J("ngIf",e.data.ShowData.SplitFromParent),t.xp6(1),t.Q6J("ngIf",e.data.ShowData.SplitToChild),t.xp6(2),t.hij("",t.xi3(26,25,e.data.To,"ddMMM")," "),t.xp6(5),t.Q6J("ngForOf",e.data.Data),t.xp6(4),t.hij("",e.data.Data.length," items"),t.xp6(4),t.hij("",t.lcZ(39,28,t.xi3(40,30,e.data.Data,"Start"))," "),t.xp6(4),t.hij("",t.lcZ(43,33,t.xi3(44,35,e.data.Data,"Sold"))," "),t.xp6(4),t.hij("",t.lcZ(47,38,t.xi3(48,40,e.data.Data,"Received"))," "),t.xp6(3),t.Q6J("ngIf",e.pageData.HasRoleDelivery),t.xp6(1),t.Q6J("ngIf",e.pageData.HasRoleDelivery),t.xp6(1),t.Q6J("ngIf",e.data.ShowData.ManufactureIN&&e.pageData.HasRoleManufacture),t.xp6(1),t.Q6J("ngIf",e.data.ShowData.ManufactureOut&&e.pageData.HasRoleManufacture),t.xp6(2),t.hij("",t.lcZ(55,43,t.xi3(56,45,e.data.Data,"Adjustment"))," "),t.xp6(3),t.Q6J("ngIf",e.data.ShowData.SplitFromParent),t.xp6(1),t.Q6J("ngIf",e.data.ShowData.SplitToChild),t.xp6(2),t.hij("",t.lcZ(61,48,t.xi3(62,50,e.data.Data,"End"))," "),t.xp6(4),t.hij("",t.lcZ(65,53,t.xi3(66,55,e.data.Data,"Now"))," ")}}const no=function(){return["/menu/Inventory/Quantity/Timeline"]};function ao(n,i){if(1&n){const e=t.EpF();t.TgZ(0,"mainpanel-cmp",1),t.NdJ("textChange",function(a){return t.CHM(e),t.oxw().pageData.Filter.Text=a})("onSubmit",function(){return t.CHM(e),t.oxw().searchFromPageOne()}),t.TgZ(1,"actions"),t.YNc(2,wa,3,0,"a",2),t.TgZ(3,"a",3),t._uU(4,"Inventory Timeline"),t.qZA()(),t.TgZ(5,"filters"),t.YNc(6,Ua,27,12,"div",4),t.qZA(),t.TgZ(7,"content"),t.YNc(8,eo,67,58,"div",5),t.qZA()()}if(2&n){const e=t.oxw();t.Q6J("pageData",e.menuData)("text",e.pageData.Filter.Text)("hidesearch",!0),t.xp6(2),t.Q6J("ngIf",e.pageData.HasRoleExport),t.xp6(1),t.Q6J("routerLink",t.DdM(7,no)),t.xp6(3),t.Q6J("ngIf",null==e.pageData?null:e.pageData.Filter),t.xp6(2),t.Q6J("ngIf",e.data)}}let oo=(()=>{class n extends A.n{constructor(e,o,a){super(e,"Inventory/GetinventoryTrafficDetailedByLog","InventoryLoader/GetinventoryTrafficDetailed",o),this.httpService=e,this.csvConverter=a}preGetList(){this.pageData.Filter.Export=!1}sortData(e){const o=this.data.Data.slice();this.data.Data=e.active&&""!==e.direction?o.sort((a,r)=>{const p="asc"===e.direction;switch(a.Code=null==a.Code?"":a.Code,r.Code=null==r.Code?"":r.Code,e.active){case"Name":return this.compare(a.Name.toLocaleLowerCase(),r.Name.toLocaleLowerCase(),p);case"Code":return this.compare(a.Code.toLocaleLowerCase(),r.Code.toLocaleLowerCase(),p);default:return 0}}):o}}return n.\u0275fac=function(e){return new(e||n)(t.Y36(d.O),t.Y36(w._W),t.Y36(C.O))},n.\u0275cmp=t.Xpm({type:n,selectors:[["POS-Product-inventory-traffic-Log"]],features:[t.qOj],decls:1,vars:1,consts:[["filterWidth","270px",3,"pageData","text","hidesearch","textChange","onSubmit",4,"ngIf"],["filterWidth","270px",3,"pageData","text","hidesearch","textChange","onSubmit"],["class","btn btn-outline-secondary me-6",3,"click",4,"ngIf"],["title","Switch to View",1,"button","btn","btn-success",3,"routerLink"],["container","","class","w-100",4,"ngIf"],["class","container-fluid mt-3",4,"ngIf"],[1,"btn","btn-outline-secondary","me-6",3,"click"],["aria-hidden","true",1,"fa-solid","fa-upload"],["container","",1,"w-100"],["bindLabel","Name","bindValue","ID","placeholder","Choose...",3,"items","multiple","ngModel","ngModelChange"],["bindLabel","Value","bindValue","Key","placeholder","Choose...",3,"items","ngModel","ngModelChange"],["ng-option-tmp",""],["bindLabel","Name","bindValue","ID","placeholder","Choose...",3,"items","ngModel","ngModelChange"],["inputID","ContactID","requestUrl","/API/AC/GetSupplierSuggestion",1,"w-100",3,"ngModel","ngModelChange"],["name","From",3,"date","dateChange"],["name","To",3,"date","dateChange"],["name","DisplayMode",3,"model","options","modelChange"],[3,"title"],[1,"container-fluid","mt-3"],[1,"table-responsive"],["id","tableGrid","matSort","",1,"table","border-bottom",3,"matSortChange"],[1,"thead-light","sticky-top-thead"],["mat-sort-header","Name",1,"border-start","border-end"],["mat-sort-header","Code",1,"border-end",2,"width","120px"],[1,"text-end","border-end",2,"width","4.375\u202crem"],["title","Sell",1,"text-end","border-end",2,"width","70px"],["title","Buy",1,"text-end","border-end",2,"width","70px"],["class","text-end border-end","style","width: 70px","title","Delivery In",4,"ngIf"],["class","text-end border-end","style","width: 70px","title","Delivery Out",4,"ngIf"],["class","text-end border-end","style","width: 70px","title","Raw Material used for Manufacturing",4,"ngIf"],["class","text-end border-end","style","width: 70px","title","Goods produced on Manufacturing",4,"ngIf"],[1,"text-end","border-end",2,"width","70px"],["class","text-end border-end","style","width: 70px","title","Split from parent",4,"ngIf"],["class","text-end border-end","style","width: 70px","title","Split to child",4,"ngIf"],[1,"text-end",2,"width","70px"],[4,"ngFor","ngForOf"],[1,"table-footer"],[1,"text-start","border-start","border-end"],[1,"text-end","empty-column","border-end"],[1,"text-end","border-end"],[1,"text-end","text-danger","border-end"],[1,"text-end","text-success","border-end"],["class","text-end text-success border-end",4,"ngIf"],["class","text-end text-danger border-end",4,"ngIf"],["title","Delivery In",1,"text-end","border-end",2,"width","70px"],["title","Delivery Out",1,"text-end","border-end",2,"width","70px"],["title","Raw Material used for Manufacturing",1,"text-end","border-end",2,"width","70px"],["title","Goods produced on Manufacturing",1,"text-end","border-end",2,"width","70px"],["title","Split from parent",1,"text-end","border-end",2,"width","70px"],["title","Split to child",1,"text-end","border-end",2,"width","70px"],[1,"border-start","border-end"],[3,"routerLink","queryParams"],[1,"border-end"]],template:function(e,o){1&e&&t.YNc(0,ao,9,8,"mainpanel-cmp",0),2&e&&t.Q6J("ngIf",o.pageData.Filter)},directives:[_.O5,g.p,x.yS,f.w9,l.JJ,l.On,f.ir,Q.J,L.QB,M.P,h.YE,h.nU,_.sg],pipes:[_.uU,_.JJ,F.qU],styles:['thead[_ngcontent-%COMP%] tr[_ngcontent-%COMP%] {\n border: none !important;\n}\nthead[_ngcontent-%COMP%] tr[_ngcontent-%COMP%] th[_ngcontent-%COMP%]::after, thead[_ngcontent-%COMP%] tr[_ngcontent-%COMP%] th[_ngcontent-%COMP%]::before {\n content: "";\n position: absolute;\n left: 0;\n width: 100%;\n z-index: -1;\n}\nthead[_ngcontent-%COMP%] tr[_ngcontent-%COMP%] th[_ngcontent-%COMP%]:first-child::before {\n height: 100%;\n border-left: 1px solid #ddd;\n}\nthead[_ngcontent-%COMP%] tr[_ngcontent-%COMP%] th[_ngcontent-%COMP%]:last-child::after {\n height: 100%;\n border-right: 1px solid #ddd;\n}\nthead[_ngcontent-%COMP%] tr[_ngcontent-%COMP%] th[_ngcontent-%COMP%]::before {\n top: 0px;\n border-top: 1px solid #ddd;\n}\nthead[_ngcontent-%COMP%] tr[_ngcontent-%COMP%] th[_ngcontent-%COMP%]::after {\n bottom: -1px;\n border-bottom: 1px solid #ddd;\n}\nthead[_ngcontent-%COMP%] tr[_ngcontent-%COMP%]:first-child th[_ngcontent-%COMP%] {\n position: sticky;\n top: 60px;\n z-index: 1021;\n}\nthead[_ngcontent-%COMP%] tr[_ngcontent-%COMP%]:last-child th[_ngcontent-%COMP%] {\n position: sticky;\n z-index: 1021;\n}\n@media screen and (max-width: 991px) {\n thead[_ngcontent-%COMP%] tr[_ngcontent-%COMP%]:first-child {\n top: 0px;\n }\n thead[_ngcontent-%COMP%] tr[_ngcontent-%COMP%]:last-child {\n top: 41px;\n }\n}']}),n})();function io(n,i){if(1&n&&(t.TgZ(0,"span",16),t._uU(1),t.qZA()),2&n){const e=i.item;t.s9C("title",e.Value),t.xp6(1),t.Oqu(e.Value)}}const ro=function(){return["/menu/Products/Catalog/Variants/Info"]},lo=function(n){return{ID:n}},_o=function(){return["/menu/Orders/Delivery/Products_to_Receive"]},po=function(n,i){return{ID:n,Name:i}};function co(n,i){if(1&n&&(t.TgZ(0,"tr")(1,"td")(2,"a",17),t._uU(3),t.qZA()(),t.TgZ(4,"td"),t._uU(5),t.qZA(),t.TgZ(6,"td"),t._uU(7),t.qZA(),t.TgZ(8,"td",18),t._uU(9),t.qZA(),t.TgZ(10,"td",18)(11,"a",17),t._uU(12),t.qZA()(),t.TgZ(13,"td",18),t._uU(14),t.qZA()()),2&n){const e=i.$implicit;t.xp6(2),t.Q6J("routerLink",t.DdM(10,ro))("queryParams",t.VKq(11,lo,e.ID)),t.xp6(1),t.Oqu(e.Name),t.xp6(2),t.Oqu(e.Code),t.xp6(2),t.Oqu(e.CategoryName),t.xp6(2),t.Oqu(e.UnitsInStock),t.xp6(2),t.Q6J("routerLink",t.DdM(13,_o))("queryParams",t.WLB(14,po,e.ID,e.Name)),t.xp6(1),t.Oqu(e.Awaiting),t.xp6(2),t.Oqu(e.Future)}}function uo(n,i){if(1&n){const e=t.EpF();t.TgZ(0,"mainpanel-cmp",1),t.NdJ("onSubmit",function(){return t.CHM(e),t.oxw().searchFromPageOne()}),t.TgZ(1,"actions")(2,"a",2),t.NdJ("click",function(){t.CHM(e);const a=t.oxw();return a.convertToCSV(a.csvConverter,a.data,"InventoryAwaiting.csv")}),t._UZ(3,"i",3),t._uU(4," Export"),t.qZA()(),t.TgZ(5,"filters")(6,"div",4)(7,"div")(8,"h6"),t._uU(9,"Outlet"),t.qZA(),t.TgZ(10,"ng-select",5),t.NdJ("ngModelChange",function(a){return t.CHM(e),t.oxw().pageData.Filter.EntityID=a}),t.qZA()(),t.TgZ(11,"div")(12,"h6"),t._uU(13,"Category"),t.qZA(),t.TgZ(14,"ng-select",6),t.NdJ("ngModelChange",function(a){return t.CHM(e),t.oxw().pageData.Filter.CategoryID=a}),t.YNc(15,io,2,2,"ng-template",7),t.qZA()()()(),t.TgZ(16,"content")(17,"div",8)(18,"div",9)(19,"table",10)(20,"thead",11)(21,"tr")(22,"th",12),t._uU(23,"Name"),t.qZA(),t.TgZ(24,"th",13),t._uU(25,"Code"),t.qZA(),t.TgZ(26,"th",13),t._uU(27,"Category"),t.qZA(),t.TgZ(28,"th",14),t._uU(29,"On Hand"),t.qZA(),t.TgZ(30,"th",14),t._uU(31,"Awaiting"),t.qZA(),t.TgZ(32,"th",14),t._uU(33,"Future"),t.qZA()()(),t.TgZ(34,"tbody"),t.YNc(35,co,15,17,"tr",15),t.qZA()()()()()()}if(2&n){const e=t.oxw();t.Q6J("pageData",e.menuData)("hideSearchBox",!0),t.xp6(10),t.Q6J("multiple",!0)("items",null==e.pageData.Options?null:e.pageData.Options.Entities)("ngModel",e.pageData.Filter.EntityID),t.xp6(4),t.Q6J("items",null==e.pageData.Options?null:e.pageData.Options.Categories)("ngModel",e.pageData.Filter.CategoryID),t.xp6(21),t.Q6J("ngForOf",e.data)}}const so=[{path:"",component:H},{path:"Quantity/Valuation",component:H},{path:"Quantity/Detail/Summary",component:It},{path:"Quantity/Outlet_Inventory",component:Mt},{path:"Quantity/Product_By_Outlet/Category_By_Outlet",component:be},{path:"Quantity/Product_By_Outlet",component:ge},{path:"Quantity/Product_By_Outlet/Product_By_Outlet_Group",component:Rt},{path:"Quantity/Highest_Quantity",component:Ne},{path:"Quantity/Low_On_Stock",component:Re},{path:"Quantity/In_Transit",component:ze},{path:"Quantity/Allocated_Inventory",component:_n},{path:"Quantity/Awaiting_Inventory",component:(()=>{class n extends A.n{constructor(e,o,a){super(e,"Inventory/InventoryAwaiting","InventoryLoader/InventoryAwaiting",o),this.httpService=e,this.csvConverter=a}}return n.\u0275fac=function(e){return new(e||n)(t.Y36(d.O),t.Y36(w._W),t.Y36(C.O))},n.\u0275cmp=t.Xpm({type:n,selectors:[["CustomerDisplay-awaiting-inventory"]],features:[t.qOj],decls:1,vars:1,consts:[["filterWidth","270px",3,"pageData","hideSearchBox","onSubmit",4,"ngIf"],["filterWidth","270px",3,"pageData","hideSearchBox","onSubmit"],["role","button","value","Export","title","Export",1,"btn","btn-outline-secondary",3,"click"],["aria-hidden","true",1,"fa","fa-upload"],["container","",1,"w-100"],["bindLabel","Name","bindValue","ID","placeholder","Choose...",1,"w-100",3,"multiple","items","ngModel","ngModelChange"],["bindLabel","Value","bindValue","Key","placeholder","Choose...",3,"items","ngModel","ngModelChange"],["ng-option-tmp",""],[1,"container-fluid","mt-3"],[1,"table-responsive"],["id","tableGrid",1,"table","border-bottom"],[1,"thead-light","sticky-top-thead"],[2,"width","150px"],[2,"width","60px"],[1,"text-end",2,"width","60px"],[4,"ngFor","ngForOf"],[3,"title"],[3,"routerLink","queryParams"],[1,"text-end"]],template:function(e,o){1&e&&t.YNc(0,uo,36,8,"mainpanel-cmp",0),2&e&&t.Q6J("ngIf",o.data)},directives:[_.O5,g.p,f.w9,l.JJ,l.On,f.ir,_.sg,x.yS],styles:[""]}),n})()},{path:"Quantity/Timeline/Detailed_Inventory_Traffic_Log",component:oo},{path:"Inventory_Traffic/Inventory_Order_By_Composite",component:Bn},{path:"Inventory_Traffic/Category_Inventory_Traffic",component:mn},{path:"Inventory_Traffic/Outlet_Inventory_Traffic",component:vn},{path:"Inventory_Traffic/Outlet_Inventory_Traffic/Outlet_Inventory_Traffic_Summary",component:Wn},{path:"Inventory_Traffic/FIFO_Illustration",component:wn},{path:"Advanced/Serial_Inventory",component:ga},{path:"Advanced/Depleting_Inventory",component:aa},{path:"Advanced/Negative",component:Sn},{path:"Quantity/Timeline",component:Ma}];let go=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=t.oAB({type:n}),n.\u0275inj=t.cJS({imports:[[x.Bz.forChild(so)],x.Bz]}),n})();var mo=c(3077),xo=c(65131),ho=c(29772);let fo=(()=>{class n{}return n.\u0275fac=function(e){return new(e||n)},n.\u0275mod=t.oAB({type:n}),n.\u0275inj=t.cJS({imports:[[g.R,_.ez,F.dr,l.u5,go,m.Fk,l.UX,O.FA,T.XK,m.Fk,y.c,T.Ng,Z.Nh,I.TU,q.vV,f.A0,h.JX,b.p0,L.ZU,M.K,K._8,Q.Q,mo.T,xo.X,ho.AV]]}),n})()},50:(k,N,c)=>{c.d(N,{M:()=>b});var _=c(67327),l=c(5e3),h=c(32442);let b=(()=>{class O{constructor(m){this.httpService=m}generateNumber(m,y){return this.httpService.post(y,JSON.stringify({ID:m}))}getQuickKey(m,y){return this.httpService.post(y,JSON.stringify(m))}updateCourierList(m){return this.httpService.post(_.Wz.UpdateCourierList,JSON.stringify({name:m}))}getVarianByCode(m,y,Z){return this.httpService.post(_.Wz.GetVariantByCode,{code:m,entityID:y,barcodeSerial:Z,Promotion:!0})}getVariantById(m,y){return this.httpService.post(_.Wz.GetVariantByID,{id:m,entityID:y})}submitTransaction(m,y){return this.httpService.post(y,m)}getPrintTemplateID(m){return this.httpService.post(_.Wz.GetPrintTemplateID,JSON.stringify(m))}createNewContact(m,y){const Z=[];return m.Group&&Z.push(m.Group),this.httpService.post(_.Wz.CreateContact,{contact:m,type:y,groups:Z})}getItemStock(m,y){return this.httpService.post(_.Wz.GetVariantStockByID,{id:m,entityID:y})}clearOutlet(m){return this.httpService.post("/api/Delivery/ClearOutlet",JSON.stringify(m))}}return O.\u0275fac=function(m){return new(m||O)(l.LFG(h.O))},O.\u0275prov=l.Yz7({token:O,factory:O.\u0275fac,providedIn:"root"}),O})()},3077:(k,N,c)=>{c.d(N,{v:()=>q,T:()=>x});var _=c(69808),l=c(5e3),h=c(93075),b=c(32442);function O(s,D){if(1&s&&(l.TgZ(0,"span"),l._uU(1),l.qZA()),2&s){const t=l.oxw();l.xp6(1),l.AsE(" Showing ",t.pageData.Filter.PageNumber*t.total-t.total+1," - ",t.pageData.Filter.PageNumber*t.total," ")}}function T(s,D){if(1&s&&(l.TgZ(0,"span"),l._uU(1),l.qZA()),2&s){const t=l.oxw();l.xp6(1),l.AsE(" Showing ",t.pageData.Filter.RowCount*t.pageData.Filter.PageNumber-t.pageData.Filter.RowCount+1," - ",t.pageData.Filter.RowCount*t.pageData.Filter.PageNumber-t.pageData.Filter.RowCount+t.total," ")}}function m(s,D){if(1&s){const t=l.EpF();l.TgZ(0,"span",8),l.NdJ("click",function(){return l.CHM(t),l.oxw().StoreRowsCountAPIResult()}),l.TgZ(1,"i",9),l._uU(2,"?"),l.qZA()()}}function y(s,D){if(1&s&&(l.TgZ(0,"span"),l._uU(1),l.ALo(2,"number"),l.qZA()),2&s){const t=l.oxw();l.xp6(1),l.hij(" of ",l.lcZ(2,1,t.listTotal),"")}}function Z(s,D){if(1&s){const t=l.EpF();l.TgZ(0,"a",10),l.NdJ("click",function(){return l.CHM(t),l.oxw().onPreviousPage()}),l._UZ(1,"i",11),l._uU(2," Previous"),l.qZA()}}function I(s,D){if(1&s){const t=l.EpF();l.TgZ(0,"a",10),l.NdJ("click",function(){return l.CHM(t),l.oxw().onNextPage()}),l._UZ(1,"i",12),l._uU(2," Next"),l.qZA()}}let q=(()=>{class s{constructor(t){this.httpService=t,this.jumpToPage=new l.vpe,this.previousPage=new l.vpe,this.nextPage=new l.vpe,this.pageNumber=1,this.showingNumber=this.pageNumber,this.listTotal=-1}onJumpToPage(t){"Enter"===t.key&&(this.pageData.Filter.PageNumber=this.pageNumber,this.showingNumber=this.pageNumber,this.jumpToPage.emit())}onPreviousPage(){this.pageData.Filter.PageNumber-=1,this.pageNumber=this.pageData.Filter.PageNumber,this.showingNumber=this.pageNumber,this.previousPage.emit()}onNextPage(){this.pageData.Filter.PageNumber+=1,this.pageNumber=this.pageData.Filter.PageNumber,this.showingNumber=this.pageNumber,this.nextPage.emit()}StoreRowsCountAPIResult(){this.httpService.post("/api/"+this.api,JSON.stringify(this.pageData.Filter)).subscribe(t=>{this.listTotal=t.Count?t.Count:t,this.pageData.HideStoreApiCount=!0})}}return s.\u0275fac=function(t){return new(t||s)(l.Y36(b.O))},s.\u0275cmp=l.Xpm({type:s,selectors:[["POS-complex-pagination"]],inputs:{pageData:"pageData",total:"total",api:"api"},outputs:{jumpToPage:"jumpToPage",previousPage:"previousPage",nextPage:"nextPage"},decls:12,vars:7,consts:[[1,"d-flex","justify-content-between","mt-5"],[1,"me-auto","d-sm-block","collapse","mt-3"],[1,"fw-bold","fst-italic","hidden-xxs"],[4,"ngIf"],["style","cursor: pointer",3,"click",4,"ngIf"],["type","number","autoNum","",1,"text-end",2,"width","45px",3,"ngModel","keyup","ngModelChange"],[1,"btn-group"],["class","btn btn-outline-secondary btn-sm text-primary",3,"click",4,"ngIf"],[2,"cursor","pointer",3,"click"],[1,"border","p-3"],[1,"btn","btn-outline-secondary","btn-sm","text-primary",3,"click"],[1,"fa-solid","fa-arrow-left"],[1,"fa-solid","fa-arrow-right"]],template:function(t,d){1&t&&(l.TgZ(0,"div",0)(1,"div",1)(2,"div",2),l.YNc(3,O,2,2,"span",3),l.YNc(4,T,2,2,"span",3),l.YNc(5,m,3,0,"span",4),l.YNc(6,y,3,3,"span",3),l._uU(7," records ~ Page "),l.TgZ(8,"input",5),l.NdJ("keyup",function(g){return d.onJumpToPage(g)})("ngModelChange",function(g){return d.pageNumber=g}),l.qZA()()(),l.TgZ(9,"div",6),l.YNc(10,Z,3,0,"a",7),l.YNc(11,I,3,0,"a",7),l.qZA()()),2&t&&(l.xp6(3),l.Q6J("ngIf",d.pageData.Filter.RowCount==d.total),l.xp6(1),l.Q6J("ngIf",d.pageData.Filter.RowCount!=d.total),l.xp6(1),l.Q6J("ngIf",!d.pageData.HideStoreApiCount),l.xp6(1),l.Q6J("ngIf",d.pageData.HideStoreApiCount),l.xp6(2),l.Q6J("ngModel",d.pageNumber),l.xp6(2),l.Q6J("ngIf",1!=d.pageData.Filter.PageNumber),l.xp6(1),l.Q6J("ngIf",d.total>=d.pageData.Filter.RowCount))},directives:[_.O5,h.wV,h.Fj,h.JJ,h.On],pipes:[_.JJ],styles:[""]}),s})(),x=(()=>{class s{}return s.\u0275fac=function(t){return new(t||s)},s.\u0275mod=l.oAB({type:s}),s.\u0275inj=l.cJS({imports:[[_.ez,h.u5,h.UX]]}),s})()}}]);