Project

General

Profile

« Previous | Next » 

Revision 6f5e909f

Added by Walden Raines about 10 years ago

Fixes #4785, replace gettext with translate for extraction/replacement.

View differences:

engines/bastion/app/assets/javascripts/bastion/systems/details/system-details.controller.js
* @requires $scope
* @requires $state
* @requires $q
* @requires gettext
* @requires translate
* @requires System
* @requires Organization
* @requires MenuExpander
......
* Provides the functionality for the system details action pane.
*/
angular.module('Bastion.systems').controller('SystemDetailsController',
['$scope', '$state', '$q', 'gettext', 'System', 'Organization', 'MenuExpander',
function ($scope, $state, $q, gettext, System, Organization, MenuExpander) {
['$scope', '$state', '$q', 'translate', 'System', 'Organization', 'MenuExpander',
function ($scope, $state, $q, translate, System, Organization, MenuExpander) {
$scope.menuExpander = MenuExpander;
$scope.successMessages = [];
......
system.$update(function (response) {
deferred.resolve(response);
$scope.successMessages.push(gettext('Save Successful.'));
$scope.successMessages.push(translate('Save Successful.'));
}, function (response) {
deferred.reject(response);
_.each(response.data.errors, function (errorMessage) {
$scope.errorMessages.push(gettext("An error occurred saving the System: ") + errorMessage);
$scope.errorMessages.push(translate("An error occurred saving the System: ") + errorMessage);
});
});

Also available in: Unified diff