2025/03/07 时间为空得时候不现实

pet-2.0
zhaohongyu 2025-03-07 14:40:41 +08:00
parent 4659117213
commit 67b89b4574
1 changed files with 6 additions and 2 deletions

View File

@ -2,7 +2,7 @@
<view class="content">
<u-cell-group>
<u-cell title="重点工程名称" :value="info.OUTSOURCED_NAME"/>
<u-cell title="计划工期" :value="info.STARTTIME+ '至'+ info.ENDTIME"/>
<u-cell title="计划工期" :value="formattedDuration"/>
<u-cell title="合同号" :value="info.CONTRACT_NUM"/>
<u-cell title="施工相关方" :value="info.UNITS_NAME"/>
<u-cell title="相关方单位工程负责人" :value="info.UNITS_PIC_NAME"/>
@ -50,7 +50,8 @@ export default {
popupShow: false,
videoShow: false,
videoSrc: '',
anniuShow: false
anniuShow: false,
formattedDuration: ''
}
},
computed: {
@ -74,6 +75,9 @@ export default {
if(this.userInfo.USER_ID == this.info.CREATOR){
this.anniuShow = true;
}
const start = this.info.STARTTIME || ''
const end = this.info.ENDTIME || ''
this.formattedDuration = (start || end) ? `${start}${end}` : '';
},
//
fnBack() {