change shop name to be link to shop on transactions page

This commit is contained in:
Eduardo
2020-05-03 20:12:10 -03:00
parent 74c7a01151
commit 2fca16f02f
2 changed files with 6 additions and 1 deletions

View File

@@ -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

View File

@@ -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"