月计划完善

This commit is contained in:
BianLzhaoMin 2024-10-28 21:43:45 +08:00
parent 8a7882ed78
commit f03364d139
13 changed files with 3264 additions and 67 deletions

View File

@ -96,6 +96,38 @@ export function submitPlanApi(data) {
data: data data: data
}) })
} }
// 月计划-工作待办-列表 --基建
export function getWorkWaitListApi(data) {
return request_yn({
url: '/ynPlanApp/infMonth/getViewReport',
method: 'post',
data: data
})
}
// 月计划-工作待办-工程信息 --基建
export function getWorkWaitProjectApi(data) {
return request_yn({
url: '/ynPlanApp/infMonth/getViewReportForPro',
method: 'post',
data: data
})
}
// 月计划-工作待办-审核不通过 --基建
export function setAuditingRejectApi(data) {
return request_yn({
url: '/ynPlanApp/infMonth/rejectPlan',
method: 'post',
data: data
})
}
// 月计划-查看报表 --基建
export function getReportFormListApi(data) {
return request_yn({
url: '/ynPlanApp/infMonth/getViewReport',
method: 'post',
data: data
})
}
/** /**
* 生产月计划 * 生产月计划
@ -214,3 +246,63 @@ export function getIsPlanProApi(data) {
data: data data: data
}) })
} }
// 月计划-工作待办-列表 - 生产
export function getWorkWaitListProApi(data) {
return request_yn({
url: '/ynPlanApp/proMonth/getViewReport',
method: 'post',
data: data
})
}
// 月计划-工作待办-工程信息- - 生产
// export function getWorkWaitProjectProApi(data) {
// return request_yn({
// url: '/ynPlanApp/proMonth/getViewReportForPro',
// method: 'post',
// data: data
// })
// }
// 月计划-工作待办-审核不通过 - 生产
export function setAuditingRejectProApi(data) {
return request_yn({
url: '/ynPlanApp/proMonth/rejectPlan',
method: 'post',
data: data
})
}
// 月计划-工作待办-列表 --生产
// export function getWorkWaitListProApi(data) {
// return request_yn({
// url: '/ynPlanApp/proMonth/getViewReport',
// method: 'post',
// data: data
// })
// }
// 月计划-工作待办-工程信息 --生产
export function getWorkWaitProjectProApi(data) {
return request_yn({
url: '/ynPlanApp/proMonth/getViewReportForPro',
method: 'post',
data: data
})
}
// 月计划-工作待办-审核不通过 --生产
// export function setAuditingRejectProApi(data) {
// return request_yn({
// url: '/ynPlanApp/proMonth/rejectPlan',
// method: 'post',
// data: data
// })
// }
// 月计划-查看报表 --生产
export function getReportFormListProApi(data) {
return request_yn({
url: '/ynPlanApp/proMonth/getViewReport',
method: 'post',
data: data
})
}

View File

@ -1,6 +1,6 @@
{ {
"name" : "作业管控智慧平台", "name" : "作业管控智慧平台",
"appid" : "__UNI__4165875", "appid" : "__UNI__5A28908",
"description" : "作业管控智慧平台", "description" : "作业管控智慧平台",
"versionName" : "1.0.11", "versionName" : "1.0.11",
"versionCode" : 111, "versionCode" : 111,

View File

@ -801,6 +801,13 @@
"navigationStyle": "custom" "navigationStyle": "custom"
} }
}, },
/* -- - */
{
"path": "pages/workPlan/monthPlanAuditingDetails/inf-index",
"style": {
"navigationStyle": "custom"
}
},
/* -- */ /* -- */
{ {
"path": "pages/workPlan/monthPlanDetails/pro-index", "path": "pages/workPlan/monthPlanDetails/pro-index",
@ -808,6 +815,13 @@
"navigationStyle": "custom" "navigationStyle": "custom"
} }
}, },
/* -- - */
{
"path": "pages/workPlan/monthPlanAuditingDetails/pro-index",
"style": {
"navigationStyle": "custom"
}
},
{ {
"path": "pages/workPlan/networkPlan/index", "path": "pages/workPlan/networkPlan/index",
"style": { "style": {

View File

@ -24,6 +24,50 @@
</button> </button>
</view> </view>
<!-- 工作待办 -->
<view v-show="activeIndex === '工作待办' && (roles == 24 || roles == 25)" class="common-style">
<view class="time-select">
<uni-icons
type="left"
size="30"
style="margin-left: 46rpx; font-weight: bold"
@tap="onWorkWaitTimeReduce"
></uni-icons>
<text>{{ getWorkWaitParams.planTime }}</text>
<uni-icons
type="right"
size="30"
style="margin-right: 46rpx; font-weight: bold"
@tap="onWorkWaitTimeAdd"
></uni-icons>
</view>
<scroll-view scroll-y>
<view class="view-data-auditing" v-for="(item, index) in workWaitList" :key="index">
<view class="auditing-item have-bottom">
<view class="item_1">在建工程</view>
<view class="item_2" @tap="onViewProjectNum(1)">{{ item.zjs }}</view>
<view class="item_3" style="text-align: right">
{{ item.planTime }}
</view>
</view>
<view class="auditing-item">
<view class="item_1">已报工程数</view>
<view class="item_2" @tap="onViewProjectNum(2)">{{ item.ybs }}</view>
<view class="item_1">未报工程数</view>
<view class="item_2" @tap="onViewProjectNum(3)">{{ item.wbs }}</view>
</view>
<view class="auditing-item">
<view class="item_1">待审核数</view>
<view class="item_2">{{ item.dsh }}</view>
<view class="item_3">
<text @tap="onViewProjectNum(4)">待审核</text>
</view>
</view>
</view>
</scroll-view>
</view>
<!-- 发起提交 --> <!-- 发起提交 -->
<view class="content-2" v-show="activeIndex === '发起提交'"> <view class="content-2" v-show="activeIndex === '发起提交'">
<view class="pages-add" id="pagesAddRef"> <view class="pages-add" id="pagesAddRef">
@ -153,8 +197,8 @@
</view> </view>
</view> </view>
<!-- 查看报表 --> <!-- 查看报表 填报人和上报人 -->
<view v-show="activeIndex === '查看报表'" class="common-style"> <view v-show="activeIndex === '查看报表' && (roles == 22 || roles == 23)" class="common-style">
<view class="report-form-header" v-if="monthDataList.length > 0"> <view class="report-form-header" v-if="monthDataList.length > 0">
<view> <view>
<scroll-view scroll-x class="header-left"> <scroll-view scroll-x class="header-left">
@ -251,6 +295,50 @@
</view> </view>
</view> </view>
<!-- 查看报表审核人 -->
<view v-show="activeIndex === '查看报表' && (roles == 24 || roles == 25)" class="common-style">
<view class="icon-search-time">
<text style="fon-size: 30rpx; margin-right: 25rpx" @tap="onReduceMonthNew"></text>
<uni-icons type="left" size="20" @tap="onReduceDayNew"></uni-icons>
<view class="view-time">
<picker mode="date" @change="onChangeCurrentDataNew" v-model="currentTimeNew">
<view class="date-picker">{{ currentTimeNew }}</view>
</picker>
</view>
<uni-icons type="right" size="20" @tap="onAddDayNew"></uni-icons>
<text style="fon-size: 30rpx; margin-left: 25rpx" @tap="onAddMonthNew"></text>
<button @tap="onBackTodayNew">返回本月</button>
</view>
<scroll-view scroll-y>
<view class="view-data-auditing" v-for="(item, index) in workWaitListNew" :key="index">
<view class="auditing-item have-bottom">
<view class="item_1">在建工程</view>
<view class="item_2" @tap="onViewProjectNum(1)">{{ item.zjs }}</view>
<view class="item_3" style="text-align: right">
{{ item.planTime }}
</view>
</view>
<view class="auditing-item">
<view class="item_1">已报工程数</view>
<view class="item_2" @tap="onViewProjectNum(2)">{{ item.ybs }}</view>
<view class="item_1">未报工程数</view>
<view class="item_2" @tap="onViewProjectNum(3)">{{ item.wbs }}</view>
</view>
<view class="auditing-item">
<view class="item_1">待审核数</view>
<view class="item_2">{{ item.dsh }}</view>
<view class="item_3">
<text @tap="onViewProjectNumNew(5)">已通过</text>
</view>
</view>
</view>
</scroll-view>
</view>
<!-- 查看数据 --> <!-- 查看数据 -->
<view v-show="activeIndex === '查看数据'" class="common-style"> <view v-show="activeIndex === '查看数据'" class="common-style">
<uni-easyinput <uni-easyinput
@ -413,6 +501,37 @@
</view> </view>
</view> </view>
</uni-popup> </uni-popup>
<!-- 弹框 查看工程 -->
<uni-popup ref="popupViewProject" background-color="#fff">
<view class="popup-view">
<view class="popup-view-title">
<text>查看工程</text>
<uni-icons type="closeempty" size="32" @tap="onCloseViewPopup"></uni-icons>
</view>
<view class="search-container">
<view class="search-box">
<view class="view-search-ipt">
<uni-easyinput
:clear="false"
type="text"
placeholder="请输入关键字"
v-model="getWorkWaitProjectParams.keyword"
/>
</view>
<view class="view-search-btn" @tap="onSearchWorkWaitProject">搜索</view>
</view>
</view>
<view class="view-project-list">
<scroll-view :scroll-y="true" class="view-project-item">
<view v-for="item in workWaitProjectList" :key="item.id" @tap="onViewAuditingDetails(item)">
{{ item.proName }}
</view>
</scroll-view>
</view>
</view>
</uni-popup>
</view> </view>
</template> </template>
@ -427,7 +546,10 @@ import {
getProjectList_2Api, getProjectList_2Api,
getControlLevelListApi, getControlLevelListApi,
getIsPlanApi, getIsPlanApi,
getAUditingUserInfoApi getAUditingUserInfoApi,
getWorkWaitListApi,
getWorkWaitProjectApi,
getReportFormListApi
} from '../../../api/workPlan/monthPlan' } from '../../../api/workPlan/monthPlan'
export default { export default {
components: { components: {
@ -435,7 +557,7 @@ export default {
}, },
data() { data() {
return { return {
activeIndex: '发起提交', activeIndex: '',
DateValue: this.$moment().format('YYYY-MM'), DateValue: this.$moment().format('YYYY-MM'),
pagesTotal: 1, pagesTotal: 1,
currentPage: 0, currentPage: 0,
@ -444,10 +566,11 @@ export default {
formData: {}, formData: {},
isType: false, isType: false,
currentTime: this.$moment().format('YYYY-MM'), currentTime: this.$moment().format('YYYY-MM'),
currentTimeNew: this.$moment().format('YYYY-MM'),
btnList: [ btnList: [
{ btn_title: '工作待办', isShow: ['24', '25'] }, { btn_title: '工作待办', isShow: ['24', '25'] },
{ btn_title: '发起提交', isShow: ['22', '23'] }, { btn_title: '发起提交', isShow: ['22', '23'] },
{ btn_title: '查看报表', isShow: ['22', '23'] }, { btn_title: '查看报表', isShow: ['22', '23', '24', '25'] },
{ btn_title: '查看数据', isShow: ['22', '23'] } { btn_title: '查看数据', isShow: ['22', '23'] }
], ],
rules: { rules: {
@ -648,7 +771,28 @@ export default {
scrollHeight_2: 0, scrollHeight_2: 0,
scrollHeight_3: 0, scrollHeight_3: 0,
searchUserName: '', searchUserName: '',
auditingUserList: [] auditingUserList: [],
workWaitList: [],
workWaitListNew: [],
//
getWorkWaitParams: {
planTime: this.$moment().format('YYYY-MM'),
type: '1'
},
getWorkWaitParamsNew: {
planTime: this.$moment().format('YYYY-MM'),
type: '2'
},
searchProjectName: '',
getWorkWaitProjectParams: {
planTime: '',
reportType: '',
keyword: ''
},
workWaitProjectList: [],
auditingDetailsFlg: true,
isView: false
} }
}, },
mounted() { mounted() {
@ -674,14 +818,31 @@ export default {
// //
this.getControlLevelListData() this.getControlLevelListData()
//
if (this.roles == 24 || this.roles == 25) {
this.getWorkWaitListData()
}
const this_ = this const this_ = this
uni.$on('update', function () { uni.$on('update', function () {
this_.getViewDataList() this_.getViewDataList()
}) })
uni.$on('updateView', function () {
this_.onCloseViewPopup()
this_.getWorkWaitListData()
})
if (this.roles == 22 || this.roles == 23) {
this.activeIndex = '发起提交'
}
if (this.roles == 24 || this.roles == 25) {
this.activeIndex = '工作待办'
}
}, },
onUnload() { onUnload() {
uni.$off('update') uni.$off('update')
uni.$off('updateView')
}, },
methods: { methods: {
leftClick() { leftClick() {
@ -690,6 +851,10 @@ export default {
onTapCheck(i) { onTapCheck(i) {
this.activeIndex = i this.activeIndex = i
if (i == '查看报表' && (this.roles == 24 || this.roles == 25)) {
this.getReportFormList()
}
}, },
/* 减少页数 */ /* 减少页数 */
onReducePages() { onReducePages() {
@ -799,28 +964,56 @@ export default {
this.currentTime = this.$moment(this.currentTime).subtract(1, 'year').format('YYYY-MM') this.currentTime = this.$moment(this.currentTime).subtract(1, 'year').format('YYYY-MM')
this.getMonthPlanData() this.getMonthPlanData()
}, },
onReduceMonthNew() {
this.currentTimeNew = this.$moment(this.currentTimeNew).subtract(1, 'year').format('YYYY-MM')
this.getWorkWaitProjectParams.planTime = this.currentTimeNew
this.getReportFormList()
},
onReduceDay() { onReduceDay() {
this.currentTime = this.$moment(this.currentTime).subtract(1, 'months').format('YYYY-MM') this.currentTime = this.$moment(this.currentTime).subtract(1, 'months').format('YYYY-MM')
this.getMonthPlanData() this.getMonthPlanData()
}, },
onReduceDayNew() {
this.currentTimeNew = this.$moment(this.currentTimeNew).subtract(1, 'months').format('YYYY-MM')
this.getWorkWaitProjectParams.planTime = this.currentTimeNew
this.getReportFormList()
},
onAddMonth() { onAddMonth() {
this.currentTime = this.$moment(this.currentTime).add(1, 'year').format('YYYY-MM') this.currentTime = this.$moment(this.currentTime).add(1, 'year').format('YYYY-MM')
this.getMonthPlanData() this.getMonthPlanData()
}, },
onAddMonthNew() {
this.currentTimeNew = this.$moment(this.currentTimeNew).add(1, 'year').format('YYYY-MM')
this.getWorkWaitProjectParams.planTime = this.currentTimeNew
this.getReportFormList()
},
onAddDay() { onAddDay() {
this.currentTime = this.$moment(this.currentTime).add(1, 'months').format('YYYY-MM') this.currentTime = this.$moment(this.currentTime).add(1, 'months').format('YYYY-MM')
this.getMonthPlanData() this.getMonthPlanData()
}, },
onAddDayNew() {
this.currentTimeNew = this.$moment(this.currentTimeNew).add(1, 'months').format('YYYY-MM')
this.getWorkWaitProjectParams.planTime = this.currentTimeNew
this.getReportFormList()
},
onBackToday() { onBackToday() {
this.currentTime = this.$moment().format('YYYY-MM') this.currentTime = this.$moment().format('YYYY-MM')
this.getMonthPlanData() this.getMonthPlanData()
}, },
onBackTodayNew() {
this.currentTimeNew = this.$moment().format('YYYY-MM')
this.getWorkWaitProjectParams.planTime = this.currentTimeNew
this.getReportFormList()
},
iconClick() { iconClick() {
this.getViewDataList() this.getViewDataList()
}, },
onChangeCurrentData(e) { onChangeCurrentData(e) {
this.currentTime = e.detail.value this.currentTime = e.detail.value
}, },
onChangeCurrentDataNew(e) {
this.currentTimeNew = e.detail.value
},
onViewSelectProject() { onViewSelectProject() {
this.$refs.popup.open('bottom') this.$refs.popup.open('bottom')
this.popupType = 'bottom' this.popupType = 'bottom'
@ -907,13 +1100,19 @@ export default {
this.zfxAmount = 0 this.zfxAmount = 0
this.gfxAmount = 0 this.gfxAmount = 0
this.tfxAmount = 0 this.tfxAmount = 0
this.monthDataList.forEach(e => { // this.monthDataList.forEach(e => {
this.kjsAmount = this.kjsAmount + e.kjsfx * 1 // this.kjsAmount = this.kjsAmount + e.kjsfx * 1
this.dfxAmount = this.dfxAmount + e.dfx * 1 // this.dfxAmount = this.dfxAmount + e.dfx * 1
this.zfxAmount = this.zfxAmount + e.zfx * 1 // this.zfxAmount = this.zfxAmount + e.zfx * 1
this.gfxAmount = this.gfxAmount + e.gfx * 1 // this.gfxAmount = this.gfxAmount + e.gfx * 1
this.tfxAmount = this.tfxAmount + e.tgfx * 1 // this.tfxAmount = this.tfxAmount + e.tgfx * 1
}) // })
this.kjsAmount = this.monthDataList[0].kjsfx * 1
this.dfxAmount = this.monthDataList[0].dfx * 1
this.zfxAmount = this.monthDataList[0].zfx * 1
this.gfxAmount = this.monthDataList[0].gfx * 1
this.tfxAmount = this.monthDataList[0].tgfx * 1
} }
if (this.scrollHeight_2 === 0) { if (this.scrollHeight_2 === 0) {
@ -1143,6 +1342,129 @@ export default {
onCheckBoxChange(item) { onCheckBoxChange(item) {
console.log(item, '*****') console.log(item, '*****')
item.isChecked = !item.isChecked item.isChecked = !item.isChecked
},
/* 获取工作待办列表 */
async getWorkWaitListData() {
console.log('this.getWorkWaitParams', this.getWorkWaitParams)
const res = await getWorkWaitListApi(this.getWorkWaitParams)
console.log('工作待办列表', res)
this.workWaitList = res.obj
if (res.obj.length < 1) {
uni.showToast({
title: '未查询到计划!',
icon: 'none'
})
}
},
onWorkWaitTimeReduce() {
this.getWorkWaitParams.planTime = this.$moment(this.getWorkWaitParams.planTime)
.subtract(1, 'months')
.format('YYYY-MM')
this.getWorkWaitListData()
},
onWorkWaitTimeAdd() {
this.getWorkWaitParams.planTime = this.$moment(this.getWorkWaitParams.planTime).add(1, 'months').format('YYYY-MM')
this.getWorkWaitListData()
},
/* 查看工程数 */
onViewProjectNum(type) {
switch (type) {
case 1:
this.getWorkWaitProjectParams.reportType = '1'
break
case 2:
this.getWorkWaitProjectParams.reportType = '2'
break
case 3:
this.getWorkWaitProjectParams.reportType = '3'
break
case 4:
this.getWorkWaitProjectParams.reportType = '4'
break
}
if (type === 4) {
this.auditingDetailsFlg = true
this.isView = false
} else {
this.auditingDetailsFlg = false
}
this.getWorkWaitProjectParams.planTime = this.getWorkWaitParams.planTime
this.getWorkWaitProjectParams.keyword = ''
this.getWorkWaitProjectData()
this.$refs.popupViewProject.open('center')
},
/* 查看工程数 */
onViewProjectNumNew(type) {
switch (type) {
case 1:
this.getWorkWaitProjectParams.reportType = '1'
break
case 2:
this.getWorkWaitProjectParams.reportType = '2'
break
case 3:
this.getWorkWaitProjectParams.reportType = '3'
break
case 4:
this.getWorkWaitProjectParams.reportType = '4'
break
case 5:
this.getWorkWaitProjectParams.reportType = '5'
break
}
if (type === 5) {
this.auditingDetailsFlg = true
this.isView = true
} else {
this.auditingDetailsFlg = false
this.isView = false
}
this.getWorkWaitProjectParams.planTime = this.getWorkWaitParamsNew.planTime
this.getWorkWaitProjectParams.keyword = ''
this.getWorkWaitProjectData()
this.$refs.popupViewProject.open('center')
},
onSearchWorkWaitProject() {
this.getWorkWaitProjectData()
},
/* 获取工程 */
async getWorkWaitProjectData() {
const res = await getWorkWaitProjectApi(this.getWorkWaitProjectParams)
console.log('工程信息列表', res)
this.workWaitProjectList = res.obj
},
onCloseViewPopup() {
this.$refs.popupViewProject.close()
},
/* 查看审核详情 */
onViewAuditingDetails(item) {
if (this.auditingDetailsFlg) {
console.log('打开审核详情', item)
uni.navigateTo({
url: `/pages/workPlan/monthPlanAuditingDetails/inf-index?id=${item.id}&month=${this.getWorkWaitProjectParams.planTime}&isView=${this.isView}`
})
}
},
/* 获取报表数据 */
async getReportFormList() {
this.getWorkWaitParamsNew.planTime = this.currentTimeNew
console.log(this.getWorkWaitParamsNew, 'this.getWorkWaitParamsNew')
const res = await getReportFormListApi(this.getWorkWaitParamsNew)
console.log('res报表数据', res)
this.workWaitListNew = res.obj
if (res.obj.length < 1) {
uni.showToast({
title: '未查询到计划!',
icon: 'none'
})
}
} }
}, },
@ -1607,4 +1929,130 @@ export default {
} }
} }
} }
.time-select {
width: 100%;
padding: 10rpx 0;
display: flex;
align-items: center;
justify-content: space-between;
text {
font-weight: bold;
color: #000;
}
}
.view-data-auditing {
width: 100%;
margin: 10rpx auto;
background-color: #fff;
.auditing-item {
width: 98%;
margin: 0 auto;
display: flex;
align-items: center;
padding: 8rpx 0;
.item_1 {
width: 25%;
}
.item_2 {
width: 10%;
}
.item_3 {
width: 65%;
text-align: right;
text {
margin-right: 10rpx;
display: inline-block;
width: 260rpx;
height: 48rpx;
border-radius: 12rpx;
line-height: 48rpx;
text-align: center;
color: #fff;
background-color: #00337a;
}
}
}
.have-bottom {
border-bottom: 1px solid #ccc;
}
}
.popup-view {
height: 60vh;
width: 95vw;
display: flex;
flex-direction: column;
background-color: #ccc;
.popup-view-title {
width: 94%;
margin: 0 auto;
padding: 30rpx 0;
display: flex;
justify-content: space-between;
align-items: center;
text {
color: #333;
font-size: 38rpx;
font-weight: bold;
}
}
.search-container {
width: 100%;
padding: 28rpx 0;
background-color: #fff;
.search-box {
width: 94%;
margin: 0 auto;
display: flex;
justify-content: space-between;
align-items: center;
.view-search-ipt {
width: 65%;
}
.view-search-btn {
width: 27%;
height: 68rpx;
text-align: center;
line-height: 68rpx;
color: #fff;
background-color: #00337a;
border-radius: 12rpx;
}
}
}
.view-project-list {
flex: 1;
overflow: hidden;
.view-project-item {
width: 96%;
height: 96%;
margin: 2% auto;
background-color: #fff;
view {
width: 100%;
padding-top: 13rpx;
padding-bottom: 6rpx;
text-align: center;
border-bottom: 1px solid #ccc;
box-sizing: border-box;
}
}
}
}
</style> </style>

View File

@ -24,6 +24,50 @@
</button> </button>
</view> </view>
<!-- 工作待办 -->
<view v-show="activeIndex === '工作待办' && (roles == 24 || roles == 25)" class="common-style">
<view class="time-select">
<uni-icons
type="left"
size="30"
style="margin-left: 46rpx; font-weight: bold"
@tap="onWorkWaitTimeReduce"
></uni-icons>
<text>{{ getWorkWaitParams.planTime }}</text>
<uni-icons
type="right"
size="30"
style="margin-right: 46rpx; font-weight: bold"
@tap="onWorkWaitTimeAdd"
></uni-icons>
</view>
<scroll-view scroll-y>
<view class="view-data-auditing" v-for="(item, index) in workWaitList" :key="index">
<view class="auditing-item have-bottom">
<view class="item_1">在建工程</view>
<view class="item_2" @tap="onViewProjectNum(1)">{{ item.zjs }}</view>
<view class="item_3" style="text-align: right">
{{ item.planTime }}
</view>
</view>
<view class="auditing-item">
<view class="item_1">已报工程数</view>
<view class="item_2" @tap="onViewProjectNum(2)">{{ item.ybs }}</view>
<view class="item_1">未报工程数</view>
<view class="item_2" @tap="onViewProjectNum(3)">{{ item.wbs }}</view>
</view>
<view class="auditing-item">
<view class="item_1">待审核数</view>
<view class="item_2">{{ item.dsh }}</view>
<view class="item_3">
<text @tap="onViewProjectNum(4)">待审核</text>
</view>
</view>
</view>
</scroll-view>
</view>
<!-- 发起提交 --> <!-- 发起提交 -->
<view class="content-2" v-show="activeIndex === '发起提交'"> <view class="content-2" v-show="activeIndex === '发起提交'">
<view class="pages-add" id="pagesAddRef"> <view class="pages-add" id="pagesAddRef">
@ -127,7 +171,7 @@
></uni-data-select> ></uni-data-select>
<uni-datetime-picker <uni-datetime-picker
v-if="f.items_type === 'date'" v-if="f.items_type === 'date'"
type="date" type="datetime"
:clear-icon="false" :clear-icon="false"
v-model="item[f.name]" v-model="item[f.name]"
/> />
@ -153,7 +197,7 @@
</view> </view>
<!-- 查看报表 --> <!-- 查看报表 -->
<view v-show="activeIndex === '查看报表'" class="common-style"> <view v-show="activeIndex === '查看报表' && (roles == 22 || roles == 23)" class="common-style">
<view class="report-form-header" v-if="monthDataList.length > 0"> <view class="report-form-header" v-if="monthDataList.length > 0">
<view> <view>
<scroll-view scroll-x class="header-left"> <scroll-view scroll-x class="header-left">
@ -250,6 +294,50 @@
</view> </view>
</view> </view>
<!-- 查看报表审核人 -->
<view v-show="activeIndex === '查看报表' && (roles == 24 || roles == 25)" class="common-style">
<view class="icon-search-time">
<text style="fon-size: 30rpx; margin-right: 25rpx" @tap="onReduceMonthNew"></text>
<uni-icons type="left" size="20" @tap="onReduceDayNew"></uni-icons>
<view class="view-time">
<picker mode="date" @change="onChangeCurrentDataNew" v-model="currentTimeNew">
<view class="date-picker">{{ currentTimeNew }}</view>
</picker>
</view>
<uni-icons type="right" size="20" @tap="onAddDayNew"></uni-icons>
<text style="fon-size: 30rpx; margin-left: 25rpx" @tap="onAddMonthNew"></text>
<button @tap="onBackTodayNew">返回本月</button>
</view>
<scroll-view scroll-y>
<view class="view-data-auditing" v-for="(item, index) in workWaitListNew" :key="index">
<view class="auditing-item have-bottom">
<view class="item_1">在建工程</view>
<view class="item_2" @tap="onViewProjectNum(1)">{{ item.zjs }}</view>
<view class="item_3" style="text-align: right">
{{ item.planTime }}
</view>
</view>
<view class="auditing-item">
<view class="item_1">已报工程数</view>
<view class="item_2" @tap="onViewProjectNum(2)">{{ item.ybs }}</view>
<view class="item_1">未报工程数</view>
<view class="item_2" @tap="onViewProjectNum(3)">{{ item.wbs }}</view>
</view>
<view class="auditing-item">
<view class="item_1">待审核数</view>
<view class="item_2">{{ item.dsh }}</view>
<view class="item_3">
<text @tap="onViewProjectNumNew(5)">已通过</text>
</view>
</view>
</view>
</scroll-view>
</view>
<!-- 查看数据 --> <!-- 查看数据 -->
<view v-show="activeIndex === '查看数据'" class="common-style"> <view v-show="activeIndex === '查看数据'" class="common-style">
<uni-easyinput <uni-easyinput
@ -411,6 +499,35 @@
</view> </view>
</view> </view>
</uni-popup> </uni-popup>
<!-- 弹框 查看工程 -->
<uni-popup ref="popupViewProject" background-color="#fff">
<view class="popup-view">
<view class="popup-view-title">
<text>查看工程</text>
<uni-icons type="closeempty" size="32" @tap="onCloseViewPopup"></uni-icons>
</view>
<view class="search-container">
<view class="search-box">
<view class="view-search-ipt">
<uni-easyinput
:clear="false"
type="text"
placeholder="请输入关键字"
v-model="getWorkWaitProjectParams.keyword"
/>
</view>
<view class="view-search-btn" @tap="onSearchWorkWaitProject">搜索</view>
</view>
</view>
<view class="view-project-list">
<scroll-view :scroll-y="true" class="view-project-item">
<view v-for="item in workWaitProjectList" :key="item.id">{{ item.proName }}</view>
</scroll-view>
</view>
</view>
</uni-popup>
</view> </view>
</template> </template>
@ -427,7 +544,11 @@ import {
getControlModeProApi, getControlModeProApi,
getControlLevelListApi, getControlLevelListApi,
getIsPlanProApi, getIsPlanProApi,
getAUditingUserInfoApi getAUditingUserInfoApi,
getWorkWaitListProApi,
getWorkWaitProjectProApi,
setAuditingRejectProApi,
getReportFormListProApi
} from '../../../api/workPlan/monthPlan' } from '../../../api/workPlan/monthPlan'
export default { export default {
components: { components: {
@ -435,7 +556,7 @@ export default {
}, },
data() { data() {
return { return {
activeIndex: '发起提交', activeIndex: '',
DateValue: this.$moment().format('YYYY-MM'), DateValue: this.$moment().format('YYYY-MM'),
pagesTotal: 1, pagesTotal: 1,
currentPage: 0, currentPage: 0,
@ -444,10 +565,11 @@ export default {
formData: {}, formData: {},
isType: false, isType: false,
currentTime: this.$moment().format('YYYY-MM'), currentTime: this.$moment().format('YYYY-MM'),
currentTimeNew: this.$moment().format('YYYY-MM'),
btnList: [ btnList: [
{ btn_title: '工作待办', isShow: ['24', '25'] }, { btn_title: '工作待办', isShow: ['24', '25'] },
{ btn_title: '发起提交', isShow: ['22', '23'] }, { btn_title: '发起提交', isShow: ['22', '23'] },
{ btn_title: '查看报表', isShow: ['22', '23'] }, { btn_title: '查看报表', isShow: ['22', '23', '24', '25'] },
{ btn_title: '查看数据', isShow: ['22', '23'] } { btn_title: '查看数据', isShow: ['22', '23'] }
], ],
monthPlanFormRules: { monthPlanFormRules: {
@ -693,7 +815,27 @@ export default {
scrollHeight_2: 0, scrollHeight_2: 0,
scrollHeight_3: 0, scrollHeight_3: 0,
searchUserName: '', searchUserName: '',
auditingUserList: [] auditingUserList: [],
workWaitList: [],
workWaitListNew: [],
//
getWorkWaitParams: {
planTime: this.$moment().format('YYYY-MM'),
type: '1'
},
getWorkWaitParamsNew: {
planTime: this.$moment().format('YYYY-MM'),
type: '2'
},
getWorkWaitProjectParams: {
planTime: '',
reportType: '',
keyword: ''
},
searchProjectName: '',
workWaitProjectList: [],
auditingDetailsFlg: false,
isView: false
} }
}, },
mounted() { mounted() {
@ -721,14 +863,32 @@ export default {
// //
this.getWorkTypeAndControlMode() this.getWorkTypeAndControlMode()
//
if (this.roles == 24 || this.roles == 25) {
this.getWorkWaitListData()
}
const this_ = this const this_ = this
uni.$on('update', function () { uni.$on('update', function () {
this_.getViewDataList() this_.getViewDataList()
}) })
uni.$on('updateView', function () {
this_.onCloseViewPopup()
this_.getWorkWaitListData()
})
console.log(this.roles, 'this.roles ')
if (this.roles == 22 || this.roles == 23) {
this.activeIndex = '发起提交'
}
if (this.roles == 24 || this.roles == 25) {
this.activeIndex = '工作待办'
}
}, },
onUnload() { onUnload() {
uni.$off('update') uni.$off('update')
uni.$off('updateView')
}, },
methods: { methods: {
leftClick() { leftClick() {
@ -952,13 +1112,18 @@ export default {
this.zfxAmount = 0 this.zfxAmount = 0
this.gfxAmount = 0 this.gfxAmount = 0
this.tfxAmount = 0 this.tfxAmount = 0
this.monthDataList.forEach(e => { // this.monthDataList.forEach(e => {
this.kjsAmount = this.kjsAmount + e.kjsfx * 1 // this.kjsAmount = this.kjsAmount + e.kjsfx * 1
this.dfxAmount = this.dfxAmount + e.dfx * 1 // this.dfxAmount = this.dfxAmount + e.dfx * 1
this.zfxAmount = this.zfxAmount + e.zfx * 1 // this.zfxAmount = this.zfxAmount + e.zfx * 1
this.gfxAmount = this.gfxAmount + e.gfx * 1 // this.gfxAmount = this.gfxAmount + e.gfx * 1
this.tfxAmount = this.tfxAmount + e.tgfx * 1 // this.tfxAmount = this.tfxAmount + e.tgfx * 1
}) // })
this.kjsAmount = this.monthDataList[0].kjsfx * 1
this.dfxAmount = this.monthDataList[0].dfx * 1
this.zfxAmount = this.monthDataList[0].zfx * 1
this.gfxAmount = this.monthDataList[0].gfx * 1
this.tfxAmount = this.monthDataList[0].tgfx * 1
} }
if (this.scrollHeight_2 === 0) { if (this.scrollHeight_2 === 0) {
@ -1211,6 +1376,159 @@ export default {
onCheckBoxChange(item) { onCheckBoxChange(item) {
console.log(item, '*****') console.log(item, '*****')
item.isChecked = !item.isChecked item.isChecked = !item.isChecked
},
/* 获取工作待办列表 */
async getWorkWaitListData() {
console.log('this.getWorkWaitParams', this.getWorkWaitParams)
const res = await getWorkWaitListProApi(this.getWorkWaitParams)
console.log('工作待办列表', res)
this.workWaitList = res.obj
if (res.obj.length < 1) {
uni.showToast({
title: '未查询到计划!',
icon: 'none'
})
}
},
onWorkWaitTimeReduce() {
this.getWorkWaitParams.planTime = this.$moment(this.getWorkWaitParams.planTime)
.subtract(1, 'months')
.format('YYYY-MM')
this.getWorkWaitListData()
},
onWorkWaitTimeAdd() {
this.getWorkWaitParams.planTime = this.$moment(this.getWorkWaitParams.planTime).add(1, 'months').format('YYYY-MM')
this.getWorkWaitListData()
},
onViewProjectNum(type) {
switch (type) {
case 1:
// console.log('')
this.getWorkWaitProjectParams.reportType = '1'
break
case 2:
// console.log('')
this.getWorkWaitProjectParams.reportType = '2'
break
case 3:
// console.log('')
this.getWorkWaitProjectParams.reportType = '3'
break
case 4:
// console.log('')
this.getWorkWaitProjectParams.reportType = '4'
break
}
if (type === 4) {
this.auditingDetailsFlg = true
this.isView = false
} else {
this.auditingDetailsFlg = false
}
this.getWorkWaitProjectParams.planTime = this.getWorkWaitParams.planTime
this.getWorkWaitProjectParams.keyword = ''
this.getWorkWaitProjectData()
this.$refs.popupViewProject.open('center')
},
/* 查看工程数 */
onViewProjectNumNew(type) {
switch (type) {
case 1:
this.getWorkWaitProjectParams.reportType = '1'
break
case 2:
this.getWorkWaitProjectParams.reportType = '2'
break
case 3:
this.getWorkWaitProjectParams.reportType = '3'
break
case 4:
this.getWorkWaitProjectParams.reportType = '4'
break
case 5:
this.getWorkWaitProjectParams.reportType = '5'
break
}
if (type === 5) {
this.auditingDetailsFlg = true
this.isView = true
} else {
this.auditingDetailsFlg = false
this.isView = false
}
this.getWorkWaitProjectParams.planTime = this.getWorkWaitParamsNew.planTime
this.getWorkWaitProjectParams.keyword = ''
this.getWorkWaitProjectData()
this.$refs.popupViewProject.open('center')
},
onSearchWorkWaitProject() {
this.getWorkWaitProjectData()
},
/* 获取工程 */
async getWorkWaitProjectData() {
const res = await getWorkWaitProjectProApi(this.getWorkWaitProjectParams)
console.log('工程信息列表', res)
this.workWaitProjectList = res.obj
},
onCloseViewPopup() {
this.$refs.popupViewProject.close()
},
/* 查看审核详情 */
onViewAuditingDetails(item) {
if (this.auditingDetailsFlg) {
console.log('打开审核详情', item)
uni.navigateTo({
url: `/pages/workPlan/monthPlanAuditingDetails/pro-index?id=${item.id}&month=${this.getWorkWaitProjectParams.planTime}&isView=${this.isView}`
})
}
},
/* 获取报表数据 */
async getReportFormList() {
this.getWorkWaitParamsNew.planTime = this.currentTimeNew
console.log(this.getWorkWaitParamsNew, 'this.getWorkWaitParamsNew')
const res = await getReportFormListProApi(this.getWorkWaitParamsNew)
console.log('res报表数据', res)
this.workWaitListNew = res.obj
if (res.obj.length < 1) {
uni.showToast({
title: '未查询到计划!',
icon: 'none'
})
}
},
onReduceMonthNew() {
this.currentTimeNew = this.$moment(this.currentTimeNew).subtract(1, 'year').format('YYYY-MM')
this.getWorkWaitProjectParams.planTime = this.currentTimeNew
this.getReportFormList()
},
onReduceDayNew() {
this.currentTimeNew = this.$moment(this.currentTimeNew).subtract(1, 'months').format('YYYY-MM')
this.getWorkWaitProjectParams.planTime = this.currentTimeNew
this.getReportFormList()
},
onChangeCurrentDataNew(e) {
this.currentTimeNew = e.detail.value
},
onAddDayNew() {
this.currentTimeNew = this.$moment(this.currentTimeNew).add(1, 'months').format('YYYY-MM')
this.getWorkWaitProjectParams.planTime = this.currentTimeNew
this.getReportFormList()
},
onAddMonthNew() {
this.currentTimeNew = this.$moment(this.currentTimeNew).add(1, 'year').format('YYYY-MM')
this.getWorkWaitProjectParams.planTime = this.currentTimeNew
this.getReportFormList()
},
onBackTodayNew() {
this.currentTimeNew = this.$moment().format('YYYY-MM')
this.getWorkWaitProjectParams.planTime = this.currentTimeNew
this.getReportFormList()
} }
}, },
@ -1674,4 +1992,58 @@ export default {
} }
} }
} }
.time-select {
width: 100%;
padding: 10rpx 0;
display: flex;
align-items: center;
justify-content: space-between;
text {
font-weight: bold;
color: #000;
}
}
.view-data-auditing {
width: 100%;
margin: 10rpx auto;
background-color: #fff;
.auditing-item {
width: 98%;
margin: 0 auto;
display: flex;
align-items: center;
padding: 8rpx 0;
.item_1 {
width: 25%;
}
.item_2 {
width: 10%;
}
.item_3 {
width: 65%;
text-align: right;
text {
margin-right: 10rpx;
display: inline-block;
width: 260rpx;
height: 48rpx;
border-radius: 12rpx;
line-height: 48rpx;
text-align: center;
color: #fff;
background-color: #00337a;
}
}
}
.have-bottom {
border-bottom: 1px solid #ccc;
}
}
</style> </style>

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@ -78,16 +78,17 @@
<!-- 项目部 <!-- 项目部
<text class="type-icon">x</text> --> <text class="type-icon">x</text> -->
<image :src="item.imgSrcList[0]" mode="'scaleToFill'"></image> <image :src="item.imgSrcList[item.imgSrcIndex]" mode="'scaleToFill'"></image>
</view> </view>
<view> <view class="box-2">
<text class="text_1">{{ item.process }}</text> <text class="text_1">{{ item.process }}</text>
<text class="text_2"> <view class="text_2" v-for="(j, k) in item.auditingInfo" :key="k">
<text>{{ item.userName }}</text> <text>{{ j.operateUser }}</text>
<text v-if="index !== 0" style="margin-left: 100rpx">{{ item.auditingResult }}</text> <text v-if="index !== 0">{{ j.operateResult }}</text>
</text> <text v-if="index !== 0">{{ j.operateTime }}</text>
</view>
</view> </view>
<view>{{ item.time }}</view> <view v-if="index == 0" class="box-3">{{ item.auditingInfo[0].operateTime || '' }}</view>
</view> </view>
<view class="line" v-if="index !== 2"> <view class="line" v-if="index !== 2">
@ -360,28 +361,41 @@ export default {
roles: uni.getStorageSync('wkRole'), roles: uni.getStorageSync('wkRole'),
processList: [ processList: [
{ {
title: '项目部',
process: '发起申请', process: '发起申请',
userName: '', userName: '',
time: '', time: '',
auditingResult: '', auditingResult: '',
imgSrcList: ['../../../static/images/workPlan/xmb_dd.png', '../../../static/images/workPlan/xmb_dsh.png'] imgSrcIndex: 0,
auditingInfo: [],
imgSrcList: ['../../../static/images/workPlan/xmb_dd.png', ' ', '../../../static/images/workPlan/xmb_tg.png']
}, },
{ {
title: '项目部',
process: '审核人', process: '审核人',
userName: '', userName: '',
time: '2', time: '2',
auditingResult: '', auditingResult: '',
imgSrcList: ['../../../static/images/workPlan/xmb_dd.png', '../../../static/images/workPlan/xmb_dsh.png'] imgSrcIndex: 0,
auditingInfo: [],
imgSrcList: [
'../../../static/images/workPlan/fgs_dsh.png',
'../../../static/images/workPlan/fgs_wtg.png',
'../../../static/images/workPlan/fgs_tg.png',
'../../../static/images/workPlan/fgs_dd.png'
]
}, },
{ {
title: '项目部',
process: '审核人', process: '审核人',
userName: '', userName: '',
time: '', time: '',
imgSrcIndex: 0,
auditingResult: '未通过', auditingResult: '未通过',
imgSrcList: ['../../../static/images/workPlan/xmb_dd.png', '../../../static/images/workPlan/xmb_dsh.png'] auditingInfo: [],
imgSrcList: [
'../../../static/images/workPlan/zgs_dsh.png',
'../../../static/images/workPlan/zgs_wtg.png',
'../../../static/images/workPlan/zgs_tg.png',
'../../../static/images/workPlan/zgs_dd.png'
]
} }
], ],
searchUserName: '', searchUserName: '',
@ -524,18 +538,70 @@ export default {
console.log('paramsparams参数', params) console.log('paramsparams参数', params)
const res = await getAUditingProcessApi(params) const res = await getAUditingProcessApi(params)
console.log('res审核流程', res)
const auditingList = res.obj.splice(1, 3) res.obj.forEach(e => {
console.log('res---审核流程图', auditingList) if (e.type == 2) {
this.processList[0].auditingInfo.push({
// this.processList[0].userName = auditingList[0].upUser operateTime: e.upTime,
auditingList.forEach((e, index) => { operateUser: e.upUser,
this.processList[index].userName = e.upUser operateResult: e.state
this.processList[index].time = e.upTime })
this.processList[index].auditingResult = e.state }
if (e.type == 3) {
this.processList[1].auditingInfo.push({
operateTime: e.upTime,
operateUser: e.upUser,
operateResult: e.state
})
}
if (e.type == 4) {
this.processList[2].auditingInfo.push({
operateTime: e.upTime,
operateUser: e.upUser,
operateResult: e.state
})
}
}) })
console.log('this.this.processList', this.processList) this.processList.forEach((e, index) => {
console.log('e.auditingInfo', e.auditingInfo, 'e.auditingInfo')
if (index === 0) {
if (e.auditingInfo[e.auditingInfo.length - 1].operateTime) {
e.imgSrcIndex = 2
} else {
e.imgSrcIndex = 0
}
}
if (index === 1) {
if (e.auditingInfo[e.auditingInfo.length - 1].operateResult == '待审核') {
e.imgSrcIndex = 0
}
if (e.auditingInfo[e.auditingInfo.length - 1].operateResult == '未通过') {
e.imgSrcIndex = 1
}
if (e.auditingInfo[e.auditingInfo.length - 1].operateResult == '通过') {
e.imgSrcIndex = 2
}
if (e.auditingInfo[e.auditingInfo.length - 1].operateResult == null) {
e.imgSrcIndex = 3
}
}
if (index === 2) {
if (e.auditingInfo[e.auditingInfo.length - 1].operateResult == '待审核') {
e.imgSrcIndex = 0
}
if (e.auditingInfo[e.auditingInfo.length - 1].operateResult == '未通过') {
e.imgSrcIndex = 1
}
if (e.auditingInfo[e.auditingInfo.length - 1].operateResult == '通过') {
e.imgSrcIndex = 2
}
if (e.auditingInfo[e.auditingInfo.length - 1].operateResult == null) {
e.imgSrcIndex = 3
}
}
})
} }
}, },
/* 复选框事件 */ /* 复选框事件 */
@ -573,14 +639,16 @@ export default {
let idsStr = ids.filter(e => e != null).join(',') let idsStr = ids.filter(e => e != null).join(',')
const params = { const params = {
id: JSON.stringify(this.monthDetailsList), id: this.proId,
user: idsStr, user: idsStr
state: '2' // state: '2'
} }
console.log('saveParams保存参数', params) console.log('saveParams保存参数', params)
const result = await setMonthPlanApi(params) const result = await submitPlanApi(params)
console.log(result, 'results上报人提交结果')
if (result.res == 1) { if (result.res == 1) {
uni.showToast({ title: `提交成功!`, icon: 'none' }) uni.showToast({ title: `提交成功!`, icon: 'none' })
setTimeout(() => { setTimeout(() => {
@ -732,7 +800,7 @@ export default {
background-color: green; background-color: green;
} }
} }
.process-item view:nth-child(2) { .process-item .box-2 {
flex: 1; flex: 1;
padding-left: 26rpx; padding-left: 26rpx;
display: flex; display: flex;
@ -745,14 +813,16 @@ export default {
.text_2 { .text_2 {
width: 100%; width: 100%;
display: flex; display: flex;
// display: block;
justify-content: space-between; justify-content: space-between;
align-items: center;
margin-top: 16rpx; margin-top: 16rpx;
font-size: 24rpx; font-size: 24rpx;
color: #000; color: #000;
} }
} }
.process-item view:last-child { .process-item .box-3 {
width: 30%; width: 30%;
font-size: 22rpx; font-size: 22rpx;
color: #333; color: #333;

View File

@ -145,7 +145,8 @@ import {
getControlLevelListApi, getControlLevelListApi,
updateInfPlanContentProApi, updateInfPlanContentProApi,
getAUditingUserInfoApi, getAUditingUserInfoApi,
setMonthPlanProApi setMonthPlanProApi,
getAUditingProcessApi
} from '../../../api/workPlan/monthPlan' } from '../../../api/workPlan/monthPlan'
export default { export default {
data() { data() {
@ -279,7 +280,46 @@ export default {
tfxAmount: 0, tfxAmount: 0,
navHeight: 0, navHeight: 0,
searchUserName: '', searchUserName: '',
auditingUserList: [] auditingUserList: [],
processList: [
{
process: '发起申请',
userName: '',
time: '',
auditingResult: '',
imgSrcIndex: 0,
auditingInfo: [],
imgSrcList: ['../../../static/images/workPlan/xmb_dd.png', ' ', '../../../static/images/workPlan/xmb_tg.png']
},
{
process: '审核人',
userName: '',
time: '2',
auditingResult: '',
imgSrcIndex: 0,
auditingInfo: [],
imgSrcList: [
'../../../static/images/workPlan/fgs_dsh.png',
'../../../static/images/workPlan/fgs_wtg.png',
'../../../static/images/workPlan/fgs_tg.png',
'../../../static/images/workPlan/fgs_dd.png'
]
},
{
process: '审核人',
userName: '',
time: '',
imgSrcIndex: 0,
auditingResult: '未通过',
auditingInfo: [],
imgSrcList: [
'../../../static/images/workPlan/zgs_dsh.png',
'../../../static/images/workPlan/zgs_wtg.png',
'../../../static/images/workPlan/zgs_tg.png',
'../../../static/images/workPlan/zgs_dd.png'
]
}
]
} }
}, },
methods: { methods: {
@ -465,6 +505,81 @@ export default {
} else { } else {
uni.showToast({ title: `提交失败!`, icon: 'none' }) uni.showToast({ title: `提交失败!`, icon: 'none' })
} }
},
/* 获取详细审核流程 */
async getAUditingProcessData() {
if (this.roles != '22') {
const params = {
id: this.proId
}
console.log('paramsparams参数', params)
const res = await getAUditingProcessApi(params)
console.log('res审核流程', res)
res.obj.forEach(e => {
if (e.type == 2) {
this.processList[0].auditingInfo.push({
operateTime: e.upTime,
operateUser: e.upUser,
operateResult: e.state
})
}
if (e.type == 3) {
this.processList[1].auditingInfo.push({
operateTime: e.upTime,
operateUser: e.upUser,
operateResult: e.state
})
}
if (e.type == 4) {
this.processList[2].auditingInfo.push({
operateTime: e.upTime,
operateUser: e.upUser,
operateResult: e.state
})
}
})
this.processList.forEach((e, index) => {
console.log('e.auditingInfo', e.auditingInfo, 'e.auditingInfo')
if (index === 0) {
if (e.auditingInfo[0].operateTime) {
e.imgSrcIndex = 2
} else {
e.imgSrcIndex = 0
}
}
if (index === 1) {
if (e.auditingInfo[e.auditingInfo.length - 1].operateResult == '待审核') {
e.imgSrcIndex = 0
}
if (e.auditingInfo[e.auditingInfo.length - 1].operateResult == '未通过') {
e.imgSrcIndex = 1
}
if (e.auditingInfo[e.auditingInfo.length - 1].operateResult == '通过') {
e.imgSrcIndex = 2
}
if (e.auditingInfo[e.auditingInfo.length - 1].operateResult == null) {
e.imgSrcIndex = 3
}
}
if (index === 2) {
if (e.auditingInfo[e.auditingInfo.length - 1].operateResult == '待审核') {
e.imgSrcIndex = 0
}
if (e.auditingInfo[e.auditingInfo.length - 1].operateResult == '未通过') {
e.imgSrcIndex = 1
}
if (e.auditingInfo[e.auditingInfo.length - 1].operateResult == '通过') {
e.imgSrcIndex = 2
}
if (e.auditingInfo[e.auditingInfo.length - 1].operateResult == null) {
e.imgSrcIndex = 3
}
}
})
}
} }
}, },

View File

@ -53,8 +53,9 @@ export default {
isShow: ['23', '24', '25'] isShow: ['23', '24', '25']
} }
], ],
roles: uni.getStorageSync('wkRole'),
title: '填报' title: '',
roles: uni.getStorageSync('wkRole')
} }
}, },
methods: { methods: {
@ -62,14 +63,14 @@ export default {
uni.navigateTo({ url: `${url}` }) uni.navigateTo({ url: `${url}` })
} }
}, },
onLoad() { mounted() {
if (this.roles === '22') { if (this.roles == 22) {
this.title = '填报' this.title = '填报'
} }
if (this.roles === '23') { if (this.roles == 23) {
this.title = '上报' this.title = '上报'
} }
if (this.roles === '24' || this.roles === '25') { if (this.roles == 24 || this.roles == 25) {
this.title = '审核' this.title = '审核'
} }
} }

View File

@ -62,14 +62,14 @@ export default {
uni.navigateTo({ url: `${url}?type=2` }) uni.navigateTo({ url: `${url}?type=2` })
} }
}, },
onLoad() { mounted() {
if (this.roles === '22') { if (this.roles == 22) {
this.title = '填报' this.title = '填报'
} }
if (this.roles === '23') { if (this.roles == 23) {
this.title = '上报' this.title = '上报'
} }
if (this.roles === '24' || this.roles === '25') { if (this.roles == 24 || this.roles == 25) {
this.title = '审核' this.title = '审核'
} }
} }

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.4 KiB