fixing check token auth
This commit is contained in:
parent
46d561b43b
commit
a5fbf5c880
3 changed files with 36 additions and 16 deletions
|
|
@ -45,20 +45,23 @@ async function fetchNotifications(index: number, type: string) {
|
|||
if (type === 'DEL') {
|
||||
notiList.value = []
|
||||
}
|
||||
response.map((e: Noti) => {
|
||||
list.push({
|
||||
id: e.id,
|
||||
sender:
|
||||
e.createdFullName == '' || e.createdFullName == null
|
||||
? 'เจ้าหน้าที่'[0]
|
||||
: e.createdFullName[0],
|
||||
body: e.body ?? '',
|
||||
timereceive: e.receiveDate,
|
||||
isOpen: e.isOpen,
|
||||
|
||||
if (response.length === 0) {
|
||||
response.map((e: Noti) => {
|
||||
list.push({
|
||||
id: e.id,
|
||||
sender:
|
||||
e.createdFullName == '' || e.createdFullName == null
|
||||
? 'เจ้าหน้าที่'[0]
|
||||
: e.createdFullName[0],
|
||||
body: e.body ?? '',
|
||||
timereceive: e.receiveDate,
|
||||
isOpen: e.isOpen,
|
||||
})
|
||||
})
|
||||
})
|
||||
notiList.value.push(...list)
|
||||
statusLoad.value = totalNotiList.value === 0 ? true : false
|
||||
notiList.value.push(...list)
|
||||
statusLoad.value = totalNotiList.value === 0 ? true : false
|
||||
}
|
||||
})
|
||||
// .catch((err) => {
|
||||
// messageError($q, err)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue