Closed engram-design closed 1 month ago
This would be awesome - I have a lot of clients requesting this functionality
I've done this with Wishlist using JS and Promises with the existing endpoints and that works well enough, but it would be nice to have official support for creating a list and adding an item to it in one go.
@martyspain Can you please show me an example of how you do create the list and add the item it immediately with JS and Promises? Thank You.
note: I don't use the form element to Add, Remove, Update or Toggle items, simply I use the URL, like:
{% for entry in craft.entries.section('news').all() %}
{% set item = craft.wishlist.item(entry.id) %}
<a href="{{ item.addUrl() }}">Add to List</a>
{% endfor %}
so I don't know how trigger the actions through JavaScript like this example: https://verbb.io/craft-plugins/wishlist/docs/template-guides/managing-items#submit-with-javaScript
Added in 3.0.0
Similar to https://github.com/verbb/wishlist/issues/93 and https://github.com/verbb/wishlist/issues/81 and will likely require some centralised mechanism to keep these things organised