From 0926753ee320184e4d70defc63efc1c10d9c82c4 Mon Sep 17 00:00:00 2001 From: Antonio Terceiro Date: Fri, 16 Apr 2010 09:51:29 -0300 Subject: [PATCH] Visual enhancements in enterprise registration --- app/views/enterprise_registration/basic_information.rhtml | 6 +++--- app/views/enterprise_registration/confirmation.rhtml | 4 ++-- app/views/enterprise_registration/select_validator.rhtml | 22 ++++++++++++++-------- 3 files changed, 19 insertions(+), 13 deletions(-) diff --git a/app/views/enterprise_registration/basic_information.rhtml b/app/views/enterprise_registration/basic_information.rhtml index 18d9624..31895e6 100644 --- a/app/views/enterprise_registration/basic_information.rhtml +++ b/app/views/enterprise_registration/basic_information.rhtml @@ -1,6 +1,6 @@ <%= error_messages_for 'create_enterprise' %> -

<%= _('Register enterprise') %>

+

<%= _('Register enterprise') %>

<% if @validation == :region && @regions.empty? %> @@ -19,8 +19,8 @@ <%= required_fields_message %> <% labelled_form_for(:create_enterprise, @create_enterprise) do |f| %> - <%= required f.text_field 'identifier'%> - <%= required f.text_field 'name'%> + <%= required f.text_field 'name', :onchange => "updateUrlField(this, 'create_enterprise_identifier')", :size => 40 %> + <%= required labelled_form_field(_('Address'), content_tag('code', environment.top_url + "/" + text_field(:create_enterprise, 'identifier', :size => 25))) %> <%= render :partial => 'shared/custom_fields', :locals => { :f => f, :object_name => :create_enterprise, :profile => @create_enterprise, :only_required => false } %> <%= required labelled_form_field(_('Region'), f.select('region_id', @regions)) if @validation == :region %> diff --git a/app/views/enterprise_registration/confirmation.rhtml b/app/views/enterprise_registration/confirmation.rhtml index e5424c3..a623616 100644 --- a/app/views/enterprise_registration/confirmation.rhtml +++ b/app/views/enterprise_registration/confirmation.rhtml @@ -1,7 +1,7 @@ -

<%= _('Enterprise Registration completed') %>

+

<%= _('Enterprise Registration completed') %>

-<%= _("Your enterprise registration request was successfully registered. The validator organization you choose (%s) should get in touch with to start the validation process. As soon as the validators approve (or reject) your request, you will be notified by e-mail.") % @create_enterprise.target.name %> +<%= _("Your enterprise registration request was successfully registered. The validator organization you choose (%s) should get in touch with to start the validation process. As soon as the validators approve (or reject) your request, you will be notified by e-mail.") % link_to(@create_enterprise.target.name, @create_enterprise.target.url) %>

diff --git a/app/views/enterprise_registration/select_validator.rhtml b/app/views/enterprise_registration/select_validator.rhtml index 1233e4b..c3dd3b3 100644 --- a/app/views/enterprise_registration/select_validator.rhtml +++ b/app/views/enterprise_registration/select_validator.rhtml @@ -1,4 +1,4 @@ -

<%= _('Enterprise Registration: Select a validator organization') %>

+

<%= _('Enterprise Registration: validator organization') %>

<%= _('Select one organization to validate your enterprise registration request. Check the provided information about their validation methodoly and criteria.') %> @@ -7,14 +7,20 @@ <% form_tag do %> <%= render :partial => 'hidden_fields' %> - <% for validator in @validators %> -

- <%= labelled_radio_button validator.name, 'create_enterprise[target_id]', validator.id, true %> - - <%= labelled_form_field(_('Validation Methodology:'), validator.validation_methodology || _("(not informed)")) %> - <%= labelled_form_field(_('Restrictions (if any):'), validator.validation_restrictions || _("(not informed)")) %> -
+ + + + + + + <% @validators.each do |validator| %> + + + + + <% end %> +
<%= _('Name') %><%= _('Validation Methodology:') %><%= _('Restrictions (if any):') %>
<%= labelled_radio_button validator.name, 'create_enterprise[target_id]', validator.id %><%= validator.validation_methodology || _("(not informed)") %><%= validator.validation_restrictions || _("(not informed)") %>
<% button_bar do %> <%= submit_button 'save', _('Confirm') %> -- libgit2 0.21.2