diff --git a/app/views/features/_manage_community_fields.rhtml b/app/views/features/_manage_community_fields.rhtml index 362d1de..67ed87d 100644 --- a/app/views/features/_manage_community_fields.rhtml +++ b/app/views/features/_manage_community_fields.rhtml @@ -1,5 +1,3 @@ -

<%= __('Manage community fields') %>

- <% labelled_form_for(:environment, @environment, :url => {:action => 'manage_community_fields'}) do |f| %> diff --git a/app/views/features/_manage_enterprise_fields.rhtml b/app/views/features/_manage_enterprise_fields.rhtml index a312c63..1e32a9b 100644 --- a/app/views/features/_manage_enterprise_fields.rhtml +++ b/app/views/features/_manage_enterprise_fields.rhtml @@ -1,5 +1,3 @@ -

<%= __('Manage enterprise fields') %>

- <% labelled_form_for(:environment, @environment, :url => {:action => 'manage_enterprise_fields'}) do |f| %>
diff --git a/app/views/features/_manage_person_fields.rhtml b/app/views/features/_manage_person_fields.rhtml index 3909a56..8584315 100644 --- a/app/views/features/_manage_person_fields.rhtml +++ b/app/views/features/_manage_person_fields.rhtml @@ -1,5 +1,3 @@ -

<%= _('Manage person fields') %>

- <% labelled_form_for(:environment, @environment, :url => {:action => 'manage_person_fields'}) do |f| %>
diff --git a/app/views/features/manage_fields.rhtml b/app/views/features/manage_fields.rhtml index 5a66c7b..f57e9ad 100644 --- a/app/views/features/manage_fields.rhtml +++ b/app/views/features/manage_fields.rhtml @@ -1,9 +1,15 @@ -<%= javascript_include_tag "manage-fields.js" %> - -<%= render :partial => 'manage_person_fields' %> +

<%= _('Manage fields displayed for profiles') %>

-<% if !environment.enabled?('disable_asset_enterprises') %> - <%= render :partial => 'manage_enterprise_fields' %> +<% tabs = [] %> +<% tabs << {:title => _("Person's fields"), :id => 'person-fields', + :content => (render :partial => 'manage_person_fields')} %> +<% tabs << {:title => _("Community's fields"), :id => 'community-fields', + :content => (render :partial => 'manage_community_fields')} %> +<% unless environment.enabled?('disable_asset_enterprises') %> + <% tabs << {:title => _("Enterprise's fields"), :id => 'enterprise-fields', + :content => (render :partial => 'manage_enterprise_fields')} %> <% end %> -<%= render :partial => 'manage_community_fields' %> +<%= render_tabs(tabs) %> + +<%= javascript_include_tag "manage-fields.js" %> diff --git a/features/manage_fields.feature b/features/manage_fields.feature index 538a639..c772cd4 100644 --- a/features/manage_fields.feature +++ b/features/manage_fields.feature @@ -17,7 +17,8 @@ Feature: check all manage fields @selenium Scenario: check all active person fields - Given I check "person_active" + Given I follow "Person's fields" + And I check "person_active" And I press "save_person_fields" When I go to admin_user's control panel And I follow "Edit Profile" @@ -25,7 +26,8 @@ Feature: check all manage fields @selenium Scenario: check all active enterprise fields - Given I check "enterprise_active" + Given I follow "Enterprise's fields" + And I check "enterprise_active" And I press "save_enterprise_fields" When I go to paper-street's control panel And I follow "Enterprise Info and settings" @@ -33,7 +35,8 @@ Feature: check all manage fields @selenium Scenario: check all active community fields - Given I check "community_active" + Given I follow "Community's fields" + And I check "community_active" And I press "save_community_fields" When I go to mycommunity's control panel And I follow "Community Info and settings" @@ -41,7 +44,8 @@ Feature: check all manage fields @selenium Scenario: uncheck Check/Uncheck All active person field - Given I check "person_active" + Given I follow "Person's fields" + And I check "person_active" And I press "save_person_fields" And I uncheck "person_active" And I press "save_person_fields" @@ -51,7 +55,8 @@ Feature: check all manage fields @selenium Scenario: uncheck Check/Uncheck All active community field - Given I check "community_active" + Given I follow "Community's fields" + And I check "community_active" And I press "save_community_fields" And I uncheck "community_active" And I press "save_community_fields" @@ -61,7 +66,8 @@ Feature: check all manage fields @selenium Scenario: uncheck Check/Uncheck All active enterprise field - Given I check "enterprise_active" + Given I follow "Enterprise's fields" + And I check "enterprise_active" And I press "save_enterprise_fields" And I uncheck "enterprise_active" And I press "save_enterprise_fields" -- libgit2 0.21.2