81f9fed894622e745f3fc8e5e0ef9abaad8a9b84.svn-base 9.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255
  1. <%@ page contentType="text/html; charset=UTF-8" language="java"%>
  2. <%@ page import="java.util.*"%>
  3. <%@ page
  4. import="com.sysmodel.datamodel.xmlmodel.ModelFactory,
  5. com.sysmodel.datamodel.xmlmodel.able.SysModel,
  6. com.sysmodel.datamodel.xmlmodel.impl.MdpClassImpl"%>
  7. <%
  8. SysModel sysmodel = ModelFactory.getSysmodel();
  9. ArrayList list = sysmodel.getMdpModules();
  10. ArrayList mdpClasses = sysmodel.getMdpClasses();
  11. %>
  12. <HTML>
  13. <HEAD>
  14. <META http-equiv="Content-Type" content="text/html; charset=UTF-8">
  15. <TITLE></TITLE>
  16. <link rel="stylesheet" href="../../../../../styles/style.css" type="text/css"></link>
  17. <link rel="stylesheet" href="../../../../../styles/css.css" ype="text/css"></link>
  18. <script type="text/javascript" src="../../../../../scripts/dojo/dojo/dojo.js" djConfig="isDebug: false, parseOnLoad: true"></script>
  19. <link rel="stylesheet" type="text/css" href="../../../../../scripts/ext20/resources/css/ext-all.css" />
  20. <script type="text/javascript" src="../../../../../scripts/ext20/adapter/ext/ext-base.js"></script>
  21. <script type="text/javascript" src="../../../../../scripts/ext20/ext-all.js"></script>
  22. <link rel="stylesheet" href="../../../../../scripts/ext20/examples/examples.css" type="text/css"></link>
  23. <script type="text/javascript" src="../../../../../scripts/ext20/examples/examples.js"></script>
  24. <script type="text/javascript">
  25. dojo.require("dijit.form.Form");
  26. dojo.require("dijit.form.FilteringSelect");
  27. dojo.require("dijit.form.Button");
  28. dojo.require("dijit.Tooltip");
  29. </script>
  30. <script language="JavaScript">
  31. function ChooseModule(Code, selectName){
  32. var strA = "";
  33. if(Code == "root") Code = "";
  34. createXMLHttpRequest();
  35. axo = new ActiveXObject("Microsoft.XMLDOM");
  36. XMLHttpReq.open("POST","../getClassids.jsp?type="+Code+"",false);
  37. XMLHttpReq.setRequestHeader("Content-Length",strA.length);
  38. XMLHttpReq.setRequestHeader("Content-type","application/x-www-form-urlencoded");
  39. XMLHttpReq.send(strA);
  40. axo.loadXML(XMLHttpReq.responseText);
  41. n1 = axo.selectNodes("/root/classid");
  42. n2 = axo.selectNodes("/root/description");
  43. BuildSel(unescape(XMLHttpReq.responseText),selectName, n1, n2);
  44. }
  45. </script>
  46. <script type="text/javascript">
  47. Ext.onReady(function(){
  48. Ext.BLANK_IMAGE_URL = '../../../../../scripts/ext20/resources/images/default/s.gif';
  49. var Tree = Ext.tree;
  50. var tree = new Tree.TreePanel({
  51. el:'tree-div',
  52. autoScroll:true,
  53. animate:true,//是否动画
  54. enableDD:true,// 是否支持拖放
  55. containerScroll:true,
  56. lines:true,
  57. loader:new Tree.TreeLoader({dataUrl:"../../../../getModuleJson.jsp"})
  58. });
  59. var root = new Tree.AsyncTreeNode({
  60. text: '全部系统模块',
  61. draggable:false,
  62. id:'root'
  63. });
  64. tree.on('click', function(node){
  65. ChooseModule(node.id, dojo.byId('role1'))
  66. });
  67. tree.setRootNode(root);
  68. tree.render();
  69. root.expand();
  70. });
  71. </script>
  72. <style type="text/css">
  73. @import "../../../../../scripts/dojo/dojo/resources/dojo.css";
  74. @import "../../../../../scripts/dojo/dijit/themes/tundra/tundra.css";
  75. @import "../../../../../scripts/dojo/dijit/themes/tundra/tundra_rtl.css";
  76. @import "../../../../../scripts/dojo/dijit/tests/css/dijitTests.css";
  77. .formQuestion {
  78. background-color:#d0e3f5;
  79. padding:0.3em;
  80. font-weight:900;
  81. font-family:Verdana, Arial, sans-serif;
  82. font-size:0.8em;
  83. color:#5a5a5a;
  84. }
  85. .formAnswer {
  86. background-color:#f5eede;
  87. padding:0.3em;
  88. margin-bottom:1em;
  89. width: 100%;
  90. }
  91. .pageSubContentTitle {
  92. color:#8e8e8e;
  93. font-size:1em;
  94. font-family:Verdana, Arial, sans-serif;
  95. margin-bottom:0.75em;
  96. }
  97. .small INPUT {
  98. width: 2.5em;
  99. }
  100. .medium INPUT {
  101. width: 10em;
  102. }
  103. .long INPUT {
  104. width: 20em;
  105. }
  106. .firstLabel {
  107. display: inline-block;
  108. display: -moz-inline-box;
  109. width: 10em;
  110. min-width: 10em;
  111. }
  112. .secondLabel {
  113. width: auto;
  114. margin-left: 5em;
  115. margin-right: 1em;
  116. }
  117. fieldset label {
  118. margin-right: 1em;
  119. }
  120. .noticeMessage {
  121. display: block;
  122. float: right;
  123. font-weight: normal;
  124. font-family:Arial, Verdana, sans-serif;
  125. color:#663;
  126. font-size:0.9em;
  127. }
  128. </style>
  129. <script language="JavaScript">
  130. function getTable(obj, selectName){
  131. var strA = "";
  132. createXMLHttpRequest();
  133. axo = new ActiveXObject("Microsoft.XMLDOM");
  134. XMLHttpReq.open("POST","../getClassids.jsp?type="+obj.getValue()+"",false);
  135. XMLHttpReq.setRequestHeader("Content-Length",strA.length);
  136. XMLHttpReq.setRequestHeader("Content-type","application/x-www-form-urlencoded");
  137. XMLHttpReq.send(strA);
  138. axo.loadXML(XMLHttpReq.responseText);
  139. n1 = axo.selectNodes("/root/classid");
  140. n2 = axo.selectNodes("/root/description");
  141. BuildSel(unescape(XMLHttpReq.responseText),selectName, n1, n2);
  142. }
  143. </script>
  144. <script type="text/javascript" src="../../select.js"></script>
  145. </HEAD>
  146. <body class="tundra">
  147. <form dojoType="dijit.form.Form" name="form1" method="post" action="">
  148. <div id=total>
  149. <div class="whiteborder">
  150. <div class="titback">
  151. <div class="floatleft"><img src="../../../../../images/index/arrow1.gif" alt="1"
  152. width="20" height="24" /></div>
  153. <div class="dropshadow">检查数据库命名规范</div>
  154. <div class="clear"></div>
  155. </div>
  156. <div class="report">
  157. <table align="center" id="SortTable512_1" width="100%"
  158. cellpadding="1" cellspacing="1" class="ltab2">
  159. <tr>
  160. <td width="60%" valign="top"><table align="center" width="100%" border="0" cellpadding="1"
  161. cellspacing="1" class="ltab2">
  162. <tr class="TableBgColorAsh">
  163. <td align="left" valign="top">
  164. <div id="tree-div" style="z-index:9999;overflow:auto; height:100%; width:100%;border:1px solid #c3daf9;">
  165. </div>
  166. </td>
  167. <td width="30%" align="center"><select name="select2" size="15" class="SelectScroll" multiple id="role1" style="width:80%">
  168. <%
  169. for (int i = 0; i < mdpClasses.size(); i++) {
  170. MdpClassImpl mdpClass = (MdpClassImpl) mdpClasses.get(i);
  171. %>
  172. <option value="<%=mdpClass.getClassid()%>"> <%=mdpClass.getDescription()%> </option>
  173. <%
  174. }
  175. %>
  176. </select></td>
  177. <td width="5%" align="center"><input name="button" type="button" class="button2"
  178. style="cursor:hand" onClick="move(this.form.role1,this.form.role2);"
  179. value=" &gt;&gt; " />
  180. <br>
  181. <br>
  182. <input name="button" type="button" class="button2"
  183. style="cursor:hand" onClick="move(this.form.role2,this.form.role1);"
  184. value=" &lt;&lt; " /> </td>
  185. <td width="30%" align="center" valign="middle"><select name="select" size="15" multiple class="SelectScroll" id="role2" style="width:80%">
  186. </select> </td>
  187. </tr>
  188. <tr class="TableBgColorBlack">
  189. <td colspan="4">
  190. <button id="save" dojoType="dijit.form.Button" onClick='console.log("clicked simple"),checkConfig();' type="button" iconClass="plusIcon">
  191. 开始检查 </button>
  192. <span dojoType="dijit.Tooltip" connectId="save">开始检查 </span>&nbsp;&nbsp;
  193. &nbsp;&nbsp; </td>
  194. </table></td>
  195. </tr>
  196. </table>
  197. <div id="boxIdea" align="left" style="width:98%;height:98%;border:1px solid #999999;"> </div>
  198. </div>
  199. </div>
  200. </div>
  201. </form>
  202. <script language="JavaScript">
  203. var indexOfCheck = 0;
  204. var role2=document.all.item("role2");
  205. function checkConfig() {
  206. indexOfCheck = 0
  207. var boxIdea=document.all.item("boxIdea");
  208. boxIdea.innerHTML = "";
  209. if(role2.options.length == 0){
  210. alert("请选则进行验证的表对象!");
  211. return;
  212. }
  213. var classid = role2.options[0].value;
  214. checkOneObj(classid)
  215. }
  216. function checkOneObj(classid){
  217. if(classid=="") return;
  218. createXMLHttpRequest();
  219. var strA = "";
  220. XMLHttpReq.open("POST","checkExc.jsp?classid=" + classid,false);
  221. XMLHttpReq.setRequestHeader("Content-Length",strA.length);
  222. XMLHttpReq.setRequestHeader("Content-type","application/x-www-form-urlencoded");
  223. XMLHttpReq.send(strA);
  224. var boxIdea=document.all.item("boxIdea");
  225. boxIdea.innerHTML = boxIdea.innerHTML + XMLHttpReq.responseText;
  226. indexOfCheck = indexOfCheck + 1;
  227. if(indexOfCheck < role2.options.length){
  228. checkOneObj(role2.options[indexOfCheck].value);
  229. }else{
  230. return;
  231. }
  232. }
  233. // End -->
  234. </script>
  235. </BODY>
  236. </HTML>