From b3b1fc54b219901445659dd342c61e11b5e25eb5 Mon Sep 17 00:00:00 2001
From: shj <1790240199@qq.com>
Date: 星期四, 18 八月 2022 15:18:19 +0800
Subject: [PATCH] 对接

---
 src/components/DailogClass/index.vue                                     |   10 ++++++++--
 src/views/goalManagement/targetDecompositionYear/component/DailogAdd.vue |    1 -
 src/components/equipmentDailog/repairDailog.vue                          |    4 ++--
 src/views/goalManagement/targetSettings/component/dailogAdd.vue          |    6 ++++++
 src/components/equipmentDailog/Dailog.vue                                |    5 +++++
 src/views/goalManagement/performanceAppraisal/component/DailogKh.vue     |   10 ++++++++--
 src/views/goalManagement/performanceAppraisal/component/DailogAq.vue     |    6 ++++++
 7 files changed, 35 insertions(+), 7 deletions(-)

diff --git a/src/components/DailogClass/index.vue b/src/components/DailogClass/index.vue
index ceb2de2..f629089 100644
--- a/src/components/DailogClass/index.vue
+++ b/src/components/DailogClass/index.vue
@@ -1,5 +1,5 @@
 <template>
-	<el-dialog v-model="dialogVisible" @close="resetForm(ruleFormRef)" :fullscreen="full" title="目标分解" width="30%" draggable>
+	<el-dialog v-model="dialogVisible" @close="resetForm(ruleFormRef)" :fullscreen="full" :title="titles" width="30%" draggable>
 		<el-button @click="toggleFullscreen" size="small" class="pot" :icon="FullScreen"></el-button>
 		<el-form :model="form" ref="ruleFormRef" :rules="rules" :disabled="disabled" label-width="120px">
 			<el-row>
@@ -44,9 +44,11 @@
 		const targetType = ref();
 		const disabled = ref(false);
 		const titles = ref();
+		const titleT=ref()
 		const openDailog = (title: string, type: any, id: number) => {
 			dialogVisible.value = true;
-			titles.value = title;
+			titles.value = `${title}目标分解`;
+			titleT.value=title
 			targetType.value = type;
 			disabled.value = title == '查看' ? true : false;
 			if (title == '查看' || title == '修改') {
@@ -81,6 +83,9 @@
 			if (!formEl) return;
 			await formEl.validate((valid, fields) => {
 				if (valid) {
+					if(titleT.value=='新建'){
+						delete form.value.id
+					}
 					dialogVisible.value = false;
 					goalManagementApi()
 						.gettargetClassAdd(form.value)
@@ -117,6 +122,7 @@
 		return {
 			timeDate,
 			ruleFormRef,
+			titleT,
 			rules,
 			submitForm,
 			resetForm,
diff --git a/src/components/equipmentDailog/Dailog.vue b/src/components/equipmentDailog/Dailog.vue
index ba857c9..c1bb4d8 100644
--- a/src/components/equipmentDailog/Dailog.vue
+++ b/src/components/equipmentDailog/Dailog.vue
@@ -229,6 +229,9 @@
 					style="width: 100%"
 				/>
 			</el-form-item>
+			<el-form-item label="保养周期" size="default" prop="takecareCycle ">
+				<el-input v-model="form.takecareCycle" placeholder="请填写保养周期" />
+			</el-form-item>
 		</el-form>
 		<el-tabs v-model="activeName" class="demo-tabs">
 			<el-tab-pane label="设备保养" name="first">
@@ -467,6 +470,7 @@
 			useDate: '',
 
 			recoverySubmitDate: '',
+			takecareCycle:"",
 
 			lockNum: '',
 
@@ -616,6 +620,7 @@
 			destoryReason: [],
 			destorySubmitDate: [],
 			actualDestoryDate: [],
+			takecareCycle :[]
 		});
 		// 提交
 		const submitForm = async (formEl: FormInstance | undefined) => {
diff --git a/src/components/equipmentDailog/repairDailog.vue b/src/components/equipmentDailog/repairDailog.vue
index 54a2238..18e0663 100644
--- a/src/components/equipmentDailog/repairDailog.vue
+++ b/src/components/equipmentDailog/repairDailog.vue
@@ -11,8 +11,8 @@
 				<el-col :span="11" :offset="2">
 					<el-form-item label="维修状态" size="default" prop="repairStatus">
 						<el-select v-model="form.repairStatus" placeholder="请选择" style="width: 100%">
-							<el-option label="维修中" value="1" />
-							<el-option label="已修好" value="2" />
+							<el-option label="维修中" :value="1" />
+							<el-option label="已修好" :value="2" />
 						</el-select>
 					</el-form-item>
 				</el-col>
diff --git a/src/views/goalManagement/performanceAppraisal/component/DailogAq.vue b/src/views/goalManagement/performanceAppraisal/component/DailogAq.vue
index 3bb2d2b..1bf1044 100644
--- a/src/views/goalManagement/performanceAppraisal/component/DailogAq.vue
+++ b/src/views/goalManagement/performanceAppraisal/component/DailogAq.vue
@@ -167,12 +167,14 @@
 			title: '', ////考核标题
 		});
 		const titles = ref();
+		const titleT = ref();
 		const disabled = ref(false);
 		// 打开弹窗
 		const openDailog = (title: string, value: any, id: number) => {
 			department();
 			dialogVisible.value = true;
 			titles.value = `${title}安全考核管理`;
+			titleT.value=title
 			disabled.value = title == '查看' ? true : false;
 			if (title == '查看' || title == '修改')
 				goalManagementApi()
@@ -282,6 +284,9 @@
 			if (!formEl) return;
 			await formEl.validate((valid, fields) => {
 				if (valid) {
+					if(titleT.value=='新建'){
+						delete form.value.id
+					}
 					dialogVisible.value = false;
 					let arr = [];
 					for (let i = 0; i < form.value.numberDetailJson.length; i++) {
@@ -403,6 +408,7 @@
 			console.log(form.value);
 		};
 		return {
+			titleT,
 			rules,
 			timeC,
 			numberC,
diff --git a/src/views/goalManagement/performanceAppraisal/component/DailogKh.vue b/src/views/goalManagement/performanceAppraisal/component/DailogKh.vue
index c295342..7d58a68 100644
--- a/src/views/goalManagement/performanceAppraisal/component/DailogKh.vue
+++ b/src/views/goalManagement/performanceAppraisal/component/DailogKh.vue
@@ -11,8 +11,8 @@
 				<el-col :span="11" :offset="2">
 					<el-form-item label="适用范围" size="default">
 						<el-select v-model="form.applyRange" style="width: 100%" placeholder="请选择">
-							<el-option label="安全生产xxx" value="1" />
-							<el-option label="安全生产xxx" value="2" />
+							<el-option label="安全生产责任制考核1" value="1" />
+							<el-option label="安全生产责任制考核2" value="2" />
 						</el-select>
 					</el-form-item>
 				</el-col>
@@ -111,12 +111,14 @@
 			applyRange: '', ////适用范围
 		});
 		const titles = ref();
+		const titleT = ref();
 		const disabled = ref(false);
 		const clickType = ref(false);
 		// 打开弹窗
 		const openDailog = (title: string, value: any, id: number) => {
 			dialogVisible.value = true;
 			titles.value = `${title}安全考核管理`;
+			titleT.value=title
 			disabled.value = title == '查看' ? true : false;
 			if (title == '查看' || title == '修改') {
 				goalManagementApi()
@@ -146,6 +148,9 @@
 		};
 		// 提交
 		const submitForm = () => {
+			if(titleT.value=='新建'){
+				delete form.value.id
+			}
 			dialogVisible.value = false;
 			goalManagementApi()
 				.getexamineTemplateAddOrUpdate(form.value)
@@ -210,6 +215,7 @@
 			}
 		};
 		return {
+			titleT,
 			index,
 			form,
 			dialogVisible,
diff --git a/src/views/goalManagement/targetDecompositionYear/component/DailogAdd.vue b/src/views/goalManagement/targetDecompositionYear/component/DailogAdd.vue
index b281c18..52680b0 100644
--- a/src/views/goalManagement/targetDecompositionYear/component/DailogAdd.vue
+++ b/src/views/goalManagement/targetDecompositionYear/component/DailogAdd.vue
@@ -153,7 +153,6 @@
 		//  分类 All
 		const allList=()=>{
 			goalManagementApi().gettargetClassAll({}).then(res=>{
-				console.log('xxxxxx')
 				if(res.data.code==200){
 					options.value=res.data.data
 				}else{
diff --git a/src/views/goalManagement/targetSettings/component/dailogAdd.vue b/src/views/goalManagement/targetSettings/component/dailogAdd.vue
index cf219d6..3c09fd3 100644
--- a/src/views/goalManagement/targetSettings/component/dailogAdd.vue
+++ b/src/views/goalManagement/targetSettings/component/dailogAdd.vue
@@ -86,9 +86,11 @@
 		});
 		const titles = ref();
 		const disabled = ref(false);
+		const titleT=ref()
 		// 打开弹窗
 		const openDialog = (title: string, value: any, id: number) => {
 			Shows.value = true;
+			titleT.value=title
 			titles.value = `${title}目标设定`;
 			form.value.targetType = value;
 			disabled.value = title == '查看' ? true : false;
@@ -169,6 +171,9 @@
 			if (!formEl) return;
 			await formEl.validate((valid, fields) => {
 				if (valid) {
+					if(titleT.value=='新建'){
+						delete form.value.id
+					}	
 					Shows.value = false;
 					goalManagementApi()
 						.getTargetMngAddOrupdata(form.value)
@@ -204,6 +209,7 @@
 			openDialog,
 			handleClose,
 			titles,
+			titleT,
 			// timeDate,
 			Shows,
 			form,

--
Gitblit v1.9.2