Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion addons/hr/models/hr_employee.py
Original file line number Diff line number Diff line change
Expand Up @@ -201,7 +201,7 @@ def _lang_get(self):
}
"""

permit_no = fields.Char('Work Permit No', groups="hr.group_hr_user", tracking=True)
permit_no = fields.Char(readonly=False, related='version_id.permit_no', inherited=True, groups="hr.group_hr_user")
visa_no = fields.Char('Visa No', groups="hr.group_hr_user", tracking=True)
visa_expire = fields.Date('Visa Expiration Date', groups="hr.group_hr_user", tracking=True)
work_permit_expiration_date = fields.Date('Work Permit Expiration Date', groups="hr.group_hr_user", tracking=True)
Expand Down
1 change: 1 addition & 0 deletions addons/hr/models/hr_version.py
Original file line number Diff line number Diff line change
Expand Up @@ -151,6 +151,7 @@ def _default_salary_structure(self):
is_flexible = fields.Boolean(compute='_compute_is_flexible', store=True, groups="hr.group_hr_user")
is_fully_flexible = fields.Boolean(compute='_compute_is_flexible', store=True, groups="hr.group_hr_user")
tz = fields.Selection(_tz_get, string='Timezone', required=True, default=lambda self: self.env.context.get('tz') or self.env.user.tz or 'UTC')
permit_no = fields.Char(string='Work Permit No', tracking=True, groups="hr.group_hr_user")

# Contract Information
contract_date_start = fields.Date('Contract Start Date', tracking=1, groups="hr.group_hr_manager")
Expand Down
2 changes: 1 addition & 1 deletion addons/hr/views/hr_employee_views.xml
Original file line number Diff line number Diff line change
Expand Up @@ -375,7 +375,7 @@
<span invisible="not contract_date_start">to</span>
<field name="contract_date_end" string="End Date" placeholder="Indefinite" widget="date_dynamic_min" options="{'min_date_field': 'contract_date_start'}"
class="o_hr_narrow_field ms-3" invisible="not contract_date_start" required="fixed_term"/>
<widget name="button_new_contract"/>
<widget name="button_new_contract" invisible="not contract_date_start"/>
</div>
<field name="fixed_term" string="Fixed Term"/>
<label for="wage"/>
Expand Down