Skip to main content
1-Visitor
July 18, 2017
Question

Binding Widget

  • July 18, 2017
  • 1 reply
  • 1219 views

Hello ,

I'm currently having an issue with a widget i am creating , everything is set in place in javascript , the widget can take information from the widget with no properties with no problem but when it comes to binding information onto the widget it doesn't seem to work for some reason ,  it seems that updateProperty function doesn't run at all .

here's part of my code :

RUNTIME :

this.updateProperty = function (updatePropertyInfo) {

console.log("ListCheckBox : updateProperty executes");

if(updatePropertyInfo.TargetProperty === 'DATA') {

var singleProperty = updatePropertyInfo.SinglePropertyValue;

this.setProperty('DATA', singleProperty);

this.afterRender();

}

if(updatePropertyInfo.TargetProperty === 'RESULT_DATA') {

var singleProperty = updatePropertyInfo.SinglePropertyValue;

this.setProperty('RESULT_DATA', singleProperty);

this.afterRender();

}

    };

   

    IDE :

    ​    

this.afterSetProperty = function (name, value) {

var refreshHtml = false;

switch (name) {

case 'DATA':

refreshHtml = true;

break;

case 'RESULT_DATA' :

refreshHtml = true;

break;

default:

refreshHtml = true;

break;

}

return refreshHtml;

};

this.afterAddBindingSource = function (bindingInfo) {

if (bindingInfo.targetProperty == 'DATA') {

this.updatedProperties();

}

if (bindingInfo.targetProperty == 'RESULT_DATA') {

this.updatedProperties();

}

};

   

        

All the functions in the runtime run normally , renderHTML() , afterRender() ... but UpdateProprety doesn't run at all , the console.log I put there doesn't show up.

1 reply

5-Regular Member
July 18, 2017

Hello, Youssef Ahkouk.

I'm trying to locate a resource to help us answer this. Thanks for your patience.

-- Craig A.