cancel
Showing results for 
Search instead for 
Did you mean: 

Refresh Context node

Former Member
0 Kudos

Hi,

I have created a context node in my controller. Then i mapped the context of controller to the context of view. Now the context of view contains some data in InputField UI. I save data by calling a save method. I want to refresh the data on frontend so I am invalidating the context node in save method at the end. But, I am not able to do it. Screen is not getting refreshed.

I dont want the data which was mapped from controller to view should vanish.

I want the updated controller context data should get reflected in view's context.

Can anybody help me in this case?

Regards,

Vaibhav.

Accepted Solutions (0)

Answers (2)

Answers (2)

0 Kudos

Hi Vaibhav,

you shouldn't invoke the invalidate method at the end of you save method because invalidating a context node means, in this case, deleting the data stored in that node.

If I understand you correctly the context of your input fields is bound to (or simply referencing) the context of a custom controller, that means if you change the data in the context of the view controller you implicitly change the data in the custom controller and vice versa.

Regards,

Christian

P.S. The method name "invalidate" is sometimes a little bit misleading, because sometimes you <b>delete</b> the data of a node and sometimes you <b>update</b> the data of a node (when the node is bound to a model node).

Former Member
0 Kudos

Hi Vaibhav,

In your Save action bind the node to a null collection, set the updated data and call/execute the RFC if any.

Collection c = null;

wdContext.node<nodeName()>.bind(c);

Regards,

Jhansi