From 3a147141b1a5d67c92a5ce88a5313eaa62859e03 Mon Sep 17 00:00:00 2001 From: xiaojunnuo Date: Wed, 28 May 2025 11:22:39 +0800 Subject: [PATCH] =?UTF-8?q?perf:=20=E4=BC=98=E5=8C=96=E7=AB=99=E7=82=B9?= =?UTF-8?q?=E9=80=89=E6=8B=A9=E7=BB=84=E4=BB=B6=EF=BC=8C=E5=88=87=E6=8D=A2?= =?UTF-8?q?=E9=80=89=E6=8B=A9=E6=97=B6=E4=B8=8D=E5=88=B7=E6=96=B0=E5=88=97?= =?UTF-8?q?=E8=A1=A8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/core/pipeline/src/context/index.ts | 6 +- .../plugins/plugin-lib/src/common/util.ts | 5 ++ .../plugins/common/remote-select.vue | 65 +++++++++++---- .../plugins/plugin-refresh-cert.ts | 1 + pnpm-lock.yaml | 82 +++++++++---------- 5 files changed, 101 insertions(+), 58 deletions(-) diff --git a/packages/core/pipeline/src/context/index.ts b/packages/core/pipeline/src/context/index.ts index 38aab45e..0c35aef4 100644 --- a/packages/core/pipeline/src/context/index.ts +++ b/packages/core/pipeline/src/context/index.ts @@ -6,9 +6,9 @@ export type PipelineContext = IContext; export type PageReq = { offset?: number; limit?: number; - query?: string; - sortBy?: string; - sortOrder?: "asc" | "desc"; + searchKey?: string; + // sortBy?: string; + // sortOrder?: "asc" | "desc"; }; export type PageRes = { diff --git a/packages/plugins/plugin-lib/src/common/util.ts b/packages/plugins/plugin-lib/src/common/util.ts index d5a88b70..ba060170 100644 --- a/packages/plugins/plugin-lib/src/common/util.ts +++ b/packages/plugins/plugin-lib/src/common/util.ts @@ -39,6 +39,8 @@ export function createRemoteSelectInputDefine(opts?: { rules?: any; mergeScript?: string; search?: boolean; + pager?: boolean; + component?: any; }) { const title = opts?.title || "请选择"; const certDomainsInputKey = opts?.certDomainsInputKey || "certDomains"; @@ -49,6 +51,7 @@ export function createRemoteSelectInputDefine(opts?: { const watches = opts?.watches || []; const helper = opts?.helper || "请选择"; const search = opts?.search ?? false; + const pager = opts?.pager ?? true; let mode = "tags"; if (opts.multi === false) { mode = undefined; @@ -66,7 +69,9 @@ export function createRemoteSelectInputDefine(opts?: { typeName, action, search, + pager, watches: [certDomainsInputKey, accessIdInputKey, ...watches], + ...opts.component, }, rules: opts?.rules, required: opts.required ?? true, diff --git a/packages/ui/certd-client/src/components/plugins/common/remote-select.vue b/packages/ui/certd-client/src/components/plugins/common/remote-select.vue index 2b564bcb..05c24ffe 100644 --- a/packages/ui/certd-client/src/components/plugins/common/remote-select.vue +++ b/packages/ui/certd-client/src/components/plugins/common/remote-select.vue @@ -19,6 +19,10 @@ + +
+ +
@@ -32,7 +36,7 @@