Skip to content

Commit

Permalink
Mark dialog selection as a required field
Browse files Browse the repository at this point in the history
  • Loading branch information
lgalis committed May 10, 2018
1 parent 96fadc6 commit e10c80e
Showing 1 changed file with 2 additions and 2 deletions.
Expand Up @@ -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",
Expand All @@ -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",
Expand Down

0 comments on commit e10c80e

Please sign in to comment.