Commit 5d7d36e8 authored by 王飞's avatar 王飞

Merge branch 'wangdingyi' into 'dev'

查询任务列表返回结果修改&接口注解

See merge request !16
parents 4494e04e 064de0b8
...@@ -2,6 +2,7 @@ package com.ruoyi.mapper; ...@@ -2,6 +2,7 @@ package com.ruoyi.mapper;
import com.ruoyi.domain.ReviewSceneChangeTask; import com.ruoyi.domain.ReviewSceneChangeTask;
import com.baomidou.mybatisplus.core.mapper.BaseMapper; import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.ruoyi.web.response.ReviewSceneChangeTaskResponse;
import org.springframework.stereotype.Repository; import org.springframework.stereotype.Repository;
import org.apache.ibatis.annotations.Param; import org.apache.ibatis.annotations.Param;
...@@ -24,14 +25,14 @@ public interface ReviewSceneChangeTaskMapper extends BaseMapper<ReviewSceneChang ...@@ -24,14 +25,14 @@ public interface ReviewSceneChangeTaskMapper extends BaseMapper<ReviewSceneChang
* @param userId * @param userId
* @return * @return
*/ */
List<ReviewSceneChangeTask> findPendingListByUserId(@Param("userId") Long userId); List<ReviewSceneChangeTaskResponse> findPendingListByUserId(@Param("userId") Long userId);
/** /**
* 根据用户ID查询已办列表 * 根据用户ID查询已办列表
* @param userId * @param userId
* @return * @return
*/ */
List<ReviewSceneChangeTask> findFinishListByUserId(@Param("userId") Long userId); List<ReviewSceneChangeTaskResponse> findFinishListByUserId(@Param("userId") Long userId);
/** /**
* 查询当前用户创建的任务 * 查询当前用户创建的任务
......
...@@ -2,6 +2,7 @@ package com.ruoyi.service; ...@@ -2,6 +2,7 @@ package com.ruoyi.service;
import com.ruoyi.domain.ReviewSceneChangeTask; import com.ruoyi.domain.ReviewSceneChangeTask;
import com.baomidou.mybatisplus.extension.service.IService; import com.baomidou.mybatisplus.extension.service.IService;
import com.ruoyi.web.response.ReviewSceneChangeTaskResponse;
import java.util.Date; import java.util.Date;
import java.util.List; import java.util.List;
...@@ -50,14 +51,14 @@ public interface ReviewSceneChangeTaskService extends IService<ReviewSceneChange ...@@ -50,14 +51,14 @@ public interface ReviewSceneChangeTaskService extends IService<ReviewSceneChange
* @param userId * @param userId
* @return * @return
*/ */
List<ReviewSceneChangeTask> findPendingListByUserId(Long userId); List<ReviewSceneChangeTaskResponse> findPendingListByUserId(Long userId);
/** /**
* 根据用户ID查询已办列表 * 根据用户ID查询已办列表
* @param userId * @param userId
* @return * @return
*/ */
List<ReviewSceneChangeTask> findFinishListByUserId(Long userId); List<ReviewSceneChangeTaskResponse> findFinishListByUserId(Long userId);
/** /**
* 根据用户ID查询发布的任务列表 * 根据用户ID查询发布的任务列表
......
...@@ -13,6 +13,7 @@ import com.ruoyi.service.ReviewSceneChangeTaskUserRelationService; ...@@ -13,6 +13,7 @@ import com.ruoyi.service.ReviewSceneChangeTaskUserRelationService;
import com.ruoyi.service.ReviewSceneService; import com.ruoyi.service.ReviewSceneService;
import com.ruoyi.service.SystemReviewTaskInboxService; import com.ruoyi.service.SystemReviewTaskInboxService;
import com.ruoyi.system.service.ISysUserService; import com.ruoyi.system.service.ISysUserService;
import com.ruoyi.web.response.ReviewSceneChangeTaskResponse;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service; import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional; import org.springframework.transaction.annotation.Transactional;
...@@ -191,8 +192,8 @@ public class ReviewSceneChangeTaskServiceImpl extends ServiceImpl<ReviewSceneCha ...@@ -191,8 +192,8 @@ public class ReviewSceneChangeTaskServiceImpl extends ServiceImpl<ReviewSceneCha
* @return * @return
*/ */
@Override @Override
public List<ReviewSceneChangeTask> findPendingListByUserId(Long userId) { public List<ReviewSceneChangeTaskResponse> findPendingListByUserId(Long userId) {
List<ReviewSceneChangeTask> reviewSceneChangeTask = reviewSceneChangeTaskMapper.findPendingListByUserId(userId); List<ReviewSceneChangeTaskResponse> reviewSceneChangeTask = reviewSceneChangeTaskMapper.findPendingListByUserId(userId);
return reviewSceneChangeTask; return reviewSceneChangeTask;
} }
...@@ -202,8 +203,8 @@ public class ReviewSceneChangeTaskServiceImpl extends ServiceImpl<ReviewSceneCha ...@@ -202,8 +203,8 @@ public class ReviewSceneChangeTaskServiceImpl extends ServiceImpl<ReviewSceneCha
* @return * @return
*/ */
@Override @Override
public List<ReviewSceneChangeTask> findFinishListByUserId(Long userId) { public List<ReviewSceneChangeTaskResponse> findFinishListByUserId(Long userId) {
List<ReviewSceneChangeTask> reviewSceneChangeTask = reviewSceneChangeTaskMapper.findFinishListByUserId(userId); List<ReviewSceneChangeTaskResponse> reviewSceneChangeTask = reviewSceneChangeTaskMapper.findFinishListByUserId(userId);
return reviewSceneChangeTask; return reviewSceneChangeTask;
} }
......
...@@ -8,6 +8,9 @@ import com.ruoyi.common.enums.BusinessType; ...@@ -8,6 +8,9 @@ import com.ruoyi.common.enums.BusinessType;
import com.ruoyi.common.utils.bean.BeanUtils; import com.ruoyi.common.utils.bean.BeanUtils;
import com.ruoyi.domain.ReviewSceneChangeTask; import com.ruoyi.domain.ReviewSceneChangeTask;
import com.ruoyi.service.ReviewSceneChangeTaskService; import com.ruoyi.service.ReviewSceneChangeTaskService;
import com.ruoyi.web.request.ReviewSceneChangeTaskCreateRequest;
import com.ruoyi.web.request.ReviewSceneChangeTaskPassRequest;
import com.ruoyi.web.response.ReviewSceneChangeTaskResponse;
import com.ruoyi.web.request.*; import com.ruoyi.web.request.*;
import io.swagger.annotations.Api; import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation; import io.swagger.annotations.ApiOperation;
...@@ -43,6 +46,7 @@ public class ReviewSceneChangeTaskController extends BaseController { ...@@ -43,6 +46,7 @@ public class ReviewSceneChangeTaskController extends BaseController {
return R.ok(); return R.ok();
} }
@ApiOperation("审核通过任务")
@Trace @Trace
@Tags({@Tag(key = "param", value = "arg[0]"), @Tag(key = "result", value = "returnedObj")}) @Tags({@Tag(key = "param", value = "arg[0]"), @Tag(key = "result", value = "returnedObj")})
@Log(title = "审核通过任务", businessType = BusinessType.UPDATE) @Log(title = "审核通过任务", businessType = BusinessType.UPDATE)
...@@ -54,6 +58,7 @@ public class ReviewSceneChangeTaskController extends BaseController { ...@@ -54,6 +58,7 @@ public class ReviewSceneChangeTaskController extends BaseController {
return R.ok(); return R.ok();
} }
@ApiOperation("审核驳回任务")
@Trace @Trace
@Tags({@Tag(key = "param", value = "arg[0]"), @Tag(key = "result", value = "returnedObj")}) @Tags({@Tag(key = "param", value = "arg[0]"), @Tag(key = "result", value = "returnedObj")})
@Log(title = "审核驳回任务", businessType = BusinessType.UPDATE) @Log(title = "审核驳回任务", businessType = BusinessType.UPDATE)
...@@ -73,7 +78,7 @@ public class ReviewSceneChangeTaskController extends BaseController { ...@@ -73,7 +78,7 @@ public class ReviewSceneChangeTaskController extends BaseController {
@Trace @Trace
@Tags({@Tag(key = "param", value = "arg[0]"), @Tag(key = "result", value = "returnedObj")}) @Tags({@Tag(key = "param", value = "arg[0]"), @Tag(key = "result", value = "returnedObj")})
@RequestMapping(method = RequestMethod.POST, value = "/findPending") @RequestMapping(method = RequestMethod.POST, value = "/findPending")
public TableDataInfo<ReviewSceneChangeTask> findPending(@Validated @RequestBody ReviewSceneChangeTaskFindPendingRequest request) { public TableDataInfo<ReviewSceneChangeTaskResponse> findPending(@Validated @RequestBody ReviewSceneChangeTaskFindPendingRequest request) {
startPage(request); startPage(request);
return getDataTable(reviewSceneChangeTaskService.findPendingListByUserId(getUserId())); return getDataTable(reviewSceneChangeTaskService.findPendingListByUserId(getUserId()));
} }
...@@ -86,7 +91,7 @@ public class ReviewSceneChangeTaskController extends BaseController { ...@@ -86,7 +91,7 @@ public class ReviewSceneChangeTaskController extends BaseController {
@Trace @Trace
@Tags({@Tag(key = "param", value = "arg[0]"), @Tag(key = "result", value = "returnedObj")}) @Tags({@Tag(key = "param", value = "arg[0]"), @Tag(key = "result", value = "returnedObj")})
@RequestMapping(method = RequestMethod.POST, value = "/findFinish") @RequestMapping(method = RequestMethod.POST, value = "/findFinish")
public TableDataInfo<ReviewSceneChangeTask> findFinish(ReviewSceneChangeTaskFindFinishRequest request) { public TableDataInfo<ReviewSceneChangeTaskResponse> findFinish(ReviewSceneChangeTaskFindFinishRequest request) {
startPage(request); startPage(request);
return getDataTable(reviewSceneChangeTaskService.findFinishListByUserId(getUserId())); return getDataTable(reviewSceneChangeTaskService.findFinishListByUserId(getUserId()));
} }
......
package com.ruoyi.web.request; package com.ruoyi.web.request;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data; import lombok.Data;
@ApiModel(value = "ReviewSceneChangeTaskPassRequest", description = "审核任务")
@Data @Data
public class ReviewSceneChangeTaskPassRequest { public class ReviewSceneChangeTaskPassRequest {
@ApiModelProperty(value = "任务id",required = true)
private Long taskId; private Long taskId;
@ApiModelProperty("评论")
private String comment; private String comment;
} }
package com.ruoyi.web.response; package com.ruoyi.web.response;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data; import lombok.Data;
import java.util.Date; import java.util.Date;
@ApiModel(value = "ReviewSceneChangeTaskResponse", description = "查询返回结果")
@Data @Data
public class ReviewSceneChangeTaskResponse { public class ReviewSceneChangeTaskResponse {
/** /**
* 主键 * 主键
*/ */
@ApiModelProperty("主键")
private Long id; private Long id;
/** /**
* 任务编号 * 任务编号
*/ */
@ApiModelProperty("任务编号")
private String taskNo; private String taskNo;
/** /**
* 章节 * 章节
*/ */
@ApiModelProperty("章节")
private String chapter; private String chapter;
/** /**
* 审查标准id * 审查标准id
*/ */
@ApiModelProperty("审查标准id")
private Long standardId; private Long standardId;
/** /**
* 审查标准 * 审查标准
*/ */
@ApiModelProperty("审查标准")
private String standard; private String standard;
/** /**
* 审查要点id * 审查要点id
*/ */
@ApiModelProperty("审查要点id")
private Long keypointId; private Long keypointId;
/** /**
* 审查要点 * 审查要点
*/ */
@ApiModelProperty("审查要点")
private String keypoint; private String keypoint;
/** /**
* 审查细则id * 审查细则id
*/ */
@ApiModelProperty("审查细则id")
private Long detailsId; private Long detailsId;
/** /**
* 审查细则 * 审查细则
*/ */
@ApiModelProperty("审查细则")
private String details; private String details;
/** /**
* 操作(ADD DELETE UPDATE) * 操作(ADD DELETE UPDATE)
*/ */
@ApiModelProperty("操作(ADD DELETE UPDATE)")
private String operation; private String operation;
/** /**
* 当 operation 为 ADD 时该字段为空 * 当 operation 为 ADD 时该字段为空
*/ */
@ApiModelProperty("当 operation 为 ADD 时该字段为空")
private String oldText; private String oldText;
/** /**
* 当 operation 为 DELETE 时该字段为空 * 当 operation 为 DELETE 时该字段为空
*/ */
@ApiModelProperty("当 operation 为 DELETE 时该字段为空")
private String newText; private String newText;
/** /**
* 任务发起人姓名 * 任务发起人姓名
*/ */
@ApiModelProperty("任务发起人姓名")
private String taskInitiator; private String taskInitiator;
/** /**
* 任务发起人部门 * 任务发起人部门
*/ */
@ApiModelProperty("任务发起人部门")
private String taskInitiatorDept; private String taskInitiatorDept;
/** /**
* 任务发起人Id * 任务发起人Id
*/ */
@ApiModelProperty("任务发起人Id")
private Long taskInitiatorId; private Long taskInitiatorId;
/** /**
* 任务状态(PENDING、FINISH、CLOSE) * 任务状态(PENDING、FINISH、CLOSE)
*/ */
@ApiModelProperty("任务状态(PENDING、FINISH、CLOSE)")
private String taskStatus; private String taskStatus;
/** /**
* 任务结果(PASS、REJECT) * 任务结果(PASS、REJECT)
*/ */
@ApiModelProperty("任务结果(PASS、REJECT)")
private String taskResult; private String taskResult;
/** /**
* 任务开始时间 * 任务开始时间
*/ */
@ApiModelProperty("任务开始时间")
private Date taskBeginTime; private Date taskBeginTime;
/** /**
* 任务结束时间 * 任务结束时间
*/ */
@ApiModelProperty("任务结束时间")
private Date taskEndTime; private Date taskEndTime;
/** /**
* 备注 * 备注
*/ */
@ApiModelProperty("备注")
private String remark; private String remark;
/** /**
...@@ -112,10 +135,12 @@ public class ReviewSceneChangeTaskResponse { ...@@ -112,10 +135,12 @@ public class ReviewSceneChangeTaskResponse {
* 若为修改、删除任务时,此id在创建任务时赋值 * 若为修改、删除任务时,此id在创建任务时赋值
* 若为新增任务时,此id在审批通过并保存新场景后赋值 * 若为新增任务时,此id在审批通过并保存新场景后赋值
*/ */
@ApiModelProperty("审查场景id")
private Long reviewSceneId; private Long reviewSceneId;
/** /**
* 本人审核意见(PASS、REJECT) * 本人审核意见(PASS、REJECT)
*/ */
@ApiModelProperty("本人审核意见(PASS、REJECT)")
private String decision; private String decision;
} }
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