fix
This commit is contained in:
@@ -3,6 +3,8 @@ package com.cool.store.dao;
|
||||
import com.alibaba.fastjson.JSONObject;
|
||||
import com.aliyun.openservices.shade.org.apache.commons.lang3.StringUtils;
|
||||
import com.cool.store.entity.LineCalendarsEventDO;
|
||||
import com.cool.store.enums.ErrorCodeEnum;
|
||||
import com.cool.store.exception.ServiceException;
|
||||
import com.cool.store.mapper.LineCalendarsEventMapper;
|
||||
import com.cool.store.utils.StringUtil;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
@@ -59,8 +61,9 @@ public class LineCalendarsEventDAO {
|
||||
* @return
|
||||
*/
|
||||
public Long addCalendarsEvent(LineCalendarsEventDO param){
|
||||
if(Objects.nonNull(param.getRegionId()) || Objects.nonNull(param.getLineId()) || Objects.nonNull(param.getPartnerId()) || Objects.nonNull(param.getStartTime()) || Objects.nonNull(param.getEndTime())){
|
||||
if(Objects.isNull(param.getRegionId()) || Objects.isNull(param.getLineId()) || Objects.isNull(param.getPartnerId()) || Objects.isNull(param.getStartTime()) || Objects.isNull(param.getEndTime())){
|
||||
log.error("新增日历事件失败:{}",JSONObject.toJSONString(param));
|
||||
throw new ServiceException(ErrorCodeEnum.PARAMS_REQUIRED);
|
||||
}
|
||||
lineCalendarsEventMapper.insertSelective(param);
|
||||
return param.getId();
|
||||
|
||||
@@ -101,7 +101,7 @@
|
||||
select
|
||||
<include refid="allColumn"/>
|
||||
from xfsg_point_info
|
||||
where deleted = 0 and point_status in (4,5) and development_manager = #{request.developmentManager}
|
||||
where deleted = 0 and point_status in (4,5) and development_manager = #{request.developmentManager}
|
||||
<if test="request.pointStatus != null and request.pointStatus != ''">
|
||||
and point_status = #{request.pointStatus}
|
||||
</if>
|
||||
|
||||
@@ -14,6 +14,7 @@ import javax.validation.constraints.NotNull;
|
||||
@Data
|
||||
public class AppointmentTimeRequest {
|
||||
|
||||
@NotNull
|
||||
@ApiModelProperty("线索id")
|
||||
private Long lineId;
|
||||
|
||||
|
||||
@@ -18,7 +18,7 @@ import java.util.stream.Collectors;
|
||||
* @date 2024-04-08 16:50
|
||||
*/
|
||||
@Data
|
||||
public class RecommendPointRequest {
|
||||
public class LineRecommendPointRequest {
|
||||
|
||||
@ApiModelProperty("线索id")
|
||||
private Long lineId;
|
||||
@@ -0,0 +1,46 @@
|
||||
package com.cool.store.request;
|
||||
|
||||
import com.cool.store.entity.PointRecommendDO;
|
||||
import com.cool.store.enums.point.PointRecommendStatus;
|
||||
import com.google.common.collect.Lists;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
import org.apache.commons.collections4.CollectionUtils;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Objects;
|
||||
import java.util.stream.Collectors;
|
||||
|
||||
/**
|
||||
* @author zhangchenbiao
|
||||
* @FileName: RecommendPointRequest
|
||||
* @Description:
|
||||
* @date 2024-04-08 16:50
|
||||
*/
|
||||
@Data
|
||||
public class PointRecommendLineRequest {
|
||||
|
||||
@ApiModelProperty("线索ids")
|
||||
private List<Long> lineIds;
|
||||
|
||||
@ApiModelProperty("铺位id")
|
||||
private Long pointId;
|
||||
|
||||
@ApiModelProperty(value = "拓展经理", hidden = true)
|
||||
private String developmentManager;
|
||||
|
||||
public List<PointRecommendDO> convertList(){
|
||||
if(Objects.isNull(this.lineIds) || CollectionUtils.isEmpty(this.lineIds) || Objects.isNull(pointId)){
|
||||
return Lists.newArrayList();
|
||||
}
|
||||
return this.lineIds.stream().map(lineId -> {
|
||||
PointRecommendDO pointRecommendDO = new PointRecommendDO();
|
||||
pointRecommendDO.setLineId(lineId);
|
||||
pointRecommendDO.setDevelopmentManager(this.developmentManager);
|
||||
pointRecommendDO.setPointId(pointId);
|
||||
pointRecommendDO.setStatus(PointRecommendStatus.POINT_RECOMMEND_STATUS_1.getCode());
|
||||
return pointRecommendDO;
|
||||
}).collect(Collectors.toList());
|
||||
}
|
||||
|
||||
}
|
||||
@@ -159,11 +159,18 @@ public interface ShopPointService {
|
||||
PageInfo<PointPageVO> getRecommendPointList(RecommendPointPageRequest request);
|
||||
|
||||
/**
|
||||
* 推送铺位
|
||||
* 加盟商推荐铺位
|
||||
* @param request
|
||||
* @return
|
||||
*/
|
||||
Integer recommendPoint(RecommendPointRequest request);
|
||||
Integer lineRecommendPoint(LineRecommendPointRequest request);
|
||||
|
||||
/**
|
||||
* 铺位推荐加盟商
|
||||
* @param request
|
||||
* @return
|
||||
*/
|
||||
Integer pointRecommendLine(PointRecommendLineRequest request);
|
||||
|
||||
/**
|
||||
* 选址人员转让加盟商
|
||||
|
||||
@@ -267,10 +267,10 @@ public class LineInterviewServiceImpl extends LineFlowService implements LineInt
|
||||
throw new ServiceException(ErrorCodeEnum.LINE_ID_IS_NOT_EXIST);
|
||||
}
|
||||
Integer joinInterviewStatus = JoinInterviewStatusEnum.getJoinInterviewStatus(interviewInfo.getJoinInterviewStatus(), userType);
|
||||
if(!joinInterviewStatus.equals(interviewInfo.getJoinInterviewStatus()) && JoinInterviewStatusEnum.JOIN.getCode().equals(joinInterviewStatus)){
|
||||
if(Objects.isNull(interviewInfo.getActualStartTime())){
|
||||
interviewInfo.setActualStartTime(new Date());
|
||||
interviewInfo.setRoomStatus(RoomStatus.OPEN.getCode());
|
||||
}
|
||||
interviewInfo.setRoomStatus(RoomStatus.OPEN.getCode());
|
||||
interviewInfo.setJoinInterviewStatus(joinInterviewStatus);
|
||||
lineInterviewDAO.updateInterviewInfo(interviewInfo);
|
||||
String userSig = TRTCUtils.genUserSig(sdkAppId, key, interviewUserId);
|
||||
@@ -395,6 +395,8 @@ public class LineInterviewServiceImpl extends LineFlowService implements LineInt
|
||||
String developmentManager = Optional.ofNullable(enterpriseUser).map(EnterpriseUserDO::getUserId).orElse(null);
|
||||
updateLine.setDevelopmentManager(developmentManager);
|
||||
lineInfoDAO.updateLineInfo(updateLine);
|
||||
//初始化店铺
|
||||
|
||||
}
|
||||
return lineInterviewDAO.updateInterviewInfo(updateInterviewInfo) > 0;
|
||||
}
|
||||
|
||||
@@ -3,7 +3,6 @@ package com.cool.store.service.impl;
|
||||
import com.alibaba.fastjson.JSONObject;
|
||||
import com.cool.store.constants.CommonConstants;
|
||||
import com.cool.store.dao.*;
|
||||
import com.cool.store.dto.interview.LineInterviewPageDTO;
|
||||
import com.cool.store.dto.point.AuditNodeDTO;
|
||||
import com.cool.store.entity.*;
|
||||
import com.cool.store.enums.AuditStatusEnum;
|
||||
@@ -306,8 +305,7 @@ public class ShopPointServiceImpl implements ShopPointService {
|
||||
updatePoint.setPointStatus(PointStatusEnum.POINT_STATUS_4.getCode());
|
||||
}else{
|
||||
//没有下一节点 审批通过
|
||||
Integer pointStatus = SelectStatusEnum.SELECT_STATUS_1.getCode().equals(pointInfo.getSelectStatus()) ? PointStatusEnum.POINT_STATUS_6.getCode() : PointStatusEnum.POINT_STATUS_5.getCode();
|
||||
updatePoint.setPointStatus(pointStatus);
|
||||
updatePoint.setPointStatus(PointStatusEnum.POINT_STATUS_5.getCode());
|
||||
}
|
||||
return pointInfoDAO.updatePointInfo(updatePoint);
|
||||
}
|
||||
@@ -362,8 +360,7 @@ public class ShopPointServiceImpl implements ShopPointService {
|
||||
}
|
||||
PointInfoDO pointInfoUpdate = new PointInfoDO();
|
||||
pointInfoUpdate.setId(pointId);
|
||||
Integer pointStatus = SelectStatusEnum.SELECT_STATUS_1.getCode().equals(pointInfo.getSelectStatus()) ? PointStatusEnum.POINT_STATUS_6.getCode() : PointStatusEnum.POINT_STATUS_5.getCode();
|
||||
pointInfoUpdate.setPointStatus(pointStatus);
|
||||
pointInfoUpdate.setPointStatus(PointStatusEnum.POINT_STATUS_5.getCode());
|
||||
return pointInfoDAO.updatePointInfo(pointInfoUpdate);
|
||||
}
|
||||
|
||||
@@ -462,7 +459,13 @@ public class ShopPointServiceImpl implements ShopPointService {
|
||||
}
|
||||
|
||||
@Override
|
||||
public Integer recommendPoint(RecommendPointRequest request) {
|
||||
public Integer lineRecommendPoint(LineRecommendPointRequest request) {
|
||||
List<PointRecommendDO> recommendList = request.convertList();
|
||||
return pointRecommendDAO.addRecommendPoint(recommendList);
|
||||
}
|
||||
|
||||
@Override
|
||||
public Integer pointRecommendLine(PointRecommendLineRequest request) {
|
||||
List<PointRecommendDO> recommendList = request.convertList();
|
||||
return pointRecommendDAO.addRecommendPoint(recommendList);
|
||||
}
|
||||
|
||||
@@ -152,11 +152,18 @@ public class ShopPointController {
|
||||
return ResponseResult.success(shopPointService.getRecommendPointList(request));
|
||||
}
|
||||
|
||||
@ApiOperation("铺位推送")
|
||||
@PostMapping("/recommendPoint")
|
||||
public ResponseResult<Integer> recommendPoint(@RequestBody @Validated RecommendPointRequest request) {
|
||||
@ApiOperation("加盟商详情推送铺位")
|
||||
@PostMapping("/lineRecommendPoint")
|
||||
public ResponseResult<Integer> lineRecommendPoint(@RequestBody @Validated LineRecommendPointRequest request) {
|
||||
request.setDevelopmentManager(CurrentUserHolder.getUserId());
|
||||
return ResponseResult.success(shopPointService.recommendPoint(request));
|
||||
return ResponseResult.success(shopPointService.lineRecommendPoint(request));
|
||||
}
|
||||
|
||||
@ApiOperation("铺位详情推送加盟商")
|
||||
@PostMapping("/pointRecommendLine")
|
||||
public ResponseResult<Integer> pointRecommendLine(@RequestBody @Validated PointRecommendLineRequest request) {
|
||||
request.setDevelopmentManager(CurrentUserHolder.getUserId());
|
||||
return ResponseResult.success(shopPointService.pointRecommendLine(request));
|
||||
}
|
||||
|
||||
@ApiOperation("选址人员转让加盟商")
|
||||
|
||||
@@ -41,7 +41,7 @@ public class LineInterviewController {
|
||||
@GetMapping("/appointment/time")
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(name = "lineId", value = "线索id", required = true),
|
||||
@ApiImplicitParam(name = "interviewType", value = "面试类型:0面谈;1面试", required = true),
|
||||
@ApiImplicitParam(name = "interviewType", value = "面试类型:0面谈;1一审;2二审", required = true),
|
||||
@ApiImplicitParam(name = "appointmentDate", value = "预约日期 yyyy-MM-dd", required = true)
|
||||
})
|
||||
public ResponseResult<List<AppointmentTimeVO>> getAppointmentTime(@RequestParam("lineId")Long lineId,
|
||||
|
||||
Reference in New Issue
Block a user