mirror of
https://github.com/ansible/awx.git
synced 2026-01-13 02:50:02 -03:30
adding translation directive in places
This commit is contained in:
parent
6915e95f58
commit
1edc688acb
@ -1,11 +1,11 @@
|
||||
<label class="at-InputLabel">
|
||||
<span ng-if="state.required" class="at-InputLabel-required">*</span>
|
||||
<span class="at-InputLabel-name">{{::state.label}}</span>
|
||||
<span class="at-InputLabel-name" >{{::state.label}}</span>
|
||||
<at-popover state="state"></at-popover>
|
||||
<span ng-if="state._displayHint" class="at-InputLabel-hint">{{::state._hint}}</span>
|
||||
<span ng-if="state._displayHint" class="at-InputLabel-hint" translate>{{::state._hint}}</span>
|
||||
<div ng-if="state._displayPromptOnLaunch" class="at-InputLabel-checkbox pull-right">
|
||||
<label class="at-InputLabel-checkboxLabel">
|
||||
<input type="checkbox"
|
||||
<input type="checkbox"
|
||||
ng-model="state._promptOnLaunch"
|
||||
ng-change="vm.togglePromptOnLaunch()" />
|
||||
<p>{{:: vm.strings.get('label.PROMPT_ON_LAUNCH') }}</p>
|
||||
|
||||
@ -1,4 +1,4 @@
|
||||
<th id="{{columnIterator}}-{{columnField}}-header" class="List-tableHeader list-header {{columnCustomClass}}" ng-click="columnNoSort !== 'true' && toggleColumnOrderBy()" ng-class="{'list-header-noSort' : columnNoSort === 'true'}">
|
||||
{{columnLabel}}
|
||||
<th id="{{columnIterator}}-{{columnField}}-header" class="List-tableHeader list-header {{columnCustomClass}}" ng-click="columnNoSort !== 'true' && toggleColumnOrderBy()" ng-class="{'list-header-noSort' : columnNoSort === 'true'}" >
|
||||
{{columnLabel | translate}}
|
||||
<i ng-if="columnNoSort !== 'true'" class="fa columnSortIcon" ng-class="orderByIcon()">
|
||||
</th>
|
||||
|
||||
@ -835,7 +835,7 @@ function(ConfigurationUtils, i18n, $rootScope) {
|
||||
id_to_close = "";
|
||||
|
||||
if (element[0].id) {
|
||||
template = '<div id="' + element[0].id + '_popover_container" class="popover" role="tooltip"><div class="arrow"></div><h3 id="' + element[0].id + '_popover_title" class="popover-title"></h3><div id="' + element[0].id + '_popover_content" class="popover-content"></div></div>';
|
||||
template = '<div id="' + element[0].id + '_popover_container" class="popover" role="tooltip"><div class="arrow"></div><h3 id="' + element[0].id + '_popover_title" class="popover-title" translate></h3><div id="' + element[0].id + '_popover_content" class="popover-content" translate></div></div>';
|
||||
}
|
||||
|
||||
scope.triggerPopover = function(e) {
|
||||
|
||||
@ -637,9 +637,9 @@ angular.module('FormGenerator', [GeneratorHelpers.name, 'Utilities', listGenerat
|
||||
html += "for=\"" + fld + '">\n';
|
||||
html += (field.icon) ? Icon(field.icon) : "";
|
||||
if (field.labelBind) {
|
||||
html += "\t\t<span ng-class=class=\"Form-inputLabel\" ng-bind=\"" + field.labelBind + "\">\n\t\t</span>";
|
||||
html += "\t\t<span ng-class=class=\"Form-inputLabel\" ng-bind=\"" + field.labelBind + "\" translate>\n\t\t</span>";
|
||||
} else {
|
||||
html += "\t\t<span class=\"Form-inputLabel\">\n\t\t\t" + field.label + "\n\t\t</span>";
|
||||
html += "\t\t<span class=\"Form-inputLabel\" translate>\n\t\t\t" + field.label + "\n\t\t</span>";
|
||||
}
|
||||
html += ((field.awPopOver || field.awPopOverWatch) && !field.awPopOverRight) ? Attr(field, 'awPopOver', fld) : "";
|
||||
html += (field.hintText) ? "\n\t\t<span class=\"label-hint-text\">\n\t\t\t<i class=\"fa fa-info-circle\">\n\t\t\t</i>\n\t\t\tHint: " + field.hintText + "\n\t\t</span>" : "";
|
||||
@ -1203,9 +1203,9 @@ angular.module('FormGenerator', [GeneratorHelpers.name, 'Utilities', listGenerat
|
||||
html += buildCheckbox(this.form, field, fld, undefined, false);
|
||||
html += (field.icon) ? Icon(field.icon) : "";
|
||||
if (field.labelBind) {
|
||||
html += "\t\t<span class=\"Form-inputLabel\" ng-bind=\"" + field.labelBind + "\">\n\t\t</span>";
|
||||
html += "\t\t<span class=\"Form-inputLabel\" ng-bind=\"" + field.labelBind + "\" translate>\n\t\t</span>";
|
||||
} else {
|
||||
html += "<span class=\"Form-inputLabel\">" + field.label + "</span>";
|
||||
html += "<span class=\"Form-inputLabel\" translate>" + field.label + "</span>";
|
||||
}
|
||||
|
||||
html += (field.awPopOver) ? this.attr(field, 'awPopOver', fld) : "";
|
||||
@ -1476,7 +1476,7 @@ angular.module('FormGenerator', [GeneratorHelpers.name, 'Utilities', listGenerat
|
||||
html += `<div id="${this.form.name}_tab" class="Form-tab" `;
|
||||
html += this.form.detailsClick ? `ng-click="` + this.form.detailsClick + `" ` : `ng-click="$state.go('${this.form.stateTree}.edit')" `;
|
||||
let detailsTabSelected = this.form.activeEditState ? `$state.is('${this.form.activeEditState}') || $state.is('${this.form.stateTree}.edit') || $state.$current.data.formChildState` : `$state.is('${this.form.stateTree}.edit') || $state.$current.data.formChildState`;
|
||||
html += `ng-class="{'is-selected': ${detailsTabSelected} }">` +
|
||||
html += `ng-class="{'is-selected': ${detailsTabSelected} }" translate>` +
|
||||
`${details}</div>`;
|
||||
|
||||
for (itm in this.form.related) {
|
||||
@ -1495,7 +1495,7 @@ angular.module('FormGenerator', [GeneratorHelpers.name, 'Utilities', listGenerat
|
||||
if(this.form.related[itm].disabled){
|
||||
html += `, 'Form-tab--disabled' : ${this.form.related[itm].disabled }`;
|
||||
}
|
||||
html += `}">${(collection.title || collection.editTitle)}</div>`;
|
||||
html += `}" translate>${(collection.title || collection.editTitle)}</div>`;
|
||||
}
|
||||
|
||||
for (itm in this.form.relatedButtons) {
|
||||
|
||||
@ -744,7 +744,7 @@ angular.module('GeneratorHelpers', [systemStatus.name])
|
||||
html += (options.ngHide) ? "ng-hide=\"" + options.ngHide + "\" " : "";
|
||||
html += (options.awFeature) ? "aw-feature=\"" + options.awFeature + "\" " : "";
|
||||
html += '>';
|
||||
html += '<span>';
|
||||
html += '<span translate>';
|
||||
html += (options.buttonContent) ? options.buttonContent : "";
|
||||
html += '</span>';
|
||||
html += '</button>';
|
||||
|
||||
@ -4,7 +4,7 @@
|
||||
<div ng-if="options.type && options.type === 'template'" ng-include="options.template" ng-show="{{options.ngShow}}"></div>
|
||||
<div class="List-action--showTooltipOnDisabled" ng-if="options.showTipWhenDisabled" aw-tool-tip="{{options.awToolTip}}" data-tip-watch="{{options.dataTipWatch}}" data-placement="{{options.dataPlacement}}" data-container="{{options.dataContainer}}" data-title="{{options.dataTitle}}" data-tooltip-inner-class="{{options.tooltipInnerClass}}">
|
||||
<div class="btn-group" ng-if="options.type === 'buttonDropdown'" ng-disabled="{{options.ngDisabled}}">
|
||||
<button type="button" class="{{options.actionClass}} List-dropdownButton" ng-bind-html="options.buttonContent"></button>
|
||||
<button type="button" class="{{options.actionClass}} List-dropdownButton" ng-bind-html="options.buttonContent" translate></button>
|
||||
<button type="button" class="{{options.actionClass}} List-dropdownButton List-dropdownCaratButton dropdown-toggle" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">
|
||||
<span class="List-dropdownCarat"></span>
|
||||
<span class="sr-only">Toggle Dropdown</span>
|
||||
@ -25,14 +25,14 @@
|
||||
ng-click="$eval(options.ngClick)"
|
||||
toolbar="true"
|
||||
aw-feature="{{options.awFeature}}">
|
||||
<span ng-bind-html="options.buttonContent"></span>
|
||||
<span ng-bind-html="options.buttonContent" translate></span>
|
||||
</button>
|
||||
</span>
|
||||
</div>
|
||||
<span ng-if="!options.showTipWhenDisabled">
|
||||
<div class="btn-group" ng-if="options.type === 'buttonDropdown'" ng-disabled="{{options.ngDisabled}}" aw-tool-tip="{{options.awToolTip}}" data-tip-watch="{{options.dataTipWatch}}" data-placement="{{options.dataPlacement}}" data-container="{{options.dataContainer}}" ng-show="{{options.ngShow}}">
|
||||
<button type="button" class="{{options.actionClass}} List-dropdownButton dropdown-toggle" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">
|
||||
<span ng-bind-html="options.buttonContent"></span>
|
||||
<span ng-bind-html="options.buttonContent" translate></span>
|
||||
<span class="List-dropdownCarat"></span>
|
||||
<span class="sr-only">Toggle Dropdown</span>
|
||||
</button>
|
||||
@ -57,7 +57,7 @@
|
||||
ng-show="{{options.ngShow}}"
|
||||
toolbar="true"
|
||||
aw-feature="{{options.awFeature}}">
|
||||
<span ng-bind-html="options.buttonContent"></span>
|
||||
<span ng-bind-html="options.buttonContent" translate></span>
|
||||
</button>
|
||||
</span>
|
||||
</span>
|
||||
|
||||
@ -135,9 +135,9 @@ export default ['$compile', 'Attr', 'Icon',
|
||||
// Don't display an empty <div> if there is no listTitle
|
||||
if ((options.title !== false && list.title !== false) && list.listTitle !== undefined) {
|
||||
html += "<div class=\"List-header\" >";
|
||||
html += "<div class=\"List-title\">";
|
||||
html += "<div class=\"List-title\" translate>";
|
||||
if (list.listTitle && options.listTitle !== false) {
|
||||
html += "<div class=\"List-titleText\">" + list.listTitle + "</div>";
|
||||
html += "<div class=\"List-titleText\" translate>" + list.listTitle + "</div>";
|
||||
// We want to show the list title badge by default and only hide it when the list config specifically passes a false flag
|
||||
list.listTitleBadge = (typeof list.listTitleBadge === 'boolean' && list.listTitleBadge === false) ? false : true;
|
||||
if (list.listTitleBadge) {
|
||||
@ -506,13 +506,13 @@ export default ['$compile', 'Attr', 'Icon',
|
||||
html = "<thead>\n";
|
||||
html += "<tr class=\"List-tableHeaderRow\">\n";
|
||||
if (list.index) {
|
||||
html += "<th class=\"col-lg-1 col-md-1 col-sm-2 hidden-xs List-tableHeader\">#</th>\n";
|
||||
html += "<th class=\"col-lg-1 col-md-1 col-sm-2 hidden-xs List-tableHeader\" translate>#</th>\n";
|
||||
}
|
||||
|
||||
if (list.multiSelect) {
|
||||
html += buildSelectAll().prop('outerHTML');
|
||||
} else if (options.mode === 'lookup') {
|
||||
html += "<th class=\"List-tableHeader select-column List-staticColumn--smallStatus\"></th>";
|
||||
html += "<th class=\"List-tableHeader select-column List-staticColumn--smallStatus\" translate></th>";
|
||||
}
|
||||
|
||||
if (options.mode !== 'lookup'){
|
||||
@ -565,11 +565,11 @@ export default ['$compile', 'Attr', 'Icon',
|
||||
}
|
||||
}
|
||||
if (options.mode === 'select') {
|
||||
html += "<th class=\"List-tableHeader col-lg-1 col-md-1 col-sm-2 col-xs-2\">Select</th>";
|
||||
html += "<th class=\"List-tableHeader col-lg-1 col-md-1 col-sm-2 col-xs-2\" translate>Select</th>";
|
||||
} else if (options.mode === 'edit' && list.fieldActions) {
|
||||
html += "<th class=\"List-tableHeader List-tableHeader--actions actions-column";
|
||||
html += (list.fieldActions && list.fieldActions.columnClass) ? " " + list.fieldActions.columnClass : "";
|
||||
html += "\">";
|
||||
html += "\" translate>";
|
||||
html += (list.fieldActions.label === undefined || list.fieldActions.label) ? i18n._("Actions") : "";
|
||||
html += "</th>\n";
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user