ソースを参照

事故时间轴接口

tags/v1.2.0^2
chengwang 1年前
コミット
ab6ed1c60e
7個のファイルの変更121行の追加2行の削除
  1. +10
    -0
      tuoheng-service/tuoheng-admin/src/main/java/com/tuoheng/admin/controller/AccidentController.java
  2. +8
    -1
      tuoheng-service/tuoheng-admin/src/main/java/com/tuoheng/admin/service/accident/AccidentServiceImpl.java
  3. +1
    -1
      tuoheng-service/tuoheng-admin/src/main/java/com/tuoheng/admin/service/accident/AccidentTipsService.java
  4. +6
    -0
      tuoheng-service/tuoheng-admin/src/main/java/com/tuoheng/admin/service/accident/IAccidentService.java
  5. +23
    -0
      tuoheng-service/tuoheng-admin/src/main/java/com/tuoheng/admin/service/accident/TimeAxisService.java
  6. +22
    -0
      tuoheng-service/tuoheng-admin/src/main/java/com/tuoheng/admin/vo/accident/AccidentPromptlyLookVo.java
  7. +51
    -0
      tuoheng-service/tuoheng-admin/src/main/java/com/tuoheng/admin/vo/accident/AccidentTimeAxisVo.java

+ 10
- 0
tuoheng-service/tuoheng-admin/src/main/java/com/tuoheng/admin/controller/AccidentController.java ファイルの表示

@@ -77,5 +77,15 @@ public class AccidentController {
return accidentService.getTips(accidentId);
}

/**
* 事故时间轴
* @param accidentId
* @return
*/
@GetMapping("/timeAxis/{accidentId}")
public JsonResult getTimeAxis(@PathVariable("accidentId") String accidentId){
return accidentService.getTimeAxis(accidentId);
}


}

+ 8
- 1
tuoheng-service/tuoheng-admin/src/main/java/com/tuoheng/admin/service/accident/AccidentServiceImpl.java ファイルの表示

@@ -4,7 +4,6 @@ import com.tuoheng.admin.entity.Accident;
import com.tuoheng.admin.mapper.AccidentMapper;
import com.tuoheng.admin.query.AccidentQuery;
import com.tuoheng.admin.request.accident.QueryAccidentPageListRequest;
import com.tuoheng.admin.service.AccidentTipsService;
import com.tuoheng.admin.service.accident.query.QueryAccidentByIdService;
import com.tuoheng.admin.service.accident.query.QueryAccidentDetailsService;
import com.tuoheng.admin.service.accident.query.QueryAccidentPageListService;
@@ -37,6 +36,9 @@ public class AccidentServiceImpl extends BaseServiceImpl<AccidentMapper, Acciden
@Autowired
private AccidentTipsService accidentTipsService;

@Autowired
private TimeAxisService timeAxisService;

@Override
public JsonResult getPageList(QueryAccidentPageListRequest request) {
return queryAccidentPageListService.getPageList(request);
@@ -66,4 +68,9 @@ public class AccidentServiceImpl extends BaseServiceImpl<AccidentMapper, Acciden
public JsonResult getTips(String accidentId) {
return accidentTipsService.getTips(accidentId);
}

@Override
public JsonResult getTimeAxis(String accidentId) {
return timeAxisService.getTimeAxis(accidentId);
}
}

tuoheng-service/tuoheng-admin/src/main/java/com/tuoheng/admin/service/AccidentTipsService.java → tuoheng-service/tuoheng-admin/src/main/java/com/tuoheng/admin/service/accident/AccidentTipsService.java ファイルの表示

@@ -1,4 +1,4 @@
package com.tuoheng.admin.service;
package com.tuoheng.admin.service.accident;

import com.baomidou.mybatisplus.core.toolkit.ObjectUtils;
import com.baomidou.mybatisplus.core.toolkit.Wrappers;

+ 6
- 0
tuoheng-service/tuoheng-admin/src/main/java/com/tuoheng/admin/service/accident/IAccidentService.java ファイルの表示

@@ -55,4 +55,10 @@ public interface IAccidentService extends IBaseService<Accident> {
*/
JsonResult getTips(String accidentId);

/**
* 事故时间轴
* @param accidentId
* @return
*/
JsonResult getTimeAxis(String accidentId);
}

+ 23
- 0
tuoheng-service/tuoheng-admin/src/main/java/com/tuoheng/admin/service/accident/TimeAxisService.java ファイルの表示

@@ -0,0 +1,23 @@
package com.tuoheng.admin.service.accident;

import com.tuoheng.common.core.utils.JsonResult;
import lombok.extern.slf4j.Slf4j;
import org.springframework.stereotype.Service;

/**
* @Author ChengWang
* @Date 2023/3/15
*/
@Slf4j
@Service
public class TimeAxisService {

/**
* 事故时间轴
* @param accidentId
* @return
*/
public JsonResult getTimeAxis(String accidentId) {
return null;
}
}

+ 22
- 0
tuoheng-service/tuoheng-admin/src/main/java/com/tuoheng/admin/vo/accident/AccidentPromptlyLookVo.java ファイルの表示

@@ -0,0 +1,22 @@
package com.tuoheng.admin.vo.accident;

import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;
import org.springframework.format.annotation.DateTimeFormat;

import java.util.Date;

/**
* @Author ChengWang
* @Date 2023/3/15
*/
@Data
public class AccidentPromptlyLookVo {

/**
* 立即查看
*/
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
private Date LookNowTime;
}

+ 51
- 0
tuoheng-service/tuoheng-admin/src/main/java/com/tuoheng/admin/vo/accident/AccidentTimeAxisVo.java ファイルの表示

@@ -0,0 +1,51 @@
package com.tuoheng.admin.vo.accident;

import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;
import org.springframework.format.annotation.DateTimeFormat;

import java.util.Date;
import java.util.List;

/**
* @Author ChengWang
* @Date 2023/3/15
*/
@Data
public class AccidentTimeAxisVo {

/**
*事故发生时间
*/
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
private Date createTime;

/**
* 立即查看时间集合形式
*/
private List<AccidentPromptlyLookVo> LookTimeList;

/**
* 核实时间
*/
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
private Date VerificationTime;

/**
* 上报时间
*/
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
private Date ReportingTime;

/**
* 事故结束时间
*/
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
private Date endTime;


}

読み込み中…
キャンセル
保存