mirror of
https://github.com/openfoodfoundation/openfoodnetwork
synced 2026-01-24 20:36:49 +00:00
add missing i18n key for check hub ready for checkout
This commit is contained in:
@@ -99,8 +99,7 @@ class ApplicationController < ActionController::Base
|
||||
if current_distributor_closed?
|
||||
current_order.empty!
|
||||
current_order.set_distribution! nil, nil
|
||||
flash[:info] = "The hub you have selected is temporarily closed for orders. "\
|
||||
"Please try again later."
|
||||
flash[:info] = I18n.t('order_cycles_closed_for_hub')
|
||||
redirect_to main_app.root_url
|
||||
end
|
||||
end
|
||||
|
||||
@@ -2197,6 +2197,7 @@ See the %{link} to find out more about %{sitename}'s features and to start using
|
||||
hub_sidebar_at_least: "At least one hub must be selected"
|
||||
hub_sidebar_blue: "blue"
|
||||
hub_sidebar_red: "red"
|
||||
order_cycles_closed_for_hub: "The hub you have selected is temporarily closed for orders. Please try again later."
|
||||
report_customers_distributor: "Distributor"
|
||||
report_customers_supplier: "Supplier"
|
||||
report_customers_cycle: "Order Cycle"
|
||||
|
||||
@@ -33,7 +33,7 @@ describe CheckoutController, type: :controller do
|
||||
get :edit
|
||||
|
||||
expect(response).to redirect_to root_url
|
||||
expect(flash[:info]).to eq("The hub you have selected is temporarily closed for orders. Please try again later.")
|
||||
expect(flash[:info]).to eq(I18n.t('order_cycles_closed_for_hub'))
|
||||
end
|
||||
|
||||
describe "redirection to cart and stripe" do
|
||||
|
||||
@@ -116,7 +116,7 @@ describe Spree::OrdersController, type: :controller do
|
||||
spree_get :edit
|
||||
|
||||
expect(response).to redirect_to root_url
|
||||
expect(flash[:info]).to eq("The hub you have selected is temporarily closed for orders. Please try again later.")
|
||||
expect(flash[:info]).to eq(I18n.t('order_cycles_closed_for_hub'))
|
||||
end
|
||||
|
||||
describe "when an item is in the cart" do
|
||||
|
||||
Reference in New Issue
Block a user