diff --git a/docs/guide/use/aliyun/index.md b/docs/guide/use/aliyun/index.md index c4268a953..3fb527ec0 100644 --- a/docs/guide/use/aliyun/index.md +++ b/docs/guide/use/aliyun/index.md @@ -17,4 +17,5 @@ ALIYUN_CLIENT_READ_TIMEOUT=10000 #读取数据超时,单位毫秒 * 申请证书 :`AliyunDNSFullAccess` * 上传证书到阿里云: `AliyunYundunCertFullAccess` * 部署证书到OSS: `AliyunYundunCertFullAccess`、`AliyunOSSFullAccess` -* 部署证书到CDN: `AliyunYundunCertFullAccess`、`AliyunCDNFullAccess` \ No newline at end of file +* 部署证书到CDN: `AliyunYundunCertFullAccess`、`AliyunCDNFullAccess` +* 部署证书到DCDN: `AliyunYundunCertFullAccess`、`AliyunDCDNFullAccess` \ No newline at end of file diff --git a/packages/ui/certd-client/src/router/source/modules/certd.ts b/packages/ui/certd-client/src/router/source/modules/certd.ts index a86cc063e..c8e185513 100644 --- a/packages/ui/certd-client/src/router/source/modules/certd.ts +++ b/packages/ui/certd-client/src/router/source/modules/certd.ts @@ -55,7 +55,7 @@ export const certdResources = [ path: "/certd/notification", component: "/certd/notification/index.vue", meta: { - icon: "ion:disc-outline", + icon: "ion:megaphone-outline", auth: true, cache: true } diff --git a/packages/ui/certd-client/src/views/certd/notification/common.tsx b/packages/ui/certd-client/src/views/certd/notification/common.tsx index c96f9f14c..508ef7f21 100644 --- a/packages/ui/certd-client/src/views/certd/notification/common.tsx +++ b/packages/ui/certd-client/src/views/certd/notification/common.tsx @@ -62,20 +62,6 @@ export function getCommonColumnDefine(crudExpose: any, typeRef: any, api: any) { show: false } }, - name: { - title: "通知名称", - search: { - show: true - }, - type: ["text"], - form: { - rules: [{ required: true, message: "请填写名称" }], - helper: "随便填,当多个相同类型的通知时,便于区分" - }, - column: { - width: 200 - } - }, type: { title: "通知类型", type: "dict-select", @@ -110,12 +96,18 @@ export function getCommonColumnDefine(crudExpose: any, typeRef: any, api: any) { if (value == null) { return; } + const lastTitle = currentDefine.value?.title; const define = await api.GetProviderDefine(value); currentDefine.value = define; console.log("define", define); + if (!immediate) { form.body = {}; } + + if (!form.name || form.name === lastTitle) { + form.name = define.title; + } buildDefineFields(define, form, mode); } }, @@ -128,9 +120,26 @@ export function getCommonColumnDefine(crudExpose: any, typeRef: any, api: any) { }) } } as ColumnCompositionProps, + name: { + title: "通知名称", + search: { + show: true + }, + type: ["text"], + form: { + rules: [{ required: true, message: "请填写名称" }], + helper: "随便填,当多个相同类型的通知时,便于区分" + }, + column: { + width: 200 + } + }, test: { title: "测试", form: { + show: compute(({ form }) => { + return !!form.type; + }), component: { name: "api-test", type: "notification", diff --git a/packages/ui/certd-server/src/plugins/plugin-notification/qywx/index.ts b/packages/ui/certd-server/src/plugins/plugin-notification/qywx/index.ts index 6ee26d9ed..1dba81003 100644 --- a/packages/ui/certd-server/src/plugins/plugin-notification/qywx/index.ts +++ b/packages/ui/certd-server/src/plugins/plugin-notification/qywx/index.ts @@ -11,6 +11,7 @@ export class QywxNotification extends BaseNotification { component: { placeholder: 'https://qyapi.weixin.qq.com/cgi-bin/webhook/send?key=xxxxx', }, + helper: '[企微群聊机器人配置说明](https://developer.work.weixin.qq.com/document/path/91770)', required: true, }) webhook = '';