Class DemandTypeHome
java.lang.Object
fr.paris.lutece.plugins.crm.business.demand.DemandTypeHome
DemandTypeHome
-
Method Summary
Modifier and TypeMethodDescriptionstatic intcreate(DemandType demandType) Insert a new record in the table.static List<DemandType>findAll()Find all demandTypesstatic List<DemandType>findByFilter(DemandTypeFilter dtFilter) Find by filterstatic List<DemandType>findByIdCategoryAndDate(int nIdCategory, Date dateToday) Find the list of demandTypes by id category and datestatic DemandTypefindByOrder(int nOrder) Find the demandType by its orderstatic DemandTypefindByPrimaryKey(int nIdDemandType) Load the data from the tablestatic fr.paris.lutece.util.ReferenceListFind all demandTypes as aReferenceListstatic intFind the max orderstatic List<DemandType>Find demand types that have not a date endstatic intGenerates a new primary keystatic voidremove(int nIdDemandType) Delete a record from the tablestatic voidupdate(DemandType demandType) Update the record in the table
-
Method Details
-
newPrimaryKey
public static int newPrimaryKey()Generates a new primary key- Returns:
- The new primary key
-
create
Insert a new record in the table.- Parameters:
demandType- instance of the DemandType object to insert- Returns:
- the key of the newly created demandType
-
update
Update the record in the table- Parameters:
demandType- the reference of the demandType
-
remove
public static void remove(int nIdDemandType) Delete a record from the table- Parameters:
nIdDemandType- int identifier of the demandType to delete
-
findByPrimaryKey
Load the data from the table- Parameters:
nIdDemandType- The identifier of the demandType- Returns:
- The instance of the demandType
-
findByOrder
Find the demandType by its order- Parameters:
nOrder- the order- Returns:
- a
DemandType
-
findAll
Find all demandTypes- Returns:
- a list of
DemandType
-
findByIdCategoryAndDate
Find the list of demandTypes by id category and date- Parameters:
nIdCategory- the ID categorydateToday- the date of today- Returns:
- a list of
DemandType
-
findDemandTypes
public static fr.paris.lutece.util.ReferenceList findDemandTypes()Find all demandTypes as aReferenceList- Returns:
- a
ReferenceList
-
findMaxOrder
public static int findMaxOrder()Find the max order- Returns:
- the max order
-
findByFilter
Find by filter- Parameters:
dtFilter- the filter- Returns:
- a list of
DemandType
-
findNoDateEndDemandTypes
Find demand types that have not a date end- Returns:
- a list of
DemandType
-