|
@@ -77,11 +77,15 @@ export default {
|
|
|
const messageDatas = [...returnData]
|
|
|
messageDatas.map(item => {
|
|
|
const { dataObjectId } = item
|
|
|
- const len = dataObjectId.length
|
|
|
- const popNums = [206, 207, 208, 209, 210, 211, 212, 213, 214].map(item => item.toString())
|
|
|
- const target = dataObjectId.substring(len - 3, len)
|
|
|
- const place = popNums.includes(target) ? '(广州)' : '(国航)'
|
|
|
- item.readTime = item.readTime.replace('T', ' ') + place
|
|
|
+ if (dataObjectId?.length) {
|
|
|
+ const len = dataObjectId.length
|
|
|
+ const popNums = [100, 101, 102].map(item => item.toString())
|
|
|
+ const target = dataObjectId.substring(len - 3, len)
|
|
|
+ const place = popNums.includes(target) ? '(国航)' : '(广州)'
|
|
|
+ item.readTime = item.readTime.replace('T', ' ') + place
|
|
|
+ } else {
|
|
|
+ item.readTime = item.readTime.replace('T', ' ') + '(广州)'
|
|
|
+ }
|
|
|
})
|
|
|
this.messageList = messageDatas
|
|
|
// this.messageList = returnData.map(message => ({
|