atsAttendanceFileDisUser.jsp 4.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146
  1. <%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
  2. <%@include file="/commons/include/html_doctype.html" %>
  3. <html>
  4. <head>
  5. <title>考勤档案管理</title>
  6. <%@include file="/commons/include/get.jsp" %>
  7. <script type="text/javascript" src="${ctx}/js/hotent/platform/system/SysDialog.js"></script>
  8. <script>
  9. function selectUser(){
  10. UserDialog({isSingle:true,callback:function(userId,userName,emails,mobiles,rtn){
  11. $('#userId').val(userId);
  12. $('#fullName').val(userName);
  13. }});
  14. }
  15. function selectOrg(){
  16. OrgDialog({isSingle:true,callback:function(orgId,orgName){
  17. $('#orgId').val(orgId);
  18. $('#orgName').val(orgName);
  19. }});
  20. }
  21. function addSelect(){
  22. var $aryId = $("input[type='checkbox'][disabled!='disabled'][class='pk']:checked");
  23. if($aryId.length == 0){
  24. $.ligerDialog.warn("请选择记录!");
  25. return false;
  26. }
  27. var aryId="",len=$aryId.length;
  28. $aryId.each(function(i){
  29. var val=$(this).val();
  30. if(i<len-1){
  31. aryId+=val +",";
  32. }else{
  33. aryId+=val;
  34. }
  35. });
  36. add(aryId);
  37. }
  38. function addAll(){
  39. add();
  40. }
  41. function add(aryId){
  42. $.ligerDialog.confirm("是否按默认配置新增?","提示信息",function(rtn) {
  43. if (rtn) {
  44. $.ligerDialog.waitting("请稍后……");
  45. $.ajax({
  46. type : "POST",
  47. url : __ctx + "/platform/ats/atsAttendanceFile/saveAdd.ht",
  48. data : {
  49. aryId : aryId
  50. },
  51. success : function(data) {
  52. $.ligerDialog.closeWaitting();
  53. var d = $.parseJSON(data);
  54. if(d.success){
  55. $.ligerDialog.alert("新增考勤档案成功!","提示信息",function(rtn) {
  56. window.location.href = window.location.href;
  57. });
  58. }else{
  59. $.ligerDialog.err("提示信息","考勤档案保存失败!",obj.getMessage());
  60. }
  61. }
  62. });
  63. }else{
  64. var url=__ctx + '/platform/ats/atsAttendanceFile/setting.ht';
  65. url=url.getNewUrl();
  66. DialogUtil.open({
  67. height:400,
  68. width: 800,
  69. title : '设置新增配置',
  70. url: url,
  71. isResize: true,
  72. //自定义参数
  73. params: aryId,
  74. //回调函数
  75. sucCall:function(rtn){
  76. if(rtn)
  77. window.location.href = window.location.href;
  78. }
  79. });
  80. }
  81. });
  82. }
  83. </script>
  84. </head>
  85. <body>
  86. <div class="panel">
  87. <div class="panel-top">
  88. <div class="panel-toolbar">
  89. <div class="toolBar">
  90. <div class="group"><a class="link search" id="btnSearch"><span></span>查询</a></div>
  91. <div class="l-bar-separator"></div>
  92. <div class="group"><a class="link add" id="add" onclick="addSelect();"><span></span>新增选择</a></div>
  93. <div class="l-bar-separator"></div>
  94. <div class="group"><a class="link add" id="addAll" onclick="add();" ><span></span>新增所有</a></div>
  95. <div class="l-bar-separator"></div>
  96. <div class="l-bar-separator"></div>
  97. <div class="group"><a class="link back" href="${ctx}/platform/ats/atsAttendanceFile/list.ht"><span></span>返回</a></div>
  98. </div>
  99. </div>
  100. <div class="panel-search">
  101. <form id="searchForm" method="post" action="disUser.ht">
  102. <ul class="row">
  103. <li>
  104. <span class="label">用户:</span>
  105. <input type="hidden" id="userId" name="Q_userId_L" value="${param['Q_userId_L']}" />
  106. <input type="text" id="fullName" name="Q_fullName_SL" value="${param['Q_fullName_SL']}" readonly="readonly" />
  107. <a href="javascript:void(0);" onclick="selectUser()" class="button inputText"><span>选 择...</span></a>
  108. </li>
  109. <li>
  110. <span class="label">组织:</span>
  111. <input type="hidden" id="orgId" name="Q_orgId_L" value="${param['Q_orgId_L']}" />
  112. <input type="text" id="orgName" name="Q_orgName_SL" class="inputText" value="${param['Q_orgName_SL']}" readonly="readonly"/>
  113. <a href="javascript:void(0);" onclick="selectOrg()" class="button inputText"><span>选 择...</span></a>
  114. </li>
  115. </ul>
  116. </form>
  117. </div>
  118. </div>
  119. <div class="panel-body">
  120. <c:set var="checkAll">
  121. <input type="checkbox" id="chkall"/>
  122. </c:set>
  123. <display:table name="sysUserList" id="sysUserItem" requestURI="disUser.ht" sort="external" cellpadding="1" cellspacing="1" class="table-grid">
  124. <display:column title="${checkAll}" media="html" style="width:30px;">
  125. <input type="checkbox" class="pk" name="userId" value="${sysUserItem.userId}">
  126. </display:column>
  127. <display:column property="fullname" title="姓名" sortable="true" sortName="USER_ID"></display:column>
  128. <display:column property="account" title="员工编号" sortable="true" sortName="ACCOUNT"></display:column>
  129. <display:column property="orgName" title="所属组织" sortable="true" sortName="orgName" maxLength="80"></display:column>
  130. </display:table>
  131. <hotent:paging tableId="sysUserItem"/>
  132. </div><!-- end of panel-body -->
  133. </div> <!-- end of panel -->
  134. </body>
  135. </html>