详情调整

This commit is contained in:
zhangchenbiao
2024-04-17 19:25:37 +08:00
parent 840007e79f
commit ee537c635a
10 changed files with 37 additions and 9 deletions

View File

@@ -51,4 +51,11 @@ public class PointTodoInfoDAO {
PageHelper.startPage(request.getPageNum(), request.getPageSize());
return pointTodoInfoMapper.getUserTodoList(request);
}
public Integer getCurNodeNoByPoint(Long pointId){
if(Objects.isNull(pointId)){
return null;
}
return pointTodoInfoMapper.getCurNodeNoByPoint(pointId);
}
}

View File

@@ -56,4 +56,11 @@ public interface PointTodoInfoMapper extends Mapper<PointTodoInfoDO> {
* @return
*/
Page<PointInfoDO> getUserTodoList(@Param("request") PointTodoPageRequest request);
/**
* 获取当前节点
* @param pointId
* @return
*/
Integer getCurNodeNoByPoint(@Param("pointId") Long pointId);
}

View File

@@ -95,4 +95,9 @@
where
a.handler_user_id = #{request.developmentManager} and a.status = 0 and a.deleted = 0 and b.deleted = 0
</select>
<select id="getCurNodeNoByPoint" resultType="integer">
select node_no from xfsg_point_todo_info where point_id = #{pointId} and status = 0 and deleted = 0 limit 1
</select>
</mapper>

View File

@@ -26,7 +26,7 @@ public class AddPointDetailRequest {
@ApiModelProperty("详细地址")
private String address;
@ApiModelProperty("经营状况")
@ApiModelProperty("经营状况 1营业中 2空铺")
private Integer businessStatus;
@ApiModelProperty("09:00-10:00人流量")

View File

@@ -27,7 +27,7 @@ public class MiniAddPointRequest {
@ApiModelProperty("详细地址")
private String address;
@ApiModelProperty("经营状况")
@ApiModelProperty("经营状况 1营业中 2空铺")
private Integer businessStatus;
@ApiModelProperty("使用面积(一楼)")

View File

@@ -230,6 +230,9 @@ public class PointDetailVO {
@ApiModelProperty("图片对象")
private String pictureObj;
@ApiModelProperty("当前节点")
private Integer curNodeNo;
public static PointDetailVO convertVO(PointInfoDO pointInfo, PointDetailInfoDO pointDetailInfo) {
PointDetailVO result = new PointDetailVO();

View File

@@ -29,7 +29,7 @@ public interface PointService {
* @param pointId
* @return
*/
PointDetailVO getPointDetailInfo(Long pointId);
PointDetailVO getPointDetailInfo(Long pointId, Boolean isGetNodeNo);
/**
* 更新铺位

View File

@@ -99,7 +99,7 @@ public class PointServiceImpl implements PointService {
}
@Override
public PointDetailVO getPointDetailInfo(Long pointId) {
public PointDetailVO getPointDetailInfo(Long pointId, Boolean isGetNodeNo) {
PointInfoDO pointInfo = pointInfoDAO.getPointInfoById(pointId);
if(Objects.isNull(pointInfo)){
log.error("铺位基本信息不存在");
@@ -110,7 +110,11 @@ public class PointServiceImpl implements PointService {
log.error("铺位详情信息不存在");
throw new ServiceException(ErrorCodeEnum.POINT_NOT_EXIST);
}
return PointDetailVO.convertVO(pointInfo, pointDetailInfo);
PointDetailVO result = PointDetailVO.convertVO(pointInfo, pointDetailInfo);
if(Objects.nonNull(isGetNodeNo) && isGetNodeNo){
result.setCurNodeNo(pointTodoInfoDAO.getCurNodeNoByPoint(pointId));
}
return result;
}
@Override

View File

@@ -38,8 +38,9 @@ public class PointController {
@ApiOperation("铺位详情")
@GetMapping("/detail")
public ResponseResult<PointDetailVO> getPointDetailInfo(@RequestParam("pointId")Long pointId) {
return ResponseResult.success(pointService.getPointDetailInfo(pointId));
public ResponseResult<PointDetailVO> getPointDetailInfo(@RequestParam("pointId")Long pointId,
@RequestParam(value = "isGetNodeNo", required = false)Boolean isGetNodeNo) {
return ResponseResult.success(pointService.getPointDetailInfo(pointId, isGetNodeNo));
}
@ApiOperation("完善铺位")

View File

@@ -66,8 +66,9 @@ public class MiniShopController {
@ApiOperation("铺位详情")
@GetMapping("/detail")
public ResponseResult<PointDetailVO> getPointDetailInfo(@RequestParam("pointId")Long pointId) {
return ResponseResult.success(pointService.getPointDetailInfo(pointId));
public ResponseResult<PointDetailVO> getPointDetailInfo(@RequestParam("pointId")Long pointId,
@RequestParam(value = "isGetNodeNo", required = false)Boolean isGetNodeNo) {
return ResponseResult.success(pointService.getPointDetailInfo(pointId, isGetNodeNo));
}
@ApiOperation("选择铺位")