| | |
| | | import com.stylefeng.guns.modular.system.model.*; |
| | | import com.stylefeng.guns.modular.system.service.*; |
| | | import com.stylefeng.guns.modular.system.util.EmailUtil; |
| | | import com.stylefeng.guns.modular.system.util.HttpRequestUtil; |
| | | import com.stylefeng.guns.modular.system.util.PushURL; |
| | | import com.stylefeng.guns.modular.system.util.RedisUtil; |
| | | import com.stylefeng.guns.modular.system.util.ResultUtil; |
| | | import org.apache.poi.ss.usermodel.Cell; |
| | | import org.apache.poi.ss.usermodel.Row; |
| | |
| | | |
| | | @Value("${spring.mail.template-path}") |
| | | private String templatePath; |
| | | |
| | | |
| | | |
| | | @Autowired |
| | | private RedisUtil redisUtil; |
| | | @Autowired |
| | | private IIncomeService incomeService; |
| | | @Autowired |
| | | private ITUserService userService; |
| | | @Autowired |
| | | private IUserActivityInviteService userActivityInviteService; |
| | | @Autowired |
| | | private IDriverActivityRegisteredService driverActivityRegisteredService; |
| | | @Autowired |
| | | private ITCompanyService itCompanyService; |
| | | @Autowired |
| | | private ITDriverServiceService itDriverServiceService; |
| | | |
| | | /** |
| | | * 跳转到司机审核列表首页 |
| | |
| | | */ |
| | | @RequestMapping("/tDriver_add") |
| | | public String tDriverAdd(Model model) { |
| | | List<TCompany> companyList = tCompanyService.selectList(new EntityWrapper<TCompany>().eq("type", 2)); |
| | | List<TCompany> companyList = tCompanyService.selectList(new EntityWrapper<TCompany>().eq("type", 2) |
| | | .eq("state", 0).ne("flag", 3)); |
| | | model.addAttribute("companyList",companyList); |
| | | |
| | | Integer roleType = ShiroKit.getUser().getRoleType(); |
| | |
| | | model.addAttribute("objectName",tCompanyService.selectById(ShiroKit.getUser().getObjectId()).getName()); |
| | | |
| | | if (1 == roleType){ |
| | | List<TCompany> companyList = tCompanyService.selectList(new EntityWrapper<TCompany>().eq("type", 2)); |
| | | List<TCompany> companyList = tCompanyService.selectList(new EntityWrapper<TCompany>().eq("type", 2).eq("state", 0).ne("flag", 3)); |
| | | model.addAttribute("companyList",companyList); |
| | | List<TCompany> franchiseeList = tCompanyService.selectList(new EntityWrapper<TCompany>().eq("type", 3).eq("superiorId",tDriver.getCompanyId())); |
| | | List<TCompany> franchiseeList = tCompanyService.selectList(new EntityWrapper<TCompany>().eq("type", 3).eq("superiorId",tDriver.getCompanyId()).eq("state", 0).ne("flag", 3)); |
| | | model.addAttribute("franchiseeList",franchiseeList); |
| | | }else if (2 == roleType){ |
| | | List<TCompany> franchiseeList = tCompanyService.selectList(new EntityWrapper<TCompany>().eq("type", 3).eq("superiorId",ShiroKit.getUser().getObjectId())); |
| | | List<TCompany> franchiseeList = tCompanyService.selectList(new EntityWrapper<TCompany>().eq("type", 3).eq("superiorId",ShiroKit.getUser().getObjectId()).eq("state", 0).ne("flag", 3)); |
| | | model.addAttribute("franchiseeList",franchiseeList); |
| | | } |
| | | |
| | | //查询平台ID |
| | | TCompany company = tCompanyService.selectOne(new EntityWrapper<TCompany>().eq("type", 1)); |
| | | TCompany company = tCompanyService.selectOne(new EntityWrapper<TCompany>().eq("type", 1).eq("state", 0).ne("flag", 3)); |
| | | //判断是平台司机还是加盟司机 |
| | | if ((SinataUtil.isEmpty(tDriver.getCompanyId()) || tDriver.getCompanyId() == 0 || tDriver.getCompanyId() == company.getId()) && (SinataUtil.isEmpty(tDriver.getFranchiseeId()) || tDriver.getFranchiseeId() == 0)){ |
| | | model.addAttribute("companyType",1); |
| | |
| | | model.addAttribute("id", id); |
| | | return PREFIX + "training.html"; |
| | | } |
| | | |
| | | |
| | | /** |
| | | * 保存培训数据 |
| | |
| | | return ResultUtil.success(driverTrains); |
| | | } |
| | | |
| | | |
| | | /** |
| | | * 跳转到处罚页 |
| | | * @param id |
| | |
| | | model.addAttribute("id", id); |
| | | return PREFIX + "punish.html"; |
| | | } |
| | | |
| | | |
| | | /** |
| | | * 保存处罚数据 |
| | |
| | | return ResultUtil.success(); |
| | | } |
| | | |
| | | |
| | | /** |
| | | * 获取所有处罚数据 |
| | | * @param driverId |
| | |
| | | List<DriverPunish> driverPunishes = driverPunishMapper.queryAllPunish(driverId); |
| | | return ResultUtil.success(driverPunishes); |
| | | } |
| | | |
| | | |
| | | /** |
| | | * 根据分公司ID获取加盟商 |
| | |
| | | public Object listYesDriver(String insertTime, |
| | | String companyName, |
| | | String phone, |
| | | String name, |
| | | String lastName, |
| | | String firstName, |
| | | Integer addType, |
| | | Integer authState, |
| | | Integer state, |
| | |
| | | endTime = timeArray[1]; |
| | | } |
| | | Page<Map<String, Object>> page = new PageFactory<Map<String, Object>>().defaultPage(); |
| | | page.setRecords(tDriverService.getDriverList(page,ShiroKit.getUser().getRoleType(),ShiroKit.getUser().getObjectId(),beginTime,endTime,companyName,phone,name,addType,authState,state,teamId)); |
| | | page.setRecords(tDriverService.getDriverList(page,ShiroKit.getUser().getRoleType(),ShiroKit.getUser().getObjectId(),beginTime,endTime,companyName,phone,lastName,firstName,addType,authState,state,teamId)); |
| | | return super.packForBT(page); |
| | | } |
| | | |
| | |
| | | return super.packForBT(page); |
| | | |
| | | } |
| | | |
| | | @Autowired |
| | | private IIncomeService incomeService; |
| | | |
| | | |
| | | @Autowired |
| | | private ITUserService userService; |
| | | |
| | | @Autowired |
| | | private IUserActivityInviteService userActivityInviteService; |
| | | |
| | | @Autowired |
| | | private IDriverActivityRegisteredService driverActivityRegisteredService; |
| | | |
| | | |
| | | /** |
| | | * 审核操作 1=通过 2=不通过 |
| | |
| | | type = 6; |
| | | tDriver.setAuthState(4); |
| | | } |
| | | |
| | | new Thread(new Runnable() { |
| | | @Override |
| | | public void run() { |
| | | try { |
| | | String path = templatePath + "driver/index.html"; |
| | | Document document = Jsoup.parse(new File(path), "UTF-8"); |
| | | document.getElementById("chinese").attr("style", "display: none;"); |
| | | document.getElementById("french").attr("style", "display: none;"); |
| | | document.getElementById("invite1").attr("style", "display: none;"); |
| | | document.getElementById("user1").attr("style", "display: none;"); |
| | | document.getElementById("settle1").attr("style", "display: none;"); |
| | | document.getElementById("pass1").attr("style", "display: none;"); |
| | | document.getElementById("email1").attr("style", "display: none;"); |
| | | document.getElementById("bill1").attr("style", "display: none;"); |
| | | document.getElementById("reward1").attr("style", "display: none;"); |
| | | document.getElementById("rewardToday1").attr("style", "display: none;"); |
| | | document.getElementById("carAudit1").attr("style", "display: none;"); |
| | | document.getElementById("chinese").remove(); |
| | | document.getElementById("french").remove(); |
| | | document.getElementById("invite1").remove(); |
| | | document.getElementById("user1").remove(); |
| | | document.getElementById("settle1").remove(); |
| | | document.getElementById("pass1").remove(); |
| | | document.getElementById("email1").remove(); |
| | | document.getElementById("bill1").remove(); |
| | | document.getElementById("reward1").remove(); |
| | | document.getElementById("rewardToday1").remove(); |
| | | document.getElementById("carAudit1").remove(); |
| | | |
| | | document.getElementsByTag("title").get(0).text(1 == authState ? "Driver is verified and qualified" : "Driver is not verified and qualified"); |
| | | Element driver_audit1_user = document.getElementById("driver_audit1_user"); |
| | | driver_audit1_user.text("Hello " + tDriver.getName() + ","); |
| | | driver_audit1_user.text("Hello " + tDriver.getFirstName() + " " + tDriver.getLastName() + ","); |
| | | Element driver_audit1_content = document.getElementById("driver_audit1_content"); |
| | | if(1 == authState){ |
| | | driver_audit1_content.text("You application has been approved."); |
| | | driver_audit1_content.text("Your application has been approved."); |
| | | }else{ |
| | | driver_audit1_content.text("I'm sorry, your application was rejected. Reason for rejection: Incomplete filling in personal information."); |
| | | driver_audit1_content.text("We are sorry to inform you that your application was rejected. Please contact our service for relevant details, call 0577777767 or send e-mail to support@i-go.group"); |
| | | } |
| | | EmailUtil.send(tDriver.getEmail(), "Notice of driver registration application", document.html()); |
| | | EmailUtil.send(tDriver.getEmail(), 1 == authState ? "Driver is verified and qualified" : "Driver is not verified and qualified", document.html()); |
| | | }catch (Exception e){ |
| | | e.printStackTrace(); |
| | | } |
| | |
| | | |
| | | tDriver.setPassword(ShiroKit.md5(tDriver.getPassword(), "SA;d5#")); |
| | | |
| | | String phone = tDriver.getPhone(); |
| | | String substring = phone.substring(0, 1); |
| | | if("0".equals(substring)){ |
| | | phone = "233" + phone.substring(1); |
| | | } |
| | | if(phone.indexOf("233") < 0){ |
| | | phone = "233" + phone; |
| | | } |
| | | tDriver.setPhone(phone); |
| | | tDriver.setAccount(phone); |
| | | tDriver.setBalance(new BigDecimal(0)); |
| | | // tDriver.setCommission(new BigDecimal(0)); |
| | | // tDriver.setCouponBalance(new BigDecimal(0)); |
| | | // tDriver.setBackgroundBalance(new BigDecimal(0)); |
| | | |
| | | tDriverService.insert(tDriver); |
| | | |
| | | //添加经营业务 |
| | |
| | | |
| | | return SUCCESS_TIP; |
| | | } |
| | | |
| | | |
| | | /** |
| | | * 添加线路 |
| | | * @param subArr |
| | |
| | | } |
| | | } |
| | | |
| | | |
| | | /** |
| | | * 删除司机审核列表 |
| | | */ |
| | |
| | | tDriverService.updateById(driver); |
| | | return SUCCESS_TIP; |
| | | } |
| | | |
| | | /** |
| | | * 操作司机状态 |
| | | */ |
| | |
| | | if (1 == optType){ //解冻 |
| | | tDriver.setAuthState(2); |
| | | }else if (2 == optType){ //冻结 |
| | | String token = redisUtil.getValue("DRIVER_" + tDriver.getPhone()); |
| | | redisUtil.remove(token);//删除个人信息数据 |
| | | redisUtil.remove("DRIVER_" + tDriver.getPhone());//删除后台冻结相关缓存 |
| | | redisUtil.remove("DRIVER_" + driverId);//清除存储的token |
| | | tDriver.setAuthState(3); |
| | | } |
| | | tDriver.setRemark(remark); |
| | |
| | | tDriver.setPassword(obj.getPassword()); |
| | | } |
| | | |
| | | String phone = tDriver.getPhone(); |
| | | String substring = phone.substring(0, 1); |
| | | if("0".equals(substring)){ |
| | | phone = "233" + phone.substring(1); |
| | | } |
| | | if(phone.indexOf("233") < 0){ |
| | | phone = "233" + phone; |
| | | } |
| | | tDriver.setPhone(phone); |
| | | tDriver.setAccount(phone); |
| | | tDriverService.updateById(tDriver); |
| | | |
| | | //删除业务 |
| | |
| | | if (ShiroKit.getUser().getRoleType() == 1){ |
| | | title = "平台导入司机模板"; |
| | | |
| | | shellList.add("司机名称"); |
| | | shellList.add("司机姓"); |
| | | shellList.add("司机名"); |
| | | shellList.add("所属机构[平台司机/加盟司机]"); |
| | | shellList.add("所属分公司[提示:加盟司机选填]"); |
| | | shellList.add("所属加盟商[提示:加盟司机选填]"); |
| | |
| | | }else if (ShiroKit.getUser().getRoleType() == 2){ |
| | | title = "分公司导入司机模板"; |
| | | |
| | | shellList.add("司机名称"); |
| | | shellList.add("司机姓"); |
| | | shellList.add("司机名"); |
| | | shellList.add("所属加盟商[选填]"); |
| | | shellList.add("性别[男/女]"); |
| | | shellList.add("驾驶证号码"); |
| | |
| | | }else if (ShiroKit.getUser().getRoleType() == 3){ |
| | | title = "加盟商导入司机模板"; |
| | | |
| | | shellList.add("司机名称"); |
| | | shellList.add("司机姓"); |
| | | shellList.add("司机名"); |
| | | shellList.add("性别[男/女]"); |
| | | shellList.add("驾驶证号码"); |
| | | shellList.add("驾龄"); |
| | |
| | | zero = String.valueOf(cell0.getStringCellValue()).trim(); |
| | | } |
| | | |
| | | Cell cell1 = row.getCell(1); //所属机构[平台司机/加盟司机] |
| | | Cell cell01 = row.getCell(1); //司机名称 |
| | | String zero1 = null; |
| | | if (SinataUtil.isNotEmpty(cell01)){ |
| | | zero1 = String.valueOf(cell01.getStringCellValue()).trim(); |
| | | } |
| | | |
| | | Cell cell1 = row.getCell(2); //所属机构[平台司机/加盟司机] |
| | | String one = null; |
| | | if (SinataUtil.isNotEmpty(cell1)){ |
| | | one = String.valueOf(cell1.getStringCellValue()).trim(); |
| | | } |
| | | |
| | | Cell cell2 = row.getCell(2); //所属分公司[提示:加盟司机选填] |
| | | Cell cell2 = row.getCell(3); //所属分公司[提示:加盟司机选填] |
| | | String two = null; |
| | | if (SinataUtil.isNotEmpty(cell2)){ |
| | | two = String.valueOf(cell2.getStringCellValue()).trim(); |
| | | } |
| | | |
| | | Cell cell3 = row.getCell(3); //所属加盟商[提示:加盟司机选填] |
| | | Cell cell3 = row.getCell(4); //所属加盟商[提示:加盟司机选填] |
| | | String three = null; |
| | | if (SinataUtil.isNotEmpty(cell3)){ |
| | | three = String.valueOf(cell3.getStringCellValue()).trim(); |
| | | } |
| | | |
| | | Cell cell4 = row.getCell(4); //性别[男/女] |
| | | Cell cell4 = row.getCell(5); //性别[男/女] |
| | | String four = null; |
| | | if (SinataUtil.isNotEmpty(cell4)){ |
| | | four = String.valueOf(cell4.getStringCellValue()).trim(); |
| | | } |
| | | |
| | | Cell cell5 = row.getCell(5); //驾驶证号码 |
| | | Cell cell5 = row.getCell(6); //驾驶证号码 |
| | | String five = null; |
| | | if (SinataUtil.isNotEmpty(cell5)){ |
| | | five = String.valueOf(cell5.getStringCellValue()).trim(); |
| | | } |
| | | |
| | | Cell cell6 = row.getCell(6); //驾龄 |
| | | Cell cell6 = row.getCell(7); //驾龄 |
| | | String six = null; |
| | | if (SinataUtil.isNotEmpty(cell6)){ |
| | | six = String.valueOf(cell6.getStringCellValue()).trim(); |
| | | } |
| | | |
| | | Cell cell7 = row.getCell(7); //身份证号 |
| | | Cell cell7 = row.getCell(8); //身份证号 |
| | | String seven = null; |
| | | if (SinataUtil.isNotEmpty(cell7)){ |
| | | seven = String.valueOf(cell7.getStringCellValue()).trim(); |
| | | } |
| | | |
| | | Cell cell8 = row.getCell(8); //居住地址 |
| | | Cell cell8 = row.getCell(9); //居住地址 |
| | | String eight = null; |
| | | if (SinataUtil.isNotEmpty(cell8)){ |
| | | eight = String.valueOf(cell8.getStringCellValue()).trim(); |
| | | } |
| | | |
| | | Cell cell9 = row.getCell(9); //出租车资格证号 |
| | | Cell cell9 = row.getCell(10); //出租车资格证号 |
| | | String nine = null; |
| | | if (SinataUtil.isNotEmpty(cell9)){ |
| | | nine = String.valueOf(cell9.getStringCellValue()).trim(); |
| | | } |
| | | |
| | | Cell cell10 = row.getCell(10); //工号[选填] |
| | | Cell cell10 = row.getCell(11); //工号[选填] |
| | | String ten = null; |
| | | if (SinataUtil.isNotEmpty(cell10)){ |
| | | ten = String.valueOf(cell10.getStringCellValue()).trim(); |
| | | } |
| | | |
| | | Cell cell11 = row.getCell(11); //经营业务:专车[是/否] |
| | | Cell cell11 = row.getCell(12); //经营业务:专车[是/否] |
| | | String eleven = null; |
| | | if (SinataUtil.isNotEmpty(cell11)){ |
| | | eleven = String.valueOf(cell11.getStringCellValue()).trim(); |
| | | } |
| | | |
| | | Cell cell12 = row.getCell(12); //经营业务:专车[是/否] |
| | | Cell cell12 = row.getCell(13); //经营业务:专车[是/否] |
| | | String twelve = null; |
| | | if (SinataUtil.isNotEmpty(cell12)){ |
| | | twelve = String.valueOf(cell12.getStringCellValue()).trim(); |
| | | } |
| | | |
| | | Cell cell13 = row.getCell(13); //经营业务:跨城出行[是/否] |
| | | Cell cell13 = row.getCell(14); //经营业务:跨城出行[是/否] |
| | | String thirteen = null; |
| | | if (SinataUtil.isNotEmpty(cell13)){ |
| | | thirteen = String.valueOf(cell13.getStringCellValue()).trim(); |
| | | } |
| | | |
| | | Cell cell14 = row.getCell(14); //经营业务:小件同城物流[是/否] |
| | | Cell cell14 = row.getCell(15); //经营业务:小件同城物流[是/否] |
| | | String fourteen = null; |
| | | if (SinataUtil.isNotEmpty(cell14)){ |
| | | fourteen = String.valueOf(cell14.getStringCellValue()).trim(); |
| | | } |
| | | |
| | | Cell cell15 = row.getCell(15); //经营业务:小件跨城物流[是/否] |
| | | Cell cell15 = row.getCell(16); //经营业务:小件跨城物流[是/否] |
| | | String fifteen = null; |
| | | if (SinataUtil.isNotEmpty(cell15)){ |
| | | fifteen = String.valueOf(cell15.getStringCellValue()).trim(); |
| | | } |
| | | |
| | | Cell cell16 = row.getCell(16); //经营业务:包车[是/否] |
| | | Cell cell16 = row.getCell(17); //经营业务:包车[是/否] |
| | | String sixteen = null; |
| | | if (SinataUtil.isNotEmpty(cell16)){ |
| | | sixteen = String.valueOf(cell16.getStringCellValue()).trim(); |
| | | } |
| | | |
| | | Cell cell17 = row.getCell(17); //登录账号[手机号] |
| | | Cell cell17 = row.getCell(18); //登录账号[手机号] |
| | | String seventeen = null; |
| | | if (SinataUtil.isNotEmpty(cell17)){ |
| | | seventeen = String.valueOf(cell17.getStringCellValue()).trim(); |
| | | String substring = seventeen.substring(0, 1); |
| | | if("0".equals(substring)){ |
| | | seventeen = "233" + seventeen.substring(1); |
| | | } |
| | | if(seventeen.indexOf("233") < 0){ |
| | | seventeen = "233" + seventeen; |
| | | } |
| | | } |
| | | |
| | | Cell cell18 = row.getCell(18); //登录密码[密码长度为6-18] |
| | | Cell cell18 = row.getCell(19); //登录密码[密码长度为6-18] |
| | | String eighteen = null; |
| | | if (SinataUtil.isNotEmpty(cell18)){ |
| | | eighteen = String.valueOf(cell18.getStringCellValue()).trim(); |
| | | } |
| | | |
| | | if (SinataUtil.isEmpty(zero) || SinataUtil.isEmpty(one) || SinataUtil.isEmpty(four) |
| | | if (SinataUtil.isEmpty(zero) || SinataUtil.isEmpty(zero1) || SinataUtil.isEmpty(one) || SinataUtil.isEmpty(four) |
| | | || SinataUtil.isEmpty(five) || SinataUtil.isEmpty(six) || SinataUtil.isEmpty(nine) |
| | | || SinataUtil.isEmpty(eleven) || SinataUtil.isEmpty(twelve) || SinataUtil.isEmpty(thirteen) |
| | | || SinataUtil.isEmpty(fourteen) || SinataUtil.isEmpty(fifteen) || SinataUtil.isEmpty(sixteen) |
| | |
| | | driver.setJobNumber(ten); |
| | | driver.setPhone(seventeen); |
| | | driver.setPassword(ShiroKit.md5(eighteen, "SA;d5#")); |
| | | driver.setName(zero); |
| | | driver.setLastName(zero); |
| | | driver.setFirstName(zero1); |
| | | if ("男".equals(four)){ |
| | | driver.setSex(1); |
| | | }else if ("女".equals(four)){ |
| | |
| | | zero = String.valueOf(cell0.getStringCellValue()).trim(); |
| | | } |
| | | |
| | | Cell cell1 = row.getCell(1); //所属加盟商[选填] |
| | | Cell cell01 = row.getCell(1); //司机名称 |
| | | String zero1 = null; |
| | | if (SinataUtil.isNotEmpty(cell01)){ |
| | | zero1 = String.valueOf(cell01.getStringCellValue()).trim(); |
| | | } |
| | | |
| | | Cell cell1 = row.getCell(2); //所属加盟商[选填] |
| | | String one = null; |
| | | if (SinataUtil.isNotEmpty(cell1)){ |
| | | one = String.valueOf(cell1.getStringCellValue()).trim(); |
| | | } |
| | | |
| | | Cell cell2 = row.getCell(2); //性别[男/女] |
| | | Cell cell2 = row.getCell(3); //性别[男/女] |
| | | String two = null; |
| | | if (SinataUtil.isNotEmpty(cell2)){ |
| | | two = String.valueOf(cell2.getStringCellValue()).trim(); |
| | | } |
| | | |
| | | Cell cell3 = row.getCell(3); //驾驶证号码 |
| | | Cell cell3 = row.getCell(4); //驾驶证号码 |
| | | String three = null; |
| | | if (SinataUtil.isNotEmpty(cell3)){ |
| | | three = String.valueOf(cell3.getStringCellValue()).trim(); |
| | | } |
| | | |
| | | Cell cell4 = row.getCell(4); //驾龄 |
| | | Cell cell4 = row.getCell(5); //驾龄 |
| | | String four = null; |
| | | if (SinataUtil.isNotEmpty(cell4)){ |
| | | four = String.valueOf(cell4.getStringCellValue()).trim(); |
| | | } |
| | | |
| | | Cell cell5 = row.getCell(5); //身份证号 |
| | | Cell cell5 = row.getCell(6); //身份证号 |
| | | String five = null; |
| | | if (SinataUtil.isNotEmpty(cell5)){ |
| | | five = String.valueOf(cell5.getStringCellValue()).trim(); |
| | | } |
| | | |
| | | Cell cell6 = row.getCell(6); //居住地址 |
| | | Cell cell6 = row.getCell(7); //居住地址 |
| | | String six = null; |
| | | if (SinataUtil.isNotEmpty(cell6)){ |
| | | six = String.valueOf(cell6.getStringCellValue()).trim(); |
| | | } |
| | | |
| | | Cell cell7 = row.getCell(7); //出租车资格证号 |
| | | Cell cell7 = row.getCell(8); //出租车资格证号 |
| | | String seven = null; |
| | | if (SinataUtil.isNotEmpty(cell7)){ |
| | | seven = String.valueOf(cell7.getStringCellValue()).trim(); |
| | | } |
| | | |
| | | Cell cell8 = row.getCell(8); //工号[选填] |
| | | Cell cell8 = row.getCell(9); //工号[选填] |
| | | String eight = null; |
| | | if (SinataUtil.isNotEmpty(cell8)){ |
| | | eight = String.valueOf(cell8.getStringCellValue()).trim(); |
| | | } |
| | | |
| | | Cell cell9 = row.getCell(9); //经营业务:专车[是/否] |
| | | Cell cell9 = row.getCell(10); //经营业务:专车[是/否] |
| | | String nine = null; |
| | | if (SinataUtil.isNotEmpty(cell9)){ |
| | | nine = String.valueOf(cell9.getStringCellValue()).trim(); |
| | | } |
| | | |
| | | Cell cell10 = row.getCell(10); //经营业务:出租车[是/否] |
| | | Cell cell10 = row.getCell(11); //经营业务:出租车[是/否] |
| | | String ten = null; |
| | | if (SinataUtil.isNotEmpty(cell10)){ |
| | | ten = String.valueOf(cell10.getStringCellValue()).trim(); |
| | | } |
| | | |
| | | Cell cell11 = row.getCell(11); //经营业务:跨城出行[是/否] |
| | | Cell cell11 = row.getCell(12); //经营业务:跨城出行[是/否] |
| | | String eleven = null; |
| | | if (SinataUtil.isNotEmpty(cell11)){ |
| | | eleven = String.valueOf(cell11.getStringCellValue()).trim(); |
| | | } |
| | | |
| | | Cell cell12 = row.getCell(12); //经营业务:小件同城物流[是/否] |
| | | Cell cell12 = row.getCell(13); //经营业务:小件同城物流[是/否] |
| | | String twelve = null; |
| | | if (SinataUtil.isNotEmpty(cell12)){ |
| | | twelve = String.valueOf(cell12.getStringCellValue()).trim(); |
| | | } |
| | | |
| | | Cell cell13 = row.getCell(13); //经营业务:小件跨城物流[是/否] |
| | | Cell cell13 = row.getCell(14); //经营业务:小件跨城物流[是/否] |
| | | String thirteen = null; |
| | | if (SinataUtil.isNotEmpty(cell13)){ |
| | | thirteen = String.valueOf(cell13.getStringCellValue()).trim(); |
| | | } |
| | | |
| | | Cell cell14 = row.getCell(14); //经营业务:包车[是/否] |
| | | Cell cell14 = row.getCell(15); //经营业务:包车[是/否] |
| | | String fourteen = null; |
| | | if (SinataUtil.isNotEmpty(cell14)){ |
| | | fourteen = String.valueOf(cell14.getStringCellValue()).trim(); |
| | | } |
| | | |
| | | Cell cell15 = row.getCell(15); //登录账号[手机号] |
| | | Cell cell15 = row.getCell(16); //登录账号[手机号] |
| | | String fifteen = null; |
| | | if (SinataUtil.isNotEmpty(cell15)){ |
| | | fifteen = String.valueOf(cell15.getStringCellValue()).trim(); |
| | | |
| | | String substring = fifteen.substring(0, 1); |
| | | if("0".equals(substring)){ |
| | | fifteen = "233" + fifteen.substring(1); |
| | | } |
| | | if(fifteen.indexOf("233") < 0){ |
| | | fifteen = "233" + fifteen; |
| | | } |
| | | } |
| | | |
| | | Cell cell16 = row.getCell(16); //登录密码[密码长度为6-18] |
| | | Cell cell16 = row.getCell(17); //登录密码[密码长度为6-18] |
| | | String sixteen = null; |
| | | if (SinataUtil.isNotEmpty(cell16)){ |
| | | sixteen = String.valueOf(cell16.getStringCellValue()).trim(); |
| | | } |
| | | if (SinataUtil.isEmpty(zero) || SinataUtil.isEmpty(two) || SinataUtil.isEmpty(three) || SinataUtil.isEmpty(four) |
| | | if (SinataUtil.isEmpty(zero) || SinataUtil.isEmpty(zero1) || SinataUtil.isEmpty(two) || SinataUtil.isEmpty(three) || SinataUtil.isEmpty(four) |
| | | || SinataUtil.isEmpty(five) || SinataUtil.isEmpty(seven) |
| | | || SinataUtil.isEmpty(nine) || SinataUtil.isEmpty(ten) |
| | | || SinataUtil.isEmpty(eleven) || SinataUtil.isEmpty(twelve) || SinataUtil.isEmpty(thirteen) |
| | |
| | | driver.setJobNumber(eight); |
| | | driver.setPhone(fifteen); |
| | | driver.setPassword(ShiroKit.md5(sixteen, "SA;d5#")); |
| | | driver.setName(zero); |
| | | driver.setLastName(zero); |
| | | driver.setFirstName(zero1); |
| | | if ("男".equals(two)){ |
| | | driver.setSex(1); |
| | | }else if ("女".equals(two)){ |
| | |
| | | zero = String.valueOf(cell0.getStringCellValue()).trim(); |
| | | } |
| | | |
| | | Cell cell2 = row.getCell(1); //性别[男/女] |
| | | Cell cell01 = row.getCell(1); //司机名称 |
| | | String zero1 = null; |
| | | if (SinataUtil.isNotEmpty(cell01)){ |
| | | zero1 = String.valueOf(cell01.getStringCellValue()).trim(); |
| | | } |
| | | |
| | | Cell cell2 = row.getCell(2); //性别[男/女] |
| | | String one = null; |
| | | if (SinataUtil.isNotEmpty(cell2)){ |
| | | one = String.valueOf(cell2.getStringCellValue()).trim(); |
| | | } |
| | | |
| | | Cell cell3 = row.getCell(2); //驾驶证号码 |
| | | Cell cell3 = row.getCell(3); //驾驶证号码 |
| | | String two = null; |
| | | if (SinataUtil.isNotEmpty(cell3)){ |
| | | two = String.valueOf(cell3.getStringCellValue()).trim(); |
| | | } |
| | | |
| | | Cell cell4 = row.getCell(3); //驾龄 |
| | | Cell cell4 = row.getCell(4); //驾龄 |
| | | String three = null; |
| | | if (SinataUtil.isNotEmpty(cell4)){ |
| | | three = String.valueOf(cell4.getStringCellValue()).trim(); |
| | | } |
| | | |
| | | Cell cell5 = row.getCell(4); //身份证号 |
| | | Cell cell5 = row.getCell(5); //身份证号 |
| | | String four = null; |
| | | if (SinataUtil.isNotEmpty(cell5)){ |
| | | four = String.valueOf(cell5.getStringCellValue()).trim(); |
| | | } |
| | | |
| | | Cell cell6 = row.getCell(5); //居住地址 |
| | | Cell cell6 = row.getCell(6); //居住地址 |
| | | String five = null; |
| | | if (SinataUtil.isNotEmpty(cell6)){ |
| | | five = String.valueOf(cell6.getStringCellValue()).trim(); |
| | | } |
| | | |
| | | Cell cell7 = row.getCell(6); //出租车资格证号 |
| | | Cell cell7 = row.getCell(7); //出租车资格证号 |
| | | String six = null; |
| | | if (SinataUtil.isNotEmpty(cell7)){ |
| | | six = String.valueOf(cell7.getStringCellValue()).trim(); |
| | | } |
| | | |
| | | Cell cell8 = row.getCell(7); //工号[选填] |
| | | Cell cell8 = row.getCell(8); //工号[选填] |
| | | String seven = null; |
| | | if (SinataUtil.isNotEmpty(cell8)){ |
| | | seven = String.valueOf(cell8.getStringCellValue()).trim(); |
| | | } |
| | | |
| | | Cell cell9 = row.getCell(8); //经营业务:专车[是/否] |
| | | Cell cell9 = row.getCell(9); //经营业务:专车[是/否] |
| | | String eight = null; |
| | | if (SinataUtil.isNotEmpty(cell9)){ |
| | | eight = String.valueOf(cell9.getStringCellValue()).trim(); |
| | | } |
| | | |
| | | Cell cell10 = row.getCell(9); //经营业务:出租车[是/否] |
| | | Cell cell10 = row.getCell(10); //经营业务:出租车[是/否] |
| | | String nine = null; |
| | | if (SinataUtil.isNotEmpty(cell10)){ |
| | | nine = String.valueOf(cell10.getStringCellValue()).trim(); |
| | | } |
| | | |
| | | Cell cell11 = row.getCell(10); //经营业务:跨城出行[是/否] |
| | | Cell cell11 = row.getCell(11); //经营业务:跨城出行[是/否] |
| | | String ten = null; |
| | | if (SinataUtil.isNotEmpty(cell11)){ |
| | | ten = String.valueOf(cell11.getStringCellValue()).trim(); |
| | | } |
| | | |
| | | Cell cell12 = row.getCell(11); //经营业务:小件同城物流[是/否] |
| | | Cell cell12 = row.getCell(12); //经营业务:小件同城物流[是/否] |
| | | String eleven = null; |
| | | if (SinataUtil.isNotEmpty(cell12)){ |
| | | eleven = String.valueOf(cell12.getStringCellValue()).trim(); |
| | | } |
| | | |
| | | Cell cell13 = row.getCell(12); //经营业务:小件跨城物流[是/否] |
| | | Cell cell13 = row.getCell(13); //经营业务:小件跨城物流[是/否] |
| | | String twelve = null; |
| | | if (SinataUtil.isNotEmpty(cell13)){ |
| | | twelve = String.valueOf(cell13.getStringCellValue()).trim(); |
| | | } |
| | | |
| | | Cell cell14 = row.getCell(13); //经营业务:包车[是/否] |
| | | Cell cell14 = row.getCell(14); //经营业务:包车[是/否] |
| | | String thirteen = null; |
| | | if (SinataUtil.isNotEmpty(cell14)){ |
| | | thirteen = String.valueOf(cell14.getStringCellValue()).trim(); |
| | | } |
| | | |
| | | Cell cell15 = row.getCell(14); //登录账号[手机号] |
| | | Cell cell15 = row.getCell(15); //登录账号[手机号] |
| | | String fourteen = null; |
| | | if (SinataUtil.isNotEmpty(cell15)){ |
| | | fourteen = String.valueOf(cell15.getStringCellValue()).trim(); |
| | | String substring = fourteen.substring(0, 1); |
| | | if("0".equals(substring)){ |
| | | fourteen = "233" + fourteen.substring(1); |
| | | } |
| | | if(fourteen.indexOf("233") < 0){ |
| | | fourteen = "233" + fourteen; |
| | | } |
| | | } |
| | | |
| | | Cell cell16 = row.getCell(15); //登录密码[密码长度为6-18] |
| | | Cell cell16 = row.getCell(16); //登录密码[密码长度为6-18] |
| | | String fifteen = null; |
| | | if (SinataUtil.isNotEmpty(cell16)){ |
| | | fifteen = String.valueOf(cell16.getStringCellValue()).trim(); |
| | | } |
| | | if (SinataUtil.isEmpty(zero) || SinataUtil.isEmpty(one) || SinataUtil.isEmpty(two) || SinataUtil.isEmpty(three) || SinataUtil.isEmpty(four) |
| | | if (SinataUtil.isEmpty(zero) || SinataUtil.isEmpty(zero1) || SinataUtil.isEmpty(one) || SinataUtil.isEmpty(two) || SinataUtil.isEmpty(three) || SinataUtil.isEmpty(four) |
| | | || SinataUtil.isEmpty(six) || SinataUtil.isEmpty(eight) |
| | | || SinataUtil.isEmpty(nine) || SinataUtil.isEmpty(ten) |
| | | || SinataUtil.isEmpty(eleven) || SinataUtil.isEmpty(twelve) || SinataUtil.isEmpty(thirteen) |
| | |
| | | driver.setJobNumber(seven); |
| | | driver.setPhone(fourteen); |
| | | driver.setPassword(ShiroKit.md5(fifteen, "SA;d5#")); |
| | | driver.setName(zero); |
| | | driver.setLastName(zero); |
| | | driver.setFirstName(zero1); |
| | | if ("男".equals(one)){ |
| | | driver.setSex(1); |
| | | }else if ("女".equals(one)){ |
| | |
| | | } |
| | | return SUCCESS_TIP; |
| | | } |
| | | |
| | | |
| | | |
| | | |
| | | @Autowired |
| | | private ITCompanyService itCompanyService; |
| | | |
| | | @Autowired |
| | | private ITDriverServiceService itDriverServiceService; |
| | | |
| | | /** |
| | | * 验证是否可以字符转为整数 |
| | |
| | | }else{ |
| | | shellList.add("-"); |
| | | } |
| | | if(SinataUtil.isNotEmpty(object.get("name"))){ |
| | | shellList.add(object.get("name").toString()); |
| | | if(SinataUtil.isNotEmpty(object.get("firstName"))){ |
| | | shellList.add(object.get("firstName").toString() + " " + object.get("lastName").toString()); |
| | | }else{ |
| | | shellList.add("-"); |
| | | } |
| | |
| | | shellList.add("-"); |
| | | } |
| | | if(SinataUtil.isNotEmpty(object.get("sex"))){ |
| | | shellList.add(object.get("sex").toString() == "1"?"男":"女"); |
| | | shellList.add(object.get("sex").toString().equals("1")?"男":"女"); |
| | | }else{ |
| | | shellList.add("-"); |
| | | } |
| | |
| | | } |
| | | if(SinataUtil.isNotEmpty(object.get("authState"))){ |
| | | shellList.add(object.get("authState").toString().equals("1")?"待审核":(object.get("authState").toString().equals("2")?"正常":(object.get("authState").toString().equals("3")?"冻结":(object.get("authState").toString().equals("4")?"已拒绝":"")))); |
| | | |
| | | shellList.add(object.get("authState").toString()); |
| | | }else{ |
| | | shellList.add("-"); |
| | | } |