/**
* Initializes the system fields.
*/
protected void initializeSystemFields() {
systemFields.put(DcObject._SYS_MODULE,
new DcField(DcObject._SYS_MODULE, getIndex(), "Item",
true, true, true, true,
255, ComponentFactory._SHORTTEXTFIELD, getIndex(), DcRepository.ValueTypes._STRING,
"Item"));
systemFields.put(DcObject._SYS_AVAILABLE,
new DcField(DcObject._SYS_AVAILABLE, getIndex(), "Available",
true, true, true, true,
4, ComponentFactory._AVAILABILITYCOMBO, getIndex(), DcRepository.ValueTypes._BOOLEAN,
"Available"));
systemFields.put(DcObject._SYS_LENDBY,
new DcField(DcObject._SYS_LENDBY, getIndex(), "Lend By",
true, true, true, true,
255, ComponentFactory._REFERENCEFIELD, DcModules._CONTACTPERSON, DcRepository.ValueTypes._DCOBJECTREFERENCE,
"LendBy"));
systemFields.put(DcObject._SYS_LOANDURATION,
new DcField(DcObject._SYS_LOANDURATION, getIndex(), "Days Loaned",
true, true, true, true,
10, ComponentFactory._NUMBERFIELD, getIndex(), DcRepository.ValueTypes._LONG,
"DaysLoaned"));
systemFields.put(DcObject._SYS_LOANDUEDATE,
new DcField(DcObject._SYS_LOANDUEDATE, getIndex(), "Due Date",
true, true, true, true,
10, ComponentFactory._DATEFIELD, getIndex(), DcRepository.ValueTypes._DATE,
"DueDate"));
systemFields.put(DcObject._SYS_LOANDAYSTILLOVERDUE,
new DcField(DcObject._SYS_LOANDAYSTILLOVERDUE, getIndex(), "Days till overdue",
true, true, true, true,
10, ComponentFactory._NUMBERFIELD, getIndex(), DcRepository.ValueTypes._LONG,
"DaysTillOverDue"));
if (isTopModule() && deliversOnlineService()) {
systemFields.put(Integer.valueOf(DcObject._SYS_SERVICE),
new DcField(DcObject._SYS_SERVICE, getIndex(), "Service",
false, true, true, false,
255, ComponentFactory._SHORTTEXTFIELD, getIndex(), DcRepository.ValueTypes._STRING,
"service"));
systemFields.put(Integer.valueOf(DcObject._SYS_SERVICEURL),
new DcField(DcObject._SYS_SERVICEURL, getIndex(), "Service URL",
false, true, true, false,
255, ComponentFactory._URLFIELD, getIndex(), DcRepository.ValueTypes._STRING,
"serviceurl"));
}
if (isContainerManaged()) {
systemFields.put(Integer.valueOf(DcObject._SYS_CONTAINER),
new DcField(DcObject._SYS_CONTAINER, getIndex(), "Container",
true, true, false, true,
10, ComponentFactory._REFERENCESFIELD, DcModules._CONTAINER, DcRepository.ValueTypes._DCOBJECTCOLLECTION,
"Container"));
}
systemFields.put(Integer.valueOf(DcObject._SYS_DISPLAYVALUE),
new DcField(Item._SYS_DISPLAYVALUE, getIndex(), "Label",
true, true, true, false,
255, ComponentFactory._SHORTTEXTFIELD, getIndex(), DcRepository.ValueTypes._STRING,
"Label"));
if (isFileBacked) {
systemFields.put(Integer.valueOf(DcObject._SYS_FILENAME),
new DcField(DcObject._SYS_FILENAME, getIndex(), "Filename",
false, true, false, true,
500, ComponentFactory._FILELAUNCHFIELD, getIndex(), DcRepository.ValueTypes._STRING,
"Filename"));
systemFields.put(Integer.valueOf(DcObject._SYS_FILEHASH),
new DcField(DcObject._SYS_FILEHASH, getIndex(), "Filehash",
false, false, true, false,
32, ComponentFactory._SHORTTEXTFIELD, getIndex(), DcRepository.ValueTypes._STRING,
"Filehash"));
systemFields.put(Integer.valueOf(DcObject._SYS_FILESIZE),
new DcField(DcObject._SYS_FILESIZE, getIndex(), "Filesize",
false, true, true, true,
10, ComponentFactory._FILESIZEFIELD, getIndex(), DcRepository.ValueTypes._LONG,
"Filesize"));
systemFields.put(Integer.valueOf(DcObject._SYS_FILEHASHTYPE),
new DcField(DcObject._SYS_FILEHASHTYPE, getIndex(), "Filehash Type",
false, false, true, false,
10, ComponentFactory._SHORTTEXTFIELD, getIndex(), DcRepository.ValueTypes._STRING,
"FilehashType"));
}
}