marketplacepos 3.22.6 → 3.22.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.
Files changed (37) hide show
  1. package/Marketplace/{chunk-TKX5EECA.js → chunk-2RZIS7SO.js} +2 -2
  2. package/Marketplace/{chunk-WDZHKT23.js → chunk-34TFHXOV.js} +1 -1
  3. package/Marketplace/{chunk-YNS23F33.js → chunk-3ATLH2O5.js} +1 -1
  4. package/Marketplace/{chunk-ZT6LL6XR.js → chunk-3T6NZ5WH.js} +1 -1
  5. package/Marketplace/{chunk-SW4MFZHR.js → chunk-4MEDGUR4.js} +1 -1
  6. package/Marketplace/{chunk-RL4DLGYC.js → chunk-4WRJ4UNZ.js} +1 -1
  7. package/Marketplace/{chunk-TIZFCLBP.js → chunk-5N4FTVPO.js} +1 -1
  8. package/Marketplace/{chunk-KRCKXDH4.js → chunk-5UKUFSGI.js} +1 -1
  9. package/Marketplace/{chunk-ERQSA4CI.js → chunk-7IV6AOHI.js} +1 -1
  10. package/Marketplace/{chunk-5RFIBP63.js → chunk-DIGP4L5I.js} +2 -2
  11. package/Marketplace/{chunk-FW2WWSWS.js → chunk-DLCEDZGK.js} +1 -1
  12. package/Marketplace/{chunk-ZK2ACEWJ.js → chunk-FK647DV3.js} +1 -1
  13. package/Marketplace/{chunk-U5DTVOAU.js → chunk-HDQ264E7.js} +1 -1
  14. package/Marketplace/{chunk-NK3KLE4Z.js → chunk-I7SRUSWR.js} +1 -1
  15. package/Marketplace/{chunk-TB7F3ZCR.js → chunk-IOHEOTV2.js} +1 -1
  16. package/Marketplace/{chunk-E3RBGXPO.js → chunk-J3APYGWI.js} +1 -1
  17. package/Marketplace/{chunk-5SVULLWJ.js → chunk-LT5ZCJRA.js} +1 -1
  18. package/Marketplace/{chunk-YEYUZNK7.js → chunk-MC7L2DZA.js} +1 -1
  19. package/Marketplace/{chunk-OHREVJW7.js → chunk-N6NC5NSE.js} +1 -1
  20. package/Marketplace/{chunk-POJ574F2.js → chunk-OKZBCK7E.js} +1 -1
  21. package/Marketplace/chunk-ONBGY7D4.js +1 -0
  22. package/Marketplace/{chunk-7FMG3H7T.js → chunk-Q653MB6W.js} +1 -1
  23. package/Marketplace/{chunk-UPGYF4XT.js → chunk-RXU6CAOP.js} +1 -1
  24. package/Marketplace/{chunk-SHUDM2FU.js → chunk-S4LDJFZS.js} +1 -1
  25. package/Marketplace/{chunk-W7EFOXDZ.js → chunk-VJUN2VLY.js} +1 -1
  26. package/Marketplace/{chunk-B37WXGPN.js → chunk-VL6PS3RX.js} +1 -1
  27. package/Marketplace/{chunk-ZZWRH7Y5.js → chunk-VRAOGJWM.js} +1 -1
  28. package/Marketplace/{chunk-DFZNHBOD.js → chunk-WUTL4JBG.js} +1 -1
  29. package/Marketplace/{chunk-EQYCYZMO.js → chunk-WZVZOQN3.js} +1 -1
  30. package/Marketplace/{chunk-CS5RLQNE.js → chunk-XEJDB2R3.js} +1 -1
  31. package/Marketplace/{chunk-ORCZERUP.js → chunk-XIQS2GJ5.js} +1 -1
  32. package/Marketplace/{chunk-FK2V7B6I.js → chunk-Y6ID7JCT.js} +1 -1
  33. package/Marketplace/{chunk-SIELKIYA.js → chunk-YPE5AC3X.js} +1 -1
  34. package/Marketplace/index.html +2 -2
  35. package/Marketplace/{main-7AJHPHM7.js → main-A5PH6KD3.js} +1 -1
  36. package/package.json +1 -1
  37. package/Marketplace/chunk-RGOGXUFL.js +0 -1
package/package.json CHANGED
@@ -1 +1 @@
1
- {"name":"marketplacepos","version":"3.22.6"}
1
+ {"name":"marketplacepos","version":"3.22.7"}
@@ -1 +0,0 @@
1
- import{a as K,b as Q}from"./chunk-IJYSJN63.js";import{Y as $}from"./chunk-OULUJ2IO.js";import{e as q}from"./chunk-4SAJUEHO.js";import{t as H,u as J}from"./chunk-HUUFOAKH.js";import{a as B,h as V,m as R,y as U}from"./chunk-BSN7ZAXG.js";import{b as g,c as s}from"./chunk-64G3XLI6.js";import{$b as N,Ca as _,Cd as j,Eb as S,Gb as b,Gc as z,Hc as W,Nb as F,Pa as I,Sb as C,Tb as m,Z as u,aa as c,bc as M,ea as l,g as d,ia as w,ja as T,jb as y,nc as L,pa as h,pc as A,q as p,rc as E,sc as O,ta as k,tc as D,uc as x,vc as P,xb as f,yd as G}from"./chunk-PQDPS2ID.js";var X=(()=>{let a=class a{constructor(){this.httpService=h(q),this.shopeeCategories=new d({data:[],isFirstLoad:!1}),this.tiktokCategories=new d({data:[],isFirstLoad:!1}),this.lazadaCategories=new d({data:[],isFirstLoad:!1}),this.tokopediaCategories=new d({data:[],isFirstLoad:!1}),this.wooCommerceCategories=new d({data:[],isFirstLoad:!1})}getCategories(t,o){switch(t){case g.Shopee:return this.shopeeCategories.asObservable().pipe(c(e=>e.isFirstLoad?p(e.data):this.getShopeeCategories(o)));case g.Tiktok:return this.tiktokCategories.asObservable().pipe(c(e=>e.isFirstLoad?p(e.data):this.getTiktokCategories(o)));case g.Lazada:return this.lazadaCategories.asObservable().pipe(c(e=>e.isFirstLoad?p(e.data):this.getLazadaCategories(o)));case g.Tokopedia:return this.tokopediaCategories.asObservable().pipe(c(e=>e.isFirstLoad?p(e.data):this.getTokopediaCategories(o)));case g.WooCommerce:return this.wooCommerceCategories.asObservable().pipe(c(e=>e.isFirstLoad?p(e.data):this.getWooCommerceCategories(o)));default:return p([])}}getShopeeCategories(t){return this.httpService.get("api/product/shopee/GetCategories",[{key:"ID",value:t}]).pipe(l(e=>{let i={data:e,isFirstLoad:!0};this.shopeeCategories.next(i)}))}getTiktokCategories(t){return this.httpService.get("api/product/tiktok/GetCategories",[{key:"ID",value:t}]).pipe(l(e=>{let i={data:e,isFirstLoad:!0};this.tiktokCategories.next(i)}))}getLazadaCategories(t){return this.httpService.get("api/product/lazada/GetCategories",[{key:"ID",value:t}]).pipe(l(e=>{let i={data:e,isFirstLoad:!0};this.lazadaCategories.next(i)}))}getTokopediaCategories(t){return this.httpService.get("api/product/tokopedia/GetCategories",[{key:"ID",value:t}]).pipe(l(e=>{let i={data:e,isFirstLoad:!0};this.tokopediaCategories.next(i)}))}getWooCommerceCategories(t){return this.httpService.get("api/product/woo/GetCategories",[{key:"ID",value:t}]).pipe(l(e=>{let i={data:e,isFirstLoad:!0};this.wooCommerceCategories.next(i)}))}searchByIdWithParentDFS(t,o){let e=[...t];for(;e.length>0;){let i=e.pop();if(i.id===JSON.stringify(o))return i;if(i.children&&i.children.length>0)for(let n of i.children)n.parent=i,e.push(n)}return null}generateCategoryLabel(t){let o="";return t?o=s.getLabelPathTree(t):o="Select a Category",o}};a.\u0275fac=function(o){return new(o||a)},a.\u0275prov=T({token:a,factory:a.\u0275fac,providedIn:"root"});let r=a;return r})();function Z(r,a){if(r&1&&(C(0,"div",3),L(1),m()),r&2){let v=M();b("matTooltip",v.selectedCategoryLabel()),y(),A(" ",v.selectedCategoryLabel()," ")}}function ee(r,a){r&1&&(C(0,"label",2),L(1,"Category"),m())}var Te=(()=>{let a=class a{constructor(){this.categoryService=h(X),this.showClear=!1,this.showLabel=!1,this.disabled=!1,this.selectedCategory=new I,this.selectedCategoryLabel=f("Select a Category"),this.selectedNode=f(null),this.onChange=t=>{},this.onTouched=()=>{}}ngOnChanges(t){let o=t?.categoryId?.previousValue,e=t?.categoryId?.currentValue;s.IsEmpty(o)&&s.IsNotEmpty(e)&&this.initCategories(),s.IsEmpty(e)&&s.IsNotEmpty(o)&&this.generateCategoryLabel(null)}initCategories(){this.categories$=this.categoryService.getCategories(this.channelType,this.channelId).pipe(l(t=>this.setDefaultCategory(t)),u(1))}setDefaultCategory(t){try{let o=this.categoryService.searchByIdWithParentDFS(t,this.categoryId);o&&(this.generateCategoryLabel(o),this.selectedNode.set(o))}catch(o){console.error(o)}}onClickSelect(){this.disabled==!1&&(this.categories$=this.categoryService.getCategories(this.channelType,this.channelId).pipe(u(1)))}onNodeSelect(t){let o=t.node;this.selectedCategoryLabel.set(s.getLabelPathTree(o));let e=parseInt(o.id);this.onChange(e),this.selectedCategory.emit(e)}onNodeUnselect(){this.selectedCategoryLabel.set("Select a Category"),this.selectedCategory.emit(null)}generateCategoryLabel(t){t?this.selectedCategoryLabel.set(s.getLabelPathTree(t)):this.selectedCategoryLabel.set("Select a Category")}writeValue(t){s.IsNotEmpty(t)&&(this.categoryId=t,this.initCategories())}registerOnChange(t){this.onChange=t}registerOnTouched(t){this.onTouched=t}setDisabledState(t){this.disabled=t}};a.\u0275fac=function(o){return new(o||a)},a.\u0275cmp=k({type:a,selectors:[["app-channel-category-select"]],inputs:{channelId:"channelId",channelType:"channelType",categoryId:"categoryId",showClear:"showClear",showLabel:"showLabel",disabled:"disabled"},outputs:{selectedCategory:"selectedCategory"},standalone:!0,features:[x([{provide:B,useExisting:w(()=>a),multi:!0}]),_,P],decls:4,vars:8,consts:[["appendTo","body","containerStyleClass","w-100","placeholder","Select a Category","id","selectCategory",3,"ngModelChange","click","onNodeSelect","onClear","ngModel","filter","options","showClear","disabled"],["pTemplate","value"],["for","selectCategory"],["matTooltipPosition","above",3,"matTooltip"]],template:function(o,e){o&1&&(C(0,"p-treeSelect",0),z(1,"async"),D("ngModelChange",function(n){return O(e.selectedNode,n)||(e.selectedNode=n),n}),N("click",function(){return e.onClickSelect()})("onNodeSelect",function(n){return e.onNodeSelect(n)})("onClear",function(){return e.onNodeUnselect()}),S(2,Z,2,2,"ng-template",1),m(),S(3,ee,2,0,"label",2)),o&2&&(E("ngModel",e.selectedNode),b("filter",!0)("options",W(1,6,e.categories$))("showClear",e.showClear)("disabled",e.disabled),y(3),F(e.showLabel?3:-1))},dependencies:[j,G,Q,K,$,J,H,U,V,R],styles:["[_nghost-%COMP%] .p-treeselect{width:100%;display:inline-flex;border:1px solid #ced4da;font-size:.875rem!important} .p-treeselect-panel{z-index:10002!important} .p-element .p-icon-wrapper{width:14px}"]});let r=a;return r})();export{X as a,Te as b};