Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CRO-169: also includes CRO-314 and CRO-179. Hide brands in the footer if #1053

Merged
merged 2 commits into from
Jul 27, 2017
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
# Changelog

## Draft
- Hide Info in footer if no address is provided in Store Profile. Hide Brands in footer if Merchant has no brands [#1053](https://github.com/bigcommerce/cornerstone/pull/1053)

## 1.9.1 (2017-07-25)
- Move some hard-coded validation messages to language file [#1040](https://github.com/bigcommerce/cornerstone/pull/1040)
Expand Down
6 changes: 4 additions & 2 deletions templates/components/common/footer.html
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ <h5 class="footer-info-heading">{{lang 'footer.categories'}}</h5>
</ul>
</article>

{{#if theme_settings.shop_by_brand_show_footer}}
{{#and theme_settings.shop_by_brand_show_footer shop_by_brand.length}}
<article class="footer-info-col footer-info-col--small" data-section-type="footer-brands">
<h5 class="footer-info-heading">{{lang 'footer.brands'}}</h5>
<ul class="footer-info-list">
Expand All @@ -54,15 +54,17 @@ <h5 class="footer-info-heading">{{lang 'footer.brands'}}</h5>
<li><a href="{{urls.brands}}">{{lang 'common.view_all'}}</a></li>
</ul>
</article>
{{/if}}
{{/and}}

{{#if settings.address}}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

any reason for not checking this as Or ? What if only phone number exists ?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

if you enter phone number it will require you to enter address as well. No way to have only phone number.

<article class="footer-info-col footer-info-col--small" data-section-type="storeInfo">
<h5 class="footer-info-heading">{{lang 'footer.info'}}</h5>
<address>{{nl2br settings.address}}</address>
{{#if settings.phone_number}}
<strong>{{lang 'footer.call_us' phone_number=settings.phone_number}}</strong>
{{/if}}
</article>
{{/if}}

<article class="footer-info-col" data-section-type="newsletterSubscription">
{{#if settings.show_newsletter_box}}
Expand Down