jformGraphreportItemList.vm 12 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201
  1. <script type="text/javascript">
  2. jQuery('#addJformGraphreportItemBtn').linkbutton({
  3. iconCls: 'icon-add'
  4. });
  5. jQuery('#delJformGraphreportItemBtn').linkbutton({
  6. iconCls: 'icon-remove'
  7. });
  8. jQuery('#addJformGraphreportItemBtn').bind('click',function() {
  9. var tr = $("#add_jformGraphreportItem_table_template tr").clone();
  10. $("#add_jformGraphreportItem_table").append(tr);
  11. resetTrNum('add_jformGraphreportItem_table');
  12. return false;
  13. });
  14. jQuery('#delJformGraphreportItemBtn').bind('click',function() {
  15. $("#add_jformGraphreportItem_table").find("input:checked").parent().parent().remove();
  16. resetTrNum('add_jformGraphreportItem_table');
  17. return false;
  18. });
  19. jQuery(document).ready(function() {
  20. $(".datagrid-toolbar").parent().css("width", "auto");
  21. if (location.href.indexOf("load=detail") != -1) {
  22. $(":input").attr("disabled", "true");
  23. $(".datagrid-toolbar").hide();
  24. }
  25. //将表格的表头固定
  26. $("#jformGraphreportItem_table").createhftable({
  27. height: '300px',
  28. width: 'auto',
  29. fixFooter: false
  30. });
  31. });
  32. </script>
  33. </head>
  34. <body>
  35. <div style="padding: 3px; height: 25px;width:auto;" class="datagrid-toolbar">
  36. <a id="addJformGraphreportItemBtn" href="#">添加</a>
  37. <a id="delJformGraphreportItemBtn" href="#">删除</a></div>
  38. <table border="0" cellpadding="2" cellspacing="0" id="jformGraphreportItem_table">
  39. <tr bgcolor="#E6E6E6">
  40. <td align="center" bgcolor="#EEEEEE">序号</td>
  41. <td align="center" bgcolor="#EEEEEE">操作</td>
  42. <td align="left" bgcolor="#EEEEEE">字段名</td>
  43. <td align="left" bgcolor="#EEEEEE">字段文本</td>
  44. <td align="left" bgcolor="#EEEEEE">排序</td>
  45. <td align="left" bgcolor="#EEEEEE">字段类型</td>
  46. <td align="left" bgcolor="#EEEEEE">是否显示</td>
  47. <td align="left" bgcolor="#EEEEEE">是否查询</td>
  48. <td align="left" bgcolor="#EEEEEE">查询模式</td>
  49. <td align="left" bgcolor="#EEEEEE">字典Code</td>
  50. <td align="left" bgcolor="#EEEEEE">显示图表</td>
  51. <td align="left" bgcolor="#EEEEEE">图表类型</td>
  52. <td align="left" bgcolor="#EEEEEE">图表名称</td>
  53. <td align="left" bgcolor="#EEEEEE">标签名称</td>
  54. </tr>
  55. <tbody id="add_jformGraphreportItem_table">
  56. #if($!{jformGraphreportItemList})
  57. #if($!jformGraphreportItemList.size() == 0)
  58. <tr>
  59. <td align="center">
  60. <div style="width: 25px;" name="xh">1</div></td>
  61. <td align="center">
  62. <input style="width:20px;" type="checkbox" name="ck" /></td>
  63. <td align="left">
  64. <input name="jformGraphreportItemList[#index#].fieldName" maxlength="36" type="text" class="inputxt" style="width:120px;">
  65. <label class="Validform_label" style="display: none;">字段名</label></td>
  66. <td align="left">
  67. <input name="jformGraphreportItemList[#index#].fieldTxt" maxlength="1000" type="text" class="inputxt" style="width:120px;">
  68. <label class="Validform_label" style="display: none;">字段文本</label></td>
  69. <td align="left">
  70. <input name="jformGraphreportItemList[#index#].orderNum" maxlength="10" type="text" class="inputxt" style="width:40px;">
  71. <label class="Validform_label" style="display: none;">排序</label></td>
  72. <td align="left">
  73. <select name="jformGraphreportItemList[#index#].fieldType">
  74. <option value="">---请选择---</option>
  75. <option value="Integer">数值类型</option>
  76. <option value="Date">日期类型</option>
  77. <option value="String" selected="selected">字符类型</option>
  78. <option value="Long">长整型</option></select>
  79. </select>
  80. <label class="Validform_label" style="display: none;">字段类型</label></td>
  81. <td align="left">
  82. <select name="jformGraphreportItemList[#index#].isShow">
  83. <option value="">--请选择--</option>
  84. <option value="Y">显示</option>
  85. <option value="N">隐藏</option></select>
  86. <label class="Validform_label" style="display: none;">是否显示</label></td>
  87. <td align="left">
  88. <select name="jformGraphreportItemList[#index#].searchFlag">
  89. <option value="" selected="selected">---请选择---</option>
  90. <option value="Y">是</option>
  91. <option value="N">否</option></select>
  92. <label class="Validform_label" style="display: none;">是否查询</label></td>
  93. <td align="left">
  94. <select name="jformGraphreportItemList[#index#].searchMode">
  95. <option value="" selected="selected">---请选择---</option>
  96. <option value="single">单条件查询</option>
  97. <option value="group">范围查询</option></select>
  98. <label class="Validform_label" style="display: none;">查询模式</label></td>
  99. <td align="left">
  100. <input name="jformGraphreportItemList[#index#].dictCode" maxlength="500" type="text" class="inputxt" style="width:120px;">
  101. <label class="Validform_label" style="display: none;">字典Code</label></td>
  102. <td align="left">
  103. <select name="jformGraphreportItemList[#index#].isGraph">
  104. <option value="" selected="selected">---请选择---</option>
  105. <option value="Y">是</option>
  106. <option value="N">否</option></select>
  107. <label class="Validform_label" style="display: none;">显示图表</label></td>
  108. <td align="left">
  109. <select name="jformGraphreportItemList[#index#].graphType">
  110. <option value="" selected="selected">---请选择---</option>
  111. <option value="spline">曲线图</option>
  112. <option value="column">柱状图</option>
  113. <option value="pie">饼图</option></select>
  114. <label class="Validform_label" style="display: none;">图表类型</label></td>
  115. <td align="left">
  116. <input name="jformGraphreportItemList[#index#].graphName" maxlength="100" type="text" class="inputxt" style="width:120px;">
  117. <label class="Validform_label" style="display: none;">图表名称</label></td>
  118. <td align="left">
  119. <input name="jformGraphreportItemList[#index#].tabName" maxlength="50" type="text" class="inputxt" style="width:120px;">
  120. <label class="Validform_label" style="display: none;">标签名称</label></td>
  121. </tr>
  122. #else
  123. #set($count=0)
  124. #foreach($!{item} in $!{jformGraphreportItemList})
  125. <tr>
  126. <td align="center">
  127. <div style="width: 25px;" name="xh">$!{velocityCount}</div></td>
  128. <td align="center">
  129. <input style="width:20px;" type="checkbox" name="ck" /></td>
  130. <td align="left">
  131. <input name="jformGraphreportItemList[$count].fieldName" maxlength="36" type="text" class="inputxt" style="width:120px;" value="$!{item.fieldName}">
  132. <label class="Validform_label" style="display: none;">字段名</label></td>
  133. <td align="left">
  134. <input name="jformGraphreportItemList[$count].fieldTxt" maxlength="1000" type="text" class="inputxt" style="width:120px;" value="$!{item.fieldTxt}">
  135. <label class="Validform_label" style="display: none;">字段文本</label></td>
  136. <td align="left">
  137. <input name="jformGraphreportItemList[$count].orderNum" maxlength="10" type="text" class="inputxt" style="width:40px;" value="$!{item.orderNum}">
  138. <label class="Validform_label" style="display: none;">排序</label></td>
  139. <td align="left">
  140. <select name="jformGraphreportItemList[$count].fieldType">
  141. <option value="">---请选择---</option>
  142. <option value="Integer" #if($!item.fieldType=='Integer' )selected="selected" #end>数值类型</option>
  143. <option value="Date" #if($!item.fieldType=='Date' )selected="selected" #end>日期类型</option>
  144. <option value="String" #if($!item.fieldType=='String' )selected="selected" #end>字符类型</option>
  145. <option value="Long" #if($!item.fieldType=='Long' )selected="selected" #end>长整型</option></select>
  146. </select>
  147. <label class="Validform_label" style="display: none;">字段类型</label></td>
  148. <td align="left">
  149. <select name="jformGraphreportItemList[$count].isShow">
  150. <option value="">--请选择--</option>
  151. <option value="Y" #if($!item.isShow=='Y' )selected="selected" #end>显示</option>
  152. <option value="N" #if($!item.isShow=='N' )selected="selected" #end>隐藏</option></select>
  153. <label class="Validform_label" style="display: none;">是否显示</label></td>
  154. <td align="left">
  155. <select name="jformGraphreportItemList[$count].searchFlag">
  156. <option value="" selected="selected">---请选择---</option>
  157. <option value="Y" #if($!item.searchFlag=='Y' )selected="selected" #end>是</option>
  158. <option value="N" #if($!item.searchFlag=='N' )selected="selected" #end>否</option></select>
  159. <label class="Validform_label" style="display: none;">是否查询</label></td>
  160. <td align="left">
  161. <select name="jformGraphreportItemList[$count].searchMode">
  162. <option value="" selected="selected">---请选择---</option>
  163. <option value="single" #if($!item.searchMode=='single' )selected="selected" #end>单条件查询</option>
  164. <option value="group" #if($!item.searchMode=='group' )selected="selected" #end>范围查询</option></select>
  165. <label class="Validform_label" style="display: none;">查询模式</label></td>
  166. <td align="left">
  167. <input name="jformGraphreportItemList[$count].dictCode" maxlength="500" type="text" class="inputxt" style="width:120px;" value="$!{item.dictCode}">
  168. <label class="Validform_label" style="display: none;">字典Code</label></td>
  169. <td align="left">
  170. <select name="jformGraphreportItemList[$count].isGraph">
  171. <option value="">---请选择---</option>
  172. <option value="Y" #if($!item.isGraph=='Y' )selected="selected" #end>是</option>
  173. <option value="N" #if($!item.isGraph=='N' )selected="selected" #end>否</option></select>
  174. <label class="Validform_label" style="display: none;">显示图表</label></td>
  175. <td align="left">
  176. <select name="jformGraphreportItemList[$count].graphType">
  177. <option value="">---请选择---</option>
  178. <option value="spline" #if($!item.graphType=='spline' )selected="selected" #end>曲线图</option>
  179. <option value="column" #if($!item.graphType=='column' )selected="selected" #end>柱状图</option>
  180. <option value="pie" #if($!item.graphType=='pie' )selected="selected" #end>饼图</option></select>
  181. <label class="Validform_label" style="display: none;">图表类型</label></td>
  182. <td align="left">
  183. <input name="jformGraphreportItemList[$count].graphName" maxlength="100" type="text" class="inputxt" style="width:120px;" value="$!{item.graphName}">
  184. <label class="Validform_label" style="display: none;">图表名称</label></td>
  185. <td align="left">
  186. <input name="jformGraphreportItemList[$count].tabName" maxlength="50" type="text" class="inputxt" style="width:120px;" value="$!{item.tabName}">
  187. <label class="Validform_label" style="display: none;">标签名称</label></td>
  188. </tr>
  189. #set($count=$count+1)
  190. #end
  191. #end
  192. #end
  193. </tbody>
  194. </table>