diff --git a/app/views/spree/users/_skinny.html.haml b/app/views/spree/users/_skinny.html.haml index 43bb039c46..2c8e7afe1d 100644 --- a/app/views/spree/users/_skinny.html.haml +++ b/app/views/spree/users/_skinny.html.haml @@ -2,7 +2,8 @@ .columns.small-2 %img.margin-top.account-logo{"logo-fallback" => true, "ng-src" => "{{shop.logo}}"} .columns.small-5 - %h3.margin-top{"ng-bind" => "::shop.name"} + %h3.margin-top + %a{"ng-href" => "{{::shop.hash}}#{main_app.shop_path}", "ng-bind" => "::shop.name"} .columns.small-4.text-right %h3.margin-top.distributor-balance{"ng-bind" => "::shop.balance | formatBalance", "ng-class" => "{'credit' : shop.balance < 0, 'debit' : shop.balance > 0, 'paid' : shop.balance == 0}" } .columns.small-1.text-right diff --git a/spec/features/consumer/account_spec.rb b/spec/features/consumer/account_spec.rb index f6a205bd29..b0139c7f6f 100644 --- a/spec/features/consumer/account_spec.rb +++ b/spec/features/consumer/account_spec.rb @@ -56,7 +56,11 @@ feature ' # It shows all hubs that have been ordered from with balance or credit expect(page).to have_content distributor1.name + expect(page).to have_link(distributor1.name, + href: "#{distributor1.permalink}/shop", count: 1) expect(page).to have_content distributor2.name + expect(page).to have_link(distributor2.name, + href: "#{distributor2.permalink}/shop", count: 1) expect(page).not_to have_content distributor_without_orders.name expect(page).to have_content distributor1.name + " " + "Balance due"