mirror of
https://github.com/FH-Complete/FHC-Core.git
synced 2026-07-20 00:12:15 +00:00
The method loadWhole has been removed from model DB_Model.
The same functionality has given by calling the load method without parameters
This commit is contained in:
@@ -186,36 +186,6 @@ class DB_Model extends FHC_Model
|
||||
else
|
||||
return $this->_error($this->db->error(), FHC_DB_ERROR);
|
||||
}
|
||||
|
||||
|
||||
|
||||
/** ---------------------------------------------------------------
|
||||
* Load single data from DB-Table
|
||||
*
|
||||
* @param string $id ID (Primary Key) for SELECT ... WHERE
|
||||
* @return array
|
||||
*/
|
||||
public function loadWhole()
|
||||
{
|
||||
// Check Class-Attributes
|
||||
if (is_null($this->dbTable))
|
||||
return $this->_error(lang('fhc_'.FHC_NODBTABLE), FHC_MODEL_ERROR);
|
||||
if (is_null($this->pk))
|
||||
return $this->_error(lang('fhc_'.FHC_NOPK), FHC_MODEL_ERROR);
|
||||
|
||||
|
||||
// Check rights
|
||||
if (! $this->fhc_db_acl->isBerechtigt($this->acl[$this->dbTable], 's'))
|
||||
return $this->_error(lang('fhc_'.FHC_NORIGHT).' -> '.$this->acl[$this->dbTable], FHC_MODEL_ERROR);
|
||||
|
||||
// DB-SELECT
|
||||
$result = $this->db->get($this->dbTable);
|
||||
|
||||
if ($result)
|
||||
return $this->_success($result->result());
|
||||
else
|
||||
return $this->_error($this->db->error(), FHC_DB_ERROR);
|
||||
}
|
||||
|
||||
/** ---------------------------------------------------------------
|
||||
* Add a table to join with
|
||||
|
||||
Reference in New Issue
Block a user