Enable collection condition

You are here:
Estimated reading time: 1 min

To show the auction widget on the collection page, you need to enable the Collection conditions.

The required step is to create a new file in your theme to enable this condition.

Steps to manage

1. From Shopify admin page > click Themes > click Edit code

2. Under the Template folder, create a new file with the Search template

3. Create a new liquid file > enter name tipoAuctionsJson so the full file name will be search.tipoAuctionsJson.liquid

 

4. Copy the codes below and paste into search.tipoAuctionsJson.liquid file

{%- layout none -%}
{%- paginate search.results by 100 -%}
[{%- for product in search.results -%}
{%- unless forloop.first -%},{%- endunless -%}
{
"id":{{-product.id-}},
"title":{{-product.title | json-}},
"handle":"{{-product.handle-}}",
"price":"{{-product.price-}}",
"featured_image":"{{-product.featured_image-}}",
"url":"{{-product.url-}}",
"collections":{{-product.collections | map: 'id' | json-}},
"images":[
{%- for image in product.images -%}{%- unless forloop.first -%},
{%- endunless -%}{"id":{{-image.id-}},
"src":{{-image.src | json-}}}{%- endfor -%}],
"first_available_variant":{"id":{{product.selected_or_first_available_variant.id}}},
"available":{{-product.available-}},
"variants":[
{%- for variant in product.variants -%}{%- unless forloop.first -%},
{%- endunless -%}
{
"id":{{-variant.id-}},
"value":{{-variant.id-}},
"title":{{-variant.title | json}},
"name":"{{-variant.name | json}}",
"price":{{-variant.price-}},
"available":{{-variant.available-}},
"sku":"{{-variant.sku-}}",
"inventory_quantity":{{-variant.inventory_quantity-}}
}
{%- endfor -%}
]
}
{%- endfor -%}]
{%- endpaginate -%}

5. Click Save to finish creating this new file

6. IMPORTANT step: Go back to the Tipo Product Auction app, open the Theme  Integrate  section so the latest codes are being pushed to the theme/app data.

Need support?

If you cannot figure it out, don’t hesitate to contact us via email [email protected]. We are happy to help!

Was this article helpful?
Dislike 0
Views: 511