feat: allowing the flagging of system messages

closes #7767
closes #7771
This commit is contained in:
Husman
2016-07-10 14:58:50 -07:00
committed by Blade Barringer
parent 0631e9ba15
commit 694cd8e555
5 changed files with 16 additions and 6 deletions

View File

@@ -94,13 +94,22 @@ habitrpg.controller('ChatCtrl', ['$scope', 'Groups', 'Chat', 'User', '$http', 'A
} else {
$scope.abuseObject = message;
$scope.groupId = groupId;
Members.selectMember(message.uuid)
.then(function () {
$scope.isSystemMessage = message.uuid === 'system';
if (message.uuid === 'system') {
$rootScope.openModal('abuse-flag',{
controller:'MemberModalCtrl',
scope: $scope
});
});
} else {
Members.selectMember(message.uuid)
.then(function () {
$rootScope.openModal('abuse-flag',{
controller:'MemberModalCtrl',
scope: $scope
});
});
}
}
};