import{C as b,N,r as n,R as w,D as y,E as i,F as t,ay as P,K as u,M as d,al as v,ar as B,am as f,I as s}from"./common.modules-7b90237f.js";import{E as z}from"./page-activity-Bonus-9d46271c.js";import{M as A}from"./MayrecordList-f448cde7.js";import{bw as q,_ as x}from"./page-activity-ActivityDetail-27bd7cf0.js";const E={class:"MyGameRecord__C"},F={key:0,class:"MyGameRecord__C-head"},S={class:"MyGameRecord__C-body"},V={key:1,class:"MyGameRecord__C-body-empty"},D={key:1,class:"MyGameRecord__C-foot"},H={class:"MyGameRecord__C-foot-page"},I=b({__name:"MyGameRecord",props:{typeid:{type:Number,required:!0},ApiFun:{type:Function,required:!0},goPathName:{type:String,required:!0},hasHead:{type:Boolean,required:!0,default:!0}},setup(g,{expose:C}){const l=g,M=N(),_=n(4),G=n(20),a=n(1),r=n([]),R=o=>{M.push({name:o})},h=()=>{a.value--,c()},k=()=>{a.value++,c()},c=async(o=!1)=>{if(l.typeid==null)return;o&&(a.value=1);const[m,e]=await q(l.ApiFun({pageSize:G.value,pageNo:a.value,typeId:l.typeid}));e&&(r.value=(e==null?void 0:e.list)||[],_.value=(e==null?void 0:e.totalPage)||0)};return C({getData:c}),w(()=>{c()}),(o,m)=>{const e=y("svg-icon"),p=y("van-icon");return s(),i("div",E,[o.hasHead?(s(),i("div",F,[t("div",{class:"MyGameRecord__C-head-moreB",onClick:m[0]||(m[0]=L=>R(o.goPathName))},[P(u(o.$t("more"))+" ",1),d(e,{name:"rightCircle"})])])):v("v-if",!0),t("div",S,[r.value.length?(s(),B(A,{key:0,mayrecord:r.value},null,8,["mayrecord"])):(s(),i("div",V,[d(z)]))]),r.value.length?(s(),i("div",D,[t("div",{class:f(["MyGameRecord__C-foot-previous",{disabled:a.value<=1}]),onClick:h},[d(p,{name:"arrow-left",class:"MyGameRecord__C-icon",size:"20"})],2),t("div",H,u(a.value)+"/"+u(_.value),1),t("div",{class:f(["MyGameRecord__C-foot-next",{disabled:a.value>=_.value}]),onClick:k},[d(p,{name:"arrow",class:"MyGameRecord__C-icon",size:"20"})],2)])):v("v-if",!0)])}}});const T=x(I,[["__scopeId","data-v-4b21e13b"],["__file","/usr/local/jenkins-prod/workspace/ar079-india-tashanwin/src/components/Home/AllLotteryGames/WinGo/MyGameRecord.vue"]]);export{T as M};
