Commit b28d3bd6 by huluobin

环境评分

parent 23b51b48
...@@ -718,7 +718,10 @@ public class OrderManageServiceImpl extends ServiceImpl<OrderManageMapper, Order ...@@ -718,7 +718,10 @@ public class OrderManageServiceImpl extends ServiceImpl<OrderManageMapper, Order
orderManage.setFinishTime(new Date()); orderManage.setFinishTime(new Date());
//订单已完成 //订单已完成
//环境评分
orderManage.setEnvironmentStar(cmd.getEnvironmentStar());
orderManageMapper.updateById(orderManage); orderManageMapper.updateById(orderManage);
Coupon coupon = couponService.getOne(new LambdaQueryWrapper<Coupon>().eq(Coupon::getName, "评价礼券")); Coupon coupon = couponService.getOne(new LambdaQueryWrapper<Coupon>().eq(Coupon::getName, "评价礼券"));
if (coupon != null) { if (coupon != null) {
couponService.sendCoupon(coupon.getId(), orderManage.getOrderUser()); couponService.sendCoupon(coupon.getId(), orderManage.getOrderUser());
......
...@@ -233,7 +233,6 @@ public class ScheduleManageServiceImpl extends ServiceImpl<ScheduleManageMapper, ...@@ -233,7 +233,6 @@ public class ScheduleManageServiceImpl extends ServiceImpl<ScheduleManageMapper,
public List<IdleTimeDTO> queryIdleTime(IdleTimeProgramQuery qry) throws ParseException, ExecutionException, InterruptedException { public List<IdleTimeDTO> queryIdleTime(IdleTimeProgramQuery qry) throws ParseException, ExecutionException, InterruptedException {
IdleTimeQuery idleTimeQuery = new IdleTimeQuery(); IdleTimeQuery idleTimeQuery = new IdleTimeQuery();
SimpleDateFormat simpleDateFormat = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss"); SimpleDateFormat simpleDateFormat = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
//美甲师不可用日期列表 //美甲师不可用日期列表
...@@ -241,20 +240,20 @@ public class ScheduleManageServiceImpl extends ServiceImpl<ScheduleManageMapper, ...@@ -241,20 +240,20 @@ public class ScheduleManageServiceImpl extends ServiceImpl<ScheduleManageMapper,
idleTimeQuery.setStoreTechnicianDTOList(storeTechnicianDTOList); idleTimeQuery.setStoreTechnicianDTOList(storeTechnicianDTOList);
long start3Time = simpleDateFormat.parse(qry.getScheduleDate() + " 10:00:00").getTime(); long workStartTime = simpleDateFormat.parse(qry.getScheduleDate() + " 10:00:00").getTime();
long workEndTime = simpleDateFormat.parse(qry.getScheduleDate() + " 22:00:00").getTime();
long end3Time = simpleDateFormat.parse(qry.getScheduleDate() + " 22:00:00").getTime();
List<Long> dateTimeList = new ArrayList<>(); List<Long> dateTimeList = new ArrayList<>();
//是否只查询指定时间段 //是否只查询指定时间段
if (ListUtil.isNotEmpty(qry.getDateTimeList())) { if (ListUtil.isNotEmpty(qry.getDateTimeList())) {
dateTimeList = qry.getDateTimeList(); dateTimeList = qry.getDateTimeList();
} }
//返回全部时间段 //返回全部时间段
else { else {
while (start3Time < end3Time) { while (workStartTime < workEndTime) {
dateTimeList.add(start3Time); dateTimeList.add(workStartTime);
start3Time = start3Time + 15 * 60000; workStartTime = workStartTime + 15 * 60000;
} }
} }
...@@ -265,6 +264,7 @@ public class ScheduleManageServiceImpl extends ServiceImpl<ScheduleManageMapper, ...@@ -265,6 +264,7 @@ public class ScheduleManageServiceImpl extends ServiceImpl<ScheduleManageMapper,
.map(scheduleServe -> { .map(scheduleServe -> {
ScheduleServeQuery scheduleServeQuery = new ScheduleServeQuery(); ScheduleServeQuery scheduleServeQuery = new ScheduleServeQuery();
BeanUtils.copyProperties(scheduleServe, scheduleServeQuery); BeanUtils.copyProperties(scheduleServe, scheduleServeQuery);
//款式or服务时间 //款式or服务时间
if (scheduleServe.getProduceId() == null) { if (scheduleServe.getProduceId() == null) {
scheduleServeQuery.setLengthTimeForEndTime(baseServeMapper.selectById(scheduleServe.getServeId()).getServiceDuration()); scheduleServeQuery.setLengthTimeForEndTime(baseServeMapper.selectById(scheduleServe.getServeId()).getServiceDuration());
......
...@@ -277,6 +277,8 @@ public class OrderManage implements Serializable { ...@@ -277,6 +277,8 @@ public class OrderManage implements Serializable {
@ApiModelProperty("是否发送评论服务通知 0-没有 1-是") @ApiModelProperty("是否发送评论服务通知 0-没有 1-是")
private Integer isSendCommentMsg; private Integer isSendCommentMsg;
@ApiModelProperty("环境评分")
private Integer environmentStar;
public void setIsFriendPayByPayUserAndOrderUser() { public void setIsFriendPayByPayUserAndOrderUser() {
this.isFriendPay = payUser.equals(orderUser) ? 2 : 1; this.isFriendPay = payUser.equals(orderUser) ? 2 : 1;
......
...@@ -107,7 +107,6 @@ public class IdleTimeProgramQuery { ...@@ -107,7 +107,6 @@ public class IdleTimeProgramQuery {
@ApiModelProperty("token") @ApiModelProperty("token")
private String token; private String token;
@TableField(exist = false) @TableField(exist = false)
@ApiModelProperty("预约时间") @ApiModelProperty("预约时间")
private String scheduleDate; private String scheduleDate;
......
...@@ -16,6 +16,9 @@ public class CreateCommentCommand { ...@@ -16,6 +16,9 @@ public class CreateCommentCommand {
private Integer currentCustomerId; private Integer currentCustomerId;
@ApiModelProperty("环境评分")
private Integer environmentStar;
@NotNull @NotNull
@ApiModelProperty("订单评论列表") @ApiModelProperty("订单评论列表")
private List<OrderCommentCommand> commentList; private List<OrderCommentCommand> commentList;
......
...@@ -146,6 +146,9 @@ public class OrderManageDTO { ...@@ -146,6 +146,9 @@ public class OrderManageDTO {
@ApiModelProperty("支付用户信息") @ApiModelProperty("支付用户信息")
private Customer payCustomer; private Customer payCustomer;
@ApiModelProperty("环境评分")
private Integer environmentStar;
public void setImages() { public void setImages() {
images = orderServeDTOList images = orderServeDTOList
.stream() .stream()
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment