Hi I recently started using
Struts and I'm still very noob
I wanted to develop something easy, so I decided to create a project to Insert, Delete, Update and Select Records from a Single Table and I don't know how to create the Actions, Should I create something like this ??:
InsertAction extends ActionSupport
EditAction extends ActionSupport
UpdateAction extends ActionSupport
SelectAction extends ActionSupport
And my struts.xml should only containg results for,input,error and success for each Action?
I'm asking this because I was creating only one Action Class named
TableAction and there I was calling methods in this way:
tableAction_insert.action
tableAction_edit.action
And my struts.xml contain different results for each action:
for example:
insert method returns "insertSuccess"
and I have a result called "insertSuccess" which is mapped to "insertSuccess.jsp"
But I have some troubles when trying to validate the form, cause I didn't have any "input" result, so my form wasn't validated.
So what's the most correct way to do what I'm trying to do??
I hope you can help me.
Thanks