Class Form
java.lang.Object
fr.paris.lutece.plugins.forms.business.Form
- All Implemented Interfaces:
fr.paris.lutece.portal.service.rbac.RBACResource,fr.paris.lutece.portal.service.workgroup.AdminWorkgroupResource,Serializable,Comparator<Form>
public class Form
extends Object
implements fr.paris.lutece.portal.service.workgroup.AdminWorkgroupResource, fr.paris.lutece.portal.service.rbac.RBACResource, Comparator<Form>, Serializable
This is the business class for the object Form
- See Also:
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final StringForm resource typestatic final intState of forms that are disabledstatic final intState of forms that are enabled -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionintCustom comparator for Availability Period sortingReturns the AvailabilityEndDateReturns the AvailabilityStartDateReturns the BreadcrumbNameReturns the CreationDateintReturns the DescriptionintgetId()Returns the IdintintGetter for id_workflowfr.paris.lutece.portal.business.file.FilegetLogo()Get the content of the logo as base64intReturns the number Max of response formReturns the return URLgetTitle()Returns the TitleReturns the UpdateDatebooleanReturns true if the access to responses management on FO is based on the roles, false otherwisebooleanisActive()Returns the active status of a form by checking if we are currently within its availability periodbooleanbooleanbooleanbooleanbooleanbooleanbooleanTells if the summary must be displayedbooleanCheck the user can only submit one form.voidsetAccessToResponsesByRole(boolean bAccessToResponsesByRole) Sets the AccessToResponsesByRolevoidsetActions(List<FormAction> formActions) set a list of action can be use for the formvoidsetAuthentificationNeeded(boolean bAuthentificationNeeded) voidsetAvailabilityEndDate(Timestamp dateAvailabilityEndDate) Sets the AvailabilityEndDatevoidsetAvailabilityStartDate(Timestamp dateAvailabilityStartDate) Sets the AvailabilityStartDatevoidsetBackupEnabled(boolean bBackupEnabled) voidsetBreadcrumbName(String strBreadcrumbName) Sets the TitlevoidsetCaptchaRecap(boolean bCaptchaRecap) voidsetCaptchaStepFinal(boolean bCaptchaStepFinal) voidsetCaptchaStepInitial(boolean bCaptchaStepInitial) voidsetCountResponses(boolean bCountResponse) voidsetCreationDate(Timestamp creationDate) Sets the CreationDatevoidsetCurrentNumberResponse(int nCurrentNumberResponse) voidsetDescription(String strDescription) Sets the DescriptionvoidsetDisplaySummary(boolean bDisplaySummary) Sets if the summary must be displayedvoidsetId(int nId) Sets the IdvoidsetIdCategory(int nIdCategory) voidsetIdWorkflow(int nIdWorkflow) setter for id_workflowvoidsetLabelFinalButton(String labelFinalButton) voidsetLogo(fr.paris.lutece.portal.business.file.File logo) voidsetMaxNumberResponse(int nMaxNumberResponse) Sets the number Max of response formvoidsetOneResponseByUser(boolean bOneResponseByUser) set true if the user can submit just once the formvoidsetReturnUrl(String strReturnUrl) Sets the return URLvoidSets the TitlevoidsetUnavailableMessage(String strUnavailableMessage) voidsetUpdateDate(Timestamp dateUpdate) Sets the UpdateDatevoidsetWorkgroup(String workGroup) set the work group associate to the formMethods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface java.util.Comparator
equals, reversed, thenComparing, thenComparing, thenComparing, thenComparingDouble, thenComparingInt, thenComparingLong
-
Field Details
-
RESOURCE_TYPE
Form resource type- See Also:
-
STATE_ENABLE
public static final int STATE_ENABLEState of forms that are enabled- See Also:
-
STATE_DISABLE
public static final int STATE_DISABLEState of forms that are disabled- See Also:
-
-
Constructor Details
-
Form
public Form()Default constructor
-
-
Method Details
-
getId
public int getId()Returns the Id- Returns:
- The Id
-
setId
public void setId(int nId) Sets the Id- Parameters:
nId- The Id
-
getTitle
Returns the Title- Returns:
- The Title
-
setTitle
Sets the Title- Parameters:
strTitle- The Title
-
getDescription
Returns the Description- Returns:
- The Description
-
setDescription
Sets the Description- Parameters:
strDescription- The Description
-
getCreationDate
Returns the CreationDate- Returns:
- The CreationDate
-
setCreationDate
Sets the CreationDate- Parameters:
creationDate- The CreationDate
-
getUpdateDate
Returns the UpdateDate- Returns:
- The UpdateDate
-
setUpdateDate
Sets the UpdateDate- Parameters:
dateUpdate- The UpdateDate
-
getAvailabilityStartDate
Returns the AvailabilityStartDate- Returns:
- The AvailabilityStartDate
-
setAvailabilityStartDate
Sets the AvailabilityStartDate- Parameters:
dateAvailabilityStartDate- The AvailabilityStartDate
-
getAvailabilityEndDate
Returns the AvailabilityEndDate- Returns:
- The AvailabilityEndDate
-
setAvailabilityEndDate
Sets the AvailabilityEndDate- Parameters:
dateAvailabilityEndDate- The AvailabilityEndDate
-
getResourceTypeCode
- Specified by:
getResourceTypeCodein interfacefr.paris.lutece.portal.service.rbac.RBACResource
-
getResourceId
- Specified by:
getResourceIdin interfacefr.paris.lutece.portal.service.rbac.RBACResource
-
getWorkgroup
- Specified by:
getWorkgroupin interfacefr.paris.lutece.portal.service.workgroup.AdminWorkgroupResource
-
setWorkgroup
set the work group associate to the form- Parameters:
workGroup- the work group associate to the form
-
getActions
- Returns:
- a list of action can be use for the form
-
setActions
set a list of action can be use for the form- Parameters:
formActions- a list of action must be use for the form
-
isActive
public boolean isActive()Returns the active status of a form by checking if we are currently within its availability period- Returns:
- true if the form is active
-
getIdWorkflow
public int getIdWorkflow()Getter for id_workflow- Returns:
- the _nIdWorkflow
-
setIdWorkflow
public void setIdWorkflow(int nIdWorkflow) setter for id_workflow- Parameters:
nIdWorkflow- the Id Workflow to set
-
isAuthentificationNeeded
public boolean isAuthentificationNeeded()- Returns:
- the _bAuthentificationNeeded
-
setAuthentificationNeeded
public void setAuthentificationNeeded(boolean bAuthentificationNeeded) - Parameters:
bAuthentificationNeeded- the bAuthentificationNeeded to set
-
getBreadcrumbName
Returns the BreadcrumbName- Returns:
- The BreadcrumbName
-
setBreadcrumbName
Sets the Title- Parameters:
strBreadcrumbName- The breadcrumb bean name
-
getReturnUrl
Returns the return URL- Returns:
- The return URL
-
setReturnUrl
Sets the return URL- Parameters:
strReturnUrl- The form return page URL
-
isDisplaySummary
public boolean isDisplaySummary()Tells if the summary must be displayed- Returns:
trueif the summary must be displayed,falseotherwise
-
setDisplaySummary
public void setDisplaySummary(boolean bDisplaySummary) Sets if the summary must be displayed- Parameters:
bDisplaySummary-trueif the summary must be displayed,falseotherwise
-
getMaxNumberResponse
public int getMaxNumberResponse()Returns the number Max of response form- Returns:
- The number max of reponse for
-
setMaxNumberResponse
public void setMaxNumberResponse(int nMaxNumberResponse) Sets the number Max of response form- Parameters:
nMaxNumberResponse- The number max of reponse form
-
isOneResponseByUser
public boolean isOneResponseByUser()Check the user can only submit one form.- Returns:
- true if the user can submit just one form
-
setOneResponseByUser
public void setOneResponseByUser(boolean bOneResponseByUser) set true if the user can submit just once the form- Parameters:
bOneResponseByUser- true if the user can submit just one form
-
getCurrentNumberResponse
public int getCurrentNumberResponse()- Returns:
- the nCurrentNumberResponse
-
setCurrentNumberResponse
public void setCurrentNumberResponse(int nCurrentNumberResponse) - Parameters:
nCurrentNumberResponse- the nCurrentNumberResponse to set
-
isCaptchaStepInitial
public boolean isCaptchaStepInitial()- Returns:
- the bCaptchaStepInitial
-
setCaptchaStepInitial
public void setCaptchaStepInitial(boolean bCaptchaStepInitial) - Parameters:
bCaptchaStepInitial- the bCaptchaStepInitial to set
-
isCaptchaStepFinal
public boolean isCaptchaStepFinal()- Returns:
- the bCaptchaStepFinal
-
setCaptchaStepFinal
public void setCaptchaStepFinal(boolean bCaptchaStepFinal) - Parameters:
bCaptchaStepFinal- the bCaptchaStepFinel to set
-
isCaptchaRecap
public boolean isCaptchaRecap()- Returns:
- the bCaptchaRecap
-
setCaptchaRecap
public void setCaptchaRecap(boolean bCaptchaRecap) - Parameters:
bCaptchaRecap- the bCaptchaRecap to set
-
isCountResponses
public boolean isCountResponses()- Returns:
- the bCountResponse
-
setCountResponses
public void setCountResponses(boolean bCountResponse) - Parameters:
bCountResponse- the bCountResponse to set
-
getLabelFinalButton
- Returns:
- the labelFinalButton
-
setLabelFinalButton
- Parameters:
labelFinalButton- the labelFinalButton to set
-
getLogo
public fr.paris.lutece.portal.business.file.File getLogo()- Returns:
- the logo
-
setLogo
public void setLogo(fr.paris.lutece.portal.business.file.File logo) - Parameters:
logo- the logo to set
-
getLogoBase64
Get the content of the logo as base64- Returns:
-
getIdCategory
public int getIdCategory()- Returns:
- the id of the category linked to the form
-
setIdCategory
public void setIdCategory(int nIdCategory) - Parameters:
_nIdCategory- the _nIdCategory to set
-
isBackupEnabled
public boolean isBackupEnabled()- Returns:
- the bBackupEnabled
-
setBackupEnabled
public void setBackupEnabled(boolean bBackupEnabled) - Parameters:
bBackupEnabled- the bBackupEnabled to set
-
getCategory
- Returns:
- the id of the category linked to the form
-
isAccessToResponsesByRole
public boolean isAccessToResponsesByRole()Returns true if the access to responses management on FO is based on the roles, false otherwise- Returns:
- true if the access to responses management on FO is based on the roles, false otherwise
-
setAccessToResponsesByRole
public void setAccessToResponsesByRole(boolean bAccessToResponsesByRole) Sets the AccessToResponsesByRole- Parameters:
bAccessToResponsesByRole- The AccessToResponsesByRole
-
compare
Custom comparator for Availability Period sorting- Specified by:
comparein interfaceComparator<Form>
-