odoo-addon-hr-appraisal-oca 16.0.1.0.0.3__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- odoo/addons/hr_appraisal_oca/README.rst +218 -0
- odoo/addons/hr_appraisal_oca/__init__.py +2 -0
- odoo/addons/hr_appraisal_oca/__manifest__.py +28 -0
- odoo/addons/hr_appraisal_oca/data/mail_activity_type_data.xml +9 -0
- odoo/addons/hr_appraisal_oca/data/mail_template_data.xml +167 -0
- odoo/addons/hr_appraisal_oca/i18n/es.po +1201 -0
- odoo/addons/hr_appraisal_oca/i18n/hr_appraisal_oca.pot +1086 -0
- odoo/addons/hr_appraisal_oca/models/__init__.py +5 -0
- odoo/addons/hr_appraisal_oca/models/hr_appraisal.py +444 -0
- odoo/addons/hr_appraisal_oca/models/hr_appraisal_tag.py +21 -0
- odoo/addons/hr_appraisal_oca/models/hr_appraisal_template.py +31 -0
- odoo/addons/hr_appraisal_oca/models/hr_employee.py +125 -0
- odoo/addons/hr_appraisal_oca/models/res_config_settings.py +16 -0
- odoo/addons/hr_appraisal_oca/readme/CONTRIBUTORS.md +6 -0
- odoo/addons/hr_appraisal_oca/readme/DESCRIPTION.md +5 -0
- odoo/addons/hr_appraisal_oca/readme/USAGE.md +95 -0
- odoo/addons/hr_appraisal_oca/security/hr_appraisal_security.xml +58 -0
- odoo/addons/hr_appraisal_oca/security/ir.model.access.csv +10 -0
- odoo/addons/hr_appraisal_oca/static/description/banner.png +0 -0
- odoo/addons/hr_appraisal_oca/static/description/icon.png +0 -0
- odoo/addons/hr_appraisal_oca/static/description/index.html +535 -0
- odoo/addons/hr_appraisal_oca/tests/__init__.py +1 -0
- odoo/addons/hr_appraisal_oca/tests/test_hr_appraisal.py +120 -0
- odoo/addons/hr_appraisal_oca/views/hr_appraisal_form_view.xml +465 -0
- odoo/addons/hr_appraisal_oca/views/hr_appraisal_tag_form_view.xml +47 -0
- odoo/addons/hr_appraisal_oca/views/hr_appraisal_template_form_view.xml +106 -0
- odoo/addons/hr_appraisal_oca/views/hr_employee_form_view.xml +42 -0
- odoo/addons/hr_appraisal_oca/views/res_config_settings_views.xml +59 -0
- odoo/addons/hr_appraisal_oca/wizard/__init__.py +2 -0
- odoo/addons/hr_appraisal_oca/wizard/hr_appraisal_request_wizard_view.xml +40 -0
- odoo/addons/hr_appraisal_oca/wizard/hr_appraisal_wizard.py +159 -0
- odoo/addons/hr_appraisal_oca/wizard/hr_appraisal_wizard_form_view.xml +32 -0
- odoo/addons/hr_appraisal_oca/wizard/send_mail_with_template_wizard.py +52 -0
- odoo_addon_hr_appraisal_oca-16.0.1.0.0.3.dist-info/METADATA +233 -0
- odoo_addon_hr_appraisal_oca-16.0.1.0.0.3.dist-info/RECORD +37 -0
- odoo_addon_hr_appraisal_oca-16.0.1.0.0.3.dist-info/WHEEL +5 -0
- odoo_addon_hr_appraisal_oca-16.0.1.0.0.3.dist-info/top_level.txt +1 -0
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
<?xml version="1.0" encoding="utf-8" ?>
|
|
2
|
+
<odoo>
|
|
3
|
+
<record id="view_employee_form" model="ir.ui.view">
|
|
4
|
+
<field name="name">hr.employee.form.view</field>
|
|
5
|
+
<field name="model">hr.employee</field>
|
|
6
|
+
<field name="inherit_id" ref="hr.view_employee_form" />
|
|
7
|
+
<field name="arch" type="xml">
|
|
8
|
+
<div name="button_box" position="inside">
|
|
9
|
+
<field name="appraisal_count" invisible="1" />
|
|
10
|
+
<field name="ongoing_appraisal_count" invisible="1" />
|
|
11
|
+
<field name="last_appraisal_id" invisible="1" />
|
|
12
|
+
<field name="last_appraisal_state" invisible="1" />
|
|
13
|
+
<field name="can_open_last_appraisal" invisible="1" />
|
|
14
|
+
<button
|
|
15
|
+
name="action_open_last_appraisal"
|
|
16
|
+
class="oe_stat_button"
|
|
17
|
+
icon="fa-th-large"
|
|
18
|
+
attrs="{'invisible': [('can_open_last_appraisal', '=', False)]}"
|
|
19
|
+
type="object"
|
|
20
|
+
>
|
|
21
|
+
<div class="o_field_widget o_stat_info">
|
|
22
|
+
<span
|
|
23
|
+
class="o_stat_text"
|
|
24
|
+
attrs="{'invisible':[('last_appraisal_state', '==', '3_done')]}"
|
|
25
|
+
>
|
|
26
|
+
Ongoing
|
|
27
|
+
</span>
|
|
28
|
+
<span
|
|
29
|
+
class="o_stat_text"
|
|
30
|
+
attrs="{'invisible':[('last_appraisal_state', '!=', '3_done')]}"
|
|
31
|
+
>
|
|
32
|
+
Latest
|
|
33
|
+
</span>
|
|
34
|
+
<span class="o_stat_text">
|
|
35
|
+
Appraisal
|
|
36
|
+
</span>
|
|
37
|
+
</div>
|
|
38
|
+
</button>
|
|
39
|
+
</div>
|
|
40
|
+
</field>
|
|
41
|
+
</record>
|
|
42
|
+
</odoo>
|
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
<?xml version="1.0" encoding="utf-8" ?>
|
|
2
|
+
<odoo>
|
|
3
|
+
<record id="res_config_settings_view_form" model="ir.ui.view">
|
|
4
|
+
<field name="name">
|
|
5
|
+
res.config.settings.view.form.inherit.hr.appraisal.oca
|
|
6
|
+
</field>
|
|
7
|
+
<field name="model">res.config.settings</field>
|
|
8
|
+
<field name="priority" eval="10" />
|
|
9
|
+
<field name="inherit_id" ref="base.res_config_settings_view_form" />
|
|
10
|
+
<field name="arch" type="xml">
|
|
11
|
+
<xpath expr="//div[hasclass('settings')]" position="inside">
|
|
12
|
+
<div
|
|
13
|
+
class="app_settings_block"
|
|
14
|
+
string="Appraisal Settings"
|
|
15
|
+
data-string="Appraisal Settings"
|
|
16
|
+
data-key="hr_appraisal_oca"
|
|
17
|
+
groups="hr_appraisal_oca.group_appraisal_hr_officer"
|
|
18
|
+
>
|
|
19
|
+
<h2>Appraisal Feedback Templates</h2>
|
|
20
|
+
<div class="row mt16 o_settings_container">
|
|
21
|
+
<div class="col-12 col-lg-6 o_setting_box">
|
|
22
|
+
<div class="o_setting_left_pane" />
|
|
23
|
+
<div class="o_setting_right_pane">
|
|
24
|
+
<label for="appraisal_default_template_id" />
|
|
25
|
+
<div class="text-muted">
|
|
26
|
+
Set default appraisal template
|
|
27
|
+
</div>
|
|
28
|
+
<div class="mt16">
|
|
29
|
+
<field
|
|
30
|
+
name="appraisal_default_template_id"
|
|
31
|
+
class="oe_inline"
|
|
32
|
+
/>
|
|
33
|
+
</div>
|
|
34
|
+
</div>
|
|
35
|
+
</div>
|
|
36
|
+
</div>
|
|
37
|
+
</div>
|
|
38
|
+
</xpath>
|
|
39
|
+
</field>
|
|
40
|
+
</record>
|
|
41
|
+
<record id="action_hr_appraisal_config_settings" model="ir.actions.act_window">
|
|
42
|
+
<field name="name">Settings</field>
|
|
43
|
+
<field name="type">ir.actions.act_window</field>
|
|
44
|
+
<field name="res_model">res.config.settings</field>
|
|
45
|
+
<field name="view_mode">form</field>
|
|
46
|
+
<field name="target">inline</field>
|
|
47
|
+
<field name="context">
|
|
48
|
+
{'module' : 'hr_appraisal_oca', 'bin_size': False}
|
|
49
|
+
</field>
|
|
50
|
+
</record>
|
|
51
|
+
<menuitem
|
|
52
|
+
id="settings_menu_hr_appraisal_oca"
|
|
53
|
+
name="Settings"
|
|
54
|
+
parent="hr_appraisal_oca.menu_hr_appraisal_configuration"
|
|
55
|
+
action="action_hr_appraisal_config_settings"
|
|
56
|
+
sequence="0"
|
|
57
|
+
groups="base.group_system"
|
|
58
|
+
/>
|
|
59
|
+
</odoo>
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
<?xml version="1.0" encoding="utf-8" ?>
|
|
2
|
+
<odoo>
|
|
3
|
+
<record id="hr_appraisal_request_wizard_view" model="ir.ui.view">
|
|
4
|
+
<field name="name">hr.appraisal.request.wizard.view</field>
|
|
5
|
+
<field name="model">hr.appraisal.request.wizard</field>
|
|
6
|
+
<field name="type">form</field>
|
|
7
|
+
<field name="arch" type="xml">
|
|
8
|
+
<form string="Appraisal Request">
|
|
9
|
+
<group>
|
|
10
|
+
<field
|
|
11
|
+
name="recipient_ids"
|
|
12
|
+
widget="many2many_tags"
|
|
13
|
+
options="{'no_quick_create': True}"
|
|
14
|
+
context="{'show_email' : True, 'form_view_ref' : 'base.view_partner_simple_form'}"
|
|
15
|
+
/>
|
|
16
|
+
<field name="subject" placeholder="Appraisal Requested" />
|
|
17
|
+
</group>
|
|
18
|
+
<div>
|
|
19
|
+
<field name="user_body" nolabel="1" />
|
|
20
|
+
</div>
|
|
21
|
+
<footer>
|
|
22
|
+
<button
|
|
23
|
+
name="send_button"
|
|
24
|
+
type="object"
|
|
25
|
+
string="Send"
|
|
26
|
+
class="btn-primary"
|
|
27
|
+
/>
|
|
28
|
+
<button special="cancel" string="Cancel" class="btn-secondary" />
|
|
29
|
+
</footer>
|
|
30
|
+
</form>
|
|
31
|
+
</field>
|
|
32
|
+
</record>
|
|
33
|
+
<record id="hr_appraisal_request_wizard_action" model="ir.actions.act_window">
|
|
34
|
+
<field name="name">Appraisal Request Confirmation</field>
|
|
35
|
+
<field name="res_model">hr.appraisal.request.wizard</field>
|
|
36
|
+
<field name="view_mode">form</field>
|
|
37
|
+
<field name="target">new</field>
|
|
38
|
+
<field name="view_id" ref="hr_appraisal_request_wizard_view" />
|
|
39
|
+
</record>
|
|
40
|
+
</odoo>
|
|
@@ -0,0 +1,159 @@
|
|
|
1
|
+
# Copyright 2025 Fundacion Esment - Estefanía Bauzá
|
|
2
|
+
# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl).
|
|
3
|
+
|
|
4
|
+
from odoo import _, api, fields, models
|
|
5
|
+
|
|
6
|
+
|
|
7
|
+
class HrAppraisalWizard(models.TransientModel):
|
|
8
|
+
_name = "hr.appraisal.wizard"
|
|
9
|
+
_inherit = "mail.thread"
|
|
10
|
+
_description = "Wizard for feedback visibility confirmation to manager"
|
|
11
|
+
|
|
12
|
+
res_model = fields.Char(string="HR Appraisal", required=True)
|
|
13
|
+
res_id = fields.Integer(string="Resource ID", required=True)
|
|
14
|
+
|
|
15
|
+
def ok_button(self):
|
|
16
|
+
"""Publish employee feedback as manager."""
|
|
17
|
+
self.ensure_one()
|
|
18
|
+
record = self.env[self.res_model].browse(self.res_id)
|
|
19
|
+
record.employee_feedback_published = True
|
|
20
|
+
message = _(
|
|
21
|
+
"{user_name} decided, as Appraisal Officer, "
|
|
22
|
+
"to publish the employee's feedback"
|
|
23
|
+
).format(user_name=self.env.user.name)
|
|
24
|
+
record.message_post(
|
|
25
|
+
body=message,
|
|
26
|
+
subtype_xmlid="mail.mt_note",
|
|
27
|
+
)
|
|
28
|
+
|
|
29
|
+
|
|
30
|
+
class HrAppraisalRequestWizard(models.TransientModel):
|
|
31
|
+
_name = "hr.appraisal.request.wizard"
|
|
32
|
+
_inherit = "mail.composer.mixin"
|
|
33
|
+
_description = "Request an Appraisal"
|
|
34
|
+
|
|
35
|
+
appraisal_id = fields.Many2one("hr.appraisal", required=True)
|
|
36
|
+
recipient_ids = fields.Many2many("res.partner", string="Recipients", required=True)
|
|
37
|
+
user_body = fields.Html(string="User Contents")
|
|
38
|
+
subject = fields.Char()
|
|
39
|
+
recipient_users = fields.Many2many(
|
|
40
|
+
"res.users", string="Recipients Users", store=False
|
|
41
|
+
)
|
|
42
|
+
|
|
43
|
+
@api.model
|
|
44
|
+
def default_get(self, fields):
|
|
45
|
+
"""
|
|
46
|
+
Provide default values based on 'default_appraisal_id' in context.
|
|
47
|
+
|
|
48
|
+
Prefills recipients, users, subject, and appraisal ID using related
|
|
49
|
+
appraisal and appropriate email template.
|
|
50
|
+
"""
|
|
51
|
+
res = super().default_get(fields)
|
|
52
|
+
appraisal_id = self.env.context.get("default_appraisal_id")
|
|
53
|
+
if not appraisal_id:
|
|
54
|
+
return res
|
|
55
|
+
appraisal = self.env["hr.appraisal"].browse(appraisal_id)
|
|
56
|
+
recipients_ids = self._get_appraisal_recipients(appraisal, field="work_email")
|
|
57
|
+
recipients_users = self._get_appraisal_recipients(appraisal, field="user_id")
|
|
58
|
+
template_xml_id = (
|
|
59
|
+
"hr_appraisal_oca.mail_template_appraisal_request_from_employee"
|
|
60
|
+
if appraisal.env.user.employee_id == appraisal.employee_id
|
|
61
|
+
else "hr_appraisal_oca.mail_template_appraisal_request"
|
|
62
|
+
)
|
|
63
|
+
template = self.env.ref(template_xml_id, False)
|
|
64
|
+
subject = self.env["mail.template"]._render_template(
|
|
65
|
+
template.subject, template.model, [self.id]
|
|
66
|
+
)[self.id]
|
|
67
|
+
res.update(
|
|
68
|
+
{
|
|
69
|
+
"recipient_ids": recipients_ids.ids,
|
|
70
|
+
"recipient_users": recipients_users.ids or None,
|
|
71
|
+
"subject": subject,
|
|
72
|
+
"appraisal_id": appraisal.id,
|
|
73
|
+
}
|
|
74
|
+
)
|
|
75
|
+
return res
|
|
76
|
+
|
|
77
|
+
def _get_appraisal_recipients(self, appraisal, field="user_id"):
|
|
78
|
+
"""
|
|
79
|
+
Get recipients related to the appraisal for notifications.
|
|
80
|
+
|
|
81
|
+
:param appraisal: hr.appraisal record
|
|
82
|
+
:param field: Field to extract ('user_id' or 'work_email')
|
|
83
|
+
:return: res.users or res.partner recordset
|
|
84
|
+
"""
|
|
85
|
+
values = []
|
|
86
|
+
if appraisal.env.user.employee_id == appraisal.employee_id:
|
|
87
|
+
# Employee: notify managers
|
|
88
|
+
for manager in appraisal.manager_ids:
|
|
89
|
+
value = getattr(manager, field)
|
|
90
|
+
if value:
|
|
91
|
+
values.append(value.id if field == "user_id" else value)
|
|
92
|
+
elif (
|
|
93
|
+
appraisal.is_manager
|
|
94
|
+
and appraisal.env.user in appraisal.manager_user_ids
|
|
95
|
+
and getattr(appraisal.employee_id, field)
|
|
96
|
+
):
|
|
97
|
+
# Manager listed: notify employee
|
|
98
|
+
value = getattr(appraisal.employee_id, field)
|
|
99
|
+
values.append(value.id if field == "user_id" else value)
|
|
100
|
+
elif appraisal.is_manager and getattr(appraisal.employee_id, field):
|
|
101
|
+
# Other managers: notify employee and managers
|
|
102
|
+
value = getattr(appraisal.employee_id, field)
|
|
103
|
+
values.append(value.id if field == "user_id" else value)
|
|
104
|
+
for manager in appraisal.manager_ids:
|
|
105
|
+
value = getattr(manager, field)
|
|
106
|
+
if value:
|
|
107
|
+
values.append(value.id if field == "user_id" else value)
|
|
108
|
+
if field == "user_id":
|
|
109
|
+
return self.env["res.users"].search([("id", "in", values)])
|
|
110
|
+
return self.env["res.partner"].search([("email", "in", values)])
|
|
111
|
+
|
|
112
|
+
def send_button(self):
|
|
113
|
+
"""Send appraisal request email using the appropriate template."""
|
|
114
|
+
self.ensure_one()
|
|
115
|
+
appraisal = self.appraisal_id
|
|
116
|
+
template_xml_id = (
|
|
117
|
+
"hr_appraisal_oca.mail_template_appraisal_request_from_employee"
|
|
118
|
+
if appraisal.env.user.employee_id == appraisal.employee_id
|
|
119
|
+
else "hr_appraisal_oca.mail_template_appraisal_request"
|
|
120
|
+
)
|
|
121
|
+
template = self.env.ref(template_xml_id, False)
|
|
122
|
+
if not template:
|
|
123
|
+
return
|
|
124
|
+
ctx = {
|
|
125
|
+
"default_use_template": True,
|
|
126
|
+
"default_email_layout_xmlid": "mail.mail_notification_light",
|
|
127
|
+
"force_email": True,
|
|
128
|
+
"mail_notify_author": True,
|
|
129
|
+
"recipient_users": self.recipient_users,
|
|
130
|
+
"user_body": self.user_body,
|
|
131
|
+
}
|
|
132
|
+
composer = (
|
|
133
|
+
self.env["mail.compose.message"]
|
|
134
|
+
.with_context(**ctx)
|
|
135
|
+
.create(
|
|
136
|
+
{
|
|
137
|
+
"res_id": appraisal.id,
|
|
138
|
+
"model": "hr.appraisal",
|
|
139
|
+
"partner_ids": self.recipient_ids.ids,
|
|
140
|
+
"template_id": template.id,
|
|
141
|
+
"email_from": self.env.user.email_formatted,
|
|
142
|
+
"composition_mode": "comment",
|
|
143
|
+
}
|
|
144
|
+
)
|
|
145
|
+
)
|
|
146
|
+
update_values = composer._onchange_template_id(
|
|
147
|
+
template.id, "comment", "hr.appraisal", appraisal.id
|
|
148
|
+
).get("value", {})
|
|
149
|
+
if update_values:
|
|
150
|
+
composer.write(update_values)
|
|
151
|
+
composer.write({"subject": self.subject})
|
|
152
|
+
composer._action_send_mail()
|
|
153
|
+
message = self.env["mail.message"].search(
|
|
154
|
+
[("model", "=", "hr.appraisal"), ("res_id", "=", appraisal.id)],
|
|
155
|
+
order="id desc",
|
|
156
|
+
limit=1,
|
|
157
|
+
)
|
|
158
|
+
if message:
|
|
159
|
+
message.write({"reply_to": self.env.user.email_formatted})
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
<?xml version="1.0" encoding="utf-8" ?>
|
|
2
|
+
<odoo>
|
|
3
|
+
<record id="hr_appraisal_wizard_form_view" model="ir.ui.view">
|
|
4
|
+
<field name="name">hr.appraisal.wizard.form.view</field>
|
|
5
|
+
<field name="model">hr.appraisal.wizard</field>
|
|
6
|
+
<field name="type">form</field>
|
|
7
|
+
<field name="arch" type="xml">
|
|
8
|
+
<form string="Confirmation">
|
|
9
|
+
<p>
|
|
10
|
+
The employee's feedback will be published without their consent. Do you really want to publish it?
|
|
11
|
+
This action will be logger in the chatter.
|
|
12
|
+
</p>
|
|
13
|
+
<footer>
|
|
14
|
+
<button
|
|
15
|
+
name="ok_button"
|
|
16
|
+
type="object"
|
|
17
|
+
string="Ok"
|
|
18
|
+
class="btn-primary"
|
|
19
|
+
/>
|
|
20
|
+
<button special="cancel" string="Cancel" class="btn-secondary" />
|
|
21
|
+
</footer>
|
|
22
|
+
</form>
|
|
23
|
+
</field>
|
|
24
|
+
</record>
|
|
25
|
+
<record id="hr_appraisal_wizard_action" model="ir.actions.act_window">
|
|
26
|
+
<field name="name">Appraisal Confirmation</field>
|
|
27
|
+
<field name="res_model">hr.appraisal.wizard</field>
|
|
28
|
+
<field name="view_mode">form</field>
|
|
29
|
+
<field name="target">new</field>
|
|
30
|
+
<field name="view_id" ref="hr_appraisal_wizard_form_view" />
|
|
31
|
+
</record>
|
|
32
|
+
</odoo>
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
from odoo import _, api, models
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
class SendEmailWithTemplate(models.TransientModel):
|
|
5
|
+
_name = "send.email.with.template"
|
|
6
|
+
_description = "Sending Email with Template"
|
|
7
|
+
|
|
8
|
+
@api.model
|
|
9
|
+
def send_email_with_template(self, template_xml_id, recipient_id, email, ctx):
|
|
10
|
+
template = self.env.ref(template_xml_id)
|
|
11
|
+
if not template:
|
|
12
|
+
raise ValueError(
|
|
13
|
+
_("Template with XML ID {template_xml_id} not found.").format(
|
|
14
|
+
template_xml_id=template_xml_id
|
|
15
|
+
)
|
|
16
|
+
)
|
|
17
|
+
template = template.with_context(**ctx)
|
|
18
|
+
subject = template._render_field("subject", [recipient_id], post_process=False)[
|
|
19
|
+
recipient_id
|
|
20
|
+
]
|
|
21
|
+
body = template._render_field("body_html", [recipient_id], post_process=True)[
|
|
22
|
+
recipient_id
|
|
23
|
+
]
|
|
24
|
+
mail_values = {
|
|
25
|
+
"email_from": self.env.user.email_formatted,
|
|
26
|
+
"author_id": self.env.user.partner_id.id,
|
|
27
|
+
"model": None,
|
|
28
|
+
"res_id": None,
|
|
29
|
+
"subject": subject,
|
|
30
|
+
"body_html": body,
|
|
31
|
+
"auto_delete": True,
|
|
32
|
+
"email_to": email,
|
|
33
|
+
"reply_to": self.env.user.email_formatted,
|
|
34
|
+
}
|
|
35
|
+
template_ctx = {
|
|
36
|
+
"model_description": self.env["ir.model"]._get("hr.appraisal").display_name,
|
|
37
|
+
"message": self.env["mail.message"]
|
|
38
|
+
.sudo()
|
|
39
|
+
.new(dict(body=mail_values["body_html"], record_name=_("Appraisal"))),
|
|
40
|
+
"company": self.env.company,
|
|
41
|
+
}
|
|
42
|
+
body = self.env["ir.qweb"]._render(
|
|
43
|
+
"mail.mail_notification_light",
|
|
44
|
+
template_ctx,
|
|
45
|
+
minimal_qcontext=True,
|
|
46
|
+
raise_if_not_found=False,
|
|
47
|
+
)
|
|
48
|
+
if body:
|
|
49
|
+
mail_values["body_html"] = self.env[
|
|
50
|
+
"mail.render.mixin"
|
|
51
|
+
]._replace_local_links(body)
|
|
52
|
+
self.env["mail.mail"].sudo().create(mail_values)
|
|
@@ -0,0 +1,233 @@
|
|
|
1
|
+
Metadata-Version: 2.1
|
|
2
|
+
Name: odoo-addon-hr_appraisal_oca
|
|
3
|
+
Version: 16.0.1.0.0.3
|
|
4
|
+
Summary: Module for managing employee appraisals
|
|
5
|
+
Home-page: https://github.com/OCA/hr
|
|
6
|
+
Author: Fundación Esment, Odoo Community Association (OCA)
|
|
7
|
+
Author-email: support@odoo-community.org
|
|
8
|
+
License: AGPL-3
|
|
9
|
+
Classifier: Programming Language :: Python
|
|
10
|
+
Classifier: Framework :: Odoo
|
|
11
|
+
Classifier: Framework :: Odoo :: 16.0
|
|
12
|
+
Classifier: License :: OSI Approved :: GNU Affero General Public License v3
|
|
13
|
+
Requires-Python: >=3.10
|
|
14
|
+
Requires-Dist: odoo<16.1dev,>=16.0a
|
|
15
|
+
|
|
16
|
+
.. image:: https://odoo-community.org/readme-banner-image
|
|
17
|
+
:target: https://odoo-community.org/get-involved?utm_source=readme
|
|
18
|
+
:alt: Odoo Community Association
|
|
19
|
+
|
|
20
|
+
=============
|
|
21
|
+
Appraisal Oca
|
|
22
|
+
=============
|
|
23
|
+
|
|
24
|
+
..
|
|
25
|
+
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
|
|
26
|
+
!! This file is generated by oca-gen-addon-readme !!
|
|
27
|
+
!! changes will be overwritten. !!
|
|
28
|
+
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
|
|
29
|
+
!! source digest: sha256:d1946002660b919f664e9679611e20cec90d54dcf506f5ee30a69d6bb3ac031d
|
|
30
|
+
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
|
|
31
|
+
|
|
32
|
+
.. |badge1| image:: https://img.shields.io/badge/maturity-Beta-yellow.png
|
|
33
|
+
:target: https://odoo-community.org/page/development-status
|
|
34
|
+
:alt: Beta
|
|
35
|
+
.. |badge2| image:: https://img.shields.io/badge/license-AGPL--3-blue.png
|
|
36
|
+
:target: http://www.gnu.org/licenses/agpl-3.0-standalone.html
|
|
37
|
+
:alt: License: AGPL-3
|
|
38
|
+
.. |badge3| image:: https://img.shields.io/badge/github-OCA%2Fhr-lightgray.png?logo=github
|
|
39
|
+
:target: https://github.com/OCA/hr/tree/16.0/hr_appraisal_oca
|
|
40
|
+
:alt: OCA/hr
|
|
41
|
+
.. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png
|
|
42
|
+
:target: https://translation.odoo-community.org/projects/hr-16-0/hr-16-0-hr_appraisal_oca
|
|
43
|
+
:alt: Translate me on Weblate
|
|
44
|
+
.. |badge5| image:: https://img.shields.io/badge/runboat-Try%20me-875A7B.png
|
|
45
|
+
:target: https://runboat.odoo-community.org/builds?repo=OCA/hr&target_branch=16.0
|
|
46
|
+
:alt: Try me on Runboat
|
|
47
|
+
|
|
48
|
+
|badge1| |badge2| |badge3| |badge4| |badge5|
|
|
49
|
+
|
|
50
|
+
This module helps maintain the employee motivation process through
|
|
51
|
+
periodic performance appraisals.
|
|
52
|
+
|
|
53
|
+
Managers can evaluate employee performance and enable employees to
|
|
54
|
+
perform self-assessments. Review forms can be customized according to
|
|
55
|
+
organizational needs.
|
|
56
|
+
|
|
57
|
+
**Table of contents**
|
|
58
|
+
|
|
59
|
+
.. contents::
|
|
60
|
+
:local:
|
|
61
|
+
|
|
62
|
+
Usage
|
|
63
|
+
=====
|
|
64
|
+
|
|
65
|
+
To create a new appraisal for an employee, first navigate to the main
|
|
66
|
+
Appraisals dashboard by opening the Appraisals app. The Appraisals
|
|
67
|
+
dashboard is the default view.
|
|
68
|
+
|
|
69
|
+
All appraisals are displayed on the dashboard in a default Kanban view.
|
|
70
|
+
To view the details of any appraisal, click on the card to open the
|
|
71
|
+
appraisal form.
|
|
72
|
+
|
|
73
|
+
1. Create an appraisal: To create a new appraisal, click the New button
|
|
74
|
+
in the upper-left corner of the Appraisals dashboard. Doing so reveals a
|
|
75
|
+
blank appraisal form. After entering a name in the first blank field,
|
|
76
|
+
proceed to enter the following information on the form: \* Employee:
|
|
77
|
+
Select the employee for whom you are creating the appraisal. \*
|
|
78
|
+
Managers: Select the managers who will be involved in the appraisal
|
|
79
|
+
process. \* Date Close: Select the date when the appraisal is expected
|
|
80
|
+
to be completed. \* Appraisal Template: Select the template that will be
|
|
81
|
+
used for this appraisal. \* Appraisal Tags: Add any relevant tags to
|
|
82
|
+
categorize the appraisal.
|
|
83
|
+
|
|
84
|
+
Once the form is complete, click the Confirm button to confirm the
|
|
85
|
+
appraisal request.
|
|
86
|
+
|
|
87
|
+
Once confirmed, the employee receives an email stating that an appraisal
|
|
88
|
+
was requested, and is then prompted to schedule an appraisal date. The
|
|
89
|
+
next steps require the employee to fill out the self-assessment, after
|
|
90
|
+
which the manager completes their assessment.
|
|
91
|
+
|
|
92
|
+
The status changes to Confirmed, and the Employee’s Feedback section of
|
|
93
|
+
the Appraisal tab is grayed out. The information in that section only
|
|
94
|
+
appears after the self-assessment is published by the employee.
|
|
95
|
+
|
|
96
|
+
If there are any existing appraisals for the employee, an Appraisal
|
|
97
|
+
smart button appears at the top of the page, listing the total number of
|
|
98
|
+
appraisals there are for the employee.
|
|
99
|
+
|
|
100
|
+
2. Employee’s feedback To complete their portion of feedback, employees
|
|
101
|
+
should navigate to the main Appraisals application dashboard, where the
|
|
102
|
+
only entries visible are appraisals for the employee, themselves, and/or
|
|
103
|
+
anyone they manage and have to provide manager feedback for.
|
|
104
|
+
|
|
105
|
+
Click on the appraisal to open the appraisal form. Enter responses in
|
|
106
|
+
the Employee’s Feedback section, under the Appraisal tab.
|
|
107
|
+
|
|
108
|
+
When completed, click the Not Visible to Manager toggle (the default
|
|
109
|
+
setting once an appraisal is confirmed). When clicked, the toggle
|
|
110
|
+
changes to Visible to Manager.
|
|
111
|
+
|
|
112
|
+
3. Manager’s feedback After the employee has completed the Employee’s
|
|
113
|
+
Feedback section, under the Appraisal tab, it is time for the manager to
|
|
114
|
+
fill out the Manager’s Feedback section.
|
|
115
|
+
|
|
116
|
+
The manager enters their responses in the fields in the same manner as
|
|
117
|
+
the employee.
|
|
118
|
+
|
|
119
|
+
When the feedback section is completed, click the Not Visible to
|
|
120
|
+
Employee toggle (the default setting once an appraisal is confirmed).
|
|
121
|
+
When clicked, the toggle changes to Visible to Employee.
|
|
122
|
+
|
|
123
|
+
4. Private Note tab If managers want to leave notes that are only
|
|
124
|
+
visible to other managers, they can be entered in the Private Note tab.
|
|
125
|
+
This can be done before or after meeting with the employee to discuss
|
|
126
|
+
the appraisal.
|
|
127
|
+
|
|
128
|
+
The employee being evaluated does not have access to this tab, and the
|
|
129
|
+
tab does not appear on their appraisal.
|
|
130
|
+
|
|
131
|
+
5. Complete an appraisal After the appraisal is complete, and both the
|
|
132
|
+
manager and employee have met to discuss the appraisal, the appraisal
|
|
133
|
+
can be marked as Done. When completed, click the Mark as Done button on
|
|
134
|
+
the appraisal form, located in the top-left corner.
|
|
135
|
+
|
|
136
|
+
Once the appraisal is marked as Done, the Mark as Done button
|
|
137
|
+
disappears, and a Reopen button appears.
|
|
138
|
+
|
|
139
|
+
6. Permissions and User Types To manage access permissions to the
|
|
140
|
+
Appraisals app, go to Settings > Users & Companies > Users and select
|
|
141
|
+
the desired user. In the Access tab, you will find the Appraisal
|
|
142
|
+
Permissions section. The following user types are available:
|
|
143
|
+
|
|
144
|
+
- User: Can access their own appraisals and complete evaluations of
|
|
145
|
+
their direct and indirect reporting employees.
|
|
146
|
+
- Human resources officer: Has full access to all appraisals and
|
|
147
|
+
settings, and can manage templates, tags, permissions, and all
|
|
148
|
+
records.
|
|
149
|
+
|
|
150
|
+
Make sure to assign the appropriate access type based on the user's role
|
|
151
|
+
in the organization. Permissions determine what actions each user can
|
|
152
|
+
perform within the Appraisals module.
|
|
153
|
+
|
|
154
|
+
7. Archive and Restore Appraisals To archive an appraisal, open the
|
|
155
|
+
record and select Archive from the Action menu. Archived appraisals are
|
|
156
|
+
hidden from the main views.
|
|
157
|
+
|
|
158
|
+
To view archived appraisals, use the Archived filter in the search bar.
|
|
159
|
+
|
|
160
|
+
To restore an appraisal, open it (with the Archived filter active) and
|
|
161
|
+
click Restore.
|
|
162
|
+
|
|
163
|
+
Archiving does not delete the record; you can archive or restore
|
|
164
|
+
appraisals at any time.
|
|
165
|
+
|
|
166
|
+
- Tip
|
|
167
|
+
|
|
168
|
+
Modifications are not possible once the appraisal is marked as done.
|
|
169
|
+
|
|
170
|
+
To make any changes to an appraisal that is marked as Done, click the
|
|
171
|
+
Reopen button.
|
|
172
|
+
|
|
173
|
+
Then, click the Confirm button that appears, and make any modifications
|
|
174
|
+
needed. Once all modifications are complete, click the Mark as Done
|
|
175
|
+
button again.
|
|
176
|
+
|
|
177
|
+
Bug Tracker
|
|
178
|
+
===========
|
|
179
|
+
|
|
180
|
+
Bugs are tracked on `GitHub Issues <https://github.com/OCA/hr/issues>`_.
|
|
181
|
+
In case of trouble, please check there if your issue has already been reported.
|
|
182
|
+
If you spotted it first, help us to smash it by providing a detailed and welcomed
|
|
183
|
+
`feedback <https://github.com/OCA/hr/issues/new?body=module:%20hr_appraisal_oca%0Aversion:%2016.0%0A%0A**Steps%20to%20reproduce**%0A-%20...%0A%0A**Current%20behavior**%0A%0A**Expected%20behavior**>`_.
|
|
184
|
+
|
|
185
|
+
Do not contact contributors directly about support or help with technical issues.
|
|
186
|
+
|
|
187
|
+
Credits
|
|
188
|
+
=======
|
|
189
|
+
|
|
190
|
+
Authors
|
|
191
|
+
-------
|
|
192
|
+
|
|
193
|
+
* Fundación Esment
|
|
194
|
+
|
|
195
|
+
Contributors
|
|
196
|
+
------------
|
|
197
|
+
|
|
198
|
+
- `Fundación Esment <https://esment.org/>`__:
|
|
199
|
+
|
|
200
|
+
- Estefanía Bauzá
|
|
201
|
+
|
|
202
|
+
- `Tecnativa <https://www.tecnativa.com/>`__:
|
|
203
|
+
|
|
204
|
+
- Pedro M. Baeza
|
|
205
|
+
- Christian Ramos
|
|
206
|
+
|
|
207
|
+
Maintainers
|
|
208
|
+
-----------
|
|
209
|
+
|
|
210
|
+
This module is maintained by the OCA.
|
|
211
|
+
|
|
212
|
+
.. image:: https://odoo-community.org/logo.png
|
|
213
|
+
:alt: Odoo Community Association
|
|
214
|
+
:target: https://odoo-community.org
|
|
215
|
+
|
|
216
|
+
OCA, or the Odoo Community Association, is a nonprofit organization whose
|
|
217
|
+
mission is to support the collaborative development of Odoo features and
|
|
218
|
+
promote its widespread use.
|
|
219
|
+
|
|
220
|
+
.. |maintainer-ebauza| image:: https://github.com/ebauza.png?size=40px
|
|
221
|
+
:target: https://github.com/ebauza
|
|
222
|
+
:alt: ebauza
|
|
223
|
+
.. |maintainer-pedrobaeza| image:: https://github.com/pedrobaeza.png?size=40px
|
|
224
|
+
:target: https://github.com/pedrobaeza
|
|
225
|
+
:alt: pedrobaeza
|
|
226
|
+
|
|
227
|
+
Current `maintainers <https://odoo-community.org/page/maintainer-role>`__:
|
|
228
|
+
|
|
229
|
+
|maintainer-ebauza| |maintainer-pedrobaeza|
|
|
230
|
+
|
|
231
|
+
This module is part of the `OCA/hr <https://github.com/OCA/hr/tree/16.0/hr_appraisal_oca>`_ project on GitHub.
|
|
232
|
+
|
|
233
|
+
You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute.
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
odoo/addons/hr_appraisal_oca/README.rst,sha256=kAAB5G_guj_wAl66pqMFw4UP7R_q-ATNEVsBW05fHzU,8522
|
|
2
|
+
odoo/addons/hr_appraisal_oca/__init__.py,sha256=R3l5zcM1DHY7iqr3kt92069kmImpPafRbNSzv6p_hBE,42
|
|
3
|
+
odoo/addons/hr_appraisal_oca/__manifest__.py,sha256=cGtpZjCbc9McYm9ueZwxrMlOYRM853tfLYGVe6fegG8,1112
|
|
4
|
+
odoo/addons/hr_appraisal_oca/data/mail_activity_type_data.xml,sha256=wBIs7iQZUvT8MruoEf_N25fLJk4s6L_soOmfd4Msj0w,367
|
|
5
|
+
odoo/addons/hr_appraisal_oca/data/mail_template_data.xml,sha256=Um-xsugoYZkPm1OSlyZYYyAEYGrHPMOm8-3zVNGHhVs,8371
|
|
6
|
+
odoo/addons/hr_appraisal_oca/i18n/es.po,sha256=QWzvanMKHIB48vsZk-SvZWW0AkLAsaZBFacdT35l6wc,52833
|
|
7
|
+
odoo/addons/hr_appraisal_oca/i18n/hr_appraisal_oca.pot,sha256=W_AtZ3WIkVwvq5jQhjaHEFwoHPsGWbqiLuKkkKt8_mw,42533
|
|
8
|
+
odoo/addons/hr_appraisal_oca/models/__init__.py,sha256=vRZeJNBp_rMcchVLtAUhQCm3yiRDiaxK_OPP4p1ga5c,154
|
|
9
|
+
odoo/addons/hr_appraisal_oca/models/hr_appraisal.py,sha256=2uRUM6BHandfuWTVpeXQJKrZTEGVzY42BlKoKWdiUg4,16806
|
|
10
|
+
odoo/addons/hr_appraisal_oca/models/hr_appraisal_tag.py,sha256=wDB9qkZM0PZnDX2LkPW5xgbzwCwvLqmihsPnYz5AJ58,557
|
|
11
|
+
odoo/addons/hr_appraisal_oca/models/hr_appraisal_template.py,sha256=wVDITaq7-lHEeYdrz_acMxtqxVI3PaUo_kf7WSws9f0,1052
|
|
12
|
+
odoo/addons/hr_appraisal_oca/models/hr_employee.py,sha256=grr4aT6_iPnflAW5oe77Mh5AoV2dYedtz54L-SO5c50,4418
|
|
13
|
+
odoo/addons/hr_appraisal_oca/models/res_config_settings.py,sha256=yK5oBRuT_vPgnUZoJjVtzRkGAweSFbAOHVb5T_qOrRI,603
|
|
14
|
+
odoo/addons/hr_appraisal_oca/readme/CONTRIBUTORS.md,sha256=By422O3dBk_AwjcaQ8nRVkjfZdlka1yfm8hjZ2_wugE,148
|
|
15
|
+
odoo/addons/hr_appraisal_oca/readme/DESCRIPTION.md,sha256=yKP8_LNuxQKAyP-1xCtKVfaINNgbP6qbeixxQKjvPsA,260
|
|
16
|
+
odoo/addons/hr_appraisal_oca/readme/USAGE.md,sha256=nCrq3Av9jaTdW1jGCqaNdggNAATCrhMQLQtS3i8L5XA,4921
|
|
17
|
+
odoo/addons/hr_appraisal_oca/security/hr_appraisal_security.xml,sha256=YO7DqnQqwIF5_5GG-hyAMjN0097YTRAT7vopXAk5zQw,2356
|
|
18
|
+
odoo/addons/hr_appraisal_oca/security/ir.model.access.csv,sha256=1ZSYGPMvceCNqiEY3MZ6s2_SvbuUDuoKwc9LjPcCxB8,1127
|
|
19
|
+
odoo/addons/hr_appraisal_oca/static/description/banner.png,sha256=79JnvZusJn5gdi7q1pyW-clP6q0U8X2ecMGV-w-6FI0,6733
|
|
20
|
+
odoo/addons/hr_appraisal_oca/static/description/icon.png,sha256=Bdah6FNKjawYkFvsSzdVPbJGrVzinYk9yxbR0-1HPvg,7525
|
|
21
|
+
odoo/addons/hr_appraisal_oca/static/description/index.html,sha256=C7FAjuOwlRrmxhAhH2HCh4eLlTFFME5MS982DAoOLiY,18365
|
|
22
|
+
odoo/addons/hr_appraisal_oca/tests/__init__.py,sha256=uQpP_r9OVWSqSArfvKhORrMQTXnkQqzji4S7RPnqtAM,32
|
|
23
|
+
odoo/addons/hr_appraisal_oca/tests/test_hr_appraisal.py,sha256=uaaX6gugdFLvCn6Ca5WPWM8-mNbWeQUjwEcF8LnkDMM,4667
|
|
24
|
+
odoo/addons/hr_appraisal_oca/views/hr_appraisal_form_view.xml,sha256=5kLQgHd_3-TORNqD--djJZ9IF9_En39OwcYi7ErAMfg,26653
|
|
25
|
+
odoo/addons/hr_appraisal_oca/views/hr_appraisal_tag_form_view.xml,sha256=TZnvbBJ_4SLhsc6RATqMbJyltw7eYy3KWtlokhSQTU0,1730
|
|
26
|
+
odoo/addons/hr_appraisal_oca/views/hr_appraisal_template_form_view.xml,sha256=PTitwi_Gl2IPXheRaktoO4m9VZwDKfAkJGTJ8YifaA0,5265
|
|
27
|
+
odoo/addons/hr_appraisal_oca/views/hr_employee_form_view.xml,sha256=I6tJUEJK5ZyySQ8PAkXrdgcK3MNYWCYtDTNsGGeT0EU,1822
|
|
28
|
+
odoo/addons/hr_appraisal_oca/views/res_config_settings_views.xml,sha256=j5ccKs_-Tc-LhjlcdsSV8YLXb5JaSZ-fBTdxMMpMgnU,2587
|
|
29
|
+
odoo/addons/hr_appraisal_oca/wizard/__init__.py,sha256=F9bh4Q-6bgXNdNKnR1Se8LeGUf4ipGR4O-HhBFKbggs,79
|
|
30
|
+
odoo/addons/hr_appraisal_oca/wizard/hr_appraisal_request_wizard_view.xml,sha256=FMd55O7qQXP9tpNMqQ-9pZnlO7PKLr6OPBDNgGYvTNI,1715
|
|
31
|
+
odoo/addons/hr_appraisal_oca/wizard/hr_appraisal_wizard.py,sha256=fdIKHh3cAVTamf6MMH3ej8W-x1kp_p60LioZTapyL2M,6451
|
|
32
|
+
odoo/addons/hr_appraisal_oca/wizard/hr_appraisal_wizard_form_view.xml,sha256=OXvjEgknrnPcZrMbvR0-5VZm2kCeQa4iBS8vV5JjYoQ,1346
|
|
33
|
+
odoo/addons/hr_appraisal_oca/wizard/send_mail_with_template_wizard.py,sha256=E6Hc1vLxnRQ3V1A0FUCMfcjlwgz6CLvmZ1GicgC9TG8,1929
|
|
34
|
+
odoo_addon_hr_appraisal_oca-16.0.1.0.0.3.dist-info/METADATA,sha256=aVWx03Cr59NegD2CpxqnKi7Pbpd7-9A8apzpEaLa8wI,9051
|
|
35
|
+
odoo_addon_hr_appraisal_oca-16.0.1.0.0.3.dist-info/WHEEL,sha256=tZoeGjtWxWRfdplE7E3d45VPlLNQnvbKiYnx7gwAy8A,92
|
|
36
|
+
odoo_addon_hr_appraisal_oca-16.0.1.0.0.3.dist-info/top_level.txt,sha256=qBj40grFkGOfDZ2WDSw3y1RnDlgG0u8rP8pvGNdbz4w,5
|
|
37
|
+
odoo_addon_hr_appraisal_oca-16.0.1.0.0.3.dist-info/RECORD,,
|