Commit Graph
117883 Commits
Author SHA1 Message Date
Christophe Simonis 3cdcbce93c [FIX] im_support: make js tests pass 2018-06-28 17:00:37 +02:00
Christophe Simonis 1bf8f685c4 [FIX] stock_landed_costs: avoid useless changes on UoM in tests 2018-06-28 13:17:15 +02:00
Christophe Simonis fc1789c40f [FIX] sale_mrp: avoid useless changes on UoM in tests 2018-06-28 11:35:10 +02:00
Christophe Simonis 2c4b555b95 [FIX] stock: use renamed xmlid in newly added test 2018-06-28 11:01:25 +02:00
Christophe Simonis b06af028e6 [MERGE] forward port branch saas-11.2 up to d112a163cd 2018-06-28 10:55:12 +02:00
Christophe Simonis d112a163cd [MERGE] forward port branch 11.0 up to f6d36d81f7 2018-06-28 10:32:03 +02:00
Géry Debongnie 6d0824b894 [FIX] base: properly render settings form view after reload
Before this commit, something strange could happen after reloading a
settings form view: all 'sections' were displayed.  The issue was caused
by the fact that the state of the view was read from the arch of the
form view at render time.  Also, as a form of optimization (I suppose), the
settings did not call the initModules method twice, when it rerenders.
This is unfortunate, because the very same method is actually
responsible for removing unused sections.

This fix is the safe fix, but definitely not the perfect fix (this would
involve a larger change, something like reading the state from the arch once in
the view (factory), then only rendering what is necessary).
2018-06-28 09:13:40 +02:00
Nicolas Lempereurandqsm-odoo f6d36d81f7 [FIX] mail: discuss smileys on several lines
In the discuss composer on google chrome, when when the smileys have
more width than available, they stayed on one line and would increase
page size (adding an horizontal scrollbar).

This happened really easily in saas-11.3 because we have more smileys,
but still happened in 11.0 depending on the screen size.

opw-1861191
closes #25507

Co-authored-by: qsm-odoo <qsm@odoo.com>
2018-06-28 09:05:36 +02:00
Nicolas Martinelli a0173bbbce [FIX] stock: fix test setup 2018-06-28 08:35:23 +02:00
Nicolas Martinelli 50a10fd736 [FIX] stock: search route name
opw-1862275
2018-06-28 08:16:31 +02:00
Christophe Simonis 9dcc32c304 [FIX] stock: avoid useless changes on UoM in tests setUp 2018-06-27 20:14:47 +02:00
Christophe Simonis d44a4df863 [FIX] stock: correctly check UoM and Locations modifications 2018-06-27 20:13:37 +02:00
Swapnesh Shah bb78b7608a [FIX] hr_payroll: prevents maximum recursion depth
When computing a salary sheet, a maximum recursion error could happen if there
is a cycle in the rules or in the categories.

Add constrains for salary rules and categories.

Closes #25405
2018-06-27 17:44:03 +02:00
Christophe Matthieu 39f0f5db77 [FIX] ir_qweb: send template options in context to the fields
Application of a fix more specific to the problem of the contact widget
which can not serialize the dictionary because it contains the values of
the context of which browse record. (because contact try to
json.dumps options for multi-edition feature in web_editor)

opw-1859848

https://github.com/odoo/odoo/commit/ab85e9594651fd33ffd2747f4d3c5b360e7c7922
2018-06-27 15:11:37 +02:00
Christophe Simonis f70a3167ee [FIX] stock: inherit from correct model
Oversight of previous forward-port
2018-06-27 15:00:59 +02:00
Christophe Simonis 40836194c2 [MERGE] forward port branch saas-11.2 up to 12ddec3a76 2018-06-27 13:41:00 +02:00
Goffin Simon 787a156f0d [FIX] purchase_requisition: origin and partner_ref erased by a requisition
Steps to reproduce the bug:

- Create a product P with routes MTO and BUY
- Set a vendor V on this product
- Create a BOM B with P
- Create a MO M with B
- A RFQ is created with M as origin
- Create a purchase requisition PR with vendor V
- Set PR as purchase agreement on the RFQ

Bug:

- The field origin with M was erased by the name of PR
- The field partner_ref was erased by the name of PR

The fix is inspired by: c914df5a36

opw:1860430
2018-06-27 13:30:09 +02:00
Nicolas Lempereur f52a5a7255 [FIX] base: print multi record report no outlines
In b446930dc there has been a number of changes in report to improve
performances.

In one of these change, printing several documents with result such as:

```
<div class="article"><h1><span data-oe-model="mymodel" data-oe-id="1" data-oe-field="myfield" /></h1></div>
<div class="article"><h1><span data-oe-model="mymodel" data-oe-id="3" data-oe-field="myfield" /></h1></div>
```

The system will know it is rendering 2 mymodel records (with IDs: 1, 3)
and will try from the document to determines what part (called
"outlines") of the PDF corresponds to these IDs.

This is done by splitting the document over semantical delimitations
such as h1, h2, *.

If all is fine: each part of the PDF will be saved for each record, so
if we print records 1 and 3 they will be saved separately and will be
possibly used as is the next time they are to be printed.

But in the instance of printing a report which has:

- field that are displayed,
- several records printed at the same time,
- save and getting document back from attachment enabled,
- no h1 or other semantic delimitation

The matching of part of PDF and outlines can't be done since there is no
outlines, this was not expected by the code and caused an error.

With this change, if there is no outline each part of the PDF will not
be saved as attachment.

opw-1856469
closes #25496
2018-06-27 13:21:13 +02:00
qsm-odoo 22c9d60ad3 [FIX] web_editor: properly save media dialog without any image
Commit https://github.com/odoo/odoo/commit/50418c481182cb414792da32f2a0529503e59f9c
was correctly forward-ported up to 11.0. This commit fixes the
forward-port from saas-11.2.
2018-06-27 12:42:44 +02:00
Martin Trigaux 5940f41ddc [FIX] sale: translate 'sign' button in email
Do not integrate static term
opw-1862234
2018-06-27 12:40:49 +02:00
Gert Pellin c7247c07b6 [FIX] product: Product variants attributes are not shown in pricelist report (#25497)
Product variants are only shown by product name and price with no distinction between them.

related to task #1861988
2018-06-27 11:57:46 +02:00
Christophe Simonis 12ddec3a76 [MERGE] forward port branch 11.0 up to 152519cd65 2018-06-27 11:37:52 +02:00
Odoo Translation Bot 33e18a0051 [I18N] Update translation terms from Transifex 2018-06-27 11:22:41 +02:00
Nicolas Martinelli 152519cd65 [FIX] mrp: BOM Cost quantity format
Correctly format the "quantity" column.

opw-1862158
2018-06-27 10:55:51 +02:00
Goffin Simon 5e3b471f4a [FIX] mail: Playing video not working on iOS
Steps to reproduce the bug:

- Go to Odoo on Safari browser
- Go to CRM > Operations > Manufacturing orders
- Select a MO and log a note on it with a video attachment
- Try to watch the video

Bug: it's not possible to watch the video

HTTP servers hosting media files for iOS must support byte-range requests, which iOS
uses to perform random access in media playback. (Byte-range support is also
known as content-range or partial-range support.)

Odoo server doesn't support partial requests with accept-ranges

opw:1857873
2018-06-27 09:42:42 +02:00
Gert Pellin deb1c7d4f6 [FIX] crm: Bug in new opportunity dialog (#25482)
in edit_dialog added 'default_type': 'opportunity' to context.

There was a bug in specific workflows of creating a new Opportunity resulting in the Opportunity saved as a Lead.
Infected workflow:
a) Create a opportunity from the Kanban view
b) Click in create and edit
c) Save the opp
d) from this opp create a new opp by clicking on create
The second Opportunity will be saved as a Lead

related to task #1857855
2018-06-27 09:08:50 +02:00
Lucas Perais (lpe) cda2ac9b71 [FIX] event, event_sale, website_event: allow portal access to own registrations
OPW 1859364
2018-06-26 15:07:42 +02:00
Pierre Masereel f6b3247c31 [FIX] purchase: remove move_dest_ids when PO line cancelled
When a PO is confirmed, cancelled, set back to draft and confirmed
again, the push rules don't apply because the PO lines have
move_dest_ids. So we remove those move_dest_ids from PO lines, to allow
push rules to be applied on the newly confirmed PO.

OPW-1859363
2018-06-26 15:02:51 +02:00
Christophe Simonis 24f18e995e [MERGE] forward port branch saas-15 up to bda926034a 2018-06-26 14:58:48 +02:00
Arnold Moyaux d0dc4c60bd [FIX] purchase: dropshipping sequence in multi company
Usecase to reproduce:
- Create 2 sequence for PO(one for each company)
- Create a product with dropshipping
- Connect on the demo user with an active company different than the
admin company
- Create a SO for this product
It will create a PO with the admin's company sequence.

It happens because _run_buy use a sudo since SO user don't always
have the purchase and inventory rights. However the company is not
forced and thus the used company for sequence is the admin company.

opw-1860802
2018-06-26 13:43:08 +02:00
Arnold Moyaux 52f323545a [FIX] stock: inconsistent state after unpack.
Usecase to reproduce:
- Update quantity in stock with a product inside a package
- Reserve a picking with this package.
- Go on the package form view and unpack it.
The package does not exist anymore on the quant, the reserved move line
still having the package as source package.

When the user try to unreserve the move lines, it will try to unrerserve
a quant with this package that does not exist anymore and then return
the error message 'can not unreserve more than you have in stock'.

This commit removes the source package on move lines that contain the
unpacked pack.
2018-06-26 13:16:52 +02:00
Arnold Moyaux bd5ca8c612 [FIX] stock: be able to update stock module (demo data)
Due to commit 74737865d5 when a user
with demo data try to update stock it will return the location
constraint because the demo data try to update the supplier location
with the usage supplier. However there is no check if the usage is
really modify or just in values.

This commit add a check in order to only select locations with a new
usage or that effectively change the 'scrap location' switch.
2018-06-26 13:16:52 +02:00
Christophe Simonis bda926034a [MERGE] forward port branch saas-14 up to c9a01ab30a 2018-06-26 13:13:05 +02:00
Ivan Yelizariev 5cecd0a197 [FIX] web_editor: restore website context for assets editor
The assets editor controller was stripped of the website context with
https://github.com/odoo/odoo/commit/198673bf35f14e3a797d2ff09208a289e12bec4e

It was however needed by some client customizations.
2018-06-26 12:58:00 +02:00
Christophe Simonis c9a01ab30a [MERGE] forward port branch 10.0 up to 58c92d9374 2018-06-26 12:57:31 +02:00
Christophe Simonis 58c92d9374 [MERGE] forward port branch 9.0 up to 22084bc52e 2018-06-26 12:27:30 +02:00
Nicolas Lempereur fadb3e155e [FIX] addons: no unsubscribe for unsubscribed
The `/groups` route display mail.channel and allow:

- a public user to subscribe specifying a mail address
- a logged in user to subscribe/unsubscribe itself

The `/groups?unsubscribe` route is the same but only allow:

- a public user to unsubscribe specifying a mail address
- a logged in user to unsubscribe itself

When a user is logged in, there is the oddity that all mail.channel
appear as to "unsubscribe" even if the user is not subscribed.

With this commit, the unsubscribe is shown only if user is subscribed.

opw-1861208
closes #25439
2018-06-26 11:37:57 +02:00
Martin Trigaux 8d9c9aa516 [REM] note: bad translation file
Remove fr_BE translation file
This file contains a duplicated translation for "Stages of Notes"
Moreover the fr_BE.po file is supposed to contains only translation that are
specific for French from Belgium and different than "standard" French

Bug revealed at cb00803473
2018-06-26 10:53:43 +02:00
len-odoo f28875b1b7 [FIX] crm: make the force assignation field visible in wizard
Commit: https://github.com/odoo/odoo/commit/83a4374
Introduced a parameter force_assignation to choose to overwrite the salesman
when converting a lead to an opportunity.
However the field had never been made visible in the wizard view.

opw 1859447
2018-06-26 10:39:26 +02:00
len-odoo d7f5a1b25e [FIX] delivery, sale, sale_order_dates: ignore delivery line in commitment date computation
The commitment date is computed using every line from the sale order.
When the picking policy is set to direct, it takes the earliest date
among the sums of the order date and lead time.
However when the delivery is set, is adds a line with an order date of 'now' and
no lead time.
This date thus necessarily becomes the commitment date, bypassing what was
intended by setting a lead times on products.

We simply ignore delivery lines in this computation.

opw 1855646
2018-06-26 10:35:57 +02:00
Nicolas Martinelli 2254b5cf1c [FIX] base: default value in set_multi
Make sure to test `None` instead of any falsy value. Indeed, when we
want to explicitly pass a `False` default value, `set_multi` might
select an incorrect default value.

This is for example the case of `_inverse_product_pricelist`, where
`default_for_country` might be `False` on purpose.

opw-1858271
2018-06-26 09:46:53 +02:00
Damien Bouvy eb67d83016 [FIX] base: missing sudo in partner merge
When reassigning the company from the destination partner, most users
don't have enough rights to update companies on partners with registered
users; hence the sudo call.
2018-06-25 17:39:45 +02:00
Toufik Benjaa 542409a1b6 [FIX] payment_stripe: If exception occurs display the message
- The code to display the exception message was not working.
2018-06-25 16:21:17 +02:00
Josse Colpaert 70ddff760f [FIX] stock: when creating a procurement from a stock move, pass the date_expected as date
Before, when we created a picking manually with MTO+buy products,
put a scheduled date in the future and did "mark as todo", the
date on the po was related to now instead of that schedule date.

The scheduled date of the picking was passed to the date_expected
of the move, but not to the date of the move, which was passed to
the date_planned of the created procurement.  By passing the
date_expected instead of the date of the stock_move to the
date_planned of the procurement, the po will have dates in function
of the scheduled date of the picking.

Courtesy of chienandalu.  Closes #25223
2018-06-25 15:38:23 +02:00
Josse Colpaert d4582cf020 [FIX] purchase: no mrp fields in purchase please
Fields of mrp should not be put in purchase like this,
as it can throw a traceback e.g. if you generate a purchase
based on a picking in MTO.
2018-06-25 15:38:23 +02:00
jem-odoo 8346461634 [FIX] sale: SO line autocreation for vendor bill only
On a sale order, when adding a line with an expensable product with a
reinvoice policy, on the linked invoiced validation, the analytic entries
are created. During this creation, the line will be reinvoiced, so a second
SO line will appears with the same product.
This should not happen, as the SO line creation from an AAL should be done
only when the amount is negative (meaning it comes from an expense or a
vendor bill).
This was introduced in 3bf8a62e0d.
2018-06-25 15:31:07 +02:00
Nicolas Martinelli 752347cdef [FIX] website_sale_options: prevent double-click
- On the eCommerce, open a product
- Click twice on 'Add to Cart'

The modal is opened twice, with potentially multiple SO created.

opw-1858080
2018-06-25 14:50:33 +02:00
Nicolas Lempereur 8188e6c802 [FIX] project: default on email as suggested recipient
With 82ca3d3f in 11.0 it was possible to have an email address on a
task, without specifying a partner.

Because of a small issue, this address was not suggested as a possible
recipients like it was in a project.issue object.

opw-1858170
closes #25427
2018-06-25 12:30:45 +02:00
Martin Trigaux cb00803473 [I18N] export saas-11.3 translations
To odoo-master Transifex project
2018-06-25 10:33:05 +02:00
William Henrotin 85f8e4761b [FIX] uom: useless constrain on purchase UoM
The purchase UoM doesn't interfere with account move line at all so we
can remove this check.

Task id: 1844684
2018-06-25 09:20:55 +02:00