4e05b0a9ec78c58dd1accae9f00fc8f5d1f4ca3d.svn-base 8.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232
  1. <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
  2. <html xmlns="http://www.w3.org/1999/xhtml">
  3. <head>
  4. <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
  5. <title>tab</title>
  6. <!--框架必需start-->
  7. <link rel="stylesheet" type="text/css"
  8. href="/nwyj/scripts/qui/libs/css/import_basic.css" />
  9. <link rel="stylesheet" type="text/css" id="skin"
  10. prePath="/nwyj/scripts/qui/" scrollerY="false" />
  11. <link rel="stylesheet" type="text/css" id="customSkin" />
  12. <link href="/nwyj/scripts/qui/libs/skins/flatBlue/style.css"
  13. rel="stylesheet" type="text/css" id="theme" themeColor="flatBlue"
  14. positionTarget="positionContent" />
  15. <link href="/nwyj/scripts/qui/system/layout/skin/style.css"
  16. rel="stylesheet" type="text/css" id="skin"
  17. skinPath="/scripts/qui/system/layout/skin/" />
  18. <script type="text/javascript" src="/nwyj/scripts/qui/libs/js/jquery.js"></script>
  19. <script type="text/javascript"
  20. src="/nwyj/scripts/qui/libs/js/language/cn.js"></script>
  21. <script type="text/javascript"
  22. src="/nwyj/scripts/qui/libs/js/framework.js"></script>
  23. <script type="text/javascript" src="/nwyj/scripts/qui/libs/js/main.js"></script>
  24. <!--框架必需end-->
  25. <!--布局组件start-->
  26. <script type="text/javascript"
  27. src="/nwyj/scripts/qui/libs/js/nav/layout.js"></script>
  28. <!--布局组件start-->
  29. <!--基本选项卡start-->
  30. <script type="text/javascript"
  31. src="/nwyj/scripts/qui/libs/js/nav/basicTab.js"></script>
  32. <script type="text/javascript"
  33. src="/nwyj/scripts/qui/libs/js/nav/basicTabModern.js"></script>
  34. <!--基本选项卡end-->
  35. <!--表单提交start-->
  36. <script type="text/javascript"
  37. src="/nwyj/scripts/qui/libs/js/form/form.js"></script>
  38. <!--表单提交end-->
  39. <!--树组件start-->
  40. <link rel="stylesheet" type="text/css"
  41. href="/nwyj/scripts/qui/libs/js/tree/ztree/ztree.css" />
  42. <script type="text/javascript"
  43. src="/nwyj/scripts/qui/libs/js/tree/ztree/ztree.js"></script>
  44. <script type="text/javascript"
  45. src="/nwyj/scripts/qui/libs/js/form/selectTree.js"></script>
  46. <script type="text/javascript"
  47. src="/nwyj/scripts/qui/libs/js/form/listerTree.js"></script>
  48. <!--树组件end-->
  49. <!--数据表格start-->
  50. <script type="text/javascript"
  51. src="/nwyj/scripts/qui/libs/js/table/quiGrid.js"></script>
  52. <!--数据表格end-->
  53. <!--弹窗组件start-->
  54. <script type="text/javascript"
  55. src="/nwyj/scripts/qui/libs/js/popup/messager.js"></script>
  56. <script type="text/javascript"
  57. src="/nwyj/scripts/qui/libs/js/popup/drag.js"></script>
  58. <script type="text/javascript"
  59. src="/nwyj/scripts/qui/libs/js/popup/dialog.js"></script>
  60. <!--弹窗组件end-->
  61. <!--上传附件start-->
  62. <script type="text/javascript"
  63. src="/nwyj/scripts/qui/libs/js/form/upload/fileUpload.js"></script>
  64. <script type="text/javascript"
  65. src="/nwyj/scripts/qui/libs/js/form/upload/handlers.js"></script>
  66. <!-- 上传附件end -->
  67. <!--分隔条start-->
  68. <script type="text/javascript"
  69. src="/nwyj/scripts/qui/libs/js/nav/spliter.js"></script>
  70. <!--分隔条end-->
  71. <!-- 扩展工具js -->
  72. <script type="text/javascript"
  73. src="/nwyj/scripts/jquery/plugins/jquery.extension.util.js"></script>
  74. <script type="text/javascript"
  75. src="/nwyj/scripts/freamwork/com/sinosoft/common/utils/Request.js"></script>
  76. <script type="text/javascript"
  77. src="/nwyj/scripts/freamwork/com/sinosoft/common/common.js"></script>
  78. <script type="text/javascript"
  79. src="/nwyj/scripts/freamwork/com/sinosoft/common/DateUtil.js"></script>
  80. <script type="text/javascript"
  81. src="/nwyj/scripts/commom/common/common.js"></script>
  82. <!--浮动面板start-->
  83. <script type="text/javascript"
  84. src="/nwyj/scripts/qui/libs/js/popup/floatPanel.js"></script>
  85. <!--浮动面板end-->
  86. <!--弹出式提示框start-->
  87. <script type="text/javascript" src="/nwyj/scripts/qui/libs/js/popup/messager.js"></script>
  88. <script type="text/javascript">
  89. var g;
  90. var iframeUrl = window.location.href;
  91. var canstType=(iframeUrl).split('?')[1].split('=')[1];
  92. $(function(){
  93. g = $("#maingrid").quiGrid({
  94. columns: [ { display: '名称', name: 'FD_DESCRIPTION', align: 'center', width: "16%"},
  95. { display: '类型', name: 'FD_TYPE', align: 'center', width: "16%"},
  96. { display: '编号', name: 'FD_CODE', align: 'center', width: "16%"},
  97. { display: '顺序', name: 'FD_SORT', align: 'center', width: "16%"},
  98. { display: '父节点编号', name: 'PARENT_ID', align: 'center', width: "16%"},
  99. { display: '操作', isSort: false, width: "16%", render: function (rowdata, rowindex, value)
  100. {
  101. var h = "";
  102. h += "<a onclick='onDelete(" + rowindex + ")'><span class='icon_delete'>删除</span></a> ";
  103. return h;
  104. }
  105. }
  106. ],
  107. url: $.pathname() + '/ws/FILEPOLL/FileAMService/queryMapValue1/',
  108. params :{"type":canstType},
  109. rownumbers:true,
  110. pageSize:10,
  111. dataAction:"server",
  112. usePager: false,
  113. percentWidthMode : true,
  114. height: "100%", width:"100%",enabledEdit: false,clickToEdit: false
  115. });
  116. })
  117. function onDelete(rowidx){
  118. top.Dialog.confirm("确定要删除么?",function(){
  119. //删除记录
  120. var row = g.getRow(rowidx)
  121. //删除操作
  122. $.post($.pathname() + '/ws/FILEPOLL/FileAMService/deleteMapValue/',
  123. {"FDCODE":row.FD_CODE,"FDTYPE":row.FD_TYPE},
  124. function(result){
  125. if (result == true) {
  126. top.Dialog.alert("删除成功!");
  127. g.loadData();
  128. } else {
  129. top.Dialog.alert("删除失败!");
  130. }
  131. },"json");
  132. });
  133. }
  134. function addMapValue(){
  135. var description = $("#FD_DESCRIPTION").val();
  136. if(description=="" || validateInput(description, "^[\" \"]+$")){
  137. top.Dialog.alert("请输入名称!");
  138. return ;
  139. }
  140. $.post($.pathname() +"/ws/FILEPOLL/FileAMService/addCanstValue/", {
  141. FD_DESCRIPTION:description,
  142. FD_TYPE:canstType
  143. }, function(result) {
  144. if (result == true) {
  145. top.Dialog.alert("添加成功!");
  146. refreshTable();
  147. g.loadData();
  148. } else {
  149. top.Dialog.alert("添加失败!");
  150. }
  151. }, "json");
  152. }
  153. function refreshTable(){
  154. var params=(iframeUrl).split('?')[1].split('=')[1];
  155. $.ajax({
  156. url : $.pathname() +"/ws/FILEPOLL/FileAMService/queryMapValue/",
  157. type : 'post',
  158. timeout : 15000,
  159. data : params,
  160. dataType : 'json',
  161. async:false,
  162. success : function(data){
  163. $('#fillForm').ajaxWrite({data:data});
  164. },
  165. error : function(e){
  166. $.messager.alert('系统提示信息', '访问服务失败!', 'error');
  167. }
  168. });
  169. }
  170. </script>
  171. </head>
  172. <body >
  173. <form id="fillForm">
  174. <fieldset style="border-color:#999999;" >
  175. <legend>新增内容:</legend>
  176. <table width="70%" class="tableStyle" height="100%">
  177. <tr>
  178. <td width="15%" align="right">名称:</td>
  179. <td width="65%"><input type="text" id="FD_DESCRIPTION" name="FD_DESCRIPTION" style="width: 300px;" maxlength="60" /></td>
  180. <td width="20%" align="center" ><input onclick="addMapValue()" value="保存" type="button"/></td>
  181. </tr>
  182. <!--
  183. <tr >
  184. <td align="right">编号:</td>
  185. <td ><input type="text" id="FD_CODE" name="FD_CODE" style="width: 300px;" maxlength="10" /></td>
  186. </tr>
  187. <tr style="display:none">
  188. <td align="right">类型:</td>
  189. <td><input type="text" disabled="true" id="FD_TYPE" name="FD_TYPE" style="width: 300px;" maxlength="20" /></td>
  190. </tr>
  191. <tr style="display:none">
  192. <td align="right">顺序:</td>
  193. <td><input type="text" disabled="true" id="FD_SORT" name="FD_SORT" style="width: 300px;" maxlength="2" /></td>
  194. </tr>
  195. <tr style="display:none">
  196. <td align="right">父节点编号:</td>
  197. <td><input type="text" disabled="true" id="PARENT_ID" name="PARENT_ID" style="width: 300px;" maxlength="10" /></td>
  198. <td></td>
  199. <td></td>
  200. </tr> -->
  201. </table>
  202. </fieldset>
  203. </form>
  204. </fieldset>
  205. </form>
  206. <fieldset style="border-color:#999999;" id="fileTable" >
  207. <legend>常量表信息:</legend>
  208. <div class="padding_right5">
  209. <div id="maingrid"></div>
  210. </div>
  211. </fieldset>
  212. </body>
  213. </html>