Browse Source

[ADD] Initial Commit

pull/72/head
Sreejith P 7 years ago
parent
commit
32b0ce7170
  1. 22
      oh_employee_check_list/README.md
  2. 24
      oh_employee_check_list/__init__.py
  3. 47
      oh_employee_check_list/__manifest__.py
  4. 23
      oh_employee_check_list/data/data.xml
  5. 6
      oh_employee_check_list/doc/RELEASE_NOTES.md
  6. 29
      oh_employee_check_list/models/__init__.py
  7. BIN
      oh_employee_check_list/models/__pycache__/__init__.cpython-35.pyc
  8. BIN
      oh_employee_check_list/models/__pycache__/employee_entry_exit_check_list.cpython-35.pyc
  9. BIN
      oh_employee_check_list/models/__pycache__/employee_master_inherit.cpython-35.pyc
  10. BIN
      oh_employee_check_list/models/__pycache__/settings.cpython-35.pyc
  11. 54
      oh_employee_check_list/models/employee_entry_exit_check_list.py
  12. 87
      oh_employee_check_list/models/employee_master_inherit.py
  13. 40
      oh_employee_check_list/models/settings.py
  14. 4
      oh_employee_check_list/security/ir.model.access.csv
  15. BIN
      oh_employee_check_list/static/description/HRMS-BUTTON.png
  16. BIN
      oh_employee_check_list/static/description/banner.jpg
  17. BIN
      oh_employee_check_list/static/description/cybro-service.png
  18. BIN
      oh_employee_check_list/static/description/cybro_logo.png
  19. BIN
      oh_employee_check_list/static/description/icon.png
  20. 174
      oh_employee_check_list/static/description/index.html
  21. BIN
      oh_employee_check_list/static/description/oh_employee_form.png
  22. BIN
      oh_employee_check_list/static/description/oh_entry_checklist.png
  23. BIN
      oh_employee_check_list/static/description/oh_exit_chceklist.png
  24. BIN
      oh_employee_check_list/static/description/oh_kanban_Settings.png
  25. BIN
      oh_employee_check_list/static/description/oh_kanban_view.png
  26. BIN
      oh_employee_check_list/static/description/oh_tree_view.png
  27. 37
      oh_employee_check_list/views/checklist_view.xml
  28. 43
      oh_employee_check_list/views/employee_check_list_view.xml
  29. 62
      oh_employee_check_list/views/employee_form_inherit_view.xml
  30. 37
      oh_employee_check_list/views/settings_view.xml

22
oh_employee_check_list/README.md

@ -0,0 +1,22 @@
Open HRMS Employee Checklist
---------------------
Supporting Addon for Open HRMS, Manages Employee's Entry & Exit Process
Overview
--------
A well functioning human resource department will lay down a number procedure and process before an employee during joining/resigning time. It may be submission/Return of a certificate or attending a conference etc.
A person has to undergo all these checklist items before being admitted/resigned. The module simplifies the process by providing you a checklist to mark the proceedings. It will also display the PercentPie of the checklist items completed.
Connect with experts
--------------------
If you have any question/queries/additional works on OpenHRMS or this module, You can drop an email directly to Cybrosys.
Contacts
--------
info - info@cybrosys.com
Nilmar Shereef - shereef@cybrosys.in
Website:
https://www.openhrms.com
https://www.cybrosys.com

24
oh_employee_check_list/__init__.py

@ -0,0 +1,24 @@
# -*- coding: utf-8 -*-
###################################################################################
# A part of Open HRMS Project <https://www.openhrms.com>
#
# Cybrosys Technologies Pvt. Ltd.
# Copyright (C) 2018-TODAY Cybrosys Technologies (<https://www.cybrosys.com>).
# Author: Nilmar Shereef (<https://www.cybrosys.com>)
#
# This program is free software: you can modify
# it under the terms of the GNU Affero General Public License (AGPL) as
# published by the Free Software Foundation, either version 3 of the
# License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU Affero General Public License for more details.
#
# You should have received a copy of the GNU Affero General Public License
# along with this program. If not, see <https://www.gnu.org/licenses/>.
#
###################################################################################
from . import models

47
oh_employee_check_list/__manifest__.py

@ -0,0 +1,47 @@
# -*- coding: utf-8 -*-
###################################################################################
# A part of Open HRMS Project <https://www.openhrms.com>
#
# Cybrosys Technologies Pvt. Ltd.
# Copyright (C) 2018-TODAY Cybrosys Technologies (<https://www.cybrosys.com>).
# Author: Nilmar Shereef (<https://www.cybrosys.com>)
#
# This program is free software: you can modify
# it under the terms of the GNU Affero General Public License (AGPL) as
# published by the Free Software Foundation, either version 3 of the
# License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU Affero General Public License for more details.
#
# You should have received a copy of the GNU Affero General Public License
# along with this program. If not, see <https://www.gnu.org/licenses/>.
#
###################################################################################
{
'name': 'Open HRMS Employee Checklist',
'version': '11.0.1.0.0',
'summary': """Manages Employee's Entry & Exit Process""",
'description': """This module is a part of OH project, used to remembering the
employee's entry and exit progress.""",
'category': 'Generic Modules/Human Resources',
'author': 'Cybrosys Techno Solutions',
'company': 'Cybrosys Techno Solutions',
'website': "https://www.openhrms.com",
'depends': ['base', 'oh_employee_documents_expiry'],
'data': [
'security/ir.model.access.csv',
'views/employee_check_list_view.xml',
'views/employee_form_inherit_view.xml',
'views/settings_view.xml',
'views/checklist_view.xml',
],
'demo': ['data/data.xml'],
'images': ['static/description/banner.jpg'],
'license': 'AGPL-3',
'installable': True,
'auto_install': False,
'application': False,
}

23
oh_employee_check_list/data/data.xml

@ -0,0 +1,23 @@
<?xml version="1.0" encoding="utf-8"?>
<odoo>
<record id="entry_document1" model="employee.checklist">
<field name="name">Education Certificate</field>
<field name="document_type">entry</field>
</record>
<record id="entry_document2" model="employee.checklist">
<field name="name">Salary Certificate</field>
<field name="document_type">entry</field>
</record>
<record id="entry_document3" model="employee.checklist">
<field name="name">Experience Certificate</field>
<field name="document_type">entry</field>
</record>
<record id="exit_document1" model="employee.checklist">
<field name="name">Experience Certificate</field>
<field name="document_type">exit</field>
</record>
<record id="exit_document2" model="employee.checklist">
<field name="name">Salary Certificate</field>
<field name="document_type">exit</field>
</record>
</odoo>

6
oh_employee_check_list/doc/RELEASE_NOTES.md

@ -0,0 +1,6 @@
## Module 'oh_employee_check_list'
#### 21.04.2018
#### Version 11.0.1.0.0
##### ADD
- Initial commit for Open HRMS Project

29
oh_employee_check_list/models/__init__.py

@ -0,0 +1,29 @@
# -*- coding: utf-8 -*-
###################################################################################
# A part of Open HRMS Project <https://www.openhrms.com>
#
# Cybrosys Technologies Pvt. Ltd.
# Copyright (C) 2018-TODAY Cybrosys Technologies (<https://www.cybrosys.com>).
# Author: Nilmar Shereef (<https://www.cybrosys.com>)
#
# This program is free software: you can modify
# it under the terms of the GNU Affero General Public License (AGPL) as
# published by the Free Software Foundation, either version 3 of the
# License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU Affero General Public License for more details.
#
# You should have received a copy of the GNU Affero General Public License
# along with this program. If not, see <https://www.gnu.org/licenses/>.
#
###################################################################################
from . import employee_entry_exit_check_list
from . import employee_master_inherit
from . import settings

BIN
oh_employee_check_list/models/__pycache__/__init__.cpython-35.pyc

Binary file not shown.

BIN
oh_employee_check_list/models/__pycache__/employee_entry_exit_check_list.cpython-35.pyc

Binary file not shown.

BIN
oh_employee_check_list/models/__pycache__/employee_master_inherit.cpython-35.pyc

Binary file not shown.

BIN
oh_employee_check_list/models/__pycache__/settings.cpython-35.pyc

Binary file not shown.

54
oh_employee_check_list/models/employee_entry_exit_check_list.py

@ -0,0 +1,54 @@
# -*- coding: utf-8 -*-
###################################################################################
# A part of Open HRMS Project <https://www.openhrms.com>
#
# Cybrosys Technologies Pvt. Ltd.
# Copyright (C) 2018-TODAY Cybrosys Technologies (<https://www.cybrosys.com>).
# Author: Nilmar Shereef (<https://www.cybrosys.com>)
#
# This program is free software: you can modify
# it under the terms of the GNU Affero General Public License (AGPL) as
# published by the Free Software Foundation, either version 3 of the
# License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU Affero General Public License for more details.
#
# You should have received a copy of the GNU Affero General Public License
# along with this program. If not, see <https://www.gnu.org/licenses/>.
#
###################################################################################
from odoo import models, fields, api
class EmployeeEntryDocuments(models.Model):
_name = 'employee.checklist'
_inherit = ['mail.thread', 'mail.activity.mixin']
_description = "Employee Documents"
@api.multi
def name_get(self):
result = []
for each in self:
if each.document_type == 'entry':
name = each.name + '_en'
elif each.document_type == 'exit':
name = each.name + '_ex'
elif each.document_type == 'other':
name = each.name + '_ot'
result.append((each.id, name))
return result
name = fields.Char(string='Name', copy=False, required=1)
document_type = fields.Selection([('entry', 'Entry Process'),
('exit', 'Exit Process'),
('other', 'Other')], string='Checklist Type', help='Type of Checklist', readonly=1, required=1)
class HrEmployeeDocumentInherit(models.Model):
_inherit = 'hr.employee.document'
document_name = fields.Many2one('employee.checklist', string='Document', help='Type of Document', required=True)

87
oh_employee_check_list/models/employee_master_inherit.py

@ -0,0 +1,87 @@
# -*- coding: utf-8 -*-
###################################################################################
# A part of Open HRMS Project <https://www.openhrms.com>
#
# Cybrosys Technologies Pvt. Ltd.
# Copyright (C) 2018-TODAY Cybrosys Technologies (<https://www.cybrosys.com>).
# Author: Nilmar Shereef (<https://www.cybrosys.com>)
#
# This program is free software: you can modify
# it under the terms of the GNU Affero General Public License (AGPL) as
# published by the Free Software Foundation, either version 3 of the
# License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU Affero General Public License for more details.
#
# You should have received a copy of the GNU Affero General Public License
# along with this program. If not, see <https://www.gnu.org/licenses/>.
#
###################################################################################
from odoo import models, fields, api
class EmployeeMasterInherit(models.Model):
_inherit = 'hr.employee'
@api.depends('exit_checklist')
def exit_progress(self):
for each in self:
total_len = self.env['employee.checklist'].search_count([('document_type', '=', 'exit')])
entry_len = len(each.exit_checklist)
if total_len != 0:
each.exit_progress = (entry_len * 100) / total_len
@api.depends('entry_checklist')
def entry_progress(self):
for each in self:
total_len = self.env['employee.checklist'].search_count([('document_type', '=', 'entry')])
entry_len = len(each.entry_checklist)
if total_len != 0:
each.entry_progress = (entry_len*100) / total_len
entry_checklist = fields.Many2many('employee.checklist', 'entry_obj', 'check_hr_rel', 'hr_check_rel',
string='Entry Process',
domain=[('document_type', '=', 'entry')])
exit_checklist = fields.Many2many('employee.checklist', 'exit_obj', 'exit_hr_rel', 'hr_exit_rel',
string='Exit Process',
domain=[('document_type', '=', 'exit')])
entry_progress = fields.Float(compute=entry_progress, string='Entry Progress', store=True, default=0.0)
exit_progress = fields.Float(compute=exit_progress, string='Exit Progress', store=True, default=0.0)
maximum_rate = fields.Integer(default=100)
check_list_enable = fields.Boolean(invisible=True, copy=False)
class EmployeeDocumentInherit(models.Model):
_inherit = 'hr.employee.document'
@api.model
def create(self, vals):
result = super(EmployeeDocumentInherit, self).create(vals)
if result.document_name.document_type == 'entry':
result.employee_ref.write({'entry_checklist': [(4, result.document_name.id)]})
if result.document_name.document_type == 'exit':
result.employee_ref.write({'exit_checklist': [(4, result.document_name.id)]})
return result
@api.multi
def unlink(self):
"""This method is used to unlink the checklist according to the documents"""
for result in self:
if result.document_name.document_type == 'entry':
result.employee_ref.write({'entry_checklist': [(5, result.document_name.id)]})
if result.document_name.document_type == 'exit':
result.employee_ref.write({'exit_checklist': [(5, result.document_name.id)]})
res = super(EmployeeDocumentInherit, self).unlink()
return res
class EmployeeChecklistInherit(models.Model):
_inherit = 'employee.checklist'
entry_obj = fields.Many2many('hr.employee', 'entry_checklist', 'hr_check_rel', 'check_hr_rel',
invisible=1)
exit_obj = fields.Many2many('hr.employee', 'exit_checklist', 'hr_exit_rel', 'exit_hr_rel',
invisible=1)

40
oh_employee_check_list/models/settings.py

@ -0,0 +1,40 @@
# -*- coding: utf-8 -*-
###################################################################################
# A part of Open HRMS Project <https://www.openhrms.com>
#
# Cybrosys Technologies Pvt. Ltd.
# Copyright (C) 2018-TODAY Cybrosys Technologies (<https://www.cybrosys.com>).
# Author: Nilmar Shereef (<https://www.cybrosys.com>)
#
# This program is free software: you can modify
# it under the terms of the GNU Affero General Public License (AGPL) as
# published by the Free Software Foundation, either version 3 of the
# License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU Affero General Public License for more details.
#
# You should have received a copy of the GNU Affero General Public License
# along with this program. If not, see <https://www.gnu.org/licenses/>.
#
###################################################################################
from odoo import models, fields, api
class MenuThemes(models.Model):
_name = 'hr.settings'
_inherit = 'res.config.settings'
enable_checklist = fields.Boolean(string='Enable Checklist Progress in Kanban?')
@api.multi
def set_enable_checklist(self):
ir_values = self.env['ir.values']
enable_checklist = self.enable_checklist
ir_values.set_default('hr.settings', 'enable_checklist', enable_checklist)
emp_obj = self.env['hr.employee'].sudo().search([])
for each in emp_obj:
each.write({'check_list_enable': enable_checklist})

4
oh_employee_check_list/security/ir.model.access.csv

@ -0,0 +1,4 @@
id,name,model_id/id,group_id/id,perm_read,perm_write,perm_create,perm_unlink
access_hr_employee_checklist_user,employee.checklist.user,model_employee_checklist,hr.group_hr_user,1,1,1,1
access_hr_employee_checklist_emp,employee.checklist.emp,model_employee_checklist,base.group_user,1,0,0,0
access_hr.settings_manager,hr.settings.manager,model_hr_settings,hr.group_hr_manager,1,1,1,1
1 id name model_id/id group_id/id perm_read perm_write perm_create perm_unlink
2 access_hr_employee_checklist_user employee.checklist.user model_employee_checklist hr.group_hr_user 1 1 1 1
3 access_hr_employee_checklist_emp employee.checklist.emp model_employee_checklist base.group_user 1 0 0 0
4 access_hr.settings_manager hr.settings.manager model_hr_settings hr.group_hr_manager 1 1 1 1

BIN
oh_employee_check_list/static/description/HRMS-BUTTON.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 17 KiB

BIN
oh_employee_check_list/static/description/banner.jpg

Binary file not shown.

After

Width:  |  Height:  |  Size: 119 KiB

BIN
oh_employee_check_list/static/description/cybro-service.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 221 KiB

BIN
oh_employee_check_list/static/description/cybro_logo.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 50 KiB

BIN
oh_employee_check_list/static/description/icon.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 33 KiB

174
oh_employee_check_list/static/description/index.html

@ -0,0 +1,174 @@
<section class="oe_container">
<div class="oe_row">
<h2 class="oe_slogan">Open HRMS</h2>
<h3 class="oe_slogan">Most advanced open source HR management software</h3>
</div>
</section>
<section class="oe_container">
<div class="oe_row oe_spaced oe_mt32">
<div class="oe_span">
<div class="oe_demo oe_picture oe_screenshot">
<a href="https://www.openhrms.com/#request-demo">
<img src="HRMS-BUTTON.png">
</a>
<div class="oe_demo_footer oe_centeralign">Online Demo</div>
</div>
</div>
</div>
</section>
<section class="oe_container">
<div class="oe_row oe_spaced">
<h2 class="oe_slogan">Open HRMS Employee Exit/Entry Checklist</h2>
<h3 class="oe_slogan">Manages Employees Entry & Exit Process</h3>
<h4 class="oe_slogan"><a href="https://www.cybrosys.com">Cybrosys Technologies</a> </h4>
</div>
<div class="oe_row oe_spaced" style="padding-left:65px;">
<h4>Features:</h4>
<div>
<span style="color:green;"> &#9745; </span> Managing entry/exit process.<br/>
<span style="color:green;"> &#9745; </span> Automatic process on document attachments.<br/>
<span style="color:green;"> &#9745; </span> Option to enable Gauge widget for employee kanban.<br/>
<span style="color:green;"> &#9745; </span> Entry/Exit Percentpie in employee form view.<br/>
<span style="color:green;"> &#9745; </span> Entry Progressbar in employee tree view.<br/>
</div>
</div>
</section>
<section class="oe_container oe_dark">
<div class="oe_row oe_spaced">
<div class="oe_picture">
<h3 class="oe_slogan">Overview</h3>
<p class="oe_mt32 text-justify" style="text-align: center;">
A well functioning human resource department will lay down a number procedure and process before an employee during joining/resigning time. It may be submission/Return of a certificate or attending a conference etc.
A person has to undergo all these checklist items before being admitted/resigned. The module simplifies the process by providing you a checklist to mark the proceedings. It will also display the PercentPie of the checklist items completed.
</p>
</div>
</div>
</section>
<section class="oe_container">
<div class="oe_row oe_spaced">
<div style="text-align: center">
<p>
<h4>Entry/Exit Checklist</h4>
<p>
</div>
<div style="text-align: center">
<a href="https://www.cybrosys.com">
<div class="oe_demo oe_picture oe_screenshot">
<img style="border:10px solid white;" src="oh_entry_checklist.png">
</div>
</a>
</div>
<div style="text-align: center">
<a href="https://www.cybrosys.com">
<div class="oe_demo oe_picture oe_screenshot">
<img style="border:10px solid white;" src="oh_exit_chceklist.png">
</div>
</a>
</div>
</div>
</section>
<section class="oe_container oe_dark">
<div class="oe_row oe_spaced">
<div style="text-align: center">
<p>
<h4>Employee From View With PercentPie</h4>
</p>
</div>
<div class="" style="text-align: center">
<div class="oe_demo oe_picture oe_screenshot">
<img style="border:10px solid white;" src="oh_employee_form.png">
</div>
</div>
</div>
</section>
<section class="oe_container">
<div class="oe_row oe_spaced">
<div style="text-align: center">
<p>
<h4>Employee Tree View With Progressbar</h4>
</p>
</div>
<div class="" style="text-align: center">
<div class="oe_demo oe_picture oe_screenshot">
<img style="border:10px solid white;" src="oh_tree_view.png">
</div>
</div>
</div>
</section>
<section class="oe_container oe_dark">
<div class="oe_row oe_spaced">
<div style="text-align: center">
<p>
<h4>Employee Kanban View with Gauge</h4>
</p>
</div>
<div class="" style="text-align: center">
<div class="oe_demo oe_picture oe_screenshot">
<img style="border:10px solid white;" src="oh_kanban_view.png">
</div>
</div>
</div>
</section>
<section class="oe_container">
<div class="oe_row oe_spaced">
<div style="text-align: center">
<p>
<h4>Configuration</h4>
</p>
</div>
<div class="" style="text-align: center">
<div class="oe_demo oe_picture oe_screenshot">
<img style="border:10px solid white;" src="oh_kanban_Settings.png">
</div>
</div>
</div>
</section>
<div class="row section-content">
<div class="col-md-6 img-content">
<h3>Our Odoo Services</h3>
</div>
<div class="bc-span col-md-12">
<div class="inner-span">
<a target="_blank" href="https://www.openhrms.com">
<img class="img-border img-responsive thumbnail" src="cybro-service.png">
</a>
</div>
</div>
</div>
<section class="oe_container">
<h2 class="oe_slogan" style="margin-top:20px;" >Need Any Help?</h2>
<div class="oe_slogan" style="margin-top:10px !important;">
<div>
<a
class="btn btn-primary btn-lg mt8" style="color: #FFFFFF !important;border-radius: 0;"
href="https://www.cybrosys.com/contact/" target="_blank"><i
class="fa fa-phone"></i> Contact Us </a>
<a
class="btn btn-primary btn-lg mt8" style="color: #FFFFFF !important;border-radius: 0;"
href="https://www.odoo.com/apps/modules/browse?search=open+hrms" target="_blank"><i
class="fa fa-suitcase"></i> Other Open HRMS Addons </a>
<a
class="btn btn-primary btn-lg mt8" style="color: #FFFFFF !important;border-radius: 0;"
href="https://www.cybrosys.com/odoo-customization-and-installation/" target="_blank"><i
class="fa fa-wrench"></i> Request Customization </a>
</div>
<br>
<a href="https://www.cybrosys.com/" target="_blank">
<img src="cybro_logo.png" style="width: 190px; margin-bottom: 20px;" class="center-block">
</a>
</div>
</section>

BIN
oh_employee_check_list/static/description/oh_employee_form.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 80 KiB

BIN
oh_employee_check_list/static/description/oh_entry_checklist.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 22 KiB

BIN
oh_employee_check_list/static/description/oh_exit_chceklist.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 27 KiB

BIN
oh_employee_check_list/static/description/oh_kanban_Settings.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 8.3 KiB

BIN
oh_employee_check_list/static/description/oh_kanban_view.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 48 KiB

BIN
oh_employee_check_list/static/description/oh_tree_view.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 65 KiB

37
oh_employee_check_list/views/checklist_view.xml

@ -0,0 +1,37 @@
<?xml version="1.0" encoding="utf-8"?>
<odoo>
<record id="action_entry_checklist" model="ir.actions.act_window">
<field name="name">Entry Checklist</field>
<field name="type">ir.actions.act_window</field>
<field name="res_model">employee.checklist</field>
<field name="view_type">form</field>
<field name="view_mode">tree,form</field>
<field name="domain">[('document_type', '=', 'entry')]</field>
<field name="context">{"default_document_type":'entry'}</field>
<field name="help" type="html">
<p class="oe_view_nocontent_create">
Click to create a New Entry Checklist
</p>
</field>
</record>
<record id="action_exit_checklist" model="ir.actions.act_window">
<field name="name">Exit Checklist</field>
<field name="type">ir.actions.act_window</field>
<field name="res_model">employee.checklist</field>
<field name="view_type">form</field>
<field name="view_mode">tree,form</field>
<field name="domain">[('document_type', '=', 'exit')]</field>
<field name="context">{"default_document_type":'exit'}</field>
<field name="help" type="html">
<p class="oe_view_nocontent_create">
Click to create a New Exit Checklist
</p>
</field>
</record>
<menuitem id="employee_entry_checklist_menu" name="Entry Checklist" parent="checklist_settings" sequence="3"
action="action_entry_checklist"/>
<menuitem id="employee_exit_checklist_menu" name="Exit Checklist" parent="checklist_settings" sequence="4"
action="action_exit_checklist"/>
</odoo>

43
oh_employee_check_list/views/employee_check_list_view.xml

@ -0,0 +1,43 @@
<?xml version="1.0" encoding="utf-8"?>
<odoo>
<record model='ir.ui.view' id='employee_check_list_form_view'>
<field name="name">employee.checklist.form</field>
<field name="model">employee.checklist</field>
<field name="arch" type="xml">
<form string="Checklist">
<sheet>
<group>
<field name="name"/>
<field name="document_type"/>
</group>
</sheet>
<div class="oe_chatter">
<field name="message_follower_ids" widget="mail_followers"/>
<field name="message_ids" widget="mail_thread"/>
</div>
</form>
</field>
</record>
<record model='ir.ui.view' id='employee_check_list_tree_view'>
<field name="name">employee.checklist.tree</field>
<field name="model">employee.checklist</field>
<field name="arch" type="xml">
<tree>
<field name="name"/>
<field name="document_type"/>
</tree>
</field>
</record>
<record model="ir.ui.view" id="hr_employee_document_inherit_form_view">
<field name="name">hr.employee.document.form.inherit.view</field>
<field name="model">hr.employee.document</field>
<field name="inherit_id" ref="oh_employee_documents_expiry.employee_document_form_view"/>
<field name="arch" type="xml">
<field name="name" position="after">
<field name="document_name" options="{'no_create': True}"/>
</field>
</field>
</record>
</odoo>

62
oh_employee_check_list/views/employee_form_inherit_view.xml

@ -0,0 +1,62 @@
<?xml version="1.0" encoding="utf-8"?>
<odoo>
<record model="ir.ui.view" id="hr_employee_inherit_form_view">
<field name="name">hr.employee.form.view</field>
<field name="model">hr.employee</field>
<field name="inherit_id" ref="hr.view_employee_form"/>
<field name="arch" type="xml">
<field name="category_ids" position="after">
<div>
<field name="entry_progress" widget="percentpie"/>
<field name="exit_progress" widget="percentpie" class="oe_inline"/>
</div>
</field>
<page name="hr_settings" position="after">
<page name="checklist" string="Checklist" groups="hr.group_hr_manager">
<group>
<group name="entry_checklist" string="Entry Checklist">
<field name="entry_checklist" widget="many2many_checkboxes"/>
<field name="check_list_enable" invisible="1"/>
</group>
<group name="exit_checklist" string="Exit Checklist">
<field name="exit_checklist" widget="many2many_checkboxes"/>
</group>
</group>
</page>
</page>
</field>
</record>
<record model="ir.ui.view" id="hr_employee_inherit_tree_view">
<field name="name">hr.employee.tree.view</field>
<field name="model">hr.employee</field>
<field name="inherit_id" ref="hr.view_employee_tree"/>
<field name="arch" type="xml">
<field name="message_needaction" position="after">
<field name="entry_progress" widget="progressbar"/>
</field>
</field>
</record>
<record model="ir.ui.view" id="hr_employee_inherit_kanban_view">
<field name="name">hr.employee.kanban.view</field>
<field name="model">hr.employee</field>
<field name="inherit_id" ref="hr.hr_kanban_view_employees"/>
<field name="arch" type="xml">
<xpath expr="//templates" position="before">
<field name="entry_progress"/>
<field name="maximum_rate"/>
<field name="check_list_enable" invisible="1"/>
</xpath>
<xpath expr="//ul/li[last()]" position="after">
<li t-if="record.check_list_enable.raw_value==1">
<field name="entry_progress" widget="gauge" style="width:120px;height:90px;cursor:pointer;"
options="{'max_field': 'maximum_rate'}">
Entry Progress
</field>
</li>
</xpath>
</field>
</record>
</odoo>

37
oh_employee_check_list/views/settings_view.xml

@ -0,0 +1,37 @@
<?xml version="1.0" encoding="utf-8"?>
<odoo>
<data>
<record id="form_hr_settings" model="ir.ui.view">
<field name="name">hr.settings.form</field>
<field name="model">hr.settings</field>
<field name="arch" type="xml">
<form string="Hr Settings" class="oe_form_configuration">
<header>
<button string="Apply" type="object" name="execute" class="oe_highlight"/>
or
<button string="Cancel" type="object" name="cancel" class="oe_link"/>
</header>
<separator string="Entry Checklist"/>
<group>
<field name="enable_checklist"/>
</group>
</form>
</field>
</record>
<record id="action_hr_settings" model="ir.actions.act_window">
<field name="name">Hr Settings</field>
<field name="res_model">hr.settings</field>
<field name="view_mode">form</field>
<field name="target">inline</field>
</record>
<menuitem id="checklist_settings" parent="hr.menu_human_resources_configuration"
groups="hr.group_hr_manager"
sequence="10" name="Checklist Config"/>
<menuitem action="action_hr_settings" id="menu_settings" parent="checklist_settings"
groups="hr.group_hr_manager"
sequence="1" name="Settings"/>
</data>
</odoo>
Loading…
Cancel
Save