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 e43393412..9c31d0d6a 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
@@ -38,15 +38,28 @@
-#elseif($column.htmlType == "datetime")
+#elseif($column.htmlType == "datetime" && $column.queryType != "BETWEEN")
-
+#elseif($column.htmlType == "datetime" && $column.queryType == "BETWEEN")
+
+
+
#end
#end
#end
@@ -201,7 +214,7 @@
#elseif($column.htmlType == "datetime")
- {
this.${businessName}List = this.handleTree(response.data, "${treeCode}", "${treeParentCode}");
this.loading = false;
@@ -397,6 +429,12 @@ export default {
},
/** 重置按钮操作 */
resetQuery() {
+#foreach ($column in $columns)
+#if($column.htmlType == "datetime" && $column.queryType == "BETWEEN")
+#set($AttrName=$column.javaField.substring(0,1).toUpperCase() + ${column.javaField.substring(1)})
+ this.daterange${AttrName} = [];
+#end
+#end
this.resetForm("queryForm");
this.handleQuery();
},
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 e667b1098..8ff104711 100644
--- a/ruoyi-generator/src/main/resources/vm/vue/index.vue.vm
+++ b/ruoyi-generator/src/main/resources/vm/vue/index.vue.vm
@@ -38,15 +38,28 @@
-#elseif($column.htmlType == "datetime")
+#elseif($column.htmlType == "datetime" && $column.queryType != "BETWEEN")
-
+#elseif($column.htmlType == "datetime" && $column.queryType == "BETWEEN")
+
+
+
#end
#end
#end
@@ -95,7 +108,7 @@
v-hasPermi="['${moduleName}:${businessName}:export']"
>导出
-
+
@@ -230,7 +243,7 @@
#elseif($column.htmlType == "datetime")
- {
this.${businessName}List = response.rows;
this.total = response.total;
@@ -413,6 +445,12 @@ export default {
},
/** 重置按钮操作 */
resetQuery() {
+#foreach ($column in $columns)
+#if($column.htmlType == "datetime" && $column.queryType == "BETWEEN")
+#set($AttrName=$column.javaField.substring(0,1).toUpperCase() + ${column.javaField.substring(1)})
+ this.daterange${AttrName} = [];
+#end
+#end
this.resetForm("queryForm");
this.handleQuery();
},
diff --git a/ruoyi-ui/src/utils/ruoyi.js b/ruoyi-ui/src/utils/ruoyi.js
index 0cecbc0b2..81ee9c70b 100644
--- a/ruoyi-ui/src/utils/ruoyi.js
+++ b/ruoyi-ui/src/utils/ruoyi.js
@@ -62,8 +62,8 @@ export function addDateRange(params, dateRange, propName) {
search.params["beginTime"] = dateRange[0];
search.params["endTime"] = dateRange[1];
} else {
- search.params[propName + "BeginTime"] = dateRange[0];
- search.params[propName + "EndTime"] = dateRange[1];
+ search.params["begin" + propName] = dateRange[0];
+ search.params["end" + propName] = dateRange[1];
}
}
return search;