haungxing
10 months ago
94 changed files with 1940 additions and 659 deletions
@ -0,0 +1,68 @@
|
||||
package com.hnac.hzims.safeproduct.entity; |
||||
|
||||
import com.baomidou.mybatisplus.annotation.TableName; |
||||
import io.swagger.annotations.ApiModel; |
||||
import io.swagger.annotations.ApiModelProperty; |
||||
import lombok.Data; |
||||
import lombok.EqualsAndHashCode; |
||||
import org.springblade.core.mp.base.BaseEntity; |
||||
|
||||
import javax.validation.constraints.Size; |
||||
import java.util.Date; |
||||
|
||||
/** |
||||
* @author liwen |
||||
* @date 2024-01-12 |
||||
*/ |
||||
@Data |
||||
@EqualsAndHashCode(callSuper = true) |
||||
@TableName("hzims_device") |
||||
@ApiModel(value = "特种设备实体类") |
||||
public class DeviceEntity extends BaseEntity { |
||||
|
||||
@Size(max = 50, message = "设备名称长度不能超过50") |
||||
@ApiModelProperty("设备名称") |
||||
private String name; |
||||
|
||||
@Size(max = 50, message = "规格型号长度不能超过50") |
||||
@ApiModelProperty("规格型号") |
||||
private String type; |
||||
|
||||
@Size(max = 50, message = "设备编码长度不能超过50") |
||||
@ApiModelProperty("设备编码") |
||||
private String code; |
||||
|
||||
@Size(max = 255, message = "产品合格证号长度不能超过255") |
||||
@ApiModelProperty("产品合格证号") |
||||
private String qualityCertificateNo; |
||||
|
||||
@ApiModelProperty("生产日期") |
||||
private Date productionTime; |
||||
|
||||
@ApiModelProperty("使用时间") |
||||
private Date usedTime; |
||||
|
||||
@Size(max = 255, message = "使用地点长度不能超过255") |
||||
@ApiModelProperty("使用地点") |
||||
private String usedLocation; |
||||
|
||||
@ApiModelProperty("检验周期") |
||||
private Integer inspectionPeriod; |
||||
|
||||
@ApiModelProperty("本次检验日期") |
||||
private Date inspectionCurrentTime; |
||||
|
||||
@ApiModelProperty("下次检验日期") |
||||
private Date inspectionNextTime; |
||||
|
||||
@ApiModelProperty("上次检验日期") |
||||
private Date inspectionLastTime; |
||||
|
||||
@Size(max = 50, message = "设备管理人长度不能超过50") |
||||
@ApiModelProperty("设备管理人") |
||||
private String manager; |
||||
|
||||
@Size(max = 20, message = "设备状态长度不能超过20") |
||||
@ApiModelProperty("设备状态") |
||||
private String deviceStatus; |
||||
} |
@ -0,0 +1,30 @@
|
||||
package com.hnac.hzims.safeproduct.enums; |
||||
|
||||
/** |
||||
* 车辆维保类型枚举类 |
||||
* |
||||
* @author liwen |
||||
* @date 2024-01-16 |
||||
*/ |
||||
public enum CarMaintenanceTypeEnum { |
||||
|
||||
MAINTAIN("MAINTAIN", "保养"), |
||||
REPAIR("REPAIR", "维修"); |
||||
|
||||
private final String value; |
||||
|
||||
private final String desc; |
||||
|
||||
CarMaintenanceTypeEnum(String value, String desc) { |
||||
this.value = value; |
||||
this.desc = desc; |
||||
} |
||||
|
||||
public String getValue() { |
||||
return value; |
||||
} |
||||
|
||||
public String getDesc() { |
||||
return desc; |
||||
} |
||||
} |
@ -0,0 +1,30 @@
|
||||
package com.hnac.hzims.safeproduct.enums; |
||||
|
||||
/** |
||||
* 特种设备状态枚举类 |
||||
* |
||||
* @author liwen |
||||
* @date 2024-01-16 |
||||
*/ |
||||
public enum DeviceStatusEnum { |
||||
|
||||
NORMAL("NORMAL", "正常"), |
||||
EXPIRED("EXPIRED", "待检修"); |
||||
|
||||
private final String value; |
||||
|
||||
private final String desc; |
||||
|
||||
DeviceStatusEnum(String value, String desc) { |
||||
this.value = value; |
||||
this.desc = desc; |
||||
} |
||||
|
||||
public String getValue() { |
||||
return value; |
||||
} |
||||
|
||||
public String getDesc() { |
||||
return desc; |
||||
} |
||||
} |
@ -0,0 +1,31 @@
|
||||
package com.hnac.hzims.safeproduct.enums; |
||||
|
||||
/** |
||||
* 培训方式枚举类 |
||||
* |
||||
* @author liwen |
||||
* @date 2024-01-15 |
||||
*/ |
||||
public enum TrainMethodEnum { |
||||
|
||||
ONLINE("ONLINE", "线上"), |
||||
OFFLINE("OFFLINE", "线下"), |
||||
MIXED("MIXED", "线上+线下"); |
||||
|
||||
private final String value; |
||||
|
||||
private final String desc; |
||||
|
||||
TrainMethodEnum(String value, String desc) { |
||||
this.value = value; |
||||
this.desc = desc; |
||||
} |
||||
|
||||
public String getValue() { |
||||
return value; |
||||
} |
||||
|
||||
public String getDesc() { |
||||
return desc; |
||||
} |
||||
} |
@ -0,0 +1,55 @@
|
||||
package com.hnac.hzims.safeproduct.vo; |
||||
|
||||
import io.swagger.annotations.ApiModel; |
||||
import io.swagger.annotations.ApiModelProperty; |
||||
import lombok.Data; |
||||
|
||||
import java.util.Date; |
||||
|
||||
/** |
||||
* @author liwen |
||||
* @date 2024-01-15 |
||||
*/ |
||||
@Data |
||||
@ApiModel(value = "会议记录表VO类") |
||||
public class ConferenceRecordDetailVO { |
||||
|
||||
@ApiModelProperty("编码") |
||||
private String code; |
||||
|
||||
@ApiModelProperty("会议实际开始时间") |
||||
private Date actualStartTime; |
||||
|
||||
@ApiModelProperty("会议实际结束时间") |
||||
private Date actualEndTime; |
||||
|
||||
@ApiModelProperty("单位") |
||||
private String unit; |
||||
|
||||
@ApiModelProperty("会议地点") |
||||
private String location; |
||||
|
||||
@ApiModelProperty("主持人") |
||||
private String host; |
||||
|
||||
@ApiModelProperty("会议方式") |
||||
private String conferenceMethod; |
||||
|
||||
@ApiModelProperty("会议主题") |
||||
private String theme; |
||||
|
||||
@ApiModelProperty("记录人") |
||||
private String recorder; |
||||
|
||||
@ApiModelProperty("参会人员") |
||||
private String peopleName; |
||||
|
||||
@ApiModelProperty("会议内容") |
||||
private String content; |
||||
|
||||
@ApiModelProperty("会议图片") |
||||
private String imgPath; |
||||
|
||||
@ApiModelProperty("会议附件") |
||||
private String filePath; |
||||
} |
@ -0,0 +1,55 @@
|
||||
package com.hnac.hzims.safeproduct.vo; |
||||
|
||||
import io.swagger.annotations.ApiModel; |
||||
import io.swagger.annotations.ApiModelProperty; |
||||
import lombok.Data; |
||||
|
||||
import java.util.Date; |
||||
|
||||
/** |
||||
* @author liwen |
||||
* @date 2024-01-15 |
||||
*/ |
||||
@Data |
||||
@ApiModel(value = "演练记录表VO类") |
||||
public class RehearsalRecordDetailVO { |
||||
|
||||
@ApiModelProperty("编码") |
||||
private String code; |
||||
|
||||
@ApiModelProperty("参演人员") |
||||
private String peopleName; |
||||
|
||||
@ApiModelProperty("演练实际开始时间") |
||||
private Date actualStartTime; |
||||
|
||||
@ApiModelProperty("演练实际结束时间") |
||||
private Date actualEndTime; |
||||
|
||||
@ApiModelProperty("演练记录") |
||||
private String record; |
||||
|
||||
@ApiModelProperty("演练评价") |
||||
private String comment; |
||||
|
||||
@ApiModelProperty("演练图片") |
||||
private String imgPath; |
||||
|
||||
@ApiModelProperty("演练附件") |
||||
private String filePath; |
||||
|
||||
@ApiModelProperty("单位") |
||||
private String unit; |
||||
|
||||
@ApiModelProperty("演练地点") |
||||
private String location; |
||||
|
||||
@ApiModelProperty("总指挥") |
||||
private String commander; |
||||
|
||||
@ApiModelProperty("演练方式") |
||||
private String rehearsalMethod; |
||||
|
||||
@ApiModelProperty("演练科目") |
||||
private String subject; |
||||
} |
@ -0,0 +1,55 @@
|
||||
package com.hnac.hzims.safeproduct.vo; |
||||
|
||||
import io.swagger.annotations.ApiModel; |
||||
import io.swagger.annotations.ApiModelProperty; |
||||
import lombok.Data; |
||||
|
||||
import java.util.Date; |
||||
|
||||
/** |
||||
* @author liwen |
||||
* @date 2024-01-15 |
||||
*/ |
||||
@Data |
||||
@ApiModel(value = "培训记录表VO类") |
||||
public class TrainRecordDetailVO { |
||||
|
||||
@ApiModelProperty("编码") |
||||
private String code; |
||||
|
||||
@ApiModelProperty("实际培训开始时间") |
||||
private Date actualStartTime; |
||||
|
||||
@ApiModelProperty("实际培训结束时间") |
||||
private Date actualEndTime; |
||||
|
||||
@ApiModelProperty("单位") |
||||
private String unit; |
||||
|
||||
@ApiModelProperty("培训地点") |
||||
private String location; |
||||
|
||||
@ApiModelProperty("培训方式") |
||||
private String trainMethod; |
||||
|
||||
@ApiModelProperty("培训讲师") |
||||
private String teacher; |
||||
|
||||
@ApiModelProperty("培训课程") |
||||
private String lesson; |
||||
|
||||
@ApiModelProperty("培训学员") |
||||
private String peopleName; |
||||
|
||||
@ApiModelProperty("培训内容") |
||||
private String content; |
||||
|
||||
@ApiModelProperty("培训评价") |
||||
private String command; |
||||
|
||||
@ApiModelProperty("培训图片") |
||||
private String imgPath; |
||||
|
||||
@ApiModelProperty("培训附件") |
||||
private String filePath; |
||||
} |
@ -0,0 +1,21 @@
|
||||
package com.hnac.hzims.ticket.repair.vo; |
||||
|
||||
import io.swagger.annotations.ApiModelProperty; |
||||
import lombok.Data; |
||||
|
||||
/** |
||||
* @author ysj |
||||
*/ |
||||
@Data |
||||
public class WorkTaskContentVO { |
||||
|
||||
@ApiModelProperty(value = "工作地点") |
||||
private String location; |
||||
|
||||
@ApiModelProperty(value = "工作内容") |
||||
private String content; |
||||
|
||||
@ApiModelProperty(value = "下标") |
||||
private Integer $index; |
||||
|
||||
} |
@ -0,0 +1,101 @@
|
||||
package com.hnac.hzims.ticket.repair.vo; |
||||
|
||||
import com.fasterxml.jackson.annotation.JsonFormat; |
||||
import com.hnac.hzims.ticket.repair.entity.WorkTaskEntity; |
||||
import io.swagger.annotations.ApiModelProperty; |
||||
import lombok.Data; |
||||
import lombok.EqualsAndHashCode; |
||||
import org.springframework.format.annotation.DateTimeFormat; |
||||
|
||||
import java.util.Date; |
||||
|
||||
/** |
||||
* @author ysj |
||||
*/ |
||||
@EqualsAndHashCode(callSuper = true) |
||||
@Data |
||||
public class WorkTaskPreviewVO extends WorkTaskEntity { |
||||
|
||||
@ApiModelProperty("创建人") |
||||
private Long userId; |
||||
|
||||
@ApiModelProperty("创建部门") |
||||
private Long deptId; |
||||
|
||||
@ApiModelProperty("创建时间") |
||||
@DateTimeFormat( |
||||
pattern = "yyyy-MM-dd HH:mm:ss" |
||||
) |
||||
@JsonFormat( |
||||
pattern = "yyyy-MM-dd HH:mm:ss" |
||||
) |
||||
private Date time; |
||||
|
||||
@ApiModelProperty(value = "单位") |
||||
private String company; |
||||
|
||||
@ApiModelProperty(value = "班组成员数量") |
||||
private Integer groupCount; |
||||
|
||||
@ApiModelProperty(value = "工作地点") |
||||
private String location; |
||||
|
||||
@ApiModelProperty(value = "工作内容") |
||||
private String content; |
||||
|
||||
@ApiModelProperty(value = "计划工作时间") |
||||
private String planTimeInterval; |
||||
|
||||
@ApiModelProperty(value = "工作派工单签发人") |
||||
private String createName; |
||||
|
||||
@ApiModelProperty(value = "签发时间: 年") |
||||
private Integer createYear; |
||||
|
||||
@ApiModelProperty(value = "签发时间: 月") |
||||
private Integer createMon; |
||||
|
||||
@ApiModelProperty(value = "签发时间: 日") |
||||
private Integer createDay; |
||||
|
||||
@ApiModelProperty(value = "签发时间: 时") |
||||
private Integer createHour; |
||||
|
||||
@ApiModelProperty(value = "签发时间: 分") |
||||
private Integer createMin; |
||||
|
||||
@ApiModelProperty(value = "开票处理时间: 年") |
||||
private Integer headYear; |
||||
|
||||
@ApiModelProperty(value = "开票处理时间: 月") |
||||
private Integer headMon; |
||||
|
||||
@ApiModelProperty(value = "开票处理时间: 日") |
||||
private Integer headDay; |
||||
|
||||
@ApiModelProperty(value = "开票处理时间: 时") |
||||
private Integer headHour; |
||||
|
||||
@ApiModelProperty(value = "开票处理时间: 分") |
||||
private Integer headMin; |
||||
|
||||
|
||||
@ApiModelProperty(value = "结束时间: 年") |
||||
private Integer endYear; |
||||
|
||||
@ApiModelProperty(value = "结束时间: 月") |
||||
private Integer endMon; |
||||
|
||||
@ApiModelProperty(value = "结束时间: 日") |
||||
private Integer endDay; |
||||
|
||||
@ApiModelProperty(value = "结束时间: 时") |
||||
private Integer endHour; |
||||
|
||||
@ApiModelProperty(value = "结束时间: 分") |
||||
private Integer endMin; |
||||
|
||||
@ApiModelProperty(value = "许可时间") |
||||
private String licensorExportTime; |
||||
|
||||
} |
@ -0,0 +1,76 @@
|
||||
package com.hnac.hzims.safeproduct.controller; |
||||
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage; |
||||
import com.github.xiaoymin.knife4j.annotations.ApiOperationSupport; |
||||
import com.hnac.hzims.common.utils.Condition; |
||||
import com.hnac.hzims.safeproduct.entity.DeviceEntity; |
||||
import com.hnac.hzims.safeproduct.service.IDeviceService; |
||||
import io.swagger.annotations.Api; |
||||
import io.swagger.annotations.ApiImplicitParam; |
||||
import io.swagger.annotations.ApiImplicitParams; |
||||
import io.swagger.annotations.ApiOperation; |
||||
import lombok.AllArgsConstructor; |
||||
import org.springblade.core.boot.ctrl.BladeController; |
||||
import org.springblade.core.mp.support.Query; |
||||
import org.springblade.core.tool.api.R; |
||||
import org.springframework.web.bind.annotation.*; |
||||
import springfox.documentation.annotations.ApiIgnore; |
||||
|
||||
import javax.validation.Valid; |
||||
import java.util.Map; |
||||
|
||||
/** |
||||
* 特种设备管理接口类 |
||||
* |
||||
* @author liwen |
||||
* @date 2024-01-12 |
||||
*/ |
||||
@RequestMapping("/device") |
||||
@AllArgsConstructor |
||||
@RestController |
||||
@Api(value = "特种设备", tags = "特种设备接口") |
||||
public class DeviceController extends BladeController { |
||||
|
||||
private final IDeviceService deviceService; |
||||
|
||||
@PostMapping("/save") |
||||
@ApiOperation(value = "新增") |
||||
@ApiOperationSupport(order = 1) |
||||
public R save(@Valid @RequestBody DeviceEntity deviceEntity) { |
||||
return R.status(deviceService.save(deviceEntity)); |
||||
} |
||||
|
||||
@PostMapping("/update") |
||||
@ApiOperation(value = "修改") |
||||
@ApiOperationSupport(order = 2) |
||||
public R update(DeviceEntity deviceEntity) { |
||||
return R.status(deviceService.updateById(deviceEntity)); |
||||
} |
||||
|
||||
@PostMapping("/remove") |
||||
@ApiOperation(value = "删除") |
||||
@ApiOperationSupport(order = 3) |
||||
public R remove(@RequestParam Long id) { |
||||
return R.status(deviceService.removeById(id)); |
||||
} |
||||
|
||||
@GetMapping("/detail") |
||||
@ApiOperation(value = "详情") |
||||
@ApiOperationSupport(order = 4) |
||||
public R<DeviceEntity> detail(@RequestParam Long id) { |
||||
return R.data(deviceService.getById(id)); |
||||
} |
||||
|
||||
@GetMapping("/page") |
||||
@ApiImplicitParams({ |
||||
@ApiImplicitParam(name = "unit", value = "单位", dataType = "query", paramType = "string"), |
||||
@ApiImplicitParam(name = "plateNumber", value = "车牌号", dataType = "query", paramType = "string") |
||||
}) |
||||
@ApiOperation(value = "分页") |
||||
@ApiOperationSupport(order = 5) |
||||
public R<IPage<DeviceEntity>> page(@ApiIgnore @RequestParam Map<String, Object> param, Query query) { |
||||
IPage<DeviceEntity> page = deviceService.page(Condition.getPage(query), Condition.getQueryWrapper(param, DeviceEntity.class) |
||||
.lambda().orderByDesc(DeviceEntity::getCreateTime)); |
||||
return R.data(page); |
||||
} |
||||
} |
@ -1,4 +1,43 @@
|
||||
package com.hnac.hzims.safeproduct.jobs; |
||||
|
||||
import com.hnac.hzims.safeproduct.entity.ConferencePlanEntity; |
||||
import com.hnac.hzims.safeproduct.enums.ConferenceStatusEnum; |
||||
import com.hnac.hzims.safeproduct.service.IConferencePlanService; |
||||
import com.xxl.job.core.biz.model.ReturnT; |
||||
import com.xxl.job.core.handler.annotation.XxlJob; |
||||
import org.springblade.core.tool.utils.DateUtil; |
||||
import org.springframework.beans.factory.annotation.Autowired; |
||||
import org.springframework.stereotype.Component; |
||||
|
||||
import java.util.Date; |
||||
import java.util.List; |
||||
|
||||
/** |
||||
* 会议管理模块定时任务 |
||||
* |
||||
* @author liwen |
||||
* @date 2024-01-15 |
||||
*/ |
||||
@Component |
||||
public class ConferenceJob { |
||||
|
||||
@Autowired |
||||
IConferencePlanService conferencePlanService; |
||||
|
||||
@XxlJob("autoChangeConferencePlanStatus") |
||||
public ReturnT<String> autoChangeConferencePlanStatus(String param) { |
||||
// 获取时间范围
|
||||
Date current = DateUtil.now(); |
||||
Date before = DateUtil.minusDays(current, 1); |
||||
String today = DateUtil.format(current, "yyyy-mm-dd hh:MM:ss"); |
||||
String yesterday = DateUtil.format(before, "yyyy-mm-dd hh:MM:ss"); |
||||
// 查询前一天的超时未完成会议计划
|
||||
List<ConferencePlanEntity> list = conferencePlanService.getWaitingConferencePlanInTimeRange(yesterday, today); |
||||
list.forEach(x -> { |
||||
x.setConferenceStatus(ConferenceStatusEnum.UNFINISHED.getValue()); |
||||
}); |
||||
// 将状态置为未完成
|
||||
boolean flag = conferencePlanService.updateBatchById(list); |
||||
return flag ? ReturnT.SUCCESS : ReturnT.FAIL; |
||||
} |
||||
} |
||||
|
@ -0,0 +1,41 @@
|
||||
package com.hnac.hzims.safeproduct.jobs; |
||||
|
||||
import com.hnac.hzims.safeproduct.entity.DeviceEntity; |
||||
import com.hnac.hzims.safeproduct.enums.DeviceStatusEnum; |
||||
import com.hnac.hzims.safeproduct.service.IDeviceService; |
||||
import com.xxl.job.core.biz.model.ReturnT; |
||||
import com.xxl.job.core.handler.annotation.XxlJob; |
||||
import org.springblade.core.tool.utils.DateUtil; |
||||
import org.springframework.beans.factory.annotation.Autowired; |
||||
import org.springframework.stereotype.Component; |
||||
|
||||
import java.util.Date; |
||||
import java.util.List; |
||||
|
||||
/** |
||||
* 特种设备模块定时任务 |
||||
* |
||||
* @author liwen |
||||
* @date 2024-01-16 |
||||
*/ |
||||
@Component |
||||
public class DeviceJob { |
||||
|
||||
@Autowired |
||||
IDeviceService deviceService; |
||||
|
||||
@XxlJob("autoChangeDeviceStatus") |
||||
public ReturnT<String> autoChangeDeviceStatus(String param) { |
||||
// 获取时间范围
|
||||
Date current = DateUtil.now(); |
||||
Date before = DateUtil.minusDays(current, 1); |
||||
String today = DateUtil.format(current, "yyyy-mm-dd"); |
||||
String yesterday = DateUtil.format(before, "yyyy-mm-dd"); |
||||
// 查询昨天的过期设备
|
||||
List<DeviceEntity> list = deviceService.getExpiredDeviceByTime(yesterday, today); |
||||
list.forEach(e -> e.setDeviceStatus(DeviceStatusEnum.EXPIRED.getValue())); |
||||
// 更新状态
|
||||
boolean update = deviceService.updateBatchById(list); |
||||
return update ? ReturnT.SUCCESS : ReturnT.FAIL; |
||||
} |
||||
} |
@ -1,4 +1,43 @@
|
||||
package com.hnac.hzims.safeproduct.jobs; |
||||
|
||||
import com.hnac.hzims.safeproduct.entity.HygienePlanEntity; |
||||
import com.hnac.hzims.safeproduct.enums.TrainStatusEnum; |
||||
import com.hnac.hzims.safeproduct.service.IHygienePlanService; |
||||
import com.xxl.job.core.biz.model.ReturnT; |
||||
import com.xxl.job.core.handler.annotation.XxlJob; |
||||
import org.springblade.core.tool.utils.DateUtil; |
||||
import org.springframework.beans.factory.annotation.Autowired; |
||||
import org.springframework.stereotype.Component; |
||||
|
||||
import java.util.Date; |
||||
import java.util.List; |
||||
|
||||
/** |
||||
* 卫生自查模块定时任务 |
||||
* |
||||
* @author liwen |
||||
* @date 2024-01-15 |
||||
*/ |
||||
@Component |
||||
public class HygieneJob { |
||||
|
||||
@Autowired |
||||
IHygienePlanService hygienePlanService; |
||||
|
||||
@XxlJob("autoChangeHygienePlanStatus") |
||||
public ReturnT<String> autoChangeHygienePlanStatus(String param) { |
||||
// 获取时间范围
|
||||
Date current = DateUtil.now(); |
||||
Date before = DateUtil.minusDays(current, 1); |
||||
String today = DateUtil.format(current, "yyyy-mm-dd hh:MM:ss"); |
||||
String yesterday = DateUtil.format(before, "yyyy-mm-dd hh:MM:ss"); |
||||
// 查询前一天的超时未完成卫生自查计划
|
||||
List<HygienePlanEntity> list = hygienePlanService.getWaitingHygienePlanInTimeRange(yesterday, today); |
||||
list.forEach(x -> { |
||||
x.setHygienePlanStatus(TrainStatusEnum.UNFINISHED.getValue()); |
||||
}); |
||||
// 将状态置为未完成
|
||||
boolean flag = hygienePlanService.updateBatchById(list); |
||||
return flag ? ReturnT.SUCCESS : ReturnT.FAIL; |
||||
} |
||||
} |
||||
|
@ -1,4 +1,16 @@
|
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> |
||||
<mapper namespace="com.hnac.hzims.safeproduct.mapper.ConferenceRecordMapper"> |
||||
|
||||
<select id="getConferenceRecordDetailById" |
||||
resultType="com.hnac.hzims.safeproduct.vo.ConferenceRecordDetailVO"> |
||||
SELECT |
||||
t1.code, t1.actual_start_time, t1.actual_end_time, t2.unit, t2.location, t2.host, t2.conference_method, t2.theme, |
||||
t1.recorder, t1.people_name, t1.content, t1.img_path, t1.file_path |
||||
FROM |
||||
hzims_conference_record t1 |
||||
LEFT JOIN hzims_conference_plan t2 ON t1.conference_plan_id = t2.id |
||||
WHERE |
||||
t1.is_deleted = 0 |
||||
AND t1.id = #{id} |
||||
</select> |
||||
</mapper> |
@ -0,0 +1,16 @@
|
||||
package com.hnac.hzims.safeproduct.mapper; |
||||
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
||||
import com.hnac.hzims.safeproduct.entity.DeviceEntity; |
||||
import org.apache.ibatis.annotations.Mapper; |
||||
|
||||
/** |
||||
* 特种设备Mapper类 |
||||
* |
||||
* @author liwen |
||||
* @date 2024-01-12 |
||||
*/ |
||||
@Mapper |
||||
public interface DeviceMapper extends BaseMapper<DeviceEntity> { |
||||
|
||||
} |
@ -0,0 +1,4 @@
|
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> |
||||
<mapper namespace="com.hnac.hzims.safeproduct.mapper.DeviceMapper"> |
||||
|
||||
</mapper> |
@ -0,0 +1,22 @@
|
||||
package com.hnac.hzims.safeproduct.service; |
||||
|
||||
import com.baomidou.mybatisplus.extension.service.IService; |
||||
import com.hnac.hzims.safeproduct.entity.DeviceEntity; |
||||
|
||||
import java.util.List; |
||||
|
||||
/** |
||||
* 特种设备服务类 |
||||
* |
||||
* @author liwen |
||||
* @date 2024-01-12 |
||||
*/ |
||||
public interface IDeviceService extends IService<DeviceEntity> { |
||||
|
||||
/** |
||||
* 查找时间范围内的过期设备 |
||||
* @param startTime 开始时间 |
||||
* @param endTime 结束时间 |
||||
*/ |
||||
List<DeviceEntity> getExpiredDeviceByTime(String startTime, String endTime); |
||||
} |
@ -0,0 +1,33 @@
|
||||
package com.hnac.hzims.safeproduct.service.impl; |
||||
|
||||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; |
||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
||||
import com.hnac.hzims.safeproduct.entity.DeviceEntity; |
||||
import com.hnac.hzims.safeproduct.enums.DeviceStatusEnum; |
||||
import com.hnac.hzims.safeproduct.mapper.DeviceMapper; |
||||
import com.hnac.hzims.safeproduct.service.IDeviceService; |
||||
import org.springframework.stereotype.Service; |
||||
|
||||
import java.util.List; |
||||
|
||||
/** |
||||
* 特种设备服务实现类 |
||||
* |
||||
* @author liwen |
||||
* @date 2024-01-12 |
||||
*/ |
||||
@Service |
||||
public class DeviceServiceImpl extends ServiceImpl<DeviceMapper, DeviceEntity> implements IDeviceService { |
||||
|
||||
/** |
||||
* 查找时间范围内的过期设备 |
||||
*/ |
||||
@Override |
||||
public List<DeviceEntity> getExpiredDeviceByTime(String startTime, String endTime) { |
||||
QueryWrapper<DeviceEntity> queryWrapper = new QueryWrapper<>(); |
||||
queryWrapper.lambda().eq(DeviceEntity::getDeviceStatus, DeviceStatusEnum.NORMAL.getValue()) |
||||
.ge(DeviceEntity::getInspectionNextTime, startTime) |
||||
.le(DeviceEntity::getInspectionNextTime, endTime); |
||||
return this.list(queryWrapper); |
||||
} |
||||
} |
@ -1 +1,365 @@
|
||||
alter table `hzims_safe_safety_tool` add column `advance_notice_days` tinyint(4) default 0 comment '安全工器具提前通知天数'; |
||||
|
||||
CREATE TABLE `hzims_rehearsal_plan` ( |
||||
`id` bigint(20) NOT NULL COMMENT '主键id', |
||||
`unit` varchar(50) NOT NULL COMMENT '单位', |
||||
`subject` varchar(50) NOT NULL COMMENT '演练科目', |
||||
`scheduled_start_time` date NOT NULL COMMENT '演练计划开始时间', |
||||
`scheduled_end_time` date NOT NULL COMMENT '演练计划结束时间', |
||||
`location` varchar(255) NOT NULL COMMENT '演练地点', |
||||
`commander` varchar(10) NOT NULL COMMENT '总指挥', |
||||
`rehearsal_method` varchar(20) DEFAULT '' COMMENT '演练方式', |
||||
`rehearsal_status` varchar(20) NOT NULL DEFAULT 'WAITING' COMMENT '演练状态', |
||||
`create_user` bigint(20) NOT NULL DEFAULT '-1' COMMENT '创建人', |
||||
`create_dept` bigint(20) NOT NULL DEFAULT '-1' COMMENT '创建部门', |
||||
`create_time` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间', |
||||
`update_user` bigint(20) DEFAULT '-1' COMMENT '更新人', |
||||
`update_time` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP COMMENT '最后更新时间', |
||||
`status` int(2) NOT NULL DEFAULT '1' COMMENT '状态', |
||||
`is_deleted` int(2) NOT NULL DEFAULT '0' COMMENT '逻辑删除状态:0-未删除,1-删除', |
||||
PRIMARY KEY (`id`) USING BTREE |
||||
) ENGINE=INNODB CHARACTER SET=utf8mb4 COLLATE=utf8mb4_general_ci COMMENT='演练计划表' ROW_FORMAT=Dynamic; |
||||
|
||||
CREATE TABLE `hzims_rehearsal_record` ( |
||||
`id` bigint(20) NOT NULL COMMENT '主键id', |
||||
`rehearsal_plan_id` bigint(20) NOT NULL COMMENT '演练计划id', |
||||
`code` varchar(50) NOT NULL COMMENT '编号', |
||||
`people_num` int(10) NOT NULL DEFAULT '0' COMMENT '参演人数', |
||||
`people_name` varchar(5000) DEFAULT '' COMMENT '参演人员', |
||||
`actual_start_time` datetime NOT NULL COMMENT '演练实际开始时间', |
||||
`actual_end_time` datetime NOT NULL COMMENT '演练实际结束时间', |
||||
`record` varchar(250) NOT NULL DEFAULT '' COMMENT '演练记录', |
||||
`comment` varchar(250) NOT NULL DEFAULT '' COMMENT '演练评价', |
||||
`img_path` varchar(1000) NOT NULL DEFAULT '' COMMENT '演练图片', |
||||
`file_path` varchar(1000) NOT NULL DEFAULT '' COMMENT '演练附件', |
||||
`create_user` bigint(20) NOT NULL DEFAULT '-1' COMMENT '创建人', |
||||
`create_dept` bigint(20) NOT NULL DEFAULT '-1' COMMENT '创建部门', |
||||
`create_time` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间', |
||||
`update_user` bigint(20) DEFAULT '-1' COMMENT '更新人', |
||||
`update_time` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP COMMENT '最后更新时间', |
||||
`status` int(2) NOT NULL DEFAULT '1' COMMENT '状态', |
||||
`is_deleted` int(2) NOT NULL DEFAULT '0' COMMENT '逻辑删除状态:0-未删除,1-删除', |
||||
PRIMARY KEY (`id`) USING BTREE |
||||
) ENGINE=INNODB CHARACTER SET=utf8mb4 COLLATE=utf8mb4_general_ci COMMENT='演练记录表' ROW_FORMAT=Dynamic; |
||||
|
||||
CREATE TABLE `hzims_train_plan` ( |
||||
`id` bigint(20) NOT NULL COMMENT '主键id', |
||||
`unit` varchar(50) NOT NULL COMMENT '单位', |
||||
`scheduled_start_time` date NOT NULL COMMENT '计划培训开始时间', |
||||
`scheduled_end_time` date NOT NULL COMMENT '计划培训结束时间', |
||||
`lesson` varchar(255) NOT NULL COMMENT '培训课程', |
||||
`location` varchar(255) NOT NULL COMMENT '培训地点', |
||||
`train_method` varchar(20) DEFAULT '' COMMENT '培训方式', |
||||
`teacher` varchar(20) NOT NULL DEFAULT '' COMMENT '培训讲师', |
||||
`train_status` varchar(20) NOT NULL DEFAULT 'WAITING' COMMENT '培训状态', |
||||
`is_test` int(2) NOT NULL DEFAULT '0' COMMENT '关联考试:0-否,1-是', |
||||
`create_user` bigint(20) NOT NULL DEFAULT '-1' COMMENT '创建人', |
||||
`create_dept` bigint(20) NOT NULL DEFAULT '-1' COMMENT '创建部门', |
||||
`create_time` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间', |
||||
`update_user` bigint(20) DEFAULT '-1' COMMENT '更新人', |
||||
`update_time` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP COMMENT '最后更新时间', |
||||
`status` int(2) NOT NULL DEFAULT '1' COMMENT '状态', |
||||
`is_deleted` int(2) NOT NULL DEFAULT '0' COMMENT '逻辑删除状态:0-未删除,1-删除', |
||||
PRIMARY KEY (`id`) USING BTREE |
||||
) ENGINE=INNODB CHARACTER SET=utf8mb4 COLLATE=utf8mb4_general_ci COMMENT='培训计划表' ROW_FORMAT=Dynamic; |
||||
|
||||
CREATE TABLE `hzims_train_record` ( |
||||
`id` bigint(20) NOT NULL COMMENT '主键id', |
||||
`train_plan_id` bigint(20) DEFAULT NULL COMMENT '培训计划id', |
||||
`train_record_name` varchar(50) NOT NULL DEFAULT '' COMMENT '培训记录名称', |
||||
`code` varchar(50) NOT NULL COMMENT '编号', |
||||
`people_name` varchar(5000) DEFAULT '' COMMENT '培训学员', |
||||
`content` mediumtext COMMENT '培训内容', |
||||
`actual_start_time` datetime DEFAULT NULL COMMENT '实际培训开始时间', |
||||
`actual_end_time` datetime DEFAULT NULL COMMENT '实际培训结束时间', |
||||
`command` varchar(250) DEFAULT NULL COMMENT '培训评价', |
||||
`img_path` varchar(1000) NOT NULL DEFAULT '' COMMENT '培训图片', |
||||
`file_path` varchar(1000) NOT NULL DEFAULT '' COMMENT '培训附件', |
||||
`create_user` bigint(20) NOT NULL DEFAULT '-1' COMMENT '创建人', |
||||
`create_dept` bigint(20) NOT NULL DEFAULT '-1' COMMENT '创建部门', |
||||
`create_time` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间', |
||||
`update_user` bigint(20) DEFAULT '-1' COMMENT '更新人', |
||||
`update_time` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP COMMENT '最后更新时间', |
||||
`status` int(2) NOT NULL DEFAULT '1' COMMENT '状态', |
||||
`is_deleted` int(2) NOT NULL DEFAULT '0' COMMENT '逻辑删除状态:0-未删除,1-删除', |
||||
PRIMARY KEY (`id`) USING BTREE |
||||
) ENGINE=INNODB CHARACTER SET=utf8mb4 COLLATE=utf8mb4_general_ci COMMENT='培训记录表' ROW_FORMAT=Dynamic; |
||||
|
||||
CREATE TABLE `hzims_test` ( |
||||
`id` bigint(20) NOT NULL COMMENT '主键id', |
||||
`train_plan_id` bigint(20) DEFAULT NULL COMMENT '培训计划id', |
||||
`train_record_id` bigint(20) DEFAULT NULL COMMENT '培训记录id', |
||||
`test_name` varchar(50) NOT NULL DEFAULT '' COMMENT '考试记录名称', |
||||
`code` varchar(50) NOT NULL COMMENT '编号', |
||||
`unit` varchar(50) NOT NULL COMMENT '单位', |
||||
`test_start_time` datetime NOT NULL COMMENT '考试开始时间', |
||||
`test_end_time` datetime NOT NULL COMMENT '考试结束时间', |
||||
`location` varchar(255) NOT NULL COMMENT '考试地点', |
||||
`subject` varchar(50) NOT NULL COMMENT '考试科目', |
||||
`proctor` varchar(20) NOT NULL COMMENT '监考人', |
||||
`people_name` varchar(1000) DEFAULT '' COMMENT '参考人员', |
||||
`img_path` varchar(1000) NOT NULL DEFAULT '' COMMENT '考试图片', |
||||
`file_path` varchar(1000) NOT NULL DEFAULT '' COMMENT '考试附件', |
||||
`create_user` bigint(20) NOT NULL DEFAULT '-1' COMMENT '创建人', |
||||
`create_dept` bigint(20) NOT NULL DEFAULT '-1' COMMENT '创建部门', |
||||
`create_time` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间', |
||||
`update_user` bigint(20) DEFAULT '-1' COMMENT '更新人', |
||||
`update_time` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP COMMENT '最后更新时间', |
||||
`status` int(2) NOT NULL DEFAULT '1' COMMENT '状态', |
||||
`is_deleted` int(2) NOT NULL DEFAULT '0' COMMENT '逻辑删除状态:0-未删除,1-删除', |
||||
PRIMARY KEY (`id`) USING BTREE |
||||
) ENGINE=INNODB CHARACTER SET=utf8mb4 COLLATE=utf8mb4_general_ci COMMENT='考试记录表' ROW_FORMAT=Dynamic; |
||||
|
||||
CREATE TABLE `hzims_test_score` ( |
||||
`id` bigint(20) NOT NULL COMMENT '主键id', |
||||
`test_id` bigint(20) DEFAULT NULL COMMENT '考试记录id', |
||||
`name` varchar(50) NOT NULL COMMENT '姓名', |
||||
`score` int(10) DEFAULT NULL COMMENT '成绩', |
||||
`create_user` bigint(20) NOT NULL DEFAULT '-1' COMMENT '创建人', |
||||
`create_dept` bigint(20) NOT NULL DEFAULT '-1' COMMENT '创建部门', |
||||
`create_time` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间', |
||||
`update_user` bigint(20) DEFAULT '-1' COMMENT '更新人', |
||||
`update_time` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP COMMENT '最后更新时间', |
||||
`status` int(2) NOT NULL DEFAULT '1' COMMENT '状态', |
||||
`is_deleted` int(2) NOT NULL DEFAULT '0' COMMENT '逻辑删除状态:0-未删除,1-删除', |
||||
PRIMARY KEY (`id`) USING BTREE |
||||
) ENGINE=INNODB CHARACTER SET=utf8mb4 COLLATE=utf8mb4_general_ci COMMENT='考试成绩表' ROW_FORMAT=Dynamic; |
||||
|
||||
CREATE TABLE `hzims_conference_plan` ( |
||||
`id` bigint(20) NOT NULL COMMENT '主键id', |
||||
`unit` varchar(50) NOT NULL COMMENT '单位', |
||||
`theme` varchar(50) NOT NULL COMMENT '会议主题', |
||||
`scheduled_start_time` date NOT NULL COMMENT '会议计划开始时间', |
||||
`scheduled_end_time` date NOT NULL COMMENT '会议计划结束时间', |
||||
`location` varchar(255) NOT NULL COMMENT '会议地点', |
||||
`host` varchar(10) NOT NULL COMMENT '主持人', |
||||
`conference_method` varchar(20) DEFAULT '' COMMENT '会议方式', |
||||
`conference_status` varchar(20) NOT NULL DEFAULT 'WAITING' COMMENT '会议状态', |
||||
`create_user` bigint(20) NOT NULL DEFAULT '-1' COMMENT '创建人', |
||||
`create_dept` bigint(20) NOT NULL DEFAULT '-1' COMMENT '创建部门', |
||||
`create_time` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间', |
||||
`update_user` bigint(20) DEFAULT '-1' COMMENT '更新人', |
||||
`update_time` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP COMMENT '最后更新时间', |
||||
`status` int(2) NOT NULL DEFAULT '1' COMMENT '状态', |
||||
`is_deleted` int(2) NOT NULL DEFAULT '0' COMMENT '逻辑删除状态:0-未删除,1-删除', |
||||
PRIMARY KEY (`id`) USING BTREE |
||||
) ENGINE=INNODB CHARACTER SET=utf8mb4 COLLATE=utf8mb4_general_ci COMMENT='会议计划表' ROW_FORMAT=Dynamic; |
||||
|
||||
CREATE TABLE `hzims_conference_record` ( |
||||
`id` bigint(20) NOT NULL COMMENT '主键id', |
||||
`conference_plan_id` bigint(20) NOT NULL COMMENT '会议计划id', |
||||
`code` varchar(50) NOT NULL COMMENT '编号', |
||||
`people_name` varchar(5000) DEFAULT '' COMMENT '参会人员', |
||||
`actual_start_time` datetime DEFAULT NULL COMMENT '会议实际开始时间', |
||||
`actual_end_time` datetime DEFAULT NULL COMMENT '会议实际结束时间', |
||||
`recorder` varchar(20) DEFAULT '' COMMENT '记录人', |
||||
`content` mediumtext COMMENT '会议内容', |
||||
`img_path` varchar(1000) NOT NULL DEFAULT '' COMMENT '会议图片', |
||||
`file_path` varchar(1000) NOT NULL DEFAULT '' COMMENT '会议附件', |
||||
`create_user` bigint(20) NOT NULL DEFAULT '-1' COMMENT '创建人', |
||||
`create_dept` bigint(20) NOT NULL DEFAULT '-1' COMMENT '创建部门', |
||||
`create_time` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间', |
||||
`update_user` bigint(20) DEFAULT '-1' COMMENT '更新人', |
||||
`update_time` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP COMMENT '最后更新时间', |
||||
`status` int(2) NOT NULL DEFAULT '1' COMMENT '状态', |
||||
`is_deleted` int(2) NOT NULL DEFAULT '0' COMMENT '逻辑删除状态:0-未删除,1-删除', |
||||
PRIMARY KEY (`id`) USING BTREE |
||||
) ENGINE=INNODB CHARACTER SET=utf8mb4 COLLATE=utf8mb4_general_ci COMMENT='会议记录表' ROW_FORMAT=Dynamic; |
||||
|
||||
CREATE TABLE `hzims_hygiene_plan` ( |
||||
`id` bigint(20) NOT NULL COMMENT '主键id', |
||||
`unit` varchar(50) NOT NULL COMMENT '单位', |
||||
`name` varchar(50) NOT NULL COMMENT '名称', |
||||
`standard_score` int(10) NOT NULL DEFAULT '100' COMMENT '标准总分值', |
||||
`scheduled_start_time` date NOT NULL COMMENT '计划开始时间', |
||||
`scheduled_end_time` date NOT NULL COMMENT '计划结束时间', |
||||
`hygiene_plan_status` varchar(50) NOT NULL DEFAULT 'WAITING' COMMENT '自查计划状态', |
||||
`create_user` bigint(20) NOT NULL DEFAULT '-1' COMMENT '创建人', |
||||
`create_dept` bigint(20) NOT NULL DEFAULT '-1' COMMENT '创建部门', |
||||
`create_time` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间', |
||||
`update_user` bigint(20) DEFAULT '-1' COMMENT '更新人', |
||||
`update_time` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP COMMENT '最后更新时间', |
||||
`status` int(2) NOT NULL DEFAULT '1' COMMENT '状态', |
||||
`is_deleted` int(2) NOT NULL DEFAULT '0' COMMENT '逻辑删除状态:0-未删除,1-删除', |
||||
PRIMARY KEY (`id`) USING BTREE |
||||
) ENGINE=INNODB CHARACTER SET=utf8mb4 COLLATE=utf8mb4_general_ci COMMENT='卫生自查计划表' ROW_FORMAT=Dynamic; |
||||
|
||||
CREATE TABLE `hzims_hygiene_zone` ( |
||||
`id` bigint(20) NOT NULL COMMENT '主键id', |
||||
`hygiene_plan_id` bigint(20) NOT NULL COMMENT '卫生自查计划id', |
||||
`zone` varchar(50) NOT NULL COMMENT '责任区', |
||||
`principal` varchar(20) NOT NULL COMMENT '责任人', |
||||
`check_item` mediumtext NOT NULL COMMENT '检查项', |
||||
`check_item_score` varchar(255) NOT NULL COMMENT '检查项分值', |
||||
`create_user` bigint(20) NOT NULL DEFAULT '-1' COMMENT '创建人', |
||||
`create_dept` bigint(20) NOT NULL DEFAULT '-1' COMMENT '创建部门', |
||||
`create_time` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间', |
||||
`update_user` bigint(20) DEFAULT '-1' COMMENT '更新人', |
||||
`update_time` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP COMMENT '最后更新时间', |
||||
`status` int(2) NOT NULL DEFAULT '1' COMMENT '状态', |
||||
`is_deleted` int(2) NOT NULL DEFAULT '0' COMMENT '逻辑删除状态:0-未删除,1-删除', |
||||
PRIMARY KEY (`id`) USING BTREE |
||||
) ENGINE=INNODB CHARACTER SET=utf8mb4 COLLATE=utf8mb4_general_ci COMMENT='卫生自查区域表' ROW_FORMAT=Dynamic; |
||||
|
||||
CREATE TABLE `hzims_hygiene_record` ( |
||||
`id` bigint(20) NOT NULL COMMENT '主键id', |
||||
`hygiene_plan_id` bigint(20) NOT NULL COMMENT '卫生自查计划id', |
||||
`unit` varchar(50) NOT NULL COMMENT '单位', |
||||
`code` varchar(50) NOT NULL COMMENT '编号', |
||||
`actual_start_time` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '实际开始时间', |
||||
`actual_end_time` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '实际结束时间', |
||||
`check_user` varchar(20) NOT NULL DEFAULT '' COMMENT '检查人', |
||||
`hygiene_zone_ids` varchar(1000) NOT NULL COMMENT '卫生自查区域id', |
||||
`check_result` mediumtext NOT NULL COMMENT '检查结果', |
||||
`comprehensive_score` varchar(500) NOT NULL COMMENT '综合评分', |
||||
`week_num` int(10) NOT NULL COMMENT '周数', |
||||
`img_path` varchar(1000) NOT NULL DEFAULT '' COMMENT '检查图片', |
||||
`create_user` bigint(20) NOT NULL DEFAULT '-1' COMMENT '创建人', |
||||
`create_dept` bigint(20) NOT NULL DEFAULT '-1' COMMENT '创建部门', |
||||
`create_time` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间', |
||||
`update_user` bigint(20) DEFAULT '-1' COMMENT '更新人', |
||||
`update_time` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP COMMENT '最后更新时间', |
||||
`status` int(2) NOT NULL DEFAULT '1' COMMENT '状态', |
||||
`is_deleted` int(2) NOT NULL DEFAULT '0' COMMENT '逻辑删除状态:0-未删除,1-删除', |
||||
PRIMARY KEY (`id`) USING BTREE |
||||
) ENGINE=INNODB CHARACTER SET=utf8mb4 COLLATE=utf8mb4_general_ci COMMENT='卫生自查记录表' ROW_FORMAT=Dynamic; |
||||
|
||||
CREATE TABLE `hzims_car` ( |
||||
`id` bigint(20) NOT NULL COMMENT '主键id', |
||||
`unit` varchar(50) NOT NULL COMMENT '单位', |
||||
`car_brand` varchar(50) NOT NULL COMMENT '品牌', |
||||
`car_type` varchar(50) NOT NULL COMMENT '型号', |
||||
`plate_number` varchar(50) NOT NULL COMMENT '车牌号', |
||||
`registration_time` date NOT NULL COMMENT '上牌时间', |
||||
`insurance_pay_last_time` date NOT NULL COMMENT '上期缴车保时间', |
||||
`insurance_pay_next_time` date NOT NULL COMMENT '下期缴车保时间', |
||||
`annual_inspection_time` date NOT NULL COMMENT '年检时间', |
||||
`annual_inspection_status` varchar(50) NOT NULL COMMENT '年检状态', |
||||
`insurance_status` varchar(50) NOT NULL COMMENT '保险状态', |
||||
`maintenance_last_time` date DEFAULT NULL COMMENT '上期保养时间', |
||||
`maintenance_next_time` date DEFAULT NULL COMMENT '下期保养时间', |
||||
`maintenance_mileage` decimal(10, 2) DEFAULT NULL COMMENT '保养里程', |
||||
`maintenance_status` varchar(50) DEFAULT NULL COMMENT '保养状态', |
||||
`manager` varchar(50) NOT NULL COMMENT '车辆管理人', |
||||
`img_path` varchar(1000) NOT NULL DEFAULT '' COMMENT '车辆图片', |
||||
`file_path` varchar(1000) NOT NULL DEFAULT '' COMMENT '车辆附件', |
||||
`create_user` bigint(20) NOT NULL DEFAULT '-1' COMMENT '创建人', |
||||
`create_dept` bigint(20) NOT NULL DEFAULT '-1' COMMENT '创建部门', |
||||
`create_time` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间', |
||||
`update_user` bigint(20) DEFAULT '-1' COMMENT '更新人', |
||||
`update_time` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP COMMENT '最后更新时间', |
||||
`status` int(2) NOT NULL DEFAULT '1' COMMENT '状态', |
||||
`is_deleted` int(2) NOT NULL DEFAULT '0' COMMENT '逻辑删除状态:0-未删除,1-删除', |
||||
PRIMARY KEY (`id`) USING BTREE |
||||
) ENGINE=INNODB CHARACTER SET=utf8mb4 COLLATE=utf8mb4_general_ci COMMENT='车辆台账表' ROW_FORMAT=Dynamic; |
||||
|
||||
CREATE TABLE `hzims_car_maintenance` ( |
||||
`id` bigint(20) NOT NULL COMMENT '主键id', |
||||
`car_id` bigint(20) NOT NULL COMMENT '车辆id', |
||||
`code` varchar(50) NOT NULL COMMENT '编号', |
||||
`maintenance_type` varchar(50) NOT NULL COMMENT '维保类型', |
||||
`content` mediumtext NOT NULL COMMENT '维保内容', |
||||
`start_time` date NOT NULL COMMENT '维保开始时间', |
||||
`end_time` date NOT NULL COMMENT '维保结束时间', |
||||
`location` varchar(255) NOT NULL COMMENT '维保地点', |
||||
`cost` bigint(20) NOT NULL COMMENT '维保费用', |
||||
`maintainer` varchar(20) NOT NULL COMMENT '维保人', |
||||
`manager_advice` varchar(500) DEFAULT NULL COMMENT '车辆管理人意见', |
||||
`maintenance_status` varchar(50) DEFAULT NULL COMMENT '维保状态', |
||||
`confirmation_time` datetime DEFAULT NULL COMMENT '确认时间', |
||||
`img_path` varchar(1000) NOT NULL DEFAULT '' COMMENT '维保图片', |
||||
`file_path` varchar(1000) NOT NULL DEFAULT '' COMMENT '维保附件', |
||||
`create_user` bigint(20) NOT NULL DEFAULT '-1' COMMENT '创建人', |
||||
`create_dept` bigint(20) NOT NULL DEFAULT '-1' COMMENT '创建部门', |
||||
`create_time` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间', |
||||
`update_user` bigint(20) DEFAULT '-1' COMMENT '更新人', |
||||
`update_time` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP COMMENT '最后更新时间', |
||||
`status` int(2) NOT NULL DEFAULT '1' COMMENT '状态', |
||||
`is_deleted` int(2) NOT NULL DEFAULT '0' COMMENT '逻辑删除状态:0-未删除,1-删除', |
||||
PRIMARY KEY (`id`) USING BTREE |
||||
) ENGINE=INNODB CHARACTER SET=utf8mb4 COLLATE=utf8mb4_general_ci COMMENT='车辆维保记录表' ROW_FORMAT=Dynamic; |
||||
|
||||
CREATE TABLE `hzims_car_used_record` ( |
||||
`id` bigint(20) NOT NULL COMMENT '主键id', |
||||
`car_id` bigint(20) NOT NULL COMMENT '车辆id', |
||||
`code` varchar(50) NOT NULL COMMENT '编号', |
||||
`unit` varchar(50) NOT NULL COMMENT '用车单位', |
||||
`used_location` varchar(255) NOT NULL COMMENT '使用地点', |
||||
`user` varchar(20) NOT NULL COMMENT '使用人', |
||||
`remark` mediumtext DEFAULT NULL COMMENT '使用详情', |
||||
`start_time` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '使用时间', |
||||
`end_time` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '收车时间', |
||||
`start_miles` decimal(10, 2) NOT NULL COMMENT '出车公里数', |
||||
`end_miles` decimal(10, 2) NOT NULL COMMENT '收车公里数', |
||||
`miles` decimal(10, 2) NOT NULL COMMENT '行驶公里数', |
||||
`used_status` varchar(50) DEFAULT NULL COMMENT '用车状态', |
||||
`confirmation_time` datetime DEFAULT NULL COMMENT '确认时间', |
||||
`img_path` varchar(1000) NOT NULL DEFAULT '' COMMENT '里程图片', |
||||
`create_user` bigint(20) NOT NULL DEFAULT '-1' COMMENT '创建人', |
||||
`create_dept` bigint(20) NOT NULL DEFAULT '-1' COMMENT '创建部门', |
||||
`create_time` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间', |
||||
`update_user` bigint(20) DEFAULT '-1' COMMENT '更新人', |
||||
`update_time` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP COMMENT '最后更新时间', |
||||
`status` int(2) NOT NULL DEFAULT '1' COMMENT '状态', |
||||
`is_deleted` int(2) NOT NULL DEFAULT '0' COMMENT '逻辑删除状态:0-未删除,1-删除', |
||||
PRIMARY KEY (`id`) USING BTREE |
||||
) ENGINE=INNODB CHARACTER SET=utf8mb4 COLLATE=utf8mb4_general_ci COMMENT='用车记录表' ROW_FORMAT=Dynamic; |
||||
|
||||
CREATE TABLE `hzims_car_check_record` ( |
||||
`id` bigint(20) NOT NULL COMMENT '主键id', |
||||
`car_id` bigint(20) NOT NULL COMMENT '车辆id', |
||||
`code` varchar(50) NOT NULL COMMENT '编号', |
||||
`checker` varchar(50) NOT NULL COMMENT '检查人', |
||||
`check_time` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '检查时间', |
||||
`conclusion` mediumtext NOT NULL COMMENT '检查结论', |
||||
`remark` varchar(500) NOT NULL DEFAULT '' COMMENT '填报备注', |
||||
`create_user` bigint(20) NOT NULL DEFAULT '-1' COMMENT '创建人', |
||||
`create_dept` bigint(20) NOT NULL DEFAULT '-1' COMMENT '创建部门', |
||||
`create_time` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间', |
||||
`update_user` bigint(20) DEFAULT '-1' COMMENT '更新人', |
||||
`update_time` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP COMMENT '最后更新时间', |
||||
`status` int(2) NOT NULL DEFAULT '1' COMMENT '状态', |
||||
`is_deleted` int(2) NOT NULL DEFAULT '0' COMMENT '逻辑删除状态:0-未删除,1-删除', |
||||
PRIMARY KEY (`id`) USING BTREE |
||||
) ENGINE=INNODB CHARACTER SET=utf8mb4 COLLATE=utf8mb4_general_ci COMMENT='车检记录表' ROW_FORMAT=Dynamic; |
||||
|
||||
CREATE TABLE `hzims_car_check_item` ( |
||||
`id` bigint(20) NOT NULL COMMENT '主键id', |
||||
`car_check_record_id` bigint(20) NOT NULL COMMENT '车检记录id', |
||||
`check_item` varchar(500) NOT NULL COMMENT '检查项目', |
||||
`check_content` mediumtext NOT NULL COMMENT '检查内容', |
||||
`check_result` mediumtext NOT NULL COMMENT '检查结果', |
||||
`create_user` bigint(20) NOT NULL DEFAULT '-1' COMMENT '创建人', |
||||
`create_dept` bigint(20) NOT NULL DEFAULT '-1' COMMENT '创建部门', |
||||
`create_time` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间', |
||||
`update_user` bigint(20) DEFAULT '-1' COMMENT '更新人', |
||||
`update_time` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP COMMENT '最后更新时间', |
||||
`status` int(2) NOT NULL DEFAULT '1' COMMENT '状态', |
||||
`is_deleted` int(2) NOT NULL DEFAULT '0' COMMENT '逻辑删除状态:0-未删除,1-删除', |
||||
PRIMARY KEY (`id`) USING BTREE |
||||
) ENGINE=INNODB CHARACTER SET=utf8mb4 COLLATE=utf8mb4_general_ci COMMENT='车检项表' ROW_FORMAT=Dynamic; |
||||
|
||||
CREATE TABLE `hzims_device` ( |
||||
`id` bigint(20) NOT NULL COMMENT '主键id', |
||||
`name` varchar(50) NOT NULL COMMENT '设备名称', |
||||
`type` varchar(50) NOT NULL DEFAULT '' COMMENT '规格型号', |
||||
`code` varchar(50) NOT NULL COMMENT '编码', |
||||
`quality_cerfiticate_no` varchar(255) NOT NULL DEFAULT '' COMMENT '产品合格证号', |
||||
`production_time` date DEFAULT NULL COMMENT '生产日期', |
||||
`used_time` date DEFAULT NULL COMMENT '使用日期', |
||||
`used_location` varchar(255) NOT NULL DEFAULT '' COMMENT '使用地点', |
||||
`inspection_period` int(10) DEFAULT NULL COMMENT '检验周期', |
||||
`inspection_current_time` date DEFAULT NULL COMMENT '本次检验日期', |
||||
`inspection_next_time` date DEFAULT NULL COMMENT '下次检验日期', |
||||
`inspection_last_time` date DEFAULT NULL COMMENT '上次检验日期', |
||||
`manager` varchar(50) NOT NULL DEFAULT '' COMMENT '设备管理人', |
||||
`device_status` varchar(20) NOT NULL DEFAULT 'NORMAL' COMMENT '设备状态', |
||||
`create_user` bigint(20) NOT NULL DEFAULT '-1' COMMENT '创建人', |
||||
`create_dept` bigint(20) NOT NULL DEFAULT '-1' COMMENT '创建部门', |
||||
`create_time` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间', |
||||
`update_user` bigint(20) DEFAULT '-1' COMMENT '更新人', |
||||
`update_time` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP COMMENT '最后更新时间', |
||||
`status` int(2) NOT NULL DEFAULT '1' COMMENT '状态', |
||||
`is_deleted` int(2) NOT NULL DEFAULT '0' COMMENT '逻辑删除状态:0-未删除,1-删除', |
||||
PRIMARY KEY (`id`) USING BTREE |
||||
) ENGINE=INNODB CHARACTER SET=utf8mb4 COLLATE=utf8mb4_general_ci COMMENT='特种设备表' ROW_FORMAT=Dynamic; |
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Loading…
Reference in new issue