Add reserved pw field to domain edit UI if active dispute

This commit is contained in:
Karl Erik Õunapuu 2020-05-08 13:50:48 +03:00
parent 4870dab8af
commit dc9bf7a5d3
2 changed files with 2 additions and 1 deletions

View file

@ -100,6 +100,7 @@ class Registrar
authorize! :update, Depp::Domain
@data = @domain.info(params[:domain_name])
@domain_params = Depp::Domain.construct_params_from_server_data(@data)
@disputed = Dispute.active.find_by(domain_name: params[:domain_name]).present?
end
def update

View file

@ -31,7 +31,7 @@
.col-md-7
= check_box_tag 'domain[verified]', '1', @domain_params[:verified].eql?('1'), onclick: "return (confirm('#{t(:verified_confirm)}') ? true : false);"
- unless params[:domain_name]
- if !params[:domain_name] || @disputed
.form-group
.col-md-3.control-label
= label_tag :domain_reserved_pw, t(:reserved_pw)