We are transitioning over to a new forum platform. Please post new issues there. Existing threads will be dealt with here unless you choose to move them over. Visit the new forum

Forum

Thread tagged as: Problem, Error, Runway

Selectize not available on new repeater sections

This is related to a recent forum post: http://forum.grabaperch.com/forum/04-28-2018-selectize-not-instantiated-on-new-repeater-sections-causing-related-fields-to-be-unresponsive

It appears to be a JS issue rather than anything to do with what's possible with Perch. However, I have a different issue, where I am using Runway relationships with repeaters.

HERE'S A 30 SECOND VIDEO OF THIS HAPPENING — https://www.dropbox.com/s/f8haizeqs556by1/Perch%20Selectivizr%20Issue.mp4?dl=0

Here is my code

<perch:repeater id="ingredients_list" label="Ingredients">
    <perch:before><ul></perch:before>
    <li>
        <perch:content id="ingredient_quantity" type="text" label="Quantity" /><perch:content id="ingredient_quantity_type" type="select" label="Quantity Type" options="Items, Table Spoons|tbs, Cups|cup" /><perch:related id="ingredients" collection="Ingredients" label="Ingredients"><perch:content id="ingredient_name"></perch:related>
    </li>
    <perch:after></ul></perch:after>
</perch:repeater>

Why I'm using repeaters with relationships

My scenario is that I'm building a recipe collection.

  • Each recipe has multiple ingredients
  • 'Ingredients' is a separate collection. Ingredients are stored as a collection rather than a simple list because each ingredient also has an associated image.

I'm using repeaters because each ingredient for the recipe also needs a quantity and quantity type.

Here is an example of the output on the page:

Chocolate shake recipe:

  • 1.5 frozen bananas
  • 1 tbs of flak seeds

This actually appears to work on the front end, but the back end Selectize UI is not responsive for multiple entries unless I save/reload the page.

Jay George

Jay George 2 points

  • 1 year ago
Drew McLellan

Drew McLellan 2638 points
Perch Support

Thanks - we'll take a look.