Added "Cancel" button on AddNew page:
1.Turned off client validation:
AddNew.html, <form t:id="regform" t:clientValidation="false">
2. AddNew.html, added <input t:type="submit" value="Cancel" t:id="Cancel"/>
3. AddNew.java, added
private String _pageToReturn;
------------------------------------
String onSuccess() {
if (_pageToReturn!=null){return _pageToReturn;}...
------------------------------------
void onSelectedFromCancel(){
_regform.clearErrors();
_pageToReturn = "Start";
}
Of course, there should be a better way... Let me search or drop a ray of light, if you have one :).
8. Step 08, Simple authentication
7. SimpleTapestry 5 CRUD application -Step 07, Cancel button, variant 1.
6. SimpleTapestry 5 CRUD application -Step 06, tweaking a grid a bit.
5. Simple Tapestry 5 CRUD application - BeanEditForm and Grid screencasts aprobation.
4. SimpleTapestry 5 CRUD application -Step 04 Adding some basic Hibernate features into the project.
3. SimpleTapestry 5 CRUD application -Step 03, "user" bean creation.
2. SimpleTapestry 5 CRUD application -Step 02, adding a service.
1. SimpleTapestry 5 CRUD application -Step 01.
Subscribe to:
Post Comments (Atom)
1 comment:
Rodrigo, it would be just greate to see your comment in English :).
Post a Comment