I believe this might be similar to this question Adornment & Databinding Question
I’m adding a selectionAdornmentTemplate to a nodeTemplate. which is basically like an expanding button which I’m checking to see if is visible based on a property, but this only seems to be triggered before I do any work.
Flow is: click on node, goes to check property in template
new gojs.Binding('visible', 'connectionsDown', function (h, shape) {
if (shape.part.data.hasConnections && h) {
return true;
}
}),
then goes to my function where I update the 2 properties “hasConnections” and “connectionsDown”
myDiagram.model.setDataProperty(node, 'hasConnections', connections);
myDiagram.model.setDataProperty(node, 'connectionsDown', true);
I was expecting trigger in visible binding to be called again.
NOTE: I’m starting with this 2 properties as False and the visible property is also defaulted to False
Any help/advice?