From e10c80eea23df2cc609579c27e75a56c3be470a1 Mon Sep 17 00:00:00 2001 From: L Galis Date: Thu, 10 May 2018 14:31:28 -0400 Subject: [PATCH] Mark dialog selection as a required field --- .../layouts/angular/_ansible_form_options_angular.html.haml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/views/layouts/angular/_ansible_form_options_angular.html.haml b/app/views/layouts/angular/_ansible_form_options_angular.html.haml index 877f0b0074e..5548a05e1b2 100644 --- a/app/views/layouts/angular/_ansible_form_options_angular.html.haml +++ b/app/views/layouts/angular/_ansible_form_options_angular.html.haml @@ -266,7 +266,7 @@ = _("Dialog") .col-md-3 %label.radio-inline - %input{"ng-model" => "vm.#{prefix}_dialog_existing", :type => "radio", :value => "existing", "ng-click" => "vm.toggleDialogSelection('#{prefix}', 'existing')", "ng-required" => true, "ng-checked" => "#{ng_model}.#{prefix}_dialog_existing == 'existing'"} + %input{"ng-model" => "vm.#{prefix}_dialog_existing", :type => "radio", :value => "existing", "ng-click" => "vm.toggleDialogSelection('#{prefix}', 'existing')", "ng-required" => "#{ng_model}.#{prefix}_dialog_existing != 'create' && #{ng_model}.#{prefix}_dialog_existing != 'existing'", "ng-checked" => "#{ng_model}.#{prefix}_dialog_existing == 'existing'"} = _("Use Existing") .col-md-6{"ng-class" => "{'has-error': angularForm.#{prefix}_dialog_id.$invalid}", "ng-if" => "#{ng_model}.#{prefix}_dialog_existing == 'existing'"} %select{"ng-model" => "vm._#{prefix}_dialog", @@ -285,7 +285,7 @@ %label.col-md-3.control-label .col-md-3 %label.radio-inline - %input{"ng-model" => "vm.#{prefix}_dialog_existing", :type => "radio", :value => "create", "ng-click" => "vm.toggleDialogSelection('#{prefix}', 'create')", "ng-checked" => ("#{ng_model}.#{prefix}_dialog_existing == 'create'")} + %input{"ng-model" => "vm.#{prefix}_dialog_existing", :type => "radio", :value => "create", "ng-click" => "vm.toggleDialogSelection('#{prefix}', 'create')", "ng-required" => "#{ng_model}.#{prefix}_dialog_existing != 'create' && #{ng_model}.#{prefix}_dialog_existing != 'existing'", "ng-checked" => ("#{ng_model}.#{prefix}_dialog_existing == 'create'")} = _("Create New") .col-md-6{"ng-class" => "{'has-error': angularForm.#{prefix}_dialog_name.$invalid}", "ng-if" => "#{ng_model}.#{prefix}_dialog_existing == 'create'"} %input.form-control{:type => "text",