Bläddra i källkod

工作台任务列表添加sn号返参

tags/v1.3.1
chengwang 1 år sedan
förälder
incheckning
61272a817c
5 ändrade filer med 18 tillägg och 10 borttagningar
  1. +0
    -1
      tuoheng-service/tuoheng-admin/src/main/java/com/tuoheng/admin/controller/InspectionController.java
  2. +5
    -0
      tuoheng-service/tuoheng-admin/src/main/java/com/tuoheng/admin/entity/Inspection.java
  3. +4
    -7
      tuoheng-service/tuoheng-admin/src/main/java/com/tuoheng/admin/service/inspection/query/QueryInspectionCardListService.java
  4. +5
    -0
      tuoheng-service/tuoheng-admin/src/main/java/com/tuoheng/admin/vo/inspection/InspectionCardVo.java
  5. +4
    -2
      tuoheng-service/tuoheng-admin/src/main/resources/mapper/InspectionMapper.xml

+ 0
- 1
tuoheng-service/tuoheng-admin/src/main/java/com/tuoheng/admin/controller/InspectionController.java Visa fil

@@ -30,7 +30,6 @@ public class InspectionController {
*/
@GetMapping("/list")
public JsonResult inspectionCardList(){
// log.info("进入查询巡检任务列表接口");
return iInspectionService.inspectionCardList();
}


+ 5
- 0
tuoheng-service/tuoheng-admin/src/main/java/com/tuoheng/admin/entity/Inspection.java Visa fil

@@ -88,6 +88,11 @@ public class Inspection extends BaseEntity {
*/
private Long airportId;

/**
* 机场sn
*/
private String sn;

/**
* 巡检无人机id
*/

+ 4
- 7
tuoheng-service/tuoheng-admin/src/main/java/com/tuoheng/admin/service/inspection/query/QueryInspectionCardListService.java Visa fil

@@ -68,22 +68,19 @@ public class QueryInspectionCardListService {
*/
public JsonResult getInspectionCardList() {
//根据当前登录用户获取数据权限信息
String userId = CurrentUserUtil.getUserId();
User user = CurrentUserUtil.getUserInfo();
String userId = user.getId();
if(StringUtils.isEmpty(userId)){
return JsonResult.error(QueryUserInfoByIdCodeEnum.USER_ID_IS_NULL.getCode()
,QueryUserInfoByIdCodeEnum.USER_ID_IS_NULL.getMsg());
}
String tenantId = CurrentUserUtil.getTenantId();
String tenantId = user.getTenantId();
if(StringUtils.isEmpty(tenantId)){
return JsonResult.error(QueryUserInfoByIdCodeEnum.USER_TENANT_ID_NULL.getCode()
,QueryUserInfoByIdCodeEnum.USER_TENANT_ID_NULL.getMsg());
}
Tenant tenant = tenantMapper.selectById(tenantId);
User user = userMapper.selectById(userId);
if(ObjectUtil.isNull(user)){
return JsonResult.error(QueryUserInfoByIdCodeEnum.USER_IS_NOT_EXIST.getCode(),
QueryUserInfoByIdCodeEnum.USER_IS_NOT_EXIST.getMsg());
}

//部门
Dept dept = deptMapper.selectById(user.getDeptId());
if(ObjectUtil.isNull(dept)){

+ 5
- 0
tuoheng-service/tuoheng-admin/src/main/java/com/tuoheng/admin/vo/inspection/InspectionCardVo.java Visa fil

@@ -100,4 +100,9 @@ public class InspectionCardVo {
*/
private String accidentId;

/**
* 机场sn号
*/
private String sn;

}

+ 4
- 2
tuoheng-service/tuoheng-admin/src/main/resources/mapper/InspectionMapper.xml Visa fil

@@ -17,6 +17,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<result property="legName" column="leg_name" />
<result property="inspectionType" column="inspection_type" />
<result property="recordId" column="record_id" />
<result property="sn" column="sn" />
<result property="airportId" column="airport_id" />
<result property="airportName" column="airport_name" />
<result property="droneId" column="drone_id" />
@@ -67,7 +68,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"

<sql id="Base_Column_list">
id, tenant_id, dept_id, code, name, type, channel_id, channel_name, leg_id, leg_name, inspection_type,
record_id, airport_id, airport_name, drone_id, inspection_line, inspection_line_name, equipment_id, equipment_name, equipment_mount_id,
record_id, airport_id, sn, airport_name, drone_id, inspection_line, inspection_line_name, equipment_id, equipment_name, equipment_mount_id,
equipment_mount_name, cloud_box_id, cloud_box_name, box_sn, flight_hand, flight_hand_name, inspection_time,
execution_start_time, execution_end_time, is_live, is_taken, is_tilt, video_url, ai_video_url, report_url, srt_url,
status, analyse_status, progressbar, note, weather, fly_height, srt_name, heartbeat_time, execution_status,
@@ -77,7 +78,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"

<sql id="selectInspectionVo">
select id, tenant_id, dept_id, code, name, type, channel_id, channel_name, leg_id, leg_name, inspection_type,
record_id, airport_id, airport_name, drone_id, inspection_line, inspection_line_name, equipment_id, equipment_name, equipment_mount_id,
record_id, airport_id, sn, airport_name, drone_id, inspection_line, inspection_line_name, equipment_id, equipment_name, equipment_mount_id,
equipment_mount_name, cloud_box_id, cloud_box_name, box_sn, flight_hand, flight_hand_name, inspection_time,
execution_start_time, execution_end_time, is_live, is_taken, is_tilt, video_url, ai_video_url, report_url, srt_url,
status, analyse_status, progressbar, note, weather, fly_height, srt_name, heartbeat_time, execution_status,
@@ -146,6 +147,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="legName != null">leg_name = #{legName},</if>
<if test="recordId != null"> record_id = #{RecordId},</if>
<if test="airportId != null">airport_id = #{airportId},</if>
<if test="sn != null">sn = #{sn},</if>
<if test="airportName != null">airport_name = #{airportName},</if>
<if test="droneId != null"> drone_id = #{droneId},</if>
<if test="inspectionLine != null">inspection_line = #{inspectionLine},</if>

Laddar…
Avbryt
Spara