From f606bfb12b015ab9cbaf9039ec733f838fb26b2d Mon Sep 17 00:00:00 2001 From: xingyu4j Date: Thu, 17 Nov 2022 13:20:55 +0800 Subject: [PATCH] fix: inputnumber --- .../src/main/resources/codegen/vue3/views/data.ts.vm | 8 +++++--- .../src/views/Profile/components/BasicInfo.vue | 3 ++- .../src/views/system/oauth2/client/client.data.ts | 6 ++++-- 3 files changed, 11 insertions(+), 6 deletions(-) diff --git a/yudao-module-infra/yudao-module-infra-biz/src/main/resources/codegen/vue3/views/data.ts.vm b/yudao-module-infra/yudao-module-infra-biz/src/main/resources/codegen/vue3/views/data.ts.vm index 1e6755ea5..ed2775102 100644 --- a/yudao-module-infra/yudao-module-infra-biz/src/main/resources/codegen/vue3/views/data.ts.vm +++ b/yudao-module-infra/yudao-module-infra-biz/src/main/resources/codegen/vue3/views/data.ts.vm @@ -41,7 +41,6 @@ const crudSchemas = reactive({ #elseif(!("" != $column.dictType)) #if ($column.htmlType == "datetime")## 时间框 form: { - show: true, component: 'DatePicker', componentProps: { type: 'datetime', @@ -50,7 +49,6 @@ const crudSchemas = reactive({ }, #elseif($column.htmlType == "editor")## 文本编辑器 form: { - show: true, component: 'Editor', colProps: { span: 24 @@ -61,7 +59,6 @@ const crudSchemas = reactive({ }, #elseif($column.htmlType == "textarea")## 文本框 form: { - show: true, component: 'Input', componentProps: { type: 'textarea', @@ -71,6 +68,11 @@ const crudSchemas = reactive({ span: 24 } }, + #elseif(${column.javaType.toLowerCase()} == "long" || ${column.javaType.toLowerCase()} == "integer")## 数字类型 + form: { + component: 'InputNumber', + value: 0 + }, #end #end #if ($column.listOperationResult) diff --git a/yudao-ui-admin-vue3/src/views/Profile/components/BasicInfo.vue b/yudao-ui-admin-vue3/src/views/Profile/components/BasicInfo.vue index f84bffac3..f1811acdd 100644 --- a/yudao-ui-admin-vue3/src/views/Profile/components/BasicInfo.vue +++ b/yudao-ui-admin-vue3/src/views/Profile/components/BasicInfo.vue @@ -62,7 +62,8 @@ const schema = reactive([ { field: 'sex', label: t('profile.user.sex'), - component: 'InputNumber' + component: 'InputNumber', + value: 0 } ]) const sexVlue = ref() diff --git a/yudao-ui-admin-vue3/src/views/system/oauth2/client/client.data.ts b/yudao-ui-admin-vue3/src/views/system/oauth2/client/client.data.ts index 73f02b63b..766d60060 100644 --- a/yudao-ui-admin-vue3/src/views/system/oauth2/client/client.data.ts +++ b/yudao-ui-admin-vue3/src/views/system/oauth2/client/client.data.ts @@ -52,7 +52,8 @@ const crudSchemas = reactive({ title: '访问令牌的有效期', field: 'accessTokenValiditySeconds', form: { - component: 'InputNumber' + component: 'InputNumber', + value: 0 }, table: { slots: { @@ -64,7 +65,8 @@ const crudSchemas = reactive({ title: '刷新令牌的有效期', field: 'refreshTokenValiditySeconds', form: { - component: 'InputNumber' + component: 'InputNumber', + value: 0 }, table: { slots: {