Commit ec34e8fb authored by lizhichao's avatar lizhichao

1.安全教育培训模块需增设培训部门、主讲人2.承包商考试界面,题面显示区域过小;3.培训统计-添加部门搜索;4风险信息管理列表中需区分设备实施清单、作业活动...

1.安全教育培训模块需增设培训部门、主讲人2.承包商考试界面,题面显示区域过小;3.培训统计-添加部门搜索;4风险信息管理列表中需区分设备实施清单、作业活动清单;5.隐患排查中“隐患排查库”把“检查依据”去掉,隐患名称改为“风险描述”
parent 1bc489f5
...@@ -46,6 +46,17 @@ public class TRiskManager extends BaseEntity ...@@ -46,6 +46,17 @@ public class TRiskManager extends BaseEntity
@Excel(name = "责任人") @Excel(name = "责任人")
private String riskPerson; private String riskPerson;
public String getListType() {
return listType;
}
public void setListType(String listType) {
this.listType = listType;
}
//清单类型 2023-10-10
private String listType;
public void setId(Long id) public void setId(Long id)
{ {
this.id = id; this.id = id;
......
...@@ -87,6 +87,44 @@ public class TTrainCourse extends BaseEntity ...@@ -87,6 +87,44 @@ public class TTrainCourse extends BaseEntity
@Excel(name = "考试人员") @Excel(name = "考试人员")
private String testPersons; private String testPersons;
/**
* 2023-10-09添加培训部门、主讲人
*/
/** 考试人员 */
@Excel(name = "培训部门id")
private String deptId;
public String getDeptName() {
return deptName;
}
public void setDeptName(String deptName) {
this.deptName = deptName;
}
@Excel(name = "培训部门名称")
private String deptName;
public String getDeptId() {
return deptId;
}
public void setDeptId(String deptId) {
this.deptId = deptId;
}
public String getZhujiang() {
return zhujiang;
}
public void setZhujiang(String zhujiang) {
this.zhujiang = zhujiang;
}
/** 考试人员 */
@Excel(name = "主讲人")
private String zhujiang;
private Integer personnelType; private Integer personnelType;
private Integer duration; private Integer duration;
......
...@@ -20,6 +20,26 @@ public class TrainCourseStat { ...@@ -20,6 +20,26 @@ public class TrainCourseStat {
private Date releaseEndTime; private Date releaseEndTime;
public String getDeptName() {
return deptName;
}
public void setDeptName(String deptName) {
this.deptName = deptName;
}
private String deptName;
public String getDeptId() {
return deptId;
}
public void setDeptId(String deptId) {
this.deptId = deptId;
}
private String deptId;
public Long getCourseId() { public Long getCourseId() {
return courseId; return courseId;
} }
......
...@@ -13,10 +13,11 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" ...@@ -13,10 +13,11 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<result property="riskControl" column="risk_control" /> <result property="riskControl" column="risk_control" />
<result property="riskDept" column="risk_dept" /> <result property="riskDept" column="risk_dept" />
<result property="riskPerson" column="risk_person" /> <result property="riskPerson" column="risk_person" />
<result property="listType" column="list_type" />
</resultMap> </resultMap>
<sql id="selectTRiskManagerVo"> <sql id="selectTRiskManagerVo">
select id, risk_part, risk_content, risk_level, risk_type, risk_control, risk_dept, risk_person from t_risk_manager select id, risk_part, risk_content, risk_level, risk_type, risk_control, risk_dept, risk_person,list_type from t_risk_manager
</sql> </sql>
<select id="selectTRiskManagerList" parameterType="TRiskManager" resultMap="TRiskManagerResult"> <select id="selectTRiskManagerList" parameterType="TRiskManager" resultMap="TRiskManagerResult">
...@@ -47,6 +48,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" ...@@ -47,6 +48,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="riskControl != null">risk_control,</if> <if test="riskControl != null">risk_control,</if>
<if test="riskDept != null">risk_dept,</if> <if test="riskDept != null">risk_dept,</if>
<if test="riskPerson != null">risk_person,</if> <if test="riskPerson != null">risk_person,</if>
<if test="listType != null">list_type,</if>
</trim> </trim>
<trim prefix="values (" suffix=")" suffixOverrides=","> <trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="riskPart != null">#{riskPart},</if> <if test="riskPart != null">#{riskPart},</if>
...@@ -56,6 +58,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" ...@@ -56,6 +58,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="riskControl != null">#{riskControl},</if> <if test="riskControl != null">#{riskControl},</if>
<if test="riskDept != null">#{riskDept},</if> <if test="riskDept != null">#{riskDept},</if>
<if test="riskPerson != null">#{riskPerson},</if> <if test="riskPerson != null">#{riskPerson},</if>
<if test="listType != null">#{listType},</if>
</trim> </trim>
</insert> </insert>
...@@ -69,6 +72,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" ...@@ -69,6 +72,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="riskControl != null">risk_control = #{riskControl},</if> <if test="riskControl != null">risk_control = #{riskControl},</if>
<if test="riskDept != null">risk_dept = #{riskDept},</if> <if test="riskDept != null">risk_dept = #{riskDept},</if>
<if test="riskPerson != null">risk_person = #{riskPerson},</if> <if test="riskPerson != null">risk_person = #{riskPerson},</if>
<if test="listType != null">list_type = #{listType},</if>
</trim> </trim>
where id = #{id} where id = #{id}
</update> </update>
......
...@@ -29,6 +29,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" ...@@ -29,6 +29,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<result property="singleChoiceScore" column="single_choice_score" /> <result property="singleChoiceScore" column="single_choice_score" />
<result property="judgmentScore" column="judgment_score" /> <result property="judgmentScore" column="judgment_score" />
<result property="isVeriftyFace" column="is_verifty_face" /> <result property="isVeriftyFace" column="is_verifty_face" />
<result property="deptName" column="dept_name" />
</resultMap> </resultMap>
<resultMap id="StatisticsTrainCourseResult" type="StatisticsTrainCourse"> <resultMap id="StatisticsTrainCourseResult" type="StatisticsTrainCourse">
...@@ -53,11 +54,12 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" ...@@ -53,11 +54,12 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
</resultMap> </resultMap>
<sql id="selectTTrainCourseVo"> <sql id="selectTTrainCourseVo">
select multiple_choice_score,single_choice_score,judgment_score,course_id, course_name, course_type, course_conent, status,personnel_type, release_time, enclosure, video, qualified_num, topic_num, create_time, create_user, is_del, data_kind, test_start_time, test_end_time, test_persons,duration,is_verifty_face from t_train_course select multiple_choice_score,single_choice_score,judgment_score,course_id, course_name, course_type, course_conent, status,personnel_type, release_time, enclosure, video, qualified_num, topic_num, create_time, create_user, is_del, data_kind, test_start_time, test_end_time, test_persons,duration,is_verifty_face,zhujiang,deptid from t_train_course
</sql> </sql>
<select id="selectTTrainCourseList" parameterType="TTrainCourse" resultMap="TTrainCourseResult"> <select id="selectTTrainCourseList" parameterType="TTrainCourse" resultMap="TTrainCourseResult">
select c.*,p.plan_name from t_train_course c select c.*,p.plan_name,d.dept_name from t_train_course c
left join sys_dept d on c.deptid=d.dept_id
LEFT JOIN t_train_plan p on p.plan_id = c.course_type LEFT JOIN t_train_plan p on p.plan_id = c.course_type
<where> <where>
...@@ -109,6 +111,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" ...@@ -109,6 +111,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="singleChoiceScore != null">single_choice_score,</if> <if test="singleChoiceScore != null">single_choice_score,</if>
<if test="judgmentScore != null">judgment_score,</if> <if test="judgmentScore != null">judgment_score,</if>
<if test="isVeriftyFace != null">is_verifty_face,</if> <if test="isVeriftyFace != null">is_verifty_face,</if>
<if test="zhujiang != null">zhujiang,</if>
<if test="deptId != null">deptid,</if>
</trim> </trim>
<trim prefix="values (" suffix=")" suffixOverrides=","> <trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="courseName != null">#{courseName},</if> <if test="courseName != null">#{courseName},</if>
...@@ -133,6 +137,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" ...@@ -133,6 +137,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="singleChoiceScore != null">#{singleChoiceScore},</if> <if test="singleChoiceScore != null">#{singleChoiceScore},</if>
<if test="judgmentScore != null">#{judgmentScore},</if> <if test="judgmentScore != null">#{judgmentScore},</if>
<if test="isVeriftyFace != null">#{isVeriftyFace},</if> <if test="isVeriftyFace != null">#{isVeriftyFace},</if>
<if test="zhujiang != null">#{zhujiang},</if>
<if test="deptId != null">#{deptId},</if>
</trim> </trim>
</insert> </insert>
...@@ -161,6 +167,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" ...@@ -161,6 +167,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="singleChoiceScore != null">single_choice_score = #{singleChoiceScore},</if> <if test="singleChoiceScore != null">single_choice_score = #{singleChoiceScore},</if>
<if test="judgmentScore != null">judgment_score = #{judgmentScore},</if> <if test="judgmentScore != null">judgment_score = #{judgmentScore},</if>
<if test="isVeriftyFace != null">is_verifty_face = #{isVeriftyFace},</if> <if test="isVeriftyFace != null">is_verifty_face = #{isVeriftyFace},</if>
<if test="zhujiang != null">zhujiang=#{zhujiang},</if>
<if test="deptId != null">deptid=#{deptId},</if>
</trim> </trim>
where course_id = #{courseId} where course_id = #{courseId}
</update> </update>
......
...@@ -11,6 +11,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" ...@@ -11,6 +11,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<result property="planName" column="plan_name" /> <result property="planName" column="plan_name" />
<result property="maybeTestNum" column="maybeTestNum" /> <result property="maybeTestNum" column="maybeTestNum" />
<result property="finishNum" column="finishNum" /> <result property="finishNum" column="finishNum" />
<result property="deptName" column="dept_name" />
</resultMap> </resultMap>
<resultMap id="TrainCourseStatDetailResult" type="TrainCourseStatDetail"> <resultMap id="TrainCourseStatDetailResult" type="TrainCourseStatDetail">
...@@ -24,6 +25,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" ...@@ -24,6 +25,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<select id="getTrainCourseStatData" parameterType="com.zehong.system.domain.TrainCourseStat" resultMap="TrainCourseStatResult"> <select id="getTrainCourseStatData" parameterType="com.zehong.system.domain.TrainCourseStat" resultMap="TrainCourseStatResult">
SELECT SELECT
d.dept_name,
train.course_id, train.course_id,
train.course_name, train.course_name,
train.release_time, train.release_time,
...@@ -33,12 +35,14 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" ...@@ -33,12 +35,14 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
FROM FROM
t_train_course train t_train_course train
LEFT JOIN t_train_plan plan ON plan.plan_id = train.course_type LEFT JOIN t_train_plan plan ON plan.plan_id = train.course_type
left join sys_dept d on train.deptid=d.dept_id
<where> <where>
train.is_del = '0' and train.data_kind = 0 train.is_del = '0' and train.data_kind = 0
AND train.status = '1' AND train.status = '1'
<if test="courseId != null "> and train.course_id = #{courseId}</if> <if test="courseId != null "> and train.course_id = #{courseId}</if>
<if test="courseName !='' and courseName!= null">and train.course_name like concat('%', #{courseName}, '%')</if> <if test="courseName !='' and courseName!= null">and train.course_name like concat('%', #{courseName}, '%')</if>
<if test="releaseBeginTime != null and releaseEndTime">and train.release_time BETWEEN #{releaseBeginTime} AND #{releaseEndTime} </if> <if test="releaseBeginTime != null and releaseEndTime">and train.release_time BETWEEN #{releaseBeginTime} AND #{releaseEndTime} </if>
<if test="deptId != null "> and train.deptid = #{deptId}</if>
</where> </where>
ORDER BY train.release_time DESC ORDER BY train.release_time DESC
</select> </select>
......
...@@ -16,8 +16,12 @@ ...@@ -16,8 +16,12 @@
:rules="rules" :rules="rules"
> >
<div class="top flex"> <div class="top flex">
<el-form-item label="课程标题" prop="courseName"> <el-form-item label="培训部门" prop="deptId">
<el-input style="width: 568px" v-model="form.courseName" :disabled="checkLock"></el-input> <treeselect v-model="form.deptId" style="width: 220px;" :options="deptOptions" :show-count="true" placeholder="请选择培训部门" />
</el-form-item>
<el-form-item label="课程标题" prop="courseName" style="margin-left: -30px">
<el-input style="width: 532px" v-model="form.courseName" :disabled="checkLock"></el-input>
</el-form-item> </el-form-item>
<!--<el-form-item label="培训计划" prop="courseType">--> <!--<el-form-item label="培训计划" prop="courseType">-->
...@@ -44,7 +48,7 @@ ...@@ -44,7 +48,7 @@
clearable clearable
size="small" size="small"
:disabled="checkLock" :disabled="checkLock"
style="width:215px" style="width:220px"
> >
<el-option <el-option
v-for="course in courseOptions" v-for="course in courseOptions"
...@@ -57,24 +61,34 @@ ...@@ -57,24 +61,34 @@
<el-form-item <el-form-item
label="培训时长" label="培训时长"
prop="duration" prop="duration"
style="margin-left: 55px" style="margin-left: 30px"
> >
<el-input <el-input
style="width: 180px" style="width: 160px"
placeholder="分钟" placeholder="分钟"
type="number" type="number"
v-model="form.duration" v-model="form.duration"
:disabled="checkLock" :disabled="checkLock"
></el-input> ></el-input>
<el-label>
(分钟) (分钟)
</el-label> </el-form-item>
<el-form-item
label="主讲人"
prop="zhujiang"
style="margin-left: 30px"
>
<el-input
style="width: 180px"
placeholder="填写主讲人"
v-model="form.zhujiang"
:disabled="checkLock"
></el-input>
</el-form-item> </el-form-item>
</div> </div>
<div class="flex"> <div class="flex">
<el-form-item label="开始时间" prop="testStartTime"> <el-form-item label="开始时间" prop="testStartTime">
<el-date-picker <el-date-picker
style="margin-right: 50px" style="margin-right: 30px"
v-model="form.testStartTime" v-model="form.testStartTime"
value-format="yyyy-MM-dd HH:mm:ss" value-format="yyyy-MM-dd HH:mm:ss"
type="datetime" type="datetime"
...@@ -94,8 +108,8 @@ ...@@ -94,8 +108,8 @@
/> />
</el-form-item> </el-form-item>
<el-form-item label="是否人脸认证" prop="isVeriftyFace" style="margin-left: 50px"> <el-form-item label="是否人脸认证" prop="isVeriftyFace" style="margin-left: 50px">
<el-radio v-model="form.isVeriftyFace" label="1"></el-radio> <el-radio v-model="form.isVeriftyFace" label="1" :disabled="checkLock"></el-radio>
<el-radio v-model="form.isVeriftyFace" label="2"></el-radio> <el-radio v-model="form.isVeriftyFace" label="2" :disabled="checkLock"></el-radio>
</el-form-item> </el-form-item>
</div> </div>
<!-- </div> --> <!-- </div> -->
...@@ -138,15 +152,18 @@ ...@@ -138,15 +152,18 @@
</template> </template>
<script> <script>
import Editor from "./Editor"; import { treeselect } from "@/api/system/dept";
import FileUpload from "@/components/FileUpload"; import "@riophae/vue-treeselect/dist/vue-treeselect.css";
import uploadfile from "@/assets/uploadfile.png"; import Editor from "./Editor";
import { mapGetters } from "vuex"; import FileUpload from "@/components/FileUpload";
import { import uploadfile from "@/assets/uploadfile.png";
addLessons, import { mapGetters } from "vuex";
getLessonById, import {
changeLesson, addLessons,
} from "@/api/educationPlanExam/lessonsProgram"; getLessonById,
changeLesson,
} from "@/api/educationPlanExam/lessonsProgram";
import Treeselect from "@riophae/vue-treeselect";
export default { export default {
name: "", name: "",
...@@ -161,11 +178,13 @@ export default { ...@@ -161,11 +178,13 @@ export default {
components: { components: {
Editor, Editor,
FileUpload, FileUpload,
Treeselect
}, },
data() { data() {
return { return {
form: { form: {
courseName: "", courseName: "",
courseDept:"",
courseType: "", courseType: "",
courseConent: "", courseConent: "",
video: "", video: "",
...@@ -177,6 +196,9 @@ export default { ...@@ -177,6 +196,9 @@ export default {
fileListFile: [], fileListFile: [],
readOnly: false, readOnly: false,
rules: { rules: {
deptId: [
{ required: true, trigger: "blur", message: "培训部门不能为空" },
],
courseName: [ courseName: [
{ required: true, trigger: "blur", message: "课程标题不能为空" }, { required: true, trigger: "blur", message: "课程标题不能为空" },
], ],
...@@ -193,13 +215,19 @@ export default { ...@@ -193,13 +215,19 @@ export default {
duration: [ duration: [
{ required: true, trigger: "blur", message: "培训时长不能为空" }, { required: true, trigger: "blur", message: "培训时长不能为空" },
], ],
zhujiang: [
{ required: true, trigger: "blur", message: "主讲人不能为空" },
],
testStartTime: [ testStartTime: [
{ required: true, trigger: "blur", message: "开始时间不能为空" }, { required: true, trigger: "blur", message: "开始时间不能为空" },
], ],
testEndTime: [ testEndTime: [
{ required: true, trigger: "blur", message: "结束时间不能为空" }, { required: true, trigger: "blur", message: "结束时间不能为空" },
], ],
}, },
// 部门树选项
deptOptions: undefined,
}; };
}, },
computed: { computed: {
...@@ -210,6 +238,7 @@ export default { ...@@ -210,6 +238,7 @@ export default {
if (this.courseId) { if (this.courseId) {
this.getLessonById(); this.getLessonById();
} }
this.getTreeselect();
}, },
mounted() {}, mounted() {},
methods: { methods: {
...@@ -240,6 +269,8 @@ export default { ...@@ -240,6 +269,8 @@ export default {
testStartTime, testStartTime,
testEndTime, testEndTime,
isVeriftyFace, isVeriftyFace,
zhujiang,
deptId
} = data; } = data;
this.form = { this.form = {
courseName, courseName,
...@@ -251,6 +282,8 @@ export default { ...@@ -251,6 +282,8 @@ export default {
testStartTime, testStartTime,
testEndTime, testEndTime,
isVeriftyFace, isVeriftyFace,
zhujiang,
deptId
}; };
console.log('video',video) console.log('video',video)
this.fileListVideo = video? [ this.fileListVideo = video? [
...@@ -341,6 +374,13 @@ export default { ...@@ -341,6 +374,13 @@ export default {
saveAndNext() { saveAndNext() {
this.save(3); this.save(3);
}, },
/** 查询部门下拉树结构 */
getTreeselect() {
treeselect().then(response => {
console.log('部门树返回值')
this.deptOptions = response.data;
});
},
}, },
}; };
</script> </script>
......
...@@ -69,7 +69,9 @@ ...@@ -69,7 +69,9 @@
</el-row> </el-row>
<el-table v-loading="loading" :data="lessonsList"> <el-table v-loading="loading" :data="lessonsList">
<el-table-column label="培训部门" align="center" prop="deptName" width="120"/>
<el-table-column label="课程标题" align="center" prop="courseName" /> <el-table-column label="课程标题" align="center" prop="courseName" />
<el-table-column label="主讲人" align="center" prop="zhujiang" width="100"/>
<!-- <el-table-column label="课程类别" align="center" prop="planName"> <!-- <el-table-column label="课程类别" align="center" prop="planName">
<template v-slot="scope"> <template v-slot="scope">
<div> <div>
...@@ -96,12 +98,12 @@ ...@@ -96,12 +98,12 @@
</div> </div>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="课程状态" align="center" prop="status"> <el-table-column label="课程状态" align="center" prop="status" width="100">
<template v-slot="scope"> <template v-slot="scope">
<div>{{ ["未发布", "已发布"][scope.row.status] }}</div> <div>{{ ["未发布", "已发布"][scope.row.status] }}</div>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="附件" align="center" prop="enclosure"> <el-table-column label="附件" align="center" prop="enclosure" width="100">
<template v-slot="{ row: { enclosure } }"> <template v-slot="{ row: { enclosure } }">
<a <a
v-if="enclosure && enclosure.indexOf('.txt') >= 0" v-if="enclosure && enclosure.indexOf('.txt') >= 0"
......
...@@ -5,7 +5,9 @@ ...@@ -5,7 +5,9 @@
ref="queryForm" ref="queryForm"
:inline="true" :inline="true"
label-width="68px"> label-width="68px">
<el-form-item label="培训部门" prop="deptId">
<treeselect v-model="queryParams.deptId" style="width: 220px;" :options="deptOptions" :show-count="true" placeholder="请选择培训部门" />
</el-form-item>
<el-form-item label="培训名称" prop="courseName"> <el-form-item label="培训名称" prop="courseName">
<el-input <el-input
v-model="queryParams.courseName" v-model="queryParams.courseName"
...@@ -44,10 +46,11 @@ ...@@ -44,10 +46,11 @@
<!-- 培训统计列表 --> <!-- 培训统计列表 -->
<el-table v-loading="loading" :data="trainCourseStatData"> <el-table v-loading="loading" :data="trainCourseStatData">
<el-table-column label="序号" width='100' align="center" prop="courseNum"/> <el-table-column label="序号" width='100' align="center" prop="courseNum"/>
<el-table-column label="培训部门" align="center" prop="deptName" width="120"/>
<el-table-column label="课程标题" align="center" prop="courseName"/> <el-table-column label="课程标题" align="center" prop="courseName"/>
<el-table-column label="培训计划" align="center" prop="planName"/> <el-table-column label="培训计划" align="center" prop="planName"/>
<el-table-column label="应参加人数" align="center" prop="maybeTestNum"/> <el-table-column label="应参加人数" align="center" prop="maybeTestNum" width="100"/>
<el-table-column label="实际完成人数" align="center" prop="finishNum"/> <el-table-column label="实际完成人数" align="center" prop="finishNum" width="100"/>
<el-table-column <el-table-column
label="操作" label="操作"
align="center" align="center"
...@@ -108,9 +111,12 @@ ...@@ -108,9 +111,12 @@
<script> <script>
import {getTrainCourseStatData,getTrainCourseStatDetailData,trainCourseStatDetailExport} from "@/api/contractTrain/trainCourseStat"; import {getTrainCourseStatData,getTrainCourseStatDetailData,trainCourseStatDetailExport} from "@/api/contractTrain/trainCourseStat";
import { treeselect } from "@/api/system/dept";
import Treeselect from "@riophae/vue-treeselect";
export default { export default {
name: "trainCourseStat", name: "trainCourseStat",
components: { components: {
Treeselect
}, },
data() { data() {
return { return {
...@@ -136,13 +142,23 @@ export default { ...@@ -136,13 +142,23 @@ export default {
courseName: "", courseName: "",
trainStatDetailOpen: false, trainStatDetailOpen: false,
trainStatDetailData: [], trainStatDetailData: [],
exportLoading: false exportLoading: false,
// 部门树选项
deptOptions: undefined,
} }
}, },
created() { created() {
this.getTrainStatList(); this.getTrainStatList();
this.getTreeselect();
}, },
methods: { methods: {
/** 查询部门下拉树结构 */
getTreeselect() {
treeselect().then(response => {
console.log('部门树返回值')
this.deptOptions = response.data;
});
},
dateFormat(picker){ dateFormat(picker){
this.queryParams.releaseBeginTime = picker[0]; this.queryParams.releaseBeginTime = picker[0];
this.queryParams.releaseEndTime = picker[1]; this.queryParams.releaseEndTime = picker[1];
......
...@@ -20,16 +20,6 @@ ...@@ -20,16 +20,6 @@
></el-option> ></el-option>
</el-select> </el-select>
</el-form-item> </el-form-item>
<!--<el-form-item label="事故类型" prop="riskType">-->
<!--<el-select v-model="queryParams.riskType" placeholder="请选择事故类型" clearable size="small">-->
<!--<el-option-->
<!--v-for="dict in riskTypeOptions"-->
<!--:key="dict.dictValue"-->
<!--:label="dict.dictLabel"-->
<!--:value="dict.dictValue"-->
<!--&gt;</el-option>-->
<!--</el-select>-->
<!--</el-form-item>-->
<el-form-item label="责任部门" prop="riskDept"> <el-form-item label="责任部门" prop="riskDept">
<el-select <el-select
...@@ -102,8 +92,15 @@ ...@@ -102,8 +92,15 @@
<el-table v-loading="loading" :data="managerList" @selection-change="handleSelectionChange"> <el-table v-loading="loading" :data="managerList" @selection-change="handleSelectionChange">
<el-table-column type="selection" width="55" align="center" /> <el-table-column type="selection" width="55" align="center" />
<el-table-column label="序号" width="55" align="center" prop="id" /> <el-table-column label="序号" width="50" align="center" prop="id" />
<el-table-column label="辨识部位" width="135" align="center" prop="riskPart" /> <el-table-column label="辨识部位" width="135" align="center" prop="riskPart" />
<el-table-column label="清单类型" width="90" align="center" prop="listType" >
<template slot-scope="scope">
<span v-if="scope.row.listType === '1' ">设备实施</span>
<span v-else-if="scope.row.listType === '2'">作业活动</span>
<span v-else >-</span>
</template>
</el-table-column>
<el-table-column label="存在风险" align="center" prop="riskContent" > <el-table-column label="存在风险" align="center" prop="riskContent" >
<template slot-scope="scope"> <template slot-scope="scope">
<dl v-html="scope.row.riskContent"> <dl v-html="scope.row.riskContent">
...@@ -143,50 +140,81 @@ ...@@ -143,50 +140,81 @@
/> />
<!-- 添加或修改【风险信息】对话框 --> <!-- 添加或修改【风险信息】对话框 -->
<el-dialog :title="title" :visible.sync="open" width="500px" append-to-body> <el-dialog :title="title" :visible.sync="open" width="800px" append-to-body>
<el-form ref="form" :model="form" :rules="rules" label-width="80px"> <el-form ref="form" :model="form" :rules="rules" label-width="80px">
<el-form-item label="辨识部位" prop="riskPart"> <el-row :gutter="24">
<el-input v-model="form.riskPart" placeholder="请输入辨识部位" /> <el-col span="12">
</el-form-item> <el-form-item label="辨识部位" prop="riskPart">
<el-form-item label="存在风险"> <el-input v-model="form.riskPart" placeholder="请输入辨识部位" />
<editor v-model="form.riskContent" :min-height="192"/> </el-form-item>
</el-form-item> </el-col>
<el-form-item label="风险等级" prop="riskLevel"> <el-col span="12">
<el-select v-model="form.riskLevel" placeholder="请输入风险等级"> <el-form-item label="清单类型" prop="listType">
<el-option <el-select v-model="form.listType" placeholder="请选择清单类型" style="width: 290px">
v-for="dict in riskLevelOptions" <el-option label="设备实施" value="1" />
:key="dict.dictValue" <el-option label="作业活动" value="2" />
:label="dict.dictLabel" </el-select>
:value="dict.dictValue" </el-form-item>
></el-option> </el-col>
</el-select> </el-row>
</el-form-item> <el-row>
<el-form-item label="事故类型" prop="riskType"> <el-col span="12">
<el-select v-model="form.riskType" multiple placeholder="请选择事故类型"> <el-form-item label="风险等级" prop="riskLevel">
<el-option <el-select v-model="form.riskLevel" placeholder="请输入风险等级" style="width: 290px">
v-for="dict in riskTypeOptions" <el-option
:key="dict.dictValue" v-for="dict in riskLevelOptions"
:label="dict.dictLabel" :key="dict.dictValue"
:value="dict.dictValue" :label="dict.dictLabel"
></el-option> :value="dict.dictValue"
</el-select> ></el-option>
</el-form-item> </el-select>
<el-form-item label="管控措施" prop="riskControl"> </el-form-item>
<el-input v-model="form.riskControl" placeholder="请输入管控措施" /> </el-col>
</el-form-item> <el-col span="12" style="padding-left: 12px">
<el-form-item label="责任部门" prop="riskDept"> <el-form-item label="事故类型" prop="riskType">
<el-select v-model="form.riskDept" placeholder="请输入责任部门" > <el-select v-model="form.riskType" multiple placeholder="请选择事故类型" style="width: 290px">
<el-option <el-option
v-for="dict in deptList" v-for="dict in riskTypeOptions"
:key="dict.deptId" :key="dict.dictValue"
:label="dict.deptName" :label="dict.dictLabel"
:value="dict.deptId" :value="dict.dictValue"
></el-option> ></el-option>
</el-select> </el-select>
</el-form-item> </el-form-item>
<el-form-item label="责任人" prop="riskPerson"> </el-col>
<el-input v-model="form.riskPerson" placeholder="请输入责任人" /> </el-row>
</el-form-item>
<el-row>
<el-form-item label="存在风险">
<editor v-model="form.riskContent" :min-height="192"/>
</el-form-item>
</el-row>
<el-row>
<el-form-item label="管控措施" prop="riskControl">
<el-input type="textarea" v-model="form.riskControl" placeholder="请输入管控措施" />
</el-form-item>
</el-row>
<el-row>
<el-col span="12">
<el-form-item label="责任部门" prop="riskDept">
<el-select v-model="form.riskDept" placeholder="请输入责任部门" style="width: 290px">
<el-option
v-for="dict in deptList"
:key="dict.deptId"
:label="dict.deptName"
:value="dict.deptId"
></el-option>
</el-select>
</el-form-item>
</el-col>
<el-col span="12">
<el-form-item label="责任人" prop="riskPerson">
<el-input v-model="form.riskPerson" placeholder="请输入责任人" style="width: 300px"/>
</el-form-item>
</el-col>
</el-row>
</el-form> </el-form>
<div slot="footer" class="dialog-footer"> <div slot="footer" class="dialog-footer">
<el-button type="primary" @click="submitForm">确 定</el-button> <el-button type="primary" @click="submitForm">确 定</el-button>
...@@ -249,6 +277,9 @@ export default { ...@@ -249,6 +277,9 @@ export default {
riskPart: [ riskPart: [
{ required: true, message: "辨识部位不能为空", trigger: "blur" } { required: true, message: "辨识部位不能为空", trigger: "blur" }
], ],
listType: [
{ required: true, message: "清单类型不能为空", trigger: "blur" }
],
riskDept: [ riskDept: [
{ required: true, message: "责任部门不能为空", trigger: "blur" } { required: true, message: "责任部门不能为空", trigger: "blur" }
], ],
...@@ -324,6 +355,7 @@ export default { ...@@ -324,6 +355,7 @@ export default {
this.form = { this.form = {
id: null, id: null,
riskPart: null, riskPart: null,
listType:null,
riskContent: null, riskContent: null,
riskLevel: null, riskLevel: null,
riskType: null, riskType: null,
......
...@@ -59,8 +59,8 @@ ...@@ -59,8 +59,8 @@
<!--<el-table-column label="风险点" align="center" prop="libraryId" />--> <!--<el-table-column label="风险点" align="center" prop="libraryId" />-->
<el-table-column label="所属部门" align="center" prop="deptName" /> <el-table-column label="所属部门" align="center" prop="deptName" />
<el-table-column label="风险点" align="center" prop="riskPointName" /> <el-table-column label="风险点" align="center" prop="riskPointName" />
<el-table-column label="隐患名称" align="center" prop="inspectTerm" /> <el-table-column label="风险描述" align="center" prop="inspectTerm" />
<el-table-column label="检查依据" align="center" prop="inspectBasis" /> <!-- <el-table-column label="检查依据" align="center" prop="inspectBasis" />-->
<!--<el-table-column label="排查库标题" align="center" prop="libraryName" />--> <!--<el-table-column label="排查库标题" align="center" prop="libraryName" />-->
<el-table-column label="内容以及标准" align="center" prop="libraryContent" /> <el-table-column label="内容以及标准" align="center" prop="libraryContent" />
<el-table-column label="操作" align="center" class-name="small-padding fixed-width"> <el-table-column label="操作" align="center" class-name="small-padding fixed-width">
...@@ -120,17 +120,17 @@ ...@@ -120,17 +120,17 @@
></el-option> ></el-option>
</el-select> </el-select>
</el-form-item> </el-form-item>
<el-form-item label="隐患名称" prop="inspectTerm"> <el-form-item label="风险描述" prop="inspectTerm">
<el-input v-model="form.inspectTerm" placeholder="请输入隐患名称" /> <el-input v-model="form.inspectTerm" placeholder="请输入风险描述" />
</el-form-item>
<el-form-item label="检查依据" prop="inspectBasis">
<el-input type="textarea" v-model="form.inspectBasis" placeholder="请输入检查依据" />
</el-form-item> </el-form-item>
<!-- <el-form-item label="检查依据" prop="inspectBasis">-->
<!-- <el-input type="textarea" v-model="form.inspectBasis" placeholder="请输入检查依据" />-->
<!-- </el-form-item>-->
<!--<el-form-item label="排查库标题" prop="libraryName">--> <!--<el-form-item label="排查库标题" prop="libraryName">-->
<!--<el-input v-model="form.libraryName" placeholder="请输入排查库标题" />--> <!--<el-input v-model="form.libraryName" placeholder="请输入排查库标题" />-->
<!--</el-form-item>--> <!--</el-form-item>-->
<el-form-item label="内容以及标准" prop="libraryContent"> <el-form-item label="内容以及标准" prop="libraryContent">
<el-input type="textarea" v-model="form.libraryContent" :min-height="192"/> <el-input type="textarea" v-model="form.libraryContent" style="height: 100px"/>
</el-form-item> </el-form-item>
</el-form> </el-form>
<div slot="footer" class="dialog-footer"> <div slot="footer" class="dialog-footer">
...@@ -202,7 +202,7 @@ export default { ...@@ -202,7 +202,7 @@ export default {
{ required: true, message: "风险点不能为空", trigger: "change" } { required: true, message: "风险点不能为空", trigger: "change" }
], ],
inspectTerm: [ inspectTerm: [
{ required: true, message: "隐患名称不能为空", trigger: "change" } { required: true, message: "风险描述不能为空", trigger: "change" }
], ],
// inspectBasis: [ // inspectBasis: [
// { required: true, message: "检查依据不能为空", trigger: "change" } // { required: true, message: "检查依据不能为空", trigger: "change" }
......
...@@ -150,10 +150,6 @@ ...@@ -150,10 +150,6 @@
<el-form ref="form" :model="form" :rules="rules" label-width="80px"> <el-form ref="form" :model="form" :rules="rules" label-width="80px">
<el-row :gutter="24" > <el-row :gutter="24" >
<el-col :span="10"> <el-col :span="10">
<el-form-item label="任务名称" prop="workName">
<el-input v-model="form.workName" placeholder="请输入任务名称" />
</el-form-item>
<el-form-item label="任务周期" prop="workCycle"> <el-form-item label="任务周期" prop="workCycle">
<el-select v-model="form.workCycle" placeholder="请选择任务周期"> <el-select v-model="form.workCycle" placeholder="请选择任务周期">
<el-option <el-option
...@@ -164,7 +160,40 @@ ...@@ -164,7 +160,40 @@
></el-option> ></el-option>
</el-select> </el-select>
</el-form-item> </el-form-item>
</el-col>
<el-col :span="14">
<el-form-item label="任务名称" prop="workName">
<el-input v-model="form.workName" placeholder="请输入任务名称" />
</el-form-item>
</el-col>
</el-row>
<el-row :gutter="24" >
<el-col :span="10">
<el-form-item label="开始时间" prop="workBeginTime">
<el-date-picker clearable size="small"
style = "width: 100%"
v-model="form.workBeginTime"
type="datetime"
value-format="yyyy-MM-dd HH:mm:ss"
placeholder="选择排查开始时间">
</el-date-picker>
</el-form-item>
</el-col>
<el-col :span="14">
<el-form-item label="结束时间" prop="workEndTime">
<el-date-picker clearable size="small"
style = "width: 100%"
v-model="form.workEndTime"
type="datetime"
value-format="yyyy-MM-dd HH:mm:ss"
placeholder="选择排查结束时间">
</el-date-picker>
</el-form-item>
</el-col>
</el-row>
<el-row :gutter="24" >
<el-col :span="10">
<el-form-item label="排查类型" prop="workType"> <el-form-item label="排查类型" prop="workType">
<el-select v-model="form.workType" placeholder="请选择任务排查类型"> <el-select v-model="form.workType" placeholder="请选择任务排查类型">
<el-option <el-option
...@@ -175,6 +204,8 @@ ...@@ -175,6 +204,8 @@
></el-option> ></el-option>
</el-select> </el-select>
</el-form-item> </el-form-item>
</el-col>
<el-col :span="14">
<el-form-item label="排查形式" prop="workForm"> <el-form-item label="排查形式" prop="workForm">
<el-select v-model="form.workForm" placeholder="请选择任务排查形式"> <el-select v-model="form.workForm" placeholder="请选择任务排查形式">
<el-option <el-option
...@@ -185,27 +216,12 @@ ...@@ -185,27 +216,12 @@
></el-option> ></el-option>
</el-select> </el-select>
</el-form-item> </el-form-item>
<el-form-item label="开始时间" prop="workBeginTime"> </el-col>
<el-date-picker clearable size="small" </el-row>
style = "width: 100%"
v-model="form.workBeginTime"
type="datetime" <el-row :gutter="24" >
value-format="yyyy-MM-dd HH:mm:ss" <el-col :span="10">
placeholder="选择排查开始时间">
</el-date-picker>
</el-form-item>
<el-form-item label="结束时间" prop="workEndTime">
<el-date-picker clearable size="small"
style = "width: 100%"
v-model="form.workEndTime"
type="datetime"
value-format="yyyy-MM-dd HH:mm:ss"
placeholder="选择排查结束时间">
</el-date-picker>
</el-form-item>
<!--<el-form-item label="责任部门" prop="deptId">-->
<!--<el-input v-model="form.deptId" placeholder="请输入责任部门" />-->
<!--</el-form-item>-->
<el-form-item label="责任部门" prop="deptId"> <el-form-item label="责任部门" prop="deptId">
<!--<el-input v-model="form.deptId" placeholder="请输入部门id" />--> <!--<el-input v-model="form.deptId" placeholder="请输入部门id" />-->
<el-select v-model="form.deptId" @change="selectUserList" filterable placeholder="请选择责任部门"> <el-select v-model="form.deptId" @change="selectUserList" filterable placeholder="请选择责任部门">
...@@ -217,6 +233,9 @@ ...@@ -217,6 +233,9 @@
></el-option> ></el-option>
</el-select> </el-select>
</el-form-item> </el-form-item>
</el-col>
<el-col :span="14">
<el-form-item label="责任人" prop="staffId"> <el-form-item label="责任人" prop="staffId">
<el-select v-model="form.staffId" filterable placeholder="请选择责任人"> <el-select v-model="form.staffId" filterable placeholder="请选择责任人">
<el-option <el-option
...@@ -228,25 +247,11 @@ ...@@ -228,25 +247,11 @@
</el-option> </el-option>
</el-select> </el-select>
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="14"> </el-row>
<!--<el-form-item label="关联隐患" prop="bookId">--> <el-row>
<!--<el-input v-model="form.bookId" placeholder="请" />--> <el-col>
<!--</el-form-item>-->
<!--<el-form-item label="关联隐患" prop="bookId">-->
<!--&lt;!&ndash;<el-input v-model="form.deptId" placeholder="请输入部门id" />&ndash;&gt;-->
<!--<el-select v-model="form.bookId" placeholder="请选择关联隐患">-->
<!--<el-option-->
<!--v-for="dict in bookList"-->
<!--:key="dict.bookId"-->
<!--:label="dict.troubleName"-->
<!--:value="parseInt(dict.bookId)"-->
<!--&gt;</el-option>-->
<!--</el-select>-->
<!--</el-form-item>-->
<el-form-item label="任务范围" prop="workRange">
<el-input v-model="form.workRange" placeholder="请输入任务范围" />
</el-form-item>
<el-form-item label="排查库" prop="libraryId"> <el-form-item label="排查库" prop="libraryId">
<!--<el-input v-model="form.deptId" placeholder="请输入部门id" />--> <!--<el-input v-model="form.deptId" placeholder="请输入部门id" />-->
<el-select v-model="form.libraryId" multiple filterable placeholder="请选择" @change="selectLibrary"> <el-select v-model="form.libraryId" multiple filterable placeholder="请选择" @change="selectLibrary">
...@@ -258,15 +263,15 @@ ...@@ -258,15 +263,15 @@
></el-option> ></el-option>
</el-select> </el-select>
</el-form-item> </el-form-item>
<!--<el-form-item label="排查内容" prop="content">-->
<!--<editor v-model="form.content" :min-height="200"/>-->
<!--</el-form-item>-->
</el-col> </el-col>
</el-row> </el-row>
<el-row :gutter="24" >
<!--<el-form-item label="任务期限" prop="timeTerm">--> <el-col :span="24">
<!--<el-input v-model="form.timeTerm" placeholder="请输入任务期限" />--> <el-form-item label="任务范围" prop="workRange">
<!--</el-form-item>--> <el-input type="textarea" :min-height="192" v-model="form.workRange" placeholder="请输入任务范围" />
</el-form-item>
</el-col>
</el-row>
</el-form> </el-form>
<div slot="footer" class="dialog-footer"> <div slot="footer" class="dialog-footer">
...@@ -864,6 +869,7 @@ export default { ...@@ -864,6 +869,7 @@ export default {
this.userList = response.rows; this.userList = response.rows;
}); });
listLibrary({pageNum:1,pageSize:10000,deptId:deptId}).then(response => { listLibrary({pageNum:1,pageSize:10000,deptId:deptId}).then(response => {
console.log("sdfsdfsdfssssssssssssssssssssssss")
this.libraryList = response.rows; this.libraryList = response.rows;
}); });
}, },
......
...@@ -187,7 +187,7 @@ export default { ...@@ -187,7 +187,7 @@ export default {
} }
.top { .top {
background: #f9f9f9; background: #f9f9f9;
height: 54px; height: 100px;
padding: 0px 10px 0px 43px; padding: 0px 10px 0px 43px;
overflow-wrap: anywhere; overflow-wrap: anywhere;
// align-items: center; // align-items: center;
...@@ -200,13 +200,13 @@ export default { ...@@ -200,13 +200,13 @@ export default {
.num { .num {
position: absolute; position: absolute;
left: 0; left: 0;
width: 48px; width: 40px;
height: 48px; height: 40px;
top: 4px; top: 4px;
background: #1d84ff; background: #1d84ff;
border-radius: 50%; border-radius: 50%;
text-align: center; text-align: center;
line-height: 48px; line-height: 40px;
font-size: 18px; font-size: 18px;
color: #ffffff; color: #ffffff;
} }
...@@ -219,7 +219,7 @@ export default { ...@@ -219,7 +219,7 @@ export default {
padding-right: 10px; padding-right: 10px;
margin-bottom: 15px; margin-bottom: 15px;
.item { .item {
padding-top: 38px; padding-top: 20px;
width: 100%; width: 100%;
overflow-wrap: anywhere; overflow-wrap: anywhere;
font-size: 14px; font-size: 14px;
......
...@@ -195,7 +195,7 @@ export default { ...@@ -195,7 +195,7 @@ export default {
} }
.top { .top {
background: #f9f9f9; background: #f9f9f9;
height: 54px; height: 100px;
padding: 0px 10px 0px 43px; padding: 0px 10px 0px 43px;
overflow-wrap: anywhere; overflow-wrap: anywhere;
// align-items: center; // align-items: center;
...@@ -208,13 +208,13 @@ export default { ...@@ -208,13 +208,13 @@ export default {
.num { .num {
position: absolute; position: absolute;
left: 0; left: 0;
width: 48px; width: 40px;
height: 48px; height: 40px;
top: 4px; top: 4px;
background: #1d84ff; background: #1d84ff;
border-radius: 50%; border-radius: 50%;
text-align: center; text-align: center;
line-height: 48px; line-height: 40px;
font-size: 18px; font-size: 18px;
color: #ffffff; color: #ffffff;
} }
...@@ -227,7 +227,7 @@ export default { ...@@ -227,7 +227,7 @@ export default {
padding-right: 10px; padding-right: 10px;
margin-bottom: 15px; margin-bottom: 15px;
.item { .item {
padding-top: 38px; padding-top: 20px;
width: 100%; width: 100%;
overflow-wrap: anywhere; overflow-wrap: anywhere;
font-size: 14px; font-size: 14px;
......
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