Compare commits

..

1 Commits

Author SHA1 Message Date
dependabot[bot]
00a53a8339 Bump ini from 1.3.5 to 1.3.8
Bumps [ini](https://github.com/isaacs/ini) from 1.3.5 to 1.3.8.
- [Release notes](https://github.com/isaacs/ini/releases)
- [Commits](https://github.com/isaacs/ini/compare/v1.3.5...v1.3.8)

Signed-off-by: dependabot[bot] <support@github.com>
2021-04-05 16:55:00 +00:00
39 changed files with 34259 additions and 398721 deletions

View File

@@ -19,9 +19,6 @@ include APP_BASE_PATH.'modulejslibs.inc.php';
<div class="tab-pane active" id="tabPageEmployeeFieldName">
<div id="EmployeeFieldName" class="reviewBlock" data-content="List" style="padding-left:5px;">
</div>
<div id="EmployeeFieldNameForm" class="reviewBlock" data-content="Form" style="padding-left:5px;display:none;">
</div>
</div>
</div>

View File

@@ -28,23 +28,20 @@ include APP_BASE_PATH.'modulejslibs.inc.php';
<div id="JobTitleForm"></div>
<div id="JobTitleFilterForm"></div>
</div>
<div class="tab-pane" id="tabPagePayGrades">
<div id="PayGradeTable" class="reviewBlock" data-content="List" style="padding-left:5px;"></div>
<div id="PayGradeForm"></div>
<div id="PayGradeFilterForm"></div>
</div>
<div class="tab-pane" id="tabPageEmploymentStatus">
<div id="EmploymentStatusTable" class="reviewBlock" data-content="List" style="padding-left:5px;"></div>
<div id="EmploymentStatusForm"></div>
<div id="EmploymentStatusFilterForm"></div>
</div>
</div>
</div>
<div id="dataGroup"></div>
<?php
$moduleData = [
'user_level' => $user->user_level,

View File

@@ -4,17 +4,12 @@
Developer: Thilina Hasantha (http://lk.linkedin.com/in/thilinah | https://github.com/thilinah)
*/
use Classes\PermissionManager;
use Loans\Common\Model\CompanyLoan;
use Loans\Common\Model\EmployeeCompanyLoan;
$moduleName = 'loans';
$moduleGroup = 'admin';
define('MODULE_PATH',dirname(__FILE__));
include APP_BASE_PATH.'header.php';
include APP_BASE_PATH.'modulejslibs.inc.php';
?>
<div class="span9">
?><div class="span9">
<ul class="nav nav-tabs" id="modTab" style="margin-bottom:0px;margin-left:5px;border-bottom: none;">
<li class="active"><a id="tabCompanyLoan" href="#tabPageCompanyLoan"><?=t('Loan Types')?></a></li>
@@ -23,32 +18,31 @@ include APP_BASE_PATH.'modulejslibs.inc.php';
<div class="tab-content">
<div class="tab-pane active" id="tabPageCompanyLoan">
<div id="CompanyLoanTable" class="reviewBlock" data-content="List" style="padding-left:5px;"></div>
<div id="CompanyLoanForm"></div>
<div id="CompanyLoanFilterForm"></div>
<div id="CompanyLoan" class="reviewBlock" data-content="List" style="padding-left:5px;">
</div>
<div id="CompanyLoanForm" class="reviewBlock" data-content="Form" style="padding-left:5px;display:none;">
</div>
</div>
<div class="tab-pane" id="tabPageEmployeeCompanyLoan">
<div id="EmployeeCompanyLoanTable" class="reviewBlock" data-content="List" style="padding-left:5px;"></div>
<div id="EmployeeCompanyLoanForm"></div>
<div id="EmployeeCompanyLoanFilterForm"></div>
<div id="EmployeeCompanyLoan" class="reviewBlock" data-content="List" style="padding-left:5px;">
</div>
<div id="EmployeeCompanyLoanForm" class="reviewBlock" data-content="Form" style="padding-left:5px;display:none;">
</div>
</div>
</div>
</div>
<?php
$moduleData = [
'user_level' => $user->user_level,
'permissions' => [
'CompanyLoan' => PermissionManager::checkGeneralAccess(new CompanyLoan()),
'EmployeeCompanyLoan' => PermissionManager::checkGeneralAccess(new EmployeeCompanyLoan()),
]
];
?>
<script>
initAdminLoan(<?=json_encode($moduleData)?>);
</script>
var modJsList = new Array();
modJsList['tabCompanyLoan'] = new CompanyLoanAdapter('CompanyLoan','CompanyLoan');
modJsList['tabEmployeeCompanyLoan'] = new EmployeeCompanyLoanAdapter('EmployeeCompanyLoan','EmployeeCompanyLoan');
var modJs = modJsList['tabCompanyLoan'];
</script>
<?php include APP_BASE_PATH.'footer.php';?>

View File

@@ -1,9 +1,4 @@
<?php
use Classes\PermissionManager;
use Salary\Common\Model\SalaryComponentType;
use Salary\Common\Model\SalaryComponent;
use Salary\Common\Model\EmployeeSalary;
$moduleName = 'salary';
$moduleGroup = 'admin';
@@ -11,7 +6,7 @@ define('MODULE_PATH',dirname(__FILE__));
include APP_BASE_PATH.'header.php';
include APP_BASE_PATH.'modulejslibs.inc.php';
/*$moduleBuilder = new \Classes\ModuleBuilder\ModuleBuilder();
$moduleBuilder = new \Classes\ModuleBuilder\ModuleBuilder();
$moduleBuilder->addModuleOrGroup(new \Classes\ModuleBuilder\ModuleTab(
'SalaryComponentType','SalaryComponentType','Salary Component Types','SalaryComponentTypeAdapter','','',true
@@ -26,55 +21,4 @@ $moduleBuilder->addModuleOrGroup(new \Classes\ModuleBuilder\ModuleTab(
echo \Classes\UIManager::getInstance()->renderModule($moduleBuilder);
include APP_BASE_PATH.'footer.php';*/
?><div class="span9">
<ul class="nav nav-tabs" id="modTab" style="margin-bottom:0px;margin-left:5px;border-bottom: none;">
<li class="active"><a id="tabSalaryComponentType" href="#tabSalaryComponentType"><?=t('Salary Component Types')?></a></li>
<li><a id="tabSalaryComponent" href="#tabPageSalaryComponent"><?=t('Salary Components')?></a></li>
<li><a id="tabEmployeeSalary" href="#tabPageEmployeeSalary"><?=t('Employee Salary Components')?></a></li>
</ul>
<div class="tab-content">
<div class="tab-pane active" id="tabPageSalaryComponentType">
<div id="SalaryComponentTypeTable" class="reviewBlock" data-content="List" style="padding-left:5px;"></div>
<div id="SalaryComponentTypeForm"></div>
<div id="SalaryComponentTypeFilterForm"></div>
</div>
<div class="tab-pane" id="tabPageSalaryComponent">
<div id="SalaryComponentTable" class="reviewBlock" data-content="List" style="padding-left:5px;"></div>
<div id="SalaryComponentForm"></div>
<div id="SalaryComponentFilterForm"></div>
</div>
<div class="tab-pane" id="tabPageEmployeeSalary">
<div id="EmployeeSalaryTable" class="reviewBlock" data-content="List" style="padding-left:5px;"></div>
<div id="EmployeeSalaryForm"></div>
<div id="EmployeeSalaryFilterForm"></div>
</div>
</div>
</div>
<?php
$moduleData = [
'user_level' => $user->user_level,
'permissions' => [
'SalaryComponentType' => PermissionManager::checkGeneralAccess(new SalaryComponentType()),
'SalaryComponent' => PermissionManager::checkGeneralAccess(new SalaryComponent()),
'EmployeeSalary' => PermissionManager::checkGeneralAccess(new EmployeeSalary()),
]
];
?>
<script>
initAdminSalary(<?=json_encode($moduleData)?>);
</script>
<?php include APP_BASE_PATH.'footer.php';?>
include APP_BASE_PATH.'footer.php';

View File

@@ -4,9 +4,6 @@
Developer: Thilina Hasantha (http://lk.linkedin.com/in/thilinah | https://github.com/thilinah)
*/
use Classes\PermissionManager;
use Loans\Common\Model\EmployeeCompanyLoan;
$moduleName = 'loans';
$moduleGroup = 'modules';
define('MODULE_PATH',dirname(__FILE__));
@@ -20,27 +17,26 @@ include APP_BASE_PATH.'modulejslibs.inc.php';
<div class="tab-content">
<div class="tab-pane active" id="tabPageEmployeeCompanyLoan">
<div id="EmployeeCompanyLoan" class="reviewBlock" data-content="List" style="padding-left:5px;">
<div id="EmployeeCompanyLoanTable" class="reviewBlock" data-content="List" style="padding-left:5px;"></div>
<div id="EmployeeCompanyLoanForm"></div>
<div id="EmployeeCompanyLoanFilterForm"></div>
</div>
<div id="EmployeeCompanyLoanForm" class="reviewBlock" data-content="Form" style="padding-left:5px;display:none;">
</div>
</div>
</div>
</div>
<?php
$moduleData = [
'user_level' => $user->user_level,
'permissions' => [
'EmployeeCompanyLoan' => PermissionManager::checkGeneralAccess(new EmployeeCompanyLoan()),
]
];
?>
<script>
initAdminLoan(<?=json_encode($moduleData)?>);
</script>
var modJsList = new Array();
modJsList['tabEmployeeCompanyLoan'] = new EmployeeCompanyLoanAdapter('EmployeeCompanyLoan','EmployeeCompanyLoan');
modJsList['tabEmployeeCompanyLoan'].setShowAddNew(false);
modJsList['tabEmployeeCompanyLoan'].setShowSave(false);
modJsList['tabEmployeeCompanyLoan'].setShowDelete(false);
modJsList['tabEmployeeCompanyLoan'].setShowEdit(true);
var modJs = modJsList['tabEmployeeCompanyLoan'];
</script>
<?php include APP_BASE_PATH.'footer.php';?>

View File

@@ -4,9 +4,6 @@
Developer: Thilina Hasantha (http://lk.linkedin.com/in/thilinah | https://github.com/thilinah)
*/
use Classes\PermissionManager;
use Salary\Common\Model\EmployeeSalary;
$moduleName = 'salary';
$moduleGroup = 'modules';
define('MODULE_PATH',dirname(__FILE__));
@@ -20,25 +17,32 @@ include APP_BASE_PATH.'modulejslibs.inc.php';
<div class="tab-content">
<div class="tab-pane active" id="tabPageEmployeeSalary">
<div id="EmployeeSalaryTable" class="reviewBlock" data-content="List" style="padding-left:5px;"></div>
<div id="EmployeeSalaryForm"></div>
<div id="EmployeeSalaryFilterForm"></div>
<div id="EmployeeSalary" class="reviewBlock" data-content="List" style="padding-left:5px;">
</div>
<div id="EmployeeSalaryForm" class="reviewBlock" data-content="Form" style="padding-left:5px;display:none;">
</div>
</div>
</div>
</div>
<?php
$moduleData = [
'user_level' => $user->user_level,
'permissions' => [
'EmployeeSalary' => PermissionManager::checkGeneralAccess(new EmployeeSalary()),
]
];
?>
<script>
initAdminSalary(<?=json_encode($moduleData)?>);
var modJsList = new Array();
modJsList['tabEmployeeSalary'] = new EmployeeSalaryAdapter('EmployeeSalary');
<?php if(isset($modulePermissions['perm']['Add Salary']) && $modulePermissions['perm']['Add Salary'] == "No"){?>
modJsList['tabEmployeeSalary'].setShowAddNew(false);
<?php }?>
<?php if(isset($modulePermissions['perm']['Delete Salary']) && $modulePermissions['perm']['Delete Salary'] == "No"){?>
modJsList['tabEmployeeSalary'].setShowDelete(false);
<?php }?>
<?php if(isset($modulePermissions['perm']['Edit Salary']) && $modulePermissions['perm']['Edit Salary'] == "No"){?>
modJsList['tabEmployeeSalary'].setShowEdit(false);
<?php }?>
var modJs = modJsList['tabEmployeeSalary'];
</script>
<?php include APP_BASE_PATH.'footer.php';?>

View File

@@ -172,7 +172,7 @@ class BaseService
public function getCustomFieldClassMap()
{
$map = [];
foreach ($this->customFieldsClassMap as $key => $val) {
foreach($this->customFieldsClassMap as $key => $val) {
$map[] = [$key, $val];
}
return $map;

View File

@@ -61,6 +61,7 @@ class DomainAwareInputCleaner
$filterData = json_decode($filters, true);
foreach ($filterData as $name => $value) {
if (!$this->isValidColumnName($name) || !$this->isValidFilterValue($value)) {
return '';
}

View File

@@ -15,7 +15,7 @@ class ModuleBuilder
public $modules = array();
public $user = null;
public function __construct()
function __construct()
{
$this->user = \Classes\BaseService::getInstance()->getCurrentUser();
}

View File

@@ -31,8 +31,8 @@ class ModuleTab
$orderBy,
$isActive = false,
$options = array()
) {
)
{
$this->modelPath = $modelPath;
$this->name = $name;
$this->class = $class;
@@ -43,14 +43,12 @@ class ModuleTab
$this->isActive = $isActive;
$this->options = array_merge(
$options,
[
$options, [
"setObjectTypeName" => "'{$this->name}'",
"setAccess" => "data.permissions.{$this->name} ? data.permissions.{$this->name} : {}",
"setDataPipe" => 'new IceDataPipe(modJsList.tab' . $this->name . ')',
"setRemoteTable" => true,
]
);
]);
}
public function getHTML()
@@ -69,8 +67,8 @@ class ModuleTab
{
$active = ($this->isActive)?" active":"";
$html = '<div class="tab-pane'.$active.'" id="tabPage'.$this->name.'">'.
'<div id="'.$this->name.'Table" class="reviewBlock" data-content="List" style="padding-left:5px;"></div>'.
'<div id="'.$this->name.'Form"></div>'.
'<div id="'.$this->name.'Table" class="reviewBlock" data-content="List" style="padding-left:5px;"></div>'.
'<div id="'.$this->name.'Form"></div>'.
'<div id="'.$this->name.'FilterForm"></div>'.
'</div>';

View File

@@ -7,8 +7,7 @@ use Utils\LogManager;
class SAMLManager
{
public function getSSOEmail($samlData, $relayState)
{
public function getSSOEmail($samlData, $relayState) {
// Service Providers Assertion Consumer Service (ACS) URL
$acsUrl = CLIENT_BASE_URL.'login.php';
$samlResponse = htmlspecialchars($samlData);
@@ -28,15 +27,15 @@ class SAMLManager
$statusString = $status->item(0)->getAttribute('Value');
$statusArray = explode(':', $statusString);
if (array_key_exists(7, $statusArray)) {
$statusArray = explode(':',$statusString);
if(array_key_exists(7, $statusArray)){
$status = $statusArray[7];
}
if ('Success' !== $status) {
$StatusMessage = $xpath->query('/samlp:Response/samlp:Status/samlp:StatusMessage', $doc)->item(0);
LogManager::getInstance()->error('SAML login failed: status = '. $status);
if (!empty($StatusMessage)) {
if(!empty($StatusMessage)) {
$StatusMessage = $StatusMessage->nodeValue;
LogManager::getInstance()->error('SAML login failed: status message = '. $StatusMessage);
}
@@ -52,31 +51,17 @@ class SAMLManager
$certFingerPrint = MoXMLSecurityKey::getRawThumbprint($x509cert);
$certFingerPrint = preg_replace('/\s+/', '', $certFingerPrint);
$validSignature = false;
if (!empty($responseSignatureData)) {
$validSignature = \Utilities::processResponse(
$acsUrl,
$certFingerPrint,
$responseSignatureData,
$samlResponse,
0,
$relayState
);
if(!empty($responseSignatureData)) {
$validSignature = \Utilities::processResponse($acsUrl, $certFingerPrint, $responseSignatureData, $samlResponse, 0, $relayState);
LogManager::getInstance()->error('SAML: response signature validity :'.$validSignature);
}
if (!empty($assertionSignatureData)) {
$validSignature = \Utilities::processResponse(
$acsUrl,
$certFingerPrint,
$assertionSignatureData,
$samlResponse,
0,
$relayState
);
if(!empty($assertionSignatureData)) {
$validSignature = \Utilities::processResponse($acsUrl, $certFingerPrint, $assertionSignatureData, $samlResponse, 0, $relayState);
LogManager::getInstance()->error('SAML: response signature validity :'.$validSignature);
}
if (!$validSignature) {
if(!$validSignature) {
LogManager::getInstance()->error('Invalid response or assertion signature');
return false;
}
@@ -97,4 +82,4 @@ class SAMLManager
return $ssoEmail;
}
}
}

View File

@@ -28,20 +28,17 @@ class SettingsManager
return self::$me;
}
public function addEncryptedSetting($name)
{
public function addEncryptedSetting($name) {
if (!$this->isEncryptedSetting($name)) {
$this->encryptedSettings[] = $name;
}
}
public function isEncryptedSetting($name)
{
public function isEncryptedSetting($name) {
return in_array($name, $this->encryptedSettings);
}
public function getInstanceKey()
{
public function getInstanceKey() {
$settings = new Setting();
$settings->Load("name = ?", array("Instance: Key"));
if ($settings->name != "Instance: Key") {
@@ -50,17 +47,16 @@ class SettingsManager
return $settings->value;
}
private function encrypt($value)
{
private function encrypt($value) {
$id = BaseService::getInstance()->getInstanceId();
$key = $this->getInstanceKey();
return AesCtr::encrypt($value, $id.$key, 256);
}
public function encryptSetting($name, $value)
{
public function encryptSetting($name, $value) {
// check the existence of prefix and encrypt only if need to avoid double encryption
if ($this->isEncryptedSetting($name)
if (
$this->isEncryptedSetting($name)
&& substr($value, 0, strlen(self::ENCRYPTED_PREFIX)) !== self::ENCRYPTED_PREFIX
) {
$value = self::ENCRYPTED_PREFIX.$this->encrypt($value);
@@ -69,16 +65,15 @@ class SettingsManager
return $value;
}
private function decrypt($value)
{
private function decrypt($value) {
$id = BaseService::getInstance()->getInstanceId();
$key = $this->getInstanceKey();
return AesCtr::decrypt($value, $id.$key, 256);
}
public function decryptSetting($name, $value)
{
if ($this->isEncryptedSetting($name)
public function decryptSetting($name, $value) {
if (
$this->isEncryptedSetting($name)
&& substr($value, 0, strlen(self::ENCRYPTED_PREFIX)) === self::ENCRYPTED_PREFIX
) {
$value = $this->decrypt(substr($value, strlen(self::ENCRYPTED_PREFIX)));
@@ -139,8 +134,7 @@ class SettingsManager
}
}
public function getDeprecatedSettings()
{
public function getDeprecatedSettings() {
return [
'Attendance: Work Week Start Day',
'Attendance: Overtime Calculation Class'

View File

@@ -22,4 +22,4 @@ class CustomFieldAdminManager extends AbstractModuleManager
{
$this->addModelClass('CustomField');
}
}
}

View File

@@ -45,8 +45,7 @@ class DocumentTaskCreator implements TaskCreator
return 0;
}
$query
= "select count(id) as c from EmployeeDocuments where employee = ? and valid_until < ? and visible_to = ?";
$query = "select count(id) as c from EmployeeDocuments where employee = ? and valid_until < ? and visible_to = ?";
$user->DB()->SetFetchMode(ADODB_FETCH_ASSOC);
// TODO - sending notifications only for Owner documents, this need to be extended later

View File

@@ -13,4 +13,4 @@ trait CustomFieldTrait
{
return $this->allowCustomFields;
}
}
}

View File

@@ -101,7 +101,7 @@ class Setting extends BaseModel
}
if (strlen($obj->value) > 30) {
$obj->value = substr($obj->value, 0, 30).'...';
$obj->value = substr($obj->value,0, 30).'...';
}
return $obj;
}

View File

@@ -17,7 +17,8 @@ class EmployeeTimeTrackReport extends ClassBasedReportBuilder implements ReportB
LogManager::getInstance()->info(json_encode($report));
LogManager::getInstance()->info(json_encode($req));
if (empty($req['period'])
if (
empty($req['period'])
&& (
empty($req['date_start'])
|| 'NULL' === $req['date_start']
@@ -84,13 +85,7 @@ class EmployeeTimeTrackReport extends ClassBasedReportBuilder implements ReportB
$company->Load('id = ?', [$employeeObject->department]);
$reportData = [];
$reportData[] = [
"Date",
"First Punch-In Time",
"Last Punch-Out Time",
"Time in Attendance (Hours)",
"Time in Time-sheets (Hours)",
];
$reportData[] = ["Date","First Punch-In Time","Last Punch-Out Time","Time in Attendance (Hours)","Time in Time-sheets (Hours)"];
$reportData[] = ["Employee:",$employeeObject->first_name." ".$employeeObject->last_name,"","",""];
$reportData[] = ["Department:",$company->title,"","",""];
$reportData[] = ["Total Days:","","","",""];
@@ -99,11 +94,7 @@ class EmployeeTimeTrackReport extends ClassBasedReportBuilder implements ReportB
//Iterate date range
$interval = \DateInterval::createFromDateString('1 day');
$period = new \DatePeriod(
new \DateTime($req['date_start']),
$interval,
(new \DateTime($req['date_end']))->modify('+1 day')
);
$period = new \DatePeriod(new \DateTime($req['date_start']), $interval, (new \DateTime($req['date_end']))->modify('+1 day'));
$totalHoursOffice = 0;
$totalHoursTimeSheets = 0;
@@ -163,8 +154,7 @@ class EmployeeTimeTrackReport extends ClassBasedReportBuilder implements ReportB
return $reportData;
}
private function setRequestDatesBasedOnThePeriod($req)
{
private function setRequestDatesBasedOnThePeriod($req) {
if (empty($req['period'])) {
return $req;
}
@@ -172,13 +162,13 @@ class EmployeeTimeTrackReport extends ClassBasedReportBuilder implements ReportB
if ($req['period'] === 'Current Month') {
$req['date_start'] = date('Y-m-01', strtotime('now'));
$req['date_end'] = date('Y-m-d', strtotime('now'));
} elseif ($req['period'] === 'Last Month') {
} else if ($req['period'] === 'Last Month') {
$req['date_start'] = date('Y-m-d', strtotime('first day of last month'));
$req['date_end'] = date('Y-m-d', strtotime('last day of last month'));
} elseif ($req['period'] === 'Last Week') {
} else if ($req['period'] === 'Last Week') {
$req['date_start'] = date("Y-m-d", strtotime("-7 days"));
$req['date_end'] = date('Y-m-d', strtotime('now'));
} elseif ($req['period'] === 'Last 2 Weeks') {
} else if ($req['period'] === 'Last 2 Weeks') {
$req['date_start'] = date("Y-m-d", strtotime("-14 days"));
$req['date_end'] = date('Y-m-d', strtotime('now'));
}

18
package-lock.json generated
View File

@@ -3824,7 +3824,7 @@
},
"doctrine": {
"version": "1.5.0",
"resolved": "http://registry.npmjs.org/doctrine/-/doctrine-1.5.0.tgz",
"resolved": "https://registry.npmjs.org/doctrine/-/doctrine-1.5.0.tgz",
"integrity": "sha1-N53Ocw9hZvds76TmcHoVmwLFpvo=",
"dev": true,
"requires": {
@@ -4759,12 +4759,6 @@
"dev": true,
"optional": true
},
"ini": {
"version": "1.3.5",
"bundled": true,
"dev": true,
"optional": true
},
"is-fullwidth-code-point": {
"version": "1.0.0",
"bundled": true,
@@ -6796,9 +6790,9 @@
"integrity": "sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ=="
},
"ini": {
"version": "1.3.5",
"resolved": "https://registry.npmjs.org/ini/-/ini-1.3.5.tgz",
"integrity": "sha512-RZY5huIKCMRWDUqZlEi72f/lmXKMvuszcMBduliQ3nnWbx9X/ZBQO7DijMEYS9EhHBb2qacRUMtC7svLwe0lcw==",
"version": "1.3.8",
"resolved": "https://registry.npmjs.org/ini/-/ini-1.3.8.tgz",
"integrity": "sha512-JV/yugV2uzW5iMRSiZAyDtQd+nxtUnjeLt0acNdw98kKLrvuRVyB80tsREOE7yvGVgalhZ6RNXCmEHkUKBKxew==",
"dev": true
},
"inline-source-map": {
@@ -6988,7 +6982,7 @@
},
"is-accessor-descriptor": {
"version": "0.1.6",
"resolved": "http://registry.npmjs.org/is-accessor-descriptor/-/is-accessor-descriptor-0.1.6.tgz",
"resolved": "https://registry.npmjs.org/is-accessor-descriptor/-/is-accessor-descriptor-0.1.6.tgz",
"integrity": "sha1-qeEss66Nh2cn7u84Q/igiXtcmNY=",
"dev": true,
"requires": {
@@ -7034,7 +7028,7 @@
},
"is-data-descriptor": {
"version": "0.1.4",
"resolved": "http://registry.npmjs.org/is-data-descriptor/-/is-data-descriptor-0.1.4.tgz",
"resolved": "https://registry.npmjs.org/is-data-descriptor/-/is-data-descriptor-0.1.4.tgz",
"integrity": "sha1-C17mSDiOLIYCgueT8YVv7D8wG1Y=",
"dev": true,
"requires": {

View File

@@ -1,27 +1,5 @@
# Release Notes IceHrm Open Source
## Release note v29.0.0.OS
### 🧲 New features
* SAML support [https://icehrm.gitbook.io/icehrm/api-and-single-sign-on/sign-in-with-saml-okta](https://icehrm.gitbook.io/icehrm/api-and-single-sign-on/sign-in-with-saml-okta)
* Ability to control who can see employee documents
* New custom field module. With this module users can manage all the custom fields via a single module.
* Adding custom field support for company structure.
* UI improvements for client module.
* Introducing encrypted settings.
* Adding additional fields such as total time to employee time tracking report.
* Improvements to icehrm custom extension development [https://icehrm.gitbook.io/icehrm/developer-guide/creating-first-extension](https://icehrm.gitbook.io/icehrm/developer-guide/creating-first-extension)
### 🛡️ Security improvements
* More restrictive criteria for user passwords.
* Removing support for legacy API tokens. (if you are using the mobile app your users will need to re authorize)
* Removing unused custom field values.
### 🐛 Bug fixes
* Only relevant settings are displayed, under the `Other` tab on settings module
## Release note v28.2.0.OS
### New features

View File

@@ -1,3 +1,4 @@
import { FieldNameAdapter } from './lib';
import { FieldNameAdapter, CustomFieldAdapter } from './lib';
window.FieldNameAdapter = FieldNameAdapter;
window.CustomFieldAdapter = CustomFieldAdapter;

View File

@@ -4,6 +4,7 @@
*/
import AdapterBase from '../../../api/AdapterBase';
import CustomFieldAdapter from '../../../api/CustomFieldAdapter';
/**
* FieldNameAdapter
@@ -43,4 +44,4 @@ class FieldNameAdapter extends AdapterBase {
}
module.exports = { FieldNameAdapter };
module.exports = { FieldNameAdapter, CustomFieldAdapter };

View File

@@ -3,24 +3,5 @@ import {
EmployeeCompanyLoanAdapter,
} from './lib';
import IceDataPipe from "../../../api/IceDataPipe";
function init(data) {
const modJsList = {};
modJsList.tabCompanyLoan = new CompanyLoanAdapter('CompanyLoan', 'CompanyLoan');
modJsList.tabCompanyLoan.setObjectTypeName('Company Loan');
modJsList.tabCompanyLoan.setDataPipe(new IceDataPipe(modJsList.tabCompanyLoan));
modJsList.tabCompanyLoan.setAccess(data.permissions.CompanyLoan);
modJsList.tabEmployeeCompanyLoan = new EmployeeCompanyLoanAdapter('EmployeeCompanyLoan', 'EmployeeCompanyLoan');
modJsList.tabEmployeeCompanyLoan.setObjectTypeName('Employee Company Loan');
modJsList.tabEmployeeCompanyLoan.setDataPipe(new IceDataPipe(modJsList.tabEmployeeCompanyLoan));
modJsList.tabEmployeeCompanyLoan.setAccess(data.permissions.EmployeeCompanyLoan);
window.modJs = modJsList.tabCompanyLoan;
window.modJsList = modJsList;
}
window.initAdminLoan = init;
window.CompanyLoanAdapter = CompanyLoanAdapter;
window.EmployeeCompanyLoanAdapter = EmployeeCompanyLoanAdapter;

View File

@@ -2,22 +2,13 @@
Copyright (c) 2018 [Glacies UG, Berlin, Germany] (http://glacies.de)
Developer: Thilina Hasantha (http://lk.linkedin.com/in/thilinah | https://github.com/thilinah)
*/
//import AdapterBase from '../../../api/AdapterBase';
import ReactModalAdapterBase from '../../../api/ReactModalAdapterBase';
import AdapterBase from '../../../api/AdapterBase';
/**
* CompanyLoanAdapter
*/
class CompanyLoanAdapter extends ReactModalAdapterBase {
constructor(endPoint, tab, filter, orderBy) {
super(endPoint, tab, filter, orderBy);
this.fieldNameMap = {};
this.hiddenFields = {};
this.tableFields = {};
this.formOnlyFields = {};
}
class CompanyLoanAdapter extends AdapterBase {
getDataMapping() {
return [
'id',
@@ -34,35 +25,13 @@ class CompanyLoanAdapter extends ReactModalAdapterBase {
];
}
getTableColumns() {
return [
{
title: 'Name',
dataIndex: 'name',
sorter: true,
},
{
title: 'Details',
dataIndex: 'details',
sorter: true,
}
];
}
getFormFields() {
if(this.showSave){
return [
['id', { label: 'ID', type: 'hidden' }],
['name', { label: 'Name', type: 'text', validation: '' }],
['details', { label: 'Details', type: 'textarea', validation: 'none' }],
];
}
return [
['id', { label: 'ID', type: 'hidden' }],
['name', { label: 'Name', type: 'text', validation: '' }],
['details', { label: 'Details', type: 'textarea', validation: 'none' }],
];
}
}
@@ -70,15 +39,7 @@ class CompanyLoanAdapter extends ReactModalAdapterBase {
* EmployeeCompanyLoanAdapter
*/
class EmployeeCompanyLoanAdapter extends ReactModalAdapterBase {
constructor(endPoint, tab, filter, orderBy) {
super(endPoint, tab, filter, orderBy);
this.fieldNameMap = {};
this.hiddenFields = {};
this.tableFields = {};
this.formOnlyFields = {};
}
class EmployeeCompanyLoanAdapter extends AdapterBase {
getDataMapping() {
return [
'id',
@@ -105,46 +66,6 @@ class EmployeeCompanyLoanAdapter extends ReactModalAdapterBase {
];
}
getTableColumns() {
return [
{
title: 'Employee',
dataIndex: 'employee',
sorter: true,
},
{
title: 'Loan Type',
dataIndex: 'loan',
sorter: true,
},
{
title: 'Loan Start Date',
dataIndex: 'start_date',
sorter: true,
},
{
title: 'Loan Period (Months)',
dataIndex: 'period_months',
sorter: true,
},
{
title: 'Currency',
dataIndex: 'currency',
sorter: true,
},
{
title: 'Amount',
dataIndex: 'amount',
sorter: true,
},
{
title: 'Status',
dataIndex: 'status',
sorter: true,
}
];
}
getFormFields() {
return [
['id', { label: 'ID', type: 'hidden' }],
@@ -176,5 +97,5 @@ class EmployeeCompanyLoanAdapter extends ReactModalAdapterBase {
module.exports = {
CompanyLoanAdapter,
EmployeeCompanyLoanAdapter
EmployeeCompanyLoanAdapter,
};

View File

@@ -4,33 +4,6 @@ import {
EmployeeSalaryAdapter,
} from './lib';
/*window.SalaryComponentTypeAdapter = SalaryComponentTypeAdapter;
window.SalaryComponentTypeAdapter = SalaryComponentTypeAdapter;
window.SalaryComponentAdapter = SalaryComponentAdapter;
window.EmployeeSalaryAdapter = EmployeeSalaryAdapter;*/
import IceDataPipe from "../../../api/IceDataPipe";
function init(data) {
const modJsList = [];
modJsList.tabSalaryComponentType = new SalaryComponentTypeAdapter('SalaryComponentType', 'SalaryComponentType');
modJsList.tabSalaryComponentType.setObjectTypeName('Salary Component Types');
modJsList.tabSalaryComponentType.setDataPipe(new IceDataPipe(modJsList.tabSalaryComponentType));
modJsList.tabSalaryComponentType.setAccess(data.permissions.SalaryComponentType);
modJsList.tabSalaryComponent = new SalaryComponentAdapter('SalaryComponent', 'SalaryComponent');
modJsList.tabSalaryComponent.setObjectTypeName('Salary components');
modJsList.tabSalaryComponent.setDataPipe(new IceDataPipe(modJsList.tabSalaryComponent));
modJsList.tabSalaryComponent.setAccess(data.permissions.SalaryComponent);
modJsList.tabEmployeeSalary = new EmployeeSalaryAdapter('EmployeeSalary', 'EmployeeSalary');
modJsList.tabEmployeeSalary.setObjectTypeName('Employee Salary');
modJsList.tabEmployeeSalary.setDataPipe(new IceDataPipe(modJsList.tabEmployeeSalary));
modJsList.tabEmployeeSalary.setAccess(data.permissions.EmployeeSalary);
//window.modJs = modJsList.tabEmployeeSalary;
window.modJs = modJsList.tabSalaryComponentType;
window.modJsList = modJsList;
}
window.initAdminSalary = init;
window.EmployeeSalaryAdapter = EmployeeSalaryAdapter;

View File

@@ -3,22 +3,13 @@
Developer: Thilina Hasantha (http://lk.linkedin.com/in/thilinah | https://github.com/thilinah)
*/
//import AdapterBase from '../../../api/AdapterBase';
import ReactModalAdapterBase from '../../../api/ReactModalAdapterBase';
import AdapterBase from '../../../api/AdapterBase';
/**
* SalaryComponentTypeAdapter
*/
class SalaryComponentTypeAdapter extends ReactModalAdapterBase {
constructor(endPoint, tab, filter, orderBy) {
super(endPoint, tab, filter, orderBy);
this.fieldNameMap = {};
this.hiddenFields = {};
this.tableFields = {};
this.formOnlyFields = {};
}
class SalaryComponentTypeAdapter extends AdapterBase {
getDataMapping() {
return [
'id',
@@ -35,21 +26,6 @@ class SalaryComponentTypeAdapter extends ReactModalAdapterBase {
];
}
getTableColumns() {
return [
{
title: 'Code',
dataIndex: 'code',
sorter: true,
},
{
title: 'Name',
dataIndex: 'name',
sorter: true,
}
];
}
getFormFields() {
return [
['id', { label: 'ID', type: 'hidden' }],
@@ -64,15 +40,7 @@ class SalaryComponentTypeAdapter extends ReactModalAdapterBase {
* SalaryComponentAdapter
*/
class SalaryComponentAdapter extends ReactModalAdapterBase {
constructor(endPoint, tab, filter, orderBy) {
super(endPoint, tab, filter, orderBy);
this.fieldNameMap = {};
this.hiddenFields = {};
this.tableFields = {};
this.formOnlyFields = {};
}
class SalaryComponentAdapter extends AdapterBase {
getDataMapping() {
return [
'id',
@@ -91,27 +59,6 @@ class SalaryComponentAdapter extends ReactModalAdapterBase {
];
}
getTableColumns() {
return [
{
title: 'Name',
dataIndex: 'name',
sorter: true,
},
{
title: 'Salary Component Type',
dataIndex: 'componentType',
sorter: true,
},
{
title: 'Details',
dataIndex: 'details',
sorter: true,
}
];
}
getFormFields() {
return [
['id', { label: 'ID', type: 'hidden' }],
@@ -127,15 +74,7 @@ class SalaryComponentAdapter extends ReactModalAdapterBase {
* EmployeeSalaryAdapter
*/
class EmployeeSalaryAdapter extends ReactModalAdapterBase {
constructor(endPoint, tab, filter, orderBy) {
super(endPoint, tab, filter, orderBy);
this.fieldNameMap = {};
this.hiddenFields = {};
this.tableFields = {};
this.formOnlyFields = {};
}
class EmployeeSalaryAdapter extends AdapterBase {
getDataMapping() {
return [
'id',
@@ -156,31 +95,6 @@ class EmployeeSalaryAdapter extends ReactModalAdapterBase {
];
}
getTableColumns() {
return [
{
title: 'Employee',
dataIndex: 'employee',
sorter: true,
},
{
title: 'Salary Component',
dataIndex: 'component',
sorter: true,
},
{
title: 'Amount',
dataIndex: 'amount',
sorter: true,
},
{
title: 'Details',
dataIndex: 'details',
sorter: true,
}
];
}
getFormFields() {
return [
['id', { label: 'ID', type: 'hidden' }],

46925
web/dist/admin-bundle.js vendored

File diff suppressed because one or more lines are too long

532
web/dist/common.js vendored

File diff suppressed because one or more lines are too long

10483
web/dist/login.js vendored

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

68174
web/dist/third-party.js vendored

File diff suppressed because one or more lines are too long

91755
web/dist/vendorAntd.js vendored

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

92738
web/dist/vendorAntv.js vendored

File diff suppressed because one or more lines are too long

15466
web/dist/vendorOther.js vendored

File diff suppressed because one or more lines are too long

28928
web/dist/vendorReact.js vendored

File diff suppressed because one or more lines are too long

View File

@@ -1,23 +1,5 @@
import {
EmployeeCompanyLoanAdapter,
} from './lib';
EmployeeCompanyLoanAdapter,
} from './lib';
import IceDataPipe from "../../../api/IceDataPipe";
function init(data) {
const modJsList = [];
modJsList.tabEmployeeCompanyLoan = new EmployeeCompanyLoanAdapter('EmployeeCompanyLoan', 'EmployeeCompanyLoan');
modJsList.tabEmployeeCompanyLoan.setObjectTypeName('Employee Company Loan');
modJsList.tabEmployeeCompanyLoan.setShowAddNew(false);
modJsList.tabEmployeeCompanyLoan.setShowEdit(false);
modJsList.tabEmployeeCompanyLoan.setShowDelete(false);
modJsList.tabEmployeeCompanyLoan.setDataPipe(new IceDataPipe(modJsList.tabEmployeeCompanyLoan));
modJsList.tabEmployeeCompanyLoan.setAccess(data.permissions.EmployeeCompanyLoan);
window.modJs = modJsList.tabEmployeeCompanyLoan;
window.modJsList = modJsList;
}
window.initAdminLoan = init;
window.EmployeeCompanyLoanAdapter = EmployeeCompanyLoanAdapter;

View File

@@ -2,18 +2,9 @@
Copyright (c) 2018 [Glacies UG, Berlin, Germany] (http://glacies.de)
Developer: Thilina Hasantha (http://lk.linkedin.com/in/thilinah | https://github.com/thilinah)
*/
//import AdapterBase from '../../../api/AdapterBase';
import ReactModalAdapterBase from '../../../api/ReactModalAdapterBase';
class EmployeeCompanyLoanAdapter extends ReactModalAdapterBase {
constructor(endPoint, tab, filter, orderBy) {
super(endPoint, tab, filter, orderBy);
this.fieldNameMap = {};
this.hiddenFields = {};
this.tableFields = {};
this.formOnlyFields = {};
}
import AdapterBase from '../../../api/AdapterBase';
class EmployeeCompanyLoanAdapter extends AdapterBase {
getDataMapping() {
return [
'id',
@@ -38,41 +29,6 @@ class EmployeeCompanyLoanAdapter extends ReactModalAdapterBase {
];
}
getTableColumns() {
return [
{
title: 'Loan Type',
dataIndex: 'loan',
sorter: true,
},
{
title: 'Loan Start Date',
dataIndex: 'start_date',
sorter: true,
},
{
title: 'Loan Period (Months)',
dataIndex: 'period_months',
sorter: true,
},
{
title: 'Currency',
dataIndex: 'currency',
sorter: true,
},
{
title: 'Amount',
dataIndex: 'amount',
sorter: true,
},
{
title: 'Status',
dataIndex: 'status',
sorter: true,
}
];
}
getFormFields() {
return [
['id', { label: 'ID', type: 'hidden' }],

View File

@@ -2,18 +2,4 @@ import {
EmployeeSalaryAdapter,
} from './lib';
import IceDataPipe from "../../../api/IceDataPipe";
function init(data) {
const modJsList = {};
modJsList.tabEmployeeSalary = new EmployeeSalaryAdapter('EmployeeSalary', 'EmployeeSalary');
modJsList.tabEmployeeSalary.setObjectTypeName('Employee Salary');
modJsList.tabEmployeeSalary.setDataPipe(new IceDataPipe(modJsList.tabEmployeeSalary));
modJsList.tabEmployeeSalary.setAccess(data.permissions.EmployeeSalary);
window.modJs = modJsList.tabEmployeeSalary;
window.modJsList = modJsList;
}
window.initAdminSalary = init;
window.EmployeeSalaryAdapter = EmployeeSalaryAdapter;

View File

@@ -2,18 +2,9 @@
Copyright (c) 2018 [Glacies UG, Berlin, Germany] (http://glacies.de)
Developer: Thilina Hasantha (http://lk.linkedin.com/in/thilinah | https://github.com/thilinah)
*/
//import AdapterBase from '../../../api/AdapterBase';
import ReactModalAdapterBase from '../../../api/ReactModalAdapterBase';
class EmployeeSalaryAdapter extends ReactModalAdapterBase {
constructor(endPoint, tab, filter, orderBy) {
super(endPoint, tab, filter, orderBy);
this.fieldNameMap = {};
this.hiddenFields = {};
this.tableFields = {};
this.formOnlyFields = {};
}
import AdapterBase from '../../../api/AdapterBase';
class EmployeeSalaryAdapter extends AdapterBase {
getDataMapping() {
return [
'id',
@@ -32,27 +23,6 @@ class EmployeeSalaryAdapter extends ReactModalAdapterBase {
];
}
getTableColumns() {
return [
{
title: 'Salary Component',
dataIndex: 'component',
sorter: true,
},
{
title: 'Amount',
dataIndex: 'amount',
sorter: true,
},
{
title: 'Details',
dataIndex: 'details',
sorter: true,
}
];
}
getFormFields() {
return [
['id', { label: 'ID', type: 'hidden' }],