Removed permission system from models

This commit is contained in:
Paolo
2018-03-29 12:13:08 +02:00
parent 0906f5bc85
commit d9b80b790d
16 changed files with 43 additions and 241 deletions
+2 -8
View File
@@ -17,12 +17,6 @@ class Phrase_model extends DB_Model
*/
public function getPhrases($app, $sprache, $phrase = null, $orgeinheit_kurzbz = null, $orgform_kurzbz = null)
{
// Checks if the operation is permitted by the API caller
if (isError($ent = $this->isEntitled('system.tbl_phrase', PermissionLib::SELECT_RIGHT, FHC_NORIGHT, FHC_MODEL_ERROR)))
return $ent;
if (isError($ent = $this->isEntitled('system.tbl_phrasentext', PermissionLib::SELECT_RIGHT, FHC_NORIGHT, FHC_MODEL_ERROR)))
return $ent;
$parametersArray = array('app' => $app, 'sprache' => $sprache);
$query = 'SELECT phrase,
@@ -36,7 +30,7 @@ class Phrase_model extends DB_Model
if (isset($phrase))
{
$parametersArray['phrase'] = $phrase;
if (is_array($phrase))
{
$query .= ' AND phrase IN ?';
@@ -57,7 +51,7 @@ class Phrase_model extends DB_Model
$parametersArray['orgform_kurzbz'] = $orgform_kurzbz;
$query .= ' AND orgform_kurzbz = ?';
}
return $this->execQuery($query, $parametersArray);
}
}