Files

2 lines
1.3 KiB
JavaScript
Raw Permalink Normal View History

2026-04-07 02:04:22 +05:30
import{a4 as P,R as w,r as o,c as f}from"./vue-core-DJjvd5ZC.js?v=1773287522785";import{aW as x,i as L}from"./index-BTglIPU2.js?v=1773287522785";const D=P("global-pay",()=>{const{t:s}=w(),n=o("pro"),a=o(s("Component.Pay.index_1")),u=o(s("Component.Pay.index_2")),l=o("100000058"),r=o(27),i=o(""),v=o(!0),c=o([]),p=e=>{n.value=e.key,l.value=e.pid,a.value=e.label,u.value=e.desc},m=e=>{r.value=e},_=e=>{i.value=e},g=e=>{c.value=[e]},h=e=>{v.value=e},t=o({status:0,end_time:0,obtain_id:0,total:0,length:0}),y=f(()=>!(t.value.status===1&&t.value.length<=0||t.value.total===0||t.value.end_time-Math.floor(Date.now()/1e3)<=0)),C=f(()=>t.value.status!==1||t.value.end_time-Math.floor(Date.now()/1e3)<=0?!1:t.value.length>0),b=async()=>{const{message:e}=await x();return L(e)&&(t.value.status=e.status,t.value.end_time=e.end_time,t.value.obtain_id=e.obtain_id,t.value.length=e.coupons.length,t.value.total=e.total),e},d=o(!1);return{pid:l,type:n,label:a,desc:u,source:r,username:i,ssl:v,plugins:c,orderLoad:d,receiveCoupon:t,showCoupon:y,showCouponModal:C,reset:()=>{n.value="pro",a.value=s("Component.Pay.index_1"),u.value=s("Component.Pay.index_2"),l.value="100000058",r.value=27,i.value="",c.value=[]},setSsl:h,setMenu:p,setSource:m,setUsername:_,setPlugins:g,setOrderLoad:e=>{d.value=e},getReceiveCoupon:b}});export{D as u};