diff --git a/packages/ui/certd-client/src/locales/langs/en-US/certd.ts b/packages/ui/certd-client/src/locales/langs/en-US/certd.ts index 4e734a54..60c1d71a 100644 --- a/packages/ui/certd-client/src/locales/langs/en-US/certd.ts +++ b/packages/ui/certd-client/src/locales/langs/en-US/certd.ts @@ -564,7 +564,7 @@ export default { ipv6Priority: "IPv6 Priority", dualStackNetworkHelper: "If IPv6 priority is selected, enable IPv6 in docker-compose.yaml", enableCommonCnameService: "Enable Public CNAME Service", - commonCnameHelper: "Allow use of public CNAME service. If disabled and no custom CNAME service is set, CNAME proxy certificate application will not work.", + commonCnameHelper: "Allow use of public CNAME service. If disabled and no custom CNAME service is set, CNAME proxy certificate application will not work.", enableCommonSelfServicePasswordRetrieval: "Enable self-service password recovery", saveButton: "Save", stopSuccess: "Stopped successfully", diff --git a/packages/ui/certd-client/src/locales/langs/zh-CN/certd.ts b/packages/ui/certd-client/src/locales/langs/zh-CN/certd.ts index ec961220..60ea53a5 100644 --- a/packages/ui/certd-client/src/locales/langs/zh-CN/certd.ts +++ b/packages/ui/certd-client/src/locales/langs/zh-CN/certd.ts @@ -570,7 +570,7 @@ export default { ipv6Priority: "IPV6优先", dualStackNetworkHelper: "如果选择IPv6优先,需要在docker-compose.yaml中启用ipv6", enableCommonCnameService: "启用公共CNAME服务", - commonCnameHelper: "是否可以使用公共CNAME服务,如果禁用,且没有设置自定义CNAME服务,则无法使用CNAME代理方式申请证书", + commonCnameHelper: "是否可以使用公共CNAME服务,如果禁用,且没有设置自定义CNAME服务,则无法使用CNAME代理方式申请证书", enableCommonSelfServicePasswordRetrieval: "启用自助找回密码", saveButton: "保存", stopSuccess: "停止成功", diff --git a/packages/ui/certd-client/src/store/plugin/index.ts b/packages/ui/certd-client/src/store/plugin/index.ts index 7f600f08..079fab20 100644 --- a/packages/ui/certd-client/src/store/plugin/index.ts +++ b/packages/ui/certd-client/src/store/plugin/index.ts @@ -1,7 +1,8 @@ import { defineStore } from "pinia"; import * as api from "./api.plugin"; -import { DynamicType, FormItemProps } from "@fast-crud/fast-crud"; +import { DynamicType, FormItemProps, useMerge } from "@fast-crud/fast-crud"; import { i18n } from "/src/locales/i18n"; +import { cloneDeep } from "lodash-es"; interface PluginState { group?: PluginGroups; } @@ -32,14 +33,17 @@ export class PluginGroups { groups!: { [key: string]: PluginGroup }; map!: { [key: string]: PluginDefine }; t: any; - constructor(groups: { [key: string]: PluginGroup }) { + mergeSetting?: boolean; + constructor(groups: { [key: string]: PluginGroup }, opts?: { mergeSetting?: boolean }) { this.groups = groups; this.t = i18n.global.t; + this.mergeSetting = opts?.mergeSetting ?? false; this.initGroup(groups); this.initMap(); } private initGroup(groups: { [p: string]: PluginGroup }) { + const { merge } = useMerge(); const all: PluginGroup = { key: "all", title: this.t("certd.all"), @@ -48,6 +52,14 @@ export class PluginGroups { icon: "material-symbols:border-all-rounded", }; for (const key in groups) { + if (this.mergeSetting) { + for (const plugin of groups[key].plugins) { + if (plugin.sysSetting) { + merge(plugin.input, plugin.sysSetting.metadata); + } + } + } + all.plugins.push(...groups[key].plugins); } this.groups = { @@ -132,11 +144,15 @@ export const usePluginStore = defineStore({ id: "app.plugin", state: (): PluginState => ({ group: null, + originGroup: null, }), actions: { async reload() { const groups = await api.GetGroups({}); - this.group = new PluginGroups(groups); + this.group = new PluginGroups(groups, { mergeSetting: true }); + this.originGroup = new PluginGroups(cloneDeep(groups)); + console.log("group", this.group); + console.log("originGroup", this.originGroup); }, async init() { if (!this.group) { @@ -159,6 +175,10 @@ export const usePluginStore = defineStore({ await this.init(); return this.group.get(name); }, + async getPluginDefineFromOrigin(name: string): Promise { + await this.init(); + return this.originGroup.get(name); + }, async getPluginConfig(query: any) { return await api.GetPluginConfig(query); }, diff --git a/packages/ui/certd-client/src/style/common.less b/packages/ui/certd-client/src/style/common.less index 8f5c3b54..70336dd0 100644 --- a/packages/ui/certd-client/src/style/common.less +++ b/packages/ui/certd-client/src/style/common.less @@ -304,3 +304,11 @@ h6 { padding: 10px; color: #6e6e6e; } + +.ant-modal-body{ + .fs-form-body{ + max-height: 66vh; + overflow-y: auto; + } + +} \ No newline at end of file diff --git a/packages/ui/certd-client/src/views/certd/pipeline/certd-form/use.tsx b/packages/ui/certd-client/src/views/certd/pipeline/certd-form/use.tsx index 74c89195..dd6ff4d5 100644 --- a/packages/ui/certd-client/src/views/certd/pipeline/certd-form/use.tsx +++ b/packages/ui/certd-client/src/views/certd/pipeline/certd-form/use.tsx @@ -138,6 +138,7 @@ export function useCertPipelineCreator() { form: { doSubmit, wrapper: { + wrapClassName: "cert_pipeline_create_form", width: 1350, saveRemind: false, title: t("certd.pipelineForm.createTitle"), diff --git a/packages/ui/certd-client/src/views/certd/pipeline/index.vue b/packages/ui/certd-client/src/views/certd/pipeline/index.vue index b337fda4..164a1a79 100644 --- a/packages/ui/certd-client/src/views/certd/pipeline/index.vue +++ b/packages/ui/certd-client/src/views/certd/pipeline/index.vue @@ -115,4 +115,13 @@ function batchRerun() { padding-left: 10px; } } + +.cert_pipeline_create_form { + .ant-collapse { + margin: 10px; + } + .ant-collapse-header { + text-align: right; + } +} diff --git a/packages/ui/certd-client/src/views/framework/login/index.vue b/packages/ui/certd-client/src/views/framework/login/index.vue index 1f6a0a71..604aa0d3 100644 --- a/packages/ui/certd-client/src/views/framework/login/index.vue +++ b/packages/ui/certd-client/src/views/framework/login/index.vue @@ -43,7 +43,7 @@ -