diff --git a/src/views/xuncha/components/TaskForm.vue b/src/views/xuncha/components/TaskForm.vue index d0caea5..399d2a7 100644 --- a/src/views/xuncha/components/TaskForm.vue +++ b/src/views/xuncha/components/TaskForm.vue @@ -13,6 +13,7 @@ show-word-limit required :rules="[{ required: true, message: '请输入项目名称' }]" + :disabled="multiple" /> @@ -80,8 +81,8 @@ import { useRouter, useRoute } from 'vue-router'; // 获取父组件传过来的patrolLogId const props = defineProps({ - patrolLogId: String, - MarkForData: Object, + numberNum: String, + projectName: String, }); const { proxy } = getCurrentInstance(); const emits = defineEmits(['closeFormTransition']); @@ -99,7 +100,7 @@ checkItem: '', isRectification: '', problemContent: '', - patrolTaskId: '', + patrolTaskNo: '', }, patrolTargetIdText: '', formOptions: { @@ -110,14 +111,13 @@ }, { value: '2', - label: '待整改', + label: '需要整改', }, - { value: '3', label: '整改已完成' }, ], caseTypeData: [], }, }); - +const multiple = ref(true); // 获取上传的图片 function getImgList(e) { e.forEach((item) => { @@ -147,6 +147,7 @@ // 提交上报 const onSubmitData = async () => { + console.log(AllData.formData, 'AllData.formData'); patrolProblemadd(AllData.formData).then((response) => { proxy.showSuccessToast('填报成功'); closeDaKa(); @@ -158,9 +159,9 @@ if (!!!route.query.id) return; setTimeout(() => { //option为object类型,会序列化上个页面传递的参数 - console.log('传递的参数111--', route.query); //打印出上个页面传递的参数。 - - AllData.formData.patrolTaskId = route.query.id; + AllData.formData.patrolTaskNo = props.numberNum; + AllData.patrolTargetIdText = props.projectName; + console.log(AllData.formData.taskName, 'AllData.formData.taskName '); }); }, { immediate: true } diff --git a/src/views/xuncha/components/TaskForm.vue b/src/views/xuncha/components/TaskForm.vue index d0caea5..399d2a7 100644 --- a/src/views/xuncha/components/TaskForm.vue +++ b/src/views/xuncha/components/TaskForm.vue @@ -13,6 +13,7 @@ show-word-limit required :rules="[{ required: true, message: '请输入项目名称' }]" + :disabled="multiple" /> @@ -80,8 +81,8 @@ import { useRouter, useRoute } from 'vue-router'; // 获取父组件传过来的patrolLogId const props = defineProps({ - patrolLogId: String, - MarkForData: Object, + numberNum: String, + projectName: String, }); const { proxy } = getCurrentInstance(); const emits = defineEmits(['closeFormTransition']); @@ -99,7 +100,7 @@ checkItem: '', isRectification: '', problemContent: '', - patrolTaskId: '', + patrolTaskNo: '', }, patrolTargetIdText: '', formOptions: { @@ -110,14 +111,13 @@ }, { value: '2', - label: '待整改', + label: '需要整改', }, - { value: '3', label: '整改已完成' }, ], caseTypeData: [], }, }); - +const multiple = ref(true); // 获取上传的图片 function getImgList(e) { e.forEach((item) => { @@ -147,6 +147,7 @@ // 提交上报 const onSubmitData = async () => { + console.log(AllData.formData, 'AllData.formData'); patrolProblemadd(AllData.formData).then((response) => { proxy.showSuccessToast('填报成功'); closeDaKa(); @@ -158,9 +159,9 @@ if (!!!route.query.id) return; setTimeout(() => { //option为object类型,会序列化上个页面传递的参数 - console.log('传递的参数111--', route.query); //打印出上个页面传递的参数。 - - AllData.formData.patrolTaskId = route.query.id; + AllData.formData.patrolTaskNo = props.numberNum; + AllData.patrolTargetIdText = props.projectName; + console.log(AllData.formData.taskName, 'AllData.formData.taskName '); }); }, { immediate: true } diff --git a/src/views/xuncha/components/inspection.vue b/src/views/xuncha/components/inspection.vue index 22d3b5a..6413c2d 100644 --- a/src/views/xuncha/components/inspection.vue +++ b/src/views/xuncha/components/inspection.vue @@ -17,8 +17,8 @@ class="DakaPropID" v-if="AllData.showForm" @closeFormTransition="closeFormTransition" - :patrolLogId="AllData.patrolLogId" - :MarkForData="AllData.MarkForData" + :numberNum="AllData.numberNum" + :projectName="AllData.projectName" :isDisable="AllData.isDisable" /> @@ -60,6 +60,8 @@ taskID: '', //当前巡检任务ID longitudeNow: '', latitudeNow: '', + numberNum: '', + projectName: '', IntervalKry: '', //定时器ID--获取经纬度信息 TimerArray: [], //记录定时器数据 num: 0, @@ -278,6 +280,8 @@ const getInspectionInfo = (id) => { PatrolTaskID(id).then((res) => { if (res && res.code == 200) { + AllData.numberNum = res.data.number; + AllData.projectName = res.data.projectName; AllData.gujiData = res.data.patrolPathLngLat; console.log(AllData.gujiData, 'AllData.gujiData'); // 保存当前巡检ID diff --git a/src/views/xuncha/components/TaskForm.vue b/src/views/xuncha/components/TaskForm.vue index d0caea5..399d2a7 100644 --- a/src/views/xuncha/components/TaskForm.vue +++ b/src/views/xuncha/components/TaskForm.vue @@ -13,6 +13,7 @@ show-word-limit required :rules="[{ required: true, message: '请输入项目名称' }]" + :disabled="multiple" /> @@ -80,8 +81,8 @@ import { useRouter, useRoute } from 'vue-router'; // 获取父组件传过来的patrolLogId const props = defineProps({ - patrolLogId: String, - MarkForData: Object, + numberNum: String, + projectName: String, }); const { proxy } = getCurrentInstance(); const emits = defineEmits(['closeFormTransition']); @@ -99,7 +100,7 @@ checkItem: '', isRectification: '', problemContent: '', - patrolTaskId: '', + patrolTaskNo: '', }, patrolTargetIdText: '', formOptions: { @@ -110,14 +111,13 @@ }, { value: '2', - label: '待整改', + label: '需要整改', }, - { value: '3', label: '整改已完成' }, ], caseTypeData: [], }, }); - +const multiple = ref(true); // 获取上传的图片 function getImgList(e) { e.forEach((item) => { @@ -147,6 +147,7 @@ // 提交上报 const onSubmitData = async () => { + console.log(AllData.formData, 'AllData.formData'); patrolProblemadd(AllData.formData).then((response) => { proxy.showSuccessToast('填报成功'); closeDaKa(); @@ -158,9 +159,9 @@ if (!!!route.query.id) return; setTimeout(() => { //option为object类型,会序列化上个页面传递的参数 - console.log('传递的参数111--', route.query); //打印出上个页面传递的参数。 - - AllData.formData.patrolTaskId = route.query.id; + AllData.formData.patrolTaskNo = props.numberNum; + AllData.patrolTargetIdText = props.projectName; + console.log(AllData.formData.taskName, 'AllData.formData.taskName '); }); }, { immediate: true } diff --git a/src/views/xuncha/components/inspection.vue b/src/views/xuncha/components/inspection.vue index 22d3b5a..6413c2d 100644 --- a/src/views/xuncha/components/inspection.vue +++ b/src/views/xuncha/components/inspection.vue @@ -17,8 +17,8 @@ class="DakaPropID" v-if="AllData.showForm" @closeFormTransition="closeFormTransition" - :patrolLogId="AllData.patrolLogId" - :MarkForData="AllData.MarkForData" + :numberNum="AllData.numberNum" + :projectName="AllData.projectName" :isDisable="AllData.isDisable" /> @@ -60,6 +60,8 @@ taskID: '', //当前巡检任务ID longitudeNow: '', latitudeNow: '', + numberNum: '', + projectName: '', IntervalKry: '', //定时器ID--获取经纬度信息 TimerArray: [], //记录定时器数据 num: 0, @@ -278,6 +280,8 @@ const getInspectionInfo = (id) => { PatrolTaskID(id).then((res) => { if (res && res.code == 200) { + AllData.numberNum = res.data.number; + AllData.projectName = res.data.projectName; AllData.gujiData = res.data.patrolPathLngLat; console.log(AllData.gujiData, 'AllData.gujiData'); // 保存当前巡检ID diff --git a/src/views/xuncha/components/patroLogDetails.vue b/src/views/xuncha/components/patroLogDetails.vue index c7d6d5e..b6cd0d2 100644 --- a/src/views/xuncha/components/patroLogDetails.vue +++ b/src/views/xuncha/components/patroLogDetails.vue @@ -73,15 +73,7 @@
整改状态 - {{ - item.isRectification == '1' - ? '无需整改' - : item.isRectification == '2' - ? '待整改' - : item.isRectification == '3' - ? '整改已完成' - : '' - }} + {{ item.isRectification == '1' ? '无需整改' : item.isRectification == '2' ? '需要整改' : '' }}
@@ -131,17 +123,8 @@ path: [], videoSrc: null, recordPath: [], - imgList: [ - // { - // url: 'http://42.193.7.161:9000/newfiber-standard/2023/03/14/Screenshot_2023-03-14-17-14-32-53_a2e629f0ea915b4ed11e296a059c9a12_20230314200209A029.jpg', - // }, - ], - videoList: [ - // { - // name: 'f210e3b80bf1dd5d867c633de815053e.mp4', - // url: 'https://server1.wh-nf.cn:6084/mp4/etdzpdx_video01.mp4', - // }, - ], + imgList: [], + videoList: [], caseList: [], patrolSectionId: '', geometryBufferData: '', @@ -159,12 +142,11 @@ }); // 获取项目巡检记录数据 const getData = async () => { - let res = await patrolProblemList({ patrolTaskId: route.query.id }); + let res = await patrolProblemList({ patrolTaskNo: route.query.number }); if (res && res.code == 200) { allData.detailsInfo = { ...res.data, }; - console.log(allData.detailsInfo, ' allData.detailsInfo'); } }; diff --git a/src/views/xuncha/components/TaskForm.vue b/src/views/xuncha/components/TaskForm.vue index d0caea5..399d2a7 100644 --- a/src/views/xuncha/components/TaskForm.vue +++ b/src/views/xuncha/components/TaskForm.vue @@ -13,6 +13,7 @@ show-word-limit required :rules="[{ required: true, message: '请输入项目名称' }]" + :disabled="multiple" /> @@ -80,8 +81,8 @@ import { useRouter, useRoute } from 'vue-router'; // 获取父组件传过来的patrolLogId const props = defineProps({ - patrolLogId: String, - MarkForData: Object, + numberNum: String, + projectName: String, }); const { proxy } = getCurrentInstance(); const emits = defineEmits(['closeFormTransition']); @@ -99,7 +100,7 @@ checkItem: '', isRectification: '', problemContent: '', - patrolTaskId: '', + patrolTaskNo: '', }, patrolTargetIdText: '', formOptions: { @@ -110,14 +111,13 @@ }, { value: '2', - label: '待整改', + label: '需要整改', }, - { value: '3', label: '整改已完成' }, ], caseTypeData: [], }, }); - +const multiple = ref(true); // 获取上传的图片 function getImgList(e) { e.forEach((item) => { @@ -147,6 +147,7 @@ // 提交上报 const onSubmitData = async () => { + console.log(AllData.formData, 'AllData.formData'); patrolProblemadd(AllData.formData).then((response) => { proxy.showSuccessToast('填报成功'); closeDaKa(); @@ -158,9 +159,9 @@ if (!!!route.query.id) return; setTimeout(() => { //option为object类型,会序列化上个页面传递的参数 - console.log('传递的参数111--', route.query); //打印出上个页面传递的参数。 - - AllData.formData.patrolTaskId = route.query.id; + AllData.formData.patrolTaskNo = props.numberNum; + AllData.patrolTargetIdText = props.projectName; + console.log(AllData.formData.taskName, 'AllData.formData.taskName '); }); }, { immediate: true } diff --git a/src/views/xuncha/components/inspection.vue b/src/views/xuncha/components/inspection.vue index 22d3b5a..6413c2d 100644 --- a/src/views/xuncha/components/inspection.vue +++ b/src/views/xuncha/components/inspection.vue @@ -17,8 +17,8 @@ class="DakaPropID" v-if="AllData.showForm" @closeFormTransition="closeFormTransition" - :patrolLogId="AllData.patrolLogId" - :MarkForData="AllData.MarkForData" + :numberNum="AllData.numberNum" + :projectName="AllData.projectName" :isDisable="AllData.isDisable" /> @@ -60,6 +60,8 @@ taskID: '', //当前巡检任务ID longitudeNow: '', latitudeNow: '', + numberNum: '', + projectName: '', IntervalKry: '', //定时器ID--获取经纬度信息 TimerArray: [], //记录定时器数据 num: 0, @@ -278,6 +280,8 @@ const getInspectionInfo = (id) => { PatrolTaskID(id).then((res) => { if (res && res.code == 200) { + AllData.numberNum = res.data.number; + AllData.projectName = res.data.projectName; AllData.gujiData = res.data.patrolPathLngLat; console.log(AllData.gujiData, 'AllData.gujiData'); // 保存当前巡检ID diff --git a/src/views/xuncha/components/patroLogDetails.vue b/src/views/xuncha/components/patroLogDetails.vue index c7d6d5e..b6cd0d2 100644 --- a/src/views/xuncha/components/patroLogDetails.vue +++ b/src/views/xuncha/components/patroLogDetails.vue @@ -73,15 +73,7 @@
整改状态 - {{ - item.isRectification == '1' - ? '无需整改' - : item.isRectification == '2' - ? '待整改' - : item.isRectification == '3' - ? '整改已完成' - : '' - }} + {{ item.isRectification == '1' ? '无需整改' : item.isRectification == '2' ? '需要整改' : '' }}
@@ -131,17 +123,8 @@ path: [], videoSrc: null, recordPath: [], - imgList: [ - // { - // url: 'http://42.193.7.161:9000/newfiber-standard/2023/03/14/Screenshot_2023-03-14-17-14-32-53_a2e629f0ea915b4ed11e296a059c9a12_20230314200209A029.jpg', - // }, - ], - videoList: [ - // { - // name: 'f210e3b80bf1dd5d867c633de815053e.mp4', - // url: 'https://server1.wh-nf.cn:6084/mp4/etdzpdx_video01.mp4', - // }, - ], + imgList: [], + videoList: [], caseList: [], patrolSectionId: '', geometryBufferData: '', @@ -159,12 +142,11 @@ }); // 获取项目巡检记录数据 const getData = async () => { - let res = await patrolProblemList({ patrolTaskId: route.query.id }); + let res = await patrolProblemList({ patrolTaskNo: route.query.number }); if (res && res.code == 200) { allData.detailsInfo = { ...res.data, }; - console.log(allData.detailsInfo, ' allData.detailsInfo'); } }; diff --git a/vite.config.js b/vite.config.js index de062ce..f43437e 100644 --- a/vite.config.js +++ b/vite.config.js @@ -10,8 +10,8 @@ const Timestamp = new Date().getTime(); //随机时间戳 // const targetUrl = 'http://192.168.16.100:7200'; //陈迁 -// const targetUrl = 'http://192.168.20.52:7300'; //杨辉 -const targetUrl = 'https://server2.wh-nf.cn:8082/prod-api'; //线上 +const targetUrl = 'http://192.168.20.52:7300'; //杨辉 +// const targetUrl = 'https://server2.wh-nf.cn:8082/prod-api'; //线上 export default defineConfig({ // 地址是和router中和ngix中配置的名称一致