|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.apache.struts.action.ActionForm org.kuali.rice.kns.web.struts.pojo.PojoFormBase org.kuali.rice.kns.web.struts.form.KualiForm org.kuali.rice.kns.web.struts.form.KualiDocumentFormBase
public abstract class KualiDocumentFormBase
TODO we should not be referencing kew constants from this class and wedding ourselves to that workflow application This class is the base action form for all documents.
Field Summary | |
---|---|
private List<String> |
additionalScriptFiles
|
protected Map |
adHocActionRequestCodes
|
private String |
annotation
|
protected org.apache.struts.upload.FormFile |
attachmentFile
|
private List |
boNotes
|
private String |
command
|
private String |
docId
|
private String |
docNum
|
private String |
docTypeName
|
private Document |
document
|
protected Map |
documentActions
|
protected Map |
editingMode
|
private MessageMap |
errorMapFromPreviousRequest
Stores the error map from previous requests, so that we can continue to display error messages displayed during a previous request |
private String |
formKey
|
private static org.apache.log4j.Logger |
LOG
|
private AdHocRoutePerson |
newAdHocRoutePerson
|
private AdHocRouteWorkgroup |
newAdHocRouteWorkgroup
|
private Note |
newNote
|
private boolean |
returnToActionList
|
private static long |
serialVersionUID
|
protected boolean |
suppressAllButtons
|
Fields inherited from class org.kuali.rice.kns.web.struts.form.KualiForm |
---|
extraButtons |
Fields inherited from class org.kuali.rice.kns.web.struts.pojo.PojoFormBase |
---|
requiredNonEditableProperties |
Fields inherited from class org.apache.struts.action.ActionForm |
---|
multipartRequestHandler, servlet |
Constructor Summary | |
---|---|
KualiDocumentFormBase()
no args constructor that just initializes things for us |
Method Summary | |
---|---|
void |
addRequiredNonEditableProperties()
This method adds the required property names, that are not directly editable by user on the html page, to a list, regardless of the context in which they appear. |
protected String |
buildHtmlLink(String url,
String linkBody)
|
protected void |
customInitMaxUploadSizes()
Adds the attachment file size to the list of max file sizes. |
String |
getAdditionalScriptFile(int index)
|
List<String> |
getAdditionalScriptFiles()
|
Map |
getAdHocActionRequestCodes()
|
AdHocRoutePerson |
getAdHocRoutePerson(int index)
Special getter based on index to work with multi rows for ad hoc routing to persons struts page |
List<AdHocRoutePerson> |
getAdHocRoutePersons()
|
AdHocRouteWorkgroup |
getAdHocRouteWorkgroup(int index)
Special getter based on index to work with multi rows for ad hoc routing to workgroups struts page |
List<AdHocRouteWorkgroup> |
getAdHocRouteWorkgroups()
get the ad hoc routing workgroup requests |
String |
getAnnotation()
|
org.apache.struts.upload.FormFile |
getAttachmentFile()
|
List |
getBoNotes()
Gets the boNotes attribute. |
String |
getCommand()
|
protected String |
getDefaultDocumentTypeName()
|
String |
getDocId()
|
String |
getDocNum()
|
String |
getDocTypeName()
getter for the docTypeName that was passed from workflow on the url |
Document |
getDocument()
|
Map |
getDocumentActions()
|
private Class<? extends Document> |
getDocumentClass()
gets the document class from the datadictionary if getDefaultDocumentTypeName() is overriden to return a valid value otherwise behavior is nondeterministic. |
protected String |
getDocumentHandlerUrl(String documentId)
|
Map |
getEditingMode()
|
String |
getFormKey()
|
Person |
getInitiator()
|
String |
getInitiatorNetworkId()
getter for convenience that will return the initiators network id |
MessageMap |
getMessageMapFromPreviousRequest()
|
AdHocRoutePerson |
getNewAdHocRoutePerson()
|
AdHocRouteWorkgroup |
getNewAdHocRouteWorkgroup()
|
Note |
getNewNote()
|
protected String |
getPersonInquiryUrlLink(Person user,
String linkBody)
|
protected List<HeaderField> |
getStandardHeaderFields(KualiWorkflowDocument workflowDocument)
This method returns a list of HeaderField objects that are used by default on Kuali document display pages. |
KualiWorkflowDocument |
getWorkflowDocument()
|
boolean |
hasDocumentId()
|
protected void |
initializeHeaderNavigationTabs()
initializes the header tabs from what is defined in the datadictionary if getDefaultDocumentTypeName() is overriden to return a valid value. |
protected void |
instantiateDocument()
will instatiate a new document setting it on the form if getDefaultDocumentTypeName() is overriden to return a valid value. |
boolean |
isDocumentEnRoute()
|
boolean |
isFormDocumentInitialized()
|
boolean |
isHasWorkflowDocument()
Null-safe check to see if the workflow document object exists before attempting to retrieve it. |
boolean |
isReturnToActionList()
|
boolean |
isSuppressAllButtons()
Gets the suppressAllButtons attribute. |
boolean |
isUserDocumentInitiator()
TODO rk implemented to account for caps coming from kuali user service from workflow |
void |
populate(javax.servlet.http.HttpServletRequest request)
Setup workflow doc in the document. |
void |
populateHeaderFields(KualiWorkflowDocument workflowDocument)
This method is used to populate the list of header field objects (see KualiForm.getDocInfo() ) displayed on
the Kuali document form display pages. |
void |
reset(org.apache.struts.action.ActionMapping mapping,
javax.servlet.http.HttpServletRequest request)
|
void |
setAdditionalScriptFile(int index,
String scriptFile)
|
void |
setAdditionalScriptFiles(List<String> additionalScriptFiles)
|
void |
setAdHocActionRequestCodes(Map adHocActionRequestCodes)
|
void |
setAdHocRoutePersons(List<AdHocRoutePerson> adHocRouteRecipients)
set the ad hoc routing persons list |
void |
setAdHocRouteWorkgroups(List<AdHocRouteWorkgroup> adHocRouteWorkgroups)
set the ad hoc routing workgroup requests |
void |
setAnnotation(String annotation)
|
void |
setAttachmentFile(org.apache.struts.upload.FormFile attachmentFile)
|
void |
setBoNotes(List boNotes)
Sets the boNotes attribute value. |
void |
setCommand(String command)
setter for the command that was passed from workflow on the url |
void |
setDerivedValuesOnForm(javax.servlet.http.HttpServletRequest request)
|
void |
setDocId(String docId)
setter for the docId that was passed from workflow on the url |
void |
setDocNum(String docNum)
|
void |
setDocTypeName(String docTypeName)
setter for the docTypeName that was passed from workflow on the url |
void |
setDocument(Document document)
|
void |
setDocumentActions(Map documentActions)
|
void |
setEditingMode(Map editingMode)
Set editingMode for this document |
void |
setFormKey(String formKey)
|
void |
setMessageMapFromPreviousRequest(MessageMap errorMapFromPreviousRequest)
|
void |
setNewAdHocRoutePerson(AdHocRoutePerson newAdHocRoutePerson)
set the new ad hoc route person object |
void |
setNewAdHocRouteWorkgroup(AdHocRouteWorkgroup newAdHocRouteWorkgroup)
set the new ad hoc route workgroup object |
void |
setNewNote(Note newNote)
|
void |
setReturnToActionList(boolean returnToActionList)
Sets flag indicating whether upon completion of approve, blanketApprove, cancel, or disapprove, the user should be returned to the actionList instead of to the portal |
void |
setSuppressAllButtons(boolean suppressAllButtons)
Sets the suppressAllButtons attribute value. |
boolean |
shouldMethodToCallParameterBeUsed(String methodToCallParameterName,
String methodToCallParameterValue,
javax.servlet.http.HttpServletRequest request)
This overridden method ... |
boolean |
shouldPropertyBePopulatedInForm(String requestParameterName,
javax.servlet.http.HttpServletRequest request)
This overridden method ... |
org.apache.struts.action.ActionErrors |
validate(org.apache.struts.action.ActionMapping mapping,
javax.servlet.http.HttpServletRequest request)
|
Methods inherited from class org.apache.struts.action.ActionForm |
---|
getMultipartRequestHandler, getServlet, getServletWrapper, setMultipartRequestHandler, setServlet, validate |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
private static final long serialVersionUID
private static final org.apache.log4j.Logger LOG
private Document document
private String annotation
private String command
private String docId
private String docTypeName
private List<String> additionalScriptFiles
private AdHocRoutePerson newAdHocRoutePerson
private AdHocRouteWorkgroup newAdHocRouteWorkgroup
private Note newNote
private List boNotes
protected org.apache.struts.upload.FormFile attachmentFile
protected Map editingMode
protected Map documentActions
protected boolean suppressAllButtons
protected Map adHocActionRequestCodes
private boolean returnToActionList
private String formKey
private String docNum
private MessageMap errorMapFromPreviousRequest
Constructor Detail |
---|
public KualiDocumentFormBase()
Method Detail |
---|
public void addRequiredNonEditableProperties()
PojoForm
addRequiredNonEditableProperties
in interface PojoForm
addRequiredNonEditableProperties
in class KualiForm
KualiForm.addRequiredNonEditableProperties()
public String getDocNum()
public void setDocNum(String docNum)
docNum
- the docNum to setpublic void populate(javax.servlet.http.HttpServletRequest request)
populate
in interface PojoForm
populate
in class KualiForm
protected String getPersonInquiryUrlLink(Person user, String linkBody)
protected String getDocumentHandlerUrl(String documentId)
protected String buildHtmlLink(String url, String linkBody)
public void populateHeaderFields(KualiWorkflowDocument workflowDocument)
KualiForm.getDocInfo()
) displayed on
the Kuali document form display pages.
workflowDocument
- - the workflow document of the document being displayed (null is allowed)protected List<HeaderField> getStandardHeaderFields(KualiWorkflowDocument workflowDocument)
HeaderField
objects that are used by default on Kuali document display pages. To
use this list and override an individual HeaderField
object the id constants from
KNSConstants.DocumentFormHeaderFieldIds
can be used to identify items from the list.
workflowDocument
- - the workflow document of the document being displayed (null is allowed)
public org.apache.struts.action.ActionErrors validate(org.apache.struts.action.ActionMapping mapping, javax.servlet.http.HttpServletRequest request)
validate
in class org.apache.struts.action.ActionForm
ActionForm.validate(org.apache.struts.action.ActionMapping,
javax.servlet.http.HttpServletRequest)
public final boolean isFormDocumentInitialized()
public Map getEditingMode()
public void setEditingMode(Map editingMode)
public Map getDocumentActions()
public void setDocumentActions(Map documentActions)
documentActions
- the documentActions to setpublic void setAdHocActionRequestCodes(Map adHocActionRequestCodes)
adHocActionRequestCodes
- the adHocActionRequestCodes to setpublic Map getAdHocActionRequestCodes()
public List<AdHocRoutePerson> getAdHocRoutePersons()
public org.apache.struts.upload.FormFile getAttachmentFile()
public void setAttachmentFile(org.apache.struts.upload.FormFile attachmentFile)
attachmentFile
- The attachmentFile to set.public void setAdHocRoutePersons(List<AdHocRoutePerson> adHocRouteRecipients)
adHocRouteRecipients
- public List<AdHocRouteWorkgroup> getAdHocRouteWorkgroups()
public void setAdHocRouteWorkgroups(List<AdHocRouteWorkgroup> adHocRouteWorkgroups)
adHocRouteWorkgroups
- public AdHocRoutePerson getAdHocRoutePerson(int index)
index
-
public AdHocRouteWorkgroup getAdHocRouteWorkgroup(int index)
index
-
public AdHocRoutePerson getNewAdHocRoutePerson()
public void setNewAdHocRoutePerson(AdHocRoutePerson newAdHocRoutePerson)
newAdHocRoutePerson
- public AdHocRouteWorkgroup getNewAdHocRouteWorkgroup()
public void setNewAdHocRouteWorkgroup(AdHocRouteWorkgroup newAdHocRouteWorkgroup)
newAdHocRouteWorkgroup
- public Document getDocument()
public void setDocument(Document document)
document
- public KualiWorkflowDocument getWorkflowDocument()
public boolean isHasWorkflowDocument()
public boolean isUserDocumentInitiator()
public Person getInitiator()
public boolean isDocumentEnRoute()
public void setAnnotation(String annotation)
annotation
- The annotation to set.public String getAnnotation()
public String getCommand()
public void setCommand(String command)
command
- public String getDocId()
public void setDocId(String docId)
docId
- public String getDocTypeName()
public void setDocTypeName(String docTypeName)
docTypeName
- public String getInitiatorNetworkId()
public final boolean isSuppressAllButtons()
public final void setSuppressAllButtons(boolean suppressAllButtons)
suppressAllButtons
- The suppressAllButtons to set.public boolean hasDocumentId()
public void setReturnToActionList(boolean returnToActionList)
returnToActionList
- public boolean isReturnToActionList()
public List<String> getAdditionalScriptFiles()
public void setAdditionalScriptFiles(List<String> additionalScriptFiles)
public void setAdditionalScriptFile(int index, String scriptFile)
public String getAdditionalScriptFile(int index)
public Note getNewNote()
public void setNewNote(Note newNote)
public List getBoNotes()
public void setBoNotes(List boNotes)
boNotes
- The boNotes to set.public String getFormKey()
public void setFormKey(String formKey)
public void reset(org.apache.struts.action.ActionMapping mapping, javax.servlet.http.HttpServletRequest request)
reset
in class KualiForm
ActionForm.reset(org.apache.struts.action.ActionMapping, javax.servlet.http.HttpServletRequest)
protected void customInitMaxUploadSizes()
customInitMaxUploadSizes
in class PojoFormBase
PojoFormBase.customInitMaxUploadSizes()
public boolean shouldPropertyBePopulatedInForm(String requestParameterName, javax.servlet.http.HttpServletRequest request)
shouldPropertyBePopulatedInForm
in interface PojoForm
shouldPropertyBePopulatedInForm
in class KualiForm
requestParameterName
- the name of the request parameterrequest
- the HTTP request
PojoFormBase.shouldPropertyBePopulatedInForm(java.lang.String, javax.servlet.http.HttpServletRequest)
public boolean shouldMethodToCallParameterBeUsed(String methodToCallParameterName, String methodToCallParameterValue, javax.servlet.http.HttpServletRequest request)
shouldMethodToCallParameterBeUsed
in class KualiForm
KualiForm.shouldMethodToCallParameterBeUsed(java.lang.String, java.lang.String, javax.servlet.http.HttpServletRequest)
public MessageMap getMessageMapFromPreviousRequest()
public void setMessageMapFromPreviousRequest(MessageMap errorMapFromPreviousRequest)
public void setDerivedValuesOnForm(javax.servlet.http.HttpServletRequest request)
setDerivedValuesOnForm
in class KualiForm
protected String getDefaultDocumentTypeName()
protected void instantiateDocument()
getDefaultDocumentTypeName()
is overriden to return a valid value.
private Class<? extends Document> getDocumentClass()
getDefaultDocumentTypeName()
is overriden to return a valid value otherwise behavior is nondeterministic.
protected void initializeHeaderNavigationTabs()
getDefaultDocumentTypeName()
is overriden to return a valid value.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |