Browse Source

Merge branch 'develop' of gitadmin/tuoheng_freeway into release

tags/v1.0.0^2
wanjing 1 year ago
parent
commit
7b0d549b51
3 changed files with 3 additions and 15 deletions
  1. +0
    -5
      tuoheng-service/tuoheng-admin/src/main/java/com/tuoheng/admin/request/inspection/EditInspectionRequest.java
  2. +2
    -9
      tuoheng-service/tuoheng-admin/src/main/java/com/tuoheng/admin/service/inspection/resubmit/ResubmitInspectionService.java
  3. +1
    -1
      tuoheng-service/tuoheng-admin/src/main/resources/mapper/WorkOrderMapper.xml

+ 0
- 5
tuoheng-service/tuoheng-admin/src/main/java/com/tuoheng/admin/request/inspection/EditInspectionRequest.java View File

@@ -27,11 +27,6 @@ public class EditInspectionRequest {
*/
private String userId;

/**
* 租户id
*/
private Integer tenantId;

/**
* 任务编码
*/

+ 2
- 9
tuoheng-service/tuoheng-admin/src/main/java/com/tuoheng/admin/service/inspection/resubmit/ResubmitInspectionService.java View File

@@ -54,20 +54,13 @@ public class ResubmitInspectionService {
*/
public JsonResult resubmit(EditInspectionRequest request) {
log.info("进入重新提交任务业务");
String userId = CurrentUserUtil.getUserId();
String tenantId = CurrentUserUtil.getTenantId();
User user = CurrentUserUtil.getUserInfo();
String tenantId = user.getTenantId();
JsonResult result = this.checkParam(tenantId, request);
if (0 != result.getCode()) {
log.info("重新提交任务业务:校验参数失败:{}", result.getMsg());
return result;
}
User user = userMapper.selectOne(new LambdaQueryWrapper<User>()
.eq(User::getTenantId, tenantId)
.eq(User::getId, userId)
.eq(User::getMark, 1));
if (null == user) {
return JsonResult.error(ResubmitInspectionCodeEnum.USER_IS_NOT_EXIST.getCode(), ResubmitInspectionCodeEnum.USER_IS_NOT_EXIST.getMsg());
}
// 构造inspection对象
result = this.buildInspection(user, tenantId, request);
if (0 != result.getCode()) {

+ 1
- 1
tuoheng-service/tuoheng-admin/src/main/resources/mapper/WorkOrderMapper.xml View File

@@ -47,7 +47,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<where>
<if test="1 == 1"> and mark = 1 </if>
<if test="request.tenantId != null and request.tenantId != ''"> and tenant_id = #{request.tenantId} </if>
<if test="request.code != null and request.code != 0"> and code = #{request.code} </if>
<if test="request.code != null and request.code != ''"> and code = #{request.code} </if>
<if test="request.status != null and request.status != ''"> and status = #{request.status} </if>
<if test="(request.userDeptId != null and request.userDeptId != '') or (request.deptIdList != null and request.deptIdList.size() > 0)">
and (

Loading…
Cancel
Save