import{_ as e,f as a,i,w as t,h as s}from"./index-4c745ab9.js";import{o as l,a as n,g as m,t as u,u as d,k as v,l as o,q as c,f as r,h as f,w as _,e as h,ar as p,F as g,i as j}from"./vendor-edc0678f.js";/* empty css              */import{t as b,k as y}from"./filters-692458bf.js";import{p as O,i as w}from"./index-478984b7.js";const R={class:"recordItem"},x={class:"item"},k={class:"itemRight"},T={class:"item"},U={class:"itemRight fw-num"},I={class:"item"},C={class:"itemRight fw-num"},D={class:"item"},L={class:"itemRight fw-num"},S={class:"item"},A={class:"itemRight fw-num"},E={class:"item"},F={class:"itemRight fw-num"},N={class:"item"},q=e({__name:"recordItem",props:{itemObj:{type:Object,default:{}}},setup:e=>(t,s)=>(l(),n("div",R,[m("div",x,[m("div",null,u(d(a)("fund_name")),1),m("div",k,u(e.itemObj.planTitle),1)]),m("div",T,[m("div",null,u(d(a)("Lock-up_days")),1),m("div",U,u(e.itemObj.days),1)]),m("div",I,[m("div",null,u(d(a)("host_dailyrateof_return")),1),m("div",C,u(e.itemObj.avgRate)+"%",1)]),m("div",D,[m("div",null,u(d(a)("investment_amount")),1),m("div",L,u(e.itemObj.amount)+" "+u(e.itemObj.coin?e.itemObj.coin.toUpperCase():""),1)]),m("div",S,[m("div",null,u(d(a)("Estimated income")),1),m("div",A,u(d(i)(e.itemObj.amount*e.itemObj.days*.05/100,6))+" "+u(e.itemObj.coin?e.itemObj.coin.toUpperCase():""),1)]),m("div",E,[m("div",null,u(d(a)("Arrival_time")),1),m("div",F,u(d(b)(e.itemObj.settlementType,e.itemObj.days,e.itemObj.params.createTime)),1)]),m("div",N,[m("div",null,u(d(a)("mining_status")),1),m("div",{class:"itemRight fw-num",style:v({color:d(y)(e.itemObj.status).color})},u(d(y)(e.itemObj.status).name),5)])]))},[["__scopeId","data-v-42460100"]]),H={class:"columnFlex"},K={class:"invest"},z={class:"item"},B={class:"itemRight fw-num"},G={class:"item"},J={class:"itemRight fw-num"},M={class:"item"},P={class:"itemRight blueColor fw-num"},Q={class:"item"},V={class:"itemRight fw-num"},W={class:"record"},X={class:"recordList"},Y=e({__name:"myInvestment",setup(e){const i=o({}),v=o([]),b=o(1),y=o(5),R=o(!1),x=o(!1),k=o(!1),T=o(0),U=async()=>{try{const e=await I();v.value=[...v.value,...e],0===v.value.length?R.value=!0:R.value=!1,v.value.length===T.value&&(k.value=!0),b.value++}catch(e){}finally{x.value=!1}},I=async()=>{try{const e=await w(b.value,y.value);if(200===e.code)return T.value=e.total,e.rows;k.value=!0}catch(e){}};return c(()=>{(async()=>{try{const e=await O();200===e.code&&(i.value=e.data)}catch(e){}})(),U()}),(e,o)=>{const c=p,b=s;return l(),n("div",H,[r(t,{currentName:d(a)("my_invest")},null,8,["currentName"]),m("div",K,[m("div",z,[m("div",null,u(d(a)("sum_bet_value")),1),m("div",B,u(i.value.sumAmount)+" USDT",1)]),m("div",G,[m("div",null,u(d(a)("earn_rewards")),1),m("div",J,u(i.value.commission)+" USDT",1)]),m("div",M,[m("div",null,u(d(a)("Cumulative_income")),1),m("div",P,u(i.value.sumEarn)+" USDT",1)]),m("div",Q,[m("div",null,u(d(a)("number_of_positions")),1),m("div",V,u(i.value.position),1)])]),m("div",W,u(d(a)("transaction_record")),1),m("div",X,[v.value.length>0&&!R.value?(l(),f(c,{key:0,loading:x.value,"onUpdate:loading":o[0]||(o[0]=e=>x.value=e),finished:k.value,"finished-text":d(a)("no_more_data"),"loading-text":d(a)("loading"),onLoad:U},{default:_(()=>[(l(!0),n(g,null,j(v.value,e=>(l(),f(q,{key:e,itemObj:e},null,8,["itemObj"]))),128))]),_:1},8,["loading","finished","finished-text","loading-text"])):h("",!0),0===v.value.length&&R.value?(l(),f(b,{key:1})):h("",!0)])])}}},[["__scopeId","data-v-a872cefe"]]);export{Y as default};
