feat: 项目管理、项目前期管理添加二级类别选项以及修改了页面必填项
This commit is contained in:
parent
9c87149040
commit
d4e55efd0e
@ -2,11 +2,11 @@
|
|||||||
NODE_ENV = 'development'
|
NODE_ENV = 'development'
|
||||||
|
|
||||||
# 本地环境接口地址(/api/index.ts文件中使用)
|
# 本地环境接口地址(/api/index.ts文件中使用)
|
||||||
# VITE_API_URL = 'http://192.168.34.155:6688'
|
VITE_API_URL = 'http://192.168.34.155:6688'
|
||||||
# VITE_API_URL = 'http://183.63.230.59:6090'
|
# VITE_API_URL = 'http://183.63.230.59:6090'
|
||||||
# VITE_API_URL = 'http://2xliv7gs.shenzhuo.vip:55296'
|
# VITE_API_URL = 'http://2xliv7gs.shenzhuo.vip:55296'
|
||||||
VITE_WPAPI_URL = "http://jxjzw.zhgdyun.com:8081"
|
VITE_WPAPI_URL = "http://jxjzw.zhgdyun.com:8081"
|
||||||
VITE_API_URL = "http://jxjzw.zhgdyun.com:9013"
|
# VITE_API_URL = "http://jxjzw.zhgdyun.com:9013"
|
||||||
# VITE_API_URL = 'https://xmglcs.hyjgxt.cn:6090'
|
# VITE_API_URL = 'https://xmglcs.hyjgxt.cn:6090'
|
||||||
|
|
||||||
# 上传
|
# 上传
|
||||||
|
|||||||
@ -39,18 +39,18 @@
|
|||||||
<div>里程(km)</div>
|
<div>里程(km)</div>
|
||||||
</div>
|
</div>
|
||||||
</div> -->
|
</div> -->
|
||||||
<div class="topsixin" @click="toProjectList(2)">
|
|
||||||
<div class="bg4"></div>
|
|
||||||
<div class="titles">
|
|
||||||
<div>{{ projectInfo.bridge }}</div>
|
|
||||||
<div>桥梁工程</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<div class="topsixin" @click="toProjectList(3)">
|
<div class="topsixin" @click="toProjectList(3)">
|
||||||
<div class="bg5"></div>
|
<div class="bg5"></div>
|
||||||
<div class="titles">
|
<div class="titles">
|
||||||
<div>{{ projectInfo.tunnel }}</div>
|
<div>{{ projectInfo.tunnel }}</div>
|
||||||
<div>隧道工程</div>
|
<div>市政工程</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="topsixin" @click="toProjectList(2)">
|
||||||
|
<div class="bg4"></div>
|
||||||
|
<div class="titles">
|
||||||
|
<div>{{ projectInfo.bridge }}</div>
|
||||||
|
<div>信息化工程</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="topsixin" @click="toProjectList(4)">
|
<div class="topsixin" @click="toProjectList(4)">
|
||||||
|
|||||||
@ -108,6 +108,9 @@ const submit = async () => {
|
|||||||
...addRepostData.value,
|
...addRepostData.value,
|
||||||
isDraft: 0 // 0代表直接提交
|
isDraft: 0 // 0代表直接提交
|
||||||
};
|
};
|
||||||
|
if (Array.isArray(requestData.projectSecondType)) {
|
||||||
|
requestData.projectSecondType = requestData.projectSecondType.join(",");
|
||||||
|
}
|
||||||
if (!store.Message) {
|
if (!store.Message) {
|
||||||
const data = await addPreEngineering(requestData);
|
const data = await addPreEngineering(requestData);
|
||||||
ElMessage.success(data.message);
|
ElMessage.success(data.message);
|
||||||
|
|||||||
@ -18,6 +18,7 @@ export enum Important {
|
|||||||
const data = {
|
const data = {
|
||||||
engineeringName: "",
|
engineeringName: "",
|
||||||
engineeringType: "",
|
engineeringType: "",
|
||||||
|
projectSecondType: [],
|
||||||
engineeringUse: Type["One"],
|
engineeringUse: Type["One"],
|
||||||
engineeringCost: "",
|
engineeringCost: "",
|
||||||
engineeringArea: "",
|
engineeringArea: "",
|
||||||
@ -40,7 +41,8 @@ const data = {
|
|||||||
{ dictValue: "项目建议书", files: [] },
|
{ dictValue: "项目建议书", files: [] },
|
||||||
{ dictValue: "各单位回复", files: [] },
|
{ dictValue: "各单位回复", files: [] },
|
||||||
{ dictValue: "政投会PPT(定稿)", files: [] },
|
{ dictValue: "政投会PPT(定稿)", files: [] },
|
||||||
{ dictValue: "政投会会议纪要", files: [] }
|
{ dictValue: "政投会会议纪要", files: [] },
|
||||||
|
{ dictValue: "其他文件", files: [] }
|
||||||
]
|
]
|
||||||
};
|
};
|
||||||
|
|
||||||
@ -52,6 +54,7 @@ export const reset = () => {
|
|||||||
form.value = {
|
form.value = {
|
||||||
engineeringName: "",
|
engineeringName: "",
|
||||||
engineeringType: "",
|
engineeringType: "",
|
||||||
|
projectSecondType: [],
|
||||||
engineeringUse: Type["One"],
|
engineeringUse: Type["One"],
|
||||||
engineeringCost: "",
|
engineeringCost: "",
|
||||||
engineeringArea: "",
|
engineeringArea: "",
|
||||||
@ -74,7 +77,8 @@ export const reset = () => {
|
|||||||
{ dictValue: "项目建议书", files: [] },
|
{ dictValue: "项目建议书", files: [] },
|
||||||
{ dictValue: "各单位回复", files: [] },
|
{ dictValue: "各单位回复", files: [] },
|
||||||
{ dictValue: "政投会PPT(定稿)", files: [] },
|
{ dictValue: "政投会PPT(定稿)", files: [] },
|
||||||
{ dictValue: "政投会会议纪要", files: [] }
|
{ dictValue: "政投会会议纪要", files: [] },
|
||||||
|
{ dictValue: "其他文件", files: [] }
|
||||||
]
|
]
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
@ -89,6 +93,10 @@ export const rules = ref<FormRules>({
|
|||||||
// required: true,
|
// required: true,
|
||||||
// message: "请输入项目类别"
|
// message: "请输入项目类别"
|
||||||
// },
|
// },
|
||||||
|
// projectSecondType: {
|
||||||
|
// required: true,
|
||||||
|
// message: "请输入项目类别"
|
||||||
|
// },
|
||||||
// engineeringUse: {
|
// engineeringUse: {
|
||||||
// type: "number",
|
// type: "number",
|
||||||
// required: true,
|
// required: true,
|
||||||
|
|||||||
@ -22,6 +22,21 @@
|
|||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</div>
|
</div>
|
||||||
|
<div class="row">
|
||||||
|
<el-form-item label="项目二级类别:" prop="projectSecondType">
|
||||||
|
<el-select class="select" multiple placeholder="请选择" v-model="form.projectSecondType">
|
||||||
|
<el-option
|
||||||
|
v-for="item in engineeringTypeSecondOptions"
|
||||||
|
:key="item.dictCode"
|
||||||
|
:label="item.dictValue"
|
||||||
|
:value="item.dictLabel"
|
||||||
|
/>
|
||||||
|
</el-select>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="建设地址:" prop="address">
|
||||||
|
<el-input placeholder="请输入" v-model="form.address" />
|
||||||
|
</el-form-item>
|
||||||
|
</div>
|
||||||
<div class="row">
|
<div class="row">
|
||||||
<el-form-item label="项目总投资:" prop="engineeringCost">
|
<el-form-item label="项目总投资:" prop="engineeringCost">
|
||||||
<el-input placeholder="请输入" v-model="form.engineeringCost" />
|
<el-input placeholder="请输入" v-model="form.engineeringCost" />
|
||||||
@ -69,9 +84,6 @@
|
|||||||
<el-form-item label="所属管辖区域:">
|
<el-form-item label="所属管辖区域:">
|
||||||
<area-selected v-model="addressList" @get-address="handleGetAdress"></area-selected>
|
<area-selected v-model="addressList" @get-address="handleGetAdress"></area-selected>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="建设地址:" prop="address">
|
|
||||||
<el-input placeholder="请输入" v-model="form.address" />
|
|
||||||
</el-form-item>
|
|
||||||
<div class="row">
|
<div class="row">
|
||||||
<el-form-item label="开始时间:" prop="oneStartTime">
|
<el-form-item label="开始时间:" prop="oneStartTime">
|
||||||
<el-date-picker
|
<el-date-picker
|
||||||
@ -181,6 +193,7 @@ const oneStartTimeRef = ref<ElDatePickerType>(),
|
|||||||
oneEndTimeRef = ref<ElDatePickerType>();
|
oneEndTimeRef = ref<ElDatePickerType>();
|
||||||
|
|
||||||
const engineeringTypeOptions = ref<any>([]),
|
const engineeringTypeOptions = ref<any>([]),
|
||||||
|
engineeringTypeSecondOptions = ref<any>([]),
|
||||||
engineeringUseOptions = ref<DictDataList>([]);
|
engineeringUseOptions = ref<DictDataList>([]);
|
||||||
|
|
||||||
const engineeringPurpose = ref<any>([]);
|
const engineeringPurpose = ref<any>([]);
|
||||||
@ -302,6 +315,7 @@ onMounted(async () => {
|
|||||||
item.files = files;
|
item.files = files;
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
form.value.projectSecondType = store.Message.projectSecondType.split(",").map((item: string) => Number(item));
|
||||||
}
|
}
|
||||||
// if (store.Message) {
|
// if (store.Message) {
|
||||||
// form.value = store.Message;
|
// form.value = store.Message;
|
||||||
@ -320,6 +334,13 @@ onUnmounted(() => {
|
|||||||
ruleFormRef.value?.clearValidate();
|
ruleFormRef.value?.clearValidate();
|
||||||
reset();
|
reset();
|
||||||
});
|
});
|
||||||
|
watch(
|
||||||
|
() => form.value.engineeringType,
|
||||||
|
async newVal => {
|
||||||
|
const res = await getDicList({ dictType: "engineering_type_" + newVal });
|
||||||
|
engineeringTypeSecondOptions.value = res.result;
|
||||||
|
}
|
||||||
|
);
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style lang="scss" scoped>
|
<style lang="scss" scoped>
|
||||||
|
|||||||
@ -31,7 +31,8 @@ const data = {
|
|||||||
twoReportedBy: "",
|
twoReportedBy: "",
|
||||||
engineeringSingles: [
|
engineeringSingles: [
|
||||||
{ dictValue: "可行性研究报告", files: [] },
|
{ dictValue: "可行性研究报告", files: [] },
|
||||||
{ dictValue: "立项批复", files: [] }
|
{ dictValue: "立项批复", files: [] },
|
||||||
|
{ dictValue: "其他文件", files: [] }
|
||||||
]
|
]
|
||||||
};
|
};
|
||||||
|
|
||||||
@ -56,7 +57,8 @@ export const reset = () => {
|
|||||||
twoReportedBy: "",
|
twoReportedBy: "",
|
||||||
engineeringSingles: [
|
engineeringSingles: [
|
||||||
{ dictValue: "可行性研究报告", files: [] },
|
{ dictValue: "可行性研究报告", files: [] },
|
||||||
{ dictValue: "立项批复", files: [] }
|
{ dictValue: "立项批复", files: [] },
|
||||||
|
{ dictValue: "其他文件", files: [] }
|
||||||
]
|
]
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|||||||
@ -36,7 +36,8 @@ const data = {
|
|||||||
engineeringSingles: [
|
engineeringSingles: [
|
||||||
{ dictValue: "用地预审回函", files: [] },
|
{ dictValue: "用地预审回函", files: [] },
|
||||||
{ dictValue: "用地规划回函", files: [] },
|
{ dictValue: "用地规划回函", files: [] },
|
||||||
{ dictValue: "征地拆迁回函", files: [] }
|
{ dictValue: "征地拆迁回函", files: [] },
|
||||||
|
{ dictValue: "其他文件", files: [] }
|
||||||
]
|
]
|
||||||
};
|
};
|
||||||
|
|
||||||
@ -66,7 +67,8 @@ export const reset = () => {
|
|||||||
engineeringSingles: [
|
engineeringSingles: [
|
||||||
{ dictValue: "用地预审回函", files: [] },
|
{ dictValue: "用地预审回函", files: [] },
|
||||||
{ dictValue: "用地规划回函", files: [] },
|
{ dictValue: "用地规划回函", files: [] },
|
||||||
{ dictValue: "征地拆迁回函", files: [] }
|
{ dictValue: "征地拆迁回函", files: [] },
|
||||||
|
{ dictValue: "其他文件", files: [] }
|
||||||
]
|
]
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|||||||
@ -25,7 +25,8 @@ const data = {
|
|||||||
engineeringSingles: [
|
engineeringSingles: [
|
||||||
{ dictValue: "汇报文档", files: [] },
|
{ dictValue: "汇报文档", files: [] },
|
||||||
{ dictValue: "方案阶段图纸", files: [] },
|
{ dictValue: "方案阶段图纸", files: [] },
|
||||||
{ dictValue: "会议签到及意见汇总", files: [] }
|
{ dictValue: "会议签到及意见汇总", files: [] },
|
||||||
|
{ dictValue: "其他文件", files: [] }
|
||||||
]
|
]
|
||||||
};
|
};
|
||||||
|
|
||||||
@ -44,7 +45,8 @@ export const reset = () => {
|
|||||||
engineeringSingles: [
|
engineeringSingles: [
|
||||||
{ dictValue: "汇报文档", files: [] },
|
{ dictValue: "汇报文档", files: [] },
|
||||||
{ dictValue: "方案阶段图纸", files: [] },
|
{ dictValue: "方案阶段图纸", files: [] },
|
||||||
{ dictValue: "会议签到及意见汇总", files: [] }
|
{ dictValue: "会议签到及意见汇总", files: [] },
|
||||||
|
{ dictValue: "其他文件", files: [] }
|
||||||
]
|
]
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|||||||
@ -30,7 +30,8 @@ const data = {
|
|||||||
{ dictValue: "初步设计图纸", files: [] },
|
{ dictValue: "初步设计图纸", files: [] },
|
||||||
{ dictValue: "概算文件", files: [] },
|
{ dictValue: "概算文件", files: [] },
|
||||||
{ dictValue: "初步设计及概算批复文件", files: [] },
|
{ dictValue: "初步设计及概算批复文件", files: [] },
|
||||||
{ dictValue: "会议签到及意见汇总", files: [] }
|
{ dictValue: "会议签到及意见汇总", files: [] },
|
||||||
|
{ dictValue: "其他文件", files: [] }
|
||||||
]
|
]
|
||||||
};
|
};
|
||||||
|
|
||||||
@ -54,7 +55,8 @@ export const reset = () => {
|
|||||||
{ dictValue: "初步设计图纸", files: [] },
|
{ dictValue: "初步设计图纸", files: [] },
|
||||||
{ dictValue: "概算文件", files: [] },
|
{ dictValue: "概算文件", files: [] },
|
||||||
{ dictValue: "初步设计及概算批复文件", files: [] },
|
{ dictValue: "初步设计及概算批复文件", files: [] },
|
||||||
{ dictValue: "会议签到及意见汇总", files: [] }
|
{ dictValue: "会议签到及意见汇总", files: [] },
|
||||||
|
{ dictValue: "其他文件", files: [] }
|
||||||
]
|
]
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|||||||
@ -29,7 +29,8 @@ const data = {
|
|||||||
{ dictValue: "勘察文件", files: [] },
|
{ dictValue: "勘察文件", files: [] },
|
||||||
{ dictValue: "施工图", files: [] },
|
{ dictValue: "施工图", files: [] },
|
||||||
{ dictValue: "审图报告", files: [] },
|
{ dictValue: "审图报告", files: [] },
|
||||||
{ dictValue: "施工图批复", files: [] }
|
{ dictValue: "施工图批复", files: [] },
|
||||||
|
{ dictValue: "其他文件", files: [] }
|
||||||
]
|
]
|
||||||
};
|
};
|
||||||
|
|
||||||
@ -52,7 +53,8 @@ export const reset = () => {
|
|||||||
{ dictValue: "勘察文件", files: [] },
|
{ dictValue: "勘察文件", files: [] },
|
||||||
{ dictValue: "施工图", files: [] },
|
{ dictValue: "施工图", files: [] },
|
||||||
{ dictValue: "审图报告", files: [] },
|
{ dictValue: "审图报告", files: [] },
|
||||||
{ dictValue: "施工图批复", files: [] }
|
{ dictValue: "施工图批复", files: [] },
|
||||||
|
{ dictValue: "其他文件", files: [] }
|
||||||
]
|
]
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|||||||
@ -27,7 +27,8 @@ const data = {
|
|||||||
engineeringSingles: [
|
engineeringSingles: [
|
||||||
{ dictValue: "预算文件", files: [] },
|
{ dictValue: "预算文件", files: [] },
|
||||||
{ dictValue: "预算审核文件", files: [] },
|
{ dictValue: "预算审核文件", files: [] },
|
||||||
{ dictValue: "预算定案书", files: [] }
|
{ dictValue: "预算定案书", files: [] },
|
||||||
|
{ dictValue: "其他文件", files: [] }
|
||||||
]
|
]
|
||||||
};
|
};
|
||||||
|
|
||||||
@ -48,7 +49,8 @@ export const reset = () => {
|
|||||||
engineeringSingles: [
|
engineeringSingles: [
|
||||||
{ dictValue: "预算文件", files: [] },
|
{ dictValue: "预算文件", files: [] },
|
||||||
{ dictValue: "预算审核文件", files: [] },
|
{ dictValue: "预算审核文件", files: [] },
|
||||||
{ dictValue: "预算定案书", files: [] }
|
{ dictValue: "预算定案书", files: [] },
|
||||||
|
{ dictValue: "其他文件", files: [] }
|
||||||
]
|
]
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|||||||
@ -46,7 +46,8 @@ const data = {
|
|||||||
{ dictValue: "招标文件", files: [] },
|
{ dictValue: "招标文件", files: [] },
|
||||||
{ dictValue: "投标文件", files: [] },
|
{ dictValue: "投标文件", files: [] },
|
||||||
{ dictValue: "评标文件", files: [] },
|
{ dictValue: "评标文件", files: [] },
|
||||||
{ dictValue: "中标通知书", files: [] }
|
{ dictValue: "中标通知书", files: [] },
|
||||||
|
{ dictValue: "其他文件", files: [] }
|
||||||
]
|
]
|
||||||
};
|
};
|
||||||
|
|
||||||
@ -86,7 +87,8 @@ export const reset = () => {
|
|||||||
{ dictValue: "招标文件", files: [] },
|
{ dictValue: "招标文件", files: [] },
|
||||||
{ dictValue: "投标文件", files: [] },
|
{ dictValue: "投标文件", files: [] },
|
||||||
{ dictValue: "评标文件", files: [] },
|
{ dictValue: "评标文件", files: [] },
|
||||||
{ dictValue: "中标通知书", files: [] }
|
{ dictValue: "中标通知书", files: [] },
|
||||||
|
{ dictValue: "其他文件", files: [] }
|
||||||
]
|
]
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|||||||
@ -409,7 +409,7 @@ const addFormContentFn = (index: number) => {
|
|||||||
let arr = [
|
let arr = [
|
||||||
{ dictValue: "编制文件", files: [] },
|
{ dictValue: "编制文件", files: [] },
|
||||||
{ dictValue: "批复文件", files: [] },
|
{ dictValue: "批复文件", files: [] },
|
||||||
{ dictValue: "其他文件", files: [] }
|
// { dictValue: "其他文件", files: [] }
|
||||||
];
|
];
|
||||||
form.value.engineeringSingles.push(...arr);
|
form.value.engineeringSingles.push(...arr);
|
||||||
}
|
}
|
||||||
|
|||||||
@ -323,13 +323,13 @@ const formRules = {
|
|||||||
trigger: "blur"
|
trigger: "blur"
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
settlementAmount: [
|
// settlementAmount: [
|
||||||
{
|
// {
|
||||||
required: true,
|
// required: true,
|
||||||
message: "请输入",
|
// message: "请输入",
|
||||||
trigger: "blur"
|
// trigger: "blur"
|
||||||
}
|
// }
|
||||||
],
|
// ],
|
||||||
// settlementTime: [
|
// settlementTime: [
|
||||||
// {
|
// {
|
||||||
// message: "请选择",
|
// message: "请选择",
|
||||||
@ -356,21 +356,21 @@ const formRules = {
|
|||||||
message: "请选择",
|
message: "请选择",
|
||||||
trigger: "change"
|
trigger: "change"
|
||||||
}
|
}
|
||||||
],
|
|
||||||
performanceTime: [
|
|
||||||
{
|
|
||||||
required: true,
|
|
||||||
message: "请选择",
|
|
||||||
trigger: "change"
|
|
||||||
}
|
|
||||||
],
|
|
||||||
warrantyPeriod: [
|
|
||||||
{
|
|
||||||
required: true,
|
|
||||||
message: "请输入",
|
|
||||||
trigger: "blur"
|
|
||||||
}
|
|
||||||
]
|
]
|
||||||
|
// performanceTime: [
|
||||||
|
// {
|
||||||
|
// required: true,
|
||||||
|
// message: "请选择",
|
||||||
|
// trigger: "change"
|
||||||
|
// }
|
||||||
|
// ],
|
||||||
|
// warrantyPeriod: [
|
||||||
|
// {
|
||||||
|
// required: true,
|
||||||
|
// message: "请输入",
|
||||||
|
// trigger: "blur"
|
||||||
|
// }
|
||||||
|
// ]
|
||||||
};
|
};
|
||||||
// 弹窗中的配置
|
// 弹窗中的配置
|
||||||
const formConfig = {
|
const formConfig = {
|
||||||
|
|||||||
@ -76,6 +76,9 @@ const submit = async () => {
|
|||||||
...addRepostData.value
|
...addRepostData.value
|
||||||
};
|
};
|
||||||
console.log(requestData, 888999);
|
console.log(requestData, 888999);
|
||||||
|
if (Array.isArray(requestData.projectSecondType)) {
|
||||||
|
requestData.projectSecondType = requestData.projectSecondType.join(",");
|
||||||
|
}
|
||||||
if (!store.Message || requestData.examineState == -1) {
|
if (!store.Message || requestData.examineState == -1) {
|
||||||
delete requestData.id;
|
delete requestData.id;
|
||||||
const data = await addEngineering(requestData);
|
const data = await addEngineering(requestData);
|
||||||
|
|||||||
@ -7,7 +7,7 @@
|
|||||||
// background-color: #fff;
|
// background-color: #fff;
|
||||||
flex: 1;
|
flex: 1;
|
||||||
.form {
|
.form {
|
||||||
padding: 40px 10% 0 10%;
|
padding: 0px 10% 0 10%;
|
||||||
.row {
|
.row {
|
||||||
display: flex;
|
display: flex;
|
||||||
justify-content: space-between;
|
justify-content: space-between;
|
||||||
|
|||||||
@ -21,6 +21,7 @@ const data = {
|
|||||||
engineeringName: "",
|
engineeringName: "",
|
||||||
engineeringCode: "",
|
engineeringCode: "",
|
||||||
engineeringType: "",
|
engineeringType: "",
|
||||||
|
projectSecondType: [],
|
||||||
engineeringUse: Type["One"],
|
engineeringUse: Type["One"],
|
||||||
engineeringCost: "",
|
engineeringCost: "",
|
||||||
engineeringArea: "",
|
engineeringArea: "",
|
||||||
@ -63,6 +64,7 @@ export const reset = () => {
|
|||||||
engineeringName: "",
|
engineeringName: "",
|
||||||
engineeringCode: "",
|
engineeringCode: "",
|
||||||
engineeringType: "",
|
engineeringType: "",
|
||||||
|
projectSecondType: [],
|
||||||
engineeringUse: Type["One"],
|
engineeringUse: Type["One"],
|
||||||
engineeringCost: "",
|
engineeringCost: "",
|
||||||
engineeringArea: "",
|
engineeringArea: "",
|
||||||
@ -113,7 +115,11 @@ export const rules = ref<FormRules>({
|
|||||||
engineeringType: {
|
engineeringType: {
|
||||||
type: "number",
|
type: "number",
|
||||||
required: true,
|
required: true,
|
||||||
message: "请输入项目类别"
|
message: "请选择项目类别"
|
||||||
|
},
|
||||||
|
projectSecondType: {
|
||||||
|
required: true,
|
||||||
|
message: "请选择项目二级类别"
|
||||||
},
|
},
|
||||||
engineeringUse: {
|
engineeringUse: {
|
||||||
type: "number",
|
type: "number",
|
||||||
|
|||||||
@ -32,6 +32,31 @@
|
|||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</div>
|
</div>
|
||||||
|
<div class="row">
|
||||||
|
<el-form-item label="项目二级类别:" prop="projectSecondType">
|
||||||
|
<el-select class="select" multiple placeholder="请选择" v-model="form.projectSecondType">
|
||||||
|
<el-option
|
||||||
|
v-for="item in engineeringTypeSecondOptions"
|
||||||
|
:key="item.dictCode"
|
||||||
|
:label="item.dictValue"
|
||||||
|
:value="item.dictLabel"
|
||||||
|
/>
|
||||||
|
</el-select>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="项目位置:" prop="position">
|
||||||
|
<!-- <label class="label"><span>经度</span> <el-input disabled v-model="form.longitude" size="small" /></label>
|
||||||
|
<label class="label"><span>纬度</span> <el-input disabled v-model="form.latitude" size="small" /></label> -->
|
||||||
|
<el-input placeholder="请选择" v-model="form.position">
|
||||||
|
<template #append>
|
||||||
|
<el-icon size="22" @click="openMap"><Location /></el-icon>
|
||||||
|
</template>
|
||||||
|
</el-input>
|
||||||
|
|
||||||
|
<!-- <el-icon style="background-color: #008bff; color: #fff; height: 42px; width: 36px" size="22" @click="openMap"
|
||||||
|
><Location
|
||||||
|
/></el-icon> -->
|
||||||
|
</el-form-item>
|
||||||
|
</div>
|
||||||
<div class="row">
|
<div class="row">
|
||||||
<el-form-item label="项目用途:" prop="engineeringUse">
|
<el-form-item label="项目用途:" prop="engineeringUse">
|
||||||
<el-select class="select" placeholder="请选择" v-model="form.engineeringUse">
|
<el-select class="select" placeholder="请选择" v-model="form.engineeringUse">
|
||||||
@ -69,19 +94,6 @@
|
|||||||
<el-radio :label="0">否</el-radio>
|
<el-radio :label="0">否</el-radio>
|
||||||
</el-radio-group>
|
</el-radio-group>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="项目位置:" prop="position">
|
|
||||||
<!-- <label class="label"><span>经度</span> <el-input disabled v-model="form.longitude" size="small" /></label>
|
|
||||||
<label class="label"><span>纬度</span> <el-input disabled v-model="form.latitude" size="small" /></label> -->
|
|
||||||
<el-input placeholder="请选择" v-model="form.position">
|
|
||||||
<template #append>
|
|
||||||
<el-icon size="22" @click="openMap"><Location /></el-icon>
|
|
||||||
</template>
|
|
||||||
</el-input>
|
|
||||||
|
|
||||||
<!-- <el-icon style="background-color: #008bff; color: #fff; height: 42px; width: 36px" size="22" @click="openMap"
|
|
||||||
><Location
|
|
||||||
/></el-icon> -->
|
|
||||||
</el-form-item>
|
|
||||||
</div>
|
</div>
|
||||||
<!-- 标记校验 -->
|
<!-- 标记校验 -->
|
||||||
<el-form-item label="所属管辖区域:">
|
<el-form-item label="所属管辖区域:">
|
||||||
@ -269,7 +281,7 @@
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script lang="ts" setup>
|
<script lang="ts" setup>
|
||||||
import { ref, onMounted, onUnmounted, onActivated, onDeactivated } from "vue";
|
import { ref, onMounted, onUnmounted, watch, onActivated, onDeactivated } from "vue";
|
||||||
import { form, reset, rules } from "./overview";
|
import { form, reset, rules } from "./overview";
|
||||||
import { getDicList } from "@/api/modules/jxjview";
|
import { getDicList } from "@/api/modules/jxjview";
|
||||||
import { getEngineeringName } from "@/api/modules/project";
|
import { getEngineeringName } from "@/api/modules/project";
|
||||||
@ -304,6 +316,7 @@ const licenseCreateTimeRef = ref<ElDatePickerType>(),
|
|||||||
endTimeRef = ref<ElDatePickerType>();
|
endTimeRef = ref<ElDatePickerType>();
|
||||||
|
|
||||||
const engineeringTypeOptions = ref<any>([]),
|
const engineeringTypeOptions = ref<any>([]),
|
||||||
|
engineeringTypeSecondOptions = ref<any>([]),
|
||||||
engineeringUseOptions = ref<DictDataList>([]);
|
engineeringUseOptions = ref<DictDataList>([]);
|
||||||
|
|
||||||
const engineeringPurpose = ref<any>([]);
|
const engineeringPurpose = ref<any>([]);
|
||||||
@ -399,6 +412,7 @@ onMounted(async () => {
|
|||||||
form.value = store.Message;
|
form.value = store.Message;
|
||||||
form.value.position = "经度:" + store.Message.longitude + " 纬度:" + store.Message.latitude;
|
form.value.position = "经度:" + store.Message.longitude + " 纬度:" + store.Message.latitude;
|
||||||
addressList.value = store.Message;
|
addressList.value = store.Message;
|
||||||
|
form.value.projectSecondType = store.Message.projectSecondType.split(",").map((item: string) => Number(item));
|
||||||
}
|
}
|
||||||
const res2 = await getDicList({ dictType: "engineering_state" });
|
const res2 = await getDicList({ dictType: "engineering_state" });
|
||||||
engineeringState.value = res2.result;
|
engineeringState.value = res2.result;
|
||||||
@ -422,6 +436,13 @@ onUnmounted(() => {
|
|||||||
ruleFormRef.value?.clearValidate();
|
ruleFormRef.value?.clearValidate();
|
||||||
reset();
|
reset();
|
||||||
});
|
});
|
||||||
|
watch(
|
||||||
|
() => form.value.engineeringType,
|
||||||
|
async newVal => {
|
||||||
|
const res = await getDicList({ dictType: "engineering_type_" + newVal });
|
||||||
|
engineeringTypeSecondOptions.value = res.result;
|
||||||
|
}
|
||||||
|
);
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style lang="scss" scoped>
|
<style lang="scss" scoped>
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user