| | |
| | | package com.stylefeng.guns.modular.system.controller.general; |
| | | |
| | | import cn.hutool.crypto.SecureUtil; |
| | | import com.baomidou.mybatisplus.mapper.EntityWrapper; |
| | | import com.stylefeng.guns.core.base.controller.BaseController; |
| | | import com.stylefeng.guns.core.base.tips.SuccessTip; |
| | | import com.stylefeng.guns.core.common.constant.state.ManagerStatus; |
| | | import com.stylefeng.guns.core.exception.GunsException; |
| | | import com.stylefeng.guns.core.exception.ServiceExceptionEnum; |
| | | import com.stylefeng.guns.core.shiro.ShiroKit; |
| | |
| | | import org.apache.poi.hssf.usermodel.HSSFWorkbook; |
| | | import org.springframework.beans.BeanUtils; |
| | | import org.springframework.stereotype.Controller; |
| | | import org.springframework.transaction.annotation.Propagation; |
| | | import org.springframework.transaction.annotation.Transactional; |
| | | import org.springframework.util.CollectionUtils; |
| | | import org.springframework.util.StringUtils; |
| | | import org.springframework.web.bind.annotation.RequestMapping; |
| | |
| | | private ITDriverService tDriverService; |
| | | @Autowired |
| | | private ITDriverWorkService tDriverWorkService; |
| | | @Autowired |
| | | private IUserService userService; |
| | | @Autowired |
| | | private RedisUtil redisUtil; |
| | | |
| | |
| | | */ |
| | | @RequestMapping(value = "/add") |
| | | @ResponseBody |
| | | @Transactional(rollbackFor = Exception.class,propagation = Propagation.REQUIRES_NEW) |
| | | public Object add(TAgent tAgent) { |
| | | |
| | | String[] split1 = tAgent.getArea().split("/"); |
| | |
| | | int count = tAgentService.selectCount(new EntityWrapper<TAgent>().eq("provinceName", split1[0]).eq("cityName",split1[1])); |
| | | if(count>0){ |
| | | return new SuccessTip(500,"该代理商已存在!"); |
| | | } |
| | | |
| | | int count1 = userService.selectCount(new EntityWrapper<User>().eq("account", tAgent.getAccount())); |
| | | if (count1 > 0){ |
| | | return new SuccessTip(500,"该账号已存在!"); |
| | | } |
| | | |
| | | tAgent.setPrincipal(tAgent.getPrincipal().replace(" ","")); |
| | |
| | | tAgent.setCityName(city.getName()); |
| | | tAgent.setCityCode(city.getCode()); |
| | | tAgentService.insert(tAgent); |
| | | |
| | | //添加User对象 |
| | | User user = new User(); |
| | | user.setAccount(tAgent.getAccount()); |
| | | user.setSalt(ShiroKit.getRandomSalt(5)); |
| | | user.setPassword(ShiroKit.md5(tAgent.getPassword(), user.getSalt())); |
| | | user.setStatus(ManagerStatus.OK.getCode()); |
| | | user.setRoleid("2"); |
| | | user.setDeptid(25); |
| | | user.setCreatetime(new Date()); |
| | | user.setRoleType(3); |
| | | user.setObjectId(tAgent.getId()); |
| | | user.setName(tAgent.getPrincipal()); |
| | | user.setSex(1); |
| | | userService.insert(user); |
| | | |
| | | return SUCCESS_TIP; |
| | | } |
| | | |
| | |
| | | package com.stylefeng.guns.modular.system.controller.general; |
| | | |
| | | import cn.hutool.crypto.SecureUtil; |
| | | import com.alibaba.fastjson.JSONObject; |
| | | import com.baomidou.mybatisplus.mapper.EntityWrapper; |
| | | import com.stylefeng.guns.core.base.controller.BaseController; |
| | | import com.stylefeng.guns.core.base.tips.SuccessTip; |
| | | import com.stylefeng.guns.core.common.constant.state.ManagerStatus; |
| | | import com.stylefeng.guns.core.shiro.ShiroKit; |
| | | import com.stylefeng.guns.core.util.SinataUtil; |
| | | import com.stylefeng.guns.modular.system.controller.resp.TBranchOfficeResp; |
| | | import com.stylefeng.guns.modular.system.controller.resp.TDriverResp; |
| | | import com.stylefeng.guns.modular.system.enums.StatusEnum; |
| | |
| | | import io.swagger.annotations.ApiOperation; |
| | | import org.springframework.beans.BeanUtils; |
| | | import org.springframework.stereotype.Controller; |
| | | import org.springframework.transaction.annotation.Propagation; |
| | | import org.springframework.transaction.annotation.Transactional; |
| | | import org.springframework.util.CollectionUtils; |
| | | import org.springframework.util.StringUtils; |
| | | import org.springframework.web.bind.annotation.RequestMapping; |
| | |
| | | private ITDriverService tDriverService; |
| | | @Autowired |
| | | private ITDriverWorkService tDriverWorkService; |
| | | @Autowired |
| | | private IUserService userService; |
| | | @Autowired |
| | | private RedisUtil redisUtil; |
| | | |
| | |
| | | */ |
| | | @RequestMapping(value = "/add") |
| | | @ResponseBody |
| | | @Transactional(rollbackFor = Exception.class,propagation = Propagation.REQUIRES_NEW) |
| | | public Object add(TBranchOffice tBranchOffice) { |
| | | int count = tBranchOfficeService.selectCount(new EntityWrapper<TBranchOffice>().eq("branchOfficeName", tBranchOffice.getBranchOfficeName())); |
| | | if(count>0){ |
| | | return new SuccessTip(500,"该分公司名称已存在!"); |
| | | } |
| | | int count1 = userService.selectCount(new EntityWrapper<User>().eq("account", tBranchOffice.getAccount())); |
| | | if (count1 > 0){ |
| | | return new SuccessTip(500,"该账号已存在!"); |
| | | } |
| | | |
| | | Object o = tBranchOfficeService.addOrUpdate(tBranchOffice); |
| | |
| | | tBranchOffice.setStatus(StatusEnum.NORMAL.getCode()); |
| | | |
| | | tBranchOfficeService.insert(tBranchOffice); |
| | | |
| | | //添加User对象 |
| | | User user = new User(); |
| | | user.setAccount(tBranchOffice.getAccount()); |
| | | user.setSalt(ShiroKit.getRandomSalt(5)); |
| | | user.setPassword(ShiroKit.md5(tBranchOffice.getPassword(), user.getSalt())); |
| | | user.setStatus(ManagerStatus.OK.getCode()); |
| | | user.setRoleid("3"); |
| | | user.setDeptid(25); |
| | | user.setCreatetime(new Date()); |
| | | user.setRoleType(2); |
| | | user.setObjectId(tBranchOffice.getId()); |
| | | user.setName(tBranchOffice.getPrincipal()); |
| | | user.setSex(1); |
| | | userService.insert(user); |
| | | |
| | | return SUCCESS_TIP; |
| | | } |
| | | |
| | |
| | | */ |
| | | @RequestMapping(value = "/update") |
| | | @ResponseBody |
| | | @Transactional(rollbackFor = Exception.class,propagation = Propagation.REQUIRES_NEW) |
| | | public Object update(TBranchOffice tBranchOffice) { |
| | | TBranchOffice branchOffice = tBranchOfficeService.selectById(tBranchOffice.getId()); |
| | | User user = userService.selectOne(new EntityWrapper<User>() |
| | | .eq("role_type", 2) |
| | | .eq("object_id", branchOffice.getId()) |
| | | .last("LIMIT 1")); |
| | | //判断账号是否已存在 |
| | | if (SinataUtil.isNotEmpty(tBranchOffice.getAccount()) && SinataUtil.isNotEmpty(tBranchOffice.getPassword())){ |
| | | if(Objects.isNull(user)){ |
| | | //添加User对象 |
| | | user.setAccount(tBranchOffice.getAccount()); |
| | | user.setSalt(ShiroKit.getRandomSalt(5)); |
| | | user.setPassword(ShiroKit.md5(tBranchOffice.getPassword(), user.getSalt())); |
| | | user.setStatus(ManagerStatus.OK.getCode()); |
| | | user.setRoleid("3"); |
| | | user.setDeptid(25); |
| | | user.setCreatetime(new Date()); |
| | | user.setRoleType(2); |
| | | user.setObjectId(tBranchOffice.getId()); |
| | | user.setName(tBranchOffice.getPrincipal()); |
| | | user.setSex(1); |
| | | userService.insert(user); |
| | | }else { |
| | | if (!tBranchOffice.getAccount().equals(user.getAccount())){ |
| | | //判断账号是否已存在 |
| | | int count = userService.selectCount(new EntityWrapper<User>().eq("account", tBranchOffice.getAccount())); |
| | | if (count > 0){ |
| | | return new SuccessTip(500,"该账号已存在!"); |
| | | } |
| | | } |
| | | user.setAccount(tBranchOffice.getAccount()); |
| | | user.setPassword(ShiroKit.md5(user.getPassword(), user.getSalt())); |
| | | userService.updateById(user); |
| | | } |
| | | } |
| | | |
| | | TBranchOffice office = tBranchOfficeService.selectOne(new EntityWrapper<TBranchOffice>().eq("branchOfficeName", tBranchOffice.getBranchOfficeName()) |
| | | .last("LIMIT 1")); |
| | | if(Objects.nonNull(office) && !tBranchOffice.getId().equals(office.getId())){ |
| | |
| | | import java.time.LocalDate; |
| | | import java.time.Period; |
| | | import java.util.*; |
| | | import java.util.concurrent.atomic.AtomicInteger; |
| | | import java.util.stream.Collectors; |
| | | |
| | | /** |
| | |
| | | } |
| | | model.addAttribute("allList",list); |
| | | List<List<String>> list1 = new ArrayList<>(); |
| | | AtomicInteger count = new AtomicInteger(0); |
| | | for (TDriver tDriver : onLineDriver) { |
| | | |
| | | String value1 = redisUtil.getValue("DRIVER_" + tDriver.getPhone()); |
| | | String value2 = redisUtil.getValue(value1); |
| | | if(ToolUtil.isNotEmpty(value2)){ |
| | | count.addAndGet(1); |
| | | } |
| | | |
| | | List<String> obj = new ArrayList<>(3); |
| | | String value = redisUtil.getValue("DRIVER" + tDriver.getId()); |
| | | if(ToolUtil.isEmpty(value)){ |
| | |
| | | obj.add(String.valueOf(tDriver.getServerStatus()));// 服务状态 |
| | | list1.add(obj); |
| | | } |
| | | model.addAttribute("onLineDriverCount",list1.size()); |
| | | model.addAttribute("onLineDriverCount",count.get()); |
| | | // 拿到所有在线司机地址 |
| | | model.addAttribute("onLineDriver",list1); |
| | | return PREFIX + "tHomePageMap.html"; |
| | |
| | | @RequestMapping("/getMap") |
| | | @ResponseBody |
| | | public Object getMap(Integer agentId,Integer type,Model model) { |
| | | Integer objectId = ShiroKit.getUser().getObjectId(); |
| | | Integer objectId = Objects.requireNonNull(ShiroKit.getUser()).getObjectId(); |
| | | Integer roleType = ShiroKit.getUser().getRoleType(); |
| | | if(roleType == 3 && Objects.nonNull(objectId)){ |
| | | agentId = objectId; |
| | |
| | | */ |
| | | @RequestMapping("/serviceMgmt") |
| | | public String serviceMgmt(Model model) { |
| | | TSystemConfig tSystemConfig = tSystemConfigService.selectOne(new EntityWrapper<TSystemConfig>().eq("type", 7) |
| | | .last("LIMIT 1")); |
| | | JSONObject jsonObject = JSONObject.parseObject(tSystemConfig.getContent()); |
| | | model.addAttribute("num1",jsonObject.getString("num1")); |
| | | Integer roleType = Objects.requireNonNull(ShiroKit.getUser()).getRoleType(); |
| | | Integer objectId = Objects.requireNonNull(ShiroKit.getUser()).getObjectId(); |
| | | if(roleType == 1){ |
| | | TSystemConfig tSystemConfig = tSystemConfigService.selectOne(new EntityWrapper<TSystemConfig>().eq("type", 7) |
| | | .last("LIMIT 1")); |
| | | JSONObject jsonObject = JSONObject.parseObject(tSystemConfig.getContent()); |
| | | model.addAttribute("num1",jsonObject.getString("num1")); |
| | | } |
| | | if(roleType == 3){ |
| | | TAgent tAgent = agentService.selectById(objectId); |
| | | if (Objects.nonNull(tAgent)){ |
| | | model.addAttribute("num1",tAgent.getServiceCalls()); |
| | | } |
| | | } |
| | | return PREFIX + "tSystemConfigServiceMgmt.html"; |
| | | } |
| | | |
| | |
| | | public class TBranchOfficeResp extends TBranchOffice { |
| | | |
| | | @ApiModelProperty(value = "订单数量") |
| | | private Integer orderCount; |
| | | private Integer orderCount=0; |
| | | |
| | | @ApiModelProperty(value = "有效订单") |
| | | private Integer effectiveOrderCount; |
| | | private Integer effectiveOrderCount=0; |
| | | |
| | | @ApiModelProperty(value = "已发放优惠券") |
| | | private Integer totalCount; |
| | | private Integer totalCount=0; |
| | | |
| | | @ApiModelProperty(value = "已使用优惠券") |
| | | private Integer usedCount; |
| | | private Integer usedCount=0; |
| | | |
| | | @ApiModelProperty(value = "累计优惠券金额") |
| | | private BigDecimal orderPriceCount; |
| | | private BigDecimal orderPriceCount=BigDecimal.ZERO; |
| | | |
| | | @ApiModelProperty(value = "司机数量") |
| | | private Integer driverCount; |
| | |
| | | @ApiModelProperty(value = "区域id") |
| | | private String areaId; |
| | | |
| | | @TableField(exist = false) |
| | | @ApiModelProperty(value = "账号") |
| | | private String account; |
| | | |
| | | @TableField(exist = false) |
| | | @ApiModelProperty(value = "密码") |
| | | private String password; |
| | | |
| | | public String getAccount() { |
| | | return account; |
| | | } |
| | | |
| | | public void setAccount(String account) { |
| | | this.account = account; |
| | | } |
| | | |
| | | public String getPassword() { |
| | | return password; |
| | | } |
| | | |
| | | public void setPassword(String password) { |
| | | this.password = password; |
| | | } |
| | | |
| | | public String getServiceCalls() { |
| | | return serviceCalls; |
| | | } |
| | |
| | | @ApiModelProperty(value = "区域id") |
| | | private String areaId; |
| | | |
| | | @TableField(exist = false) |
| | | @ApiModelProperty(value = "账号") |
| | | private String account; |
| | | |
| | | @TableField(exist = false) |
| | | @ApiModelProperty(value = "密码") |
| | | private String password; |
| | | |
| | | public String getAccount() { |
| | | return account; |
| | | } |
| | | |
| | | public void setAccount(String account) { |
| | | this.account = account; |
| | | } |
| | | |
| | | public String getPassword() { |
| | | return password; |
| | | } |
| | | |
| | | public void setPassword(String password) { |
| | | this.password = password; |
| | | } |
| | | |
| | | public String getBankDeposit() { |
| | | return bankDeposit; |
| | | } |
| | |
| | | model.addAttribute("orderSum",orderList.size()); |
| | | // 过滤已完成和待评价订单,且支付金额在14元以上 |
| | | List<TOrder> orders = orderList.stream().filter(order -> (order.getState().equals(OrderStateEnum.FINISH.getCode()) || order.getState().equals(OrderStateEnum.WAIT_EVALUATED.getCode())) |
| | | && 0 < order.getPayMoney().compareTo(new BigDecimal("14")) && order.getAgentId().equals(tAgent.getId())).collect(Collectors.toList()); |
| | | && 0 < order.getOrderMoney().compareTo(new BigDecimal("14")) && order.getAgentId().equals(tAgent.getId())).collect(Collectors.toList()); |
| | | model.addAttribute("validOrder",orders.size()); |
| | | // 过滤已使用优惠券 |
| | | List<TOrder> usedCoupon = orderList.stream().filter(order -> (order.getState().equals(OrderStateEnum.FINISH.getCode()) || order.getState().equals(OrderStateEnum.WAIT_EVALUATED.getCode())) |
| | |
| | | tAgentResp.setOrderSum(orderList.size()); |
| | | // 过滤已完成和待评价订单,且支付金额在14元以上 |
| | | List<TOrder> orders = tOrders.stream().filter(order -> (order.getState().equals(OrderStateEnum.FINISH.getCode()) || order.getState().equals(OrderStateEnum.WAIT_EVALUATED.getCode())) |
| | | && 0 < order.getPayMoney().compareTo(new BigDecimal("14")) && tAgent.getId().equals(order.getAgentId())).collect(Collectors.toList()); |
| | | && 0 < order.getOrderMoney().compareTo(new BigDecimal("14")) && tAgent.getId().equals(order.getAgentId())).collect(Collectors.toList()); |
| | | tAgentResp.setValidOrder(orders.size()); |
| | | // 过滤已使用优惠券 |
| | | List<TOrder> usedCoupon = tOrders.stream().filter(order -> (order.getState().equals(OrderStateEnum.FINISH.getCode()) || order.getState().equals(OrderStateEnum.WAIT_EVALUATED.getCode())) |
| | |
| | | import com.stylefeng.guns.modular.system.model.TUserToCoupon; |
| | | import com.stylefeng.guns.modular.system.service.ITAppUserService; |
| | | import com.baomidou.mybatisplus.service.impl.ServiceImpl; |
| | | import org.apache.poi.hdf.extractor.TC; |
| | | import org.springframework.beans.BeanUtils; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.stereotype.Service; |
| | |
| | | // List<TCoupon> notUsedList = tCoupons.stream().filter(coupon -> coupon.getCouponStatus().equals(CouponStatusEnum.NOT_USED.getCode())).collect(Collectors.toList()); |
| | | // List<TCoupon> usedList = tCoupons.stream().filter(coupon -> coupon.getCouponStatus().equals(CouponStatusEnum.USED.getCode())).collect(Collectors.toList()); |
| | | // List<TCoupon> expiredList = tCoupons.stream().filter(coupon -> coupon.getCouponStatus().equals(CouponStatusEnum.EXPIRED.getCode())).collect(Collectors.toList()); |
| | | // 查询当前用户优惠券数量 |
| | | List<TUserToCoupon> tUserToCoupons = tUserToCouponMapper.selectList(new EntityWrapper<TUserToCoupon>().eq("userId", tAppUser.getId())); |
| | | |
| | | // 查询全部未删除优惠券 |
| | | List<TCoupon> tCoupons = tCouponMapper.selectList(new EntityWrapper<TCoupon>() |
| | | .eq("status", true)); |
| | | List<Integer> couponIds = tCoupons.stream().map(TCoupon::getId).collect(Collectors.toList()); |
| | | List<TUserToCoupon> tUserToCoupons; |
| | | if(CollectionUtils.isEmpty(couponIds)){ |
| | | tUserToCoupons = new ArrayList<>(); |
| | | }else { |
| | | // 查询当前用户优惠券数量 |
| | | tUserToCoupons = tUserToCouponMapper.selectList(new EntityWrapper<TUserToCoupon>().eq("userId", tAppUser.getId()) |
| | | .in("couponId",couponIds)); |
| | | } |
| | | int couponTotal = tUserToCoupons.stream().mapToInt(TUserToCoupon::getCouponTotal).sum(); |
| | | int validCount = tUserToCoupons.stream().mapToInt(TUserToCoupon::getValidCount).sum(); |
| | | int expireCount = tUserToCoupons.stream().mapToInt(TUserToCoupon::getExpireCount).sum(); |
| | |
| | | .filter(order -> OrderStateEnum.CANCELED.getCode() == order.getState()).collect(Collectors.toList()); |
| | | model.addAttribute("canceledNumber",collect.size()); |
| | | |
| | | TOrder tOrder = orders.get(0); |
| | | // 最近消费时间 |
| | | model.addAttribute("latelyTime",DateUtil.formatDate(tOrder.getCreateTime())); |
| | | // 最近消费金额 |
| | | model.addAttribute("latelyPrice",tOrder.getPayMoney()); |
| | | // 获取已支付订单 |
| | | List<TOrder> payOrder = orders.stream().filter(order -> order.getState().equals(OrderStateEnum.WAIT_EVALUATED.getCode()) |
| | | || order.getState().equals(OrderStateEnum.FINISH.getCode())).collect(Collectors.toList()); |
| | | if(CollectionUtils.isEmpty(payOrder)){ |
| | | // 最近消费时间 |
| | | model.addAttribute("latelyTime",""); |
| | | // 最近消费金额 |
| | | model.addAttribute("latelyPrice",""); |
| | | }else { |
| | | TOrder tOrder = payOrder.get(0); |
| | | // 最近消费时间 |
| | | model.addAttribute("latelyTime",DateUtil.formatDate(tOrder.getCreateTime())); |
| | | // 最近消费金额 |
| | | model.addAttribute("latelyPrice",tOrder.getPayMoney()); |
| | | } |
| | | |
| | | // 总消费次数 |
| | | List<TOrder> collect1 = orders.stream().filter(order->Objects.nonNull(order.getState())) |
| | |
| | | public void queryOtherInfo(List<TBranchOfficeResp> tBranchOfficeRespList) { |
| | | List<TOrder> orders = tOrderMapper.selectList(new EntityWrapper<TOrder>()); |
| | | |
| | | |
| | | for (TBranchOfficeResp tBranchOfficeResp : tBranchOfficeRespList) { |
| | | |
| | | List<TOrder> orderList = orders.stream().filter(t -> tBranchOfficeResp.getId().equals(t.getBranchOfficeId())).collect(Collectors.toList()); |
| | | |
| | | List<TUserToCoupon> tUserToCoupons = tUserToCouponMapper.selectList(new EntityWrapper<TUserToCoupon>().eq("objectId", tBranchOfficeResp.getId()) |
| | | .eq("roleType",2)); |
| | | |
| | | if(!CollectionUtils.isEmpty(orderList)){ |
| | | |
| | |
| | | |
| | | // 优惠券数据,,,通过订单找到该区域的下单人,找出优惠券信息 |
| | | List<Integer> userIds = orderList.stream().map(TOrder::getUserId).collect(Collectors.toList()); |
| | | List<TUserToCoupon> tUserToCoupons = tUserToCouponMapper.selectList(new EntityWrapper<TUserToCoupon>().eq("objectId", tBranchOfficeResp.getId()) |
| | | .eq("roleType",2)); |
| | | // 优惠券有效数量 |
| | | int validCount = tUserToCoupons.stream().mapToInt(TUserToCoupon::getValidCount).sum(); |
| | | // 过期数量 |
| | | int expireCount = tUserToCoupons.stream().mapToInt(TUserToCoupon::getExpireCount).sum(); |
| | | // 总数量 |
| | | int totalCount = tUserToCoupons.stream().mapToInt(TUserToCoupon::getCouponTotal).sum(); |
| | | // 已使用优惠券;总数量减去有效数量 |
| | | tBranchOfficeResp.setUsedCount(totalCount-validCount-expireCount); |
| | | |
| | | // 已发放优惠券 |
| | | tBranchOfficeResp.setTotalCount(totalCount); |
| | | |
| | | BigDecimal orderPriceCount = new BigDecimal("0"); |
| | | |
| | | // 累计优惠券金额 |
| | | for (TUserToCoupon tUserToCoupon : tUserToCoupons) { |
| | | TCoupon tCoupon = tCouponMapper.selectById(tUserToCoupon.getCouponId()); |
| | | BigDecimal price = tCoupon.getCouponPreferentialAmount().multiply(new BigDecimal(tUserToCoupon.getCouponTotal())); |
| | | orderPriceCount = orderPriceCount.add(price); |
| | | } |
| | | tBranchOfficeResp.setOrderPriceCount(orderPriceCount); |
| | | } |
| | | |
| | | // 优惠券有效数量 |
| | | int validCount = tUserToCoupons.stream().mapToInt(TUserToCoupon::getValidCount).sum(); |
| | | // 过期数量 |
| | | int expireCount = tUserToCoupons.stream().mapToInt(TUserToCoupon::getExpireCount).sum(); |
| | | // 总数量 |
| | | int totalCount = tUserToCoupons.stream().mapToInt(TUserToCoupon::getCouponTotal).sum(); |
| | | // 已使用优惠券;总数量减去有效数量 |
| | | tBranchOfficeResp.setUsedCount(totalCount-validCount-expireCount); |
| | | |
| | | // 已发放优惠券 |
| | | tBranchOfficeResp.setTotalCount(totalCount); |
| | | |
| | | BigDecimal orderPriceCount = new BigDecimal("0"); |
| | | // 累计优惠券金额 |
| | | for (TUserToCoupon tUserToCoupon : tUserToCoupons) { |
| | | TCoupon tCoupon = tCouponMapper.selectById(tUserToCoupon.getCouponId()); |
| | | BigDecimal price = tCoupon.getCouponPreferentialAmount().multiply(new BigDecimal(tUserToCoupon.getCouponTotal())); |
| | | orderPriceCount = orderPriceCount.add(price); |
| | | } |
| | | tBranchOfficeResp.setOrderPriceCount(orderPriceCount); |
| | | |
| | | // 司机数量 |
| | | Integer driverCount = tDriverMapper.selectCount(new EntityWrapper<TDriver>().eq("branchOfficeId", tBranchOfficeResp.getId())); |
| | | tBranchOfficeResp.setDriverCount(driverCount); |
| | |
| | | Integer count = orderService.getValidOrderCount(driver.getId(),new BigDecimal(14),new SimpleDateFormat("yyyy-MM").format(new Date())); |
| | | if(count < 30){ |
| | | driver.setIsException(2); |
| | | }else { |
| | | driver.setIsException(1); |
| | | } |
| | | TDriverWork tDriverWork = tDriverWorkService.selectOne(new EntityWrapper<TDriverWork>() |
| | | .eq("driverId", driver.getId()) |
| | |
| | | } |
| | | } |
| | | }else { |
| | | // 没有上班记录,计算审核时间 |
| | | Period period = Period.between(DateUtil.dateToLocalDate(driver.getApprovalTime()), LocalDate.now()); |
| | | int day = Math.abs(period.getDays()); |
| | | if(day>14){ |
| | | driver.setIsException(2); |
| | | if(Objects.nonNull(driver.getApprovalTime())){ |
| | | // 没有上班记录,计算审核时间 |
| | | Period period = Period.between(DateUtil.dateToLocalDate(driver.getApprovalTime()), LocalDate.now()); |
| | | int day = Math.abs(period.getDays()); |
| | | if(day>14){ |
| | | driver.setIsException(2); |
| | | } |
| | | } |
| | | } |
| | | } |
| | |
| | | #redisÅäÖÿªÊ¼ |
| | | # RedisÊý¾Ý¿âË÷Òý£¨Ä¬ÈÏΪ0£© |
| | | spring.redis.database=0 |
| | | ## Redis·þÎñÆ÷µØÖ· |
| | | # Redis·þÎñÆ÷µØÖ· |
| | | spring.redis.host=127.0.0.1 |
| | | ## Redis·þÎñÆ÷Á¬½Ó¶Ë¿Ú |
| | | spring.redis.port=16379 |
| | |
| | | </select> |
| | | </div> |
| | | <div class="initialLevel col-sm-2 control-label form-group" > |
| | | <#button name="查询" icon="fa-search" clickFun="getData()"/> |
| | | <#button name="重置" icon="fa-trash" clickFun="reset()" space="true"/> |
| | | <button type="button" class="btn btn-primary" onclick="getData()" style="height: 33px"> |
| | | <i class="fa fa-search"></i> 查询 |
| | | </button> |
| | | <button type="button" class="btn btn-primary button-margin" onclick="reset()" style="height: 33px"> |
| | | <i class="fa fa-trash"></i> 重置 |
| | | </button> |
| | | </div> |
| | | </div> |
| | | <div class="col-sm-12" > |
| | |
| | | </select> |
| | | </div> |
| | | <div class="initialLevel col-sm-2 control-label form-group" > |
| | | <#button name="查询" icon="fa-search" clickFun="getDataOrder()"/> |
| | | <#button name="重置" icon="fa-trash" clickFun="resetOrder()" space="true"/> |
| | | <button type="button" class="btn btn-primary " onclick="getDataOrder()" style="height: 33px"> |
| | | <i class="fa fa-search"></i> 查询 |
| | | </button> |
| | | <button type="button" class="btn btn-primary button-margin" onclick="resetOrder()" style="height: 33px"> |
| | | <i class="fa fa-trash"></i> 重置 |
| | | </button> |
| | | </div> |
| | | </div> |
| | | <div class="col-sm-10" > |
| | |
| | | <input id="bankAccount" name="bankAccount" type="number" maxlength="20" placeholder="请输入" style="height: 30px"> |
| | | </div> |
| | | </div> |
| | | <!-- <div class="initialLevel col-sm-12 control-label form-group">--> |
| | | <!-- <div class="initialLevel col-sm-6 control-label form-group" >--> |
| | | <!-- <label class="control-label" >客服电话:</label>--> |
| | | <!-- <input id="serviceCalls" name="serviceCalls" type="number" maxlength="20" placeholder="请输入" style="height: 30px">--> |
| | | <!-- </div>--> |
| | | <!-- </div>--> |
| | | <div class="initialLevel col-sm-12 control-label form-group"> |
| | | <div class="initialLevel col-sm-6 control-label form-group" > |
| | | <label class="control-label" >客服电话:</label> |
| | | <input id="serviceCalls" name="serviceCalls" type="number" maxlength="20" placeholder="请输入" style="height: 30px"> |
| | | <span style="color:red">*</span> |
| | | <label class="control-label" >登录账号:</label> |
| | | <input id="account" name="account" type="text" maxlength="20" placeholder="请输入" style="height: 30px"> |
| | | </div> |
| | | </div> |
| | | <div class="initialLevel col-sm-12 control-label form-group"> |
| | | <div class="initialLevel col-sm-6 control-label form-group" > |
| | | <span style="color:red">*</span> |
| | | <label class="control-label" >登录密码:</label> |
| | | <input id="password" name="password" type="password" maxlength="20" placeholder="请输入密码" style="height: 30px"> |
| | | </div> |
| | | </div> |
| | | <div class="initialLevel col-sm-12 control-label form-group"> |
| | | <div class="initialLevel col-sm-6 control-label form-group" > |
| | | <span style="color:red">*</span> |
| | | <label class="control-label" >确认密码:</label> |
| | | <input id="rePassword" name="rePassword" type="password" maxlength="20" placeholder="请输入确认密码" style="height: 30px"> |
| | | </div> |
| | | </div> |
| | | |
| | |
| | | </div> |
| | | <hr/> |
| | | |
| | | <div class="initialLevel col-sm-12 control-label form-group" > |
| | | <div class="initialLevel col-sm-1 control-label form-group" style="margin-left: 10px" > |
| | | <img src="${avatar}" style="height: 100px;width: 100px"/> |
| | | </div> |
| | | <div class="initialLevel col-sm-3 control-label form-group" > |
| | | <label class="control-label" >昵称:</label> |
| | | <label>${nickname}</label> |
| | | </div> |
| | | <div class="initialLevel col-sm-2 control-label form-group" > |
| | | <label class="control-label">ID:</label> |
| | | <label>${id}</label> |
| | | </div> |
| | | <div class="initialLevel col-sm-3 control-label form-group" > |
| | | <label class="control-label">注册时间:</label> |
| | | <label>${createTime}</label> |
| | | <div class="col-lg-2"> |
| | | <div class="initialLevel col-sm-12 control-label form-group" > |
| | | <div class="initialLevel col-sm-1 control-label form-group" style="margin-left: 10px" > |
| | | <img src="${avatar}" style="height: 100px;width: 100px"/> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | <div class="col-lg-10"> |
| | | <div class="initialLevel col-sm-12 control-label form-group" > |
| | | <div class="initialLevel col-sm-3 control-label form-group" > |
| | | <label class="control-label" >昵称:</label> |
| | | <label>${nickname}</label> |
| | | </div> |
| | | <div class="initialLevel col-sm-2 control-label form-group" > |
| | | <label class="control-label">ID:</label> |
| | | <label>${id}</label> |
| | | </div> |
| | | <div class="initialLevel col-sm-3 control-label form-group" > |
| | | <label class="control-label">注册时间:</label> |
| | | <label>${createTime}</label> |
| | | </div> |
| | | </div> |
| | | |
| | | <div class="initialLevel col-sm-12 control-label form-group" > |
| | | <div class="initialLevel col-sm-3 control-label form-group" style="margin-left: 150px"> |
| | | <label class="control-label">客户渠道:</label> |
| | | <label>${customerChannel}</label> |
| | | </div> |
| | | <div class="initialLevel col-sm-2 control-label form-group" style="margin-left: 150px"> |
| | | <label class="control-label" >下单次数:</label> |
| | | <label>${numberOfOrder}</label> |
| | | </div> |
| | | <div class="initialLevel col-sm-3 control-label form-group" style="margin-left: 150px" > |
| | | <label class="control-label" >取消次数:</label> |
| | | <label>${canceledNumber}</label> |
| | | <div class="initialLevel col-sm-12 control-label form-group" > |
| | | <div class="initialLevel col-sm-3 control-label form-group"> |
| | | <label class="control-label">客户渠道:</label> |
| | | <!-- <label>${customerChannel}</label>--> |
| | | <label>微信小程序</label> |
| | | </div> |
| | | <div class="initialLevel col-sm-2 control-label form-group" > |
| | | <label class="control-label" >下单次数:</label> |
| | | <label>${numberOfOrder}</label> |
| | | </div> |
| | | <div class="initialLevel col-sm-3 control-label form-group"> |
| | | <label class="control-label" >取消次数:</label> |
| | | <label>${canceledNumber}</label> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | |
| | |
| | | <div class="col-sm-2"> |
| | | <#NameCon id="phone" name="手机号" /> |
| | | </div> |
| | | <div class="col-sm-1"> |
| | | <select class="input-group" id="status" style="width: 80px;height: 33px" name="status"> |
| | | <option value="">状态</option> |
| | | <option value="1">正常</option> |
| | | <option value="2">冻结</option> |
| | | </select> |
| | | <div class="col-sm-2"> |
| | | <#SelectCon id="status" name="状态" > |
| | | <option value="">状态</option> |
| | | <option value="1">正常</option> |
| | | <option value="2">冻结</option> |
| | | </#SelectCon> |
| | | </div> |
| | | <div class="col-sm-2"> |
| | | <#button name="查询" icon="fa-search" clickFun="TAppUserException.search()"/> |
| | |
| | | </div> |
| | | </div> |
| | | |
| | | <div class="initialLevel col-sm-12 control-label form-group"> |
| | | <div class="initialLevel col-sm-3 control-label form-group" > |
| | | <span style="color:red">*</span> |
| | | <label class="control-label" >登录账号:</label> |
| | | <input id="account" name="account" type="text" maxlength="20" placeholder="请输入" style="height: 30px"> |
| | | </div> |
| | | </div> |
| | | <div class="initialLevel col-sm-12 control-label form-group"> |
| | | <div class="initialLevel col-sm-3 control-label form-group" > |
| | | <span style="color:red">*</span> |
| | | <label class="control-label" >登录密码:</label> |
| | | <input id="password" name="password" type="password" maxlength="20" placeholder="请输入密码" style="height: 30px"> |
| | | </div> |
| | | </div> |
| | | <div class="initialLevel col-sm-12 control-label form-group"> |
| | | <div class="initialLevel col-sm-3 control-label form-group" > |
| | | <span style="color:red">*</span> |
| | | <label class="control-label" >确认密码:</label> |
| | | <input id="rePassword" name="rePassword" type="password" maxlength="20" placeholder="请输入确认密码" style="height: 30px"> |
| | | </div> |
| | | </div> |
| | | |
| | | </div> |
| | | |
| | | </div> |
| | |
| | | </div> |
| | | </div> |
| | | |
| | | <div class="initialLevel col-sm-12 control-label form-group"> |
| | | <div class="initialLevel col-sm-3 control-label form-group" > |
| | | <span style="color:red">*</span> |
| | | <label class="control-label" >登录账号:</label> |
| | | <input id="account" name="account" type="text" maxlength="20" placeholder="请输入" style="height: 30px"> |
| | | </div> |
| | | </div> |
| | | <div class="initialLevel col-sm-12 control-label form-group"> |
| | | <div class="initialLevel col-sm-3 control-label form-group" > |
| | | <span style="color:red">*</span> |
| | | <label class="control-label" >登录密码:</label> |
| | | <input id="password" name="password" type="password" maxlength="20" placeholder="请输入密码" style="height: 30px"> |
| | | </div> |
| | | </div> |
| | | <div class="initialLevel col-sm-12 control-label form-group"> |
| | | <div class="initialLevel col-sm-3 control-label form-group" > |
| | | <span style="color:red">*</span> |
| | | <label class="control-label" >确认密码:</label> |
| | | <input id="rePassword" name="rePassword" type="password" maxlength="20" placeholder="请输入确认密码" style="height: 30px"> |
| | | </div> |
| | | </div> |
| | | |
| | | </div> |
| | | |
| | | </div> |
| | |
| | | <input id="sort" name="sort" type="number" style="height: 30px" maxlength="4" placeholder="请输入排序" required="required"> |
| | | </div> |
| | | </div> |
| | | <div class="initialLevel col-sm-12 control-label form-group" > |
| | | <div class="initialLevel col-sm-12 control-label form-group" id="detailContent" > |
| | | <div class="initialLevel col-sm-6 control-label form-group" > |
| | | <span style="color:red">*</span> |
| | | <label class="control-label" >详情内容: </label> |
| | |
| | | if(this.value == 1){ |
| | | $("#jumpTypeIsShow").show() |
| | | $("#jumpUrlIsShow").show() |
| | | $("#detailContent").show() |
| | | } |
| | | if(this.value == 0){ |
| | | $("#jumpTypeIsShow").hide() |
| | | $("#jumpUrlIsShow").hide() |
| | | $("#detailContent").hide() |
| | | } |
| | | }) |
| | | //监听下拉菜单的变动操作 |
| | |
| | | $("#jumpType").change(function(){ |
| | | if(this.value == 1){ |
| | | $("#jumpUrlIsShow").hide() |
| | | $("#detailContent").show() |
| | | } |
| | | if(this.value == 2){ |
| | | $("#jumpUrlIsShow").show() |
| | | $("#detailContent").hide() |
| | | } |
| | | }) |
| | | </script> |
| | |
| | | </div> |
| | | </div> |
| | | |
| | | <div class="initialLevel col-sm-12 control-label form-group" > |
| | | <div class="initialLevel col-sm-12 control-label form-group" id="homePageBannerIsShow"> |
| | | <div class="initialLevel col-sm-3 control-label form-group" > |
| | | <span style="color:red">*</span> |
| | | <label class="control-label" >广告类型: </label> |
| | |
| | | <input id="sort" value="${item.sort}" type="number" style="height: 30px" maxlength="4" placeholder="请输入排序" required="required"> |
| | | </div> |
| | | </div> |
| | | <div class="initialLevel col-sm-12 control-label form-group" > |
| | | <div class="initialLevel col-sm-12 control-label form-group" id="detailContent"> |
| | | <div class="initialLevel col-sm-6 control-label form-group" > |
| | | <span style="color:red">*</span> |
| | | <label class="control-label" >详情内容: </label> |
| | |
| | | if(1 == $("#isJump").val()){ |
| | | $("#jumpTypeIsShow").show() |
| | | $("#jumpUrlIsShow").show() |
| | | }else { |
| | | $("#detailContent").show() |
| | | } |
| | | if(0 == $("#isJump").val()) { |
| | | $("#jumpTypeIsShow").hide() |
| | | $("#jumpUrlIsShow").hide() |
| | | $("#detailContent").hide() |
| | | } |
| | | |
| | | if(1 == $("#device").val()){ |
| | |
| | | if(this.value == 1){ |
| | | $("#jumpTypeIsShow").show() |
| | | $("#jumpUrlIsShow").show() |
| | | $("#detailContent").show() |
| | | if(1 == $("#jumpType").val()){ |
| | | $("#jumpUrlIsShow").hide() |
| | | $("#detailContent").show() |
| | | } |
| | | if(2 == $("#jumpType").val()){ |
| | | $("#jumpUrlIsShow").show() |
| | | $("#detailContent").hide() |
| | | } |
| | | } |
| | | if(this.value == 0){ |
| | | $("#jumpTypeIsShow").hide() |
| | | $("#jumpUrlIsShow").hide() |
| | | $("#detailContent").hide() |
| | | } |
| | | }) |
| | | //监听下拉菜单的变动操作 |
| | |
| | | $("#jumpType").change(function(){ |
| | | if(this.value == 1){ |
| | | $("#jumpUrlIsShow").hide() |
| | | $("#detailContent").show() |
| | | } |
| | | if(this.value == 2){ |
| | | $("#jumpUrlIsShow").show() |
| | | $("#detailContent").hide() |
| | | } |
| | | }) |
| | | </script> |
| | |
| | | </div> |
| | | <hr/> |
| | | |
| | | <div class="initialLevel col-sm-12 control-label form-group" > |
| | | <div class="col-lg-4"> |
| | | <div class="initialLevel col-sm-12 control-label form-group" > |
| | | <label class="control-label" >姓名:</label> |
| | | <label>${name}</label> |
| | | </div> |
| | | <div class="initialLevel col-sm-12 control-label form-group" > |
| | | <label class="control-label" >手机号:</label> |
| | | <label>${phone}</label> |
| | | </div> |
| | | <div class="initialLevel col-sm-12 control-label form-group" > |
| | | <label class="control-label" >性别:</label> |
| | | @if(sex==1){ |
| | | <label>男</label> |
| | | @} |
| | | @if(sex==2){ |
| | | <label>女</label> |
| | | @} |
| | | @if(sex==3){ |
| | | <label>未知</label> |
| | | @} |
| | | </div> |
| | | <div class="initialLevel col-sm-12 control-label form-group" > |
| | | <label class="control-label">司机来源:</label> |
| | | <label></label> |
| | | </div> |
| | | |
| | | <div class="initialLevel col-sm-12 control-label form-group" > |
| | | <label class="control-label" >驾驶证号码:</label> |
| | | <label>${driverLicenseNumber}</label> |
| | | </div> |
| | | <div class="initialLevel col-sm-12 control-label form-group" > |
| | | <label class="control-label">驾龄:</label> |
| | | <label>${drivingExperience}</label> |
| | | </div> |
| | | </div> |
| | | <div class="col-lg-4"> |
| | | <div class="initialLevel col-sm-12 control-label form-group" > |
| | | <label class="control-label">头像:</label> |
| | | <img src="${avatar}" style="height: 100px;width: 100px"/> |
| | | </div> |
| | | <div class="initialLevel col-sm-12 control-label form-group" > |
| | | <label class="control-label">邀请人:</label> |
| | | <label>${inviterName}</label> |
| | | </div> |
| | | </div> |
| | | <div class="col-lg-4"> |
| | | <div class="initialLevel col-sm-12 control-label form-group" > |
| | | <label class="control-label">紧急联系人:</label> |
| | | <label>${emergencyContact}</label> |
| | | </div> |
| | | <div class="initialLevel col-sm-12 control-label form-group" > |
| | | <label class="control-label">紧急联系人电话:</label> |
| | | <label>${emergencyPhone}</label> |
| | | </div> |
| | | <div class="initialLevel col-sm-12 control-label form-group" > |
| | | <label class="control-label">电话:</label> |
| | | <label>${inviterPhone}</label> |
| | | </div> |
| | | </div> |
| | | <!--<div class="initialLevel col-sm-12 control-label form-group" > |
| | | <div class="initialLevel col-sm-3 control-label form-group" > |
| | | <label class="control-label" >姓名:</label> |
| | | <label>${name}</label> |
| | |
| | | <label class="control-label">驾龄:</label> |
| | | <label>${drivingExperience}</label> |
| | | </div> |
| | | </div> |
| | | </div>--> |
| | | |
| | | <hr/> |
| | | <div class="initialLevel col-sm-12 control-label form-group" > |
| | |
| | | |
| | | <div class="initialLevel col-sm-12 control-label form-group" > |
| | | <div class="initialLevel col-sm-3 control-label form-group" > |
| | | <label class="control-label" >驾驶证照片:</label> |
| | | <label class="control-label" >驾驶证照片:</label><br/> |
| | | <img src="${driverLicense}" style="height: 100px;width: 100px"/> |
| | | </div> |
| | | <div class="initialLevel col-sm-2 control-label form-group" > |
| | | <label class="control-label">身份证照片:</label> |
| | | <label class="control-label">身份证照片:</label><br/> |
| | | <img src="${idcardFront}" style="height: 100px;width: 100px"/> |
| | | </div> |
| | | </div> |
| | |
| | | |
| | | <div class="row row-lg"> |
| | | <div class="col-sm-12" > |
| | | <!-- <div class="initialLevel col-sm-12 control-label form-group" style="cursor: pointer;text-align: left;">--> |
| | | <!-- <div class="initialLevel col-sm-3 control-label form-group" >--> |
| | | <!-- <label class="control-label" >运营数据总览/车辆地图总览/</label>--> |
| | | <!-- <label class="control-label" style="color: red">订单热点图</label>--> |
| | | <!-- </div>--> |
| | | <!-- </div>--> |
| | | |
| | | <div class="initialLevel col-sm-12 control-label form-group" style="cursor: pointer;text-align: left;"> |
| | | <div class="initialLevel col-sm-1 control-label form-group" > |
| | |
| | | <option value="4">已取消</option> |
| | | </select> |
| | | </div> |
| | | <div class="initialLevel col-sm-2 control-label form-group" > |
| | | <#button name="查询" icon="fa-search" clickFun="getData()"/> |
| | | <#button name="重置" icon="fa-trash" clickFun="reset()" space="true"/> |
| | | <div class="col-sm-2"> |
| | | <button type="button" class="btn btn-primary " onclick="getData()" style="height: 33px"> |
| | | <i class="fa fa-search"></i> 查询 |
| | | </button> |
| | | <button type="button" class="btn btn-primary button-margin" onclick="reset()" style="height: 33px"> |
| | | <i class="fa fa-trash"></i> 重置 |
| | | </button> |
| | | </div> |
| | | </div> |
| | | <div class="col-sm-10" > |
| | |
| | | border-bottom-left-radius: 4px; |
| | | border-bottom-right-radius: 4px; |
| | | overflow: hidden; |
| | | } |
| | | .btn{ |
| | | height: 33px |
| | | } |
| | | </style> |
| | | <script type="text/javascript"> |
| | |
| | | |
| | | |
| | | $(function(){ |
| | | $('.btn').css('height','33px') |
| | | map(""); |
| | | getOrder(); |
| | | }) |
| | |
| | | <div class="col-sm-2"> |
| | | <#NameCon id="code" name="订单编号" /> |
| | | </div> |
| | | <div class="col-sm-1"> |
| | | <select class="input-group" id="source" style="width: 120px;height: 33px" name="source"> |
| | | <option value="">请选择订单来源</option> |
| | | <option value="1">小程序</option> |
| | | <option value="2">司机创建</option> |
| | | </select> |
| | | <div class="col-sm-2"> |
| | | <#SelectCon id="source" name="订单来源" > |
| | | <option value="">请选择订单来源</option> |
| | | <option value="1">小程序</option> |
| | | <option value="2">司机创建</option> |
| | | </#SelectCon> |
| | | </div> |
| | | <div class="col-sm-2"> |
| | | <#NameCon id="userName" name="下单用户昵称" /> |
| | |
| | | <div class="col-sm-2"> |
| | | <#NameCon id="userPhone" name="下单用户手机" /> |
| | | </div> |
| | | <div class="col-sm-1"> |
| | | <select class="input-group" id="state" style="width: 120px;height: 33px" name="state"> |
| | | <option value="">请选择订单状态</option> |
| | | <option value="101">待接单</option> |
| | | <option value="102">已接单</option> |
| | | <option value="103">前往预约点</option> |
| | | <option value="104">到达预约点</option> |
| | | <option value="105">开始服务</option> |
| | | <option value="106">到达目的地</option> |
| | | <option value="107">待支付</option> |
| | | <option value="108">待评价</option> |
| | | <option value="109">已完成</option> |
| | | <option value="201">转单中</option> |
| | | <option value="301">已取消</option> |
| | | <option value="401">等待中</option> |
| | | </select> |
| | | <div class="col-sm-2"> |
| | | <#SelectCon id="state" name="订单状态" > |
| | | <option value="">请选择订单状态</option> |
| | | <option value="101">待接单</option> |
| | | <option value="102">已接单</option> |
| | | <option value="103">前往预约点</option> |
| | | <option value="104">到达预约点</option> |
| | | <option value="105">开始服务</option> |
| | | <option value="106">到达目的地</option> |
| | | <option value="107">待支付</option> |
| | | <option value="108">待评价</option> |
| | | <option value="109">已完成</option> |
| | | <option value="201">转单中</option> |
| | | <option value="301">已取消</option> |
| | | <option value="401">等待中</option> |
| | | </#SelectCon> |
| | | </div> |
| | | <div class="col-sm-2"> |
| | | <#NameCon id="driverName" name="司机姓名" /> |
| | |
| | | <#NameCon id="userPhone" name="下单用户手机" /> |
| | | </div> |
| | | <div class="col-sm-3"> |
| | | <#SelectCon id="state" name="状态" > |
| | | <#SelectCon id="state" name="订单状态" > |
| | | <option value="">请选择订单状态</option> |
| | | <option value="101">待接单</option> |
| | | <option value="102">已接单</option> |
| | |
| | | <div class="col-sm-2"> |
| | | <#NameCon id="code" name="订单编号" /> |
| | | </div> |
| | | <div class="col-sm-1"> |
| | | <select class="input-group" id="source" style="width: 120px;height: 33px" name="source"> |
| | | <option value="">请选择订单来源</option> |
| | | <option value="1">小程序</option> |
| | | <option value="2">司机创建</option> |
| | | </select> |
| | | <div class="col-sm-2"> |
| | | <#SelectCon id="source" name="订单来源" > |
| | | <option value="">请选择订单来源</option> |
| | | <option value="1">小程序</option> |
| | | <option value="2">司机创建</option> |
| | | </#SelectCon> |
| | | </div> |
| | | <div class="col-sm-2"> |
| | | <#NameCon id="userName" name="下单用户昵称" /> |
| | |
| | | <#NameCon id="userPhone" name="下单用户手机" /> |
| | | </div> |
| | | <div class="col-sm-1"> |
| | | <select class="input-group" id="state" style="width: 120px;height: 33px" name="state"> |
| | | <option value="">请选择订单状态</option> |
| | | <option value="101">待接单</option> |
| | | <option value="102">已接单</option> |
| | | <option value="103">前往预约点</option> |
| | | <option value="104">到达预约点</option> |
| | | <option value="105">开始服务</option> |
| | | <option value="106">到达目的地</option> |
| | | <option value="107">待支付</option> |
| | | <option value="108">待评价</option> |
| | | <option value="109">已完成</option> |
| | | <option value="201">转单中</option> |
| | | <option value="301">已取消</option> |
| | | <option value="401">等待中</option> |
| | | </select> |
| | | <#SelectCon id="state" name="订单状态" > |
| | | <option value="">请选择订单状态</option> |
| | | <option value="101">待接单</option> |
| | | <option value="102">已接单</option> |
| | | <option value="103">前往预约点</option> |
| | | <option value="104">到达预约点</option> |
| | | <option value="105">开始服务</option> |
| | | <option value="106">到达目的地</option> |
| | | <option value="107">待支付</option> |
| | | <option value="108">待评价</option> |
| | | <option value="109">已完成</option> |
| | | <option value="201">转单中</option> |
| | | <option value="301">已取消</option> |
| | | <option value="401">等待中</option> |
| | | </#SelectCon> |
| | | </div> |
| | | <div class="col-sm-2"> |
| | | <#NameCon id="driverName" name="司机姓名" /> |
| | |
| | | } |
| | | } |
| | | }, |
| | | account: { |
| | | validators: { |
| | | notEmpty: { |
| | | message: '登录账号不能为空' |
| | | } |
| | | } |
| | | }, |
| | | password: { |
| | | validators: { |
| | | notEmpty: { |
| | | message: '登录密码不能为空' |
| | | }, |
| | | identical: { |
| | | field: 'rePassword', |
| | | message: '两次密码不一致' |
| | | }, |
| | | } |
| | | }, |
| | | rePassword: { |
| | | validators: { |
| | | notEmpty: { |
| | | message: '密码不能为空' |
| | | }, |
| | | identical: { |
| | | field: 'password', |
| | | message: '两次密码不一致' |
| | | }, |
| | | } |
| | | } |
| | | } |
| | | }; |
| | | |
| | |
| | | .set('status') |
| | | .set('area') |
| | | .set('areaId') |
| | | .set('account') |
| | | .set('password') |
| | | .set('createTime'); |
| | | } |
| | | |
| | |
| | | } |
| | | } |
| | | }, |
| | | account: { |
| | | validators: { |
| | | notEmpty: { |
| | | message: '登录账号不能为空' |
| | | } |
| | | } |
| | | }, |
| | | password: { |
| | | validators: { |
| | | notEmpty: { |
| | | message: '登录密码不能为空' |
| | | }, |
| | | identical: { |
| | | field: 'rePassword', |
| | | message: '两次密码不一致' |
| | | }, |
| | | } |
| | | }, |
| | | rePassword: { |
| | | validators: { |
| | | notEmpty: { |
| | | message: '密码不能为空' |
| | | }, |
| | | identical: { |
| | | field: 'password', |
| | | message: '两次密码不一致' |
| | | }, |
| | | } |
| | | } |
| | | } |
| | | }; |
| | | |
| | |
| | | .set('area') |
| | | .set('areaId') |
| | | .set('status') |
| | | .set('account') |
| | | .set('password') |
| | | .set('createTime'); |
| | | } |
| | | |
| | |
| | | //提交信息 |
| | | var ajax = new $ax(Feng.ctxPath + "/tBranchOffice/add", function(data){ |
| | | if(data.code == 500){ |
| | | Feng.error("添加失败!" + data.message + "!"); |
| | | Feng.error(data.message); |
| | | return false; |
| | | }else { |
| | | Feng.success("添加成功!"); |
| | |
| | | } |
| | | }}, |
| | | {title: '添加时间', field: 'createTime', visible: true, align: 'center', valign: 'middle'}, |
| | | {title: '操作', visible: true, align: 'center', valign: 'middle',width:150, |
| | | {title: '操作', visible: true, align: 'center', valign: 'middle',width:'160px',fixed:'true', |
| | | formatter: function (value, row) { |
| | | if (row.status === 1){ |
| | | return '<a href="#" onclick="TDriver.searchTDriverDetail('+row.id+')" style="color:green">详情</a>' +' ' + |
| | |
| | | {title: '操作', visible: true, align: 'center', valign: 'middle',width:150, |
| | | formatter: function (value, row) { |
| | | if (row.businessType === 1){ |
| | | return '<a href="#" onclick="TRevenue.searchTRevenueOrderDetail('+row.code+')" style="color:blue">详情</a>' |
| | | return `<a href="#" onclick="TRevenue.searchTRevenueOrderDetail('${row.code}')" style="color:blue">详情</a>` |
| | | }else if (row.businessType === 11){ |
| | | return '<a href="#" onclick="TRevenue.searchTRevenueCommissionDetail('+row.code+')" style="color:blue">详情</a>' |
| | | return `<a href="#" onclick="TRevenue.searchTRevenueCommissionDetail('${row.code}')" style="color:blue">详情</a>` |
| | | }else if (row.businessType === 12){ |
| | | return '<a href="#" onclick="TRevenue.searchTRevenueBalanceDetail('+row.code+')" style="color:blue">详情</a>' |
| | | return `<a href="#" onclick="TRevenue.searchTRevenueBalanceDetail('${row.code}')" style="color:blue">详情</a>` |
| | | } |
| | | } |
| | | } |
| | |
| | | * 客服管理 |
| | | */ |
| | | TSystemConfig.serviceMgmtSubmit = function () { |
| | | |
| | | var num1 = $("#num1").val(); |
| | | var reg=/^1[3-9]\d{9}$/;//由 1-9开头 的正则表达式 |
| | | //先判断是否为整数 在判断 是否在 1-总页 整数范围之内 |
| | | if(!reg.test(num1)){ |
| | | Feng.error("请输入合法手机号!"); |
| | | return; |
| | | } |
| | | |
| | | var ajax = new $ax(Feng.ctxPath + "/tSystemConfig/systemConfigSubmit", function (data) { |
| | | Feng.success("保存成功!"); |
| | | TSystemConfig.table.refresh(); |