We would like to automatize lunch as currently all orders are manually ordered and validated,
and a cash move has to be manually created each time you want to credit the wallet of some user.
In this commit we add a new widget that comes with the kanban view and will allow to take orders
in a friendly manner.
We also add a lunch.supplier model and an integration with the hr module in order to filter what
products you can order depending on your working location, this also allows you to configure an
automatic ordering via email.
TaskID: 1856876
With this commit, when a kit is processed trough an immediate transfer,
the quantity done set on the kit is now propagated to its components.
TaskID: 1896772
closesodoo/odoo#28998
* web_unsplash, website_sale
- Visual improvements and cleaning in each tab: video, documents,
pictogram, images.
- Only one search input for both the local library and unsplash.
- Replace the idea of multiple pages by adding a 'Load More' button.
task-1896705
Since project only handle task (project.issue has
been merged into tasks), the global satisfaction
field is not required anymore, as it is the same
as task satisfaction percentage.
Task-1903565
We don't want to bloat the company settings with the choice of the barcode nomenclature. We move this settings to event_barcode and stock_barcodes.
task id 1903864
closesodoo/odoo#28346
On test fixes: Because the company now have parenthesis in its name,
formatting email addresses adds double quotes around the name.
e.g.: "My Company (San Francisco)" <example@exmaple.com>
* do not display the scrap button in receipt (we don't want to allow
products not coming from your stock)
* no scrap button when any picking is done
* don't display the scrap moves, the user needs to go to the stat button
Task ID 1913275
closesodoo/odoo#29097
The fields property_cost_method ad property_valuation are never shown on the products but they sometimes are set. This creates confusion and some difficulties in the migration (the cost method/valuation on the products are different than the one set on the categories).
We remove them and only use the one on the categories.
Task: 1866333
closesodoo/odoo#26008
Purpose
=======
For payroll purpose, we need to manage attendances.
For instance, someone is working only mondays, tuesdays and fridays, but works exceptionally an other day.
It must be recorded.
Specification
===========
The new models are used to represent attendances, extra hours and leaves (as `hr.benefit`s) in a new window called "Benefits".
The schedule of employees for the full month is visible in that view (calendar view).
First the benefits needs to be generated (via a button) based on the calendar attendances and leaves.
The manager can then check benefits, delete or add some. Only the benefit name and type can be edited (not start and end dates).
Once benefits are correct, they can be validated. Validation will fail if they are some leaves to approve or if some benefits overlap on the same day.
Benefits cannot be deleted or edited once validated.
When benefits are all validated, a button appears to generate payslips.
Additional development
==================
Most of the time we don't what is the next action that should be done when creating payslips or payslip batches.
- Improve the layout, the buttons of the payroll object.
- Refactor a little the code to reuse existing chunks of code instead of reinventing the wheel in several methods.
- Remove the hr.rule.input model.
- Remove an useless report.
See each individual commit for more information.
TaskID: 1912944, 1903239
closesodoo/odoo#29065
property_cost_method is removed from product.product and product.template.
And use property_cost_method of product.category everywhare.
In This -
Used property_cost_method of product.category instead of cost_method or property_cost_method of product.template.
This commit is related to task#1866333.
product.product and product.template.
And use property_cost_method of product.category everywhare.
In This -
Used property_cost_method of product.category instead of cost_method or property_cost_method of product.template.
This commit is related to task#1866333.
Same than for payslips. Improve the flow to make it clear what is the next action
instead of displaying all the buttons.
And refactor a little the code to be more efficient, and reuse existing method instead
of using this horrible 'onchange_employee_id' method.
This field brings nothing more than the payslip lines.
Btw the term is badly chosen, it doesn't display the lines by salary rules category,
it displays the payslip lines that have a category.
The printed report is not very useful too. The only interesting part is the
contribution register at the end of the report, and there is already a dedicated
report for that.
There are currently 2 models:
- hr.rule.input to link some inputs to an hr.payslip.rule
- hr.payslip.input to add some additional inputs on a payslip.
The first model is actually there to automatically add inputs on the
additional inputs on the payslip. This is problematic because these
rules are always added (For example a salary reduction due to a
police fine). As these inputs are always added on the payslip, the
the related rules are always computed with an amount of 0.
We decided to remove this mechanism for the following reasons:
- If the rule is important and common, then define the needed values on
the contract, and compute the rules from that.
- If the rule is not so important, it should be added manually when needed.
Purpose
=======
For payroll purpose, we need to manage attendances.
For instance, someone is working only mondays, tuesdays and fridays, but works exceptionally an other day.
It must be recorded.
Specification
=============
The new models are used to represent attendances, extra hours and leaves (as `hr.benefit`s) in a new window called "Benefits".
The schedule of employees for the full month is visible in that view (calendar view).
First the benefits needs to be generated (via a button) based on the calendar attendances and leaves.
The manager can then check benefits, delete or add some. Only the benefit name and type can be edited (not start and end dates).
Once benefits are correct, they can be validated. Validation will fail if they are some leaves to approve or if some benefits overlap on the same day.
Benefits cannot be deleted or edited once validated.
When benefits are all validated, a button appears to generate payslips.
Closes#28261
Purpose
=======
More flexibility is useful when using the _attendance_intervals method (resource.calendar) in other modules when inheriting resource.calendar
Specification
=============
The commit adds a `domain` parameter to the _attendance_intervals method in resource.calendar, allowing
to better control attendances from which to compute intervals.
+ small refactoring: extraction of duplicated code in method
If the wizard to generate payslip was launched without an ´active_id´ in the context.
A ´journal_id´ entry was set to False in the context later leading to a crash at payslip creation.
The crash happens because, at creation time, the journal_id of a ´hr.payslip´ is set to the journal_id
in the context if its present. Since this context entry is False and the journal_id field is required,
creation crashes.
Before this commit, the web client evaluated all modifiers
(readonly/invisible/required) in some cases, even if it only needed one
of them. This is clearly not optimal, and I even suppose that for large o2m,
it could even have a noticeable effect on web client perceived speed
This commit simply make sure that we evaluate only what we need in those
cases. Note that it is not really a testable improvement, hence the
lack of tests.
closesodoo/odoo#29171
Traceback when the responsible is not set on an activity
since it's a required field. In this case we will use the
odoo system responsible for the activity.
Also reintroduce the default value for the responsible as
the user that create the product. The purpose is to avoid
to log all the activity for the odoo system but to dispatch
the exception between user, if a user create the product he
will probably be responsible for it. It is always possible
to remove the responsible or to modify it.
Task ID - 1913168
closesodoo/odoo#29138
hs code was dropped in 12.0 however it shouldn't have been (commit 2d738f8563). commit 498dbc548b created a new module in order to avoid losing hscode for existing database during migration.
This commit set it back as before.
closesodoo/odoo#29167
_tag_delete was not properly converted when the _tag_ calling
convention was modified in 4d581e26c2,
so <delete> tags would all blow up if encountered.
closesodoo/odoo#29149
If a user is at the same time purchase user and billing manager
he can't create a new payment terms from the PO and he has to
navigates throws multiple menus instead of just using the create
and edit function.
taskId 1868555
Closes#28280
Odoo no longer supports python 2, thus some of these helpers can and
have been replaced by python 3 built-ins, therefore there is no need for
them to stay defined.
The removed helpers are:
* izip, imap and ifilter
* unichr, text_type
* implements_to_string, implements_iterator
* string_types, integer_types
* to_native
The python 2 shims have also been removed, and only the python 3 helpers
have been kept, because they can still be usable (i.e. accepting
both bytes and str for functions that can only accept one of the two)
[REM] pyjsparser: remove PY3 shims
They're no longer necessary as Odoo doesn't officially support python 2
anymore.
closesodoo/odoo#28519
This commit replaces calls to pycompat helpers that were intended for
python 2 <-> python 3 interoperability for python 3 builtins, as python
2 is no longer officially supported by Odoo.
This includes:
* calls to imap/izip/ifilter replaced by map/zip/filter
* uses of text_type replaced by str
* uses of unichr replaced by chr
* calls to implements_to_string, implements_iterator removed
* string_types and integer_types replaced by str, int respectively
* calls to to_native replaced by calls to to_text
This is done in preparation to the removal of these deprecated helpers
in the following commit.
Since Odoo no longer officially supports python 2, some of the
restrictions previously imposed by test_pylint are no longer necessary,
either because the usage of some builtin functions is legal (zip, map,
filter) or because the concerned function/module would already raise a
relevant error under python 3.
On some models, like picking, package and move, the weight was hardcoded
in 'kg', we instead use the value in the ir.config.parameter.
We also changed some field labels to give them more meaning.
Related Task ID: #1895297closesodoo/odoo#27944
While creating a new record, the default value of a field used with the
'html_frame' field widget was not used.
Discovered with task-1903256
closesodoo/odoo#28838
The BoM structure report is recursive, since product X might use a product X.Y,
itself built using a BoM that uses X.Y.Z, and so on.
To avoid breaking the layout in cases with too deep nestedness,
the report returned a level bounded by 6.
This is a totally arbitrary value: the layout can be broken not only
because of nestedness, but also because of the length of the product name.
So it doesn't really solve the problem.
Moreover, a presentation problem should be solved at the presentation layer,
which is CSS.
opw 1921011
closesodoo/odoo#30606
When a user/partner is deleted, their messages lose their author.
Replying to those may result in a failure to fetch the mails from the
incomming mail server.
without this commit, partner_ids == [(4, False)] and this value "goes
down" all the way to the orm method "write" of the Many2many field.
resulting in a SQL query like :
INSERT INTO mail_message_res_partner_rel (mail_message_id, res_partner_id)
(SELECT a, b FROM unnest(ARRAY[149855]) AS a, unnest(ARRAY[false]) AS b)
EXCEPT (SELECT mail_message_id, res_partner_id FROM mail_message_res_partner_rel WHERE mail_message_id IN (149855))
which fails with the ProgrammingError : EXCEPT types boolean and integer
cannot be matched
opw-1921805
closesodoo/odoo#30528