AtomPostButton

AtomPostButton performs AJAX Post Operation when clicked. AtomPostButton also supports confirmation, if set to true, user will be alerted and only after user's confirmation, post activity will be performed. As usual, this control has "next" action set, that will be performed after successful post operation.

In order to give more flexibility, post operation will be performed using postData property of button, if postData is not set, than data property will be posted. This is sometime useful in case when we want to send only "id" of object instead of posting whole object for operations like delete, archive etc.

If postUrl property of AtomPostButton is not set, AtomPostButon will simply act as AtomButton and execute next action event. This will not post data to same page url.

In this example, we have added a  button in every row, and we have added postUrl and postData properties. if postData is not specified, current inherited data property will be posted to the postUrl. postData is useful when we want to send only part of data, for example, only primary key of the object.

While executing this example, you can check in network section in debugging, what will be posted. However, we do not have server side implementation, so no action will be taken. However if the operation on server side was successful, next action set will be invoked, that will be, list will refresh its contents.

If you use AtomDeleteButton, confirm is automatically set to true, so it will always confirm the user before executing the action.

Difference between Form Post and AtomPostButton: AtomPostButton does not do any validation on data, if you want to perform validation, you must use AtomForm control along with input[type=submit].