Update orders closing message

This commit is contained in:
Matt-Yorkley
2020-11-30 10:02:57 +00:00
committed by Andy Brett
parent f71de8123a
commit 0ceba7c0a8
4 changed files with 5 additions and 7 deletions

View File

@@ -170,10 +170,6 @@ shop ordercycle {
float: none;
padding: 0;
}
.no-message-pad {
padding: 0.95rem;
}
}
form.custom {

View File

@@ -4,7 +4,8 @@
%div{"ng-if" => "closesInLessThan3Months()"}
= t :enterprises_next_closing
%strong {{ OrderCycle.orders_close_at() | date_in_words }}
%div.no-message-pad{"ng-if" => "!closesInLessThan3Months()"}
%div{"ng-if" => "!closesInLessThan3Months()"}
= t :enterprises_currently_open
%div{"ng-if" => "!OrderCycle.selected()"}
= t :enterprises_choose

View File

@@ -1677,6 +1677,7 @@ See the %{link} to find out more about %{sitename}'s features and to start using
shopping_producers_of_hub: "%{hub}'s producers:"
enterprises_next_closing: "Next order closing"
enterprises_currently_open: "Orders are currently open"
enterprises_ready_for: "Ready for"
enterprises_choose: "Choose when you want your order:"

View File

@@ -62,9 +62,9 @@ feature "As a consumer I want to shop with a distributor", js: true do
describe "when order cycle closes in more than 3 months" do
before { oc1.update orders_close_at: 5.months.from_now }
it "does not show 'closing in' message" do
it "shows alternative to 'closing in' message" do
visit shop_path
expect(page).not_to have_content "Next order closing in 2 days"
expect(page).to have_content "Orders are currently open"
end
end
end