Merge pull request #31303 from marination/update-employee-compatibility-fix
fix: locale Currency and Float setting in update_employee
This commit is contained in:
commit
2941a8ce73
@ -55,6 +55,8 @@ def update_employee_work_history(employee, details, date=None, cancel=False):
|
||||
new_data = getdate(new_data)
|
||||
elif fieldtype == "Datetime" and new_data:
|
||||
new_data = get_datetime(new_data)
|
||||
elif fieldtype in ["Currency", "Float"] and new_data:
|
||||
new_data = flt(new_data)
|
||||
setattr(employee, item.fieldname, new_data)
|
||||
if item.fieldname in ["department", "designation", "branch"]:
|
||||
internal_work_history[item.fieldname] = item.new
|
||||
|
Loading…
x
Reference in New Issue
Block a user