listStaffInsuranceHistory.jsp 9.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296
  1. <%@ page language="java" contentType="text/html;charset=GBK" pageEncoding="GBK"%>
  2. <%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
  3. <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
  4. <html>
  5. <head>
  6. <meta http-equiv="Content-Type" content="text/html;charset=GBK">
  7. <title>员工社保查询列表</title>
  8. <link href="${pageContext.request.contextPath}/main.css" rel="stylesheet" type="text/css" />
  9. <link href="${pageContext.request.contextPath }/liger/lib/ligerUI/skins/${sessionScope.css}/css/ligerui-all.css" rel="stylesheet" type="text/css" />
  10. <script src="${pageContext.request.contextPath }/liger/lib/jquery/jquery-1.3.2.min.js" type="text/javascript"></script>
  11. <script src="${pageContext.request.contextPath }/liger/lib/ligerUI/js/core/base.js" type="text/javascript"></script>
  12. <script src="${pageContext.request.contextPath}/liger/lib/ligerUI/js/ligerui.all.js" type="text/javascript"></script>
  13. <script type="text/javascript" src="/shares/datePicker/WdatePicker.js"></script>
  14. <script type="text/javascript" src="/shares/js/constant.js"></script>
  15. <script type="text/javascript" src="/shares/js/common.js"></script>
  16. <script type="text/javascript">
  17. var grid = null;
  18. var oDialog = null;
  19. $(function() {
  20. initSalaryInsuranceHistoryList();
  21. });
  22. function initSalaryInsuranceHistoryList(params) {
  23. var columns = [ {
  24. display : '姓名',
  25. name : 'staff_name',
  26. width : 60
  27. }, {
  28. display : '身份证号',
  29. name : 'id_number',
  30. width: 150
  31. }, {
  32. display : '职位',
  33. name : 'digits'
  34. }, {
  35. display : '状态',
  36. name : 'state_name'
  37. }, {
  38. display : '社保月份',
  39. name : 'insurance_month',
  40. width : 60
  41. }, {
  42. display : '社保扣费月',
  43. name : 'insurance_charged_month',
  44. width : 60
  45. }, {
  46. display : '帐套信息',
  47. name : 'insurance_count_name',
  48. width : 150
  49. } ];
  50. // var columns2 = ;
  51. var distinct_project = ${requestScope.distinct_project_json};
  52. for (var i = 0; i < distinct_project.length; i++) {
  53. columns
  54. .push({
  55. display : distinct_project[i].insurance_proj_name,
  56. name : 'plan_time_str',
  57. columns : [
  58. {
  59. display : '基数',
  60. name : 'base_number',
  61. width : 60,
  62. render : function(row, index, value, column) {
  63. // alert(column.columnindex+"==="+parseInt(column.columnindex/5)+"==="+i);
  64. var projectIndex = parseInt(column.columnindex / 5) - 1;
  65. var s = "0";
  66. if (row.historyDetialList[projectIndex].base_number) {
  67. s = row.historyDetialList[projectIndex].base_number;
  68. }
  69. ;
  70. return s;
  71. }
  72. },
  73. {
  74. display : '单位',
  75. columns : [
  76. {
  77. display : '比例',
  78. name : 'CustomerID',
  79. width : 50,
  80. align : 'center',
  81. render : function(row, index,
  82. value, column) {
  83. // alert(column.columnindex+"==="+parseInt(column.columnindex/5)+"==="+i);
  84. var projectIndex = parseInt(column.columnindex / 5) - 1;
  85. var s = "0";
  86. if (row.historyDetialList[projectIndex].unit_pay) {
  87. s = row.historyDetialList[projectIndex].unit_pay;
  88. if (row.historyDetialList[projectIndex].unit_pay_method == 0) {
  89. s += "%";
  90. }
  91. ;
  92. }
  93. ;
  94. return s;
  95. }
  96. },
  97. {
  98. display : '金额',
  99. name : 'ContactName',
  100. width : 50,
  101. align : 'right',
  102. render : function(row, index,
  103. value, column) {
  104. // alert(column.columnindex+"==="+parseInt(column.columnindex/5)+"==="+i);
  105. var projectIndex = parseInt(column.columnindex / 5) - 1;
  106. var s = "0";
  107. if (row.historyDetialList[projectIndex].unit_actual_pay) {
  108. s = row.historyDetialList[projectIndex].unit_actual_pay;
  109. }
  110. ;
  111. return s;
  112. }
  113. } ]
  114. },
  115. {
  116. display : '个人',
  117. columns : [
  118. {
  119. display : '比例',
  120. name : 'CustomerID',
  121. width : 50,
  122. align : 'center',
  123. render : function(row, index,
  124. value, column) {
  125. // alert(column.columnindex+"==="+parseInt(column.columnindex/5)+"==="+i);
  126. var projectIndex = parseInt(column.columnindex / 5) - 2;
  127. var s = "0";
  128. if (row.historyDetialList[projectIndex].person_pay) {
  129. s = row.historyDetialList[projectIndex].person_pay;
  130. if (row.historyDetialList[projectIndex].person_pay_method == 0) {
  131. s += "%";
  132. }
  133. ;
  134. }
  135. ;
  136. return s;
  137. }
  138. },
  139. {
  140. display : '金额',
  141. name : 'ContactName',
  142. width : 50,
  143. align : 'right',
  144. render : function(row, index,
  145. value, column) {
  146. // alert(column.columnindex+"==="+parseInt(column.columnindex/5)+"==="+i);
  147. var projectIndex = parseInt(column.columnindex / 5) - 2;
  148. var s = "0";
  149. if (row.historyDetialList[projectIndex].person_actual_pay) {
  150. s = row.historyDetialList[projectIndex].person_actual_pay;
  151. }
  152. ;
  153. return s;
  154. }
  155. } ]
  156. } ]
  157. });
  158. }
  159. columns.push({
  160. display : "合计",
  161. name : 'plan_time_str',
  162. columns : [ {
  163. display : '单位',
  164. name : 'unit_amount',
  165. width : 50,
  166. }, {
  167. display : '个人',
  168. name : 'person_amount',
  169. width : 50,
  170. } ]
  171. });
  172. grid = $("#maingrid4")
  173. .ligerGrid(
  174. {
  175. columns : columns,
  176. pageSize : 20,
  177. url : 'hrSalaryStaffInsuranceHistoryAction.do?task=queryStaffInsureHistoryData&time='
  178. + new Date().getTime() + params,
  179. pageParmName : 'p', //页索引参数名,(提交给服务器)
  180. pagesizeParmName : 'pSize', //页记录数参数名,(提交给服务器)
  181. width : '99.9%',
  182. height : '99%'
  183. });
  184. $("#pageloading").hide();
  185. }
  186. //查询
  187. function searchByKword() {
  188. var s = "";
  189. var staff_name = $("#staff_name");//姓名
  190. if (staff_name) {
  191. s += "&salaryInsuranceHistory.staff_name="
  192. + encodeURI(encodeURI(staff_name.val()));
  193. }
  194. var insurance_count_id = $("#insurance_count_id");//社保帐套
  195. if (insurance_count_id) {
  196. s += "&salaryInsuranceHistory.insurance_count_id="
  197. + insurance_count_id.val();
  198. }
  199. var insurance_month_start = $("#insurance_month_start");
  200. if (insurance_month_start) {
  201. s += "&salaryInsuranceHistory.insurance_month_start="
  202. + insurance_month_start.val();
  203. }
  204. var insurance_month_end = $("#insurance_month_end");//规则名称
  205. if (insurance_month_end) {
  206. s += "&salaryInsuranceHistory.insurance_month_end="
  207. + insurance_month_end.val();
  208. }
  209. grid.set("newPage", "1");
  210. initSalaryInsuranceHistoryList(s);
  211. }
  212. function createStaffInsuranceHistory() {
  213. oDialog = openTopDialog({
  214. title : '选择项目',
  215. width : 650,
  216. height : 400,
  217. url : 'hrSalaryStaffInsuranceHistoryAction.do?task=toCreateStaffInsureHistory'
  218. + '&tabid=' + getCurrentTabId() + "&time=" + new Date(),
  219. // +'&depot_id='
  220. // + ins_depot_id_val + '&location_id='
  221. // + ins_location_id_val,
  222. buttons : [ {
  223. text : '保存',
  224. onclick : f_btnOK
  225. }, {
  226. text : '取消',
  227. onclick : f_btnCancel
  228. } ]
  229. });
  230. }
  231. function closeODialog() {
  232. oDialog.close();
  233. }
  234. function f_btnOK(item, dialog) {
  235. if (!dialog.frame.checkForm()) {
  236. return;
  237. }
  238. dialog.frame.btnSave();
  239. // dialog.close();
  240. }
  241. function f_btnCancel(item, dialog) {
  242. if (dialog)
  243. dialog.close();
  244. }
  245. </script>
  246. </head>
  247. <body>
  248. <div class="container">
  249. <div id="title" class="form-button">
  250. <input type="button" class="l-button" value="生成报表" onclick="createStaffInsuranceHistory();" style="width: 70px" />
  251. </div>
  252. <div class="default_search" style="margin: 0; height: 30px;"></div>
  253. <div class="default_search" style="margin: 0;">
  254. <ul class="list_search">
  255. <li class="title">姓名:</li>
  256. <li class="text"><input type="text" id=staff_name name="staff_name" /></li>
  257. </ul>
  258. <ul class="list_search">
  259. <li class="title">帐套信息:</li>
  260. <li class="text"><select id="insurance_count_id" name="salaryStaffInsurance.insurance_count_id">
  261. <option value="">全部</option>
  262. <c:forEach items="${sicList }" var="sic">
  263. <option value="${sic.universalid }">${sic.count_name }</option>
  264. </c:forEach>
  265. </select></li>
  266. </ul>
  267. <ul class="list_search" >
  268. <li class="title">社保月份:</li>
  269. <li class="text" "><input type="text" class="Wdate" name="insurance_month_start" id="insurance_month_start"
  270. onclick="WdatePicker({dateFmt:'yyyy-MM',maxDate:'#F{$dp.$D(\'insurance_month_end\',{d:0})}'})" /> 至 <input type="text" class="Wdate" name="insurance_month_end"
  271. id="insurance_month_end" onclick="WdatePicker({dateFmt:'yyyy-MM',minDate:'#F{$dp.$D(\'insurance_month_start\',{d:0})}'})" /></li>
  272. </ul>
  273. <ul>
  274. <li class="search-button"><input type="button" class='l-button' name="search" onclick="searchByKword()" value="查询" /></li>
  275. </ul>
  276. </div>
  277. <div style="clear: both;"></div>
  278. <div id="searchbar">
  279. <div style="overflow: hidden; clear: both;">
  280. <div id="maingrid4" style="margin: 0; padding: 0"></div>
  281. </div>
  282. </div>
  283. </div>
  284. </body>
  285. </html>