angular.module('push') .controller('activityNoticeMangerCtrl', function ($scope, $stateParams, ActivityService, UtilService) { /* $scope.setStatusBar(1);*/ var activityid = $stateParams.activityid; $scope.title = $stateParams.title; $scope.status = $stateParams.status; $scope.days = $stateParams.days; // 获取活动下通知信息 var getManangerNotifyList = function () { $scope.showLoadingToast(); ActivityService.getManangerNotifyList(" ", activityid, 1).then(function (response) { // console.log(response); $scope.notifylist = response.notifylist; $scope.hideLoadingToast(); }, function () { $scope.hideLoadingToast(); }) }; getManangerNotifyList(); // 删除通知 $scope.deledtNotify = function (notifyid, index) { $scope.showLoadingToast(); ActivityService.deleteNotify(notifyid).then(function (response) { $scope.notifylist.splice(index, 1); UtilService.showMess("删除通知成功"); $scope.hideLoadingToast(); }, function () { $scope.hideLoadingToast(); }) }; });