|
@@ -4961,9 +4961,9 @@ jQuery(document).ready(function(){
|
|
|
$jsonResponse['rows'] = array();
|
|
$jsonResponse['rows'] = array();
|
|
|
foreach ($rowsHist as $row) {
|
|
foreach ($rowsHist as $row) {
|
|
|
$histItem = array();
|
|
$histItem = array();
|
|
|
- $histItem['ID'] = $row->ID;
|
|
|
|
|
- $histItem['_created'] = $row->_created;
|
|
|
|
|
- $histItem['_author'] = $row->_author;
|
|
|
|
|
|
|
+ $histItem['ID'] = V::get('ID', '', $row);
|
|
|
|
|
+ $histItem['_created'] = V::get('_created', '', $row);
|
|
|
|
|
+ $histItem['_author'] = V::get('_author', '', $row);
|
|
|
$histItem['changes'] = array();
|
|
$histItem['changes'] = array();
|
|
|
foreach ($visibleColsWithIds as $fldId => $fieldName) {
|
|
foreach ($visibleColsWithIds as $fldId => $fieldName) {
|
|
|
// if (in_array($fieldName, array('ID', 'A_RECORD_UPDATE_DATE', 'A_RECORD_UPDATE_AUTHOR', 'A_RECORD_CREATE_DATE', 'A_RECORD_CREATE_AUTHOR'))) continue;
|
|
// if (in_array($fieldName, array('ID', 'A_RECORD_UPDATE_DATE', 'A_RECORD_UPDATE_AUTHOR', 'A_RECORD_CREATE_DATE', 'A_RECORD_CREATE_AUTHOR'))) continue;
|
|
@@ -4972,14 +4972,15 @@ jQuery(document).ready(function(){
|
|
|
$changeItem['fieldName'] = $fieldName;
|
|
$changeItem['fieldName'] = $fieldName;
|
|
|
$changeItem['acl_read'] = $acl->canReadObjectField($fieldName, $record);
|
|
$changeItem['acl_read'] = $acl->canReadObjectField($fieldName, $record);
|
|
|
if ($changeItem['acl_read']) {
|
|
if ($changeItem['acl_read']) {
|
|
|
- $changeItem['value'] = $row->{$fieldName};
|
|
|
|
|
|
|
+ $changeItem['value'] = V::get($fieldName, '', $row);
|
|
|
}
|
|
}
|
|
|
if ('the_geom' == $fieldName && $acl->canWriteObjectField($fieldName, $record)) {
|
|
if ('the_geom' == $fieldName && $acl->canWriteObjectField($fieldName, $record)) {
|
|
|
$sourceName = $acl->getSourceName();
|
|
$sourceName = $acl->getSourceName();
|
|
|
if ('default_db' == $sourceName) {
|
|
if ('default_db' == $sourceName) {
|
|
|
$typeName = $acl->getName();
|
|
$typeName = $acl->getName();
|
|
|
- $changeItem['revert_function_url'] = Request::getPathUri() . "index.php?_route=ViewTableAjax&typeName=p5_{$sourceName}:{$typeName}&_task=revertFromHistAjax&ID={$id}&idHist={$row->ID}&fieldName={$fieldName}";
|
|
|
|
|
- $changeItem['revert_function_data'] = "ID={$id}&idHist={$row->ID}&fieldName={$fieldName}";
|
|
|
|
|
|
|
+ $idHist = V::get('ID', '', $_row);
|
|
|
|
|
+ $changeItem['revert_function_url'] = Request::getPathUri() . "index.php?_route=ViewTableAjax&typeName=p5_{$sourceName}:{$typeName}&_task=revertFromHistAjax&ID={$id}&idHist={$idHist}&fieldName={$fieldName}";
|
|
|
|
|
+ $changeItem['revert_function_data'] = "ID={$id}&idHist={$idHist}&fieldName={$fieldName}";
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
|
$histItem['changes'][$fieldName] = $changeItem;
|
|
$histItem['changes'][$fieldName] = $changeItem;
|