考核考评

This commit is contained in:
cclu 2023-05-19 11:02:28 +08:00
parent 51a9802407
commit 7d82886d77
2 changed files with 106 additions and 43 deletions

View File

@ -336,10 +336,23 @@ function handleReduceAMonth(nowTime,newTime){
let howDay = this.getThisMonthDay(`${y}-${m}`) let howDay = this.getThisMonthDay(`${y}-${m}`)
let newHowDay = this.getThisMonthDay(`${newY}-${newM}`) let newHowDay = this.getThisMonthDay(`${newY}-${newM}`)
console.log('d',d)
if (d === howDay){ console.log('newHowDay',newHowDay)
const nowDate = new Date()
let nowM =nowDate.getMonth() + 1
let nowD = nowDate.getDate()
console.log('nowD',nowD)
if (d === newHowDay){
if (d<nowD){
console.log('111',`${y}-${newM}-${newHowDay}`) console.log('111',`${y}-${newM}-${newHowDay}`)
return `${newY}-${newM}-${newHowDay}` return `${newY}-${newM}-${newHowDay}`
}else{
if (newM===nowM){
return `${newY}-${newM}-${nowD}`
}else{
return `${newY}-${newM}-${newHowDay}`
}
}
}else{ }else{
if (newM===2){ if (newM===2){
if (d>newHowDay){ if (d>newHowDay){
@ -350,8 +363,26 @@ function handleReduceAMonth(nowTime,newTime){
return `${newY}-${newM}-${d}` return `${newY}-${newM}-${d}`
} }
}else{ }else{
console.log('nowD',nowD)
console.log('d',d)
if (nowD<d){
if (nowM===newM){
console.log('3333',`${y}-${newM}-${nowD}`)
return `${newY}-${newM}-${nowD}`
}else{
if (d<newHowDay){
console.log('333',`${y}-${newM}-${d}`) console.log('333',`${y}-${newM}-${d}`)
return `${newY}-${newM}-${d}` return `${newY}-${newM}-${d}`
}else{
console.log('333',`${y}-${newM}-${newHowDay}`)
return `${newY}-${newM}-${newHowDay}`
}
}
}else {
console.log('333',`${y}-${newM}-${d}`)
return `${newY}-${newM}-${d}`
}
} }
} }
} }

View File

@ -136,6 +136,11 @@
<span class="text">{{item.list[0].SERVERPARTList[0].MEETING_PLACE}}</span> <span class="text">{{item.list[0].SERVERPARTList[0].MEETING_PLACE}}</span>
</view> </view>
</view> </view>
<view class="noDataItem" v-if="!item.list[0].SERVERPARTList[0].MEETING_PERSONS && !item.list[0].SERVERPARTList[0].MEETING_CONTENT">
<image class="img" src="https://eshangtech.com/ShopICO/ahyd-BID/examine/noData.svg"></image>
<p class="text">暂无会议内容</p>
</view>
<view v-else>
<view class="detail"> <view class="detail">
<view class="message" style="margin-bottom: 6px"> <view class="message" style="margin-bottom: 6px">
<image class="icon" src="https://eshangtech.com/ShopICO/ahyd-BID/examine/time.svg"></image> <image class="icon" src="https://eshangtech.com/ShopICO/ahyd-BID/examine/time.svg"></image>
@ -155,13 +160,14 @@
</view> </view>
</view> </view>
</view> </view>
</view>
</view> </view>
<view class="noData" v-else> <view class="noData" v-else>
<image class="img" src="https://eshangtech.com/ShopICO/ahyd-BID/examine/noData.svg"></image> <image class="img" src="https://eshangtech.com/ShopICO/ahyd-BID/examine/noData.svg"></image>
<p class="text">暂无数据</p> <p class="text">暂无数据</p>
</view> </view>
</view> </view>
</view> </view>
<uniPopup type="bottom" :round="true" :show="showPop" @hidePopup="hidePopup"> <uniPopup type="bottom" :round="true" :show="showPop" @hidePopup="hidePopup">
@ -294,7 +300,7 @@ export default {
this.current='item'+month this.current='item'+month
// //
this.selectDate = `${year}-${month}-${day}` this.selectDate = `${year}-${month}-${day}`
this.currentDate = 'item'+`${year}-${month}-${day}` this.currentDate = 'item'+`${year}-${month}-${day - 4>0?day - 4:1}`
}, },
// //
handleShowPopup(value,obj){ handleShowPopup(value,obj){
@ -346,27 +352,27 @@ export default {
let howDay = this.$util.getThisMonthDay(`${y}-${this.selectMonth}`) let howDay = this.$util.getThisMonthDay(`${y}-${this.selectMonth}`)
this.searchTime = `${y}-${this.selectMonth}-${howDay}` this.searchTime = `${y}-${this.selectMonth}-${howDay}`
} }
//
this.dateList = this.$util.getThisMonthDateList(`${y}-${this.selectMonth}`)
//
this.selectDate = this.$util.handleReduceAMonth(`${this.selectDate}`,`${y}-${this.selectMonth}`)
//
const selectTime = new Date(this.selectDate)
let selectY = selectTime.getFullYear()
let selectM = selectTime.getMonth() + 1
let selectD = selectTime.getDate() - 4>0?selectTime.getDate() - 4:1
this.currentDate = 'item' + `${selectY}-${selectM}-${selectD}`
if (this.selectTab===1){ if (this.selectTab===1){
// //
this.getManagerList() this.getManagerList()
}else if (this.selectTab===2){ }else if (this.selectTab===2){
// //
//
this.dateList = this.$util.getThisMonthDateList(`${y}-${this.selectMonth}`)
//
this.selectDate = this.$util.handleReduceAMonth(`${this.selectDate}`,`${y}-${this.selectMonth}`)
//
this.currentDate = 'item'+this.selectDate
// //
this.getDailyInspectionList() this.getDailyInspectionList()
}else if(this.selectTab===3){ }else if(this.selectTab===3){
// //
//
this.dateList = this.$util.getThisMonthDateList(`${y}-${this.selectMonth}`)
//
this.selectDate = this.$util.handleReduceAMonth(`${this.selectDate}`,`${y}-${this.selectMonth}`)
//
this.currentDate = 'item'+this.selectDate
// //
this.getMeetingDetail() this.getMeetingDetail()
} }
@ -397,16 +403,20 @@ export default {
}, },
// //
handleChangeDate(value){ handleChangeDate(value){
const date = new Date(this.lastDay) let time = `${value.split('-')[0]}-${value.split('-')[1]<10?'0'+value.split('-')[1]:value.split('-')[1]}-${value.split('-')[2]}`
const date = new Date()
let m = date.getMonth() +1
let d = date.getDate() let d = date.getDate()
const selectDay = new Date(value) const selectDay = new Date(time)
let selectM = selectDay.getMonth() +1
let selectd = selectDay.getDate() let selectd = selectDay.getDate()
if (d<selectd){ if (d<selectd && m<=selectM){
uni.showToast({ uni.showModal({
title: '时间还未到,不可选择', title: `日常巡检仅支持查看${m}${d}号及之前的数据`,
icon: 'none' icon:'none',
showCancel: false,
duration:3000
}) })
}else{ }else{
this.selectDate = value this.selectDate = value
// 2 // 2
@ -519,6 +529,7 @@ export default {
.main{ .main{
width: 100%; width: 100%;
height: calc(100vh + 105px); height: calc(100vh + 105px);
background: #fff;
.heard{ .heard{
width: 100%; width: 100%;
height: 185px; height: 185px;
@ -988,6 +999,25 @@ export default {
} }
} }
} }
.noDataItem{
width: 100%;
display: flex;
flex-direction: column;
justify-content: center;
align-items: center;
margin-top: 6px;
.img{
width: 80px;
height: 80px;
}
.text{
text-align: center;
font-size: 14px;
font-family: PingFangSC-Regular, PingFang SC;
font-weight: 400;
color: #A69E9F;
}
}
.detail{ .detail{
margin-top: 12px; margin-top: 12px;
.message{ .message{
@ -1177,6 +1207,8 @@ export default {
} }
.meetList{ .meetList{
margin-top: 16px; margin-top: 16px;
height: calc(60vh - 80px);
overflow-y: scroll;
.message{ .message{
display: flex; display: flex;
align-items: flex-start; align-items: flex-start;