How can I add a core (additional) charge to a product?

Highlighted
New Member
2 0 0

I am selling vehicle parts through the website I created with shopify. Does anyone know how to add a core charge to a product? A core charge is an additional charge that is charged at the time of the sale and then once the customer returns their original part, they are refunded that charge.

For example, a customer purchases an axle for $200. There would be an additional core charge of $50 added to the sale, totalling $250 for the axle. The customer will receive the new axle and take their current axle off of their vehicle, repackage it and send it back to us. Once we receive their old axle, we will refund the $50 core charge. If they do not return an axle in the alloted time, there will be no refund.

Is it possible to add a core charge and if so, how can I do this? I would really appreciate any help.

Thank you in advance!

-Tim

0 Likes
Highlighted
Shopify Expert
463 0 84

You could set up your product variant with the total price, product price + core charge. Then for display purposes on the collection and product pages, you could create a metafield with the core charge as an integer (50) that you could check and use liquid math the subtract that amount from the variant/product price.

{% assign price = product.price %}
{% if product.metafields.charge.value %}
  {% assign price = price | money_without_currency | minus: product.metafields.charge.value | times: 100 %}
{% endif %}

<h3>{{ price | money }}</h3>

 

0 Likes
Highlighted
New Member
2 0 0

Thank you for your response. I managed to get this working on the product page but not on the collection page. Metafields are a little beyond my skill level and because of my unfamiliarity with Shopify's templating system, I will make a call to Shopify to receive some help on this matter. Thank you for your help in directing me in the way I need to go!

0 Likes
Highlighted
New Member
1 0 0

I realize this post is pretty old but curious what you are shopify was able to do to, To get this working ?

0 Likes