History#
NAME#
Kernel::System::DBCRUD::History
HistoryBackendSet()#
This function sets the information for the history DBCRUD module
my $Success = $Object->HistoryBackendSet();
Returns:
my $Success = 1;
HistoryBackendUnset()#
This function unsets the information for the history DBCRUD module
my $Success = $Object->HistoryBackendUnset();
Returns:
my $Success = 1;
IsHistoryBackendSet()#
Checks if history backend is currently set.
my $HistoryBackendIsSet = $Object->IsHistoryBackendSet();
Returns true value, if history backend is currently set.
HistoryEventDataAdd()#
This functions adds the history based on the information of the event
my $Success = $Object->HistoryEventDataAdd(%Event);
Returns:
my $Success = 1;
HistoryEventDataDelete()#
This functions removes the history based on the information of the event
my $Success = $Object->HistoryEventDataDelete(%Event);
Returns:
my $Success = 1;
DataHistoryGet()#
returns a hash of some of the data calculated based on data history info at the given date.
my %DataHistoryGet = $Object->DataHistoryGet(
[Identifier] => 123,
# get data based on the system time
SystemTime => 123,
);
my %DataHistoryGet = $Object->DataHistoryGet(
[Identifier] => 123,
# get data based on the timestamp
TimeStamp => '2017-01-01 12:00:00',
);
my %DataHistoryGet = $Object->DataHistoryGet(
[Identifier] => 123,
# get data based on the date information
StopYear => 2003,
StopMonth => 12,
StopDay => 24,
StopHour => 10, (optional, default 23)
StopMinute => 0, (optional, default 59)
StopSecond => 0, (optional, default 59)
);
Returns:
my %DataHistoryGet = (...);
IsUUIDHistoryDatabaseTableColumnPresent()#
Checks if the column for the UUID.
my $UUIDColumnPresent = $DBCRUDObject->IsUUIDHistoryDatabaseTableColumnPresent();
Returns true value if column for UUID is present.
CreateUUIDHistoryDatabaseTableColumn()#
Creates the UUID database table column.
my $UUIDColumnCreated = $DBCRUDObject->CreateUUIDHistoryDatabaseTableColumn();
Returns true value if column has been created successfully.
CreateMissingUUIDHistoryDatabaseTableColumn()#
Creates missing UUID database table column in backend's history database table.
my $Success = $DBCRUDObject->CreateMissingUUIDHistoryDatabaseTableColumn();
Returns true value on success (also if column already existed).
Returns false value if something went wrong.
MigrateUUIDHistoryDatabaseTableColumn()#
Renames the UUID column from z4o_database_backend_uuid (used up until Znuny 6.0) or
database_backend_uuid (used in Znuny 6.1 and 6.2) to dbcrud_uuid (Znuny 6.3 and up).
Also includes table from history backend, if present.
my $Success = $Object->MigrateUUIDHistoryDatabaseTableColumn();
Returns true value on success.