1"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[5578],{25578:function(e,s,r){r.r(s),r.d(s,{__N_SSP:function(){return E},default:function(){return U}});var t=r(85893),l=r(67294),n=r(99603),a=r(59417),i=r(38138),c=r(34288),o=r(63750),d=r(42444),x=r(41664),u=r.n(x),h=r(29552);r(85231);var p=r(11163),g=r(39332),m=r(22632),y=r(10329),j=r(11719),f=r(51800),v=r(74293),b=r(94543),N=r(48583),w=r(79965),_=r(91132),S=r(99034),k=r(86501),C=r(88446);r(83868);var q=r(70372),Z=r(30660),G=r(9008),F=r.n(G),A=r(76648),D=r(7023),I=r(88754),P=r(13415),O=r(93729),T=r(92879);r(58639);var L=e=>{var s;let{item:r}=e,[i,c]=(0,l.useState)(0),[o,d]=(0,l.useState)(!1);if(!(null==r?void 0:r.imagesArr)||!Array.isArray(r.imagesArr))return null;let x=(null!==(s=null==r?void 0:r.type)&&void 0!==s?s:1)===1?3e3:parseInt(null==r?void 0:r.code.toString().slice(0,4)),u=r.imagesArr.map((e,s)=>"".concat(h.Z.CDN_URL_PUBLIC,"/uploads/l/").concat(x,"/").concat(null==r?void 0:r.code).concat(s+1,"3.jpg"));return(0,t.jsxs)("div",{children:[(0,t.jsx)("div",{className:"absolute top-1 right-1",children:(0,t.jsx)(n.G,{icon:a.TL5,onClick:()=>d(!0)})}),o&&(0,t.jsx)(T.Z,{mainSrc:u[i],nextSrc:u[(i+1)%u.length],prevSrc:u[(i+u.length-1)%u.length],onCloseRequest:()=>d(!1),onMovePrevRequest:()=>c((i+u.length-1)%u.length),onMoveNextRequest:()=>c((i+1)%u.length)})]})},E=!0,U=e=>{var s,r,x,G,T,E,U,z,R,K;let{productListServer:B,productCategoryHPfilter:M,productCategoryNav:Y,productHP:V,productTotalCount:H,serverPageNo:Q,serverPerPage:J,serverOrderBy:W,serverSearchKeyword:X,serverSearchSKU:$,productDataStatus:ee,categoryHeadData:es,relatedCategoryProducts:er,show_more:et,eshopRandomProductShowBtnThisWeek:el}=e,en=(0,p.useRouter)(),ea=(0,g.usePathname)(),ei=(0,N.Dv)(b.ZP),ec=(0,N.Dv)(q.Z),eo=(0,N.b9)(q.Z),[ed,ex]=(0,l.useState)([]),[eu,eh]=(0,l.useState)(en.query.view),[ep,eg]=(0,l.useState)(""),[em,ey]=(0,l.useState)(""),[ej,ef]=(0,l.useState)(""),[ev,eb]=(0,l.useState)(1),[eN,ew]=(0,l.useState)(1),[e_,eS]=(0,l.useState)([]),[ek,eC]=(0,l.useState)(-1),[eq,eZ]=(0,l.useState)({loading:!1,success:"",error:""}),[eG,eF]=(0,l.useState)({loading:!1,success:"",error:""}),[eA,eD]=(0,l.useState)(!1),[eI,eP]=(0,l.useState)({code:0,email:"",comment:"",LotNum:0,type:0,auction_no:0}),[eO,eT]=(0,l.useState)({code:"",email:"",comment:""}),[eL,eE]=(0,l.useState)({loading:!1,success:"",error:""}),[eU,ez]=(0,l.useState)(""),[eR,eK]=(0,l.useState)(""),[eB,eM]=(0,l.useState)("");(0,l.useEffect)(()=>{eM(window.location.href)},[en]);let eY="e-shop";(0,l.useRef)(null);let eV=async e=>{try{var s,r,t;eZ({loading:!0,success:"",error:""});let l=await C.Z.post("/e-Shop-product/addToNotify",{code:e});l&&(null==l?void 0:null===(s=l.data)||void 0===s?void 0:s.status)===!0?k.ZP.success(null==l?void 0:null===(r=l.data)||void 0===r?void 0:r.data):k.ZP.error(null==l?void 0:null===(t=l.data)||void 0===t?void 0:t.data),eZ({loading:!1,success:"success",error:""})}catch(e){console.error(e),k.ZP.error("you need to login to continue..."),en.push("/login"),eZ({loading:!1,success:"error",error:""})}},eH=async()=>{try{var e;eF({loading:!0,success:"",error:""});let s=await C.Z.get("/user/viewuser");eC(null==s?void 0:null===(e=s.data)||void 0===e?void 0:e.id),eF({loading:!1,success:"success",error:""})}catch(e){console.error(e),eF({loading:!1,success:"error",error:""})}};(0,l.useEffect)(()=>{ex(B)},[B]),(0,l.useEffect)(()=>{ss()}),(0,l.useEffect)(()=>{ew(Q)},[Q]),(0,l.useEffect)(()=>{var e;let s="",r="",t=null==(r=null==en?void 0:null===(e=en.query)||void 0===e?void 0:e.sku)?void 0:r.toString();$&&"string"==typeof $&&ef($),(null==t?void 0:t.length)>0&&"string"==typeof t&&ez(r),("string"==typeof(s=X)||""===s)&&ey("")},[$]),(0,l.useEffect)(()=>{let e="";"string"==typeof(e=en.query.q)&&e.length>0&&(ey(e),eK(e))},[X]),(0,l.useEffect)(()=>{let e=async()=>{let e=await (0,w.Z)({user_login_status:ei.isLoggedIn,auction_type:eY});eS(e)};e()},[ed,ei]),(0,l.useEffect)(()=>{eH()},[]);let eQ=e=>{eg(e),navigator.clipboard.writeText(e),eg("")},eJ=(0,_.Z)({current_path:ea,auction_no:-1,type:eY}),eW=en.query,eX=0,e$="";Array.isArray(eW.pid)&&eW.pid.length>0&&("CHP"===(e$=eW.pid[0])?(e$="categoryHP",eX=parseInt(eW.pid[eW.pid.length-1])):"auctionno"!==e$&&"CHP"!==e$&&(e$="category",eX=parseInt(eW.pid[eW.pid.length-1])));let e0=(e,s)=>(0,t.jsx)(t.Fragment,{children:(0,t.jsxs)("span",{className:"",children:["(",Math.abs((e-s)/e*100).toFixed(2),"% Off)"]})}),e2=e=>{if(e>0){ew(e);let s=(0,S.Z)({query:en.query,type:eY}),r={...s,pn:e};en.push({pathname:eJ,query:r})}},e1=()=>{e2(Q+1)},e3=()=>{e2(Q-1)},e4=e=>{eh(e);let s=(0,S.Z)({query:en.query,type:eY}),r={...s,view:e};en.push({pathname:eJ,query:r})},e5=e=>e.length>=60?"".concat(e.substring(0,55)," ..."):e,e7=()=>{let e=Math.ceil(H/J),s=[],r=Q-2<1?1:Q-2,l=Q+2<=e?Q+2:e;s.unshift(...[1,"..."]);for(let t=r;t<=l;t++)t>1&&t<e&&s.push(t);return(0,t.jsx)(t.Fragment,{children:e>1&&(0,t.jsx)("div",{className:"flex xxxs:pb-5",children:(0,t.jsx)("nav",{children:(0,t.jsxs)("ul",{className:"flex -sp
1ace-x-px h-4 text-sm lining-nums",children:[Q>1&&(0,t.jsx)(t.Fragment,{children:(0,t.jsx)("li",{onClick:e3,className:"flex items-center justify-center px-3 h-7 ml-0 leading-tight text-gray-500 bg-white border cursor-pointer border-gray-300 rounded-l-lg hover:bg-gray-100 hover:text-gray-700",children:(0,t.jsx)(n.G,{icon:a.EyR,className:"w-2.5 h-2.5"})})}),s.map(s=>(0,t.jsx)(t.Fragment,{children:s<=e&&(0,t.jsx)("li",{onClick:()=>e2(s),value:s,className:"flex items-center justify-center px-3 h-7 leading-tight cursor-pointer border-gray-300 border ".concat(Q===s?"bg-gray-100 hover:text-gray-700 ":" text-gray-500 bg-white hover:bg-gray-100 hover:text-gray-700 "),children:s},s)})),(0,t.jsx)("li",{onClick:e=>e2(e.target.value),value:e,className:"flex items-center justify-center px-3 h-7 leading-tight cursor-pointer border-gray-300 border ".concat(Q==e?"bg-gray-100 hover:text-gray-700 ":" text-gray-500 bg-white hover:bg-gray-100 hover:text-gray-700 "),children:e}),Q<e&&(0,t.jsx)(t.Fragment,{children:(0,t.jsx)("li",{onClick:e1,className:"flex items-center justify-center px-3 h-7 leading-tight text-gray-500 bg-white border border-gray-300 rounded-r-lg cursor-pointer hover:bg-gray-100 hover:text-gray-700 ",children:(0,t.jsx)(n.G,{icon:a.yOZ,className:"w-2.5 h-2.5"})})})]})})})})},e8="";ei.isLoggedIn||(e8="/login?re_url=".concat(en.asPath));let e9=(e,s)=>{"keyword"===s&&ey(e),"string"==typeof e&&"sku"===s&&ef(e)},e6=(e,s)=>(0,t.jsxs)(t.Fragment,{children:[ei.isLoggedIn&&(0,t.jsxs)(t.Fragment,{children:[("list"===eu||void 0===eu)&&(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(Z.Z,{code:e,page:"e-shop-list-lv",productUrl:s}),(0,t.jsx)(v.Z,{code:e,loginStatus:ei.isLoggedIn,type:1,wishlist_code:e_,auction_type:eY,view_type:eu,pageType:""})]}),"grid"===eu&&(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(Z.Z,{code:e,page:"e-shop-list-gv",productUrl:s}),(0,t.jsx)(v.Z,{code:e,loginStatus:ei.isLoggedIn,type:1,wishlist_code:e_,auction_type:eY,view_type:eu,pageType:""})]})]}),!ei.isLoggedIn&&(0,t.jsxs)(t.Fragment,{children:[("list"===eu||void 0===eu)&&(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(Z.Z,{code:e,page:"e-shop-list-lv",productUrl:s}),(0,t.jsxs)(u(),{href:e8,children:[(0,t.jsx)(n.G,{icon:c.m6i,type:"far",size:"lg",className:"h-4 w-4 cursor-pointer mx-1 focus:outline-none outline-none","data-tooltip-id":"wish-tooltip"}),(0,t.jsx)(d.u,{id:"wish-tooltip",place:"top",content:"Add to Wishlist"})]})]}),"grid"===eu&&(0,t.jsx)(t.Fragment,{children:(0,t.jsxs)("div",{className:"inline-flex",children:[(0,t.jsx)(Z.Z,{code:e,page:"e-shop-list-gv",productUrl:s}),(0,t.jsx)(u(),{href:"".concat(e8),children:(0,t.jsx)("button",{className:"px-2 mt-2 my-2 py-1 inline-flex justify-center gap-2 bg-gray-200 hover:bg-gray-100 border-2 focus:border-gray-200 border-gray-100 rounded",children:(0,t.jsx)("span",{children:(0,t.jsx)(n.G,{icon:c.m6i,className:" h-3 w-3"})})})})]})})]})]}),se=e=>{if("string"==typeof em&&""!==em&&"keyword"===e){let e=em;"string"==typeof em&&(eK(e=em),ez(""));let s=(0,S.Z)({query:en.query,type:eY}),r={...s};delete en.query.sku,delete r.sku;let t=e;r={...s,q:t,pn:1},en.push({pathname:eJ,query:r})}if("string"==typeof ej&&"sku"===e){let e=parseInt(ej);if(!isNaN(e)){let s=(0,S.Z)({query:en.query,type:eY}),r={...s};delete en.query.q,delete r.q;let t=e.toString();ez(t),eK(""),r={...s,sku:t,pn:1},en.push({pathname:eJ,query:r})}}},ss=()=>{let e="",s=0,r="",l=0;return r=en.query.q,l=0,"string"==typeof en.query.sku&&(s=parseInt(en.query.sku)),"object"==typeof V&&Object.keys(V).length>0&&"object"==typeof en.query.pid&&(e=en.query.pid[0]),(0,t.jsx)(t.Fragment,{children:(0,t.jsx)(y.Z,{product_hp:V,product_category_nav:Y,cat_hp_str:e,code:s,search_query:r,auction_no:l,auctiontype:"e-store",type:1})})};return(0,t.jsxs)(l.Fragment,{children:[(0,t.jsxs)(t.Fragment,{children:[es.length>0&&(0,t.jsx)(t.Fragment,{children:(0,t.jsxs)(F(),{children:[(0,t.jsx)("title",{children:null===(s=es[0])||void 0===s?void 0:s.title}),(0,t.jsx)("meta",{name:"description",content:null===(r=es[0])||void 0===r?void 0:r.meta_description}),(0,t.jsx)("meta",{name:"keywords",content:null===(x=es[0])||void 0===x?void 0:x.meta_keyword}),(0,t.jsx)("meta",{name:"og:description",content:D.Z.OG_DESCRIPTION},"ogdescription"),(0,t.jsx)("meta",{property:"og:url",content:D.Z.OG_URL}),(0,t.jsx)("meta",{property:"og:title",content:null===(G=es[0])||void 0===G?void 0:G.t
1itle}),(0,t.jsx)("meta",{property:"og:type",content:D.Z.OG_TYPE},"ogtype"),(0,t.jsx)("meta",{property:"og:image",content:D.Z.OG_IMAGE},"ogimage")]})}),es.length<=0&&Object.keys(V).length<=0&&(0,t.jsx)(t.Fragment,{children:(0,t.jsxs)(F(),{children:[(0,t.jsx)("title",{children:"e-Shop Online auction, Coins Auction in India, Coin Seller, Stamp Seller in India"}),(0,t.jsx)("meta",{name:"description",content:"Auction Coins, Stamps, Bank Notes, Paintings, Antique Jewellery, Autograph, Medals, Tokens, Accessories."}),(0,t.jsx)("meta",{name:"keywords",content:"Online jewellery auction, Live online auctions,Stamps Seller in India, Coins Auction Dealer in India, Coin Seller in India, Online Auction Company, Local online auctions, Online auction sites, Numismatic Exhibition in India, Coin and Stamp Exhibition in India, Antique medals, numismatic Accessories"}),(0,t.jsx)("meta",{name:"og:description",content:D.Z.OG_DESCRIPTION},"ogdescription"),(0,t.jsx)("meta",{property:"og:url",content:D.Z.OG_URL}),(0,t.jsx)("meta",{property:"og:title",content:"e-Shop Online auction, Coins Auction in India, Coin Seller, Stamp Seller in India"}),(0,t.jsx)("meta",{property:"og:type",content:D.Z.OG_TYPE},"ogtype"),(0,t.jsx)("meta",{property:"og:image",content:D.Z.OG_IMAGE},"ogimage")]})}),V.length>0&&(0,t.jsx)(t.Fragment,{children:(0,t.jsxs)(F(),{children:[(0,t.jsx)("title",{children:null===(T=V[0])||void 0===T?void 0:T.category}),(0,t.jsx)("meta",{name:"description",content:null===(E=V[0])||void 0===E?void 0:null===(U=E.metaDetails)||void 0===U?void 0:U.meta_description}),(0,t.jsx)("meta",{name:"keywords",content:null===(z=V[0])||void 0===z?void 0:null===(R=z.metaDetails)||void 0===R?void 0:R.meta_keyword}),(0,t.jsx)("meta",{name:"og:description",content:D.Z.OG_DESCRIPTION},"ogdescription"),(0,t.jsx)("meta",{property:"og:url",content:D.Z.OG_URL}),(0,t.jsx)("meta",{property:"og:title",content:null===(K=V[0])||void 0===K?void 0:K.category}),(0,t.jsx)("meta",{property:"og:type",content:D.Z.OG_TYPE},"ogtype"),(0,t.jsx)("meta",{property:"og:image",content:D.Z.OG_IMAGE},"ogimage")]})})]}),ss(),(0,t.jsx)("section",{className:"md:mx-8 px-3 lg:mx-28 lg:px-0 md:p-0",children:(0,t.jsx)("div",{className:"container mx-auto",children:(0,t.jsxs)("div",{className:"w-full flex md:flex-row xxxs:flex-col gap-2",children:[(0,t.jsxs)("div",{className:"w-full md:w-1/4 lg:w-1/4",children:[(0,t.jsxs)("div",{className:"flex pb-2",children:[(0,t.jsx)(n.G,{icon:a.G_j,size:"lg",className:"h-4 w-4 mt-1"}),(0,t.jsx)("p",{className:"px-2 text-base",children:"Filter & Search "})]}),(0,t.jsxs)("div",{className:"border rounded pb-1",children:[(0,t.jsx)("div",{className:"p-2 bg-gray-100 ",children:"e Store Search"}),(0,t.jsxs)("div",{children:[(0,t.jsx)("div",{className:"p-2 text-sm",children:"Type Any Keywords"}),(0,t.jsx)("div",{className:"px-1",children:(0,t.jsxs)("div",{className:" flex rounded-md",children:[(0,t.jsx)("input",{type:"text",onChange:e=>e9(e.target.value,"keyword"),value:em,placeholder:"Type any keywords",className:"p-2 block w-full border-2 border-gray-100 outline-none rounded-l-md text-xs focus:border-gray-200 "}),(0,t.jsx)("button",{type:"button",onClick:()=>se("keyword"),className:"p-1 inline-flex flex-shrink-0 justify-center items-center rounded-r-md border-1 bg-gray-200 text-black hover:bg-gray-300 focus:outline-none focus:ring-2 focus:ring-gray-300",children:"Search"})]})})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)("div",{className:"p-2 text-sm",children:"Search SKU"}),(0,t.jsx)("div",{className:"px-1",children:(0,t.jsxs)("div",{className:" flex rounded-md",children:[(0,t.jsx)("input",{type:"text",value:ej,onChange:e=>e9(e.target.value,"sku"),placeholder:"Search SKU",className:"p-2 block w-full border-2 border-gray-100 outline-none rounded-l-md text-xs focus:border-gray-200"}),(0,t.jsx)("button",{type:"button",onClick:()=>se("sku"),className:"p-1 inline-flex flex-shrink-0 justify-center placeholder-[] items-center rounded-r-md border-1 bg-gray-200 text-black hover:bg-gray-300 focus:outline-none focus:ring-2 focus:ring-gray-300",children:"Search"})]})})]})]}),(0,t.jsx)("div",{className:"pt-2",children:(0,t.jsxs)("div",{className:"border rounded ",children:[(0,t.jsx)("div",{className:"p-2 bg-gray-100",children:"Category"}),(0,t.jsx)("div",{children:(0,t.jsx)(f.Z,{categoryItems:M,auctio_id:-1,id:eX,type:e$,auctionType:"e_store"})})]})})]}),(0,t.jsxs)("div",{className:"w-full lg:w-4/5",children:[(0,t.jsxs)("section",{className:"flex gap-2",children:[(0,t.jsxs)("div",{className:"inline-flex gap-2",children:[(0,t.jsxs)("select",{onChange:e=>{let s=e.target.value,r=(0,S.Z)({query:en.query,type:eY}),t={...r,sortby:s,pn:1};en.push({pathname:eJ,query:t})},className:"p-1 h-7 text-gray-600 border-gray-200 border-2 rounded-md outline-none focus:border-gray-100",children:[(0,t.jsxs)("option",{value:"",className:" hidden",children:["Order By"," "]}),[{label:"A-Z",value:"a-z"},{label:"Z-A",value:"z-a"},{label:"Newest Lot",value:"nl"},{label:"Popular Lot",value:"pl"},{label:"Price: Low to High",value:"l-h"},{label:"Price: High to Low",value:"h-l"}].map(e=>(0,t.jsx)("option",{value:e.value,selected:e.value===W,children:e.label},e.value))]}),(0,t.jsx)(o.qY1,{className:"w-5 h-5 cursor-pointer outline-none","data-tooltip-id":"grid-tooltip",onClick:()=>e4("grid")}),(0,t.jsx)(d.u,{id:"grid-tooltip",place:"top",content:"grid"}),(0,t.jsx)(n.G,{icon:a.Zrf,size:"lg",className:"w-5 h-5 cursor-pointer outline-none",onClick:()=>e4("list"),"data-tooltip-id":"list-tooltip"}),(0,t.jsx)(d.u,{id:"list-tooltip",place:"top",content:"list"})]}),(0,t.jsxs)("div",{className:"flex lg:flex-row gap-2 xxxs:flex-col xs:flex-row xs:ml-auto md:flex-row xxs:ml-auto",children:[(0,t.jsxs)("div",{className:" inline-flex rounded-md ",children:[(0,t.jsx)("button",{type:"button",className:"p-1 inline-flex flex-shrink-0 justify-center items-center rounded-l-md border-1 bg-gray-200 text-black focus:outline-none ",children:"Page #"}),(0,t.jsx)("input",{type:"number",value:eN,onChange:e=>{let s=parseInt(e.target.value),r=Math.ceil(H/J);eb(r),"number"==typeof s&&(s>r?ew(1):ew(s))},min:1,className:"p-1 block lg:w-10 xxxs:w-8 border-2 border-gray-100 outline-none text-xs focus:border-gray-200"}),(0,t.jsx)("button",{type:"button",onClick:()=>{e2(eN)},className:"p-1 px-3 inline-flex flex-shrink-0 justify-center items-center rounded-r-md border-1 bg-gray-200 text-black hover:bg-gray-300 focus:outline-none focus:ring-2 focus:ring-gray-300",children:(0,t.jsx)(n.G,{icon:a.wn1,size:"sm"})})]}),(0,t.jsxs)("select",{className:"p-1 text-gray-600 border-gray-200 border-2 rounded-md outline-none focus:border-gray-100",onChange:e=>{let s=e.target.value,r=(0,S.Z)({query:en.query,type:eY}),t={...r,pn:1,perpage:s};en.push({pathname:eJ,query:t})},value:J>=10?J:"",children:[(0,t.jsxs)("option",{value:"",className:"selected hidden",children:["Page No"," "]}),(0,t.jsx)("option",{value:"10",children:"10"}),(0,t.jsx)("option",{value:"20",children:"20"}),(0,t.jsx)("option",{value:"25",children:"25"}),(0,t.jsx)("option",{value:"30",children:"30"}),(0,t.jsx)("option",{value:"40",children:"40"}),(0,t.jsx)("option",{value:"50",children:"50"}),(0,t.jsx)("option",{value:"100",children:"100"})]})]})]}),(0,t.jsxs)("section",{className:"",children:[(0,t.jsxs)("div",{className:"lg:flex lg:flex-row lg:justify-between md:flex md:flex-row md:justify-between xs:flex xs:flex-row xs:justify-between pt-2 ",children:[(0,t.jsxs)("div",{className:"flex flex-col",children:[(0,t.jsx)("div",{children:(0,t.jsxs)("h3",{className:"font-semibold py-2 lining-nums",children:["Total Records # ",H]})}),eU.length>0||eR.length>0?(0,t.jsxs)("div",{className:"flex flex-row items-center justify-center gap-x-3 bg-gray-200 py-2 px-2 rounded-sm",children:[(0,t.jsx)("h3",{children:eU.length>0&&"SKU: ".concat(eU)}),(0,t.jsx)("h3",{children:eR.length>0&&"Keyword: ".concat(eR)}),eU.length>0||eR.length>0?(0,t.jsx)(i.nA2,{onClick:()=>{try{let e=window.location.href;if(eR.length>0){let s=e.indexOf("?"),r=e.slice(0,s);eK(""),ez(""),en.push(r)}if(eU.length>0){let s=e.indexOf("?"),r=e.slice(0,s);eK(""),ez(""),en.push(r)}}catch(e){console.log(e)}},className:"cursor-pointer"}):""]}):""]}),e7()]}),(()=>{let[e,s]=(0,l.useState)(!1),r=e=>{try{let s=ec.some(s=>s.code===e);return s}catch(e){return console.error(e),!1}},i=async(e,s)=>{try{if(ei.isLoggedIn){var r,t;let l=async e=>{try{let s=await C.Z.post("/product-cart/getCartDetails",e),r=s.data.data;eo(r)}catch(e){console.error(e)}},n=await C.Z.post("/product-cart/getCartDetails",{page_enabled:"y",page:1,limit:100,sortDetails:{sort
1Key:"id",sortType:1},searchDetails:[],searchDetailsAnd:[{basicSearchKey:"code",basicSearchValue:e,basicSearchType:"number"},{basicSearchKey:"status",basicSearchValue:-1,basicSearchType:"number"}],searchQuery:""});if((null==n?void 0:null===(r=n.data)||void 0===r?void 0:null===(t=r.data)||void 0===t?void 0:t.length)>0){let r=await C.Z.post("/product-cart/updateCartStatus",{code:e,typeOfFunction:0});"add"===s?k.ZP.success("Product is added to the cart"):"buy_now"===s&&en.push("/checkout"),200===r.status&&l({page_enabled:"y",page:1,limit:100,sortDetails:{sortKey:"id",sortType:1},searchDetails:[],searchDetailsAnd:[{basicSearchKey:"status",basicSearchValue:0,basicSearchType:"number"}],searchQuery:""})}else{let r=await C.Z.post("/product-cart/addToCart",{code:e},{headers:{frontendurl:eB||""}});"add"===s?!0===r.data.data.status?(0,O.Z)({type:"success",msg:r.data.data.msg}):!1===r.data.data.status&&(0,O.Z)({type:"error",msg:r.data.data.msg}):"buy_now"===s&&en.push("/checkout"),200===r.status&&l({page_enabled:"y",page:1,limit:100,sortDetails:{sortKey:"id",sortType:1},searchDetails:[],searchDetailsAnd:[{basicSearchKey:"status",basicSearchValue:0,basicSearchType:"number"}],searchQuery:""})}eE({loading:!1,success:"success",error:""})}else localStorage.setItem("pendingProductCode",e.toString()),en.push("/login?re_url=".concat(en.asPath))}catch(e){eE({loading:!1,success:"error",error:""})}};return(0,t.jsx)(t.Fragment,{children:(0,t.jsxs)("div",{className:"".concat("list"===eu||void 0===eu?"md:flex-row xxxs:flex-col":"grid lg:grid-cols-3 md:grid-cols-2 gap-1 w-full"),children:[null==ed?void 0:ed.map((e,s)=>{var l,o;let x=(0,m.Z)({category:[e.category1Details,e.category2Details,e.category3Details,e.category4Details,e.category5Details],title:e.title,auction:0,code:e.code,auctiontype:"e-shop",type:1,isLive:0}),p=(0,j.Z)({category:[e.category1Details,e.category2Details,e.category3Details,e.category4Details,e.category5Details],type:eY}),g=null==e?void 0:e.imagesArr;return(0,t.jsxs)(t.Fragment,{children:["grid"===eu&&(0,t.jsx)(t.Fragment,{children:(0,t.jsxs)("div",{className:"border-2 ",children:[(0,t.jsx)("div",{className:"",children:(0,t.jsxs)("div",{className:"flex justify-between p-2 bg-gray-100 w-full border-b-2",children:[(0,t.jsx)("h6",{className:"text-xs font-semibold",children:(0,t.jsxs)("h1",{className:"text-sm font-semibold",children:[(0,t.jsx)("span",{className:"",children:"SKU #"}),(0,t.jsx)(u(),{href:x,children:(0,t.jsx)("span",{className:"lining-nums pl-2",children:e.code})})]})}),(0,t.jsx)("div",{className:"flex",children:(0,t.jsxs)("div",{className:"float-right",children:["grid"!==eu&&(0,t.jsx)(t.Fragment,{children:e6(null==e?void 0:e.code,x)}),(0,t.jsx)(n.G,{icon:a.Mdf,size:"lg",className:"cursor-pointer mx-1 outline-none focus:outline-none h-4 w-4 ","data-tooltip-id":"view-tooltip"}),(0,t.jsx)("span",{className:"lining-nums",children:e.view}),(0,t.jsx)(d.u,{id:"view-tooltip",place:"top",content:"No of Views"})]})})]})}),(0,t.jsxs)("div",{className:"flex flex-row items-center justify-around xxxs:flex-row md:max-w-xl relative",children:[(0,t.jsx)(L,{item:e}),(0,t.jsx)(u(),{href:x,className:"flex flex-row space-x-4",children:null===(l=null==g?void 0:g.slice(0,g.length>1?2:1))||void 0===l?void 0:l.map((e,s)=>(0,t.jsx)("div",{className:"flex",children:(0,t.jsx)("img",{src:"".concat(h.Z.CDN_URL_PUBLIC,"/uploads/o/3000/").concat(e),className:"object-contain md:h-30 lg:h-40 w-full"},s)}))})]}),(0,t.jsx)("div",{className:" w-full border-t-2 h-18",children:(0,t.jsx)("div",{className:"flex justify-between p-2 lining-nums",children:(0,t.jsx)(u(),{href:x,children:(0,t.jsx)("h6",{className:"text-xs ",children:e5(e.title)})})})}),(0,t.jsx)("div",{children:(0,t.jsxs)("div",{className:"pt-1 px-2",children:[(0,t.jsx)("div",{className:"",children:e.discount_price>0&&e.discount_price!==e.eshop_price&&e.quantity>0?(0,t.jsxs)(t.Fragment,{children:[(0,t.jsxs)("div",{className:"text-center",children:[(0,t.jsx)(n.G,{icon:a.sph,size:"lg",className:"h-4 w-4 "}),(0,t.jsx)("span",{className:"lining-nums text-lg",children:(0,t.jsx)("span",{className:"text-red-700",children:(0,I.b)(e.discount_price)})})]}),(0,t.jsxs)("div",{className:"text-center",children:[(0,t.jsxs)("span",{className:"text-gray-500",children:[(0,t.jsx)(n.G,{icon:a.sph,size:"sm",className:"h-3 w-3 "}),(0,t.jsx)("span",{className:"lining-nums line-through ",children:(0,I.b)(e.eshop_price)})]}),(0,t.jsx)("span",{className:"lining-nums px-2",children:(0,I.b)(e0(e.eshop_price,e.discount_price))})]})]}):(0,t.jsx)(t.Fragment,{children:e.quantity>0&&e.eshop_price>0&&(0,t.jsx)(t.Fragment,{children:(0,t.jsxs)("div",{className:"text-center",children:[(0,t.jsx)(n.G,{icon:a.sph,size:"lg",className:"h-4 w-4 "}),(0,t.jsx)("span",{className:"lining-nums text-lg",children:(0,t.jsx)("span",{className:"text-red-700",children:(0,I.b)(e.eshop_price)})})]})})})}),(0,t.jsx)("div",{className:"text-center",children:(0,t.jsxs)("div",{className:"inline-flex",children:["grid"===eu&&(0,t.jsx)(t.Fragment,{children:(0,t.jsxs)(t.Fragment,{children:[0===e.quantity&&(0,t.jsx)(t.Fragment,{children:(0,t.jsx)("button",{className:"px-3 mt-2 my-2 py-1 inline-flex justify-center gap-2 bg-gray-200 hover:bg-gray-100 border-2 focus:border-gray-200 border-gray-100 rounded",children:(0,t.jsx)("span",{children:(0,t.jsx)(n.G,{icon:a.qmU,className:"m h-3 w-3"})})})}),e.quantity>0&&e.eshop_price>0&&(0,t.jsxs)(t.Fragment,{children:[e.quantity>0&&r(e.code)&&(0,t.jsx)("button",{className:"px-3 mt-2 my-2 py-1 inline-flex justify-center gap-2 bg-gray-200 hover:bg-gray-100 border-2 focus:border-gray-200 border-gray-100 rounded",children:(0,t.jsxs)("span",{children:[(0,t.jsx)(n.G,{icon:a.bMA,className:"m h-3 w-3"}),(0,t.jsx)(d.u,{id:"Already-in-Cart",place:"top",content:"Already in Cart"})]})}),!r(e.code)&&(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)("button",{onClick:()=>i(null==e?void 0:e.code,"add"),className:"px-3 mt-2 my-2 py-1 inline-flex justify-center gap-2 bg-gray-200 hover:bg-gray-100 border-2 focus:border-gray-200 border-gray-100 rounded",children:(0,t.jsxs)("span",{children:[(0,t.jsx)(n.G,{icon:a.yYj,className:"m h-3 w-3"}),(0,t.jsx)(d.u,{id:"Add-to-Cart",place:"top",content:"Add to cart"})]})}),(0,t.jsx)("button",{onClick:()=>i(null==e?void 0:e.code,"buy_now"),className:"px-2 mt-2 my-2 py-1 inline-flex justify-center gap-2 bg-gray-200 hover:bg-gray-100 border-2 focus:border-gray-200 border-gray-100 rounded",children:(0,t.jsxs)("span",{children:[(0,t.jsx)(n.G,{icon:a.Diu,className:" h-3 w-3 pr-2"}),"Buy Now"]})})]})]})]})}),e6(e.code,x)]})})]})})]},s)}),("list"===eu||void 0===eu)&&(0,t.jsxs)("div",{className:"md:flex-row flex border-2 rounded mt-1 xxxs:flex-col",children:[(0,t.jsxs)("div",{className:"lg:w-[23%] p-1 md:border-r-2 xxxs:border-0",children:[(0,t.jsxs)("div",{className:"flex flex-row items-center justify-around xxxs:flex-row md:max-w-xl relative",children:[(0,t.jsx)(L,{item:e}),(0,t.jsx)(u(),{href:x,className:"flex flex-row space-x-4",children:null===(o=null==g?void 0:g.slice(0,g.length>1?2:1))||void 0===o?void 0:o.map((e,s)=>(0,t.jsx)("div",{className:"flex",children:(0,t.jsx)("img",{src:"".concat(h.Z.CDN_URL_PUBLIC,"/uploads/o/3000/").concat(e),className:"object-contain md:h-30 lg:h-40 w-full"},s)}))})]}),(0,t.jsx)("div",{className:"text-center",children:(0,t.jsx)(u(),{href:x,children:(0,t.jsxs)("button",{className:"px-2 w-full py-1 flex justify-center gap-2 bg-gray-200 hover:bg-gray-100 border-2 focus:border-gray-200 border-gray-100 rounded ",children:[(0,t.jsx)("span",{children:(0,t.jsx)(n.G,{icon:a.nNP})}),"Read more"]})})})]}),(0,t.jsx)("div",{className:"lg:w-[54%] md:w-full lg:border-r-2 xxxs:border-0",children:(0,t.jsxs)("div",{className:"px-2 pt-1",children:[(0,t.jsxs)("div",{className:"flex justify-between",children:[(0,t.jsxs)("div",{className:"float-left inline-flex",children:[(0,t.jsxs)("h1",{className:"text-sm font-semibold",children:["SKU #",(0,t.jsx)(u(),{href:x,children:(0,t.jsx)("span",{className:"lining-nums pl-2",children:e.code})})]}),(0,t.jsxs)("span",{children:[(0,t.jsx)(n.G,{icon:c.zcJ,size:"sm",className:"mt-1 mx-1 cursor-pointer outline-none focus:outline-none","data-tooltip-id":"copy-tooltip",onClick:()=>eQ(null==e?void 0:e.code)}),(0,t.jsx)(d.u,{id:"copy-tooltip",place:"top",content:"Copy SKU No"})]})]}),(0,t.jsx)("div",{className:"flex",children:(0,t.jsxs)("div",{className:"float-right",children:[e6(e.code,x),(0,t.jsx)(n.G,{icon:a.Mdf,size:"lg",className:"cursor-pointer mx-1 outline-none focus:outline-none h-4 w-4 ","data-tooltip-id":"view-tooltip"}),(0,t.jsx)("span",{className:"lining-nums",children:e.view}),(0,t.jsx)(d.u,{id:"view-tooltip",place:"top",content:"No of Views"})]})})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)("div",{className:" text-gray-500 pt-3",children:p}),(0,t.jsx)("div",{className:"pt-2",children:(0,t.jsx)("div",{className:"text-base lining-nums",children:(0,t.jsx)(u(),{href:x,children:(0,t.jsx)("p",{children:e.title})})})})]}),(0,t.jsxs)("div",{className:"pt-1 px-2 xxxs:hidden lg:hidden md:block",children:[(0,t.jsx)("div",{className:"flex",children:e.discount_price>0&&e.discount_price!==e.eshop_price&&e.quantity>0?(0,t.jsxs)(t.Fragment,{children:[(0,t.jsxs)("div",{className:"",children:[(0,t.jsx)(n.G,{icon:a.sph,size:"lg",className:"h-4 w-4 "}),(0,t.jsx)("span",{className:"lining-nums text-lg",children:(0,t.jsx)("span",{className:"text-red-700",children:(0,I.b)(e.discount_price)})})]}),(0,t.jsxs)("div",{className:"pt-1",children:[(0,t.jsxs)("span",{className:"text-gray-500",children:[(0,t.jsx)(n.G,{icon:a.sph,size:"sm",className:"h-3 w-3 "}),(0,t.jsx)("span",{className:"lining-nums line-through ",children:(0,I.b)(e.eshop_price)})]}),(0,t.jsx)("span",{className:"lining-nums px-2",children:(0,I.b)(e0(e.eshop_price,e.discount_price))})]})]}):(0,t.jsxs)(t.Fragment,{children:[e.quantity>0&&e.eshop_price>0&&(0,t.jsx)(t.Fragment,{children:(0,t.jsxs)("div",{className:"",children:[(0,t.jsx)(n.G,{icon:a.sph,size:"lg",className:"h-4 w-4 "}),(0,t.jsx)("span",{className:"lining-nums text-lg",children:(0,t.jsx)("span",{className:"text-red-700",children:(0,I.b)(e.eshop_price)})})]})}),0==e.quantity&&(0,t.jsx)(t.Fragment,{children:(0,t.jsx)("div",{className:"mt-auto",children:(0,t.jsxs)("button",{onClick:()=>eV(null==e?void 0:e.code),className:"px-2 mt-2 w-full py-1 inline-flex justify-center gap-2 bg-gray-200 hover:bg-gray-100 border-2 focus:border-gray-200 border-gray-100 rounded ",children:[(0,t.jsx)("span",{children:(0,t.jsx)(n.G,{icon:a.qmU,className:" h-3 w-3"})}),"Click to Notify"]})})})]})}),e.quantity>0&&e.eshop_price>0&&(0,t.jsxs)(t.Fragment,{children:[e.quantity>0&&r(e.code)&&(0,t.jsx)("div",{className:"flex",children:(0,t.jsxs)("button",{className:"px-2 mt-2 my-2 w-full py-1 inline-flex justify-center gap-2 bg-green-400 hover:bg-green-300 border-2 focus:border-gray-200 border-gray-100 rounded ",children:[(0,t.jsx)("span",{children:(0,t.jsx)(n.G,{icon:a.Diu,className:" h-3 w-3"})}),"Already in Cart"]})})," ",!r(e.code)&&(0,t.jsxs)("div",{className:"flex",children:[(0,t.jsxs)("button",{onClick:()=>i(null==e?void 0:e.code,"add"),className:"px-2 mt-2 my-2 w-full py-1 inline-flex justify-center gap-2 bg-gray-200 hover:bg-gray-100 border-2 focus:border-gray-200 border-gray-100 rounded ",children:[(0,t.jsx)("span",{children:(0,t.jsx)(n.G,{icon:a.Diu,className:" h-3 w-3"})}),"Add to Cart"]}),(0,t.jsxs)("button",{onClick:()=>i(null==e?void 0:e.code,"buy_now"),className:"px-2 mt-2 my-2 w-full py-1 inline-flex justify-center gap-2 bg-gray-200 hover:bg-gray-100 border-2 focus:border-gray-200 border-gray-100 rounded ",children:[(0,t.jsx)("span",{children:(0,t.jsx)(n.G,{icon:a.yYj,className:"m h-3 w-3"})}),"Buy Now"]})]})]})]})]})}),(0,t.jsx)("div",{className:"lg:w-[23%] md:w-[19rem] lg:block md:hidden",children:(0,t.jsxs)("div",{className:"pt-1 px-2",children:[(0,t.jsx)("div",{className:"",children:e.discount_price>0&&e.discount_price!==e.eshop_price&&e.quantity>0?(0,t.jsxs)(t.Fragment,{children:[(0,t.jsxs)("div",{className:"text-center",children:[(0,t.jsx)(n.G,{icon:a.sph,size:"lg",className:"h-4 w-4 "}),(0,t.jsx)("span",{className:"lining-nums text-lg",children:(0,t.jsx)("span",{className:"text-red-700",children:(0,I.b)(e.discount_price)})})]}),(0,t.jsxs)("div",{className:"text-center",children:[(0,t.jsxs)("span",{className:"text-gray-500",children:[(0,t.jsx)(n.G,{icon:a.sph,size:"sm",className:"h-3 w-3 "}),(0,t.jsx)("span",{className:"lining-nums line-through ",children:(0,I.b)(e.eshop_price)})]}),(0,t.jsx)("span",{className:"lining-nums px-2",children:(0,I.b)(e0(e.eshop_price,e.discount_price))})]})]}):(0,t.jsxs)(t.Fragment,{children:[e.quantity>0&&e.eshop_price>0&&(0,t.jsx)(t.Fragment,{children:(0,t.jsxs)("div",{className:"text-center",children:[(0,t.jsx)(n.G,{icon:a.sph,size:"lg",className:"h-4 w-4 "}),(0,t.jsx)("span",{className:"lining-nums text-lg",children:(0,t.jsx)("span",{className:"text-red-700",children:(0,I.b)(e.eshop_price)})})]})}),0==e.quantity&&(0,t.jsx)(t.Fragment,{children:(0,t.jsx)("div",{className:"text-center mt-auto",children:(0,t.jsxs)("button",{onClick:()=>eV(null==e?void 0:e.code),className:"px-2 mt-2 w-full py-1 inline-flex justify-center gap-2 bg-gray-200 hover:bg-gray-100 border-2 focus:border-gray-200 border-gray-100 rounded ",children:[(0,t.jsx)("span",{children:(0,t.jsx)(n.G,{icon:a.qmU,className:" h-3 w-3"})}),"Click to Notify"]})})})]})}),e.quantity>0&&e.eshop_price>0&&(0,t.jsxs)(t.Fragment,{children:[e.quantity>0&&r(e.code)&&(0,t.jsxs)("button",{className:"px-2 mt-2 my-2 w-full py-1 inline-flex justify-center gap-2 bg-green-300 hover:bg-green-500 border-2 focus:border-gray-200 border-gray-100 rounded ",children:[(0,t.jsx)("span",{children:(0,t.jsx)(n.G,{icon:a.yYj,className:"m h-3 w-3"})}),"Already in cart"]}),!r(e.code)&&(0,t.jsxs)("div",{className:"",children:[(0,t.jsxs)("button",{onClick:()=>i(null==e?void 0:e.code,"add"),className:"px-2 mt-2 w-full py-1 inline-flex justify-center gap-2 bg-gray-200 hover:bg-gray-100 border-2 focus:border-gray-200 border-gray-100 rounded ",children:[(0,t.jsx)("span",{children:(0,t.jsx)(n.G,{icon:a.Diu,className:" h-3 w-3"})}),"Add to Cart"]}),(0,t.jsxs)("button",{onClick:()=>i(null==e?void 0:e.code,"buy_now"),className:"px-2 mt-2 my-2 w-full py-1 inline-flex justify-center gap-2 bg-gray-200 hover:bg-gray-100 border-2 focus:border-gray-200 border-gray-100 rounded ",children:[(0,t.jsx)("span",{children:(0,t.jsx)(n.G,{icon:a.yYj,className:"m h-3 w-3"})}),"Buy Now"]})]})]})]})})]},e.id)]})}),0===Object.keys(ed).length&&(0,t.jsx)(t.Fragment,{children:(0,t.jsx)("section",{className:"md:mx-8 px-3 lg:mx-28 lg:px-0 md:p-0",children:(0,t.jsx)("div",{className:"container mx-auto",children:(0,t.jsx)("div",{className:"w-full flex justify-start items-start md:flex-row xxxs:flex-col",children:(0,t.jsxs)("div",{className:" h-12 flex md:flex-col xxxs:flex-col",children:[(0,t.jsx)("div",{className:"p-3 text-black flex",children:"Sorry, no record found"}),(0,t.jsxs)("div",{className:"flex md:flex-row lg:flex-row xxxs:flex-col gap-x-3 ",children:[(0,t.jsx)(u(),{href:"/e-shop/all-products?viewBy=last_week",children:(0,t.jsx)("button",{className:"border p-1 text-gray-400 shadow-md",children:"Last week"})}),(0,t.jsx)(u(),{href:"/e-shop/all-products?viewBy=this_week",children:(0,t.jsx)("button",{className:"border p-1 text-gray-400 shadow-md",children:"This week"})}),(0,t.jsx)(u(),{href:"/e-shop/all-products?viewBy=this_month",children:(0,t.jsx)("button",{className:"border p-1 text-gray-400 shadow-md",children:"This month"})}),(0,t.jsx)(u(),{href:"/e-shop/all-products",children:(0,t.jsx)("button",{className:"border p-1 text-gray-400 shadow-md",children:"All products"})})]})]})})})})})]})})})(),(0,t.jsxs)("div",{className:"flex items-end justify-end mt-2 ",children:[" ",e7()]}),er.length>0&&(0,t.jsx)(t.Fragment,{children:(0,t.jsx)("section",{className:"mt-2",children:(0,t.jsx)("div",{className:"container mx-auto",children:(0,t.jsx)(P.Z,{relatedCategoryProducts:er,auctionType:"e-shop",page:"list",show_more:et,eshopRandomProductShowBtnThisWeek:el})})})}),(0,t.jsx)(A.Z,{})]})]})]})})})]})}}}]);
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.