From ef8d28c86d74db675af578a10870a407a623368d Mon Sep 17 00:00:00 2001
From: Alexey Pelykh
Date: Sun, 8 Mar 2020 10:14:11 +0100
Subject: [PATCH 01/24] [ADD] hr_contract_rate: flexible wage
---
hr_contract_rate/__init__.py | 4 +
hr_contract_rate/__manifest__.py | 24 ++++
hr_contract_rate/hooks.py | 28 ++++
hr_contract_rate/models/__init__.py | 3 +
hr_contract_rate/models/hr_contract.py | 127 +++++++++++++++++
hr_contract_rate/readme/CONTRIBUTORS.rst | 1 +
hr_contract_rate/readme/DESCRIPTION.rst | 12 ++
hr_contract_rate/readme/USAGE.rst | 6 +
hr_contract_rate/tests/__init__.py | 3 +
.../tests/test_hr_contract_rate.py | 133 ++++++++++++++++++
hr_contract_rate/views/hr_contract.xml | 36 +++++
11 files changed, 377 insertions(+)
create mode 100644 hr_contract_rate/__init__.py
create mode 100644 hr_contract_rate/__manifest__.py
create mode 100644 hr_contract_rate/hooks.py
create mode 100644 hr_contract_rate/models/__init__.py
create mode 100644 hr_contract_rate/models/hr_contract.py
create mode 100644 hr_contract_rate/readme/CONTRIBUTORS.rst
create mode 100644 hr_contract_rate/readme/DESCRIPTION.rst
create mode 100644 hr_contract_rate/readme/USAGE.rst
create mode 100644 hr_contract_rate/tests/__init__.py
create mode 100644 hr_contract_rate/tests/test_hr_contract_rate.py
create mode 100644 hr_contract_rate/views/hr_contract.xml
diff --git a/hr_contract_rate/__init__.py b/hr_contract_rate/__init__.py
new file mode 100644
index 00000000000..eae2840ab05
--- /dev/null
+++ b/hr_contract_rate/__init__.py
@@ -0,0 +1,4 @@
+# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl.html).
+
+from . import models
+from .hooks import pre_init_hook, post_init_hook
diff --git a/hr_contract_rate/__manifest__.py b/hr_contract_rate/__manifest__.py
new file mode 100644
index 00000000000..83a0fbe1c80
--- /dev/null
+++ b/hr_contract_rate/__manifest__.py
@@ -0,0 +1,24 @@
+# Copyright 2020 Brainbean Apps (https://brainbeanapps.com)
+# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl.html).
+
+{
+ 'name': 'HR Contract Rate',
+ 'version': '12.0.1.0.0',
+ 'category': 'Human Resources',
+ 'website': 'https://github.com/OCA/hr',
+ 'author':
+ 'Brainbean Apps, '
+ 'Odoo Community Association (OCA)',
+ 'license': 'AGPL-3',
+ 'installable': True,
+ 'application': False,
+ 'summary': 'Employee\'s contract rate and period',
+ 'pre_init_hook': 'pre_init_hook',
+ 'post_init_hook': 'post_init_hook',
+ 'depends': [
+ 'hr_contract',
+ ],
+ 'data': [
+ 'views/hr_contract.xml',
+ ],
+}
diff --git a/hr_contract_rate/hooks.py b/hr_contract_rate/hooks.py
new file mode 100644
index 00000000000..920e2d6be8a
--- /dev/null
+++ b/hr_contract_rate/hooks.py
@@ -0,0 +1,28 @@
+# Copyright 2020 Brainbean Apps (https://brainbeanapps.com)
+# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl.html).
+
+from odoo import api, SUPERUSER_ID
+
+
+def pre_init_hook(cr):
+ cr.execute("""
+ ALTER TABLE hr_contract
+ ADD amount numeric;
+ COMMENT
+ ON COLUMN hr_contract.amount
+ IS 'Amount';
+ ALTER TABLE hr_contract
+ ADD amount_period varchar;
+ COMMENT
+ ON COLUMN hr_contract.amount_period
+ IS 'Period of Amount';
+ UPDATE hr_contract
+ SET amount = wage, amount_period = 'month';
+ """)
+
+
+def post_init_hook(cr, registry):
+ env = api.Environment(cr, SUPERUSER_ID, {})
+ contracts = env['hr.contract'].search([])
+ contracts._inverse_wage()
+ contracts._compute_wage()
diff --git a/hr_contract_rate/models/__init__.py b/hr_contract_rate/models/__init__.py
new file mode 100644
index 00000000000..0824362dde5
--- /dev/null
+++ b/hr_contract_rate/models/__init__.py
@@ -0,0 +1,3 @@
+# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl.html).
+
+from . import hr_contract
diff --git a/hr_contract_rate/models/hr_contract.py b/hr_contract_rate/models/hr_contract.py
new file mode 100644
index 00000000000..d475f1b8217
--- /dev/null
+++ b/hr_contract_rate/models/hr_contract.py
@@ -0,0 +1,127 @@
+# Copyright 2020 Brainbean Apps (https://brainbeanapps.com)
+# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl.html).
+
+from odoo import api, fields, models
+
+
+class HrContract(models.Model):
+ _inherit = 'hr.contract'
+
+ wage = fields.Monetary(
+ compute='_compute_wage',
+ inverse='_inverse_wage',
+ store=True,
+ required=False,
+ track_visibility=None,
+ )
+ approximate_wage = fields.Monetary(
+ string='Wage (approximate)',
+ compute='_compute_wage',
+ store=True,
+ help='Employee\'s monthly gross wage (approximate)',
+ )
+ is_wage_accurate = fields.Boolean(
+ compute='_compute_wage',
+ store=True,
+ )
+ work_hours_per_month = fields.Float(
+ string='Work hours (per month)',
+ default=lambda self: self._default_work_hours_per_month(),
+ help='How many work hours there is in an average month',
+ )
+ work_days_per_month = fields.Float(
+ string='Work days (per month)',
+ default=lambda self: self._default_work_days_per_month(),
+ help='How many work days there is in an average month',
+ )
+ work_weeks_per_month = fields.Float(
+ string='Work weeks (per month)',
+ default=lambda self: self._default_work_weeks_per_month(),
+ help='How many work weeks there is in an average month',
+ )
+ amount = fields.Monetary(
+ string='Amount',
+ track_visibility='onchange',
+ help='Employee\'s contract amount per period',
+ )
+ amount_period = fields.Selection(
+ string='Period of Amount',
+ selection=[
+ ('hour', 'Hour'),
+ ('day', 'Day'),
+ ('week', 'Week'),
+ ('month', 'Month'),
+ ('quarter', 'Quarter'),
+ ('year', 'Year'),
+ ],
+ default='month',
+ track_visibility='onchange',
+ help='Period of employee\'s contract amount',
+ )
+
+ @api.model
+ def _default_work_hours_per_month(self):
+ """ Hook for extensions """
+ return 2080.0 / 12.0
+
+ @api.model
+ def _default_work_days_per_month(self):
+ """ Hook for extensions """
+ return self._default_work_hours_per_month() / 8.0
+
+ @api.model
+ def _default_work_weeks_per_month(self):
+ """ Hook for extensions """
+ return self._default_work_days_per_month() / 5.0
+
+ @api.multi
+ def _get_wage_from_amount(self):
+ """ Hook for extensions """
+ self.ensure_one()
+ if self.amount_period == 'hour':
+ is_wage_accurate = False
+ wage = self.amount * self.work_hours_per_month
+ elif self.amount_period == 'day':
+ is_wage_accurate = False
+ wage = self.amount * self.work_days_per_month
+ elif self.amount_period == 'week':
+ is_wage_accurate = False
+ wage = self.amount * self.work_weeks_per_month
+ elif self.amount_period == 'month':
+ is_wage_accurate = True
+ wage = self.amount
+ elif self.amount_period == 'quarter':
+ is_wage_accurate = True
+ wage = self.amount / 3.0
+ elif self.amount_period == 'year':
+ is_wage_accurate = True
+ wage = self.amount / 12.0
+ return wage, is_wage_accurate
+
+ @api.multi
+ @api.depends(
+ 'amount',
+ 'amount_period',
+ 'work_hours_per_month',
+ 'work_days_per_month',
+ 'work_weeks_per_month',
+ )
+ def _compute_wage(self):
+ for contract in self:
+ wage, is_wage_accurate = contract._get_wage_from_amount()
+ contract.is_wage_accurate = is_wage_accurate
+ contract.approximate_wage = 0 if is_wage_accurate else wage
+ contract.wage = wage if is_wage_accurate else 0
+
+ @api.multi
+ def _inverse_wage(self):
+ if self.env.context.get('hr_contract_inverse_wage_skip'):
+ return
+
+ # NOTE: In order to maintain compatibility with other tests also
+ # support setting monthly amount by setting wage directly.
+ for contract in self:
+ if contract.amount != contract.wage:
+ contract.amount = contract.wage
+ if contract.amount_period != 'month':
+ contract.amount_period = 'month'
diff --git a/hr_contract_rate/readme/CONTRIBUTORS.rst b/hr_contract_rate/readme/CONTRIBUTORS.rst
new file mode 100644
index 00000000000..1c6a35a1e35
--- /dev/null
+++ b/hr_contract_rate/readme/CONTRIBUTORS.rst
@@ -0,0 +1 @@
+* Alexey Pelykh
diff --git a/hr_contract_rate/readme/DESCRIPTION.rst b/hr_contract_rate/readme/DESCRIPTION.rst
new file mode 100644
index 00000000000..5600a0ba5c6
--- /dev/null
+++ b/hr_contract_rate/readme/DESCRIPTION.rst
@@ -0,0 +1,12 @@
+This module allows to specify a contractual rate of Employee using various
+time periods:
+
+* Hour
+* Day
+* Week
+* Month
+* Quarter
+* Year
+
+It's possible to specify number of hours/days/weeks per month for wage
+calculation for the contract.
diff --git a/hr_contract_rate/readme/USAGE.rst b/hr_contract_rate/readme/USAGE.rst
new file mode 100644
index 00000000000..f9f55492994
--- /dev/null
+++ b/hr_contract_rate/readme/USAGE.rst
@@ -0,0 +1,6 @@
+Since hourly, daily, and weekly rates are not tranformable to monthly wage with
+precision, ``wage`` is being set to zero in these cases. An extra ``approximate_wage``
+field is added to store approximately computed average monthly wage. It's also
+important to review payroll calculation rules.
+
+This module is based on different approach than ``hr_contract_hourly_rate`` use.
diff --git a/hr_contract_rate/tests/__init__.py b/hr_contract_rate/tests/__init__.py
new file mode 100644
index 00000000000..ae09e46231f
--- /dev/null
+++ b/hr_contract_rate/tests/__init__.py
@@ -0,0 +1,3 @@
+# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl.html).
+
+from . import test_hr_contract_rate
diff --git a/hr_contract_rate/tests/test_hr_contract_rate.py b/hr_contract_rate/tests/test_hr_contract_rate.py
new file mode 100644
index 00000000000..905e9432892
--- /dev/null
+++ b/hr_contract_rate/tests/test_hr_contract_rate.py
@@ -0,0 +1,133 @@
+# Copyright 2020 Brainbean Apps (https://brainbeanapps.com)
+# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl.html).
+
+from odoo import fields
+from odoo.tests import common
+
+
+class TestHrContractRate(common.TransactionCase):
+
+ def setUp(self):
+ super().setUp()
+
+ self.today = fields.Date.today()
+ self.now = fields.Datetime.now()
+ self.HrEmployee = self.env['hr.employee']
+ self.HrContract = self.env['hr.contract']
+
+ def test_compatibility(self):
+ employee = self.HrEmployee.create({
+ 'name': 'Employee',
+ })
+ contract = self.HrContract.create({
+ 'name': 'Contract',
+ 'employee_id': employee.id,
+ 'date_start': self.today,
+ 'date_end': self.today,
+ 'wage': 5000.0,
+ })
+
+ self.assertEqual(contract.amount, 5000.0)
+ self.assertEqual(contract.amount_period, 'month')
+
+ def test_hourly(self):
+ employee = self.HrEmployee.create({
+ 'name': 'Employee',
+ })
+ contract = self.HrContract.create({
+ 'name': 'Contract',
+ 'employee_id': employee.id,
+ 'date_start': self.today,
+ 'date_end': self.today,
+ 'amount': 50.0,
+ 'amount_period': 'hour',
+ })
+
+ self.assertEqual(contract.wage, 0.0)
+ self.assertEqual(contract.approximate_wage, 8666.67)
+ self.assertFalse(contract.is_wage_accurate)
+
+ def test_daily(self):
+ employee = self.HrEmployee.create({
+ 'name': 'Employee',
+ })
+ contract = self.HrContract.create({
+ 'name': 'Contract',
+ 'employee_id': employee.id,
+ 'date_start': self.today,
+ 'date_end': self.today,
+ 'amount': 400.0,
+ 'amount_period': 'day',
+ })
+
+ self.assertEqual(contract.wage, 0.0)
+ self.assertEqual(contract.approximate_wage, 8666.67)
+ self.assertFalse(contract.is_wage_accurate)
+
+ def test_weekly(self):
+ employee = self.HrEmployee.create({
+ 'name': 'Employee',
+ })
+ contract = self.HrContract.create({
+ 'name': 'Contract',
+ 'employee_id': employee.id,
+ 'date_start': self.today,
+ 'date_end': self.today,
+ 'amount': 2000.0,
+ 'amount_period': 'week',
+ })
+
+ self.assertEqual(contract.wage, 0.0)
+ self.assertEqual(contract.approximate_wage, 8666.67)
+ self.assertFalse(contract.is_wage_accurate)
+
+ def test_monthly(self):
+ employee = self.HrEmployee.create({
+ 'name': 'Employee',
+ })
+ contract = self.HrContract.create({
+ 'name': 'Contract',
+ 'employee_id': employee.id,
+ 'date_start': self.today,
+ 'date_end': self.today,
+ 'amount': 5000.0,
+ 'amount_period': 'month',
+ })
+
+ self.assertEqual(contract.wage, 5000.0)
+ self.assertEqual(contract.approximate_wage, 0.0)
+ self.assertTrue(contract.is_wage_accurate)
+
+ def test_quarterly(self):
+ employee = self.HrEmployee.create({
+ 'name': 'Employee',
+ })
+ contract = self.HrContract.create({
+ 'name': 'Contract',
+ 'employee_id': employee.id,
+ 'date_start': self.today,
+ 'date_end': self.today,
+ 'amount': 15000.0,
+ 'amount_period': 'quarter',
+ })
+
+ self.assertEqual(contract.wage, 5000.0)
+ self.assertEqual(contract.approximate_wage, 0.0)
+ self.assertTrue(contract.is_wage_accurate)
+
+ def test_annual(self):
+ employee = self.HrEmployee.create({
+ 'name': 'Employee',
+ })
+ contract = self.HrContract.create({
+ 'name': 'Contract',
+ 'employee_id': employee.id,
+ 'date_start': self.today,
+ 'date_end': self.today,
+ 'amount': 60000.0,
+ 'amount_period': 'year',
+ })
+
+ self.assertEqual(contract.wage, 5000.0)
+ self.assertEqual(contract.approximate_wage, 0.0)
+ self.assertTrue(contract.is_wage_accurate)
diff --git a/hr_contract_rate/views/hr_contract.xml b/hr_contract_rate/views/hr_contract.xml
new file mode 100644
index 00000000000..b197476ea3a
--- /dev/null
+++ b/hr_contract_rate/views/hr_contract.xml
@@ -0,0 +1,36 @@
+
+
+
+
+
+ hr.contract.view.form
+ hr.contract
+
+
+
+ Salary and Advantages
+
+
+ Amount
+
+
+ 1
+ 1
+
+
+
+
+
+ 1
+
+
+ /
+
+
+
+
+
+
From 90379dcc27d77946ffb7b4141bae57f075b8913f Mon Sep 17 00:00:00 2001
From: oca-travis
Date: Thu, 19 Mar 2020 14:54:01 +0000
Subject: [PATCH 02/24] [UPD] hr_contract_rate: .pot, readme, icon
---
hr_contract_rate/README.rst | 94 ++++
hr_contract_rate/i18n/hr_contract_rate.pot | 131 ++++++
hr_contract_rate/static/description/icon.png | Bin 0 -> 9455 bytes
.../static/description/index.html | 442 ++++++++++++++++++
4 files changed, 667 insertions(+)
create mode 100644 hr_contract_rate/README.rst
create mode 100644 hr_contract_rate/i18n/hr_contract_rate.pot
create mode 100644 hr_contract_rate/static/description/icon.png
create mode 100644 hr_contract_rate/static/description/index.html
diff --git a/hr_contract_rate/README.rst b/hr_contract_rate/README.rst
new file mode 100644
index 00000000000..9d0d8756f4c
--- /dev/null
+++ b/hr_contract_rate/README.rst
@@ -0,0 +1,94 @@
+================
+HR Contract Rate
+================
+
+.. !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
+ !! This file is generated by oca-gen-addon-readme !!
+ !! changes will be overwritten. !!
+ !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
+
+.. |badge1| image:: https://img.shields.io/badge/maturity-Beta-yellow.png
+ :target: https://odoo-community.org/page/development-status
+ :alt: Beta
+.. |badge2| image:: https://img.shields.io/badge/licence-AGPL--3-blue.png
+ :target: http://www.gnu.org/licenses/agpl-3.0-standalone.html
+ :alt: License: AGPL-3
+.. |badge3| image:: https://img.shields.io/badge/github-OCA%2Fhr-lightgray.png?logo=github
+ :target: https://github.com/OCA/hr/tree/12.0/hr_contract_rate
+ :alt: OCA/hr
+.. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png
+ :target: https://translation.odoo-community.org/projects/hr-12-0/hr-12-0-hr_contract_rate
+ :alt: Translate me on Weblate
+.. |badge5| image:: https://img.shields.io/badge/runbot-Try%20me-875A7B.png
+ :target: https://runbot.odoo-community.org/runbot/116/12.0
+ :alt: Try me on Runbot
+
+|badge1| |badge2| |badge3| |badge4| |badge5|
+
+This module allows to specify a contractual rate of Employee using various
+time periods:
+
+* Hour
+* Day
+* Week
+* Month
+* Quarter
+* Year
+
+It's possible to specify number of hours/days/weeks per month for wage
+calculation for the contract.
+
+**Table of contents**
+
+.. contents::
+ :local:
+
+Usage
+=====
+
+Since hourly, daily, and weekly rates are not tranformable to monthly wage with
+precision, ``wage`` is being set to zero in these cases. An extra ``approximate_wage``
+field is added to store approximately computed average monthly wage. It's also
+important to review payroll calculation rules.
+
+This module is based on different approach than ``hr_contract_hourly_rate`` use.
+
+Bug Tracker
+===========
+
+Bugs are tracked on `GitHub Issues `_.
+In case of trouble, please check there if your issue has already been reported.
+If you spotted it first, help us smashing it by providing a detailed and welcomed
+`feedback `_.
+
+Do not contact contributors directly about support or help with technical issues.
+
+Credits
+=======
+
+Authors
+~~~~~~~
+
+* Brainbean Apps
+
+Contributors
+~~~~~~~~~~~~
+
+* Alexey Pelykh
+
+Maintainers
+~~~~~~~~~~~
+
+This module is maintained by the OCA.
+
+.. image:: https://odoo-community.org/logo.png
+ :alt: Odoo Community Association
+ :target: https://odoo-community.org
+
+OCA, or the Odoo Community Association, is a nonprofit organization whose
+mission is to support the collaborative development of Odoo features and
+promote its widespread use.
+
+This module is part of the `OCA/hr `_ project on GitHub.
+
+You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute.
diff --git a/hr_contract_rate/i18n/hr_contract_rate.pot b/hr_contract_rate/i18n/hr_contract_rate.pot
new file mode 100644
index 00000000000..00a85da0c34
--- /dev/null
+++ b/hr_contract_rate/i18n/hr_contract_rate.pot
@@ -0,0 +1,131 @@
+# Translation of Odoo Server.
+# This file contains the translation of the following modules:
+# * hr_contract_rate
+#
+msgid ""
+msgstr ""
+"Project-Id-Version: Odoo Server 12.0\n"
+"Report-Msgid-Bugs-To: \n"
+"Last-Translator: <>\n"
+"Language-Team: \n"
+"MIME-Version: 1.0\n"
+"Content-Type: text/plain; charset=UTF-8\n"
+"Content-Transfer-Encoding: \n"
+"Plural-Forms: \n"
+
+#. module: hr_contract_rate
+#: model:ir.model.fields,field_description:hr_contract_rate.field_hr_contract__amount
+#: model_terms:ir.ui.view,arch_db:hr_contract_rate.hr_contract_view_form
+msgid "Amount"
+msgstr ""
+
+#. module: hr_contract_rate
+#: selection:hr.contract,amount_period:0
+msgid "Day"
+msgstr ""
+
+#. module: hr_contract_rate
+#: model:ir.model,name:hr_contract_rate.model_hr_contract
+msgid "Employee Contract"
+msgstr ""
+
+#. module: hr_contract_rate
+#: model:ir.model.fields,help:hr_contract_rate.field_hr_contract__amount
+msgid "Employee's contract amount per period"
+msgstr ""
+
+#. module: hr_contract_rate
+#: model:ir.model.fields,help:hr_contract_rate.field_hr_contract__approximate_wage
+msgid "Employee's monthly gross wage (approximate)"
+msgstr ""
+
+#. module: hr_contract_rate
+#: model:ir.model.fields,help:hr_contract_rate.field_hr_contract__wage
+msgid "Employee's monthly gross wage."
+msgstr ""
+
+#. module: hr_contract_rate
+#: selection:hr.contract,amount_period:0
+msgid "Hour"
+msgstr ""
+
+#. module: hr_contract_rate
+#: model:ir.model.fields,help:hr_contract_rate.field_hr_contract__work_days_per_month
+msgid "How many work days there is in an average month"
+msgstr ""
+
+#. module: hr_contract_rate
+#: model:ir.model.fields,help:hr_contract_rate.field_hr_contract__work_hours_per_month
+msgid "How many work hours there is in an average month"
+msgstr ""
+
+#. module: hr_contract_rate
+#: model:ir.model.fields,help:hr_contract_rate.field_hr_contract__work_weeks_per_month
+msgid "How many work weeks there is in an average month"
+msgstr ""
+
+#. module: hr_contract_rate
+#: model:ir.model.fields,field_description:hr_contract_rate.field_hr_contract__is_wage_accurate
+msgid "Is Wage Accurate"
+msgstr ""
+
+#. module: hr_contract_rate
+#: selection:hr.contract,amount_period:0
+msgid "Month"
+msgstr ""
+
+#. module: hr_contract_rate
+#: model:ir.model.fields,field_description:hr_contract_rate.field_hr_contract__amount_period
+msgid "Period of Amount"
+msgstr ""
+
+#. module: hr_contract_rate
+#: model:ir.model.fields,help:hr_contract_rate.field_hr_contract__amount_period
+msgid "Period of employee's contract amount"
+msgstr ""
+
+#. module: hr_contract_rate
+#: selection:hr.contract,amount_period:0
+msgid "Quarter"
+msgstr ""
+
+#. module: hr_contract_rate
+#: model_terms:ir.ui.view,arch_db:hr_contract_rate.hr_contract_view_form
+msgid "Salary and Advantages"
+msgstr ""
+
+#. module: hr_contract_rate
+#: model:ir.model.fields,field_description:hr_contract_rate.field_hr_contract__wage
+msgid "Wage"
+msgstr ""
+
+#. module: hr_contract_rate
+#: model:ir.model.fields,field_description:hr_contract_rate.field_hr_contract__approximate_wage
+msgid "Wage (approximate)"
+msgstr ""
+
+#. module: hr_contract_rate
+#: selection:hr.contract,amount_period:0
+msgid "Week"
+msgstr ""
+
+#. module: hr_contract_rate
+#: model:ir.model.fields,field_description:hr_contract_rate.field_hr_contract__work_days_per_month
+msgid "Work days (per month)"
+msgstr ""
+
+#. module: hr_contract_rate
+#: model:ir.model.fields,field_description:hr_contract_rate.field_hr_contract__work_hours_per_month
+msgid "Work hours (per month)"
+msgstr ""
+
+#. module: hr_contract_rate
+#: model:ir.model.fields,field_description:hr_contract_rate.field_hr_contract__work_weeks_per_month
+msgid "Work weeks (per month)"
+msgstr ""
+
+#. module: hr_contract_rate
+#: selection:hr.contract,amount_period:0
+msgid "Year"
+msgstr ""
+
diff --git a/hr_contract_rate/static/description/icon.png b/hr_contract_rate/static/description/icon.png
new file mode 100644
index 0000000000000000000000000000000000000000..3a0328b516c4980e8e44cdb63fd945757ddd132d
GIT binary patch
literal 9455
zcmW++2RxMjAAjx~&dlBk9S+%}OXg)AGE&Cb*&}d0jUxM@u(PQx^-s)697TX`ehR4?GS^qbkof1cslKgkU)h65qZ9Oc=ml_0temigYLJfnz{IDzUf>bGs4N!v3=Z3jMq&A#7%rM5eQ#dc?k~!
zVpnB`o+K7|Al`Q_U;eD$B
zfJtP*jH`siUq~{KE)`jP2|#TUEFGRryE2`i0**z#*^6~AI|YzIWy$Cu#CSLW3q=GA
z6`?GZymC;dCPk~rBS%eCb`5OLr;RUZ;D`}um=H)BfVIq%7VhiMr)_#G0N#zrNH|__
zc+blN2UAB0=617@>_u;MPHN;P;N#YoE=)R#i$k_`UAA>WWCcEVMh~L_
zj--gtp&|K1#58Yz*AHCTMziU1Jzt_jG0I@qAOHsk$2}yTmVkBp_eHuY$A9)>P6o~I
z%aQ?!(GqeQ-Y+b0I(m9pwgi(IIZZzsbMv+9w{PFtd_<_(LA~0H(xz{=FhLB@(1&qHA5EJw1>>=%q2f&^X>IQ{!GJ4e9U
z&KlB)z(84HmNgm2hg2C0>WM{E(DdPr+EeU_N@57;PC2&DmGFW_9kP&%?X4}+xWi)(
z;)z%wI5>D4a*5XwD)P--sPkoY(a~WBw;E~AW`Yue4kFa^LM3X`8x|}ZUeMnqr}>kH
zG%WWW>3ml$Yez?i%)2pbKPI7?5o?hydokgQyZsNEr{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`}-m4(0F>%@P|?7fx{=R^uFdISRnZ2W_xQhD{YuR3t<
z{6yxu=4~JkeA;|(J6_nv#>Nvs&FuLA&PW^he@t(UwFFE8)|a!R{`E`K`i^ZnyE4$k
z;(749Ix|oi$c3QbEJ3b~D_kQsPz~fIUKym($a_7dJ?o+40*OLl^{=&oq$<#Q(yyrp
z{J-FAniyAw9tPbe&IhQ|a`DqFTVQGQ&Gq3!C2==4x{6EJwiPZ8zub-iXoUtkJiG{}
zPaR&}_fn8_z~(=;5lD-aPWD3z8PZS@AaUiomF!G8I}Mf>e~0g#BelA-5#`cj;O5>N
Xviia!U7SGha1wx#SCgwmn*{w2TRX*I
literal 0
HcmV?d00001
diff --git a/hr_contract_rate/static/description/index.html b/hr_contract_rate/static/description/index.html
new file mode 100644
index 00000000000..b1cca2afadc
--- /dev/null
+++ b/hr_contract_rate/static/description/index.html
@@ -0,0 +1,442 @@
+
+
+
+
+
+
+HR Contract Rate
+
+
+
+
+
HR Contract Rate
+
+
+
+
This module allows to specify a contractual rate of Employee using various
+time periods:
+
+Hour
+Day
+Week
+Month
+Quarter
+Year
+
+
It’s possible to specify number of hours/days/weeks per month for wage
+calculation for the contract.
+
Table of contents
+
+
+
+
Since hourly, daily, and weekly rates are not tranformable to monthly wage with
+precision, wage is being set to zero in these cases. An extra approximate_wage
+field is added to store approximately computed average monthly wage. It’s also
+important to review payroll calculation rules.
+
This module is based on different approach than hr_contract_hourly_rate use.
+
+
+
+
Bugs are tracked on GitHub Issues .
+In case of trouble, please check there if your issue has already been reported.
+If you spotted it first, help us smashing it by providing a detailed and welcomed
+feedback .
+
Do not contact contributors directly about support or help with technical issues.
+
+
+
+
+
+
+
+
This module is maintained by the OCA.
+
+
OCA, or the Odoo Community Association, is a nonprofit organization whose
+mission is to support the collaborative development of Odoo features and
+promote its widespread use.
+
This module is part of the OCA/hr project on GitHub.
+
You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute .
+
+
+
+
+
From 5f7babf404d38259cd433a366d04398547b97e3d Mon Sep 17 00:00:00 2001
From: Alexey Pelykh
Date: Wed, 4 Nov 2020 12:47:36 +0200
Subject: [PATCH 03/24] [UPD] Brainbean Apps => CorporateHub
---
hr_contract_rate/README.rst | 8 +++++---
hr_contract_rate/__manifest__.py | 3 ++-
hr_contract_rate/readme/CONTRIBUTORS.rst | 4 +++-
3 files changed, 10 insertions(+), 5 deletions(-)
diff --git a/hr_contract_rate/README.rst b/hr_contract_rate/README.rst
index 9d0d8756f4c..35990b45ddb 100644
--- a/hr_contract_rate/README.rst
+++ b/hr_contract_rate/README.rst
@@ -23,7 +23,7 @@ HR Contract Rate
:target: https://runbot.odoo-community.org/runbot/116/12.0
:alt: Try me on Runbot
-|badge1| |badge2| |badge3| |badge4| |badge5|
+|badge1| |badge2| |badge3| |badge4| |badge5|
This module allows to specify a contractual rate of Employee using various
time periods:
@@ -69,12 +69,14 @@ Credits
Authors
~~~~~~~
-* Brainbean Apps
+* CorporateHub
Contributors
~~~~~~~~~~~~
-* Alexey Pelykh
+* `CorporateHub `__
+
+ * Alexey Pelykh
Maintainers
~~~~~~~~~~~
diff --git a/hr_contract_rate/__manifest__.py b/hr_contract_rate/__manifest__.py
index 83a0fbe1c80..e1dbb66e5a5 100644
--- a/hr_contract_rate/__manifest__.py
+++ b/hr_contract_rate/__manifest__.py
@@ -1,4 +1,5 @@
# Copyright 2020 Brainbean Apps (https://brainbeanapps.com)
+# Copyright 2020 CorporateHub (https://corporatehub.eu)
# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl.html).
{
@@ -7,7 +8,7 @@
'category': 'Human Resources',
'website': 'https://github.com/OCA/hr',
'author':
- 'Brainbean Apps, '
+ 'CorporateHub, '
'Odoo Community Association (OCA)',
'license': 'AGPL-3',
'installable': True,
diff --git a/hr_contract_rate/readme/CONTRIBUTORS.rst b/hr_contract_rate/readme/CONTRIBUTORS.rst
index 1c6a35a1e35..724bc1d03a2 100644
--- a/hr_contract_rate/readme/CONTRIBUTORS.rst
+++ b/hr_contract_rate/readme/CONTRIBUTORS.rst
@@ -1 +1,3 @@
-* Alexey Pelykh
+* `CorporateHub `__
+
+ * Alexey Pelykh
From 25ab44b55639f47b75be677092c31e6c3a8d13d2 Mon Sep 17 00:00:00 2001
From: nans
Date: Tue, 5 Jan 2021 11:17:13 +0100
Subject: [PATCH 04/24] [REF] hr_contract_rate: Black python code
---
hr_contract_rate/__manifest__.py | 32 ++--
hr_contract_rate/hooks.py | 10 +-
hr_contract_rate/models/hr_contract.py | 83 +++++----
.../tests/test_hr_contract_rate.py | 159 +++++++++---------
hr_contract_rate/views/hr_contract.xml | 8 +-
5 files changed, 141 insertions(+), 151 deletions(-)
diff --git a/hr_contract_rate/__manifest__.py b/hr_contract_rate/__manifest__.py
index e1dbb66e5a5..9a3c5fac8fc 100644
--- a/hr_contract_rate/__manifest__.py
+++ b/hr_contract_rate/__manifest__.py
@@ -3,23 +3,17 @@
# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl.html).
{
- 'name': 'HR Contract Rate',
- 'version': '12.0.1.0.0',
- 'category': 'Human Resources',
- 'website': 'https://github.com/OCA/hr',
- 'author':
- 'CorporateHub, '
- 'Odoo Community Association (OCA)',
- 'license': 'AGPL-3',
- 'installable': True,
- 'application': False,
- 'summary': 'Employee\'s contract rate and period',
- 'pre_init_hook': 'pre_init_hook',
- 'post_init_hook': 'post_init_hook',
- 'depends': [
- 'hr_contract',
- ],
- 'data': [
- 'views/hr_contract.xml',
- ],
+ "name": "HR Contract Rate",
+ "version": "12.0.1.0.0",
+ "category": "Human Resources",
+ "website": "https://github.com/OCA/hr",
+ "author": "CorporateHub, " "Odoo Community Association (OCA)",
+ "license": "AGPL-3",
+ "installable": True,
+ "application": False,
+ "summary": "Employee's contract rate and period",
+ "pre_init_hook": "pre_init_hook",
+ "post_init_hook": "post_init_hook",
+ "depends": ["hr_contract"],
+ "data": ["views/hr_contract.xml"],
}
diff --git a/hr_contract_rate/hooks.py b/hr_contract_rate/hooks.py
index 920e2d6be8a..40953c115d2 100644
--- a/hr_contract_rate/hooks.py
+++ b/hr_contract_rate/hooks.py
@@ -1,11 +1,12 @@
# Copyright 2020 Brainbean Apps (https://brainbeanapps.com)
# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl.html).
-from odoo import api, SUPERUSER_ID
+from odoo import SUPERUSER_ID, api
def pre_init_hook(cr):
- cr.execute("""
+ cr.execute(
+ """
ALTER TABLE hr_contract
ADD amount numeric;
COMMENT
@@ -18,11 +19,12 @@ def pre_init_hook(cr):
IS 'Period of Amount';
UPDATE hr_contract
SET amount = wage, amount_period = 'month';
- """)
+ """
+ )
def post_init_hook(cr, registry):
env = api.Environment(cr, SUPERUSER_ID, {})
- contracts = env['hr.contract'].search([])
+ contracts = env["hr.contract"].search([])
contracts._inverse_wage()
contracts._compute_wage()
diff --git a/hr_contract_rate/models/hr_contract.py b/hr_contract_rate/models/hr_contract.py
index d475f1b8217..e4099708546 100644
--- a/hr_contract_rate/models/hr_contract.py
+++ b/hr_contract_rate/models/hr_contract.py
@@ -5,58 +5,55 @@
class HrContract(models.Model):
- _inherit = 'hr.contract'
+ _inherit = "hr.contract"
wage = fields.Monetary(
- compute='_compute_wage',
- inverse='_inverse_wage',
+ compute="_compute_wage",
+ inverse="_inverse_wage",
store=True,
required=False,
track_visibility=None,
)
approximate_wage = fields.Monetary(
- string='Wage (approximate)',
- compute='_compute_wage',
- store=True,
- help='Employee\'s monthly gross wage (approximate)',
- )
- is_wage_accurate = fields.Boolean(
- compute='_compute_wage',
+ string="Wage (approximate)",
+ compute="_compute_wage",
store=True,
+ help="Employee's monthly gross wage (approximate)",
)
+ is_wage_accurate = fields.Boolean(compute="_compute_wage", store=True,)
work_hours_per_month = fields.Float(
- string='Work hours (per month)',
+ string="Work hours (per month)",
default=lambda self: self._default_work_hours_per_month(),
- help='How many work hours there is in an average month',
+ help="How many work hours there is in an average month",
)
work_days_per_month = fields.Float(
- string='Work days (per month)',
+ string="Work days (per month)",
default=lambda self: self._default_work_days_per_month(),
- help='How many work days there is in an average month',
+ help="How many work days there is in an average month",
)
work_weeks_per_month = fields.Float(
- string='Work weeks (per month)',
+ string="Work weeks (per month)",
default=lambda self: self._default_work_weeks_per_month(),
- help='How many work weeks there is in an average month',
+ help="How many work weeks there is in an average month",
)
amount = fields.Monetary(
- string='Amount',
- track_visibility='onchange',
- help='Employee\'s contract amount per period',
+ string="Amount",
+ track_visibility="onchange",
+ help="Employee's contract amount per period",
)
amount_period = fields.Selection(
- string='Period of Amount',
+ string="Period of Amount",
selection=[
- ('hour', 'Hour'),
- ('day', 'Day'),
- ('week', 'Week'),
- ('month', 'Month'),
- ('quarter', 'Quarter'),
- ('year', 'Year'),
+ ("hour", "Hour"),
+ ("day", "Day"),
+ ("week", "Week"),
+ ("month", "Month"),
+ ("quarter", "Quarter"),
+ ("year", "Year"),
],
- default='month',
- track_visibility='onchange',
- help='Period of employee\'s contract amount',
+ default="month",
+ track_visibility="onchange",
+ help="Period of employee's contract amount",
)
@api.model
@@ -78,33 +75,33 @@ def _default_work_weeks_per_month(self):
def _get_wage_from_amount(self):
""" Hook for extensions """
self.ensure_one()
- if self.amount_period == 'hour':
+ if self.amount_period == "hour":
is_wage_accurate = False
wage = self.amount * self.work_hours_per_month
- elif self.amount_period == 'day':
+ elif self.amount_period == "day":
is_wage_accurate = False
wage = self.amount * self.work_days_per_month
- elif self.amount_period == 'week':
+ elif self.amount_period == "week":
is_wage_accurate = False
wage = self.amount * self.work_weeks_per_month
- elif self.amount_period == 'month':
+ elif self.amount_period == "month":
is_wage_accurate = True
wage = self.amount
- elif self.amount_period == 'quarter':
+ elif self.amount_period == "quarter":
is_wage_accurate = True
wage = self.amount / 3.0
- elif self.amount_period == 'year':
+ elif self.amount_period == "year":
is_wage_accurate = True
wage = self.amount / 12.0
return wage, is_wage_accurate
@api.multi
@api.depends(
- 'amount',
- 'amount_period',
- 'work_hours_per_month',
- 'work_days_per_month',
- 'work_weeks_per_month',
+ "amount",
+ "amount_period",
+ "work_hours_per_month",
+ "work_days_per_month",
+ "work_weeks_per_month",
)
def _compute_wage(self):
for contract in self:
@@ -115,7 +112,7 @@ def _compute_wage(self):
@api.multi
def _inverse_wage(self):
- if self.env.context.get('hr_contract_inverse_wage_skip'):
+ if self.env.context.get("hr_contract_inverse_wage_skip"):
return
# NOTE: In order to maintain compatibility with other tests also
@@ -123,5 +120,5 @@ def _inverse_wage(self):
for contract in self:
if contract.amount != contract.wage:
contract.amount = contract.wage
- if contract.amount_period != 'month':
- contract.amount_period = 'month'
+ if contract.amount_period != "month":
+ contract.amount_period = "month"
diff --git a/hr_contract_rate/tests/test_hr_contract_rate.py b/hr_contract_rate/tests/test_hr_contract_rate.py
index 905e9432892..bbc9fd3f367 100644
--- a/hr_contract_rate/tests/test_hr_contract_rate.py
+++ b/hr_contract_rate/tests/test_hr_contract_rate.py
@@ -6,127 +6,126 @@
class TestHrContractRate(common.TransactionCase):
-
def setUp(self):
super().setUp()
self.today = fields.Date.today()
self.now = fields.Datetime.now()
- self.HrEmployee = self.env['hr.employee']
- self.HrContract = self.env['hr.contract']
+ self.HrEmployee = self.env["hr.employee"]
+ self.HrContract = self.env["hr.contract"]
def test_compatibility(self):
- employee = self.HrEmployee.create({
- 'name': 'Employee',
- })
- contract = self.HrContract.create({
- 'name': 'Contract',
- 'employee_id': employee.id,
- 'date_start': self.today,
- 'date_end': self.today,
- 'wage': 5000.0,
- })
+ employee = self.HrEmployee.create({"name": "Employee"})
+ contract = self.HrContract.create(
+ {
+ "name": "Contract",
+ "employee_id": employee.id,
+ "date_start": self.today,
+ "date_end": self.today,
+ "wage": 5000.0,
+ }
+ )
self.assertEqual(contract.amount, 5000.0)
- self.assertEqual(contract.amount_period, 'month')
+ self.assertEqual(contract.amount_period, "month")
def test_hourly(self):
- employee = self.HrEmployee.create({
- 'name': 'Employee',
- })
- contract = self.HrContract.create({
- 'name': 'Contract',
- 'employee_id': employee.id,
- 'date_start': self.today,
- 'date_end': self.today,
- 'amount': 50.0,
- 'amount_period': 'hour',
- })
+ employee = self.HrEmployee.create({"name": "Employee"})
+ contract = self.HrContract.create(
+ {
+ "name": "Contract",
+ "employee_id": employee.id,
+ "date_start": self.today,
+ "date_end": self.today,
+ "amount": 50.0,
+ "amount_period": "hour",
+ }
+ )
self.assertEqual(contract.wage, 0.0)
self.assertEqual(contract.approximate_wage, 8666.67)
self.assertFalse(contract.is_wage_accurate)
def test_daily(self):
- employee = self.HrEmployee.create({
- 'name': 'Employee',
- })
- contract = self.HrContract.create({
- 'name': 'Contract',
- 'employee_id': employee.id,
- 'date_start': self.today,
- 'date_end': self.today,
- 'amount': 400.0,
- 'amount_period': 'day',
- })
+ employee = self.HrEmployee.create({"name": "Employee"})
+ contract = self.HrContract.create(
+ {
+ "name": "Contract",
+ "employee_id": employee.id,
+ "date_start": self.today,
+ "date_end": self.today,
+ "amount": 400.0,
+ "amount_period": "day",
+ }
+ )
self.assertEqual(contract.wage, 0.0)
self.assertEqual(contract.approximate_wage, 8666.67)
self.assertFalse(contract.is_wage_accurate)
def test_weekly(self):
- employee = self.HrEmployee.create({
- 'name': 'Employee',
- })
- contract = self.HrContract.create({
- 'name': 'Contract',
- 'employee_id': employee.id,
- 'date_start': self.today,
- 'date_end': self.today,
- 'amount': 2000.0,
- 'amount_period': 'week',
- })
+ employee = self.HrEmployee.create({"name": "Employee"})
+ contract = self.HrContract.create(
+ {
+ "name": "Contract",
+ "employee_id": employee.id,
+ "date_start": self.today,
+ "date_end": self.today,
+ "amount": 2000.0,
+ "amount_period": "week",
+ }
+ )
self.assertEqual(contract.wage, 0.0)
self.assertEqual(contract.approximate_wage, 8666.67)
self.assertFalse(contract.is_wage_accurate)
def test_monthly(self):
- employee = self.HrEmployee.create({
- 'name': 'Employee',
- })
- contract = self.HrContract.create({
- 'name': 'Contract',
- 'employee_id': employee.id,
- 'date_start': self.today,
- 'date_end': self.today,
- 'amount': 5000.0,
- 'amount_period': 'month',
- })
+ employee = self.HrEmployee.create({"name": "Employee"})
+ contract = self.HrContract.create(
+ {
+ "name": "Contract",
+ "employee_id": employee.id,
+ "date_start": self.today,
+ "date_end": self.today,
+ "amount": 5000.0,
+ "amount_period": "month",
+ }
+ )
self.assertEqual(contract.wage, 5000.0)
self.assertEqual(contract.approximate_wage, 0.0)
self.assertTrue(contract.is_wage_accurate)
def test_quarterly(self):
- employee = self.HrEmployee.create({
- 'name': 'Employee',
- })
- contract = self.HrContract.create({
- 'name': 'Contract',
- 'employee_id': employee.id,
- 'date_start': self.today,
- 'date_end': self.today,
- 'amount': 15000.0,
- 'amount_period': 'quarter',
- })
+ employee = self.HrEmployee.create({"name": "Employee"})
+ contract = self.HrContract.create(
+ {
+ "name": "Contract",
+ "employee_id": employee.id,
+ "date_start": self.today,
+ "date_end": self.today,
+ "amount": 15000.0,
+ "amount_period": "quarter",
+ }
+ )
self.assertEqual(contract.wage, 5000.0)
self.assertEqual(contract.approximate_wage, 0.0)
self.assertTrue(contract.is_wage_accurate)
def test_annual(self):
- employee = self.HrEmployee.create({
- 'name': 'Employee',
- })
- contract = self.HrContract.create({
- 'name': 'Contract',
- 'employee_id': employee.id,
- 'date_start': self.today,
- 'date_end': self.today,
- 'amount': 60000.0,
- 'amount_period': 'year',
- })
+ employee = self.HrEmployee.create({"name": "Employee"})
+ contract = self.HrContract.create(
+ {
+ "name": "Contract",
+ "employee_id": employee.id,
+ "date_start": self.today,
+ "date_end": self.today,
+ "amount": 60000.0,
+ "amount_period": "year",
+ }
+ )
self.assertEqual(contract.wage, 5000.0)
self.assertEqual(contract.approximate_wage, 0.0)
diff --git a/hr_contract_rate/views/hr_contract.xml b/hr_contract_rate/views/hr_contract.xml
index b197476ea3a..9cd3d58d97c 100644
--- a/hr_contract_rate/views/hr_contract.xml
+++ b/hr_contract_rate/views/hr_contract.xml
@@ -4,11 +4,10 @@
License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl.html).
-->
-
hr.contract.view.form
hr.contract
-
+
Salary and Advantages
@@ -21,16 +20,15 @@
1
-
+
1
/
-
+
-
From 1cc53b49f7e149e3f787061350214cb8cb971304 Mon Sep 17 00:00:00 2001
From: nans
Date: Tue, 5 Jan 2021 11:17:13 +0100
Subject: [PATCH 05/24] [MIG] hr_contract_rate: Migration to 13.0
---
hr_contract_rate/__manifest__.py | 2 +-
hr_contract_rate/models/hr_contract.py | 3 ---
2 files changed, 1 insertion(+), 4 deletions(-)
diff --git a/hr_contract_rate/__manifest__.py b/hr_contract_rate/__manifest__.py
index 9a3c5fac8fc..e8ba12053cd 100644
--- a/hr_contract_rate/__manifest__.py
+++ b/hr_contract_rate/__manifest__.py
@@ -4,7 +4,7 @@
{
"name": "HR Contract Rate",
- "version": "12.0.1.0.0",
+ "version": "13.0.1.0.0",
"category": "Human Resources",
"website": "https://github.com/OCA/hr",
"author": "CorporateHub, " "Odoo Community Association (OCA)",
diff --git a/hr_contract_rate/models/hr_contract.py b/hr_contract_rate/models/hr_contract.py
index e4099708546..0a36d972190 100644
--- a/hr_contract_rate/models/hr_contract.py
+++ b/hr_contract_rate/models/hr_contract.py
@@ -71,7 +71,6 @@ def _default_work_weeks_per_month(self):
""" Hook for extensions """
return self._default_work_days_per_month() / 5.0
- @api.multi
def _get_wage_from_amount(self):
""" Hook for extensions """
self.ensure_one()
@@ -95,7 +94,6 @@ def _get_wage_from_amount(self):
wage = self.amount / 12.0
return wage, is_wage_accurate
- @api.multi
@api.depends(
"amount",
"amount_period",
@@ -110,7 +108,6 @@ def _compute_wage(self):
contract.approximate_wage = 0 if is_wage_accurate else wage
contract.wage = wage if is_wage_accurate else 0
- @api.multi
def _inverse_wage(self):
if self.env.context.get("hr_contract_inverse_wage_skip"):
return
From 15c60f8e2805b1dfac0724401bdc6bfcdb9eb230 Mon Sep 17 00:00:00 2001
From: oca-travis
Date: Tue, 12 Jan 2021 07:07:43 +0000
Subject: [PATCH 06/24] [UPD] Update hr_contract_rate.pot
---
hr_contract_rate/i18n/hr_contract_rate.pot | 25 +++++++++++-----------
1 file changed, 12 insertions(+), 13 deletions(-)
diff --git a/hr_contract_rate/i18n/hr_contract_rate.pot b/hr_contract_rate/i18n/hr_contract_rate.pot
index 00a85da0c34..d9e1bb67c92 100644
--- a/hr_contract_rate/i18n/hr_contract_rate.pot
+++ b/hr_contract_rate/i18n/hr_contract_rate.pot
@@ -1,12 +1,12 @@
# Translation of Odoo Server.
# This file contains the translation of the following modules:
-# * hr_contract_rate
+# * hr_contract_rate
#
msgid ""
msgstr ""
-"Project-Id-Version: Odoo Server 12.0\n"
+"Project-Id-Version: Odoo Server 13.0\n"
"Report-Msgid-Bugs-To: \n"
-"Last-Translator: <>\n"
+"Last-Translator: \n"
"Language-Team: \n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
@@ -20,13 +20,13 @@ msgid "Amount"
msgstr ""
#. module: hr_contract_rate
-#: selection:hr.contract,amount_period:0
-msgid "Day"
+#: model:ir.model,name:hr_contract_rate.model_hr_contract
+msgid "Contract"
msgstr ""
#. module: hr_contract_rate
-#: model:ir.model,name:hr_contract_rate.model_hr_contract
-msgid "Employee Contract"
+#: model:ir.model.fields.selection,name:hr_contract_rate.selection__hr_contract__amount_period__day
+msgid "Day"
msgstr ""
#. module: hr_contract_rate
@@ -45,7 +45,7 @@ msgid "Employee's monthly gross wage."
msgstr ""
#. module: hr_contract_rate
-#: selection:hr.contract,amount_period:0
+#: model:ir.model.fields.selection,name:hr_contract_rate.selection__hr_contract__amount_period__hour
msgid "Hour"
msgstr ""
@@ -70,7 +70,7 @@ msgid "Is Wage Accurate"
msgstr ""
#. module: hr_contract_rate
-#: selection:hr.contract,amount_period:0
+#: model:ir.model.fields.selection,name:hr_contract_rate.selection__hr_contract__amount_period__month
msgid "Month"
msgstr ""
@@ -85,7 +85,7 @@ msgid "Period of employee's contract amount"
msgstr ""
#. module: hr_contract_rate
-#: selection:hr.contract,amount_period:0
+#: model:ir.model.fields.selection,name:hr_contract_rate.selection__hr_contract__amount_period__quarter
msgid "Quarter"
msgstr ""
@@ -105,7 +105,7 @@ msgid "Wage (approximate)"
msgstr ""
#. module: hr_contract_rate
-#: selection:hr.contract,amount_period:0
+#: model:ir.model.fields.selection,name:hr_contract_rate.selection__hr_contract__amount_period__week
msgid "Week"
msgstr ""
@@ -125,7 +125,6 @@ msgid "Work weeks (per month)"
msgstr ""
#. module: hr_contract_rate
-#: selection:hr.contract,amount_period:0
+#: model:ir.model.fields.selection,name:hr_contract_rate.selection__hr_contract__amount_period__year
msgid "Year"
msgstr ""
-
From a294f4b4916bd704574f4c7f795260c4449d2a7c Mon Sep 17 00:00:00 2001
From: OCA-git-bot
Date: Tue, 12 Jan 2021 07:20:27 +0000
Subject: [PATCH 07/24] [UPD] README.rst
---
hr_contract_rate/README.rst | 12 ++++++------
hr_contract_rate/static/description/index.html | 6 +++---
2 files changed, 9 insertions(+), 9 deletions(-)
diff --git a/hr_contract_rate/README.rst b/hr_contract_rate/README.rst
index 35990b45ddb..670922b9064 100644
--- a/hr_contract_rate/README.rst
+++ b/hr_contract_rate/README.rst
@@ -14,16 +14,16 @@ HR Contract Rate
:target: http://www.gnu.org/licenses/agpl-3.0-standalone.html
:alt: License: AGPL-3
.. |badge3| image:: https://img.shields.io/badge/github-OCA%2Fhr-lightgray.png?logo=github
- :target: https://github.com/OCA/hr/tree/12.0/hr_contract_rate
+ :target: https://github.com/OCA/hr/tree/13.0/hr_contract_rate
:alt: OCA/hr
.. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png
- :target: https://translation.odoo-community.org/projects/hr-12-0/hr-12-0-hr_contract_rate
+ :target: https://translation.odoo-community.org/projects/hr-13-0/hr-13-0-hr_contract_rate
:alt: Translate me on Weblate
.. |badge5| image:: https://img.shields.io/badge/runbot-Try%20me-875A7B.png
- :target: https://runbot.odoo-community.org/runbot/116/12.0
+ :target: https://runbot.odoo-community.org/runbot/116/13.0
:alt: Try me on Runbot
-|badge1| |badge2| |badge3| |badge4| |badge5|
+|badge1| |badge2| |badge3| |badge4| |badge5|
This module allows to specify a contractual rate of Employee using various
time periods:
@@ -59,7 +59,7 @@ Bug Tracker
Bugs are tracked on `GitHub Issues `_.
In case of trouble, please check there if your issue has already been reported.
If you spotted it first, help us smashing it by providing a detailed and welcomed
-`feedback `_.
+`feedback `_.
Do not contact contributors directly about support or help with technical issues.
@@ -91,6 +91,6 @@ OCA, or the Odoo Community Association, is a nonprofit organization whose
mission is to support the collaborative development of Odoo features and
promote its widespread use.
-This module is part of the `OCA/hr `_ project on GitHub.
+This module is part of the `OCA/hr `_ project on GitHub.
You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute.
diff --git a/hr_contract_rate/static/description/index.html b/hr_contract_rate/static/description/index.html
index b1cca2afadc..2e1973c14af 100644
--- a/hr_contract_rate/static/description/index.html
+++ b/hr_contract_rate/static/description/index.html
@@ -367,7 +367,7 @@ HR Contract Rate
!! This file is generated by oca-gen-addon-readme !!
!! changes will be overwritten. !!
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! -->
-
+
This module allows to specify a contractual rate of Employee using various
time periods:
@@ -406,7 +406,7 @@
Bugs are tracked on GitHub Issues .
In case of trouble, please check there if your issue has already been reported.
If you spotted it first, help us smashing it by providing a detailed and welcomed
-feedback .
+feedback .
Do not contact contributors directly about support or help with technical issues.
@@ -433,7 +433,7 @@
OCA, or the Odoo Community Association, is a nonprofit organization whose
mission is to support the collaborative development of Odoo features and
promote its widespread use.
-
This module is part of the OCA/hr project on GitHub.
+
This module is part of the OCA/hr project on GitHub.
You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute .
From 820f1fe8189aa00ba6f0ddd100f4ef7ddaf654bd Mon Sep 17 00:00:00 2001
From: "Sandrine (ACSONE)"
Date: Fri, 19 Mar 2021 12:54:14 +0000
Subject: [PATCH 08/24] Added translation using Weblate (French (France))
---
hr_contract_rate/i18n/fr_FR.po | 131 +++++++++++++++++++++++++++++++++
1 file changed, 131 insertions(+)
create mode 100644 hr_contract_rate/i18n/fr_FR.po
diff --git a/hr_contract_rate/i18n/fr_FR.po b/hr_contract_rate/i18n/fr_FR.po
new file mode 100644
index 00000000000..c7443b18e98
--- /dev/null
+++ b/hr_contract_rate/i18n/fr_FR.po
@@ -0,0 +1,131 @@
+# Translation of Odoo Server.
+# This file contains the translation of the following modules:
+# * hr_contract_rate
+#
+msgid ""
+msgstr ""
+"Project-Id-Version: Odoo Server 13.0\n"
+"Report-Msgid-Bugs-To: \n"
+"Last-Translator: Automatically generated\n"
+"Language-Team: none\n"
+"Language: fr_FR\n"
+"MIME-Version: 1.0\n"
+"Content-Type: text/plain; charset=UTF-8\n"
+"Content-Transfer-Encoding: \n"
+"Plural-Forms: nplurals=2; plural=n > 1;\n"
+
+#. module: hr_contract_rate
+#: model:ir.model.fields,field_description:hr_contract_rate.field_hr_contract__amount
+#: model_terms:ir.ui.view,arch_db:hr_contract_rate.hr_contract_view_form
+msgid "Amount"
+msgstr ""
+
+#. module: hr_contract_rate
+#: model:ir.model,name:hr_contract_rate.model_hr_contract
+msgid "Contract"
+msgstr ""
+
+#. module: hr_contract_rate
+#: model:ir.model.fields.selection,name:hr_contract_rate.selection__hr_contract__amount_period__day
+msgid "Day"
+msgstr ""
+
+#. module: hr_contract_rate
+#: model:ir.model.fields,help:hr_contract_rate.field_hr_contract__amount
+msgid "Employee's contract amount per period"
+msgstr ""
+
+#. module: hr_contract_rate
+#: model:ir.model.fields,help:hr_contract_rate.field_hr_contract__approximate_wage
+msgid "Employee's monthly gross wage (approximate)"
+msgstr ""
+
+#. module: hr_contract_rate
+#: model:ir.model.fields,help:hr_contract_rate.field_hr_contract__wage
+msgid "Employee's monthly gross wage."
+msgstr ""
+
+#. module: hr_contract_rate
+#: model:ir.model.fields.selection,name:hr_contract_rate.selection__hr_contract__amount_period__hour
+msgid "Hour"
+msgstr ""
+
+#. module: hr_contract_rate
+#: model:ir.model.fields,help:hr_contract_rate.field_hr_contract__work_days_per_month
+msgid "How many work days there is in an average month"
+msgstr ""
+
+#. module: hr_contract_rate
+#: model:ir.model.fields,help:hr_contract_rate.field_hr_contract__work_hours_per_month
+msgid "How many work hours there is in an average month"
+msgstr ""
+
+#. module: hr_contract_rate
+#: model:ir.model.fields,help:hr_contract_rate.field_hr_contract__work_weeks_per_month
+msgid "How many work weeks there is in an average month"
+msgstr ""
+
+#. module: hr_contract_rate
+#: model:ir.model.fields,field_description:hr_contract_rate.field_hr_contract__is_wage_accurate
+msgid "Is Wage Accurate"
+msgstr ""
+
+#. module: hr_contract_rate
+#: model:ir.model.fields.selection,name:hr_contract_rate.selection__hr_contract__amount_period__month
+msgid "Month"
+msgstr ""
+
+#. module: hr_contract_rate
+#: model:ir.model.fields,field_description:hr_contract_rate.field_hr_contract__amount_period
+msgid "Period of Amount"
+msgstr ""
+
+#. module: hr_contract_rate
+#: model:ir.model.fields,help:hr_contract_rate.field_hr_contract__amount_period
+msgid "Period of employee's contract amount"
+msgstr ""
+
+#. module: hr_contract_rate
+#: model:ir.model.fields.selection,name:hr_contract_rate.selection__hr_contract__amount_period__quarter
+msgid "Quarter"
+msgstr ""
+
+#. module: hr_contract_rate
+#: model_terms:ir.ui.view,arch_db:hr_contract_rate.hr_contract_view_form
+msgid "Salary and Advantages"
+msgstr ""
+
+#. module: hr_contract_rate
+#: model:ir.model.fields,field_description:hr_contract_rate.field_hr_contract__wage
+msgid "Wage"
+msgstr ""
+
+#. module: hr_contract_rate
+#: model:ir.model.fields,field_description:hr_contract_rate.field_hr_contract__approximate_wage
+msgid "Wage (approximate)"
+msgstr ""
+
+#. module: hr_contract_rate
+#: model:ir.model.fields.selection,name:hr_contract_rate.selection__hr_contract__amount_period__week
+msgid "Week"
+msgstr ""
+
+#. module: hr_contract_rate
+#: model:ir.model.fields,field_description:hr_contract_rate.field_hr_contract__work_days_per_month
+msgid "Work days (per month)"
+msgstr ""
+
+#. module: hr_contract_rate
+#: model:ir.model.fields,field_description:hr_contract_rate.field_hr_contract__work_hours_per_month
+msgid "Work hours (per month)"
+msgstr ""
+
+#. module: hr_contract_rate
+#: model:ir.model.fields,field_description:hr_contract_rate.field_hr_contract__work_weeks_per_month
+msgid "Work weeks (per month)"
+msgstr ""
+
+#. module: hr_contract_rate
+#: model:ir.model.fields.selection,name:hr_contract_rate.selection__hr_contract__amount_period__year
+msgid "Year"
+msgstr ""
From e5901398978994b4e96e1b97f2fca32f9347df54 Mon Sep 17 00:00:00 2001
From: "Sandrine (ACSONE)"
Date: Fri, 19 Mar 2021 12:56:21 +0000
Subject: [PATCH 09/24] Translated using Weblate (French (France))
Currently translated at 47.8% (11 of 23 strings)
Translation: hr-13.0/hr-13.0-hr_contract_rate
Translate-URL: https://translation.odoo-community.org/projects/hr-13-0/hr-13-0-hr_contract_rate/fr_FR/
---
hr_contract_rate/i18n/fr_FR.po | 26 ++++++++++++++------------
1 file changed, 14 insertions(+), 12 deletions(-)
diff --git a/hr_contract_rate/i18n/fr_FR.po b/hr_contract_rate/i18n/fr_FR.po
index c7443b18e98..274fa54e17e 100644
--- a/hr_contract_rate/i18n/fr_FR.po
+++ b/hr_contract_rate/i18n/fr_FR.po
@@ -6,29 +6,31 @@ msgid ""
msgstr ""
"Project-Id-Version: Odoo Server 13.0\n"
"Report-Msgid-Bugs-To: \n"
-"Last-Translator: Automatically generated\n"
+"PO-Revision-Date: 2021-03-19 15:46+0000\n"
+"Last-Translator: Sandrine (ACSONE) \n"
"Language-Team: none\n"
"Language: fr_FR\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: \n"
"Plural-Forms: nplurals=2; plural=n > 1;\n"
+"X-Generator: Weblate 4.3.2\n"
#. module: hr_contract_rate
#: model:ir.model.fields,field_description:hr_contract_rate.field_hr_contract__amount
#: model_terms:ir.ui.view,arch_db:hr_contract_rate.hr_contract_view_form
msgid "Amount"
-msgstr ""
+msgstr "Salaire"
#. module: hr_contract_rate
#: model:ir.model,name:hr_contract_rate.model_hr_contract
msgid "Contract"
-msgstr ""
+msgstr "Contrat"
#. module: hr_contract_rate
#: model:ir.model.fields.selection,name:hr_contract_rate.selection__hr_contract__amount_period__day
msgid "Day"
-msgstr ""
+msgstr "Jour"
#. module: hr_contract_rate
#: model:ir.model.fields,help:hr_contract_rate.field_hr_contract__amount
@@ -48,7 +50,7 @@ msgstr ""
#. module: hr_contract_rate
#: model:ir.model.fields.selection,name:hr_contract_rate.selection__hr_contract__amount_period__hour
msgid "Hour"
-msgstr ""
+msgstr "Heure"
#. module: hr_contract_rate
#: model:ir.model.fields,help:hr_contract_rate.field_hr_contract__work_days_per_month
@@ -73,12 +75,12 @@ msgstr ""
#. module: hr_contract_rate
#: model:ir.model.fields.selection,name:hr_contract_rate.selection__hr_contract__amount_period__month
msgid "Month"
-msgstr ""
+msgstr "Mois"
#. module: hr_contract_rate
#: model:ir.model.fields,field_description:hr_contract_rate.field_hr_contract__amount_period
msgid "Period of Amount"
-msgstr ""
+msgstr "Périodicité"
#. module: hr_contract_rate
#: model:ir.model.fields,help:hr_contract_rate.field_hr_contract__amount_period
@@ -88,17 +90,17 @@ msgstr ""
#. module: hr_contract_rate
#: model:ir.model.fields.selection,name:hr_contract_rate.selection__hr_contract__amount_period__quarter
msgid "Quarter"
-msgstr ""
+msgstr "Trimestre"
#. module: hr_contract_rate
#: model_terms:ir.ui.view,arch_db:hr_contract_rate.hr_contract_view_form
msgid "Salary and Advantages"
-msgstr ""
+msgstr "Salaire et avantages"
#. module: hr_contract_rate
#: model:ir.model.fields,field_description:hr_contract_rate.field_hr_contract__wage
msgid "Wage"
-msgstr ""
+msgstr "Salaire"
#. module: hr_contract_rate
#: model:ir.model.fields,field_description:hr_contract_rate.field_hr_contract__approximate_wage
@@ -108,7 +110,7 @@ msgstr ""
#. module: hr_contract_rate
#: model:ir.model.fields.selection,name:hr_contract_rate.selection__hr_contract__amount_period__week
msgid "Week"
-msgstr ""
+msgstr "Semaine"
#. module: hr_contract_rate
#: model:ir.model.fields,field_description:hr_contract_rate.field_hr_contract__work_days_per_month
@@ -128,4 +130,4 @@ msgstr ""
#. module: hr_contract_rate
#: model:ir.model.fields.selection,name:hr_contract_rate.selection__hr_contract__amount_period__year
msgid "Year"
-msgstr ""
+msgstr "Année"
From 2e6a3d43563d3a4b691df042ea22ef87b1157d1e Mon Sep 17 00:00:00 2001
From: nicolasrsande
Date: Mon, 20 Mar 2023 14:07:42 -0300
Subject: [PATCH 10/24] [IMP] hr_contract_rate: black, isort, prettier
---
hr_contract_rate/models/hr_contract.py | 13 ++++++++-----
1 file changed, 8 insertions(+), 5 deletions(-)
diff --git a/hr_contract_rate/models/hr_contract.py b/hr_contract_rate/models/hr_contract.py
index 0a36d972190..c0115409288 100644
--- a/hr_contract_rate/models/hr_contract.py
+++ b/hr_contract_rate/models/hr_contract.py
@@ -20,7 +20,10 @@ class HrContract(models.Model):
store=True,
help="Employee's monthly gross wage (approximate)",
)
- is_wage_accurate = fields.Boolean(compute="_compute_wage", store=True,)
+ is_wage_accurate = fields.Boolean(
+ compute="_compute_wage",
+ store=True,
+ )
work_hours_per_month = fields.Float(
string="Work hours (per month)",
default=lambda self: self._default_work_hours_per_month(),
@@ -58,21 +61,21 @@ class HrContract(models.Model):
@api.model
def _default_work_hours_per_month(self):
- """ Hook for extensions """
+ """Hook for extensions"""
return 2080.0 / 12.0
@api.model
def _default_work_days_per_month(self):
- """ Hook for extensions """
+ """Hook for extensions"""
return self._default_work_hours_per_month() / 8.0
@api.model
def _default_work_weeks_per_month(self):
- """ Hook for extensions """
+ """Hook for extensions"""
return self._default_work_days_per_month() / 5.0
def _get_wage_from_amount(self):
- """ Hook for extensions """
+ """Hook for extensions"""
self.ensure_one()
if self.amount_period == "hour":
is_wage_accurate = False
From 31b97f8c50b244eae2c13dde5b551ade0238ab57 Mon Sep 17 00:00:00 2001
From: nicolasrsande
Date: Mon, 20 Mar 2023 14:16:35 -0300
Subject: [PATCH 11/24] [14.0] [MIG] hr_contract_rate
---
hr_contract_rate/__manifest__.py | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/hr_contract_rate/__manifest__.py b/hr_contract_rate/__manifest__.py
index e8ba12053cd..6eff2b2cbcb 100644
--- a/hr_contract_rate/__manifest__.py
+++ b/hr_contract_rate/__manifest__.py
@@ -4,7 +4,7 @@
{
"name": "HR Contract Rate",
- "version": "13.0.1.0.0",
+ "version": "14.0.1.0.0",
"category": "Human Resources",
"website": "https://github.com/OCA/hr",
"author": "CorporateHub, " "Odoo Community Association (OCA)",
@@ -16,4 +16,5 @@
"post_init_hook": "post_init_hook",
"depends": ["hr_contract"],
"data": ["views/hr_contract.xml"],
+ "mantainers": ["nimarosa"],
}
From 843c3aa03015e32c06e59a64660e02d0a637644c Mon Sep 17 00:00:00 2001
From: oca-ci
Date: Mon, 20 Mar 2023 17:44:10 +0000
Subject: [PATCH 12/24] [UPD] Update hr_contract_rate.pot
---
hr_contract_rate/i18n/hr_contract_rate.pot | 25 +++++++++++++++++-----
1 file changed, 20 insertions(+), 5 deletions(-)
diff --git a/hr_contract_rate/i18n/hr_contract_rate.pot b/hr_contract_rate/i18n/hr_contract_rate.pot
index d9e1bb67c92..4ff7bc94b6c 100644
--- a/hr_contract_rate/i18n/hr_contract_rate.pot
+++ b/hr_contract_rate/i18n/hr_contract_rate.pot
@@ -4,7 +4,7 @@
#
msgid ""
msgstr ""
-"Project-Id-Version: Odoo Server 13.0\n"
+"Project-Id-Version: Odoo Server 14.0\n"
"Report-Msgid-Bugs-To: \n"
"Last-Translator: \n"
"Language-Team: \n"
@@ -20,13 +20,18 @@ msgid "Amount"
msgstr ""
#. module: hr_contract_rate
-#: model:ir.model,name:hr_contract_rate.model_hr_contract
-msgid "Contract"
+#: model:ir.model.fields.selection,name:hr_contract_rate.selection__hr_contract__amount_period__day
+msgid "Day"
msgstr ""
#. module: hr_contract_rate
-#: model:ir.model.fields.selection,name:hr_contract_rate.selection__hr_contract__amount_period__day
-msgid "Day"
+#: model:ir.model.fields,field_description:hr_contract_rate.field_hr_contract__display_name
+msgid "Display Name"
+msgstr ""
+
+#. module: hr_contract_rate
+#: model:ir.model,name:hr_contract_rate.model_hr_contract
+msgid "Employee Contract"
msgstr ""
#. module: hr_contract_rate
@@ -64,11 +69,21 @@ msgstr ""
msgid "How many work weeks there is in an average month"
msgstr ""
+#. module: hr_contract_rate
+#: model:ir.model.fields,field_description:hr_contract_rate.field_hr_contract__id
+msgid "ID"
+msgstr ""
+
#. module: hr_contract_rate
#: model:ir.model.fields,field_description:hr_contract_rate.field_hr_contract__is_wage_accurate
msgid "Is Wage Accurate"
msgstr ""
+#. module: hr_contract_rate
+#: model:ir.model.fields,field_description:hr_contract_rate.field_hr_contract____last_update
+msgid "Last Modified on"
+msgstr ""
+
#. module: hr_contract_rate
#: model:ir.model.fields.selection,name:hr_contract_rate.selection__hr_contract__amount_period__month
msgid "Month"
From 959c8bb2e5361c0744f739ceecea08be3887f1d0 Mon Sep 17 00:00:00 2001
From: OCA-git-bot
Date: Mon, 20 Mar 2023 17:49:41 +0000
Subject: [PATCH 13/24] [UPD] README.rst
---
hr_contract_rate/README.rst | 10 +++++-----
hr_contract_rate/static/description/index.html | 6 +++---
2 files changed, 8 insertions(+), 8 deletions(-)
diff --git a/hr_contract_rate/README.rst b/hr_contract_rate/README.rst
index 670922b9064..39827e6142e 100644
--- a/hr_contract_rate/README.rst
+++ b/hr_contract_rate/README.rst
@@ -14,13 +14,13 @@ HR Contract Rate
:target: http://www.gnu.org/licenses/agpl-3.0-standalone.html
:alt: License: AGPL-3
.. |badge3| image:: https://img.shields.io/badge/github-OCA%2Fhr-lightgray.png?logo=github
- :target: https://github.com/OCA/hr/tree/13.0/hr_contract_rate
+ :target: https://github.com/OCA/hr/tree/14.0/hr_contract_rate
:alt: OCA/hr
.. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png
- :target: https://translation.odoo-community.org/projects/hr-13-0/hr-13-0-hr_contract_rate
+ :target: https://translation.odoo-community.org/projects/hr-14-0/hr-14-0-hr_contract_rate
:alt: Translate me on Weblate
.. |badge5| image:: https://img.shields.io/badge/runbot-Try%20me-875A7B.png
- :target: https://runbot.odoo-community.org/runbot/116/13.0
+ :target: https://runbot.odoo-community.org/runbot/116/14.0
:alt: Try me on Runbot
|badge1| |badge2| |badge3| |badge4| |badge5|
@@ -59,7 +59,7 @@ Bug Tracker
Bugs are tracked on `GitHub Issues `_.
In case of trouble, please check there if your issue has already been reported.
If you spotted it first, help us smashing it by providing a detailed and welcomed
-`feedback `_.
+`feedback `_.
Do not contact contributors directly about support or help with technical issues.
@@ -91,6 +91,6 @@ OCA, or the Odoo Community Association, is a nonprofit organization whose
mission is to support the collaborative development of Odoo features and
promote its widespread use.
-This module is part of the `OCA/hr `_ project on GitHub.
+This module is part of the `OCA/hr `_ project on GitHub.
You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute.
diff --git a/hr_contract_rate/static/description/index.html b/hr_contract_rate/static/description/index.html
index 2e1973c14af..330ede4488e 100644
--- a/hr_contract_rate/static/description/index.html
+++ b/hr_contract_rate/static/description/index.html
@@ -367,7 +367,7 @@ HR Contract Rate
!! This file is generated by oca-gen-addon-readme !!
!! changes will be overwritten. !!
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! -->
-
+
This module allows to specify a contractual rate of Employee using various
time periods:
@@ -406,7 +406,7 @@
Bugs are tracked on GitHub Issues .
In case of trouble, please check there if your issue has already been reported.
If you spotted it first, help us smashing it by providing a detailed and welcomed
-feedback .
+feedback .
Do not contact contributors directly about support or help with technical issues.
@@ -433,7 +433,7 @@
OCA, or the Odoo Community Association, is a nonprofit organization whose
mission is to support the collaborative development of Odoo features and
promote its widespread use.
-
This module is part of the OCA/hr project on GitHub.
+
This module is part of the OCA/hr project on GitHub.
You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute .
From 4b67eecbb0570276dee0ec02dd268634ea43f40c Mon Sep 17 00:00:00 2001
From: Nicolas Rodriguez Sande
Date: Sun, 2 Apr 2023 22:13:53 +0000
Subject: [PATCH 14/24] Added translation using Weblate (Spanish (Argentina))
---
hr_contract_rate/i18n/es_AR.po | 146 +++++++++++++++++++++++++++++++++
1 file changed, 146 insertions(+)
create mode 100644 hr_contract_rate/i18n/es_AR.po
diff --git a/hr_contract_rate/i18n/es_AR.po b/hr_contract_rate/i18n/es_AR.po
new file mode 100644
index 00000000000..950051e2d74
--- /dev/null
+++ b/hr_contract_rate/i18n/es_AR.po
@@ -0,0 +1,146 @@
+# Translation of Odoo Server.
+# This file contains the translation of the following modules:
+# * hr_contract_rate
+#
+msgid ""
+msgstr ""
+"Project-Id-Version: Odoo Server 14.0\n"
+"Report-Msgid-Bugs-To: \n"
+"Last-Translator: Automatically generated\n"
+"Language-Team: none\n"
+"Language: es_AR\n"
+"MIME-Version: 1.0\n"
+"Content-Type: text/plain; charset=UTF-8\n"
+"Content-Transfer-Encoding: \n"
+"Plural-Forms: nplurals=2; plural=n != 1;\n"
+
+#. module: hr_contract_rate
+#: model:ir.model.fields,field_description:hr_contract_rate.field_hr_contract__amount
+#: model_terms:ir.ui.view,arch_db:hr_contract_rate.hr_contract_view_form
+msgid "Amount"
+msgstr ""
+
+#. module: hr_contract_rate
+#: model:ir.model.fields.selection,name:hr_contract_rate.selection__hr_contract__amount_period__day
+msgid "Day"
+msgstr ""
+
+#. module: hr_contract_rate
+#: model:ir.model.fields,field_description:hr_contract_rate.field_hr_contract__display_name
+msgid "Display Name"
+msgstr ""
+
+#. module: hr_contract_rate
+#: model:ir.model,name:hr_contract_rate.model_hr_contract
+msgid "Employee Contract"
+msgstr ""
+
+#. module: hr_contract_rate
+#: model:ir.model.fields,help:hr_contract_rate.field_hr_contract__amount
+msgid "Employee's contract amount per period"
+msgstr ""
+
+#. module: hr_contract_rate
+#: model:ir.model.fields,help:hr_contract_rate.field_hr_contract__approximate_wage
+msgid "Employee's monthly gross wage (approximate)"
+msgstr ""
+
+#. module: hr_contract_rate
+#: model:ir.model.fields,help:hr_contract_rate.field_hr_contract__wage
+msgid "Employee's monthly gross wage."
+msgstr ""
+
+#. module: hr_contract_rate
+#: model:ir.model.fields.selection,name:hr_contract_rate.selection__hr_contract__amount_period__hour
+msgid "Hour"
+msgstr ""
+
+#. module: hr_contract_rate
+#: model:ir.model.fields,help:hr_contract_rate.field_hr_contract__work_days_per_month
+msgid "How many work days there is in an average month"
+msgstr ""
+
+#. module: hr_contract_rate
+#: model:ir.model.fields,help:hr_contract_rate.field_hr_contract__work_hours_per_month
+msgid "How many work hours there is in an average month"
+msgstr ""
+
+#. module: hr_contract_rate
+#: model:ir.model.fields,help:hr_contract_rate.field_hr_contract__work_weeks_per_month
+msgid "How many work weeks there is in an average month"
+msgstr ""
+
+#. module: hr_contract_rate
+#: model:ir.model.fields,field_description:hr_contract_rate.field_hr_contract__id
+msgid "ID"
+msgstr ""
+
+#. module: hr_contract_rate
+#: model:ir.model.fields,field_description:hr_contract_rate.field_hr_contract__is_wage_accurate
+msgid "Is Wage Accurate"
+msgstr ""
+
+#. module: hr_contract_rate
+#: model:ir.model.fields,field_description:hr_contract_rate.field_hr_contract____last_update
+msgid "Last Modified on"
+msgstr ""
+
+#. module: hr_contract_rate
+#: model:ir.model.fields.selection,name:hr_contract_rate.selection__hr_contract__amount_period__month
+msgid "Month"
+msgstr ""
+
+#. module: hr_contract_rate
+#: model:ir.model.fields,field_description:hr_contract_rate.field_hr_contract__amount_period
+msgid "Period of Amount"
+msgstr ""
+
+#. module: hr_contract_rate
+#: model:ir.model.fields,help:hr_contract_rate.field_hr_contract__amount_period
+msgid "Period of employee's contract amount"
+msgstr ""
+
+#. module: hr_contract_rate
+#: model:ir.model.fields.selection,name:hr_contract_rate.selection__hr_contract__amount_period__quarter
+msgid "Quarter"
+msgstr ""
+
+#. module: hr_contract_rate
+#: model_terms:ir.ui.view,arch_db:hr_contract_rate.hr_contract_view_form
+msgid "Salary and Advantages"
+msgstr ""
+
+#. module: hr_contract_rate
+#: model:ir.model.fields,field_description:hr_contract_rate.field_hr_contract__wage
+msgid "Wage"
+msgstr ""
+
+#. module: hr_contract_rate
+#: model:ir.model.fields,field_description:hr_contract_rate.field_hr_contract__approximate_wage
+msgid "Wage (approximate)"
+msgstr ""
+
+#. module: hr_contract_rate
+#: model:ir.model.fields.selection,name:hr_contract_rate.selection__hr_contract__amount_period__week
+msgid "Week"
+msgstr ""
+
+#. module: hr_contract_rate
+#: model:ir.model.fields,field_description:hr_contract_rate.field_hr_contract__work_days_per_month
+msgid "Work days (per month)"
+msgstr ""
+
+#. module: hr_contract_rate
+#: model:ir.model.fields,field_description:hr_contract_rate.field_hr_contract__work_hours_per_month
+msgid "Work hours (per month)"
+msgstr ""
+
+#. module: hr_contract_rate
+#: model:ir.model.fields,field_description:hr_contract_rate.field_hr_contract__work_weeks_per_month
+msgid "Work weeks (per month)"
+msgstr ""
+
+#. module: hr_contract_rate
+#: model:ir.model.fields.selection,name:hr_contract_rate.selection__hr_contract__amount_period__year
+msgid "Year"
+msgstr ""
From b37e8a4bc4df10ed0ae177f5a5715c4b3f3207b6 Mon Sep 17 00:00:00 2001
From: Nicolas Rodriguez Sande
Date: Sun, 2 Apr 2023 22:14:39 +0000
Subject: [PATCH 15/24] Translated using Weblate (Spanish (Argentina))
Currently translated at 100.0% (26 of 26 strings)
Translation: hr-14.0/hr-14.0-hr_contract_rate
Translate-URL: https://translation.odoo-community.org/projects/hr-14-0/hr-14-0-hr_contract_rate/es_AR/
---
hr_contract_rate/i18n/es_AR.po | 56 ++++++++++++++++++----------------
1 file changed, 29 insertions(+), 27 deletions(-)
diff --git a/hr_contract_rate/i18n/es_AR.po b/hr_contract_rate/i18n/es_AR.po
index 950051e2d74..86990f82401 100644
--- a/hr_contract_rate/i18n/es_AR.po
+++ b/hr_contract_rate/i18n/es_AR.po
@@ -6,141 +6,143 @@ msgid ""
msgstr ""
"Project-Id-Version: Odoo Server 14.0\n"
"Report-Msgid-Bugs-To: \n"
-"Last-Translator: Automatically generated\n"
+"PO-Revision-Date: 2023-04-02 22:27+0000\n"
+"Last-Translator: Nicolas Rodriguez Sande \n"
"Language-Team: none\n"
"Language: es_AR\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: \n"
"Plural-Forms: nplurals=2; plural=n != 1;\n"
+"X-Generator: Weblate 4.14.1\n"
#. module: hr_contract_rate
#: model:ir.model.fields,field_description:hr_contract_rate.field_hr_contract__amount
#: model_terms:ir.ui.view,arch_db:hr_contract_rate.hr_contract_view_form
msgid "Amount"
-msgstr ""
+msgstr "Importe"
#. module: hr_contract_rate
#: model:ir.model.fields.selection,name:hr_contract_rate.selection__hr_contract__amount_period__day
msgid "Day"
-msgstr ""
+msgstr "Dia"
#. module: hr_contract_rate
#: model:ir.model.fields,field_description:hr_contract_rate.field_hr_contract__display_name
msgid "Display Name"
-msgstr ""
+msgstr "Nombre para mostrar"
#. module: hr_contract_rate
#: model:ir.model,name:hr_contract_rate.model_hr_contract
msgid "Employee Contract"
-msgstr ""
+msgstr "Contrato del Empleado"
#. module: hr_contract_rate
#: model:ir.model.fields,help:hr_contract_rate.field_hr_contract__amount
msgid "Employee's contract amount per period"
-msgstr ""
+msgstr "Importe del contrato por periodo"
#. module: hr_contract_rate
#: model:ir.model.fields,help:hr_contract_rate.field_hr_contract__approximate_wage
msgid "Employee's monthly gross wage (approximate)"
-msgstr ""
+msgstr "Sueldo Bruto (aproximado)"
#. module: hr_contract_rate
#: model:ir.model.fields,help:hr_contract_rate.field_hr_contract__wage
msgid "Employee's monthly gross wage."
-msgstr ""
+msgstr "Sueldo bruto."
#. module: hr_contract_rate
#: model:ir.model.fields.selection,name:hr_contract_rate.selection__hr_contract__amount_period__hour
msgid "Hour"
-msgstr ""
+msgstr "Hora"
#. module: hr_contract_rate
#: model:ir.model.fields,help:hr_contract_rate.field_hr_contract__work_days_per_month
msgid "How many work days there is in an average month"
-msgstr ""
+msgstr "Cuantos dias hay en un mes promedio"
#. module: hr_contract_rate
#: model:ir.model.fields,help:hr_contract_rate.field_hr_contract__work_hours_per_month
msgid "How many work hours there is in an average month"
-msgstr ""
+msgstr "Horas en un mes promedio"
#. module: hr_contract_rate
#: model:ir.model.fields,help:hr_contract_rate.field_hr_contract__work_weeks_per_month
msgid "How many work weeks there is in an average month"
-msgstr ""
+msgstr "Semanas en un mes promedio"
#. module: hr_contract_rate
#: model:ir.model.fields,field_description:hr_contract_rate.field_hr_contract__id
msgid "ID"
-msgstr ""
+msgstr "ID"
#. module: hr_contract_rate
#: model:ir.model.fields,field_description:hr_contract_rate.field_hr_contract__is_wage_accurate
msgid "Is Wage Accurate"
-msgstr ""
+msgstr "Es importe fijo"
#. module: hr_contract_rate
#: model:ir.model.fields,field_description:hr_contract_rate.field_hr_contract____last_update
msgid "Last Modified on"
-msgstr ""
+msgstr "Última modificación en"
#. module: hr_contract_rate
#: model:ir.model.fields.selection,name:hr_contract_rate.selection__hr_contract__amount_period__month
msgid "Month"
-msgstr ""
+msgstr "Mes"
#. module: hr_contract_rate
#: model:ir.model.fields,field_description:hr_contract_rate.field_hr_contract__amount_period
msgid "Period of Amount"
-msgstr ""
+msgstr "Periodo del importe"
#. module: hr_contract_rate
#: model:ir.model.fields,help:hr_contract_rate.field_hr_contract__amount_period
msgid "Period of employee's contract amount"
-msgstr ""
+msgstr "Importe del periodo"
#. module: hr_contract_rate
#: model:ir.model.fields.selection,name:hr_contract_rate.selection__hr_contract__amount_period__quarter
msgid "Quarter"
-msgstr ""
+msgstr "Cuatrimestre"
#. module: hr_contract_rate
#: model_terms:ir.ui.view,arch_db:hr_contract_rate.hr_contract_view_form
msgid "Salary and Advantages"
-msgstr ""
+msgstr "Sueldo y Ventajas"
#. module: hr_contract_rate
#: model:ir.model.fields,field_description:hr_contract_rate.field_hr_contract__wage
msgid "Wage"
-msgstr ""
+msgstr "Sueldo"
#. module: hr_contract_rate
#: model:ir.model.fields,field_description:hr_contract_rate.field_hr_contract__approximate_wage
msgid "Wage (approximate)"
-msgstr ""
+msgstr "Sueldo (aproximado)"
#. module: hr_contract_rate
#: model:ir.model.fields.selection,name:hr_contract_rate.selection__hr_contract__amount_period__week
msgid "Week"
-msgstr ""
+msgstr "Semana"
#. module: hr_contract_rate
#: model:ir.model.fields,field_description:hr_contract_rate.field_hr_contract__work_days_per_month
msgid "Work days (per month)"
-msgstr ""
+msgstr "Dias laborables (por mes)"
#. module: hr_contract_rate
#: model:ir.model.fields,field_description:hr_contract_rate.field_hr_contract__work_hours_per_month
msgid "Work hours (per month)"
-msgstr ""
+msgstr "Horas laborables (por mes)"
#. module: hr_contract_rate
#: model:ir.model.fields,field_description:hr_contract_rate.field_hr_contract__work_weeks_per_month
msgid "Work weeks (per month)"
-msgstr ""
+msgstr "Semanas laborables (por mes)"
#. module: hr_contract_rate
#: model:ir.model.fields.selection,name:hr_contract_rate.selection__hr_contract__amount_period__year
msgid "Year"
-msgstr ""
+msgstr "Año"
From 8c7edbe0c3283bfc7449d20563a4a48b3ff16ca1 Mon Sep 17 00:00:00 2001
From: mymage
Date: Thu, 18 May 2023 17:50:29 +0000
Subject: [PATCH 16/24] Added translation using Weblate (Italian)
---
hr_contract_rate/i18n/it.po | 146 ++++++++++++++++++++++++++++++++++++
1 file changed, 146 insertions(+)
create mode 100644 hr_contract_rate/i18n/it.po
diff --git a/hr_contract_rate/i18n/it.po b/hr_contract_rate/i18n/it.po
new file mode 100644
index 00000000000..193573b7773
--- /dev/null
+++ b/hr_contract_rate/i18n/it.po
@@ -0,0 +1,146 @@
+# Translation of Odoo Server.
+# This file contains the translation of the following modules:
+# * hr_contract_rate
+#
+msgid ""
+msgstr ""
+"Project-Id-Version: Odoo Server 14.0\n"
+"Report-Msgid-Bugs-To: \n"
+"Last-Translator: Automatically generated\n"
+"Language-Team: none\n"
+"Language: it\n"
+"MIME-Version: 1.0\n"
+"Content-Type: text/plain; charset=UTF-8\n"
+"Content-Transfer-Encoding: \n"
+"Plural-Forms: nplurals=2; plural=n != 1;\n"
+
+#. module: hr_contract_rate
+#: model:ir.model.fields,field_description:hr_contract_rate.field_hr_contract__amount
+#: model_terms:ir.ui.view,arch_db:hr_contract_rate.hr_contract_view_form
+msgid "Amount"
+msgstr ""
+
+#. module: hr_contract_rate
+#: model:ir.model.fields.selection,name:hr_contract_rate.selection__hr_contract__amount_period__day
+msgid "Day"
+msgstr ""
+
+#. module: hr_contract_rate
+#: model:ir.model.fields,field_description:hr_contract_rate.field_hr_contract__display_name
+msgid "Display Name"
+msgstr ""
+
+#. module: hr_contract_rate
+#: model:ir.model,name:hr_contract_rate.model_hr_contract
+msgid "Employee Contract"
+msgstr ""
+
+#. module: hr_contract_rate
+#: model:ir.model.fields,help:hr_contract_rate.field_hr_contract__amount
+msgid "Employee's contract amount per period"
+msgstr ""
+
+#. module: hr_contract_rate
+#: model:ir.model.fields,help:hr_contract_rate.field_hr_contract__approximate_wage
+msgid "Employee's monthly gross wage (approximate)"
+msgstr ""
+
+#. module: hr_contract_rate
+#: model:ir.model.fields,help:hr_contract_rate.field_hr_contract__wage
+msgid "Employee's monthly gross wage."
+msgstr ""
+
+#. module: hr_contract_rate
+#: model:ir.model.fields.selection,name:hr_contract_rate.selection__hr_contract__amount_period__hour
+msgid "Hour"
+msgstr ""
+
+#. module: hr_contract_rate
+#: model:ir.model.fields,help:hr_contract_rate.field_hr_contract__work_days_per_month
+msgid "How many work days there is in an average month"
+msgstr ""
+
+#. module: hr_contract_rate
+#: model:ir.model.fields,help:hr_contract_rate.field_hr_contract__work_hours_per_month
+msgid "How many work hours there is in an average month"
+msgstr ""
+
+#. module: hr_contract_rate
+#: model:ir.model.fields,help:hr_contract_rate.field_hr_contract__work_weeks_per_month
+msgid "How many work weeks there is in an average month"
+msgstr ""
+
+#. module: hr_contract_rate
+#: model:ir.model.fields,field_description:hr_contract_rate.field_hr_contract__id
+msgid "ID"
+msgstr ""
+
+#. module: hr_contract_rate
+#: model:ir.model.fields,field_description:hr_contract_rate.field_hr_contract__is_wage_accurate
+msgid "Is Wage Accurate"
+msgstr ""
+
+#. module: hr_contract_rate
+#: model:ir.model.fields,field_description:hr_contract_rate.field_hr_contract____last_update
+msgid "Last Modified on"
+msgstr ""
+
+#. module: hr_contract_rate
+#: model:ir.model.fields.selection,name:hr_contract_rate.selection__hr_contract__amount_period__month
+msgid "Month"
+msgstr ""
+
+#. module: hr_contract_rate
+#: model:ir.model.fields,field_description:hr_contract_rate.field_hr_contract__amount_period
+msgid "Period of Amount"
+msgstr ""
+
+#. module: hr_contract_rate
+#: model:ir.model.fields,help:hr_contract_rate.field_hr_contract__amount_period
+msgid "Period of employee's contract amount"
+msgstr ""
+
+#. module: hr_contract_rate
+#: model:ir.model.fields.selection,name:hr_contract_rate.selection__hr_contract__amount_period__quarter
+msgid "Quarter"
+msgstr ""
+
+#. module: hr_contract_rate
+#: model_terms:ir.ui.view,arch_db:hr_contract_rate.hr_contract_view_form
+msgid "Salary and Advantages"
+msgstr ""
+
+#. module: hr_contract_rate
+#: model:ir.model.fields,field_description:hr_contract_rate.field_hr_contract__wage
+msgid "Wage"
+msgstr ""
+
+#. module: hr_contract_rate
+#: model:ir.model.fields,field_description:hr_contract_rate.field_hr_contract__approximate_wage
+msgid "Wage (approximate)"
+msgstr ""
+
+#. module: hr_contract_rate
+#: model:ir.model.fields.selection,name:hr_contract_rate.selection__hr_contract__amount_period__week
+msgid "Week"
+msgstr ""
+
+#. module: hr_contract_rate
+#: model:ir.model.fields,field_description:hr_contract_rate.field_hr_contract__work_days_per_month
+msgid "Work days (per month)"
+msgstr ""
+
+#. module: hr_contract_rate
+#: model:ir.model.fields,field_description:hr_contract_rate.field_hr_contract__work_hours_per_month
+msgid "Work hours (per month)"
+msgstr ""
+
+#. module: hr_contract_rate
+#: model:ir.model.fields,field_description:hr_contract_rate.field_hr_contract__work_weeks_per_month
+msgid "Work weeks (per month)"
+msgstr ""
+
+#. module: hr_contract_rate
+#: model:ir.model.fields.selection,name:hr_contract_rate.selection__hr_contract__amount_period__year
+msgid "Year"
+msgstr ""
From 851fdfd426cfb83c127d571a41c08e9e537fae9c Mon Sep 17 00:00:00 2001
From: mymage
Date: Tue, 30 May 2023 07:36:29 +0000
Subject: [PATCH 17/24] Translated using Weblate (Italian)
Currently translated at 100.0% (26 of 26 strings)
Translation: hr-14.0/hr-14.0-hr_contract_rate
Translate-URL: https://translation.odoo-community.org/projects/hr-14-0/hr-14-0-hr_contract_rate/it/
---
hr_contract_rate/i18n/it.po | 56 +++++++++++++++++++------------------
1 file changed, 29 insertions(+), 27 deletions(-)
diff --git a/hr_contract_rate/i18n/it.po b/hr_contract_rate/i18n/it.po
index 193573b7773..d71280e3b90 100644
--- a/hr_contract_rate/i18n/it.po
+++ b/hr_contract_rate/i18n/it.po
@@ -6,141 +6,143 @@ msgid ""
msgstr ""
"Project-Id-Version: Odoo Server 14.0\n"
"Report-Msgid-Bugs-To: \n"
-"Last-Translator: Automatically generated\n"
+"PO-Revision-Date: 2023-05-30 09:09+0000\n"
+"Last-Translator: mymage \n"
"Language-Team: none\n"
"Language: it\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: \n"
"Plural-Forms: nplurals=2; plural=n != 1;\n"
+"X-Generator: Weblate 4.17\n"
#. module: hr_contract_rate
#: model:ir.model.fields,field_description:hr_contract_rate.field_hr_contract__amount
#: model_terms:ir.ui.view,arch_db:hr_contract_rate.hr_contract_view_form
msgid "Amount"
-msgstr ""
+msgstr "Valore"
#. module: hr_contract_rate
#: model:ir.model.fields.selection,name:hr_contract_rate.selection__hr_contract__amount_period__day
msgid "Day"
-msgstr ""
+msgstr "Giorno"
#. module: hr_contract_rate
#: model:ir.model.fields,field_description:hr_contract_rate.field_hr_contract__display_name
msgid "Display Name"
-msgstr ""
+msgstr "Nome visualizzato"
#. module: hr_contract_rate
#: model:ir.model,name:hr_contract_rate.model_hr_contract
msgid "Employee Contract"
-msgstr ""
+msgstr "Contratto dipendente"
#. module: hr_contract_rate
#: model:ir.model.fields,help:hr_contract_rate.field_hr_contract__amount
msgid "Employee's contract amount per period"
-msgstr ""
+msgstr "Valore contratto dipendente per periodo"
#. module: hr_contract_rate
#: model:ir.model.fields,help:hr_contract_rate.field_hr_contract__approximate_wage
msgid "Employee's monthly gross wage (approximate)"
-msgstr ""
+msgstr "Retribuzione lorda mensile dipendente (approssimata)"
#. module: hr_contract_rate
#: model:ir.model.fields,help:hr_contract_rate.field_hr_contract__wage
msgid "Employee's monthly gross wage."
-msgstr ""
+msgstr "Retribuzione lorda mensile dipendente."
#. module: hr_contract_rate
#: model:ir.model.fields.selection,name:hr_contract_rate.selection__hr_contract__amount_period__hour
msgid "Hour"
-msgstr ""
+msgstr "Ora"
#. module: hr_contract_rate
#: model:ir.model.fields,help:hr_contract_rate.field_hr_contract__work_days_per_month
msgid "How many work days there is in an average month"
-msgstr ""
+msgstr "Numero medio di giorni lavorativi in un mese"
#. module: hr_contract_rate
#: model:ir.model.fields,help:hr_contract_rate.field_hr_contract__work_hours_per_month
msgid "How many work hours there is in an average month"
-msgstr ""
+msgstr "Numero medio ore di lavoro in un mese"
#. module: hr_contract_rate
#: model:ir.model.fields,help:hr_contract_rate.field_hr_contract__work_weeks_per_month
msgid "How many work weeks there is in an average month"
-msgstr ""
+msgstr "Numero medio di settimane di lavoro in un mese"
#. module: hr_contract_rate
#: model:ir.model.fields,field_description:hr_contract_rate.field_hr_contract__id
msgid "ID"
-msgstr ""
+msgstr "ID"
#. module: hr_contract_rate
#: model:ir.model.fields,field_description:hr_contract_rate.field_hr_contract__is_wage_accurate
msgid "Is Wage Accurate"
-msgstr ""
+msgstr "La retribuzione è precisa"
#. module: hr_contract_rate
#: model:ir.model.fields,field_description:hr_contract_rate.field_hr_contract____last_update
msgid "Last Modified on"
-msgstr ""
+msgstr "Ultima modifica il"
#. module: hr_contract_rate
#: model:ir.model.fields.selection,name:hr_contract_rate.selection__hr_contract__amount_period__month
msgid "Month"
-msgstr ""
+msgstr "Mese"
#. module: hr_contract_rate
#: model:ir.model.fields,field_description:hr_contract_rate.field_hr_contract__amount_period
msgid "Period of Amount"
-msgstr ""
+msgstr "Periodo del valore"
#. module: hr_contract_rate
#: model:ir.model.fields,help:hr_contract_rate.field_hr_contract__amount_period
msgid "Period of employee's contract amount"
-msgstr ""
+msgstr "Periodo del valore contratto dipendente"
#. module: hr_contract_rate
#: model:ir.model.fields.selection,name:hr_contract_rate.selection__hr_contract__amount_period__quarter
msgid "Quarter"
-msgstr ""
+msgstr "Trimestre"
#. module: hr_contract_rate
#: model_terms:ir.ui.view,arch_db:hr_contract_rate.hr_contract_view_form
msgid "Salary and Advantages"
-msgstr ""
+msgstr "Stipendio e benefit"
#. module: hr_contract_rate
#: model:ir.model.fields,field_description:hr_contract_rate.field_hr_contract__wage
msgid "Wage"
-msgstr ""
+msgstr "Paga"
#. module: hr_contract_rate
#: model:ir.model.fields,field_description:hr_contract_rate.field_hr_contract__approximate_wage
msgid "Wage (approximate)"
-msgstr ""
+msgstr "Paga (approssimata)"
#. module: hr_contract_rate
#: model:ir.model.fields.selection,name:hr_contract_rate.selection__hr_contract__amount_period__week
msgid "Week"
-msgstr ""
+msgstr "Settimana"
#. module: hr_contract_rate
#: model:ir.model.fields,field_description:hr_contract_rate.field_hr_contract__work_days_per_month
msgid "Work days (per month)"
-msgstr ""
+msgstr "Giorni lavorativi (per mese)"
#. module: hr_contract_rate
#: model:ir.model.fields,field_description:hr_contract_rate.field_hr_contract__work_hours_per_month
msgid "Work hours (per month)"
-msgstr ""
+msgstr "Ore lavorative (per mese)"
#. module: hr_contract_rate
#: model:ir.model.fields,field_description:hr_contract_rate.field_hr_contract__work_weeks_per_month
msgid "Work weeks (per month)"
-msgstr ""
+msgstr "Settimane lavorative (per mese)"
#. module: hr_contract_rate
#: model:ir.model.fields.selection,name:hr_contract_rate.selection__hr_contract__amount_period__year
msgid "Year"
-msgstr ""
+msgstr "Anno"
From 91135250cb32baf1e60ff08e434720f07fe93a4e Mon Sep 17 00:00:00 2001
From: OCA-git-bot
Date: Sun, 3 Sep 2023 13:06:48 +0000
Subject: [PATCH 18/24] [UPD] README.rst
---
hr_contract_rate/README.rst | 15 +++++---
.../static/description/index.html | 38 ++++++++++---------
2 files changed, 29 insertions(+), 24 deletions(-)
diff --git a/hr_contract_rate/README.rst b/hr_contract_rate/README.rst
index 39827e6142e..b42e3dbfd9d 100644
--- a/hr_contract_rate/README.rst
+++ b/hr_contract_rate/README.rst
@@ -2,10 +2,13 @@
HR Contract Rate
================
-.. !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
+..
+ !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
!! This file is generated by oca-gen-addon-readme !!
!! changes will be overwritten. !!
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
+ !! source digest: sha256:633c9cebd405948bd6e70d276863b2046c939088fbb41a52061bd92a61e3da44
+ !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
.. |badge1| image:: https://img.shields.io/badge/maturity-Beta-yellow.png
:target: https://odoo-community.org/page/development-status
@@ -19,11 +22,11 @@ HR Contract Rate
.. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png
:target: https://translation.odoo-community.org/projects/hr-14-0/hr-14-0-hr_contract_rate
:alt: Translate me on Weblate
-.. |badge5| image:: https://img.shields.io/badge/runbot-Try%20me-875A7B.png
- :target: https://runbot.odoo-community.org/runbot/116/14.0
- :alt: Try me on Runbot
+.. |badge5| image:: https://img.shields.io/badge/runboat-Try%20me-875A7B.png
+ :target: https://runboat.odoo-community.org/builds?repo=OCA/hr&target_branch=14.0
+ :alt: Try me on Runboat
-|badge1| |badge2| |badge3| |badge4| |badge5|
+|badge1| |badge2| |badge3| |badge4| |badge5|
This module allows to specify a contractual rate of Employee using various
time periods:
@@ -58,7 +61,7 @@ Bug Tracker
Bugs are tracked on `GitHub Issues `_.
In case of trouble, please check there if your issue has already been reported.
-If you spotted it first, help us smashing it by providing a detailed and welcomed
+If you spotted it first, help us to smash it by providing a detailed and welcomed
`feedback `_.
Do not contact contributors directly about support or help with technical issues.
diff --git a/hr_contract_rate/static/description/index.html b/hr_contract_rate/static/description/index.html
index 330ede4488e..7f8a8d37f61 100644
--- a/hr_contract_rate/static/description/index.html
+++ b/hr_contract_rate/static/description/index.html
@@ -1,20 +1,20 @@
-
+
-
+
HR Contract Rate