|
@@ -247,7 +247,7 @@ class AntAclBase extends Core_AclBase {
|
|
|
throw new Exception("Field not found '{$this->_namespace}/{$fieldName}'");
|
|
throw new Exception("Field not found '{$this->_namespace}/{$fieldName}'");
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
- public function getSqlPrimaryKeyField() { return 'ID'; } // TODO: read from root object schema (_rootTableName)
|
|
|
|
|
|
|
+ public function getSqlPrimaryKeyField() { return $this->_primaryKey; }
|
|
|
|
|
|
|
|
public function getTotal($params = []) {
|
|
public function getTotal($params = []) {
|
|
|
DBG::log($params, 'array', "AntAclBase::getTotal params");
|
|
DBG::log($params, 'array', "AntAclBase::getTotal params");
|
|
@@ -315,7 +315,7 @@ class AntAclBase extends Core_AclBase {
|
|
|
$acl->_namespace = $conf['namespace'];
|
|
$acl->_namespace = $conf['namespace'];
|
|
|
$acl->_rootNamespace = str_replace('__x3A__', '/', $conf['nsPrefix']);
|
|
$acl->_rootNamespace = str_replace('__x3A__', '/', $conf['nsPrefix']);
|
|
|
$acl->_fields = $conf['field']; // TODO: lazyLoading - use getFields() in all functions - TODO: use ACL::getObjectFields
|
|
$acl->_fields = $conf['field']; // TODO: lazyLoading - use getFields() in all functions - TODO: use ACL::getObjectFields
|
|
|
- $acl->_primaryKey = 'ID'; // $conf['primaryKey'];
|
|
|
|
|
|
|
+ $acl->_primaryKey = (!empty($conf['primaryKey'])) ? $conf['primaryKey'] : 'ID'; // $conf['primaryKey'];
|
|
|
|
|
|
|
|
$_cache[$idZasob] = $acl;
|
|
$_cache[$idZasob] = $acl;
|
|
|
return $_cache[$idZasob];
|
|
return $_cache[$idZasob];
|