tBusActivitiUserPersonnel-add.jsp 23 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512
  1. <%@ page language="java" import="java.util.*" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8" %>
  2. <%@include file="/context/mytags.jsp" %>
  3. <!DOCTYPE html>
  4. <html>
  5. <head>
  6. <title>员工信息</title>
  7. <t:base type="jquery,easyui,tools,DatePicker"></t:base>
  8. <script type="text/javascript">
  9. //编写自定义JS代码
  10. $(function () {
  11. $.Datatype.checkIdcard = function (val, obj, frm) {
  12. var msg = true;
  13. $.ajax({
  14. url: 'userActivitiController.do?checkIdcard'
  15. , data: {idcard: val}
  16. , dataType: 'json'
  17. , method: "POST"
  18. , async: false
  19. , success: function (d) {
  20. if (!d.success) {
  21. msg = d.msg
  22. }
  23. }
  24. }
  25. )
  26. return msg;
  27. }
  28. });
  29. </script>
  30. </head>
  31. <body>
  32. <t:formvalid formid="formobj" dialog="false" usePlugin="password" layout="table"
  33. action="userActivitiController.do?doAdd" callback="callback">
  34. <input id="id" name="id" type="hidden" value="${obj.id }"/>
  35. <input id="userType" name="userType" type="hidden" value="${projectUser?1:0}"/>
  36. <table style="width: 1000px;" cellpadding="0" cellspacing="1" class="formtable">
  37. <tr>
  38. <td align="right" nowrap>
  39. <label class="Validform_label"><span color="red" class="requiredIcon">*</span>员工工号: </label>
  40. </td>
  41. <td class="value">
  42. <%--<c:if test="${obj.id!=null }"> ${obj.userNum } </c:if>--%>
  43. <%--<c:if test="${obj.id==null }">--%>
  44. <input id="userNum" class="inputxt" name="userNum" value="${obj.userNum }" datatype="s2-10"
  45. userInfoValidType="t_s_user,userNum,id"/>
  46. <span class="Validform_checktip"></span>
  47. <span class="Validform_checktip" style="display: none;"> 员工工号范围在2~10位字符</span>
  48. <%--</c:if>--%>
  49. </td>
  50. <td align="right">
  51. <label class="Validform_label">
  52. <span color="red" class="requiredIcon">*</span>员工姓名:
  53. </label>
  54. </td>
  55. <td class="value">
  56. <input id="realname" name="realName" type="text" style="width: 150px" class="inputxt" datatype="s2-10"
  57. value="${obj.realName}"/>
  58. <span class="Validform_checktip"></span>
  59. <label class="Validform_label" style="display: none;">姓名</label>
  60. </td>
  61. </tr>
  62. <tr>
  63. <td align="right">
  64. <label class="Validform_label">
  65. <span color="red" class="requiredIcon">*</span>性别:
  66. </label>
  67. </td>
  68. <td class="value">
  69. <t:dictSelect field="gender" id="gender" type="list" typeGroupCode="sex" defaultVal="${obj.gender}"
  70. hasLabel="false" datatype="*" title="性别"></t:dictSelect>
  71. <span class="Validform_checktip"></span>
  72. <label class="Validform_label" style="display: none;">性别</label>
  73. </td>
  74. <td align="right">
  75. <label class="Validform_label">
  76. <span color="red" class="requiredIcon">*</span>民族:
  77. </label>
  78. </td>
  79. <td class="value">
  80. <t:dictSelect field="nation" id="nation" type="list" typeGroupCode="nation"
  81. defaultVal="${empty obj.nation?'hanzu':obj.nation }" hasLabel="false" datatype="*"
  82. title="民族"
  83. ></t:dictSelect>
  84. <span class="Validform_checktip"></span>
  85. <label class="Validform_label" style="display: none;">民族</label>
  86. </td>
  87. </tr>
  88. <tr>
  89. <td align="right">
  90. <label class="Validform_label">
  91. <span color="red" class="requiredIcon">*</span>手机号码:
  92. </label>
  93. </td>
  94. <td class="value">
  95. <input id="mobilephone" name="mobilePhone" type="text" style="width: 150px" class="inputxt"
  96. value="${obj.mobilePhone}" datatype="m" errormsg="手机号码不正确"
  97. userInfoValidType="t_s_user,mobilePhone,id"/>
  98. <span class="Validform_checktip"></span>
  99. <label class="Validform_label" style="display: none;">手机号</label>
  100. </td>
  101. <td align="right">
  102. <label class="Validform_label">
  103. <span color="red" class="requiredIcon">*</span>身份证号:
  104. </label>
  105. </td>
  106. <td class="value">
  107. <!-- <input id="idcard" name="idcard" type="text" style="width: 150px" class="inputxt" -->
  108. <%-- value='${obj.idcard}' placeholder="" datatype="idcard,checkIdcard" errormsg="请填写正确的身份证号码!" --%>
  109. <!-- /> -->
  110. <input id="idcard" name="idcard" type="text" style="width: 150px" class="inputxt"
  111. value='${obj.idcard}' placeholder="" datatype="idcard,checkIdcard" errormsg="请填写正确的身份证号码!"
  112. />
  113. <span class="Validform_checktip"></span>
  114. <label class="Validform_label" style="display: none;">身份证号</label>
  115. </td>
  116. </tr>
  117. <tr>
  118. <td align="right">
  119. <label class="Validform_label">
  120. <span color="red" class="requiredIcon">*</span>学历:
  121. </label>
  122. </td>
  123. <td class="value">
  124. <t:dictSelect field="education" id="education" type="list" typeGroupCode="education" hasLabel="false"
  125. datatype="*" title="学历" defaultVal="${obj.education}"></t:dictSelect>
  126. <span class="Validform_checktip"></span>
  127. <label class="Validform_label" style="display: none;">学历</label>
  128. </td>
  129. <td align="right">
  130. <label class="Validform_label"><span color="red" class="requiredIcon">*</span>户口属性</label>
  131. </td>
  132. <td class="value">
  133. <t:dictSelect field="hktype" id="hktype" type="list"
  134. typeGroupCode="hktype" hasLabel="false" datatype="*" title="户口属性"
  135. defaultVal="${obj.hktype}"></t:dictSelect>
  136. <span class="Validform_checktip"></span>
  137. <label class="Validform_label" style="display: none;">户口属性</label>
  138. </td>
  139. </tr>
  140. <tr>
  141. <td align="right">
  142. <label class="Validform_label">
  143. <span color="red" class="requiredIcon">*</span>薪资:
  144. </label>
  145. </td>
  146. <td class="value">
  147. <input id="money" name="money" type="text" style="width: 150px" class="inputxt" datatype="d"
  148. value="${obj.money}"/>
  149. <span class="Validform_checktip"></span>
  150. <label class="Validform_label" style="display: none;">薪资</label>
  151. </td>
  152. </tr>
  153. <tr>
  154. <td align="right">
  155. <label class="Validform_label">
  156. <span color="red" class="requiredIcon">*</span>所属部门:
  157. </label>
  158. </td>
  159. <td class="value" colspan="3">
  160. <input id="departname" name="departName" type="text" readonly="readonly" class="inputxt" datatype="*"
  161. value="${obj.departName}">
  162. <input id="departId" name="departId" type="hidden" value="${obj.departId}">
  163. <c:if test="${empty param.load}">
  164. <a href="#" class="easyui-linkbutton" plain="true" icon="icon-select" id="departSearch"
  165. onclick="openDepartmentSelect()">选择</a>
  166. <a href="#" class="easyui-linkbutton" plain="true" icon="icon-clean" id="departRedo"
  167. onclick="callbackClean()">清空</a>
  168. </c:if>
  169. <span class="Validform_checktip">
  170. <c:if test="${projectUser}">所属部门只能单选</c:if>
  171. <c:if test="${not projectUser}">一线员工必须选择保安部、保洁部等部门;项目经理和内勤必须选择项目</c:if>
  172. </span>
  173. </td>
  174. </tr>
  175. <tr>
  176. <td align="right">
  177. <label class="Validform_label">
  178. <span color="red" class="requiredIcon">*</span>职务:
  179. </label>
  180. </td>
  181. <td class="value" >
  182. <input id="duty" name="duty" type="hidden" datatype="*" value="${obj.duty}">
  183. <input id="dutyName" name="dutyName" type="text" style="width: 150px" readonly="readonly"
  184. value='${obj.dutyName}' placeholder="请选择所属职务"/>
  185. <c:if test="${empty param.load}">
  186. <a href="javascript:void(0)" class="easyui-linkbutton" plain="true" icon="icon-select" id="dutiesSearch"
  187. onclick="openDutiesSelect()">选择</a>
  188. <a href="javascript:void(0)" class="easyui-linkbutton" plain="true" icon="icon-clean" id="dutiesRedo"
  189. onclick="dutiesClean()">清空</a>
  190. </c:if>
  191. <span class="Validform_checktip"></span>
  192. <label class="Validform_label" style="display: none;">职务</label>
  193. </td>
  194. </tr>
  195. <tr>
  196. <td align="right">
  197. <label class="Validform_label">
  198. 居住地址:
  199. </label>
  200. </td>
  201. <td class="value" colspan="2">
  202. <input id="address" name="address" type="text" style="width: 300px" class="inputxt" datatype="*0-100"
  203. value="${obj.address}"/>
  204. <span class="Validform_checktip"></span>
  205. <label class="Validform_label" style="display: none;">地址</label>
  206. </td>
  207. </tr>
  208. <tr>
  209. <td align="right">
  210. <label class="Validform_label">
  211. 户口地址:
  212. </label>
  213. </td>
  214. <td class="value" colspan="2">
  215. <input id="hkaddress" name="hkaddress" type="text" style="width: 300px" class="inputxt"
  216. datatype="*0-100" value="${obj.hkaddress}"/>
  217. <span class="Validform_checktip"></span>
  218. <label class="Validform_label" style="display: none;">户口地址</label>
  219. </td>
  220. </tr>
  221. <tr>
  222. <td align="right">
  223. <label class="Validform_label">
  224. <span color="red" class="requiredIcon">*</span>入司日期:
  225. </label>
  226. </td>
  227. <td class="value">
  228. <input id="contractStime" name="contractStime" type="text" style="width: 150px"
  229. class="Wdate" onClick="WdatePicker()" readonly="readonly" datatype="*"
  230. value="<fmt:formatDate value="${obj.contractStime}" pattern="yyyy-MM-dd"/>"/>
  231. <span class="Validform_checktip"></span>
  232. <label class="Validform_label" style="display: none;">入司日期</label>
  233. </td>
  234. </tr>
  235. <tr>
  236. <td align="right">
  237. <label class="Validform_label">
  238. <span color="red" class="requiredIcon">*</span>合同时长(年):
  239. </label>
  240. </td>
  241. <td class="value">
  242. <input id="contractLong" name="contractLong" type="text" style="width: 150px" class="inputxt"
  243. datatype="n" value="${obj.contractLong}"/>
  244. <span class="Validform_checktip"></span>
  245. <label class="Validform_label" style="display: none;">合同时长</label>
  246. </td>
  247. <td align="right">
  248. <label class="Validform_label">
  249. <span color="red" class="requiredIcon">*</span>试用期限(月):
  250. </label>
  251. </td>
  252. <td class="value">
  253. <t:dictSelect field="trialPeriod" id="trialPeriod" type="list" typeGroupCode="shiyongqi" datatype="*"
  254. defaultVal="${obj.trialPeriod}" hasLabel="false" title="试用期限"></t:dictSelect>
  255. <span class="Validform_checktip"></span>
  256. <label class="Validform_label" style="display: none;">试用期限</label>
  257. </td>
  258. </tr>
  259. <tr>
  260. <td align="right">
  261. <label class="Validform_label">
  262. <span color="red" class="requiredIcon">*</span>缴金方式:
  263. </label>
  264. </td>
  265. <td class="value">
  266. <t:dictSelect field="jiaojin" id="jiaojin" type="list" typeGroupCode="jiaojin"
  267. hasLabel="false" datatype="*" title="缴金方式" defaultVal="${obj.jiaojin}"></t:dictSelect>
  268. <span class="Validform_checktip"></span>
  269. <label class="Validform_label" style="display: none;">缴金方式</label>
  270. </td>
  271. <td align="right">
  272. <label class="Validform_label">
  273. 拟排班方式:
  274. </label>
  275. </td>
  276. <td class="value">
  277. <input id="prearrange" name="prearrange" type="text" style="width: 150px" class="inputxt"
  278. value="${obj.prearrange}"/>
  279. <span class="Validform_checktip"></span>
  280. <label class="Validform_label" style="display: none;">拟排班方式</label>
  281. </td>
  282. </tr>
  283. <tr>
  284. <td align="right">
  285. <label class="Validform_label">
  286. 从业经验:
  287. </label>
  288. </td>
  289. <td class="value" colspan="2">
  290. <input id="experience" name="experience" type="text" style="width: 300px" class="inputxt"
  291. value="${obj.experience}"/>
  292. <span class="Validform_checktip"></span>
  293. <label class="Validform_label" style="display: none;">从业经验</label>
  294. </td>
  295. </tr>
  296. <tr>
  297. <td align="right">
  298. <label class="Validform_label">
  299. 备注:
  300. </label>
  301. </td>
  302. <td class="value" colspan="3">
  303. <textarea id="remark" name="remark" type="text" class="inputxt" ignore="ignore"
  304. style="width: 300px; height: 60px;">${obj.remark}</textarea>
  305. <span class="Validform_checktip"></span>
  306. <label class="Validform_label" style="display: none;">备注</label>
  307. </td>
  308. </tr>
  309. <tr>
  310. <td align="right"> <label class="Validform_label">岗位编制: </label></td>
  311. <td class="value" colspan="3">${needNum}</td>
  312. </tr>
  313. <%--<tr>
  314. <td align="right">
  315. <label class="Validform_label">
  316. 用户账户:
  317. </label>
  318. </td>
  319. <td class="value">
  320. <input id="username" name="userName" type="text" style="width: 150px" class="inputxt" datatype="s2-10" value="${obj.userName}"
  321. userInfoValidType="t_s_base_user,username,id"/>
  322. <span class="Validform_checktip"></span>
  323. <label class="Validform_label" style="display: none;">用户账户</label>
  324. </td>
  325. </tr>
  326. <tr>
  327. <td align="right"><label class="Validform_label"> <t:mutiLang langKey="common.common.mail"/>: </label></td>
  328. <td class="value">
  329. <input class="inputxt" name="email" value="${obj.email}" datatype="e" errormsg="邮箱格式不正确!">
  330. <span class="Validform_checktip"></span>
  331. </td>
  332. </tr>--%>
  333. <div style="display:none"><input type="submit" id="btn_sub" value=""/></div>
  334. <c:choose>
  335. <c:when test="${param.returnBack ==1}"><%--审批退回--%>
  336. <tr id="tdbtn">
  337. <td height="38px" align="right"> <!-- style="display: none" -->
  338. <!-- <a href="#" class="easyui-linkbutton l-btn" plain="true" iconcls="icon-le-back" onclick="history.go(-1)">返回</a> -->
  339. <a href="javascript:void(0)" class="easyui-linkbutton l-btn" iconcls="icon-le-ok"
  340. onclick="btn_ok()"> &nbsp;&nbsp;&nbsp;保&nbsp;&nbsp;存</a>
  341. </td>
  342. </tr>
  343. </c:when>
  344. <c:otherwise>
  345. <c:if test="${empty param.load}">
  346. <tr>
  347. <td height="50px" align="center" colspan="2">
  348. <a href="javascript:void(0)" class="easyui-linkbutton l-btn" iconcls="icon-confirm" onclick="btn_ok()">确定</a>
  349. <a style="margin-left:0px" href="javascript:void(0)" class="easyui-linkbutton l-btn" plain="true" iconcls="icon-return"
  350. onclick="cal();">返回</a>
  351. </td>
  352. </tr>
  353. </c:if>
  354. </c:otherwise>
  355. </c:choose>
  356. </table>
  357. </t:formvalid>
  358. </body>
  359. <script>
  360. function openDepartmentSelect() {
  361. var departId = $("#departId").val();
  362. var projectUser = '${projectUser}';
  363. var params = '&ids=' + departId;
  364. if (projectUser == 'true') {
  365. $.dialog({
  366. content: 'url:dialogDealController.do?projectDepartTablePartChild' + params,
  367. zIndex: getzIndex(),
  368. title: '项目名称列表',
  369. lock: true,
  370. width: '600px',
  371. height: '400px',
  372. opacity: 0.4,
  373. button: [
  374. {
  375. name: '确定', callback: function () {
  376. var iframe = this.iframe.contentWindow;
  377. if (iframe.getReason().length > 0) {
  378. var strData = eval(iframe.getReason());
  379. for (var key in strData[0]) {
  380. if (key == "strPId") {
  381. $("#departId").val(strData[0][key]);
  382. } else if (key == "strDepartName") {
  383. $("#departname").val(strData[0][key]);
  384. }
  385. }
  386. }
  387. }, focus: true
  388. },
  389. {
  390. name: '取消', callback: function () {
  391. $('#departname').val('');
  392. $('#departId').val('');
  393. }
  394. }
  395. ]
  396. }).zindex();
  397. } else {
  398. $.dialog({
  399. content: 'url:dialogDealController.do?projectDepartTableAllWithChild' + params,
  400. zIndex: getzIndex(),
  401. title: '项目名称列表',
  402. lock: true,
  403. width: '600px',
  404. height: '400px',
  405. opacity: 0.4,
  406. button: [
  407. {
  408. name: '<t:mutiLang langKey="common.confirm"/>', callback: function () {
  409. var iframe = this.iframe.contentWindow;
  410. if (iframe.getReason().length > 0) {
  411. var strData = eval(iframe.getReason());
  412. for (var key in strData[0]) {
  413. if (key == "strPId") {
  414. $("#departId").val(strData[0][key]);
  415. } else if (key == "strDepartName") {
  416. $("#departname").val(strData[0][key]);
  417. }
  418. }
  419. }
  420. }, focus: true
  421. },
  422. {
  423. name: '<t:mutiLang langKey="common.cancel"/>', callback: function () {
  424. $('#departname').val('');
  425. $('#departId').val('');
  426. }
  427. }
  428. ]
  429. }).zindex();
  430. }
  431. }
  432. function callbackClean() {
  433. $('#departname').val('');
  434. $('#departId').val('');
  435. }
  436. // 职务选择
  437. function openDutiesSelect() {
  438. $.dialog.setting.zIndex = getzIndex();
  439. var orgIds = $("#duty").val();
  440. $.dialog({
  441. content: 'url:dutiesController.do?departSelect${dutyCodeFilter}&orgIds=' + orgIds,
  442. zIndex: getzIndex(),
  443. title: '职务列表',
  444. lock: true,
  445. width: '400px',
  446. height: '350px',
  447. opacity: 0.4,
  448. button: [
  449. {name: '<t:mutiLang langKey="common.confirm"/>', callback: callbackDutiesSelect, focus: true},
  450. {
  451. name: '<t:mutiLang langKey="common.cancel"/>', callback: function () {
  452. }
  453. }
  454. ]
  455. }).zindex();
  456. }
  457. // 职务回调
  458. function callbackDutiesSelect() {
  459. var iframe = this.iframe.contentWindow;
  460. var treeObj = iframe.$.fn.zTree.getZTreeObj("departSelect");
  461. var nodes = treeObj.getCheckedNodes();
  462. // var nodes = treeObj.getSelectedNodes();
  463. // console.log(nodes);
  464. if (nodes.length > 0) {
  465. var ids = '', names = '';
  466. for (var i = 0; i < nodes.length; i++) {
  467. var node = nodes[i];
  468. ids += node.id + ',';
  469. names += node.name + ',';
  470. }
  471. ids = ids.substring(0, ids.length - 1);
  472. names = names.substring(0, names.length - 1);
  473. $("#dutyName").val(names);
  474. $("#dutyName").blur();
  475. $("#duty").val(ids);
  476. }
  477. }
  478. function dutiesClean() {
  479. $("#duty").val('');
  480. $("#dutyName").val('');
  481. }
  482. function btn_ok() {
  483. $("#btn_sub").click();
  484. }
  485. function cal(){
  486. location='userActivitiController.do?list';
  487. }
  488. function callback(){
  489. console.log(arguments)
  490. <c:choose>
  491. <c:when test="${param.returnBack ==1}"><%--审批退回--%>
  492. tip("已保存,请重新提交审批");
  493. </c:when>
  494. <c:otherwise>
  495. location='userActivitiController.do?list';
  496. </c:otherwise>
  497. </c:choose>
  498. }
  499. </script>