Adapted dokumentname to be empty since Nachweisdokumente can be deleted now (Datenschutz)

Error was thrown in AnrechnungLib since dms_id can be null and no document
exist after Datenschutz delete. This is fixed now.

Signed-off-by: cris-technikum <hainberg@technikum-wien.at>
This commit is contained in:
cris-technikum
2021-05-20 16:26:02 +02:00
parent 1c780d5aae
commit 0b7adba115
+1 -6
View File
@@ -818,12 +818,7 @@ class AnrechnungLib
$this->ci->DmsVersionModel->addSelect('name');
$result = $this->ci->DmsVersionModel->loadWhere(array('dms_id' => $anrechnung->dms_id));
if (isError($result))
{
show_error(getError($result));
}
$anrechnung_data->dokumentname = $result->retval[0]->name;
$anrechnung_data->dokumentname = hasData($result) ? getData($result)[0]->name : '';
return $anrechnung_data;
}