Upgrades from IceHrm Pro v24
This commit is contained in:
@@ -38,7 +38,7 @@ abstract class ApproveModel extends BaseModel
|
||||
//Auto approve if the current user is an admin
|
||||
|
||||
if (!empty($currentEmpId)) {
|
||||
$employee = BaseService::getInstance()->getElement('Employee', $currentEmpId);
|
||||
$employee = BaseService::getInstance()->getElement('Employee', $currentEmpId, null, true);
|
||||
|
||||
if (!empty($employee->supervisor)) {
|
||||
$notificationMsg = "A new "
|
||||
@@ -131,7 +131,7 @@ abstract class ApproveModel extends BaseModel
|
||||
//Auto approve if the current user is an admin
|
||||
|
||||
if (!empty($currentEmpId)) {
|
||||
$employee = BaseService::getInstance()->getElement('Employee', $currentEmpId);
|
||||
$employee = BaseService::getInstance()->getElement('Employee', $currentEmpId, null, true);
|
||||
|
||||
if (!empty($employee->supervisor)) {
|
||||
$notificationMsg = $this->notificationUnitPrefix." "
|
||||
|
||||
@@ -11,4 +11,14 @@ namespace Model;
|
||||
class Audit extends BaseModel
|
||||
{
|
||||
public $table = 'AuditLog';
|
||||
|
||||
public function getManagerAccess()
|
||||
{
|
||||
return array();
|
||||
}
|
||||
|
||||
public function getUserAccess()
|
||||
{
|
||||
return array();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -26,7 +26,7 @@ class BaseModel extends \ADOdb_Active_Record
|
||||
|
||||
public function getOtherAccess()
|
||||
{
|
||||
return array("get","element","save","delete");
|
||||
return array();
|
||||
}
|
||||
|
||||
public function getManagerAccess()
|
||||
@@ -54,6 +54,11 @@ class BaseModel extends \ADOdb_Active_Record
|
||||
return array("get","element");
|
||||
}
|
||||
|
||||
public function getUserOnlyMeSwitchedAccess()
|
||||
{
|
||||
return $this->getUserOnlyMeAccess();
|
||||
}
|
||||
|
||||
public function getUserOnlyMeAccessField()
|
||||
{
|
||||
return "employee";
|
||||
@@ -123,6 +128,14 @@ class BaseModel extends \ADOdb_Active_Record
|
||||
return get_called_class();
|
||||
}
|
||||
|
||||
public function fieldValueMethods() {
|
||||
return [];
|
||||
}
|
||||
|
||||
public function validateCSRF() {
|
||||
return false;
|
||||
}
|
||||
|
||||
public function getObjectKeys()
|
||||
{
|
||||
$keys = array();
|
||||
|
||||
@@ -11,4 +11,19 @@ namespace Model;
|
||||
class Cron extends BaseModel
|
||||
{
|
||||
public $table = 'Crons';
|
||||
|
||||
public function getAdminAccess()
|
||||
{
|
||||
return array();
|
||||
}
|
||||
|
||||
public function getManagerAccess()
|
||||
{
|
||||
return array();
|
||||
}
|
||||
|
||||
public function getUserAccess()
|
||||
{
|
||||
return array();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -15,14 +15,4 @@ class File extends BaseModel
|
||||
{
|
||||
return array("get","element","save","delete");
|
||||
}
|
||||
|
||||
public function getUserAccess()
|
||||
{
|
||||
return array();
|
||||
}
|
||||
|
||||
public function getAnonymousAccess()
|
||||
{
|
||||
return array("save");
|
||||
}
|
||||
}
|
||||
|
||||
@@ -11,4 +11,14 @@ namespace Model;
|
||||
class Notification extends BaseModel
|
||||
{
|
||||
public $table = 'Notifications';
|
||||
|
||||
public function getManagerAccess()
|
||||
{
|
||||
return array();
|
||||
}
|
||||
|
||||
public function getUserAccess()
|
||||
{
|
||||
return array();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -19,6 +19,11 @@ class Setting extends BaseModel
|
||||
return array("get","element","save","delete");
|
||||
}
|
||||
|
||||
public function getManagerAccess()
|
||||
{
|
||||
return array();
|
||||
}
|
||||
|
||||
public function getUserAccess()
|
||||
{
|
||||
return array();
|
||||
|
||||
Reference in New Issue
Block a user