fix: BUG修改
This commit is contained in:
parent
06bed84d68
commit
56a6c86836
@ -81,7 +81,7 @@ export const subGovermentItemDetailList = (params: any) => {
|
|||||||
return http.post(BASEURL + `/gov/investmentPaymentDetail/list`, params);
|
return http.post(BASEURL + `/gov/investmentPaymentDetail/list`, params);
|
||||||
};
|
};
|
||||||
|
|
||||||
// 全景计划------------
|
// 全景计划(项目端)------------
|
||||||
// 全景计划分页列表
|
// 全景计划分页列表
|
||||||
export const globalPlanList = (params: any) => {
|
export const globalPlanList = (params: any) => {
|
||||||
return http.post(BASEURL + `/project/projectNodePlan/page`, params);
|
return http.post(BASEURL + `/project/projectNodePlan/page`, params);
|
||||||
@ -94,3 +94,17 @@ export const globalPlanAdd = (params: any) => {
|
|||||||
export const globalPlanEdit = (params: any) => {
|
export const globalPlanEdit = (params: any) => {
|
||||||
return http.post(BASEURL + `/project/projectNodePlan/edit`, params);
|
return http.post(BASEURL + `/project/projectNodePlan/edit`, params);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
// 全景计划(政务端)------------
|
||||||
|
// 全景计划分页列表
|
||||||
|
export const globalPlanGovermentList = (params: any) => {
|
||||||
|
return http.post(BASEURL + `/gov/projectNodePlan/page`, params);
|
||||||
|
};
|
||||||
|
// 全景计划项目分页列表
|
||||||
|
export const globalPlanProList = (params: any) => {
|
||||||
|
return http.post(BASEURL + `/gov/projectNodePlan/projectPage`, params);
|
||||||
|
};
|
||||||
|
// 全景计划工程分页列表
|
||||||
|
export const globalPlanEngList = (params: any) => {
|
||||||
|
return http.post(BASEURL + `/gov/projectNodePlan/engineeringPage`, params);
|
||||||
|
};
|
||||||
|
|||||||
@ -24,7 +24,15 @@
|
|||||||
<div class="vaks">状态</div>
|
<div class="vaks">状态</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<vue3-seamless-scroll :list="list" class="scroll" :hover="true" :step="0.4" :singleWaitTime="3000" :wheel="true">
|
<vue3-seamless-scroll
|
||||||
|
v-if="list.length > 0"
|
||||||
|
:list="list"
|
||||||
|
class="scroll"
|
||||||
|
:hover="true"
|
||||||
|
:step="0.2"
|
||||||
|
:singleWaitTime="3000"
|
||||||
|
:wheel="true"
|
||||||
|
>
|
||||||
<div class="item" v-for="(item, index) in list" :key="index">
|
<div class="item" v-for="(item, index) in list" :key="index">
|
||||||
<div class="time">{{ item.create_time }}</div>
|
<div class="time">{{ item.create_time }}</div>
|
||||||
<div class="qs">{{ item.type }}</div>
|
<div class="qs">{{ item.type }}</div>
|
||||||
@ -78,10 +86,24 @@ const getEnvironmentAlarmStatFn = async () => {
|
|||||||
});
|
});
|
||||||
};
|
};
|
||||||
// 获取报警列表
|
// 获取报警列表
|
||||||
const list = ref([{ time: "" }]);
|
const list = ref([]);
|
||||||
const getEnvironmentAlarmFn = async () => {
|
const getEnvironmentAlarmFn = async () => {
|
||||||
const res = await getEnvironmentAlarm();
|
const res = await getEnvironmentAlarm();
|
||||||
list.value = res.result;
|
list.value = res.result;
|
||||||
|
// if (res.result.length > 0) {
|
||||||
|
// } else {
|
||||||
|
// list.value = [
|
||||||
|
// { create_time: "2022-01-01", type: "污染", cause: "泄露", state: 1 },
|
||||||
|
// { create_time: "2022-02-02", type: "污染", cause: "泄露", state: 1 },
|
||||||
|
// { create_time: "2022-03-03", type: "污染", cause: "泄露", state: 1 },
|
||||||
|
// { create_time: "2022-04-04", type: "污染", cause: "泄露", state: 1 },
|
||||||
|
// { create_time: "2022-05-05", type: "污染", cause: "泄露", state: 1 },
|
||||||
|
// { create_time: "2022-06-06", type: "污染", cause: "泄露", state: 1 },
|
||||||
|
// { create_time: "2022-07-07", type: "污染", cause: "泄露", state: 1 },
|
||||||
|
// { create_time: "2022-08-08", type: "污染", cause: "泄露", state: 1 }
|
||||||
|
// ];
|
||||||
|
// }
|
||||||
|
console.log(list.value);
|
||||||
};
|
};
|
||||||
|
|
||||||
const rigthBottRigth = ref();
|
const rigthBottRigth = ref();
|
||||||
|
|||||||
@ -4,6 +4,7 @@
|
|||||||
width: 100%;
|
width: 100%;
|
||||||
height: 100%;
|
height: 100%;
|
||||||
.leftMenu {
|
.leftMenu {
|
||||||
|
width: 300px;
|
||||||
// width: 290px;
|
// width: 290px;
|
||||||
// 页面的项目工程
|
// 页面的项目工程
|
||||||
:deep(.item) {
|
:deep(.item) {
|
||||||
@ -55,6 +56,7 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
.table-box {
|
.table-box {
|
||||||
|
width: calc(100% - 320px);
|
||||||
height: 100%;
|
height: 100%;
|
||||||
.table {
|
.table {
|
||||||
margin-left: 20px;
|
margin-left: 20px;
|
||||||
|
|||||||
@ -16,8 +16,8 @@
|
|||||||
}}</span>
|
}}</span>
|
||||||
<div class="leftMenu_item">
|
<div class="leftMenu_item">
|
||||||
<div class="video">
|
<div class="video">
|
||||||
<img src="@/assets/images/leftTab/设备列表.png" alt="" />
|
<img style="margin-right: 5px" src="@/assets/images/AIwaring/dustMap.png" alt="" />
|
||||||
<span class="middleSize">影像视频树:{{ data.deviceNum }}</span>
|
<span class="middleSize">{{ data.projectAddress || data.address }}</span>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
@ -35,14 +35,12 @@
|
|||||||
:pagination="true"
|
:pagination="true"
|
||||||
background
|
background
|
||||||
:isShowSearch="false"
|
:isShowSearch="false"
|
||||||
|
:onReset="true"
|
||||||
>
|
>
|
||||||
<template #formButton="scope">
|
|
||||||
<el-button class="btnStyle">刷新</el-button>
|
|
||||||
</template>
|
|
||||||
<!-- 表格操作 -->
|
<!-- 表格操作 -->
|
||||||
<template #operation="scope">
|
<template #operation="{ row }">
|
||||||
<el-button class="btnStyle" type="primary" @click="handleAddItem()">
|
<el-button type="primary" link @click="handleItemDetail(row)">
|
||||||
<!-- <img src="@/assets/images/tableIcon/configureIcon.png" alt="" class="configureIcon" /> -->
|
<img src="@/assets/images/tableIcon/look.png" alt="" class="configureIcon" />
|
||||||
<span>查看</span>
|
<span>查看</span>
|
||||||
</el-button>
|
</el-button>
|
||||||
</template>
|
</template>
|
||||||
@ -64,53 +62,82 @@
|
|||||||
|
|
||||||
<script lang="ts" setup>
|
<script lang="ts" setup>
|
||||||
import { ref, reactive, onMounted, watch } from "vue";
|
import { ref, reactive, onMounted, watch } from "vue";
|
||||||
import {
|
|
||||||
getDustprojectPage,
|
|
||||||
getDustengineeringPage,
|
|
||||||
getAIQuestionPage,
|
|
||||||
addAIrecords,
|
|
||||||
getAiMonitorDev
|
|
||||||
} from "@/api/modules/goverment";
|
|
||||||
import { videoList, videoDataAdd, videoDataEdit, videoDataDelete } from "@/api/modules/enterpriseApi";
|
|
||||||
import Pagination from "@/components/ProTable/components/Pagination.vue";
|
|
||||||
import { ElMessage, UploadProps } from "element-plus";
|
|
||||||
import type { FormRules, FormInstance, UploadInstance } from "element-plus";
|
|
||||||
import { GlobalStore } from "@/stores";
|
import { GlobalStore } from "@/stores";
|
||||||
import { Delete } from "@element-plus/icons-vue";
|
|
||||||
import { jxj_User } from "@/api/types";
|
|
||||||
import { useHandleData } from "@/hooks/useHandleData";
|
|
||||||
import LeftMenu from "@/components/LeftMenu/LeftMenu.vue";
|
import LeftMenu from "@/components/LeftMenu/LeftMenu.vue";
|
||||||
import type { ResAiProjectPage, ResAiEngineerPage } from "@/api/types/government/AIwaring";
|
import type { ResAiProjectPage, ResAiEngineerPage } from "@/api/types/government/AIwaring";
|
||||||
import ProTable from "@/components/ProTable/index.vue";
|
import ProTable from "@/components/ProTable/index.vue";
|
||||||
import DialogForm from "@/components/DialogForm/index.vue";
|
import DialogForm from "@/components/DialogForm/index.vue";
|
||||||
import { ColumnProps } from "@/components/ProTable/interface";
|
import { ColumnProps } from "@/components/ProTable/interface";
|
||||||
import { getRealTimePage } from "@/api/modules/project";
|
import { globalPlanGovermentList, globalPlanProList, globalPlanEngList } from "@/api/modules/huizhou";
|
||||||
|
import { getDicList } from "@/api/modules/jxjview";
|
||||||
const pages = ref({
|
const pages = ref({
|
||||||
pageNo: 1,
|
pageNo: 1,
|
||||||
pageSize: 7,
|
pageSize: 7,
|
||||||
total: 0
|
total: 0
|
||||||
});
|
});
|
||||||
const records = ref<ResAiProjectPage[] | ResAiEngineerPage[]>([]);
|
const records = ref<ResAiProjectPage[] | ResAiEngineerPage[]>([]);
|
||||||
|
const DicMainList = ref([]);
|
||||||
const active = ref(0);
|
const active = ref(0);
|
||||||
const fileList = ref([]);
|
|
||||||
const store = GlobalStore();
|
const store = GlobalStore();
|
||||||
// 表格配置项
|
// 表格配置项
|
||||||
const columns: ColumnProps[] = [
|
const columns: ColumnProps[] = [
|
||||||
{ type: "index", label: "序号", width: 80 },
|
{ type: "index", label: "序号", width: 80 },
|
||||||
{ prop: "name", label: "节点编号" },
|
{
|
||||||
{ prop: "name", label: "节点名称", search: { el: "input" } },
|
prop: "nodeNumber",
|
||||||
{ prop: "name", label: "节点类型" },
|
label: "节点编号",
|
||||||
{ prop: "name", label: "标准完成时间" },
|
width: 150
|
||||||
{ prop: "name", label: "计划完成时间" },
|
},
|
||||||
{ prop: "name", label: "预计完成时间" },
|
// 多级 prop
|
||||||
{ prop: "name", label: "实际完成时间" },
|
{ prop: "nodeName", label: "节点名称", width: 150, search: { el: "input" } },
|
||||||
{ prop: "name", label: "状态", search: { el: "select" } },
|
{ prop: "type", label: "节点类型", width: 150 },
|
||||||
{ prop: "name", label: "智能条线" },
|
{ prop: "standardCompleteTime", label: "标准完成时间", width: 150 },
|
||||||
{ prop: "name", label: "节点责任人编号" },
|
{ prop: "planCompleteTime", label: "计划完成时间", width: 150 },
|
||||||
{ prop: "name", label: "节点责任人" },
|
{ prop: "expectCompleteTime", label: "预计完成时间", width: 150 },
|
||||||
{ prop: "name", label: "节点失效标记" },
|
{
|
||||||
{ prop: "name", label: "是否退回" },
|
prop: "state",
|
||||||
{ prop: "operation", label: "操作", fixed: "right", width: 120 }
|
label: "状态",
|
||||||
|
width: 150,
|
||||||
|
isShow: false,
|
||||||
|
search: { el: "select" },
|
||||||
|
enum: DicMainList.value,
|
||||||
|
fieldNames: { label: "dictValue", value: "dictLabel" }
|
||||||
|
},
|
||||||
|
{
|
||||||
|
prop: "status",
|
||||||
|
label: "状态",
|
||||||
|
width: 150
|
||||||
|
},
|
||||||
|
{
|
||||||
|
prop: "realCompleteTime",
|
||||||
|
label: "实际完成时间",
|
||||||
|
width: 150,
|
||||||
|
search: {
|
||||||
|
el: "date-picker",
|
||||||
|
span: 2,
|
||||||
|
props: { type: "daterange", format: "YYYY-MM-DD", valueFormat: "YYYY-MM-DD" }
|
||||||
|
// defaultValue: "2023-05"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{ prop: "phaseName", label: "智能条线", width: 150 },
|
||||||
|
{ prop: "chargerNumber", label: "节点责任人编号", width: 150 },
|
||||||
|
{ prop: "chargerName", label: "节点责任人", width: 150 },
|
||||||
|
{
|
||||||
|
prop: "isDeleted",
|
||||||
|
label: "节点失效标记",
|
||||||
|
width: 150,
|
||||||
|
render: scoped => {
|
||||||
|
return scoped.row.isDeleted == 0 ? "有效" : "失效";
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
prop: "isSendBack",
|
||||||
|
label: "是否退回",
|
||||||
|
width: 150,
|
||||||
|
render: scoped => {
|
||||||
|
return scoped.row.isSendBack == 1 ? "是" : "否";
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{ prop: "operation", label: "操作", width: 100, fixed: "right" }
|
||||||
];
|
];
|
||||||
interface formData {
|
interface formData {
|
||||||
title: string;
|
title: string;
|
||||||
@ -125,93 +152,172 @@ const formData = ref<formData>({
|
|||||||
videoUrl: ""
|
videoUrl: ""
|
||||||
});
|
});
|
||||||
const visible = ref(false);
|
const visible = ref(false);
|
||||||
const title = ref("新增录像");
|
const title = ref("新增");
|
||||||
|
|
||||||
const pageable = ref({
|
|
||||||
pageNo: 1,
|
|
||||||
pageSize: 12,
|
|
||||||
total: 0
|
|
||||||
});
|
|
||||||
|
|
||||||
const videoData = ref({
|
|
||||||
records: []
|
|
||||||
});
|
|
||||||
const form = ref({
|
|
||||||
title: "",
|
|
||||||
createTime: "",
|
|
||||||
startTime: "",
|
|
||||||
endTime: ""
|
|
||||||
});
|
|
||||||
// 搜索用的项目sn或者工程sn
|
// 搜索用的项目sn或者工程sn
|
||||||
const searchSn = ref("");
|
const searchSn = ref("");
|
||||||
|
// 获取 ProTable 元素,调用其获取刷新数据方法(还能获取到当前查询参数,方便导出携带参数)
|
||||||
|
const proTable = ref();
|
||||||
// 弹窗中的配置
|
// 弹窗中的配置
|
||||||
const formConfig = {
|
const formConfig = {
|
||||||
formItemConfig: [
|
formItemConfig: [
|
||||||
{
|
{
|
||||||
label: "节点编码",
|
label: "节点编码",
|
||||||
prop: "governmentName",
|
prop: "nodeNumber",
|
||||||
type: "input"
|
type: "input",
|
||||||
|
disabled: true
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
label: "节点名称",
|
label: "节点名称",
|
||||||
prop: "governmentTel",
|
prop: "nodeName",
|
||||||
type: "input"
|
type: "input",
|
||||||
|
disabled: true
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
label: "节点类型",
|
label: "节点类型",
|
||||||
prop: "account",
|
prop: "type",
|
||||||
type: "input"
|
type: "input",
|
||||||
|
disabled: true
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
label: "标准完成时间",
|
label: "标准完成时间",
|
||||||
prop: "password",
|
prop: "standardCompleteTime",
|
||||||
type: "date"
|
type: "date",
|
||||||
|
disabled: true
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
label: "计划完成时间",
|
label: "计划完成时间",
|
||||||
prop: "password",
|
prop: "planCompleteTime",
|
||||||
type: "date"
|
type: "date",
|
||||||
|
disabled: true
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
label: "预计完成时间",
|
label: "预计完成时间",
|
||||||
prop: "password",
|
prop: "expectCompleteTime",
|
||||||
type: "date"
|
type: "date",
|
||||||
|
disabled: true
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
label: "实际完成时间",
|
label: "实际完成时间",
|
||||||
prop: "password",
|
prop: "realCompleteTime",
|
||||||
type: "date"
|
type: "date",
|
||||||
|
disabled: true
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
label: "状态",
|
label: "状态",
|
||||||
prop: "password",
|
prop: "state",
|
||||||
type: "input"
|
type: "select",
|
||||||
|
data: [],
|
||||||
|
clearable: true,
|
||||||
|
disabled: true
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
label: "实际偏差",
|
label: "实际偏差",
|
||||||
prop: "password",
|
prop: "actualDeviation",
|
||||||
type: "input"
|
type: "input",
|
||||||
|
disabled: true
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
label: "职能线条",
|
label: "职能线条",
|
||||||
prop: "password",
|
prop: "phaseName",
|
||||||
type: "input"
|
type: "input",
|
||||||
|
disabled: true
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
label: "节点负责人编号",
|
label: "节点负责人编号",
|
||||||
prop: "password",
|
prop: "chargerNumber",
|
||||||
type: "input"
|
type: "input",
|
||||||
|
disabled: true
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
label: "节点负责人",
|
label: "节点负责人",
|
||||||
prop: "password",
|
prop: "chargerName",
|
||||||
type: "input"
|
type: "input",
|
||||||
|
disabled: true
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
rules: {}
|
rules: {
|
||||||
|
nodeNumber: [
|
||||||
|
{
|
||||||
|
required: true,
|
||||||
|
message: "请输入",
|
||||||
|
trigger: "blur"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
nodeName: [
|
||||||
|
{
|
||||||
|
required: true,
|
||||||
|
message: "请输入",
|
||||||
|
trigger: "blur"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
type: [
|
||||||
|
{
|
||||||
|
required: true,
|
||||||
|
message: "请输入",
|
||||||
|
trigger: "blur"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
standardCompleteTime: [
|
||||||
|
{
|
||||||
|
required: true,
|
||||||
|
message: "请输入",
|
||||||
|
trigger: "blur"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
planCompleteTime: [
|
||||||
|
{
|
||||||
|
required: true,
|
||||||
|
message: "请输入",
|
||||||
|
trigger: "blur"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
engineeringSn: [
|
||||||
|
{
|
||||||
|
required: true,
|
||||||
|
message: "请输入",
|
||||||
|
trigger: "change"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
phaseName: [
|
||||||
|
{
|
||||||
|
required: true,
|
||||||
|
message: "请输入",
|
||||||
|
trigger: "blur"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
chargerNumber: [
|
||||||
|
{
|
||||||
|
required: true,
|
||||||
|
message: "请输入",
|
||||||
|
trigger: "blur"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
chargerName: [
|
||||||
|
{
|
||||||
|
required: true,
|
||||||
|
message: "请输入",
|
||||||
|
trigger: "blur"
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
};
|
};
|
||||||
// 项目或者工程名字
|
// 项目或者工程名字
|
||||||
const searchName = ref<string>("");
|
const searchName = ref<string>("");
|
||||||
|
const getDicMainList = async () => {
|
||||||
|
// 获取状态字典
|
||||||
|
const { result } = await getDicList({ dictType: "node_plan_state" });
|
||||||
|
console.log(result);
|
||||||
|
if (result.length > 0) {
|
||||||
|
formConfig.formItemConfig[7].data = result.map(item => {
|
||||||
|
return {
|
||||||
|
label: item.dictValue,
|
||||||
|
value: item.status
|
||||||
|
};
|
||||||
|
});
|
||||||
|
DicMainList.value.length = 0;
|
||||||
|
DicMainList.value.push(...result);
|
||||||
|
}
|
||||||
|
};
|
||||||
// dataCallback 是对于返回的表格数据做处理,如果你后台返回的数据不是 list && total && pageNum && pageSize 这些字段,那么你可以在这里进行处理成这些字段
|
// dataCallback 是对于返回的表格数据做处理,如果你后台返回的数据不是 list && total && pageNum && pageSize 这些字段,那么你可以在这里进行处理成这些字段
|
||||||
// 或者直接去 hooks/useTable.ts 文件中把字段改为你后端对应的就行
|
// 或者直接去 hooks/useTable.ts 文件中把字段改为你后端对应的就行
|
||||||
const dataCallback = (data: any) => {
|
const dataCallback = (data: any) => {
|
||||||
@ -227,60 +333,55 @@ const dataCallback = (data: any) => {
|
|||||||
// 默认不做操作就直接在 ProTable 组件上绑定 :requestApi="getUserList"
|
// 默认不做操作就直接在 ProTable 组件上绑定 :requestApi="getUserList"
|
||||||
const getTableList = (params: any) => {
|
const getTableList = (params: any) => {
|
||||||
let newParams = JSON.parse(JSON.stringify(params));
|
let newParams = JSON.parse(JSON.stringify(params));
|
||||||
return getRealTimePage(newParams);
|
if (newParams.realCompleteTime) {
|
||||||
|
newParams.realCompleteTime_begin = newParams.realCompleteTime[0];
|
||||||
|
newParams.realCompleteTime_end = newParams.realCompleteTime[1];
|
||||||
|
delete newParams.realCompleteTime;
|
||||||
|
}
|
||||||
|
if (active.value === 0) {
|
||||||
|
newParams.projectSn = searchSn.value;
|
||||||
|
} else {
|
||||||
|
newParams.engineeringSn = searchSn.value;
|
||||||
|
}
|
||||||
|
return globalPlanGovermentList(newParams);
|
||||||
};
|
};
|
||||||
// 页面的项目名称和工程名称的div点击事件
|
// 页面的项目名称和工程名称的div点击事件
|
||||||
const onSearch = async (params: ResAiProjectPage | ResAiEngineerPage) => {
|
const onSearch = async (params: ResAiProjectPage | ResAiEngineerPage) => {
|
||||||
const { result } = await getAIQuestionPage(
|
|
||||||
active.value === 0
|
|
||||||
? { projectSn: (params as ResAiProjectPage).projectSn, pageNo: pageable.value.pageNo, pageSize: pageable.value.pageSize }
|
|
||||||
: {
|
|
||||||
engineeringSn: (params as ResAiEngineerPage).engineeringSn,
|
|
||||||
pageNo: pageable.value.pageNo,
|
|
||||||
pageSize: pageable.value.pageSize
|
|
||||||
}
|
|
||||||
);
|
|
||||||
pageable.value.total = Number(result.total);
|
|
||||||
active.value === 0
|
active.value === 0
|
||||||
? (searchSn.value = (params as ResAiProjectPage).projectSn)
|
? (searchSn.value = (params as ResAiProjectPage).projectSn)
|
||||||
: (searchSn.value = (params as ResAiEngineerPage).engineeringSn);
|
: (searchSn.value = (params as ResAiEngineerPage).engineeringSn);
|
||||||
active.value === 0
|
active.value === 0
|
||||||
? (searchName.value = (params as ResAiProjectPage).projectName)
|
? (searchName.value = (params as ResAiProjectPage).projectName)
|
||||||
: (searchName.value = (params as ResAiEngineerPage).engineeringName);
|
: (searchName.value = (params as ResAiEngineerPage).engineeringName);
|
||||||
getVideoData();
|
proTable.value.getTableList();
|
||||||
};
|
};
|
||||||
// leftMenu页面的搜索按钮
|
// leftMenu页面的搜索按钮
|
||||||
const onSearchInput = async (params: string) => {
|
const onSearchInput = async (params: string) => {
|
||||||
console.log(params);
|
console.log(params);
|
||||||
if (active.value === 0) {
|
if (active.value === 0) {
|
||||||
const { result } = await getDustprojectPage({ projectName: params, ...pages.value });
|
const { result } = await globalPlanProList({ projectName: params, ...pages.value });
|
||||||
records.value = result.records;
|
records.value = result.records;
|
||||||
} else {
|
} else {
|
||||||
const { result } = await getDustengineeringPage({ engineeringName: params, ...pages.value });
|
const { result } = await globalPlanEngList({ engineeringName: params, ...pages.value });
|
||||||
records.value = result.records;
|
records.value = result.records;
|
||||||
}
|
}
|
||||||
|
proTable.value.getTableList();
|
||||||
};
|
};
|
||||||
// leftMenu页面的分页
|
// leftMenu页面的分页
|
||||||
const onCurChange = async (params: number) => {
|
const onCurChange = async (params: number) => {
|
||||||
if (active.value === 0) {
|
if (active.value === 0) {
|
||||||
const { result } = await getDustprojectPage({ ...pages.value, pageNo: params });
|
const { result } = await globalPlanProList({ ...pages.value, pageNo: params });
|
||||||
records.value = result.records;
|
records.value = result.records;
|
||||||
} else {
|
} else {
|
||||||
const { result } = await getDustengineeringPage({ ...pages.value, pageNo: params });
|
const { result } = await globalPlanEngList({ ...pages.value, pageNo: params });
|
||||||
records.value = result.records;
|
records.value = result.records;
|
||||||
pages.value.total = +result.total;
|
pages.value.total = +result.total;
|
||||||
}
|
}
|
||||||
pages.value.total = +res.result.total;
|
pages.value.total = +res.result.total;
|
||||||
};
|
};
|
||||||
const getVideoData = async () => {
|
|
||||||
const res = await videoList({ ...pageable.value, ...form.value });
|
|
||||||
videoData.value.records = res.result.records;
|
|
||||||
console.log(videoData.value);
|
|
||||||
console.log(res);
|
|
||||||
};
|
|
||||||
// 获取项目名称分页
|
// 获取项目名称分页
|
||||||
const getProPage = async () => {
|
const getProPage = async () => {
|
||||||
const { result } = await getDustprojectPage(pages.value);
|
const { result } = await globalPlanProList(pages.value);
|
||||||
records.value = result.records;
|
records.value = result.records;
|
||||||
records.value.map(item => {
|
records.value.map(item => {
|
||||||
let showGif = false;
|
let showGif = false;
|
||||||
@ -290,7 +391,7 @@ const getProPage = async () => {
|
|||||||
};
|
};
|
||||||
// 获取工程名称分页
|
// 获取工程名称分页
|
||||||
const getEngPage = async () => {
|
const getEngPage = async () => {
|
||||||
const { result } = await getDustengineeringPage(pages.value);
|
const { result } = await globalPlanEngList(pages.value);
|
||||||
records.value = result.records;
|
records.value = result.records;
|
||||||
records.value.map(item => {
|
records.value.map(item => {
|
||||||
let showGif = false;
|
let showGif = false;
|
||||||
@ -298,16 +399,15 @@ const getEngPage = async () => {
|
|||||||
});
|
});
|
||||||
pages.value.total = +result.total;
|
pages.value.total = +result.total;
|
||||||
};
|
};
|
||||||
// 添加数据按钮
|
// 查看数据按钮
|
||||||
const handleAddItem = () => {
|
const handleItemDetail = async (row: any) => {
|
||||||
|
console.log(row);
|
||||||
|
formData.value = reactive({ ...row });
|
||||||
|
title.value = "查看";
|
||||||
visible.value = true;
|
visible.value = true;
|
||||||
title.value = "查看子分部分项";
|
|
||||||
// formData.value = reactive({});
|
|
||||||
};
|
};
|
||||||
// 新增,编辑数据
|
// 新增,编辑数据
|
||||||
const saveItem = async (form: any) => {
|
const saveItem = async (form: any) => {
|
||||||
// const res = await addGovernment(form);
|
|
||||||
// ElMessage.success("新增成功");
|
|
||||||
visible.value = false;
|
visible.value = false;
|
||||||
};
|
};
|
||||||
watch(
|
watch(
|
||||||
@ -330,7 +430,7 @@ watch(
|
|||||||
}
|
}
|
||||||
);
|
);
|
||||||
onMounted(async () => {
|
onMounted(async () => {
|
||||||
getVideoData();
|
getDicMainList();
|
||||||
await getProPage();
|
await getProPage();
|
||||||
onSearch(records.value[0]);
|
onSearch(records.value[0]);
|
||||||
searchSn.value = (records.value as ResAiProjectPage[])[0].projectSn;
|
searchSn.value = (records.value as ResAiProjectPage[])[0].projectSn;
|
||||||
|
|||||||
@ -0,0 +1,171 @@
|
|||||||
|
<template>
|
||||||
|
<div class="overview">
|
||||||
|
<el-dialog :show-close="false" v-model="visible1" @close="closeMain" width="30%">
|
||||||
|
<template #title>
|
||||||
|
<div class="title-detail">
|
||||||
|
<img src="@/assets/images/tableIcon/look.png" alt="" />
|
||||||
|
<span>审批</span>
|
||||||
|
<el-icon>
|
||||||
|
<close @click="closeMain" />
|
||||||
|
</el-icon>
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
|
<div class="content-detail">
|
||||||
|
<img src="@/assets/images/tableIcon/look.png" alt="" />
|
||||||
|
<span>是否通过审批?</span>
|
||||||
|
</div>
|
||||||
|
<template #footer>
|
||||||
|
<span class="dialog-footer">
|
||||||
|
<el-button class="hzCancelStyle" @click="singleAuditSubmit(1)">驳 回</el-button>
|
||||||
|
<el-button class="hzStyle" type="primary" @click="singleAuditSubmit(2)">通 过</el-button>
|
||||||
|
</span>
|
||||||
|
</template>
|
||||||
|
</el-dialog>
|
||||||
|
<el-dialog v-model="auditVisible" :append-to-body="true">
|
||||||
|
<template #title>
|
||||||
|
<div style="border-left: 2px solid #0f81ff; font-size: 20px; color: #333333">
|
||||||
|
<span style="margin-left: 5px">审核意见</span>
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
|
<el-input v-model="auditForm.content" type="textarea" :rows="2" placeholder="请输入内容" />
|
||||||
|
<template #footer>
|
||||||
|
<span class="dialog-footer">
|
||||||
|
<el-button @click="singleAuditSubmit(1)">驳 回</el-button>
|
||||||
|
<el-button type="primary" @click="singleAuditSubmit(2)">通 过</el-button>
|
||||||
|
</span>
|
||||||
|
</template>
|
||||||
|
</el-dialog>
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script lang="ts" setup>
|
||||||
|
import { onMounted, ref, watch, reactive } from "vue";
|
||||||
|
import { ElMessage, ElMessageBox } from "element-plus";
|
||||||
|
import type { FormInstance, UploadProps } from "element-plus";
|
||||||
|
import { singleOptionAudit } from "@/api/modules/goverment";
|
||||||
|
const props = defineProps({
|
||||||
|
auditDialogVisible: Boolean,
|
||||||
|
relativeId: String
|
||||||
|
});
|
||||||
|
const emits = defineEmits(["update:auditDialogVisible", "confirm"]);
|
||||||
|
const visible1 = ref(false);
|
||||||
|
const singleData = ref(); // 单个整改情况数据
|
||||||
|
const auditForm = ref({
|
||||||
|
content: ""
|
||||||
|
});
|
||||||
|
// 关闭主窗口
|
||||||
|
const closeMain = () => {
|
||||||
|
visible1.value = false;
|
||||||
|
};
|
||||||
|
// 单项审核提交
|
||||||
|
const singleAuditSubmit = async index => {
|
||||||
|
if (index == 1) {
|
||||||
|
let requestData = {
|
||||||
|
id: singleData.value.id,
|
||||||
|
suggest: auditForm.value.content,
|
||||||
|
examineState: 2
|
||||||
|
};
|
||||||
|
const res = await singleOptionAudit(requestData);
|
||||||
|
ElMessage.success("操作成功");
|
||||||
|
} else {
|
||||||
|
let requestData = {
|
||||||
|
id: singleData.value.id,
|
||||||
|
suggest: auditForm.value.content,
|
||||||
|
examineState: 1
|
||||||
|
};
|
||||||
|
const res = await singleOptionAudit(requestData);
|
||||||
|
ElMessage.success("操作成功");
|
||||||
|
}
|
||||||
|
auditVisible.value = false;
|
||||||
|
};
|
||||||
|
const auditVisible = ref(false);
|
||||||
|
// 监听父组件的visible,用来简介控制el-dialog的弹框开关,一般是用于开
|
||||||
|
watch(
|
||||||
|
() => props.auditDialogVisible,
|
||||||
|
(n, o) => {
|
||||||
|
visible1.value = n;
|
||||||
|
if (n) {
|
||||||
|
} else {
|
||||||
|
emits("confirm");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
);
|
||||||
|
// 监听el-dialog显示状态,再通过@update:visible 通知父组件,一般是用于关
|
||||||
|
watch(visible1, (n, o) => {
|
||||||
|
emits("update:auditDialogVisible", n);
|
||||||
|
});
|
||||||
|
onMounted(() => {});
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<style lang="scss" scoped>
|
||||||
|
@mixin fullwidth {
|
||||||
|
width: -webkit-fill-available;
|
||||||
|
width: -moz-available;
|
||||||
|
width: stretch;
|
||||||
|
}
|
||||||
|
@mixin flex {
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
}
|
||||||
|
@mixin title {
|
||||||
|
font-size: 16px;
|
||||||
|
font-family: Source Han Sans CN-Regular, Source Han Sans CN;
|
||||||
|
font-weight: 400;
|
||||||
|
color: var(--el-menu-text-color);
|
||||||
|
border-left: 2px solid #008bff;
|
||||||
|
padding-left: 5px;
|
||||||
|
}
|
||||||
|
.overview {
|
||||||
|
// background-color: #fff;
|
||||||
|
:deep(.el-dialog) {
|
||||||
|
position: relative;
|
||||||
|
}
|
||||||
|
.title-detail {
|
||||||
|
@include flex;
|
||||||
|
> img {
|
||||||
|
width: 16px;
|
||||||
|
height: 18px;
|
||||||
|
}
|
||||||
|
> span {
|
||||||
|
font-size: 20px;
|
||||||
|
font-family: Source Han Sans CN-Regular, Source Han Sans CN;
|
||||||
|
font-weight: 400;
|
||||||
|
color: var(--el-menu-text-color);
|
||||||
|
margin-left: 10px;
|
||||||
|
margin-right: auto;
|
||||||
|
}
|
||||||
|
:deep(.el-icon) {
|
||||||
|
cursor: pointer;
|
||||||
|
color: #a8abb2;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
.content-detail {
|
||||||
|
@include flex;
|
||||||
|
> img {
|
||||||
|
width: 11px;
|
||||||
|
height: 11px;
|
||||||
|
margin-right: 10px;
|
||||||
|
margin-left: 20px;
|
||||||
|
}
|
||||||
|
> span {
|
||||||
|
font-size: 12px;
|
||||||
|
font-family: Inter-Regular, Inter;
|
||||||
|
font-weight: 400;
|
||||||
|
color: var(--el-menu-text-color);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.test :deep(.el-input__wrapper) {
|
||||||
|
box-shadow: 0 0 0 0;
|
||||||
|
}
|
||||||
|
.test :deep(.el-input__inner) {
|
||||||
|
text-align: center;
|
||||||
|
}
|
||||||
|
:deep(.el-table__empty-text) {
|
||||||
|
min-height: 200px;
|
||||||
|
display: flex;
|
||||||
|
justify-content: center;
|
||||||
|
align-items: center;
|
||||||
|
}
|
||||||
|
</style>
|
||||||
@ -0,0 +1,50 @@
|
|||||||
|
.warning-page {
|
||||||
|
// background-color: blue;
|
||||||
|
display: flex;
|
||||||
|
width: 100%;
|
||||||
|
height: 100%;
|
||||||
|
.table-box {
|
||||||
|
height: 100%;
|
||||||
|
.table {
|
||||||
|
height: 100%;
|
||||||
|
:deep(.table-main) {
|
||||||
|
height: 100%;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
:deep(.el-scrollbar__view) {
|
||||||
|
width: 100%;
|
||||||
|
height: 100%;
|
||||||
|
|
||||||
|
// display: flex;
|
||||||
|
// flex-wrap: wrap;
|
||||||
|
}
|
||||||
|
:deep() {
|
||||||
|
.el-form-item__content > :not(button) {
|
||||||
|
// width: 160px;
|
||||||
|
}
|
||||||
|
.el-input__wrapper {
|
||||||
|
color: white;
|
||||||
|
font-size: 16px;
|
||||||
|
background-color: transparent;
|
||||||
|
border: none;
|
||||||
|
box-shadow: 0 0 0 1px var(--el-color-primary, var(--el-color-primary)) inset;
|
||||||
|
}
|
||||||
|
.el-input__inner {
|
||||||
|
color: white;
|
||||||
|
font-size: 16px;
|
||||||
|
}
|
||||||
|
.el-textarea__inner {
|
||||||
|
color: white;
|
||||||
|
font-size: 16px;
|
||||||
|
background-color: transparent;
|
||||||
|
border: none;
|
||||||
|
box-shadow: 0 0 0 1px var(--el-color-primary, var(--el-color-primary)) inset;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// :deep(.el-dialog__body) {
|
||||||
|
// padding: 0 0 0 0 !important;
|
||||||
|
// background-color: pink;
|
||||||
|
// }
|
||||||
@ -1,8 +1,124 @@
|
|||||||
<template>
|
<template>
|
||||||
<div class="">项目审批</div>
|
<div class="warning-page">
|
||||||
|
<div class="table-box">
|
||||||
|
<div class="table">
|
||||||
|
<ProTable
|
||||||
|
ref="proTable"
|
||||||
|
title="项目审批"
|
||||||
|
:columns="columns"
|
||||||
|
:requestApi="getTableList"
|
||||||
|
:dataCallback="dataCallback"
|
||||||
|
:tool-button="false"
|
||||||
|
:pagination="true"
|
||||||
|
background
|
||||||
|
:isShowSearch="false"
|
||||||
|
:onReset="false"
|
||||||
|
>
|
||||||
|
<!-- <template #formButton="scope">
|
||||||
|
<el-button class="addButtonStyle" @click="handleAddItem">新增</el-button>
|
||||||
|
</template> -->
|
||||||
|
<template #operation="{ row }">
|
||||||
|
<el-button type="primary" link @click="handleLookItem(row)">
|
||||||
|
<img src="@/assets/images/tableIcon/look.png" alt="" class="configureIcon" />
|
||||||
|
<span>审核</span>
|
||||||
|
</el-button>
|
||||||
|
</template>
|
||||||
|
<template #state="{ row }">
|
||||||
|
<span>{{
|
||||||
|
row.state == 1
|
||||||
|
? "执法中"
|
||||||
|
: row.state == 2
|
||||||
|
? "待整改"
|
||||||
|
: row.state == 3
|
||||||
|
? "待审核"
|
||||||
|
: row.state == 4
|
||||||
|
? "已闭合"
|
||||||
|
: row.state == 5
|
||||||
|
? "已驳回"
|
||||||
|
: ""
|
||||||
|
}}</span>
|
||||||
|
</template>
|
||||||
|
</ProTable>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<!-- 审核弹框 -->
|
||||||
|
<auditDialog v-model:auditDialogVisible="auditDialogVisible" :relativeId="relativeId" @confirm="allConfirm"></auditDialog>
|
||||||
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script setup lang="tsx" name="ProjectSupervisionRecord">
|
<script setup lang="tsx" name="ProjectSupervisionRecord">
|
||||||
import { ref, reactive, nextTick, computed } from "vue";
|
import { ref, onMounted } from "vue";
|
||||||
|
import { ElMessage, ElMessageBox, ElTree, FormInstance } from "element-plus";
|
||||||
|
import { ColumnProps } from "@/components/ProTable/interface";
|
||||||
|
import ProTable from "@/components/ProTable/index.vue";
|
||||||
|
import { statisticsTable } from "@/api/modules/goverment";
|
||||||
|
import auditDialog from "./components/auditDialog.vue";
|
||||||
|
const auditDialogVisible = ref(false);
|
||||||
|
// 表格配置项
|
||||||
|
const columns: ColumnProps[] = [
|
||||||
|
{ type: "index", label: "序号", width: 80 },
|
||||||
|
{
|
||||||
|
prop: "engineeringName",
|
||||||
|
label: "项目名称"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
prop: "inspectUserName",
|
||||||
|
label: "项目编号"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
prop: "buildEnt",
|
||||||
|
label: "项目类型"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
prop: "supervisorEnt",
|
||||||
|
label: "负责人"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
prop: "surveyEnt",
|
||||||
|
label: "手机号"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
prop: "designEnt",
|
||||||
|
label: "审批状态"
|
||||||
|
},
|
||||||
|
{ prop: "operation", label: "操作", fixed: "right", width: 100 }
|
||||||
|
];
|
||||||
|
const relativeId = ref("");
|
||||||
|
// 获取 ProTable 元素,调用其获取刷新数据方法(还能获取到当前查询参数,方便导出携带参数)
|
||||||
|
const proTable = ref();
|
||||||
|
// 子组件弹框确认回调
|
||||||
|
const allConfirm = val => {
|
||||||
|
console.log(val);
|
||||||
|
};
|
||||||
|
const handleLookItem = row => {
|
||||||
|
console.log(row);
|
||||||
|
relativeId.value = row.id;
|
||||||
|
auditDialogVisible.value = true;
|
||||||
|
};
|
||||||
|
const getTableList = (params: any) => {
|
||||||
|
let newParams = JSON.parse(JSON.stringify(params));
|
||||||
|
console.log(newParams);
|
||||||
|
if (newParams.createTime) {
|
||||||
|
newParams.createTime_begin = newParams.createTime[0];
|
||||||
|
newParams.createTime_end = newParams.createTime[1];
|
||||||
|
delete newParams.createTime;
|
||||||
|
}
|
||||||
|
newParams.type = 2;
|
||||||
|
return statisticsTable(newParams);
|
||||||
|
};
|
||||||
|
// dataCallback 是对于返回的表格数据做处理,如果你后台返回的数据不是 list && total && pageNum && pageSize 这些字段,那么你可以在这里进行处理成这些字段
|
||||||
|
// 或者直接去 hooks/useTable.ts 文件中把字段改为你后端对应的就行
|
||||||
|
const dataCallback = (data: any) => {
|
||||||
|
// console.log(data);
|
||||||
|
return {
|
||||||
|
list: data.records,
|
||||||
|
total: Number(data.total),
|
||||||
|
pageNo: Number(data.current),
|
||||||
|
pageSize: Number(data.size)
|
||||||
|
};
|
||||||
|
};
|
||||||
|
onMounted(() => {});
|
||||||
</script>
|
</script>
|
||||||
<style scoped lang="scss"></style>
|
<style scoped lang="scss">
|
||||||
|
@import "./index.scss";
|
||||||
|
</style>
|
||||||
|
|||||||
@ -20,6 +20,10 @@
|
|||||||
<img src="@/assets/images/tableIcon/updateIcon.png" alt="" class="configureIcon" />
|
<img src="@/assets/images/tableIcon/updateIcon.png" alt="" class="configureIcon" />
|
||||||
<span>编辑</span>
|
<span>编辑</span>
|
||||||
</el-button>
|
</el-button>
|
||||||
|
<el-button type="primary" link @click="handleItemDetail(row)">
|
||||||
|
<img src="@/assets/images/tableIcon/look.png" alt="" class="configureIcon" />
|
||||||
|
<span>查看</span>
|
||||||
|
</el-button>
|
||||||
</template>
|
</template>
|
||||||
</ProTable>
|
</ProTable>
|
||||||
<changeTheme />
|
<changeTheme />
|
||||||
@ -71,64 +75,76 @@ const formConfig = {
|
|||||||
{
|
{
|
||||||
label: "节点编码",
|
label: "节点编码",
|
||||||
prop: "nodeNumber",
|
prop: "nodeNumber",
|
||||||
type: "input"
|
type: "input",
|
||||||
|
disabled: false
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
label: "节点名称",
|
label: "节点名称",
|
||||||
prop: "nodeName",
|
prop: "nodeName",
|
||||||
type: "input"
|
type: "input",
|
||||||
|
disabled: false
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
label: "节点类型",
|
label: "节点类型",
|
||||||
prop: "type",
|
prop: "type",
|
||||||
type: "input"
|
type: "input",
|
||||||
|
disabled: false
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
label: "标准完成时间",
|
label: "标准完成时间",
|
||||||
prop: "standardCompleteTime",
|
prop: "standardCompleteTime",
|
||||||
type: "date"
|
type: "date",
|
||||||
|
disabled: false
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
label: "计划完成时间",
|
label: "计划完成时间",
|
||||||
prop: "planCompleteTime",
|
prop: "planCompleteTime",
|
||||||
type: "date"
|
type: "date",
|
||||||
|
disabled: false
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
label: "预计完成时间",
|
label: "预计完成时间",
|
||||||
prop: "expectCompleteTime",
|
prop: "expectCompleteTime",
|
||||||
type: "date"
|
type: "date",
|
||||||
|
disabled: false
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
label: "实际完成时间",
|
label: "实际完成时间",
|
||||||
prop: "realCompleteTime",
|
prop: "realCompleteTime",
|
||||||
type: "date"
|
type: "date",
|
||||||
|
disabled: false
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
label: "状态",
|
label: "状态",
|
||||||
prop: "state",
|
prop: "state",
|
||||||
type: "select",
|
type: "select",
|
||||||
data: [],
|
data: [],
|
||||||
clearable: true
|
clearable: true,
|
||||||
|
disabled: false
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
label: "实际偏差",
|
label: "实际偏差",
|
||||||
prop: "actualDeviation",
|
prop: "actualDeviation",
|
||||||
type: "input"
|
type: "input",
|
||||||
|
disabled: false
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
label: "职能线条",
|
label: "职能线条",
|
||||||
prop: "phaseName",
|
prop: "phaseName",
|
||||||
type: "input"
|
type: "input",
|
||||||
|
disabled: false
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
label: "节点负责人编号",
|
label: "节点负责人编号",
|
||||||
prop: "chargerNumber",
|
prop: "chargerNumber",
|
||||||
type: "input"
|
type: "input",
|
||||||
|
disabled: false
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
label: "节点负责人",
|
label: "节点负责人",
|
||||||
prop: "chargerName",
|
prop: "chargerName",
|
||||||
type: "input"
|
type: "input",
|
||||||
|
disabled: false
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
rules: {
|
rules: {
|
||||||
@ -295,7 +311,7 @@ const columns: ColumnProps[] = [
|
|||||||
return scoped.row.isSendBack == 1 ? "是" : "否";
|
return scoped.row.isSendBack == 1 ? "是" : "否";
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{ prop: "operation", label: "操作", fixed: "right" }
|
{ prop: "operation", label: "操作", width: 200, fixed: "right" }
|
||||||
];
|
];
|
||||||
const getDicMainList = async () => {
|
const getDicMainList = async () => {
|
||||||
// 获取学历字典
|
// 获取学历字典
|
||||||
@ -316,12 +332,12 @@ const getDicMainList = async () => {
|
|||||||
};
|
};
|
||||||
// 新增,编辑数据
|
// 新增,编辑数据
|
||||||
const saveItem = async (form: any) => {
|
const saveItem = async (form: any) => {
|
||||||
if (form.id) {
|
if (form.id && newTitle.value != "查看") {
|
||||||
// console.log(form.dictCode);
|
// console.log(form.dictCode);
|
||||||
const res = await globalPlanEdit(form);
|
const res = await globalPlanEdit(form);
|
||||||
proTable.value.getTableList();
|
proTable.value.getTableList();
|
||||||
ElMessage.success("编辑成功");
|
ElMessage.success("编辑成功");
|
||||||
} else {
|
} else if (newTitle.value != "查看" && !form.id) {
|
||||||
const res = await globalPlanAdd(form);
|
const res = await globalPlanAdd(form);
|
||||||
ElMessage.success("新增成功");
|
ElMessage.success("新增成功");
|
||||||
proTable.value.getTableList();
|
proTable.value.getTableList();
|
||||||
@ -408,6 +424,9 @@ const handleAddItem = () => {
|
|||||||
});
|
});
|
||||||
newTitle.value = "新增";
|
newTitle.value = "新增";
|
||||||
// fileList.value = reactive([]);
|
// fileList.value = reactive([]);
|
||||||
|
formConfig.formItemConfig.map(item => {
|
||||||
|
item.disabled = false;
|
||||||
|
});
|
||||||
visible.value = true;
|
visible.value = true;
|
||||||
};
|
};
|
||||||
|
|
||||||
@ -416,6 +435,19 @@ const handleEditItem = async (row: any) => {
|
|||||||
console.log(row);
|
console.log(row);
|
||||||
formData.value = reactive({ ...row });
|
formData.value = reactive({ ...row });
|
||||||
newTitle.value = "编辑";
|
newTitle.value = "编辑";
|
||||||
|
formConfig.formItemConfig.map(item => {
|
||||||
|
item.disabled = false;
|
||||||
|
});
|
||||||
|
visible.value = true;
|
||||||
|
};
|
||||||
|
// 查看数据按钮
|
||||||
|
const handleItemDetail = async (row: any) => {
|
||||||
|
console.log(row);
|
||||||
|
formData.value = reactive({ ...row });
|
||||||
|
formConfig.formItemConfig.map(item => {
|
||||||
|
item.disabled = true;
|
||||||
|
});
|
||||||
|
newTitle.value = "查看";
|
||||||
visible.value = true;
|
visible.value = true;
|
||||||
};
|
};
|
||||||
onMounted(() => {
|
onMounted(() => {
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user