The method 'action_done' on inventory adjustment became private and the
action launched from the view is now 'action_validate', so we adapt
those tests to use the new function.
TASK-30921
When you have some product tracked in an inventory adjustment, the
lot/serial number is not required, so when you confirm an inventory
adjustment with product tracked for which you didn't provide serial/lot
number you get a warning to inform you.
TASK-30921
The constraint avoifding ot have two inventory lines with the same
properties was only triggered in the create, we make it work also in the
write.
TASK-30921
When you create a inventory adjustement line, you can create new products,
but you don't really want to create products in the inventory adjustment.
TASK-30921
When the update quantity on hand is clicked on a product tracked by lot
or serial number or if the database is in multi location, the button
update quantity on hand will open an inventory adjustment to allow you
to add multiple lot/serial number and/or choose the lopcation in which
you are updateing quantities
TASK-30921
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).
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>
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
- Store a token inside sessions to allow implicit session deactivation when needed.
backport of @da1f153d61d747d9357694382fe04f96c0ca886a @c8243e71c6da37547a19f61c58f25d5d03e13d38
- Activate the Sale option 'Tax-Included Prices'
- Create and print an invoice
=> the total is displayed on each line
- Activate the Sale option 'Sections on Sales Orders'
- Create and print an invoice
=> the total is NOT displayed on each line
The option 'Tax Display' only applies to SO, not to invoices. Moreover,
we make consistent the wording.
opw-1856623
In this commit, our hero backport c444b5a293 to 9.0
[FIX] google_account: fix google request exception management
Error thrown by google request is an urllib2.HTTPError that can be read
and loaded in JSON. However in some cases the result of the read may
be void or not JSON-ready. This was causing a crash in the error
management and hid the actual issue.
This commit tries to read and JSON-load the error but fall back on
simply displaying the raw error in case of issue when handling it.
opw-1851612
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
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
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
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
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
The stock_move_line wizard in manufacturing order show the 'finished
lot' column if the finished product is tracked. The label mention only
the lot.
This commit change the label to take care of serial nulbers too.
When returning None, the XML-RPC can trigger an error, making
the api unusable in certain cases.
So, we added return True and if the context is None we
use an empty dict, so if the context is returned in a dict,
it is not returning None either. Tests were adapted too.
Closes#22264
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
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
Before this commit, it was not possible to add an amount to a new
bank statement. The input (.o_form_field_monetary) appeared as disabled.
This bug was due to this commit: @a1224f5ca
This rule should be only applied to .o_form_field_radio.
Closes#18887
Task ID: 35832
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.
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.
When using easypost, it could exist more than one tracking
link. In this case they are stored as a json and the method
open_url try to load it as a list of url. Then it checks if there is
more than one url or not. However in a single case, there is only one
string and the lenght of a string is the number of chracter inside that
is often more than one.