Button is not saving the value on multiple clicks

Certified Senior Developer

Hello All,

I have a requirement where user can open the ui and redirects to the url that was mentioned in the ui and can change the data in the new tab.

After changing the data. we are giving an buttonwidget in the ui to refresh a variable to know whether data had changed or not. It returns true or false based on the actions done in the different tab.

But the problem I am seeing button is not working as expected.

Below is the code

a!buttonWidget(
label: "REFRESH",
value:ri!refresh,
saveInto:
{

a!save(
ri!refresh,
rule!SD_IsDataChanged(

)id:ri!id
)
},

On the above i am getting the data from the database to check data is updated or not and storing in the refresh variable. the problem here is first when user clicked on the refresh , refresh variable is storing the expected value. but later if i change the data and click on the button again it still having the same value. i doubt whether button save is working or not beacuse when i open the actual rule its giving the correct boolean value.

What i observed is if ri!refresh had a value already. its not saving again. The thing is i am testing this in normal designer ui. not even in site. 

Can someone pls help on this?

Thanks in Advance!!

),

  Discussion posts and replies are publicly visible

Parents Reply Children
No Data