Reenable 'winners' tab under Admin::Budget::Investment

This commit is contained in:
Angel Perez
2018-01-19 09:45:02 -04:00
parent a79e60ecd1
commit 1027896617
5 changed files with 11 additions and 8 deletions

View File

@@ -3,7 +3,8 @@ class Admin::BudgetInvestmentsController < Admin::BaseController
include FeatureFlags
feature_flag :budgets
has_filters(%w{all without_admin without_valuator under_valuation valuation_finished},
has_filters(%w{all without_admin without_valuator under_valuation
valuation_finished winners},
only: [:index, :toggle_selection])
before_action :load_budget

View File

@@ -148,6 +148,7 @@ en:
undecided: Undecided
unfeasible: Unfeasible
max_per_heading: Max. supports per heading
winners: Winners
button: Filter
download_current_selection: "Download current selection"
no_budget_investments: "There are no investment projects."

View File

@@ -148,6 +148,7 @@ es:
undecided: Sin decidir
unfeasible: Inviables
max_per_heading: Corte por partida
winners: Ganadores
button: Filtrar
download_current_selection: "Descargar selección actual"
no_budget_investments: "No hay proyectos de gasto."

View File

@@ -646,12 +646,12 @@ feature 'Admin budget investments' do
expect(page).to have_content(selected_bi.title)
expect(page).to have_content(winner_bi.title)
# within('#filter-subnav') { click_link 'Winners' }
# expect(page).not_to have_content(unfeasible_bi.title)
# expect(page).not_to have_content(feasible_bi.title)
# expect(page).not_to have_content(feasible_vf_bi.title)
# expect(page).not_to have_content(selected_bi.title)
# expect(page).to have_content(winner_bi.title)
within('#filter-subnav') { click_link 'Winners' }
expect(page).not_to have_content(unfeasible_bi.title)
expect(page).not_to have_content(feasible_bi.title)
expect(page).not_to have_content(feasible_vf_bi.title)
expect(page).not_to have_content(selected_bi.title)
expect(page).to have_content(winner_bi.title)
end
scenario "Showing the selection buttons", :js do

View File

@@ -177,7 +177,7 @@ feature 'Admin budgets' do
context "Calculate Budget's Winner Investments" do
xscenario 'For a Budget in reviewing balloting' do
scenario 'For a Budget in reviewing balloting' do
budget = create(:budget, phase: 'reviewing_ballots')
group = create(:budget_group, budget: budget)
heading = create(:budget_heading, group: group, price: 4)