Hello,
I have a custom widget where I not able to update the property value.
I did a simplified version of this widget as it follows here:
Template: just a link element (<a>) with id=a (your forum is parsing html )
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<a id="a" href='#'></a></div>
Controller:
function ($scope) {
var a = document.getElementById("a");
a.innerHTML = "Save scope value";
a.addEventListener("click", function(event){
console.log("event detected");
updateValue();
});
updateValue = function(){
console.log("passing here");
$scope.properties.value = "updated value";
};
$scope.properties.value = "init value";}
And then I created a property called value of type "Biderectional bond".
I'd expect that when I click on the link with id="a" the property is updated, but the value is always = "init value".
I can see the message "passing here" logged.
How can I fix this?
Please help
thanks