1"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[841],{95016:function(e,a,l){l.r(a),l.d(a,{TabContent:function(){return r},TabProvider:function(){return s}});var n=l(57437);l(2265);var t=l(24792),i=l(29186);let s=e=>(0,n.jsx)(i.Z,{...e,children:e.children}),r=e=>(0,n.jsx)(t.Z,{...e,children:e.children})},49915:function(e,a,l){l.r(a);var n=l(57437),t=l(2265),i=l(18492),s=l(27648),r=l(61418),o=l(73221),d=l(8166),c=l(65113);a.default=e=>{var a,l,m;let u,{isGrtLiveAvailable:h,isEnquiryFormAvailable:f,isEmailMandatory:b,bridesEnquiry:p,children:x}=e,[v,g]=(0,t.useState)(0),y=()=>{g(0)},_=1===v,j=2===v,{moduleStatus:N}=(0,c.CG)(e=>null==e?void 0:e.globalState);return u=f?(0,n.jsx)(o.Ak,{onClick:()=>{var e;return g(h&&(null==N?void 0:null===(e=N.grt_live)||void 0===e?void 0:e.is_enabled)?1:2)},className:"cursor-pointer",children:x}):x,(0,n.jsxs)(n.Fragment,{children:[u,_&&(0,n.jsxs)(i.Z,{centered:!0,className:"storelocator-call-popup brides-enquiry-popup",show:_,onHide:y,children:[(0,n.jsx)(i.Z.Header,{closeButton:!0,children:(0,n.jsx)(i.Z.Title,{children:(0,n.jsx)("div",{children:"Enquiry"})})}),(0,n.jsxs)(i.Z.Body,{children:[(null==N?void 0:null===(a=N.grt_live)||void 0===a?void 0:a.is_enabled)&&(0,n.jsxs)(s.default,{type:"button",target:"_blank",className:"call-button me-2",href:null!==(m=null==N?void 0:null===(l=N.grt_live)||void 0===l?void 0:l.link)&&void 0!==m?m:"",prefetch:!1,children:[" ",(0,n.jsx)("i",{className:"bi bi-camera-reels"}),"GRT Live Video Shopping"]}),(0,n.jsxs)(r.zx,{className:"call-button link-btn me-2",onClick:()=>g(2),children:[(0,n.jsx)("i",{className:"bi bi-geo-alt"})," Showroom Visit"]})]})]}),j&&(0,n.jsx)(d.Z,{status:j,onClose:y,formPayload:p?{is_showroom:!0,enquiry_url:window.location.href}:{},isEmailNotMandatory:!b})]})}},81518:function(e,a,l){l.r(a);var n=l(57437),t=l(2265),i=l(27648),s=l(13786),r=l(68412),o=l(57099);a.default=e=>{let{redirectLink:a,isHandleNetCore:l,payload:d,target:c,rel:m,isSalesAssistEvent:u,children:h}=e,[f,b]=(0,t.useState)(()=>u?{event:o.HA.EVENT,page_name:"",page_url:"",product_name:""}:null);return(0,t.useEffect)(()=>{u&&b({event:o.HA.EVENT,page_name:document.title,page_url:window.location.href,product_name:""})},[u]),a||""===a||u&&null!=a?(0,n.jsx)(i.default,{href:a,className:"text-decoration-none cursor-pointer",...c&&{target:c},...m&&{rel:m},...l&&{onClick:()=>{(0,s.sendGTMEvent)({...d,page_name:document.title,page_url:window.location.href})}},...u&&{onClick:()=>(0,r.qE)(f)},prefetch:!1,children:h}):(0,n.jsx)(n.Fragment,{children:h})}},61924:function(e,a,l){var n=l(57437);l(2265);var t=l(29854),i=l(99376),s=l(65113),r=l(15268),o=l(57099);a.default=e=>{let{configData:a,currencySymbol:l}=e,d=(0,i.useRouter)(),{quoteDetails:c,calculatedDetails:m}=(0,s.CG)(e=>e.digiGoldSlice);return(0,n.jsx)(t.Z,{configData:a,optionsData:o.Jz.buy,currencySymbol:l,onProceed:e=>(0,r.D)({route:"/digi-gold/checkout/buy",router:d,quoteDetails:c,calculatedDetails:m,currencySymbol:l,formValues:e})})}},75229:function(e,a,l){var n=l(57437);l(2265);var t=l(29854),i=l(99376),s=l(65113),r=l(15268),o=l(57099);a.default=e=>{let{configData:a,currencySymbol:l}=e,d=(0,i.useRouter)(),{quoteDetails:c,calculatedDetails:m}=(0,s.CG)(e=>e.digiGoldSlice);return(0,n.jsx)(t.Z,{configData:a,optionsData:o.Jz.sell,currencySymbol:l,onProceed:e=>(0,r.D)({route:"/digi-gold/checkout/sell",router:d,quoteDetails:c,calculatedDetails:m,currencySymbol:l,formValues:e})})}},37513:function(e,a,l){var n=l(57437);l(2265);var t=l(29854),i=l(99376),s=l(65113),r=l(15268),o=l(57099);a.default=e=>{let{configData:a,currencySymbol:l}=e,d=(0,i.useRouter)(),{quoteDetails:c,calculatedDetails:m}=(0,s.CG)(e=>e.digiGoldSlice);return(0,n.jsx)(t.Z,{configData:a,optionsData:o.Jz.transfer,currencySymbol:l,onProceed:e=>(0,r.D)({route:"/digi-gold/checkout/transfer",router:d,quoteDetails:c,calculatedDetails:m,currencySymbol:l,formValues:e})})}},91816:function(e,a,l){var n=l(57437),t=l(2265),i=l(95016),s=l(69714),r=l(65113),o=l(58945),d=l(22532);a.default=e=>{let{children:a}=e,l=(0,r.TL)(),{activeTabkey:c}=(0,r.CG)(e=>e.digiGoldSlice);return(0,t.useEffect)(()=>
1{l((0,o.Oe)("buy"))},[l]),(0,n.jsx)(i.TabProvider,{id:"tab-section",className:"mb-3",defaultActiveKey:"buy",onSelect:e=>{if(e!==c)switch(l((0,o.nV)(o.oO)),l((0,o.$R)(o.Um)),e){case"buy":l((0,o.Oe)(e)),(0,d.k)(s.U2);break;case"sell":l((0,o.Oe)(e)),(0,d.k)(s.IO);break;case"transfer":l((0,o.Oe)(e)),(0,d.k)(s.cs)}},children:a})}},10425:function(e,a,l){l.r(a);var n=l(57437);l(2265);var t=l(73221),i=l(60180),s=l(27648),r=l(38536),o=l(4670),d=l(19555),c=l(49360),m=l(80453),u=l(29139),h=l(90099),f=l(24402),b=l(61418),p=l(57099),x=l(68412),v=l(76353);a.default=e=>{var a;let{title:l,subtitle:g,isTitle:y,additionalFields:_,backgroundColor:j,backgroundImage:N,background:C,buttonLinkText:S,buttonLink:k,banner:w,cssClass:E,header_tag:T}=e,Z=e=>e.map(e=>{let{additionalId:a,title:l,content:t}=e;return(0,n.jsxs)(r.Z.Item,{eventKey:a,children:[(0,n.jsx)(r.Z.Header,{children:l}),(0,n.jsx)(r.Z.Body,{children:(0,n.jsx)("li",{children:(0,n.jsx)(v.y,{verbiage:null!=t?t:""})})})]},a)}),I=e=>(0,n.jsx)(u.Z,{direction:"vertical",gap:2,children:(0,n.jsx)(r.Z,{defaultActiveKey:"0",children:Z(e)})}),P=(0,x.Sp)(T,p.yl),A=l&&"1"===y;return(0,n.jsx)(i.default,{cssClass:E,backgroundColor:j,backgroundImage:N,background:C,children:(0,n.jsx)("section",{className:E,id:"faq",children:(0,n.jsx)(h.default,{children:(0,n.jsxs)(f.default,{className:"justify-between gap-2 gap-md-5",children:[_.length>6&&!w.banner_image?(0,n.jsxs)(n.Fragment,{children:[!E.includes("title-none")&&(0,n.jsxs)("div",{className:"faq-header-block",children:[A&&(0,n.jsx)(P,{className:"fs40-variant2",children:l}),g&&(0,n.jsx)("p",{className:"fs20-variant1",children:g})]}),(0,n.jsxs)(f.default,{className:"justify-between",children:[(0,n.jsx)(o.default,{xs:12,sm:12,md:6,children:I(_.slice(0,Math.ceil(_.length/2)))}),(0,n.jsx)(o.default,{xs:12,sm:12,md:6,children:I(_.slice(Math.ceil(_.length/2)))})]})]}):(0,n.jsxs)(o.default,{xs:12,sm:12,md:7,children:[!E.includes("title-none")&&(0,n.jsxs)("div",{className:"faq-header-block",children:[A&&(0,n.jsx)(P,{className:"fs40-variant2",children:l}),g&&(0,n.jsx)("p",{className:"fs20-variant1",children:g})]}),E.includes("title-none")&&(0,n.jsx)("h3",{children:l}),I(_)]}),w.banner_image&&(0,n.jsx)(o.default,{xs:12,sm:12,md:4,children:(0,n.jsxs)(t.Ak,{className:"card-section",children:[(0,n.jsx)(s.default,{href:(null==w?void 0:w.banner_link)?null==w?void 0:w.banner_link:"#",prefetch:!1,children:(0,n.jsx)(t.xu,{containerClassName:"card-image-section",src:"".concat("https://media.grtjewels.com","/").concat(w.banner_image),className:"w-full",alt:null!==(a=null==w?void 0:w.banner_title)&&void 0!==a?a:l,width:0,height:0,sizes:"(max-width: 768px) 100vw, (max-width: 1200px) 50vw, 33vw",actiontype:"zoom
1-in"})}),(0,n.jsx)(d.Z,{className:"card-body-content",children:(0,n.jsx)("div",{className:"d-flex justify-content-between flex-column",children:w.banner_title&&(0,n.jsx)(c.Z,{children:w.banner_title})})}),S&&(0,n.jsx)(m.Z,{className:"card-btn-section w-100",children:(0,n.jsx)(s.default,{href:null!=k?k:"",prefetch:!1,children:(0,n.jsx)(b.zx,{className:"grt-btn btn--ruby btn--medium",children:S})})})]})})]})})})})}},69125:function(e,a,l){l.r(a);var n=l(57437),t=l(2265),i=l(60180),s=l(73221),r=l(57099),o=l(96440),d=l(90099),c=l(68412),m=l(49915),u=l(81518);let h=e=>{var a;let{title:l,cardInfo:t}=e,i=null!=t&&!!t.class&&(null==t?void 0:t.class.includes("show-enquiry-form")),o=null!=t&&!!t.class&&(null==t?void 0:t.class.includes("show-grt-live")),d=null!=t&&!!t.class&&(null==t?void 0:t.class.includes("target-blank-true")),c=null!=t&&!!t.class&&(null==t?void 0:t.class.includes("enquiry-form-mandatory-email")),h=!(null!=t&&t.class&&(null==t?void 0:t.class.includes("brides-enquiry-false"))),f=null!=t&&!!t.class&&(null==t?void 0:t.class.includes("sales-assist-event"));return(0,n.jsxs)("div",{className:"tab-images",children:[(0,n.jsx)("div",{className:"tab-img",children:(0,n.jsx)(u.default,{redirectLink:t.buttonLink?t.buttonLink:null,...d&&{target:"_blank"},isSalesAssistEvent:f,children:(0,n.jsx)(m.default,{isGrtLiveAvailable:o,isEnquiryFormAvailable:i,isEmailMandatory:c,bridesEnquiry:h,children:(0,n.jsx)(s.xu,{width:"0",height:"0",sizes:"100vw",className:"img-fluid w-full",src:"".concat("https://media.grtjewels.com","/").concat(null==t?void 0:t.image),alt:t.title||l,actiontype:"zoom
1-out"})})})}),t.title&&(null==t?void 0:null===(a=t.title)||void 0===a?void 0:a.toLowerCase())!==r.Yf&&(0,n.jsx)(u.default,{redirectLink:t.buttonLink?t.buttonLink:null,...d&&{target:"_blank"},isSalesAssistEvent:f,children:(0,n.jsx)(m.default,{isGrtLiveAvailable:o,isEnquiryFormAvailable:i,isEmailMandatory:c,bridesEnquiry:h,children:(0,n.jsx)("p",{children:t.title})})})]},null==t?void 0:t.additionalId)};a.default=e=>{var a,l,s;let{title:m,tabItems:u,cssClass:f,header_tag:b}=e,[p,x]=(0,t.useState)({title:null===(a=u[0])||void 0===a?void 0:a.tabTitle,backgroundColor:null===(l=u[0])||void 0===l?void 0:l.backgroundColor,backgroundImage:null===(s=u[0])||void 0===s?void 0:s.backgroundImage}),v=(0,c.Sp)(b,r.yl);return(0,t.useEffect)(()=>{if((null==u?void 0:u.length)>0){var e;let a=null==u?void 0:u.find(e=>{var a;return(null==e?void 0:null===(a=e.additionalFields)||void 0===a?void 0:a.length)>0});a&&(null===(e=Object.keys(a))||void 0===e?void 0:e.length)>0&&x({title:null==a?void 0:a.tabTitle,backgroundColor:null==a?void 0:a.backgroundColor,backgroundImage:null==a?void 0:a.backgroundImage})}},[u]),(0,n.jsx)(i.default,{cssClass:f,backgroundColor:null==p?void 0:p.backgroundColor,backgroundImage:null==p?void 0:p.backgroundImage,children:(0,n.jsx)("section",{className:f,children:(0,n.jsxs)(d.default,{children:[(0,n.jsx)("header",{className:"text-center",children:m&&(0,n.jsx)(v,{className:"tms-header",children:m})}),(0,n.jsxs)("section",{className:"grt-tab-section",children:[(0,n.jsx)("nav",{className:"grt-nav-tabs",children:null==u?void 0:u.map(e=>{var a;return(null===(a=e.additionalFields)||void 0===a?void 0:a.length)>0&&(0,n.jsx)(o.default,{className:"grt-btn btn--outline btn--medium ".concat((null==p?void 0:p.title)===e.tabTitle?"active":""),handleClick:()=>{x({title:e.tabTitle,backgroundColor:null==e?void 0:e.backgroundColor,backgroundImage:null==e?void 0:e.backgroundImage})},children:e.tabTitle},null==e?void 0:e.tabTitle)})}),(0,n.jsx)("div",{className:"tab-contents",children:null==u?void 0:u.map(e=>{if((null==p?void 0:p.title)===e.tabTitle){var a;return null===(a=e.additionalFields)||void 0===a?void 0:a.map(e=>(0,n.jsx)(h,{title:m,cardInfo:e},null==e?void 0:e.additionalId))}})})]})]})})})}},66920:function(e,a,l){l.d(a,{default:function(){return U}});var n=l(57437),t=l(65113),i=l(2265),s=l(99376),r=l(84773),o=l(74402),d=l(34370),c=l(90099),m=l(24402),u=l(4670),h=l(38281),f=l(54834),b=l(29501),p=l(13590),x=l(61006),v=l(68142),g=l(65582);let y={button:{submit:{className:"grt-btn btn--ruby btn--large mx-md-0 mx-auto no-shrink ",text:"Proceed to next step",colmatrix:{md:12}},additionalButton:{className:"grt-btn btn--ruby btn--large no-shrink",text:"Save and continue",colmatrix:{xs:12,md:12}}},fields:[{fieldType:"text",name:"firstname",maxLength:50,placeholder:"First Name*",className:"input-field",conatinerClassName:"form-field",colmatrix:{xs:12,md:6}},{fieldType:"text",name:"lastname",maxLength:50,placeholder:"Last Name*",className:"input-field",conatinerClassName:"form-field",colmatrix:{xs:12,md:6}},{fieldType:"tel",name:"mobile",maxLength:10,placeholder:"Mobile*",className:"input-field",conatinerClassName:"form-field",colmatrix:{xs:12,md:6}},{fieldType:"email",name:"email",maxLength:50,placeholder:"Email ID*",className:"input-field",conatinerClassName:"form-field",colmatrix:{xs:12,md:6}},{fieldType:"address",name:"address",className:"user-address-card",conatinerClassName:"none",colmatrix:{xs:12,md:12}}]};var _=l(45061),j=l(70019),N=l(78361),C=l(66507),S=l(83142),k=l(69714),w=l(68412);let E={userDetails:0,schemeDetails:1,additionalInformation:2};var T=e=>{let{currentValues:a,previousValues:l,formName:n}=e,[s,r]=(0,i.useState)(!1),{stepperCount:o,lastVisitedStepperIndex:c}=(0,t.CG)(e=>e.savingSchemeSlice),m=(0,t.TL)(),u=(e,a)=>Object.keys(e).some(l=>e[l]!==a[l]);return(0,i.useEffect)(()=>{(0,w.kQ)(l)&&c>o&&(u(a,l)?(r(!0),m((0,d.VK)(E[n]))):r(!1))},[a,l,c,o,n,m]),{showSaveAndContinue:s}},Z=l(30963),I=()=>{let[e,a]=(0,i.useState)(!1),[l,s]=(0,i.useState)(!0),[r,o]=(0,i.useState)(!1),[m,u]=(0,i.useState)(null),h=(0,t.TL)(),{userDetailFormData:f,trackPreviousStepperIndex:E}=(0,t.CG)(e=>e.savingSchemeSlice),{data:I,isLoading:P}=(0,x.u)(k.bu,S.SU,{revalidateOnFocus:!1,shouldRetryOnError:!1}),{trigger:A,isMutating:L}=(0,g.Z)("saving-scheme/mobile/authentication",S.rT),D=(0,i.useMemo)(()=>{try{if((null==f?void 0:f.firstname)!==""){let{firstname:e,lastname:a,email:l,mobile:n,address:t}=f;return{firstname:e,lastname:a,email:l,address:t,mobile:n}}if((null==I?void 0:I.error)||(null==I?void 0:I.status)==="error")return{firstname:"",lastname:"",email:"",address:"",mobile:""};{var e;let{data:a}=I,{name:l,email:n,mobile:t}=a,[i,s]=null!==(e=null==l?void 0:l.split(" "))&&void 0!==e?e:[];return{firstname:i,lastname:s,email:n,address:"",mobile:t}}}catch(e){return{firstname:"",lastname:"",email:"",address:"",mobile:""}}},[I,f]),{register:R,handleSubmit:F,watch:V,formState:{errors:B},setValue:G}=(0,b.cI)({resolver:(0,p.F)(N.$q),mode:"onChange",values:D}),{showSaveAndContinue:O}=T({currentValues:V(),previousValues:f,formName:"userDetails"}),M=async e=>{try{let a=await A({mobile:e});if((null==a?void 0:a.status)==="success"){let{uuid:e}=(null==a?void 0:a.data)||{};return e}if((null==a?void 0:a.status)==="error")return(0,_.C)({message:a.message,type:"error"}),!1}catch(e){return!1}},z=async e=>{f.mobile!==e.mobile?await q(e):await U(e)},q=async e=>{var a;(null==I?void 0:null===(a=I.data)||void 0===a?void 0:a.mobile)!==e.mobile?await $(e):!r&&m?await $(e):H(e)},U=async e=>{!r&&m?await $(e):H(e)},$=async e=>{let l=await M(e.mobile);l?(u({mobile:e.mobile,uuid:l}),h((0,d._E)(l)),h((0,d.Xk)(e)),a(!0)):(0,_.C)(Z.N.OTP_SEND_FAILED)},H=e=>{h((0,d.Xk)(e)),h((0,d.E3)(l?1:E)),u(null),h((0,d._E)(null)),a(!1)},J=(e,a,l)=>{let n=e.target.value;G(a,(0,w.Vl)(l,n),{shouldValidate:!0})};return(0,n.jsxs)(c.default,{className:"mt-md-4",children:[(0,n.jsx)("h2",{children:"Verify your details"}),(0,n.jsx)("div",{className:"form-style1",children:(0,n.jsx)(j.Z,{formTemplate:y,register:R,errors:B,onSubmit:z,handleSubmit:F,onChangeDetails:{mobile:e=>J(e,"mobile","numeric"),firstname:e=>J(e,"firstname","name"),lastname:e=>J(e,"lastname","name")},showSaveButton:O,onSaveButtonClick:()=>s(!1),onSubmitButtonClick:()=>s(!0),isSubmitInprogress:L})}),e&&m&&(0,n.jsx)(v.Z,{mobileOTPFormData:m,open:e,onClose:e=>{e?(o(!0),u(null)):o(!1),a(!1)},toProceedNextStep:l}),P&&(0,n.jsx)(C.Z,{})]})},P=l(57099);let A={button:{submit:{className:"grt-btn btn--ruby btn--large no-shrink",text:"Proceed to next step",colmatrix:{md:12}},additionalButton:{className:"grt-btn btn--ruby btn--large no-shrink",text:"Save and continue",colmatrix:{md:12}},backButton:{className:"grt-btn btn--outline btn--large",text:"Back",colmatrix:{md:12}}},fields:[{label:"Select the Scheme Name*",placeholder:"Please select the scheme*",name:"scheme",fieldType:"scheme-list",sendOptionsData:!0,apiDetail
1s:{endPoint:"saving-schemes/method/new",additionalInformation:{isToken:!0},dataConfig:{key:"scheme_code",value:"scheme_code",customValue:"${scheme_code}~${scheme_name}",label:"scheme_name",dataProperty:"data.schemes"}},colmatrix:{xs:12,md:12}},{name:"amount",fieldType:"scheme-amount",colmatrix:{xs:12,md:12}},{name:"preferredAmount",fieldType:"preferred-amount",colmatrix:{xs:12,md:12}},{fieldType:"text",name:"pan_number",label:"PAN Number*",className:"input-field",maxLength:10,conatinerClassName:"form-field",colmatrix:{md:6}}]};var L=()=>{var e;let[a,l]=(0,i.useState)(!0),s=(0,t.TL)(),{schemeDetailFormData:r,defaultDropDownValues:o,trackPreviousStepperIndex:m,preferredAmount:u,isPanRequired:h,preselectAmountValue:f,additionalInformationFormData:x}=(0,t.CG)(e=>e.savingSchemeSlice),v=(0,i.useMemo)(()=>(0,N.lp)(h),[h]),{register:g,handleSubmit:y,formState:{errors:_},watch:C,setValue:S,reset:k}=(0,b.cI)({resolver:(0,p.F)(v),mode:"onChange",values:{scheme:r.scheme?r.scheme:o.schemeDropdown,amount:r.amount?r.amount:"",pan_number:null!==(e=r.pan_number)&&void 0!==e?e:x.pan_number}}),w=(0,i.useMemo)(()=>{let e={...A};return h||(e.fields=e.fields.filter(e=>"pan_number"!==e.name)),e},[h]),{showSaveAndContinue:E}=T({currentValues:C(),previousValues:r,formName:"schemeDetails"});(0,i.useEffect)(()=>{f&&S("amount",f.toString(),{shouldValidate:!0})},[f,S]),(0,i.useEffect)(()=>{if(r.amount){let e=11*parseInt(r.amount)>=P.r4;s((0,d.Pg)(e))}else s((0,d.AK)(null)),s((0,d.Pg)(!1))},[r.amount,s]);let Z=(0,i.useCallback)((e,a)=>{let[l]=(null==e?void 0:e.split("~"))||[];return a.find(e=>e.scheme_code===l)||null},[]),I=(0,i.useCallback)(e=>{var a;let l=(null==e?void 0:e.split("~"))||[],n=null==u?void 0:null===(a=u.schemes)||void 0===a?void 0:a.find(e=>e.scheme_name===l[1]);return(null==n?void 0:n.preferred_amount)?null==n?void 0:n.preferred_amount:[]},[u]);return(0,n.jsxs)(c.default,{className:"mt-4",children:[(0,n.jsx)("h2",{children:"Enter details regarding the scheme"}),(0,n.jsx)("div",{className:"form-style1",children:(0,n.jsx)(j.Z,{formTemplate:w,register:g,errors:_,onSubmit:e=>{s((0,d.AK)(null)),s((0,d.dZ)(e)),e.pan_number&&s((0,d.Ie)({...x,pan_number:e.pan_number})),a?s((0,d.E3)(2)):s((0,d.E3)(m))},handleSubmit:y,onChangeDetails:{scheme:(e,a)=>{let l=e.target.value,n=Z(l,a);if(n){let{amount:e,country:a}=n;void 0!==e&&void 0!==a&&(s((0,d.KK)(e)),s((0,d.Ag)(a)));let t=I(l);s((0,d.n0)(t))}s((0,d.AK)(null)),s((0,d.Pg)(!1)),S("scheme",l,{shouldValidate:!0}),S("amount","")},pan_number:e=>{S("pan_number",e.target.value?e.target.value.toUpperCase():"",{shouldValidate:!0})},amount:e=>{let a=11*parseInt(e.target.value)>=P.r4;s((0,d.Pg)(a)),S("amount",e.target.value,{shouldValidate:!0})}},showSaveButton:E,onSaveButtonClick:()=>l(!1),onSubmitButtonClick:()=>l(!0),onBackButtonClick:()=>{var e;k({scheme:r.scheme?r.scheme:"",amount:r.amount?r.amount:"",pan_number:null!==(e=r.pan_number)&&void 0!==e?e:x.pan_number}),s((0,d.AK)(null)),s((0,d.E3)(0))}})})]})};let D={button:{submit:{className:"grt-btn btn--ruby btn--large mx-md-0 mx-auto no-shrink",text:"Proceed to next step",colmatrix:{md:12}},additionalButton:{className:"grt-btn btn--ruby btn--large no-shrink",text:"Save and continue",colmatrix:{xs:12,md:12}},backButton:{className:"grt-btn btn--outline btn--large",text:"Back",colmatrix:{md:12}}},fields:[{fieldType:"text",name:"pan_number",label:"PAN Number*",maxLength:10,className:"input-field",conatinerClassName:"form-field",colmatrix:{md:6}},{fieldType:"select",name:"id_proof_type",label:"Identity Proof Type*",className:"select-field",colmatrix:{md:6},options:P.y1},{fieldType:"text",name:"id_proof_number",label:"Identity Proof Number*",maxLength:20,disabled:!0,className:"input-field",conatinerClassName:"form-field",colmatrix:{md:6}},{fieldType:"text",name:"nominee",label:"Name of Nominee*",maxLength:50,className:"input-field",conatinerClassName:"form-field",colmatrix:{md:6}},{fieldType:"date",name:"date_of_birth",label:"Choose date of birth",className:"input-field",colmatrix:{md:6}},{fieldType:"date",name:"wedding_anniversary",label:"Wedding Anniversary",className:"input-field",colmatrix:{md:6}},{fieldType:"masked",name:"account_number",maxLength:20,label:"Bank account number",className:"input-field",conatinerClassName:"form-field",colmatrix:{md:6}},{fieldType:"text",name:"reenter_account_number",label:"Re-enter bank account number",maxLength:20,preventPaste:!0,className:"input-field",conatinerClassName:"form-field",colmatrix:{md:6}},{fieldType:"text",name:"branch",maxLength:50,label:"Bank branch",className:"input-field",conatinerClassName:"form-field",colmatrix:{md:6}},{fieldType:"text",name:"ifsc_code",label:"IFSC Code",preventPaste:!0,maxLength:11,className:"input-field",conatinerClassName:"form-field",colmatrix:{md:6}}]}
1,R={"Driving Licence":16,"Electoral Identity Card":10,"Aadhaar Number":14,"Passport Number":8,"Ration Card Number":10};var F=()=>{let[e,a]=(0,i.useState)(!0),[l,s]=(0,i.useState)(null),{schemeDetailFormData:r,trackPreviousStepperIndex:o,additionalInformationFormData:m,isPanRequired:u}=(0,t.CG)(e=>e.savingSchemeSlice),h=(0,t.TL)(),{register:f,handleSubmit:x,watch:v,setValue:g,reset:y,formState:{errors:_}}=(0,b.cI)({resolver:(0,i.useMemo)(()=>{let e=(0,N.Hm)(!0);return(0,p.F)(e)},[]),mode:"onChange",values:{...m,pan_number:m.pan_number?m.pan_number:r.pan_number,id_proof_type:m.id_proof_type?m.id_proof_type:P.y1[0]}}),C=v(),{showSaveAndContinue:S}=T({currentValues:C,previousValues:m,formName:"additionalInformation"}),k=(0,i.useMemo)(()=>{let e={...D},a=e.fields.find(e=>"id_proof_number"===e.name);return a&&(a.disabled=!l),e},[l]),E=(e,a,l,n)=>{if("id_proof_number"!==e)return a?(0,w.Vl)(a,l,n):l;{let e=C.id_proof_type;return a?(0,w.Vl)(a,l,n,R[e]||20):l}},Z=e=>{s((null==e?void 0:e.includes("Please select"))?null:"Aadhaar Number"===e?"aadhaar":"alphanumeric"),(null==e?void 0:e.includes("Please select"))?g("id_proof_number","",{shouldValidate:!0}):C.id_proof_number&&g("id_proof_number",C.id_proof_number,{shouldValidate:!0})},I=(e,a,l,n)=>{let t=e.target.value,i=E(a,l,t,n);g(a,i,{shouldValidate:!0}),"account_number"===a&&g("reenter_account_number",C.reenter_account_number,{shouldValidate:!0}),"id_proof_type"===a&&Z(t)},A=()=>{y({...m,pan_number:m.pan_number?m.pan_number:r.pan_number})};return(0,n.jsxs)(c.default,{className:"mt-4",children:[(0,n.jsx)("h2",{children:"Additional Information"}),(0,n.jsx)("div",{className:"form-style1",children:(0,n.jsx)(j.Z,{formTemplate:k,register:f,errors:_,onSubmit:a=>{var l;h((0,d.Ie)({...a,id_proof_type:(null===(l=a.id_proof_type)||void 0===l?void 0:l.includes("Please select"))?"":a.id_proof_type})),h((0,d.dZ)({...r,pan_number:a.pan_number})),e?h((0,d.E3)(3)):h((0,d.E3)(o))},handleSubmit:x,onChangeDetails:{account_number:e=>I(e,"account_number","numeric"),reenter_account_number:e=>I(e,"reenter_account_number","numeric"),branch:e=>I(e,"branch","alphabeticwithspace"),ifsc_code:e=>I(e,"ifsc_code","alphanumeric",!0),pan_number:e=>I(e,"pan_number","alphanumeric",!0),nominee:e=>I(e,"nominee","name"),id_proof_type:e=>I(e,"id_proof_type",null),id_proof_number:e=>I(e,"id_proof_number",l,!0)},showSaveButton:S,showSkipButton:!S,onSaveButtonClick:()=>a(!1),onSubmitButtonClick:()=>a(!0),onSkipButtonClick:()=>{A(),h((0,d.E3)(3))},onBackButtonClick:()=>{A(),h((0,d.E3)(1))}})})]})},V=l(95098),B=l(61418),G=l(92286);let O={pan_number:"PAN Number",ifsc_code:"IFSC Code"},M=e=>O[e]||e.replace(/_/g," ").replace(/\b\w/g,e=>e.toUpperCase()),z=e=>{let{data:a}=e,l=Object.entries(a).filter(e=>void 0!==e[1]&&""!==e[1]);return 0===l.length?null:(0,n.jsx)(m.default,{children:l.map(e=>{let[a,l]=e;return(0,n.jsx)(u.default,{xs:12,md:6,className:"mb-3",children:(0,n.jsx)(G.Z,{fieldType:"text",disabled:!0,name:a,label:M(a),className:"input-field",value:l})},a)})})};var q=()=>{let e=(0,t.TL)(),{schemeDetailFormData:a,userDetailFormData:l,additionalInformationFormData:s,defaultBranch:r,userDetails:o}=(0,t.CG)(e=>({...e.savingSchemeSlice,userDetails:e.user.userDetails})),{date_of_birth:h,wedding_anniversary:f,account_number:b,branch:p,id_proof_number:x,id_proof_type:v,ifsc_code:g,pan_number:y,nominee:_}=s,{mobile:j,email:N,firstname:C,lastname:S,address:k}=l,{amount:w}=a,E=(0,i.useMemo)(()=>{if(o.email&&k){var e;return null!==(e=o.addresses.find(e=>e.id.toString()===k))&&void 0!==e?e:null}return null},[o,k]);return(0,n.jsxs)(c.default,{className:"jss-confirmdetail-step",children:[(0,n.jsx)("h2",{children:"Verify your details"}),(0,n.jsx)("div",{className:"form-style1",children:(0,n.jsxs)("form",{children:[(0,n.jsx)(z,{data:{amount:w,scheme_branch:null!=r?r:"",name:"".concat(C," ").concat(S),email:N,mobile_number:j,date_of_birth:null!=h?h:"",wedding_anniversary:null!=f?f:"",bank_account_number:null!=b?b:"",bank_branch:null!=p?p:"",ifsc_code:null!=g?g:"",pan_number:null!=y?y:"",identity_proof_type:null!=v?v:"",identity_proof_number:null!=x?x:"",nominee:null!=_?_:""}}),(0,n.jsx)(m.default,{children:(0,n.jsx)(u.default,{xs:12,className:"mb-3",children:E&&(0,n.jsx)(V.Z,{info:E,readOnly:!0})})}),(0,n.jsxs)("div",{className:"text-md-start text-center",children:[(0,n.jsx)(B.zx,{type:"button",handleClick:()=>{e((0,d.E3)(2))},className:"grt-btn btn--outline btn--large me-3",children:"Back"}
1),(0,n.jsx)(B.zx,{className:"grt-btn btn--ruby btn--large mt-md-4 mx-md-0 mx-auto mt-2",type:"button",handleClick:()=>{e((0,d.E3)(4))},children:"Proceed to next step"})]})]})})]})},U=()=>{var e;let a=null===(e=(0,s.useSearchParams)().get("type"))||void 0===e?void 0:e.toLowerCase(),{stepperCount:l}=(0,t.CG)(e=>e.savingSchemeSlice),b=(0,t.TL)();return(0,i.useEffect)(()=>{window.scrollTo(0,0)},[l]),(0,n.jsx)("div",{className:"scheme-details",children:(0,n.jsxs)(c.default,{children:["new"===a&&(0,n.jsxs)(m.default,{className:"new-scheme",children:[(0,n.jsxs)(u.default,{md:6,className:"left-section",children:[(0,n.jsx)("h1",{className:"maintitle",children:"Welcome to the Jewellery Purchase Plan"}),(0,n.jsx)(r.Z,{onStepClick:e=>{b((0,d.E3)(e)),b((0,d.AK)(null))},currentStep:0,steps:o._F,markCompletedSteps:!0,hightlightCompletedStep:!0})]}),(0,n.jsx)(u.default,{md:6,className:"right-section",children:(e=>{switch(e){case 0:return(0,n.jsx)(I,{});case 1:return(0,n.jsx)(L,{});case 2:return(0,n.jsx)(F,{});case 3:return(0,n.jsx)(q,{});case 4:return(0,n.jsx)(h.Z,{flow:"newscheme"});default:return(0,n.jsx)(n.Fragment,{})}})(l)})]}),(0,n.jsx)("section",{children:"existing"===a&&(0,n.jsx)("div",{className:"existing-scheme",children:(0,n.jsx)(f.Z,{})})})]})})}},3626:function(e,a,l){var n=l(57437),t=l(2265),i=l(99376),s=l(63735),r=l(61006),o=l(83142),d=l(19032),c=l(13786),m=l(57099);a.default=()=>{let e=(0,i.useSearchParams)(),a=e.get("transaction_id"),l=e.get("error_message"),[u,h]=(0,t.useState)(!1),[f,b]=(0,t.useState)(null),[p,x]=(0,t.useState)(null),{data:v}=(0,r.u)(a?"saving-scheme/payment/message/".concat(a):null,o.Et,{revalidateOnFocus:!1,shouldRetryOnError:!1});return(0,t.useEffect)(()=>{(async()=>{let e=await (0,d.r3)();e&&x(e)})()},[]),(0,t.useEffect)(()=>{var e,n,t;if(l){let t=decodeURIComponent(l);b({type:"danger",text:t}),h(!0);let i=null==p?void 0:null===(n=p.customAttributes)||void 0===n?void 0:null===(e=n.find(e=>"mobile"===e.name))||void 0===e?void 0:e.value;(0,c.sendGTMEvent)({event:m.Hb,transaction_id:a,error_message:t,user_email:null==p?void 0:p.email,user_phone:i,page_name:document.title,page_url:window.location.href});let s=setTimeout(()=>h(!1),1e4);return()=>clearTimeout(s)}if(v){let e=(null==v?void 0:v.status)==="success",a=(null==v?void 0:null===(t=v.errorResponse)||void 0===t?void 0:t.status)==="error";if(e||a){b({type:e?"success":"danger",text:e?v.message:v.error}),h(!0);let a=setTimeout(()=>h(!1),1e4);return()=>clearTimeout(a)}}},[v,l]),(0,n.jsx)(n.Fragment,{children:u&&f&&(0,n.jsx)(s.default,{variant:f.type,children:f.text})})}},28205:function(e,a,l){var n=l(57437);l(2265);var t=l(27648),i=l(90099),s=l(61418),r=l(57099),o=l(13786);let d=()=>{(0,o.sendGTMEvent)({event:r.rO,page_name:document.title,page_url:window.location.href,cta_name:"Join New Purchase Plan"})},c=()=>{(0,o.sendGTMEvent)({event:r.tr,page_name:document.title,page_url:window.location.href,cta_name:"ADD YOUR EXISTING PURCHASE PLAN"})},m=()=>{(0,o.sendGTMEvent)({event:r.zk,page_name:document.title,page_url:window.location.href,cta_name:"PAY YOUR MONTHLY ADVANCE"})};a.default=e=>{let{buttonLabel:a,showContent:l,children:r}=e;return(0,n.jsx)("section",{children:(0,n.jsx)(i.default,{children:(0,n.jsxs)("div",{className:"grt-tab-style scheme-tab",children:[(0,n.jsxs)("section",{className:"tab-header d-none d-md-flex",children:[l&&(0,n.jsx)(s.zx,{className:"active-tab",children:a}),(0,n.jsx)(t.default,{href:"/jewellery-purchase-plan/register/?type=new",onClick:d,prefetch:!1,children:"Join New Purchase Plan"}),(0,n.jsx)(t.default,{href:"/jewellery-purchase-plan/register/?type=existing",onClick:c,prefetch:!1,children:"Add to existing plan"}),(0,n.jsx)(t.default,{href:"/jewellery-purchase-plan/scheme",onClick:m,prefetch:!1,children:"Pay your monthly advance"})]}),l&&(0,n.jsxs)("section",{className:"tab-content d-block d-md-none",children:[(0,n.jsx)("h3",{className:"",children:a}),r]}),l&&(0,n.jsx)("section",{className:"tab-content d-none d-md-block",children:r}),(0,n.jsxs)("section",{className:"tab-header d-block d-md-none",children:[(0,n.jsx)(t.default,{href:"/jewellery-purchase-plan/scheme",onClick:m,prefetch:!1,children:"Pay your monthly advance"}),(0,n.jsx)(t.default,{href:"/jewellery-purchase-plan/register/?type=existing",onClick:c,prefetch:!1,children:"Add to existing plan"}),(0,n.jsx)(t.default,{href:"/jewellery-purchase-plan/register/?type=new",onClick:d,prefetch:!1,children:"Join New Purchase Plan"})]})]})})})}},8166:function(e,a,l){var n=l(57437);l(2265);var t=l(29501),i=l(13590),s=l(18492),r=l(24402),o=l(4670),d=l(33145),c=l(3435),m=l(45061),u=l(29535),h=l(61418),f=l(25236),b=l(30963),p=l(92286),x=l(65113),v=l(92731),g=l(68412);a.Z=e=>{var a,l,y,_,j,N;let{status:C,productData:S,formPayload:k,onClose:w,isEmailNotMandatory:E}=e,T=(0,x.TL)(),Z=(0,c.ob)(!E),{register:I,handleSubmit:P,setValue:A,formState:{errors:L,isValid:D}}=(0,t.cI)({resolver:(0,i.F)(Z),mode:"onChange"}),{error:R,clearError:F}=(0,f.Z)(),V=async e=>{try{var a,l;T((0,v.VO)());let n={product_name:null!==(a=null==S?void 0:S.name)&&void 0!==a?a:"",name:e.name,mobile:e.mobile,sku:null!==(l=null==S?void 0:S.sku)&&void 0!==l?l:"",reason:e.reason,...E?{}:{email:null==e?void 0:e.email}};k&&(n={...n,...k});let t=await (0,u.md)(n);"string"==typeof t?(T((0,v.Gx)()),(0,m.C)({message:"string"==typeof t?t:"",type:"success"}),w()):(T((0,v.Gx)()),(0,m.C)({message:"string"==typeof(null==t?void 0:t.error)?null==t?void 0:t.error:b.N.UNSUCCESS_ERROR.message,type:"error"}))}catch(e){(0,m.C)(b.N.SEND_ENQUIRY_FAILED)}},B=(e,a,l)=>{let n=e.target.value;A(a,(0,g.Vl)(l,n),{shouldValidate:!0}),F()};return(0,n.jsx)(n.Fragment,{children:C&&(0,n.jsxs)(s.Z,{show:C,onHide:w,className:"enquiry-form",children:[(0,n.jsx)(s.Z.Header,{closeButton:!0,children:(0,n.jsx)(s.Z.Title,{children:(0,n.jsx)("div",{style:{color:"#681016"},children:"Send Enquiry"})})}),(0,n.jsxs)(s.Z.Body,{children:[(0,n.jsxs)(r.default,{className:"align-items-center",children:[(0,n.jsx)(o.default,{xs:4,children:(0,n.jsx)(d.default,{src:null!==(j=null==S?void 0:S.thumb_image)&&void 0!==j?j:"/GRT_Logo.png",alt:null!==(N=null==S?void 0:S.name)&&void 0!==N?N:"Grt jewellers",width:200,height:200})}),(0,n.jsxs)(o.default,{xs:8,children:[(0,n.jsx)("h6",{children:null==S?void 0:S.sku}),(0,n.jsx)("h5",{className:"mt-2",children:null==S?void 0:S.name})]})]}),(0,n.jsxs)("form",{onSubmit:P(V),className:"grt-form",children:[(0,n.jsx)(p.Z,{fieldType:"text",name:"name",label:"Name*",register:I,placeholder:"Enter name",ariaLabel:"Name",onChange:e=>{A("name",e.target.value,{shouldValidate:!0}),F()},error:null===(a=L.name)||void 0===a?void 0:a.message,className:"mb-3 p-2"}),(0,n.jsx)(p.Z,{fieldType:"text",name:"email",label:"Email".concat(E?"":"*"),register:I,placeholder:"Enter email-id",ariaLabel:"Email",onChange:e=>{A("email",e.target.value,{shouldValidate:!0}),F()},error:null===(l=L.email)||void 0===l?void 0:l.message,className:"mb-3 p-2"}),(0,n.jsx)(p.Z,{fieldType:"text",name:"mobile",label:"Mobile Number*",register:I,placeholder:"Enter mobile number",ariaLabel:"Mobile Number",error:null===(y=L.mobile)||void 0===y?void 0:y.message,maxLength:10,onChange:e=>B(e,"mobile","numeric"),className:"mb-3 p-2"}),(0,n.jsx)(p.Z,{fieldType:"text",name:"reason",label:"Reason*",register:I,placeholder:"Enter reason",ariaLabel:"Reason",error:null===(_=L.reason)||void 0===_?void 0:_.message,onChange:e=>{A("reason",e.target.value,{shouldValidate:!0}),F()},className:"mb-3 p-2"}),""!==R&&(0,n.jsx)("p",{className:"error-message mt-1",children:R}),(0,n.jsx)("div",{className:"mt-3 text-center",children:(0,n.jsx)(h.zx,{className:"grt-btn btn--ruby btn--medium mx-auto$ ".concat(!D&&"disabled-btn"),type:"submit",disabled:!D,children:"Submit"})})]})]})]})})}},5513:function(e,a,l){l.d(a,{default:function(){return w}});var n=l(57437),t=l(29501),i=l(13590),s=l(90099),r=l(24402),o=l(4670),d=l(2265);let c={button:{colClassName:"mx-auto",submit:{className:"grt-btn btn--ruby btn--large mx-md-0 mx-auto",text:"Submit",colmatrix:{md:12}}},allFieldsMatrix:{colmatrix:{md:12},rowClassName:"instantpay-form"},fields:[{label:"Scheme Name*",placeholder:"Please select the scheme*",name:"scheme",fieldType:"select",apiDetail
1s:{endPoint:"saving-schemes/method/instantpay",dataConfig:{key:"scheme_code",value:"scheme_code",customValue:"${scheme_code}~${scheme_name}",label:"scheme_name",dataProperty:"data"}},colmatrix:{xs:12,md:6}},{fieldType:"tel",name:"mobile",maxLength:10,label:"Scheme Registerd Mobile Number*",className:"input-field",conatinerClassName:"none",colmatrix:{xs:12,md:6}},{fieldType:"select",name:"branch",label:"Branch*",placeholder:"Please Select Branch*",className:"select-field",apiDetails:{endPoint:"saving-scheme/branches/",dataConfig:{dataProperty:"data",key:"code",value:"code",label:"name"}},colmatrix:{xs:12,md:4}},{fieldType:"text",name:"msno",label:"Membership No*",placeholder:"Four digit of membership number (Ex., 1234)*",className:"input-field",colmatrix:{xs:12,md:4}},{fieldType:"text",name:"group_code",label:"Group Code*",placeholder:"Three digit of group code (Ex., ABC)*",className:"input-field",colmatrix:{xs:12,md:4}}]};var m=l(70019),u=l(78361),h=l(45061),f=l(65582),b=l(34370),p=l(65113),x=e=>{let{userData:a}=e,{amount:l,name:t,email:i}=a;return(0,n.jsxs)("section",{children:[(0,n.jsx)("h3",{className:"mb-4",children:"Your Scheme Detail"}),(0,n.jsxs)("div",{className:"form-view",children:[(0,n.jsxs)(r.default,{className:"mb-3",children:[(0,n.jsx)(o.default,{id:"name",xs:4,md:3,children:(0,n.jsx)("label",{htmlFor:"name",children:"Name"})}),(0,n.jsx)(o.default,{xs:8,md:9,children:(0,n.jsx)("p",{className:"info",children:t})})]}),(0,n.jsxs)(r.default,{className:"mb-3",children:[(0,n.jsx)(o.default,{id:"amount",xs:4,md:3,children:(0,n.jsx)("label",{htmlFor:"amount",children:"Amount"})}),(0,n.jsx)(o.default,{xs:8,md:9,children:(0,n.jsx)("p",{className:"info",children:l})})]}),(0,n.jsxs)(r.default,{className:"mb-3",children:[(0,n.jsx)(o.default,{id:"email",xs:4,md:3,children:(0,n.jsx)("label",{htmlFor:"email",children:"Email"})}),(0,n.jsx)(o.default,{xs:8,md:9,children:(0,n.jsx)("p",{className:"info",children:i})})]})]})]})},v=l(38281),g=l(66507),y=l(83142),_=l(61418),j=l(3626),N=l(25236),C=l(30963),S=l(57099),k=l(13786),w=()=>{let[e,a]=(0,d.useState)(null),l=(0,p.TL)(),{register:w,handleSubmit:E,formState:{errors:T},setValue:Z}=(0,t.cI)({resolver:(0,i.F)(u.f0),mode:"onChange"}),{error:I,showError:P,clearError:A}=(0,N.Z)(),{trigger:L,isMutating:D}=(0,f.Z)("saving-scheme/instant-pay-validate",y.v7);(0,d.useEffect)(()=>{!(null==e?void 0:e.can_pay)&&(null==e?void 0:e.message)&&(0,h.C)({message:null==e?void 0:e.message,type:"error"})},[e]);let R=async e=>{try{let{branch:n,msno:t,group_code:i,mobile:s,scheme:r}=e,o=null==r?void 0:r.split("~")[0];l((0,b.Xu)({scheme_code:o,mobile:s,company_code:n,msno:t,group_code:i}));let d=await L({scheme_code:o,mobile:s,company_code:n,msno:t,group_code:i});if("success"===d.status){let{data:e}=d;(0,k.sendGTMEvent)({event:S.C5,page_name:document.title,page_url:window.location.href,cta_name:"Instant pay submit",mobile_number:s}),a(e)}else a(null),P(d.message||d.error)}catch(e){(0,h.C)(C.N.COMMON_ERROR)}};return(0,n.jsxs)(s.default,{children:[(0,n.jsx)(j.default,{}),(0,n.jsx)("h2",{children:"Instant Pay Installments"}),(0,n.jsx)("p",{className:"sub-title",children:"Pay your monthly advance quickly"}),(0,n.jsxs)("section",{className:"form-style1 mt-md-5 mt-2",children:[(0,n.jsx)(m.Z,{formTemplate:c,onSubmit:R,register:w,handleSubmit:E,onChangeDetails:{mobile:e=>{A(),Z("mobile",e.target.value.replace(/\D/g,""))},scheme:()=>A(),msno:()=>A(),group_code:()=>A(),branch:()=>A()},errors:T,hideSubmitButton:null==e?void 0:e.can_pay,disableForm:null==e?void 0:e.can_pay,error:I}),(null==e?void 0:e.can_pay)&&(0,n.jsx)(_.zx,{className:"grt-btn btn--ruby btn--medium mx-auto",handleClick:()=>{a(null)},children:"Edit"})]}),(null==e?void 0:e.can_pay)&&(0,n.jsxs)(r.default,{className:"mt-5",children:[(0,n.jsx)(o.default,{md:5,children:(0,n.jsx)(x,{userData:e})}),(0,n.jsx)(o.default,{md:7,children:(0,n.jsx)(v.Z,{flow:"instantpay",userSchemeDetails:e})})]}),D&&(0,n.jsx)(g.Z,{})]})}},38281:function(e,a,l){var n=l(57437),t=l(2265),i=l(92286),s=l(45061),r=l(65113),o=l(68412),d=l(13590),c=l(10279),m=l(63735),u=l(29501),h=l(65582),f=l(97154),b=l(78361),p=l(83142),x=l(61418),v=l(25236),g=l(30963),y=l(57099);let _={instantpay:"Pay now",existing:"Pay now",newscheme:"Pay now"};a.Z=e=>{var a,l;let{userSchemeDetails:j,flow:N}=e,[C,S]=(0,t.useState)(null),{payment_method:k,schemeDetailFormData:w,userDetailFormData:E,additionalInformationFormData:T,scheme_data:Z,countryDataForSelectedScheme:I,scheme_id:P,uuidValue:A}=(0,r.CG)(e=>e.savingSchemeSlice),{userDetails:L}=(0,r.CG)(e=>e.user),{mobile:D,email:R,firstname:F,lastname:V,address:B}=E,{addresses:G}
1=L,{ifsc_code:O,id_proof_type:M,wedding_anniversary:z,pan_number:q,account_number:U,branch:$,date_of_birth:H,nominee:J,id_proof_number:K}=T,{scheme:Y,amount:Q}=w,{error:X,showError:W,clearError:ee}=(0,v.Z)(),{moduleStatus:ea}=(0,r.CG)(e=>null==e?void 0:e.globalState),{register:el,handleSubmit:en,formState:{errors:et}}=(0,u.cI)({resolver:(0,d.F)(b.af),mode:"onChange",values:{payment_method:k||""}}),{trigger:ei,isMutating:es}=(0,h.Z)("saving-scheme/payment/init",p.kU),er=async e=>{let{payment_method:a}=e,[l,n]=a.split("~");try{"instantpay"===N?await eo(l,n):"newscheme"===N?await ed(l,n):"existing"===N&&await ec(l,n)}catch(e){W((0,o.e$)(e))}},eo=async(e,a)=>{if(!(null==j?void 0:j.scheme_id)||""===Z.msno){(0,s.C)(g.N.MISSING_REQUIRED);return}let l={payment_type:"instant-pay",card_type:e,scheme_id:j.scheme_id,scheme_data:Z,saving_scheme_payment:{device_type:"w",payment_method:a}};await em(l)},ed=async(e,a)=>{let l=eu(B),n=eh(l),t={mobile:D,email:R,card_type:e,saving_scheme_user_profile:ef(),name:"".concat(F," ").concat(V).trim(),scheme_code:Y.split("~")[0],saving_scheme_payment:{device_type:"w",payment_method:a},payment_type:"new",amount:Q,saving_scheme_user_address:eb(l,n)};A&&(t.uuid=A),await em(t,!0)},ec=async(e,a)=>{if(!P){(0,s.C)(g.N.MISSING_REQUIRED);return}await em({scheme_id:P,card_type:e,saving_scheme_payment:{device_type:"w",payment_method:a},payment_type:"existing"},!0)},em=async function(e){let a=arguments.length>1&&void 0!==arguments[1]&&arguments[1],l=await ei({payload:e,isToken:a});if("success"===l.status)S(l.data);else{var n;S(null);let e=null!==(n=l.error)&&void 0!==n?n:l.message;l.errorResponse&&(e=(0,o.Jw)(l.errorResponse)),W(e)}},eu=e=>G.find(a=>a.id.toString()===e),eh=e=>I.find(a=>{var l,n;return(null===(l=a.code)||void 0===l?void 0:l.toLowerCase())===(null==e?void 0:null===(n=e.country_id)||void 0===n?void 0:n.toLowerCase())}),ef=()=>({ifsc_code:null!=O?O:"",idnumber:null!=K?K:"",idproof:null!=M?M:"",pan_number:null!=q?q:"",account_number:null!=U?U:"",branch:null!=$?$:"",dob:null!=H?H:"",title:"",nominee:null!=J?J:"",initials:"",wedding_date:null!=z?z:""}),eb=(e,a)=>{var l,n,t,i,s,r;return{pincode:null!==(n=null==e?void 0:e.postcode)&&void 0!==n?n:"",state:null!==(t=null==e?void 0:null===(l=e.region)||void 0===l?void 0:l.region)&&void 0!==t?t:"",address3:"",address1:null!==(i=null==e?void 0:e.street[0])&&void 0!==i?i:"",city:null!==(s=null==e?void 0:e.city)&&void 0!==s?s:"",address2:null!==(r=null==e?void 0:e.street[0])&&void 0!==r?r:"",country:null==a?void 0:a.id}};return(0,n.jsx)(n.Fragment,{children:(null==ea?void 0:null===(a=ea.payment)||void 0===a?void 0:a.is_enabled)?(0,n.jsxs)(n.Fragment,{children:[(0,n.jsxs)("form",{onSubmit:en(er),children:[(0,n.jsx)(i.Z,{fieldType:"payment",name:"payment_method",register:el,onChange:()=>ee(),error:null===(l=et.payment_method)||void 0===l?void 0:l.message}),""!==X&&(0,n.jsx)("p",{className:"error-message mt-1",children:X}),(0,n.jsxs)(x.zx,{type:"submit",disabled:es,className:"grt-btn btn--ruby btn--large mx-auto ms-3 mt-2",children:[es&&(0,n.jsx)("output",{"aria-live":"polite",children:(0,n.jsx)(c.default,{as:"span",animation:"grow",size:"sm","aria-hidden":"true"})}),es?"Processing...":_[N]]})]}),C&&(0,n.jsx)(f.Z,{redirectionData:C})]}):(0,n.jsx)(m.default,{variant:"warning",children:y.wf})})}},97154:function(e,a,l){var n=l(57437),t=l(2265);a.Z=e=>{var a;let{redirectionData:l}=e,i=(0,t.useRef)(null),{url:s,...r}=l;if((0,t.useEffect)(()=>{""!==l.url&&o()},[l]),""===s)return(0,n.jsx)(n.Fragment,{});let o=()=>{i.current&&i.current.submit()};return(0,n.jsx)("form",{method:"post",action:s,ref:i,children:null===(a=Object.entries(r))||void 0===a?void 0:a.map(e=>{let[a,l]=e;return(0,n.jsx)("input",{type:"hidden",name:a,value:l},a)})})}},60180:function(e,a,l){l.r(a);var n=l(57437),t=l(2265);a.default=e=>{let{cssClass:a,backgroundColor:l,backgroundImage:i,background:s,children:r,fontColor:o,showBackgroundImage:d}=e;return(0,t.useInsertionEffect)(()=>{let e=document.createElement("style"),n=null==a?void 0:a.split(" ").join("."),t="";i&&(t=d?i:"url(".concat("https://media.grtjewels.com","/").concat(i,")"));let r="\n .".concat(n," {\n ").concat(l?"background-color: ".concat(l," !important"):"",";\n ").concat(i?"background-image: ".concat(t,";"):"","\n ").concat(o?"color: ".concat(o," !important"):"",";\n ").concat(s?"background: ".concat(s," !important"):"",";\n }\n ");return e.appendChild(document.createTextNode(r)),document.head.appendChild(e),()=>{document.head.removeChild(e)}},[a,l,i,o]),(0,n.jsx)(n.Fragment,{children:r})}},16538:function(e,a,l){l.r(a),l.d(a,{NextArrow:function(){return i},PrevArrow:function(){return s}});var n=l(57437);l(2265);var t=l(61418);let i=e=>{let{onClick:a,className:l}=e;return(0,n.jsx)(t.zx,{type:"button","aria-label":"previous-icon",className:l,handleClick:a,children:(0,n.jsx)("i",{className:"bi bi-chevron-right"})})},s=e=>{let{onClick:a,className:l}=e;return(0,n.jsx)(t.zx,{type:"button","aria-label":"next-icon",className:l,handleClick:a,children:(0,n.jsx)("i",{className:"bi bi-chevron-left"})})}},3435:function(e,a,l){l.d(a,{RI:function(){return s},V6:function(){return r},Zx:function(){return i},ob:function(){return t}});var n=l(91351);let t=function(){let e=!(arguments.length>0)||void 0===arguments[0]||arguments[0];return n.Ry({name:n.Z_().min(1,"Name is required").regex(/^[a-zA-Z\s]+$/,"Only letters and spaces are allowed"),email:e?n.Z_().min(1,{message:"Email is required"}).email({message:"Invalid email address"}).regex(/^[a-zA-Z0-9._%+-]+@[a-zA-Z]+\.[a-zA-Z]{2,}$/,{message:"Invalid email address"}):n.Z_().nullable().or(n.i0("")).refine(e=>!e||/^[a-zA-Z0-9._%+-]+@[a-zA-Z]+\.[a-zA-Z]{2,}$/.test(e),{message:"Invalid email address"}),mobile:n.Z_().min(1,"Mobile number is required").regex(/^\d{10}$/,{message:"Invalid mobile number"}),reason:n.Z_().min(1,{message:"Reason is required"}).max(255,{message:"Reason must be 200 characters or fewer"})})},i=n.Ry({pincode:n.Z_().regex(/^\d{6}$/,{message:"Invalid pincode. It should be exactly 6 digits."})}),s=n.Ry({email:n.Z_().min(1,{message:"Email is required"}).email({message:"Invalid email address"}).regex(/^[a-zA-Z0-9._%+-]+@[a-zA-Z]+\.[a-zA-Z]{2,}$/,{message:"Invalid email address"}),mobileNumber:n.Z_().min(1,{message:"Mobile Number is required"}).regex(/^\d{10}$/,{message:"Mobile number must be 10 digits"})}
1),r=n.Ry({couponCode:n.Z_().min(1,{message:"Please enter coupon code and continue."}).max(24,{message:"Coupon code should not exceed 24 characters."})})},15268:function(e,a,l){l.d(a,{D:function(){return n}});let n=e=>{let{route:a,router:l,quoteDetails:n,calculatedDetails:t,currencySymbol:i,formValues:s}=e;if(n.is_registered){let e=localStorage.getItem("remainingTime");if(e){localStorage.setItem("remainingCheckoutTime",e.toString());let a=Date.now();localStorage.setItem("checkoutStartTime",a.toString())}localStorage.setItem("QUOTE_DETAILS",JSON.stringify(n)),localStorage.setItem("CALCULATED_DETAILS",JSON.stringify(t)),localStorage.setItem("CURRENCY_SYMBOL",JSON.stringify(i)),localStorage.setItem("FORM_VALUES",JSON.stringify(s)),l.push(a)}else l.push("/digi-gold/profile?isRegistered=false")}},96413:function(e,a,l){l.r(a),a.default={src:"/_next/static/media/header-underline.92b44f0d.svg",height:29,width:463,blurWidth:0,blurHeight:0}}}]);
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.