From b2d3abd9d6412097febfe2027300d84f3888d144 Mon Sep 17 00:00:00 2001
From: 疯狂的狮子li <15040126243@163.com>
Date: 星期四, 03 三月 2022 11:18:10 +0800
Subject: [PATCH] update 优化去除sql差异化 时间范围统一使用 between 处理
---
ruoyi-generator/src/main/resources/vm/vue/index.vue.vm | 37 ++++++++++++++++++++++++++++++++-----
1 files changed, 32 insertions(+), 5 deletions(-)
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 279144d..760ba85 100644
--- a/ruoyi-generator/src/main/resources/vm/vue/index.vue.vm
+++ b/ruoyi-generator/src/main/resources/vm/vue/index.vue.vm
@@ -44,7 +44,7 @@
v-model="queryParams.${column.javaField}"
type="date"
value-format="yyyy-MM-dd"
- placeholder="閫夋嫨${comment}">
+ placeholder="璇烽�夋嫨${comment}">
</el-date-picker>
</el-form-item>
#elseif($column.htmlType == "datetime" && $column.queryType == "BETWEEN")
@@ -268,7 +268,7 @@
v-model="form.${field}"
type="datetime"
value-format="yyyy-MM-dd HH:mm:ss"
- placeholder="閫夋嫨${comment}">
+ placeholder="璇烽�夋嫨${comment}">
</el-date-picker>
</el-form-item>
#elseif($column.htmlType == "textarea")
@@ -300,10 +300,37 @@
#set($comment=$column.columnComment)
#end
#if($column.pk || $javaField == ${subTableFkclassName})
-#elseif($column.list && "" != $javaField)
- <el-table-column label="$comment" prop="${javaField}">
+#elseif($column.list && $column.htmlType == "input")
+ <el-table-column label="$comment" prop="${javaField}" width="150">
<template slot-scope="scope">
<el-input v-model="scope.row.$javaField" placeholder="璇疯緭鍏�$comment" />
+ </template>
+ </el-table-column>
+#elseif($column.list && $column.htmlType == "datetime")
+ <el-table-column label="$comment" prop="${javaField}" width="240">
+ <template slot-scope="scope">
+ <el-date-picker clearable v-model="scope.row.$javaField" type="date" value-format="yyyy-MM-dd" placeholder="璇烽�夋嫨$comment" />
+ </template>
+ </el-table-column>
+#elseif($column.list && ($column.htmlType == "select" || $column.htmlType == "radio") && "" != $column.dictType)
+ <el-table-column label="$comment" prop="${javaField}" width="150">
+ <template slot-scope="scope">
+ <el-select v-model="scope.row.$javaField" placeholder="璇烽�夋嫨$comment">
+ <el-option
+ v-for="dict in dict.type.$column.dictType"
+ :key="dict.value"
+ :label="dict.label"
+ :value="dict.value"
+ ></el-option>
+ </el-select>
+ </template>
+ </el-table-column>
+#elseif($column.list && ($column.htmlType == "select" || $column.htmlType == "radio") && "" == $column.dictType)
+ <el-table-column label="$comment" prop="${javaField}" width="150">
+ <template slot-scope="scope">
+ <el-select v-model="scope.row.$javaField" placeholder="璇烽�夋嫨$comment">
+ <el-option label="璇烽�夋嫨瀛楀吀鐢熸垚" value="" />
+ </el-select>
</template>
</el-table-column>
#end
@@ -541,7 +568,7 @@
});
},
#if($table.sub)
- /** ${subTable.functionName}搴忓彿 */
+ /** ${subTable.functionName}搴忓彿 */
row${subClassName}Index({ row, rowIndex }) {
row.index = rowIndex + 1;
},
--
Gitblit v1.9.3