import{U as R,P as I,r as d,$ as N,a0 as T,N as A,V as v,ah as V,m as l,p as t,Z as p,M as c,ai as _,Y as o,as as x,ac as f,am as E,a2 as g,T as q,t as S,o as u,W as U,X as z}from"./common.modules-219f1756.js";import{bC as G,A as H,bD as h,a as M,g as j,_ as F}from"./page-activity-ActivityDetail-346b11b6.js";import{L as W}from"./page-activity-DailySignIn-96ec389f.js";import"./native/index-a8a2a0fc.js";import"./en-43c55ab8.js";import"./page-activity-Championship-f7467ceb.js";window.getBuildInfo=function(){return{buildTime:"3/15/2025, 9:01:28 PM",branch:" commitId:c8ca98fce6fc864cab311715d288030620d0dc9f"}};const Q={class:"redeem-container"},X={class:"redeem-container-header"},Y={class:"redeem-container-header-belly"},Z={alt:""},J={class:"redeem-container-content"},K={class:"redeem-container-receive"},O=["placeholder"],ee={key:0},te={class:"redeem-container-record"},se={class:"redeem-container-record-title"},ae={class:"redeem-container-record-itemsBox"},oe={class:"redeem-container-record-item ar-1px-b"},ie={class:"redeem-container-record-item-left"},ne={class:"redeem-container-record-item-right"},re=["src"],de=R({__name:"index",setup(w){const{t:i}=I(),C=d(!1),y=N(),b=T(),n=d(b.query.hbcode||""),$=d(!0),m=A({pageSize:10,pageNo:1,startDate:null,endDate:null}),r=d({list:[],pageNo:0,totalPage:0,totalCount:0}),k=async()=>{if(n.value.trim()===""){await g({message:i("tipPlsEnterCode")});return}const e=await G({giftCode:n.value});if(e.code===0){q(i("redeemDialogDesc1")),n.value="",await P();return}e.msgCode===1007?await g({message:i("code1007")}):e.msgCode===235?await g({message:i("code235")}):S({message:`Error: ${e.msgCode?e.msgCode:""} 
 `+e.msg,wordBreak:"break-word"})},P=async()=>{const e=await H(h(m));e&&(r.value.list=e==null?void 0:e.data.list)};return(e,a)=>{const B=v("NavBar"),D=v("svg-icon"),L=V("lazy");return u(),l("div",Q,[t("div",X,[p(B,{title:e.$t("gift"),"left-arrow":"",onClickLeft:a[0]||(a[0]=s=>c(y).go(-1))},null,8,["title"]),t("div",Y,[_(t("img",Z,null,512),[[L,c(M)("main","gift")]])])]),t("div",J,[t("div",K,[t("p",null,o(e.$t("tipHelloVIP")),1),t("p",null,o(e.$t("tipWepreparedGift4u")),1),t("h4",null,o(e.$t("tipPlsEnterRedeemCode")),1),_(t("input",{type:"text","auto-complete":"new-password",autocomplete:"off",placeholder:e.$t("tipPlsEnterCode"),"onUpdate:modelValue":a[1]||(a[1]=s=>n.value=s)},null,8,O),[[x,n.value]]),C.value?(u(),l("h5",ee,o(e.$t("tipPlsBindBankcard")),1)):f("v-if",!0),t("button",{onClick:a[2]||(a[2]=s=>k())},o(e.$t("receive")),1)]),t("div",te,[t("div",se,[p(D,{name:"giftHistory"}),f(` <img :src="getIcons('main', 'gRecord')" /> `),t("span",null,o(e.$t("record")),1)]),t("div",ae,[p(W,{list:r.value.list,"onUpdate:list":a[3]||(a[3]=s=>r.value.list=s),"page-query":m,"onUpdate:pageQuery":a[4]||(a[4]=s=>m=s),api:c(h),distance:20,isAutoLoad:$.value},{content:E(()=>[(u(!0),l(U,null,z(r.value.list,s=>(u(),l("div",{class:"redeem-container-record-items",key:s.reserved},[t("div",oe,[t("div",ie,[t("h5",null,o(e.$t("receiveSuccess")),1),t("span",null,o(s.addTime),1)]),t("div",ne,[t("img",{src:c(j)("main","gold")},null,8,re),t("span",null,o(s.amount),1)])])]))),128))]),_:1},8,["list","page-query","api","isAutoLoad"])])])])])}}});const ve=F(de,[["__scopeId","data-v-695ca243"],["__file","/usr/local/jenkins-prod/workspace/ar077-india-jalwa/src/views/main/RedeemGift/index.vue"]]);export{ve as default};
//# sourceMappingURL=page-main-RedeemGift-37753511.js.map
