restrict check-in outside allowed working hours
This commit is contained in:
parent
d958040137
commit
c1ab708b12
|
|
@ -28,6 +28,7 @@
|
|||
'views/hr_employee_view.xml',
|
||||
'views/firebase_notifications.xml',
|
||||
'views/firebase_registration.xml',
|
||||
'views/resource_calendar.xml',
|
||||
'wizard/firebase_registration_wizard.xml',
|
||||
'templates/terms.xml',
|
||||
'data/zone_crone.xml',
|
||||
|
|
|
|||
|
|
@ -2374,3 +2374,13 @@ msgstr "ساعات الحضور"
|
|||
#, python-format
|
||||
msgid "Dear employee, your working hours have not started yet."
|
||||
msgstr "عزيزي الموظف دوام العمل لم يبدا بعد"
|
||||
|
||||
#. module: odex_mobile
|
||||
#: model:ir.model.fields,field_description:odex_mobile.field_resource_calendar__grace_hour_after_work
|
||||
msgid "Grace Hours After Work"
|
||||
msgstr "ساعات السماحية بعد الدوام"
|
||||
|
||||
#. module: odex_mobile
|
||||
#: model:ir.model.fields,field_description:odex_mobile.field_resource_calendar__grace_hour_before_work
|
||||
msgid "Grace Hours Before Work"
|
||||
msgstr "ساعات السماحية قبل الدوم"
|
||||
|
|
@ -8,4 +8,5 @@ from . import firebase_registration
|
|||
from . import res_partner
|
||||
from . import hr_firebase_notification
|
||||
from . import base
|
||||
from . import ir_property
|
||||
from . import ir_property
|
||||
from . import resource
|
||||
|
|
@ -0,0 +1,10 @@
|
|||
# -*- coding: utf-8 -*-
|
||||
|
||||
from odoo import fields, models
|
||||
|
||||
|
||||
class ResourceCalendar(models.Model):
|
||||
_inherit = 'resource.calendar'
|
||||
|
||||
grace_hour_before_work = fields.Float(string="Grace Hours Before Work")
|
||||
grace_hour_after_work = fields.Float(string="Grace Hours After Work")
|
||||
|
|
@ -0,0 +1,20 @@
|
|||
<?xml version="1.0"?>
|
||||
<odoo>
|
||||
<data>
|
||||
<record id="resource_calendar_grace_inherited_form" model="ir.ui.view">
|
||||
<field name="name">resource.calendar.inherited.form</field>
|
||||
<field name="model">resource.calendar</field>
|
||||
<field name="inherit_id" ref="attendances.resource_calendar_inherited_form"/>
|
||||
<field name="arch" type="xml">
|
||||
<xpath expr="//group[@id='sign_out_period']" position="after">
|
||||
<group colspan="2">
|
||||
<field name="grace_hour_before_work" widget="float_time"/>
|
||||
</group>
|
||||
<group colspan="2">
|
||||
<field name="grace_hour_after_work" widget="float_time"/>
|
||||
</group>
|
||||
</xpath>
|
||||
</field>
|
||||
</record>
|
||||
</data>
|
||||
</odoo>
|
||||
Loading…
Reference in New Issue