The read_group function bypasses some restrictions, and in this case
was counting the "image", "image_small" and "image_medium" attachments
of the products, thus resulting in wrong attachment counts.
I changed it to a search_count which is cleaner, simplifies the code
a lot and, more importantly, returns the right values.
Before this, we would compute taxes based on quantity * price. In
account.tax (used by the POS backend) however taxes are computed on a
rounded (based on currency precision) quantity * price. This would cause
issues as orders in the backend would have a different total price as
calculated in the frontend.
An example that used to trigger the problem:
Order with orderline with product with price of 5, excluded tax of 21%
and a quantity of 0.985. This would cost 5.96 in the frontend and 5.97
in the backend.
The issue was that the deselection button did not appear when setting a
customer and then going back into the client list. Now new_client gets
reset whenever we hide the clientlist widget, which makes the hide/show
deselect button logic work.
...and not text, which is the default value. Otherwise, they are evaluated
server-side and the produced html is escaped in the body. Smileys are thus
not displayed.
`node.get('class', '')` returns a `Nonetype`
in some cases, and, therefore,
`'o_mail_notification' in node.get('class', '')`
throws a
`TypeError: argument of type 'NoneType' is not iterable`.
Replacing by `(node.get('class') or '')` keep the behavior
that was expected, but will prevent to have a `Nonetype`
opw-656508
opw-656753
opw-653965
Use `ir.config.parameter`.`set_param` with `None` or `False`
was not allowed as `value` of a `ir.config.parameter` is required.
An attempt to set a system parameter to `None` or `False` means,
most of the time, that the system parameter should be dropped.
For instance, in configuration wizards (`res.config`),
`set_param` is used when boxes are checked, or fields are filled,
to create/update system parameters with the value given in the
configuration wizards.
When unchecking these boxes, the configurations wizards tried
to set `None` in the system parameters, leading to a warning
saying the value is mandatory. The behavior expected when
unchecking these boxes was to remove the system parameters,
not to leave them empty. Besides, there is not methods
available in `ir.config.parameter` to quickly remove a system
parameter, like there is one to set a parameter.
opw-653547
Autofocus in formview did not work when landing on the form view in
edit/create mode. This was because autofocus was called before the
formview was in the DOM.
Solution here in community is to defer the call to autofocus.
The sequence of the first account.payment.term.line must be 9 because
the default sequence for a new line is 10.
Before the fix:
When changing the value of the default line by "percent" and adding a
new line with value equal to "balance". An exception was raised because
the sequence of the default line was 500 and then this default line was
always considered as the last one.
opw:656704
When a SO line is added through the pop-up form, the price subtotal is
not calculated when the user saves the pop-up, and therefore it is not
displayed in the SO line list.
When the field is added in the pop-up, it will be calculated and
displayed right away.
opw-654283
Due to the change in 2many input / output the domain to apply the mailing was
not computed correctly. Indeed the onchange was waiting for a list of ids or
a 6, _, ids command, aka things that were send by 2many before some cleaning.
It has been adapted to the 4 command, now sent by the new onchange mechanism.
Some feature of the iframe embedded editor may require csrf token
present, thus it has been added in the same way that cea29e0c0 did.
The web editor iframe template is also used to display the value without
editing it and in this instance having the csrf has no meaning.
opw-656685
The read more / read less in chatter has been removed in the new timeline and
then cleaned timeline introduced at cc6d2aa995.
This feature has been brought back at revision 486aab5098.
However a new cleaning removed the feature at revision 2a5f07e0b9.
This commit brings back this feature for the second time. Next one brings free
cookies.
When having a tracking, the subtype description should be displayed. This is
used for tracking linked to a subtype like Task Opened, Task Blocked, ...
This feature was forgotten when refactoring the chatter for v9 and is now
back.
In some instance, the mail content of a sent form would only be text
formatted. This could lead to a message with no newline, thus making it
illegible.
This fix has to be ugly since body_html field of a mail.mail is of type
text.
In the form builder, custom field name could contain special char but
the get key values are of the type str whilst the value are in unicode
type.
Thus when concatenating them, one should be converted so they are
uniform and don't lead to an encoding error.
opw-656745
The popover in the mass mailing are not enabled, also the whole CSS of
the website is not used (particularly, the popover CSS is not included).
This commit replace the popover by a tooltip and enable tooltip on
[data-toggle="tooltip"] elements.
second half of:
opw-656693
This revision is related to a9d20d9fa0.
`dataset.cache` contains an item for each records, even
if the records hasn't been loaded in the cache. If a record
has not been loaded, only the record id is available, not
the other values. Thefore, this isn't possible to validate
the record values of records that have not been loaded
in the dataset cache.
opw-654013
When terms are translated in the website, their values are sent as HTML (with
text entities escaped). The function `xml_translate` is used to sanitize those
values, and sometimes crashes because of non-closed entities like `<br>`. Fix
it by using an HTML parser as a fallback.
This is a partial revert of 6c8e53a087.
Warning messages are automatically displayed if a module takes more than 1000ms to load, but this delay is a bit short if you make multiple rpc calls (sorry for all the dead kittens)
Variable 'event' is magically defined on some browsers like chrome, but not on
firefox. Anyway, those preventDefault() were useless as they are performed
beforehand.
This filter filters requests for this year. However allocation requests do not
have date_from and date_to. For requests not having those dates the filter
takes requests whose type (holiday_status_id) is active. This was the old
Year filter, that is applied only to allocation requests now. Leave request
are still based on date_from and date_to.