From f11db02ff84efaf69a881a5ffc9f42d1c19a11a8 Mon Sep 17 00:00:00 2001 From: RuoYi Date: Thu, 8 Dec 2022 10:19:38 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E4=BB=A3=E7=A0=81=E7=94=9F?= =?UTF-8?q?=E6=88=90=E5=9B=BE=E7=89=87/=E6=96=87=E4=BB=B6/=E5=8D=95?= =?UTF-8?q?=E9=80=89=E6=97=B6=E9=80=89=E6=8B=A9=E5=BF=85=E5=A1=AB=E6=97=A0?= =?UTF-8?q?=E6=B3=95=E6=A0=A1=E9=AA=8C=E9=97=AE=E9=A2=98(I64IO2)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../main/resources/vm/vue/index-tree.vue.vm | 33 ++++++++++--------- .../src/main/resources/vm/vue/index.vue.vm | 32 ++++++++++-------- .../resources/vm/vue/v3/index-tree.vue.vm | 33 ++++++++++--------- .../src/main/resources/vm/vue/v3/index.vue.vm | 32 ++++++++++-------- 4 files changed, 72 insertions(+), 58 deletions(-) diff --git a/ruoyi-generator/src/main/resources/vm/vue/index-tree.vue.vm b/ruoyi-generator/src/main/resources/vm/vue/index-tree.vue.vm index 9d29ace..b7fdb62 100644 --- a/ruoyi-generator/src/main/resources/vm/vue/index-tree.vue.vm +++ b/ruoyi-generator/src/main/resources/vm/vue/index-tree.vue.vm @@ -187,11 +187,11 @@ #elseif($column.htmlType == "imageUpload") - + #elseif($column.htmlType == "fileUpload") - + #elseif($column.htmlType == "editor") @@ -205,8 +205,11 @@ v-for="dict in dict.type.${dictType}" :key="dict.value" :label="dict.label" - #if($column.javaType == "Integer" || $column.javaType == "Long"):value="parseInt(dict.value)"#else:value="dict.value"#end - +#if($column.javaType == "Integer" || $column.javaType == "Long") + :value="parseInt(dict.value)" +#else + :value="dict.value" +#end > @@ -217,7 +220,7 @@ #elseif($column.htmlType == "checkbox" && "" != $dictType) - + #elseif($column.htmlType == "checkbox" && $dictType) - + 请选择字典生成 #elseif($column.htmlType == "radio" && "" != $dictType) - + {{dict.label}} #elseif($column.htmlType == "radio" && $dictType) - + 请选择字典生成 @@ -335,7 +341,7 @@ export default { #set($comment=$column.columnComment) #end $column.javaField: [ - { required: true, message: "$comment不能为空", trigger: #if($column.htmlType == "select")"change"#else"blur"#end } + { required: true, message: "$comment不能为空", trigger: #if($column.htmlType == "select" || $column.htmlType == "radio")"change"#else"blur"#end } ]#if($foreach.count != $columns.size()),#end #end #end @@ -398,10 +404,7 @@ export default { reset() { this.form = { #foreach ($column in $columns) -#if($column.htmlType == "radio") - $column.javaField: #if($column.javaType == "Integer" || $column.javaType == "Long")0#else"0"#end#if($foreach.count != $columns.size()),#end - -#elseif($column.htmlType == "checkbox") +#if($column.htmlType == "checkbox") $column.javaField: []#if($foreach.count != $columns.size()),#end #else $column.javaField: null#if($foreach.count != $columns.size()),#end diff --git a/ruoyi-generator/src/main/resources/vm/vue/index.vue.vm b/ruoyi-generator/src/main/resources/vm/vue/index.vue.vm index 8daa05e..70ff30d 100644 --- a/ruoyi-generator/src/main/resources/vm/vue/index.vue.vm +++ b/ruoyi-generator/src/main/resources/vm/vue/index.vue.vm @@ -198,11 +198,11 @@ #elseif($column.htmlType == "imageUpload") - + #elseif($column.htmlType == "fileUpload") - + #elseif($column.htmlType == "editor") @@ -216,8 +216,11 @@ v-for="dict in dict.type.${dictType}" :key="dict.value" :label="dict.label" - #if($column.javaType == "Integer" || $column.javaType == "Long"):value="parseInt(dict.value)"#else:value="dict.value"#end - +#if($column.javaType == "Integer" || $column.javaType == "Long") + :value="parseInt(dict.value)" +#else + :value="dict.value" +#end > @@ -228,7 +231,7 @@ #elseif($column.htmlType == "checkbox" && "" != $dictType) - + #elseif($column.htmlType == "checkbox" && $dictType) - + 请选择字典生成 #elseif($column.htmlType == "radio" && "" != $dictType) - + {{dict.label}} #elseif($column.htmlType == "radio" && $dictType) - + 请选择字典生成 @@ -412,7 +418,7 @@ export default { #set($comment=$column.columnComment) #end $column.javaField: [ - { required: true, message: "$comment不能为空", trigger: #if($column.htmlType == "select")"change"#else"blur"#end } + { required: true, message: "$comment不能为空", trigger: #if($column.htmlType == "select" || $column.htmlType == "radio")"change"#else"blur"#end } ]#if($foreach.count != $columns.size()),#end #end #end @@ -456,9 +462,7 @@ export default { reset() { this.form = { #foreach ($column in $columns) -#if($column.htmlType == "radio") - $column.javaField: #if($column.javaType == "Integer" || $column.javaType == "Long")0#else"0"#end#if($foreach.count != $columns.size()),#end -#elseif($column.htmlType == "checkbox") +#if($column.htmlType == "checkbox") $column.javaField: []#if($foreach.count != $columns.size()),#end #else $column.javaField: null#if($foreach.count != $columns.size()),#end diff --git a/ruoyi-generator/src/main/resources/vm/vue/v3/index-tree.vue.vm b/ruoyi-generator/src/main/resources/vm/vue/v3/index-tree.vue.vm index 559683a..405d7d6 100644 --- a/ruoyi-generator/src/main/resources/vm/vue/v3/index-tree.vue.vm +++ b/ruoyi-generator/src/main/resources/vm/vue/v3/index-tree.vue.vm @@ -174,11 +174,11 @@ #elseif($column.htmlType == "imageUpload") - + #elseif($column.htmlType == "fileUpload") - + #elseif($column.htmlType == "editor") @@ -192,8 +192,11 @@ v-for="dict in ${dictType}" :key="dict.value" :label="dict.label" - #if($column.javaType == "Integer" || $column.javaType == "Long"):value="parseInt(dict.value)"#else:value="dict.value"#end - +#if($column.javaType == "Integer" || $column.javaType == "Long") + :value="parseInt(dict.value)" +#else + :value="dict.value" +#end > @@ -204,7 +207,7 @@ #elseif($column.htmlType == "checkbox" && "" != $dictType) - + #elseif($column.htmlType == "checkbox" && $dictType) - + 请选择字典生成 #elseif($column.htmlType == "radio" && "" != $dictType) - + {{dict.label}} #elseif($column.htmlType == "radio" && $dictType) - + 请选择字典生成 @@ -308,7 +314,7 @@ const data = reactive({ #set($comment=$column.columnComment) #end $column.javaField: [ - { required: true, message: "$comment不能为空", trigger: #if($column.htmlType == "select")"change"#else"blur"#end } + { required: true, message: "$comment不能为空", trigger: #if($column.htmlType == "select" || $column.htmlType == "radio")"change"#else"blur"#end } ]#if($foreach.count != $columns.size()),#end #end #end @@ -361,10 +367,7 @@ function cancel() { function reset() { form.value = { #foreach ($column in $columns) -#if($column.htmlType == "radio") - $column.javaField: #if($column.javaType == "Integer" || $column.javaType == "Long")0#else"0"#end#if($foreach.count != $columns.size()),#end - -#elseif($column.htmlType == "checkbox") +#if($column.htmlType == "checkbox") $column.javaField: []#if($foreach.count != $columns.size()),#end #else $column.javaField: null#if($foreach.count != $columns.size()),#end diff --git a/ruoyi-generator/src/main/resources/vm/vue/v3/index.vue.vm b/ruoyi-generator/src/main/resources/vm/vue/v3/index.vue.vm index 8fae449..8b25665 100644 --- a/ruoyi-generator/src/main/resources/vm/vue/v3/index.vue.vm +++ b/ruoyi-generator/src/main/resources/vm/vue/v3/index.vue.vm @@ -181,11 +181,11 @@ #elseif($column.htmlType == "imageUpload") - + #elseif($column.htmlType == "fileUpload") - + #elseif($column.htmlType == "editor") @@ -199,8 +199,11 @@ v-for="dict in ${dictType}" :key="dict.value" :label="dict.label" - #if($column.javaType == "Integer" || $column.javaType == "Long"):value="parseInt(dict.value)"#else:value="dict.value"#end - +#if($column.javaType == "Integer" || $column.javaType == "Long") + :value="parseInt(dict.value)" +#else + :value="dict.value" +#end > @@ -211,7 +214,7 @@ #elseif($column.htmlType == "checkbox" && "" != $dictType) - + #elseif($column.htmlType == "checkbox" && $dictType) - + 请选择字典生成 #elseif($column.htmlType == "radio" && "" != $dictType) - + {{dict.label}} #elseif($column.htmlType == "radio" && $dictType) - + 请选择字典生成 @@ -388,7 +394,7 @@ const data = reactive({ #set($comment=$column.columnComment) #end $column.javaField: [ - { required: true, message: "$comment不能为空", trigger: #if($column.htmlType == "select")"change"#else"blur"#end } + { required: true, message: "$comment不能为空", trigger: #if($column.htmlType == "select" || $column.htmlType == "radio")"change"#else"blur"#end } ]#if($foreach.count != $columns.size()),#end #end #end @@ -432,9 +438,7 @@ function cancel() { function reset() { form.value = { #foreach ($column in $columns) -#if($column.htmlType == "radio") - $column.javaField: #if($column.javaType == "Integer" || $column.javaType == "Long")0#else"0"#end#if($foreach.count != $columns.size()),#end -#elseif($column.htmlType == "checkbox") +#if($column.htmlType == "checkbox") $column.javaField: []#if($foreach.count != $columns.size()),#end #else $column.javaField: null#if($foreach.count != $columns.size()),#end