Commit Graph
152817 Commits
Author SHA1 Message Date
Moens Alexandre 58b3625bc4 [IMP] l10n_eg_edi_eta : neutralise production env
before this commit:
The `odoo-bin neutralize` command would not neutralise l10n_eg_edi_eta

closes odoo/odoo#92298

X-original-commit: 9a0a644444be4cceb4bdc43838dc6ce414608437
Signed-off-by: Josse Colpaert <jco@odoo.com>
2022-05-31 16:02:15 +02:00
Antoine Vandevenne (anv) cfbd8990a3 [FIX] payment_*: update module sequences to be placed after Flutterwave
task-2759117

closes odoo/odoo#85514

Related: odoo/documentation#1939
Signed-off-by: Antoine Vandevenne (anv) <anv@odoo.com>
2022-05-31 16:02:08 +02:00
Antoine Vandevenne (anv) 94bddadf4e [ADD] payment_flutterwave: integrate with "Flutterwave standard" gateway
See README for technical details.

task-2759117

Part-of: odoo/odoo#85514
2022-05-31 16:02:08 +02:00
william-andre 9e6d585f75 [REF] account{,_edi}: upload bill wizard is for all kind of documents
An enterprise module adds the possibility to upload bank statements.
Since the mechanism is exactly the same, we should use the same
functions.

closes odoo/odoo#83639

Related: odoo/enterprise#25123
Related: odoo/upgrade#3460
Signed-off-by: Cedric Snauwaert <csn@odoo.com>
2022-05-31 16:01:51 +02:00
william-andre 7902975989 [IMP] account: allow drag and drop to upload bills in list view
Make users feel at home with a warm welcome when they try to upload
something with a drag and drop.

task-2748604

Part-of: odoo/odoo#83639
2022-05-31 16:01:51 +02:00
Didier (did) ef65fb396f [IMP] mail, im_livechat: remove dead code
closes odoo/odoo#92502

Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
2022-05-31 14:59:32 +02:00
Philippe Wauthy 7f35035f9c [FIX] privacy_lookup: fix xml id not found error
In privacy_lookup, an action is called with a XML id that is not existing.
This commit fixes the traceback received by pointing to the correct XML id.

closes odoo/odoo#92499

Signed-off-by: Kevin Baptiste <kba@odoo.com>
2022-05-31 14:59:28 +02:00
Shawcker 273c133f70 [IMP] account: improve display of the journals audit report
A few points can be improved in the display of the journals audit report:
1. it only contains the account codes. This can be unclear and lead to hard to read reports, especially for manually created accounts
2. the width of the columns Partner, Account, Label can sometimes be too small which causes a line break to happen too early
3. monetary fields do not align right for right-to-left languages.

This commit addresses these issues by:
1. adding the account name right next to the account code (same column) for more clarity.
2. setting a minimum width to mentioned columns
3. modifying the html classes accordingly to ensure the text aligns right no matter the direction of reading of the language (l2r or r2l).

task id=2824121

closes odoo/odoo#92304

X-original-commit: 0f5d125ee12597b4acb40053f74af8e03a102493
Related: odoo/enterprise#27776
Signed-off-by: Quentin De Paoli <qdp@odoo.com>
2022-05-31 14:59:20 +02:00
Cyril (cyla) e7f07d6021 [FIX] l10n_it: fix migration script
This migration script assigns the tags associated to an account's
templates to the account. It fails to consider conflicting cases
when the account already has the tag, or when multiple templates
associated with the same account share the same tag.

closes odoo/odoo#91663

X-original-commit: 04e3d52cff678dacee530e12d3f833fcce9147bc
Signed-off-by: Olivier Colson <oco@odoo.com>
Signed-off-by: William André (wan) <wan@odoo.com>
2022-05-31 14:59:11 +02:00
Didier (did) d46e879983 [FIX] mail: remove channel name translation
task-2818091

closes odoo/odoo#88239

Related: odoo/upgrade#3423
Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
2022-05-31 14:59:04 +02:00
Odoo's Mergebot 1ba2d59e1c [MERGE][IMP] mail, mass_mailing: remove mails in batch outside of send loop
Remove `mail.mail` in batch
===========================
Improve the performance of mass mailing by removing the <mail.mail>, in
batch, all at once. The unlink operation is very expensive for the ORM,
in terms of SQL queries.

A new field `to_delete` is required to know which <mail.mail> we need
to delete. The reason is that the `failure_type` is stored on the
<mail.notification>, and it's possible to have <mail.mail> without
<mail.notification>.

Improve some views
==================
Show the state of the <mail.mail> in the tree view and color only the
badge widget instead of the entire row.

Misc improvement
================
Do not remove cancelled email during the sending.
It's not the role of the sending method to remove non outgoing emails.

Do not try to send a lot of emails because of the mass mailing demo data

Task-2587345

closes odoo/odoo#73271

Related: odoo/enterprise#24266
Related: odoo/upgrade#3481
Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
2022-05-31 14:58:54 +02:00
std-odoo 036a739b62 [IMP] mail, mass_mailing: remove the <mail.mail> in batch
Purpose
=======
Improve the performance of mass mailing by removing the <mail.mail>, in
batch, all at once. The unlink operation is very expensive for the ORM,
in terms of SQL queries.

A new field `to_delete` is required to know which <mail.mail> we need
to delete. The reason is that the `failure_type` is stored on the
<mail.notification>, and it's possible to have <mail.mail> without
<mail.notification>.

Task-2587345

Part-of: odoo/odoo#73271
2022-05-31 14:58:53 +02:00
std-odoo 94a372dee7 [IMP] mail: improve the tree view of the <mail.mail>
Purpose
=======
Show the state of the <mail.mail> in the tree view and color only the
badge widget instead of the entire row.

Fix a typo in the help of the scheduled_date field on mail template.

Task-2587345

Part-of: odoo/odoo#73271
2022-05-31 14:58:53 +02:00
std-odoo 33965afa5e [IMP] mail: do not remove cancelled email during the sending
Purpose
=======
It's not the role of the sending method to remove non outgoing emails.

Task-2587345

Part-of: odoo/odoo#73271
2022-05-31 14:58:52 +02:00
Odoo's Mergebot 0ee53dc7bd [MERGE][REF] event{,_sale}: unstore seats and add revenues reporting
This PR tackles event registrations in two ways:

1. In order to reduce the concurrent writes on the database occurring when many users book at the same time, this unstores seats availability on events and tickets.

2. To provide better tools to analyse revenues specifically generated from events, we add an event sales report (+ a dashboard with Enterprise).

Task-2654816
Task-2679881
See odoo/upgrade#3118
See odoo/enterprise#24472

closes odoo/odoo#81583

Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
2022-05-31 13:57:26 +02:00
Florian CharlierandJulien Banken 1840656060 [IMP] event_sale: add event revenue reporting
As an event manager, it can be difficult to estimate how much of the revenue
was generated by the events. To give clear insights, we will add new reports
to the 'event' module.

With those new reports, the user can group the revenues by event (type),
ticket, product, etc. The user will then be able to quickly see which tickets
and events are the most profitable ones. The reports will be accessible only if
the user installed the 'sale' module.

Task-2679881
See odoo/enterprise#24472

Part-of: odoo/odoo#81583
Co-authored-by: Florian Charlier <flch@odoo.com>
Co-authored-by: Julien Banken <jbn@odoo.com>
2022-05-31 13:57:25 +02:00
Florian Charlier a0e7f69513 [IMP] event{,_sale}: unstore seat fields
With stored computed seat attributes, the database can be flooded with update
queries for the stored values for the event (ticket) seats computations (such
as reserved, expected, and available seats).
This can especially occur when a communication is sent to many people about
an event with a registration link, many users may want to register at the same
time, possibly resulting in concurrent_update errors.

In this commit, we remove the `store=True` attribute of those fields, and
therefore remove the Reporting/Event feature depending on them and rewrite some
domain searches and _compute fields in the event and event_sale modules.

This also impacts the way constraints are enforced on the number of
registrations vs defined maximum as no stored value is directly available.

For performance reasons, all events and tickets are now shown on backend form
views, with seat availability added in their displayed name.

Misc
To avoid delaying the inevitable, the Event configurator modal/wizard now
validates event/ticket consistency at closing.

The UI of the RegistrationEditor wizard is also improved:
* A warning alert will tell users that free registrations were not confirmed
because of insufficient seat availability.
* A first step to better explain the consequences of the actions taken on the
modal was to be taken, here via the description and buttons wording.

Tests
Query counts are (indeed reduced) and updated. However, as local testing with
`test-tags=/test_event_full` ("tef_only") is currently not reliable, these
values were updated by applying the same change from the commit as the one seen
for the runbots, while a "?" is appended to show this uncertainty.

Task-2654816
See odoo/upgrade#3118

Part-of: odoo/odoo#81583
2022-05-31 13:57:24 +02:00
Louis Wicket (wil) 94db11826e [IMP] mail: add res_users_settings_id field
Add the `res_users_settings_id` field on `res.users` so that it can be
used as a target for relateds that is not a x2many field.

closes odoo/odoo#90015

Related: odoo/upgrade#3479
Related: odoo/enterprise#26287
Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
2022-05-31 12:52:00 +02:00
Louis Wicket (wil) a3f9f345b2 [IMP] mail: add name to a group in res.users.settings view
Add name to a group in res.users.settings view so that it can be used as
a target for overriding.

Part-of: odoo/odoo#90015
2022-05-31 12:52:00 +02:00
Louis Wicket (wil) fde48eca1c [IMP] test_discuss_full: move init_messaging result in its own getter
Move expected init_messaging results in a getter so that it can be
overriden.

Needed for task-2821508 that adds fields to the model
`res.users.settings`, whose the content is returned by init_messaging.

Part-of: odoo/odoo#90015
2022-05-31 12:52:00 +02:00
Patrick Hoste b309200de5 [IMP] event: allows filtering event on address
PURPOSE

This commit allows one to filter the events based on its address

LINKS

Task-2810400

closes odoo/odoo#87678

Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
2022-05-31 12:51:50 +02:00
Jacky (trj) 0e2840aa87 [ADD] pos_hr_restaurant: link between pos_hr and pos_restaurant
Moved the cross behaviors and logics in a new link module. This avoid having to
create hook methods in the `point_of_sale` that needs to be overridden.

closes odoo/odoo#92256

Signed-off-by: Masereel Pierre <pim@odoo.com>
2022-05-31 11:07:08 +02:00
Kevin Baptiste 48f340d885 [IMP] hr_expense: rename default Expense product
Both default expenses product were called Expenses, which was confusing
as it was not possible to distinguish them at first glance.

Here the expense product with a fixed cost is renamed to make it more
clear.

odoo/upgrade#3546

closes odoo/odoo#92232

Taskid: 2862104
Signed-off-by: Kevin Baptiste <kba@odoo.com>
2022-05-31 11:07:02 +02:00
root 4c6a010730 [ADD] mail: quick-open related record from activity
Current behavior before PR: You have to find the right menu/view and then take
over the ID stored on the activity (through export) to find back the record.
This is annoying, painful and error prone.

Desired behavior after PR is merged: By adding a smartbutton the user can
quick-navigate to the related record in a second. This allows for quickly
finding and opening records which is usually handy when debugging things or
finding back related records.

Task-2868230

closes odoo/odoo#91230

Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
2022-05-31 11:06:56 +02:00
root 6d1f9a2000 [ADD] mail: quick-open related record from email
Current behavior before PR: You have to find the right menu/view and then take
over the ID stored on the email to find back the record. This is annoying,
painful and error prone.

Desired behavior after PR is merged: By adding a smartbutton the user can
quick-navigate to the related record in a second. This allows for quickly
finding and opening records which is usually handy when debugging things.

Task-2868230

closes odoo/odoo#91228

Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
2022-05-31 11:06:52 +02:00
Antoine Guenet f9a8072dbf [IMP] web_editor: don't convert little column duos to wrapping columns
This applies the following heuristic when converting from static columns
to stacking, responsive columns: don't do stack duos of columns where
one is very small and the other very big (eg., col-2 col-10). This
doesn't apply when one of the columns in question is host to a
full-width element (as this could cause ugly sizing).

task-2761098

closes odoo/odoo#87962

Signed-off-by: David Monjoie (dmo) <dmo@odoo.com>
2022-05-31 11:06:48 +02:00
Antoine Guenet aa4590f4d9 [FIX] mass_mailing: center header cells on mobile
On mobile, header cells don't always have the space to fit in one line
and end up getting stacked with one aligned to the left and the other
aligned to the right. To avoid this ugly mess, center everything on
mobile.

task-2761098

Part-of: odoo/odoo#87962
2022-05-31 11:06:48 +02:00
Antoine Guenet 63c301ce20 [FIX] web_editor: ensure images don't stretch on responsive resizing
When images get resized, we need to make sure they don't stretch.

task-2761098

Part-of: odoo/odoo#87962
2022-05-31 11:06:48 +02:00
Antoine Guenet 6a9ec78e55 [FIX] mass_mailing, web_editor: ensure proper table dimensions (masonry)
When fixing a row's max-width for responsivity, we need to get the
parent table's width before manipulating it. Failure to do that caused
issues with nested table dimensions. In addition, masonry's maze of
nested tables required some extra styling in order to propagate
alignment.

task-2761098

Part-of: odoo/odoo#87962
2022-05-31 11:06:48 +02:00
Antoine Guenet d6cc70ec72 [FIX] web_editor, mass_mailing: support responsive columns in mailings
Since flexbox is not well supported across e-mail clients, columns were
until now not responsive. This adds support for responsive columns and
a special rendering of them for Outlook so they don't break there.

task-2761098

Part-of: odoo/odoo#87962
2022-05-31 11:06:47 +02:00
Antoine Guenet 756243ecd3 [FIX] web_editor: properly convert Bootstrap buttons for Outlook
Outlook's renderer doesn't understand Bootstrap's styling of buttons we
have a special rendering just for it but its design was suboptimal so
this improves it.

task-2761098

Part-of: odoo/odoo#87962
2022-05-31 11:06:47 +02:00
Antoine Guenet 82e270d998 [FIX] web_editor: propagate text alignment through tables
Outlook doesn't seem to properly read `text-align: inherit` on tables.
This makes them explicit by fetching the alignment of the first ancestor
with an explicit alignment.

task-2761098

Part-of: odoo/odoo#87962
2022-05-31 11:06:46 +02:00
Horacio Tellez 1991306e76 [FIX] event_sale: ticket price is not correctly updated
When using the product configurator for event tickets the
price was not updated when picking a ticket with a different
price.
This of course is to the desired behavior.

This commit makes sure the unit price is correctly
recomputed when the ticket is modified on the SO
line.

Task - 2767301

closes odoo/odoo#85208

Signed-off-by: Victor Feyens (vfe) <vfe@odoo.com>
2022-05-31 11:06:28 +02:00
Xavier BOL (xbo) 3f263f1eae [IMP] project: display milestone field in the tasks in Project Sharing
Before this commit, the external collaborator cannot see in which
milestone the tasks in the project are linked in the Project Sharing
feature.

This commit adds the milestone field in the Project Sharing to show the
milestone linked to a task in the project shared.

task-2829542
2022-05-31 10:29:09 +02:00
Xavier BOL (xbo) 50ffc33999 [IMP] sale_{project,timesheet}: remove 'delivered_milestone' in invoice_policy
Before this commit, when the `Milestones` feature is disable, the user
can always defined a service product with invoice policy equals to
'Based on Milestones' but since the feature is disabled he cannot add
this product on a milestone and so this configuratiom is useless without
the feature.

This commit removes the item into the invoice_policy field Selection
when the feature is disabled. Moreover, when the feature is disabled,
the existing products with this setting should be updated to be a
service product with `invoice_policy='delivered_manual'`. The quantity
delivered method of the existing SOLs containing those products should
also be updated to allow the user to manually edit the quantity
delivered of those SOLs when the `Milestones` feature is disabled.
However, when the `Milestones` feature is enabled again, only the
products contained in SOL linked to a milestone will be updated because
we cannot assume all service products with
`invoice_policy='delivered_manual'` were a service products with invoice
policy based on Milestones. Also the existing SOLs containing the
products updated will not be updated too to not impact the quantity
delivered.

task-2829542
2022-05-31 10:29:09 +02:00
Xavier BOL (xbo) d923f8ae4a [IMP] sale_timesheet: avoid calling filtering before for loop
Before this commit, 2 loops are made, one for the `filtered` method and
another for the for loop with the result of the `filtered`.

This commit avoid using the `filtered` method since all could be done in
the for loop directly.

task-2829542
2022-05-31 10:29:08 +02:00
Xavier BOL (xbo) e058472d21 [IMP] project: display wizard to reach milestone if all tasks linked are done
Before this commit, when the user changes the stage of a task linked to
a milestone, he cannot know if after that task, there is another one
before reaching the milestone related.

This commit displays a wizard to allow the current user to directly
mark as reached the milestone when the user changes the stage of a
task linked to a milestone to a closed stage and all tasks linked to
that milestone are done too. However, if the milestone is already
reached, no wizard will be displayed.

task-2829542
2022-05-31 10:29:08 +02:00
Xavier BOL (xbo) 41b72e0398 [IMP] project: display in green milestone if all tasks linked are done
Before this commit, when all tasks linked to the milestone are done, it
means all tasks are in a closed stage. Then, the user has no visual
feedback to know if all tasks linked to the milestone are done to be
sure he can mark the milestone has reached without missing a task to
complete.

This commit checks if all tasks of unreached milestones shown in the
project update are done or not. If it is the case the milestone is
greened to show to the user that milestone can be marked as reached.

task-2829542
2022-05-31 10:29:08 +02:00
Xavier BOL (xbo) c1feb0deaf [IMP] sale_project: get the SOL from the milestone to task if no SOL found
Before this commit, the compute of `sale_line_id` field searches a SOL
to set to each task containing in `self` as default value for
`sale_line_id`. If no SOL is found in the parent task or the project set
into the task then no SOL will set. Since a milestone can be set to a
task and a milestone can have a SOL set in its model, the task could
have the one of the milestone if no SOL is found.

This commit sets the SOL from the milestone to the task if no SOL is
found in the project or the parent task related to that task.

task-2829542
2022-05-31 10:29:08 +02:00
Xavier BOL (xbo) d128a7683b [IMP] project: add 'Late Milestone' filter in tasks
Before this commit, the milestone is displayed in red in project update
when its deadline is in the past. To display the tasks containing a late
milestone, a filter need to be added.

This commit adds this filter to display the tasks containing a milestone
with a deadline in the past. This filter is also added in the `Tasks
Analysis` and the `Burndown Chart` reports.

task-2829542
2022-05-31 10:29:08 +02:00
Xavier BOL (xbo) a118555a40 [IMP] project: link milestone to task
Before this commit, the milestones are only linked to a project without
any link to the tasks of the same project. However, the tasks could be
considered as steps to reach a project milestone.

This commit adds a link between the `project.task` and
`project.milestone` models. This link is added in the `project.task`
model with the Many2One field called `milestone_id`. With this field,
the user will be able to link a milestone to a task.

task-2829542
2022-05-31 10:29:08 +02:00
Rémi RahirandLucas Lefèvre d090d449d5 [FIX] web: mocked name_get should return "" instead of "False"
Since 43474916 and ff37a2fe, the function `name_get` now returns an
empty string for missing records. This change was not reflected in
mockServer.

This commit also copies the tests of `name_get` on  the legacy mockServer
to the "new" one. They were missing.

closes odoo/odoo#92473

X-original-commit: 638fab65cdf7a615138dee1395f54224b3ea1e77
Signed-off-by: Lucas Lefèvre (lul) <lul@odoo.com>
Signed-off-by: Rémi Rahir (rar) <rar@odoo.com>
Co-authored-by: Lucas Lefèvre <lul@odoo.com>
2022-05-31 10:04:17 +02:00
Ivan Yelizariev 09417b6ae0 [FIX] product: disable company creation via list view
List of companies is a quite delicate configuration, which must be done by Admin
via`Settings > Companies` menu. Inline creation should be always disabled for
`company_id` field. Few such cases were presented probably because of
ambiguous setting name `no_create_edit`: it disabled "Create & Edit" button, but not
"Create" button.

STEPS:

-Go to Sales -> Products and go to the List view.
-Select one Product and try to change their Company
-You'll be able create a new company.

opw-2861853

closes odoo/odoo#92453

X-original-commit: 73e6d2250b2bf15d757f0333f8f014bd8a9895cb
Signed-off-by: Nicolas Lempereur (nle) <nle@odoo.com>
Signed-off-by: Ivan Elizaryev (iel) <iel@odoo.com>
2022-05-31 10:04:07 +02:00
Audric Onockx (auon) fd521e8d39 [FIX] project : allow to continue recurrence
This fix corrects the error committed in a previous fix :
https://github.com/odoo/odoo/pull/85209

closes odoo/odoo#92381

X-original-commit: d6bff1a9ccfc52adf98dbbf5c9c56c4a1a4fb3e8
Signed-off-by: Xavier <xbo@odoo.com>
2022-05-31 09:06:18 +02:00
Florian Damhaut 073540c132 [FIX] project: use website lang for portal sharing view
Step to reproduce:
- Have a least 2 lang with portal lang set to langA
- Log in as portal user
- In portal change lang to langB
- Go to portal sharing view

Current behaviour:
- Iframe does not get info from the request and use the user's
 lang

Behaviour after PR:
- If there is a lang set on the website (in url) we use this one
instead.

closes odoo/odoo#92459

X-original-commit: 8c8cc52479132a91a2abd7592d589835798c3a49
Signed-off-by: Laurent Stukkens (ltu) <ltu@odoo.com>
2022-05-30 22:49:32 +02:00
Carlos Valverde 37af093d2a [REF] o-autogrow scss refactoring
This commit deletes the class `o-autogrow` and replaces each instance of
it with a global Bootstrap class.

Task-2833725

closes odoo/odoo#89714

Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
2022-05-30 21:45:13 +02:00
Alexandre Kühn 71d56c9ffe [MOV] mail: rename RTC models (step 1)
- rename 'RtcController' to 'CallActionListView'
- rename 'RtcOptionList' to 'CallOptionMenu'
- rename 'RtcInvitationCard' to 'CallInviteRequestPopup'
- rename 'RtcInvitations' to 'CallInviteRequestPopupList'
- rename 'RtcVideo' to 'CallParticipantVideo'

Task-2867786

closes odoo/odoo#92463

Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
2022-05-30 20:43:48 +02:00
Alexandre Kühn cb53260afb [IMP] mail: rename RTC models (step 1)
- rename 'RtcController' to 'CallActionListView'
- rename 'RtcOptionList' to 'CallOptionMenu'
- rename 'RtcInvitationCard' to 'CallInviteRequestPopup'
- rename 'RtcInvitations' to 'CallInviteRequestPopupList'
- rename 'RtcVideo' to 'CallParticipantVideo'

Task-2867786

Part-of: odoo/odoo#92463
2022-05-30 20:43:48 +02:00
Nasreddin Boulif (bon) d8760bf21f Cherry pick of dc8dac3e0f004f2d2569fb2bcf780a4b0669d23f failed
stdout:

stderr:
15:07:24.803999 git.c:344               trace: built-in: git cherry-pick dc8dac3e0f004f2d2569fb2bcf780a4b0669d23f
error: could not apply dc8dac3e0f0... [FIX] website_sale_stock: use website warehouse on sale order
hint: after resolving the conflicts, mark the corrected paths
hint: with 'git add <paths>' or 'git rm <paths>'
hint: and commit the result with 'git commit'
----------
status:

closes odoo/odoo#92461

X-original-commit: d47b845faeda716a3a943fc4aff6c90a86d26b70
Signed-off-by: William Braeckman (wbr) <wbr@odoo.com>
2022-05-30 20:43:42 +02:00
Trinh Duc Do 945e409bf4 [FIX] sale: remove duplicate product records
closes odoo/odoo#92384

Signed-off-by: Victor Feyens (vfe) <vfe@odoo.com>
2022-05-30 19:41:00 +02:00