mirror of
https://github.com/HabitRPG/habitica.git
synced 2025-12-19 07:37:25 +01:00
add notifications, fix too many seen requests and misc fixes
This commit is contained in:
@@ -24,6 +24,12 @@ habitrpg.controller("PartyCtrl", ['$rootScope','$scope','Groups','Chat','User','
|
||||
$scope.group = $rootScope.party;
|
||||
$scope.group.loadingParty = false;
|
||||
checkForNotifications();
|
||||
if ($state.is('options.social.party')) {
|
||||
if ('Notification' in window && window.Notification.permission === 'default') {
|
||||
window.Notification.requestPermission();
|
||||
}
|
||||
Chat.markChatSeen($scope.group._id);
|
||||
}
|
||||
}
|
||||
|
||||
function handlePartyError (response) {
|
||||
@@ -52,10 +58,6 @@ habitrpg.controller("PartyCtrl", ['$rootScope','$scope','Groups','Chat','User','
|
||||
}
|
||||
}
|
||||
|
||||
if ($scope.group && $scope.group._id) {
|
||||
Chat.markChatSeen($scope.group._id);
|
||||
}
|
||||
|
||||
$scope.create = function(group) {
|
||||
group.loadingParty = true;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user