Commit Graph
132278 Commits
Author SHA1 Message Date
Fanny He 58b7907254 [FIX] website_form: link attachments to binary fields
If the name of a file input field is 'x_binary_input', before
commit 9be29371abcdfe57b1738484c5057ad81e76b00d (opw 2092653),
self.form_fields would have names of the form 'x_binary_input[i]'.
After this commit, they are of the form 'x_binary_input[i][j]'.
When calling extract_data, field_name would then be 'x_binary_input[i]'
instead of 'x_binary_input'. Therefore, the file would be considered as orphan
instead of being attached to x_binary_input.
We thus change the split so that it always returns 'x_binary_input'.

opw 2122624

closes odoo/odoo#41135

X-original-commit: 21ed2b971f66879fa3fa53dbd2c349ab39fa3fdb
Signed-off-by: fah-odoo <fah-odoo@users.noreply.github.com>
2019-11-29 10:55:09 +00:00
Alexandre Kühn 4876dd7906 [REV] hr_holidays: consecutive leave date on out of office message
This reverts commit 802817c925.

The new test was crashing when current weekday is Friday.
This is easy to fix, but some other considerations are missing in
the original commit, like taking into account timezones.

We will add a proper fix later, and revert now in the meantime.

closes odoo/odoo#41123

Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
2019-11-29 14:16:00 +00:00
Andrea Grazioso (agr-odoo) 72386a4832 [FIX] point_of_sale: respect order date when issuing invoice
Create a sale order in POS with generate invoice option enabled.

When the user timezone is creating a day difference with respect to UTC
the date reported on the invoice will be wrong. This is caused by the
invoice date being written using `fields.Date.today()` , which is using
the UTC date. Respecting the order_date fix the issue

opw-2129440

closes odoo/odoo#41121

X-original-commit: 34fcb7300a8eb73b39f5f871e3553f036d6f3639
Signed-off-by: Nicolas Martinelli (nim) <nim@odoo.com>
2019-11-28 12:04:21 +00:00
Damien Bouvy 1b3b7a61a6 [FIX] payment_ogone: correct list of params for SHA-OUT computation
Some parameters were missing, leading to incorrect SHA-OUT calculation
on Odoo's side. Some were removed as well.

opw-2121544

closes odoo/odoo#41114

X-original-commit: af184e7c4fb89752263a53794e4807f601587ecd
Signed-off-by: Damien Bouvy (dbo) <dbo@odoo.com>
2019-11-28 16:34:19 +00:00
lejeune quentin 5caa5d7d2e [IMP] hw_drivers: Change IoT Box version
Change the version of the IoT Box.
From 19_10 to 19_12

closes odoo/odoo#41109

X-original-commit: 2b8779dc657a5a2b877ad2a552dd0dfda0071357
Signed-off-by: Quentin Lejeune (qle) <qle@odoo.com>
2019-11-29 10:23:15 +00:00
Laurent Smet 2b5dbc0ef3 [FIX] account: Fix internal transfer account.payment
1) Don't set an amount_currency without currency_id set.
2) Use the journal's currency only if different of the company one.

closes odoo/odoo#41094

X-original-commit: 3dd8bf6a38704df0db4f0879e685d2230be572a2
Signed-off-by: Laurent Smet <smetl@users.noreply.github.com>
2019-11-29 13:17:51 +00:00
Kevin Baptiste edb02d6e94 [FIX] pad_project: prevent crash if no default project_id
Task creation was crashing when there was no project selected in the
kanban's quickcreate window.

closes odoo/odoo#41006

Taskid: 2146564
Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
2019-11-28 07:54:00 +00:00
Victor Feyens b9fabffe4e [IMP] sale_margin: make the cost a computed field.
And clean the code mess.

closes odoo/odoo#40953

Signed-off-by: Damien Bouvy (dbo) <dbo@odoo.com>
2019-11-29 12:09:40 +00:00
Xavier Morel 2c123005a7 [REM] dynamic domain from hr_timesheet
closes odoo/odoo#40952

Signed-off-by: Xavier Morel (xmo) <xmo@odoo.com>
2019-11-29 09:10:07 +00:00
Xavier Morel 3895ecfb3a [FIX] gamification: remove dynamic domains on field_[date_]id
closes odoo/odoo#40951

Signed-off-by: Xavier Morel (xmo) <xmo@odoo.com>
2019-11-27 10:00:18 +00:00
Xavier Morel 6c4ac28f33 [FIX] hr_timesheet: remove onchange domain
Fixes issues where static multi-company filtering would get squashed /
replaced by dynamic domains not having those filters.

The conditional could be replicated in two ways: one would be to use a
python-level conditional expression:

    a if cond else b

this is easier for users to interpret, but harder to analyze: python
expressions are currently opaque to view analysis (and possibly
eventually to domain edition).

The alternative here is to leverage domain simplification:

    (OR (= (not cond) 1) section)

if `cond` is true becomes

    (OR (= 0 1) section)

and thus `section` itself, while if `cond` is false it becomes

    (OR (= 1 1) section)

and thus `true` (so the section doesn't apply).

It works OK though the inversion of the condition itself is a bit
bizarre.

And in this specific case since we need both branches the negated
condition requires explicitly converting the condition to a boolean if
it might not be one: the expression compiler recognizes specifically
`(= 0 1)` and `(= 1 1)` (`(= False 1)` and `(= True 1)` also work for
Python reasons).

[REM] dynamic domain from hr_timesheet

closes odoo/odoo#40945

Signed-off-by: Xavier Morel (xmo) <xmo@odoo.com>
2019-11-29 12:02:57 +00:00
Yannick Tivisse 4411cedde8 [IMP] base: Display 'Contains In-App Purchases' on module form views
Purpose
=======

There are no mentions that a module may contain In-App Purchases in Apps.
We should inform the users of this so they make a conscious decision when
installing such app.

closes odoo/odoo#40731

Taskid: 2129214
Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
2019-11-29 14:03:41 +00:00
Julien Castiaux dec397b86d [IMP] base_automation: refine CRON frequency
The current 'Base Action Rule: check and execute' CRON search every
four hours for delayed actions to run. This mean, any action scheduled
later can be delayed up to four hours.

We now dynamically reset the CRON frequency according to the least
delayed automated action to minimize the potential gap.

closes odoo/odoo#40633

Task: 1998809
Signed-off-by: Raphael Collet (rco) <rco@openerp.com>
2019-11-29 09:07:58 +00:00
Hoste Patrick ec9e389f2f [IMP] website_slides: allow to create and update quizzes directly in frontend
Purpose is to ease designing your courses by allowing to create and update
slide quiz directly in frontend, within the slide display.

With this commit you are able to

  * add a quiz to a slide or add a question to an existing quiz;
  * edit an existing question from a quiz:

   * change the title of the Question;
   * add, remove or update answers;
   * change the right answer;
   * delete an existing question;
   * reorder the questions from a quiz;
   * reset the quiz for the current user if he is a website designer, allowing
     to test the quiz and its answers;

New frontend widgets are introduced allowing to manipulate quiz. Slide page
now supports a readonly / taking quiz mode and an edit mode for quizzes
used notably for website designers / course maintainers.

Task ID : 1999636
PR : #35326

Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
2019-11-29 13:36:25 +00:00
Thibault Delavallée a4abdfa316 [IMP] website_slides: merge slide quiz answers constraints in a single method
Currently there are several checks on answer integrity for slide quiz
questions. In this commit we simplify code to effectively implement
what is requested: 1 valid answer and at least 1 invalid answer.

Task ID 1999636
PR #35326
2019-11-29 13:36:25 +00:00
qsm-odoo 0b5f1fbead [FIX] web_editor: restore fa icons used in editor following lib update
Commit https://github.com/odoo/odoo/commit/ff1c35513aecef5fbc30f7c2f3834450e719714e
broke some editor icons.

closes odoo/odoo#41097

Signed-off-by: Quentin Smetz (qsm) <qsm@odoo.com>
2019-11-29 10:47:02 +00:00
Victor Feyens 51e289dac3 [FIX] doc: force_company isn't supported in master anymore.
New multi-company guidelines for 13.0 documentation explain the use of 
force_company. This is still valid in 13.0, but removed in 13.1 and 
replaced by the with_company mechanism.

closes odoo/odoo#41108

Signed-off-by: Victor Feyens (vfe) <vfe@odoo.com>
2019-11-29 10:56:51 +00:00
Laurent Smet a4c2a1425a [FIX] account: Fix fy lock date check on account.move
The trailing check on the fiscal year lock date is wrong and is
triggered whatever the values passed to 'write'.

closes odoo/odoo#41100

X-original-commit: 5b3486a434dbb0d9d1ed583e59f6b478b33e9745
Signed-off-by: oco-odoo <oco-odoo@users.noreply.github.com>
2019-11-29 08:45:26 +00:00
Nans Lefebvre b66c6c0f75 [FIX] l10n_nl: set depreciation lines as cost in report
Afschrijving means depreciation.
However all depreciation lines have been copy-pasted with
wrong tags and types:
e.g. Aanschafwaarde overige immateriele vaste activa
has a counterpart Afschrijving overige immateriele vaste activa,
the first user_type_id is data_account_type_non_current_assets, but the
counterpart should be depreciation; similarly tags should go to their
Afschrijving counterpart.

opw 2115991

closes odoo/odoo#41071

X-original-commit: edac3bf4147aa4853660621b6c34f3a750882a94
Related: odoo/enterprise#6953
Signed-off-by: Nans Lefebvre (len) <len@odoo.com>
2019-11-28 11:54:30 +00:00
Antoine Prieels 6f645925a4 [IMP] hw_drivers: Clean MPD manager in driver.py
We clean the code for the MPDManager by removing useless lines and
simplifying the way we run the MPD server.

closes odoo/odoo#40892

Related: odoo/enterprise#6892
Signed-off-by: Quentin Lejeune (qle) <qle@odoo.com>
2019-11-28 14:04:33 +00:00
mgh-odooandMohammed Shekha 5c004c2e83 [IMP] mail: show out of office ribbon on discuss
This commit adds the out-of-office ribbon at the top of the
conversation in the discuss app.

Task-2066672

closes odoo/odoo#39362

Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
Co-authored-by: Mohammed Shekha <msh@odoo.com>
2019-11-29 08:56:15 +00:00
Julien Mougenot bf18802c1d [FIX] web: CalendarView: event edition in month mode
Fixes the way record end hours are computed in calendar views.

Before this commit:  objects `record start` and `record end` properties being copied by reference
and being incorrectly rewritten by other functions.
This caused incorrect end hour computations (and a SQL crash in the Planning app).

Now, objects are copied by value and don't interfere with each other.

Task 2072961

closes odoo/odoo#37690

Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>
2019-11-29 09:06:04 +00:00
Julien Mougenot 9d9dc29c3a [REF] web: revert 13.0-opw-2093111-calendar_fixex-jpp
Most of the diff changes don't seem to affect the  issue, and
there is no test to prove that it has been actually fixed.
2019-11-29 09:05:58 +00:00
Jason Van Malder 22df074e7b [FIX] payment_stripe: fix bad request not displaying
Reproduce the issue

    - Install eCommerce
    - Activate stripe, use testing credentials and select
      Configuration > Payment Flow > Payment from Odoo
    - Create a contact that has a trailing whitespace at the beginning
      of the email
    - Grant him portal access, and a password
    - Open your browser devtools
    - Login to the web shop with this portal user and buy an item using
      stripe

    1. Error Dialog: Server Error (HTTP 500)
    2. The exception received by the front-end is not clear
    3. When the 500 error is fixed, we still have a error dialog
       => bad UX

Cause

    1. The raise was removed but we need to keep it because
       it allows the true error to be raised (bad request)

    2. The "invalid email address: x" is lost when we raise the
       exception

    3. In V13, all catch & guardedCatch open a error dialog if we
       don't set preventDefaulted to true on the error's event

This commit changes restore the raise, change the error message and
disable the error dialog for this case.

OPW-2126196

closes odoo/odoo#41087

X-original-commit: b8d013285ba54c8d3ab4a3857604dfca3e479b39
Signed-off-by: Jason Van Malder <jasonvanmalder@users.noreply.github.com>
2019-11-29 06:59:42 +00:00
Xavier Morel de52631795 [REM] website_sale: dynamic domain
closes odoo/odoo#40962

Signed-off-by: Xavier Morel (xmo) <xmo@odoo.com>
2019-11-27 13:41:49 +00:00
shreya thakrar 29cb942868 [IMP] base: add support of VAT field for "contact" qweb widget
This commit adds support for displaying 'VAT' field in a 'contact'
widget used in qweb views.

This commit also does the necessary changes needed for behavior
improvements of report editor in studio. For more information,
see https://github.com/odoo/enterprise/pull/6543 or task pad.

task-1904639

closes odoo/odoo#39722

Related: odoo/enterprise#6543
Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>
2019-11-15 11:36:00 +00:00
Nicolas Lempereur 34aae9faa5 [FIX] web: typo calendar highlight -> ok now
Adapt calendar highlight option (that "highlight" event linked to the
record we come from) to current JS framework data structures.

note: this changeset also fixes the original `_compute_is_highlighted`
that was would trigger CacheMiss errors, and also adds back the CSS for
highlighting that was lost between 12.0 and 13.0 version.

opw-2131494
closes #40791

closes odoo/odoo#41077

X-original-commit: da56e3e7036ecdb3905f4152778e853e080e0163
Signed-off-by: Nicolas Lempereur (nle) <nle@odoo.com>
2019-11-28 16:57:04 +00:00
Adrien Horgnies 35eab823b0 [FIX] l10n_it: fix tax deductible percent and remove obsolete taxes
tax name suggest 10 but code 20, history tells 10 is right, fixed code
two children taxes are now orphans, kill the orphans

closes odoo/odoo#40825

X-original-commit: 28e74fafec4cec3179db330a1ededf4ef8677fbc
Signed-off-by: oco-odoo <oco-odoo@users.noreply.github.com>
2019-11-25 14:35:01 +00:00
Jason Van Malder 16e6907efa [FIX] http_routing, portal: fix web translations not loaded
Reproduce the issue

    - Install eCommerce & Sales
    - Create a quotation
    - Preview
    - Switch to french on the website page
    - Click on "Signer & Payer"

    There is a lot of things not translated.

Cause

    On the website, the route `/website/translations` is called.
    The route calls a method `_get_translation_frontend_modules_domain`
    which teturn a domain to list the domain adding web-translations and
    dynamic resources that may be used frontend views.

    The missing translations are in the web module and the module is not
    loaded by the method.

This commit adds the `web` module to the domain and a missing
translation for the portal module

OPW-2120397

closes odoo/odoo#41072

X-original-commit: 50c2ecbc9ef0e446af0a1d4010ec1d923aa41bec
Signed-off-by: Nicolas Lempereur (nle) <nle@odoo.com>
2019-11-28 15:22:41 +00:00
Laurent Smet 358f633028 [FIX] account: Fix mobile view of invoice's lines.
The invisible fields are not there for the fun...

closes odoo/odoo#41066

X-original-commit: e26946c5da9aa3a656e3368ec98e9806b2c7ba54
Signed-off-by: Laurent Smet <smetl@users.noreply.github.com>
2019-11-28 13:41:09 +00:00
Laurent Smet 07ddb43783 [FIX] account: Fix amount_total_signed in account.move
The miscalleneous journal entries has displayed in the tree view with
a negative amount in amount_total_signed that has no meaning.

X-original-commit: 4a7dcb4027ee93448b2d15cc262b8c2fb5d531db
2019-11-28 13:26:59 +00:00
Laurent Smet 6f9c1f778d [FIX] account: Don't compute invoice_payment_state for Misc. Journal entry.
The reason is the invoice_payment_state is tracked by the chatter and displayed
when the field is recomputed during the 'post'. However, this field has no
meaning in a Miscellaneous Journal entry.

X-original-commit: e0a0d06c7aa0acbc3c37b9a108fa5d67042c0438
2019-11-28 13:23:18 +00:00
Laurent Smet b21d0f77af [FIX] account: Don't generate 0 balance payment term lines
In the Mexican Localisation (l10n_mx), there is a "custom" behavior
made when there is more than one payment term lines.
Before the account-pocalypse, the receivable lines having a balance equals
to zero was ignored.
This commit aims to restore this behavior and then, fix l10n_mx.

--issue: 2121973
X-original-commit: 6a4f9a2666b7414d208248da52862428c04bb4a6
2019-11-28 12:51:21 +00:00
David Beguin 5e605f589d [FIX-IMP] website, website_livechat : disable create visitor and review ACLS
This commit applies the following ACLs rules:

C : nobody can create visitor (except system)
R : everyone that should access to this model
U : website_designer can update (even if only few fields are editable),
    mainly useful for language (+ system obviously)
    + livechat users as they are the guys who directly speaks with the visitors
D : system + website_designer can delete, mainly useful to clean if necessary

Remove the no_create from all visitor views as handled by ACLs.

This fixes the 'can create' that should not be done by any users
except system + admin

Task ID: 2092502
PR #40439

closes odoo/odoo#40865

X-original-commit: 23f3324830adf31edb0a12c7009fcb65b0f54614
Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
2019-11-28 14:31:29 +00:00
jbw 6c9a7592a4 [IMP] various : remove-bic-constraint-on-sepa-operations
{ As the SEPA BIC is no longer mandatory we simplify bank creation removing constrains about BIC }
As of 01/02/2016, the BIC is no longer mandatory, you can see the page 25 ==> https://www.febelfin.be/sites/default/files/2019-04/standard-xml-sdd-initiation-_v4.1a-en.pdf
As a result, in order to simplify both the code and the process, we don’t want anymore constrains about that.

task : https://www.odoo.com/web#id=2056370&action=327&model=project.task&view_type=form&menu_id=4720

> We don't need BIC for both the company iban bank account or customer/vendor iban bank account
> If a vendor bill is linked to a valid IBAN bank account without BIC, show the QRcode (remove the BIC constrains )
> CREATE A SDD mandate should be possible without BIC (for both the company iban bank account or customer/vendor iban bank account)
> Create a SCT payment should be possible without BIC (for both the company iban bank account or customer/vendor iban bank account)
> Add a country group for SEPA zone
> Add IBAN country codes for each country in base_iban module
> Only display qr code when making a payment to an IBAN account whose country code corresponds to a SEPA member
> in account's post init hook, install SEPA modules if the country of the company belgons to SEPA zone (instead of Europe, as it is now)

closes odoo/odoo#40356

Related: odoo/enterprise#6738
Signed-off-by: oco-odoo <oco-odoo@users.noreply.github.com>
2019-11-28 15:35:42 +00:00
Varun Raval f98b397dc8 [IMP] l10n_it_edi: tax representative should have vat number
If Company Tax Representative of the seller is not having a VAT number,
which is mandatory, system won't allow to validate the invoice.

closes odoo/odoo#34511

Task: 1971512
Closes: #34511
Signed-off-by: Josse Colpaert <jco@openerp.com>
2019-11-28 14:59:59 +00:00
David Monjoie 53323c7ce9 [FIX] web_editor: apply missing fix from saas-12.3 revert
closes odoo/odoo#41021

X-original-commit: 21c23050f100bab2c5377c37a6de40c4acf28ca8
Signed-off-by: David Monjoie (dmo) <dmo@odoo.com>
2019-11-28 08:05:00 +00:00
Florian Gilbert 9b9379bf2c [FIX] account: Set the reference and not the name for Opening Journal Entry.
We have a problem about the opening journal entry because we set the account
move name to "Opening Journal Entry" and it's not compliant with our policy
about the account move name.
We often check the account move name to know if the move has consumed a number.
And we cannot check it correctly for the opening journal entry.

closes odoo/odoo#38957

Signed-off-by: oco-odoo <oco-odoo@users.noreply.github.com>
2019-11-28 14:47:12 +00:00
Florian Gilbert d862965324 [IMP] account: Add tracking for account move line in account move chatter.
Purpose:

In V13, you can reset to draft a posted move if this move isn't in
a hashed journal. But it's little bit dangerous and we want to
track changes for some fields.
It works for editing in editable list view and form view.

Task ID: 2061399
2019-11-28 14:47:12 +00:00
Jason Van Malder fd9c6bdcc6 [FIX] project: fix crash when no language selected
Reproduce the issue

    - Select a language (done by default)
    - Install Project
    - Create a project
    - Create a task with a formatted date
    - Reset the language
    - Go on the project

    Traceback

Cause

    In 7e42c663, I format the date_deadline based on the user's language
    but did'nt know that we could have no language selected.

This commit uses the `format_date` method from `odoo.tools.misc`
which fallback on the first language installed if there is no
language selected.

OPW-2146479

closes odoo/odoo#41057

X-original-commit: 7d06135712b6646816b0558a63e55bc10622e59c
Signed-off-by: Jason Van Malder <jasonvanmalder@users.noreply.github.com>
2019-11-28 12:18:39 +00:00
Nicolas Martinelli b96830ed83 [FIX] mrp: default location
- Create a picking type with specific default locations, for type
  Manufacturing
- Go to Inventory, click on the 'To Process' button
- Create a MO

The default locations are not taken into account.

This is because the default picking type is not in the context.

opw-2128182

closes odoo/odoo#41049

X-original-commit: 6f7cbedd0ad252352209391501ba8971f7e90d00
Signed-off-by: Nicolas Martinelli (nim) <nim@odoo.com>
2019-11-28 11:55:01 +00:00
Andrea Grazioso (agr-odoo) ca92a5e8cd [FIX] point_of_sale: add UoM to invoice line
Enable units of measure from Settings.
Go to Point of Sale, enable "Invoicing" from the PoS, open the session,
sell something specifing customer and invoice. Close the session and
post.
Check the sale order, UoM is specified. Now check the associated
invoice, UoM is missing.

This is because the UoM is not propagated from the sale order to the
invoice. Adding the missing value

opw-2129428

closes odoo/odoo#41040

X-original-commit: 2d5f22f040e7d28a17191cd6cc512b58b929efa1
Signed-off-by: Nicolas Martinelli (nim) <nim@odoo.com>
2019-11-28 10:22:25 +00:00
Victor FeyensandAntoine Vandevenne 5a1d603c5f [ADD] doc: multi-company howtos
closes odoo/odoo#41038

X-original-commit: eaabad20516a73a97b23343a22357659c29945f7
Signed-off-by: Antoine Vandevenne (anv) <AntoineVDV@users.noreply.github.com>
Co-authored-by: Antoine Vandevenne (anv) <anv@odoo.com>
2019-11-28 10:16:48 +00:00
Antoine Prieels 2e34d456e8 [FIX] hw_drivers: Redirect exceptions to log file
Exceptions were logged to stderr so we couldn't see them when Odoo was
running as a service on the IoT Box. We now redirect stderr to the logger
to see track errors in the log file too.

closes odoo/odoo#41028

Taskid: 2146835
X-original-commit: 54a1919cbc37f5832ce110605c29b222c7a5bfe9
Signed-off-by: Antoine Prieëls <aprieels@users.noreply.github.com>
2019-11-28 08:32:28 +00:00
Antoine Prieels 738868a1db [IMP] hw_drivers: Dual customer display
Customer displays were all using the same URL and therefore could only
show the same products. We now use different URLs per screen.

Two screens connected to the same IoT Box can now display customer
displays from different POS.

closes odoo/odoo#41026

Taskid: 2123511
X-original-commit: 12569b0e7f7a9e447f8df908597131911c5cfef8
Signed-off-by: Antoine Prieëls <aprieels@users.noreply.github.com>
2019-11-27 14:15:18 +00:00
Antoine Prieels ad846fcee5 [IMP] iot: Dual screen support for RPI4
We now support the RPI4 which has 2 micro-HDMI outputs, while the
prvious driver only supported one display. We add support for a second
display.

Taskid: 2123511
X-original-commit: 5886c3a864c990fcd7b852baafab752e7da90494
2019-11-27 14:15:18 +00:00
Goffin Simon c1c4404131 [FIX] website_sale: Wrong price_unit in the cart
Steps to reproduce the bug:
- Let's consider two companies C1 and C2
- Let's consider website W
- Activate multi-company
- Disable common contact book and common catalog
- Switch the superuser in company C2
- Activate pricelist
- Create a public pricelist PL for C1 and available on W
- Set up a pricelist with compute price = formula and  based on = cost
- Go Sales > Configuration > tick Multiple Sales Prices per Product and tick Prices computed from formulas
- Create a portal user PU and set PL on him
- Create a product P with cost = 10$ and publish it on W
- Set up the product valuation as: automated
- Log as PU and go on the shop
- Put P on your cart

Bug:

The price of P was 0$ instead of 10$

opw:2092695

closes odoo/odoo#40981

X-original-commit: 40d3fa50e3d9a0e1cc0077cc8dcbe052ffa9820f
Signed-off-by: Simon Goffin (sig) <sig@openerp.com>
2019-11-28 10:10:16 +00:00
Martin Trigaux b175558ce7 [FIX] tools: no pollution during export translation
Before this commit, the export of translations was incorrect for code
and model translations:

For code translations, the field 'name' was used for the matching
while the _() method explicitly use None in the _get_source call to
only use the field 'src' for the search.

For model translations, the field 'res_id' was not used when searching
for a translation.
For instance, if a ir.model.fields did not have translated label,
exporting the translations was using the translations of the first
field having the same source.
While this could be convient during the import (to be discussed),
doing so in an export of translation is clearly an unexpected
side-effect.

closes odoo/odoo#40909

X-original-commit: 4534181f106cf5aa50c65c942c260eeec122d3d2
Signed-off-by: Martin Trigaux (mat) <mat@odoo.com>
2019-11-28 11:43:46 +00:00
jbm-odoo 9725eadfdd [Fix] hr_employee: Fix compute fields
When we add a user to employee, we can have problem with leave,
expense or coach manager. It's due to those compute fields.

closes odoo/odoo#40795

Related: odoo/enterprise#6865
Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
2019-11-28 10:40:34 +00:00
jbm-odoo df44538a8b [IMP] fleet: Add analytic account and mobility card
Create analytic account from fleet (and link it to vehicle) based
on the plate and the fiscal deduction rate (if l10n_hr_payroll_fleet
is installed).

Add on employee a Mobility Card number. This number is set on vehicle
when we put a partner linked to employee on a vehicle.

taskID: 2127641
2019-11-28 10:39:49 +00:00