How to edit value of nested object

  • saillmone-1319325572198830141

    saillmone

    3 months ago

    Hello guys,
    I have a "data" variable which groups together several objects.
    I would like, for example, to modify the quantity of the variant items[1].

    I suspect that I should use the Set & get function but I cannot directly reach the right data.

    Can someone help me?

    Thanks guys!
    1319325572362666035-image.png
  • lucasg-1319325770178363403

    Lucas G

    3 months ago

    You do indeed use Set
  • Use an array to specify the path to the item you want to edit
  • variant_items.[index].quantity
  • saillmone-1319334456825221270

    saillmone

    3 months ago

    I try as hard as I can but I can't do it haha.

    It must be not very far but I can't find it, thank you in any case!
    1319334456561238036-image.png
  • lucasg-1319355656565686343

    Lucas G

    3 months ago

    Don’t add the Get node
  • Just an array for the path
  • saillmone-1319398396011741318

    saillmone

    3 months ago

    Wow, more simple than thought ! I spent like 1h to do it working, but it's working now πŸ˜‰
    Thanks for the advice!
    1319398395881721917-image.png
    πŸ‘1

Stop scrolling. Start building.

toddle is a visual web app builder that rivals custom code β€” but accessible to your entire team!

Try toddle β€” it's free!

Β© Copyright 2024 toddle. All rights reserved.