f0f9e64d2d2b12f5eadc6150c704e3b1e4451b69.svn-base 8.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195
  1. <%@page contentType="text/html" pageEncoding="UTF-8"%>
  2. <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
  3. <html xmlns="http://www.w3.org/1999/xhtml">
  4. <head>
  5. <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
  6. <title></title>
  7. <%@include file="../../../../include.jsp" %>
  8. <!--引用资源文件,JS CSS-->
  9. <script type="text/javascript" src="<%=path%>/scripts/jquery/plugins/jquery.extension.util.js"></script>
  10. <script type="text/javascript" src="<%=path%>/scripts/freamwork/com/sinosoft/common/common.js"></script>
  11. <script type="text/javascript" src="<%=path%>/scripts/freamwork/com/sinosoft/common/utils/utils.js"></script>
  12. <script type="text/javascript" src="<%=path%>/scripts/freamwork/com/sinosoft/common/frameWork/frameWork.js"></script>
  13. <script type="text/javascript" src="<%=path%>/scripts/business/he/common/common.js"></script>
  14. <script type="text/javascript" src="<%=path%>/scripts/freamwork/com/sinosoft/common/utils/Request.js"></script>
  15. <script type="text/javascript" src="<%=path%>/scripts/qui/libs/js/tree/ztree/ztree.js"></script>
  16. <link href="<%=path%>/scripts/qui/libs/js/tree/ztree/ztree.css" rel="stylesheet" type="text/css" />
  17. <link href="/nwyj/scripts/qui/libs/skins/flatBlue/style1.css"
  18. rel="stylesheet" type="text/css" id="theme" themeColor="flatBlue"
  19. positionTarget="positionContent" selInputHeight="32"
  20. selButtonWidth="35" defaultSelWidth="200" fileBtnWidth="60"
  21. defaultFileInputWidth="200" defaultGridHeaderHeight="34"
  22. defaultGridRowHeight="38" defaultFontSize="12" defaultPageSelWidth="55"
  23. defaultFilterItemHeight="32" dialogWidthFix="0"
  24. defaultSelItemHeight="32" defaultFontFamily="宋体" />
  25. <script type="text/javascript" src="<%=path%>/scripts/business/em/evaluate/score/Score_addEdit.js"></script>
  26. <script type="text/javascript">
  27. var fd_id = "<%=request.getParameter("fd_id")%>";
  28. $(function(){
  29. //取得用户真实名字
  30. var realName = top.com.sinosoft.lz.system.user.LoginInfo.getReal_name();
  31. //部门id
  32. var deptId = top.com.sinosoft.lz.system.user.LoginInfo.getCorp_ids();
  33. //部门名称
  34. var deptName = top.com.sinosoft.lz.system.user.LoginInfo.getCorp_names();
  35. //父部门id
  36. var parentId = getCorpParentId(deptId);
  37. //页面初始化
  38. $(function(){
  39. if(fd_id.length>0 ){//修改表单
  40. $(".titleShow").text("修改评估");
  41. $("#editReset").show();
  42. $("#editSave").show();
  43. //评价单位
  44. var deptUrl = $.pathname() + '/ws/dept/DeptService/getDepartTree';
  45. $.post(deptUrl,{id:parentId,name:''},function(data){
  46. $("#COMPANY_ID_375").data("data",data);
  47. $("#COMPANY_ID_375").render();
  48. }, "json");
  49. //评价体系
  50. var trunkUrl = $.pathname() + '/ws/targetManage/TargetManageService/getTrunkAllTree';
  51. $.post(trunkUrl,{id:parentId,name:'',dept:'CORP'},function(data){
  52. $("#TRUNK_ID_375").data("data",data);
  53. $("#TRUNK_ID_375").render();
  54. }, "json");
  55. var url = $.pathname() + '/ws/crud/CRUDService/getDataById/';
  56. var params = {
  57. classid : '375',
  58. objectID : fd_id
  59. };
  60. $.request.query(url,params,function(data){
  61. $('#editForm').ajaxWrite({data:data});
  62. $('#editForm input[name="classid"]').val('375');
  63. });
  64. }else{//新增
  65. $(".titleShow").text("新增评估");
  66. $("#addReset").show();
  67. $("#addSave").show();
  68. //填报人
  69. $("#WRITER_375").val(realName);
  70. //填报部门
  71. //$("#WRITE_DEPT_375").val(deptId);//15CC8A55C3DE0ED0E0530113960A6CC1
  72. $("#WRITE_DEPT_375").val(deptName);//广电信息中心
  73. //填报时间
  74. $("#WRITE_TIME_375").val(getDateTime());
  75. //评价单位
  76. var deptUrl = $.pathname() + '/ws/dept/DeptService/getDepartTree';
  77. $.post(deptUrl,{id:parentId,name:'',dept:'1'},function(data){
  78. $("#COMPANY_ID_375").data("data",data);
  79. $("#COMPANY_ID_375").render();
  80. }, "json");
  81. //$("#DEPT_375").initYewuSelect("800","Dept_Id","DEPT_NAME");
  82. //评价体系
  83. //$("#TRUNKLD_375").initYewuSelect("372","FD_OBJECTID","NAME","is_del=0");
  84. var trunkUrl = $.pathname() + '/ws/targetManage/TargetManageService/getTrunkAllTree';
  85. $.post(trunkUrl,{id:parentId,name:''},function(data){
  86. $("#TRUNK_ID_375").data("data",data);
  87. $("#TRUNK_ID_375").render();
  88. }, "json");
  89. //状态(0未完成/1已完成)
  90. $("#STATUS_375").val(0);
  91. }
  92. });
  93. });
  94. //获得当前系统时间
  95. function getDateTime(){
  96. var s="";
  97. var d = allGetServerTime();
  98. var vYear = d.getFullYear();
  99. var vMon = d.getMonth() + 1;
  100. var vDay = d.getDate();
  101. var h = d.getHours();
  102. var m = d.getMinutes();
  103. var se = d.getSeconds();
  104. s=vYear+"-"+(vMon<10 ? "0" + vMon : vMon)+"-"+(vDay<10 ? "0"+ vDay : vDay)+" "+(h<10 ? "0"+ h : h)+":"+(m<10 ? "0" + m : m)+":"+(se<10 ? "0" +se : se);
  105. return s;
  106. }
  107. function formReset(){//新增重置方法
  108. document.getElementById("editForm").reset();
  109. $("#NAME_375").resetValue();//评价名称
  110. $("#TRUNKLD_375").resetValue();//评价体系
  111. $("#DEPT_375").resetValue();//评价单位
  112. }
  113. function getCorpParentId(corpId){
  114. var parentId = corpId;
  115. $.ajax({
  116. url : $.pathname() + '/ws/crud/CRUDService/getParentCorpIdByCorpid/',
  117. type : 'post',
  118. timeout : 15000,
  119. data : {corpId:corpId},
  120. dataType : 'text',
  121. async:false,
  122. success : function(data) {
  123. parentId = data;
  124. },
  125. error : function(e) {
  126. $.messager.alert('访问服务失败!');
  127. }
  128. });
  129. return parentId;
  130. }
  131. </script>
  132. </head>
  133. <body>
  134. <div class="box1" id="formContent" style="border: 1px solid #E4E4E4;background: #F8F8F8;">
  135. <div style="height: 50px;background: #F8F8F8;" align="center"><a href="javascript:;"><img id="back" align="left" alt="返回" title="返回" src="/nwyj/images/temp/back.png" /></a><font style="font-weight: bold;font-size: 20px;line-height: 45px;" class="titleShow"></font></div>
  136. <form id="editForm" method="post" >
  137. <input name="classid" value="375" type="hidden"/>
  138. <input type="hidden" name="FD_OBJECTID375" id="FD_OBJECTID375" value=""/>
  139. <input id="STATUS_375" name="STATUS_375" value="0" type="hidden"/>
  140. <input id="WRITER_375" name="WRITER_375" type="hidden"/>
  141. <input id="WRITE_DEPT_375" name="WRITE_DEPT_375" type="hidden"/>
  142. <input id="WRITE_TIME_375" name="WRITE_TIME_375" type="hidden"/>
  143. <input id="TRUNK_NAME_375" name="TRUNK_NAME_375" type="hidden"/>
  144. <input id="COMPANY_NAME_375" name="COMPANY_NAME_375" type="hidden"/>
  145. <!-- 保存和重置 -->
  146. <br/>
  147. <div style="float:left">
  148. &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<font class="titleShow1"></font>
  149. </div>
  150. <div style="float:right">
  151. <input value="保存" type="button" id="add"/>
  152. <input value="去评分" type="button" id="goScore"/>
  153. <input value="重置" onclick="formReset();" type="button"/><!-- 新增重置 -->&nbsp;&nbsp;&nbsp;&nbsp;
  154. </div><br/>
  155. <div align="center"><!-- <font style="font-weight: bold;font-size: 30px;line-height: 45px;" color="red" id="" class="titleShow"></font> --></div><br/>
  156. <!-- 正文表格 -->
  157. <table class="tableStyle" style="width: 100%;" align="center" id="contentTable">
  158. <tr>
  159. <td width="25%" align="right"><span>评价名称:</span></td><!-- <span class="star">*</span> -->
  160. <td width="75%"><input id="NAME_375" name="NAME_375" type="text" style="width: 97%;" maxlength="50"/></td>
  161. </tr>
  162. <tr>
  163. <td width="25%" align="right"><span>评估单位:</span></td>
  164. <td width="75%">
  165. <div title="" swidth="97%" class="selectTree validate[required] selectWidth" id="COMPANY_ID_375" name="COMPANY_ID_375" multiMode="true" selWidth="940"></div>
  166. <!-- <select id="DEPT_375" name="DEPT_375" editable=false prompt="请选择" selWidth="940"></select> --></td>
  167. </tr>
  168. <tr>
  169. <td width="25%" align="right"><span>评价体系:</span></td>
  170. <td width="75%">
  171. <div title="" swidth="97%" class="selectTree validate[required] selectWidth" id="TRUNK_ID_375" name="TRUNK_ID_375" multiMode="true" ></div>
  172. <!-- <select id="TRUNKLD_375" name="TRUNKLD_375" editable=false prompt="请选择" selWidth="940"></select> -->
  173. </td>
  174. </tr>
  175. <tr>
  176. <td width="25%" align="right"><span>开始时间:</span></td>
  177. <td width="75%"><input id="START_DATE_375" name="START_DATE_375" type="text" class="date" style="width: 97%;" readonly="readonly"></select></td>
  178. </tr>
  179. <tr>
  180. <td width="25%" align="right"><span>结束时间:</span></td>
  181. <td width="75%"><input id="END_DATE_375" name="END_DATE_375" type="text" class="date" style="width: 97%;" readonly="readonly"></select></td>
  182. </tr>
  183. </table>
  184. </form>
  185. </div>
  186. </body>
  187. </html>