Friendship Accepted and Refused (notification updated)
This commit is contained in:
@@ -5,6 +5,7 @@ import { useGlobalStore } from '@store/globalStore'
|
||||
import { useProducts } from '@store/Products'
|
||||
import { serv_constants } from '@store/Modules/serv_constants'
|
||||
import { tools } from '@store/Modules/tools'
|
||||
import { shared_consts } from '@src/common/shared_vuejs'
|
||||
|
||||
// You can declare a mixin as the same style as components.
|
||||
export default function () {
|
||||
@@ -156,9 +157,20 @@ export default function () {
|
||||
return ris
|
||||
}
|
||||
|
||||
function getNotifText(notif: INotif) {
|
||||
function getNotifText($t: any, notif: INotif) {
|
||||
|
||||
let descr = notif.descr
|
||||
|
||||
if (notif.typedir === shared_consts.TypeNotifs.TYPEDIR_FRIENDS) {
|
||||
if (notif.status === shared_consts.StatusNotifs.STATUS_FRIENDS_ACCEPTED) {
|
||||
descr += '\n' + $t('friends.accepted')
|
||||
} else if (notif.status === shared_consts.StatusNotifs.STATUS_FRIENDS_REFUSED) {
|
||||
descr += '\n' + $t('friends.refused')
|
||||
}
|
||||
}
|
||||
|
||||
return descr
|
||||
|
||||
return notif.descr
|
||||
}
|
||||
|
||||
function getNumNotif() {
|
||||
|
||||
Reference in New Issue
Block a user