marketplacepos 5.48.1 → 5.48.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (50) hide show
  1. package/Marketplace/{chunk-ZRTEGBXK.js → chunk-2IASUYTM.js} +1 -1
  2. package/Marketplace/{chunk-D3VVBQYY.js → chunk-3JYZF65T.js} +1 -1
  3. package/Marketplace/{chunk-SJT5OMJM.js → chunk-3K2EKA5O.js} +1 -1
  4. package/Marketplace/{chunk-KB3CRZC5.js → chunk-5CHTDUME.js} +1 -1
  5. package/Marketplace/{chunk-BYTWGXP7.js → chunk-5KYN6Y7M.js} +1 -1
  6. package/Marketplace/{chunk-MRT6ZM2A.js → chunk-5X2L45XK.js} +1 -1
  7. package/Marketplace/{chunk-AAUBUT4Y.js → chunk-6OIMOM7S.js} +1 -1
  8. package/Marketplace/{chunk-IX6JJ6BJ.js → chunk-7DT7FQ2T.js} +1 -1
  9. package/Marketplace/{chunk-IWFUFVCC.js → chunk-7SB4C4PT.js} +1 -1
  10. package/Marketplace/{chunk-3LTTPECO.js → chunk-ADKAX3OO.js} +1 -1
  11. package/Marketplace/{chunk-6Z2CE7TK.js → chunk-AEVLZ7NS.js} +1 -1
  12. package/Marketplace/{chunk-HUECAZ5I.js → chunk-ALPG22RQ.js} +1 -1
  13. package/Marketplace/{chunk-PUUZQ4N5.js → chunk-B6F5PDL5.js} +1 -1
  14. package/Marketplace/{chunk-IYDRCUIT.js → chunk-C6JHPCLF.js} +1 -1
  15. package/Marketplace/{chunk-CG7UNGPF.js → chunk-CAZ7U2IL.js} +1 -1
  16. package/Marketplace/{chunk-SGTGXMFX.js → chunk-CBU473N2.js} +1 -1
  17. package/Marketplace/{chunk-QSBCJIQ3.js → chunk-CLQGGKN6.js} +1 -1
  18. package/Marketplace/{chunk-JKRH5WGR.js → chunk-DH5CXAEM.js} +1 -1
  19. package/Marketplace/{chunk-RASTACH2.js → chunk-FCFCTT5A.js} +1 -1
  20. package/Marketplace/{chunk-I3Q5TAIL.js → chunk-FRZCC6KZ.js} +1 -1
  21. package/Marketplace/{chunk-Q7MU7DBD.js → chunk-GVI6GJHY.js} +1 -1
  22. package/Marketplace/{chunk-TOATNIRC.js → chunk-GX6JPDQ5.js} +1 -1
  23. package/Marketplace/{chunk-XLNRT52E.js → chunk-H7GV5SNI.js} +1 -1
  24. package/Marketplace/{chunk-ZEF5FMYQ.js → chunk-HKHNRMPT.js} +1 -1
  25. package/Marketplace/{chunk-Q4AWQ7IC.js → chunk-I723PUUO.js} +1 -1
  26. package/Marketplace/{chunk-7WHUYSBD.js → chunk-IDH7MCR3.js} +1 -1
  27. package/Marketplace/{chunk-3TPMCGA5.js → chunk-J6BQDYXO.js} +1 -1
  28. package/Marketplace/{chunk-TLPRODFI.js → chunk-KSVJCX2D.js} +1 -1
  29. package/Marketplace/{chunk-IODYBTLK.js → chunk-KZSTYKIP.js} +1 -1
  30. package/Marketplace/{chunk-IU36PH6K.js → chunk-LABF6W37.js} +1 -1
  31. package/Marketplace/{chunk-NSBKRFO7.js → chunk-M65Z55OS.js} +1 -1
  32. package/Marketplace/{chunk-6ZE3KI6C.js → chunk-MKADKY44.js} +1 -1
  33. package/Marketplace/{chunk-ZVTFMONF.js → chunk-PLLHTY6O.js} +1 -1
  34. package/Marketplace/{chunk-RDS3OGH2.js → chunk-PZKN5FIT.js} +1 -1
  35. package/Marketplace/{chunk-WIYPRMVW.js → chunk-QCV5XC3U.js} +2 -2
  36. package/Marketplace/{chunk-64EV3KZS.js → chunk-RCBY7EIY.js} +1 -1
  37. package/Marketplace/{chunk-RXZ43ZSY.js → chunk-SZVL42NR.js} +1 -1
  38. package/Marketplace/{chunk-SFZDUON5.js → chunk-TIIGDXIJ.js} +2 -2
  39. package/Marketplace/{chunk-BJH4EGMC.js → chunk-UBTALPOC.js} +1 -1
  40. package/Marketplace/{chunk-XF2QZL6C.js → chunk-UCEZJNIL.js} +1 -1
  41. package/Marketplace/{chunk-327AAICB.js → chunk-VYQD3A3M.js} +1 -1
  42. package/Marketplace/{chunk-5G3OIF3V.js → chunk-WRK3ZHRX.js} +1 -1
  43. package/Marketplace/{chunk-GTIJJRTW.js → chunk-X6COQADC.js} +1 -1
  44. package/Marketplace/{chunk-X5X4R6MJ.js → chunk-XDBH7EGC.js} +1 -1
  45. package/Marketplace/{chunk-UIZJMH4U.js → chunk-XK4RP5MQ.js} +1 -1
  46. package/Marketplace/{chunk-GF6B54DH.js → chunk-Y77WYZ6Y.js} +1 -1
  47. package/Marketplace/{chunk-AFCA7VVG.js → chunk-ZUL6ZHSW.js} +1 -1
  48. package/Marketplace/index.html +2 -2
  49. package/Marketplace/{main-T7D6R6TU.js → main-YJKBQ3LW.js} +1 -1
  50. package/package.json +1 -1
@@ -1,4 +1,4 @@
1
- import{a as Pt,b as _t,d as Ti}from"./chunk-Q2QX5AAJ.js";import"./chunk-AZOCRKXK.js";import{a as di}from"./chunk-EYT2YJGK.js";import{b as bt}from"./chunk-RNWHARPK.js";import{a as _i}from"./chunk-5X2E3W32.js";import{a as ui}from"./chunk-UH5C5HXK.js";import{a as Jt}from"./chunk-ZSUWHVKX.js";import{a as Ci}from"./chunk-BYTWGXP7.js";import{a as fi,b as bi}from"./chunk-3JRUKSV3.js";import"./chunk-SJ5MC42H.js";import{a as si}from"./chunk-4RLWHMI6.js";import"./chunk-NWB7EVME.js";import{d as ft,e as Bt}from"./chunk-AFDI4TD4.js";import"./chunk-4RG5YR7N.js";import"./chunk-5MV3UFJQ.js";import{a as ci,b as yi,c as wi}from"./chunk-E6AMKEQR.js";import{a as We,b as mi,c as gi}from"./chunk-IGKMJFKP.js";import{a as gt,d as pi,e as hi}from"./chunk-ITGVXYDV.js";import{a as Qe}from"./chunk-HK5FXZE4.js";import{b as Ke}from"./chunk-KJE5GRQ4.js";import{a as K}from"./chunk-4ILDFTIG.js";import"./chunk-A6QXXKPR.js";import{i as ti}from"./chunk-Q4AWQ7IC.js";import"./chunk-QXRG5XYP.js";import"./chunk-RXLMJGUY.js";import"./chunk-M4ZE35XK.js";import{a as M,e as F,f as li}from"./chunk-L7WZ6U4T.js";import{b as Y,c as pe,d as Ae,e as A,f as ue}from"./chunk-LOWGZOML.js";import{G as oi,U as mt,V as qe,ja as ce,ka as ai,la as Ft,ma as Lt,oa as ri,ra as ie,sa as q}from"./chunk-5PMKN6PM.js";import"./chunk-AGBJEXIM.js";import{b as Zt,e as Xt}from"./chunk-OXWPYJNB.js";import"./chunk-XBIHN6D3.js";import{c as Dt}from"./chunk-JBEKD57G.js";import{m as ii,n as ni}from"./chunk-EDEZ3JLR.js";import{A as we,a as Ie,b as Wt,g as ht,h as Ne,m as He}from"./chunk-L3W6SG2T.js";import"./chunk-YTHY4IFS.js";import{b as Yt,c as ei}from"./chunk-ZETUYNFJ.js";import"./chunk-STYL7ETF.js";import"./chunk-XLIPGDSC.js";import{c as Ve,e as pt,f as Le,g as ut,h as be,i as jt,l as qt,m as ne,n as Oe}from"./chunk-LNJUGHOX.js";import{$b as me,$c as G,Ac as v,Ba as tt,Bc as ae,Cc as b,Dc as _,Fd as T,Gb as I,Gd as Z,Ha as it,Hb as le,Hc as lt,Ib as Rt,Ic as Re,K as kt,Kb as E,Kc as ze,Lb as se,Lc as C,Mb as p,Mc as V,Nc as $e,Oa as x,Oc as te,Qc as Me,Rc as De,Sc as Fe,Z as et,Zb as D,Zc as oe,_c as Mt,ad as Se,bc as ge,cc as Ut,cd as st,dd as dt,ea as Ue,ec as at,ed as je,f as Pe,fc as rt,fd as $t,gc as l,hc as h,hd as Te,ic as m,id as ve,jc as B,kc as U,kd as ye,la as xe,lb as nt,lc as $,ma as ee,mc as L,na as re,nb as s,nc as O,oc as N,od as ct,pa as de,pc as k,qc as H,ra as z,rc as X,sb as R,tb as ot,td as fe,v as Gt,vc as P,xa as y,xc as c,ya as w,za as S,zb as ke}from"./chunk-ZYJ6LAJ3.js";import"./chunk-WFMAM73Y.js";import{a as Be,b as Ge}from"./chunk-66YHNWRR.js";var vi=`
1
+ import{a as Pt,b as _t,d as Ti}from"./chunk-Q2QX5AAJ.js";import"./chunk-AZOCRKXK.js";import{a as di}from"./chunk-EYT2YJGK.js";import{b as bt}from"./chunk-RNWHARPK.js";import{a as _i}from"./chunk-5X2E3W32.js";import{a as ui}from"./chunk-UH5C5HXK.js";import{a as Jt}from"./chunk-ZSUWHVKX.js";import{a as Ci}from"./chunk-5KYN6Y7M.js";import{a as fi,b as bi}from"./chunk-3JRUKSV3.js";import"./chunk-SJ5MC42H.js";import{a as si}from"./chunk-4RLWHMI6.js";import"./chunk-NWB7EVME.js";import{d as ft,e as Bt}from"./chunk-AFDI4TD4.js";import"./chunk-4RG5YR7N.js";import"./chunk-5MV3UFJQ.js";import{a as ci,b as yi,c as wi}from"./chunk-E6AMKEQR.js";import{a as We,b as mi,c as gi}from"./chunk-IGKMJFKP.js";import{a as gt,d as pi,e as hi}from"./chunk-ITGVXYDV.js";import{a as Qe}from"./chunk-HK5FXZE4.js";import{b as Ke}from"./chunk-KJE5GRQ4.js";import{a as K}from"./chunk-4ILDFTIG.js";import"./chunk-A6QXXKPR.js";import{i as ti}from"./chunk-I723PUUO.js";import"./chunk-QXRG5XYP.js";import"./chunk-RXLMJGUY.js";import"./chunk-M4ZE35XK.js";import{a as M,e as F,f as li}from"./chunk-L7WZ6U4T.js";import{b as Y,c as pe,d as Ae,e as A,f as ue}from"./chunk-LOWGZOML.js";import{G as oi,U as mt,V as qe,ja as ce,ka as ai,la as Ft,ma as Lt,oa as ri,ra as ie,sa as q}from"./chunk-5PMKN6PM.js";import"./chunk-AGBJEXIM.js";import{b as Zt,e as Xt}from"./chunk-OXWPYJNB.js";import"./chunk-XBIHN6D3.js";import{c as Dt}from"./chunk-JBEKD57G.js";import{m as ii,n as ni}from"./chunk-EDEZ3JLR.js";import{A as we,a as Ie,b as Wt,g as ht,h as Ne,m as He}from"./chunk-L3W6SG2T.js";import"./chunk-YTHY4IFS.js";import{b as Yt,c as ei}from"./chunk-ZETUYNFJ.js";import"./chunk-STYL7ETF.js";import"./chunk-XLIPGDSC.js";import{c as Ve,e as pt,f as Le,g as ut,h as be,i as jt,l as qt,m as ne,n as Oe}from"./chunk-LNJUGHOX.js";import{$b as me,$c as G,Ac as v,Ba as tt,Bc as ae,Cc as b,Dc as _,Fd as T,Gb as I,Gd as Z,Ha as it,Hb as le,Hc as lt,Ib as Rt,Ic as Re,K as kt,Kb as E,Kc as ze,Lb as se,Lc as C,Mb as p,Mc as V,Nc as $e,Oa as x,Oc as te,Qc as Me,Rc as De,Sc as Fe,Z as et,Zb as D,Zc as oe,_c as Mt,ad as Se,bc as ge,cc as Ut,cd as st,dd as dt,ea as Ue,ec as at,ed as je,f as Pe,fc as rt,fd as $t,gc as l,hc as h,hd as Te,ic as m,id as ve,jc as B,kc as U,kd as ye,la as xe,lb as nt,lc as $,ma as ee,mc as L,na as re,nb as s,nc as O,oc as N,od as ct,pa as de,pc as k,qc as H,ra as z,rc as X,sb as R,tb as ot,td as fe,v as Gt,vc as P,xa as y,xc as c,ya as w,za as S,zb as ke}from"./chunk-ZYJ6LAJ3.js";import"./chunk-WFMAM73Y.js";import{a as Be,b as Ge}from"./chunk-66YHNWRR.js";var vi=`
2
2
  .p-datatable {
3
3
  position: relative;
4
4
  display: block;
@@ -1 +1 @@
1
- import{a as pe}from"./chunk-ZSUWHVKX.js";import{e as _e}from"./chunk-6KWG6O5L.js";import{a as ge,i as be}from"./chunk-Q4AWQ7IC.js";import"./chunk-QXRG5XYP.js";import"./chunk-RXLMJGUY.js";import"./chunk-AGBJEXIM.js";import{b as he,e as S}from"./chunk-OXWPYJNB.js";import"./chunk-XBIHN6D3.js";import{a as M,c as ue}from"./chunk-JBEKD57G.js";import{A as me,c as te,h as ne,i as ie,k as oe,m as re,n as ae,t as se,u as de,v as ce,w as le}from"./chunk-L3W6SG2T.js";import"./chunk-YTHY4IFS.js";import{a as fe,c as xe}from"./chunk-ZETUYNFJ.js";import{D as y,F as w,I as V,c as X,i as Z,m as ee}from"./chunk-LNJUGHOX.js";import{$b as C,Bc as W,Cc as B,Dc as q,Gb as f,Hb as A,Hc as k,Lc as H,Mc as a,Nc as x,Oc as Y,Pc as G,Qc as E,Rc as L,Sc as I,Z as R,ad as Q,bc as v,dc as z,ec as N,fc as D,gc as b,hc as i,hd as K,ic as r,id as $,jc as l,lb as O,ma as U,na as T,nb as c,qc as j,td as J,vc as g,xa as u,xc as p,ya as h,zb as m}from"./chunk-ZYJ6LAJ3.js";import"./chunk-WFMAM73Y.js";import"./chunk-66YHNWRR.js";var Ce=(()=>{let t=class t{constructor(){}getBrowserName(){let n=window.navigator.userAgent.toLowerCase();switch(!0){case(n.indexOf("edge")>-1||n.indexOf("edg")>-1):return"edge";case n.indexOf("opr")>-1:return"opera";case n.indexOf("chrome")>-1:return"chrome";case n.indexOf("trident")>-1:return"ie";case n.indexOf("firefox")>-1:return"firefox";case n.indexOf("safari")>-1:return"safari";default:return"other"}}};t.\u0275fac=function(e){return new(e||t)},t.\u0275prov=U({token:t,factory:t.\u0275fac,providedIn:"root"});let o=t;return o})();function Le(o,t){if(o&1&&(i(0,"swiper-slide")(1,"div")(2,"a",1),l(3,"img",2),r()(),i(4,"a",3),a(5),r(),i(6,"p",4),a(7),r()()),o&2){let d=t.$implicit;c(2),b("href",d.href,O),c(),b("src",d.imgSrc,O),c(),b("href",d.href,O),c(),x(d.title),c(2),x(d.description)}}var ve=(()=>{let t=class t{constructor(){this.newsList=J([])}};t.\u0275fac=function(e){return new(e||t)},t.\u0275cmp=f({type:t,selectors:[["POS-news-swiper"]],inputs:{newsList:[1,"newsList"]},standalone:!1,decls:3,vars:0,consts:[["pagination","true","pagination-clickable","true","autoplay-delay","5000","autoplay-disable-on-interaction","false",2,"margin-top","30px"],["target","_blank",3,"href"],[1,"border-0","rounded-1","mb-8",2,"width","252px","height","152px",3,"src"],["target","_blank",1,"fw-bold","h5","text-success","header-title","fs-4",3,"href"],[2,"margin-bottom","3rem"]],template:function(e,s){e&1&&(i(0,"swiper-container",0),N(1,Le,8,5,"swiper-slide",null,z),r()),e&2&&(c(),D(s.newsList()))},styles:["swiper-container[_ngcontent-%COMP%]{--swiper-pagination-bullet-inactive-color: #89b03e;--swiper-pagination-color: #89b03e}"]});let o=t;return o})();var Te=["subdomainEl"],Ae=(o,t)=>({"rounded-end":o,"border-end-0":t});function ze(o,t){if(o&1&&(i(0,"div",33),l(1,"img",34),r()),o&2){let d=t.$implicit;c(),b("src",d.img,O)("title",d.title)("alt",d.title)}}function Ne(o,t){if(o&1){let d=j();i(0,"div",15)(1,"h3",16),a(2," DealPOS Omnichannel "),r(),i(3,"small",17),a(4," Multichannel Inventory Management Software "),r()(),i(5,"form",18)(6,"div",19)(7,"div",20)(8,"div",21)(9,"span"),l(10,"i",22),r()(),i(11,"input",23,0),I("ngModelChange",function(e){u(d);let s=p();return L(s.subdomain,e)||(s.subdomain=e),h(e)}),r(),i(13,"div")(14,"select",24),I("ngModelChange",function(e){u(d);let s=p();return L(s.domain,e)||(s.domain=e),h(e)}),i(15,"option",25),a(16,".dealpos.co.id"),r(),i(17,"option",26),a(18,".dealpos.net"),r(),i(19,"option",27),a(20,".dealpos.com"),r(),i(21,"option",28),a(22,".dealpos.app"),r()()()(),i(23,"div",29)(24,"button",30),g("click",function(){u(d);let e=p();return h(e.onNextState())}),a(25," Next "),r()(),i(26,"div",31)(27,"div",32),N(28,ze,2,3,"div",33,z),r()()()()}if(o&2){let d=p();c(11),E("ngModel",d.subdomain),c(3),E("ngModel",d.domain),c(14),D(d.channels)}}function De(o,t){o&1&&(i(0,"p"),a(1," Username is required "),r())}function je(o,t){if(o&1&&(i(0,"div",44),l(1,"div",54),i(2,"div",55),C(3,De,2,0,"p"),r()()),o&2){p();let d=k(14);c(3),v(d.errors.required?3:-1)}}function Ve(o,t){if(o&1){let d=j();i(0,"i",57),g("click",function(){u(d);let e=p(3);return h(e.hideShowPassword())}),r()}if(o&2){let d=p(3);H("fa "+d.passwordIcon)}}function Fe(o,t){if(o&1&&(i(0,"span",47),C(1,Ve,1,2,"i",56),r()),o&2){let d=p(2);c(),v(d.password?1:-1)}}function Re(o,t){o&1&&(i(0,"p"),a(1," Password is required "),r())}function Ue(o,t){if(o&1&&(i(0,"div",44),l(1,"div",54),i(2,"div",55),C(3,Re,2,0,"p"),r()()),o&2){p();let d=k(21);c(3),v(d.errors.required?3:-1)}}function We(o,t){if(o&1){let d=j();i(0,"div",35)(1,"h3",36),a(2,"Sign in"),r(),i(3,"h3",37),a(4," to "),i(5,"h6",38),a(6),r(),i(7,"i",39),g("click",function(){u(d);let e=p();return h(e.onEditDomain())}),r()()(),i(8,"form",40)(9,"div",41)(10,"div",21)(11,"span"),l(12,"i",42),r()(),i(13,"input",43,1),I("ngModelChange",function(e){u(d);let s=p();return L(s.username,e)||(s.username=e),h(e)}),r()(),C(15,je,4,1,"div",44),i(16,"div",20)(17,"div",21)(18,"span"),l(19,"i",45),r()(),i(20,"input",46,2),I("ngModelChange",function(e){u(d);let s=p();return L(s.password,e)||(s.password=e),h(e)}),r(),C(22,Fe,2,1,"span",47),r(),C(23,Ue,4,1,"div",44),i(24,"div",48)(25,"button",49),g("click",function(){u(d);let e=p();return h(e.onLogin())}),a(26," Log in "),r()(),i(27,"div",50),l(28,"hr"),i(29,"span",51),a(30,"or"),r(),l(31,"hr"),r(),i(32,"div")(33,"button",52),g("click",function(e){u(d);let s=p();return h(s.onLoginByGoogle(e))}),l(34,"i",53),a(35," Sign In with Google "),r()()()}if(o&2){let d=k(14),n=k(21),e=p();c(6),G(" (",e.subdomain,"",e.domain,") "),c(7),E("ngModel",e.username),c(2),v(d.invalid&&(d.dirty||d.touched)?15:-1),c(5),b("type",e.passwordType)("ngClass",Q(9,Ae,e.browser=="edge",e.browser!="edge")),E("ngModel",e.password),c(2),v(e.browser!="edge"?22:-1),c(),v(n.invalid&&(n.dirty||n.touched)?23:-1)}}var we=(()=>{let t=class t{constructor(n,e,s,_,ke){this._router=n,this.toastr=e,this.checkBrowser=s,this.authService=_,this.ngxPermission=ke,this.domain=".dealpos.co.id",this.loginState="FORM_DOMAIN",this.passwordType="password",this.passwordIcon="fa-eye",this.channels=[{title:"Shopee",img:M.SHOOPE},{title:"Tokopedia",img:M.TOKOPEDIA},{title:"Tiktok",img:M.TIKTOK},{title:"Woocommerce",img:M.WOOCOMMERCE},{title:"Lazada",img:M.LAZADA},{title:"Shopify",img:M.SHOPIFY},{title:"Plugo",img:M.PLUGONEW}],this.version=ge.version,this.news$=_.getNews().pipe(R(1))}ngOnInit(){this.initLogin(),this.browser=this.checkBrowser.getBrowserName(),document.body.classList.add("login-body"),this.initChangeLogUrl()}initChangeLogUrl(){let n=`https://changelog.dealpos.com/?categories=cat_nILYcoEQzgGWX&view=complete&v=${this.version}`;this.changelogUrl=n}ngAfterViewInit(){this.setAutoFocusDomain()}initLogin(){let n=JSON.parse(localStorage.getItem("Authorization"));if(n){this.username=n?.username,this.subdomain=n?.Host?.split(".")[0];let e=n?.Host?.split("dealpos");this.domain=`.dealpos${e[1]}`,this.authService.isActiveToken()&&this._router.navigate(["menu"])}}onNextState(){if(ue.IsEmpty(this.subdomain)){this.toastr.warning("Account Domain is required","Warning");return}this.parseSubdomain(),this.loginState="FORM_AUTH"}parseSubdomain(){let n=this.subdomain.indexOf(".dealpos");n!=-1&&(this.subdomain=this.subdomain.substring(0,n))}onEditDomain(){this.loginState="FORM_DOMAIN"}onLogin(){let n={Host:`${this.subdomain}${this.domain}`,Username:this.username,Password:this.password};this.authService.login(n).subscribe(e=>{this.onSuccessLogin(e)})}onLoginByGoogle(n){let e=`${this.subdomain}${this.domain}`;this.authService.loginWithGoogle(n,e).subscribe(s=>{this.onSuccessLogin(s)})}onSuccessLogin(n){this.ngxPermission.hasPermission([pe.DashboardView]).then(e=>{e?this._router.navigate(["menu/dashboard"]):n?.TotalChannel<1?this._router.navigate(["menu/channel"]):this._router.navigate(["menu/products"])})}setAutoFocusDomain(){this.subdomainEl.nativeElement.focus()}hideShowPassword(){this.passwordType=this.passwordType==="text"?"password":"text",this.passwordIcon=this.passwordIcon==="fa-eye"?"fa-eye-slash":"fa-eye"}ngOnDestroy(){document.body.classList.remove("login-body")}};t.\u0275fac=function(e){return new(e||t)(m(w),m(he),m(Ce),m(be),m(fe))},t.\u0275cmp=f({type:t,selectors:[["app-login"]],viewQuery:function(e,s){if(e&1&&W(Te,5),e&2){let _;B(_=q())&&(s.subdomainEl=_.first)}},standalone:!1,decls:18,vars:6,consts:[["subdomainEl",""],["usernameCtrl","ngModel"],["passwordCtrl","ngModel"],[1,"container-fluid"],[1,"row","mx-auto","bg-white","login-pane"],[1,"col-md-5","order-md-first","order-last","border-end","features-pane","pt-12","pb-9"],[1,"fw-normal","fs-2","header-title","text-center"],[3,"newsList"],[1,"col-md-7","order-md-last","order-first","py-12","sign-in-pane"],[1,"d-flex","copyright",2,"margin-left","20px"],[1,"align-self-center","me-5"],["target","_blank","href","http://www.dealpos.com"],[1,"version",2,"margin-right","18px"],["target","_blank",1,"text-dark","fst-italic",3,"href"],[1,"fa-solid","fa-circle-exclamation","ms-2",2,"font-size","16px"],[1,"text-md-start","text-center"],[1,"fs-2","header-title","me-2","fw-normal"],[1,"text-secondary-emphasis","fst-italic",2,"font-size","11px"],[2,"margin-top","38px"],[1,"form-block","mt-5"],[1,"input-group","input-group-lg","mt-8"],[1,"input-group-text","rounded-start","border-end-0",2,"width","52px"],[1,"fa-solid","fa-cloud"],["placeholder","Store Address","aria-label","Store Address","aria-describedby","basic-addon1","autofocus","","name","Store Address",1,"form-control","form-control-lg","rounded-end-0","border-start-0","ps-1",2,"height","58px",3,"ngModelChange","ngModel"],["name","domainOption",1,"form-select","form-control","form-control-lg","border-start-0","border-start","rounded-end","rounded-start-0","domain-option",2,"height","58px",3,"ngModelChange","ngModel"],["selected","","value",".dealpos.co.id"],["value",".dealpos.net"],["value",".dealpos.com"],["value",".dealpos.app"],[1,"w-100",2,"margin-top","1.8rem"],["name","next","data-cy","next","type","submit",1,"btn","btn-xl","btn-success","btn-block","font125rem","robotoslab","w-100",3,"click"],[1,"d-flex","align-items-center","justify-content-center",2,"margin-top","2.1rem"],[1,"d-flex","align-items-center","justify-content-between","w-100"],[1,""],[1,"border-0",2,"width","34px","height","34px",3,"src","title","alt"],[1,"d-flex","align-items-center","justify-content-start","mb-2"],[1,"robotoslab","fw-normal"],[1,"ms-2","fw-normal"],[1,"me-2","robotoslab","d-inline-block","text-success"],["title","Edit Store Address",1,"fa-solid","fa-edit","link-success","fs-5","pointer",3,"click"],[2,"margin-top","29px"],[1,"input-group","input-group-lg"],[1,"fas","fa-user","fa-lg"],["id","txtUsername","type","text","data-cy","username","required","","placeholder","Username","aria-label","Username","aria-describedby","basic-addon1","autofocus","","name","username",1,"form-control","form-control-lg","rounded-end","border-start-0","ps-1",2,"height","58px",3,"ngModelChange","ngModel"],[1,"d-flex","justify-content-start","w-50","mb-4",2,"height","16px"],[1,"fas","fa-key","fa-lg"],["id","txtPassword","data-cy","password","placeholder","Password","aria-label","Password","aria-describedby","basic-addon1","autofocus","","name","password","required","",1,"form-control","form-control-lg","rounded-end","border-start-0","ps-1",2,"height","58px",3,"ngModelChange","type","ngClass","ngModel"],[1,"input-group-text","border-start-0","rounded-end"],[1,"w-100","mt-8"],["data-cy","login","type","submit",1,"btn","btn-lg","btn-success","btn-block","font125rem","robotoslab","w-100",3,"click"],[1,"divider","d-flex","align-items-center","justify-content-center"],[1,"mx-4","text-muted"],[1,"btn","btn-social-login","text-success","w-100","fw-bold",3,"click"],[1,"fa-brands","fa-google"],[2,"width","52px"],[1,"text-danger","ps-1"],[3,"class"],[3,"click"]],template:function(e,s){e&1&&(i(0,"div",3)(1,"div",4)(2,"div",5)(3,"h3",6),a(4,"New Features"),r(),l(5,"POS-news-swiper",7),K(6,"async"),r(),i(7,"div",8),C(8,Ne,30,2)(9,We,36,12),r()(),i(10,"div",9)(11,"span",10),a(12,"powered by :"),r(),l(13,"a",11),r(),i(14,"div",12)(15,"a",13),a(16),l(17,"i",14),r()()()),e&2&&(c(5),b("newsList",$(6,4,s.news$)),c(3),v(s.loginState=="FORM_DOMAIN"?8:9),c(7),b("href",s.changelogUrl,O),c(),Y("version ",s.version))},dependencies:[X,ae,de,ce,te,se,ne,ie,le,re,oe,ve,Z],styles:[".login-pane[_ngcontent-%COMP%]{max-width:57rem;height:max-content;margin-top:115px}@media (max-width: 768px){.login-pane[_ngcontent-%COMP%]{margin-top:0}}@media only screen and (max-width: 1300px) and (min-width: 1024px){.login-pane[_ngcontent-%COMP%]{margin-top:30px}}.header-title[_ngcontent-%COMP%]{font-family:Roboto Slab}.carousel-inner[_ngcontent-%COMP%]{height:310px}.carousel-inner[_ngcontent-%COMP%] div.carousel-item[_ngcontent-%COMP%]{top:28px}@media (max-width: 820px){.carousel-indicators[_ngcontent-%COMP%]{bottom:-8px}}.carousel-indicators[_ngcontent-%COMP%] button[_ngcontent-%COMP%]{background-color:#ddd;width:1.25rem;height:.375rem;transition:.3s}.carousel-indicators[_ngcontent-%COMP%] button.active[_ngcontent-%COMP%]{background-color:var(--bs-success)}.sign-in-pane[_ngcontent-%COMP%]{padding:0 3rem 0 3.5rem}@media (max-width: 768px){.sign-in-pane[_ngcontent-%COMP%]{padding:24px 12px}.sign-in-pane[_ngcontent-%COMP%] input[_ngcontent-%COMP%]{padding-left:8px!important}}@media (min-width: 1200px){.sign-in-pane[_ngcontent-%COMP%]{border-bottom:1px solid #89b03e;border-right:1px solid #89b03e;border-top:1px solid #89b03e;border-radius:0 10px 10px 0}}.subscription.danger[_ngcontent-%COMP%]{background-color:#f2dede;border-color:#eb415d;color:#a94442}.subscription.warning[_ngcontent-%COMP%]{background-color:#fcf8e3;border-color:#faebcc;color:#8a6d3b}@media (max-width: 768px){.features-pane[_ngcontent-%COMP%]{border-right:0px!important}}@media (min-width: 1200px){.features-pane[_ngcontent-%COMP%]{border-left:1px solid #89b03e;border-bottom:1px solid #89b03e;border-top:1px solid #89b03e;border-radius:10px 0 0 10px}}.copyright[_ngcontent-%COMP%]{position:absolute;bottom:1.25rem;left:1.25rem}.copyright[_ngcontent-%COMP%] a[_ngcontent-%COMP%]{width:8.125rem;height:2.5rem;background-image:url(//res.cloudinary.com/pos/image/upload/POS/Images/Login/dealpos.png);background-position:left top;background-repeat:no-repeat;background-size:contain}.version[_ngcontent-%COMP%]{bottom:1.25rem;right:1.25rem;position:absolute}@media (max-width: 768px){.copyright[_ngcontent-%COMP%], .version[_ngcontent-%COMP%]{position:static;margin-top:10px}.copyright[_ngcontent-%COMP%]{justify-content:center}}div.divider[_ngcontent-%COMP%] > hr[_ngcontent-%COMP%]{margin-top:1.2rem;margin-bottom:1.2rem;border-top:1px solid rgba(0,0,0,.855);width:20%}button.btn-social-login[_ngcontent-%COMP%], .btn-login[_ngcontent-%COMP%]{border:1px solid var(--bs-success)}.fa-google[_ngcontent-%COMP%]{background:conic-gradient(from -45deg,#ea4335 110deg,#4285f4 90deg 180deg,#34a853 180deg 270deg,#fbbc05 270deg) 73% 55%/150% 150% no-repeat;-webkit-background-clip:text;background-clip:text;color:transparent;-webkit-text-fill-color:transparent}.version[_ngcontent-%COMP%] a[_ngcontent-%COMP%] i[_ngcontent-%COMP%]{color:#fe3a00!important}.version[_ngcontent-%COMP%] a[_ngcontent-%COMP%]:visited i[_ngcontent-%COMP%]{color:#f4f4f4!important}.version[_ngcontent-%COMP%] a[_ngcontent-%COMP%]:visited{margin-left:-10px}.domain-option[_ngcontent-%COMP%]{padding:.75rem;color:#343434;font-size:.875rem;width:8.5rem}"]});let o=t;return o})();var Oe=(()=>{let t=class t{constructor(n,e,s){this.route=n,this.http=e,this.service=s}ngOnInit(){this.route.queryParams.subscribe(n=>{this.shopID=n.shop_id,this.code=n.code})}addShopee(){let n={ShopID:Number(this.shopID),Code:this.code};this.http.post("/api/ChannelAdd/ShopeeV2",n).subscribe(s=>{this.service.navigate(["/menu/channel"])})}};t.\u0275fac=function(e){return new(e||t)(m(y),m(S),m(w))},t.\u0275cmp=f({type:t,selectors:[["shopee-authorized"]],standalone:!1,decls:20,vars:1,consts:[[1,"container","h-100"],[1,"row","d-flex","justify-content-center","align-items-center","h-100"],[1,"col-md-4"],[1,"card"],[1,"card-header","text-center"],[1,"far","fa-check-circle","text-success",2,"font-size","115px"],[1,"h3","fw-bold"],[1,"card-body","text-center","py-6"],[1,"text-shopee","fw-bold"],["type","button",1,"btn","btn-success","mt-t",3,"click"],[1,"fas","fa-undo"]],template:function(e,s){e&1&&(i(0,"div",0)(1,"div",1)(2,"div",2)(3,"div",3)(4,"div",4),l(5,"i",5),i(6,"div",6),a(7,"Success !"),r()(),i(8,"div",7)(9,"div"),a(10,"You have successfully authorized "),r(),i(11,"div"),a(12,"DEALPOS to manage your Shopee"),r(),i(13,"div"),a(14," Your shopID is "),i(15,"span",8),a(16),r()(),i(17,"button",9),g("click",function(){return s.addShopee()}),l(18,"i",10),a(19," Add to my Channel"),r()()()()()()),e&2&&(c(16),x(s.shopID))},styles:[".login-pane[_ngcontent-%COMP%]{max-width:57rem;height:max-content;margin-top:115px}@media (max-width: 768px){.login-pane[_ngcontent-%COMP%]{margin-top:0}}@media only screen and (max-width: 1300px) and (min-width: 1024px){.login-pane[_ngcontent-%COMP%]{margin-top:30px}}.header-title[_ngcontent-%COMP%]{font-family:Roboto Slab}.carousel-inner[_ngcontent-%COMP%]{height:310px}.carousel-inner[_ngcontent-%COMP%] div.carousel-item[_ngcontent-%COMP%]{top:28px}@media (max-width: 820px){.carousel-indicators[_ngcontent-%COMP%]{bottom:-8px}}.carousel-indicators[_ngcontent-%COMP%] button[_ngcontent-%COMP%]{background-color:#ddd;width:1.25rem;height:.375rem;transition:.3s}.carousel-indicators[_ngcontent-%COMP%] button.active[_ngcontent-%COMP%]{background-color:var(--bs-success)}.sign-in-pane[_ngcontent-%COMP%]{padding:0 3rem 0 3.5rem}@media (max-width: 768px){.sign-in-pane[_ngcontent-%COMP%]{padding:24px 12px}.sign-in-pane[_ngcontent-%COMP%] input[_ngcontent-%COMP%]{padding-left:8px!important}}@media (min-width: 1200px){.sign-in-pane[_ngcontent-%COMP%]{border-bottom:1px solid #89b03e;border-right:1px solid #89b03e;border-top:1px solid #89b03e;border-radius:0 10px 10px 0}}.subscription.danger[_ngcontent-%COMP%]{background-color:#f2dede;border-color:#eb415d;color:#a94442}.subscription.warning[_ngcontent-%COMP%]{background-color:#fcf8e3;border-color:#faebcc;color:#8a6d3b}@media (max-width: 768px){.features-pane[_ngcontent-%COMP%]{border-right:0px!important}}@media (min-width: 1200px){.features-pane[_ngcontent-%COMP%]{border-left:1px solid #89b03e;border-bottom:1px solid #89b03e;border-top:1px solid #89b03e;border-radius:10px 0 0 10px}}.copyright[_ngcontent-%COMP%]{position:absolute;bottom:1.25rem;left:1.25rem}.copyright[_ngcontent-%COMP%] a[_ngcontent-%COMP%]{width:8.125rem;height:2.5rem;background-image:url(//res.cloudinary.com/pos/image/upload/POS/Images/Login/dealpos.png);background-position:left top;background-repeat:no-repeat;background-size:contain}.version[_ngcontent-%COMP%]{bottom:1.25rem;right:1.25rem;position:absolute}@media (max-width: 768px){.copyright[_ngcontent-%COMP%], .version[_ngcontent-%COMP%]{position:static;margin-top:10px}.copyright[_ngcontent-%COMP%]{justify-content:center}}div.divider[_ngcontent-%COMP%] > hr[_ngcontent-%COMP%]{margin-top:1.2rem;margin-bottom:1.2rem;border-top:1px solid rgba(0,0,0,.855);width:20%}button.btn-social-login[_ngcontent-%COMP%], .btn-login[_ngcontent-%COMP%]{border:1px solid var(--bs-success)}.fa-google[_ngcontent-%COMP%]{background:conic-gradient(from -45deg,#ea4335 110deg,#4285f4 90deg 180deg,#34a853 180deg 270deg,#fbbc05 270deg) 73% 55%/150% 150% no-repeat;-webkit-background-clip:text;background-clip:text;color:transparent;-webkit-text-fill-color:transparent}.version[_ngcontent-%COMP%] a[_ngcontent-%COMP%] i[_ngcontent-%COMP%]{color:#fe3a00!important}.version[_ngcontent-%COMP%] a[_ngcontent-%COMP%]:visited i[_ngcontent-%COMP%]{color:#f4f4f4!important}.version[_ngcontent-%COMP%] a[_ngcontent-%COMP%]:visited{margin-left:-10px}.domain-option[_ngcontent-%COMP%]{padding:.75rem;color:#343434;font-size:.875rem;width:8.5rem}.form-signin[_ngcontent-%COMP%]{max-width:600px}.card[_ngcontent-%COMP%]{font:100 14px/25px Roboto,Helvetica Neue,sans-serif;border-radius:13px;box-sizing:border-box}.text-shopee[_ngcontent-%COMP%]{color:#f53d2d}"]});let o=t;return o})();var Pe=(()=>{let t=class t{constructor(n,e,s){this.route=n,this.http=e,this.service=s}ngOnInit(){this.route.queryParams.subscribe(n=>{this.code=n.code,this.state=n.state})}addChannelTiktok(){let n={Code:this.code};this.http.post("/api/ChannelAdd/AddTiktok",n).subscribe(e=>{this.service.navigate(["/menu/channel"])})}};t.\u0275fac=function(e){return new(e||t)(m(y),m(S),m(w))},t.\u0275cmp=f({type:t,selectors:[["app-tiktok"]],standalone:!1,decls:24,vars:2,consts:[[1,"container","h-100"],[1,"row","d-flex","justify-content-center","align-items-center","h-100"],[1,"col-md-4"],[1,"card"],[1,"card-header","text-center"],[1,"far","fa-check-circle","text-success",2,"font-size","115px"],[1,"h3","fw-bold"],[1,"card-body","text-center","py-6"],[1,"text-shopee","fw-bold"],["type","button",1,"btn","btn-success","mt-6",3,"click"],[1,"fas","fa-undo"]],template:function(e,s){e&1&&(i(0,"div",0)(1,"div",1)(2,"div",2)(3,"div",3)(4,"div",4),l(5,"i",5),i(6,"div",6),a(7,"Success !"),r()(),i(8,"div",7)(9,"div"),a(10,"You have successfully authorized "),r(),i(11,"div"),a(12,"DEALPOS to manage your Tiktok"),r(),i(13,"div"),a(14," Your Code is "),i(15,"span",8),a(16),r()(),i(17,"div"),a(18," Your State is "),i(19,"span",8),a(20),r()(),i(21,"button",9),g("click",function(){return s.addChannelTiktok()}),l(22,"i",10),a(23," Add to my Channel"),r()()()()()()),e&2&&(c(16),x(s.code),c(4),x(s.state))},styles:[".login-pane[_ngcontent-%COMP%]{max-width:57rem;height:max-content;margin-top:115px}@media (max-width: 768px){.login-pane[_ngcontent-%COMP%]{margin-top:0}}@media only screen and (max-width: 1300px) and (min-width: 1024px){.login-pane[_ngcontent-%COMP%]{margin-top:30px}}.header-title[_ngcontent-%COMP%]{font-family:Roboto Slab}.carousel-inner[_ngcontent-%COMP%]{height:310px}.carousel-inner[_ngcontent-%COMP%] div.carousel-item[_ngcontent-%COMP%]{top:28px}@media (max-width: 820px){.carousel-indicators[_ngcontent-%COMP%]{bottom:-8px}}.carousel-indicators[_ngcontent-%COMP%] button[_ngcontent-%COMP%]{background-color:#ddd;width:1.25rem;height:.375rem;transition:.3s}.carousel-indicators[_ngcontent-%COMP%] button.active[_ngcontent-%COMP%]{background-color:var(--bs-success)}.sign-in-pane[_ngcontent-%COMP%]{padding:0 3rem 0 3.5rem}@media (max-width: 768px){.sign-in-pane[_ngcontent-%COMP%]{padding:24px 12px}.sign-in-pane[_ngcontent-%COMP%] input[_ngcontent-%COMP%]{padding-left:8px!important}}@media (min-width: 1200px){.sign-in-pane[_ngcontent-%COMP%]{border-bottom:1px solid #89b03e;border-right:1px solid #89b03e;border-top:1px solid #89b03e;border-radius:0 10px 10px 0}}.subscription.danger[_ngcontent-%COMP%]{background-color:#f2dede;border-color:#eb415d;color:#a94442}.subscription.warning[_ngcontent-%COMP%]{background-color:#fcf8e3;border-color:#faebcc;color:#8a6d3b}@media (max-width: 768px){.features-pane[_ngcontent-%COMP%]{border-right:0px!important}}@media (min-width: 1200px){.features-pane[_ngcontent-%COMP%]{border-left:1px solid #89b03e;border-bottom:1px solid #89b03e;border-top:1px solid #89b03e;border-radius:10px 0 0 10px}}.copyright[_ngcontent-%COMP%]{position:absolute;bottom:1.25rem;left:1.25rem}.copyright[_ngcontent-%COMP%] a[_ngcontent-%COMP%]{width:8.125rem;height:2.5rem;background-image:url(//res.cloudinary.com/pos/image/upload/POS/Images/Login/dealpos.png);background-position:left top;background-repeat:no-repeat;background-size:contain}.version[_ngcontent-%COMP%]{bottom:1.25rem;right:1.25rem;position:absolute}@media (max-width: 768px){.copyright[_ngcontent-%COMP%], .version[_ngcontent-%COMP%]{position:static;margin-top:10px}.copyright[_ngcontent-%COMP%]{justify-content:center}}div.divider[_ngcontent-%COMP%] > hr[_ngcontent-%COMP%]{margin-top:1.2rem;margin-bottom:1.2rem;border-top:1px solid rgba(0,0,0,.855);width:20%}button.btn-social-login[_ngcontent-%COMP%], .btn-login[_ngcontent-%COMP%]{border:1px solid var(--bs-success)}.fa-google[_ngcontent-%COMP%]{background:conic-gradient(from -45deg,#ea4335 110deg,#4285f4 90deg 180deg,#34a853 180deg 270deg,#fbbc05 270deg) 73% 55%/150% 150% no-repeat;-webkit-background-clip:text;background-clip:text;color:transparent;-webkit-text-fill-color:transparent}.version[_ngcontent-%COMP%] a[_ngcontent-%COMP%] i[_ngcontent-%COMP%]{color:#fe3a00!important}.version[_ngcontent-%COMP%] a[_ngcontent-%COMP%]:visited i[_ngcontent-%COMP%]{color:#f4f4f4!important}.version[_ngcontent-%COMP%] a[_ngcontent-%COMP%]:visited{margin-left:-10px}.domain-option[_ngcontent-%COMP%]{padding:.75rem;color:#343434;font-size:.875rem;width:8.5rem}.form-signin[_ngcontent-%COMP%]{max-width:600px}.card[_ngcontent-%COMP%]{font:100 14px/25px Roboto,Helvetica Neue,sans-serif;border-radius:13px;box-sizing:border-box}.text-shopee[_ngcontent-%COMP%]{color:#f53d2d}"]});let o=t;return o})();var ye=(()=>{let t=class t{constructor(n,e,s){this.route=n,this.http=e,this.service=s}ngOnInit(){this.route.queryParams.subscribe(n=>{this.code=n.code})}addChannelLazada(){let n={Code:this.code};this.http.post("/api/ChannelAdd/AddLazada",n).subscribe(e=>{this.service.navigate(["/menu/channel"])})}};t.\u0275fac=function(e){return new(e||t)(m(y),m(S),m(w))},t.\u0275cmp=f({type:t,selectors:[["app-lazada"]],standalone:!1,decls:20,vars:1,consts:[[1,"container","h-100"],[1,"row","d-flex","justify-content-center","align-items-center","h-100"],[1,"col-md-4"],[1,"card"],[1,"card-header","text-center"],[1,"far","fa-check-circle","text-success",2,"font-size","115px"],[1,"h3","fw-bold"],[1,"card-body","text-center","py-6"],[1,"text-shopee","fw-bold"],["type","button",1,"btn","btn-success","mt-6",3,"click"],[1,"fas","fa-undo"]],template:function(e,s){e&1&&(i(0,"div",0)(1,"div",1)(2,"div",2)(3,"div",3)(4,"div",4),l(5,"i",5),i(6,"div",6),a(7,"Success !"),r()(),i(8,"div",7)(9,"div"),a(10,"You have successfully authorized "),r(),i(11,"div"),a(12,"DEALPOS to manage your Lazada"),r(),i(13,"div"),a(14," Your Code is "),i(15,"span",8),a(16),r()(),i(17,"button",9),g("click",function(){return s.addChannelLazada()}),l(18,"i",10),a(19," Add to my Channel"),r()()()()()()),e&2&&(c(16),x(s.code))},encapsulation:2});let o=t;return o})();var Be=[{path:"",component:we,data:{title:"Dealpos x Marketplace"}},{path:"shopee",component:Oe,data:{title:"Success"}},{path:"tiktok",component:Pe,data:{title:"Success"}},{path:"lazada",component:ye,data:{title:"Success"}}],Se=(()=>{let t=class t{};t.\u0275fac=function(e){return new(e||t)},t.\u0275mod=A({type:t}),t.\u0275inj=T({imports:[V.forChild(Be),V]});let o=t;return o})();var kt=(()=>{let t=class t{};t.\u0275fac=function(e){return new(e||t)},t.\u0275mod=A({type:t}),t.\u0275inj=T({imports:[ee,me,Se,_e,xe]});let o=t;return o})();export{kt as LoginModule};
1
+ import{a as pe}from"./chunk-ZSUWHVKX.js";import{e as _e}from"./chunk-6KWG6O5L.js";import{a as ge,i as be}from"./chunk-I723PUUO.js";import"./chunk-QXRG5XYP.js";import"./chunk-RXLMJGUY.js";import"./chunk-AGBJEXIM.js";import{b as he,e as S}from"./chunk-OXWPYJNB.js";import"./chunk-XBIHN6D3.js";import{a as M,c as ue}from"./chunk-JBEKD57G.js";import{A as me,c as te,h as ne,i as ie,k as oe,m as re,n as ae,t as se,u as de,v as ce,w as le}from"./chunk-L3W6SG2T.js";import"./chunk-YTHY4IFS.js";import{a as fe,c as xe}from"./chunk-ZETUYNFJ.js";import{D as y,F as w,I as V,c as X,i as Z,m as ee}from"./chunk-LNJUGHOX.js";import{$b as C,Bc as W,Cc as B,Dc as q,Gb as f,Hb as A,Hc as k,Lc as H,Mc as a,Nc as x,Oc as Y,Pc as G,Qc as E,Rc as L,Sc as I,Z as R,ad as Q,bc as v,dc as z,ec as N,fc as D,gc as b,hc as i,hd as K,ic as r,id as $,jc as l,lb as O,ma as U,na as T,nb as c,qc as j,td as J,vc as g,xa as u,xc as p,ya as h,zb as m}from"./chunk-ZYJ6LAJ3.js";import"./chunk-WFMAM73Y.js";import"./chunk-66YHNWRR.js";var Ce=(()=>{let t=class t{constructor(){}getBrowserName(){let n=window.navigator.userAgent.toLowerCase();switch(!0){case(n.indexOf("edge")>-1||n.indexOf("edg")>-1):return"edge";case n.indexOf("opr")>-1:return"opera";case n.indexOf("chrome")>-1:return"chrome";case n.indexOf("trident")>-1:return"ie";case n.indexOf("firefox")>-1:return"firefox";case n.indexOf("safari")>-1:return"safari";default:return"other"}}};t.\u0275fac=function(e){return new(e||t)},t.\u0275prov=U({token:t,factory:t.\u0275fac,providedIn:"root"});let o=t;return o})();function Le(o,t){if(o&1&&(i(0,"swiper-slide")(1,"div")(2,"a",1),l(3,"img",2),r()(),i(4,"a",3),a(5),r(),i(6,"p",4),a(7),r()()),o&2){let d=t.$implicit;c(2),b("href",d.href,O),c(),b("src",d.imgSrc,O),c(),b("href",d.href,O),c(),x(d.title),c(2),x(d.description)}}var ve=(()=>{let t=class t{constructor(){this.newsList=J([])}};t.\u0275fac=function(e){return new(e||t)},t.\u0275cmp=f({type:t,selectors:[["POS-news-swiper"]],inputs:{newsList:[1,"newsList"]},standalone:!1,decls:3,vars:0,consts:[["pagination","true","pagination-clickable","true","autoplay-delay","5000","autoplay-disable-on-interaction","false",2,"margin-top","30px"],["target","_blank",3,"href"],[1,"border-0","rounded-1","mb-8",2,"width","252px","height","152px",3,"src"],["target","_blank",1,"fw-bold","h5","text-success","header-title","fs-4",3,"href"],[2,"margin-bottom","3rem"]],template:function(e,s){e&1&&(i(0,"swiper-container",0),N(1,Le,8,5,"swiper-slide",null,z),r()),e&2&&(c(),D(s.newsList()))},styles:["swiper-container[_ngcontent-%COMP%]{--swiper-pagination-bullet-inactive-color: #89b03e;--swiper-pagination-color: #89b03e}"]});let o=t;return o})();var Te=["subdomainEl"],Ae=(o,t)=>({"rounded-end":o,"border-end-0":t});function ze(o,t){if(o&1&&(i(0,"div",33),l(1,"img",34),r()),o&2){let d=t.$implicit;c(),b("src",d.img,O)("title",d.title)("alt",d.title)}}function Ne(o,t){if(o&1){let d=j();i(0,"div",15)(1,"h3",16),a(2," DealPOS Omnichannel "),r(),i(3,"small",17),a(4," Multichannel Inventory Management Software "),r()(),i(5,"form",18)(6,"div",19)(7,"div",20)(8,"div",21)(9,"span"),l(10,"i",22),r()(),i(11,"input",23,0),I("ngModelChange",function(e){u(d);let s=p();return L(s.subdomain,e)||(s.subdomain=e),h(e)}),r(),i(13,"div")(14,"select",24),I("ngModelChange",function(e){u(d);let s=p();return L(s.domain,e)||(s.domain=e),h(e)}),i(15,"option",25),a(16,".dealpos.co.id"),r(),i(17,"option",26),a(18,".dealpos.net"),r(),i(19,"option",27),a(20,".dealpos.com"),r(),i(21,"option",28),a(22,".dealpos.app"),r()()()(),i(23,"div",29)(24,"button",30),g("click",function(){u(d);let e=p();return h(e.onNextState())}),a(25," Next "),r()(),i(26,"div",31)(27,"div",32),N(28,ze,2,3,"div",33,z),r()()()()}if(o&2){let d=p();c(11),E("ngModel",d.subdomain),c(3),E("ngModel",d.domain),c(14),D(d.channels)}}function De(o,t){o&1&&(i(0,"p"),a(1," Username is required "),r())}function je(o,t){if(o&1&&(i(0,"div",44),l(1,"div",54),i(2,"div",55),C(3,De,2,0,"p"),r()()),o&2){p();let d=k(14);c(3),v(d.errors.required?3:-1)}}function Ve(o,t){if(o&1){let d=j();i(0,"i",57),g("click",function(){u(d);let e=p(3);return h(e.hideShowPassword())}),r()}if(o&2){let d=p(3);H("fa "+d.passwordIcon)}}function Fe(o,t){if(o&1&&(i(0,"span",47),C(1,Ve,1,2,"i",56),r()),o&2){let d=p(2);c(),v(d.password?1:-1)}}function Re(o,t){o&1&&(i(0,"p"),a(1," Password is required "),r())}function Ue(o,t){if(o&1&&(i(0,"div",44),l(1,"div",54),i(2,"div",55),C(3,Re,2,0,"p"),r()()),o&2){p();let d=k(21);c(3),v(d.errors.required?3:-1)}}function We(o,t){if(o&1){let d=j();i(0,"div",35)(1,"h3",36),a(2,"Sign in"),r(),i(3,"h3",37),a(4," to "),i(5,"h6",38),a(6),r(),i(7,"i",39),g("click",function(){u(d);let e=p();return h(e.onEditDomain())}),r()()(),i(8,"form",40)(9,"div",41)(10,"div",21)(11,"span"),l(12,"i",42),r()(),i(13,"input",43,1),I("ngModelChange",function(e){u(d);let s=p();return L(s.username,e)||(s.username=e),h(e)}),r()(),C(15,je,4,1,"div",44),i(16,"div",20)(17,"div",21)(18,"span"),l(19,"i",45),r()(),i(20,"input",46,2),I("ngModelChange",function(e){u(d);let s=p();return L(s.password,e)||(s.password=e),h(e)}),r(),C(22,Fe,2,1,"span",47),r(),C(23,Ue,4,1,"div",44),i(24,"div",48)(25,"button",49),g("click",function(){u(d);let e=p();return h(e.onLogin())}),a(26," Log in "),r()(),i(27,"div",50),l(28,"hr"),i(29,"span",51),a(30,"or"),r(),l(31,"hr"),r(),i(32,"div")(33,"button",52),g("click",function(e){u(d);let s=p();return h(s.onLoginByGoogle(e))}),l(34,"i",53),a(35," Sign In with Google "),r()()()}if(o&2){let d=k(14),n=k(21),e=p();c(6),G(" (",e.subdomain,"",e.domain,") "),c(7),E("ngModel",e.username),c(2),v(d.invalid&&(d.dirty||d.touched)?15:-1),c(5),b("type",e.passwordType)("ngClass",Q(9,Ae,e.browser=="edge",e.browser!="edge")),E("ngModel",e.password),c(2),v(e.browser!="edge"?22:-1),c(),v(n.invalid&&(n.dirty||n.touched)?23:-1)}}var we=(()=>{let t=class t{constructor(n,e,s,_,ke){this._router=n,this.toastr=e,this.checkBrowser=s,this.authService=_,this.ngxPermission=ke,this.domain=".dealpos.co.id",this.loginState="FORM_DOMAIN",this.passwordType="password",this.passwordIcon="fa-eye",this.channels=[{title:"Shopee",img:M.SHOOPE},{title:"Tokopedia",img:M.TOKOPEDIA},{title:"Tiktok",img:M.TIKTOK},{title:"Woocommerce",img:M.WOOCOMMERCE},{title:"Lazada",img:M.LAZADA},{title:"Shopify",img:M.SHOPIFY},{title:"Plugo",img:M.PLUGONEW}],this.version=ge.version,this.news$=_.getNews().pipe(R(1))}ngOnInit(){this.initLogin(),this.browser=this.checkBrowser.getBrowserName(),document.body.classList.add("login-body"),this.initChangeLogUrl()}initChangeLogUrl(){let n=`https://changelog.dealpos.com/?categories=cat_nILYcoEQzgGWX&view=complete&v=${this.version}`;this.changelogUrl=n}ngAfterViewInit(){this.setAutoFocusDomain()}initLogin(){let n=JSON.parse(localStorage.getItem("Authorization"));if(n){this.username=n?.username,this.subdomain=n?.Host?.split(".")[0];let e=n?.Host?.split("dealpos");this.domain=`.dealpos${e[1]}`,this.authService.isActiveToken()&&this._router.navigate(["menu"])}}onNextState(){if(ue.IsEmpty(this.subdomain)){this.toastr.warning("Account Domain is required","Warning");return}this.parseSubdomain(),this.loginState="FORM_AUTH"}parseSubdomain(){let n=this.subdomain.indexOf(".dealpos");n!=-1&&(this.subdomain=this.subdomain.substring(0,n))}onEditDomain(){this.loginState="FORM_DOMAIN"}onLogin(){let n={Host:`${this.subdomain}${this.domain}`,Username:this.username,Password:this.password};this.authService.login(n).subscribe(e=>{this.onSuccessLogin(e)})}onLoginByGoogle(n){let e=`${this.subdomain}${this.domain}`;this.authService.loginWithGoogle(n,e).subscribe(s=>{this.onSuccessLogin(s)})}onSuccessLogin(n){this.ngxPermission.hasPermission([pe.DashboardView]).then(e=>{e?this._router.navigate(["menu/dashboard"]):n?.TotalChannel<1?this._router.navigate(["menu/channel"]):this._router.navigate(["menu/products"])})}setAutoFocusDomain(){this.subdomainEl.nativeElement.focus()}hideShowPassword(){this.passwordType=this.passwordType==="text"?"password":"text",this.passwordIcon=this.passwordIcon==="fa-eye"?"fa-eye-slash":"fa-eye"}ngOnDestroy(){document.body.classList.remove("login-body")}};t.\u0275fac=function(e){return new(e||t)(m(w),m(he),m(Ce),m(be),m(fe))},t.\u0275cmp=f({type:t,selectors:[["app-login"]],viewQuery:function(e,s){if(e&1&&W(Te,5),e&2){let _;B(_=q())&&(s.subdomainEl=_.first)}},standalone:!1,decls:18,vars:6,consts:[["subdomainEl",""],["usernameCtrl","ngModel"],["passwordCtrl","ngModel"],[1,"container-fluid"],[1,"row","mx-auto","bg-white","login-pane"],[1,"col-md-5","order-md-first","order-last","border-end","features-pane","pt-12","pb-9"],[1,"fw-normal","fs-2","header-title","text-center"],[3,"newsList"],[1,"col-md-7","order-md-last","order-first","py-12","sign-in-pane"],[1,"d-flex","copyright",2,"margin-left","20px"],[1,"align-self-center","me-5"],["target","_blank","href","http://www.dealpos.com"],[1,"version",2,"margin-right","18px"],["target","_blank",1,"text-dark","fst-italic",3,"href"],[1,"fa-solid","fa-circle-exclamation","ms-2",2,"font-size","16px"],[1,"text-md-start","text-center"],[1,"fs-2","header-title","me-2","fw-normal"],[1,"text-secondary-emphasis","fst-italic",2,"font-size","11px"],[2,"margin-top","38px"],[1,"form-block","mt-5"],[1,"input-group","input-group-lg","mt-8"],[1,"input-group-text","rounded-start","border-end-0",2,"width","52px"],[1,"fa-solid","fa-cloud"],["placeholder","Store Address","aria-label","Store Address","aria-describedby","basic-addon1","autofocus","","name","Store Address",1,"form-control","form-control-lg","rounded-end-0","border-start-0","ps-1",2,"height","58px",3,"ngModelChange","ngModel"],["name","domainOption",1,"form-select","form-control","form-control-lg","border-start-0","border-start","rounded-end","rounded-start-0","domain-option",2,"height","58px",3,"ngModelChange","ngModel"],["selected","","value",".dealpos.co.id"],["value",".dealpos.net"],["value",".dealpos.com"],["value",".dealpos.app"],[1,"w-100",2,"margin-top","1.8rem"],["name","next","data-cy","next","type","submit",1,"btn","btn-xl","btn-success","btn-block","font125rem","robotoslab","w-100",3,"click"],[1,"d-flex","align-items-center","justify-content-center",2,"margin-top","2.1rem"],[1,"d-flex","align-items-center","justify-content-between","w-100"],[1,""],[1,"border-0",2,"width","34px","height","34px",3,"src","title","alt"],[1,"d-flex","align-items-center","justify-content-start","mb-2"],[1,"robotoslab","fw-normal"],[1,"ms-2","fw-normal"],[1,"me-2","robotoslab","d-inline-block","text-success"],["title","Edit Store Address",1,"fa-solid","fa-edit","link-success","fs-5","pointer",3,"click"],[2,"margin-top","29px"],[1,"input-group","input-group-lg"],[1,"fas","fa-user","fa-lg"],["id","txtUsername","type","text","data-cy","username","required","","placeholder","Username","aria-label","Username","aria-describedby","basic-addon1","autofocus","","name","username",1,"form-control","form-control-lg","rounded-end","border-start-0","ps-1",2,"height","58px",3,"ngModelChange","ngModel"],[1,"d-flex","justify-content-start","w-50","mb-4",2,"height","16px"],[1,"fas","fa-key","fa-lg"],["id","txtPassword","data-cy","password","placeholder","Password","aria-label","Password","aria-describedby","basic-addon1","autofocus","","name","password","required","",1,"form-control","form-control-lg","rounded-end","border-start-0","ps-1",2,"height","58px",3,"ngModelChange","type","ngClass","ngModel"],[1,"input-group-text","border-start-0","rounded-end"],[1,"w-100","mt-8"],["data-cy","login","type","submit",1,"btn","btn-lg","btn-success","btn-block","font125rem","robotoslab","w-100",3,"click"],[1,"divider","d-flex","align-items-center","justify-content-center"],[1,"mx-4","text-muted"],[1,"btn","btn-social-login","text-success","w-100","fw-bold",3,"click"],[1,"fa-brands","fa-google"],[2,"width","52px"],[1,"text-danger","ps-1"],[3,"class"],[3,"click"]],template:function(e,s){e&1&&(i(0,"div",3)(1,"div",4)(2,"div",5)(3,"h3",6),a(4,"New Features"),r(),l(5,"POS-news-swiper",7),K(6,"async"),r(),i(7,"div",8),C(8,Ne,30,2)(9,We,36,12),r()(),i(10,"div",9)(11,"span",10),a(12,"powered by :"),r(),l(13,"a",11),r(),i(14,"div",12)(15,"a",13),a(16),l(17,"i",14),r()()()),e&2&&(c(5),b("newsList",$(6,4,s.news$)),c(3),v(s.loginState=="FORM_DOMAIN"?8:9),c(7),b("href",s.changelogUrl,O),c(),Y("version ",s.version))},dependencies:[X,ae,de,ce,te,se,ne,ie,le,re,oe,ve,Z],styles:[".login-pane[_ngcontent-%COMP%]{max-width:57rem;height:max-content;margin-top:115px}@media (max-width: 768px){.login-pane[_ngcontent-%COMP%]{margin-top:0}}@media only screen and (max-width: 1300px) and (min-width: 1024px){.login-pane[_ngcontent-%COMP%]{margin-top:30px}}.header-title[_ngcontent-%COMP%]{font-family:Roboto Slab}.carousel-inner[_ngcontent-%COMP%]{height:310px}.carousel-inner[_ngcontent-%COMP%] div.carousel-item[_ngcontent-%COMP%]{top:28px}@media (max-width: 820px){.carousel-indicators[_ngcontent-%COMP%]{bottom:-8px}}.carousel-indicators[_ngcontent-%COMP%] button[_ngcontent-%COMP%]{background-color:#ddd;width:1.25rem;height:.375rem;transition:.3s}.carousel-indicators[_ngcontent-%COMP%] button.active[_ngcontent-%COMP%]{background-color:var(--bs-success)}.sign-in-pane[_ngcontent-%COMP%]{padding:0 3rem 0 3.5rem}@media (max-width: 768px){.sign-in-pane[_ngcontent-%COMP%]{padding:24px 12px}.sign-in-pane[_ngcontent-%COMP%] input[_ngcontent-%COMP%]{padding-left:8px!important}}@media (min-width: 1200px){.sign-in-pane[_ngcontent-%COMP%]{border-bottom:1px solid #89b03e;border-right:1px solid #89b03e;border-top:1px solid #89b03e;border-radius:0 10px 10px 0}}.subscription.danger[_ngcontent-%COMP%]{background-color:#f2dede;border-color:#eb415d;color:#a94442}.subscription.warning[_ngcontent-%COMP%]{background-color:#fcf8e3;border-color:#faebcc;color:#8a6d3b}@media (max-width: 768px){.features-pane[_ngcontent-%COMP%]{border-right:0px!important}}@media (min-width: 1200px){.features-pane[_ngcontent-%COMP%]{border-left:1px solid #89b03e;border-bottom:1px solid #89b03e;border-top:1px solid #89b03e;border-radius:10px 0 0 10px}}.copyright[_ngcontent-%COMP%]{position:absolute;bottom:1.25rem;left:1.25rem}.copyright[_ngcontent-%COMP%] a[_ngcontent-%COMP%]{width:8.125rem;height:2.5rem;background-image:url(//res.cloudinary.com/pos/image/upload/POS/Images/Login/dealpos.png);background-position:left top;background-repeat:no-repeat;background-size:contain}.version[_ngcontent-%COMP%]{bottom:1.25rem;right:1.25rem;position:absolute}@media (max-width: 768px){.copyright[_ngcontent-%COMP%], .version[_ngcontent-%COMP%]{position:static;margin-top:10px}.copyright[_ngcontent-%COMP%]{justify-content:center}}div.divider[_ngcontent-%COMP%] > hr[_ngcontent-%COMP%]{margin-top:1.2rem;margin-bottom:1.2rem;border-top:1px solid rgba(0,0,0,.855);width:20%}button.btn-social-login[_ngcontent-%COMP%], .btn-login[_ngcontent-%COMP%]{border:1px solid var(--bs-success)}.fa-google[_ngcontent-%COMP%]{background:conic-gradient(from -45deg,#ea4335 110deg,#4285f4 90deg 180deg,#34a853 180deg 270deg,#fbbc05 270deg) 73% 55%/150% 150% no-repeat;-webkit-background-clip:text;background-clip:text;color:transparent;-webkit-text-fill-color:transparent}.version[_ngcontent-%COMP%] a[_ngcontent-%COMP%] i[_ngcontent-%COMP%]{color:#fe3a00!important}.version[_ngcontent-%COMP%] a[_ngcontent-%COMP%]:visited i[_ngcontent-%COMP%]{color:#f4f4f4!important}.version[_ngcontent-%COMP%] a[_ngcontent-%COMP%]:visited{margin-left:-10px}.domain-option[_ngcontent-%COMP%]{padding:.75rem;color:#343434;font-size:.875rem;width:8.5rem}"]});let o=t;return o})();var Oe=(()=>{let t=class t{constructor(n,e,s){this.route=n,this.http=e,this.service=s}ngOnInit(){this.route.queryParams.subscribe(n=>{this.shopID=n.shop_id,this.code=n.code})}addShopee(){let n={ShopID:Number(this.shopID),Code:this.code};this.http.post("/api/ChannelAdd/ShopeeV2",n).subscribe(s=>{this.service.navigate(["/menu/channel"])})}};t.\u0275fac=function(e){return new(e||t)(m(y),m(S),m(w))},t.\u0275cmp=f({type:t,selectors:[["shopee-authorized"]],standalone:!1,decls:20,vars:1,consts:[[1,"container","h-100"],[1,"row","d-flex","justify-content-center","align-items-center","h-100"],[1,"col-md-4"],[1,"card"],[1,"card-header","text-center"],[1,"far","fa-check-circle","text-success",2,"font-size","115px"],[1,"h3","fw-bold"],[1,"card-body","text-center","py-6"],[1,"text-shopee","fw-bold"],["type","button",1,"btn","btn-success","mt-t",3,"click"],[1,"fas","fa-undo"]],template:function(e,s){e&1&&(i(0,"div",0)(1,"div",1)(2,"div",2)(3,"div",3)(4,"div",4),l(5,"i",5),i(6,"div",6),a(7,"Success !"),r()(),i(8,"div",7)(9,"div"),a(10,"You have successfully authorized "),r(),i(11,"div"),a(12,"DEALPOS to manage your Shopee"),r(),i(13,"div"),a(14," Your shopID is "),i(15,"span",8),a(16),r()(),i(17,"button",9),g("click",function(){return s.addShopee()}),l(18,"i",10),a(19," Add to my Channel"),r()()()()()()),e&2&&(c(16),x(s.shopID))},styles:[".login-pane[_ngcontent-%COMP%]{max-width:57rem;height:max-content;margin-top:115px}@media (max-width: 768px){.login-pane[_ngcontent-%COMP%]{margin-top:0}}@media only screen and (max-width: 1300px) and (min-width: 1024px){.login-pane[_ngcontent-%COMP%]{margin-top:30px}}.header-title[_ngcontent-%COMP%]{font-family:Roboto Slab}.carousel-inner[_ngcontent-%COMP%]{height:310px}.carousel-inner[_ngcontent-%COMP%] div.carousel-item[_ngcontent-%COMP%]{top:28px}@media (max-width: 820px){.carousel-indicators[_ngcontent-%COMP%]{bottom:-8px}}.carousel-indicators[_ngcontent-%COMP%] button[_ngcontent-%COMP%]{background-color:#ddd;width:1.25rem;height:.375rem;transition:.3s}.carousel-indicators[_ngcontent-%COMP%] button.active[_ngcontent-%COMP%]{background-color:var(--bs-success)}.sign-in-pane[_ngcontent-%COMP%]{padding:0 3rem 0 3.5rem}@media (max-width: 768px){.sign-in-pane[_ngcontent-%COMP%]{padding:24px 12px}.sign-in-pane[_ngcontent-%COMP%] input[_ngcontent-%COMP%]{padding-left:8px!important}}@media (min-width: 1200px){.sign-in-pane[_ngcontent-%COMP%]{border-bottom:1px solid #89b03e;border-right:1px solid #89b03e;border-top:1px solid #89b03e;border-radius:0 10px 10px 0}}.subscription.danger[_ngcontent-%COMP%]{background-color:#f2dede;border-color:#eb415d;color:#a94442}.subscription.warning[_ngcontent-%COMP%]{background-color:#fcf8e3;border-color:#faebcc;color:#8a6d3b}@media (max-width: 768px){.features-pane[_ngcontent-%COMP%]{border-right:0px!important}}@media (min-width: 1200px){.features-pane[_ngcontent-%COMP%]{border-left:1px solid #89b03e;border-bottom:1px solid #89b03e;border-top:1px solid #89b03e;border-radius:10px 0 0 10px}}.copyright[_ngcontent-%COMP%]{position:absolute;bottom:1.25rem;left:1.25rem}.copyright[_ngcontent-%COMP%] a[_ngcontent-%COMP%]{width:8.125rem;height:2.5rem;background-image:url(//res.cloudinary.com/pos/image/upload/POS/Images/Login/dealpos.png);background-position:left top;background-repeat:no-repeat;background-size:contain}.version[_ngcontent-%COMP%]{bottom:1.25rem;right:1.25rem;position:absolute}@media (max-width: 768px){.copyright[_ngcontent-%COMP%], .version[_ngcontent-%COMP%]{position:static;margin-top:10px}.copyright[_ngcontent-%COMP%]{justify-content:center}}div.divider[_ngcontent-%COMP%] > hr[_ngcontent-%COMP%]{margin-top:1.2rem;margin-bottom:1.2rem;border-top:1px solid rgba(0,0,0,.855);width:20%}button.btn-social-login[_ngcontent-%COMP%], .btn-login[_ngcontent-%COMP%]{border:1px solid var(--bs-success)}.fa-google[_ngcontent-%COMP%]{background:conic-gradient(from -45deg,#ea4335 110deg,#4285f4 90deg 180deg,#34a853 180deg 270deg,#fbbc05 270deg) 73% 55%/150% 150% no-repeat;-webkit-background-clip:text;background-clip:text;color:transparent;-webkit-text-fill-color:transparent}.version[_ngcontent-%COMP%] a[_ngcontent-%COMP%] i[_ngcontent-%COMP%]{color:#fe3a00!important}.version[_ngcontent-%COMP%] a[_ngcontent-%COMP%]:visited i[_ngcontent-%COMP%]{color:#f4f4f4!important}.version[_ngcontent-%COMP%] a[_ngcontent-%COMP%]:visited{margin-left:-10px}.domain-option[_ngcontent-%COMP%]{padding:.75rem;color:#343434;font-size:.875rem;width:8.5rem}.form-signin[_ngcontent-%COMP%]{max-width:600px}.card[_ngcontent-%COMP%]{font:100 14px/25px Roboto,Helvetica Neue,sans-serif;border-radius:13px;box-sizing:border-box}.text-shopee[_ngcontent-%COMP%]{color:#f53d2d}"]});let o=t;return o})();var Pe=(()=>{let t=class t{constructor(n,e,s){this.route=n,this.http=e,this.service=s}ngOnInit(){this.route.queryParams.subscribe(n=>{this.code=n.code,this.state=n.state})}addChannelTiktok(){let n={Code:this.code};this.http.post("/api/ChannelAdd/AddTiktok",n).subscribe(e=>{this.service.navigate(["/menu/channel"])})}};t.\u0275fac=function(e){return new(e||t)(m(y),m(S),m(w))},t.\u0275cmp=f({type:t,selectors:[["app-tiktok"]],standalone:!1,decls:24,vars:2,consts:[[1,"container","h-100"],[1,"row","d-flex","justify-content-center","align-items-center","h-100"],[1,"col-md-4"],[1,"card"],[1,"card-header","text-center"],[1,"far","fa-check-circle","text-success",2,"font-size","115px"],[1,"h3","fw-bold"],[1,"card-body","text-center","py-6"],[1,"text-shopee","fw-bold"],["type","button",1,"btn","btn-success","mt-6",3,"click"],[1,"fas","fa-undo"]],template:function(e,s){e&1&&(i(0,"div",0)(1,"div",1)(2,"div",2)(3,"div",3)(4,"div",4),l(5,"i",5),i(6,"div",6),a(7,"Success !"),r()(),i(8,"div",7)(9,"div"),a(10,"You have successfully authorized "),r(),i(11,"div"),a(12,"DEALPOS to manage your Tiktok"),r(),i(13,"div"),a(14," Your Code is "),i(15,"span",8),a(16),r()(),i(17,"div"),a(18," Your State is "),i(19,"span",8),a(20),r()(),i(21,"button",9),g("click",function(){return s.addChannelTiktok()}),l(22,"i",10),a(23," Add to my Channel"),r()()()()()()),e&2&&(c(16),x(s.code),c(4),x(s.state))},styles:[".login-pane[_ngcontent-%COMP%]{max-width:57rem;height:max-content;margin-top:115px}@media (max-width: 768px){.login-pane[_ngcontent-%COMP%]{margin-top:0}}@media only screen and (max-width: 1300px) and (min-width: 1024px){.login-pane[_ngcontent-%COMP%]{margin-top:30px}}.header-title[_ngcontent-%COMP%]{font-family:Roboto Slab}.carousel-inner[_ngcontent-%COMP%]{height:310px}.carousel-inner[_ngcontent-%COMP%] div.carousel-item[_ngcontent-%COMP%]{top:28px}@media (max-width: 820px){.carousel-indicators[_ngcontent-%COMP%]{bottom:-8px}}.carousel-indicators[_ngcontent-%COMP%] button[_ngcontent-%COMP%]{background-color:#ddd;width:1.25rem;height:.375rem;transition:.3s}.carousel-indicators[_ngcontent-%COMP%] button.active[_ngcontent-%COMP%]{background-color:var(--bs-success)}.sign-in-pane[_ngcontent-%COMP%]{padding:0 3rem 0 3.5rem}@media (max-width: 768px){.sign-in-pane[_ngcontent-%COMP%]{padding:24px 12px}.sign-in-pane[_ngcontent-%COMP%] input[_ngcontent-%COMP%]{padding-left:8px!important}}@media (min-width: 1200px){.sign-in-pane[_ngcontent-%COMP%]{border-bottom:1px solid #89b03e;border-right:1px solid #89b03e;border-top:1px solid #89b03e;border-radius:0 10px 10px 0}}.subscription.danger[_ngcontent-%COMP%]{background-color:#f2dede;border-color:#eb415d;color:#a94442}.subscription.warning[_ngcontent-%COMP%]{background-color:#fcf8e3;border-color:#faebcc;color:#8a6d3b}@media (max-width: 768px){.features-pane[_ngcontent-%COMP%]{border-right:0px!important}}@media (min-width: 1200px){.features-pane[_ngcontent-%COMP%]{border-left:1px solid #89b03e;border-bottom:1px solid #89b03e;border-top:1px solid #89b03e;border-radius:10px 0 0 10px}}.copyright[_ngcontent-%COMP%]{position:absolute;bottom:1.25rem;left:1.25rem}.copyright[_ngcontent-%COMP%] a[_ngcontent-%COMP%]{width:8.125rem;height:2.5rem;background-image:url(//res.cloudinary.com/pos/image/upload/POS/Images/Login/dealpos.png);background-position:left top;background-repeat:no-repeat;background-size:contain}.version[_ngcontent-%COMP%]{bottom:1.25rem;right:1.25rem;position:absolute}@media (max-width: 768px){.copyright[_ngcontent-%COMP%], .version[_ngcontent-%COMP%]{position:static;margin-top:10px}.copyright[_ngcontent-%COMP%]{justify-content:center}}div.divider[_ngcontent-%COMP%] > hr[_ngcontent-%COMP%]{margin-top:1.2rem;margin-bottom:1.2rem;border-top:1px solid rgba(0,0,0,.855);width:20%}button.btn-social-login[_ngcontent-%COMP%], .btn-login[_ngcontent-%COMP%]{border:1px solid var(--bs-success)}.fa-google[_ngcontent-%COMP%]{background:conic-gradient(from -45deg,#ea4335 110deg,#4285f4 90deg 180deg,#34a853 180deg 270deg,#fbbc05 270deg) 73% 55%/150% 150% no-repeat;-webkit-background-clip:text;background-clip:text;color:transparent;-webkit-text-fill-color:transparent}.version[_ngcontent-%COMP%] a[_ngcontent-%COMP%] i[_ngcontent-%COMP%]{color:#fe3a00!important}.version[_ngcontent-%COMP%] a[_ngcontent-%COMP%]:visited i[_ngcontent-%COMP%]{color:#f4f4f4!important}.version[_ngcontent-%COMP%] a[_ngcontent-%COMP%]:visited{margin-left:-10px}.domain-option[_ngcontent-%COMP%]{padding:.75rem;color:#343434;font-size:.875rem;width:8.5rem}.form-signin[_ngcontent-%COMP%]{max-width:600px}.card[_ngcontent-%COMP%]{font:100 14px/25px Roboto,Helvetica Neue,sans-serif;border-radius:13px;box-sizing:border-box}.text-shopee[_ngcontent-%COMP%]{color:#f53d2d}"]});let o=t;return o})();var ye=(()=>{let t=class t{constructor(n,e,s){this.route=n,this.http=e,this.service=s}ngOnInit(){this.route.queryParams.subscribe(n=>{this.code=n.code})}addChannelLazada(){let n={Code:this.code};this.http.post("/api/ChannelAdd/AddLazada",n).subscribe(e=>{this.service.navigate(["/menu/channel"])})}};t.\u0275fac=function(e){return new(e||t)(m(y),m(S),m(w))},t.\u0275cmp=f({type:t,selectors:[["app-lazada"]],standalone:!1,decls:20,vars:1,consts:[[1,"container","h-100"],[1,"row","d-flex","justify-content-center","align-items-center","h-100"],[1,"col-md-4"],[1,"card"],[1,"card-header","text-center"],[1,"far","fa-check-circle","text-success",2,"font-size","115px"],[1,"h3","fw-bold"],[1,"card-body","text-center","py-6"],[1,"text-shopee","fw-bold"],["type","button",1,"btn","btn-success","mt-6",3,"click"],[1,"fas","fa-undo"]],template:function(e,s){e&1&&(i(0,"div",0)(1,"div",1)(2,"div",2)(3,"div",3)(4,"div",4),l(5,"i",5),i(6,"div",6),a(7,"Success !"),r()(),i(8,"div",7)(9,"div"),a(10,"You have successfully authorized "),r(),i(11,"div"),a(12,"DEALPOS to manage your Lazada"),r(),i(13,"div"),a(14," Your Code is "),i(15,"span",8),a(16),r()(),i(17,"button",9),g("click",function(){return s.addChannelLazada()}),l(18,"i",10),a(19," Add to my Channel"),r()()()()()()),e&2&&(c(16),x(s.code))},encapsulation:2});let o=t;return o})();var Be=[{path:"",component:we,data:{title:"Dealpos x Marketplace"}},{path:"shopee",component:Oe,data:{title:"Success"}},{path:"tiktok",component:Pe,data:{title:"Success"}},{path:"lazada",component:ye,data:{title:"Success"}}],Se=(()=>{let t=class t{};t.\u0275fac=function(e){return new(e||t)},t.\u0275mod=A({type:t}),t.\u0275inj=T({imports:[V.forChild(Be),V]});let o=t;return o})();var kt=(()=>{let t=class t{};t.\u0275fac=function(e){return new(e||t)},t.\u0275mod=A({type:t}),t.\u0275inj=T({imports:[ee,me,Se,_e,xe]});let o=t;return o})();export{kt as LoginModule};
@@ -1 +1 @@
1
- import{a as r}from"./chunk-XF2QZL6C.js";import{a as l,b as u}from"./chunk-A7PUMY67.js";import"./chunk-Q4AWQ7IC.js";import"./chunk-QXRG5XYP.js";import"./chunk-RXLMJGUY.js";import"./chunk-AGBJEXIM.js";import"./chunk-OXWPYJNB.js";import"./chunk-XBIHN6D3.js";import"./chunk-JBEKD57G.js";import"./chunk-YTHY4IFS.js";import"./chunk-ZETUYNFJ.js";import"./chunk-STYL7ETF.js";import"./chunk-XLIPGDSC.js";import{E as m,I as s}from"./chunk-LNJUGHOX.js";import{Gb as i,gc as p,hc as c,ic as d,jc as n,nb as a}from"./chunk-ZYJ6LAJ3.js";import"./chunk-WFMAM73Y.js";import"./chunk-66YHNWRR.js";var h=(()=>{let e=class e{constructor(){this.tabs=[{Title:"Origin Order API",Url:"/menu/json-api/order-api"},{Title:"Origin Product API",Url:"/menu/json-api/product-api"},{Title:"Origin Escrow API",Url:"/menu/json-api/escrow-api"}]}};e.\u0275fac=function(o){return new(o||e)},e.\u0275cmp=i({type:e,selectors:[["app-json-api"]],decls:5,vars:1,consts:[[1,"navbar","page-nav","navbar-default","py-0","navbar-expand-lg"],[1,"container-fluid"],[3,"Tabs"]],template:function(o,f){o&1&&(c(0,"nav",0)(1,"div",1)(2,"div"),n(3,"nav-tab",2),d()()(),n(4,"router-outlet")),o&2&&(a(3),p("Tabs",f.tabs))},dependencies:[u,l,s,m],encapsulation:2});let t=e;return t})(),O=[{path:"",component:h,children:[{path:"",redirectTo:"order-api",pathMatch:"full"},{path:"order-api",loadComponent(){return import("./chunk-IYDRCUIT.js").then(t=>t.OrderApiComponent)},canActivate:[r],data:{title:"Order API"}},{path:"product-api",loadComponent(){return import("./chunk-I3Q5TAIL.js").then(t=>t.ProductApiComponent)},canActivate:[r],data:{title:"Product API"}},{path:"escrow-api",loadComponent(){return import("./chunk-RXZ43ZSY.js").then(t=>t.EscrowApiComponent)},canActivate:[r],data:{title:"Escrow API"}}]}];export{h as JsonApiComponent,O as routes};
1
+ import{a as r}from"./chunk-UCEZJNIL.js";import{a as l,b as u}from"./chunk-A7PUMY67.js";import"./chunk-I723PUUO.js";import"./chunk-QXRG5XYP.js";import"./chunk-RXLMJGUY.js";import"./chunk-AGBJEXIM.js";import"./chunk-OXWPYJNB.js";import"./chunk-XBIHN6D3.js";import"./chunk-JBEKD57G.js";import"./chunk-YTHY4IFS.js";import"./chunk-ZETUYNFJ.js";import"./chunk-STYL7ETF.js";import"./chunk-XLIPGDSC.js";import{E as m,I as s}from"./chunk-LNJUGHOX.js";import{Gb as i,gc as p,hc as c,ic as d,jc as n,nb as a}from"./chunk-ZYJ6LAJ3.js";import"./chunk-WFMAM73Y.js";import"./chunk-66YHNWRR.js";var h=(()=>{let e=class e{constructor(){this.tabs=[{Title:"Origin Order API",Url:"/menu/json-api/order-api"},{Title:"Origin Product API",Url:"/menu/json-api/product-api"},{Title:"Origin Escrow API",Url:"/menu/json-api/escrow-api"}]}};e.\u0275fac=function(o){return new(o||e)},e.\u0275cmp=i({type:e,selectors:[["app-json-api"]],decls:5,vars:1,consts:[[1,"navbar","page-nav","navbar-default","py-0","navbar-expand-lg"],[1,"container-fluid"],[3,"Tabs"]],template:function(o,f){o&1&&(c(0,"nav",0)(1,"div",1)(2,"div"),n(3,"nav-tab",2),d()()(),n(4,"router-outlet")),o&2&&(a(3),p("Tabs",f.tabs))},dependencies:[u,l,s,m],encapsulation:2});let t=e;return t})(),O=[{path:"",component:h,children:[{path:"",redirectTo:"order-api",pathMatch:"full"},{path:"order-api",loadComponent(){return import("./chunk-C6JHPCLF.js").then(t=>t.OrderApiComponent)},canActivate:[r],data:{title:"Order API"}},{path:"product-api",loadComponent(){return import("./chunk-FRZCC6KZ.js").then(t=>t.ProductApiComponent)},canActivate:[r],data:{title:"Product API"}},{path:"escrow-api",loadComponent(){return import("./chunk-SZVL42NR.js").then(t=>t.EscrowApiComponent)},canActivate:[r],data:{title:"Escrow API"}}]}];export{h as JsonApiComponent,O as routes};
@@ -1 +1 @@
1
- import{a as j}from"./chunk-S7CKRTJV.js";import{b as Oe}from"./chunk-ZME22WYI.js";import{a as ie}from"./chunk-7JQEF4XX.js";import"./chunk-AFIF6VRM.js";import"./chunk-ZW2TMVZP.js";import{a as ne,b as Re}from"./chunk-FKGKMEDE.js";import"./chunk-ZKIO2ZQ6.js";import{a as W}from"./chunk-XF2QZL6C.js";import"./chunk-ZTHO6JJM.js";import"./chunk-SHUYFOQI.js";import"./chunk-FCEXPGTK.js";import"./chunk-QFSA7CU4.js";import"./chunk-OPXITNRF.js";import"./chunk-FULVA6QB.js";import"./chunk-HPINZVE4.js";import"./chunk-D2J64VUP.js";import"./chunk-6Q6L5NUD.js";import"./chunk-C7N6EI73.js";import"./chunk-GPHNPV7O.js";import"./chunk-3RK6DDJD.js";import"./chunk-4YCSITNV.js";import"./chunk-WHHW4IZT.js";import{a as Me,b as Pe}from"./chunk-A7PUMY67.js";import"./chunk-N5AE5WMQ.js";import{a as $,b as ee,d as te,e as Te}from"./chunk-6KWG6O5L.js";import"./chunk-A6QXXKPR.js";import{i as V}from"./chunk-Q4AWQ7IC.js";import"./chunk-QXRG5XYP.js";import"./chunk-RXLMJGUY.js";import"./chunk-AGBJEXIM.js";import{e as I}from"./chunk-OXWPYJNB.js";import"./chunk-XBIHN6D3.js";import{c as A}from"./chunk-JBEKD57G.js";import{m as T,n as Le}from"./chunk-EDEZ3JLR.js";import{A as we,B as Ie,c as Q,h as X,m as Y,o as Z,u as xe,v as Ee}from"./chunk-L3W6SG2T.js";import"./chunk-YTHY4IFS.js";import"./chunk-ZETUYNFJ.js";import{v as De,w as Ne}from"./chunk-STYL7ETF.js";import"./chunk-XLIPGDSC.js";import{D as B,E as be,G as N,I as ge,c as ce,i as Se,j as w,k as q,m as ue}from"./chunk-LNJUGHOX.js";import{$b as _,$c as F,Gb as b,Hb as pe,Lc as ye,Mb as z,Mc as n,Nc as p,Oc as M,Qc as h,Rc as f,Sc as v,_c as K,bc as y,dc as H,ec as U,fc as J,gc as u,hc as t,hd as S,ic as i,id as O,jc as D,jd as E,lb as G,ma as me,na as se,nb as r,qc as R,ra as g,v as de,vc as x,xa as P,xc as C,ya as L}from"./chunk-ZYJ6LAJ3.js";import"./chunk-WFMAM73Y.js";import"./chunk-66YHNWRR.js";var We=(()=>{let a=class a{constructor(){this.ObjectlogTabs=[{Title:"Channel Push Log Exception",Url:"/menu/log/exception"},{Title:"Channel Push Log",Url:"/menu/log/rawlog"},{Title:"POS Sync Order Log",Url:"/menu/log/order"},{Title:"Inventory Sync ",Url:"/menu/log/inventory"},{Title:"Authorization Log ",Url:"/menu/log/authorization-log"}]}};a.\u0275fac=function(d){return new(d||a)},a.\u0275cmp=b({type:a,selectors:[["app-logs"]],standalone:!1,decls:5,vars:1,consts:[[1,"navbar","page-nav","navbar-default","py-0","navbar-expand-lg"],[1,"container-fluid"],[3,"Tabs"]],template:function(d,e){d&1&&(t(0,"nav",0)(1,"div",1)(2,"div"),D(3,"nav-tab",2),i()()(),D(4,"router-outlet")),d&2&&(r(3),u("Tabs",e.ObjectlogTabs))},dependencies:[be,Me],encapsulation:2});let o=a;return o})();var ae=(()=>{let a=class a{constructor(){}get Data(){return this._Data}set Data(s){this._Data=s}Fill(s){return this._Data.find(d=>d._id==s)}};a.\u0275fac=function(d){return new(d||a)},a.\u0275prov=me({token:a,factory:a.\u0275fac,providedIn:"root"});let o=a;return o})();var Je=()=>["/menu/log/order/detail-user"],Ke=o=>({ID:o}),Qe=o=>({"bg-warning":o});function Xe(o,a){if(o&1&&(t(0,"span",22),D(1,"img",23),i(),n(2)),o&2){let l=a.item;r(),u("src",l.Img,G)("alt",l.Name),r(),M(" ",l.Name," ")}}function Ye(o,a){o&1&&(t(0,"th",26)(1,"span",29),n(2," Response Body Warning "),i()())}function Ze(o,a){o&1&&(t(0,"th")(1,"span",29),n(2," Number Override "),i()())}function $e(o,a){if(o&1&&(t(0,"td",26)(1,"span",32),n(2),i()()),o&2){let l=C().$implicit;r(),u("ngClass",F(2,Qe,l.responseBodyWarning!=null)),r(),p(l.responseBodyWarning)}}function et(o,a){if(o&1&&(t(0,"td"),n(1),i()),o&2){let l=C().$implicit;r(),M(" ",l.ResponseBodyWarningReference," ")}}function tt(o,a){if(o&1&&(t(0,"tr")(1,"td")(2,"a",30),n(3),S(4,"date"),i()(),t(5,"td"),n(6),i(),t(7,"td"),n(8),i(),t(9,"td"),n(10),i(),t(11,"td",26)(12,"span",31),n(13),i()(),_(14,$e,3,4,"td",26),_(15,et,2,1,"td"),i()),o&2){let l=a.$implicit,s=C(2);r(2),u("routerLink",K(14,Je))("queryParams",F(15,Ke,l.ID)),r(),M(" ",E(4,11,l.Created,"dd MMM yyyy HH:mm:ss")," "),r(3),p(l.ChannelName),r(2),p(l.POSActionTypeString),r(2),p(l.Number),r(2),ye(l.ResponseCode===200||l.ResponseCode===202?"bg-success":"bg-warning"),r(),M(" ",l.ResponseCode," "),r(),y(s.responseBodyWarningVisible?14:-1),r(),y(s.responseBodyWarningVisible?15:-1)}}function it(o,a){if(o&1){let l=R();t(0,"div",20)(1,"table",24)(2,"thead")(3,"tr",25)(4,"th"),n(5,"Date"),i(),t(6,"th"),n(7,"Channel"),i(),t(8,"th"),n(9,"Actions"),i(),t(10,"th"),n(11,"Number"),i(),t(12,"th",26)(13,"span",27),n(14," Response Code "),i()(),_(15,Ye,3,0,"th",26),_(16,Ze,3,0,"th"),i()(),t(17,"tbody"),U(18,tt,16,17,"tr",null,H),i()(),t(20,"mat-paginator",28),x("page",function(d){P(l);let e=C();return L(e.changePage(d))}),i()()}if(o&2){let l=C();r(15),y(l.responseBodyWarningVisible?15:-1),r(),y(l.responseBodyWarningVisible?16:-1),r(2),J(l.Result),r(2),u("length",l.paginationTotal)("pageSize",l.paginationPageSize)("pageIndex",(l.filter==null?null:l.filter.PageNumber)==0?0:(l.filter==null?null:l.filter.PageNumber)-1)}}function nt(o,a){o&1&&(t(0,"div",21),D(1,"app-empty-state"),i())}var ke=(()=>{let a=class a{constructor(){this.http=g(I),this._RawLogService=g(ae),this.route=g(B),this.authService=g(V),this.Result=Array(),this.filter={RowCount:20,Number:"",PageNumber:1,ActionType:"",ChannelID:"",StatusCode:"",From:"",To:"",responseBodyWarning:""},this.responseBodyWarningVisible=!1,this.channelOptions=this.authService.getChannels()}ngOnInit(){this.route.queryParams.subscribe(s=>{this.responseCode=s.responseCode,this.responseCode!=null?this.Load(s):this.Load()})}Load(s={}){this.http.post("/api/OrdersLoader/Get",s).subscribe(d=>{this.filter=d.Filter,this.ActionTypeList=d.Options.ActionTypeList,this.Get()})}Get(s){this.filter.Number=s,this.http.post("/api/Orders/Get",this.filter).subscribe(d=>{this._RawLogService.Data=d.hits,this.Result=Array();for(let e of d.hits){e._source.log.responseBodyWarning!=null&&(this.responseBodyWarningVisible=!0);let c={ID:e._id,Created:e._source["@timestamp_received"],shopId:e._source.shopId,MarketTypeString:e._source.log.type,ChannelName:e._source?.channelId!=null?this.channelOptions.find(m=>m.ID===e._source?.channelId)?.Name:"",POSActionTypeString:e._source.message,Number:e._source.log.number,ResponseCode:e._source.log.responseCode,responseBodyWarning:e._source.log.responseBodyWarning,ResponseBodyWarningReference:e._source.log.ResponseBodyWarningReference};this.Result.push(c)}this.paginationTotal=d.total.value,this.paginationPageSize=this.filter.RowCount>this.paginationTotal?this.paginationTotal:this.filter.RowCount})}changePage(s){this.filter.PageNumber=s.pageIndex+1,this.Get()}};a.\u0275fac=function(d){return new(d||a)},a.\u0275cmp=b({type:a,selectors:[["app-order"]],standalone:!1,decls:42,vars:14,consts:[["headerTitle","Order Log","searchBoxPlaceHolder","Invoice Number..",3,"textChange","onSubmit","text"],[1,"fw-bold","mb-2"],["appendTo","body","bindLabel","Name","name","channelid","bindValue","ID","placeholder","Select Channel",1,"center-text",3,"ngModelChange","clearable","items","ngModel"],["ng-option-tmp","","ng-label-tmp",""],[1,"mt-5"],["bindLabel","Value","name","ActionType","bindValue","Key","placeholder","Action Type",1,"center-text",3,"ngModelChange","clearable","items","ngModel"],[1,"fw-bold","mb-1"],[1,"mb-4"],["name","From",3,"dateChange","date"],["name","To",3,"dateChange","date"],[1,"fw-bold"],["type","text","name","StatusCode",1,"w-100","mt-2","form-control",3,"ngModelChange","ngModel"],["type","text","name","responseBodyWarning","list","listresponseBodyWarning",1,"w-100","mt-2","form-control",3,"ngModelChange","ngModel"],["id","listresponseBodyWarning"],["value","number-override"],["type","number","name","PageNumber",1,"w-100","mt-2","form-control",3,"ngModelChange","ngModel"],["type","number","name","RowCount",1,"w-100","mt-2","form-control",3,"ngModelChange","ngModel"],[1,"container-fluid","mt-3"],[1,"row"],[1,"col-md-12"],[1,"table-responsive"],[1,"d-flex","flex-column","justify-content-center","align-items-center",2,"margin-top","26vh"],[1,"me-2"],[2,"width","18px",3,"src","alt"],[1,"table","table-hover"],[1,"table-light"],[1,"text-center"],["matTooltip","Http Status Code from developer.dealpos.com."],[3,"page","length","pageSize","pageIndex"],["matTooltip","ex: when payload.Number != response.Number value will be number-override"],[3,"routerLink","queryParams"],[1,"text-white","p-2","rounded","response-desc"],[1,"text-white","p-2","rounded","response-desc",3,"ngClass"]],template:function(d,e){d&1&&(t(0,"mainpanel",0),v("textChange",function(m){return f(e.Number,m)||(e.Number=m),m}),x("onSubmit",function(m){return e.Get(m)}),t(1,"filters")(2,"div")(3,"label",1),n(4,"Channel"),i(),t(5,"ng-select",2),v("ngModelChange",function(m){return f(e.filter.ChannelID,m)||(e.filter.ChannelID=m),m}),z(6,Xe,3,3,"ng-template",3),i()(),t(7,"div",4)(8,"label",1),n(9,"Action"),i(),t(10,"ng-select",5),v("ngModelChange",function(m){return f(e.filter.ActionType,m)||(e.filter.ActionType=m),m}),i()(),t(11,"div",4)(12,"label",6),n(13,"From/To"),i(),t(14,"div",7)(15,"datepicker",8),v("dateChange",function(m){return f(e.filter.From,m)||(e.filter.From=m),m}),i()(),t(16,"div")(17,"datepicker",9),v("dateChange",function(m){return f(e.filter.To,m)||(e.filter.To=m),m}),i()()(),t(18,"div",4)(19,"label",10),n(20,"Response Code"),i(),t(21,"input",11),v("ngModelChange",function(m){return f(e.filter.StatusCode,m)||(e.filter.StatusCode=m),m}),i()(),t(22,"div",4)(23,"label",10),n(24,"Response Body Warning"),i(),t(25,"input",12),v("ngModelChange",function(m){return f(e.filter.responseBodyWarning,m)||(e.filter.responseBodyWarning=m),m}),i(),t(26,"datalist",13),D(27,"option",14),i()(),t(28,"div",4)(29,"label",10),n(30,"Page Number"),i(),t(31,"input",15),v("ngModelChange",function(m){return f(e.filter.PageNumber,m)||(e.filter.PageNumber=m),m}),i()(),t(32,"div",4)(33,"label",10),n(34,"Page Size"),i(),t(35,"input",16),v("ngModelChange",function(m){return f(e.filter.RowCount,m)||(e.filter.RowCount=m),m}),i()()(),t(36,"content")(37,"div",17)(38,"div",18)(39,"div",19),_(40,it,21,5,"div",20)(41,nt,2,0,"div",21),i()()()()()),d&2&&(h("text",e.Number),r(5),u("clearable",!0)("items",e.channelOptions),h("ngModel",e.filter.ChannelID),r(5),u("clearable",!0)("items",e.ActionTypeList),h("ngModel",e.filter.ActionType),r(5),h("date",e.filter.From),r(2),h("date",e.filter.To),r(4),h("ngModel",e.filter.StatusCode),r(4),h("ngModel",e.filter.responseBodyWarning),r(6),h("ngModel",e.filter.PageNumber),r(4),h("ngModel",e.filter.RowCount),r(5),y((e.Result==null?null:e.Result.length)>0?40:41))},dependencies:[ce,xe,Ee,Q,Z,X,Y,N,T,ne,te,$,ee,j,ie,De,w],encapsulation:2});let o=a;return o})();var ot=o=>({"bg-gradient-warning":o}),at=()=>["/menu/log/inventory/sync-inventory/detail"],rt=o=>({ID:o});function lt(o,a){if(o&1&&(t(0,"span",19),D(1,"img",20),i(),n(2)),o&2){let l=a.item;r(),u("src",l.Img,G)("alt",l.Name),r(),M(" ",l.Name," ")}}function dt(o,a){if(o&1&&(t(0,"tr",23)(1,"td")(2,"a",25),n(3),S(4,"date"),i()(),t(5,"td"),n(6),i(),t(7,"td"),n(8),i(),t(9,"td"),n(10),i(),t(11,"td"),n(12),i()()),o&2){let l=a.$implicit;u("ngClass",F(11,ot,l.ResponseCode==400)),r(2),u("routerLink",K(13,at))("queryParams",F(14,rt,l.ID)),r(),M(" ",E(4,8,l.Created,"dd MMM yyyy HH:mm")," "),r(3),p(l.channelName),r(2),p(l.Sku),r(2),p(l.Stock),r(2),p(l.ResponseCode)}}function mt(o,a){if(o&1){let l=R();t(0,"div",17)(1,"table",21)(2,"thead")(3,"tr",22)(4,"th"),n(5,"Created"),i(),t(6,"th"),n(7,"Channel"),i(),t(8,"th"),n(9,"SKU"),i(),t(10,"th"),n(11,"Stock"),i(),t(12,"th"),n(13,"Response code"),i()()(),t(14,"tbody"),U(15,dt,13,16,"tr",23,H),i()(),t(17,"mat-paginator",24),x("page",function(d){P(l);let e=C();return L(e.changePage(d))}),i()()}if(o&2){let l=C();r(15),J(l.Result),r(2),u("length",l.paginationTotal)("pageSize",l.paginationPageSize)("pageIndex",(l.filter==null?null:l.filter.PageNumber)==0?0:(l.filter==null?null:l.filter.PageNumber)-1)}}function st(o,a){o&1&&(t(0,"div",18),D(1,"app-empty-state"),i())}var Be=(()=>{let a=class a{constructor(){this.http=g(I),this._RawLogService=g(ae),this.authService=g(V),this.Result=Array(),this.filter={PageNumber:0,RowCount:20,Sku:null,ChannelID:"",StatusCode:"",From:"",To:""},this.Load(),this.channelOptions=this.authService.getChannels()}Load(){this.http.post("/api/OrdersLoader/Get",{}).subscribe(s=>{this.filter=s.Filter,this.ActionTypeList=s.Options.ActionTypeList,this.Get()})}Get(s){s!=null&&(this.filter.Sku=s),this.http.post("api/Inventory/GetLog",this.filter).subscribe(d=>{this._RawLogService.Data=d.hits,this.Result=Array();for(let e of d.hits){let c={ID:e._source.log.id,Created:e._source["@timestamp_received"],channelName:e._source.log.channelName,Sku:e._source.log.sku,Stock:e._source.log.stock,ResponseCode:e._source.log.responseCode};this.Result.push(c)}this.paginationTotal=d.total.value,this.paginationPageSize=this.filter.RowCount>this.paginationTotal?this.paginationTotal:this.filter.RowCount})}changePage(s){this.filter.PageNumber=s.pageIndex+1,this.Get()}};a.\u0275fac=function(d){return new(d||a)},a.\u0275cmp=b({type:a,selectors:[["app-inventory-log"]],standalone:!1,decls:32,vars:9,consts:[["headerTitle","Channel Inventory Sync","searchBoxPlaceHolder","Enter SKU...",3,"textChange","onSubmit","text"],["role","button","routerLink","/menu/log/inventory",1,"btn","btn-success"],["container",""],[1,"fw-bold","mb-2"],["appendTo","body","bindLabel","Name","name","channelid","bindValue","ID","placeholder","Select Channel",1,"center-text",3,"ngModelChange","clearable","items","ngModel"],["ng-option-tmp","","ng-label-tmp",""],[1,"mt-5"],[1,"fw-bold","mb-1"],[1,"mb-4"],["name","From",3,"dateChange","date"],["name","To",3,"dateChange","date"],[1,"fw-bold"],["type","number","name","PageNumber",1,"w-100","mt-2","form-control",3,"ngModelChange","ngModel"],["type","number","name","RowCount",1,"w-100","mt-2","form-control",3,"ngModelChange","ngModel"],[1,"container-fluid","mt-3"],[1,"row"],[1,"col-md-12"],[1,"table-responsive"],[1,"d-flex","flex-column","justify-content-center","align-items-center",2,"margin-top","26vh"],[1,"me-2"],[2,"width","18px",3,"src","alt"],[1,"table","table-hover"],[1,"table-light"],[3,"ngClass"],[3,"page","length","pageSize","pageIndex"],[3,"routerLink","queryParams"]],template:function(d,e){d&1&&(t(0,"mainpanel",0),v("textChange",function(m){return f(e.filter.Sku,m)||(e.filter.Sku=m),m}),x("onSubmit",function(m){return e.Get(m)}),t(1,"actions")(2,"a",1),n(3," Order Inventory Sync Job "),i()(),t(4,"filters")(5,"div",2)(6,"div")(7,"label",3),n(8,"Channel"),i(),t(9,"ng-select",4),v("ngModelChange",function(m){return f(e.filter.ChannelID,m)||(e.filter.ChannelID=m),m}),z(10,lt,3,3,"ng-template",5),i()(),t(11,"div",6)(12,"label",7),n(13,"From/To"),i(),t(14,"div",8)(15,"datepicker",9),v("dateChange",function(m){return f(e.filter.From,m)||(e.filter.From=m),m}),i()(),t(16,"div")(17,"datepicker",10),v("dateChange",function(m){return f(e.filter.To,m)||(e.filter.To=m),m}),i()()(),t(18,"div",6)(19,"label",11),n(20,"Page Number"),i(),t(21,"input",12),v("ngModelChange",function(m){return f(e.filter.PageNumber,m)||(e.filter.PageNumber=m),m}),i()(),t(22,"div",6)(23,"label",11),n(24,"Page Size"),i(),t(25,"input",13),v("ngModelChange",function(m){return f(e.filter.RowCount,m)||(e.filter.RowCount=m),m}),i()()()(),t(26,"content")(27,"div",14)(28,"div",15)(29,"div",16),_(30,mt,18,3,"div",17)(31,st,2,0,"div",18),i()()()()()),d&2&&(h("text",e.filter.Sku),r(9),u("clearable",!0)("items",e.channelOptions),h("ngModel",e.filter.ChannelID),r(6),h("date",e.filter.From),r(2),h("date",e.filter.To),r(4),h("ngModel",e.filter.PageNumber),r(4),h("ngModel",e.filter.RowCount),r(5),y((e.Result==null?null:e.Result.length)>0?30:31))},dependencies:[ce,Q,Z,X,Y,N,T,ne,te,$,ee,j,ie,w],encapsulation:2});let o=a;return o})();var pt=()=>["/menu/log/rawlog/detail"],ct=o=>({ID:o});function ut(o,a){if(o&1&&(t(0,"span",17),D(1,"img",18),i(),n(2)),o&2){let l=a.item;r(),u("src",l.Img,G)("alt",l.Name),r(),M(" ",l.Name," ")}}function gt(o,a){if(o&1&&(t(0,"tr")(1,"td")(2,"a",23),n(3),S(4,"date"),i()(),t(5,"td"),n(6),i(),t(7,"td"),n(8),i(),t(9,"td"),n(10),i()()),o&2){let l=a.$implicit;r(2),u("routerLink",K(9,pt))("queryParams",F(10,ct,l.id)),r(),M(" ",E(4,6,l.Created,"dd MMM yyyy HH:mm:ss")," "),r(3),p(l.type),r(2),p(l.number),r(2),p(l.message)}}function ht(o,a){if(o&1){let l=R();t(0,"div",15)(1,"table",19)(2,"thead",20)(3,"tr")(4,"th",21),n(5,"Date"),i(),t(6,"th"),n(7,"Type"),i(),t(8,"th"),n(9,"Number"),i(),t(10,"th"),n(11,"Message"),i()()(),t(12,"tbody"),U(13,gt,11,12,"tr",null,H),i()(),t(15,"mat-paginator",22),x("page",function(d){P(l);let e=C();return L(e.changePage(d))}),i()()}if(o&2){let l=C();r(13),J(l.Result),r(2),u("length",l.paginationTotal)("pageSize",l.paginationPageSize)("pageIndex",(l.filter==null?null:l.filter.PageNumber)==0?0:(l.filter==null?null:l.filter.PageNumber)-1)}}function ft(o,a){o&1&&(t(0,"div",16),D(1,"app-empty-state"),i())}var Ae=(()=>{let a=class a{constructor(){this.http=g(I),this._RawLogService=g(ae),this.authService=g(V),this.Result=Array(),this.filter={RowCount:20,Number:"",PageNumber:1,ActionType:"",ChannelID:"",StatusCode:"",From:"",To:""},this.list=[],this.Types=[{Key:0,Value:"Shopee"},{Key:1,Value:"Tokopedia"}],this.channelOptions=this.authService.getChannels()}ngOnInit(){this.Load()}Load(s={}){this.http.post("/api/OrdersLoader/Get",s).subscribe(d=>{this.filter=d.Filter,this.ActionTypeList=d.Options.ActionTypeList,this.Get()})}Get(s){this.filter.Number=s,this.http.post("api/Orders/GetRawLog",this.filter).subscribe(d=>{this._RawLogService.Data=d.hits,this.Result=Array();for(let e of d.hits){let c={id:e._id,message:e._source.message,responseCode:e._source.log.responseCode,processTypeString:e._source.log.processType,type:e._source.log.type,number:e._source.log.number,Created:e._source["@timestamp_received"]};this.Result.push(c)}this.paginationTotal=d.total.value,this.paginationPageSize=this.filter.RowCount>this.paginationTotal?this.paginationTotal:this.filter.RowCount})}changePage(s){this.filter.PageNumber=s.pageIndex+1,this.Get()}};a.\u0275fac=function(d){return new(d||a)},a.\u0275cmp=b({type:a,selectors:[["app-raw-log"]],standalone:!1,decls:28,vars:9,consts:[["headerTitle","Channel Push Log","searchBoxPlaceHolder","Invoice Number..",3,"textChange","onSubmit","text"],[1,"fw-bold","mb-2"],["appendTo","body","bindLabel","Name","name","channelid","bindValue","ID","placeholder","Select Channel",1,"center-text",3,"ngModelChange","clearable","items","ngModel"],["ng-option-tmp","","ng-label-tmp",""],[1,"mt-5"],[1,"fw-bold","mb-1"],[1,"mb-4"],["name","From",3,"dateChange","date"],["name","To",3,"dateChange","date"],[1,"fw-bold"],["type","number","name","PageNumber",1,"w-100","mt-2","form-control",3,"ngModelChange","ngModel"],["type","number","name","RowCount",1,"w-100","mt-2","form-control",3,"ngModelChange","ngModel"],[1,"container-fluid","mt-3"],[1,"row"],[1,"col-md-12"],[1,"table-responsive"],[1,"d-flex","flex-column","justify-content-center","align-items-center",2,"margin-top","26vh"],[1,"me-2"],[2,"width","18px",3,"src","alt"],[1,"table"],[1,"thead-light"],[2,"width","200px"],[3,"page","length","pageSize","pageIndex"],[3,"routerLink","queryParams"]],template:function(d,e){d&1&&(t(0,"mainpanel",0),v("textChange",function(m){return f(e.filter.Number,m)||(e.filter.Number=m),m}),x("onSubmit",function(m){return e.Get(m)}),t(1,"filters")(2,"div")(3,"label",1),n(4,"Channel"),i(),t(5,"ng-select",2),v("ngModelChange",function(m){return f(e.filter.ChannelID,m)||(e.filter.ChannelID=m),m}),z(6,ut,3,3,"ng-template",3),i()(),t(7,"div",4)(8,"label",5),n(9,"From/To"),i(),t(10,"div",6)(11,"datepicker",7),v("dateChange",function(m){return f(e.filter.From,m)||(e.filter.From=m),m}),i()(),t(12,"div")(13,"datepicker",8),v("dateChange",function(m){return f(e.filter.To,m)||(e.filter.To=m),m}),i()()(),t(14,"div",4)(15,"label",9),n(16,"Page Number"),i(),t(17,"input",10),v("ngModelChange",function(m){return f(e.filter.PageNumber,m)||(e.filter.PageNumber=m),m}),i()(),t(18,"div",4)(19,"label",9),n(20,"Page Size"),i(),t(21,"input",11),v("ngModelChange",function(m){return f(e.filter.RowCount,m)||(e.filter.RowCount=m),m}),i()()(),t(22,"content")(23,"div",12)(24,"div",13)(25,"div",14),_(26,ht,16,3,"div",15)(27,ft,2,0,"div",16),i()()()()()),d&2&&(h("text",e.filter.Number),r(5),u("clearable",!0)("items",e.channelOptions),h("ngModel",e.filter.ChannelID),r(6),h("date",e.filter.From),r(2),h("date",e.filter.To),r(4),h("ngModel",e.filter.PageNumber),r(4),h("ngModel",e.filter.RowCount),r(5),y((e.Result==null?null:e.Result.length)>0?26:27))},dependencies:[Q,Z,X,Y,N,T,ne,te,$,ee,j,ie,w],encapsulation:2});let o=a;return o})();function vt(o,a){if(o&1&&(t(0,"div",9)(1,"div",10)(2,"label"),n(3,"Process Code"),i(),t(4,"div")(5,"span"),n(6),i()()()()),o&2){let l=C();r(6),p(l.ProcessedCode)}}function Ct(o,a){if(o&1){let l=R();t(0,"a",15),x("click",function(){P(l);let d=C();return L(d.Retry())}),n(1,"Retry"),i()}}var Fe=(()=>{let a=class a{constructor(){this.route=g(B),this.http=g(I),this.ProcessDuration=0,this.request="",this.response="",this.route.queryParams.subscribe(s=>{this.ID=s.ID,this.Load()})}Retry(){var s={Number:this.Number,ShopID:this.shopId};this.http.post("/api/Orders/Retry",s).subscribe(d=>{alert(JSON.stringify(d))})}Load(){var s={ID:this.ID};this.http.post("/api/Orders/GetDetailChannelWebhook",s).subscribe(d=>{for(let e of d.hits)this.Number=e._source.log.number,this.MarketTypeString=e._source.log.type,this.ResponseCode=e._source.log.responseCode,this.POSActionTypeString=e._source.message,this.ProcessDuration=0,this.Created=e._source["@timestamp_received"],this.request=A.IsNotEmpty(e._source?.log?.request)?JSON.parse(e._source.log?.request):"",this.response=A.IsNotEmpty(e._source?.log?.response)?JSON.parse(e._source.log?.response):"",this.shopId=e._source.shopId,this.ProcessedCode=e._source.log.processedCode})}};a.\u0275fac=function(d){return new(d||a)},a.\u0275cmp=b({type:a,selectors:[["app-raw-detail"]],standalone:!1,decls:83,vars:21,consts:[[3,"headerTitle","pageData","hideSearchBox","hideSearchDropdown"],["role","button","routerLink","/menu/log/order",1,"btn","btn-secondary","btn-fill","btn-lg","me-3"],[1,"container-fluid","mt-3"],[1,"row"],[1,"col-sm-12"],[1,"card"],[1,"card-header"],[1,"card-body"],[1,"row","mt-7"],[1,"col-sm-6"],[1,"info-label-group"],[1,"row","mt-2"],[1,"form-group"],[1,"float-right"],["role","button",1,"btn","btn-success","btn-fill","btn-lg","me-3"],["role","button",1,"btn","btn-success","btn-fill","btn-lg","me-3",3,"click"]],template:function(d,e){d&1&&(t(0,"mainpanel",0)(1,"actions")(2,"a",1),n(3,"Back"),i()(),t(4,"content")(5,"div",2)(6,"div",3)(7,"div",4)(8,"div",5)(9,"div",6)(10,"h5"),n(11,"General"),i()(),t(12,"div",7)(13,"div",8)(14,"div",9)(15,"div",10)(16,"label"),n(17,"Date"),i(),t(18,"div")(19,"span"),n(20),S(21,"date"),i()()()(),t(22,"div",9)(23,"div",10)(24,"label"),n(25,"Number"),i(),t(26,"div")(27,"span"),n(28),i()()()(),t(29,"div",9)(30,"div",10)(31,"label"),n(32,"Type"),i(),t(33,"div")(34,"span"),n(35),i()()()(),t(36,"div",9)(37,"div",10)(38,"label"),n(39,"Response Code"),i(),t(40,"div")(41,"span"),n(42),i()()()(),t(43,"div",9)(44,"div",10)(45,"label"),n(46,"ShopID"),i(),t(47,"div")(48,"span"),n(49),i()()()(),_(50,vt,7,1,"div",9),t(51,"div",9)(52,"div",10)(53,"label"),n(54,"Action"),i(),t(55,"div")(56,"span"),n(57),i()()()()()()()()(),t(58,"div",11)(59,"div",9)(60,"div",5)(61,"div",6)(62,"h5"),n(63,"Request"),i()(),t(64,"div",7)(65,"div",4)(66,"div",12)(67,"pre"),n(68),S(69,"json"),i()()(),t(70,"actions",13),_(71,Ct,2,0,"a",14),i()()()(),t(72,"div",9)(73,"div",5)(74,"div",6)(75,"h5"),n(76,"Response"),i()(),t(77,"div",7)(78,"div",4)(79,"div",12)(80,"pre"),n(81),S(82,"json"),i()()()()()()()()()()),d&2&&(u("headerTitle","Order #"+e.Number)("pageData","Orders Detail ")("hideSearchBox",!0)("hideSearchDropdown",!0),r(20),p(E(21,14,e.Created,"dd MMM yyyy HH:mm:ss")),r(8),p(e.Number),r(7),p(e.MarketTypeString),r(7),p(e.ResponseCode),r(7),p(e.shopId),r(),y(e.ProcessedCode!=null?50:-1),r(7),p(e.POSActionTypeString),r(11),p(O(69,17,e.request)),r(3),y(e.ResponseCode!="200"&&e.ResponseCode!="201"?71:-1),r(10),p(O(82,19,e.response)))},dependencies:[N,T,q,w],encapsulation:2});let o=a;return o})();function _t(o,a){if(o&1&&(t(0,"div",4)(1,"div",7)(2,"div",8)(3,"h5"),n(4,"General"),i()(),t(5,"div",9)(6,"div",3)(7,"div",6)(8,"div",11)(9,"label"),n(10,"Date"),i(),t(11,"div")(12,"span"),n(13),S(14,"date"),i()()()(),t(15,"div",6)(16,"div",11)(17,"label"),n(18,"SKU"),i(),t(19,"div")(20,"span"),n(21),i()()()(),t(22,"div",6)(23,"div",11)(24,"label"),n(25,"Channel"),i(),t(26,"div")(27,"span"),n(28),i()()()(),t(29,"div",6)(30,"div",11)(31,"label"),n(32,"Response Code"),i(),t(33,"div")(34,"span"),n(35),i()()()()()()()()),o&2){let l=C();r(13),p(E(14,4,l.data.Created,"dd MMM yyyy")),r(8),p(l.data.Sku),r(7),p(l.data.ChannelName),r(7),p(l.data.ResponseCode)}}var qe=(()=>{let a=class a{constructor(){this.route=g(B),this.http=g(I),this._RawLogService=g(ae),this.data={Created:"",Sku:"",ChannelName:"",ResponseCode:""},this.route.queryParams.subscribe(s=>{this.ID=s.ID,this.Load()})}ngOnInit(){}Load(){var s={ID:this.ID};this.http.post("/api/Inventory/GetInventoryLogDeatil",s).subscribe(d=>{this.data.Created=d.hits[0]._source["@timestamp_received"],this.data.Sku=d.hits[0]._source.log.sku,this.data.ChannelName=d.hits[0]._source.log.channelName,this.data.ResponseCode=d.hits[0]._source.log.responseCode,this.request=A.IsNotEmpty(d.hits[0]?._source.log?.request)?JSON.parse(d.hits[0]?._source?.log?.request):"",this.response=d.hits[0]._source.log.response})}};a.\u0275fac=function(d){return new(d||a)},a.\u0275cmp=b({type:a,selectors:[["app-inventory-detail"]],standalone:!1,decls:30,vars:7,consts:[["headerTitle","Product Inventory Sync Detail",3,"hideSearchBox","hideSearchDropdown"],["role","button","routerLink","/menu/log/inventory/sync-inventory",1,"btn","btn-secondary","btn-fill","btn-lg","me-2"],[1,"container-fluid","mt-3"],[1,"row"],[1,"col-sm-12"],[1,"row","mt-2"],[1,"col-sm-6"],[1,"card"],[1,"card-header"],[1,"card-body"],[1,"form-group"],[1,"info-label-group"]],template:function(d,e){d&1&&(t(0,"mainpanel",0)(1,"actions")(2,"a",1),n(3,"Back"),i()(),t(4,"content")(5,"div",2)(6,"div",3),_(7,_t,36,7,"div",4),i(),t(8,"div",5)(9,"div",6)(10,"div",7)(11,"div",8)(12,"h5"),n(13,"Request"),i()(),t(14,"div",9)(15,"div",4)(16,"div",10)(17,"pre"),n(18),S(19,"json"),i()()()()()(),t(20,"div",6)(21,"div",7)(22,"div",8)(23,"h5"),n(24,"Response"),i()(),t(25,"div",9)(26,"div",4)(27,"div",10)(28,"pre"),n(29),i()()()()()()()()()()),d&2&&(u("hideSearchBox",!0)("hideSearchDropdown",!0),r(7),y(e.data?7:-1),r(11),p(O(19,5,e.request)),r(11),p(e.response))},dependencies:[N,T,q,w],encapsulation:2});let o=a;return o})();function yt(o,a){if(o&1&&(t(0,"div",9)(1,"div",10)(2,"label"),n(3,"Process Code"),i(),t(4,"div")(5,"span"),n(6),i()()()()),o&2){let l=C();r(6),p(l.ProcessedCode)}}function St(o,a){if(o&1){let l=R();t(0,"a",15),x("click",function(){P(l);let d=C();return L(d.Retry())}),n(1,"Retry"),i()}}var Ve=(()=>{let a=class a{constructor(){this.route=g(B),this.http=g(I),this.ProcessDuration=0,this.request="",this.response="",this.route.queryParams.subscribe(s=>{this.ID=s.ID,this.Load()})}Retry(){var s={Number:this.Number,ShopID:this.shopId};this.http.post("/api/Orders/Retry",s).subscribe(d=>{alert(JSON.stringify(d))})}Load(){var s={ID:this.ID};this.http.post("/api/Orders/GetDetailChannelWebhook",s).subscribe(d=>{for(let e of d.hits)this.Number=e._source.log.number,this.MarketTypeString=e._source.log.type,this.ResponseCode=e._source.log.responseCode,this.POSActionTypeString=e._source.message,this.ProcessDuration=0,this.Created=e._source["@timestamp_received"],this.request=A.IsNotEmpty(e._source?.log?.request)?JSON.parse(e._source.log?.request):"",this.response=A.IsNotEmpty(e._source?.log?.response)?JSON.parse(e._source.log?.response):"",this.shopId=e._source.shopId,this.ProcessedCode=e._source.log.processedCode})}};a.\u0275fac=function(d){return new(d||a)},a.\u0275cmp=b({type:a,selectors:[["app-orderdetail"]],standalone:!1,decls:83,vars:21,consts:[[3,"headerTitle","pageData","hideSearchBox","hideSearchDropdown"],["role","button","routerLink","/menu/log/order",1,"btn","btn-secondary","btn-fill","btn-lg","me-3"],[1,"container-fluid","mt-3"],[1,"row"],[1,"col-sm-12"],[1,"card"],[1,"card-header"],[1,"card-body"],[1,"row","mt-7"],[1,"col-sm-6"],[1,"info-label-group"],[1,"row","mt-2"],[1,"form-group"],[1,"float-right"],["role","button",1,"btn","btn-success","btn-fill","btn-lg","me-3"],["role","button",1,"btn","btn-success","btn-fill","btn-lg","me-3",3,"click"]],template:function(d,e){d&1&&(t(0,"mainpanel",0)(1,"actions")(2,"a",1),n(3,"Back"),i()(),t(4,"content")(5,"div",2)(6,"div",3)(7,"div",4)(8,"div",5)(9,"div",6)(10,"h5"),n(11,"General"),i()(),t(12,"div",7)(13,"div",8)(14,"div",9)(15,"div",10)(16,"label"),n(17,"Date"),i(),t(18,"div")(19,"span"),n(20),S(21,"date"),i()()()(),t(22,"div",9)(23,"div",10)(24,"label"),n(25,"Number"),i(),t(26,"div")(27,"span"),n(28),i()()()(),t(29,"div",9)(30,"div",10)(31,"label"),n(32,"Type"),i(),t(33,"div")(34,"span"),n(35),i()()()(),t(36,"div",9)(37,"div",10)(38,"label"),n(39,"Response Code"),i(),t(40,"div")(41,"span"),n(42),i()()()(),t(43,"div",9)(44,"div",10)(45,"label"),n(46,"ShopID"),i(),t(47,"div")(48,"span"),n(49),i()()()(),_(50,yt,7,1,"div",9),t(51,"div",9)(52,"div",10)(53,"label"),n(54,"Action"),i(),t(55,"div")(56,"span"),n(57),i()()()()()()()()(),t(58,"div",11)(59,"div",9)(60,"div",5)(61,"div",6)(62,"h5"),n(63,"Request"),i()(),t(64,"div",7)(65,"div",4)(66,"div",12)(67,"pre"),n(68),S(69,"json"),i()()(),t(70,"actions",13),_(71,St,2,0,"a",14),i()()()(),t(72,"div",9)(73,"div",5)(74,"div",6)(75,"h5"),n(76,"Response"),i()(),t(77,"div",7)(78,"div",4)(79,"div",12)(80,"pre"),n(81),S(82,"json"),i()()()()()()()()()()),d&2&&(u("headerTitle","Order #"+e.Number)("pageData","Orders Detail ")("hideSearchBox",!0)("hideSearchDropdown",!0),r(20),p(E(21,14,e.Created,"dd MMM yyyy HH:mm:ss")),r(8),p(e.Number),r(7),p(e.MarketTypeString),r(7),p(e.ResponseCode),r(7),p(e.shopId),r(),y(e.ProcessedCode!=null?50:-1),r(7),p(e.POSActionTypeString),r(11),p(O(69,17,e.request)),r(3),y(e.ResponseCode!="200"&&e.ResponseCode!="201"?71:-1),r(10),p(O(82,19,e.response)))},dependencies:[N,T,q,w],encapsulation:2});let o=a;return o})();var bt=()=>["/menu/log/exception/detail"],xt=o=>({ID:o});function Et(o,a){if(o&1&&(t(0,"span",17),D(1,"img",18),i(),n(2)),o&2){let l=a.item;r(),u("src",l.Img,G)("alt",l.Name),r(),M(" ",l.Name," ")}}function wt(o,a){if(o&1&&D(0,"img",23),o&2){let l=C().$implicit;u("src",l.Logo,G)}}function It(o,a){if(o&1&&(t(0,"tr")(1,"td"),_(2,wt,1,1,"img",23),n(3),i(),t(4,"td")(5,"a",24),n(6),i()(),t(7,"td"),n(8),S(9,"date"),i(),t(10,"td")(11,"div",9),n(12),i(),t(13,"div"),n(14),i()()()),o&2){let l=a.$implicit;r(2),y(l.Logo?2:-1),r(),M(" ",l.ChannelName," "),r(2),u("routerLink",K(11,bt))("queryParams",F(12,xt,l.id)),r(),M(" ",l.number??"N/A"," "),r(2),p(E(9,8,l.date,"dd-MM-yyyy hh:mm:ss")),r(4),p(l.message),r(2),p(l.stackTrace)}}function Tt(o,a){if(o&1){let l=R();t(0,"mat-paginator",25),x("page",function(d){P(l);let e=C(2);return L(e.onPaginationChange(d))}),i()}if(o&2){let l=C(2);u("length",l.pageTotal)("pageSize",l.pageSize)("pageIndex",(l.filter==null?null:l.filter.PageNumber)==0?0:(l.filter==null?null:l.filter.PageNumber)-1)}}function Dt(o,a){if(o&1&&(t(0,"div",15)(1,"table",19)(2,"thead")(3,"tr",20)(4,"th",21),n(5,"Channel Name"),i(),t(6,"th",21),n(7,"Number"),i(),t(8,"th",21),n(9,"Date"),i(),t(10,"th"),n(11,"Exception"),i()()(),t(12,"tbody"),U(13,It,15,14,"tr",null,H),i()(),_(15,Tt,1,3,"mat-paginator",22),i()),o&2){let l=C();r(13),J(l.exceptions),r(2),y((l.exceptions==null?null:l.exceptions.length)>0?15:-1)}}function Nt(o,a){o&1&&(t(0,"div",16),D(1,"app-empty-state"),i())}var je=(()=>{let a=class a{constructor(){this.http=g(I),this.authService=g(V),this.exceptions=[],this.filter={RowCount:50,PageNumber:1,Number:null,From:null,To:null,ChannelID:null},this.channelOptions=this.authService.getChannels()}ngOnInit(){this.Load()}Load(s={}){this.http.post("/api/OrdersLoader/Get",s).subscribe(d=>{this.filter=d.Filter,this.getData()})}getData(s){this.filter.Number=s,this.http.post("/api/Orders/GetExceptionList",this.filter).subscribe(d=>{this.exceptions=d.hits.map(e=>({id:e._id,ChannelName:e._source?.channelId!=null?this.channelOptions.find(c=>c.ID===e._source?.channelId)?.Name:e._source?.shopId,Logo:e._source?.channelId!=null?this.channelOptions.find(c=>c.ID===e._source?.channelId)?.Img:null,number:e._source?.error?.number,date:e._source["@timestamp_received"],stackTrace:e._source?.error?.stackTrace,message:e._source?.message,requestJSON:e._source?.error?.requestJSON})),this.pageTotal=d.total.value,this.pageSize=this.filter.RowCount>this.pageTotal?this.pageTotal:this.filter.RowCount})}onPaginationChange(s){this.filter.PageNumber=s.pageIndex+1,this.getData()}};a.\u0275fac=function(d){return new(d||a)},a.\u0275cmp=b({type:a,selectors:[["app-exception-log"]],standalone:!1,decls:28,vars:8,consts:[["headerTitle","Exception Log","searchBoxPlaceHolder","Enter Number...",3,"onSubmit"],[1,"fw-bold","mb-2"],["appendTo","body","bindLabel","Name","name","channelid","bindValue","ID","placeholder","Select Channel",1,"center-text",3,"ngModelChange","clearable","items","ngModel"],["ng-option-tmp","","ng-label-tmp",""],[1,"mt-5"],[1,"fw-bold","mb-1"],[1,"mb-4"],["name","From",3,"dateChange","date"],["name","To",3,"dateChange","date"],[1,"fw-bold"],["type","number","name","PageNumber",1,"w-100","mt-2","form-control",3,"ngModelChange","ngModel"],["type","number","name","RowCount",1,"w-100","mt-2","form-control",3,"ngModelChange","ngModel"],[1,"container-fluid","mt-3"],[1,"row"],[1,"col-md-12"],[1,"table-responsive"],[1,"d-flex","flex-column","justify-content-center","align-items-center",2,"margin-top","26vh"],[1,"me-2"],[2,"width","18px",3,"src","alt"],[1,"table","table-hover"],[1,"table-light"],[2,"width","10%"],[3,"length","pageSize","pageIndex"],["alt","Logo",2,"width","18px",3,"src"],[3,"routerLink","queryParams"],[3,"page","length","pageSize","pageIndex"]],template:function(d,e){d&1&&(t(0,"mainpanel",0),x("onSubmit",function(m){return e.getData(m)}),t(1,"filters")(2,"div")(3,"label",1),n(4,"Channel"),i(),t(5,"ng-select",2),v("ngModelChange",function(m){return f(e.filter.ChannelID,m)||(e.filter.ChannelID=m),m}),z(6,Et,3,3,"ng-template",3),i()(),t(7,"div",4)(8,"label",5),n(9,"From/To"),i(),t(10,"div",6)(11,"datepicker",7),v("dateChange",function(m){return f(e.filter.From,m)||(e.filter.From=m),m}),i()(),t(12,"div")(13,"datepicker",8),v("dateChange",function(m){return f(e.filter.To,m)||(e.filter.To=m),m}),i()()(),t(14,"div",4)(15,"label",9),n(16,"Page Number"),i(),t(17,"input",10),v("ngModelChange",function(m){return f(e.filter.PageNumber,m)||(e.filter.PageNumber=m),m}),i()(),t(18,"div",4)(19,"label",9),n(20,"Page Size"),i(),t(21,"input",11),v("ngModelChange",function(m){return f(e.filter.RowCount,m)||(e.filter.RowCount=m),m}),i()()(),t(22,"content")(23,"div",12)(24,"div",13)(25,"div",14),_(26,Dt,16,1,"div",15)(27,Nt,2,0,"div",16),i()()()()()),d&2&&(r(5),u("clearable",!0)("items",e.channelOptions),h("ngModel",e.filter.ChannelID),r(6),h("date",e.filter.From),r(2),h("date",e.filter.To),r(4),h("ngModel",e.filter.PageNumber),r(4),h("ngModel",e.filter.RowCount),r(5),y(e.exceptions.length>0?26:27))},dependencies:[Q,Z,X,Y,N,T,ne,te,$,ee,j,ie,w],encapsulation:2});let o=a;return o})();var Ge=(()=>{let a=class a{constructor(){this.httpService=g(I)}getExceptionDetail(s){return this.httpService.post("/api/Orders/GetDetailException",{ID:s}).pipe(de(e=>e?.hits[0]?._source))}};a.\u0275fac=function(d){return new(d||a)},a.\u0275prov=me({token:a,factory:a.\u0275fac,providedIn:"root"});let o=a;return o})();function Mt(o,a){if(o&1&&(t(0,"div",1)(1,"div",2)(2,"div",3)(3,"div",4)(4,"div",5)(5,"h5"),n(6,"General"),i()(),t(7,"div",6)(8,"div",7)(9,"div",8)(10,"div",9)(11,"label"),n(12,"Date"),i(),t(13,"div")(14,"span"),n(15),S(16,"date"),i()()()(),t(17,"div",8)(18,"div",9)(19,"label"),n(20,"Number"),i(),t(21,"div")(22,"span"),n(23),i()()()(),t(24,"div",8)(25,"div",9)(26,"label"),n(27,"Channel Name"),i(),t(28,"div")(29,"span"),n(30),i()()()(),t(31,"div",8)(32,"div",9)(33,"label"),n(34,"ShopID"),i(),t(35,"div")(36,"span"),n(37),i()()()(),t(38,"div",8)(39,"div",9)(40,"label"),n(41,"Channel ID"),i(),t(42,"div")(43,"span"),n(44),i()()()()()()()()(),t(45,"div",10)(46,"div",8)(47,"div",4)(48,"div",5)(49,"h5"),n(50,"Request"),i()(),t(51,"div",6)(52,"div",11)(53,"div",12)(54,"pre"),n(55),S(56,"json"),i()()()()()(),t(57,"div",8)(58,"div",4)(59,"div",5)(60,"h5"),n(61,"Exception"),i()(),t(62,"div",6)(63,"div",13)(64,"div",12)(65,"pre"),n(66),i()()()()()()()()),o&2){let l=a;r(15),p(E(16,7,l["@timestamp"],"dd MMM yyyy HH:mm:ss")),r(8),p(l==null||l.error==null?null:l.error.number),r(7),p(l==null?null:l.channelName),r(7),p(l==null?null:l.shopId),r(7),p(l==null?null:l.message),r(11),p(O(56,10,l==null||l.error==null?null:l.error.request)),r(11),p(l==null||l.error==null?null:l.error.response)}}var ze=(()=>{let a=class a{constructor(){this.activatedRoute=g(B),this.exceptionService=g(Ge),this.authService=g(V),this.invoiceNumber="",this.channelName="",this.logo=null,this.channelOptions=this.authService.getChannels()}ngOnInit(){let s=this.activatedRoute.snapshot.queryParams;this.exceptionDetail$=this.exceptionService.getExceptionDetail(s?.ID).pipe(de(d=>{let e=d;return{"@timestamp":e["@timestamp"]||e["@timestamp_received"],error:{number:e?.error?.number,request:JSON.parse(e?.error?.request),response:JSON.parse(e?.error?.response)},channelName:e?.channelId!=null?this.channelOptions.find(c=>c.ID===e?.channelId)?.Name:e?.shopId,shopId:e?.shopId,message:e?.message}}))}};a.\u0275fac=function(d){return new(d||a)},a.\u0275cmp=b({type:a,selectors:[["app-exception-detail"]],standalone:!1,decls:4,vars:6,consts:[[3,"headerTitle","hideSearchBox","hideSearchDropdown"],[1,"container-fluid","mt-3"],[1,"row"],[1,"col-12"],[1,"card"],[1,"card-header"],[1,"card-body"],[1,"row","mt-7"],[1,"col-sm-6"],[1,"info-label-group"],[1,"row","mt-2"],[1,"col-sm-12"],[1,"form-group"],[1,"col-sm-12","mt-2"]],template:function(d,e){if(d&1&&(t(0,"mainpanel",0)(1,"content"),_(2,Mt,67,12,"div",1),S(3,"async"),i()()),d&2){let c;u("headerTitle","Order #"+e.invoiceNumber)("hideSearchBox",!0)("hideSearchDropdown",!0),r(2),y((c=O(3,4,e.exceptionDetail$))?2:-1,c)}},dependencies:[T,Se,q,w],encapsulation:2});let o=a;return o})();function Pt(o,a){if(o&1&&(t(0,"div",9)(1,"div",10)(2,"label"),n(3,"Process Code"),i(),t(4,"div")(5,"span"),n(6),i()()()()),o&2){let l=C();r(6),p(l.ProcessedCode)}}function Lt(o,a){if(o&1){let l=R();t(0,"a",15),x("click",function(){P(l);let d=C();return L(d.Retry())}),n(1,"Retry"),i()}}var He=(()=>{let a=class a{constructor(){this.route=g(B),this.http=g(I),this.ProcessDuration=0,this.request="",this.response="",this.route.queryParams.subscribe(s=>{this.ID=s.ID,this.Load()})}Retry(){var s={Number:this.Number,ShopID:this.shopId};this.http.post("/api/Orders/Retry",s).subscribe(d=>{alert(JSON.stringify(d))})}Load(){var s={ID:this.ID};this.http.post("/api/Orders/GetDetailSyncOrder",s).subscribe(d=>{for(let e of d.hits)this.Number=e._source.log.number,this.MarketTypeString=e._source.log.type,this.ResponseCode=e._source.log.responseCode,this.POSActionTypeString=e._source.message,this.ProcessDuration=0,this.Created=e._source["@timestamp_received"],this.request=A.IsNotEmpty(e._source?.log?.request)?JSON.parse(e._source.log?.request):"",this.response=A.IsNotEmpty(e._source?.log?.response)?JSON.parse(e._source.log?.response):"",this.shopId=e._source.shopId,this.ProcessedCode=e._source.log.processedCode})}};a.\u0275fac=function(d){return new(d||a)},a.\u0275cmp=b({type:a,selectors:[["app-orderdetail-user"]],standalone:!1,decls:83,vars:21,consts:[[3,"headerTitle","pageData","hideSearchBox","hideSearchDropdown"],["role","button","routerLink","/menu/log/order",1,"btn","btn-secondary","btn-fill","btn-lg","me-3"],[1,"container-fluid","mt-3"],[1,"row"],[1,"col-sm-12"],[1,"card"],[1,"card-header"],[1,"card-body"],[1,"row","mt-7"],[1,"col-sm-6"],[1,"info-label-group"],[1,"row","mt-2"],[1,"form-group"],[1,"float-right"],["role","button",1,"btn","btn-success","btn-fill","btn-lg","me-3"],["role","button",1,"btn","btn-success","btn-fill","btn-lg","me-3",3,"click"]],template:function(d,e){d&1&&(t(0,"mainpanel",0)(1,"actions")(2,"a",1),n(3,"Back"),i()(),t(4,"content")(5,"div",2)(6,"div",3)(7,"div",4)(8,"div",5)(9,"div",6)(10,"h5"),n(11,"General"),i()(),t(12,"div",7)(13,"div",8)(14,"div",9)(15,"div",10)(16,"label"),n(17,"Date"),i(),t(18,"div")(19,"span"),n(20),S(21,"date"),i()()()(),t(22,"div",9)(23,"div",10)(24,"label"),n(25,"Number"),i(),t(26,"div")(27,"span"),n(28),i()()()(),t(29,"div",9)(30,"div",10)(31,"label"),n(32,"Type"),i(),t(33,"div")(34,"span"),n(35),i()()()(),t(36,"div",9)(37,"div",10)(38,"label"),n(39,"Response Code"),i(),t(40,"div")(41,"span"),n(42),i()()()(),t(43,"div",9)(44,"div",10)(45,"label"),n(46,"ShopID"),i(),t(47,"div")(48,"span"),n(49),i()()()(),_(50,Pt,7,1,"div",9),t(51,"div",9)(52,"div",10)(53,"label"),n(54,"Action"),i(),t(55,"div")(56,"span"),n(57),i()()()()()()()()(),t(58,"div",11)(59,"div",9)(60,"div",5)(61,"div",6)(62,"h5"),n(63,"Request"),i()(),t(64,"div",7)(65,"div",4)(66,"div",12)(67,"pre"),n(68),S(69,"json"),i()()(),t(70,"actions",13),_(71,Lt,2,0,"a",14),i()()()(),t(72,"div",9)(73,"div",5)(74,"div",6)(75,"h5"),n(76,"Response"),i()(),t(77,"div",7)(78,"div",4)(79,"div",12)(80,"pre"),n(81),S(82,"json"),i()()()()()()()()()()),d&2&&(u("headerTitle","Order #"+e.Number)("pageData","Orders Detail ")("hideSearchBox",!0)("hideSearchDropdown",!0),r(20),p(E(21,14,e.Created,"dd MMM yyyy HH:mm:ss")),r(8),p(e.Number),r(7),p(e.MarketTypeString),r(7),p(e.ResponseCode),r(7),p(e.shopId),r(),y(e.ProcessedCode!=null?50:-1),r(7),p(e.POSActionTypeString),r(11),p(O(69,17,e.request)),r(3),y(e.ResponseCode!="200"&&e.ResponseCode!="201"?71:-1),r(10),p(O(82,19,e.response)))},dependencies:[N,T,q,w],encapsulation:2});let o=a;return o})();var Rt=[{path:"",component:We,children:[{path:"",redirectTo:"exception",pathMatch:"full"},{path:"order",component:ke,canActivate:[W],data:{title:"Order Log"}},{path:"inventory/sync-inventory",component:Be,canActivate:[W],data:{title:"Product Inventory Sync"}},{path:"rawlog",component:Ae,canActivate:[W],data:{title:"Raw Log"}},{path:"rawlog/detail",component:Fe,canActivate:[W],data:{title:"Raw Log Detail"}},{path:"inventory/sync-inventory/detail",component:qe,canActivate:[W],data:{title:"Product Inventory Sync Detail"}},{path:"order/detail",component:Ve,canActivate:[W],data:{title:"Order Details"}},{path:"order/detail-user",component:He,canActivate:[W],data:{title:"Order User Details"}},{path:"exception",component:je,canActivate:[W],data:{title:"Exception Log"}},{path:"exception/detail",component:ze,canActivate:[W],data:{title:"Exception Log Detail"}},{path:"inventory",loadComponent:()=>import("./chunk-Q4TAOZ73.js").then(o=>o.InventoryAsyncLogComponent),canActivate:[W],data:{title:"Product Inventory Sync"}},{path:"inventory/detail",loadComponent:()=>import("./chunk-CT6UFONR.js").then(o=>o.InventoryAsyncDetailComponent),canActivate:[W],data:{title:"Product Inventory Sync Detail"}},{path:"authorization-log",loadComponent(){return import("./chunk-TLPRODFI.js").then(o=>o.ChannelLogComponent)},canActivate:[W],data:{title:"Authorization Log"}}]}],Ue=(()=>{let a=class a{};a.\u0275fac=function(d){return new(d||a)},a.\u0275mod=pe({type:a}),a.\u0275inj=se({imports:[ue,ge.forChild(Rt)]});let o=a;return o})();var Fn=(()=>{let a=class a{};a.\u0275fac=function(d){return new(d||a)},a.\u0275mod=pe({type:a}),a.\u0275inj=se({imports:[ue,we,Ie,Ue,ge,Le,Oe,Re,Te,Pe,j,Ne]});let o=a;return o})();export{Fn as LogsModule};
1
+ import{a as j}from"./chunk-S7CKRTJV.js";import{b as Oe}from"./chunk-ZME22WYI.js";import{a as ie}from"./chunk-7JQEF4XX.js";import"./chunk-AFIF6VRM.js";import"./chunk-ZW2TMVZP.js";import{a as ne,b as Re}from"./chunk-FKGKMEDE.js";import"./chunk-ZKIO2ZQ6.js";import{a as W}from"./chunk-UCEZJNIL.js";import"./chunk-ZTHO6JJM.js";import"./chunk-SHUYFOQI.js";import"./chunk-FCEXPGTK.js";import"./chunk-QFSA7CU4.js";import"./chunk-OPXITNRF.js";import"./chunk-FULVA6QB.js";import"./chunk-HPINZVE4.js";import"./chunk-D2J64VUP.js";import"./chunk-6Q6L5NUD.js";import"./chunk-C7N6EI73.js";import"./chunk-GPHNPV7O.js";import"./chunk-3RK6DDJD.js";import"./chunk-4YCSITNV.js";import"./chunk-WHHW4IZT.js";import{a as Me,b as Pe}from"./chunk-A7PUMY67.js";import"./chunk-N5AE5WMQ.js";import{a as $,b as ee,d as te,e as Te}from"./chunk-6KWG6O5L.js";import"./chunk-A6QXXKPR.js";import{i as V}from"./chunk-I723PUUO.js";import"./chunk-QXRG5XYP.js";import"./chunk-RXLMJGUY.js";import"./chunk-AGBJEXIM.js";import{e as I}from"./chunk-OXWPYJNB.js";import"./chunk-XBIHN6D3.js";import{c as A}from"./chunk-JBEKD57G.js";import{m as T,n as Le}from"./chunk-EDEZ3JLR.js";import{A as we,B as Ie,c as Q,h as X,m as Y,o as Z,u as xe,v as Ee}from"./chunk-L3W6SG2T.js";import"./chunk-YTHY4IFS.js";import"./chunk-ZETUYNFJ.js";import{v as De,w as Ne}from"./chunk-STYL7ETF.js";import"./chunk-XLIPGDSC.js";import{D as B,E as be,G as N,I as ge,c as ce,i as Se,j as w,k as q,m as ue}from"./chunk-LNJUGHOX.js";import{$b as _,$c as F,Gb as b,Hb as pe,Lc as ye,Mb as z,Mc as n,Nc as p,Oc as M,Qc as h,Rc as f,Sc as v,_c as K,bc as y,dc as H,ec as U,fc as J,gc as u,hc as t,hd as S,ic as i,id as O,jc as D,jd as E,lb as G,ma as me,na as se,nb as r,qc as R,ra as g,v as de,vc as x,xa as P,xc as C,ya as L}from"./chunk-ZYJ6LAJ3.js";import"./chunk-WFMAM73Y.js";import"./chunk-66YHNWRR.js";var We=(()=>{let a=class a{constructor(){this.ObjectlogTabs=[{Title:"Channel Push Log Exception",Url:"/menu/log/exception"},{Title:"Channel Push Log",Url:"/menu/log/rawlog"},{Title:"POS Sync Order Log",Url:"/menu/log/order"},{Title:"Inventory Sync ",Url:"/menu/log/inventory"},{Title:"Authorization Log ",Url:"/menu/log/authorization-log"}]}};a.\u0275fac=function(d){return new(d||a)},a.\u0275cmp=b({type:a,selectors:[["app-logs"]],standalone:!1,decls:5,vars:1,consts:[[1,"navbar","page-nav","navbar-default","py-0","navbar-expand-lg"],[1,"container-fluid"],[3,"Tabs"]],template:function(d,e){d&1&&(t(0,"nav",0)(1,"div",1)(2,"div"),D(3,"nav-tab",2),i()()(),D(4,"router-outlet")),d&2&&(r(3),u("Tabs",e.ObjectlogTabs))},dependencies:[be,Me],encapsulation:2});let o=a;return o})();var ae=(()=>{let a=class a{constructor(){}get Data(){return this._Data}set Data(s){this._Data=s}Fill(s){return this._Data.find(d=>d._id==s)}};a.\u0275fac=function(d){return new(d||a)},a.\u0275prov=me({token:a,factory:a.\u0275fac,providedIn:"root"});let o=a;return o})();var Je=()=>["/menu/log/order/detail-user"],Ke=o=>({ID:o}),Qe=o=>({"bg-warning":o});function Xe(o,a){if(o&1&&(t(0,"span",22),D(1,"img",23),i(),n(2)),o&2){let l=a.item;r(),u("src",l.Img,G)("alt",l.Name),r(),M(" ",l.Name," ")}}function Ye(o,a){o&1&&(t(0,"th",26)(1,"span",29),n(2," Response Body Warning "),i()())}function Ze(o,a){o&1&&(t(0,"th")(1,"span",29),n(2," Number Override "),i()())}function $e(o,a){if(o&1&&(t(0,"td",26)(1,"span",32),n(2),i()()),o&2){let l=C().$implicit;r(),u("ngClass",F(2,Qe,l.responseBodyWarning!=null)),r(),p(l.responseBodyWarning)}}function et(o,a){if(o&1&&(t(0,"td"),n(1),i()),o&2){let l=C().$implicit;r(),M(" ",l.ResponseBodyWarningReference," ")}}function tt(o,a){if(o&1&&(t(0,"tr")(1,"td")(2,"a",30),n(3),S(4,"date"),i()(),t(5,"td"),n(6),i(),t(7,"td"),n(8),i(),t(9,"td"),n(10),i(),t(11,"td",26)(12,"span",31),n(13),i()(),_(14,$e,3,4,"td",26),_(15,et,2,1,"td"),i()),o&2){let l=a.$implicit,s=C(2);r(2),u("routerLink",K(14,Je))("queryParams",F(15,Ke,l.ID)),r(),M(" ",E(4,11,l.Created,"dd MMM yyyy HH:mm:ss")," "),r(3),p(l.ChannelName),r(2),p(l.POSActionTypeString),r(2),p(l.Number),r(2),ye(l.ResponseCode===200||l.ResponseCode===202?"bg-success":"bg-warning"),r(),M(" ",l.ResponseCode," "),r(),y(s.responseBodyWarningVisible?14:-1),r(),y(s.responseBodyWarningVisible?15:-1)}}function it(o,a){if(o&1){let l=R();t(0,"div",20)(1,"table",24)(2,"thead")(3,"tr",25)(4,"th"),n(5,"Date"),i(),t(6,"th"),n(7,"Channel"),i(),t(8,"th"),n(9,"Actions"),i(),t(10,"th"),n(11,"Number"),i(),t(12,"th",26)(13,"span",27),n(14," Response Code "),i()(),_(15,Ye,3,0,"th",26),_(16,Ze,3,0,"th"),i()(),t(17,"tbody"),U(18,tt,16,17,"tr",null,H),i()(),t(20,"mat-paginator",28),x("page",function(d){P(l);let e=C();return L(e.changePage(d))}),i()()}if(o&2){let l=C();r(15),y(l.responseBodyWarningVisible?15:-1),r(),y(l.responseBodyWarningVisible?16:-1),r(2),J(l.Result),r(2),u("length",l.paginationTotal)("pageSize",l.paginationPageSize)("pageIndex",(l.filter==null?null:l.filter.PageNumber)==0?0:(l.filter==null?null:l.filter.PageNumber)-1)}}function nt(o,a){o&1&&(t(0,"div",21),D(1,"app-empty-state"),i())}var ke=(()=>{let a=class a{constructor(){this.http=g(I),this._RawLogService=g(ae),this.route=g(B),this.authService=g(V),this.Result=Array(),this.filter={RowCount:20,Number:"",PageNumber:1,ActionType:"",ChannelID:"",StatusCode:"",From:"",To:"",responseBodyWarning:""},this.responseBodyWarningVisible=!1,this.channelOptions=this.authService.getChannels()}ngOnInit(){this.route.queryParams.subscribe(s=>{this.responseCode=s.responseCode,this.responseCode!=null?this.Load(s):this.Load()})}Load(s={}){this.http.post("/api/OrdersLoader/Get",s).subscribe(d=>{this.filter=d.Filter,this.ActionTypeList=d.Options.ActionTypeList,this.Get()})}Get(s){this.filter.Number=s,this.http.post("/api/Orders/Get",this.filter).subscribe(d=>{this._RawLogService.Data=d.hits,this.Result=Array();for(let e of d.hits){e._source.log.responseBodyWarning!=null&&(this.responseBodyWarningVisible=!0);let c={ID:e._id,Created:e._source["@timestamp_received"],shopId:e._source.shopId,MarketTypeString:e._source.log.type,ChannelName:e._source?.channelId!=null?this.channelOptions.find(m=>m.ID===e._source?.channelId)?.Name:"",POSActionTypeString:e._source.message,Number:e._source.log.number,ResponseCode:e._source.log.responseCode,responseBodyWarning:e._source.log.responseBodyWarning,ResponseBodyWarningReference:e._source.log.ResponseBodyWarningReference};this.Result.push(c)}this.paginationTotal=d.total.value,this.paginationPageSize=this.filter.RowCount>this.paginationTotal?this.paginationTotal:this.filter.RowCount})}changePage(s){this.filter.PageNumber=s.pageIndex+1,this.Get()}};a.\u0275fac=function(d){return new(d||a)},a.\u0275cmp=b({type:a,selectors:[["app-order"]],standalone:!1,decls:42,vars:14,consts:[["headerTitle","Order Log","searchBoxPlaceHolder","Invoice Number..",3,"textChange","onSubmit","text"],[1,"fw-bold","mb-2"],["appendTo","body","bindLabel","Name","name","channelid","bindValue","ID","placeholder","Select Channel",1,"center-text",3,"ngModelChange","clearable","items","ngModel"],["ng-option-tmp","","ng-label-tmp",""],[1,"mt-5"],["bindLabel","Value","name","ActionType","bindValue","Key","placeholder","Action Type",1,"center-text",3,"ngModelChange","clearable","items","ngModel"],[1,"fw-bold","mb-1"],[1,"mb-4"],["name","From",3,"dateChange","date"],["name","To",3,"dateChange","date"],[1,"fw-bold"],["type","text","name","StatusCode",1,"w-100","mt-2","form-control",3,"ngModelChange","ngModel"],["type","text","name","responseBodyWarning","list","listresponseBodyWarning",1,"w-100","mt-2","form-control",3,"ngModelChange","ngModel"],["id","listresponseBodyWarning"],["value","number-override"],["type","number","name","PageNumber",1,"w-100","mt-2","form-control",3,"ngModelChange","ngModel"],["type","number","name","RowCount",1,"w-100","mt-2","form-control",3,"ngModelChange","ngModel"],[1,"container-fluid","mt-3"],[1,"row"],[1,"col-md-12"],[1,"table-responsive"],[1,"d-flex","flex-column","justify-content-center","align-items-center",2,"margin-top","26vh"],[1,"me-2"],[2,"width","18px",3,"src","alt"],[1,"table","table-hover"],[1,"table-light"],[1,"text-center"],["matTooltip","Http Status Code from developer.dealpos.com."],[3,"page","length","pageSize","pageIndex"],["matTooltip","ex: when payload.Number != response.Number value will be number-override"],[3,"routerLink","queryParams"],[1,"text-white","p-2","rounded","response-desc"],[1,"text-white","p-2","rounded","response-desc",3,"ngClass"]],template:function(d,e){d&1&&(t(0,"mainpanel",0),v("textChange",function(m){return f(e.Number,m)||(e.Number=m),m}),x("onSubmit",function(m){return e.Get(m)}),t(1,"filters")(2,"div")(3,"label",1),n(4,"Channel"),i(),t(5,"ng-select",2),v("ngModelChange",function(m){return f(e.filter.ChannelID,m)||(e.filter.ChannelID=m),m}),z(6,Xe,3,3,"ng-template",3),i()(),t(7,"div",4)(8,"label",1),n(9,"Action"),i(),t(10,"ng-select",5),v("ngModelChange",function(m){return f(e.filter.ActionType,m)||(e.filter.ActionType=m),m}),i()(),t(11,"div",4)(12,"label",6),n(13,"From/To"),i(),t(14,"div",7)(15,"datepicker",8),v("dateChange",function(m){return f(e.filter.From,m)||(e.filter.From=m),m}),i()(),t(16,"div")(17,"datepicker",9),v("dateChange",function(m){return f(e.filter.To,m)||(e.filter.To=m),m}),i()()(),t(18,"div",4)(19,"label",10),n(20,"Response Code"),i(),t(21,"input",11),v("ngModelChange",function(m){return f(e.filter.StatusCode,m)||(e.filter.StatusCode=m),m}),i()(),t(22,"div",4)(23,"label",10),n(24,"Response Body Warning"),i(),t(25,"input",12),v("ngModelChange",function(m){return f(e.filter.responseBodyWarning,m)||(e.filter.responseBodyWarning=m),m}),i(),t(26,"datalist",13),D(27,"option",14),i()(),t(28,"div",4)(29,"label",10),n(30,"Page Number"),i(),t(31,"input",15),v("ngModelChange",function(m){return f(e.filter.PageNumber,m)||(e.filter.PageNumber=m),m}),i()(),t(32,"div",4)(33,"label",10),n(34,"Page Size"),i(),t(35,"input",16),v("ngModelChange",function(m){return f(e.filter.RowCount,m)||(e.filter.RowCount=m),m}),i()()(),t(36,"content")(37,"div",17)(38,"div",18)(39,"div",19),_(40,it,21,5,"div",20)(41,nt,2,0,"div",21),i()()()()()),d&2&&(h("text",e.Number),r(5),u("clearable",!0)("items",e.channelOptions),h("ngModel",e.filter.ChannelID),r(5),u("clearable",!0)("items",e.ActionTypeList),h("ngModel",e.filter.ActionType),r(5),h("date",e.filter.From),r(2),h("date",e.filter.To),r(4),h("ngModel",e.filter.StatusCode),r(4),h("ngModel",e.filter.responseBodyWarning),r(6),h("ngModel",e.filter.PageNumber),r(4),h("ngModel",e.filter.RowCount),r(5),y((e.Result==null?null:e.Result.length)>0?40:41))},dependencies:[ce,xe,Ee,Q,Z,X,Y,N,T,ne,te,$,ee,j,ie,De,w],encapsulation:2});let o=a;return o})();var ot=o=>({"bg-gradient-warning":o}),at=()=>["/menu/log/inventory/sync-inventory/detail"],rt=o=>({ID:o});function lt(o,a){if(o&1&&(t(0,"span",19),D(1,"img",20),i(),n(2)),o&2){let l=a.item;r(),u("src",l.Img,G)("alt",l.Name),r(),M(" ",l.Name," ")}}function dt(o,a){if(o&1&&(t(0,"tr",23)(1,"td")(2,"a",25),n(3),S(4,"date"),i()(),t(5,"td"),n(6),i(),t(7,"td"),n(8),i(),t(9,"td"),n(10),i(),t(11,"td"),n(12),i()()),o&2){let l=a.$implicit;u("ngClass",F(11,ot,l.ResponseCode==400)),r(2),u("routerLink",K(13,at))("queryParams",F(14,rt,l.ID)),r(),M(" ",E(4,8,l.Created,"dd MMM yyyy HH:mm")," "),r(3),p(l.channelName),r(2),p(l.Sku),r(2),p(l.Stock),r(2),p(l.ResponseCode)}}function mt(o,a){if(o&1){let l=R();t(0,"div",17)(1,"table",21)(2,"thead")(3,"tr",22)(4,"th"),n(5,"Created"),i(),t(6,"th"),n(7,"Channel"),i(),t(8,"th"),n(9,"SKU"),i(),t(10,"th"),n(11,"Stock"),i(),t(12,"th"),n(13,"Response code"),i()()(),t(14,"tbody"),U(15,dt,13,16,"tr",23,H),i()(),t(17,"mat-paginator",24),x("page",function(d){P(l);let e=C();return L(e.changePage(d))}),i()()}if(o&2){let l=C();r(15),J(l.Result),r(2),u("length",l.paginationTotal)("pageSize",l.paginationPageSize)("pageIndex",(l.filter==null?null:l.filter.PageNumber)==0?0:(l.filter==null?null:l.filter.PageNumber)-1)}}function st(o,a){o&1&&(t(0,"div",18),D(1,"app-empty-state"),i())}var Be=(()=>{let a=class a{constructor(){this.http=g(I),this._RawLogService=g(ae),this.authService=g(V),this.Result=Array(),this.filter={PageNumber:0,RowCount:20,Sku:null,ChannelID:"",StatusCode:"",From:"",To:""},this.Load(),this.channelOptions=this.authService.getChannels()}Load(){this.http.post("/api/OrdersLoader/Get",{}).subscribe(s=>{this.filter=s.Filter,this.ActionTypeList=s.Options.ActionTypeList,this.Get()})}Get(s){s!=null&&(this.filter.Sku=s),this.http.post("api/Inventory/GetLog",this.filter).subscribe(d=>{this._RawLogService.Data=d.hits,this.Result=Array();for(let e of d.hits){let c={ID:e._source.log.id,Created:e._source["@timestamp_received"],channelName:e._source.log.channelName,Sku:e._source.log.sku,Stock:e._source.log.stock,ResponseCode:e._source.log.responseCode};this.Result.push(c)}this.paginationTotal=d.total.value,this.paginationPageSize=this.filter.RowCount>this.paginationTotal?this.paginationTotal:this.filter.RowCount})}changePage(s){this.filter.PageNumber=s.pageIndex+1,this.Get()}};a.\u0275fac=function(d){return new(d||a)},a.\u0275cmp=b({type:a,selectors:[["app-inventory-log"]],standalone:!1,decls:32,vars:9,consts:[["headerTitle","Channel Inventory Sync","searchBoxPlaceHolder","Enter SKU...",3,"textChange","onSubmit","text"],["role","button","routerLink","/menu/log/inventory",1,"btn","btn-success"],["container",""],[1,"fw-bold","mb-2"],["appendTo","body","bindLabel","Name","name","channelid","bindValue","ID","placeholder","Select Channel",1,"center-text",3,"ngModelChange","clearable","items","ngModel"],["ng-option-tmp","","ng-label-tmp",""],[1,"mt-5"],[1,"fw-bold","mb-1"],[1,"mb-4"],["name","From",3,"dateChange","date"],["name","To",3,"dateChange","date"],[1,"fw-bold"],["type","number","name","PageNumber",1,"w-100","mt-2","form-control",3,"ngModelChange","ngModel"],["type","number","name","RowCount",1,"w-100","mt-2","form-control",3,"ngModelChange","ngModel"],[1,"container-fluid","mt-3"],[1,"row"],[1,"col-md-12"],[1,"table-responsive"],[1,"d-flex","flex-column","justify-content-center","align-items-center",2,"margin-top","26vh"],[1,"me-2"],[2,"width","18px",3,"src","alt"],[1,"table","table-hover"],[1,"table-light"],[3,"ngClass"],[3,"page","length","pageSize","pageIndex"],[3,"routerLink","queryParams"]],template:function(d,e){d&1&&(t(0,"mainpanel",0),v("textChange",function(m){return f(e.filter.Sku,m)||(e.filter.Sku=m),m}),x("onSubmit",function(m){return e.Get(m)}),t(1,"actions")(2,"a",1),n(3," Order Inventory Sync Job "),i()(),t(4,"filters")(5,"div",2)(6,"div")(7,"label",3),n(8,"Channel"),i(),t(9,"ng-select",4),v("ngModelChange",function(m){return f(e.filter.ChannelID,m)||(e.filter.ChannelID=m),m}),z(10,lt,3,3,"ng-template",5),i()(),t(11,"div",6)(12,"label",7),n(13,"From/To"),i(),t(14,"div",8)(15,"datepicker",9),v("dateChange",function(m){return f(e.filter.From,m)||(e.filter.From=m),m}),i()(),t(16,"div")(17,"datepicker",10),v("dateChange",function(m){return f(e.filter.To,m)||(e.filter.To=m),m}),i()()(),t(18,"div",6)(19,"label",11),n(20,"Page Number"),i(),t(21,"input",12),v("ngModelChange",function(m){return f(e.filter.PageNumber,m)||(e.filter.PageNumber=m),m}),i()(),t(22,"div",6)(23,"label",11),n(24,"Page Size"),i(),t(25,"input",13),v("ngModelChange",function(m){return f(e.filter.RowCount,m)||(e.filter.RowCount=m),m}),i()()()(),t(26,"content")(27,"div",14)(28,"div",15)(29,"div",16),_(30,mt,18,3,"div",17)(31,st,2,0,"div",18),i()()()()()),d&2&&(h("text",e.filter.Sku),r(9),u("clearable",!0)("items",e.channelOptions),h("ngModel",e.filter.ChannelID),r(6),h("date",e.filter.From),r(2),h("date",e.filter.To),r(4),h("ngModel",e.filter.PageNumber),r(4),h("ngModel",e.filter.RowCount),r(5),y((e.Result==null?null:e.Result.length)>0?30:31))},dependencies:[ce,Q,Z,X,Y,N,T,ne,te,$,ee,j,ie,w],encapsulation:2});let o=a;return o})();var pt=()=>["/menu/log/rawlog/detail"],ct=o=>({ID:o});function ut(o,a){if(o&1&&(t(0,"span",17),D(1,"img",18),i(),n(2)),o&2){let l=a.item;r(),u("src",l.Img,G)("alt",l.Name),r(),M(" ",l.Name," ")}}function gt(o,a){if(o&1&&(t(0,"tr")(1,"td")(2,"a",23),n(3),S(4,"date"),i()(),t(5,"td"),n(6),i(),t(7,"td"),n(8),i(),t(9,"td"),n(10),i()()),o&2){let l=a.$implicit;r(2),u("routerLink",K(9,pt))("queryParams",F(10,ct,l.id)),r(),M(" ",E(4,6,l.Created,"dd MMM yyyy HH:mm:ss")," "),r(3),p(l.type),r(2),p(l.number),r(2),p(l.message)}}function ht(o,a){if(o&1){let l=R();t(0,"div",15)(1,"table",19)(2,"thead",20)(3,"tr")(4,"th",21),n(5,"Date"),i(),t(6,"th"),n(7,"Type"),i(),t(8,"th"),n(9,"Number"),i(),t(10,"th"),n(11,"Message"),i()()(),t(12,"tbody"),U(13,gt,11,12,"tr",null,H),i()(),t(15,"mat-paginator",22),x("page",function(d){P(l);let e=C();return L(e.changePage(d))}),i()()}if(o&2){let l=C();r(13),J(l.Result),r(2),u("length",l.paginationTotal)("pageSize",l.paginationPageSize)("pageIndex",(l.filter==null?null:l.filter.PageNumber)==0?0:(l.filter==null?null:l.filter.PageNumber)-1)}}function ft(o,a){o&1&&(t(0,"div",16),D(1,"app-empty-state"),i())}var Ae=(()=>{let a=class a{constructor(){this.http=g(I),this._RawLogService=g(ae),this.authService=g(V),this.Result=Array(),this.filter={RowCount:20,Number:"",PageNumber:1,ActionType:"",ChannelID:"",StatusCode:"",From:"",To:""},this.list=[],this.Types=[{Key:0,Value:"Shopee"},{Key:1,Value:"Tokopedia"}],this.channelOptions=this.authService.getChannels()}ngOnInit(){this.Load()}Load(s={}){this.http.post("/api/OrdersLoader/Get",s).subscribe(d=>{this.filter=d.Filter,this.ActionTypeList=d.Options.ActionTypeList,this.Get()})}Get(s){this.filter.Number=s,this.http.post("api/Orders/GetRawLog",this.filter).subscribe(d=>{this._RawLogService.Data=d.hits,this.Result=Array();for(let e of d.hits){let c={id:e._id,message:e._source.message,responseCode:e._source.log.responseCode,processTypeString:e._source.log.processType,type:e._source.log.type,number:e._source.log.number,Created:e._source["@timestamp_received"]};this.Result.push(c)}this.paginationTotal=d.total.value,this.paginationPageSize=this.filter.RowCount>this.paginationTotal?this.paginationTotal:this.filter.RowCount})}changePage(s){this.filter.PageNumber=s.pageIndex+1,this.Get()}};a.\u0275fac=function(d){return new(d||a)},a.\u0275cmp=b({type:a,selectors:[["app-raw-log"]],standalone:!1,decls:28,vars:9,consts:[["headerTitle","Channel Push Log","searchBoxPlaceHolder","Invoice Number..",3,"textChange","onSubmit","text"],[1,"fw-bold","mb-2"],["appendTo","body","bindLabel","Name","name","channelid","bindValue","ID","placeholder","Select Channel",1,"center-text",3,"ngModelChange","clearable","items","ngModel"],["ng-option-tmp","","ng-label-tmp",""],[1,"mt-5"],[1,"fw-bold","mb-1"],[1,"mb-4"],["name","From",3,"dateChange","date"],["name","To",3,"dateChange","date"],[1,"fw-bold"],["type","number","name","PageNumber",1,"w-100","mt-2","form-control",3,"ngModelChange","ngModel"],["type","number","name","RowCount",1,"w-100","mt-2","form-control",3,"ngModelChange","ngModel"],[1,"container-fluid","mt-3"],[1,"row"],[1,"col-md-12"],[1,"table-responsive"],[1,"d-flex","flex-column","justify-content-center","align-items-center",2,"margin-top","26vh"],[1,"me-2"],[2,"width","18px",3,"src","alt"],[1,"table"],[1,"thead-light"],[2,"width","200px"],[3,"page","length","pageSize","pageIndex"],[3,"routerLink","queryParams"]],template:function(d,e){d&1&&(t(0,"mainpanel",0),v("textChange",function(m){return f(e.filter.Number,m)||(e.filter.Number=m),m}),x("onSubmit",function(m){return e.Get(m)}),t(1,"filters")(2,"div")(3,"label",1),n(4,"Channel"),i(),t(5,"ng-select",2),v("ngModelChange",function(m){return f(e.filter.ChannelID,m)||(e.filter.ChannelID=m),m}),z(6,ut,3,3,"ng-template",3),i()(),t(7,"div",4)(8,"label",5),n(9,"From/To"),i(),t(10,"div",6)(11,"datepicker",7),v("dateChange",function(m){return f(e.filter.From,m)||(e.filter.From=m),m}),i()(),t(12,"div")(13,"datepicker",8),v("dateChange",function(m){return f(e.filter.To,m)||(e.filter.To=m),m}),i()()(),t(14,"div",4)(15,"label",9),n(16,"Page Number"),i(),t(17,"input",10),v("ngModelChange",function(m){return f(e.filter.PageNumber,m)||(e.filter.PageNumber=m),m}),i()(),t(18,"div",4)(19,"label",9),n(20,"Page Size"),i(),t(21,"input",11),v("ngModelChange",function(m){return f(e.filter.RowCount,m)||(e.filter.RowCount=m),m}),i()()(),t(22,"content")(23,"div",12)(24,"div",13)(25,"div",14),_(26,ht,16,3,"div",15)(27,ft,2,0,"div",16),i()()()()()),d&2&&(h("text",e.filter.Number),r(5),u("clearable",!0)("items",e.channelOptions),h("ngModel",e.filter.ChannelID),r(6),h("date",e.filter.From),r(2),h("date",e.filter.To),r(4),h("ngModel",e.filter.PageNumber),r(4),h("ngModel",e.filter.RowCount),r(5),y((e.Result==null?null:e.Result.length)>0?26:27))},dependencies:[Q,Z,X,Y,N,T,ne,te,$,ee,j,ie,w],encapsulation:2});let o=a;return o})();function vt(o,a){if(o&1&&(t(0,"div",9)(1,"div",10)(2,"label"),n(3,"Process Code"),i(),t(4,"div")(5,"span"),n(6),i()()()()),o&2){let l=C();r(6),p(l.ProcessedCode)}}function Ct(o,a){if(o&1){let l=R();t(0,"a",15),x("click",function(){P(l);let d=C();return L(d.Retry())}),n(1,"Retry"),i()}}var Fe=(()=>{let a=class a{constructor(){this.route=g(B),this.http=g(I),this.ProcessDuration=0,this.request="",this.response="",this.route.queryParams.subscribe(s=>{this.ID=s.ID,this.Load()})}Retry(){var s={Number:this.Number,ShopID:this.shopId};this.http.post("/api/Orders/Retry",s).subscribe(d=>{alert(JSON.stringify(d))})}Load(){var s={ID:this.ID};this.http.post("/api/Orders/GetDetailChannelWebhook",s).subscribe(d=>{for(let e of d.hits)this.Number=e._source.log.number,this.MarketTypeString=e._source.log.type,this.ResponseCode=e._source.log.responseCode,this.POSActionTypeString=e._source.message,this.ProcessDuration=0,this.Created=e._source["@timestamp_received"],this.request=A.IsNotEmpty(e._source?.log?.request)?JSON.parse(e._source.log?.request):"",this.response=A.IsNotEmpty(e._source?.log?.response)?JSON.parse(e._source.log?.response):"",this.shopId=e._source.shopId,this.ProcessedCode=e._source.log.processedCode})}};a.\u0275fac=function(d){return new(d||a)},a.\u0275cmp=b({type:a,selectors:[["app-raw-detail"]],standalone:!1,decls:83,vars:21,consts:[[3,"headerTitle","pageData","hideSearchBox","hideSearchDropdown"],["role","button","routerLink","/menu/log/order",1,"btn","btn-secondary","btn-fill","btn-lg","me-3"],[1,"container-fluid","mt-3"],[1,"row"],[1,"col-sm-12"],[1,"card"],[1,"card-header"],[1,"card-body"],[1,"row","mt-7"],[1,"col-sm-6"],[1,"info-label-group"],[1,"row","mt-2"],[1,"form-group"],[1,"float-right"],["role","button",1,"btn","btn-success","btn-fill","btn-lg","me-3"],["role","button",1,"btn","btn-success","btn-fill","btn-lg","me-3",3,"click"]],template:function(d,e){d&1&&(t(0,"mainpanel",0)(1,"actions")(2,"a",1),n(3,"Back"),i()(),t(4,"content")(5,"div",2)(6,"div",3)(7,"div",4)(8,"div",5)(9,"div",6)(10,"h5"),n(11,"General"),i()(),t(12,"div",7)(13,"div",8)(14,"div",9)(15,"div",10)(16,"label"),n(17,"Date"),i(),t(18,"div")(19,"span"),n(20),S(21,"date"),i()()()(),t(22,"div",9)(23,"div",10)(24,"label"),n(25,"Number"),i(),t(26,"div")(27,"span"),n(28),i()()()(),t(29,"div",9)(30,"div",10)(31,"label"),n(32,"Type"),i(),t(33,"div")(34,"span"),n(35),i()()()(),t(36,"div",9)(37,"div",10)(38,"label"),n(39,"Response Code"),i(),t(40,"div")(41,"span"),n(42),i()()()(),t(43,"div",9)(44,"div",10)(45,"label"),n(46,"ShopID"),i(),t(47,"div")(48,"span"),n(49),i()()()(),_(50,vt,7,1,"div",9),t(51,"div",9)(52,"div",10)(53,"label"),n(54,"Action"),i(),t(55,"div")(56,"span"),n(57),i()()()()()()()()(),t(58,"div",11)(59,"div",9)(60,"div",5)(61,"div",6)(62,"h5"),n(63,"Request"),i()(),t(64,"div",7)(65,"div",4)(66,"div",12)(67,"pre"),n(68),S(69,"json"),i()()(),t(70,"actions",13),_(71,Ct,2,0,"a",14),i()()()(),t(72,"div",9)(73,"div",5)(74,"div",6)(75,"h5"),n(76,"Response"),i()(),t(77,"div",7)(78,"div",4)(79,"div",12)(80,"pre"),n(81),S(82,"json"),i()()()()()()()()()()),d&2&&(u("headerTitle","Order #"+e.Number)("pageData","Orders Detail ")("hideSearchBox",!0)("hideSearchDropdown",!0),r(20),p(E(21,14,e.Created,"dd MMM yyyy HH:mm:ss")),r(8),p(e.Number),r(7),p(e.MarketTypeString),r(7),p(e.ResponseCode),r(7),p(e.shopId),r(),y(e.ProcessedCode!=null?50:-1),r(7),p(e.POSActionTypeString),r(11),p(O(69,17,e.request)),r(3),y(e.ResponseCode!="200"&&e.ResponseCode!="201"?71:-1),r(10),p(O(82,19,e.response)))},dependencies:[N,T,q,w],encapsulation:2});let o=a;return o})();function _t(o,a){if(o&1&&(t(0,"div",4)(1,"div",7)(2,"div",8)(3,"h5"),n(4,"General"),i()(),t(5,"div",9)(6,"div",3)(7,"div",6)(8,"div",11)(9,"label"),n(10,"Date"),i(),t(11,"div")(12,"span"),n(13),S(14,"date"),i()()()(),t(15,"div",6)(16,"div",11)(17,"label"),n(18,"SKU"),i(),t(19,"div")(20,"span"),n(21),i()()()(),t(22,"div",6)(23,"div",11)(24,"label"),n(25,"Channel"),i(),t(26,"div")(27,"span"),n(28),i()()()(),t(29,"div",6)(30,"div",11)(31,"label"),n(32,"Response Code"),i(),t(33,"div")(34,"span"),n(35),i()()()()()()()()),o&2){let l=C();r(13),p(E(14,4,l.data.Created,"dd MMM yyyy")),r(8),p(l.data.Sku),r(7),p(l.data.ChannelName),r(7),p(l.data.ResponseCode)}}var qe=(()=>{let a=class a{constructor(){this.route=g(B),this.http=g(I),this._RawLogService=g(ae),this.data={Created:"",Sku:"",ChannelName:"",ResponseCode:""},this.route.queryParams.subscribe(s=>{this.ID=s.ID,this.Load()})}ngOnInit(){}Load(){var s={ID:this.ID};this.http.post("/api/Inventory/GetInventoryLogDeatil",s).subscribe(d=>{this.data.Created=d.hits[0]._source["@timestamp_received"],this.data.Sku=d.hits[0]._source.log.sku,this.data.ChannelName=d.hits[0]._source.log.channelName,this.data.ResponseCode=d.hits[0]._source.log.responseCode,this.request=A.IsNotEmpty(d.hits[0]?._source.log?.request)?JSON.parse(d.hits[0]?._source?.log?.request):"",this.response=d.hits[0]._source.log.response})}};a.\u0275fac=function(d){return new(d||a)},a.\u0275cmp=b({type:a,selectors:[["app-inventory-detail"]],standalone:!1,decls:30,vars:7,consts:[["headerTitle","Product Inventory Sync Detail",3,"hideSearchBox","hideSearchDropdown"],["role","button","routerLink","/menu/log/inventory/sync-inventory",1,"btn","btn-secondary","btn-fill","btn-lg","me-2"],[1,"container-fluid","mt-3"],[1,"row"],[1,"col-sm-12"],[1,"row","mt-2"],[1,"col-sm-6"],[1,"card"],[1,"card-header"],[1,"card-body"],[1,"form-group"],[1,"info-label-group"]],template:function(d,e){d&1&&(t(0,"mainpanel",0)(1,"actions")(2,"a",1),n(3,"Back"),i()(),t(4,"content")(5,"div",2)(6,"div",3),_(7,_t,36,7,"div",4),i(),t(8,"div",5)(9,"div",6)(10,"div",7)(11,"div",8)(12,"h5"),n(13,"Request"),i()(),t(14,"div",9)(15,"div",4)(16,"div",10)(17,"pre"),n(18),S(19,"json"),i()()()()()(),t(20,"div",6)(21,"div",7)(22,"div",8)(23,"h5"),n(24,"Response"),i()(),t(25,"div",9)(26,"div",4)(27,"div",10)(28,"pre"),n(29),i()()()()()()()()()()),d&2&&(u("hideSearchBox",!0)("hideSearchDropdown",!0),r(7),y(e.data?7:-1),r(11),p(O(19,5,e.request)),r(11),p(e.response))},dependencies:[N,T,q,w],encapsulation:2});let o=a;return o})();function yt(o,a){if(o&1&&(t(0,"div",9)(1,"div",10)(2,"label"),n(3,"Process Code"),i(),t(4,"div")(5,"span"),n(6),i()()()()),o&2){let l=C();r(6),p(l.ProcessedCode)}}function St(o,a){if(o&1){let l=R();t(0,"a",15),x("click",function(){P(l);let d=C();return L(d.Retry())}),n(1,"Retry"),i()}}var Ve=(()=>{let a=class a{constructor(){this.route=g(B),this.http=g(I),this.ProcessDuration=0,this.request="",this.response="",this.route.queryParams.subscribe(s=>{this.ID=s.ID,this.Load()})}Retry(){var s={Number:this.Number,ShopID:this.shopId};this.http.post("/api/Orders/Retry",s).subscribe(d=>{alert(JSON.stringify(d))})}Load(){var s={ID:this.ID};this.http.post("/api/Orders/GetDetailChannelWebhook",s).subscribe(d=>{for(let e of d.hits)this.Number=e._source.log.number,this.MarketTypeString=e._source.log.type,this.ResponseCode=e._source.log.responseCode,this.POSActionTypeString=e._source.message,this.ProcessDuration=0,this.Created=e._source["@timestamp_received"],this.request=A.IsNotEmpty(e._source?.log?.request)?JSON.parse(e._source.log?.request):"",this.response=A.IsNotEmpty(e._source?.log?.response)?JSON.parse(e._source.log?.response):"",this.shopId=e._source.shopId,this.ProcessedCode=e._source.log.processedCode})}};a.\u0275fac=function(d){return new(d||a)},a.\u0275cmp=b({type:a,selectors:[["app-orderdetail"]],standalone:!1,decls:83,vars:21,consts:[[3,"headerTitle","pageData","hideSearchBox","hideSearchDropdown"],["role","button","routerLink","/menu/log/order",1,"btn","btn-secondary","btn-fill","btn-lg","me-3"],[1,"container-fluid","mt-3"],[1,"row"],[1,"col-sm-12"],[1,"card"],[1,"card-header"],[1,"card-body"],[1,"row","mt-7"],[1,"col-sm-6"],[1,"info-label-group"],[1,"row","mt-2"],[1,"form-group"],[1,"float-right"],["role","button",1,"btn","btn-success","btn-fill","btn-lg","me-3"],["role","button",1,"btn","btn-success","btn-fill","btn-lg","me-3",3,"click"]],template:function(d,e){d&1&&(t(0,"mainpanel",0)(1,"actions")(2,"a",1),n(3,"Back"),i()(),t(4,"content")(5,"div",2)(6,"div",3)(7,"div",4)(8,"div",5)(9,"div",6)(10,"h5"),n(11,"General"),i()(),t(12,"div",7)(13,"div",8)(14,"div",9)(15,"div",10)(16,"label"),n(17,"Date"),i(),t(18,"div")(19,"span"),n(20),S(21,"date"),i()()()(),t(22,"div",9)(23,"div",10)(24,"label"),n(25,"Number"),i(),t(26,"div")(27,"span"),n(28),i()()()(),t(29,"div",9)(30,"div",10)(31,"label"),n(32,"Type"),i(),t(33,"div")(34,"span"),n(35),i()()()(),t(36,"div",9)(37,"div",10)(38,"label"),n(39,"Response Code"),i(),t(40,"div")(41,"span"),n(42),i()()()(),t(43,"div",9)(44,"div",10)(45,"label"),n(46,"ShopID"),i(),t(47,"div")(48,"span"),n(49),i()()()(),_(50,yt,7,1,"div",9),t(51,"div",9)(52,"div",10)(53,"label"),n(54,"Action"),i(),t(55,"div")(56,"span"),n(57),i()()()()()()()()(),t(58,"div",11)(59,"div",9)(60,"div",5)(61,"div",6)(62,"h5"),n(63,"Request"),i()(),t(64,"div",7)(65,"div",4)(66,"div",12)(67,"pre"),n(68),S(69,"json"),i()()(),t(70,"actions",13),_(71,St,2,0,"a",14),i()()()(),t(72,"div",9)(73,"div",5)(74,"div",6)(75,"h5"),n(76,"Response"),i()(),t(77,"div",7)(78,"div",4)(79,"div",12)(80,"pre"),n(81),S(82,"json"),i()()()()()()()()()()),d&2&&(u("headerTitle","Order #"+e.Number)("pageData","Orders Detail ")("hideSearchBox",!0)("hideSearchDropdown",!0),r(20),p(E(21,14,e.Created,"dd MMM yyyy HH:mm:ss")),r(8),p(e.Number),r(7),p(e.MarketTypeString),r(7),p(e.ResponseCode),r(7),p(e.shopId),r(),y(e.ProcessedCode!=null?50:-1),r(7),p(e.POSActionTypeString),r(11),p(O(69,17,e.request)),r(3),y(e.ResponseCode!="200"&&e.ResponseCode!="201"?71:-1),r(10),p(O(82,19,e.response)))},dependencies:[N,T,q,w],encapsulation:2});let o=a;return o})();var bt=()=>["/menu/log/exception/detail"],xt=o=>({ID:o});function Et(o,a){if(o&1&&(t(0,"span",17),D(1,"img",18),i(),n(2)),o&2){let l=a.item;r(),u("src",l.Img,G)("alt",l.Name),r(),M(" ",l.Name," ")}}function wt(o,a){if(o&1&&D(0,"img",23),o&2){let l=C().$implicit;u("src",l.Logo,G)}}function It(o,a){if(o&1&&(t(0,"tr")(1,"td"),_(2,wt,1,1,"img",23),n(3),i(),t(4,"td")(5,"a",24),n(6),i()(),t(7,"td"),n(8),S(9,"date"),i(),t(10,"td")(11,"div",9),n(12),i(),t(13,"div"),n(14),i()()()),o&2){let l=a.$implicit;r(2),y(l.Logo?2:-1),r(),M(" ",l.ChannelName," "),r(2),u("routerLink",K(11,bt))("queryParams",F(12,xt,l.id)),r(),M(" ",l.number??"N/A"," "),r(2),p(E(9,8,l.date,"dd-MM-yyyy hh:mm:ss")),r(4),p(l.message),r(2),p(l.stackTrace)}}function Tt(o,a){if(o&1){let l=R();t(0,"mat-paginator",25),x("page",function(d){P(l);let e=C(2);return L(e.onPaginationChange(d))}),i()}if(o&2){let l=C(2);u("length",l.pageTotal)("pageSize",l.pageSize)("pageIndex",(l.filter==null?null:l.filter.PageNumber)==0?0:(l.filter==null?null:l.filter.PageNumber)-1)}}function Dt(o,a){if(o&1&&(t(0,"div",15)(1,"table",19)(2,"thead")(3,"tr",20)(4,"th",21),n(5,"Channel Name"),i(),t(6,"th",21),n(7,"Number"),i(),t(8,"th",21),n(9,"Date"),i(),t(10,"th"),n(11,"Exception"),i()()(),t(12,"tbody"),U(13,It,15,14,"tr",null,H),i()(),_(15,Tt,1,3,"mat-paginator",22),i()),o&2){let l=C();r(13),J(l.exceptions),r(2),y((l.exceptions==null?null:l.exceptions.length)>0?15:-1)}}function Nt(o,a){o&1&&(t(0,"div",16),D(1,"app-empty-state"),i())}var je=(()=>{let a=class a{constructor(){this.http=g(I),this.authService=g(V),this.exceptions=[],this.filter={RowCount:50,PageNumber:1,Number:null,From:null,To:null,ChannelID:null},this.channelOptions=this.authService.getChannels()}ngOnInit(){this.Load()}Load(s={}){this.http.post("/api/OrdersLoader/Get",s).subscribe(d=>{this.filter=d.Filter,this.getData()})}getData(s){this.filter.Number=s,this.http.post("/api/Orders/GetExceptionList",this.filter).subscribe(d=>{this.exceptions=d.hits.map(e=>({id:e._id,ChannelName:e._source?.channelId!=null?this.channelOptions.find(c=>c.ID===e._source?.channelId)?.Name:e._source?.shopId,Logo:e._source?.channelId!=null?this.channelOptions.find(c=>c.ID===e._source?.channelId)?.Img:null,number:e._source?.error?.number,date:e._source["@timestamp_received"],stackTrace:e._source?.error?.stackTrace,message:e._source?.message,requestJSON:e._source?.error?.requestJSON})),this.pageTotal=d.total.value,this.pageSize=this.filter.RowCount>this.pageTotal?this.pageTotal:this.filter.RowCount})}onPaginationChange(s){this.filter.PageNumber=s.pageIndex+1,this.getData()}};a.\u0275fac=function(d){return new(d||a)},a.\u0275cmp=b({type:a,selectors:[["app-exception-log"]],standalone:!1,decls:28,vars:8,consts:[["headerTitle","Exception Log","searchBoxPlaceHolder","Enter Number...",3,"onSubmit"],[1,"fw-bold","mb-2"],["appendTo","body","bindLabel","Name","name","channelid","bindValue","ID","placeholder","Select Channel",1,"center-text",3,"ngModelChange","clearable","items","ngModel"],["ng-option-tmp","","ng-label-tmp",""],[1,"mt-5"],[1,"fw-bold","mb-1"],[1,"mb-4"],["name","From",3,"dateChange","date"],["name","To",3,"dateChange","date"],[1,"fw-bold"],["type","number","name","PageNumber",1,"w-100","mt-2","form-control",3,"ngModelChange","ngModel"],["type","number","name","RowCount",1,"w-100","mt-2","form-control",3,"ngModelChange","ngModel"],[1,"container-fluid","mt-3"],[1,"row"],[1,"col-md-12"],[1,"table-responsive"],[1,"d-flex","flex-column","justify-content-center","align-items-center",2,"margin-top","26vh"],[1,"me-2"],[2,"width","18px",3,"src","alt"],[1,"table","table-hover"],[1,"table-light"],[2,"width","10%"],[3,"length","pageSize","pageIndex"],["alt","Logo",2,"width","18px",3,"src"],[3,"routerLink","queryParams"],[3,"page","length","pageSize","pageIndex"]],template:function(d,e){d&1&&(t(0,"mainpanel",0),x("onSubmit",function(m){return e.getData(m)}),t(1,"filters")(2,"div")(3,"label",1),n(4,"Channel"),i(),t(5,"ng-select",2),v("ngModelChange",function(m){return f(e.filter.ChannelID,m)||(e.filter.ChannelID=m),m}),z(6,Et,3,3,"ng-template",3),i()(),t(7,"div",4)(8,"label",5),n(9,"From/To"),i(),t(10,"div",6)(11,"datepicker",7),v("dateChange",function(m){return f(e.filter.From,m)||(e.filter.From=m),m}),i()(),t(12,"div")(13,"datepicker",8),v("dateChange",function(m){return f(e.filter.To,m)||(e.filter.To=m),m}),i()()(),t(14,"div",4)(15,"label",9),n(16,"Page Number"),i(),t(17,"input",10),v("ngModelChange",function(m){return f(e.filter.PageNumber,m)||(e.filter.PageNumber=m),m}),i()(),t(18,"div",4)(19,"label",9),n(20,"Page Size"),i(),t(21,"input",11),v("ngModelChange",function(m){return f(e.filter.RowCount,m)||(e.filter.RowCount=m),m}),i()()(),t(22,"content")(23,"div",12)(24,"div",13)(25,"div",14),_(26,Dt,16,1,"div",15)(27,Nt,2,0,"div",16),i()()()()()),d&2&&(r(5),u("clearable",!0)("items",e.channelOptions),h("ngModel",e.filter.ChannelID),r(6),h("date",e.filter.From),r(2),h("date",e.filter.To),r(4),h("ngModel",e.filter.PageNumber),r(4),h("ngModel",e.filter.RowCount),r(5),y(e.exceptions.length>0?26:27))},dependencies:[Q,Z,X,Y,N,T,ne,te,$,ee,j,ie,w],encapsulation:2});let o=a;return o})();var Ge=(()=>{let a=class a{constructor(){this.httpService=g(I)}getExceptionDetail(s){return this.httpService.post("/api/Orders/GetDetailException",{ID:s}).pipe(de(e=>e?.hits[0]?._source))}};a.\u0275fac=function(d){return new(d||a)},a.\u0275prov=me({token:a,factory:a.\u0275fac,providedIn:"root"});let o=a;return o})();function Mt(o,a){if(o&1&&(t(0,"div",1)(1,"div",2)(2,"div",3)(3,"div",4)(4,"div",5)(5,"h5"),n(6,"General"),i()(),t(7,"div",6)(8,"div",7)(9,"div",8)(10,"div",9)(11,"label"),n(12,"Date"),i(),t(13,"div")(14,"span"),n(15),S(16,"date"),i()()()(),t(17,"div",8)(18,"div",9)(19,"label"),n(20,"Number"),i(),t(21,"div")(22,"span"),n(23),i()()()(),t(24,"div",8)(25,"div",9)(26,"label"),n(27,"Channel Name"),i(),t(28,"div")(29,"span"),n(30),i()()()(),t(31,"div",8)(32,"div",9)(33,"label"),n(34,"ShopID"),i(),t(35,"div")(36,"span"),n(37),i()()()(),t(38,"div",8)(39,"div",9)(40,"label"),n(41,"Channel ID"),i(),t(42,"div")(43,"span"),n(44),i()()()()()()()()(),t(45,"div",10)(46,"div",8)(47,"div",4)(48,"div",5)(49,"h5"),n(50,"Request"),i()(),t(51,"div",6)(52,"div",11)(53,"div",12)(54,"pre"),n(55),S(56,"json"),i()()()()()(),t(57,"div",8)(58,"div",4)(59,"div",5)(60,"h5"),n(61,"Exception"),i()(),t(62,"div",6)(63,"div",13)(64,"div",12)(65,"pre"),n(66),i()()()()()()()()),o&2){let l=a;r(15),p(E(16,7,l["@timestamp"],"dd MMM yyyy HH:mm:ss")),r(8),p(l==null||l.error==null?null:l.error.number),r(7),p(l==null?null:l.channelName),r(7),p(l==null?null:l.shopId),r(7),p(l==null?null:l.message),r(11),p(O(56,10,l==null||l.error==null?null:l.error.request)),r(11),p(l==null||l.error==null?null:l.error.response)}}var ze=(()=>{let a=class a{constructor(){this.activatedRoute=g(B),this.exceptionService=g(Ge),this.authService=g(V),this.invoiceNumber="",this.channelName="",this.logo=null,this.channelOptions=this.authService.getChannels()}ngOnInit(){let s=this.activatedRoute.snapshot.queryParams;this.exceptionDetail$=this.exceptionService.getExceptionDetail(s?.ID).pipe(de(d=>{let e=d;return{"@timestamp":e["@timestamp"]||e["@timestamp_received"],error:{number:e?.error?.number,request:JSON.parse(e?.error?.request),response:JSON.parse(e?.error?.response)},channelName:e?.channelId!=null?this.channelOptions.find(c=>c.ID===e?.channelId)?.Name:e?.shopId,shopId:e?.shopId,message:e?.message}}))}};a.\u0275fac=function(d){return new(d||a)},a.\u0275cmp=b({type:a,selectors:[["app-exception-detail"]],standalone:!1,decls:4,vars:6,consts:[[3,"headerTitle","hideSearchBox","hideSearchDropdown"],[1,"container-fluid","mt-3"],[1,"row"],[1,"col-12"],[1,"card"],[1,"card-header"],[1,"card-body"],[1,"row","mt-7"],[1,"col-sm-6"],[1,"info-label-group"],[1,"row","mt-2"],[1,"col-sm-12"],[1,"form-group"],[1,"col-sm-12","mt-2"]],template:function(d,e){if(d&1&&(t(0,"mainpanel",0)(1,"content"),_(2,Mt,67,12,"div",1),S(3,"async"),i()()),d&2){let c;u("headerTitle","Order #"+e.invoiceNumber)("hideSearchBox",!0)("hideSearchDropdown",!0),r(2),y((c=O(3,4,e.exceptionDetail$))?2:-1,c)}},dependencies:[T,Se,q,w],encapsulation:2});let o=a;return o})();function Pt(o,a){if(o&1&&(t(0,"div",9)(1,"div",10)(2,"label"),n(3,"Process Code"),i(),t(4,"div")(5,"span"),n(6),i()()()()),o&2){let l=C();r(6),p(l.ProcessedCode)}}function Lt(o,a){if(o&1){let l=R();t(0,"a",15),x("click",function(){P(l);let d=C();return L(d.Retry())}),n(1,"Retry"),i()}}var He=(()=>{let a=class a{constructor(){this.route=g(B),this.http=g(I),this.ProcessDuration=0,this.request="",this.response="",this.route.queryParams.subscribe(s=>{this.ID=s.ID,this.Load()})}Retry(){var s={Number:this.Number,ShopID:this.shopId};this.http.post("/api/Orders/Retry",s).subscribe(d=>{alert(JSON.stringify(d))})}Load(){var s={ID:this.ID};this.http.post("/api/Orders/GetDetailSyncOrder",s).subscribe(d=>{for(let e of d.hits)this.Number=e._source.log.number,this.MarketTypeString=e._source.log.type,this.ResponseCode=e._source.log.responseCode,this.POSActionTypeString=e._source.message,this.ProcessDuration=0,this.Created=e._source["@timestamp_received"],this.request=A.IsNotEmpty(e._source?.log?.request)?JSON.parse(e._source.log?.request):"",this.response=A.IsNotEmpty(e._source?.log?.response)?JSON.parse(e._source.log?.response):"",this.shopId=e._source.shopId,this.ProcessedCode=e._source.log.processedCode})}};a.\u0275fac=function(d){return new(d||a)},a.\u0275cmp=b({type:a,selectors:[["app-orderdetail-user"]],standalone:!1,decls:83,vars:21,consts:[[3,"headerTitle","pageData","hideSearchBox","hideSearchDropdown"],["role","button","routerLink","/menu/log/order",1,"btn","btn-secondary","btn-fill","btn-lg","me-3"],[1,"container-fluid","mt-3"],[1,"row"],[1,"col-sm-12"],[1,"card"],[1,"card-header"],[1,"card-body"],[1,"row","mt-7"],[1,"col-sm-6"],[1,"info-label-group"],[1,"row","mt-2"],[1,"form-group"],[1,"float-right"],["role","button",1,"btn","btn-success","btn-fill","btn-lg","me-3"],["role","button",1,"btn","btn-success","btn-fill","btn-lg","me-3",3,"click"]],template:function(d,e){d&1&&(t(0,"mainpanel",0)(1,"actions")(2,"a",1),n(3,"Back"),i()(),t(4,"content")(5,"div",2)(6,"div",3)(7,"div",4)(8,"div",5)(9,"div",6)(10,"h5"),n(11,"General"),i()(),t(12,"div",7)(13,"div",8)(14,"div",9)(15,"div",10)(16,"label"),n(17,"Date"),i(),t(18,"div")(19,"span"),n(20),S(21,"date"),i()()()(),t(22,"div",9)(23,"div",10)(24,"label"),n(25,"Number"),i(),t(26,"div")(27,"span"),n(28),i()()()(),t(29,"div",9)(30,"div",10)(31,"label"),n(32,"Type"),i(),t(33,"div")(34,"span"),n(35),i()()()(),t(36,"div",9)(37,"div",10)(38,"label"),n(39,"Response Code"),i(),t(40,"div")(41,"span"),n(42),i()()()(),t(43,"div",9)(44,"div",10)(45,"label"),n(46,"ShopID"),i(),t(47,"div")(48,"span"),n(49),i()()()(),_(50,Pt,7,1,"div",9),t(51,"div",9)(52,"div",10)(53,"label"),n(54,"Action"),i(),t(55,"div")(56,"span"),n(57),i()()()()()()()()(),t(58,"div",11)(59,"div",9)(60,"div",5)(61,"div",6)(62,"h5"),n(63,"Request"),i()(),t(64,"div",7)(65,"div",4)(66,"div",12)(67,"pre"),n(68),S(69,"json"),i()()(),t(70,"actions",13),_(71,Lt,2,0,"a",14),i()()()(),t(72,"div",9)(73,"div",5)(74,"div",6)(75,"h5"),n(76,"Response"),i()(),t(77,"div",7)(78,"div",4)(79,"div",12)(80,"pre"),n(81),S(82,"json"),i()()()()()()()()()()),d&2&&(u("headerTitle","Order #"+e.Number)("pageData","Orders Detail ")("hideSearchBox",!0)("hideSearchDropdown",!0),r(20),p(E(21,14,e.Created,"dd MMM yyyy HH:mm:ss")),r(8),p(e.Number),r(7),p(e.MarketTypeString),r(7),p(e.ResponseCode),r(7),p(e.shopId),r(),y(e.ProcessedCode!=null?50:-1),r(7),p(e.POSActionTypeString),r(11),p(O(69,17,e.request)),r(3),y(e.ResponseCode!="200"&&e.ResponseCode!="201"?71:-1),r(10),p(O(82,19,e.response)))},dependencies:[N,T,q,w],encapsulation:2});let o=a;return o})();var Rt=[{path:"",component:We,children:[{path:"",redirectTo:"exception",pathMatch:"full"},{path:"order",component:ke,canActivate:[W],data:{title:"Order Log"}},{path:"inventory/sync-inventory",component:Be,canActivate:[W],data:{title:"Product Inventory Sync"}},{path:"rawlog",component:Ae,canActivate:[W],data:{title:"Raw Log"}},{path:"rawlog/detail",component:Fe,canActivate:[W],data:{title:"Raw Log Detail"}},{path:"inventory/sync-inventory/detail",component:qe,canActivate:[W],data:{title:"Product Inventory Sync Detail"}},{path:"order/detail",component:Ve,canActivate:[W],data:{title:"Order Details"}},{path:"order/detail-user",component:He,canActivate:[W],data:{title:"Order User Details"}},{path:"exception",component:je,canActivate:[W],data:{title:"Exception Log"}},{path:"exception/detail",component:ze,canActivate:[W],data:{title:"Exception Log Detail"}},{path:"inventory",loadComponent:()=>import("./chunk-Q4TAOZ73.js").then(o=>o.InventoryAsyncLogComponent),canActivate:[W],data:{title:"Product Inventory Sync"}},{path:"inventory/detail",loadComponent:()=>import("./chunk-CT6UFONR.js").then(o=>o.InventoryAsyncDetailComponent),canActivate:[W],data:{title:"Product Inventory Sync Detail"}},{path:"authorization-log",loadComponent(){return import("./chunk-KSVJCX2D.js").then(o=>o.ChannelLogComponent)},canActivate:[W],data:{title:"Authorization Log"}}]}],Ue=(()=>{let a=class a{};a.\u0275fac=function(d){return new(d||a)},a.\u0275mod=pe({type:a}),a.\u0275inj=se({imports:[ue,ge.forChild(Rt)]});let o=a;return o})();var Fn=(()=>{let a=class a{};a.\u0275fac=function(d){return new(d||a)},a.\u0275mod=pe({type:a}),a.\u0275inj=se({imports:[ue,we,Ie,Ue,ge,Le,Oe,Re,Te,Pe,j,Ne]});let o=a;return o})();export{Fn as LogsModule};
@@ -1 +1 @@
1
- import{a as rt}from"./chunk-7KG3DC5J.js";import{b as nt}from"./chunk-AAUBUT4Y.js";import{e as it}from"./chunk-6KWG6O5L.js";import{a as pt}from"./chunk-BYTWGXP7.js";import"./chunk-3JRUKSV3.js";import"./chunk-SJ5MC42H.js";import"./chunk-4RLWHMI6.js";import"./chunk-NWB7EVME.js";import{a as lt}from"./chunk-PDCVMSLL.js";import"./chunk-AFDI4TD4.js";import"./chunk-4RG5YR7N.js";import"./chunk-5MV3UFJQ.js";import"./chunk-E6AMKEQR.js";import"./chunk-IGKMJFKP.js";import"./chunk-ITGVXYDV.js";import"./chunk-HK5FXZE4.js";import"./chunk-KJE5GRQ4.js";import"./chunk-4ILDFTIG.js";import"./chunk-A6QXXKPR.js";import"./chunk-Q4AWQ7IC.js";import"./chunk-QXRG5XYP.js";import"./chunk-RXLMJGUY.js";import"./chunk-M4ZE35XK.js";import"./chunk-L7WZ6U4T.js";import"./chunk-LOWGZOML.js";import"./chunk-5PMKN6PM.js";import"./chunk-AGBJEXIM.js";import{e as et}from"./chunk-OXWPYJNB.js";import"./chunk-XBIHN6D3.js";import{c as tt}from"./chunk-JBEKD57G.js";import{m as ot,n as at}from"./chunk-EDEZ3JLR.js";import{A as Z,h as X,m as Y}from"./chunk-L3W6SG2T.js";import"./chunk-YTHY4IFS.js";import"./chunk-ZETUYNFJ.js";import"./chunk-STYL7ETF.js";import"./chunk-XLIPGDSC.js";import{G as K,I as Q,c as q,i as A,j as J,l as U,m as G}from"./chunk-LNJUGHOX.js";import{$b as g,$c as W,Gb as L,Mc as l,Nc as x,Oc as w,Qc as V,Rc as k,Sc as H,Wc as O,Z as v,_c as z,ad as j,bc as S,ca as D,dc as F,ec as R,f as M,fc as $,gc as d,hc as o,hd as c,ic as a,id as u,jc as N,jd as I,kb as E,lb as P,nb as p,qc as B,ra as b,v as _,vc as T,xa as C,xc as s,ya as h}from"./chunk-ZYJ6LAJ3.js";import"./chunk-WFMAM73Y.js";import"./chunk-66YHNWRR.js";var st=(i,r)=>({"bg-gradient-danger":i,"bg-gradient-warning":r}),ct=()=>["/menu/products/status/notification/detail"],mt=i=>({ID:i});function dt(i,r){if(i&1&&(l(0),c(1,"number"),o(2,"span"),l(3,"s"),a()),i&2){let n=s().$implicit;w(" ",I(1,1,n.DurationInSecond,"1.1-1")," ")}}function ut(i,r){i&1&&l(0," - ")}function ft(i,r){if(i&1&&(o(0,"tr",11)(1,"td")(2,"a",12),N(3,"img",13),o(4,"span"),l(5),a()()(),o(6,"td")(7,"b"),l(8),a(),N(9,"div",14),a(),o(10,"td"),g(11,dt,4,4)(12,ut,1,0),a(),o(13,"td"),l(14),a(),o(15,"td"),l(16),c(17,"date"),a()()),i&2){let n=r.$implicit;d("ngClass",j(14,st,n.Status==1,n.Status==0)),p(2),d("routerLink",z(17,ct))("queryParams",W(18,mt,n.ID)),p(),d("src",O(n.Img),P),p(2),x(n.Name),p(3),x(n.Label),p(),d("innerHTML",n.Message,E),p(2),S(n.DurationInSecond?11:12),p(3),x(n.StatusLabel),p(2),w(" ",I(17,11,n.Created,"dd MMM yyyy HH:mm")," ")}}function _t(i,r){if(i&1){let n=B();o(0,"div",5)(1,"div",15)(2,"app-custom-paginator",16),c(3,"async"),c(4,"async"),T("total",function(){C(n);let t=s(2);return h(t.getRowCount())})("next",function(){C(n);let t=s(2);return h(t.getNotifications())})("previous",function(){C(n);let t=s(2);return h(t.getNotifications())}),a()()()}if(i&2){let n=s(),e=s();p(2),d("filter",e.filter)("totaldata",n==null?null:n.length)("paginationTotal",u(3,4,e.rowCount$))("hasClicked",u(4,6,e.rowCount$))}}function Ct(i,r){i&1&&g(0,_t,5,8,"div",5),i&2&&S(r.length>0?0:-1)}var Vt=(()=>{let r=class r{constructor(){this.http=b(et),this.notificationService=b(nt),this.filter=new rt,this.destroy$=new M}ngOnInit(){this.notificationService.clearNotification(),this.initPageLoader(),this.subscribeNotification()}subscribeNotification(){this.notificationService.getNotification().pipe(D(this.destroy$)).subscribe(e=>{e.length>0&&(this.getNotifications(),this.notificationService.clearNotification())})}initPageLoader(){this.http.post("/api/notification/Load",{}).subscribe(e=>{this.filter=e.Filter,this.filter.PageSize=this.filter.RowCount,this.getNotifications()})}onFilter(){this.rowCount$=null,this.getNotifications()}getNotifications(){let e={ChannelID:this.filter.ChannelID,RowCount:this.filter.PageSize,PageNumber:this.filter.PageNumber};this.notifications$=this.http.post("/api/notification/Get",e).pipe(_(t=>t.Data),_(t=>(t=this.setChannelLogoToNotifications(t),t=this.setTimeToSecond(t),t)),v(1))}setTimeToSecond(e){return e=e.map(t=>(t.DurationInSecond=parseInt(t.Duration)/1e3,t)),e}setChannelLogoToNotifications(e){return e=e.map(t=>(t.Img=tt.getChannelLogoByTypeId(t.TypeID),t)),e}getRowCount(){let e={ChannelID:this.filter.ChannelID};this.rowCount$=this.http.post("/api/notification/RowCount",e).pipe(_(t=>t.Count),v(1))}ngOnDestroy(){this.destroy$.next(!0),this.destroy$.complete()}};r.\u0275fac=function(t){return new(t||r)},r.\u0275cmp=L({type:r,selectors:[["app-notification"]],decls:33,vars:6,consts:[["headerTitle","Product Scan Job","hideSearchBox","true",3,"onSubmit"],["routerLink","/menu/products/status/notificationV2",1,"btn","btn-outline-secondary","btn-lg"],[1,"mb-2"],[3,"ngModelChange","ngModel"],[1,"container-fluid","mt-3"],[1,"row"],[1,"col-md-12"],[1,"table-responsive"],[1,"table","table-hover"],[1,"sticky-top-thead"],[1,"table-light"],[3,"ngClass"],[3,"routerLink","queryParams"],["alt","",1,"channelLogo-md","me-4",3,"src"],[3,"innerHTML"],[1,"col-12"],[3,"total","next","previous","filter","totaldata","paginationTotal","hasClicked"]],template:function(t,m){if(t&1&&(o(0,"mainpanel",0),T("onSubmit",function(){return m.onFilter()}),o(1,"actions")(2,"a",1),l(3," Scan Job V2 "),a()(),o(4,"filters")(5,"div")(6,"h6",2),l(7,"Channel"),a(),o(8,"app-channel-options-v2",3),H("ngModelChange",function(y){return k(m.filter.ChannelID,y)||(m.filter.ChannelID=y),y}),a()()(),o(9,"content")(10,"div",4)(11,"div",5)(12,"div",6)(13,"div",7)(14,"table",8)(15,"thead",9)(16,"tr",10)(17,"th"),l(18,"Channel"),a(),o(19,"th"),l(20,"Process"),a(),o(21,"th"),l(22,"Duration"),a(),o(23,"th"),l(24,"Status"),a(),o(25,"th"),l(26,"Created"),a()()(),o(27,"tbody"),R(28,ft,18,20,"tr",11,F),c(30,"async"),a()()()()(),g(31,Ct,1,1),c(32,"async"),a()()()),t&2){let f;p(8),V("ngModel",m.filter.ChannelID),p(20),$(u(30,2,m.notifications$)),p(3),S((f=u(32,4,m.notifications$))?31:-1,f)}},dependencies:[G,q,Z,X,Y,at,ot,lt,it,Q,K,pt,A,U,J],encapsulation:2});let i=r;return i})();export{Vt as NotificationComponent};
1
+ import{a as rt}from"./chunk-7KG3DC5J.js";import{b as nt}from"./chunk-6OIMOM7S.js";import{e as it}from"./chunk-6KWG6O5L.js";import{a as pt}from"./chunk-5KYN6Y7M.js";import"./chunk-3JRUKSV3.js";import"./chunk-SJ5MC42H.js";import"./chunk-4RLWHMI6.js";import"./chunk-NWB7EVME.js";import{a as lt}from"./chunk-PDCVMSLL.js";import"./chunk-AFDI4TD4.js";import"./chunk-4RG5YR7N.js";import"./chunk-5MV3UFJQ.js";import"./chunk-E6AMKEQR.js";import"./chunk-IGKMJFKP.js";import"./chunk-ITGVXYDV.js";import"./chunk-HK5FXZE4.js";import"./chunk-KJE5GRQ4.js";import"./chunk-4ILDFTIG.js";import"./chunk-A6QXXKPR.js";import"./chunk-I723PUUO.js";import"./chunk-QXRG5XYP.js";import"./chunk-RXLMJGUY.js";import"./chunk-M4ZE35XK.js";import"./chunk-L7WZ6U4T.js";import"./chunk-LOWGZOML.js";import"./chunk-5PMKN6PM.js";import"./chunk-AGBJEXIM.js";import{e as et}from"./chunk-OXWPYJNB.js";import"./chunk-XBIHN6D3.js";import{c as tt}from"./chunk-JBEKD57G.js";import{m as ot,n as at}from"./chunk-EDEZ3JLR.js";import{A as Z,h as X,m as Y}from"./chunk-L3W6SG2T.js";import"./chunk-YTHY4IFS.js";import"./chunk-ZETUYNFJ.js";import"./chunk-STYL7ETF.js";import"./chunk-XLIPGDSC.js";import{G as K,I as Q,c as q,i as A,j as J,l as U,m as G}from"./chunk-LNJUGHOX.js";import{$b as g,$c as W,Gb as L,Mc as l,Nc as x,Oc as w,Qc as V,Rc as k,Sc as H,Wc as O,Z as v,_c as z,ad as j,bc as S,ca as D,dc as F,ec as R,f as M,fc as $,gc as d,hc as o,hd as c,ic as a,id as u,jc as N,jd as I,kb as E,lb as P,nb as p,qc as B,ra as b,v as _,vc as T,xa as C,xc as s,ya as h}from"./chunk-ZYJ6LAJ3.js";import"./chunk-WFMAM73Y.js";import"./chunk-66YHNWRR.js";var st=(i,r)=>({"bg-gradient-danger":i,"bg-gradient-warning":r}),ct=()=>["/menu/products/status/notification/detail"],mt=i=>({ID:i});function dt(i,r){if(i&1&&(l(0),c(1,"number"),o(2,"span"),l(3,"s"),a()),i&2){let n=s().$implicit;w(" ",I(1,1,n.DurationInSecond,"1.1-1")," ")}}function ut(i,r){i&1&&l(0," - ")}function ft(i,r){if(i&1&&(o(0,"tr",11)(1,"td")(2,"a",12),N(3,"img",13),o(4,"span"),l(5),a()()(),o(6,"td")(7,"b"),l(8),a(),N(9,"div",14),a(),o(10,"td"),g(11,dt,4,4)(12,ut,1,0),a(),o(13,"td"),l(14),a(),o(15,"td"),l(16),c(17,"date"),a()()),i&2){let n=r.$implicit;d("ngClass",j(14,st,n.Status==1,n.Status==0)),p(2),d("routerLink",z(17,ct))("queryParams",W(18,mt,n.ID)),p(),d("src",O(n.Img),P),p(2),x(n.Name),p(3),x(n.Label),p(),d("innerHTML",n.Message,E),p(2),S(n.DurationInSecond?11:12),p(3),x(n.StatusLabel),p(2),w(" ",I(17,11,n.Created,"dd MMM yyyy HH:mm")," ")}}function _t(i,r){if(i&1){let n=B();o(0,"div",5)(1,"div",15)(2,"app-custom-paginator",16),c(3,"async"),c(4,"async"),T("total",function(){C(n);let t=s(2);return h(t.getRowCount())})("next",function(){C(n);let t=s(2);return h(t.getNotifications())})("previous",function(){C(n);let t=s(2);return h(t.getNotifications())}),a()()()}if(i&2){let n=s(),e=s();p(2),d("filter",e.filter)("totaldata",n==null?null:n.length)("paginationTotal",u(3,4,e.rowCount$))("hasClicked",u(4,6,e.rowCount$))}}function Ct(i,r){i&1&&g(0,_t,5,8,"div",5),i&2&&S(r.length>0?0:-1)}var Vt=(()=>{let r=class r{constructor(){this.http=b(et),this.notificationService=b(nt),this.filter=new rt,this.destroy$=new M}ngOnInit(){this.notificationService.clearNotification(),this.initPageLoader(),this.subscribeNotification()}subscribeNotification(){this.notificationService.getNotification().pipe(D(this.destroy$)).subscribe(e=>{e.length>0&&(this.getNotifications(),this.notificationService.clearNotification())})}initPageLoader(){this.http.post("/api/notification/Load",{}).subscribe(e=>{this.filter=e.Filter,this.filter.PageSize=this.filter.RowCount,this.getNotifications()})}onFilter(){this.rowCount$=null,this.getNotifications()}getNotifications(){let e={ChannelID:this.filter.ChannelID,RowCount:this.filter.PageSize,PageNumber:this.filter.PageNumber};this.notifications$=this.http.post("/api/notification/Get",e).pipe(_(t=>t.Data),_(t=>(t=this.setChannelLogoToNotifications(t),t=this.setTimeToSecond(t),t)),v(1))}setTimeToSecond(e){return e=e.map(t=>(t.DurationInSecond=parseInt(t.Duration)/1e3,t)),e}setChannelLogoToNotifications(e){return e=e.map(t=>(t.Img=tt.getChannelLogoByTypeId(t.TypeID),t)),e}getRowCount(){let e={ChannelID:this.filter.ChannelID};this.rowCount$=this.http.post("/api/notification/RowCount",e).pipe(_(t=>t.Count),v(1))}ngOnDestroy(){this.destroy$.next(!0),this.destroy$.complete()}};r.\u0275fac=function(t){return new(t||r)},r.\u0275cmp=L({type:r,selectors:[["app-notification"]],decls:33,vars:6,consts:[["headerTitle","Product Scan Job","hideSearchBox","true",3,"onSubmit"],["routerLink","/menu/products/status/notificationV2",1,"btn","btn-outline-secondary","btn-lg"],[1,"mb-2"],[3,"ngModelChange","ngModel"],[1,"container-fluid","mt-3"],[1,"row"],[1,"col-md-12"],[1,"table-responsive"],[1,"table","table-hover"],[1,"sticky-top-thead"],[1,"table-light"],[3,"ngClass"],[3,"routerLink","queryParams"],["alt","",1,"channelLogo-md","me-4",3,"src"],[3,"innerHTML"],[1,"col-12"],[3,"total","next","previous","filter","totaldata","paginationTotal","hasClicked"]],template:function(t,m){if(t&1&&(o(0,"mainpanel",0),T("onSubmit",function(){return m.onFilter()}),o(1,"actions")(2,"a",1),l(3," Scan Job V2 "),a()(),o(4,"filters")(5,"div")(6,"h6",2),l(7,"Channel"),a(),o(8,"app-channel-options-v2",3),H("ngModelChange",function(y){return k(m.filter.ChannelID,y)||(m.filter.ChannelID=y),y}),a()()(),o(9,"content")(10,"div",4)(11,"div",5)(12,"div",6)(13,"div",7)(14,"table",8)(15,"thead",9)(16,"tr",10)(17,"th"),l(18,"Channel"),a(),o(19,"th"),l(20,"Process"),a(),o(21,"th"),l(22,"Duration"),a(),o(23,"th"),l(24,"Status"),a(),o(25,"th"),l(26,"Created"),a()()(),o(27,"tbody"),R(28,ft,18,20,"tr",11,F),c(30,"async"),a()()()()(),g(31,Ct,1,1),c(32,"async"),a()()()),t&2){let f;p(8),V("ngModel",m.filter.ChannelID),p(20),$(u(30,2,m.notifications$)),p(3),S((f=u(32,4,m.notifications$))?31:-1,f)}},dependencies:[G,q,Z,X,Y,at,ot,lt,it,Q,K,pt,A,U,J],encapsulation:2});let i=r;return i})();export{Vt as NotificationComponent};
@@ -1 +1 @@
1
- import{a as Y}from"./chunk-BYTWGXP7.js";import"./chunk-3JRUKSV3.js";import"./chunk-SJ5MC42H.js";import"./chunk-4RLWHMI6.js";import"./chunk-NWB7EVME.js";import"./chunk-AFDI4TD4.js";import"./chunk-4RG5YR7N.js";import"./chunk-5MV3UFJQ.js";import"./chunk-E6AMKEQR.js";import"./chunk-IGKMJFKP.js";import"./chunk-ITGVXYDV.js";import"./chunk-HK5FXZE4.js";import"./chunk-KJE5GRQ4.js";import"./chunk-4ILDFTIG.js";import"./chunk-A6QXXKPR.js";import"./chunk-Q4AWQ7IC.js";import"./chunk-QXRG5XYP.js";import"./chunk-RXLMJGUY.js";import"./chunk-M4ZE35XK.js";import"./chunk-L7WZ6U4T.js";import"./chunk-LOWGZOML.js";import"./chunk-5PMKN6PM.js";import{a as H}from"./chunk-AGBJEXIM.js";import{e as F}from"./chunk-OXWPYJNB.js";import"./chunk-XBIHN6D3.js";import"./chunk-JBEKD57G.js";import{m as J,n as G}from"./chunk-EDEZ3JLR.js";import{A as j,c as U,h as K,m as R,p as O}from"./chunk-L3W6SG2T.js";import"./chunk-YTHY4IFS.js";import"./chunk-ZETUYNFJ.js";import"./chunk-STYL7ETF.js";import"./chunk-XLIPGDSC.js";import{i as W,k as D,m as N}from"./chunk-LNJUGHOX.js";import{$b as S,Gb as V,Ha as w,Mc as d,Nc as A,Qc as g,Rc as C,Sc as y,Tc as L,Uc as T,Vc as P,Z as k,bc as x,gc as f,hc as i,hd as b,ic as t,id as B,jc as E,nb as c,qc as M,ra as I,vc as v,xa as m,xc as h,ya as u}from"./chunk-ZYJ6LAJ3.js";import"./chunk-WFMAM73Y.js";import"./chunk-66YHNWRR.js";function q(n,a){if(n&1){let p=M();i(0,"input",30),y("ngModelChange",function(o){m(p);let e=h();return C(e.sku,o)||(e.sku=o),u(o)}),t()}if(n&2){let p=h();g("ngModel",p.sku)}}function z(n,a){if(n&1){let p=M();i(0,"input",31),y("ngModelChange",function(o){m(p);let e=h();return C(e.itemId,o)||(e.itemId=o),u(o)}),t()}if(n&2){let p=h();g("ngModel",p.itemId)}}function Q(n,a){if(n&1&&(i(0,"pre",28),d(1),b(2,"json"),t()),n&2){h();let p=P(35);c(),A(B(2,1,p))}}function X(n,a){n&1&&(i(0,"p",29),d(1," Your data will be shown here once it's available "),t())}var me=(()=>{let a=class a{constructor(){this.httpService=I(F),this.selectedChannel=w(null),this.sku=w(null),this.itemId=w(null),this.searchBy="sku"}initProductLog(){let l={ChannelID:this.selectedChannel()};this.searchBy==="sku"?l.SKU=this.sku():l.ItemID=this.itemId(),this.productLog$=this.httpService.post(H.GetProductApiLog,l).pipe(k(1))}copyToClipboard(l){if(!l)return;let o=typeof l=="string"?l:JSON.stringify(l,null,2);navigator.clipboard.writeText(o),alert("Copied to clipboard!")}};a.\u0275fac=function(o){return new(o||a)},a.\u0275cmp=V({type:a,selectors:[["app-product-api"]],decls:50,vars:14,consts:[["headerTitle","Origin Product Api",3,"hideSearchBox","hideSearchDropdown"],[1,"btn","btn-success","btn-fill","me-3",3,"click"],[1,"fa","fa-search"],[1,"container-fluid","mt-8","px-10"],[1,"row"],[1,"col-7"],[1,"d-flex","align-items-center"],[1,"w-75"],[1,"mb-0","text-muted","fst-italic"],[1,"w-100"],[3,"ngModelChange","ngModel"],[1,"d-flex","align-items-center","mt-3"],[1,"mb-2"],[1,"form-check","form-check-inline"],["type","radio","name","searchBy","id","searchBySku",1,"form-check-input",3,"ngModelChange","ngModel","value"],["for","searchBySku",1,"form-check-label"],["type","radio","name","searchBy","id","searchByItemId",1,"form-check-input",3,"ngModelChange","ngModel","value"],["for","searchByItemId",1,"form-check-label"],["type","text","placeholder","Product Code / SKU",1,"form-control","rounded-1",2,"height","40px",3,"ngModel"],["type","text","placeholder","ItemID is Product id from seller center",1,"form-control","rounded-1",2,"height","40px",3,"ngModel"],[1,"row","mt-6"],[1,"col-12"],[1,"card"],[1,"card-header","d-flex","justify-content-between","align-items-center"],["type","button",1,"btn","btn-sm","btn-outline-primary",3,"click","disabled"],[1,"card-body"],[1,"col-sm-12"],[1,"form-group","position-relative"],["id","productLogText"],[1,"text-center","my-12","text-muted"],["type","text","placeholder","Product Code / SKU",1,"form-control","rounded-1",2,"height","40px",3,"ngModelChange","ngModel"],["type","text","placeholder","ItemID is Product id from seller center",1,"form-control","rounded-1",2,"height","40px",3,"ngModelChange","ngModel"]],template:function(o,e){if(o&1){let s=M();i(0,"mainpanel",0)(1,"actions")(2,"button",1),v("click",function(){return m(s),u(e.initProductLog())}),E(3,"i",2),d(4," Search "),t()(),i(5,"content")(6,"div",3)(7,"div",4)(8,"div",5)(9,"div",6)(10,"div",7)(11,"h6"),d(12,"Channel"),t(),i(13,"p",8),d(14," View logs related to Product API Detail "),t()(),i(15,"div",9)(16,"app-channel-options-v2",10),y("ngModelChange",function(r){return m(s),C(e.selectedChannel,r)||(e.selectedChannel=r),u(r)}),t()()(),i(17,"div",11)(18,"div",7)(19,"h6"),d(20,"Product Code / SKU"),t(),i(21,"p",8),d(22," Product SKU or Code from Channel Product "),t()(),i(23,"div",9)(24,"div",12)(25,"div",13)(26,"input",14),y("ngModelChange",function(r){return m(s),C(e.searchBy,r)||(e.searchBy=r),u(r)}),t(),i(27,"label",15),d(28,"Search by SKU"),t()(),i(29,"div",13)(30,"input",16),y("ngModelChange",function(r){return m(s),C(e.searchBy,r)||(e.searchBy=r),u(r)}),t(),i(31,"label",17),d(32,"Search by ItemID"),t()()(),S(33,q,1,1,"input",18),S(34,z,1,1,"input",19),t()()()(),L(35),b(36,"async"),i(37,"div",20)(38,"div",21)(39,"div",22)(40,"div",23)(41,"h5"),d(42,"Response"),t(),i(43,"button",24),v("click",function(){m(s);let r=P(35);return u(e.copyToClipboard(r))}),d(44," Copy "),t()(),i(45,"div",25)(46,"div",26)(47,"div",27),S(48,Q,3,3,"pre",28)(49,X,2,0,"p",29),t()()()()()()()()()}if(o&2){f("hideSearchBox",!0)("hideSearchDropdown",!0),c(16),g("ngModel",e.selectedChannel),c(10),g("ngModel",e.searchBy),f("value","sku"),c(4),g("ngModel",e.searchBy),f("value","itemid"),c(3),x(e.searchBy==="sku"?33:-1),c(),x(e.searchBy==="itemid"?34:-1),c();let s=T(B(36,11,e.productLog$));c(8),f("disabled",!s),c(5),x(s?48:49)}},dependencies:[N,j,U,O,K,R,G,J,Y,W,D],encapsulation:2});let n=a;return n})();export{me as ProductApiComponent};
1
+ import{a as Y}from"./chunk-5KYN6Y7M.js";import"./chunk-3JRUKSV3.js";import"./chunk-SJ5MC42H.js";import"./chunk-4RLWHMI6.js";import"./chunk-NWB7EVME.js";import"./chunk-AFDI4TD4.js";import"./chunk-4RG5YR7N.js";import"./chunk-5MV3UFJQ.js";import"./chunk-E6AMKEQR.js";import"./chunk-IGKMJFKP.js";import"./chunk-ITGVXYDV.js";import"./chunk-HK5FXZE4.js";import"./chunk-KJE5GRQ4.js";import"./chunk-4ILDFTIG.js";import"./chunk-A6QXXKPR.js";import"./chunk-I723PUUO.js";import"./chunk-QXRG5XYP.js";import"./chunk-RXLMJGUY.js";import"./chunk-M4ZE35XK.js";import"./chunk-L7WZ6U4T.js";import"./chunk-LOWGZOML.js";import"./chunk-5PMKN6PM.js";import{a as H}from"./chunk-AGBJEXIM.js";import{e as F}from"./chunk-OXWPYJNB.js";import"./chunk-XBIHN6D3.js";import"./chunk-JBEKD57G.js";import{m as J,n as G}from"./chunk-EDEZ3JLR.js";import{A as j,c as U,h as K,m as R,p as O}from"./chunk-L3W6SG2T.js";import"./chunk-YTHY4IFS.js";import"./chunk-ZETUYNFJ.js";import"./chunk-STYL7ETF.js";import"./chunk-XLIPGDSC.js";import{i as W,k as D,m as N}from"./chunk-LNJUGHOX.js";import{$b as S,Gb as V,Ha as w,Mc as d,Nc as A,Qc as g,Rc as C,Sc as y,Tc as L,Uc as T,Vc as P,Z as k,bc as x,gc as f,hc as i,hd as b,ic as t,id as B,jc as E,nb as c,qc as M,ra as I,vc as v,xa as m,xc as h,ya as u}from"./chunk-ZYJ6LAJ3.js";import"./chunk-WFMAM73Y.js";import"./chunk-66YHNWRR.js";function q(n,a){if(n&1){let p=M();i(0,"input",30),y("ngModelChange",function(o){m(p);let e=h();return C(e.sku,o)||(e.sku=o),u(o)}),t()}if(n&2){let p=h();g("ngModel",p.sku)}}function z(n,a){if(n&1){let p=M();i(0,"input",31),y("ngModelChange",function(o){m(p);let e=h();return C(e.itemId,o)||(e.itemId=o),u(o)}),t()}if(n&2){let p=h();g("ngModel",p.itemId)}}function Q(n,a){if(n&1&&(i(0,"pre",28),d(1),b(2,"json"),t()),n&2){h();let p=P(35);c(),A(B(2,1,p))}}function X(n,a){n&1&&(i(0,"p",29),d(1," Your data will be shown here once it's available "),t())}var me=(()=>{let a=class a{constructor(){this.httpService=I(F),this.selectedChannel=w(null),this.sku=w(null),this.itemId=w(null),this.searchBy="sku"}initProductLog(){let l={ChannelID:this.selectedChannel()};this.searchBy==="sku"?l.SKU=this.sku():l.ItemID=this.itemId(),this.productLog$=this.httpService.post(H.GetProductApiLog,l).pipe(k(1))}copyToClipboard(l){if(!l)return;let o=typeof l=="string"?l:JSON.stringify(l,null,2);navigator.clipboard.writeText(o),alert("Copied to clipboard!")}};a.\u0275fac=function(o){return new(o||a)},a.\u0275cmp=V({type:a,selectors:[["app-product-api"]],decls:50,vars:14,consts:[["headerTitle","Origin Product Api",3,"hideSearchBox","hideSearchDropdown"],[1,"btn","btn-success","btn-fill","me-3",3,"click"],[1,"fa","fa-search"],[1,"container-fluid","mt-8","px-10"],[1,"row"],[1,"col-7"],[1,"d-flex","align-items-center"],[1,"w-75"],[1,"mb-0","text-muted","fst-italic"],[1,"w-100"],[3,"ngModelChange","ngModel"],[1,"d-flex","align-items-center","mt-3"],[1,"mb-2"],[1,"form-check","form-check-inline"],["type","radio","name","searchBy","id","searchBySku",1,"form-check-input",3,"ngModelChange","ngModel","value"],["for","searchBySku",1,"form-check-label"],["type","radio","name","searchBy","id","searchByItemId",1,"form-check-input",3,"ngModelChange","ngModel","value"],["for","searchByItemId",1,"form-check-label"],["type","text","placeholder","Product Code / SKU",1,"form-control","rounded-1",2,"height","40px",3,"ngModel"],["type","text","placeholder","ItemID is Product id from seller center",1,"form-control","rounded-1",2,"height","40px",3,"ngModel"],[1,"row","mt-6"],[1,"col-12"],[1,"card"],[1,"card-header","d-flex","justify-content-between","align-items-center"],["type","button",1,"btn","btn-sm","btn-outline-primary",3,"click","disabled"],[1,"card-body"],[1,"col-sm-12"],[1,"form-group","position-relative"],["id","productLogText"],[1,"text-center","my-12","text-muted"],["type","text","placeholder","Product Code / SKU",1,"form-control","rounded-1",2,"height","40px",3,"ngModelChange","ngModel"],["type","text","placeholder","ItemID is Product id from seller center",1,"form-control","rounded-1",2,"height","40px",3,"ngModelChange","ngModel"]],template:function(o,e){if(o&1){let s=M();i(0,"mainpanel",0)(1,"actions")(2,"button",1),v("click",function(){return m(s),u(e.initProductLog())}),E(3,"i",2),d(4," Search "),t()(),i(5,"content")(6,"div",3)(7,"div",4)(8,"div",5)(9,"div",6)(10,"div",7)(11,"h6"),d(12,"Channel"),t(),i(13,"p",8),d(14," View logs related to Product API Detail "),t()(),i(15,"div",9)(16,"app-channel-options-v2",10),y("ngModelChange",function(r){return m(s),C(e.selectedChannel,r)||(e.selectedChannel=r),u(r)}),t()()(),i(17,"div",11)(18,"div",7)(19,"h6"),d(20,"Product Code / SKU"),t(),i(21,"p",8),d(22," Product SKU or Code from Channel Product "),t()(),i(23,"div",9)(24,"div",12)(25,"div",13)(26,"input",14),y("ngModelChange",function(r){return m(s),C(e.searchBy,r)||(e.searchBy=r),u(r)}),t(),i(27,"label",15),d(28,"Search by SKU"),t()(),i(29,"div",13)(30,"input",16),y("ngModelChange",function(r){return m(s),C(e.searchBy,r)||(e.searchBy=r),u(r)}),t(),i(31,"label",17),d(32,"Search by ItemID"),t()()(),S(33,q,1,1,"input",18),S(34,z,1,1,"input",19),t()()()(),L(35),b(36,"async"),i(37,"div",20)(38,"div",21)(39,"div",22)(40,"div",23)(41,"h5"),d(42,"Response"),t(),i(43,"button",24),v("click",function(){m(s);let r=P(35);return u(e.copyToClipboard(r))}),d(44," Copy "),t()(),i(45,"div",25)(46,"div",26)(47,"div",27),S(48,Q,3,3,"pre",28)(49,X,2,0,"p",29),t()()()()()()()()()}if(o&2){f("hideSearchBox",!0)("hideSearchDropdown",!0),c(16),g("ngModel",e.selectedChannel),c(10),g("ngModel",e.searchBy),f("value","sku"),c(4),g("ngModel",e.searchBy),f("value","itemid"),c(3),x(e.searchBy==="sku"?33:-1),c(),x(e.searchBy==="itemid"?34:-1),c();let s=T(B(36,11,e.productLog$));c(8),f("disabled",!s),c(5),x(s?48:49)}},dependencies:[N,j,U,O,K,R,G,J,Y,W,D],encapsulation:2});let n=a;return n})();export{me as ProductApiComponent};
@@ -1,2 +1,2 @@
1
- import{h as f}from"./chunk-Q4AWQ7IC.js";import{a as n}from"./chunk-AGBJEXIM.js";import{e as m}from"./chunk-OXWPYJNB.js";import{ea as u,ma as c,ra as l,v as a}from"./chunk-ZYJ6LAJ3.js";var S=(()=>{let r=class r{constructor(){}convertToCSV(t,e){let i;if(typeof t=="string")i=t;else{var o=typeof t=="object"?t:JSON.parse(t);i=this.transformToCSVStringFormat(o)}this.downloadCSV(i,e)}transformToCSVStringFormat(t){if(!t||!t.length)return;let e=",",i=Object.keys(t[0]);return t.map(h=>i.map(d=>{let p=h[d]===null||h[d]===void 0?"":h[d];return p=p instanceof Date?p.toLocaleString():p.toString().replace(/"/g,'""'),p.search(/("|,|\n)/g)>=0&&(p=`"${p}"`),p}).join(e)).join(`
1
+ import{h as f}from"./chunk-I723PUUO.js";import{a as n}from"./chunk-AGBJEXIM.js";import{e as m}from"./chunk-OXWPYJNB.js";import{ea as u,ma as c,ra as l,v as a}from"./chunk-ZYJ6LAJ3.js";var S=(()=>{let r=class r{constructor(){}convertToCSV(t,e){let i;if(typeof t=="string")i=t;else{var o=typeof t=="object"?t:JSON.parse(t);i=this.transformToCSVStringFormat(o)}this.downloadCSV(i,e)}transformToCSVStringFormat(t){if(!t||!t.length)return;let e=",",i=Object.keys(t[0]);return t.map(h=>i.map(d=>{let p=h[d]===null||h[d]===void 0?"":h[d];return p=p instanceof Date?p.toLocaleString():p.toString().replace(/"/g,'""'),p.search(/("|,|\n)/g)>=0&&(p=`"${p}"`),p}).join(e)).join(`
2
2
  `)}downloadCSV(t,e){var i=new Blob([t],{type:"text/csv;charset=utf8;"}),o=document.createElement("a");o.setAttribute("href",window.URL.createObjectURL(i)),o.setAttribute("download",e),document.body.appendChild(o),o.click(),document.body.removeChild(o)}};r.\u0275fac=function(e){return new(e||r)},r.\u0275prov=c({token:r,factory:r.\u0275fac,providedIn:"root"});let s=r;return s})();var T=(()=>{let r=class r{constructor(){this.httpService=l(m),this.tokenService=l(f),this.exportService=l(S)}getShippedOrders(t){return this.httpService.post(n.GetShipped,t).pipe(a(e=>e.Data||[]))}getReadyToShipOrders(t){return this.httpService.post(n.GetToShip,t).pipe(a(e=>e?.Data))}getCompletedOrders(t){return this.httpService.post(n.GetCompleted,t).pipe(a(e=>e?.Data||[]))}getCancelledOrders(t){return this.httpService.post(n.GetCancelled,t).pipe(a(e=>e.Data))}getAwaitingCollectionOrders(t){return this.httpService.post(n.GetAwaitingCollection,t).pipe(a(e=>e?.Data))}getOrderDefaultValue(){return this.httpService.get(n.getOrderDaysFrom).pipe(a(t=>{let e=Number(t.Days??0),i=new Date;return e===0?null:new Date(i.setDate(i.getDate()-e))}))}getAllOrders(t){return this.httpService.post(n.GetAll,t).pipe(a(e=>e.Data))}exportOrders(t,e){return this.httpService.post("api/Orders/ExportOrder",t).pipe(u(i=>{this.exportService.convertToCSV(i,e)}))}refreshShippingCourier(t,e){let i={ShopID:t,OrderNumber:e};return this.httpService.post(n.RefreshShippingCourierAndRefNumber,i)}};r.\u0275fac=function(e){return new(e||r)},r.\u0275prov=c({token:r,factory:r.\u0275fac});let s=r;return s})();export{T as a};