code refactor

master
MaysWind 2019-08-20 23:31:31 +08:00
parent 3df4656c61
commit df8f7e32ff
2 changed files with 1 additions and 16 deletions

View File

@ -32,17 +32,10 @@
return;
}
var noticicationScope = $rootScope.$new();
noticicationScope.refreshPage = function () {
$window.location.reload();
};
lastRefreshPageNotification = ariaNgLocalizationService.notifyInPage('', 'Configuration has been modified, please reload the page for the changes to take effect.', {
delay: false,
type: 'info',
templateUrl: 'setting-changed-notification.html',
scope: noticicationScope,
templateUrl: 'views/notification-reloadable.html',
onClose: function () {
lastRefreshPageNotification = null;
}

View File

@ -346,11 +346,3 @@
</div>
</div>
</section>
<script id="setting-changed-notification.html" type="text/ng-template">
<div class="ui-notification custom-template">
<div class="message" ng-bind-html="message"></div>
<div class="message">
<a class="btn btn-small btn-primary close-notification" ng-click="refreshPage()" translate>Reload Page</a>
</div>
</div>
</script>