Barcodes are detected by catching keypresses. When a keypress is not
part of a barcode, it is 'released' by forging a keypress event.
For security reasons, a non-native keypress doesn't trigger the native
input mechanism. So in order to make both barcode-scanning and manual
keypresses work in a field, it is necessary to have a handler listen
to the 'false' keypresses and simulate the native input behaviour.
When a button in the modal's footer has an onclick handler and closes the
modal, the action of closing the modal should wait for the potential deferred
returned by the handler.
For instance, if an handler performs an asynchronous call and, when resolved,
triggers a notification, the notification doesn't reach the webclient if the
modal is already closed because the widgets hierarchy is broken.
This allows to detect barcode scans while the focus is in such a field.
It is not the default behaviour because buffering keystrokes to see if
they are a barcode then releasing them if they aren't isn't trivial
(it is impossible to trigger a native keyboard event).
A 'display: none' rule on hover has been added for boolean buttons, on each
'o_stat_button o_stat_text' that hasn't classname o_hover. This applies on
every stat button that isn't a boolean button, so their content is always
hidden on hover.
Disabling all warning coming from listview editable broke tests
because they relied on this behaviour.
The problem that was to be solved is that warnings coming from
listview editable were useless for the user in a form view. Another
solution must be found.
Backport of refactoring/fixes/features for the listview editable. This
includes changes to formview and listview too (as the listview editable
interacts with them).
The widget now provide labels that depend on widget option "terminology". For
each terminology, it provides four button labels that are shown depending on
the field's value and hover status on the button.
On a first edition of a view list editable, scrolling before the first
edition might cause an issue: the editing fields are higher than they
should.
This commit solves this.
This issue stems from jQuery .offset({value}) function which is broken
if the element we want to position:
- is in absolute postionning,
- is inside a scrolled element in non static positionning,
- has not both top and left css property setted,
- has no ancestor element between itself and the scrolled not in static
positionning.
This issue happens less (and probably not at all) in saas-6 since the
last condition is most often not met thanks to this change:
https://github.com/odoo/odoo/commit/1ccd87a#diff-27c072074221456684bfc5f150ca0bc9R876
This issue of jquery is solved since jquery 3.0.0-alpha1:
https://github.com/jquery/jquery/commit/2d71594
( the issue is shown in https://jsfiddle.net/wpjrnggf/ and we can see it
is solved with jQuery 3.0.0-alpha1 https://jsfiddle.net/L6ykpjgy/ )
closes#8251
opw-647622
Replace deprecate controllers like /web/binary/image, /web/binary/saveas...
Use ETag for all content with 'unique' option to cache the content if the content is never changed.
LESS rules (enterprise compatibility) :
* .oe_avatar is float:left by default
* .oe_title is placed between oe_avatar/oe_button_box if any
without the need to make it float
Main changes :
- mail.notification model is removed. People do not receive notifications
anymore. Instead two ways of following documents exist
- using a channel; messages will be displayed on the channel itself
in a near future commit
- following with its partner; messages will all be considered as
needaction, using a new m2m table. People should receive less
needaction messages by following less records by themselves.
There is no more read / unread state anymore. Instead only needaction
messages are considered. Todo (Favorites) messages still exist, and are
stores on a new m2m table instead of using decorated notifciations.
- the main filter for documents is not message_unread anymore, but
message_needaction. A lot of views and filters have been updated
accordingly.
- the vote feature has been removed