pull/1/head
z 2024-01-12 18:21:07 +08:00
parent b30aaf9f34
commit 2fe776a3f6
44 changed files with 1638 additions and 147 deletions

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.2 KiB

BIN
src/assets/images/map/h.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.5 KiB

View File

@ -307,6 +307,79 @@ export default [
},
],
},
{
path: "/hazard_investigation/checklist_inspection_status",
meta: { title: "清单检查情况", isSubMenu: false },
component: "children",
children: [
{
path: "",
component: "hazard_investigation/checklist_inspection_status/index",
},
{
path: "/hazard_investigation/checklist_inspection_status/inspection_record",
meta: {
title: "检查记录",
activeMenu: "/hazard_investigation/checklist_inspection_status",
},
component: "children",
children: [
{
path: "",
component:
"hazard_investigation/checklist_inspection_status/inspection_record",
},
{
path: "/hazard_investigation/checklist_inspection_status/inspection_record/supplementary_recording",
meta: {
title: "补录",
activeMenu:
"/hazard_investigation/checklist_inspection_status",
},
component:
"hazard_investigation/checklist_inspection_status/supplementary_recording",
},
{
path: "/hazard_investigation/checklist_inspection_status/inspection_record/view",
meta: {
title: "详情",
activeMenu:
"/hazard_investigation/checklist_inspection_status",
},
component: "children",
children: [
{
path: "",
component:
"hazard_investigation/checklist_inspection_status/inspection_record_view",
},
{
path: "/hazard_investigation/checklist_inspection_status/inspection_record/view/hidden_danger",
meta: {
title: "隐患信息",
activeMenu:
"/hazard_investigation/checklist_inspection_status",
},
component:
"hazard_investigation/checklist_inspection_status/hidden_danger_view",
},
],
},
],
},
],
},
{
path: "/hazard_investigation/inspection_record",
meta: { title: "检查记录管理", isSubMenu: false },
component: "children",
children: [
{
path: "",
component: "hazard_investigation/inspection_record/index",
},
],
},
],
},
{

View File

@ -17,7 +17,6 @@ export default function usePrint() {
elements = document.querySelectorAll("#printContent > table > tr");
const thead = document.querySelector("#printContent > table thead");
if (thead) A4_HEIGHT_PX = A4_HEIGHT_PX - thead.offsetHeight;
else A4_HEIGHT_PX = A4_HEIGHT_PX + thead.offsetHeight;
fnIsPaging();
buttonRef.value.$el.click();
};

View File

@ -35,6 +35,10 @@ const props = defineProps({
type: String,
default: "600px",
},
visible: {
type: Boolean,
default: false,
},
});
const visibility = useDocumentVisibility();
onMounted(() => {
@ -51,9 +55,9 @@ onMounted(() => {
() => visibility.value,
() => {
if (visibility.value === "hidden") {
pause();
props.visible && pause();
} else {
play();
props.visible && play();
}
},
{

View File

@ -22,7 +22,6 @@
</template>
<script setup>
import LayoutCard from "@/components/card/index.vue";
import usePrint from "@/assets/js/usePrint.js";
defineOptions({

View File

@ -5,6 +5,7 @@
:vid="vid"
:play-auth="playAuth"
ref="playerRef"
:visible="visible"
/>
</el-dialog>
</template>

View File

@ -50,3 +50,22 @@ export const setInventoryTroubleshootingOtherHiddenDangerListAdd = (params) =>
post("/hidden/listAdd", params); // 清单排查其它隐患添加
export const setInventoryTroubleshootingSubmit = (params) =>
post("/checkrecord/add", params); // 清单排查提交
export const getChecklistInspectionStatusList = (params) =>
post("/listmanager/recordList", params); // 清单检查情况列表
export const getChecklistInspectionStatusRecordList = (params) =>
post("/checkrecord/list", params); // 清单检查情况检查记录列表
export const setChecklistInspectionStatusRecordDelete = (params) =>
post("/checkrecord/delete", params); // 清单检查情况检查记录删除
export const setChecklistInspectionStatusRecordSupplementaryRecordingSubmit = (
params
) => post("/checkrecord/recording", params); // 清单检查情况检查记录补录提交
export const getChecklistInspectionStatusRecordView = (params) =>
post("/checkrecord/goEdit", params); // 清单检查情况检查记录查看
export const getChecklistInspectionStatusRecordViewOtherHiddenDangerList = (
params
) => post("/hidden/getCheckHidden", params); // 清单检查情况检查记录查看其它隐患列表
export const getChecklistInspectionStatusRecordMap = (params) =>
post("/checkrecord/goMap", params); // 清单检查情况检查记录查看地图
export const getHiddenDangerView = (params) => post("/hidden/goEdit", params); // 清单排查隐患查看
export const getInspectionRecordList = (params) =>
post("/checkrecord/allList", params); // 检查记录管理列表

View File

@ -22,7 +22,6 @@
</layout-card>
</template>
<script setup>
import LayoutTable from "@/components/table/index.vue";
import ArchivesPdf from "./components/archives_pdf.vue";
import Capital from "./components/capital.vue";
import Edumanager from "./components/edumanager.vue";

View File

@ -155,7 +155,6 @@ import {
import { reactive } from "vue";
import { useVModels } from "@vueuse/core";
import { useUserStore } from "@/pinia/user.js";
import LayoutTable from "@/components/table/index.vue";
import { serialNumber } from "@/assets/js/utils.js";
import CapitalForm from "./capital_form.vue";
import { ElMessageBox } from "element-plus";

View File

@ -124,7 +124,6 @@ import {
import { reactive } from "vue";
import { useVModels } from "@vueuse/core";
import { useUserStore } from "@/pinia/user.js";
import LayoutTable from "@/components/table/index.vue";
import { serialNumber } from "@/assets/js/utils.js";
import EdumanagerForm from "./edumanager_form.vue";
import { ElMessageBox } from "element-plus";

View File

@ -127,7 +127,6 @@ import {
import { reactive } from "vue";
import { useVModels } from "@vueuse/core";
import { useUserStore } from "@/pinia/user.js";
import LayoutTable from "@/components/table/index.vue";
import { serialNumber } from "@/assets/js/utils.js";
import EduplanForm from "./eduplan_form.vue";
import { ElMessageBox } from "element-plus";

View File

@ -104,7 +104,6 @@ import {
import { reactive } from "vue";
import { useVModels } from "@vueuse/core";
import { useUserStore } from "@/pinia/user.js";
import LayoutTable from "@/components/table/index.vue";
import { serialNumber } from "@/assets/js/utils.js";
import PostmanForm from "./postman_form.vue";
import { ElMessageBox } from "element-plus";

View File

@ -119,7 +119,6 @@ import {
import { reactive } from "vue";
import { useVModels } from "@vueuse/core";
import { useUserStore } from "@/pinia/user.js";
import LayoutTable from "@/components/table/index.vue";
import { serialNumber } from "@/assets/js/utils.js";
import TeacherForm from "./teacher_form.vue";
import { ElMessageBox } from "element-plus";

View File

@ -175,7 +175,6 @@ import {
} from "@/request/archives.js";
import { computed, reactive } from "vue";
import { useVModels } from "@vueuse/core";
import LayoutTable from "@/components/table/index.vue";
import { useUserStore } from "@/pinia/user.js";
import { serialNumber } from "@/assets/js/utils.js";
import { PRINT_STYLE } from "@/assets/js/constant.js";

View File

@ -88,7 +88,6 @@ import {
} from "@/request/archives.js";
import { computed, reactive } from "vue";
import { useVModels } from "@vueuse/core";
import LayoutTable from "@/components/table/index.vue";
import { PRINT_STYLE } from "@/assets/js/constant.js";
const props = defineProps({

View File

@ -135,7 +135,6 @@ import {
import { reactive } from "vue";
import { useVModels } from "@vueuse/core";
import { useUserStore } from "@/pinia/user.js";
import LayoutTable from "@/components/table/index.vue";
import { serialNumber } from "@/assets/js/utils.js";
import TrainingScheduleForm from "./training_schedule_form.vue";
import { ElMessageBox } from "element-plus";

View File

@ -117,8 +117,6 @@
import { reactive } from "vue";
import useListData from "@/assets/js/useListData.js";
import { getTaskList } from "@/request/archives.js";
import LayoutCard from "@/components/card/index.vue";
import LayoutTable from "@/components/table/index.vue";
import { serialNumber } from "@/assets/js/utils.js";
import { useRouter } from "vue-router";

View File

@ -152,8 +152,6 @@
</template>
<script setup>
import LayoutTable from "@/components/table/index.vue";
import LayoutCard from "@/components/card/index.vue";
import { getTaskListByUser } from "@/request/archives.js";
import useListData from "@/assets/js/useListData.js";
import { reactive } from "vue";

View File

@ -95,9 +95,7 @@
<script setup>
import { nextTick, reactive } from "vue";
import LayoutTable from "@/components/table/index";
import { serialNumber } from "@/assets/js/utils";
import LayoutCard from "@/components/card/index.vue";
import {
getLedgerList,
setLedgerDelete,

View File

@ -45,7 +45,6 @@
</template>
<script setup>
import LayoutCard from "@/components/card/index.vue";
import LayoutUpload from "@/components/upload/index.vue";
import { reactive, ref } from "vue";
import {

View File

@ -29,7 +29,6 @@
</template>
<script setup>
import LayoutCard from "@/components/card/index.vue";
import { getIndustryQualificationsView } from "@/request/enterprise_management.js";
import { ref } from "vue";
import { useRoute } from "vue-router";

View File

@ -0,0 +1,111 @@
<template>
<el-dialog title="请选择位置" v-model="visible">
<el-form label-position="right" label-width="50px">
<el-row>
<el-col :span="12">
<el-form-item label="坐标">
<el-input disabled :model-value="currentLongitude || longitude" />
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label-width="10px">
<el-input disabled :model-value="currentLatitude || latitude" />
</el-form-item>
</el-col>
</el-row>
</el-form>
<div
v-loading="loading"
element-loading-text="地图正在加载中..."
element-loading-background="rgba(0, 0, 0, 0.5)"
>
<div style="width: 100%; height: 500px" id="map_container" />
</div>
<template #footer>
<el-button @click="fnClose"></el-button>
<el-button type="primary" @click="fnConfirm"></el-button>
</template>
</el-dialog>
</template>
<script setup>
import { useVModels } from "@vueuse/core";
import { nextTick, onBeforeUnmount, ref, watch } from "vue";
let mapInstance;
const props = defineProps({
visible: {
type: Boolean,
required: true,
default: false,
},
longitude: {
type: [Number, String],
required: true,
default: "",
},
latitude: {
type: [Number, String],
required: true,
default: "",
},
});
const emits = defineEmits([
"update:visible",
"update:longitude",
"update:latitude",
]);
const { visible, longitude, latitude } = useVModels(props, emits);
const loading = ref(false);
const currentLongitude = ref("");
const currentLatitude = ref("");
const fnMapInit = async () => {
loading.value = true;
await nextTick();
mapInstance = new window.BMapGL.Map("map_container");
mapInstance.centerAndZoom(
new window.BMapGL.Point(
props.longitude || "116.3972282409668",
props.latitude || "39.90960456049752"
),
16
);
mapInstance.enableScrollWheelZoom(true);
mapInstance.setMapStyleV2({
styleId: "6f501abeb2a0cc0d961d110b9407b127",
});
loading.value = false;
mapInstance.addEventListener("click", function (event) {
currentLatitude.value = event.latlng.lat;
currentLongitude.value = event.latlng.lng;
});
};
const fnClose = () => {
visible.value = false;
};
const fnConfirm = () => {
latitude.value = currentLatitude.value;
longitude.value = currentLongitude.value;
fnClose();
};
const stop = watch(
() => props.visible,
(val) => {
if (val && !mapInstance) {
fnMapInit();
stop && stop();
}
},
{
immediate: true,
}
);
onBeforeUnmount(() => {
if (mapInstance) {
mapInstance.destroy();
mapInstance = null;
}
});
</script>
<style scoped lang="scss"></style>

View File

@ -106,7 +106,7 @@
<el-button
type="primary"
class="ml-10"
@click="fnMapDialogVisible"
@click="data.mapDialogVisible = true"
>
地图定位
</el-button>
@ -427,38 +427,16 @@
<el-button type="primary" @click="fnSubmit"> </el-button>
</div>
</layout-card>
<el-dialog title="请选择位置" v-model="data.mapDialog.visible">
<el-form label-position="right" label-width="50px">
<el-row>
<el-col :span="12">
<el-form-item label="坐标">
<el-input disabled v-model="data.mapDialog.lng" />
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label-width="10px">
<el-input disabled v-model="data.mapDialog.lat" />
</el-form-item>
</el-col>
</el-row>
</el-form>
<div
v-loading="data.mapDialog.loading"
element-loading-text="地图正在加载中..."
element-loading-background="rgba(0, 0, 0, 0.5)"
>
<div style="width: 100%; height: 500px" id="map_container" />
</div>
<template #footer>
<el-button @click="fnMapDialogVisible"></el-button>
<el-button type="primary" @click="fnMapDialogConfirm"></el-button>
</template>
</el-dialog>
<map-dialog
v-model:visible="data.mapDialogVisible"
v-model:latitude="data.form.LATITUDE"
v-model:longitude="data.form.LONGITUDE"
/>
</div>
</template>
<script setup>
import { nextTick, onBeforeUnmount, reactive, ref } from "vue";
import { reactive, ref } from "vue";
import LayoutTerritory from "@/components/territory/index.vue";
import LayoutRegulatoryType from "@/components/regulatory_type/index.vue";
import LayoutIndustry from "@/components/industry/index.vue";
@ -479,8 +457,8 @@ import {
setEnterpriseInfo,
} from "@/request/enterprise_management.js";
import { addingPrefixToFile } from "@/assets/js/utils.js";
import MapDialog from "./components/map.vue";
let mapInstance;
const router = useRouter();
const formRef = ref(null);
const territoryCascaderRef = ref(null);
@ -608,12 +586,7 @@ const data = reactive({
WHETHER_LIQUIDAMMONIA: "",
WHETHER_PIPELINE: "",
},
mapDialog: {
visible: false,
loading: true,
lat: "",
lng: "",
},
mapDialogVisible: false,
});
const fnGetData = async () => {
const resData = await getEnterpriseInfo();
@ -627,39 +600,6 @@ fnGetData();
const enterpriseStatus = await layoutFnGetEnterpriseStatus();
const subordination = await layoutFnGetSubordination();
const enterpriseScale = await layoutFnGetEnterpriseScale();
const fnMapInit = () => {
mapInstance = new window.BMapGL.Map("map_container");
mapInstance.centerAndZoom(
new window.BMapGL.Point(
data.form.LONGITUDE || "116.3972282409668",
data.form.LATITUDE || "39.90960456049752"
),
16
);
mapInstance.enableScrollWheelZoom(true);
mapInstance.setMapStyleV2({
styleId: "6f501abeb2a0cc0d961d110b9407b127",
});
data.mapDialog.loading = false;
mapInstance.addEventListener("click", function (event) {
data.mapDialog.lat = event.latlng.lat;
data.mapDialog.lng = event.latlng.lng;
});
};
const fnMapDialogVisible = async () => {
data.mapDialog.visible = !data.mapDialog.visible;
data.mapDialog.lat = data.form.LATITUDE;
data.mapDialog.lng = data.form.LONGITUDE;
if (!mapInstance) {
await nextTick();
fnMapInit();
}
};
const fnMapDialogConfirm = () => {
data.form.LATITUDE = data.mapDialog.lat;
data.form.LONGITUDE = data.mapDialog.lng;
fnMapDialogVisible();
};
const fnProhibitSelect = () => {
ElMessage.error("请联系管理员制作3D图");
data.form.FOURTYPE = 1;
@ -708,12 +648,6 @@ const fnSubmit = debounce(
},
{ atBegin: true }
);
onBeforeUnmount(() => {
if (mapInstance) {
mapInstance.destroy();
mapInstance = null;
}
});
</script>
<style scoped lang="scss"></style>

View File

@ -0,0 +1,129 @@
<template>
<el-dialog v-model="visible" title="地图">
<div
v-loading="loading"
element-loading-text="地图正在加载中..."
element-loading-background="rgba(0, 0, 0, 0.5)"
>
<div id="map_container" style="width: 100%; height: 500px" />
</div>
<template #footer>
<el-button @click="visible = false">关闭</el-button>
</template>
</el-dialog>
</template>
<script setup>
import { useVModel } from "@vueuse/core";
import { nextTick, onBeforeUnmount, ref, watch } from "vue";
import { getChecklistInspectionStatusRecordMap } from "@/request/hazard_investigation.js";
const aPng = new URL("/src/assets/images/map/h.png", import.meta.url).href;
const bPng = new URL("/src/assets/images/map/50.png", import.meta.url).href;
let mapInstance;
const props = defineProps({
visible: {
type: Boolean,
required: true,
default: false,
},
id: {
type: String,
required: true,
default: "",
},
list: {
type: Array,
required: true,
default: () => [],
},
});
const emits = defineEmits(["update:visible"]);
const visible = useVModel(props, "visible", emits);
const loading = ref(false);
const fnMapInit = async () => {
loading.value = true;
await nextTick();
const resData = await getChecklistInspectionStatusRecordMap({
CHECKRECORD_ID: props.id,
});
mapInstance = new window.BMapGL.Map("map_container");
mapInstance.centerAndZoom(
new window.BMapGL.Point(
resData.cinfo.LONGITUDE || "116.3972282409668",
resData.cinfo.LATITUDE || "39.90960456049752"
),
16
);
mapInstance.enableScrollWheelZoom(true);
mapInstance.setMapStyleV2({
styleId: "6f501abeb2a0cc0d961d110b9407b127",
});
loading.value = false;
mapInstance && mapInstance.clearOverlays();
fnAddPoint(resData);
};
const fnAddPoint = (info) => {
for (let i = 0; i < info.varList.length; i++) {
const point = new window.BMapGL.Point(
props.list[i].LONGITUDE,
props.list[i].LATITUDE
);
const deviceSize = new window.BMapGL.Size(23, 24);
const deviceIcon = new window.BMapGL.Icon(bPng, deviceSize, {
imageSize: deviceSize,
});
const marker = new window.BMapGL.Marker(point, {
icon: deviceIcon,
});
mapInstance.addOverlay(marker);
}
for (let i = 0; i < info.hdList.length; i++) {
const point = new window.BMapGL.Point(
info.hdList[i].LONGITUDE,
info.hdList[i].LATITUDE
);
const deviceSize = new window.BMapGL.Size(23, 24);
const deviceIcon = new window.BMapGL.Icon(aPng, deviceSize, {
imageSize: deviceSize,
});
const marker = new window.BMapGL.Marker(point, {
icon: deviceIcon,
});
mapInstance.addOverlay(marker);
}
const point = new window.BMapGL.Point(
info.checkrecord.LONGITUDE,
info.checkrecord.LATITUDE
);
const deviceSize = new window.BMapGL.Size(23, 24);
const deviceIcon = new window.BMapGL.Icon(aPng, deviceSize, {
imageSize: deviceSize,
});
const marker = new window.BMapGL.Marker(point, {
icon: deviceIcon,
});
mapInstance.addOverlay(marker);
};
const stop = watch(
() => props.visible,
(val) => {
if (val && !mapInstance) {
fnMapInit();
stop && stop();
}
},
{
immediate: true,
}
);
onBeforeUnmount(() => {
if (mapInstance) {
mapInstance.destroy();
mapInstance = null;
}
});
</script>
<style scoped lang="scss"></style>

View File

@ -0,0 +1,42 @@
<template>
<el-dialog v-model="visible" title="检查照片">
<el-descriptions border :column="1">
<el-descriptions-item label="检查照片">
<img
v-viewer
v-for="item in file"
:key="item.url"
:src="item.url"
alt=""
class="ml-10"
width="100"
height="100"
/>
</el-descriptions-item>
</el-descriptions>
<template #footer>
<el-button @click="visible = false">关闭</el-button>
</template>
</el-dialog>
</template>
<script setup>
import { useVModel } from "@vueuse/core";
const props = defineProps({
visible: {
type: Boolean,
required: true,
default: false,
},
file: {
type: Array,
required: true,
default: () => [],
},
});
const emits = defineEmits(["update:visible"]);
const visible = useVModel(props, "visible", emits);
</script>
<style scoped lang="scss"></style>

View File

@ -0,0 +1,11 @@
<template>
<layout-card>
<hidden-view />
</layout-card>
</template>
<script setup>
import HiddenView from "./hidden_view.vue";
</script>
<style scoped lang="scss"></style>

View File

@ -0,0 +1,270 @@
<template>
<div>
<el-divider content-position="left">隐患信息</el-divider>
<el-descriptions :column="1" border>
<el-descriptions-item label="隐患来源">
<span v-if="data.info.SOURCE === '1'"> </span>
<span v-else-if="data.info.SOURCE === '2'"> 隐患排查 </span>
<span v-else-if="data.info.SOURCE === '3'"> 隐患排查 </span>
</el-descriptions-item>
<template v-if="data.info.SOURCE === '2'">
<el-descriptions-item label="风险点(单元)">
{{ data.info.RISK_UNIT }}
</el-descriptions-item>
<el-descriptions-item label="辨识部位">
{{ data.info.IDENTIFICATION }}
</el-descriptions-item>
<el-descriptions-item label="存在风险">
{{ data.info.RISK_DESCR }}
</el-descriptions-item>
<el-descriptions-item label="风险分级">
{{ data.info.LEVEL }}
</el-descriptions-item>
<el-descriptions-item label="检查内容">
{{ data.info.CHECK_CONTENT }}
</el-descriptions-item>
</template>
<el-descriptions-item label="隐患级别">
{{ data.info.HIDDENLEVELNAME }}
</el-descriptions-item>
<el-descriptions-item label="隐患状态">
<span v-if="data.info.STATE === '1'"> </span>
<span v-else-if="data.info.STATE === '3'"> 已整改 </span>
<span v-else-if="data.info.STATE === '4'"> 已验收 </span>
<span v-else-if="data.info.STATE === '-1'"> 已超期 </span>
</el-descriptions-item>
<el-descriptions-item label="隐患描述">
{{ data.info.HIDDENDESCR }}
</el-descriptions-item>
<el-descriptions-item label="隐患部位">
{{ data.info.HIDDENPART }}
</el-descriptions-item>
<el-descriptions-item label="隐患发现部门">
{{ data.info.HIDDENFINDDEPTNAME }}
</el-descriptions-item>
<el-descriptions-item label="发现人">
{{ data.info.CREATORNAME }}
</el-descriptions-item>
<el-descriptions-item label="发现时间">
{{ data.info.CREATTIME }}
</el-descriptions-item>
<el-descriptions-item label="整改类型">
<span v-if="data.info.RECTIFICATIONTYPE === '1'"> </span>
<span v-else-if="data.info.RECTIFICATIONTYPE === '2'"> 限期整改 </span>
</el-descriptions-item>
<el-descriptions-item
label="整改期限"
v-if="data.info.RECTIFICATIONTYPE === '2'"
>
{{ data.info.RECTIFICATIONDEADLINE }}
</el-descriptions-item>
<el-descriptions-item label="隐患类别" v-if="data.info.HIDDEN_CATEGORY">
{{ data.info.HIDDEN_CATEGORY_NAME }}
</el-descriptions-item>
<el-descriptions-item label="隐患图片">
<img
v-viewer
v-for="item in data.hImgs"
:key="item.IMGFILES_ID"
:src="FILE_URL + item.FILEPATH"
alt=""
width="100"
height="100"
class="ml-10"
/>
</el-descriptions-item>
<el-descriptions-item label="隐患视频" v-if="data.videoSrc">
<el-icon
size="30px"
@click="data.videoVisible = true"
style="cursor: pointer"
>
<video-play />
</el-icon>
<layout-video
v-model:visible="data.videoVisible"
:src="data.videoSrc"
/>
</el-descriptions-item>
</el-descriptions>
<template v-if="data.info.STATE >= 2">
<el-divider content-position="left">整改信息</el-divider>
<el-descriptions :column="1" border>
<el-descriptions-item label="整改描述">
{{ data.info.RECTIFYDESCR }}
</el-descriptions-item>
<el-descriptions-item label="整改部门">
{{ data.info.RECTIFICATIONDEPTNAME }}
</el-descriptions-item>
<el-descriptions-item label="整改人">
{{ data.info.RECTIFICATIONORNAME }}
</el-descriptions-item>
<el-descriptions-item label="整改时间">
{{ data.info.RECTIFICATIONTIME }}
</el-descriptions-item>
<el-descriptions-item label="整改后图片">
<img
v-viewer
v-for="item in data.rImgs"
:key="item.IMGFILES_ID"
:src="FILE_URL + item.FILEPATH"
alt=""
width="100"
height="100"
class="ml-10"
/>
</el-descriptions-item>
<el-descriptions-item label="整改计划">
{{ data.info.HAVEPLAN === "0" ? "无" : "" }}
{{ data.info.HAVEPLAN === "1" ? "有" : "" }}
</el-descriptions-item>
<el-descriptions-item
label="计划图片"
v-if="data.info.HAVEPLAN === '1'"
>
<img
v-viewer
v-for="item in data.pImgs"
:key="item.IMGFILES_ID"
:src="FILE_URL + item.FILEPATH"
alt=""
width="100"
height="100"
class="ml-10"
/>
</el-descriptions-item>
<el-descriptions-item
label="整改方案"
v-if="data.info.RECTIFICATIONTYPE === '2'"
>
{{ data.info.HAVESCHEME === "0" ? "无" : "" }}
{{ data.info.HAVESCHEME === "1" ? "有" : "" }}
</el-descriptions-item>
<template v-if="data.hs && data.info.HAVESCHEME === '1'">
<el-descriptions-item label="排查日期">
{{ data.hs.SCREENINGDATE }}
</el-descriptions-item>
<el-descriptions-item label="隐患清单">
{{ data.hs.LISTNAME }}
</el-descriptions-item>
<el-descriptions-item label="治理标准要求">
{{ data.hs.GOVERNSTANDARDS }}
</el-descriptions-item>
<el-descriptions-item label="治理方法">
{{ data.hs.GOVERNMETHOD }}
</el-descriptions-item>
<el-descriptions-item label="经费和物资的落实">
{{ data.hs.EXPENDITURE }}
</el-descriptions-item>
<el-descriptions-item label="负责治理人员">
{{ data.hs.PRINCIPAL }}
</el-descriptions-item>
<el-descriptions-item label="工时安排">
{{ data.hs.PROGRAMMING }}
</el-descriptions-item>
<el-descriptions-item label="时限要求">
{{ data.hs.TIMELIMITFOR }}
</el-descriptions-item>
<el-descriptions-item label="工作要求">
{{ data.hs.JOBREQUIREMENT }}
</el-descriptions-item>
<el-descriptions-item label="其他事项">
{{ data.hs.OTHERBUSINESS }}
</el-descriptions-item>
<el-descriptions-item label="方案图片">
<img
v-viewer
v-for="item in data.sImgs"
:key="item.IMGFILES_ID"
:src="FILE_URL + item.FILEPATH"
alt=""
width="100"
height="100"
class="ml-10"
/>
</el-descriptions-item>
</template>
</el-descriptions>
</template>
<template v-if="data.info.STATE >= 4">
<el-divider content-position="left">验收信息</el-divider>
<template v-for="(item, index) in data.checkList" :key="index">
<el-descriptions :column="1" border class="mt-10">
<el-descriptions-item label="验收描述">
{{ item.CHECKDESCR }}
</el-descriptions-item>
<el-descriptions-item label="是否合格">
<span v-if="item.STATUS === '1'"> </span>
<span v-else-if="item.STATUS === '0'"> </span>
</el-descriptions-item>
<el-descriptions-item label="验收部门">
{{ item.CHECKDEPTNAME }}
</el-descriptions-item>
<el-descriptions-item label="验收人">
{{ item.CHECKORNAME }}
</el-descriptions-item>
<el-descriptions-item label="验收时间">
{{ item.CHECK_TIME }}
</el-descriptions-item>
<el-descriptions-item label="验收图片">
<img
v-viewer
v-for="item1 in item.cImgs"
:key="item1.IMGFILES_ID"
:src="FILE_URL + item1.FILEPATH"
alt=""
width="100"
height="100"
class="ml-10"
/>
</el-descriptions-item>
</el-descriptions>
</template>
</template>
</div>
</template>
<script setup>
import { reactive } from "vue";
import { useRoute } from "vue-router";
import { getFileSuffix } from "@/assets/js/utils";
import { VideoPlay } from "@element-plus/icons-vue";
import LayoutVideo from "@/components/video/index";
import { getHiddenDangerView } from "@/request/hazard_investigation.js";
const FILE_URL = import.meta.env.VITE_FILE_URL;
const route = useRoute();
const { HIDDEN_ID } = route.query;
const data = reactive({
info: {},
hs: {},
hImgs: [],
rImgs: [],
sImgs: [],
pImgs: [],
checkList: [],
videoSrc: "",
videoVisible: false,
});
const fnGetData = async () => {
const resData = await getHiddenDangerView({
HIDDEN_ID,
});
data.info = resData.pd;
data.hs = resData.hs;
data.checkList = resData.checkList;
for (let i = 0; i < resData.hImgs.length; i++) {
if (getFileSuffix(resData.hImgs[i].FILEPATH) === "mp4") {
data.videoSrc = FILE_URL + resData.hImgs[i].FILEPATH;
} else {
data.hImgs.push(resData.hImgs[i]);
}
}
data.rImgs = resData.rImgs;
data.sImgs = resData.sImgs;
data.pImgs = resData.pImgs;
};
fnGetData();
</script>
<style scoped lang="scss"></style>

View File

@ -0,0 +1,262 @@
<template>
<div>
<el-card>
<el-form
:model="searchForm"
label-width="130px"
@submit.prevent="fnResetPaginationTransfer"
>
<el-row>
<el-col :span="6">
<el-form-item label="清单名称" prop="KEYWORDS">
<el-input
v-model="searchForm.KEYWORDS"
placeholder="请输入关键字"
/>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="周期内检查状态" prop="STATUS">
<el-select v-model="searchForm.STATUS">
<el-option label="未检查" value="0" />
<el-option label="已检查" value="1" />
</el-select>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="是否存在隐患项" prop="HASHIDDEN">
<el-select v-model="searchForm.HASHIDDEN">
<el-option label="无隐患" value="0" />
<el-option label="有隐患" value="1" />
</el-select>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="是否有超期记录" prop="OVERTIME">
<el-select v-model="searchForm.OVERTIME">
<el-option label="无超期" value="0" />
<el-option label="有超期" value="1" />
</el-select>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="人员" prop="USERNAME">
<el-input
v-model="searchForm.USERNAME"
placeholder="请输入关键字"
/>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="清单类型" prop="TYPE">
<el-select v-model="searchForm.TYPE">
<el-option
v-for="item in inventoryTypeList"
:key="item.BIANMA"
:label="item.NAME"
:value="item.BIANMA"
/>
</el-select>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="排查周期" prop="PERIOD">
<el-select v-model="searchForm.PERIOD">
<el-option
v-for="item in troubleshootingCycleList"
:key="item.BIANMA"
:label="item.NAME"
:value="item.BIANMA"
/>
</el-select>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="清单级别" prop="LISTINGLEVEL">
<el-select v-model="searchForm.LISTINGLEVEL">
<el-option
v-for="item in [
{ BIANMA: '1', NAME: '公司' },
...inventoryLevelList,
]"
:key="item.BIANMA"
:label="item.NAME"
:value="item.BIANMA"
/>
</el-select>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="部门" prop="DEPTIDS">
<layout-department
v-model="searchForm.DEPTIDS"
multiple
show-checkbox
collapse-tags
/>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="清单状态" prop="ISDELETE">
<el-select v-model="searchForm.ISDELETE">
<el-option label="启用" value="0" />
<el-option label="禁用" value="1" />
<el-option label="已删除" value="2" />
<el-option label="彻底删除" value="-1" />
</el-select>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="在岗状态" prop="WORKSTATUS">
<el-select v-model="searchForm.WORKSTATUS">
<el-option label="在岗" value="0" />
<el-option label="离岗" value="1" />
</el-select>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label-width="10px">
<el-button type="primary" native-type="submit">搜索</el-button>
<el-button native-type="reset" @click="fnResetPaginationTransfer">
重置
</el-button>
</el-form-item>
</el-col>
</el-row>
</el-form>
</el-card>
<layout-card>
<layout-table
:data="list"
v-model:pagination="pagination"
@get-data="fnGetDataTransfer"
>
<el-table-column label="序号" width="70">
<template v-slot="{ $index }">
{{ serialNumber(pagination, $index) }}
</template>
</el-table-column>
<el-table-column prop="NAME" label="清单名称" />
<el-table-column prop="DEPARTMENT_NAME_ALL" label="部门" />
<el-table-column prop="POST_NAME" label="岗位" />
<el-table-column
prop="USER_NAME"
label="人员"
width="90"
show-overflow-tooltip
/>
<el-table-column label="在岗状态" width="90">
<template v-slot="{ row }">
{{ fnGetStatus(row.STARTTIME, row.ENDTIME, row.WORKSTATUS) }}
</template>
</el-table-column>
<el-table-column prop="PERIODNAME" label="排查周期" width="90" />
<el-table-column label="周期" width="260">
<template v-slot="{ row }">
<span v-if="row.DATESTART && row.DATEEND">
{{ row.DATESTART }}-{{ row.DATEEND }}
</span>
</template>
</el-table-column>
<el-table-column prop="count" label="检查次数" width="90" />
<el-table-column prop="hiddenCount" label="隐患数" width="90" />
<el-table-column label="周期内次数" width="120" show-overflow-tooltip>
<template v-slot="{ row }">
<span :class="{ 'text-red': row.checkCount === 0 }">
{{ row.checkCount }}/1
</span>
</template>
</el-table-column>
<el-table-column prop="TYPENAME" label="清单类型" width="90" />
<el-table-column
v-if="SPECIAL_ENTERPRISES.includes(CORPINFO_ID)"
label="是否包保责任人任务"
width="90"
>
<template v-slot="{ row }">
<span v-if="row.BAO_BAO_TYPE !== '1'"> </span>
<span v-if="row.BAO_BAO_TYPE === '1'"> </span>
</template>
</el-table-column>
<el-table-column label="清单状态" width="90">
<template v-slot="{ row }">
<span class="text-green" v-if="row.ISDELETE === '0'"></span>
<span class="text-red" v-else-if="row.ISDELETE === '1'">禁用</span>
<span v-else-if="row.ISDELETE === '2'"> 已删除 </span>
<span v-else-if="row.ISDELETE === '-1'"> 彻底删除 </span>
</template>
</el-table-column>
<el-table-column label="操作" width="100">
<template v-slot="{ row }">
<el-button
type="primary"
text
link
@click="
router.push({
path: '/hazard_investigation/checklist_inspection_status/inspection_record',
query: {
LISTMANAGER_ID: row.LISTMANAGER_ID,
},
})
"
>
检查记录
</el-button>
</template>
</el-table-column>
</layout-table>
</layout-card>
</div>
</template>
<script setup>
import { serialNumber } from "@/assets/js/utils.js";
import useListData from "@/assets/js/useListData.js";
import LayoutDepartment from "@/components/department/index.vue";
import {
layoutFnGetInventoryLevel,
layoutFnGetInventoryType,
layoutFnGetTroubleshootingCycle,
} from "@/assets/js/data_dictionary.js";
import { getChecklistInspectionStatusList } from "@/request/hazard_investigation.js";
import { useRouter } from "vue-router";
import { SPECIAL_ENTERPRISES } from "@/assets/js/constant.js";
import { useUserStore } from "@/pinia/user.js";
import dayjs from "dayjs";
const router = useRouter();
const userStore = useUserStore();
const CORPINFO_ID = userStore.getUserInfo.CORPINFO_ID;
const { list, pagination, searchForm, fnGetData, fnResetPagination } =
useListData(getChecklistInspectionStatusList);
const troubleshootingCycleList = await layoutFnGetTroubleshootingCycle();
const inventoryLevelList = await layoutFnGetInventoryLevel();
const inventoryTypeList = await layoutFnGetInventoryType();
const fnGetDataTransfer = () => {
fnGetData({
DEPTIDS: searchForm.value.DEPTIDS?.join(","),
});
};
const fnResetPaginationTransfer = () => {
fnResetPagination({
DEPTIDS: searchForm.value.DEPTIDS?.join(","),
});
};
const fnGetStatus = (STARTTIME, ENDTIME, WORKSTATUS) => {
if (!STARTTIME || !ENDTIME) {
return "在岗";
}
if (
dayjs(dayjs().format("YYYY-MM-DD")).diff(dayjs(STARTTIME), "days") >= 0 &&
dayjs(dayjs().format("YYYY-MM-DD")).diff(dayjs(ENDTIME), "days") <= 0
) {
return "离岗";
} else {
if (WORKSTATUS === 2) return "离岗";
return "在岗";
}
};
</script>
<style scoped></style>

View File

@ -0,0 +1,182 @@
<template>
<div>
<el-card>
<el-form
:model="searchForm"
label-width="80px"
@submit.prevent="fnResetPaginationTransfer"
>
<el-row>
<el-col :span="6">
<el-form-item label="检查周期" prop="dates">
<el-date-picker
v-model="searchForm.dates"
type="daterange"
value-format="YYYY-MM-DD"
format="YYYY-MM-DD"
range-separator="至"
/>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="检查状态" prop="TYPE">
<el-select v-model="searchForm.TYPE">
<el-option label="已检查" value="1" />
<el-option label="超期未检查" value="2" />
</el-select>
</el-form-item>
</el-col>
<el-col :span="4">
<el-form-item label-width="10px">
<el-button type="primary" native-type="submit">搜索</el-button>
<el-button native-type="reset" @click="fnResetPaginationTransfer">
重置
</el-button>
</el-form-item>
</el-col>
</el-row>
</el-form>
</el-card>
<layout-card>
<layout-table
:data="list"
@get-data="fnGetDataTransfer"
v-model:pagination="pagination"
>
<el-table-column label="序号" width="60">
<template #default="{ $index }">
{{ serialNumber(pagination, $index) }}
</template>
</el-table-column>
<el-table-column prop="LIST_NAME" label="清单名称">
<template v-slot="{ row }">
{{ row.LIST_NAME ? row.LIST_NAME : info.NAME }}
</template>
</el-table-column>
<el-table-column
prop="PRINCIPALNAME"
label="人员"
width="90"
show-overflow-tooltip
/>
<el-table-column prop="DATESTART" label="检查周期">
<template v-slot="{ row }">
<template v-if="row.DATESTART && row.DATEEND">
{{ row.DATESTART }}-{{ row.DATEEND }}
</template>
</template>
</el-table-column>
<el-table-column prop="CHECK_USERS" label="检查人" width="90" />
<el-table-column prop="CHECK_TIME" label="检查时间" />
<el-table-column label="检查状态" width="120">
<template v-slot="{ row }">
<div v-if="row.TYPE === '2'"></div>
<div v-else></div>
</template>
</el-table-column>
<el-table-column label="操作" width="140">
<template #default="{ row }">
<template v-if="row.TYPE === '1'">
<el-button
type="primary"
text
link
@click="
router.push({
path: '/hazard_investigation/checklist_inspection_status/inspection_record/view',
query: {
CHECKRECORD_ID: row.CHECKRECORD_ID,
},
})
"
>
检查记录
</el-button>
<el-button
v-if="buttonJurisdiction.del"
type="primary"
text
link
@click="fnDelete(row.CHECKRECORD_ID)"
>
删除
</el-button>
</template>
<template v-else>
<el-button
type="primary"
text
link
@click="
router.push({
path: '/hazard_investigation/checklist_inspection_status/inspection_record/supplementary_recording',
query: {
CHECKRECORD_ID: row.CHECKRECORD_ID,
DATESTART: row.DATESTART,
DATEEND: row.DATEEND,
LISTMANAGER_ID,
type: 'supplementaryRecording',
},
})
"
>
补录
</el-button>
</template>
</template>
</el-table-column>
</layout-table>
</layout-card>
</div>
</template>
<script setup>
import { ref } from "vue";
import { useRouter, useRoute } from "vue-router";
import { serialNumber } from "@/assets/js/utils";
import {
getChecklistInspectionStatusRecordList,
setChecklistInspectionStatusRecordDelete,
} from "@/request/hazard_investigation.js";
import { debounce } from "throttle-debounce";
import { ElMessage, ElMessageBox } from "element-plus";
import useButtonJurisdiction from "@/assets/js/useButtonJurisdiction.js";
import useListData from "@/assets/js/useListData.js";
const route = useRoute();
const router = useRouter();
const { LISTMANAGER_ID } = route.query;
const info = ref({});
const { list, pagination, searchForm, fnGetData, fnResetPagination } =
useListData(getChecklistInspectionStatusRecordList, {
otherParams: { LISTMANAGER_ID },
callbackFn: (list, resData) => {
info.value = resData.ls;
},
});
const fnGetDataTransfer = () => {
fnGetData({
STARTINSPECTTIME: searchForm.value.dates?.[0],
ENDINSPECTTIME: searchForm.value.dates?.[1],
});
};
const fnResetPaginationTransfer = () => {
fnResetPagination({
STARTINSPECTTIME: searchForm.value.dates?.[0],
ENDINSPECTTIME: searchForm.value.dates?.[1],
});
};
const buttonJurisdiction = await useButtonJurisdiction("checkrecord");
const fnDelete = debounce(
1000,
async (CHECKRECORD_ID) => {
await ElMessageBox.confirm("确定要删除吗?", { type: "warning" });
await setChecklistInspectionStatusRecordDelete({ CHECKRECORD_ID });
ElMessage.success("删除成功");
fnResetPaginationTransfer();
},
{ atBegin: true }
);
</script>
<style scoped></style>

View File

@ -0,0 +1,260 @@
<template>
<layout-card>
<div id="printContent">
<el-divider content-position="left">清单信息</el-divider>
<el-descriptions border :column="2">
<el-descriptions-item label="清单名称">
{{ info.LIST_NAME }}
</el-descriptions-item>
<el-descriptions-item label="排查清单类型">
{{ info.SCREENTYPENAME }}
</el-descriptions-item>
<el-descriptions-item
:label="info.BAO_BAO_TYPE === '1' ? '包保责任人' : '检查人'"
>
{{ info.USERS }}
</el-descriptions-item>
<el-descriptions-item label="检查时间">
{{ info.CHECK_TIME }}
</el-descriptions-item>
<el-descriptions-item
:label="info.BAO_BAO_TYPE === '1' ? '包保责任人部门' : '所属部门'"
>
{{ info.DEPARTMENT_NAME }}
</el-descriptions-item>
<el-descriptions-item
:label="info.BAO_BAO_TYPE === '1' ? '包保责任人岗位' : '所属岗位'"
>
{{ info.POST_NAME }}
</el-descriptions-item>
<el-descriptions-item label="排查周期">
{{ info.PERIODNAME }}
</el-descriptions-item>
<el-descriptions-item label="清单类型">
{{ info.TYPENAME }}
</el-descriptions-item>
<el-descriptions-item
label="排查日期"
v-if="info.LISTTYPE === 'listType0006'"
>
{{ info.START_DATE }} - {{ info.END_DATE }}
</el-descriptions-item>
<el-descriptions-item label="补录原因" :span="2" v-if="info.REASON">
{{ info.REASON }}
</el-descriptions-item>
<el-descriptions-item
label="地图"
:span="2"
class-name="print_no_use"
label-class-name="print_no_use"
>
<el-button @click="data.mapDialogVisible = true">
<icon-international
theme="outline"
size="18"
fill="#0694f4"
:strokeWidth="3"
/>
</el-button>
</el-descriptions-item>
<el-descriptions-item label="签字" :span="2">
<img
v-if="qianming"
:src="qianming"
style="width: 200px; height: 97px"
/>
</el-descriptions-item>
</el-descriptions>
<el-divider content-position="left">检查内容</el-divider>
<div class="print_no_use">
<layout-table :data="inspectionList" :show-pagination="false">
<el-table-column label="序号" width="70" type="index" />
<el-table-column prop="RISKUNITNAME" label="风险点(单元)" />
<el-table-column prop="PARTSNAME" label="辨识部位" />
<el-table-column prop="RISK_DESCR" label="存在风险" />
<el-table-column prop="DNAME5" label="风险分级" />
<el-table-column prop="CHECK_CONTENT" label="检查内容" />
<el-table-column label="状态" width="100">
<template v-slot="{ row }">
<template v-if="row.ISNORMAL === 0">
<el-button
v-if="row.IMGCOUNT > 0"
type="primary"
text
link
@click="fnQualified(row.RECORDITEM_ID)"
>
合格
</el-button>
<div v-else></div>
</template>
<el-button
v-else-if="row.ISNORMAL === 1"
type="primary"
text
link
@click="
router.push({
path: '/hazard_investigation/checklist_inspection_status/inspection_record/view/hidden_danger',
query: { HIDDEN_ID: row.HIDDEN_ID },
})
"
>
不合格
</el-button>
<div v-else-if="row.ISNORMAL === 2">不涉及</div>
<div v-else></div>
</template>
</el-table-column>
</layout-table>
</div>
<table class="print_use">
<tr>
<th width="55">序号</th>
<th width="125">风险点单元</th>
<th width="100">辨识部位</th>
<th>存在风险</th>
<th width="120">风险分级</th>
<th>检查内容</th>
<th width="100">状态</th>
</tr>
<tr v-for="(item, index) in inspectionList" :key="index">
<td>{{ index + 1 }}</td>
<td>{{ item.RISKUNITNAME }}</td>
<td>{{ item.PARTSNAME }}</td>
<td>{{ item.RISK_DESCR }}</td>
<td>{{ item.LEVEL_NAME }}</td>
<td>{{ item.CHECK_CONTENT }}</td>
<template v-if="item.ISNORMAL === 0">
<template v-if="item.IMGCOUNT > 0">
<td>
<el-button type="primary" text link> 合格 </el-button>
</td>
</template>
<template v-else>
<td>合格</td>
</template>
</template>
<template v-else-if="item.ISNORMAL === 1">
<td>
<el-button type="primary" text link> 不合格 </el-button>
</td>
</template>
<template v-else-if="item.ISNORMAL === 2">
<td>不涉及</td>
</template>
<template v-else>
<td>存在未整改隐患</td>
</template>
</tr>
</table>
<el-divider content-position="left">其他隐患</el-divider>
<div class="print_no_use">
<layout-table :data="otherHiddenList" :show-pagination="false">
<el-table-column label="序号" width="70" type="index" />
<el-table-column prop="HIDDENDESCR" label="隐患描述" />
<el-table-column label="操作" width="100">
<template v-slot="{ row }">
<el-button
type="primary"
text
link
@click="
router.push({
path: '/hazard_investigation/checklist_inspection_status/inspection_record/view/hidden_danger',
query: { HIDDEN_ID: row.HIDDEN_ID },
})
"
>
查看
</el-button>
</template>
</el-table-column>
</layout-table>
</div>
<table class="print_use">
<tr>
<th width="55">序号</th>
<th>隐患描述</th>
</tr>
<tr v-for="(item, index) in otherHiddenList" :key="index">
<td>{{ index + 1 }}</td>
<td>{{ item.HIDDENDESCR }}</td>
</tr>
</table>
</div>
<div class="tc mt">
<el-button v-print="'#printContent'" type="primary"></el-button>
</div>
<qualified
v-model:visible="data.qualifiedDialog.visible"
:file="data.qualifiedDialog.file"
/>
<map-dialog
v-model:visible="data.mapDialogVisible"
:id="CHECKRECORD_ID"
:list="inspectionList"
/>
<div v-html="PRINT_STYLE" />
</layout-card>
</template>
<script setup>
import { useRoute, useRouter } from "vue-router";
import { reactive, ref } from "vue";
import {
getChecklistInspectionStatusRecordView,
getChecklistInspectionStatusRecordViewOtherHiddenDangerList,
} from "@/request/hazard_investigation.js";
import { getViewImg } from "@/request/api.js";
import { PRINT_STYLE } from "@/assets/js/constant.js";
import useListData from "@/assets/js/useListData.js";
import { addingPrefixToFile } from "@/assets/js/utils.js";
import Qualified from "./components/qualified.vue";
import MapDialog from "./components/map.vue";
const route = useRoute();
const router = useRouter();
const { CHECKRECORD_ID } = route.query;
const VITE_FILE_URL = import.meta.env.VITE_FILE_URL;
const info = ref({});
const qianming = ref("");
const data = reactive({
qualifiedDialog: {
visible: false,
file: [],
},
mapDialogVisible: false,
});
const { list: inspectionList } = useListData(
getChecklistInspectionStatusRecordView,
{
otherParams: { CHECKRECORD_ID },
usePagination: false,
callbackFn: (list, resData) => {
info.value = resData.pd;
if (resData.qianming && resData.qianming.length > 0) {
qianming.value = VITE_FILE_URL + resData.qianming[0].FILEPATH;
}
},
}
);
const { list: otherHiddenList } = useListData(
getChecklistInspectionStatusRecordViewOtherHiddenDangerList,
{
otherParams: { CHECKRECORD_ID },
usePagination: false,
key: "hiddenList",
}
);
const fnQualified = async (RECORDITEM_ID) => {
const resData = await getViewImg({
FOREIGN_KEY: RECORDITEM_ID,
TYPE: "14",
});
data.qualifiedDialog.file = addingPrefixToFile(resData.imgs);
data.qualifiedDialog.visible = true;
};
</script>
<style scoped lang="scss"></style>

View File

@ -0,0 +1,9 @@
<template>
<inspection />
</template>
<script setup>
import Inspection from "../inventory_troubleshooting/inspect.vue";
</script>
<style scoped></style>

View File

@ -0,0 +1,185 @@
<template>
<div>
<el-card>
<el-form
:model="searchForm"
label-width="80px"
@submit.prevent="fnResetPaginationTransfer"
>
<el-row>
<el-col :span="6">
<el-form-item label="检查周期" prop="dates">
<el-date-picker
v-model="searchForm.dates"
type="daterange"
value-format="YYYY-MM-DD"
format="YYYY-MM-DD"
range-separator="至"
/>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="检查状态" prop="TYPE">
<el-select v-model="searchForm.TYPE">
<el-option label="已检查" value="1" />
<el-option label="超期未检查" value="2" />
</el-select>
</el-form-item>
</el-col>
<el-col :span="4">
<el-form-item label-width="10px">
<el-button type="primary" native-type="submit">搜索</el-button>
<el-button native-type="reset" @click="fnResetPaginationTransfer">
重置
</el-button>
</el-form-item>
</el-col>
</el-row>
</el-form>
</el-card>
<layout-card>
<layout-table
:data="list"
@get-data="fnGetDataTransfer"
v-model:pagination="pagination"
>
<el-table-column label="序号" width="60">
<template #default="{ $index }">
{{ serialNumber(pagination, $index) }}
</template>
</el-table-column>
<el-table-column prop="LIST_NAME" label="清单名称">
<template v-slot="{ row }">
{{ row.LIST_NAME ? row.LIST_NAME : info.NAME }}
</template>
</el-table-column>
<el-table-column
prop="PRINCIPALNAME"
label="人员"
width="90"
show-overflow-tooltip
/>
<el-table-column prop="DATESTART" label="检查周期">
<template v-slot="{ row }">
<template v-if="row.DATESTART && row.DATEEND">
{{ row.DATESTART }}-{{ row.DATEEND }}
</template>
</template>
</el-table-column>
<el-table-column prop="CHECK_USERS" label="检查人" width="90" />
<el-table-column prop="CHECK_TIME" label="检查时间" />
<el-table-column label="检查状态" width="120">
<template v-slot="{ row }">
<div v-if="row.TYPE === '2'"></div>
<div v-else></div>
</template>
</el-table-column>
<el-table-column label="操作" width="140">
<template #default="{ row }">
<template v-if="row.TYPE === '1'">
<el-button
type="primary"
text
link
@click="
router.push({
path: '/hazard_investigation/checklist_inspection_status/inspection_record/view',
query: {
CHECKRECORD_ID: row.CHECKRECORD_ID,
},
})
"
>
检查记录
</el-button>
<el-button
v-if="buttonJurisdiction.del"
type="primary"
text
link
@click="fnDelete(row.CHECKRECORD_ID)"
>
删除
</el-button>
</template>
<template v-else>
<el-button
type="primary"
text
link
@click="
router.push({
path: '/hazard_investigation/checklist_inspection_status/inspection_record/supplementary_recording',
query: {
CHECKRECORD_ID: row.CHECKRECORD_ID,
DATESTART: row.DATESTART,
DATEEND: row.DATEEND,
LISTMANAGER_ID,
type: 'supplementaryRecording',
},
})
"
>
补录
</el-button>
</template>
</template>
</el-table-column>
</layout-table>
</layout-card>
</div>
</template>
<script setup>
import { ref } from "vue";
import { useRouter } from "vue-router";
import { serialNumber } from "@/assets/js/utils";
import {
getInspectionRecordList,
setChecklistInspectionStatusRecordDelete,
} from "@/request/hazard_investigation.js";
import { debounce } from "throttle-debounce";
import { ElMessage, ElMessageBox } from "element-plus";
import useButtonJurisdiction from "@/assets/js/useButtonJurisdiction.js";
import useListData from "@/assets/js/useListData.js";
import { useUserStore } from "@/pinia/user.js";
const router = useRouter();
const userStore = useUserStore();
const info = ref({});
const { list, pagination, searchForm, fnGetData, fnResetPagination } =
useListData(getInspectionRecordList, {
otherParams: {
USER_ID: userStore.getUserInfo.USER_ID,
TYPE: "1",
},
callbackFn: (list, resData) => {
info.value = resData.ls;
},
});
const fnGetDataTransfer = () => {
fnGetData({
STARTINSPECTTIME: searchForm.value.dates?.[0],
ENDINSPECTTIME: searchForm.value.dates?.[1],
});
};
const fnResetPaginationTransfer = () => {
fnResetPagination({
STARTINSPECTTIME: searchForm.value.dates?.[0],
ENDINSPECTTIME: searchForm.value.dates?.[1],
});
};
const buttonJurisdiction = await useButtonJurisdiction("checkrecord");
const fnDelete = debounce(
1000,
async (CHECKRECORD_ID) => {
await ElMessageBox.confirm("确定要删除吗?", { type: "warning" });
await setChecklistInspectionStatusRecordDelete({ CHECKRECORD_ID });
ElMessage.success("删除成功");
fnResetPaginationTransfer();
},
{ atBegin: true }
);
</script>
<style scoped></style>

View File

@ -36,15 +36,8 @@
<el-col :span="6">
<el-form-item label="检查状态" prop="STATUS">
<el-select v-model="searchForm.STATUS">
<el-option
v-for="item in [
{ ID: '0', NAME: '未检查' },
{ ID: '1', NAME: '已检查' },
]"
:key="item.ID"
:label="item.NAME"
:value="item.ID"
/>
<el-option label="未检查" value="0" />
<el-option label="已检查" value="1" />
</el-select>
</el-form-item>
</el-col>

View File

@ -47,11 +47,26 @@
<el-radio-group :disabled="row.HASHIDDEN > 0" v-model="row.ISNORMAL">
<el-radio :label="0" @click.prevent="fnQualified($index, row)">
合格
<el-tooltip
content="注意:补录时,不允许添加隐患"
placement="top"
v-if="type === 'supplementaryRecording'"
>
<el-icon><warning-filled /></el-icon>
</el-tooltip>
</el-radio>
<el-radio :label="1" @click.prevent="fnUnqualified($index, row)">
<el-radio
:label="1"
:disabled="type === 'supplementaryRecording'"
@click.prevent="fnUnqualified($index, row)"
>
不合格
</el-radio>
<el-radio :label="2" @click.prevent="fnNotInvolved($index, row)">
<el-radio
:label="2"
:disabled="type === 'supplementaryRecording'"
@click.prevent="fnNotInvolved($index, row)"
>
不涉及
</el-radio>
</el-radio-group>
@ -60,7 +75,11 @@
</layout-table>
<el-divider content-position="left">其他隐患</el-divider>
<div class="tr mb-10">
<el-button type="primary" @click="fnAddOrEditOtherHidden({}, 'add')">
<el-button
type="primary"
@click="fnAddOrEditOtherHidden({}, 'add')"
:disabled="type === 'supplementaryRecording'"
>
添加
</el-button>
</div>
@ -103,6 +122,7 @@
value-format="YYYY-MM-DD HH:mm:ss"
type="datetime"
placeholder="这里输入检查时间"
:disabled-date="fnDisabledDate"
/>
</el-form-item>
</el-col>
@ -175,6 +195,11 @@
</el-form-item>
</el-col>
</template>
<el-col :span="24" v-if="type === 'supplementaryRecording'">
<el-form-item label="补录原因" prop="REASON">
<el-input v-model="data.form.REASON" type="textarea" autosize />
</el-form-item>
</el-col>
<el-col :span="24">
<el-form-item label="备注" prop="DESCR">
<el-input
@ -218,6 +243,7 @@ import {
getInventoryTroubleshootingOtherHiddenDangerView,
setInventoryTroubleshootingOtherHiddenDangerDelete,
setInventoryTroubleshootingSubmit,
setChecklistInspectionStatusRecordSupplementaryRecordingSubmit,
} from "@/request/hazard_investigation.js";
import { useRoute, useRouter } from "vue-router";
import useListData from "@/assets/js/useListData.js";
@ -235,14 +261,18 @@ import { ElMessage, ElMessageBox } from "element-plus";
import Qualified from "./components/qualified.vue";
import UnQualified from "./components/un_qualified.vue";
import { cloneDeep } from "lodash-es";
import { WarningFilled } from "@element-plus/icons-vue";
const route = useRoute();
const router = useRouter();
const { LISTMANAGER_ID } = route.query;
const { LISTMANAGER_ID, type, CHECKRECORD_ID, DATEEND, DATESTART } =
route.query;
console.log(CHECKRECORD_ID);
const rules = {
CHECK_TIME: [
{ required: true, message: "请选择检查时间", trigger: "change" },
],
REASON: [{ required: true, message: "请输入补录原因", trigger: "blur" }],
};
const formRef = ref(null);
const info = ref({});
@ -251,6 +281,7 @@ const data = reactive({
latitude: 0,
form: {
CHECK_TIME: "",
REASON: "",
inspectedList: [],
},
qualifiedDialog: {
@ -281,19 +312,6 @@ const data = reactive({
},
},
});
onMounted(() => {
const geolocation = new window.BMapGL.Geolocation();
geolocation.getCurrentPosition(async (r) => {
if (!r) {
await ElMessageBox.alert("获取位置信息失败,请刷新重试", {
type: "warning",
});
window.location.reload();
}
data.longitude = r.longitude;
data.latitude = r.latitude;
});
});
const { list: inspectionList } = useListData(getInventoryManagementView, {
otherParams: { LISTMANAGER_ID },
usePagination: false,
@ -312,6 +330,27 @@ const { list: otherHiddenList, fnGetData: fnGetOtherHidden } = useListData(
key: "hiddenList",
}
);
onMounted(() => {
const geolocation = new window.BMapGL.Geolocation();
geolocation.getCurrentPosition(async (r) => {
if (!r) {
await ElMessageBox.alert("获取位置信息失败,请刷新重试", {
type: "warning",
});
window.location.reload();
}
data.longitude = r.longitude;
data.latitude = r.latitude;
});
});
const fnDisabledDate = (time) => {
if (DATEEND && DATESTART)
return (
time.getTime() > new Date(DATEEND).getTime() ||
time.getTime() < new Date(DATESTART).getTime()
);
else return false;
};
const fnQualified = async (index, row) => {
if (row.HASHIDDEN > 0) return;
data.qualifiedDialog.visible = true;
@ -328,7 +367,7 @@ const fnQualified = async (index, row) => {
inspectionList.value[index].ISNORMAL = 0;
};
const fnNotInvolved = (index, row) => {
if (row.HASHIDDEN > 0) return;
if (row.HASHIDDEN > 0 || type === "supplementaryRecording") return;
fnRemoveUnqualified(index);
inspectionList.value[index].ISNORMAL = 2;
};
@ -336,7 +375,7 @@ const fnRemoveUnqualified = (index) => {
inspectionList.value[index].HIDDEN_ID = "";
};
const fnUnqualified = async (index, row) => {
if (row.HASHIDDEN > 0) return;
if (row.HASHIDDEN > 0 || type === "supplementaryRecording") return;
data.unQualifiedDialog.visible = true;
await nextTick();
if (
@ -432,7 +471,7 @@ const fnSubmit = debounce(
}
const inspectedList = cloneDeep(data.form.inspectedList);
if (inspectedList.length > 0) inspectedList.splice(0, 1);
await setInventoryTroubleshootingSubmit({
const params = {
LISTMANAGER_ID,
LIST_NAME: info.value.NAME,
CHECK_TIME: data.form.CHECK_TIME,
@ -444,7 +483,14 @@ const fnSubmit = debounce(
OTHER: JSON.stringify(inspectedList),
LONGITUDE: data.longitude,
LATITUDE: data.latitude,
});
};
if (type === "supplementaryRecording") {
params.REASON = data.form.REASON;
params.CHECKRECORD_ID = CHECKRECORD_ID;
await setChecklistInspectionStatusRecordSupplementaryRecordingSubmit(
params
);
} else await setInventoryTroubleshootingSubmit(params);
ElMessage.success("操作成功");
router.back();
},

View File

@ -218,7 +218,6 @@
</template>
<script setup>
import LayoutCard from "@/components/card/index.vue";
import LayoutLearningTrainType from "@/components/learning_train_type/index.vue";
import {
getDataCoursewareList,
@ -228,7 +227,6 @@ import {
import useListData from "@/assets/js/useListData.js";
import { reactive } from "vue";
import { interceptTheSuffix, serialNumber } from "@/assets/js/utils.js";
import LayoutTable from "@/components/table/index.vue";
import { ArrowDown, ArrowUp } from "@element-plus/icons-vue";
import useButtonJurisdiction from "@/assets/js/useButtonJurisdiction.js";
import { ElMessage, ElMessageBox } from "element-plus";

View File

@ -140,8 +140,6 @@
</template>
<script setup>
import LayoutTable from "@/components/table/index.vue";
import LayoutCard from "@/components/card/index.vue";
import {
importQuestion,
deleteQuestion,

View File

@ -235,7 +235,6 @@
</template>
<script setup>
import LayoutCard from "@/components/card/index.vue";
import LayoutLearningTrainType from "@/components/learning_train_type/index.vue";
import {
getVideoCoursewareList,
@ -245,7 +244,6 @@ import {
import useListData from "@/assets/js/useListData.js";
import { reactive } from "vue";
import { serialNumber } from "@/assets/js/utils.js";
import LayoutTable from "@/components/table/index.vue";
import LayoutVideo from "@/components/video/index.vue";
import { getVideoAuth, getVideoSource } from "@/request/api.js";
import { ArrowDown, ArrowUp } from "@element-plus/icons-vue";

View File

@ -139,7 +139,6 @@
</template>
<script setup>
import LayoutCard from "@/components/card/index.vue";
import LayoutLearningTrainType from "@/components/learning_train_type/index.vue";
import {
getDataCoursewareList,
@ -148,8 +147,6 @@ import {
import useListData from "@/assets/js/useListData.js";
import { reactive } from "vue";
import { interceptTheSuffix, serialNumber } from "@/assets/js/utils.js";
import LayoutTable from "@/components/table/index.vue";
// import useButtonJurisdiction from "@/assets/js/useButtonJurisdiction.js";
import { debounce } from "throttle-debounce";
import { ElMessage, ElMessageBox } from "element-plus";
import { useRouter } from "vue-router";
@ -169,9 +166,6 @@ const data = reactive({
visible: false,
},
});
// const buttonJurisdiction = await useButtonJurisdiction("courseware");
const fnAdd = debounce(1000, async (DATACOURSEWARE_ID) => {
await ElMessageBox.confirm("确定要添加吗?", { type: "warning" });
await joinMyDataCourseware({ COURSEWARE_ID: DATACOURSEWARE_ID });

View File

@ -156,7 +156,6 @@
</template>
<script setup>
import LayoutCard from "@/components/card/index.vue";
import LayoutLearningTrainType from "@/components/learning_train_type/index.vue";
import {
getVideoCoursewareList,
@ -165,7 +164,6 @@ import {
import useListData from "@/assets/js/useListData.js";
import { reactive } from "vue";
import { serialNumber } from "@/assets/js/utils.js";
import LayoutTable from "@/components/table/index.vue";
import { debounce } from "throttle-debounce";
import { ElMessage, ElMessageBox } from "element-plus";
import { useRouter } from "vue-router";

View File

@ -65,8 +65,6 @@
</template>
<script setup>
import LayoutTable from "@/components/table/index.vue";
import LayoutCard from "@/components/card/index.vue";
import { getQuestionListByCoursewareIdAndType } from "@/request/platform_resource_library.js";
import useListData from "@/assets/js/useListData.js";
import { reactive } from "vue";

View File

@ -104,7 +104,6 @@
</template>
<script setup>
import LayoutCard from "@/components/card/index.vue";
import LayoutLearningTrainType from "@/components/learning_train_type/index.vue";
import {
getCurriculumList,
@ -112,7 +111,6 @@ import {
} from "@/request/platform_resource_library.js";
import useListData from "@/assets/js/useListData.js";
import { serialNumber } from "@/assets/js/utils.js";
import LayoutTable from "@/components/table/index.vue";
import { debounce } from "throttle-debounce";
import { ElMessage, ElMessageBox } from "element-plus";
import { useRouter } from "vue-router";

View File

@ -139,7 +139,6 @@
</template>
<script setup>
import LayoutTable from "@/components/table/index.vue";
import { reactive } from "vue";
import { useRoute } from "vue-router";
import { getCurriculumInfo } from "@/request/platform_resource_library.js";

View File

@ -111,7 +111,6 @@
</div>
</template>
<script setup>
import LayoutCard from "@/components/card/index.vue";
import LayoutLearningTrainType from "@/components/learning_train_type/index.vue";
import {
getPaperList,
@ -119,7 +118,6 @@ import {
} from "@/request/platform_resource_library.js";
import useListData from "@/assets/js/useListData.js";
import { serialNumber } from "@/assets/js/utils.js";
import LayoutTable from "@/components/table/index.vue";
import { debounce } from "throttle-debounce";
import { ElMessage, ElMessageBox } from "element-plus";
import { useRouter } from "vue-router";