PageSourceSearch

https://samugiken.com/_next/static/chunks/pages/admin/warranty-claim-b8e76a21c12be291.js

js samugiken.com collected 2026-10-07 01:51:04 UTC 40,121 bytes, 1 lines download raw bytes

1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[9587,9810],{22960:function(e,r,t){(window.__NEXT_P=window.__NEXT_P||[]).push(["/admin/warranty-claim",function(){return t(46190)}])},4180:function(e,r){"use strict";r.Z={src:"/_next/static/media/samu-giken.1bf2ec60.webp",height:549,width:1920,blurDataURL:"data:image/webp;base64,UklGRmQAAABXRUJQVlA4WAoAAAAQAAAABwAAAQAAQUxQSBEAAAAAGjk6MjtENBAZNi4qQzcvCgBWUDggLAAAAJABAJ0BKggAAgACQDgloAJ0ugADmAD+6ez/dAAp+z/+0s/+pZ/9Sz/NAAAA",blurWidth:8,blurHeight:2}},39577:function(e,r,t){"use strict";var n=t(52676),a=t(98807),l=t(78051),i=t(92966),s=t(63309);r.Z=e=>{let{children:r,className:t,...d}=e;return(0,n.jsx)(a.Z,{trigger:["click"],rootClassName:(0,s.cn)("!min-w-[100px]",t),...d,children:r||(0,n.jsx)(l.ZP,{className:"!px-2",children:(0,n.jsx)(i.Z,{})})})}},98131:function(e,r,t){"use strict";var n=t(52676),a=t(79406),l=t(78051);r.Z=e=>{let{visible:r,onOk:t,onCancel:i,title:s,content:d,danger:o=!1,okButtonText:c,cancelButtonText:u,loading:m,disabled:h}=e;return(0,n.jsxs)(a.Z,{open:r,title:s,footer:null,closeIcon:null,centered:!0,onCancel:()=>{h||null==i||i()},children:[d,(0,n.jsxs)("div",{className:"flex gap-5 mt-5",children:[(0,n.jsx)(l.ZP,{size:"large",onClick:i,block:!0,disabled:h,children:u||"Cancel"}),(0,n.jsx)(l.ZP,{size:"large",type:"primary",danger:o,onClick:t,block:!0,loading:m,disabled:h,children:c||"Ok"})]})]})}},46976:function(e,r,t){"use strict";var n=t(52676),a=t(75271),l=t(9059),i=t(96516),s=t(4948),d=t(89120),o=t.n(d);r.Z=e=>{let{fetchOptions:r,debounceTimeout:t=500,...d}=e,[c,u]=(0,a.useState)(!1),[m,h]=(0,a.useState)([]),[p,f]=(0,a.useState)(""),x=(0,a.useRef)(0),y=(0,a.useMemo)(()=>o()(e=>{x.current+=1;let t=x.current;r(e).then(e=>{t===x.current&&(h(e),u(!1))})},t),[r,t]),g=c?(0,n.jsx)("div",{className:"py-2 flex justify-center",children:(0,n.jsx)(l.Z,{size:"small"})}):(0,n.jsx)(i.Z,{});return(0,n.jsx)(s.default,{labelInValue:!0,filterOption:!1,onSearch:e=>{h([]),f(e),void 0!==e&&(u(!0),y(e))},onFocus:()=>{h([]),u(!0),y("")},notFoundContent:g,...d,options:m,showSearch:!0,loading:c,searchValue:p})}},99195:function(e,r,t){"use strict";var n=t(52676);t(32195);var a=t(79884),l=t(42148),i=t(6474),s=t(82948);let d=(0,a.M)({features:l.bV});r.Z=e=>{let{src:r,className:t}=e;return(0,n.jsx)("div",{className:t,style:{position:"relative",paddingBottom:"56.25%",height:0,overflow:"hidden"},children:(0,n.jsx)("div",{style:{position:"absolute",inset:0},children:(0,n.jsx)(d.Provider,{children:(0,n.jsx)(i.U,{children:(0,n.jsx)(s.n,{src:r,playsInline:!0,crossOrigin:"anonymous"})})})})})}},49810:function(e,r,t){"use strict";t.d(r,{Z:function(){return U}});var n=t(52676),a=t(75271),l=t(46035),i=t(33022),s=t(40150),d=t(28994),o=t(85304),c=t(4180),u=t(16624),m=t(27026),h=t.n(m),p=t(78051),f=t(98807),x=t(15036),y=t(32623),g=t.n(y);let v=e=>{let{isMobile:r,isDrawerOpen:t,setIsDrawerOpen:a,collapsed:l,setCollapsed:i,fullName:s}=e,{logout:d}=(0,o.a)();return(0,n.jsxs)("div",{style:{borderBottom:"1px solid #e8e8e8",position:"fixed",width:"100%",zIndex:100},className:"flex items-center justify-between h-16 px-6 bg-white",children:[(0,n.jsxs)("div",{className:"flex items-center h-full gap-2",children:[(0,n.jsx)(p.ZP,{onClick:()=>{r?a(!t):i(!l)},"aria-controls":"sidebar",className:"flex items-center justify-center w-8 px-1 py-0",icon:(0,n.jsx)("svg",{className:"w-5 h-5 text-gray-500",fill:"currentColor",viewBox:"0 0 20 20",xmlns:"http://www.w3.org/2000/svg",children:(0,n.jsx)("path",{fillRule:"evenodd",d:"M3 5a1 1 0 011-1h12a1 1 0 110 2H4a1 1 0 01-1-1zM3 10a1 1 0 011-1h6a1 1 0 110 2H4a1 1 0 01-1-1zM3 15a1 1 0 011-1h12a1 1 0 110 2H4a1 1 0 01-1-1z",clipRule:"evenodd"})})}),!r&&(0,n.jsx)(h(),{href:"/",className:"h-full",children:(0,n.jsx)(g(),{src:c.Z,alt:"Samugiken",className:"w-[100%] h-[60px]"})})]}),(0,n.jsx)("div",{className:"flex items-center justify-center",children:(0,n.jsx)("div",{className:"flex items-center justify-center col-row",children:(0,n.jsx)(f.Z,{arrow:!0,placement:"bottomRight",overlayClassName:"shadow-[rgba(0,0,0,0.35)_0_5px_15px] rounded-xl top-10",trigger:["click"],dropdownRender:()=>(0,n.jsxs)("div",{className:"flex flex-col p-3 bg-white rounded-md shadow-md gap-y-1",children:[(0,n.jsx)(h(),{href:"/my-profile",className:"font-medium leading-[normal] text-primary hover:text-primary",children:(0,n.jsx)("div",{className:"cursor-pointer rounded-[4px]  p-3 duration-100 hover:bg-primary/10",children:"My Profile"})}),(0,n.jsx)(x.Z,{className:"!my-2"}),(0,n.jsx)(p.ZP,{type:"primary",danger:!0,onClick:d,children:"Logout"})]}),children:(0,n.jsxs)("div",{className:"flex items-center cursor-pointer gap-x-3",children:[(0,n.jsx)("div",{className:"flex items-center gap-2 ml-2",children:(0,n.jsx)("span",{className:"font-semibold",children:s})}),(0,n.jsx)(u.ZP,{name:s,round:!0,maxInitials:1,size:"35",textSizeRatio:2,fgColor:"white",color:"black"})]})})})})]})};
1var N=t(73640),j=t(62581),b=t(26134),I=t(1952),w=t(7144),A=t(42439),E=t(88483),Z=t(42720),R=t(43146),C=t(57221),O=t(84176),S=t(54216),P=t(12285),_=t(20188),T=t(19254);let D=e=>{var r,t,l,i,s,d,c,u,m,p,f;let{activeMenu:x,activeDropdown:y}=e,[g,v]=(0,a.useState)(x),{user:D}=(0,o.a)(),F=null==D?void 0:D.role.accessRights,L=e=>{v([e])},k=[{key:"dashboard",label:(0,n.jsx)(h(),{href:j.Z.ADMIN_DASHBOARD,children:"Dashboard"}),icon:(0,n.jsx)(I.Z,{width:16,height:16}),onClick:()=>L("dashboard")},...(0,b.f)(null==F?void 0:null===(r=F.PRODUCT)||void 0===r?void 0:r.READ,[{key:"product",label:(0,n.jsx)(h(),{href:j.Z.PRODUCT,children:"Product"}),icon:(0,n.jsx)(w.Z,{width:16,height:16}),onClick:()=>L("product")}]),...(0,b.f)(null==F?void 0:null===(t=F.REVIEW)||void 0===t?void 0:t.READ,[{key:"review",label:(0,n.jsx)(h(),{href:j.Z.REVIEW,children:"Reviews"}),icon:(0,n.jsx)(A.Z,{width:16,height:16}),onClick:()=>L("review")}]),...(0,b.f)(null==F?void 0:null===(l=F.WARRANTY)||void 0===l?void 0:l.READ,[{key:"warranty",label:"Warranty",icon:(0,n.jsx)(T.Z,{width:16,height:16}),children:[{key:"warranty-register",label:(0,n.jsx)(h(),{href:j.Z.WARRANTY_REGISTER,children:"Warranty Register"}),onClick:()=>L("warranty-register")},{key:"warranty-claim",label:(0,n.jsx)(h(),{href:j.Z.WARRANTY_CLAIM,children:"Warranty Claim"}),onClick:()=>L("warranty-claim")}]}]),...(0,b.f)(null==F?void 0:null===(i=F.COUPON)||void 0===i?void 0:i.READ,[{key:"coupon",label:(0,n.jsx)(h(),{href:j.Z.COUPON,children:"Coupon"}),icon:(0,n.jsx)(E.Z,{width:16,height:16}),onClick:()=>L("coupon")}]),...(0,b.f)(null==F?void 0:null===(s=F.ORDER)||void 0===s?void 0:s.READ,[{key:"order",label:(0,n.jsx)(h(),{href:j.Z.ORDER,children:"Orders"}),icon:(0,n.jsx)(T.Z,{width:16,height:16}),onClick:()=>L("order")},{key:"abandonment",label:(0,n.jsx)(h(),{href:j.Z.ABANDONMENT,children:"Abandonment"}),icon:(0,n.jsx)(Z.Z,{width:16,height:16}),onClick:()=>L("abandonment")}]),...(0,b.f)(null==F?void 0:null===(d=F.BLOG)||void 0===d?void 0:d.READ,[{key:"blog",label:(0,n.jsx)(h(),{href:j.Z.BLOG,children:"Blog"}),icon:(0,n.jsx)(R.Z,{width:16,height:16}),onClick:()=>L("blog")}]),...(0,b.f)(null==F?void 0:null===(c=F.OUR_PARTNERS)||void 0===c?void 0:c.READ,[{key:"our-partners",label:(0,n.jsx)(h(),{href:j.Z.OUR_PARTNERS,children:"Our Partners"}),icon:(0,n.jsx)(C.Z,{width:16,height:16}),onClick:()=>L("our-partners")}]),...(0,b.f)(null==F?void 0:null===(u=F.CONTENT_MANAGEMENT)||void 0===u?void 0:u.READ,[{key:"content",label:"Content Management",icon:(0,n.jsx)(O.Z,{width:16,height:16}),children:[{key:"content-banners",label:(0,n.jsx)(h(),{href:j.Z.CONTENT_BANNER,children:"Banners"}),onClick:()=>L("content-banners")},{key:"content-reviews",label:(0,n.jsx)(h(),{href:j.Z.CONTENT_REVIEW,children:"Customer Reviews"}),onClick:()=>L("content-reviews")},{key:"content-videos",label:(0,n.jsx)(h(),{href:j.Z.CONTENT_VIDEO,children:"Product Videos"}),onClick:()=>L("content-videos")},{key:"content-popups",label:(0,n.jsx)(h(),{href:j.Z.CONTENT_POPUP,children:"Popups"}),onClick:()=>L("content-popups")}]}]),...(0,b.f)(null==F?void 0:null===(m=F.USER)||void 0===m?void 0:m.READ,[{key:"user",label:(0,n.jsx)(h(),{href:j.Z.USER,children:"User"}),icon:(0,n.jsx)(S.Z,{width:16,height:16}),onClick:()=>L("user")}]),...(0,b.f)(null==F?void 0:null===(p=F.ROLE)||void 0===p?void 0:p.READ,[{key:"role",label:(0,n.jsx)(h(),{href:j.Z.ROLE,children:"Role"}),icon:(0,n.jsx)(P.Z,{width:16,height:16}),onClick:()=>L("role")}]),...(0,b.f)(null==F?void 0:null===(f=F["SYSTEM_CONFIG/CATEGORY"])||void 0===f?void 0:f.READ,[{key:"system-config",label:(0,n.jsx)(h(),{href:j.Z.SYSTEM_CONFIG,children:"System Config"}),icon:(0,n.jsx)(_.Z,{width:16,height:16}),onClick:()=>L("category")}])];return(0,n.jsx)(N.Z,{theme:"light",mode:"inline",defaultOpenKeys:y||[],defaultSelectedKeys:g,items:k,className:"h-full font-medium"})};var F=t(63309);let{Sider:L,Content:k}=i.default;var U=e=>{let{children:r,user:t,activeMenu:u=[],activeDropdown:m=[],seoConfig:h,withPadding:p=!0,card:f=!0,contentClassName:x}=e,y=(0,d.ac)("(max-width: 768px)"),[N,j]=(0,a.useState)(!1),[b,I]=(0,a.useState)(!1);return(0,n.jsx)(o.H,{user:t,children:(0,n.jsxs)(i.default,{className:"!min-h-screen",children:[(0,n.jsx)(l.PB,{...h}),(0,n.jsx)(v,{isMobile:y,isDrawerOpen:b,setIsDrawerOpen:I,collapsed:N,setCollapsed:j,fullName:(null==t?void 0:t.firstName)+" "+(null==t?void 0:t.lastName)||""}),(0,n.jsx)("div",{className:"mt-[64px]"}),(0,n.jsxs)(i.default,{hasSider:!0,style:{minHeight:"100%"},children:[y?(0,n.jsx)(s.Z,{placement:"left",open:b,onClose:()=>I(!1),width:"250px",styles:{body:{padding:0}},closable:!1,children:(0,n.jsxs)("div",{className:"flex flex-col",children:[(0,n.jsx)("div",{className:"py-2",children:(0,n.jsx)(g(),{src:c.Z,alt:"Samugiken",className:"w-[100%] h-[70px]"})}),(0,n.jsx)(D,{activeMenu:u,activeDropdown:m})]})}):(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)("div",{className:N?"duration-200 ml-[80px]":"duration-200 ml-[250px]"}),(0,n.jsx)(L,{trigger:null,collapsible:!0,collapsed:N,theme:"light",width:250,className:"hide-scrollbar",style:{overflow:"scroll",position:"fixed",marginTop:"64px",left:0,top:0,bottom:0,zIndex:100},children:(0,n.jsx)(D,{activeMenu:u,activeDropdown:m})})]}),(0,n.jsx)(k,{className:(0,F.cn)("min-h-full",p&&"px-3 py-5 md:p-9"),children:(0,n.jsx)("div",{className:(0,F.cn)(f&&"rounded-lg bg-white p-8 shadow-sm",x),children:r})})]})]})})}},5409:function(e,r,t){"use strict";t.d(r,{J:function(){return s}});var n=t(15989),a=t(39771),l=t(91340);let i=n.Z.create({baseURL:a.T5+"/api",headers:{"Content-Type":"application/json"},withCredentials:!0});i.interceptors.request.use(e=>{if((0,l.rD)()){let r=(0,l.Zd)();r&&(e.headers=e.headers||{},e.headers["x-session-id"]=r)}else e.headers&&e.headers["x-session-id"]&&delete e.headers["x-session-id"];return e});let s=n.Z.create({baseURL:a.T5+"/api",headers:{"Content-Type":"multipart/form-data"},maxContentLength:1/0,maxBodyLength:1/0,withCredentials:!0});r.Z=i},95809:function(e,r,t){"use strict";var n=t(75271);r.Z=function(){let e=arguments.length>
10&&void 0!==arguments[0]&&arguments[0],[r,t]=(0,n.useState)(e);return{visible:r,open:()=>{t(!0)},close:()=>{t(!1)},toggle:()=>{t(e=>!e)}}}},56346:function(e,r,t){"use strict";var n=t(75271),a=t(94170);r.Z=e=>{let[r,t]=(0,n.useState)({page:1,pageSize:10,total:0,sortOrder:a.As.DESC,sortField:"createdAt",...e});return[r,t,(e,r,n)=>{t(r=>{var t;return{...r,page:e.current||1,pageSize:e.pageSize||10,sortField:null!==(t=null==n?void 0:n.field)&&void 0!==t?t:null==r?void 0:r.sortField,sortOrder:"ascend"==n.order?a.As.ASC:n.order?a.As.DESC:r.sortOrder}})}]}},85304:function(e,r,t){"use strict";t.d(r,{H:function(){return h},a:function(){return p}});var n=t(52676),a=t(75271),l=t(76517),i=t(73414),s=t(71030),d=t(83214),o=t(62581),c=t(69504),u=t(91340);let m=(0,a.createContext)(null),h=e=>{let{children:r,user:t}=e,h=(0,i.useRouter)(),{mutate:p}=(0,s.D)({mutationFn:c.kS,onError:e=>l.Am.error((0,d._g)(e)),onSuccess:()=>{h.push(o.Z.LOGIN)}});return(0,a.useEffect)(()=>{t?(0,u.hv)():(0,u.wN)()},[t]),(0,n.jsx)(m.Provider,{value:{user:t,logout:p},children:r})},p=()=>{let e=(0,a.useContext)(m);if(!e)throw Error("useAuth must be used within a AuthProvider");return e}},83471:function(e,r,t){"use strict";t.d(r,{$:function(){return i},c:function(){return l}});var n=t(5409),a=t(22903);let l=async(e,r,t)=>{let l=new FormData;l.append("file",r.file);try{let i=await n.J.post(null!=t?t:"/file/upload/".concat(e),l),s=(0,a.I)(i.data.key),d={uid:i.data.refId,name:i.data.name,url:s,status:"done",type:r.file.type,originFileObj:r.file};r.onSuccess(d)}catch(e){r.onError(e)}},i=async(e,r,t)=>{let l=new FormData;l.append("video",r.file);try{let i=await n.J.post(null!=t?t:"/video/upload/".concat(e),l),s=(0,a.I)(i.data.key),d={uid:i.data.refId,name:i.data.name,url:s,status:"done",type:r.file.type,originFileObj:r.file};return r.onSuccess(d),{success:!0,fileObject:d}}catch(e){return r.onError(e),{success:!1,error:e.response.data.message}}}},88290:function(e,r,t){"use strict";var n,a,l,i;t.d(r,{T:function(){return n},Z:function(){return a}}),(l=n||(n={})).PRODUCT_IMAGE="product-image",l.BLOG_IMAGE="blog-image",l.WARRANTY_CLAIM="warranty-claim",l.REVIEW="review",l.CONTENT_IMAGE="content-image",(i=a||(a={})).warranty_claim="warranty-claim",i.description="product-description",i.review="review"},64453:function(e,r,t){"use strict";t.d(r,{Z:function(){return F}});var n=t(52676),a=t(71030),l=t(18060),i=t(79406),s=t(76517),d=t(83214),o=t(3716),c=t(15036),u=t(21844),m=t(88463),h=t(4948),p=t(87517),f=t(78051),x=t(43532),y=t(74563),g=t.n(y);t(41877);var v=t(72626),N=t(57418),j=t(52043),b=t.n(j),I=t(83471),w=t(88290),A=t(46976),E=t(29607),Z=t(22047),R=t(69834),C=t(75271),O=t(22903),S=t(63309),P=t(99195);let _=Object.values(N.Cw),T=Object.values(N.TT);var D=e=>{var r,t;let{isUserClaim:a=!0,fetchOptions:i,fileList:d,setFileList:y,videoFileList:j,setVideoFileList:D,selectedWarranty:F,selectedWarrantyClaim:L,selectedWarrantyId:k,setSelectedWarrantyId:U,onFinish:M,form:W,loading:V,disabled:G,onCancel:Y,readOnlyFieldsAsInfo:B=!1}=e,H={warrantyRefId:L?(null==L?void 0:L.refId)||null:(null==F?void 0:F.refId)||null,fullName:L?(null==L?void 0:L.fullName)||"":(null==F?void 0:F.fullName)||"",phoneNumber:L?(null==L?void 0:L.phoneNumber)||"":(null==F?void 0:F.phoneNumber)||"",emailAddress:L?(null==L?void 0:L.emailAddress)||"":(null==F?void 0:F.emailAddress)||"",dateOfPurchase:L?b()(L.dateOfPurchase):(null==F?void 0:F.dateOfPurchase)?b()(F.dateOfPurchase):null,placeOfPurchase:L?(null==L?void 0:L.placeOfPurchase)||null:(null==F?void 0:F.placeOfPurchase)||null,orderNumber:L?(null==L?void 0:L.orderNumber)||"":(null==F?void 0:F.orderNumber)||"",product:L&&(null==L?void 0:L.product)?{label:L.product.name||"",value:L.product.refId||""}:void 0,productId:L&&(null==L?void 0:null===(r=L.product)||void 0===r?void 0:r.refId)||"",reason:(null==L?void 0:L.reason)||"",images:[],video:null},[q,z]=(0,C.useState)(L?null:F||null),K=l.Z.useWatch("productType",W),$=l.Z.useWatch("productId",W),Q=!!(q||F||k),J=(null==q?void 0:q.products)||(null==F?void 0:F.products)||[],X=!!(G||L||a||Q),ee=!!(B&&X),er=e=>{let{name:r,label:t,formatter:a}=e;return(0,n.jsx)(l.Z.Item,{shouldUpdate:!0,label:t,children:()=>{let e=W.getFieldValue(r),t=a?a(e):e;return(0,n.jsx)("div",{className:"px-3 py-2 text-gray-700 border border-gray-200 rounded-md bg-gray-50",children:t||"-"})}})},et=async e=>{if(!K)return[];let{data:r}=await (0,v.vd)(K,e);return r.map(e=>({label:e.label,value:e.value}))},en=(0,n.jsxs)("button",{style:{border:0,background:"none"},type:"button",children:[(0,n.jsx)(E.Z,{}),(0,n.jsx)("div",{style:{marginTop:8},children:"Upload"})]}),ea=e=>{W.setFieldsValue({warrantyRefId:e.refId||"",fullName:e.fullName||"",phoneNumber:e.phoneNumber||"",emailAddress:e.emailAddress||"",dateOfPurchase:e.dateOfPurchase?b()(e.dateOfPurchase):null,placeOfPurchase:e.placeOfPurchase||null,orderNumber:e.orderNumber||"",product:void 0,productId:"",reason:"",images:[]})};return(0,C.useEffect)(()=>{!L&&F&&(z(F),ea(F))},[F,L,W]),(0,C.useEffect)(()=>{F||k||z(null)},[F,k]),(0,R.a)({queryKey:["product-warranty","warranty",k],queryFn:async()=>{let e=a?await (0,o.hH)({id:k}):await (0,o.li)({id:k});return e.data&&(z(e.data),ea(e.data)),e},select:e=>e.data,enabled:!!k}),(0,n.jsxs)(l.Z,{form:W,onFinish:M,layout:"vertical",initialValues:{...H},children:[i&&U&&(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)(l.Z.Item,{label:"Warranty",name:"warrantyId",children:(0,n.jsx)(A.Z,{fetchOptions:i,placeholder:"Start typing to search",onChange:e=>{e?(z(null),U(e.value)):(U(null),z(null),W.resetFields())},allowClear:!0})}),(0,n.jsx)(c.Z,{})]}),(0,n.jsx)(l.Z.Item,{name:"warrantyRefId",noStyle:!0}),(0,n.jsx)(l.Z.Item,{name:"fullName",label:"Full Name",rules:[{required:!0}],hidden:ee,children:(0,n.jsx)(u.default,{placeholder:"Enter your full name",disabled:X})}),ee&&(0,n.jsx)(er,{name:"fullName",label:"Full Name"}),(0,n.jsx)(l.Z.Item,{name:"phoneNumber",label:"Phone Number",rules:[{required:!0}],hidden:ee,children:(0,n.jsx)(g(),{inputProps:{required:!0},country:"my",inputClass:"form-control",inputStyle:{width:"100%",borderRadius:"6px"},buttonStyle:{borderRadius:"6px 0px 0px 6px",backgroundColor:"#FFFFFF"},placeholder:"00-000 0000",disabled:X})}),ee&&(0,n.jsx)(er,{name:"phoneNumber",label:"Phone Number"}),(0,n.jsx)(l.Z.Item,{name:"emailAddress",label:"Email Address",rules:[{required:!0,type:"email"}],hidden:ee,children:(0,n.jsx)(u.default,{type:"email",placeholder:"Enter your email address",disabled:X})}),ee&&(0,n.jsx)(er,{name:"emailAddress",label:"Email Address"}),(0,n.jsx)(l.Z.Item,{name:"dateOfPurchase",label:"Date of Purchase",rules:[{required:!0,type:"date"}],hidden:ee,children:(0,n.jsx)(m.default,{className:"w-full",disabled:X})}),ee&&(0,n.jsx)(er,{name:"dateOfPurchase",label:"Date of Purchase",formatter:e=>e?b()(e).format("YYYY-MM-DD"):"-"}),(0,n.jsx)(l.Z.Item,{name:"placeOfPurchase",label:"Place of Purchase",rules:[{required:!0}
1],hidden:ee,children:(0,n.jsx)(h.default,{options:[{label:"Choose place",value:null,disabled:!0},...T.map(e=>({label:(0,Z.U$)(e),value:e}))],disabled:X})}),ee&&(0,n.jsx)(er,{name:"placeOfPurchase",label:"Place of Purchase",formatter:e=>e?e===N.TT.EXPO_FAIR_WH_SALES?"Expo / Fair / Warehouse Sales":(0,Z.U$)(e):"-"}),(0,n.jsx)(l.Z.Item,{name:"orderNumber",label:"Order Number / Invoice Number",rules:[{required:!0}],hidden:ee,children:(0,n.jsx)(u.default,{placeholder:"Enter the number",disabled:X})}),ee&&(0,n.jsx)(er,{name:"orderNumber",label:"Order Number / Invoice Number"}),Q?(0,n.jsx)(n.Fragment,{children:(0,n.jsx)(l.Z.Item,{name:"productId",label:"Registered Products",rules:[{required:!0}],children:(0,n.jsx)(p.ZP.Group,{className:"w-full",value:$,onChange:e=>{let r=e.target.value,t=J.find(e=>e.productId===r);W.setFieldValue("productId",r),t&&W.setFieldValue("product",{label:t.sku?"".concat(t.name," (").concat(t.sku,")"):t.name,value:r})},disabled:!!(G||L),children:(0,n.jsx)("div",{className:"flex flex-col w-full gap-2",children:J.map(e=>(0,n.jsxs)("label",{className:(0,S.cn)("flex cursor-pointer items-center justify-between gap-3 rounded-md border p-2 transition",$===e.productId?"border-blue-500 bg-blue-50":"border-gray-200 hover:bg-gray-50"),children:[(0,n.jsxs)("div",{className:"flex items-center flex-1 min-w-0 gap-3",children:[(0,n.jsx)("div",{className:"flex items-center justify-center flex-none w-12 h-12 overflow-hidden bg-white border border-gray-200 rounded-md",children:e.imageKey?(0,n.jsx)("img",{src:(0,O.I)(e.imageKey),alt:e.name,className:"object-contain w-full h-full"}):(0,n.jsx)("span",{className:"text-gray-400 text-[10px]",children:"No Image"})}),(0,n.jsx)("div",{className:"flex-1 min-w-0",children:(0,n.jsx)("div",{className:"text-sm font-medium leading-tight text-gray-900 break-words",children:e.name||"Unnamed product"})})]}),(0,n.jsx)("div",{className:"flex-none",children:(0,n.jsx)(p.ZP,{value:e.productId})})]},e.productId))})})})}):(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)(l.Z.Item,{name:"productType",label:"Product Type",rules:[{required:!0}],children:(0,n.jsx)(h.default,{options:[{label:"Choose product type",value:null,disabled:!0},..._.map(e=>({label:(0,Z.U$)(e),value:e}))],disabled:!!(G||L)})}),K&&(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)(l.Z.Item,{name:"product",label:"".concat((0,Z.U$)(K)," Products"),rules:[{required:!0}],children:(0,n.jsx)(A.Z,{fetchOptions:et,placeholder:"Start typing to search",onChange:e=>W.setFieldValue("productId",e.value),disabled:!!(G||L)})}),(0,n.jsx)(l.Z.Item,{name:"productId",noStyle:!0})]})]}),(0,n.jsx)(l.Z.Item,{name:"reason",label:"Reason",rules:[{required:!0}],children:(0,n.jsx)(u.default.TextArea,{rows:5,placeholder:"Enter your reason"})}),(0,n.jsx)(l.Z.Item,{name:"video",label:(0,n.jsxs)("div",{className:"flex items-center gap-1",children:[(0,n.jsx)("span",{className:"text-red-500",children:"*"}),"Upload Video (Max: 1)"]}),extra:"Video duration only up to 1 minute 30 seconds.",children:j.length>0&&(null===(t=j[0].response)||void 0===t?void 0:t.url)?(0,n.jsxs)("div",{children:[(0,n.jsx)("div",{className:"flex justify-center pb-3",children:(0,n.jsx)(P.Z,{src:j[0].response.url,className:"w-full h-64"})}),(0,n.jsx)("div",{className:"flex justify-center",children:(0,n.jsx)(f.ZP,{danger:!0,size:"large",onClick:()=>{D([])},children:"Remove"})})]}):(0,n.jsx)(x.default,{customRequest:async e=>{let r=await (0,I.$)(w.Z.warranty_claim,e,"/warranty/warranty-claim-video");r.success||s.Am.error(r.error)},fileList:j,onChange:e=>{let{fileList:r}=e;D(r)},listType:"picture-card",accept:"video/*",maxCount:1,children:j.length>=1?null:en})}),(0,n.jsx)(l.Z.Item,{name:"images",label:"Upload Photo (Max: 3)",children:(0,n.jsx)(x.default,{multiple:!0,customRequest:e=>(0,I.c)(w.T.WARRANTY_CLAIM,e,"/warranty/warranty-claim"),fileList:d,onChange:e=>{let{fileList:r}=e;y(r)},listType:"picture-card",accept:"image/*",maxCount:3,children:d.length>=3?null:en})}),(0,n.jsxs)("div",{className:"flex justify-end gap-2",children:[(0,n.jsx)(f.ZP,{block:!0,size:"large",type:"default",onClick:Y,disabled:G,children:"Cancel"}),(0,n.jsx)(f.ZP,{block:!0,size:"large",type:"primary",htmlType:"submit",loading:V,disabled:G,children:"Submit Claim"})]})]})},F=e=>{let{isUserClaim:r=!0,open:t,onSuccess:c,onClose:u,fetchOptions:m,setSelectedUserId:h,fileList:p,setFileList:f,videoFileList:x,setVideoFileList:y,selectedWarranty:g,selectedWarrantyClaim:v,selectedWarrantyId:N,setSelectedWarrantyId:j}=e,[b]=l.Z.useForm(),I=(0,a.D)({mutationFn:e=>(0,o.R8)(e),onSuccess:()=>{b.resetFields(),null==u||u(),c()}}),w=()=>{b.resetFields(),null==u||u(),null==h||h(null),null==j||j(null),y([]),f([])};return(0,n.jsx)(i.Z,{open:t,onCancel:w,footer:null,title:"Claim Warranty",closeIcon:null,centered:!0,children:(0,n.jsx)(D,{isUserClaim:r,readOnlyFieldsAsInfo:r,fetchOptions:m,fileList:p,setFileList:f,videoFileList:x,setVideoFileList:y,selectedWarrantyClaim:v,form:b,onFinish:e=>{var r;if(0===x.length){b.setFields([{name:"video",errors:["At least one video is required"]}]);return}let t=(p||[]).map(e=>e.response?e.response.uid:e.uid),n=(null===(r=x[0].response)||void 0===r?void 0:r.uid)||x[0].uid,{product:a,...l}=e,i={...l,images:t,video:n};s.Am.promise(I.mutateAsync(i),{pending:"Submitting warranty claim...",success:"Warranty claim submitted successfully",error:{render(e){let{data:r}=e;return"Error claiming warranty: ".concat((0,d._g)(r))}}})},selectedWarranty:g,selectedWarrantyId:N,setSelectedWarrantyId:j,loading:I.isPending,disabled:I.isPending,onCancel:w})})}},57418:function(e,r,t){"use strict";var n,a,l,i,s,d,o,c,u,m;t.d(r,{Cw:function(){return n},RL:function(){return s},TT:function(){return a},bR:function(){return i},e_:function(){return l}}),(d=n||(n={})).BABY_AND_MUMMY="BABY_AND_MUMMY",d.KITCHEN_APPLIANCES="KITCHEN_APPLIANCES",d.HOME_APPLIANCES="HOME_APPLIANCES",d.BEAUTY_AND_HEALTH="BEAUTY_AND_HEALTH",(o=a||(a={})).LAZADA="LAZADA",o.SHOPEE="SHOPEE",o.WOW_SHOP="WOW_SHOP",o.WEBSITE="WEBSITE",o.TIK_TOK="TIK_TOK",o.PG_MALL="PG_MALL",o.ZALORA
1="ZALORA",o.OFFLINE_DEALER="OFFLINE_DEALER",o.EXPO_FAIR_WH_SALES="EXPO_FAIR_WH_SALES",o.WALK_IN="WALK_IN",(c=l||(l={})).COMMENT="COMMENT",c.STATUS_CHANGE="STATUS_CHANGE",(u=i||(i={})).USER="USER",u.ADMIN="ADMIN",(m=s||(s={})).PENDING="PENDING",m.IN_PROCESSING="IN_PROCESSING",m.RESOLVED="RESOLVED",m.CLOSED="CLOSED"},22047:function(e,r,t){"use strict";t.d(r,{U$:function(){return i},rp:function(){return a},z2:function(){return l}});var n=t(57418);let a=e=>({[n.RL.PENDING]:"Pending",[n.RL.IN_PROCESSING]:"In Processing",[n.RL.RESOLVED]:"Resolved",[n.RL.CLOSED]:"Closed"})[e],l=e=>({[n.RL.PENDING]:"orange",[n.RL.IN_PROCESSING]:"blue",[n.RL.RESOLVED]:"green",[n.RL.CLOSED]:"default"})[e],i=e=>e.toLowerCase().replace(/[_-]/g," ").replace(/\b\w/g,e=>e.toUpperCase()).replace(/ And /g," & ")},46190:function(e,r,t){"use strict";t.r(r),t.d(r,{__N_SSP:function(){return $},default:function(){return Q}});var n=t(52676),a=t(49810),l=t(21844),i=t(78051),s=t(95809),d=t(87927),o=t(69947),c=t(69834),u=t(4475),m=t(56346),h=t(75271),p=t(3716),f=t(71030),x=t(57722),y=t(77894),g=t(83214),v=t(57418),N=t(52043),j=t.n(N),b=t(39577),I=t(26134),w=t(85304),A=t(2194),E=t(1705),Z=t(98131),R=t(76517),C=t(18060),O=t(79406),S=t(88463),P=t(4948),_=t(43532),T=t(74563),D=t.n(T);t(41877);var F=t(83471),L=t(88290),k=t(29607),U=t(22047),M=t(99195);let W=Object.values(v.TT);var V=e=>{var r,t,a,s;let{onFinish:d,form:o,fileList:c,setFileList:u,videoFileList:m,setVideoFileList:h,loading:p,disabled:f}=e,x=(0,n.jsxs)("button",{style:{border:0,background:"none"},type:"button",children:[(0,n.jsx)(k.Z,{}),(0,n.jsx)("div",{style:{marginTop:8},children:"Upload"})]});return(0,n.jsxs)(C.Z,{form:o,onFinish:d,layout:"vertical",children:[(0,n.jsx)(C.Z.Item,{name:"warrantyRefId",noStyle:!0}),(0,n.jsx)(C.Z.Item,{name:"warrantyClaimId",noStyle:!0}),(0,n.jsx)(C.Z.Item,{name:"fullName",label:"Full Name",rules:[{required:!0}],children:(0,n.jsx)(l.default,{placeholder:"Enter your full name"})}),(0,n.jsx)(C.Z.Item,{name:"phoneNumber",label:"Phone Number",rules:[{required:!0}],children:(0,n.jsx)(D(),{inputProps:{required:!0},country:"my",inputClass:"form-control",inputStyle:{width:"100%",borderRadius:"6px"},buttonStyle:{borderRadius:"6px 0px 0px 6px",backgroundColor:"#FFFFFF"},placeholder:"00-000 0000"})}),(0,n.jsx)(C.Z.Item,{name:"emailAddress",label:"Email Address",rules:[{required:!0,type:"email"}],children:(0,n.jsx)(l.default,{type:"email",placeholder:"Enter your email address"})}),(0,n.jsx)(C.Z.Item,{name:"dateOfPurchase",label:"Date of Purchase",rules:[{required:!0,type:"date"}],children:(0,n.jsx)(S.default,{className:"w-full"})}),(0,n.jsx)(C.Z.Item,{name:"placeOfPurchase",label:"Place of Purchase",rules:[{required:!0}],children:(0,n.jsx)(P.default,{options:[{label:"Choose place",value:null,disabled:!0},...W.map(e=>({label:(0,U.U$)(e),value:e}))]})}),(0,n.jsx)(C.Z.Item,{name:"orderNumber",label:"Order Number / Invoice Number",rules:[{required:!0}],children:(0,n.jsx)(l.default,{placeholder:"Enter the number"})}),(0,n.jsx)(C.Z.Item,{shouldUpdate:!0,noStyle:!0,children:()=>{let e=o.getFieldValue("product");return(0,n.jsx)(C.Z.Item,{label:"Product",children:(0,n.jsx)(l.default,{value:(null==e?void 0:e.label)||"",disabled:!0})})}}),(0,n.jsx)(C.Z.Item,{name:"productId",noStyle:!0}),(0,n.jsx)(C.Z.Item,{name:"reason",label:"Reason",rules:[{required:!0}],children:(0,n.jsx)(l.default,{placeholder:"Enter your reason"})}),(0,n.jsx)(C.Z.Item,{name:"images",label:(0,n.jsxs)("div",{className:"flex items-center gap-1",children:[(0,n.jsx)("span",{className:"text-red-500",children:"*"}),"Upload Photo (Max: 3)"]}),children:(0,n.jsx)(_.default,{multiple:!0,customRequest:e=>(0,F.c)(L.T.WARRANTY_CLAIM,e,"/warranty/warranty-claim"),fileList:c,onChange:e=>{let{fileList:r}=e;u(r)},listType:"picture-card",accept:"image/*",maxCount:3,children:c.length>=3?null:x})}),(0,n.jsx)(C.Z.Item,{name:"video",label:"Upload Video (Max: 1)",children:m.length>0&&((null===(r=m[0].response)||void 0===r?void 0:r.url)||(null===(t=m[0])||void 0===t?void 0:t.url))?(0,n.jsxs)("div",{children:[(0,n.jsx)("div",{className:"flex justify-center pb-3",children:(0,n.jsx)(M.Z,{src:(null===(a=m[0].response)||void 0===a?void 0:a.url)||(null===(s=m[0])||void 0===s?void 0:s.url)||"",className:"w-full h-64"})}),(0,n.jsx)("div",{className:"flex justify-center",children:(0,n.jsx)(i.ZP,{danger:!0,size:"large",onClick:()=>{h([])},children:"Remove"})})]}):(0,n.jsx)(_.default,{customRequest:async e=>{let r=await (0,F.$)(L.Z.warranty_claim,e,"/warranty/warranty-claim-video");r.success||R.Am.error(r.error)},fileList:m,onChange:e=>{let{fileList:r}=e;h(r)},listType:"picture-card",accept:"video/*",maxCount:1,children:m.length>=1?null:x})}),(0,n.jsx)("div",{className:"flex justify-end",children:(0,n.jsx)(i.ZP,{type:"primary",htmlType:"submit",loading:p,disabled:f,children:"Update"})})]})},G=t(22903),Y=e=>{let{open:r,onClose:t,onSuccess:a,warrantyClaim:l}=e,[i]=C.Z.useForm(),[s,d]=(0,h.useState)([]),[o,c]=(0,h.useState)([]);(0,h.useEffect)(()=>
1{if(l){var e;i.setFieldsValue({warrantyClaimId:l.refId||"",warrantyId:l.productWarrantyId||"",fullName:l.fullName||"",phoneNumber:l.phoneNumber||"",emailAddress:l.emailAddress||"",dateOfPurchase:l.dateOfPurchase?j()(l.dateOfPurchase):null,placeOfPurchase:l.placeOfPurchase||null,orderNumber:l.orderNumber||"",product:l.product?{label:l.product.name||"",value:l.product.refId||""}:void 0,productId:(null===(e=l.product)||void 0===e?void 0:e.refId)||"",reason:l.reason||""}),d(l.images.map(e=>({uid:e.refId||"",name:e.name||"",type:e.mimeType||"",status:"done",url:(0,G.I)(e.key||"")}))),l.video&&c([{uid:l.video.refId||"",name:l.video.name||"",type:l.video.mimeType||"",status:"done",url:(0,G.B)(l.video.key||"")}])}},[l,i]);let u=(0,f.D)({mutationFn:e=>(0,p.OR)(e),onSuccess:()=>{i.resetFields(),d([]),c([]),null==t||t(),a()}});return(0,n.jsx)(O.Z,{open:r,onCancel:()=>{i.resetFields(),null==t||t(),d([]),c([])},footer:null,title:"Update Warranty Claim",closeIcon:null,centered:!0,children:(0,n.jsx)(V,{form:i,onFinish:e=>{var r;if(0===s.length){i.setFields([{name:"images",errors:["At least one image is required"]}]);return}let t=s.map(e=>e.response?e.response.uid:e.uid),n=o.length>0?(null===(r=o[0].response)||void 0===r?void 0:r.uid)||o[0].uid:null,{product:a,...l}=e,d={...l,images:t,video:n};R.Am.promise(u.mutateAsync(d),{pending:"Updating warranty claim...",success:"Warranty claim updated successfully",error:{render(e){let{data:r}=e;return"Error updating warranty claim: ".concat((0,g._g)(r))}}})},loading:!1,disabled:!1,fileList:s,setFileList:d,videoFileList:o,setVideoFileList:c})})},B=t(27026),H=t.n(B),q=e=>{let{warrantyClaimQuery:r,pagination:t,paginationOnChange:a}=e,{user:l}=(0,w.a)(),[i,d]=(0,h.useState)(null),o=(0,s.Z)(),c=(0,s.Z)(),u=(0,f.D)({mutationFn:e=>(0,p.E0)(e),onSuccess:()=>{o.close(),r.refetch()}}),m=e=>{R.Am.promise(u.mutateAsync({id:e}),{pending:"Deleting warranty claim...",success:"Warranty claim deleted successfully",error:{render(e){let{data:r}=e;return"Error deleting warranty claim: ".concat((0,g._g)(r))}}})};return(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)(y.Z,{columns:[{title:"Claim ID",dataIndex:"warrantyClaimId",width:120,render:(e,r)=>(0,n.jsx)(H(),{href:"/admin/warranty-claim/".concat(r.refId),children:e})},{title:"Register ID",dataIndex:["productWarranty","warrantyId"],width:120,render:(e,r)=>{var t;return(null===(t=r.productWarranty)||void 0===t?void 0:t.warrantyId)||"-"}},{title:"Order Number",dataIndex:"orderNumber",width:200},{title:"Status",dataIndex:"status",width:100,render:e=>e===v.RL.PENDING?(0,n.jsx)(x.Z,{color:"orange",children:"Pending"}):e===v.RL.IN_PROCESSING?(0,n.jsx)(x.Z,{color:"blue",children:"In Processing"}):e===v.RL.RESOLVED?(0,n.jsx)(x.Z,{color:"green",children:"Resolved"}):e===v.RL.CLOSED?(0,n.jsx)(x.Z,{color:"default",children:"Closed"}):void 0},{title:"Reason",dataIndex:"reason",width:200,render:e=>e||"-"},{title:"Product Name",dataIndex:["product","name"],render:(e,r)=>{var t;return(null===(t=r.product)||void 0===t?void 0:t.name)?r.product.name:"-"},width:400},{title:"Full Name",dataIndex:"fullName",width:200},{title:"Phone Number",dataIndex:"phoneNumber",width:150},{title:"Email Address",dataIndex:"emailAddress",width:200},{title:"Date of Purchase",dataIndex:"dateOfPurchase",render:e=>j()(e).format("YYYY-MM-DD"),width:160},{title:"Place of Purchase",dataIndex:"placeOfPurchase",render:e=>e===v.TT.EXPO_FAIR_WH_SALES?"Expo / Fair / Warehouse Sales":(0,U.U$)(e),width:200},{title:"Created at",dataIndex:"createdAt",render:e=>(0,g.i$)(e,"-"),width:200},{dataIndex:"refId",width:50,render:(e,r)=>(0,n.jsx)(b.Z,{menu:{items:[{key:"view",label:(0,n.jsx)(H(),{href:"/admin/warranty-claim/".concat(e),children:"View"}),icon:(0,n.jsx)(A.Z,{})},{type:"divider"},...(0,I.f)(l.role.accessRights.WARRANTY.DELETE,[{key:"delete",label:"Delete",danger:!0,className:"",icon:(0,n.jsx)(E.Z,{}),onClick:()=>{d(r),o.open()}}])]}})}],dataSource:r.data,onChange:a,loading:r.isFetching,rowKey:e=>e.refId,scroll:{x:"max-content"},pagination:{current:t.page,pageSize:t.pageSize,defaultPageSize:1,showSizeChanger:!0,pageSizeOptions:[10,25,50,100],showTotal:(e,r)=>"Pagination: ".concat(r[0],"-").concat(r[1]," of ").concat(e," items"),total:t.total}}),(0,n.jsx)(Z.Z,{visible:o.visible,title:(null==i?void 0:i.orderNumber)||"",content:"Are you sure you want to delete this warranty claim?",okButtonText:"Delete",onCancel:()=>{o.close(),d(null)},onOk:()=>{i&&m(i.refId)},danger:!0,loading:u.isPending,disabled:u.isPending}),(0,n.jsx)(Y,{warrantyClaim:i,open:c.visible,onClose:()=>{c.close(),d(null)},onSuccess:()=>r.refetch()})]})},z=t(64453),K=t(98774),$=!0,Q=e=>{var r;let{user:t}=e,[f,x]=(0,d.v1)("search",d.Oi.withDefault("")),{open:y,visible:g,close:v}=(0,s.Z)(),N=(0,o.NL)(),[j,b,w]=(0,m.Z)(),[A]=(0,m.Z)(),[E,Z]=(0,h.useState)(null),[R,C]=(0,h.useState)([]),[O,S]=(0,h.useState)([]),P=(0,c.a)({queryKey:["warranty","claim","pagination",j,f],queryFn:async()=>{let e=await (0,p.ND)({page:j.page,pageSize:j.pageSize,sortField:j.sortField,sortOrder:j.sortOrder,search:f});return b(r=>({...r,page:e.data.page,total:e.data.total})),e},placeholderData:u.Wk,select:e=>e.data.rows}),_=async e=>{let{rows:r}=(await (0,p.YE)({page:A.page,pageSize:A.pageSize,sortField:A.sortField,sortOrder:A.sortOrder,search:e})).data;return r.map(e=>({label:e.warrantyId,value:e.refId}))};return(0,n.jsxs)(a.Z,{user:t,activeMenu:["warranty","warranty-claim"],activeDropdown:["warranty"],children:[(0,n.jsxs)("div",{className:"flex gap-5 justify-between mb-5",children:[(0,n.jsx)(l.default.Search,{className:"max-w-[400px]",allowClear:!0,onSearch:e=>x(e)}),...(0,I.f)(null===(r=t.role.accessRights)||void 0===r?void 0:r.WARRANTY.CREATE,[(0,n.jsxs)(i.ZP,{type:"primary",onClick:y,children:[(0,n.jsx)(K.Z,{}),"Claim Warranty"]}
1,"new-user-button")])]},"new-user-button"),(0,n.jsx)(q,{warrantyClaimQuery:P,pagination:j,paginationOnChange:w}),(0,n.jsx)(z.Z,{isUserClaim:!1,fetchOptions:_,open:g,onClose:v,onSuccess:()=>N.refetchQueries({queryKey:["warranty","claim","pagination"]}),fileList:R,setFileList:C,videoFileList:O,setVideoFileList:S,selectedWarrantyId:E,setSelectedWarrantyId:Z})]})}},69504:function(e,r,t){"use strict";t.d(r,{A9:function(){return o},IU:function(){return l},c0:function(){return d},kS:function(){return i},o9:function(){return s},x4:function(){return a}});var n=t(5409);let a=async e=>n.Z.post("/auth/login",e),l=async e=>n.Z.post("/auth/signup",e),i=async()=>n.Z.post("/auth/logout"),s=async e=>n.Z.post("/auth/forget-password",e),d=async e=>n.Z.post("/auth/password-reset/confirm",e),o=async e=>n.Z.post("/auth/verify-user",e)},72626:function(e,r,t){"use strict";t.d(r,{PA:function(){return a},Yc:function(){return l},lq:function(){return i},vd:function(){return s}});var n=t(5409);let a=()=>n.Z.get("admin/option/category"),l=()=>n.Z.get("option/categories/tree"),i=e=>n.Z.get("option/categories/children",{params:e?{parentId:e}:void 0}),s=(e,r)=>n.Z.get("option/products",{params:{productType:e,search:r}})},3716:function(e,r,t){"use strict";t.d(r,{DQ:function(){return a},E0:function(){return g},Gt:function(){return u},JU:function(){return x},M1:function(){return v},ND:function(){return y},OR:function(){return h},R8:function(){return m},Y3:function(){return N},YE:function(){return i},YJ:function(){return c},e_:function(){return l},g5:function(){return f},hH:function(){return d},li:function(){return s},nf:function(){return p},wf:function(){return o}});var n=t(5409);let a=()=>n.Z.get("warranty"),l=()=>n.Z.get("warranty/claims"),i=e=>n.Z.get("admin/warranty",{params:e}),s=e=>n.Z.get("/admin/warranty/".concat(e.id)),d=e=>n.Z.get("/warranty/".concat(e.id)),o=e=>n.Z.post("warranty/register-warranty",e),c=(e,r)=>n.Z.post("admin/warranty/register",{...e,userId:r}),u=e=>n.Z.put("admin/warranty/".concat(e.warrantyId),e),m=e=>n.Z.post("warranty/claim-warranty",e),h=e=>n.Z.put("admin/claim/".concat(e.warrantyClaimId),e),p=(e,r)=>n.Z.put("admin/claim/".concat(e,"/status"),{status:r}),f=(e,r)=>n.Z.put("admin/claim/".concat(e,"/comment"),r),x=e=>n.Z.delete("/admin/warranty/".concat(e.id)),y=e=>n.Z.get("admin/claim",{params:e}),g=e=>n.Z.delete("/admin/claim/".concat(e.id)),v=e=>n.Z.get("/admin/claim/".concat(e.id)),N=e=>n.Z.get("/warranty/claims/".concat(e.id))},62581:function(e,r,t){"use strict";var n,a;t.d(r,{Z:function(){return n}}),(a=n||(n={})).LOGIN="/login",a.ADMIN_DASHBOARD="/admin/dashboard",a.HOME="/",a.USER="/admin/user",a.ROLE="/admin/role",a.NEW_ROLE="/admin/role/new",a.SYSTEM_CONFIG="/admin/system-config",a.PRODUCT="/admin/product",a.BLOG="/admin/blog",a.ORDER="/admin/order",a.ABANDONMENT="/admin/abandonment",a.WARRANTY_REGISTER="/admin/warranty-register",a.WARRANTY_CLAIM="/admin/warranty-claim",a.COUPON="/admin/coupon",a.OUR_PARTNERS="/admin/our-partners",a.REVIEW="/admin/review",a.CONTENT_BANNER="/admin/content/banners",a.CONTENT_REVIEW="/admin/content/reviews",a.CONTENT_VIDEO="/admin/content/videos",a.CONTENT_POPUP="/admin/content/popups"},94170:function(e,r,t){"use strict";var n,a,l,i,s,d,o,c,u,m;t.d(r,{As:function(){return l},fH:function(){return i},hY:function(){return a}}),(d=n||(n={})).EN="en",d.ZH_HK="zh-HK",(o=a||(a={})).LOGIN="login",o.FORGET_PASSWORD="forget_password",o.SIGNUP="signup",(c=l||(l={})).ASC="asc",c.DESC="desc",(u=i||(i={})).VERIFIED="VERIFIED",u.PENDING_FOR_VERIFICATION="PENDING_FOR_VERIFICATION",u.VERIFICATION_EXPIRED="VERIFICATION_EXPIRED",(m=s||(s={})).ADMIN="Admin",m.CUSTOMER="Customer"},26134:function(e,r,t){"use strict";t.d(r,{f:function(){return n}});let n=(e,r,t)=>void 0===r?void 0!==t?t:Array.isArray(r)?[]:{}:e?r:void 0!==t?t:Array.isArray(r)?[]:{}},83214:function(e,r,t){"use strict";t.d(r,{_g:function(){return l},i$:function(){return i}});var n=t(52043),a=t.n(n);let l=e=>{if("response"in e){var r,t;return null===(t=e.response)||void 0===t?void 0:null===(r=t.data)||void 0===r?void 0:r.message}return e.message},i=(e,r)=>{let t=a()(e);return e&&t.isValid()?a()(e).format("DD MMM YYYY, hh:mm a"):r||null}},22903:function(e,r,t){"use strict";t.d(r,{B:function(){return a},I:function(){return n}});let n=e=>"".concat("https://cdn.samugiken.com","/").concat("production","/").concat(encodeURIComponent(e)),a=e=>"".concat("https://cdn.samugiken.com","/").concat("production","/").concat(encodeURIComponent(e))},91340:function(e,r,t){"use strict";t.d(r,{Zd:function(){return l},hv:function(){return s},rD:function(){return d},wN:function(){return i}});let n="session_id",a="session_header_enabled";function l(){try{let e=localStorage.getItem(n);if(e&&e.length>0)return e;let r="undefined"!=typeof crypto&&"randomUUID"in crypto?crypto.randomUUID():o();return localStorage.setItem(n,r),r}catch(e){return o()}}function i(){try{localStorage.setItem(a,"1")}catch(e){}}function s(){try{localStorage.setItem(a,"0"),localStorage.removeItem(n)}catch(e){}}function d(){try{return"1"===localStorage.getItem(a)}catch(e){return!1}}function o(){return"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,function(e){let r=16*Math.random()|0;return("x"===e?r:3&r|8).toString(16)})}}},function(e){e.O(0,[5989,4237,7610,8174,9834,8051,9513,4540,928,4298,4190,6631,6220,9575,7444,9406,150,1887,5934,8060,9059,8672,1795,8374,7894,8463,3532,6509,2888,9774,179],function(){return e(e.s=22960)}),_N_E=e.O()}]);

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.