添加开始服务打卡备注
This commit is contained in:
parent
75b37b259d
commit
f7cdf0bfa9
|
@ -368,12 +368,12 @@ public class ArtificerController {
|
|||
if(artificer.getStatus()==1){
|
||||
artificer.setStatus(2);
|
||||
}else{
|
||||
SimpleDateFormat simpleDateFormat = new SimpleDateFormat("yyyy-MM-dd");
|
||||
String time = simpleDateFormat.format(new Date());
|
||||
MessageInfo messageInfo = messageService.selectMessageByUserIdAndTime(userId, time);
|
||||
if(messageInfo==null){
|
||||
return Result.error("您今天还没签到,请签到后进行上线!");
|
||||
}
|
||||
// SimpleDateFormat simpleDateFormat = new SimpleDateFormat("yyyy-MM-dd");
|
||||
// String time = simpleDateFormat.format(new Date());
|
||||
// MessageInfo messageInfo = messageService.selectMessageByUserIdAndTime(userId, time);
|
||||
// if(messageInfo==null){
|
||||
// return Result.error("您今天还没签到,请签到后进行上线!");
|
||||
// }
|
||||
artificer.setStatus(1);
|
||||
}
|
||||
artificerService.updateById(artificer);
|
||||
|
@ -506,5 +506,10 @@ public class ArtificerController {
|
|||
return ordersService.selectNewUserOrdersRate();
|
||||
}
|
||||
|
||||
@GetMapping("/jszd")
|
||||
@ApiOperation("技师转单")
|
||||
public Result jszd(Long orderId,Long artificerId){
|
||||
return ordersService.jszd(orderId, artificerId);
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -288,8 +288,8 @@ public class AppArtificerController {
|
|||
|
||||
@PostMapping("/startOrders")
|
||||
@ApiOperation("开始服务")
|
||||
public Result startOrders(Long ordersId,String startLongitude,String startLatitude,String startImg){
|
||||
return ordersService.startOrders(ordersId,startLongitude,startLatitude,startImg);
|
||||
public Result startOrders(Long ordersId,String startLongitude,String startLatitude,String startImg,String startRemark){
|
||||
return ordersService.startOrders(ordersId,startLongitude,startLatitude,startImg,startRemark);
|
||||
}
|
||||
|
||||
@PostMapping("/artificerStartOrEndTime")
|
||||
|
|
|
@ -120,6 +120,8 @@ public class MassageType implements Serializable {
|
|||
|
||||
private String jianjie;
|
||||
|
||||
private Integer qyType;//是否企业预约项目(0不是 1是)
|
||||
|
||||
@TableField(exist = false)
|
||||
private String classifyName;
|
||||
|
||||
|
|
|
@ -457,6 +457,12 @@ public class Orders implements Serializable {
|
|||
* 项目名称
|
||||
*/
|
||||
private String entryName;
|
||||
|
||||
private String startRemark;
|
||||
|
||||
|
||||
|
||||
|
||||
@TableField(exist = false)
|
||||
private List<OrdersMassage> ordersMassageList;
|
||||
@TableField(exist = false)
|
||||
|
|
|
@ -54,7 +54,7 @@ public interface OrdersService extends IService<Orders> {
|
|||
|
||||
Result accomplishOrders(Long ordersId,Integer type,String accomplishLongitude,String accomplishLatitude,String jsFwcn,String jsPjtag,String jsTsbz,String earlyFinishReason);
|
||||
|
||||
Result startOrders(Long ordersId,String startLongitude,String startLatitude,String startImg);
|
||||
Result startOrders(Long ordersId,String startLongitude,String startLatitude,String startImg,String startRemark);
|
||||
|
||||
Result artificerStartOrEndTime(Long ordersId);
|
||||
|
||||
|
@ -108,4 +108,6 @@ public interface OrdersService extends IService<Orders> {
|
|||
* @return
|
||||
*/
|
||||
Result jishiQueren(Long ordersId);
|
||||
|
||||
Result jszd(Long orderId, Long artificerId);
|
||||
}
|
|
@ -6099,7 +6099,7 @@ public class OrdersServiceImpl extends ServiceImpl<OrdersDao, Orders> implements
|
|||
}
|
||||
|
||||
@Override
|
||||
public Result startOrders(Long ordersId, String startLongitude, String startLatitude, String startImg) {
|
||||
public Result startOrders(Long ordersId, String startLongitude, String startLatitude, String startImg,String startRemark) {
|
||||
Calendar calendar = Calendar.getInstance();
|
||||
Orders orders = baseMapper.selectById(ordersId);
|
||||
//判断开始服务时间 是否超过预定时间
|
||||
|
@ -6121,6 +6121,7 @@ public class OrdersServiceImpl extends ServiceImpl<OrdersDao, Orders> implements
|
|||
orders.setOverTimeOrders(2);
|
||||
}
|
||||
orders.setStartImg(startImg);
|
||||
orders.setStartRemark(startRemark);
|
||||
orders.setStartLatitude(startLatitude);
|
||||
orders.setStartLongitude(startLongitude);
|
||||
|
||||
|
@ -6855,4 +6856,30 @@ public class OrdersServiceImpl extends ServiceImpl<OrdersDao, Orders> implements
|
|||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
@Transactional
|
||||
public Result jszd(Long orderId, Long artificerId) {
|
||||
Orders orders = ordersDao.selectById(orderId);
|
||||
|
||||
Long parentId = orders.getParentId();
|
||||
Long oldOrdersId = orders.getOldOrdersId();
|
||||
if(parentId != null && parentId != 0){
|
||||
Orders parentorders = ordersDao.selectById(parentId);
|
||||
parentorders.setArtificerId(artificerId);
|
||||
ordersDao.updateById(parentorders);
|
||||
|
||||
}
|
||||
if(oldOrdersId!=null){
|
||||
Orders oldorders = ordersDao.selectById(oldOrdersId);
|
||||
oldorders.setArtificerId(artificerId);
|
||||
ordersDao.updateById(oldorders);
|
||||
}
|
||||
orders.setArtificerId(artificerId);
|
||||
ordersDao.updateById(orders);
|
||||
Map<String,Object> map = new HashMap<>();
|
||||
map.put("code",200);
|
||||
map.put("msg","转单成功");
|
||||
return Result.success(map);
|
||||
}
|
||||
|
||||
}
|
Loading…
Reference in New Issue