fix: BUG修改

This commit is contained in:
kun 2023-08-11 18:41:21 +08:00
parent e3d4cfd1a1
commit f1d788a3a3
5 changed files with 272 additions and 148 deletions

View File

@ -125,6 +125,10 @@ export const payGovermentList = (params: any) => {
export const payGovermentContactAdd = (params: any) => {
return http.post(BASEURL + `/gov/investmentContract/add`, params);
};
// 投资支付合同设置结算定额日期
export const payGovermentContactSet = (params: any) => {
return http.post(BASEURL + `/gov/engineering/edit`, params);
};
// 投资支付列表
export const payGovermentAllList = (params: any) => {
return http.post(BASEURL + `/gov/investmentPayment/page`, params);
@ -180,6 +184,10 @@ export const globalPlanGovermentAdd = (params: any) => {
export const globalPlanGovermentEdit = (params: any) => {
return http.post(BASEURL + `/gov/projectNodePlan/edit`, params);
};
// 全景计划审批
export const globalPlanGovermentAudit = (params: any) => {
return http.post(BASEURL + `/gov/projectNodePlan/examine`, params);
};
// 全景计划(政务端)------------
// 全景计划分页列表

View File

@ -149,7 +149,7 @@
</el-form-item>
</template>
</el-form>
<template #footer>
<template #footer v-if="props.title != '查看'">
<el-button class="hzCancelStyle" @click="visible1 = false">取消</el-button>
<el-button class="btnStyle" type="primary" @click="confirm(ruleFormRef)"> 保存 </el-button>
</template>

View File

@ -36,8 +36,11 @@
background
:isShowSearch="false"
>
<template #formButton="scope" v-auth="'investment_contract_add'">
<el-button class="btnStyle" @click="handleAddItem()">新增</el-button>
<template #formButton="scope">
<el-button class="btnStyle" v-auth="'investment_contract_add'" @click="handleAddItem()">新增</el-button>
<el-button class="btnStyle" v-auth="'investment_contract_setting'" @click="handleSetDate()"
>设置结算定额日期</el-button
>
</template>
<!-- 表格操作 -->
<template #operation="{ row }">
@ -46,6 +49,7 @@
</el-button>
</template>
</ProTable>
<!-- 新增 -->
<DialogForm
:title="title"
:formConfig="formConfig"
@ -56,6 +60,17 @@
@confirm="saveItem"
>
</DialogForm>
<!-- 设置结算定额日期 -->
<DialogForm
:title="dateTitle"
:formConfig="dateFormConfig"
:formData="dateFormData"
v-model:visible="dateVisible"
append-to-body
width="40%"
@confirm="saveDateItem"
>
</DialogForm>
</div>
<!-- 投资支付详情 -->
<transformInfo1
@ -78,7 +93,13 @@ import LeftMenu from "@/components/LeftMenu/LeftMenu.vue";
import ProTable from "@/components/ProTable/index.vue";
import DialogForm from "@/components/DialogForm/index.vue";
import { ColumnProps } from "@/components/ProTable/interface";
import { payGovermentEngList, payGovermentProList, payGovermentList, payGovermentContactAdd } from "@/api/modules/huizhou";
import {
payGovermentEngList,
payGovermentProList,
payGovermentList,
payGovermentContactAdd,
payGovermentContactSet
} from "@/api/modules/huizhou";
import { sendIframeMessage } from "@/utils/util";
const route = useRoute();
const detailsDialog = ref(false);
@ -146,13 +167,13 @@ const formConfig = {
prop: "settlementAmount",
type: "input"
},
{
label: "结算定额日期",
prop: "settlementTime",
type: "date",
format: "YYYY-MM-DD",
valueFormat: "YYYY-MM-DD"
},
// {
// label: "",
// prop: "settlementTime",
// type: "date",
// format: "YYYY-MM-DD",
// valueFormat: "YYYY-MM-DD"
// },
{
label: "申请单位",
prop: "applicationUnit",
@ -225,21 +246,55 @@ const formConfig = {
]
}
};
//
const dateFormConfig = {
formItemConfig: [
{
label: "结算定额日期",
prop: "settlementTime",
type: "date",
format: "YYYY-MM-DD",
valueFormat: "YYYY-MM-DD"
}
],
rules: {
settlementTime: [
{
required: true,
message: "请选择",
trigger: "change"
}
]
}
};
const formData = ref({
type: "",
contractAmount: "",
settlementAmount: "",
settlementTime: "",
applicationUnit: "",
bidderTime: "",
contractTime: ""
});
const dateFormData = ref({
settlementTime: ""
});
const dateVisible = ref(false);
const visible = ref(false);
const title = ref("新增录像");
const title = ref("");
const dateTitle = ref("设置");
// ProTable 便
const proTable = ref();
// snsn
const searchSn = ref("");
const searchId = ref("");
const handleSetDate = () => {
dateFormData.value = reactive({
settlementTime: ""
});
dateVisible.value = true;
dateTitle.value = "设置";
// formData.value = reactive({});
};
const handleItemDetail = (index: number, row: any) => {
console.log(row);
// if (index === 1) {
@ -279,6 +334,19 @@ const saveItem = async (form: any) => {
proTable.value.getTableList();
visible.value = false;
};
//
const saveDateItem = async (form: any) => {
if (active.value === 0) {
form.projectSn = searchSn.value;
} else {
form.engineeringSn = searchSn.value;
}
form.id = searchId.value;
const res = await payGovermentContactSet(form);
ElMessage.success("设置成功");
proTable.value.getTableList();
dateVisible.value = false;
};
//
const searchName = ref<string>("");
// dataCallback list && total && pageNum && pageSize
@ -317,9 +385,11 @@ const onSearch = async (params: any) => {
if (active.value === 0) {
searchSn.value = params.projectSn;
searchName.value = params.projectName;
searchId.value = params.id;
} else {
searchSn.value = params.engineeringSn;
searchName.value = params.engineeringName;
searchId.value = params.id;
}
proTable.value.getTableList();
};
@ -389,6 +459,7 @@ onMounted(async () => {
await getEngPage();
searchSn.value = records.value[0].projectSn;
searchName.value = records.value[0].projectName;
searchId.value = records.value[0].id;
onSearch(records.value[0]);
await sendIframeMessage({ obj: { path: route.path } }, 2, undefined);
});

View File

@ -52,6 +52,27 @@
<img src="@/assets/images/tableIcon/look.png" alt="" class="configureIcon" />
<span>查看</span>
</el-button>
<el-button v-if="row.fillState == 1" type="primary" link @click="auditData(row)" v-auth="'node_plan_examine'">
<img src="@/assets/images/tableIcon/look.png" alt="" class="configureIcon" />
<span>审批</span>
</el-button>
<el-button type="primary" v-if="row.fillState == 2" link @click="againApply(row)" v-auth="'node_plan_resave'">
<img src="@/assets/images/tableIcon/look.png" alt="" class="configureIcon" />
<span>重新填报</span>
</el-button>
</template>
<template #fillState="{ row }">
<span>{{
row.fillState == 1
? "已填报"
: row.fillState == 2
? "已审核"
: row.fillState == 3
? "已驳回"
: row.fillState == 4
? "重新填报"
: ""
}}</span>
</template>
</ProTable>
<DialogForm
@ -66,6 +87,20 @@
</DialogForm>
</div>
</div>
<!-- 审核 -->
<el-dialog title="审批" width="26%" v-model="aproveVisible" show-close>
<div style="display: flex; align-items: center">
<el-icon style="color: var(--el-menu-text-color); margin: 0 12px; font-size: 20px"><WarningFilled /></el-icon>
<span>是否通过审批?</span>
</div>
<template #footer>
<span class="dialog-footer">
<el-button class="hzCancelStyle" @click="reject">驳回</el-button>
<el-button type="primary" @click="onSubmit">通过</el-button>
</span>
</template>
</el-dialog>
</div>
</template>
@ -82,11 +117,15 @@ import {
globalPlanProList,
globalPlanEngList,
globalPlanGovermentAdd,
globalPlanGovermentEdit
globalPlanGovermentEdit,
globalPlanGovermentAudit
} from "@/api/modules/huizhou";
import { getDicList } from "@/api/modules/jxjview";
import { ElMessage } from "element-plus";
import { useRoute } from "vue-router";
import { useHandleData } from "@/hooks/useHandleData";
const rowId = ref("");
const aproveVisible = ref(false);
const route = useRoute();
const pages = ref({
pageNo: 1,
@ -101,30 +140,15 @@ const store = GlobalStore();
const columns: ColumnProps[] = [
{ type: "index", label: "序号", width: 80 },
{
prop: "nodeNumber",
label: "节点编号",
width: 150
prop: "subItemName",
label: "分部分项工程名称",
width: 200
},
// prop
{ prop: "nodeName", label: "节点名称", width: 150, search: { el: "input" } },
{ prop: "type", label: "节点类型", width: 150 },
{ prop: "childName", label: "子分项名称", width: 150, search: { el: "input" } },
{ prop: "standardCompleteTime", label: "标准完成时间", width: 150 },
{ prop: "planCompleteTime", label: "计划完成时间", width: 150 },
{ prop: "expectCompleteTime", label: "预计完成时间", width: 150 },
{
prop: "state",
label: "状态",
width: 150,
isShow: false,
search: { el: "select" },
enum: DicMainList.value,
fieldNames: { label: "dictValue", value: "dictLabel" }
},
{
prop: "status",
label: "状态",
width: 150
},
{
prop: "realCompleteTime",
label: "实际完成时间",
@ -136,25 +160,61 @@ const columns: ColumnProps[] = [
// defaultValue: "2023-05"
}
},
{ prop: "phaseName", label: "智能条线", width: 150 },
{ prop: "chargerName", label: "节点责任人", width: 150 },
{
prop: "isDeleted",
label: "节点失效标记",
width: 150,
render: scoped => {
return scoped.row.isDeleted == 0 ? "有效" : "失效";
}
prop: "commander",
label: "负责人",
width: 150
},
{
prop: "isSendBack",
label: "是否退回",
width: 150,
render: scoped => {
return scoped.row.isSendBack == 1 ? "是" : "否";
}
prop: "completeRatio",
label: "完成比率",
width: 150
},
{ prop: "operation", label: "操作", width: 160, fixed: "right" }
{
prop: "state",
label: "状态",
width: 150,
isShow: false,
search: { el: "select" },
// enum: DicMainList.value,
enum: [
{ label: "未开始", value: 1 },
{ label: "推进中", value: 2 },
{ label: "按期完成", value: 3 },
{ label: "临期", value: 4 },
{ label: "超期", value: 5 },
{ label: "逾期完成", value: 6 },
{ label: "暂停", value: 7 }
]
// fieldNames: { label: "dictValue", value: "dictLabel" }
},
{
prop: "state",
label: "状态",
width: 150
},
{
prop: "fillState",
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: 340, fixed: "right" }
];
const formData = ref({
nodeNumber: "",
@ -180,20 +240,14 @@ const proTable = ref();
const formConfig = {
formItemConfig: [
{
label: "节点编码",
prop: "nodeNumber",
label: "分部分项工程名称",
prop: "subItemName",
type: "input",
disabled: true
},
{
label: "节点名称",
prop: "nodeName",
type: "input",
disabled: true
},
{
label: "节点类型",
prop: "type",
label: "子分项名称",
prop: "childName",
type: "input",
disabled: true
},
@ -229,31 +283,33 @@ const formConfig = {
valueFormat: "YYYY-MM-DD",
disabled: true
},
{
label: "负责人",
prop: "commander",
type: "input",
disabled: true
},
{
label: "完成比率",
prop: "completeRatio",
type: "input",
disabled: true
},
{
label: "状态",
prop: "state",
type: "select",
data: [],
data: [
{ label: "未开始", value: 1 },
{ label: "推进中", value: 2 },
{ label: "按期完成", value: 3 },
{ label: "临期", value: 4 },
{ label: "超期", value: 5 },
{ label: "逾期完成", value: 6 },
{ label: "暂停", value: 7 }
],
clearable: true,
disabled: true
},
{
label: "实际偏差",
prop: "actualDeviation",
type: "input",
disabled: true
},
{
label: "职能线条",
prop: "phaseName",
type: "input",
disabled: true
},
{
label: "节点负责人",
prop: "chargerName",
type: "input",
disabled: true
}
// {
// label: "",
@ -263,21 +319,7 @@ const formConfig = {
// }
],
rules: {
nodeNumber: [
{
required: true,
message: "请输入",
trigger: "blur"
}
],
nodeName: [
{
required: true,
message: "请输入",
trigger: "blur"
}
],
type: [
subItemName: [
{
required: true,
message: "请输入",
@ -291,35 +333,7 @@ const formConfig = {
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: [
commander: [
{
required: true,
message: "请输入",
@ -330,6 +344,28 @@ const formConfig = {
};
//
const searchName = ref<string>("");
//
const againApply = async (params: any) => {
await useHandleData(globalPlanGovermentAudit, { id: rowId.value, fillState: 4 }, `是否重新填报`);
proTable.value.getTableList();
};
//
const auditData = async (row: any) => {
rowId.value = row.id;
aproveVisible.value = true;
};
const reject = async () => {
await globalPlanGovermentAudit({ id: rowId.value, fillState: 3 });
ElMessage.success("已驳回");
aproveVisible.value = false;
proTable.value.getTableList();
};
const onSubmit = async () => {
await globalPlanGovermentAudit({ id: rowId.value, fillState: 2 });
ElMessage.success("通过成功");
aproveVisible.value = false;
proTable.value.getTableList();
};
//
const handleEditItem = async (row: any) => {
console.log(row);

View File

@ -73,48 +73,56 @@ const columns: ColumnProps[] = [
{ type: "index", label: "序号", width: 80 },
{
prop: "engineeringName",
label: "工程名称",
search: { el: "input" }
label: "工程名称"
// search: { el: "input" }
},
{
prop: "engineeringCode",
label: "工程编号",
search: { el: "input" }
label: "工程编号"
// search: { el: "input" }
},
// prop
{
prop: "district",
label: "所在区域",
enum: engineeringArea?.value,
search: { el: "select", props: { filterable: true } }
},
// {
// prop: "district",
// label: ""
// enum: engineeringArea?.value,
// search: { el: "select", props: { filterable: true } }
// },
{
prop: "engineeringType",
label: "工程类型",
enum: DicTypeList.value,
search: { el: "select", props: { filterable: true } },
// search: { el: "select", props: { filterable: true } },
fieldNames: { label: "dictValue", value: "dictLabel" }
},
{
prop: "engineeringCode",
label: "负责人"
},
{
prop: "engineeringCode",
label: "手机号"
},
{
prop: "state",
label: "工程状态",
label: "审批状态",
enum: DicStatusList.value,
search: { el: "select", props: { filterable: true } },
// search: { el: "select", props: { filterable: true } },
fieldNames: { label: "dictValue", value: "dictLabel" }
},
{
prop: "createTime",
label: "提交时间",
search: {
el: "date-picker",
props: {
type: "daterange",
format: "YYYY-MM-DD",
valueFormat: "YYYY-MM-DD"
// defaultTime: defaultTime2
}
}
},
// {
// prop: "createTime",
// label: ""
// search: {
// el: "date-picker",
// props: {
// type: "daterange",
// format: "YYYY-MM-DD",
// valueFormat: "YYYY-MM-DD"
// // defaultTime: defaultTime2
// }
// }
// },
{ prop: "operation", label: "操作", fixed: "right", width: 150 }
];
const relativeId = ref("");
@ -169,7 +177,8 @@ const getTableList = (params: any) => {
delete newParams.createTime;
}
newParams.type = 2;
return getEngineeringApproveList(newParams);
// return getEngineeringApproveList(newParams);
return { result: { records: [], current: "1", pages: "1", size: "10", total: "0" } };
};
// dataCallback list && total && pageNum && pageSize
// hooks/useTable.ts