HTTP status lines are required to have both
a status code *and* a "reason phrase".
Some stricter HTTP clients / proxies choke
on status lines without "reason".
Technically, setting `response.status` is supposed
to set both at the same time, so we need to provide
both, or to set `status_code` only and let werkzeug
add the reason. This patch does the latter.
Fixes#8924
The serialization gives different results for some elements. For instance, an
empty element `i` must be serialized as `<i/>` in XML and `<i></i>` in HTML.
It must be done like that, otherwise the world (of web browsers) would break.
Add a test case for `html_translate`.
group_no_one is almost no longer accessible (way too technical to ask to modify
the url to end users) while this field is simply more advanced configuration
(functionnal and not technical).
Replace technical feature group by purchase manager.
... allowing multi-line edition, like in the chatter.
Shortcuts:
- in the client action: ENTER sends, SHIFT+ENTER goes to newline
- in the chatter: SHIFT+ENTER sends, ENTER goes to newline
Don't use autosize anymore to resize the textarea according to its content as
it didn't fit well within the flex layout of the client action ('height: auto'
didn't increase the height of the flex-item with 'flex-grow: 0'). We perform
the resizing ourselves instead.
including:
- reset scroll position to bottom when leaving channel
- allow clicking on the avatar image
- hide stars when message is of type notification
- sort channel names
- add # before channel names
- rename Whole company channel in general
- replace \n and \r in messages by <br/>
- lighten the hover color of sidebar items in the client action
- Display @ before mentions
When website_quote is installed, the Terms and Conditions of the quote
template should replace the Terms and Conditions of the company.
However, if the T&C of the quote are not filled, they will be kept
empty. This fix uses the T&C of the company as a backup.
This fix also set the TéC in the lang of the partner.
opw-652390
The amount to show in payments_widget must be the opposite of amount_currency like
in the else condition:
amount_to_show = payment.company_id.currency_id.compute(-amount, self.currency_id)
opw:652478
Commit 4f9c9ad adds the context to the RPC call of 'message_post', but the
context was only defined for messages sent, and not for internal notes logged.
This causes a crash when logging a note on a calendar event as its method
'message_post' makes the assumption that it always exists, and tries to access
one of its keys.
opw-652470
Closes#9164
Fixes/hides a deadlock when running test_sale_order with either a single
database or a db_filter making a single database visible: the test
causes a report to be printed, which invokes wkhtmltopdf, which tries to
fetch assets using the registry which is being loaded. The asset request
thus waits on a lock which is held by the test which waits on the asset,
deadlocking the whole thing.
Using HttpCase means we're using the test_cr or something and bypassing
the deadlock, instead the asset requests just 404 as they do when using
the nodb routing.
.. instead of at the start. The reason is: if any rollback have to occur
during the call to `save_attachments`, we want to avoid rollbacking an
unlink on the ir.attachment table (because we cannot rollback the
removal of a file in the filestore).
This issue is especially annoying when we generate a bundle whose
ir.attachment record has the same hash than the invalidated one (for
instance when one of the source files in the bundle has been touched
but not modified) and of of these rollback occurs: the bundle has been
deleted on the filestore and cannot be served.
as save_attachment is only callded by js and css methods after an
empty return result of get_attachment, directly calling again
get_attachment is superfluous
If one of the javascript files of the bundle has been modified since the
bundle generation, we are sure that get_attachments will return an empty
list because it searches with the version of the bundle which takes into
account the last modification of any of the bundle's content.
Also, this check is not present in the css bundle generation.
It is not always possible to possess both the account number and the BIC at the
time of creation. Eg. bank statement import where few file formats provide BIC
When setting the quantity in a PO line, the field "date_planned" is changed
by onchange_product_id and this field is equal to:
-the date of today + seller.delay if there is at least one provider for the product
-the date of today if there is no provider set for the product
-the date manually set if there is no provider and already a scheduled_date set
To keep the similar behaviour to 8.0 for product without provider.
opw:652394
During new-api rewrite, some property fields wrongly lost their
company_dependent flag.
Despite it need a migration script to create the missing properties,
not updating the module does not lead to crashes.
In the refactoring of v9.0 accounting module (c04065a) the currency
field on account.bank.statement has been renamed currency_id.
sentry-32303830312e3239303433353734
A lead can be marked as won, it must be converted to an opportunity first.
Previous flow was problematic as we could still convert to opportunity a won
lead (which does not work and does not make much sense).
A lead can only be lost or converted.
Fixes#9076
When creating an invoice in a foreign currency,
and adding a line with a product,
the `onchange` failed,
due to the fact the field `date_invoice`
is not on the invoice line, but on the invoice.
In 6b55539dc7 the "container_row_stock"
group in stock.view_partner_stock_form was hidden using
groups="base.group_no_one". The issue is that the POS used a group
inside of this group that it modified to display the associated
barcode of the partner and the loyalty points of the partner. So
although the code still worked, the actual information was invisible.
To fix it we inherit the view directly from where it is created, namely
base.view_partner_form which is a bit nicer than inheriting from an
already inherited view.
The ISO weekday should be computed with isocalendar dateformat
The exact directive is '%V' according to GNU/Linux system strftime
http://man7.org/linux/man-pages/man3/strftime.3.html
However '%V' is not documented in official cross-platform syntax supported on
all python built, according to standardized by ANSI C formats
https://docs.python.org/2.7/library/datetime.html#strftime-and-strptime-behavior
as '%V' may not be supported on other platforms such as MS Windows, use the
cross-platform 'isoformat()' method.
Note that according to ISO 8601, the start and end of date may belong to the
previous or next year.
e.g.
>>> datetime.datetime.strptime('2005-01-01', '%Y-%m-%d').isocalendar()
(2004, 53, 6)
>>> datetime.datetime.strptime('2005-01-01', '%Y-%m-%d').strftime('%W')
'00'
Fixes#8927
In e9c6fd0 'accuracy' was added to the field list read for res.currency,
but since the accounting refactoring in 9.0 (c04065a), this field was no
more present (replaced by decimal_places).
Since this field in the current point_of_sale javascript code was never
used, this commit removes it from the field list.
sentry-32303830312e3239303433353734