Commit Graph
151129 Commits
Author SHA1 Message Date
JF Aubert fcc7b3d46a IMP] mrp: add workcenter capacity per product
Allow workcenter capacities based on product instead of
applying the same capacity for all.

closes odoo/odoo#87131

Task: 2691328
Related: odoo/enterprise#25532
Related: odoo/upgrade#3370
Signed-off-by: William Henrotin (whe) <whe@odoo.com>
2022-06-03 16:40:09 +02:00
JF Aubert bb5805542a [IMP] mrp,mrp_workorder: add progress bar to workorder gantt view
Add work center planned time vs operating time, on hover.
And percentage as progress bar.

Task: 2691328
Part-of: odoo/odoo#87131
2022-06-03 16:40:09 +02:00
JF Aubert dbd09f16a2 [IMP] mrp,mrp_workorder: workorder scheduling revamp
Currently MRP only allows sequential scheduling of work orders.

This commit allows to specify the dependencies for work orders to be
scheduled in parallel or in a complex diagram.

By enabling the feature in the settings and at the bom level,
you can specify dependencies between operations:
on the operation form, select the operations on which the
current one depends.

The dependencies will be reflected in work orders during planning.

The workorders Gantt view has been adapted for you to visualize
and manipulate the dependencies.

Please note:
- work orders without predecessors will be started first
- they can all be done in parallel
- when all work orders of this step are finished, their successors
  will start
- and so on, step by step

Also, with the feature activated at the bom level and no dependency,
the parallel scheme will be applied (all operations at first step).

Finally, without activation at the bom level, the dependencies will
be created in order to satisfy the current sequential model.

Task: 2691328
Part-of: odoo/odoo#87131
2022-06-03 16:40:08 +02:00
Joseph Caburnay fa111d449d [IMP] point_of_sale,*pos*: configure pos from general settings
Purpose:

- Move PoS settings in general settings to be consistent with the rest
  of Odoo (PoS being the only app where settings are split in two locations)
- Clean settings by enabling obvious settings or dropping unnecessary ones.

closes odoo/odoo#84719

Task-id: 2753430
Related: odoo/upgrade#3260
Related: odoo/enterprise#24425
Signed-off-by: Masereel Pierre <pim@odoo.com>
2022-06-03 16:39:51 +02:00
Joseph Caburnay b0b75575a0 [IMP] point_of_sale: do not reload when module is installed
When a module corresponding to a pos.config field is already
installed, do not reload the page.

Part-of: odoo/odoo#84719
2022-06-03 16:39:51 +02:00
Eleftherios Kritsotakis b0ea01ff1e [FIX] pos_loyalty: properly load loyalty_points for all partners
Before this commit, the loyalty_points field, neccessary to
implement the loyalty functionality in PoS in offline mode,
was only loaded properly for the partners at the start of
a PoS session.

After this commit, the loyalty_points are loaded properly for
every partner throughout the duration of the session, including
those that are loaded in the background or fetched when using
the search bar, which was not the case before.

Part-of: odoo/odoo#84719
2022-06-03 16:39:51 +02:00
Eleftherios Kritsotakis 602acc4801 [FIX] pos_loyalty: load reward products
Before this commit, if the config setting
limited_products_loading was activated,
some reward products might not get loaded
in the frontend. So the UI crashed whenever a
reward product was accessed.

In this commit we force-load all the reward products
at the start of session, regardless of the number of
loaded products (loading_products_amount)

Part-of: odoo/odoo#84719
2022-06-03 16:39:50 +02:00
Eleftherios Kritsotakis 891bd99299 [FIX] pos_loyalty: consider falsy query case
When limited_products_amout is 0, query is an
empty list. In this case, we do not need to
modify the result further, so we return it
as is.

Part-of: odoo/odoo#84719
2022-06-03 16:39:49 +02:00
Umesh Gupta e58f864fd7 [FIX] knowledge: unarchive multiple articles
Currently, when we unarchive a single article, it works properly by
making it active again and redirecting user to that article. But
when we try to unarchive multiple articles, it throws traceback.

This commit fixes the issue by properly handling the action for
unarchiving, which now will simply reload the same action in
case of multiple articles. Note that behavior for unarchiving
single article is still the same.

taskID-2869659

closes odoo/odoo#92851

Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
2022-06-03 14:36:46 +02:00
Nicolas (vin) d83ce882b8 [IMP] account: journal audit report improvement.
Improve the tax report section of the journal audit by adding a
background color to it, as well as reducing the width of the tables.
Ease the navigation from the journal audit report by adding three
new actions:
    - Taxes in the tax applied section can be clicked to audit them
    - The tax applied and the impacted tax grid sections now have an
      audit button to open a group-by view of journal items grouped
      appropriately according to the information we need.

closes odoo/odoo#92846

Related: odoo/enterprise#28025
Signed-off-by: Quentin De Paoli <qdp@odoo.com>
2022-06-03 14:36:39 +02:00
Kevin Baptiste 08588f7cc7 [IMP] hr_holidays: hide archived time off from analysis report
The "Time Off Analysis" report was showing Archived (aka canceled) time
off, which was confusing/misleading.

closes odoo/odoo#92778

Taskid: 2864419
Signed-off-by: Kevin Baptiste <kba@odoo.com>
2022-06-03 13:07:02 +02:00
Kevin Baptiste a2d22373fd [IMP] hr: make Plan department dependent
Plans can be available for a specific department or global for the
company.

closes odoo/odoo#92648

Taskid: 2868447
Signed-off-by: Kevin Baptiste <kba@odoo.com>
2022-06-03 13:06:59 +02:00
Fabio Barbero 5d71064d03 [FIX] knowledge: allow portal users to click on articles
Purpose
=======
Properly compute portal_readonly_mode to also take into account portal
users, so the template is properly rendered for them.

closes odoo/odoo#92850

Signed-off-by: Warnon Aurélien (awa) <awa@odoo.com>
2022-06-03 12:02:39 +02:00
dbkosky 037c0a6e31 [FIX] l10n_it_edi_sdicoop: empty invoice company
When the cron is fetching the xml from the database, an empty invoice
with the xml as an attachment is created. The reason for this is so
that, if the import fails, there is at least a file accessible on the
invoice for the purposes of debugging.

When the cron's fetching function loops through the proxy users for each
company, fetching the results from the proxy server for each company in
turn. However when the empty invoice is created, the company is not
provided, and thus the context company is used (that of the cron), which
is not necessarily correct. This commit uses the company of the proxy to
create the empty invoice (which in turn selects the correct journal etc.
for the empty invoice).

closes odoo/odoo#92830

Ticket-id: 2854284
X-original-commit: a19cdf82f3276f84fba2961fbd82a5a1a2f7844e
Signed-off-by: Josse Colpaert <jco@odoo.com>
Signed-off-by: Daniel Kosky (dako) <dako@odoo.com>
2022-06-03 12:02:32 +02:00
Touati Djamel (otd) 74526ff1c7 [FIX] product: add the product’s company to the context
Steps to reproduce the bug:
- Enable “Product Packagings” in the settings
- Create a storable product
- Set the company field
- Go to the inventory tab:
    - Click on add packaging

Problem
The company field is not set automatically

opw-2864554

closes odoo/odoo#92826

X-original-commit: 79223022e79a95c9c1f7d6307c48866a0f9a13ef
Signed-off-by: William Henrotin (whe) <whe@odoo.com>
Signed-off-by: Djamel Touati (otd) <otd@odoo.com>
2022-06-03 12:02:28 +02:00
roen-odoo 75211a4557 [FIX] point_of_sale: prevent crash with float quantity when edit lot
Current behavior:
In the PoS if you add a tracked product that uses "kg" as uom
and change the quantity to any float value. After that if you try
to modify the lot number you get an error.

Steps to reproduce:
- Have PoS installed
- Create a tracked product that use kg as uom
- Open PoS session
- Add the product to the order and modify the quantity to any float
  value
- Click on the green lines to edit the lot number
- You get an error

opw-2861426

[FIX] point_of_sale: float_serial

Current behavior:

Steps to reproduce:

opw-2861426

closes odoo/odoo#92722

X-original-commit: 0aff8bb9484a23c0d875d3b12259dd4e0d51e716
Signed-off-by: Nicolas Lempereur (nle) <nle@odoo.com>
Signed-off-by: Engels Robin (roen) <roen@odoo.com>
2022-06-03 12:02:21 +02:00
Leonardo Pavan Rocha 4e62c2847f [FIX] sale: remove click auto tour step
In the sale_signature tour, there was a step for entering auto mode when
signing for a payment. Since now the auto mode is selected by default,
it's not necessary to set it anymore.

task-2862209

closes odoo/odoo#92340

Related: odoo/enterprise#27793
Signed-off-by: Arnaud Joset <arj@odoo.com>
2022-06-03 12:02:17 +02:00
Leonardo Pavan Rocha 2ac2d5ef1f [IMP] sign: makes automatic signature default
In order to make the process of signing faster, automatic mode should be the
default one. This commit implements this behavior and adds tests for it.

task-2862209

Part-of: odoo/odoo#92340
2022-06-03 12:02:17 +02:00
Odoo's Mergebot d18a8f9339 [IMP] stock, purchase, sale: inventory back to basics
Applies various small changes:

- [IMP] stock, stock_account: add dates to stock move name (inventory adjustments)
- [IMP] delivery,stock: add pack type weight
- [IMP] {purchase, sale}_stock: add Incoterm Location field
- [IMP] stock_picking_batch: default show Batch Transfer
- [IMP] purchase: add supplier info with sudo qty 1
- [IMP] sale_purchase: add related PO warning
- [FIX] product: order product labels by product
- [IMP] product: default filter vendor pricelist w/ active products
- [IMP] stock: relax picking locations readonly states
- [IMP] stock: add consumables replenish button
- [IMP] stock_picking_batch: pick type auto batch not active by default
- [IMP] stock: add stock quant import template
- [FIX] sale,stock,mrp,purchase: add uom precision

Task Id: 2764771
COM PR: odoo/odoo#91640

--
I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr

Signed-off-by: Tiffany Chang <tic@odoo.com>
2022-06-03 12:02:09 +02:00
Ahmed Khalaf (ahkh) ae76ba4386 [FIX] sale,stock,mrp,purchase: added uom precision
Task: 2764771
Part-of: odoo/odoo#91640
2022-06-03 12:02:08 +02:00
Ahmed Khalaf (ahkh) db810d14be [IMP] stock: stock quant import template
Task: 2764771
Part-of: odoo/odoo#91640
2022-06-03 12:02:08 +02:00
Ahmed Khalaf (ahkh) 80a52dfbbc [IMP] stock_picking_batch: pick type auto batch inactive
auto batch in picking type is now set inactive by default

Task: 2764771
Part-of: odoo/odoo#91640
2022-06-03 12:02:07 +02:00
Ahmed Khalaf (ahkh) 85dc26e2ff [IMP] stock: replenish consumables
Product of type consumable can now be replenished

Task: 2764771
Part-of: odoo/odoo#91640
2022-06-03 12:02:07 +02:00
Ahmed Khalaf (ahkh) 30bc765271 [IMP] stock: edit picking locations
stock picking source and destination locations are editable until done state

Task: 2764771
Part-of: odoo/odoo#91640
2022-06-03 12:02:07 +02:00
Ahmed Khalaf(ahkh) cd40bad675 [IMP] product: vendor pricelist default filter active products
Task: 2764771
Part-of: odoo/odoo#91640
2022-06-03 12:02:07 +02:00
Ahmed Khalaf(ahkh) fc692e5f9c [FIX] product: Ordered printing product labels
Product labels are now printed by name order

Task: 2764771
Part-of: odoo/odoo#91640
2022-06-03 12:02:06 +02:00
Ahmed Khalaf(ahkh) f3571331e5 [IMP] sale_purchase: warning message added
When cancelling SO with a related PO a warning message is added
to warn the user to cancel the PO manually

Task: 2764771
Part-of: odoo/odoo#91640
2022-06-03 12:02:06 +02:00
Ahmed Khalaf(ahkh) 3b88ed5ea4 [IMP] purchase: Supplier info added with sudo qty 1
This commit contains the following:
1) Added sudo to product record when adding supplier info during PO confirm, so that
supplier info is created regardless of who is confirming the PO.

2) the test test_multicompany_partner_bank was removed since it was creating two
res partner banks with the same partner and setting company_id to two seperate companies
while currently the company_id is related to the company partner thus this can no longer
happen.

3) test_message_qty_already_received was changed to not set the company_id explicitly as
it caused unexpected cache miss in the runbot.

task : 2764771

Part-of: odoo/odoo#91640
2022-06-03 12:02:06 +02:00
Ahmed Khalaf(ahkh) d5bf927bf9 [IMP] stock_picking_batch: Show Batch Transfer
set batch transfer in account move line to optional show

Task: 2764771
Part-of: odoo/odoo#91640
2022-06-03 12:02:05 +02:00
Ahmed Khalaf(ahkh) 7253130cb1 [IMP] {purchase, sale}_stock: Incoterm Location field
Added Incoterm Location field in SO and PO forms and reports

Task: 2764771
Part-of: odoo/odoo#91640
2022-06-03 12:02:05 +02:00
Ahmed Khalaf(ahkh) 42714e2202 [IMP] delivery,stock: added pack type weight
Base Weight field added to Package type to be added to shipping weight

Task: 2764771
Part-of: odoo/odoo#91640
2022-06-03 12:02:05 +02:00
Ahmed Khalaf(ahkh) 9c46e2ba95 [IMP] stock, stock_account: dates added to stock move name
Scheduled date and accounting date added to stock move name

Task: 2764771
Part-of: odoo/odoo#91640
2022-06-03 12:02:04 +02:00
Yolann Sabaux dd1d758476 [FIX] stock: hot key for "put in pack"
Steps to reproduce:
just be sure you activate "packages" from the Inventory settings and you can find that button on a picking. Inventory dash > Operations > Transfers > Form view

Solution:
Add the hotkey

The choice has been made as following:
- not used in stock.picking
- used in other models
 https://docs.google.com/spreadsheets/d/1QIPwUiEDv37H1P_FjN-WctzPey2Niu6K5dCL157Z8BY/edit#gid=0

opw-2858629

closes odoo/odoo#92838

X-original-commit: 73ab94402878a16c34c0e131818ffc0d2e8da3da
Signed-off-by: Adrien Widart <awt@odoo.com>
Signed-off-by: yosa-odoo <yosa@odoo.com>
2022-06-03 09:46:50 +02:00
Arnaud Joset fe2be46214 [FIX] google_calendar: remove dead code
The _sync_google_calendar method was copied in https://github.com/odoo/odoo/commit/24c2d7e9d609f02b1814be0faf82352bfeb45d96
in the google.calendar.credentials model from res.users but it was not useful
or used. This method makes more sense on res.users model.

closes odoo/odoo#92835

X-original-commit: f78431507ec9a5e2d9f1d2847d723e1f7bfeca11
Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
Signed-off-by: Arnaud Joset <arj@odoo.com>
2022-06-03 09:46:46 +02:00
alt-odooandava-odoo 9ae8d07b35 [FIX] portal: prevent traceback if no subtype set on message
This is a small fixup of a recent commit [1].

If no subtype is set on one message read, we should correctly return
False and not a TypeError.

[1]:https://github.com/odoo/odoo/commit/f74434c6f4303650e886d99fb950c763f2d4cc6e

closes odoo/odoo#92843

X-original-commit: 5020f6eb91f2c84eaaa4ba65f5a25ae8f04820a0
Signed-off-by: Warnon Aurélien (awa) <awa@odoo.com>
Signed-off-by: Alex Thuyls (alt) <alt@odoo.com>
Co-authored-by: ava-odoo <awa@odoo.com>
2022-06-03 07:22:46 +02:00
aliya 4fa0d275ad [IMP] account: change date for calculating the currency exchange
Currently, the currency conversion rate used is based on the accounting date on invoices and bills.
According to partner feedback and the official documentation we should use the exchange rate on the invoice/bill date.
Moves that are not invoices or bills should still use the accounting date.

closes odoo/odoo#87984

Task: 2807136
Signed-off-by: Quentin De Paoli <qdp@odoo.com>
2022-06-02 23:21:52 +02:00
Géry Debongnie 87ed548bc9 [FIX] base_import: properly display controlpanel buttons
Problem: open any (multi record) view, open the "favorites" menu and
select the import action. The import client action now opens, but no
button is visible in the control panel.

Since a recent owl update, the import client action did not display its
control panel buttons (upload file, cancel, ...). This is caused by an
unfortunate situation: the control panel buttons are rendered, but after
the control panel was rendered, so owl does not add them in the DOM.  It
worked by chance before: the props were completely reactive, and the
code actually modifies in place some object received in props. So, a
render was forced on the controlpanel, which means that it properly
picked up the buttons.

Now, this render was accidental, so the new owl code is actually
correct. This commit fixes the issue by simply rendering the buttons
before the controlpanel is even rendered, so it now works as expected.

closes odoo/odoo#92810

X-original-commit: f185f543452abf65b9948e907aeb45e918cf3bed
Signed-off-by: Lucas Perais (lpe) <lpe@odoo.com>
Signed-off-by: Géry Debongnie <ged@odoo.com>
2022-06-02 21:45:27 +02:00
Yolann Sabaux 0c9c9304b3 [FIX] account: correct regex extraction reconciliation
Steps to repdroduce:
- In Reconciliation Models create a new rule
- Add two new lines with a "From Label" type and respectively set the "Amount" field to:
Koerperschaftst.{5,10}\s([\d\,\.]+)
Solid.Zuschl.KSt.{5,10}\s([\d\,\.]+)
- Change the "Decimal Separator" to a comma ","
- In Bank statement, create a new one with the following label:
Stnr 330/5707/3700 Koerperschaftst. 1.Vj.22 1.250,00 Solid.Zuschl.KSt 1.Vj.22 50,00 - FOLGELASTSCHRIFT
- Reoncile by using the button corresponding to the new rule

Issue:
-> "1.250,00" won't extracted contrarily to the "50,00"

Cause:
In:  https://github.com/odoo/odoo/blob/affdd8d6276cb3c3aea9b994fa2427a6e97de691/addons/account/models/account_reconcile_model.py#L353
Our scenario: float("1.250.00") -> will throw an error

Solution:
Clean the match group to only keep the numebers and the decimal_separator

opw-2794209

closes odoo/odoo#92827

X-original-commit: d4da8be3669fbfdfdcad752af1f0311accaf34a3
Signed-off-by: William André (wan) <wan@odoo.com>
2022-06-02 20:46:46 +02:00
Benoit Socias cb6bb3f8f2 [FIX] website: wait for steps to be effective in social media test
Could not actually reproduce problem locally.

Looking at the logs, the randomly failing tests seem to be related to
the effects of some previous steps not having been applied even though
the test did proceed further.

This commit introduces intermediary checks to make sure that the effect
of each step is fully applied before proceeding to the next one.

runbot-3171
runbot-3172
runbot-3629
runbot-3630
runbot-3778
runbot-3779
runbot-3859
runbot-3860

closes odoo/odoo#92816

X-original-commit: 2d47b78e677f5046214cb2c8613eeb510753076d
Signed-off-by: Romain Derie (rde) <rde@odoo.com>
2022-06-02 18:58:54 +02:00
Julien Castiaux ad4e528dee [FIX] test_http: missing import
Fine-tunning of da8def8

closes odoo/odoo#92775

Signed-off-by: Julien Castiaux <juc@odoo.com>
2022-06-02 18:58:51 +02:00
Romain Derie dcf79f01b3 [IMP] website_sale: add name to template for enterprise xpath
See enterprise counterpart, we need a way to extend this template.

closes odoo/odoo#92808

Related: odoo/enterprise#27911
Signed-off-by: Romain Derie (rde) <rde@odoo.com>
2022-06-02 18:58:44 +02:00
Nemael 9830406020 [IMP] mail: introduce EmojiView model
Task-2365687

closes odoo/odoo#92485

Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
2022-06-02 18:58:36 +02:00
Nemael 03dc1bed08 [IMP] mail: introduce Emoji model
Task-2365687

Part-of: odoo/odoo#92485
2022-06-02 18:58:36 +02:00
Alexandre Kühn 299138350d [IMP] mail: introduce ChannelMemberListCategoryView
Task-2831082

closes odoo/odoo#91699

Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
2022-06-02 18:58:31 +02:00
Sébastien Theys 22f52f3700 [IMP] mail: avoid storing model manager in scope that are not cleaned
This will reduce memory leak size in tests. But the proper fix should be lower
level in the code (probably in Owl according to the stack) to ensure unnecessary
references aren't kept anymore.

Part of task-2850875

closes odoo/odoo#90934

Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
2022-06-02 18:58:27 +02:00
Sébastien Theys 44c4e5b3d0 [IMP] mail: properly destroy bus and messaging service in tests
This will reduce memory leaks in tests.
Indeed `destroy` is not a standard service method, it must be called manually.

And references to messaging service were unnecessarily kept in env.

Note: ideally everything should be cleaned this way, not just messaging code.
In other words, env itself should have no retainers at the end of each test, but
completely removing all of them is a much bigger work that is outside of the
scope of this PR.

Part of task-2850875

Part-of: odoo/odoo#90934
2022-06-02 18:58:27 +02:00
Sébastien Theys 094df7528e [IMP] mail: completely clean records after deletion
This will reduce memory leaks.

Side-effect of this PR:

Accessing a field after the record is deleting is no longer supported. It was
never meant to be, but some async code relied on this behavior to check the
(non-)existence of relation fields, with an implicit check on the current record
existence.

-> After this PR, the existence check of current record needs to be explicit,
before accessing any field.

Part of task-2850875

Part-of: odoo/odoo#90934
2022-06-02 18:58:27 +02:00
Raouf 83760b9f10 [IMP] project: improve ux
Before this committ:
- Stats buttons were hidden when records are zero
- Some wordings were insignificant
- Existing filters don't allow us to check blocked, blocking and tasks soon in overtime and some other information
- Product form fields need some changes in their order

After this commit:
- All stats button are displayed when records are zero
- Wordings fixed
- New filters added to check blocked, blocking tasks and tasks in overtime soon
- Fields were rearanged

task-2726465

closes odoo/odoo#82253

Related: odoo/enterprise#23257
Related: odoo/upgrade#3185
Signed-off-by: Laurent Stukkens (ltu) <ltu@odoo.com>
2022-06-02 18:58:14 +02:00
Eleftherios Kritsotakis ca200e2ba5 [IMP] point_of_sale: disable backend querying when all items loaded
In this commit, we improve the load-in-the-background
feature of partners/products.

If there are items that are not loaded yet, (either because the
background loading is still running or because the user did not
want to load any prodcts at all at the start of the session)
the option to fetch items from the database is enabled: every
time the user interacts with the search bar (pressing "Enter",
"Search database" or the "Search" icon at the search bar) the
backend is queried and new items (products/partners) are fetched
and added to the frontend. Before the fetching of products from
the backend was done using the "database" icon / "Load Customers"
button which are now dropped.

In this commit, the feature of querrying the database
is automatically disabled once all the partners or
products (available_in_pos) have been loaded in PoS.
Then, the querying of the backend stops.

task-2755384

closes odoo/odoo#81226

Related: odoo/enterprise#23544
Signed-off-by: Masereel Pierre <pim@odoo.com>
2022-06-02 18:58:07 +02:00
Eleftherios Kritsotakis 4dd7416ab8 [FIX] point_of_sale: center align Notification for all screens
Before this commit, the toast Notification would apprear
center aligned only for some screen sizes. In this commit
we adjust it so that is displays properly for any screen
size.

task-2669747

Part-of: odoo/odoo#81226
2022-06-02 18:58:07 +02:00