| | |
| | | user.setJurisdiction(one.getId().toString()); |
| | | } |
| | | userService.submit(user); |
| | | String birthday = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss").format(user.getBirthday()); |
| | | String rtime = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss").format(user.getRtime()); |
| | | // String birthday = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss").format(user.getBirthday()); |
| | | String rtime = null; |
| | | if (null!=user.getRtime()) { |
| | | rtime = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss").format(user.getRtime()); |
| | | } |
| | | String s = "insert into blade_user(id,tenant_id,account,password,name,real_name,avatar,email,phone,birthday,sex,role_id,dept_id,cardid,nativePlace,nation,education," + |
| | | "politicaloutlook,healstats,height,address,registered,rtime,securitynumber,hold,jurisdiction) " + |
| | | "values(" + "'" + user.getId() + "'" + "," + "'" + 000000 + "'" + "," + "'" + user.getAccount() + "'" + "," + |
| | | "'" + user.getPassword() + "'" + "," +"'" + user.getName() + "'" + "," + "'" + user.getRealName() + "'" + "," + "'" + user.getAvatar() + "'" + "," + |
| | | "'" + user.getEmail() + "'" + "," + "'" + user.getPhone() + "'" + "," + "'" + birthday + "'" + "," + "'" + user.getSex() + "'" + "," + "'" + user.getRoleId() + "'" + |
| | | "'" + user.getEmail() + "'" + "," + "'" + user.getPhone() + "'" + "," + "'" + user.getSex() + "'" + "," + "'" + user.getRoleId() + "'" + |
| | | "," + "'" + user.getDeptId() + "'" + "," + "'" + user.getCardid() + "'" + "," + "'" + user.getNativeplace() + "'" + "," + "'" |
| | | + user.getNation() + "'" + "," + "'" + user.getEducation() + "'" + "," + "'" + user.getPoliticaloutlook() + "'" + "," + "'" + user.getHealstats() + "'" |
| | | + "," +"'" + user.getHeight() + "'" + "," + "'" + user.getAddress() + "'" +"," + "'" + user.getRegistered() + "'"+ "," + |
| | |
| | | userExcel.setRegistered("江西南昌"); |
| | | userExcel.setRtime("2021-05-01"); |
| | | userExcel.setHold("是"); |
| | | userExcel.setSex("赣洪202100001"); |
| | | userExcel.setSecuritynumber("赣洪202100001"); |
| | | list.add(userExcel); |
| | | UserExcel userExcel1 = new UserExcel(); |
| | | userExcel1.setDeptId("xxx保安公司"); |
| | |
| | | userExcel1.setRegistered("江西南昌"); |
| | | userExcel1.setRtime("2021-05-01"); |
| | | userExcel1.setHold("否"); |
| | | userExcel1.setSex(""); |
| | | userExcel1.setSecuritynumber(""); |
| | | list.add(userExcel1); |
| | | ExcelUtil.export(response, "保安员导入数据模板", "保安员数据表", list, UserExcel.class); |
| | | } |
| | |
| | | } |
| | | |
| | | |
| | | /** |
| | | * 保安员信息 |
| | | * @param user |
| | | * @return |
| | | */ |
| | | @GetMapping("/getUserDetails") |
| | | public R getUserDetails(User user) { |
| | | return R.data(userService.getUserDetails(user)); |
| | | } |
| | | |
| | | |
| | | /** |
| | | * |
| | | * @param type 1:保安 2:公安 |
| | | * @param deptid |
| | | * @param jurisdiction |
| | | * @return |
| | | */ |
| | | @GetMapping("/seleL") |
| | | public R seleL(String type,String deptid, String jurisdiction) { |
| | | List<Map<String, Object>> list = userService.seleL(type,deptid, jurisdiction); |
| | | return R.data(list); |
| | | } |
| | | |
| | | |
| | | |
| | | } |