소스 검색

Merge branch 'develop' of gitadmin/tuoheng_telecomumale into release

tags/v1.3.1
wanjing 1 년 전
부모
커밋
ceccc414c7
5개의 변경된 파일11개의 추가작업 그리고 42개의 파일을 삭제
  1. +7
    -0
      tuoheng-service/tuoheng-admin/src/main/java/com/tuoheng/admin/tzhl/service/fly/log/FlyLogByNormalService.java
  2. +1
    -11
      tuoheng-service/tuoheng-miniprogram/src/main/java/com/tuoheng/miniprogram/service/impl/IUserServiceImpl.java
  3. +1
    -11
      tuoheng-service/tuoheng-miniprogram/src/main/java/com/tuoheng/miniprogram/service/impl/InspectionFileHandleServiceImpl.java
  4. +1
    -8
      tuoheng-service/tuoheng-miniprogram/src/main/java/com/tuoheng/miniprogram/service/impl/InspectionServiceImpl.java
  5. +1
    -12
      tuoheng-service/tuoheng-miniprogram/src/main/java/com/tuoheng/miniprogram/service/impl/WorkOrderServiceImpl.java

+ 7
- 0
tuoheng-service/tuoheng-admin/src/main/java/com/tuoheng/admin/tzhl/service/fly/log/FlyLogByNormalService.java 파일 보기

@@ -6,6 +6,7 @@ import com.tuoheng.admin.entity.InspectionHistory;
import com.tuoheng.admin.enums.InspectionStatusEnum;
import com.tuoheng.admin.mapper.InspectionHistoryMapper;
import com.tuoheng.admin.mapper.InspectionMapper;
import com.tuoheng.admin.service.report.generate.GenerateReportService;
import com.tuoheng.admin.service.third.dsp.IDspService;
import com.tuoheng.admin.tzhl.response.TZHLFlyLogResponse;
import com.tuoheng.admin.tzhl.service.fly.data.FlyDataService;
@@ -47,6 +48,9 @@ public class FlyLogByNormalService {
@Autowired
private FlyDataService flyDataService;

@Autowired
private GenerateReportService generateReportService;

public void getFlyLog(Inspection inspection, TZHLFlyLogResponse flyLogResponse) {
log.info("获取飞行日志,status=normal,title={}", flyLogResponse.getTitle());

@@ -129,6 +133,9 @@ public class FlyLogByNormalService {

this.updateInspection(inspection);

// 任务完成后自动生成报告
generateReportService.generateByAuto(inspection);

// 拉取飞行数据
flyDataService.getFlyData(inspection);


+ 1
- 11
tuoheng-service/tuoheng-miniprogram/src/main/java/com/tuoheng/miniprogram/service/impl/IUserServiceImpl.java 파일 보기

@@ -53,17 +53,7 @@ public class IUserServiceImpl extends ServiceImpl<UserMapper, User> implements I
@Override
public JsonResult getUserInfo() {
//登录用户信息
User userInfo = CurrentUserUtil.getUserInfo();
String username = userInfo.getUsername();
if(StringUtils.isEmpty(username)){
return JsonResult.error(UserCodeEnum.USER_NAME_IS_NULL.getCode(),UserCodeEnum.USER_NAME_IS_NULL.getMsg());
}
User user = userMapper.selectOne(new LambdaQueryWrapper<User>()
.eq(User::getUsername, username)
.eq(User::getMark, MarkEnum.VALID.getCode()));
if(ObjectUtil.isNull(user)){
return JsonResult.error(UserCodeEnum.USER_IS_NULL.getCode(),UserCodeEnum.USER_IS_NULL.getMsg());
}
User user = CurrentUserUtil.getUserInfo();
if(2== user.getStatus()){
return JsonResult.error(UserCodeEnum.USER_STATUS_INTERDICT.getCode(),UserCodeEnum.USER_STATUS_INTERDICT.getMsg());
}

+ 1
- 11
tuoheng-service/tuoheng-miniprogram/src/main/java/com/tuoheng/miniprogram/service/impl/InspectionFileHandleServiceImpl.java 파일 보기

@@ -53,17 +53,7 @@ public class InspectionFileHandleServiceImpl implements IInspectionFileHandleSer
@Override
public JsonResult uploadResult(UploadResultDto dto) {
//登录用户信息
User userInfo = CurrentUserUtil.getUserInfo();
String username = userInfo.getUsername();
if(StringUtils.isEmpty(username)){
return JsonResult.error(InspectionFileHandleEnum.USER_NAME_IS_NULL.getCode(),InspectionFileHandleEnum.USER_NAME_IS_NULL.getMsg());
}
User user = userMapper.selectOne(Wrappers.<User>lambdaQuery()
.eq(User::getMark, MarkEnum.VALID.getCode())
.eq(User::getUsername, username));
if(ObjectUtil.isNull(user)){
return JsonResult.error(InspectionFileHandleEnum.USER_IS_NOT_EXIST.getCode(),InspectionFileHandleEnum.USER_IS_NOT_EXIST.getMsg());
}
User user = CurrentUserUtil.getUserInfo();
if(StringUtils.isEmpty(user.getId())){
return JsonResult.error(InspectionFileHandleEnum.USER_ID_IS_NULL.getCode(),InspectionFileHandleEnum.USER_ID_IS_NULL.getMsg());
}

+ 1
- 8
tuoheng-service/tuoheng-miniprogram/src/main/java/com/tuoheng/miniprogram/service/impl/InspectionServiceImpl.java 파일 보기

@@ -63,14 +63,7 @@ public class InspectionServiceImpl implements IInspectionService {
throw new ServiceException(ServiceExceptionEnum.PARAMETER_IS_NULL);
}
//登录用户信息
User userInfo = CurrentUserUtil.getUserInfo();
String username = userInfo.getUsername();
User user = userMapper.selectOne(Wrappers.<User>lambdaQuery()
.eq(StringUtils.isNotEmpty(username), User::getUsername, username)
.eq(User::getStatus, 1).eq(User::getMark, MarkEnum.VALID.getCode()));
if(ObjectUtil.isNull(user)){
return null;
}
User user = CurrentUserUtil.getUserInfo();
String tenantId = user.getTenantId();
if(StringUtils.isEmpty(tenantId)){
return null;

+ 1
- 12
tuoheng-service/tuoheng-miniprogram/src/main/java/com/tuoheng/miniprogram/service/impl/WorkOrderServiceImpl.java 파일 보기

@@ -880,17 +880,7 @@ public class WorkOrderServiceImpl extends BaseServiceImpl<WorkOrderMapper, WorkO
@Override
public JsonResult mothCount() {
//获取登录用户信息
User userInfo = CurrentUserUtil.getUserInfo();
String username = userInfo.getUsername();
if (StringUtils.isEmpty(username)) {
return JsonResult.error(WorkOrderEnum.USER_NAME_IS_NULL.getCode(), WorkOrderEnum.USER_NAME_IS_NULL.getMsg());
}
User user = userMapper.selectOne(Wrappers.<User>lambdaQuery()
.eq(User::getMark, MarkEnum.VALID.getCode())
.eq(User::getUsername, username));
if (ObjectUtil.isNull(user)) {
return JsonResult.error(WorkOrderEnum.USER_IS_NOT_EXIST.getCode(), WorkOrderEnum.USER_IS_NOT_EXIST.getMsg());
}
User user = CurrentUserUtil.getUserInfo();
String tenantId = user.getTenantId();
if (StringUtils.isEmpty(tenantId)) {
return JsonResult.error(WorkOrderEnum.TENANT_ID_IS_NULL.getCode(), WorkOrderEnum.TENANT_ID_IS_NULL.getMsg());
@@ -915,7 +905,6 @@ public class WorkOrderServiceImpl extends BaseServiceImpl<WorkOrderMapper, WorkO
if (null == endTime || null == beginTime) {
return null;
}
//根据用户角色判断 1超级管理员 2部门管理员 3普通用户
if (RoleEnum.SUPER_ADMIN.getCode() == type) {
//获取当前登录用户(超级管理员)已完成工单列表
List<WorkOrder> workOrders = workOrderMapper.selectList(Wrappers.<WorkOrder>lambdaQuery()

Loading…
취소
저장