Upgrade to v26 (#172)
* A bunch of new updates from icehrm pro * Push changes to frontend
This commit is contained in:
5
web/modules/src/salary/index.js
Normal file
5
web/modules/src/salary/index.js
Normal file
@@ -0,0 +1,5 @@
|
||||
import {
|
||||
EmployeeSalaryAdapter,
|
||||
} from './lib';
|
||||
|
||||
window.EmployeeSalaryAdapter = EmployeeSalaryAdapter;
|
||||
36
web/modules/src/salary/lib.js
Normal file
36
web/modules/src/salary/lib.js
Normal file
@@ -0,0 +1,36 @@
|
||||
/*
|
||||
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';
|
||||
|
||||
class EmployeeSalaryAdapter extends AdapterBase {
|
||||
getDataMapping() {
|
||||
return [
|
||||
'id',
|
||||
'component',
|
||||
'amount',
|
||||
'details',
|
||||
];
|
||||
}
|
||||
|
||||
getHeaders() {
|
||||
return [
|
||||
{ sTitle: 'ID', bVisible: false },
|
||||
{ sTitle: 'Salary Component' },
|
||||
{ sTitle: 'Amount' },
|
||||
{ sTitle: 'Details' },
|
||||
];
|
||||
}
|
||||
|
||||
getFormFields() {
|
||||
return [
|
||||
['id', { label: 'ID', type: 'hidden' }],
|
||||
['component', { label: 'Salary Component', type: 'select2', 'remote-source': ['SalaryComponent', 'id', 'name'] }],
|
||||
['amount', { label: 'Amount', type: 'text', validation: 'float' }],
|
||||
['details', { label: 'Details', type: 'textarea', validation: 'none' }],
|
||||
];
|
||||
}
|
||||
}
|
||||
|
||||
module.exports = { EmployeeSalaryAdapter };
|
||||
Reference in New Issue
Block a user