4f59045cc9111c93434a1e2f7330dea5935056ec.svn-base 11 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369
  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>应急组织外部机构信息</title>
  6. <!--框架必需start-->
  7. <script type="text/javascript" src="/nwyj/scripts/qui/libs/js/jquery.js"></script>
  8. <script type="text/javascript"
  9. src="/nwyj/scripts/qui/libs/js/language/cn.js"></script>
  10. <script type="text/javascript"
  11. src="/nwyj/scripts/qui/libs/js/framework.js"></script>
  12. <link href="/nwyj/scripts/qui/libs/css/import_basic.css"
  13. rel="stylesheet" type="text/css" />
  14. <link rel="stylesheet" type="text/css" id="skin"
  15. prePath="/nwyj/scripts/qui/" />
  16. <link rel="stylesheet" type="text/css" id="customSkin" />
  17. <!--框架必需end-->
  18. <script type="text/javascript"
  19. src="/nwyj/scripts/qui/libs/js/form/form.js"></script>
  20. <script type="text/javascript"
  21. src="/nwyj/scripts/qui/libs/js/form/validation.js"></script>
  22. <script type="text/javascript"
  23. src="/nwyj/scripts/qui/libs/js/form/validationRule.js"></script>
  24. <script type="text/javascript"
  25. src="/nwyj/scripts/qui/libs/js/popup/messager.js"></script>
  26. <!--弹窗组件start-->
  27. <script type="text/javascript"
  28. src="/nwyj/scripts/qui/libs/js/popup/drag.js"></script>
  29. <script type="text/javascript"
  30. src="/nwyj/scripts/qui/libs/js/popup/dialog.js"></script>
  31. <!--弹窗组件end-->
  32. <!--弹出式提示框start-->
  33. <script type="text/javascript"
  34. src="/nwyj/scripts/qui/libs/js/popup/messager.js"></script>
  35. <!--弹出式提示框end-->
  36. <!--数据表格start-->
  37. <script src="/nwyj/scripts/qui/libs/js/table/quiGrid.js"
  38. type="text/javascript"></script>
  39. <!--数据表格end-->
  40. <!--树组件start-->
  41. <link rel="stylesheet" type="text/css"
  42. href="/nwyj/scripts/qui/libs/js/tree/ztree/ztree.css" />
  43. <script type="text/javascript"
  44. src="/nwyj/scripts/qui/libs/js/tree/ztree/ztree.js"></script>
  45. <script type="text/javascript"
  46. src="/nwyj/scripts/qui/libs/js/form/selectTree.js"></script>
  47. <script type="text/javascript"
  48. src="/nwyj/scripts/qui/libs/js/form/listerTree.js"></script>
  49. <!--树组件end-->
  50. <!-- 日期选择框start -->
  51. <script type="text/javascript"
  52. src="/nwyj/scripts/qui/libs/js/form/datePicker/WdatePicker.js"></script>
  53. <!-- 日期选择框end -->
  54. <!-- 扩展工具js -->
  55. <script type="text/javascript" src="/nwyj/scripts/common/common.js"></script>
  56. <script type="text/javascript"
  57. src="/nwyj/scripts/jquery/plugins/jquery.extension.util.js"></script>
  58. <script type="text/javascript"
  59. src="/nwyj/scripts/freamwork/com/sinosoft/common/common.js"></script>
  60. <!-- <script type="text/javascript"
  61. src="../../../../../scripts/business/am/org/maintenance/out-orginfo.js"></script> -->
  62. <style type="text/css">
  63. .hr3 {
  64. height: 2px;
  65. border: none;
  66. border-top: 2px ridge #45D6D8;
  67. }
  68. #org_info_span {
  69. font-size: 25px;
  70. color: blue;
  71. }
  72. #org_info_title {
  73. width: 760px;
  74. text-align: center;
  75. }
  76. .tool_class {
  77. display: inline-block;
  78. float: right;
  79. margin: 10px 10px 10px 10px;
  80. }
  81. .clear_style_org {
  82. visibility: hidden;
  83. clear: both;
  84. }
  85. </style>
  86. <script type="text/javascript">
  87. /* $(function() {
  88. //获得树节点的objectId用于加载机构信息
  89. fd_id_org = parent.sup_fd_objectId;
  90. //获得机构名称 用于查询筛选条件
  91. org_name_org = parent.sup_org_name;
  92. //初始化界面
  93. init_orgInfo()
  94. })
  95. //初始化机构的详细信息
  96. function init_orgInfo() {
  97. //更新界面显示--界面title(机构名称)
  98. document.getElementById("org_info_span").innerHTML = org_name_org;
  99. //隐藏按钮
  100. document.getElementById("am_org_img").style.display = "none";
  101. document.getElementById("option_tr").style.display = "none";
  102. //加载机构信息显示
  103. var url = $.pathname() + '/ws/crud/CRUDService/getDataById/';
  104. var params = {
  105. classid : '212',
  106. objectID : fd_id_org
  107. };
  108. $.ajax({
  109. url : url,
  110. type : 'post',
  111. timeout : 60000,
  112. data : params,
  113. dataType : 'json',
  114. success : function(data) {
  115. $("#fillForm").ajaxWrite({
  116. data : data
  117. });
  118. $("#fillForm input[name='classid']").val("212");
  119. },
  120. error : function(e) {
  121. $.messager.alert('系统提示信息', '访问服务失败!', 'error');
  122. }
  123. });
  124. }
  125. //修改按钮操作
  126. function update_operator() {
  127. //显示 “返回”图标 “保存” “重置”按钮
  128. document.getElementById("am_org_img").style.display = "";
  129. document.getElementById("option_tr").style.display = "";
  130. //隐藏 “修改” “删除”按钮
  131. document.getElementById("update_orgInfo").style.display = "none";
  132. document.getElementById("delete_orgInfo").style.display = "none";
  133. //将只读样式去掉
  134. var readOnly_input = document.getElementsByTagName("input");
  135. for (var i = 0; i < readOnly_input.length; i++) {
  136. readOnly_input[i].readOnly = false;
  137. }
  138. }
  139. //删除机构事件
  140. function delete_operator() {
  141. alert("点击了删除按钮");
  142. top.Dialog.confirm("确定要删除吗?|删除", function() {
  143. // 删除记录
  144. $.post($.pathname() + "/ws/crud/CRUDService/delete/", {
  145. "objectIDs" : fd_id_org,
  146. classid : 212
  147. }, function(result) {
  148. if (result.Msg.sucsess == true) {
  149. $.messager.alert("删除成功", null, null, null, 1);
  150. //清空界面
  151. document.getElementById("fillForm").setAttribute("style",
  152. "none");
  153. } else {
  154. top.Dialog.alert("删除失败!");
  155. }
  156. }, "json");
  157. });
  158. document.getElementById("fillForm").setAttribute("style", "none");
  159. }
  160. //修改事件--表单提交时触发
  161. function save_orgInfo() {
  162. //验证表单
  163. editValidate();
  164. }
  165. //表单验证
  166. function editValidate() {
  167. var valid = $("#fillForm").validationEngine({
  168. returnIsValid : true,
  169. });
  170. if (valid == true) {
  171. editfn();
  172. } else {
  173. top.Dialog.alert('表单填写不正确,请按要求填写!');
  174. }
  175. }
  176. //修改机构信息--发送请求后台交互
  177. function editfn() {
  178. $form = $("#fillForm");
  179. var formValue = $form.serialize();
  180. $("#classid").val("212");
  181. var url = $.pathname() + "/ws/crud/CRUDService/update/";
  182. $.ajax({
  183. url : url,
  184. type : "post",
  185. timeout : 60000,
  186. data : formValue,
  187. dataType : "json",
  188. success : function(data) {
  189. top.Dialog.alert("修改成功,点击返回按钮返回列表");
  190. },
  191. error : function() {
  192. top.Dialog.alert("修改失败,稍后再试...");
  193. }
  194. });
  195. }
  196. //返回图标单击事件 --重新加载界面
  197. function goBack() {
  198. location.reload();
  199. } */
  200. //部门id
  201. var dpids = top.com.sinosoft.lz.system.user.LoginInfo.getDeptids();
  202. //取得用户真实姓名
  203. var realname = top.com.sinosoft.lz.system.user.LoginInfo.getReal_name();
  204. //获取用户的Id
  205. var userId = top.com.sinosoft.lz.system.user.LoginInfo.getUser_id();
  206. //部门名称
  207. var deptName = top.com.sinosoft.lz.system.user.LoginInfo.getDeptnames();
  208. //父部门id
  209. var parentId = top.com.sinosoft.lz.system.user.LoginInfo.getParent_ids();
  210. //外部单位的怕人id
  211. var outOrgParentId =top.com.sinosoft.lz.system.user.LoginInfo.getDeptids();
  212. //当前机构树点击节点的id
  213. var fd_id = parent.sup_fd_objectId;
  214. $(function() {
  215. var iframe = parent.document.getElementsByName("frmrightChild")[0];
  216. var iframeUrl = iframe.src;
  217. //alert("src==="+iframeUrl);
  218. //判定查看详情--》更新界面显示的信息
  219. //var fd_id = (iframeUrl).split('?')[1];
  220. if(fd_id==outOrgParentId||fd_id==null||""==fd_id){
  221. $("#titleShow").html("外部机构");
  222. }else{
  223. var url = $.pathname() + "/ws/crud/CRUDService/getDataById/";
  224. var params = {
  225. classid : '212',
  226. objectID : fd_id
  227. };
  228. /* ajax请求 */
  229. $.ajax({
  230. url : url,
  231. type : 'post',
  232. timeout : 60000,
  233. data : params,
  234. dataType : 'json',
  235. success : function(data) {
  236. /* $("#fillForm").ajaxWrite({
  237. data : data
  238. });
  239. $("#fillForm input[name='classid']").val("212"); */
  240. for(var i in data){
  241. $("#"+i).html(data[i]);
  242. }
  243. //显示标题信息
  244. $("#titleShow").html(data.ORG_DEPT_NAME_212);
  245. },
  246. error : function(e) {
  247. $.messager.alert('系统提示信息', '访问服务失败!', 'error');
  248. }
  249. });
  250. }
  251. });
  252. function refreshOutOrgInfo(fd_objectid){
  253. if(fd_objectid==outOrgParentId||fd_objectid==null||""==fd_objectid){
  254. $("#titleShow").html("外部机构");
  255. }else{
  256. var url = $.pathname() + "/ws/crud/CRUDService/getDataById/";
  257. var params = {
  258. classid : '212',
  259. objectID : fd_objectid
  260. };
  261. /* ajax请求 */
  262. $.ajax({
  263. url : url,
  264. type : 'post',
  265. timeout : 60000,
  266. data : params,
  267. dataType : 'json',
  268. success : function(data) {
  269. /* $("#fillForm").ajaxWrite({
  270. data : data
  271. });
  272. $("#fillForm input[name='classid']").val("212"); */
  273. for(var i in data){
  274. $("#"+i).html(data[i]);
  275. }
  276. //显示标题信息
  277. $("#titleShow").html(data.ORG_DEPT_NAME_212);
  278. },
  279. error : function(e) {
  280. $.messager.alert('系统提示信息', '访问服务失败!', 'error');
  281. }
  282. });
  283. }
  284. }
  285. </script>
  286. </head>
  287. <body>
  288. <div class="box1" id="formContent"
  289. style="overflow:auto;height:545px;border: 1px solid #E4E4E4;background: #F8F8F8;">
  290. <div style="height: 50px;background: #F8F8F8;" align="center">
  291. <font style="font-weight: bold;font-size: 20px;line-height: 45px;" id="titleShow"></font></div>
  292. <div>
  293. <form id="fillForm" action="javascript:save_orgInfo()" method="post"
  294. failAlert="表单填写错误,请检查">
  295. <table class="tableStyle" formMode="view">
  296. <tr style="display: none;">
  297. <td><input type="hidden" id="fd_id212" name="FD_OBJECTID212"
  298. required="true" /> <input type="hidden" name="classid"
  299. value="212" required="true" /></td>
  300. </tr>
  301. <tr>
  302. <td width="18%" align="right">机构名称:</td>
  303. <td width="32%" id="ORG_DEPT_NAME_212" name="ORG_DEPT_NAME_212"></td>
  304. <td width="18%" align="right">机构类别:</td>
  305. <td width="32%" id="ORG_DEPT_TYPE_212_SHOW" name="ORG_DEPT_TYPE_212_SHOW"></td>
  306. </tr>
  307. <tr>
  308. <td width="18%" align="right">所在区域:</td>
  309. <td width="32%" id="LOCATION_212" name="LOCATION_212"></td>
  310. <td width="18%" align="right">办公地点:</td>
  311. <td width="32%" id="WORK_ADDRESS_212" name="WORK_ADDRESS_212"></td>
  312. </tr>
  313. <tr>
  314. <td width="18%" align="right">联动部门:</td>
  315. <td width="32%" id="LINK_DEPT_212_SHOW" name="LINK_DEPT_212__SHOW"></td>
  316. <td width="18%" align="right">联动联系人:</td>
  317. <td width="32%" id="LINK_MAN_212_SHOW" name="LINK_MAN_212_SHOW"></td>
  318. </tr>
  319. <tr>
  320. <td width="18%" align="right">邮编:</td>
  321. <td width="32%" id="CODE_212" name="CODE_212"></td>
  322. <td width="18%" align="right">网址:</td>
  323. <td width="32%" id="SITE_212" name="SITE_212"></td>
  324. </tr>
  325. </table>
  326. </form>
  327. </div>
  328. </div>
  329. </body>
  330. </html>