Commit 6b87fec3 authored by 纪泽龙's avatar 纪泽龙
parents a73af416 429084a6
......@@ -181,6 +181,9 @@ public class TDanger extends BaseEntity
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
private Date endDate;
@Excel(name = "表具编号")
private String meterNum;
public void setId(Long id)
{
this.id = id;
......@@ -570,6 +573,14 @@ public class TDanger extends BaseEntity
this.endDate = endDate;
}
public String getMeterNum() {
return meterNum;
}
public void setMeterNum(String meterNum) {
this.meterNum = meterNum;
}
@Override
public String toString() {
return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
......
......@@ -54,6 +54,14 @@ public class UserTaskInspect {
private Long village;
/** 安检开始时间 */
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
private Date beginDate;
/** 安检结束时间 */
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
private Date endDate;
public String getNickName() {
return nickName;
}
......@@ -237,4 +245,20 @@ public class UserTaskInspect {
public void setMeternum(String meternum) {
this.meternum = meternum;
}
public Date getBeginDate() {
return beginDate;
}
public void setBeginDate(Date beginDate) {
this.beginDate = beginDate;
}
public Date getEndDate() {
return endDate;
}
public void setEndDate(Date endDate) {
this.endDate = endDate;
}
}
......@@ -99,6 +99,12 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
else '-'
end
) as receiveName,
(
case type
when '1' then (select tu.meternum from t_user tu where tu.id = danger.receive_id)
else '-'
end
) as meterNum,
(select nick_name from sys_user where user_id = danger.reform_id) as reformName,
us.nick_name as reportName,
(select nick_name from sys_user where user_id = danger.check_id) as checkName
......
......@@ -132,6 +132,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="village == null ">
and u.village in (SELECT re.relation_id FROM t_task_relation_info re WHERE re.task_id = #{taskId} and re.type = '1' )
</if>
<if test="beginDate != null and endDate != null">
and inspect.create_time BETWEEN #{beginDate} AND #{endDate}
</if>
</where>
order by inspect.create_time desc
</select>
......@@ -161,6 +164,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="village == null ">
and u.village in (SELECT re.relation_id FROM t_task_relation_info re WHERE re.task_id = #{taskId} and re.type = '1' )
</if>
<if test="beginDate != null and endDate != null">
and inspect.create_time BETWEEN #{beginDate} AND #{endDate}
</if>
</where>
order by inspect.create_time desc
</select>
......
......@@ -114,6 +114,7 @@
</template>
</el-table-column>
<el-table-column label="隐患来源" align="center" prop="type" :formatter="typeFormatter"/>
<el-table-column label="表具编号" align="center" prop="meterNum" />
<el-table-column label="责任归属" align="center" prop="flag">
<template slot-scope="scope">
<span v-if="scope.row.flag == 1">安全管理部</span>
......@@ -122,12 +123,12 @@
<span v-else>-</span>
</template>
</el-table-column>
<el-table-column label="隐患级别" align="center" prop="level">
<!--<el-table-column label="隐患级别" align="center" prop="level">
<template slot-scope="scope">
<span v-if="scope.row.level == 1">重大</span>
<span v-if="scope.row.level == 2">一般</span>
</template>
</el-table-column>
</el-table-column>-->
<el-table-column label="隐患地址" align="center" prop="address" width="150" :show-overflow-tooltip="true"/>
<el-table-column label="隐患状态" align="center" prop="status">
<template slot-scope="scope">
......
......@@ -170,6 +170,20 @@
</el-select>
</el-form-item>
<el-form-item label="安检时间" prop="inspectTimeRange">
<el-date-picker
v-model="inspectTimeRange"
type="datetimerange"
size="small"
:clearable="false"
value-format="yyyy-MM-dd HH:mm"
@change="timeChange"
range-separator="至"
start-placeholder="开始日期"
end-placeholder="结束日期">
</el-date-picker>
</el-form-item>
<el-form-item>
<el-button
type="primary"
......@@ -383,7 +397,9 @@ export default {
satisfy: "",
inspectStatus: "",
nickName: null,
village: null
village: null,
beginDate: null,
endDate : null
},
satisfyOptions: [
{
......@@ -476,7 +492,8 @@ export default {
],
taskDetailData:{},
taskInspectDangerDetailData:{},
communityInfos: []
communityInfos: [],
inspectTimeRange: []
};
},
created() {
......@@ -544,6 +561,9 @@ export default {
/** 重置按钮操作 */
resetQuery() {
this.resetForm("queryForm");
this.inspectTimeRange = [];
this.queryParams.beginDate = null;
this.queryParams.endDate = null;
this.handleQuery();
},
// 多选框选中数据
......@@ -706,7 +726,11 @@ export default {
},
handleBatchInspectExport(){
this.$refs.exportInspect.init(this.queryParams);
}
},
timeChange(val){
this.queryParams.beginDate = val[0];
this.queryParams.endDate = val[1];
},
},
};
</script>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment