mirror of
https://github.com/overleaf/overleaf.git
synced 2024-10-31 21:21:03 -04:00
17 lines
390 B
CoffeeScript
17 lines
390 B
CoffeeScript
define [
|
|
"base"
|
|
], (App) ->
|
|
|
|
App.controller "NotificationsController", ($scope, $http) ->
|
|
for notification in $scope.notifications
|
|
notification.hide = false
|
|
|
|
$scope.dismiss = (notification) ->
|
|
$http({
|
|
url: "/notifications/#{notification._id}"
|
|
method: "DELETE"
|
|
headers:
|
|
"X-Csrf-Token": window.csrfToken
|
|
})
|
|
.success (data) ->
|
|
notification.hide = true
|