diff --git a/app/controllers/account_controller.rb b/app/controllers/account_controller.rb index 625452196..b0bd18e5b 100644 --- a/app/controllers/account_controller.rb +++ b/app/controllers/account_controller.rb @@ -23,7 +23,7 @@ class AccountController < ApplicationController def account_params if @account.organization? - params.require(:account).permit(:phone_number, :email_on_debate_comment, :email_on_comment_reply, organization_attributes: [:name]) + params.require(:account).permit(:phone_number, :email_on_debate_comment, :email_on_comment_reply, organization_attributes: [:name, :responsible_name]) else params.require(:account).permit(:username, :email_on_debate_comment, :email_on_comment_reply) end diff --git a/app/views/account/show.html.erb b/app/views/account/show.html.erb index b1382ce4c..e43c424de 100644 --- a/app/views/account/show.html.erb +++ b/app/views/account/show.html.erb @@ -33,6 +33,7 @@ <% if @account.organization? %> <%= f.fields_for :organization do |fo| %> <%= fo.text_field :name, autofocus: true, maxlength: Organization.name_max_length, placeholder: t("account.show.organization_name_label") %> + <%= fo.text_field :responsible_name, autofocus: true, maxlength: Organization.responsible_name_max_length, placeholder: t("account.show.organization_responsible_name_placeholder") %> <% end %> <%= f.text_field :phone_number, placeholder: t("account.show.phone_number_label") %> diff --git a/config/locales/en.yml b/config/locales/en.yml index 98afaeb4f..bca35eb2e 100644 --- a/config/locales/en.yml +++ b/config/locales/en.yml @@ -176,6 +176,7 @@ en: username_label: "Username" phone_number_label: "Phone number" organization_name_label: "Organization name" + organization_responsible_name_placeholder: "The responsible representative of the organization" notifications: Notifications finish_verification: "Finish verification" verified_account: Verified account diff --git a/config/locales/es.yml b/config/locales/es.yml index d2b51d551..bd3722b71 100644 --- a/config/locales/es.yml +++ b/config/locales/es.yml @@ -176,6 +176,7 @@ es: username_label: "Nombre de usuario" phone_number_label: "Teléfono" organization_name_label: "Nombre de la organización" + organization_responsible_name_placeholder: "Representante de la asociación/colectivo" notifications: Notificaciones finish_verification: "Finalizar verificación" verified_account: Cuenta verificada