受限空间,高处作业

pull/1/head
chenxinying 2024-02-02 14:08:57 +08:00
parent 5ea9fb929d
commit f6d550ab3e
4 changed files with 98 additions and 80 deletions

View File

@ -5,3 +5,17 @@ export const getTaskSetps = (params) =>
export const getHotWorkList = (params) => post("/hotwork/list", params); // 动火作业管理列表
export const getHotWorkView = (params) => post("/hotwork/findById", params); // 动火作业管理查看
export const getHotWorkFlow = (params) => post("/hotwork/getFlowList", params); // 动火作业流程图
export const getConfinedSpaceList = (params) =>
post("/confinedspace/list", params); // 受限作业管理列表
export const getConfinedSpaceView = (params) =>
post("/confinedspace/findById", params); // 受限作业管理查看
export const getConfinedSpaceFlow = (params) =>
post("/confinedspace/getFlowList", params); // 受限作业流程图
export const getHighWorkList = (params) => post("/highwork/list", params); // 高处作业管理列表
export const getHighWorkView = (params) => post("/highwork/findById", params); // 高处作业管理查看
export const getHighWorkFlow = (params) =>
post("/highwork/getFlowList", params); // 高处作业流程图

View File

@ -16,13 +16,13 @@
</el-form-item>
</el-col>
<el-col :span="6" v-if="entrance === 'job_data'">
<el-form-item label="状态" prop="APPLY_STATUS">
<el-select v-model="searchForm.APPLY_STATUS">
<el-form-item label="状态" prop="STEP_ID">
<el-select v-model="searchForm.STEP_ID">
<el-option
v-for="item in stateList"
:key="item.ID"
:label="item.NAME"
:value="item.ID"
v-for="item in stepList"
:key="item.STEP_ID"
:label="item.STEP_NAME"
:value="item.STEP_ID"
/>
</el-select>
</el-form-item>
@ -53,15 +53,14 @@
<el-table-column prop="APPLY_USER_NAME" label="申请人" />
<el-table-column prop="ANALYZE_USER_NAME" label="分析人" />
<el-table-column prop="CONFIRM_USER_NAME" label="作业负责人" />
<el-table-column prop="APPROVE_USER_NAME" label="所在单位负责人" />
<el-table-column prop="LEADER_USER_NAME" label="所在单位负责人" />
<el-table-column prop="ACCEPT_USER_NAME" label="验收部门负责人" />
<el-table-column label="审核状态">
<template v-slot="{ row }">
{{
entrance === "job_data"
? translationStatus(row.APPLY_STATUS, stateList)
: "已归档"
}}
<span v-if="row.STEP_ID === 0"></span>
<span v-else-if="row.STATUS === -2">气体检测打回</span>
<span v-else-if="row.STEP_ID !== -1">{{ row.NEXT_STEP_NAME }}</span>
<span v-else>{{ row.STEP_NAME }}</span>
</template>
</el-table-column>
<el-table-column label="操作" width="250">
@ -69,9 +68,8 @@
<el-button
v-if="
entrance === 'job_data' &&
row.APPLY_STATUS !== '6' &&
row.APPLY_STATUS !== '-99' &&
row.APPLY_STATUS !== '-98'
row.STATUS > -1 &&
row.NEXT_STEP_ID !== 99
"
type="primary"
text
@ -92,7 +90,7 @@
type="primary"
text
link
@click="fnFlowChart(row)"
@click="fnFlowChart(row.CONFINEDSPACE_ID)"
v-if="entrance === 'job_data'"
>
流程图
@ -119,18 +117,22 @@
</layout-card>
<flow-chart
v-model:visible="data.flowChartDialog.visible"
:info="data.flowChartDialog.info"
:flowList="data.flowChartDialog.flowList"
/>
</div>
</template>
<script setup>
import { serialNumber, translationStatus } from "@/assets/js/utils.js";
import { serialNumber } from "@/assets/js/utils.js";
import { useRouter } from "vue-router";
import useListData from "@/assets/js/useListData.js";
import { getConfinedSpaceList } from "@/request/confined_space.js";
import { reactive } from "vue";
import { reactive, ref } from "vue";
import FlowChart from "./components/flow_chart.vue";
import {
getConfinedSpaceFlow,
getTaskSetps,
getConfinedSpaceList,
} from "@/request/eight_work.js";
const props = defineProps({
entrance: {
@ -138,32 +140,34 @@ const props = defineProps({
default: "job_data",
},
});
const stateList = [
{ ID: "0", NAME: "受限空间作业待提交" },
{ ID: "1", NAME: "作业负责人待审核" },
{ ID: "4", NAME: "所在单位待审核" },
{ ID: "5", NAME: "待验收" },
{ ID: "6", NAME: "验收归档" },
{ ID: "-4", NAME: "作业负责人审核打回" },
{ ID: "-5", NAME: "所在单位审核打回" },
{ ID: "-6", NAME: "验收打回" },
{ ID: "-99", NAME: "已作废(监护人未签字)" },
{ ID: "-98", NAME: "已作废(未进行气体检测)" },
];
const stepList = ref([]);
const getStepList = async () => {
const { list } = await getTaskSetps({ TASK_ID: 1 });
stepList.value = [
{ STEP_NAME: "请选择", STEP_ID: "" },
...list,
{ STEP_NAME: "验收归档", STEP_ID: "99" },
];
};
getStepList();
const router = useRouter();
const { list, pagination, searchForm, fnGetData, fnResetPagination } =
useListData(getConfinedSpaceList, {
otherParams: props.entrance === "archive" ? { APPLY_STATUS: "6" } : {},
otherParams: props.entrance === "archive" ? { STEP_ID: "99" } : {},
});
const data = reactive({
flowChartDialog: {
visible: false,
info: {},
flowList: {},
},
});
const fnFlowChart = (info) => {
const fnFlowChart = async (CONFINEDSPACE_ID) => {
const { flowList } = await getConfinedSpaceFlow({ CONFINEDSPACE_ID });
data.flowChartDialog.visible = true;
data.flowChartDialog.info = info;
data.flowChartDialog.flowList = flowList;
};
</script>

View File

@ -16,13 +16,13 @@
</el-form-item>
</el-col>
<el-col :span="6" v-if="entrance === 'job_data'">
<el-form-item label="状态" prop="APPLY_STATUS">
<el-select v-model="searchForm.APPLY_STATUS">
<el-form-item label="状态" prop="STEP_ID">
<el-select v-model="searchForm.STEP_ID">
<el-option
v-for="item in stateList"
:key="item.ID"
:label="item.NAME"
:value="item.ID"
v-for="item in stepList"
:key="item.STEP_ID"
:label="item.STEP_NAME"
:value="item.STEP_ID"
/>
</el-select>
</el-form-item>
@ -50,12 +50,8 @@
</template>
</el-table-column>
<el-table-column prop="CHECK_NO" label="编号" show-overflow-tooltip />
<el-table-column prop="APPLY_USER" label="填写人" />
<el-table-column
prop="CONSTRUCTION_USER_NAME"
label="作业负责人"
show-overflow-tooltip
/>
<el-table-column prop="APPLY_USER_NAME" label="申请人" />
<el-table-column prop="CONFIRM_USER_NAME" label="作业负责人" />
<el-table-column label="所在单位负责人" show-overflow-tooltip>
<template v-slot="{ row }">
{{ row.LEADER_USER_NAME || " 已跳过" }}
@ -76,19 +72,21 @@
label="验收部门负责人"
show-overflow-tooltip
/>
<el-table-column label="审核状态">
<el-table-column label="审核状态" width="170">
<template v-slot="{ row }">
{{
entrance === "job_data"
? translationStatus(row.APPLY_STATUS, stateList)
: "已归档"
}}
<span v-if="row.STEP_ID === 0"></span>
<span v-else-if="row.STEP_ID !== -1">{{ row.NEXT_STEP_NAME }}</span>
<span v-else>{{ row.STEP_NAME }}</span>
</template>
</el-table-column>
<el-table-column label="操作" width="250">
<template v-slot="{ row }">
<el-button
v-if="entrance === 'job_data' && row.APPLY_STATUS !== '6'"
v-if="
entrance === 'job_data' &&
row.STATUS > -1 &&
row.NEXT_STEP_ID !== 99
"
type="primary"
text
link
@ -108,7 +106,7 @@
type="primary"
text
link
@click="fnFlowChart(row)"
@click="fnFlowChart(row.HIGHWORK_ID)"
v-if="entrance === 'job_data'"
>
流程图
@ -135,18 +133,22 @@
</layout-card>
<flow-chart
v-model:visible="data.flowChartDialog.visible"
:info="data.flowChartDialog.info"
:flowList="data.flowChartDialog.flowList"
/>
</div>
</template>
<script setup>
import { serialNumber, translationStatus } from "@/assets/js/utils.js";
import { serialNumber } from "@/assets/js/utils.js";
import { useRouter } from "vue-router";
import useListData from "@/assets/js/useListData.js";
import { reactive } from "vue";
import { reactive, ref } from "vue";
import FlowChart from "./components/flow_chart.vue";
import { getHighList } from "@/request/high.js";
import {
getHighWorkFlow,
getHighWorkList,
getTaskSetps,
} from "@/request/eight_work.js";
const props = defineProps({
entrance: {
@ -154,34 +156,32 @@ const props = defineProps({
default: "job_data",
},
});
const stateList = [
{ ID: "0", NAME: "高处作业待提交" },
{ ID: "1", NAME: "作业负责人待审核" },
{ ID: "2", NAME: "所在单位待审核" },
{ ID: "3", NAME: "审核部门待审核" },
{ ID: "4", NAME: "审批部门待审核" },
{ ID: "5", NAME: "待验收" },
{ ID: "6", NAME: "验收归档" },
{ ID: "-2", NAME: "作业负责人审核打回" },
{ ID: "-3", NAME: "所在单位审核打回" },
{ ID: "-4", NAME: "审核部门审核打回" },
{ ID: "-5", NAME: "审批部门审核打回" },
{ ID: "-6", NAME: "验收打回" },
];
const stepList = ref([]);
const getStepList = async () => {
const { list } = await getTaskSetps({ TASK_ID: 1 });
stepList.value = [
{ STEP_NAME: "请选择", STEP_ID: "" },
...list,
{ STEP_NAME: "验收归档", STEP_ID: "99" },
];
};
getStepList();
const router = useRouter();
const { list, pagination, searchForm, fnGetData, fnResetPagination } =
useListData(getHighList, {
otherParams: props.entrance === "archive" ? { APPLY_STATUS: "6" } : {},
useListData(getHighWorkList, {
otherParams: props.entrance === "archive" ? { STEP_ID: "99" } : {},
});
const data = reactive({
flowChartDialog: {
visible: false,
info: {},
flowList: {},
},
});
const fnFlowChart = (info) => {
const fnFlowChart = async (HIGHWORK_ID) => {
const { flowList } = await getHighWorkFlow({ HIGHWORK_ID });
data.flowChartDialog.visible = true;
data.flowChartDialog.info = info;
data.flowChartDialog.flowList = flowList;
};
</script>

View File

@ -169,7 +169,7 @@ getStepList();
const router = useRouter();
const { list, pagination, searchForm, fnGetData, fnResetPagination } =
useListData(getHotWorkList, {
otherParams: props.entrance === "archive" ? { APPLY_STATUS: "8" } : {},
otherParams: props.entrance === "archive" ? { STEP_ID: "99" } : {},
});
const data = reactive({
flowChartDialog: {