com.aurel.track.admin.fields
Class AdminFieldOptionsAction

java.lang.Object
  extended by DispatchAction
      extended by com.aurel.track.admin.fields.AdminFieldOptionsAction

public final class AdminFieldOptionsAction
extends DispatchAction

Implementation of DispatchAction that processes field options edit/delete/add requests. It handles the options of all build in fields and may be extended to handle all custom field options as well.

Version:
$Revision: 1.18 $
Author:
Joerg Friedrich

Constructor Summary
AdminFieldOptionsAction()
           
 
Method Summary
 ActionForward add(ActionMapping mapping, ActionForm form, HttpServletRequest request, HttpServletResponse response)
          This method handles the add request.
 ActionForward delete(ActionMapping mapping, ActionForm form, HttpServletRequest request, HttpServletResponse response)
          This method handles the delete request.
 ActionForward deleteFinal(ActionMapping mapping, ActionForm form, HttpServletRequest request, HttpServletResponse response)
          This method handles the deleteFinal request.
 ActionForward done(ActionMapping mapping, ActionForm form, HttpServletRequest request, HttpServletResponse response)
          This method handles the done request to return to the previous page.
 ActionForward edit(ActionMapping mapping, ActionForm form, HttpServletRequest request, HttpServletResponse response)
          This method handles the edit request.
 ActionForward load(ActionMapping mapping, ActionForm form, HttpServletRequest request, HttpServletResponse response)
          This method handles the load request.
 ActionForward more(ActionMapping mapping, ActionForm form, HttpServletRequest request, HttpServletResponse response)
          This method handles the done request to return to the previous page.
 ActionForward moveDown(ActionMapping mapping, ActionForm form, HttpServletRequest request, HttpServletResponse response)
          This method handles the moveDown request.
 ActionForward moveUp(ActionMapping mapping, ActionForm form, HttpServletRequest request, HttpServletResponse response)
          This method handles the moveUp request.
 ActionForward save(ActionMapping mapping, ActionForm form, HttpServletRequest request, HttpServletResponse response)
          This method handles the save request.
 ActionForward submitProjectListType(ActionMapping mapping, ActionForm form, HttpServletRequest request, HttpServletResponse response)
          This method handles the submitProjectListType request.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AdminFieldOptionsAction

public AdminFieldOptionsAction()
Method Detail

load

public ActionForward load(ActionMapping mapping,
                          ActionForm form,
                          HttpServletRequest request,
                          HttpServletResponse response)
This method handles the load request. This method is typically called the first time this page is loaded.

Parameters:
mapping - Struts mapping pertaining to this action
form - Struts form bean belonging to this action
request - the calling request
response - where to put the response
Returns:
the new action or input Java Server Page

done

public ActionForward done(ActionMapping mapping,
                          ActionForm form,
                          HttpServletRequest request,
                          HttpServletResponse response)
This method handles the done request to return to the previous page.

Parameters:
mapping - Struts mapping pertaining to this action
form - Struts form bean belonging to this action
request - the calling request
response - where to put the response
Returns:
the new action or input Java Server Page

more

public ActionForward more(ActionMapping mapping,
                          ActionForm form,
                          HttpServletRequest request,
                          HttpServletResponse response)
This method handles the done request to return to the previous page.

Parameters:
mapping - Struts mapping pertaining to this action
form - Struts form bean belonging to this action
request - the calling request
response - where to put the response
Returns:
the new action or input Java Server Page

moveUp

public ActionForward moveUp(ActionMapping mapping,
                            ActionForm form,
                            HttpServletRequest request,
                            HttpServletResponse response)
This method handles the moveUp request. This request serves to change the sequence of field options, that is move the selected field one position up if possible.

Parameters:
mapping - Struts mapping pertaining to this action
form - Struts form bean belonging to this action
request - the calling request
response - where to put the response
Returns:
the new action or input Java Server Page

moveDown

public ActionForward moveDown(ActionMapping mapping,
                              ActionForm form,
                              HttpServletRequest request,
                              HttpServletResponse response)
This method handles the moveDown request. This request serves to change the sequence of field options, that is move the selected field one position down if possible.

Parameters:
mapping - Struts mapping pertaining to this action
form - Struts form bean belonging to this action
request - the calling request
response - where to put the response
Returns:
the new action or input Java Server Page

add

public ActionForward add(ActionMapping mapping,
                         ActionForm form,
                         HttpServletRequest request,
                         HttpServletResponse response)
This method handles the add request. This request serves to enable a new field at the input page where the user can add a new field option. This option is not persistent until the save(ActionMapping, ActionForm, HttpServletRequest, HttpServletResponse) request is called.

Parameters:
mapping - Struts mapping pertaining to this action
form - Struts form bean belonging to this action
request - the calling request
response - where to put the response
Returns:
the new action or input Java Server Page

edit

public ActionForward edit(ActionMapping mapping,
                          ActionForm form,
                          HttpServletRequest request,
                          HttpServletResponse response)
This method handles the edit request. This request serves to enable a new field at the input page where the user can edit the selected option. The modified option is not persistent until the save(ActionMapping, ActionForm, HttpServletRequest, HttpServletResponse) request is called.

Parameters:
mapping - Struts mapping pertaining to this action
form - Struts form bean belonging to this action
request - the calling request
response - where to put the response
Returns:
the new action or input Java Server Page

save

public ActionForward save(ActionMapping mapping,
                          ActionForm form,
                          HttpServletRequest request,
                          HttpServletResponse response)
This method handles the save request. This request saves changes made in the context of an add(ActionMapping, ActionForm, HttpServletRequest, HttpServletResponse) or save(ActionMapping, ActionForm, HttpServletRequest, HttpServletResponse) operation to the database.

Parameters:
mapping - Struts mapping pertaining to this action
form - Struts form bean belonging to this action
request - the calling request
response - where to put the response
Returns:
the new action or input Java Server Page

delete

public ActionForward delete(ActionMapping mapping,
                            ActionForm form,
                            HttpServletRequest request,
                            HttpServletResponse response)
This method handles the delete request. Deletion is a two step process since options that are used in the database and shall be deleted have to be replaced first. Thus this action forwards to an input page offering a selection of possible replacement values.

Only after selecting a replacement value the old option value can be deleted using the deleteFinal(ActionMapping, ActionForm, HttpServletRequest, HttpServletResponse) method.

Parameters:
mapping - Struts mapping pertaining to this action
form - Struts form bean belonging to this action
request - the calling request
response - where to put the response
Returns:
the new action or input Java Server Page

deleteFinal

public ActionForward deleteFinal(ActionMapping mapping,
                                 ActionForm form,
                                 HttpServletRequest request,
                                 HttpServletResponse response)
This method handles the deleteFinal request. Deletion is a two step process since options that are used in the database and shall be deleted have to be replaced first. Thus this action processes the final delete, that means values are first replaced by the selected replacement value and then removed from the database.

Parameters:
mapping - Struts mapping pertaining to this action
form - Struts form bean belonging to this action
request - the calling request
response - where to put the response
Returns:
the new action or input Java Server Page

submitProjectListType

public ActionForward submitProjectListType(ActionMapping mapping,
                                           ActionForm form,
                                           HttpServletRequest request,
                                           HttpServletResponse response)
This method handles the submitProjectListType request. This request saves changes made in the context of an add(ActionMapping, ActionForm, HttpServletRequest, HttpServletResponse) or save(ActionMapping, ActionForm, HttpServletRequest, HttpServletResponse) operation to the database.

Parameters:
mapping - Struts mapping pertaining to this action
form - Struts form bean belonging to this action
request - the calling request
response - where to put the response
Returns:
the new action or input Java Server Page


Issue Tracking with Track+: Home Page      Copyright © 2008 Trackplus. All Rights Reserved.