From 237f437c14709dd4e42181411ae361a27e4f6769 Mon Sep 17 00:00:00 2001 From: wangxiang <1827945911@qq.com> Date: Thu, 19 May 2022 16:07:59 +0800 Subject: [PATCH] =?UTF-8?q?=F0=9F=91=88=20=E9=87=8D=E6=9E=84=E5=AE=89?= =?UTF-8?q?=E5=85=A8=E6=A1=86=E6=9E=B6=E5=BA=95=E5=B1=82=E4=BB=A3=E7=A0=81?= =?UTF-8?q?=E6=94=AF=E6=8C=81=E5=BD=93=E5=89=8D=E7=94=A8=E6=88=B7=E4=BF=AE?= =?UTF-8?q?=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- kicc-ui/package.json | 1 + kicc-ui/src/views/system/tenant/TenantModal.vue | 13 ++++++++++++- kicc-ui/yarn.lock | 5 +++++ 3 files changed, 18 insertions(+), 1 deletion(-) diff --git a/kicc-ui/package.json b/kicc-ui/package.json index 6db4a11b..1d80afea 100644 --- a/kicc-ui/package.json +++ b/kicc-ui/package.json @@ -24,6 +24,7 @@ "type:check": "vue-tsc --noEmit --skipLibCheck" }, "dependencies": { + "@amap/amap-jsapi-loader": "1.0.1", "@iconify/iconify": "2.2.1", "@vueuse/core": "6.4.1", "@zxcvbn-ts/core": "2.0.1", diff --git a/kicc-ui/src/views/system/tenant/TenantModal.vue b/kicc-ui/src/views/system/tenant/TenantModal.vue index fd71d0ef..5d264d78 100644 --- a/kicc-ui/src/views/system/tenant/TenantModal.vue +++ b/kicc-ui/src/views/system/tenant/TenantModal.vue @@ -41,11 +41,22 @@ const props: Partial = { confirmLoading: false }; await updateSchema({ field: 'code', + componentProps: { + disabled: tag.value == 'edit' + }, rules: [ { required: true, whitespace: true, - message: '请输入多租户编码' + message: '请输入多租户编码!' + }, + { + len: 19, + message: '编码长度必须为19位!' + }, + { + pattern: new RegExp('^[0-9a-zA-Z_]{1,}$', 'g'), + message: '只允许包含数字,字母,下划线!' }, { validator: async (rule, value) => { diff --git a/kicc-ui/yarn.lock b/kicc-ui/yarn.lock index 6ec846ed..f7ff7c03 100644 --- a/kicc-ui/yarn.lock +++ b/kicc-ui/yarn.lock @@ -2,6 +2,11 @@ # yarn lockfile v1 +"@amap/amap-jsapi-loader@^1.0.1": + version "1.0.1" + resolved "https://registry.npmmirror.com/@amap/amap-jsapi-loader/-/amap-jsapi-loader-1.0.1.tgz#9ec4b4d5d2467eac451f6c852e35db69e9f9f0c0" + integrity sha512-nPyLKt7Ow/ThHLkSvn2etQlUzqxmTVgK7bIgwdBRTg2HK5668oN7xVxkaiRe3YZEzGzfV2XgH5Jmu2T73ljejw== + "@ampproject/remapping@^2.1.0": version "2.2.0" resolved "https://registry.npmmirror.com/@ampproject/remapping/-/remapping-2.2.0.tgz#56c133824780de3174aed5ab6834f3026790154d"