How to add a column dynamically to a repeating panel

a quick note that using append alone isn’t enough here.
Use either:

self.repeating_panel.items.append({'foo':'baz','message':'Error!'})
self.repeating_panel.items = self.repeating_panel.items

or

self.repeating_panel.items = self.repeating_panel.items  +  [{'foo':'baz','message':'Error!'}]

related topics:


regarding how to loop over the repeating panels - you have some optoins

for componet in repeating_panel.get_components():
  # do something

or use the __init__ method of the ItemTemplate itself

class ItemTemplate(ItemTemplateForm):
   def __init__(self, **properties):
     self.init_components(**properties)
     # now you have self.item
     if self.item['bar']:
        # do something...
        self.bar_component.visible = False

or set databindings on the components of ItemTemplate
Screen Shot 2020-05-21 at 18.31.14


you might also find this post helpful