import{az as x,d as L,b as d,c as n,e as u,f as r,h as l,i as t,F as c,j as _,k as p,g as E,u as m,m as i,t as F,E as N,_ as q}from"./index.0308b213.js";const T=()=>x.get("addon/payment.web.payment_setting/getSetting"),$=g=>x.post("addon/payment.web.payment_setting/setSetting",g),j={class:"setting-form"},z={style:{display:"flex",width:"100%"}},M=i("\u5220\u9664"),R=i("\u6DFB\u52A0"),G={class:"operation-btn"},H=i("\u63D0\u4EA4"),J=L({setup(g){const a=d({detail:[]});d({list:[]});const C=()=>{$(a).then(o=>{console.log(o),N.success("\u8BBE\u7F6E\u6210\u529F")})};(()=>{T().then(o=>{console.log(o),a.detail=o.data.detail||[],console.log("setting",a)})})();const D=d({list:[{label:"\u7528\u6237\u5145\u503C",value:"recharge"},{label:"\u8DD1\u817F",value:"errander"},{label:"\u5957\u9910\u7EA2\u5305",value:"mealRedpacket"},{label:"\u9884\u5B58\u91D1\u5145\u503C",value:"store_recharge"},{label:"\u7535\u5F71\u7968",value:"movie"},{label:"\u8D85\u7EA7vip",value:"svip"}]}),k=d({list:[{label:"\u539F\u751F\u652F\u4ED8",value:"native"},{label:"\u5408\u5229\u5B9D",value:"helibao"},{label:"\u5929\u9619\u968F\u884C\u4ED8",value:"tianque"}]}),V=()=>{a.detail.push({order_type:"",payment:""}),console.log("setting.detail",a.detail)},w=o=>{a.detail.splice(o,1),console.log("setting.detail",a.detail)};return(o,b)=>{const f=n("el-option"),v=n("el-select"),y=n("el-link"),h=n("el-form-item"),A=n("el-form"),B=n("el-card"),S=n("el-button");return u(),r("div",j,[l(B,{shadow:"always",style:{"margin-top":"20px"}},{default:t(()=>[l(A,{"label-width":"170px"},{default:t(()=>[(u(!0),r(c,null,_(m(a).detail,(s,U)=>(u(),p(h,{label:"\u8BA2\u5355\u7C7B\u578B\u8BBE\u7F6E",prop:"detail"},{default:t(()=>[E("view",z,[l(v,{class:"tn-el-form-item--item",modelValue:s.order_type,"onUpdate:modelValue":e=>s.order_type=e,"aria-placeholder":"\u9009\u62E9\u8BA2\u5355\u7C7B\u578B",filterable:"",clearable:""},{default:t(()=>[(u(!0),r(c,null,_(m(D).list,(e,I)=>(u(),p(f,{value:e.value,label:e.label},{default:t(()=>[i(F(e.label),1)]),_:2},1032,["value","label"]))),256))]),_:2},1032,["modelValue","onUpdate:modelValue"]),l(v,{class:"tn-el-form-item--item",modelValue:s.payment,"onUpdate:modelValue":e=>s.payment=e,"aria-placeholder":"\u9009\u62E9\u9ED8\u8BA4\u652F\u4ED8\u65B9\u5F0F",filterable:"",clearable:""},{default:t(()=>[(u(!0),r(c,null,_(m(k).list,(e,I)=>(u(),p(f,{value:e.value,label:e.label},{default:t(()=>[i(F(e.label),1)]),_:2},1032,["value","label"]))),256))]),_:2},1032,["modelValue","onUpdate:modelValue"]),l(y,{type:"danger",onClick:e=>w(U),style:{"margin-left":"10px"}},{default:t(()=>[M]),_:2},1032,["onClick"])])]),_:2},1024))),256)),l(h,{label:""},{default:t(()=>[l(y,{type:"primary",onClick:b[0]||(b[0]=s=>V())},{default:t(()=>[R]),_:1})]),_:1})]),_:1})]),_:1}),l(B,{shadow:"always",style:{"margin-top":"20px"}},{default:t(()=>[E("div",G,[l(S,{type:"primary",onClick:C},{default:t(()=>[H]),_:1})])]),_:1})])}}});const P=q(J,[["__scopeId","data-v-87f25783"]]);export{P as default};
