修正普通文本框字段如果查询方式为BETWEEN,list.html无法正确生成代码的问题

pull/549/head
K.X 2025-03-28 09:34:18 +08:00
parent 9c9567a5e7
commit f7942187e0
2 changed files with 25 additions and 11 deletions

View File

@ -17,14 +17,21 @@
#set($parentheseIndex=$column.columnComment.indexOf("")) #set($parentheseIndex=$column.columnComment.indexOf(""))
#if($parentheseIndex != -1) #if($parentheseIndex != -1)
#set($comment=$column.columnComment.substring(0, $parentheseIndex)) #set($comment=$column.columnComment.substring(0, $parentheseIndex))
#else #else
#set($comment=$column.columnComment) #set($comment=$column.columnComment)
#end #end
#if($column.htmlType == "input") #if($column.htmlType == "input" && $column.queryType != "BETWEEN")
<li> <li>
<label>${comment}</label> <label>${comment}</label>
<input type="text" name="${column.javaField}"/> <input type="text" name="${column.javaField}"/>
</li> </li>
#elseif($column.htmlType == "input" && $column.queryType == "BETWEEN")
<li class="select-time">
<label>${comment}</label>
<input type="text" id="begin${AttrName}" placeholder="开始${comment}" name="params[begin${AttrName}]"/>
<span>-</span>
<input type="text" id="end${AttrName}" placeholder="结束${comment}" name="params[end${AttrName}]"/>
</li>
#elseif(($column.htmlType == "select" || $column.htmlType == "radio") && "" != $dictType) #elseif(($column.htmlType == "select" || $column.htmlType == "radio") && "" != $dictType)
<li> <li>
<label>${comment}</label> <label>${comment}</label>
@ -52,7 +59,7 @@
<input type="text" class="time-input" id="startTime" placeholder="开始时间" name="params[begin${AttrName}]"/> <input type="text" class="time-input" id="startTime" placeholder="开始时间" name="params[begin${AttrName}]"/>
<span>-</span> <span>-</span>
<input type="text" class="time-input" id="endTime" placeholder="结束时间" name="params[end${AttrName}]"/> <input type="text" class="time-input" id="endTime" placeholder="结束时间" name="params[end${AttrName}]"/>
</li> </li>
#end #end
#end #end
#end #end
@ -133,7 +140,7 @@
title: '${comment}', title: '${comment}',
align: 'left' align: 'left'
}, },
#end #end
#end #end
{ {
title: '操作', title: '操作',
@ -152,4 +159,4 @@
}); });
</script> </script>
</body> </body>
</html> </html>

View File

@ -17,14 +17,21 @@
#set($parentheseIndex=$column.columnComment.indexOf("")) #set($parentheseIndex=$column.columnComment.indexOf(""))
#if($parentheseIndex != -1) #if($parentheseIndex != -1)
#set($comment=$column.columnComment.substring(0, $parentheseIndex)) #set($comment=$column.columnComment.substring(0, $parentheseIndex))
#else #else
#set($comment=$column.columnComment) #set($comment=$column.columnComment)
#end #end
#if($column.htmlType == "input") #if($column.htmlType == "input" && $column.queryType != "BETWEEN")
<li> <li>
<label>${comment}</label> <label>${comment}</label>
<input type="text" name="${column.javaField}"/> <input type="text" name="${column.javaField}"/>
</li> </li>
#elseif($column.htmlType == "input" && $column.queryType == "BETWEEN")
<li class="select-time">
<label>${comment}</label>
<input type="text" id="begin${AttrName}" placeholder="开始${comment}" name="params[begin${AttrName}]"/>
<span>-</span>
<input type="text" id="end${AttrName}" placeholder="结束${comment}" name="params[end${AttrName}]"/>
</li>
#elseif(($column.htmlType == "select" || $column.htmlType == "radio") && "" != $dictType) #elseif(($column.htmlType == "select" || $column.htmlType == "radio") && "" != $dictType)
<li> <li>
<label>${comment}</label> <label>${comment}</label>
@ -134,7 +141,7 @@
field: '${javaField}', field: '${javaField}',
title: '${comment}' title: '${comment}'
}, },
#end #end
#end #end
{ {
title: '操作', title: '操作',
@ -151,4 +158,4 @@
}); });
</script> </script>
</body> </body>
</html> </html>