import{o as d,g as u,b as a,w as s,u as o,F as m,a as t,t as i,f as l,i as p}from"./app-BYcXwl4U.js";import{i as _,c as f}from"./app-a6cKceqE.js";import{_ as h}from"./app-BTdips4W.js";import{_ as g}from"./app-CQ-vNlMj.js";import{_ as v}from"./app-CignoBaV.js";import{P as w}from"./app-CberKKnC.js";import{D as k}from"./app-7GBSHA5C.js";import"./app-DCd54JMo.js";import"./app-MrAtUXr3.js";import"./app-BWSI2Z1R.js";import"./app-DPDEogA0.js";import"./app-DxjODhok.js";import"./app-CabATHnR.js";import"./app-BhzV4gWo.js";import"./app-CrjU8lgK.js";import"./app-Dm54XnL8.js";import"./app-Btbk6LWy.js";function y(){const{utils:r,Tea:e}=_(this);this.goBack=function(){window.history.back()},this.success=function(n){if(n.data.success){r.success("流量包购买成功",function(){window.location="/servers/packages"});return}n.data.orderCode.length>0&&(window.location="/finance/pay?code="+n.data.orderCode+"&from="+window.escape(window.location.toString())+"&returnURL=/servers/packages")},this.methodCode="@balance",this.changePayMethod=function(n){this.methodCode=n}}const x=["value"],b=["value"],C=["value"],I=["value"],N=t("td",{class:"title"},"流量包",-1),B=t("td",null,"价格",-1),S=t("td",null,"支付方式",-1),K={__name:"confirm",setup(r){const e=f(new y);return(n,c)=>(d(),u(m,null,[a(h,{"active-tab":"buy"}),a(g,{action:"$",onSuccess:o(e).success},{default:s(()=>[t("input",{type:"hidden",name:"packageId",value:o(e).packageId},null,8,x),t("input",{type:"hidden",name:"regionId",value:o(e).regionId},null,8,b),t("input",{type:"hidden",name:"periodId",value:o(e).periodId},null,8,C),t("input",{type:"hidden",name:"count",value:o(e).count},null,8,I),a(k,null,{default:s(()=>[t("tbody",null,[t("tr",null,[N,t("td",null,"["+i(o(e).packageName)+" / "+i(o(e).regionName)+" / "+i(o(e).periodName)+"] x "+i(o(e).count),1)]),t("tr",null,[B,t("td",null,"￥"+i(o(e).amount)+"元",1)]),t("tr",null,[S,t("td",null,[a(w)])])])]),_:1}),a(v,null,{default:s(()=>[l("确定购买")]),_:1}),l("   "),t("a",{href:"/servers/packages/buy",onClick:c[0]||(c[0]=p($=>o(e).goBack(),["prevent"]))},"上一步")]),_:1},8,["onSuccess"])],64))}};export{K as default};
