Commit Graph
127209 Commits
Author SHA1 Message Date
Olivier Colson b29c8d4dd9 [FIX] l10n_ae: avoid duplicate tag names in tax report
Having duplicate tag names is bad for usability, as the user will ne be able to differenciate between tags when performing tax configuration.
2019-07-29 11:37:35 +00:00
Olivier Colson 710c2b91b4 [FIX] l10n_de: reintroduce view, removed by mistake
closes odoo/odoo#35224

Signed-off-by: Laurent Smet <smetl@users.noreply.github.com>
2019-08-02 23:07:22 +00:00
Olivier Colson f5653603a5 [FIX] l10n_de: fix reference to an old field in tax form 2019-08-02 23:07:22 +00:00
Olivier Colson 333c22edd9 [FIX] l10n_*: fix taxes repartition so that 12.3 matches what is defined in 12.2
[IMP] l10n_*: don't define accounts or tags on tax repartition line templates anymore for 0% taxes

[FIX] account: remove old function used to migrate the former tax model, incompatible with the new one
2019-08-02 23:07:22 +00:00
Laurent Smet 3efefd2171 [FIX] l10n_mx: Reintroduce missing tag for CFDI
closes odoo/odoo#35101

Signed-off-by: oco-odoo <oco-odoo@users.noreply.github.com>
2019-08-01 08:50:00 +00:00
jem-odoo ed4d14a31b [FIX] account: analytic lines access with timesheet manager
When validating a invoice, the billing user should have access (read) for all analytic
lines. A problem appears when timesheet is installed, since there is a mismatch with
ir.rule (a timesheet is an analytic line with a project set).
The rule "account.analytic.line.billing.user" already exists for this problem, but should
be extended to work in any case.

To reproduce:
- set a user as timesheet manager and billing user
- try to validate an invoice (or post an expense)
- got an access error with "account.analytic.line.timesheet.manager"

opw-2041615

closes odoo/odoo#35297

Signed-off-by: Jérome Maes (jem) <jem@openerp.com>
2019-07-30 12:59:20 +00:00
Mathieu Duckerts-Antoine 1631c9dbc9 [FIX] web: date filter options unselected after facet deletion
Select the option 'This Month' of a date filter
in the filter menu and then remove the facet created
correctly toggles the filter from the query but the
option is still shown as selected. This commit fixes
that situation.

closes odoo/odoo#35340

Signed-off-by: VincentSchippefilt <VincentSchippefilt@users.noreply.github.com>
2019-07-31 12:35:48 +00:00
Olivier Colson cfe2ee9341 [FIX] l10n_do: use the right sign on every tax tags
Some signs had been inverted when converting from 12.2 to 12.3 model.

closes odoo/odoo#34817

Signed-off-by: Laurent Smet <smetl@users.noreply.github.com>
2019-07-12 09:10:30 +00:00
Olivier Colson 9a09388618 [FIX] l10n_et: fix tags of some taxes (for consistency with 12.2 reports)
closes odoo/odoo#34829

Signed-off-by: Laurent Smet <smetl@users.noreply.github.com>
2019-07-12 11:24:14 +00:00
Mathieu Duckerts-Antoine 3184059071 [FIX] web: no forced date matching in pie charts
In a graph view in mode 'pie', a matching of dates was
attempted each time a comparison and a grouping of data
using the same date/datetime field was done.
Unfortunately, since the read groups results are ordered using
the order of groupbys, the matching was not sensible in case
the date/datetime field was not the first groupby.
We thus restrict the matching to the sole case where it is
sensible. More work should be done to have sensible matchings
in all situations.

closes odoo/odoo#34379

Signed-off-by: VincentSchippefilt <VincentSchippefilt@users.noreply.github.com>
2019-07-16 07:55:04 +00:00
Mathieu Duckerts-Antoine 6ef6881a12 [FIX] web: style chart elements in graph views only locally
The elements style was set globally and thus used to modify
the style of any chart in Odoo after the first loading of a
graph view. For instance, the charts drawn in
sale_subscription_dashboard are not the same before and after
the first loading of a graph view. This is fixed by this
commit.
2019-07-16 07:55:04 +00:00
Mathieu Duckerts-Antoine a87cbcadbc [FIX] web: appropriate symbol in mobile embedded graph view groupby menu 2019-07-16 07:55:04 +00:00
Thomas Werland 150bd2b948 [FIX] web: fix Groupby menu style in embedded graph views 2019-07-16 07:55:04 +00:00
Vincent Schippefilt ba1f4dc381 [FIX] web: fix error when image field can't load image
when image field cannot load an image, it will default to the placeholder image.
If this placeholder image also cannot be loaded it was creating an infinite loop errors

After this commit, we only show one error if the original image cannot be downloaded
and if the placeholder cannot be downloaded, we don't show anything else.

closes odoo/odoo#35226

Signed-off-by: VincentSchippefilt <VincentSchippefilt@users.noreply.github.com>
2019-07-29 09:24:18 +00:00
Odoo Translation Bot 56f74a63be [I18N] Update translation terms from Transifex 2019-07-28 06:08:27 +02:00
Christophe Simonis 40e8b67179 [FIX] mail: add missing requirement in test
Oversight of previous forward-port.
2019-07-26 14:34:48 +02:00
Christophe Simonis e0f9c092cc [MERGE] forward port branch saas-12.2 up to 1d6d790513 2019-07-26 11:32:43 +02:00
Christophe Simonis 1d6d790513 [FIX] mail: adapt test to new version
Oversight of previous forward-port.
2019-07-26 10:36:18 +02:00
Christophe Simonis a4b1b532ea [MERGE] forward port branch 12.0 up to b82df99d7a 2019-07-25 20:01:05 +02:00
Christophe Simonis b82df99d7a [MERGE] forward port branch saas-11.3 up to 5f419d4ad3 2019-07-25 18:38:32 +02:00
Christophe Simonis 7702d07d39 [FIX] base: force user's group view update when deleting a module category
On the users' view, groups are shown grouped by application (module category).
Deleting a module category should, therefore, regenerate the view.

closes odoo/odoo#35181

Signed-off-by: Christophe Simonis <chs@odoo.com>
2019-07-25 14:21:53 +00:00
Christophe Simonis 5f419d4ad3 [MERGE] forward port branch 11.0 up to f2f24381f2 2019-07-25 16:12:08 +02:00
Géry Debongnie 7d78795f8b [FIX] web: properly handle (grouped list) pager
when last field is numeric

closes odoo/odoo#35176

Signed-off-by: VincentSchippefilt <VincentSchippefilt@users.noreply.github.com>
2019-07-25 12:23:51 +00:00
Christophe Simonis f2f24381f2 [MERGE] forward port branch saas-15 up to d649cab7b9 2019-07-25 11:43:19 +02:00
Christophe Simonis d649cab7b9 [MERGE] forward port branch saas-14 up to 39de3797f8 2019-07-25 11:42:01 +02:00
Christophe Simonis 39de3797f8 [MERGE] forward port branch 10.0 up to cb3bf5509f 2019-07-25 11:41:33 +02:00
Nans Lefebvre 7b22be4814 [FIX] account: restore standard composer behaviour when sending unique mails
Fine-tuning of commit 5621ae3d6b.
While it focused on fixing the 'mass_mail' mode,
it forgot to keep the correct behaviour for the case where only one mail is sent.
In the latter case, it is typical to overwrite the template values, especially
for the body, before sending the mail.
In that case, applying the onchange on the templates overwrites the user input.

Note that in the case where the template is undefined it would set the composer
values to empty ones; while standard use would not allow in mass mail to both
send content and have no template, it could be done via a customisation.

opw 2041631

closes odoo/odoo#35164

Signed-off-by: Nans Lefebvre (len) <len@odoo.com>
2019-07-25 06:13:59 +00:00
Romain Derie 6a59224055 [FIX] web_editor, website: avoid returning children of inactive view
Before this commit, for the following view tree:
P (active)
|
I (inactive)
|
II (active)
When calling `get_related_views()` on 'P', it would wrongly return 'II'.
It shouldn't, since its parent 'I' is inactive.

Step to reproduce:
- Go to /shop
- Enable ecommerce categories
- Enable Collapsible Cateogories
- Disable ecommerce categories
- Collapsible categories is still shown even if its parent got archived

closes odoo/odoo#35154

Signed-off-by: Jérémy Kersten (jke) <jke@openerp.com>
2019-07-24 15:38:42 +00:00
Arnold Moyaux c8754185d1 [FIX] stock: MTO overprocessed move
Error due to other module (e.g. purchase_stock, mrp) that will
define their own rules in order to merge or not moves together.
Usecase:
- Install purchase_stock
- Create a product MTO + buy with a vendor
- Create a SO of 1 unit
- On the PO receive 2 units
- On the delivery deliver 2 units

It will create an empty delivery and put the entire move in
a back order.

First issue the extra move is created as a MTO if it's copied from an
MTO move. So il will trigger all the pull rule. We won't it because it's
an extra quantity and the rules should be only trigger by the original
document (SO/MO).
Also an extra move in a picking do the hypothesis that the original move and
the extra move will always be merged together. But in the previous
usecase, the module purchase add the condition that 'created_purchase_line_id'
and 'purchase_line_id' should be the same in order to merge move.
'created_purchase_line_id' is also copy=False, so the move and the
extra move will not be merged. create_extra_move only returns the extra
move and _action_done only process the moves returned by _create_extra_move.
It result by an original move not merged and not processed by _action_done,
it will be automaticaly set in a back order and the extra move is
processed.

In order to fix it, check if the move and the original move will be
merged. If not, returns both moves.

opw-2008113
Close #34005

closes odoo/odoo#34411

Signed-off-by: Simon Lejeune (sle) <sle@openerp.com>
2019-07-25 07:41:58 +00:00
David Dufresne 5b80695fc6 [CLA] signature for ddufresne
closes odoo/odoo#35079

Signed-off-by: Martin Trigaux (mat) <mat@odoo.com>
2019-07-25 07:32:06 +00:00
Romain Derie cb3bf5509f [FIX] web_editor, website: avoid returning children of inactive view
Before this commit, for the following view tree:
P (active)
|
I (inactive)
|
II (active)
When calling `customize_template_get()` on 'P', it would wrongly return 'II'.
It shouldn't, since its parent 'I' is inactive.

Step to reproduce:
- Go to /shop
- Enable ecommerce categories
- Enable Collapsible Cateogories
- Disable ecommerce categories
- Collapsible categories is still shown even if its parent got archived

Test writen in 12.0 with #35154

closes odoo/odoo#35155

Signed-off-by: Jérémy Kersten (jke) <jke@openerp.com>
2019-07-24 15:19:26 +00:00
Julien Mougenot 5c34091361 [FIX] web: improve editable list column widths
Changed the way some field types are displayed.

Before this commit, column width in a list were calculated according to
a given factor (integer), determining their weight.

Now, some specific fields have an hardcoded width instead. This task
also slightly tweaks some width factors, in order to try to have a
better layout in most list views

Task 1985916

closes odoo/odoo#35147

Signed-off-by: VincentSchippefilt <VincentSchippefilt@users.noreply.github.com>
2019-07-24 14:05:02 +00:00
Christophe Simonis e4a4b5a8f0 [MERGE] forward port branch 11.0 up to 0375c0174d 2019-07-24 16:04:59 +02:00
Christophe Simonis 0375c0174d [MERGE] forward port branch saas-15 up to fc80a9dae3 2019-07-24 15:06:16 +02:00
Goffin Simon ffe58a56bf [FIX] purchase: Saving PO with a foreign currency
Steps to reproduce the bug:
- Create a company C with currency = USD
- Create a vendor V with a supplier currency = EUR
- Create a PO for V with one line, the default currency is EUR
- Save

Bug:

The currency of the PO was USD when saving because the field currency is
in readonly when the state is draft.

opw:2035640

closes odoo/odoo#35144

Signed-off-by: Simon Goffin (sig) <sig@openerp.com>
2019-07-24 12:48:06 +00:00
Christophe Simonis fc80a9dae3 [MERGE] forward port branch saas-14 up to 36fdb2ff49 2019-07-24 14:01:48 +02:00
Jairo Llopis 21ede5365a [FIX] website: Delete redirections if website is deleted
Before this patch, if a website is deleted, its redirections will stay, affecting other websites.

Now, website-specific redirections will disappear along with their corresponding website.

closes odoo/odoo#35130

Signed-off-by: Jérémy Kersten (jke) <jke@openerp.com>
2019-07-24 10:16:43 +00:00
Romain Derie 36fdb2ff49 [FIX] website_sale: restore possibility to remove promo code pricelist
Since 5c9cea4ee7, it was not possible to remove an applied promo code
pricelist by adding an empty promo code on checkout (eg removing the one shown
in the promo code input).

Indeed, when sending an empty promo code, the `search()` done in the controller
would not find any pricelist as promo would be en empty string. For the rest,
check code on mentionned commit.

See `sale_get_order()` method docstring about `code` param: "If empty, it's a
special case to reset the pricelist with the first available else the default.".

Fixes #34633
2019-07-24 11:31:57 +02:00
svs-odoo 4d0f36ac01 [FIX] web: context when read on multi edit
Before this commit, in list editable, when user save multiple records in
the same time, the context is passed for the write but not for the read.
Now, the context is passed also for the read.

closes odoo/odoo#35113

Signed-off-by: Géry Debongnie (ged) <ged@openerp.com>
2019-07-24 07:05:32 +00:00
Martin Trigaux a98427834e [MERGE] Forward port of saas-12.2 to saas-12.3 up to 860ab5a1c2
closes odoo/odoo#35119

Signed-off-by: Martin Trigaux (mat) <mat@odoo.com>
2019-07-24 10:32:23 +00:00
Juhil Somaiya 860ab5a1c2 [FIX] website_slides: fix webiste menu being not clickable in lesson fullscreen
Before this commit, the navigation menu was not clickable because of higher
z-index of the slides fullscreen menu. This commit fixes that by correctly
setting z-index, using the standard variable to avoid custom values.

task-2036877

closes odoo/odoo#35107

Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
2019-07-23 13:44:06 +00:00
Siddarth Gajjar 7e5a80abc6 [FIX] web: fix footer layout issue in pdf report rendering
- When reports print with long string in footer will spoil layout. This issue will
fix that.
Task ID: 1960423 Closes at #33271

closes odoo/odoo#35097

Signed-off-by: Damien Bouvy (dbo) <dbo@odoo.com>
2019-07-23 11:24:31 +00:00
Jeremy Kersten 8a80efd7cd [FIX] gamification: perf on write karma_min on gamification.karma.rank
This commits avoid to call recompute when you write on the rank without
touch the karma_min value.

On write on karma_min, we have 2 cases:
- Rank order are the same, just need to recompute the rank for the user
that could be impacted. Eg. if karma_min changes from 45 to 50, we need
to recheck for all user between 45 and 50 their new rank.
- Rank order are not the same, we need to recompute for all users.
(could be still improved if needed)

When you recompute the rank on a list of users, depending of the number of
users (bulk if more than 3 * number of rank) we check for each user what is
the new rank, or for each rank whats is the new users.

task-internal

No way to edit a rank on the prod server. Lock sql -> crash server

closes odoo/odoo#34835

Signed-off-by: Jérémy Kersten (jke) <jke@openerp.com>
2019-07-24 09:03:13 +00:00
Lucas Perais (lpe) 78b09d82fb [FIX] web: pivot keeps controlpanel's domain on reload
Open a pivot view, make a search for some field
Click on a pivot cell to display the list view of elements matching the group's domain
Go back to the pivot using breadcrumbs

Before this commit, the original search domain was not kept across those actions

After this commit, it is kept

This difference is due to the fact that before 12.2, the whole action had an env, containing the search domain
in 12.2 and afterwards, things are not done this way anymore

OPW 2030555
OPW 2030983

closes odoo/odoo#35096

Signed-off-by: Lucas Perais (lpe) <lpe@odoo.com>
2019-07-23 13:48:37 +00:00
Géry Debongnie 4e6ee3ac97 [FIX] web: allow groupby buttons in list view at any level
The initial implementation of the special group by buttons in list
groups only supported the first level of groupby.  So, if one grouped a
list view by field A, it worked (if A had a groupby defined).  However,
if we want to group by B/A, this no longer works.

opw 2040725

closes odoo/odoo#35090

Signed-off-by: VincentSchippefilt <VincentSchippefilt@users.noreply.github.com>
2019-07-23 08:09:50 +00:00
Julien Castiaux ceeb5b51d5 [FIX] mail: form activity widget: do not close activity popover on click
Create an activity in a chatter, mark it as done, click inside the
textarea, the popover is automatically closed.

The `click` trigger both opens and closes the popover on click.

opw-2028399

closes odoo/odoo#34982

Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
2019-07-22 15:08:15 +00:00
Lucas Perais (lpe) a5ca064dc2 [FIX] website_sale: frontend billing address is partner's address
Have a partner

Partner (A1)
/		\
Shipping Addr (A2)	Invoice Addr (A3)

Give portal access to A1
Make a webshop order with A1

Make it possible for the front end user to edit his billing address (by having forgotten "country" on A1)
Note that the address being choosen as Billing is A1, NOT A3
Save
In the backend check the order. The customer is A1
The shipping address is A2

Before this commit though, the invoice address is A3, which is plain wrong
usability-wise since at no point in the flow the front end user chose that address

After this commit, the billing address stays A1, and A3 is just ignored

This goes with the spirit of https://github.com/odoo/odoo/commit/6e69de67071f2618e00856a74716d861b7f47391
Also, something smarter is possible if we let the user choose the billing address
just like we let him choose the shipping address

OPW 2034976

closes odoo/odoo#35105

Signed-off-by: Lucas Perais (lpe) <lpe@odoo.com>
2019-07-23 12:32:48 +00:00
Julien Castiaux 7273719b88 [FIX] mail,account: use reply_to header from tmplt
Create an invoice for a customer, send him an email from the chatter, in
the mail template set a specific "Reply to" and send the email. The
"Reply-To" template mail header is ignore and the one generated by
`mail_thread._notify_get_reply_to` is used.

See also 1c57d5e and 7b0806b

opw-2041640

closes odoo/odoo#35127

Signed-off-by: Julien Castiaux <Julien00859@users.noreply.github.com>
2019-07-24 06:25:02 +00:00
Julien Castiaux c1d63fc599 [FIX] stock: scrap from current picking
Steps to reproduce:

1) Make sure you don't have any piece of the product you're about to
sell on hand.
2) Create two sale order, each with 10 pieces of the product and
validate them
3) Do a RFQ and buy 15 pieces.
4) On the earliest sale order, check the availability, it should
autofill the desired quantity with 10
5) Do the same on the second, it autofills 5.
6) On the later delivery, scrap one.
=> The product is scrapped from the early picking.

Sort the candidates so the current picking is on top, this ensure the
current picking is the first scraped.

opw-2036381

closes odoo/odoo#35021

Signed-off-by: Arnold Moyaux <amoyaux@users.noreply.github.com>
2019-07-22 14:01:14 +00:00
Nans Lefebvre 088edee2ce [FIX] product: do not create duplicate variants
Create a product template Pt with attibutes A1, A2,
respectively with values Va1_1, Va1_2, and Va2.
This should make 2 variants, V1 and V2.
Sell some of these variants.
Then they can't be deleted since they are linked to orders/invoices/...

Now delete attribute A2. We know that:
Warning: adding or deleting attributes will delete and recreate existing
variants and lead to the loss of their possible customizations.

In fact, old variants are only archived instead of deleted:
for variant in variants_to_unlink: ... variant.write({'active': False})
as a fallback.

Now add again the attribute A2 to Pt.
It creates a new variant with the correct attributes.
Since the product is not active and has valid attributes and attribute values,
it is reactivated.
As a result we get the same variant twice.

Here we can simply add a check: if there is already an existing variant with
the same values, we can skip this activation.

We add a tiny little test to make sure that we have correct number of variants.
It's basically unreadable but somewhat commented.

fix coauthored with @rco-odoo

opw 2029985

closes odoo/odoo#35013

Signed-off-by: Nans Lefebvre (len) <len@odoo.com>
2019-07-22 13:07:57 +00:00