mirror of
https://github.com/ansible/awx.git
synced 2026-03-18 09:27:31 -02:30
Fix survey button ids (#5975)
Change all references to 'btn' within the relatedButton loop to the loop variable 'itm' so that survey button ids are no longer shown as 'job_template_undefined_btn'.
This commit is contained in:
@@ -1520,7 +1520,7 @@ angular.module('FormGenerator', [GeneratorHelpers.name, 'Utilities', listGenerat
|
|||||||
html += "class=\"btn btn-sm";
|
html += "class=\"btn btn-sm";
|
||||||
html += (button['class']) ? " " + button['class'] : "";
|
html += (button['class']) ? " " + button['class'] : "";
|
||||||
html += "\" ";
|
html += "\" ";
|
||||||
html += "id=\"" + this.form.name + "_" + btn + "_btn\" ";
|
html += "id=\"" + this.form.name + "_" + itm + "_btn\" ";
|
||||||
|
|
||||||
if(button.ngShow){
|
if(button.ngShow){
|
||||||
html += this.attr(button, 'ngShow');
|
html += this.attr(button, 'ngShow');
|
||||||
@@ -1533,7 +1533,7 @@ angular.module('FormGenerator', [GeneratorHelpers.name, 'Utilities', listGenerat
|
|||||||
}
|
}
|
||||||
if (button.ngDisabled) {
|
if (button.ngDisabled) {
|
||||||
ngDisabled = (button.ngDisabled===true) ? this.form.name+"_form.$invalid" : button.ngDisabled;
|
ngDisabled = (button.ngDisabled===true) ? this.form.name+"_form.$invalid" : button.ngDisabled;
|
||||||
if (btn !== 'reset') {
|
if (itm !== 'reset') {
|
||||||
//html += "ng-disabled=\"" + this.form.name + "_form.$pristine || " + this.form.name + "_form.$invalid";
|
//html += "ng-disabled=\"" + this.form.name + "_form.$pristine || " + this.form.name + "_form.$invalid";
|
||||||
html += "ng-disabled=\"" + ngDisabled;
|
html += "ng-disabled=\"" + ngDisabled;
|
||||||
//html += (this.form.allowReadonly) ? " || " + this.form.name + "ReadOnly == true" : "";
|
//html += (this.form.allowReadonly) ? " || " + this.form.name + "ReadOnly == true" : "";
|
||||||
@@ -1572,7 +1572,7 @@ angular.module('FormGenerator', [GeneratorHelpers.name, 'Utilities', listGenerat
|
|||||||
html += "class=\"btn btn-sm Form-tab--disabled";
|
html += "class=\"btn btn-sm Form-tab--disabled";
|
||||||
html += (button['class']) ? " " + button['class'] : "";
|
html += (button['class']) ? " " + button['class'] : "";
|
||||||
html += "\" ";
|
html += "\" ";
|
||||||
html += "id=\"" + this.form.name + "_" + btn + "_btn\" ";
|
html += "id=\"" + this.form.name + "_" + itm + "_btn\" ";
|
||||||
|
|
||||||
if(button.ngShow){
|
if(button.ngShow){
|
||||||
html += this.attr(button, 'ngShow');
|
html += this.attr(button, 'ngShow');
|
||||||
|
|||||||
Reference in New Issue
Block a user