fix: allow addition and removal of employee in payroll Entry
This commit is contained in:
parent
0411a43c6e
commit
d556847fca
@ -17,8 +17,7 @@
|
||||
"fieldtype": "Link",
|
||||
"in_list_view": 1,
|
||||
"label": "Employee",
|
||||
"options": "Employee",
|
||||
"read_only": 1
|
||||
"options": "Employee"
|
||||
},
|
||||
{
|
||||
"fetch_from": "employee.employee_name",
|
||||
@ -52,7 +51,7 @@
|
||||
],
|
||||
"istable": 1,
|
||||
"links": [],
|
||||
"modified": "2020-09-30 12:40:07.999878",
|
||||
"modified": "2020-12-17 15:43:29.542977",
|
||||
"modified_by": "Administrator",
|
||||
"module": "Payroll",
|
||||
"name": "Payroll Employee Detail",
|
||||
|
@ -70,18 +70,18 @@ frappe.ui.form.on('Payroll Entry', {
|
||||
render_employee_attendance(frm, r.message);
|
||||
}
|
||||
}
|
||||
})
|
||||
});
|
||||
},
|
||||
|
||||
create_salary_slips: function(frm) {
|
||||
frm.call({
|
||||
doc: frm.doc,
|
||||
method: "create_salary_slips",
|
||||
callback: function(r) {
|
||||
callback: function() {
|
||||
frm.refresh();
|
||||
frm.toolbar.refresh();
|
||||
}
|
||||
})
|
||||
});
|
||||
},
|
||||
|
||||
add_context_buttons: function(frm) {
|
||||
@ -274,7 +274,9 @@ const submit_salary_slip = function (frm) {
|
||||
frappe.call({
|
||||
method: 'submit_salary_slips',
|
||||
args: {},
|
||||
callback: function() {frm.events.refresh(frm);},
|
||||
callback: function() {
|
||||
frm.events.refresh(frm);
|
||||
},
|
||||
doc: frm.doc,
|
||||
freeze: true,
|
||||
freeze_message: __('Submitting Salary Slips and creating Journal Entry...')
|
||||
@ -316,4 +318,4 @@ let render_employee_attendance = function(frm, data) {
|
||||
data: data
|
||||
})
|
||||
);
|
||||
}
|
||||
};
|
||||
|
@ -129,8 +129,7 @@
|
||||
"fieldname": "employees",
|
||||
"fieldtype": "Table",
|
||||
"label": "Employee Details",
|
||||
"options": "Payroll Employee Detail",
|
||||
"read_only": 1
|
||||
"options": "Payroll Employee Detail"
|
||||
},
|
||||
{
|
||||
"fieldname": "section_break_13",
|
||||
@ -290,7 +289,7 @@
|
||||
"icon": "fa fa-cog",
|
||||
"is_submittable": 1,
|
||||
"links": [],
|
||||
"modified": "2020-10-23 13:00:33.753228",
|
||||
"modified": "2020-12-17 15:13:17.766210",
|
||||
"modified_by": "Administrator",
|
||||
"module": "Payroll",
|
||||
"name": "Payroll Entry",
|
||||
|
Loading…
x
Reference in New Issue
Block a user