1. 待初审,待复审, 归档 以及全部
This commit is contained in:
parent
8805b6838c
commit
267dd281ea
|
|
@ -62,8 +62,11 @@ public class ReviewedQuery extends CommonParam {
|
|||
|
||||
/**
|
||||
* 工单状态
|
||||
* 2 待初审,
|
||||
* 3 待复审
|
||||
* 4 归档
|
||||
* null 全部
|
||||
*/
|
||||
@Condition(name = "wrk_status", tableName = "i")
|
||||
@Range(min = 1, max = 6, message = "工单状态非法")
|
||||
private Integer wrkStatus;
|
||||
|
||||
|
|
|
|||
|
|
@ -33,7 +33,7 @@ public class TerminalController {
|
|||
* 商户终端池
|
||||
* @param query 条件
|
||||
*/
|
||||
@SysLog(value = "终端池", businessType = BusinessType.QUERY)
|
||||
@SysLog(value = "终端商户池", businessType = BusinessType.QUERY)
|
||||
@GetMapping("/page")
|
||||
@RequiresPermissions("ins:terminal:page")
|
||||
public AjaxResult pageList(@Validated TerminalQuery query) {
|
||||
|
|
|
|||
|
|
@ -62,14 +62,25 @@ public class WrkInfoController {
|
|||
@SysLog(value = "待审核列表", businessType = BusinessType.QUERY)
|
||||
@GetMapping("/review/page")
|
||||
@RequiresPermissions("wrk:reviewed:page")
|
||||
public AjaxResult queryToDeReviewedPage(@Validated ReviewedQuery query) {
|
||||
Integer reviewMethod = TaskConfigUtils.reviewMethod(query.getTaskId());
|
||||
Assert.isTrue(reviewMethod != 1, "审核方式为无需审核,无法进入次页面");
|
||||
List<Integer> status = ListUtil.toList(2, 5);
|
||||
if (reviewMethod == 3) {
|
||||
status.add(3);
|
||||
status.add(6);
|
||||
public AjaxResult queryToDeReviewedPage(@Validated ReviewedQuery query)
|
||||
{
|
||||
Integer wrkStatus = query.getWrkStatus();
|
||||
List<Integer> status = new ArrayList<>();
|
||||
// 待初审
|
||||
if (2 == wrkStatus){
|
||||
status.add(2);
|
||||
}
|
||||
// 待复审, 应当查询审核方式为复审, 同时审核通过人员
|
||||
else if (3 == wrkStatus){
|
||||
status.add(3);
|
||||
}
|
||||
// 归档, 审核通过, 应当查询 审核方式为初审, 审核通过, 审核方式为复审, 审核通过
|
||||
else if (4 == wrkStatus){
|
||||
status.add(4);
|
||||
status.add(7);
|
||||
status.add(8);
|
||||
}
|
||||
// 否则就是获取全部
|
||||
query.setStates(status);
|
||||
return AjaxResult.success(wrkInfoService.queryArchivePage(query));
|
||||
}
|
||||
|
|
|
|||
|
|
@ -16,6 +16,18 @@ public class WrkInfoAuditServiceImpl extends ServiceImpl<WrkInfoAuditMapper, Wrk
|
|||
/**
|
||||
* 工单审核
|
||||
* @param audit 审核所需
|
||||
* 工单共计有7个状态,
|
||||
* 1. 已分配
|
||||
* 2. 待初审
|
||||
* 3. 待复审
|
||||
* 4. 复审通过
|
||||
* 5. 初审驳回
|
||||
* 6. 复审驳回
|
||||
* 7. 初审通过
|
||||
* 8. 默认审核通过
|
||||
* todo 当任务为只需要初审时, 点击初审通过, 则其状态由2 变为 7
|
||||
* todo 当任务需要复审时, 点击初审通过, 其状态由2 变为3
|
||||
* 当任务不需要审核时, 点击提交, 工单状态, 由1 变为8
|
||||
*/
|
||||
@Override
|
||||
public void audit(AuditDTO audit) {
|
||||
|
|
|
|||
|
|
@ -275,6 +275,9 @@ public class WrkInfoServiceImpl extends ServiceImpl<WrkInfoMapper, WrkInfo> impl
|
|||
|
||||
// 无需审核, 此处改变下 终端以及对应的商户信息
|
||||
if (reviewMethod == 1) {
|
||||
// 无需审核, 工单状态直接变为8
|
||||
tempStorageWrkInfo.setWrkStatus(8);
|
||||
|
||||
// 此处应当修改 商户记录表
|
||||
// // 1. 修改工单
|
||||
Assert.notNull(wrkInfo, "请确认此工单是否存在");
|
||||
|
|
@ -318,27 +321,8 @@ public class WrkInfoServiceImpl extends ServiceImpl<WrkInfoMapper, WrkInfo> impl
|
|||
terminalInsService.saveOrUpdate(terminalIns);
|
||||
// 还需要 更改 记录表对应的数据.
|
||||
}
|
||||
// 需要初审
|
||||
else if (reviewMethod == 2) {
|
||||
AssertUtil.invalidate(wrkInfo.getWrkStatus().equals(1) || wrkInfo.getWrkStatus().equals(5),
|
||||
String.format("【%s】此状态无法提交,指定的审核方式为初审,只有已分配和初审拒绝可以提交",
|
||||
DictUtils.getDictLabel("wrk_status",wrkInfo.getWrkStatus()+""))
|
||||
);
|
||||
tempStorageWrkInfo.setWrkStatus(2);
|
||||
}
|
||||
// 需要复审
|
||||
else if (reviewMethod == 3){
|
||||
Assert.isFalse(ListUtil.toList(2, 3, 4).contains(wrkInfo.getWrkStatus()),
|
||||
String.format("【%s】此状态无法提交,指定的审核方式为复审,只有已分配,初审拒绝或复审拒绝可以提交",
|
||||
DictUtils.getDictWrkStatusLabel(wrkInfo.getWrkStatus()+""))
|
||||
);
|
||||
// 审核(处,复)拒绝 都需要初审
|
||||
if (ListUtil.toList(1, 5, 6).contains(wrkInfo.getWrkStatus())) {
|
||||
tempStorageWrkInfo.setWrkStatus(2);
|
||||
} else {
|
||||
tempStorageWrkInfo.setWrkStatus(3);
|
||||
}
|
||||
}
|
||||
// 此时的 审核工单状态应当为待初审
|
||||
tempStorageWrkInfo.setWrkStatus(2);
|
||||
// 偏差
|
||||
Long deviation = StrUtil.isNotEmpty(tempStorageTerminalInsRecord.getGeographicLocation())
|
||||
? distance(tempStorageTerminalInsRecord.getGeographicLocation(), tempStorageTerminalInsRecord.getWorkLocation()) : null;
|
||||
|
|
|
|||
Loading…
Reference in New Issue