diff --git a/api/workPlan/monthPlan.js b/api/workPlan/monthPlan.js
index a49fcfa..0346b49 100644
--- a/api/workPlan/monthPlan.js
+++ b/api/workPlan/monthPlan.js
@@ -230,6 +230,14 @@ export function getAUditingProcessApi(data) {
data: data
})
}
+// 月计划-查看数据-审核流程
+export function getAUditingProcessProApi(data) {
+ return request_yn({
+ url: '/ynPlanApp/proMonth/getCheckDetail',
+ method: 'post',
+ data: data
+ })
+}
// 月计划-上报人-获取审核人信息
export function getAUditingUserInfoApi(data) {
return request_yn({
diff --git a/api/workPlan/my.js b/api/workPlan/my.js
index 0154f9c..ebc1492 100644
--- a/api/workPlan/my.js
+++ b/api/workPlan/my.js
@@ -16,3 +16,11 @@ export function getReportMessageApi(data) {
data: data
})
}
+// 点击报告获取内容
+export function messagePushApi(data) {
+ return request_yn({
+ url: '/ynPlanApp/home/setSendNessage',
+ method: 'post',
+ data: data
+ })
+}
diff --git a/pages/workPlan/custody/index.vue b/pages/workPlan/custody/index.vue
index 6368ffd..e7d9246 100644
--- a/pages/workPlan/custody/index.vue
+++ b/pages/workPlan/custody/index.vue
@@ -80,7 +80,7 @@
>
-
+
{{ submitParams.lat }}
@@ -88,7 +88,10 @@
{{ submitParams.lon }}
+
+
+
@@ -249,7 +252,9 @@ export default {
date: '',
remark: ''
},
- detailsList: []
+ detailsList: [],
+ demoAddress: '',
+ demoAddress_2: ''
}
},
methods: {
@@ -439,6 +444,16 @@ export default {
if (res.resMsg == 'success') {
this.riskInfo = res.obj[0]
}
+ },
+ getLocationAddress() {
+ const this_ = this
+ uni.chooseLocation({
+ success: function (res) {
+ this_.submitParams.address = res.address
+ this_.submitParams.lon = res.longitude
+ this_.submitParams.lat = res.latitude
+ }
+ })
}
},
@@ -448,17 +463,35 @@ export default {
// 获取定位位置信息
uni.getLocation({
type: 'gcj02', // 默认为 gcj02,可以选择 'wgs84'
- // altitude: true,
+ altitude: false,
geocode: true,
success: res => {
console.log(res, '位置信息--')
+ this.demoAddress = res
const { latitude, longitude } = res
- const { province, city, district, street, streetNum, poiName } = res.address
+ // const { province, city, district, street, streetNum, poiName } = res.address
- this.submitParams.lon = longitude
- this.submitParams.lat = latitude
- console.log(province, 'province')
- this.submitParams.address = `${province}${city}${district}${street}${streetNum}${poiName}`
+ uni.request({
+ url: `https://api.map.baidu.com/reverse_geocoding/v3/?ak=PM43nB8eDNTBrXkQwGrTQFcmOni3Z9nO&output=json&coordtype=gcj02ll&location=${latitude},${longitude}`,
+ method: 'GET',
+ // data: {
+ // ak: 'PM43nB8eDNTBrXkQwGrTQFcmOni3Z9nO',
+ // output: JSON,
+ // coordtype: 'gcj02ll',
+ // location: `${longitude},${latitude}`
+ // },
+ success: res => {
+ console.log('解析的地址', res)
+
+ this.submitParams.address = res.data.result.formatted_address
+ }
+ })
+ // console.log(longitude.toString().slice(0, 7), '-----')
+
+ this.submitParams.lon = longitude.toString().length > 7 ? longitude.toString().slice(0, 7) : longitude
+ this.submitParams.lat = latitude.toString().length > 6 ? latitude.toString().slice(0, 6) : latitude
+ // console.log(province, 'province')
+ // this.submitParams.address = `${province}${city}${district}${street}${streetNum}${poiName}`
},
fail: err => {
console.error('获取位置失败:', err)
@@ -466,6 +499,17 @@ export default {
}
})
+ // uni.chooseLocation({
+ // success: function (res) {
+ // // this.demoAddress_2 = res
+ // console.log('获取位置--',res)
+ // // console.log('位置名称:' + res.name);
+ // // console.log('详细地址:' + res.address);
+ // // console.log('纬度:' + res.latitude);
+ // // console.log('经度:' + res.longitude);
+ // }
+ // })
+
const _this = this
uni.$on('update', function (data) {
// this_.getViewDataList()
@@ -611,9 +655,11 @@ export default {
position: absolute;
right: 0;
top: -30px;
+ display: flex;
+ align-items: center;
text {
- margin-right: 46rpx;
+ margin-right: 16rpx;
}
}
}
diff --git a/pages/workPlan/dayPlan/inf-index.vue b/pages/workPlan/dayPlan/inf-index.vue
index ffeb49d..1bb7e67 100644
--- a/pages/workPlan/dayPlan/inf-index.vue
+++ b/pages/workPlan/dayPlan/inf-index.vue
@@ -2050,7 +2050,25 @@ export default {
(this.monthDataList[this.activeFormPages].imgList.length +
this.monthDataList[this.activeFormPages].imgViewList.length)
}
- }
+ },
+ debounce(fn, delay) {
+ let timer = null
+ return (...args) => {
+ // 清除之前的定时器
+ if (timer) {
+ clearTimeout(timer)
+ }
+
+ // 设置新的定时器,延迟执行函数
+ timer = setTimeout(() => {
+ fn.apply( ...args) // 使用 `apply` 确保 `this` 指向 Vue 实例
+ }, delay)
+ }
+ },
+ },
+ created() {
+ // 将防抖应用到 `onSendMessage` 方法上
+ this.onSaveSubmit = this.debounce(this.onSaveSubmit, 1000);
},
onReady() {},
diff --git a/pages/workPlan/dayPlan/sub-user/index.vue b/pages/workPlan/dayPlan/sub-user/index.vue
index cc1dcc1..7c4f360 100644
--- a/pages/workPlan/dayPlan/sub-user/index.vue
+++ b/pages/workPlan/dayPlan/sub-user/index.vue
@@ -40,7 +40,7 @@
activeBorderColor="#003778"
activeBackgroundColor="#003778"
style="transform: scale(0.7)"
- @tap="onCheckBoxChangeAll()"
+ @tap="onCheckBoxChangeAll(isAllChecked)"
/>
@@ -143,11 +143,11 @@
暂退人员:
- {{ item }}
+ {{ item }}
临时人员:
- {{ item }}
+ {{ item }}
@@ -191,7 +191,8 @@ export default {
currentIndex: 0,
fixedPersonList: [],
tempPersonList: [],
- returnPersonList: []
+ returnPersonList: [],
+ isSearch: false
}
},
methods: {
@@ -232,13 +233,46 @@ export default {
// 过滤已选择的数据
if (this.subUserListTemp.length > 0) {
// this.subUserList = this.subUserListTemp.filter(e => e.isAllChecked == true)
- this.subUserListAll.forEach(e => {
- this.subUserListTemp.forEach(j => {
- if (e.idNumber == j.idNumber) {
- this.subUserList.push(JSON.parse(JSON.stringify(j)))
- }
+ // this.subUserListAll.forEach(e => {
+ // this.subUserListTemp.forEach(j => {
+ // if (e.idNumber == j.idNumber) {
+ // this.subUserList.push(JSON.parse(JSON.stringify(j)))
+ // }
+ // })
+ // })
+ let tempArray = this.personList.filter((e, index) => index != this.currentIndex)
+ let tempPersonList = []
+ if (tempArray.length > 0) {
+ this.subUserList = []
+ // this.subUserListTemp
+ tempArray.forEach(e => {
+ this.subUserListAll.forEach(j => {
+ if (!e.includes(j.idNumber)) {
+ // this.subUserList.push(j)
+ tempPersonList.push(JSON.parse(JSON.stringify(j)))
+ // this.subUserListTemp.push(JSON.parse(JSON.stringify(j)))
+ }
+ })
})
- })
+
+ // this.subUserList = this.subUserListTemp.filter(e => e.isAllChecked == true)
+ tempPersonList.forEach(e => {
+ this.subUserListTemp.forEach(j => {
+ if (e.idNumber == j.idNumber) {
+ this.subUserList.push(JSON.parse(JSON.stringify(j)))
+ }
+ })
+ })
+ // this.subUserList = tempPersonList
+ } else {
+ this.subUserListAll.forEach(e => {
+ this.subUserListTemp.forEach(j => {
+ if (e.idNumber == j.idNumber) {
+ this.subUserList.push(JSON.parse(JSON.stringify(j)))
+ }
+ })
+ })
+ }
} else {
this.subUserList = []
}
@@ -250,15 +284,67 @@ export default {
// this.subUserList = this.subUserListTemp.filter(e => e.isAllChecked == false)
// }
if (this.subUserListTemp.length > 0) {
- this.subUserListAll.forEach(e => {
- this.subUserListTemp.forEach(j => {
- if (e.idNumber != j.idNumber) {
- this.subUserList.push(JSON.parse(JSON.stringify(e)))
- }
+ // this.subUserListAll.forEach(e => {
+ // if (!this.subUserListTemp.includes(e)) {
+ // this.subUserList.push(JSON.parse(JSON.stringify(e)))
+ // }
+ // // console.log('外层循环', e)
+ // // this.subUserListTemp.forEach(j => {
+ // // console.log('内层循环', j)
+ // // if (e.idNumber == j.idNumber) {
+ // // this.subUserList.push(JSON.parse(JSON.stringify(e)))
+ // // }
+ // // })
+ // })
+ // this.subUserListTemp.forEach((e)=>{
+ // this.subUserListAll.forEach((j)=>{
+ // if(e.idNumber )
+ // })
+ // })
+
+ let tempArray = this.personList.filter((e, index) => index != this.currentIndex)
+ let tempPersonList = []
+ if (tempArray.length > 0) {
+ this.subUserList = []
+ // this.subUserListTemp
+ tempArray.forEach(e => {
+ this.subUserListAll.forEach(j => {
+ if (!e.includes(j.idNumber)) {
+ // this.subUserList.push(j)
+ tempPersonList.push(JSON.parse(JSON.stringify(j)))
+ // this.subUserListTemp.push(JSON.parse(JSON.stringify(j)))
+ }
+ })
})
- })
+
+ this.subUserList = this.tempPersonList.filter(
+ itemA => !this.subUserListTemp.some(itemB => itemB.idNumber == itemA.idNumber)
+ )
+ } else {
+ this.subUserList = this.subUserListAll.filter(
+ itemA => !this.subUserListTemp.some(itemB => itemB.idNumber == itemA.idNumber)
+ )
+ }
} else {
- this.subUserList = JSON.parse(JSON.stringify(this.subUserListAll))
+ let tempArray = this.personList.filter((e, index) => index != this.currentIndex)
+ let tempPersonList = []
+ if (tempArray.length > 0) {
+ this.subUserList = []
+ // this.subUserListTemp
+ tempArray.forEach(e => {
+ this.subUserListAll.forEach(j => {
+ if (!e.includes(j.idNumber)) {
+ // this.subUserList.push(j)
+ tempPersonList.push(JSON.parse(JSON.stringify(j)))
+ // this.subUserListTemp.push(JSON.parse(JSON.stringify(j)))
+ }
+ })
+ })
+
+ this.subUserList = tempPersonList
+ } else {
+ this.subUserList = JSON.parse(JSON.stringify(this.subUserListAll))
+ }
}
}
} else {
@@ -272,7 +358,7 @@ export default {
// }
console.log('全部状态---', this.personList)
- if (this.subUserListTemp.length == 0) {
+ if (this.subUserListTemp.length == 0 && !this.isSearch) {
if (this.personList.length > 0) {
this.subUserListAll.forEach(e => {
if (this.personList[this.currentIndex].includes(e.idNumber)) {
@@ -300,16 +386,69 @@ export default {
} else {
this.subUserList = JSON.parse(JSON.stringify(this.subUserListAll))
}
- } else {
- this.subUserListAll.forEach(e => {
- this.subUserListTemp.forEach(j => {
- if (e.idNumber == j.idNumber) {
- this.subUserList.push(JSON.parse(JSON.stringify(j)))
- } else {
- this.subUserList.push(JSON.parse(JSON.stringify(e)))
- }
+ } else if (this.subUserListTemp.length > 0 && this.isSearch) {
+ let tempArray = this.personList.filter((e, index) => index != this.currentIndex)
+ let tempPersonList = []
+ if (tempArray.length > 0) {
+ this.subUserList = []
+ // this.subUserListTemp
+ tempArray.forEach(e => {
+ this.subUserListAll.forEach(j => {
+ if (!e.includes(j.idNumber)) {
+ // this.subUserList.push(j)
+ tempPersonList.push(JSON.parse(JSON.stringify(j)))
+ // this.subUserListTemp.push(JSON.parse(JSON.stringify(j)))
+ }
+ })
})
- })
+
+ // this.subUserList = tempPersonList
+
+ tempPersonList.forEach(e => {
+ this.subUserListTemp.forEach(j => {
+ if (e.idNumber == j.idNumber) {
+ // this.subUserList.push(JSON.parse(JSON.stringify(j)))
+ e.isChecked = true
+ } else {
+ // this.subUserList.push(JSON.parse(JSON.stringify(e)))
+ }
+ })
+ })
+ this.subUserList = tempPersonList
+ } else {
+ this.subUserListAll.forEach(e => {
+ this.subUserListTemp.forEach(j => {
+ if (e.idNumber == j.idNumber) {
+ // this.subUserList.push(JSON.parse(JSON.stringify(j)))
+ e.isChecked = true
+ } else {
+ // this.subUserList.push(JSON.parse(JSON.stringify(e)))
+ }
+ })
+ })
+ this.subUserList = this.subUserListAll
+ }
+ } else if (this.subUserListTemp.length == 0 && this.isSearch) {
+ let tempArray = this.personList.filter((e, index) => index != this.currentIndex)
+ let tempPersonList = []
+ if (tempArray.length > 0) {
+ this.subUserList = []
+ // this.subUserListTemp
+ tempArray.forEach(e => {
+ this.subUserListAll.forEach(j => {
+ if (!e.includes(j.idNumber)) {
+ // this.subUserList.push(j)
+ tempPersonList.push(JSON.parse(JSON.stringify(j)))
+ // this.subUserListTemp.push(JSON.parse(JSON.stringify(j)))
+ }
+ })
+ })
+
+ this.subUserList = tempPersonList
+ } else {
+ this.subUserList = this.subUserListAll
+ }
+ } else {
}
}
this.totalAmount = this.subUserList.length
@@ -324,14 +463,14 @@ export default {
},
onCheckBoxChange(item) {
item.isChecked = !item.isChecked
- try {
- this.subUserListAll.forEach(e => {
- if (e.idNumber == item.idNumber) {
- e.isChecked = !eisChecked
- throw new Error()
- }
- })
- } catch (error) {}
+ // try {
+ // this.subUserListAll.forEach(e => {
+ // if (e.idNumber == item.idNumber) {
+ // e.isChecked = !e.isChecked
+ // throw new Error()
+ // }
+ // })
+ // } catch (error) {}
this.subUserListTemp = []
this.subUserList.forEach(e => {
@@ -397,6 +536,7 @@ export default {
this.$refs.popup.close()
},
onSubmit() {
+ this.isSearch = true
if (this.reamList.length > 0) {
this.subQueryParams.teamName = this.reamList.join(',')
}
@@ -419,6 +559,9 @@ export default {
// } else {
// }
+ this.fixedPersonList = []
+ this.tempPersonList = []
+ this.returnPersonList = []
this.subUserList.forEach(e => {
console.log('选择的每一项', e)
@@ -453,9 +596,16 @@ export default {
})
},
// 全选
- onCheckBoxChangeAll() {
+ onCheckBoxChangeAll(isAllChecked) {
+ console.log(isAllChecked, 'isAllChecked')
this.subUserList.forEach(e => {
- e.isChecked = !e.isChecked
+ e.isChecked = !isAllChecked
+
+ // this.subUserListAll.forEach(j => {
+ // if (e.idNumber == j.idNumber) {
+ // j.isChecked = !j.isChecked
+ // }
+ // })
})
if (this.subUserList.every(e => e.isChecked == true)) {
diff --git a/pages/workPlan/dayPlanAuditingDetails/inf-index.vue b/pages/workPlan/dayPlanAuditingDetails/inf-index.vue
index 18628e1..400dee3 100644
--- a/pages/workPlan/dayPlanAuditingDetails/inf-index.vue
+++ b/pages/workPlan/dayPlanAuditingDetails/inf-index.vue
@@ -644,11 +644,11 @@ export default {
}
}
})
- this.processList.forEach(e => {
- if (e.auditingInfo.length > 1) {
- e.auditingInfo = e.auditingInfo.splice(-1, 1)
- }
- })
+ // this.processList.forEach(e => {
+ // if (e.auditingInfo.length > 1) {
+ // e.auditingInfo = e.auditingInfo.splice(-1, 1)
+ // }
+ // })
}
},
/* 复选框事件 */
diff --git a/pages/workPlan/dayPlanAuditingDetails/pro-index.vue b/pages/workPlan/dayPlanAuditingDetails/pro-index.vue
index 9f9e6a9..0a6f62b 100644
--- a/pages/workPlan/dayPlanAuditingDetails/pro-index.vue
+++ b/pages/workPlan/dayPlanAuditingDetails/pro-index.vue
@@ -647,11 +647,11 @@ export default {
}
}
})
- this.processList.forEach(e => {
- if (e.auditingInfo.length > 1) {
- e.auditingInfo = e.auditingInfo.splice(-1, 1)
- }
- })
+ // this.processList.forEach(e => {
+ // if (e.auditingInfo.length > 1) {
+ // e.auditingInfo = e.auditingInfo.splice(-1, 1)
+ // }
+ // })
}
},
/* 复选框事件 */
diff --git a/pages/workPlan/dayPlanDetails/inf-index.vue b/pages/workPlan/dayPlanDetails/inf-index.vue
index e109f5f..bd9496d 100644
--- a/pages/workPlan/dayPlanDetails/inf-index.vue
+++ b/pages/workPlan/dayPlanDetails/inf-index.vue
@@ -535,11 +535,11 @@ export default {
}
}
})
- this.processList.forEach(e => {
- if (e.auditingInfo.length > 1) {
- e.auditingInfo = e.auditingInfo.splice(-1, 1)
- }
- })
+ // this.processList.forEach(e => {
+ // if (e.auditingInfo.length > 1) {
+ // e.auditingInfo = e.auditingInfo.splice(-1, 1)
+ // }
+ // })
}
},
/* 复选框事件 */
diff --git a/pages/workPlan/dayPlanDetails/pro-index.vue b/pages/workPlan/dayPlanDetails/pro-index.vue
index af0c5b3..33b3dbc 100644
--- a/pages/workPlan/dayPlanDetails/pro-index.vue
+++ b/pages/workPlan/dayPlanDetails/pro-index.vue
@@ -539,11 +539,11 @@ export default {
}
}
})
- this.processList.forEach(e => {
- if (e.auditingInfo.length > 1) {
- e.auditingInfo = e.auditingInfo.splice(-1, 1)
- }
- })
+ // this.processList.forEach(e => {
+ // if (e.auditingInfo.length > 1) {
+ // e.auditingInfo = e.auditingInfo.splice(-1, 1)
+ // }
+ // })
}
},
/* 复选框事件 */
diff --git a/pages/workPlan/messagePush/index.vue b/pages/workPlan/messagePush/index.vue
index 67d9e00..112b4bb 100644
--- a/pages/workPlan/messagePush/index.vue
+++ b/pages/workPlan/messagePush/index.vue
@@ -30,6 +30,7 @@
发送
+
@@ -88,7 +89,8 @@
diff --git a/pages/workPlan/monthPlanAuditingDetails/inf-index.vue b/pages/workPlan/monthPlanAuditingDetails/inf-index.vue
index 06fc940..83eee1f 100644
--- a/pages/workPlan/monthPlanAuditingDetails/inf-index.vue
+++ b/pages/workPlan/monthPlanAuditingDetails/inf-index.vue
@@ -650,11 +650,11 @@ export default {
}
}
})
- this.processList.forEach(e => {
- if (e.auditingInfo.length > 1) {
- e.auditingInfo = e.auditingInfo.splice(-1, 1)
- }
- })
+ // this.processList.forEach(e => {
+ // if (e.auditingInfo.length > 1) {
+ // e.auditingInfo = e.auditingInfo.splice(-1, 1)
+ // }
+ // })
}
},
/* 复选框事件 */
diff --git a/pages/workPlan/monthPlanAuditingDetails/pro-index.vue b/pages/workPlan/monthPlanAuditingDetails/pro-index.vue
index bdcb8c3..a20fd5f 100644
--- a/pages/workPlan/monthPlanAuditingDetails/pro-index.vue
+++ b/pages/workPlan/monthPlanAuditingDetails/pro-index.vue
@@ -210,7 +210,7 @@ import {
getRiskLevelListApi,
getControlLevelListApi,
updateInfPlanContentProApi,
- getAUditingProcessApi,
+ getAUditingProcessProApi,
getAUditingUserInfoApi,
// setMonthPlanApi,
setAuditingRejectProApi
@@ -242,10 +242,10 @@ export default {
{ title: '提交', id: 4, type: 'upload', isShow: ['1', '2', '3'], isRoles: ['22', '23'] }
],
productionFormLabel: [
- { form_label: '作业内容', items_type: 'ipt', name: 'area', required: true },
- { form_label: '实施单位', items_type: 'ipt', name: 'area', required: true },
- { form_label: '实施部门', items_type: 'ipt', name: 'area', required: true },
- { form_label: '任务来源', items_type: 'ipt', name: 'area', required: true },
+ { form_label: '作业内容', items_type: 'area', name: 'zynr', required: true },
+ { form_label: '实施单位', items_type: 'area', name: 'ssdw', required: true },
+ { form_label: '实施部门', items_type: 'area', name: 'ssbm', required: true },
+ { form_label: '任务来源', items_type: 'area', name: 'rwly', required: true },
{
form_label: '作业类型',
items_type: 'sel',
@@ -331,7 +331,7 @@ export default {
]
},
{ form_label: '备注', items_type: 'ipt', name: 'bz', required: false },
- { form_label: '计划数量', items_type: 'ipt', name: 'planCount', isType: 'number', required: true }
+ { form_label: '计划数量', items_type: 'ipt', isType: 'number', name: 'planCount', required: true }
],
kjsAmount: 0,
dfxAmount: 0,
@@ -537,7 +537,7 @@ export default {
// }
// console.log('paramsparams参数', params)
- const res = await getAUditingProcessApi(this.params)
+ const res = await getAUditingProcessProApi(this.params)
console.log('res审核流程', res)
res.obj.forEach(e => {
@@ -600,11 +600,11 @@ export default {
}
}
})
- this.processList.forEach(e => {
- if (e.auditingInfo.length > 1) {
- e.auditingInfo = e.auditingInfo.splice(-1, 1)
- }
- })
+ // this.processList.forEach(e => {
+ // if (e.auditingInfo.length > 1) {
+ // e.auditingInfo = e.auditingInfo.splice(-1, 1)
+ // }
+ // })
}
},
/* 复选框事件 */
diff --git a/pages/workPlan/monthPlanDetails/inf-index.vue b/pages/workPlan/monthPlanDetails/inf-index.vue
index 066e424..bbce316 100644
--- a/pages/workPlan/monthPlanDetails/inf-index.vue
+++ b/pages/workPlan/monthPlanDetails/inf-index.vue
@@ -544,11 +544,11 @@ export default {
}
}
})
- this.processList.forEach(e => {
- if (e.auditingInfo.length > 1) {
- e.auditingInfo = e.auditingInfo.splice(-1, 1)
- }
- })
+ // this.processList.forEach(e => {
+ // if (e.auditingInfo.length > 1) {
+ // e.auditingInfo = e.auditingInfo.splice(-1, 1)
+ // }
+ // })
}
},
/* 复选框事件 */
diff --git a/pages/workPlan/monthPlanDetails/pro-index.vue b/pages/workPlan/monthPlanDetails/pro-index.vue
index 50634b3..13b4678 100644
--- a/pages/workPlan/monthPlanDetails/pro-index.vue
+++ b/pages/workPlan/monthPlanDetails/pro-index.vue
@@ -13,7 +13,7 @@
+
+ 工程名称
+ {{ item.proName }}
+
计划数量
{{ item.planCount }}
@@ -363,6 +367,10 @@
{{ item.planTime }}
+
+ 工程名称
+ {{ item.proName }}
+
计划数量
{{ item.planCount }}
@@ -1780,7 +1788,8 @@ export default {
}
.item-num,
- .item-time {
+ .item-time,
+ .item-pro {
width: 96%;
margin: 0 auto;
padding: 12rpx 0;
@@ -1789,6 +1798,9 @@ export default {
justify-content: space-between;
font-size: 26rpx;
}
+ .item-pro text:first-child {
+ width: 30%;
+ }
.item-num {
margin-top: 18rpx;
}
diff --git a/pages/workPlan/networkPlan/pro-index.vue b/pages/workPlan/networkPlan/pro-index.vue
index c7a5b4a..9b3e269 100644
--- a/pages/workPlan/networkPlan/pro-index.vue
+++ b/pages/workPlan/networkPlan/pro-index.vue
@@ -313,6 +313,10 @@
{{ item.planTime }}
+
+ 工程名称
+ {{ item.proName }}
+
计划数量
@@ -363,6 +367,10 @@
{{ item.planTime }}
+
+ 工程名称
+ {{ item.proName }}
+
计划数量
@@ -1776,7 +1784,8 @@ export default {
}
.item-num,
- .item-time {
+ .item-time,
+ .item-pro {
width: 96%;
margin: 0 auto;
padding: 12rpx 0;
@@ -1788,6 +1797,9 @@ export default {
.item-num {
margin-top: 18rpx;
}
+ .item-pro text:first-child {
+ width: 30%;
+ }
.item-num text:last-child {
width: 60%;
text-align: left;
diff --git a/pages/workPlan/networkPlanAuditingDetails/inf-index.vue b/pages/workPlan/networkPlanAuditingDetails/inf-index.vue
index e527c3a..71c0886 100644
--- a/pages/workPlan/networkPlanAuditingDetails/inf-index.vue
+++ b/pages/workPlan/networkPlanAuditingDetails/inf-index.vue
@@ -604,11 +604,11 @@ export default {
}
}
})
- this.processList.forEach(e => {
- if (e.auditingInfo.length > 1) {
- e.auditingInfo = e.auditingInfo.splice(-1, 1)
- }
- })
+ // this.processList.forEach(e => {
+ // if (e.auditingInfo.length > 1) {
+ // e.auditingInfo = e.auditingInfo.splice(-1, 1)
+ // }
+ // })
}
},
/* 复选框事件 */
diff --git a/pages/workPlan/tempPlanAuditingDetails/inf-index.vue b/pages/workPlan/tempPlanAuditingDetails/inf-index.vue
index 46729b8..0ec087c 100644
--- a/pages/workPlan/tempPlanAuditingDetails/inf-index.vue
+++ b/pages/workPlan/tempPlanAuditingDetails/inf-index.vue
@@ -662,11 +662,11 @@ export default {
}
}
})
- this.processList.forEach(e => {
- if (e.auditingInfo.length > 1) {
- e.auditingInfo = e.auditingInfo.splice(-1, 1)
- }
- })
+ // this.processList.forEach(e => {
+ // if (e.auditingInfo.length > 1) {
+ // e.auditingInfo = e.auditingInfo.splice(-1, 1)
+ // }
+ // })
}
},
/* 复选框事件 */
diff --git a/pages/workPlan/tempPlanAuditingDetails/pro-index.vue b/pages/workPlan/tempPlanAuditingDetails/pro-index.vue
index 5e3432c..dd7178c 100644
--- a/pages/workPlan/tempPlanAuditingDetails/pro-index.vue
+++ b/pages/workPlan/tempPlanAuditingDetails/pro-index.vue
@@ -691,11 +691,11 @@ export default {
}
}
})
- this.processList.forEach(e => {
- if (e.auditingInfo.length > 1) {
- e.auditingInfo = e.auditingInfo.splice(-1, 1)
- }
- })
+ // this.processList.forEach(e => {
+ // if (e.auditingInfo.length > 1) {
+ // e.auditingInfo = e.auditingInfo.splice(-1, 1)
+ // }
+ // })
}
},
/* 复选框事件 */
diff --git a/pages/workPlan/tempPlanDetails/inf-index.vue b/pages/workPlan/tempPlanDetails/inf-index.vue
index 3d933e1..6d6ea34 100644
--- a/pages/workPlan/tempPlanDetails/inf-index.vue
+++ b/pages/workPlan/tempPlanDetails/inf-index.vue
@@ -556,11 +556,11 @@ export default {
}
}
})
- this.processList.forEach(e => {
- if (e.auditingInfo.length > 1) {
- e.auditingInfo = e.auditingInfo.splice(-1, 1)
- }
- })
+ // this.processList.forEach(e => {
+ // if (e.auditingInfo.length > 1) {
+ // e.auditingInfo = e.auditingInfo.splice(-1, 1)
+ // }
+ // })
}
},
/* 复选框事件 */
diff --git a/pages/workPlan/tempPlanDetails/pro-index.vue b/pages/workPlan/tempPlanDetails/pro-index.vue
index 15d36dd..08b6d0a 100644
--- a/pages/workPlan/tempPlanDetails/pro-index.vue
+++ b/pages/workPlan/tempPlanDetails/pro-index.vue
@@ -586,11 +586,11 @@ export default {
}
}
})
- this.processList.forEach(e => {
- if (e.auditingInfo.length > 1) {
- e.auditingInfo = e.auditingInfo.splice(-1, 1)
- }
- })
+ // this.processList.forEach(e => {
+ // if (e.auditingInfo.length > 1) {
+ // e.auditingInfo = e.auditingInfo.splice(-1, 1)
+ // }
+ // })
}
},
/* 复选框事件 */
diff --git a/pages/workPlan/weekPlanAuditingDetails/inf-index.vue b/pages/workPlan/weekPlanAuditingDetails/inf-index.vue
index 64b43d5..3cecf34 100644
--- a/pages/workPlan/weekPlanAuditingDetails/inf-index.vue
+++ b/pages/workPlan/weekPlanAuditingDetails/inf-index.vue
@@ -648,11 +648,11 @@ export default {
}
}
})
- this.processList.forEach(e => {
- if (e.auditingInfo.length > 1) {
- e.auditingInfo = e.auditingInfo.splice(-1, 1)
- }
- })
+ // this.processList.forEach(e => {
+ // if (e.auditingInfo.length > 1) {
+ // e.auditingInfo = e.auditingInfo.splice(-1, 1)
+ // }
+ // })
}
},
/* 复选框事件 */
diff --git a/pages/workPlan/weekPlanAuditingDetails/pro-index.vue b/pages/workPlan/weekPlanAuditingDetails/pro-index.vue
index 44f8c84..be8874c 100644
--- a/pages/workPlan/weekPlanAuditingDetails/pro-index.vue
+++ b/pages/workPlan/weekPlanAuditingDetails/pro-index.vue
@@ -745,11 +745,11 @@ export default {
}
}
})
- this.processList.forEach(e => {
+ /* this.processList.forEach(e => {
if (e.auditingInfo.length > 1) {
e.auditingInfo = e.auditingInfo.splice(-1, 1)
}
- })
+ }) */
}
},
/* 复选框事件 */
diff --git a/pages/workPlan/weekPlanDetails/inf-index.vue b/pages/workPlan/weekPlanDetails/inf-index.vue
index 36c1332..a235bc9 100644
--- a/pages/workPlan/weekPlanDetails/inf-index.vue
+++ b/pages/workPlan/weekPlanDetails/inf-index.vue
@@ -631,11 +631,11 @@ export default {
}
}
})
- this.processList.forEach(e => {
- if (e.auditingInfo.length > 1) {
- e.auditingInfo = e.auditingInfo.splice(-1, 1)
- }
- })
+ // this.processList.forEach(e => {
+ // if (e.auditingInfo.length > 1) {
+ // e.auditingInfo = e.auditingInfo.splice(-1, 1)
+ // }
+ // })
}
},
/* 复选框事件 */
diff --git a/pages/workPlan/weekPlanDetails/pro-index.vue b/pages/workPlan/weekPlanDetails/pro-index.vue
index e9e37a8..95297af 100644
--- a/pages/workPlan/weekPlanDetails/pro-index.vue
+++ b/pages/workPlan/weekPlanDetails/pro-index.vue
@@ -642,11 +642,11 @@ export default {
}
}
})
- this.processList.forEach(e => {
- if (e.auditingInfo.length > 1) {
- e.auditingInfo = e.auditingInfo.splice(-1, 1)
- }
- })
+ // this.processList.forEach(e => {
+ // if (e.auditingInfo.length > 1) {
+ // e.auditingInfo = e.auditingInfo.splice(-1, 1)
+ // }
+ // })
}
},
/* 复选框事件 */
diff --git a/utils/request_new_yn.js b/utils/request_new_yn.js
index a79ceed..83896f1 100644
--- a/utils/request_new_yn.js
+++ b/utils/request_new_yn.js
@@ -10,13 +10,26 @@ let timeout = 60000
const baseUrl = config.workPlanNewYnUrl
console.log('token', token)
+let isRequesting = false // 请求锁,防止重复请求
+
const request = config => {
+ // 如果正在请求中,直接返回一个 rejected promise
+ if (isRequesting) {
+ // return uni.showToast({ title: '请求正在处理中...请稍后', icon: 'none' })
+ // return Promise.reject('请求正在处理中,请稍后再试')
+ // uni.showToast({ title: '请求正在处理中...', icon: 'none' })
+ }
+
+ // 设置请求正在进行
+ isRequesting = true
+
// 是否需要设置 token
const isToken = (config.headers || {}).isToken === false
config.header = config.header || {}
if (token && !isToken) {
config.header['Authorization'] = 'Bearer ' + token
}
+
// get请求映射params参数
if (config.params) {
let url = config.url + '?' + tansParams(config.params)
@@ -31,6 +44,7 @@ const request = config => {
}
// config.data = JSON.stringify(config.data);
}
+
return new Promise((resolve, reject) => {
uni
.request({
@@ -42,15 +56,18 @@ const request = config => {
dataType: 'json'
})
.then(response => {
- // console.log(response)
let [error, res] = response
if (error) {
toast('后端接口连接异常')
+ // 请求完成,解除锁定
+ isRequesting = false
reject('后端接口连接异常')
return
}
+
const code = res.data.code || 200
const msg = errorCode[code] || res.data.msg || errorCode['default']
+
if (code === 401) {
showConfirm('登录状态已过期,您可以继续留在该页面,或者重新登录?').then(res => {
if (res.confirm) {
@@ -59,18 +76,29 @@ const request = config => {
})
}
})
+ // 请求完成,解除锁定
+ isRequesting = false
reject('无效的会话,或者会话已过期,请重新登录。')
} else if (code === 500) {
toast(msg)
+ // 请求完成,解除锁定
+ isRequesting = false
reject(msg)
} else if (code !== 200) {
toast(msg)
+ // 请求完成,解除锁定
+ isRequesting = false
reject(msg)
}
+
+ // 请求完成,解除锁定
+ isRequesting = false
resolve(res.data)
})
.catch(error => {
let { message } = error
+
+ // 请求异常处理
if (message === 'Network Error') {
message = '后端接口连接异常'
} else if (message.includes('timeout')) {
@@ -78,6 +106,9 @@ const request = config => {
} else if (message.includes('Request failed with status code')) {
message = '系统接口' + message.substr(message.length - 3) + '异常'
}
+
+ // 请求完成,解除锁定
+ isRequesting = false
toast(message)
reject(error)
})