mirror of
https://gitee.com/niucloud-team/niucloud-admin.git
synced 2026-01-05 04:38:09 +00:00
2 lines
7.3 KiB
JavaScript
2 lines
7.3 KiB
JavaScript
import"./base-0e92f4db.js";/* empty css *//* empty css */import{a as E,E as k}from"./el-form-item-c2dd2ffe.js";/* empty css */import{_ as S}from"./index.vue_vue_type_style_index_0_lang-3c5de079.js";/* empty css *//* empty css */import{aj as q,ak as T}from"./index-9033603c.js";import{t as e}from"./index-8f29cb04.js";import{u as U}from"./vue-router-8b032575.js";import{E as F}from"./index-72686045.js";import{E as R}from"./index-dd8098b2.js";import{E as B}from"./index-8cefa3ab.js";import{E as D}from"./index-2668a8ea.js";import{E as K}from"./index-e09a20f5.js";import{v as N}from"./directive-c6f70b8e.js";import{d as j,r as y,M as L,c as W,Q as $,b,e as z,q as a,p as c,f as i,x as p,u as t,L as A,m as M,v as Q}from"./runtime-core.esm-bundler-67034826.js";import{_ as G}from"./_plugin-vue_export-helper-c27b6911.js";import"./event-a537c4cb.js";/* empty css */import"./common-46715e7e.js";import"./index-e9d9b1a1.js";import"./index-6cae7119.js";import"./focus-trap-83769a43.js";import"./index-434046cb.js";import"./index-81f2aa1e.js";import"./el-main-7a89c415.js";import"./index-ebd2990f.js";import"./el-overlay-3eff2fc5.js";import"./index-defed8ff.js";import"./index-d87ae4a2.js";/* empty css */import"./index-ef31373f.js";import"./index-de22cd40.js";const H={class:"main-container"},J={class:"flex items-center"},O={class:"text-base"},X={class:"flex ml-[18px] justify-between items-center mt-[20px]"},Y={class:"text-[20px]"},Z={class:"panel-title !text-sm"},ee={class:"form-tip"},ae={class:"form-tip"},te={class:"input-width"},le={class:"form-tip"},oe={class:"input-width"},re={class:"form-tip"},ie={class:"panel-title !text-sm"},ce={class:"form-tip"},pe={class:"input-width"},se={class:"input-width"},_e={class:"input-width"},ne={class:"fixed-footer-wrap"},de={class:"fixed-footer"},me=j({__name:"transfer",setup(ue){const w=U().meta.title,_=y(!1),l=L({...{wechatpay_config:{mch_id:"",mch_secret_key:"",mch_secret_cert:"",mch_public_cert_path:""},alipay_config:{app_secret_cert:"",app_public_cert_path:"",alipay_public_cert_path:"",alipay_root_cert_path:"",app_id:""}}});(async()=>{_.value=!0;let n=await(await q("transfer")).data;n&&n.length&&(l.wechatpay_config=n[0].config,l.alipay_config=n[1].config),_.value=!1})();const u=y(),v=W(()=>({"wechatpay_config.mch_id":[{required:!0,message:e("mchIdPlaceholder"),trigger:"blur"}],"wechatpay_config.mch_secret_key":[{required:!0,message:e("mchSecretKeyPlaceholder"),trigger:"blur"}],"wechatpay_config.mch_secret_cert":[{required:!0,message:e("mchSecretCertPlaceholder"),trigger:"blur"}],"wechatpay_config.mch_public_cert_path":[{required:!0,message:e("mchPublicCertPathPlaceholder"),trigger:"blur"}],"alipay_config.app_id":[{required:!0,message:e("appIdPlaceholder"),trigger:"blur"}],"alipay_config.app_secret_cert":[{required:!0,message:e("appSecretCertPlaceholder"),trigger:"blur"}],"alipay_config.app_public_cert_path":[{required:!0,message:e("appPublicCertPathPlaceholder"),trigger:"blur"}],"alipay_config.alipay_public_cert_path":[{required:!0,message:e("alipayPublicCertPathPlaceholder"),trigger:"blur"}],"alipay_config.alipay_root_cert_path":[{required:!0,message:e("alipayRootCertPathPlaceholder"),trigger:"blur"}]})),V=async n=>{_.value||!n||await n.validate(async o=>{o&&(_.value=!0,T(l).then(f=>{_.value=!1}).catch(()=>{_.value=!1}))})};return(n,o)=>{const h=$("Warning"),f=F,P=R,m=B,s=E,d=S,g=D,x=k,C=K,I=N;return b(),z("div",H,[a(P,{class:"warm-prompt",type:"info"},{default:c(()=>[i("div",J,[a(f,{class:"mr-2",size:"18"},{default:c(()=>[a(h)]),_:1}),i("p",O,p(t(e)("operationTip")),1)])]),_:1}),i("div",X,[i("span",Y,p(t(w)),1)]),A((b(),M(x,{model:l,"label-width":"200px",ref_key:"formRef",ref:u,rules:t(v),class:"page-form"},{default:c(()=>[a(g,{class:"box-card !border-none",shadow:"never"},{default:c(()=>[i("h3",Z,p(t(e)("wechatpay")),1),a(s,{label:t(e)("mchId"),prop:"wechatpay_config.mch_id"},{default:c(()=>[a(m,{modelValue:l.wechatpay_config.mch_id,"onUpdate:modelValue":o[0]||(o[0]=r=>l.wechatpay_config.mch_id=r),placeholder:t(e)("mchIdPlaceholder"),class:"input-width",maxlength:"32","show-word-limit":"",clearable:""},null,8,["modelValue","placeholder"]),i("div",ee,p(t(e)("mchIdTips")),1)]),_:1},8,["label"]),a(s,{label:t(e)("mchSecretKey"),prop:"wechatpay_config.mch_secret_key"},{default:c(()=>[a(m,{modelValue:l.wechatpay_config.mch_secret_key,"onUpdate:modelValue":o[1]||(o[1]=r=>l.wechatpay_config.mch_secret_key=r),placeholder:t(e)("mchSecretKeyPlaceholder"),class:"input-width",maxlength:"32","show-word-limit":"",clearable:""},null,8,["modelValue","placeholder"]),i("div",ae,p(t(e)("mchSecretKeyTips")),1)]),_:1},8,["label"]),a(s,{label:t(e)("mchSecretCert"),prop:"wechatpay_config.mch_secret_cert"},{default:c(()=>[i("div",te,[a(d,{modelValue:l.wechatpay_config.mch_secret_cert,"onUpdate:modelValue":o[2]||(o[2]=r=>l.wechatpay_config.mch_secret_cert=r),api:"sys/document/wechat"},null,8,["modelValue"])]),i("div",le,p(t(e)("mchSecretCertTips")),1)]),_:1},8,["label"]),a(s,{label:t(e)("mchPublicCertPath"),prop:"wechatpay_config.mch_public_cert_path"},{default:c(()=>[i("div",oe,[a(d,{modelValue:l.wechatpay_config.mch_public_cert_path,"onUpdate:modelValue":o[3]||(o[3]=r=>l.wechatpay_config.mch_public_cert_path=r),api:"sys/document/wechat"},null,8,["modelValue"])]),i("div",re,p(t(e)("mchPublicCertPathTips")),1)]),_:1},8,["label"])]),_:1}),a(g,{class:"box-card mt-4 !border-none",shadow:"never"},{default:c(()=>[i("h3",ie,p(t(e)("alipay")),1),a(s,{label:t(e)("appId"),prop:"alipay_config.app_id"},{default:c(()=>[a(m,{modelValue:l.alipay_config.app_id,"onUpdate:modelValue":o[4]||(o[4]=r=>l.alipay_config.app_id=r),placeholder:t(e)("appIdPlaceholder"),class:"input-width",maxlength:"32","show-word-limit":"",clearable:""},null,8,["modelValue","placeholder"]),i("div",ce,p(t(e)("appIdTips")),1)]),_:1},8,["label"]),a(s,{label:t(e)("appSecretCert"),prop:"alipay_config.app_secret_cert"},{default:c(()=>[a(m,{modelValue:l.alipay_config.app_secret_cert,"onUpdate:modelValue":o[5]||(o[5]=r=>l.alipay_config.app_secret_cert=r),placeholder:t(e)("appSecretCertPlaceholder"),class:"input-width",type:"textarea",rows:"4",clearable:""},null,8,["modelValue","placeholder"])]),_:1},8,["label"]),a(s,{label:t(e)("appPublicCertPath"),prop:"alipay_config.app_public_cert_path"},{default:c(()=>[i("div",pe,[a(d,{modelValue:l.alipay_config.app_public_cert_path,"onUpdate:modelValue":o[6]||(o[6]=r=>l.alipay_config.app_public_cert_path=r),api:"sys/document/aliyun"},null,8,["modelValue"])])]),_:1},8,["label"]),a(s,{label:t(e)("alipayPublicCertPath"),prop:"alipay_config.alipay_public_cert_path"},{default:c(()=>[i("div",se,[a(d,{modelValue:l.alipay_config.alipay_public_cert_path,"onUpdate:modelValue":o[7]||(o[7]=r=>l.alipay_config.alipay_public_cert_path=r),api:"sys/document/aliyun"},null,8,["modelValue"])])]),_:1},8,["label"]),a(s,{label:t(e)("alipayRootCertPath"),prop:"alipay_config.alipay_root_cert_path"},{default:c(()=>[i("div",_e,[a(d,{modelValue:l.alipay_config.alipay_root_cert_path,"onUpdate:modelValue":o[8]||(o[8]=r=>l.alipay_config.alipay_root_cert_path=r),api:"sys/document/aliyun"},null,8,["modelValue"])])]),_:1},8,["label"])]),_:1})]),_:1},8,["model","rules"])),[[I,_.value]]),i("div",ne,[i("div",de,[a(C,{type:"primary",loading:_.value,onClick:o[9]||(o[9]=r=>V(u.value))},{default:c(()=>[Q(p(t(e)("save")),1)]),_:1},8,["loading"])])])])}}});const Ze=G(me,[["__scopeId","data-v-e027528a"]]);export{Ze as default};
|