PageSourceSearch

https://www.medikabazaar.ae/_next/static/chunks/pages/checkout/[id]/processing-c198dde6e6-61b8e182345a2d28.js

js medikabazaar.ae collected 2026-09-24 14:09:09 UTC 6,490 bytes, 1 lines download raw bytes

1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[4750],{8007:function(e,t,s){(window.__NEXT_P=window.__NEXT_P||[]).push(["/checkout/[id]/processing",function(){return s(36851)}])},79586:function(e,t,s){"use strict";var n=s(85893),a=s(733),i=s.n(a),o=s(57851);let r=e=>{let t="",s="#2A4689",a="";e.outline?(t+="bg-[#fff] ",a="#EC6303",e.secondary?(t+="border-[".concat(s,"] text-[").concat(s,"] "),a="#182A54"):t+=e.color?"border-[".concat(e.color,"] text-[").concat(e.color,"] "):"border-orange text-orange ",e.noborder?t+="border-0 ":t+="border "):(a="#fff",t+="text-[#fff] ",e.secondary?t+="bg-[".concat(s,"] "):t+=e.color?"bg-[".concat(e.color,"] "):"bg-orange ",t+="border-0 ");let r=e.paddingClasses||"p-2",l=e.disabled||e.loading,c=e.textClasses||"text-sm font-semibold",d=e.width||"w-full",u=e.height||"h-full",m={};return(null==e?void 0:e.color)&&(m={borderColor:null==e?void 0:e.color},m=(null==e?void 0:e.outline)?{...m,color:null==e?void 0:e.color}:{...m,backgroundColor:null==e?void 0:e.color}),(0,n.jsx)("button",{"aria-label":e.ariaLabel||e.children||"button",type:e.type||"button",className:(0,o.m)("flex justify-center items-center",t,r,e.rounded?"rounded":"",c,d,u,e.extraClasses||""),onClick:e.onClick,disabled:l,id:e.id,style:{...m,...e.additionalStyles},children:e.loading?(0,n.jsx)("div",{className:"relative h-2/3 aspect-square",children:(0,n.jsx)(i(),{type:"bars",width:"100%",height:"100%",color:a})}):e.children})};t.Z=r},41686:function(e,t,s){"use strict";var n=s(85893),a=s(65478);let i=e=>{let{height:t,width:s}=e,i=e.isLoading;return i?(0,n.jsx)("div",{children:(0,n.jsx)("div",{className:"".concat(t," ").concat(s," text-[#444] bg-[#fff] fixed inset-0 z-[1000] flex items-center justify-center text-sm text-center lg:text-xl font-600"),children:(0,n.jsxs)("div",{children:[(0,n.jsx)(a.hU,{src:"/New/Logomark.png",className:"mx-auto w-full h-auto mb-3 lg:mb-7 max-w-[3.13rem] lg:max-w-[6.25rem] animate-spin",alt:"loader"}),(0,n.jsx)("p",{children:"Largest Marketplace For Medical Supplies"})]})})}):null};t.Z=i},24272:function(e,t,s){"use strict";s.d(t,{Y:function(){return o}});var n=s(72074),a=s(18853),i=s(45785);async function o(e,t){var s;let o=[],r=[];for(let t of e.items)o.push({item_id:t.sku_id,item_name:t.title,discount:t.discount,price:t.price,quantity:t.quantity,item_category5:e.business_category}),r.push({sku_id:t.sku_id,product_name:t.title,price:t.price,discount:t.discount,business_category:(null!==(s=t.business_categories)&&void 0!==s?s:[]).join(",")});await (0,i.PY)("purchase",{transaction_id:e.transaction_id,value:e.total,coupon:e.voucher_code,tax:e.tax,items:o}),(0,i.Qp)("Purchase",{content_ids:o.map(e=>e.item_id),content_category:e.business_category,content_name:"order placed",content_type:"product",contents:o.map(e=>({id:e.item_id,quantity:e.quantity})),value:e.total}),(0,n.X2)(a.L.OrderPlaced,{checkout_price:e.total,coupon_name:e.voucher,payment_type:e.transaction_method?e.transaction_method:e.is_cod?"COD":"Not Available",product_details:r,order_id:e.id,checkout_id:t})}},36851:function(e,t,s){"use strict";s.r(t),s.d(t,{default:function(){return g}});var n=s(85893),a=s(67294);let i=a.forwardRef(function({title:e,titleId:t,...s},n){return a.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",strokeWidth:1.5,stroke:"currentColor","aria-hidden":"true",ref:n,"aria-labelledby":t},s),e?a.createElement("title",{id:t},e):null,a.createElement("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M9 12.75L11.25 15 15 9.75M21 12a9 9 0 11-18 0 9 9 0 0118 0z"}))}),o=a.forwardRef(function({title:e,titleId:t,...s},n){return a.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",strokeWidth:1.5,stroke:"currentColor","aria-hidden":"true",ref:n,"aria-labelledby":t},s),e?a.createElement("title",{id:t},e):null,a.createElement("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M9.75 9.75l4.5 4.5m0-4.5l-4.5 4.5M21 12a9 9 0 11-18 0 9 9 0 0118 0z"}))});var r=s(79586),l=s(41686),c=s(65478),d=s(32202),u=s(24272),m=s(11163),h=s(58369),f=s(99571),x=s(72074),p=s(18853);function g(){let e=(0,m.useRouter)(),[t,s]=(0,a.useState)({status:0}),{id:g,txnid:_}=e.query,b=async()=>
1{if(!g)return;let e={checkout_id:g,payment_method:"Online",transaction_id:_};sessionStorage.getItem("landingPageURL")&&(e.landed_page_url=sessionStorage.getItem("landingPageURL"));let t=await (0,h.ck)(f.Mq,"POST",e);(null==t?void 0:t.success)?(s({status:1,orderId:t.order.id}),(0,u.Y)(t.order,g)):(s({status:2,message:t.message}),(0,x.X2)(p.L.PaymentFailed,{checkout_id:g,message:t.message}))};return(0,a.useEffect)(()=>{0!=t.status&&1==t.status&&setTimeout(()=>{e.push("/checkout/".concat(g,"/success/?oid=").concat(t.orderId))},1e3)},[t]),(0,a.useEffect)(()=>{b()},[]),(0,n.jsxs)("div",{className:"min-h-[500px] relative",children:[(0,n.jsxs)("div",{className:"absolute top-0 bottom-0 left-0 right-0 flex items-center justify-center",children:[0==t.status?(0,n.jsxs)("div",{className:"flex flex-col items-center gap-4",children:[(0,n.jsx)("div",{children:(0,n.jsx)(l.Z,{isLoading:!0,height:"h-full",width:"w-full"})}),(0,n.jsx)("div",{children:"Verifying Payment"})]}):null,1==t.status?(0,n.jsxs)("div",{className:"flex flex-col items-center gap-4",children:[(0,n.jsx)(i,{className:"text-[#3A9F4B] h-32 w-32"}),(0,n.jsx)("div",{className:"text-[#3A9F4B]",children:"Payment Successful!"})]}):null]}),(0,n.jsx)("div",{className:"absolute bottom-0 left-0 right-0 flex px-8 py-10 top-16",children:2==t.status&&(0,n.jsxs)("div",{className:"flex flex-col gap-4",children:[(0,n.jsx)(o,{className:"text-[#C65151] h-12 w-12"}),(0,n.jsx)("div",{className:"text-xl font-700",children:"Payment Failed!"}),(0,n.jsx)("div",{className:"font-500 leading-[160%]",children:"There was a problem with your payment attempt. It was failed because of following reason."}),(0,n.jsx)("div",{className:"text-[#DC5035]",children:t.message}),(0,n.jsxs)("div",{className:"flex gap-4",children:[(0,n.jsx)(r.Z,{onClick:()=>{e.push({pathname:"/checkout/".concat(g,"/address/")})},rounded:!0,paddingClasses:"p-4",children:"Try Again"}),(0,n.jsx)(r.Z,{onClick:()=>{e.push("/")},rounded:!0,outline:!0,paddingClasses:"p-4",children:"Go to home"})]}),(0,n.jsx)("span",{children:(0,n.jsx)(c.Gw,{href:d._B,className:"text-[#BCC6E4] text-xs font-semibold",children:"Need Help ?"})})]})})]})}}},function(e){e.O(0,[7851,733,9774,2888,179],function(){return e(e.s=8007)}),_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.