Getting committed value from nested flex repeater

I have a dynamic ‘table’ of numeric edit fields set up using flex repeaters as follows:

  • ‘Numeric Entry’ view containing a single numeric entry field and view param ‘value’ which is bound bidirectionally to the ‘value’ prop of the numeric entry field component

  • ‘Attribute Values’ view containing a column flex repeater with ‘Numeric Entry’ as the subview. View param ‘instances’ bound bidirectionally to the instances prop of the flex repeater

  • Main view containing a row flex repeater with ‘Attribute Values’ as the subview. The instances prop is populated via script to get data from the sepasoft SPC module.

This main view is a popup to view/modify recorded SPC data, with data committed on OK button.

I’m struggling to get the value of the numeric entry field to commit, even when pressing enter, and I’ve checked that my bindings are bidirectional.

I’ve added a few diagnostic print statements to see what’s happening - I’ve put one in an ‘on change’ script on the value of the numeric entry field and it seems to see the change in value but not commit it.
The main view does not see the updated value. Is there something else I need to be doing to pass the new value back to the main view? Or is it potentially getting overwritten by my script transform?

Here’s the instance binding script on the main flex repeater:

def transform(self, value, quality, timestamp):
	sample = system.mes.spc.sample.getSample(value)
	sampleDef = sample.getSampleDefinition()
	atts = sampleDef.getAllAttributes()
	count = sampleDef.getMeasurementCount()
	instanceData = []
	for att in atts:
		attMeasurements = []
		attName = att.getName()
		for i in range(count):
			sampleData = sample.getSampleData(i+1,attName)
			attMeasurements.append({"value": sampleData})
		instanceData.append({"attName": attName, "instances": attMeasurements})

	return instanceData

Here’s the OK button script

def runAction(self, event):
	sample = system.mes.spc.sample.getSample(self.view.params.SampleUUID)
	attCount = len(self.parent.parent.getChild("FlexRepeater").props.instances)
	for i in range(attCount) :
		measCount = len(self.parent.parent.getChild("FlexRepeater").props.instances[i].instances)
		attName = self.parent.parent.getChild("FlexRepeater").props.instances[i].attName
		for j in range(measCount) :
			sampleValue = str(self.parent.parent.getChild("FlexRepeater").props.instances[i].instances[j].value)

As I mentioned in chat, try setting the prop value param in the template View to in/out as I believe it’s currently set to in at the moment