exp_official_mission edits on training
This commit is contained in:
parent
19228b6100
commit
daa9122131
|
|
@ -12,8 +12,8 @@
|
|||
'data': [
|
||||
'data/data.xml',
|
||||
'security/official_mission_security.xml',
|
||||
'security/training_security.xml',
|
||||
'security/ir.model.access.csv',
|
||||
|
||||
'views/hr_official_mission.xml',
|
||||
'views/hr_official_mission_type_view.xml',
|
||||
'views/attendance_view.xml',
|
||||
|
|
@ -25,6 +25,7 @@
|
|||
'views/ticket_view.xml',
|
||||
'views/course_view.xml',
|
||||
'views/appraisal_view.xml',
|
||||
'views/training_menus.xml',
|
||||
|
||||
],
|
||||
'installable': True,
|
||||
|
|
|
|||
|
|
@ -316,6 +316,8 @@ msgstr "عدد المرفقات"
|
|||
#: model_terms:ir.ui.view,arch_db:exp_official_mission.employee_especially_hours_form_view
|
||||
#: model_terms:ir.ui.view,arch_db:exp_official_mission.employee_official_mission_form_view
|
||||
#: model_terms:ir.ui.view,arch_db:exp_official_mission.employee_training_form_view
|
||||
#: model_terms:ir.ui.view,arch_db:exp_official_mission.employee_oficial_mission_line_tree_view
|
||||
#: model_terms:ir.ui.view,arch_db:exp_official_mission.employee_training_tree_view
|
||||
msgid "Attachments"
|
||||
msgstr "المُرفقات"
|
||||
|
||||
|
|
@ -415,7 +417,7 @@ msgstr "الدولـــة"
|
|||
#: model_terms:ir.ui.view,arch_db:exp_official_mission.employee_training_form_view
|
||||
#: model_terms:ir.ui.view,arch_db:exp_official_mission.employee_training_tree_view
|
||||
msgid "Course Name"
|
||||
msgstr "أسماء الدورات"
|
||||
msgstr " أسماء الدورات التدريبية"
|
||||
|
||||
#. module: exp_official_mission
|
||||
#: model_terms:ir.ui.view,arch_db:exp_official_mission.official_tran_report_template
|
||||
|
|
@ -751,7 +753,7 @@ msgstr "عقد الموظف"
|
|||
#: model:ir.ui.menu,name:exp_official_mission.employee_training_menu_item
|
||||
#: model_terms:ir.ui.view,arch_db:exp_official_mission.employee_training_tree_view
|
||||
msgid "Employee Training"
|
||||
msgstr "الدورات التدريبية للموظفين"
|
||||
msgstr "الدورات التدريبية"
|
||||
|
||||
#. module: exp_official_mission
|
||||
#: model:ir.actions.act_window,name:exp_official_mission.employee_official_mission_action
|
||||
|
|
@ -2454,3 +2456,56 @@ msgstr "طلبـاتي"
|
|||
msgid "Branch"
|
||||
msgstr "الفروع"
|
||||
|
||||
#. module: exp_official_mission
|
||||
#: model:ir.module.category,name:exp_official_mission.module_category_hr_employee_training
|
||||
#: model:ir.ui.menu,name:exp_official_mission.hr_employee_training_main_menu
|
||||
#, python-format
|
||||
msgid "Training"
|
||||
msgstr "التدريب"
|
||||
|
||||
#. module: exp_official_mission
|
||||
#: model:res.groups,name:exp_official_mission.group_hr_training_user
|
||||
msgid "Training User"
|
||||
msgstr "مسوؤل التدريب"
|
||||
|
||||
#. module: exp_official_mission
|
||||
#: model:res.groups,name:exp_official_mission.group_hr_training_manager
|
||||
msgid "Training Manager"
|
||||
msgstr "مدير التدريب"
|
||||
|
||||
|
||||
|
||||
#. module: exp_official_mission
|
||||
#: model:ir.ui.menu,name:exp_official_mission.hr_employee_official_mission_menu
|
||||
msgid "Employees Training Courses"
|
||||
msgstr "الدورات التدربية للموظفين"
|
||||
|
||||
#. module: exp_official_mission
|
||||
#: model:ir.ui.menu,name:exp_official_mission.hr_official_mission_config_menu
|
||||
msgid "Configurations"
|
||||
msgstr "الاعدادات"
|
||||
|
||||
|
||||
|
||||
#. module: exp_official_mission
|
||||
#: model:ir.ui.menu,name:exp_official_mission.hr_employee_training_types_config_menu
|
||||
msgid "Training Types"
|
||||
msgstr "انواع التدريب"
|
||||
|
||||
#. module: exp_official_mission
|
||||
#: model:ir.ui.menu,name:exp_official_mission.hr_official_mission_report_menu
|
||||
msgid "Reports"
|
||||
msgstr "التقارير"
|
||||
|
||||
#. module: exp_official_mission
|
||||
#: model:ir.ui.menu,name:hr_base_reports.employee_training_report_menu
|
||||
msgid "Training Report"
|
||||
msgstr "تقرير التدريب"
|
||||
|
||||
#. module: exp_official_mission
|
||||
#: model:ir.module.category,description:exp_official_mission.module_category_hr_employee_training
|
||||
msgid "Helps to Manage Employee Training Process..."
|
||||
msgstr "يساعد في إدارة عملية تدريب الموظفين"
|
||||
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -91,6 +91,7 @@ class HrOfficialMission(models.Model):
|
|||
ticket_request_id = fields.Many2one('hr.ticket.request', string="Ticket Request", readonly=True)
|
||||
department_id2 = fields.Many2one(related='employee_id.department_id', readonly=True,store=True,string='Department')
|
||||
is_branch = fields.Many2one(related='department_id2.branch_name', store=True, readonly=True)
|
||||
attachment_count = fields.Integer(string="Attachments", compute="_compute_attachment_count")
|
||||
|
||||
|
||||
'''@api.constrains('employee_ids')
|
||||
|
|
@ -120,6 +121,34 @@ class HrOfficialMission(models.Model):
|
|||
|
||||
#########################################
|
||||
|
||||
|
||||
def _compute_attachment_count(self):
|
||||
attachment = self.env['ir.attachment']
|
||||
for rec in self:
|
||||
rec.attachment_count = attachment.search_count([('res_model', '=', self._name), ('res_id', '=', rec.id)])
|
||||
|
||||
def action_get_attachment_view(self):
|
||||
domain = ['&', ('res_model', '=', self._name), ('res_id', 'in', self.ids)]
|
||||
res_id = self.ids and self.ids[0] or False
|
||||
return {
|
||||
'name': _('Attachments'),
|
||||
'domain': domain,
|
||||
'res_model': 'ir.attachment',
|
||||
'type': 'ir.actions.act_window',
|
||||
'view_id': False,
|
||||
'view_mode': 'kanban,tree,form',
|
||||
'view_type': 'form',
|
||||
'help': _('''<p class="oe_view_nocontent_create">
|
||||
|
||||
Attach
|
||||
documents of %s .</p>''' % (self._description)),
|
||||
'limit': 80,
|
||||
'context': "{'default_res_model': '%s','default_res_id': %d}"
|
||||
% (self._name, res_id)
|
||||
}
|
||||
|
||||
|
||||
|
||||
def get_user_id(self):
|
||||
employee_id = self.env['hr.employee'].search([('user_id', '=', self.env.uid)], limit=1)
|
||||
if employee_id:
|
||||
|
|
@ -353,6 +382,26 @@ class HrOfficialMission(models.Model):
|
|||
self.employee_ids.chick_not_overtime()
|
||||
self.state = "send"
|
||||
|
||||
|
||||
def send_depart_manager(self):
|
||||
for item in self:
|
||||
if not item.employee_ids:
|
||||
raise exceptions.Warning(_('The Request cannot Be completed without Employees'))
|
||||
|
||||
item.employee_ids.compute_Training_cost_emp()
|
||||
# item.chick_employee_ids()
|
||||
for line in item.employee_ids:
|
||||
mail_content = "Hello I'm", line.employee_id.name, " request Need to ", item.mission_type.name, "Please approved thanks."
|
||||
main_content = {
|
||||
'subject': _('Request To %s Employee %s') % (item.mission_type.name, line.employee_id.name),
|
||||
'author_id': self.env.user.partner_id.id,
|
||||
'body_html': mail_content,
|
||||
'email_to': line.employee_id.department_id.email_manager,
|
||||
}
|
||||
self.env['mail.mail'].sudo().create(main_content).send()
|
||||
self.employee_ids.chick_not_overtime()
|
||||
self.state = "depart_manager"
|
||||
|
||||
def direct_manager(self):
|
||||
# self.chick_employee_ids()
|
||||
self.employee_ids.chick_not_overtime()
|
||||
|
|
@ -817,6 +866,34 @@ class HrOfficialMissionEmployee(models.Model):
|
|||
total_hours = fields.Float()
|
||||
course_name = fields.Many2one(related='official_mission_id.course_name', readonly=True,
|
||||
store=True)
|
||||
attachment_count = fields.Integer(string="Attachments", compute="_compute_attachment_count")
|
||||
|
||||
|
||||
|
||||
def _compute_attachment_count(self):
|
||||
attachment = self.env['ir.attachment']
|
||||
for rec in self:
|
||||
rec.attachment_count = attachment.search_count([('res_model', '=', self._name), ('res_id', '=', rec.id)])
|
||||
|
||||
def action_get_attachment_view(self):
|
||||
domain = ['&', ('res_model', '=', self._name), ('res_id', 'in', self.ids)]
|
||||
res_id = self.ids and self.ids[0] or False
|
||||
return {
|
||||
'name': _('Attachments'),
|
||||
'domain': domain,
|
||||
'res_model': 'ir.attachment',
|
||||
'type': 'ir.actions.act_window',
|
||||
'view_id': False,
|
||||
'view_mode': 'kanban,tree,form',
|
||||
'view_type': 'form',
|
||||
'help': _('''<p class="oe_view_nocontent_create">
|
||||
|
||||
Attach
|
||||
documents of %s .</p>''' % (self._description)),
|
||||
'limit': 80,
|
||||
'context': "{'default_res_model': '%s','default_res_id': %d}"
|
||||
% (self._name, res_id)
|
||||
}
|
||||
|
||||
@api.constrains('date_from', 'date_to', 'hour_from', 'hour_to', 'employee_id')
|
||||
def check_dates(self):
|
||||
|
|
|
|||
|
|
@ -0,0 +1,26 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<odoo>
|
||||
<data>
|
||||
<record id="module_category_hr_employee_training" model="ir.module.category">
|
||||
<field name="name">Training</field>
|
||||
<field name="description">Helps to Manage Employee Training Process...</field>
|
||||
<field name="parent_id" eval="ref('base.module_category_human_resources')"/>
|
||||
|
||||
</record>
|
||||
|
||||
<record id="group_hr_training_user" model="res.groups">
|
||||
<field name="name">Training User</field>
|
||||
<field name="category_id" ref="module_category_hr_employee_training"/>
|
||||
<field name="implied_ids" eval="[(4, ref('hr.group_hr_user'))]"/>
|
||||
</record>
|
||||
|
||||
<record id="group_hr_training_manager" model="res.groups">
|
||||
<field name="name">Training Manager</field>
|
||||
<field name="category_id" ref="module_category_hr_employee_training"/>
|
||||
<field name="implied_ids" eval="[(4, ref('group_hr_training_user'))]"/>
|
||||
</record>
|
||||
|
||||
</data>
|
||||
|
||||
|
||||
</odoo>
|
||||
|
|
@ -197,6 +197,11 @@
|
|||
<field name="arch" type="xml">
|
||||
<form>
|
||||
<sheet>
|
||||
<div class="oe_button_box" name="button_box">
|
||||
<button name="action_get_attachment_view" class="oe_stat_button" icon="fa-file-text-o" type="object">
|
||||
<field name="attachment_count" widget="statinfo" string="Attachments" options="{'reload_on_button': true}"/>
|
||||
</button>
|
||||
</div>
|
||||
<group>
|
||||
<group>
|
||||
<field name="employee_id" readonly="1"/>
|
||||
|
|
|
|||
|
|
@ -342,6 +342,9 @@
|
|||
<field name="hour_to" widget="float_time"/>
|
||||
<field name="hours" widget="float_time"/>
|
||||
<field name="state" string="Status" invisible="1"/>
|
||||
<field name="attachment_count" invisible="1"/>
|
||||
<button name="action_get_attachment_view" string="Attachments" type="object" icon="fa-paperclip" attrs="{'invisible': [('attachment_count', '=', 0)]}"/>
|
||||
<field name="state" string="Status"/>
|
||||
</tree>
|
||||
</field>
|
||||
</record>
|
||||
|
|
|
|||
|
|
@ -7,6 +7,15 @@
|
|||
<field name="view_mode">tree,form</field>
|
||||
</record>
|
||||
|
||||
|
||||
<record model="ir.actions.act_window" id="employee_mission_type_training_settings_action">
|
||||
<field name="name">Mission Type Settings</field>
|
||||
<field name="res_model">hr.official.mission.type</field>
|
||||
<field name="view_mode">tree,form</field>
|
||||
<field name="domain">[('work_state','=','training')]</field>
|
||||
|
||||
</record>
|
||||
|
||||
<menuitem name="Mission Type Settings" id="mission_type_settings_menu_item"
|
||||
parent="hr.hr_menu_configuration"
|
||||
action="employee_mission_type_settings_action"
|
||||
|
|
@ -34,7 +43,8 @@
|
|||
|
||||
<field name="maximum_hours" string="Maximum hours"
|
||||
attrs="{'invisible':[('duration_type','!=','hours')]}"/>
|
||||
<field name="company_id" string="Company" groups="base.group_multi_company" readonly="1"/>
|
||||
<field name="company_id" string="Company" groups="base.group_multi_company"
|
||||
readonly="1"/>
|
||||
<field name="work_state" required="1" string='Mission Type'/>
|
||||
<field name="special_hours"
|
||||
attrs="{'invisible':[('work_state','not in',('others','work'))]}"/>
|
||||
|
|
|
|||
|
|
@ -20,12 +20,12 @@
|
|||
<field name="arch" type="xml">
|
||||
<form>
|
||||
<header>
|
||||
<button name="send" string="Submit" class="oe_highlight" type="object"
|
||||
<button name="send_depart_manager" string="Submit" class="oe_highlight" type="object"
|
||||
states="draft" groups="base.group_user"/>
|
||||
<button name="direct_manager" string="Direct Manager Approve" class="oe_highlight" type="object"
|
||||
states="send" groups="hr_base.group_division_manager"/>
|
||||
<button name="refused" string="Refused" class="oe_highlight" type="object"
|
||||
states="send" groups="hr_base.group_division_manager"/>
|
||||
<!-- <button name="direct_manager" string="Direct Manager Approve" class="oe_highlight" type="object"-->
|
||||
<!-- states="send" groups="hr_base.group_division_manager"/>-->
|
||||
<!-- <button name="refused" string="Refused" class="oe_highlight" type="object"-->
|
||||
<!-- states="send" groups="hr_base.group_division_manager"/>-->
|
||||
|
||||
<button name="depart_manager" string="Department Manager" class="oe_highlight" type="object"
|
||||
states="direct_manager" groups="hr_base.group_department_manager"/>
|
||||
|
|
@ -48,9 +48,14 @@
|
|||
<button name="draft_state" string="RE-Draft" class="oe_highlight" type="object"
|
||||
states="approve,refused" groups="hr.group_hr_user"
|
||||
confirm="Are you sure to Reset To Draft This Record?"/>
|
||||
<field name="state" widget="statusbar"/>
|
||||
<field name="state" widget="statusbar" statusbar_visible="draft,depart_manager,hr_aaproval,approve,refused"/>/>
|
||||
</header>
|
||||
<sheet>
|
||||
<div class="oe_button_box" name="button_box">
|
||||
<button name="action_get_attachment_view" class="oe_stat_button" icon="fa-file-text-o" type="object">
|
||||
<field name="attachment_count" widget="statinfo" string="Attachments" options="{'reload_on_button': true}"/>
|
||||
</button>
|
||||
</div>
|
||||
<group>
|
||||
<group>
|
||||
<field name="process_type" invisible="1"/>
|
||||
|
|
@ -84,21 +89,20 @@
|
|||
attrs="{'readonly':[('state','!=','draft')]}"/>
|
||||
</group>
|
||||
<group>
|
||||
<field name="company_id" groups="base.group_multi_company" readonly="1"/>
|
||||
<field name="company_id" groups="base.group_multi_company" readonly="1"/>
|
||||
<field name="employee_id" string="Responsible" required="1"
|
||||
attrs="{'readonly':[('state','!=','draft')]}"/>
|
||||
<field name="employee_no" string="Employee Number" readonly="1"/>
|
||||
<field name="department_id2" string="Department" readonly="1"/>
|
||||
<field name="date" string="Date Request" attrs="{'readonly':[('state','!=','draft')]}"
|
||||
required="1"/>
|
||||
<field name="department_id" string="Department" widget="many2many_tags" invisible="1"
|
||||
attrs="{'readonly':[('state','not in',('draft','direct_manager','depart_manager','send'))]}"/>
|
||||
<field name="country_id" string="Country" attrs="{'readonly':[('state','!=','draft')]}"/>
|
||||
<field name="destination" string="Destination" required="1" widget="selection"
|
||||
<field name="department_id" string="Department" widget="many2many_tags"/>
|
||||
<field name="country_id" string="Country"
|
||||
attrs="{'readonly':[('state','!=','draft')]}"/>
|
||||
<field name="destination" string="Destination" required="1" widget="selection"
|
||||
domain="[('country_id','=',country_id),('destination_type','in',('training','all'))]"
|
||||
attrs="{'readonly':[('state','not in',('draft','direct_manager','depart_manager','send'))] }"/>
|
||||
<field name="partner_id" string="Organiser" attrs="{'readonly':[('state','not in',('depart_manager','direct_manager','send'))],
|
||||
'invisible':[('state','=','draft')],'required':[('state','in',('depart_manager','direct_manager','send'))]}"/>
|
||||
<field name="partner_id" string="Organiser" required="1"/>
|
||||
<field name="move_type" string="Move type"
|
||||
attrs="{'readonly':[('state','!=','depart_manager')], 'required': [('state', '=', 'depart_manager')],'invisible':[('related_with_financial','=',False)]}"/>
|
||||
<field name="official_mission" string="Allowance Name"
|
||||
|
|
@ -106,20 +110,17 @@
|
|||
'invisible':['|',('related_with_financial','=',False),('move_type','!=','payroll')],
|
||||
'required':[('move_type','=','payroll'),('state', '=', 'depart_manager'),('related_with_financial','=',True)]}"/>
|
||||
<field name="Training_cost" string="Training Cost"
|
||||
groups="hr_base.group_account_manager,hr.group_hr_user,hr_base.group_division_manager"
|
||||
attrs="{'invisible':[('state','=','draft')],'readonly':[('state','not in',('depart_manager','direct_manager','send'))]}"/>
|
||||
groups="hr_base.group_account_manager,hr.group_hr_user,hr_base.group_division_manager"/>
|
||||
|
||||
<field name="Tra_cost_invo_id" string="Training Cost Invoice"
|
||||
attrs="{'invisible':[('state','!=','approve')]}"
|
||||
groups="hr_base.group_account_manager,hr.group_hr_user,hr_base.group_division_manager"/>
|
||||
|
||||
<field name="min_of_employee" string="Min Trainees"
|
||||
groups="hr_base.group_account_manager,hr.group_hr_user,hr_base.group_division_manager"
|
||||
attrs="{'invisible':[('state','=','draft')],'readonly':[('state','not in',('depart_manager','direct_manager','send','draft'))]}"/>
|
||||
groups="hr_base.group_account_manager,hr.group_hr_user,hr_base.group_division_manager"/>
|
||||
|
||||
<field name="max_of_employee" string="Max Trainees"
|
||||
groups="hr_base.group_account_manager,hr.group_hr_user,hr_base.group_division_manager"
|
||||
attrs="{'invisible':[('state','=','draft')],'readonly':[('state','not in',('depart_manager','direct_manager','send','draft'))]}"/>
|
||||
groups="hr_base.group_account_manager,hr.group_hr_user,hr_base.group_division_manager"/>
|
||||
<field name="appraisal_check" invisible="1"/>
|
||||
</group>
|
||||
</group>
|
||||
|
|
@ -132,7 +133,8 @@
|
|||
<field name="related_with_financial" invisible="1"/>
|
||||
<group>
|
||||
<button name="re_compute" string=" Re-Compute " type="object" class="oe_highlight"
|
||||
icon="fa-cogs" attrs="{'invisible':[('state','in',('approve','refused','send'))]}"/>
|
||||
icon="fa-cogs"
|
||||
attrs="{'invisible':[('state','in',('approve','refused','send'))]}"/>
|
||||
</group>
|
||||
<field name="employee_ids"
|
||||
attrs="{'readonly':[('state','not in',('depart_manager','direct_manager','send','draft'))]}">
|
||||
|
|
@ -181,6 +183,9 @@
|
|||
groups="hr_base.group_account_manager,hr.group_hr_user"
|
||||
attrs="{'column_invisible':['|',('parent.related_with_financial','=',False),
|
||||
('parent.move_type','!=','accounting')]}"/>
|
||||
<field name="attachment_count" invisible="1"/>
|
||||
<button name="action_get_attachment_view" string="Attachments" type="object" icon="fa-paperclip"/>
|
||||
|
||||
</tree>
|
||||
</field>
|
||||
</page>
|
||||
|
|
@ -199,24 +204,24 @@
|
|||
</group>
|
||||
|
||||
<group>
|
||||
<!-- <field name="ticket_insurance" string="Ticket Insurance"-->
|
||||
<!-- attrs="{'readonly':[('state','!=','draft')]}"/>-->
|
||||
<!-- <field name="ticket_insurance" string="Ticket Insurance"-->
|
||||
<!-- attrs="{'readonly':[('state','!=','draft')]}"/>-->
|
||||
<field name="self_car" string="Self Car"
|
||||
attrs="{'readonly':[('state','!=','draft')]}"/>
|
||||
<field name="visa" string="Visa" attrs="{'readonly':[('state','!=','draft')]}"/>
|
||||
<field name="note" string="Other"
|
||||
attrs="{'readonly':[('state','!=','draft')]}"/>
|
||||
</group>
|
||||
<!-- <group>-->
|
||||
<!-- <field name="car_insurance" string="Car Insurance"-->
|
||||
<!-- attrs="{'readonly':[('state','!=','draft')]}"/>-->
|
||||
<!-- <field name="car_type" string="Car Type"-->
|
||||
<!-- attrs="{'readonly':[('state','!=','draft')]}"/>-->
|
||||
<!-- <field name="rent_days" string="Rent Days"-->
|
||||
<!-- attrs="{'readonly':[('state','!=','draft')]}"/>-->
|
||||
<!-- <field name="max_rent" string="Max Rent"-->
|
||||
<!-- attrs="{'readonly':[('state','!=','draft')]}"/>-->
|
||||
<!-- </group>-->
|
||||
<!-- <group>-->
|
||||
<!-- <field name="car_insurance" string="Car Insurance"-->
|
||||
<!-- attrs="{'readonly':[('state','!=','draft')]}"/>-->
|
||||
<!-- <field name="car_type" string="Car Type"-->
|
||||
<!-- attrs="{'readonly':[('state','!=','draft')]}"/>-->
|
||||
<!-- <field name="rent_days" string="Rent Days"-->
|
||||
<!-- attrs="{'readonly':[('state','!=','draft')]}"/>-->
|
||||
<!-- <field name="max_rent" string="Max Rent"-->
|
||||
<!-- attrs="{'readonly':[('state','!=','draft')]}"/>-->
|
||||
<!-- </group>-->
|
||||
</group>
|
||||
</page>
|
||||
|
||||
|
|
@ -266,6 +271,8 @@
|
|||
<field name="date_from" string="Date From"/>
|
||||
<field name="date_to" string="Date To"/>
|
||||
<field name="destination" string="Destination"/>
|
||||
<field name="attachment_count" invisible="1"/>
|
||||
<button name="action_get_attachment_view" string="Attachments" type="object" icon="fa-paperclip" attrs="{'invisible': [('attachment_count', '=', 0)]}"/>
|
||||
<field name="state" string="Status"/>
|
||||
|
||||
</tree>
|
||||
|
|
@ -279,22 +286,25 @@
|
|||
<field name="type">search</field>
|
||||
<field name="arch" type="xml">
|
||||
<search>
|
||||
<field name="course_name"/>
|
||||
<field name="mission_type"/>
|
||||
<field name="employee_id"/>
|
||||
<field name="employee_no"/>
|
||||
<field name="destination"/>
|
||||
<field name="train_category"/>
|
||||
<field name="state"/>
|
||||
<field name="course_name"/>
|
||||
<field name="mission_type"/>
|
||||
<field name="employee_id"/>
|
||||
<field name="employee_no"/>
|
||||
<field name="destination"/>
|
||||
<field name="train_category"/>
|
||||
<field name="state"/>
|
||||
<group expand="0" string="Group By">
|
||||
<filter name="group_employee" string="Responsible" domain="[]" context="{'group_by': 'employee_id'}"/>
|
||||
<filter name="group_type" string="Mission Type" domain="[]" context="{'group_by': 'mission_type'}"/>
|
||||
<filter name="group_department" string="Department" domain="[]" context="{'group_by': 'department_id2'}"/>
|
||||
<filter name="group_employee" string="Responsible" domain="[]"
|
||||
context="{'group_by': 'employee_id'}"/>
|
||||
<filter name="group_type" string="Mission Type" domain="[]"
|
||||
context="{'group_by': 'mission_type'}"/>
|
||||
<filter name="group_department" string="Department" domain="[]"
|
||||
context="{'group_by': 'department_id2'}"/>
|
||||
<filter name="group_branch" string="Branch" domain="[]" context="{'group_by': 'is_branch'}"/>
|
||||
<filter name="group_state" string="State" domain="[]" context="{'group_by': 'state'}"/>
|
||||
</group>
|
||||
<separator/>
|
||||
<filter string="My Requests" name="my_request" domain="[('employee_id.user_id', '=', uid)]"/>
|
||||
<filter string="My Requests" name="my_request" domain="[('employee_id.user_id', '=', uid)]"/>
|
||||
<separator/>
|
||||
</search>
|
||||
|
||||
|
|
@ -331,5 +341,19 @@
|
|||
</field>
|
||||
</record>
|
||||
|
||||
|
||||
<record id="hr_employees_training_lines_action" model="ir.actions.act_window">
|
||||
<field name="name">Employees Official Mission</field>
|
||||
<field name="res_model">hr.official.mission.employee</field>
|
||||
<field name="view_mode">tree,form</field>
|
||||
<field name="domain">[('official_mission_id.process_type','=','training')]</field>
|
||||
<field name="help" type="html">
|
||||
<p class="oe_view_nocontent_create">
|
||||
Click to add a Employee official mission.
|
||||
</p>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
|
||||
</data>
|
||||
</odoo>
|
||||
|
|
|
|||
|
|
@ -0,0 +1,46 @@
|
|||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<odoo>
|
||||
<data>
|
||||
|
||||
<menuitem name="Training" id="hr_employee_training_main_menu"
|
||||
parent="hr.menu_hr_root" sequence="3"
|
||||
groups="group_hr_training_user"/>
|
||||
|
||||
<menuitem name="Training Courses" id="exp_official_mission.employee_training_menu_item"
|
||||
parent="hr_employee_training_main_menu" action="exp_official_mission.employee_training_action"
|
||||
sequence="1"
|
||||
groups="group_hr_training_user"/>
|
||||
|
||||
<menuitem name="Employees Training Courses" id="hr_employee_official_mission_menu"
|
||||
parent="hr_employee_training_main_menu"
|
||||
action="exp_official_mission.hr_employees_training_lines_action"
|
||||
sequence="2"
|
||||
groups="hr_base.group_division_manager"/>
|
||||
|
||||
<menuitem name="Configurations" id="hr_official_mission_config_menu"
|
||||
parent="hr_employee_training_main_menu" sequence="3"
|
||||
groups="group_hr_training_manager"/>
|
||||
|
||||
|
||||
<menuitem name="Training Courses Name" id="exp_official_mission.employee_course_name_menu"
|
||||
parent="hr_official_mission_config_menu" action="exp_official_mission.employee_course_name_action"
|
||||
sequence="1"
|
||||
groups="group_hr_training_manager"/>
|
||||
|
||||
<menuitem name="Training Types" id="hr_employee_training_types_config_menu"
|
||||
parent="hr_official_mission_config_menu" action="employee_mission_type_training_settings_action"
|
||||
sequence="2"
|
||||
groups="group_hr_training_manager"/>
|
||||
|
||||
|
||||
|
||||
<menuitem name="Reports" id="hr_official_mission_report_menu"
|
||||
parent="hr_employee_training_main_menu" sequence="4"
|
||||
groups="group_hr_training_user"/>
|
||||
|
||||
|
||||
|
||||
|
||||
</data>
|
||||
</odoo>
|
||||
|
||||
|
|
@ -145,7 +145,8 @@
|
|||
<menuitem
|
||||
id="employee_training_report_menu"
|
||||
name="Training Report"
|
||||
parent="employee_request_root_report_menu"
|
||||
parent="exp_official_mission.hr_official_mission_report_menu"
|
||||
sequence="1"
|
||||
action="employee_training_report_actions"
|
||||
/>
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue