Error when on change for link lookup is fired during onload

Posted by Rollbase User on 06-Mar-2012 03:34

Good Day, As per update of latest binaries in .com to fix the link lookup issue as raised by martin, i've tested it again and found out that there still some issues in firing the onchange event during onload event of the pages. I've attached some screen shots for reference. Thanks, Ruben Guico Rollbase PH

All Replies

Posted by Admin on 06-Mar-2012 12:04

I suggest you fix your JavaScript handler.

Posted by Admin on 07-Mar-2012 00:33

Hi,



I've reviewed the script but it seems the real cause of the error is because the scripts in the onchange event of link lookup were invoked during population of the records from the link lookup upon selection in the parent lookup, i've attached some reference screen shots, onchange is fired onload as per update but shouldn't fire when the link lookup is populated with dependent records, it should only fire when i've selected a record from the link lookup.



Regards,



Ruben Guico

Rollbase PH











Posted by Admin on 07-Mar-2012 11:20

Perhaps Martin can help you.

Posted by Admin on 07-Mar-2012 17:01

Hi Pavel,



Just for confirmation,

The new behavior of the component is that it calls the onchange of the link lookup even though it hasn't changed value yet?.



Thanks

Piscoso Martin

Posted by Admin on 07-Mar-2012 20:11

onchange() is called explicitly since set of choices has changed

Posted by Admin on 11-Mar-2012 19:27

Hi Pavel,



I've retested on .com, Thank you very much for adding the handler on the link lookup where if (newValue != oldValue) it's the only time the onchange will fire, this handles the explicit firing when the data is loaded and the selection is not changed ^_^



Piscoso Martin

Rollbase.ph

This thread is closed