mirror of
https://gitee.com/bootx/dax-pay-ui.git
synced 2025-09-03 10:56:00 +00:00
feat 微信只保留p12证书, 支付宝中证书直接以文本方式保存
This commit is contained in:
@@ -180,8 +180,8 @@
|
||||
showable,
|
||||
formEditType,
|
||||
} = useFormEdit()
|
||||
// 文件上传
|
||||
const { tokenHeader, uploadAction } = useUpload('/alipay/toBase64')
|
||||
// 读取证书内容
|
||||
const { tokenHeader, uploadAction } = useUpload('/alipay/readPem')
|
||||
const { createMessage } = useMessage()
|
||||
|
||||
const formRef = $ref<FormInstance>()
|
||||
|
@@ -73,50 +73,6 @@
|
||||
</template>
|
||||
</a-input>
|
||||
</a-form-item>
|
||||
<a-form-item label="证书(cert.pem)" name="certPem">
|
||||
<a-upload
|
||||
v-if="!form.certPem"
|
||||
:disabled="showable"
|
||||
name="file"
|
||||
:multiple="false"
|
||||
:action="uploadAction"
|
||||
:headers="tokenHeader"
|
||||
:showUploadList="false"
|
||||
@change="(info) => handleChange(info, 'certPem')"
|
||||
>
|
||||
<a-button type="primary" preIcon="carbon:cloud-upload"> 证书上传 </a-button>
|
||||
</a-upload>
|
||||
<a-input v-else defaultValue="cert.pem" disabled>
|
||||
<template #addonAfter v-if="!showable">
|
||||
<a-tooltip>
|
||||
<template #title> 删除上传的证书文件 </template>
|
||||
<icon @click="form.certPem = ''" icon="ant-design:close-circle-outlined" :size="20" />
|
||||
</a-tooltip>
|
||||
</template>
|
||||
</a-input>
|
||||
</a-form-item>
|
||||
<a-form-item label="私钥(key.pem)" name="keyPem">
|
||||
<a-upload
|
||||
v-if="!form.keyPem"
|
||||
:disabled="showable"
|
||||
name="file"
|
||||
:multiple="false"
|
||||
:action="uploadAction"
|
||||
:headers="tokenHeader"
|
||||
:showUploadList="false"
|
||||
@change="(info) => handleChange(info, 'keyPem')"
|
||||
>
|
||||
<a-button type="primary" preIcon="carbon:cloud-upload"> 私钥上传 </a-button>
|
||||
</a-upload>
|
||||
<a-input v-else defaultValue="key.pem" disabled>
|
||||
<template #addonAfter v-if="!showable">
|
||||
<a-tooltip>
|
||||
<template #title> 删除上传的证书文件 </template>
|
||||
<icon @click="form.keyPem = ''" icon="ant-design:close-circle-outlined" :size="20" />
|
||||
</a-tooltip>
|
||||
</template>
|
||||
</a-input>
|
||||
</a-form-item>
|
||||
<a-form-item label="APIv2密钥" name="apiKeyV2">
|
||||
<a-textarea :rows="3" :disabled="showable" v-model:value="form.apiKeyV2" placeholder="请输入APIv2密钥" />
|
||||
</a-form-item>
|
||||
@@ -185,8 +141,6 @@
|
||||
p12: null,
|
||||
apiKeyV2: '',
|
||||
apiKeyV3: '',
|
||||
keyPem: '',
|
||||
certPem: '',
|
||||
domain: '',
|
||||
notifyUrl: '',
|
||||
returnUrl: '',
|
||||
|
@@ -114,10 +114,6 @@ export interface WechatPayConfig extends BaseEntity {
|
||||
appSecret?: string
|
||||
// p12的文件id
|
||||
p12?: string | null
|
||||
// API 证书中的 cert.pem
|
||||
certPem?: string
|
||||
// API 证书中的 key.pem
|
||||
keyPem?: string
|
||||
// 应用域名,回调中会使用此参数
|
||||
domain?: string
|
||||
// 服务器异步通知页面路径
|
||||
|
@@ -85,7 +85,7 @@
|
||||
// 查询条件
|
||||
const fields = [
|
||||
{ field: 'name', type: STRING, name: '参数名称', placeholder: '请输入字典名称' },
|
||||
{ field: 'paramKey', type: STRING, name: '分组标签', placeholder: '请输入分组标签' },
|
||||
{ field: 'paramKey', type: STRING, name: '参数键名', placeholder: '请输入参数键名' },
|
||||
] as QueryField[]
|
||||
|
||||
const xTable = $ref<VxeTableInstance>()
|
||||
|
Reference in New Issue
Block a user