@@ -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); | |||
} | |||
} |
@@ -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); | |||
} | |||
} |
@@ -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; |
@@ -55,4 +55,10 @@ public interface IAccidentService extends IBaseService<Accident> { | |||
*/ | |||
JsonResult getTips(String accidentId); | |||
/** | |||
* 事故时间轴 | |||
* @param accidentId | |||
* @return | |||
*/ | |||
JsonResult getTimeAxis(String accidentId); | |||
} |
@@ -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; | |||
} | |||
} |
@@ -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; | |||
} |
@@ -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; | |||
} |