Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Preethi 32 posts 99 karma points
    Jun 30, 2016 @ 16:07
    Preethi
    0

    Stock for each variant

    Can we add a stock property for each variant. I have tried adding the stock as a property to the 'Variant' document type. The value does not get saved though.If feasible can we display or update the stock value based on the variant selection in the dropdown. Using Tea Commerce 3.1.0. tks

  • Rune Grønkjær 1371 posts 3102 karma points
    Jul 19, 2016 @ 06:05
    Rune Grønkjær
    0

    Hi Preethi,

    Yes you can. Just make sure that the propery alias is "stock" and you will be fine. Maybe take a look at the demo website where you can log in and check the setup: https://demo.teacommerce.net/umbraco

    /Rune

  • Preethi 32 posts 99 karma points
    Jul 19, 2016 @ 16:02
    Preethi
    0

    Like in your demo site had to add a value to sku. Otherwise the stock value does not get saved. Thanks that worked

  • Rune Grønkjær 1371 posts 3102 karma points
    Jul 20, 2016 @ 05:48
    Rune Grønkjær
    0

    Ah, ofcause. Good that is solved. Please mark your answer for others to see.

    /Rune

  • Preethi 32 posts 99 karma points
    Jul 20, 2016 @ 16:15
    Preethi
    0

    Hi Rune,

    There was a second part to my question. Can we display or update the stock value based on the variant selection in the drop down?

    Tks

  • Preethi 32 posts 99 karma points
    Jul 20, 2016 @ 17:14
    Preethi
    0

    We want to dynamically change the image as well based on the colour of the product. Basically when a variant is selected we want to be able to change a few things on the product page.

  • Rune Grønkjær 1371 posts 3102 karma points
    Jul 21, 2016 @ 05:49
    Rune Grønkjær
    0

    There's a few ways to do that, but we usually write all the different images, prices and whatever you have on your individual variant, to the html. Give the html elements an attribute with the variant id. Each time a new variant is selected you now just have to find the variant html elements, hide them alle and then show the ones for the selected variant.

    All in all just a little jquery magic.

    It is done here: https://www.kitchenone.dk/produkt/ankarsrum-akm-6220-roeremaskine/ with both images and the product price.

    /Rune

  • Rune Grønkjær 1371 posts 3102 karma points
    Jul 21, 2016 @ 05:49
    Rune Grønkjær
    0

    By the way, that would work for the stock as well.

Please Sign in or register to post replies

Write your reply to:

Draft