diff options
author | luxagraf <sng@luxagraf.net> | 2023-07-28 13:39:02 -0500 |
---|---|---|
committer | luxagraf <sng@luxagraf.net> | 2023-07-28 13:39:02 -0500 |
commit | 9a620cf42bf1fe6977e378bd834b41ff4a593dde (patch) | |
tree | cf41a0582681cecaf88a30bfe409f9c2be57972a /bak/unused_apps/products/templates | |
parent | 6e5897117124cd60ae81efb1574c6347f48e60e5 (diff) |
main: removed some apps I wasn't using and added bak to git to preserve
a copy of old apps
Diffstat (limited to 'bak/unused_apps/products/templates')
-rw-r--r-- | bak/unused_apps/products/templates/products/snippet.html | 41 |
1 files changed, 41 insertions, 0 deletions
diff --git a/bak/unused_apps/products/templates/products/snippet.html b/bak/unused_apps/products/templates/products/snippet.html new file mode 100644 index 0000000..3fc9f6f --- /dev/null +++ b/bak/unused_apps/products/templates/products/snippet.html @@ -0,0 +1,41 @@ +{% load get_image_by_size %} +{% load get_image_width %} +{% with image=object.featured_image %} +<div itemscope itemtype="http://schema.org/Product" class="product-card"> + <meta itemprop="brand" content="{{object.brand.name}}" /> + <figure itemscope itemtype="http://schema.org/ImageObject" class="picfull"> + <a href="{% get_image_by_size image 'original' %}" title="view larger image"> + <img class="u-photo" itemprop="contentUrl" sizes="(max-width: 750px) 100vw, (min-width: 751) 750px" srcset="{% for size in image.sizes.all%}{% get_image_by_size image size.name %} {{size.width}}w{% if forloop.last%}"{%else%}, {%endif%}{%endfor%}{% for size in image.sizes.all%}{%if not forloop.first and not forloop.last%} src="{% get_image_by_size image size.name%}"{%endif%}{%endfor%} alt="{{image.alt}} photographed by {% if image.photo_credit_source %}{{image.photo_credit_source}}{%else%}luxagraf{%endif%}" > + </a> + <figcaption>{% if image.caption %}{{image.caption|safe}}{% endif %}{% if image.photo_credit_source %}{%if image.caption %} | {%endif%}image: {% if image.photo_credit_url %}<a href="{{image.photo_credit_url}}" itemprop="author">{%endif%}{{image.photo_credit_source|lower}}{% if image.photo_credit_url %}</a>{%endif%}{%endif%} + </figcaption> + </figure> + <div class="buy-btn-wrapper"> + <h4 class="product-header" itemprop="name">{{object.get_full_name}}</h4> + <h5 class="product-link" itemprop="offers" itemscope itemtype="http://schema.org/Offer"> + <a href="{{object.primary_offer_url}}" title="buy the {{object.get_full_name}} for ${{object.primary_offer_price}} from {{object.primary_offer_retailer.get_primary_offer_retailer_display}}" itemprop="url" rel="nofollow"> + Buy Now ({{object.get_primary_offer_retailer_display}} + <span itemprop="priceCurrency" content="USD">$</span><span itemprop="price" content="{{object.primary_offer_price}}">{{object.primary_offer_price}}</span>) + </a> + <link itemprop="availability" href="http://schema.org/InStock" /> + </h5>{% if object.secondary_offer_url %} + <h5 class="product-link" itemprop="offers" itemscope itemtype="http://schema.org/Offer"> + <a href="{{object.secondary_offer_url}}" title="buy the {{object.get_full_name}} for ${{object.secondary_offer_price}} from {{object.secondary_offer_retailer.get_secondary_offer_retailer_display}}" itemprop="url"> + Buy Now ({{object.get_secondary_offer_retailer_display}} + <span itemprop="priceCurrency" content="USD">$</span><span itemprop="price" content="{{object.secondary_offer_price}}">{{object.secondary_offer_price}}</span>) + </a> + <link itemprop="availability" href="http://schema.org/InStock" /> + </h5>{% endif %} + </div> + <span itemprop="review" itemscope itemtype="http://schema.org/Review"> + <meta itemprop="name" content="{{object.get_full_name}}" /> + <meta itemprop="author" content="Scott Gilbertson" /> + <meta itemprop="datePublished" content="{{object.pub_date}}" /> + <span itemprop="reviewRating" itemscope itemtype="http://schema.org/Rating"> + <meta itemprop="worstRating" content = "1"/> + <meta itemprop="ratingValue" content="{{object.rating}}" /> + <meta itemprop="bestRating" content="10" /> + </span> + <meta itemprop="description" content="{{object.body_markdown}}" /> +</div> +{% endwith %} |