angular-flash icon indicating copy to clipboard operation
angular-flash copied to clipboard

I cant see a flash mesage when I created it inside a promise

Open corali89 opened this issue 9 years ago • 0 comments

I have a lot of promises that are calling to services, depending of the response I want to show a success or a error mesage.. and fot any reason thi does not work... any idea? not working: $scope.approveIt= function(id) { guestService.UpdateAppointmentStatus([id], Enums.GuestStatus.APPROVED) .then(function () { var message = ' Well done! You successfully approved the appointment.'; Flash.create('success', message); },function(error){ var message = ' Something wrong happened...'+error; Flash.create('danger', message); }) };

working: $scope.successAlert = function () { var message = ' Well done! You successfully read this important alert message.'; Flash.create('success', message,0); }

corali89 avatar Sep 06 '16 13:09 corali89