base
This commit is contained in:
12
frontend/src/rest/notifications.js
Normal file
12
frontend/src/rest/notifications.js
Normal file
@ -0,0 +1,12 @@
|
||||
import { ref } from 'vue'
|
||||
import { restGet, restPost } from '@/rest/restConsumer.js'
|
||||
|
||||
export const notifications = ref({});
|
||||
|
||||
export function fetchNotifications(){
|
||||
restGet("/notifications").then( e => notifications.value = e );
|
||||
}
|
||||
|
||||
export function archiveNotification(id){
|
||||
restPost("/notifications/" + id).then( e => fetchNotifications() );
|
||||
}
|
Reference in New Issue
Block a user