cgDynamGraphConfigHead-update.jsp 8.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135
  1. <%@ page language="java" import="java.util.*" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
  2. <%@include file="/context/mytags.jsp"%>
  3. <!DOCTYPE html>
  4. <html>
  5. <head>
  6. <title>动态报表配置抬头</title>
  7. <t:base type="jquery,easyui,tools,DatePicker"></t:base>
  8. <script type="text/javascript">
  9. $(document).ready(function(){
  10. $('#tt').tabs({
  11. onSelect:function(title){
  12. $('#tt .panel-body').css('width','auto');
  13. }
  14. });
  15. $('#ttp').tabs({
  16. onSelect:function(title){
  17. $('#ttp .panel-body').css('width','auto');
  18. }
  19. });
  20. });
  21. //初始化下标
  22. function resetTrNum(tableId) {
  23. $tbody = $("#"+tableId+"");
  24. $tbody.find('>tr').each(function(i){
  25. $(':input, select,button,a', this).each(function(){
  26. var $this = $(this), name = $this.attr('name'),id=$this.attr('id'),onclick_str=$this.attr('onclick'), val = $this.val();
  27. if(name!=null){
  28. if (name.indexOf("#index#") >= 0){
  29. $this.attr("name",name.replace('#index#',i));
  30. }else{
  31. var s = name.indexOf("[");
  32. var e = name.indexOf("]");
  33. var new_name = name.substring(s+1,e);
  34. $this.attr("name",name.replace(new_name,i));
  35. }
  36. }
  37. if(id!=null){
  38. if (id.indexOf("#index#") >= 0){
  39. $this.attr("id",id.replace('#index#',i));
  40. }else{
  41. var s = id.indexOf("[");
  42. var e = id.indexOf("]");
  43. var new_id = id.substring(s+1,e);
  44. $this.attr("id",id.replace(new_id,i));
  45. }
  46. }
  47. if(onclick_str!=null){
  48. if (onclick_str.indexOf("#index#") >= 0){
  49. $this.attr("onclick",onclick_str.replace(/#index#/g,i));
  50. }else{
  51. }
  52. }
  53. });
  54. });
  55. }
  56. function decode(value, id) {//value传入值,id接受值
  57. var last = value.lastIndexOf("/");
  58. var filename = value.substring(last + 1, value.length);
  59. $("#" + id).text(decodeURIComponent(filename));
  60. }
  61. </script>
  62. </head>
  63. <body style="overflow-x: hidden;">
  64. <t:formvalid formid="formobj" dialog="true" usePlugin="password" layout="table" tiptype="1" action="cgDynamGraphConfigHeadController.do?doUpdate">
  65. <input id="id" name="id" type="hidden" value="${cgDynamGraphConfigHeadPage.id }">
  66. <table cellpadding="0" cellspacing="1" class="formtable">
  67. <tr>
  68. <td align="right"><label class="Validform_label"><t:mutiLang langKey="common.code"/>:</label></td>
  69. <td class="value"><input id="code" name="code" type="text" style="width: 150px" class="inputxt" datatype="*" value='${cgDynamGraphConfigHeadPage.code}'> <span class="Validform_checktip"></span></td>
  70. <td align="right"><label class="Validform_label"><t:mutiLang langKey="common.name"/> :</label></td>
  71. <td class="value"><input id="name" name="name" type="text" style="width: 150px" class="inputxt" datatype="*" value='${cgDynamGraphConfigHeadPage.name}'> <span class="Validform_checktip"></span></td>
  72. <td align="right"><label class="Validform_label"><t:mutiLang langKey="common.dynamic.dbsource"/> :</label></td>
  73. <td class="value"><t:dictSelect field="dbSource" dictTable="t_s_data_source" dictField="DB_KEY" dictText="DB_KEY" defaultVal="${cgDynamGraphConfigHeadPage.dbSource}" /><span class="Validform_checktip"></span></td>
  74. </tr>
  75. <tr>
  76. <td align="right"><label class="Validform_label"><t:mutiLang langKey="query.sql"/>:</label></td>
  77. <td class="value" colspan="5"><textarea rows="5" cols="150" id="cgrSql" name="cgrSql" datatype="*">${cgDynamGraphConfigHeadPage.cgrSql}</textarea> <span class="Validform_checktip"></span>
  78. <p>&nbsp;&nbsp;&nbsp;&nbsp;您可以键入“${abc}”作为一个参数,这里abc是参数的名称。例如:<br/>
  79. &nbsp;&nbsp;&nbsp;&nbsp;select broswer name,count(1) value, '#286FBB' color from t_s_log where id = <%="${abc}"%> group by broswer。<br/>
  80. &nbsp;&nbsp;&nbsp;&nbsp;select broswer name,count(1) value, '#286FBB' color from t_s_log where id = <%="'${abc}'"%> group by broswer。(如果id字段为字符串类型)<br/>
  81. &nbsp;&nbsp;&nbsp;&nbsp;<font color="red">注:必要用 name,value,color 列。 name 为X轴数据,value 为Y轴数据,color为图表的颜色</font><p/>
  82. </td>
  83. </tr>
  84. <tr>
  85. <td align="right"><label class="Validform_label"><t:mutiLang langKey="common.description"/>:</label></td>
  86. <td class="value" colspan="5"><textarea rows="3" cols="150" id="content" name="content" datatype="*">${cgDynamGraphConfigHeadPage.content}</textarea> <span class="Validform_checktip"></span></td>
  87. </tr>
  88. <tr>
  89. <td align="right"><label class="Validform_label">图表类型:</label></td>
  90. <td class="value"><t:dictSelect field="graphType" typeGroupCode="graphType" hasLabel="false" defaultVal="${cgDynamGraphConfigHeadPage.graphType}" /><span class="Validform_checktip"></span></td>
  91. <td align="right"><label class="Validform_label">数据结构类型:</label></td>
  92. <td class="value" colspan="3"><t:dictSelect field="dataStructure" typeGroupCode="fieldtype" hasLabel="false" defaultVal="${cgDynamGraphConfigHeadPage.dataStructure}" /> <span class="Validform_checktip"></span></td>
  93. </tr>
  94. </table>
  95. <div style="width: auto; height: 200px;"><%-- 增加一个div,用于调节页面大小,否则默认太小 --%>
  96. <div style="width: 800px; height: 1px;"></div>
  97. <t:tabs id="ttp" iframe="false" tabPosition="top" fit="false"><t:tab href="cgDynamGraphConfigHeadController.do?cgDynamGraphConfigParamList&id=${cgDynamGraphConfigHeadPage.id}" icon="icon-search" title="报表参数" id="cgDynamGraphConfigParam"></t:tab></t:tabs>
  98. <t:tabs id="tt" iframe="false" tabPosition="top" fit="false"><t:tab href="cgDynamGraphConfigHeadController.do?cgDynamGraphConfigItemList&id=${cgDynamGraphConfigHeadPage.id}" icon="icon-search" title="dynamic.report.config.detail" id="cgDynamGraphConfigItem"></t:tab></t:tabs>
  99. </div>
  100. </t:formvalid>
  101. <!-- 添加 附表明细 模版 -->
  102. <table style="display: none">
  103. <tbody id="add_cgDynamGraphConfigItem_table_template">
  104. <tr>
  105. <td align="center"><input style="width: 20px;" type="checkbox" name="ck" /></td>
  106. <td align="left"><input name="cgDynamGraphConfigItemList[#index#].fieldName" maxlength="36" type="text" class="inputxt" style="width: 120px;"></td>
  107. <td align="left"><input name="cgDynamGraphConfigItemList[#index#].orderNum" maxlength="10" type="text" class="inputxt" style="width: 30px;"></td>
  108. <td align="left"><input name="cgDynamGraphConfigItemList[#index#].fieldTxt" maxlength="1000" type="text" class="inputxt" style="width: 120px;"></td>
  109. <td align="left"><t:dictSelect field="cgDynamGraphConfigItemList[#index#].fieldType" type="list" extendJson="{style:'width:80px'}" typeGroupCode="fieldtype" defaultVal="String" hasLabel="false" title="common.text.type"></t:dictSelect></td>
  110. <td align="left"><select id="isShow" name="cgDynamGraphConfigItemList[#index#].isShow" style="width: 60px;">
  111. <option value="Y"><t:mutiLang langKey="common.show"/></option>
  112. <option value="N"><t:mutiLang langKey="common.hide"/></option>
  113. </select></td>
  114. <td align="left"><input name="cgDynamGraphConfigItemList[#index#].fieldHref" maxlength="1000" type="text" class="inputxt" style="width: 120px;">
  115. <td align="left"><t:dictSelect field="cgDynamGraphConfigItemList[#index#].SMode" type="list" extendJson="{style:'width:90px'}" typeGroupCode="searchmode" defaultVal="" hasLabel="false" title="common.query.module"></t:dictSelect></td>
  116. <td align="left"><input name="cgDynamGraphConfigItemList[#index#].replaceVa" maxlength="36" type="text" class="inputxt" style="width: 120px;"></td>
  117. <td align="left"><input name="cgDynamGraphConfigItemList[#index#].dictCode" maxlength="36" type="text" class="inputxt" style="width: 120px;"></td>
  118. <td align="left"><t:dictSelect field="cgDynamGraphConfigItemList[#index#].SFlag" type="list" extendJson="{style:'width:60px'}" typeGroupCode="yesorno" defaultVal="" hasLabel="false" title="common.isquery"></t:dictSelect></td>
  119. </tr>
  120. </tbody>
  121. </table>
  122. <table style="display: none">
  123. <tbody id="add_cgDynamGraphConfigParam_table_template">
  124. <tr>
  125. <td align="center"><input style="width:20px;" type="checkbox" name="ck"/></td>
  126. <td align="left"><input name="cgDynamGraphConfigParamList[#index#].paramName" maxlength="32" type="text" class="inputxt" style="width:120px;" datatype="*" ></td>
  127. <td align="left"><input name="cgDynamGraphConfigParamList[#index#].paramDesc" maxlength="32" type="text" class="inputxt" style="width:120px;" ></td>
  128. <td align="left"><input name="cgDynamGraphConfigParamList[#index#].paramValue" maxlength="32" type="text" class="inputxt" style="width:120px;" ></td>
  129. <td align="left"><input name="cgDynamGraphConfigParamList[#index#].seq" maxlength="32" type="text" class="inputxt" style="width:120px;"></td>
  130. </tr>
  131. </tbody>
  132. </table>
  133. </body>
  134. <script src="webpage/jeecg/cgdynamgraph/core/cgDynamGraphConfigHead.js"></script>