diff --git a/app/views/subscription_mailer/_summary_detail.html.haml b/app/views/subscription_mailer/_summary_detail.html.haml index 66efd0b8b1..ff0d13872c 100644 --- a/app/views/subscription_mailer/_summary_detail.html.haml +++ b/app/views/subscription_mailer/_summary_detail.html.haml @@ -17,5 +17,5 @@ %h4= t(".other.title", count: orders.count) %p= t(".other.explainer") - orders.each_with_index do |order, i| - %a{ href: spree.order_url(order) }>= order.number + %a{ href: spree_order_url(order) }>= order.number = ", " if i < orders.count - 1 diff --git a/app/views/subscription_mailer/confirmation_email.html.haml b/app/views/subscription_mailer/confirmation_email.html.haml index 3af1ef2d21..0c2b274fb1 100644 --- a/app/views/subscription_mailer/confirmation_email.html.haml +++ b/app/views/subscription_mailer/confirmation_email.html.haml @@ -6,7 +6,7 @@ - if @order.user.present? = t("email_so_edit_false_html", orders_close_at: l(@order.order_cycle.orders_close_at, format: mail_long_datetime_format), - order_url: spree.order_url(@order)) + order_url: spree_order_url(@order)) = t("email_so_contact_distributor_html", distributor: @order.distributor.name, email: @order.distributor.contact.email) %p   diff --git a/app/views/subscription_mailer/failed_payment_email.html.haml b/app/views/subscription_mailer/failed_payment_email.html.haml index 36fa8d8741..bb02532d77 100644 --- a/app/views/subscription_mailer/failed_payment_email.html.haml +++ b/app/views/subscription_mailer/failed_payment_email.html.haml @@ -5,7 +5,7 @@ - if @order.user.present? = t("email_so_edit_false_html", orders_close_at: l(@order.order_cycle.orders_close_at, format: mail_long_datetime_format), - order_url: spree.order_url(@order)) + order_url: spree_order_url(@order)) = t("email_so_contact_distributor_html", distributor: @order.distributor.name, email: @order.distributor.contact.email) - if @order.errors.any? diff --git a/app/views/subscription_mailer/placement_email.html.haml b/app/views/subscription_mailer/placement_email.html.haml index 9acb8aa7a1..bfcefb6a7e 100644 --- a/app/views/subscription_mailer/placement_email.html.haml +++ b/app/views/subscription_mailer/placement_email.html.haml @@ -8,7 +8,7 @@ - allow_changes = !!@order.distributor.allow_order_changes? = t("email_so_edit_#{allow_changes}_html", orders_close_at: l(@order.order_cycle.orders_close_at, format: mail_long_datetime_format), - order_url: spree.order_url(@order)) + order_url: spree_order_url(@order)) = t("email_so_contact_distributor_html", distributor: @order.distributor.name, email: @order.distributor.contact.email) - else = t("email_so_contact_distributor_to_change_order_html", diff --git a/spec/mailers/subscription_mailer_spec.rb b/spec/mailers/subscription_mailer_spec.rb index 2db967e603..f224fbe960 100644 --- a/spec/mailers/subscription_mailer_spec.rb +++ b/spec/mailers/subscription_mailer_spec.rb @@ -47,7 +47,7 @@ describe SubscriptionMailer, type: :mailer do end describe "linking to order page" do - let(:order_link_href) { "href=\"#{spree.order_url(order)}\"" } + let(:order_link_href) { "href=\"#{spree_order_url(order)}\"" } let(:order_link_style) { "style='[^']+'" } let(:shop) { create(:enterprise, allow_order_changes: true) } @@ -113,7 +113,7 @@ describe SubscriptionMailer, type: :mailer do end describe "linking to order page" do - let(:order_link_href) { "href=\"#{spree.order_url(order)}\"" } + let(:order_link_href) { "href=\"#{spree_order_url(order)}\"" } let(:email) { SubscriptionMailer.deliveries.last } let(:body) { email.body.encoded } @@ -179,7 +179,7 @@ describe SubscriptionMailer, type: :mailer do end describe "linking to order page" do - let(:order_link_href) { "href=\"#{spree.order_url(order)}\"" } + let(:order_link_href) { "href=\"#{spree_order_url(order)}\"" } let(:email) { SubscriptionMailer.deliveries.last } let(:body) { email.body.encoded }