<feed xmlns='http://www.w3.org/2005/Atom'>
<title>Odoo/addons/barcodes/static/src/js/field_float_scannable.js, branch 14.0</title>
<subtitle>The current checkout of upstream Odoo</subtitle>
<link rel='alternate' type='text/html' href='http://erp.ceuconsult.com:9000/Odoo/'/>
<entry>
<title>[REF] barcode, *: update code to new JS framework</title>
<updated>2017-04-11T17:44:38+00:00</updated>
<author>
<name>Christophe Matthieu</name>
<email>chm@odoo.com</email>
</author>
<published>2017-03-29T15:25:18+00:00</published>
<link rel='alternate' type='text/html' href='http://erp.ceuconsult.com:9000/Odoo/commit/?id=920df597d3d7174723736a395e94dc8ff413c70b'/>
<id>920df597d3d7174723736a395e94dc8ff413c70b</id>
<content type='text'>
With the new views, the barcode mechanisms were completely broken,
because the view and widget JS code was totally changed.

This commit update and refactor all that code to make it work with the
new design philosophy.  Also, it update the coding style.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
With the new views, the barcode mechanisms were completely broken,
because the view and widget JS code was totally changed.

This commit update and refactor all that code to make it work with the
new design philosophy.  Also, it update the coding style.
</pre>
</div>
</content>
</entry>
<entry>
<title>[REF] web, *: redesign all JS views</title>
<updated>2017-04-11T17:44:38+00:00</updated>
<author>
<name>Géry Debongnie</name>
<email>ged@odoo.com</email>
</author>
<published>2017-03-05T09:05:56+00:00</published>
<link rel='alternate' type='text/html' href='http://erp.ceuconsult.com:9000/Odoo/commit/?id=905e01921f3c3ef43ace6fc537d1d8c0d280002c'/>
<id>905e01921f3c3ef43ace6fc537d1d8c0d280002c</id>
<content type='text'>
This commit introduce a full redesign of all JS views.  We started
basically from scratch.  The goal was to unify all the various views
under a common framework, to make them testable, to make then usable in
different conditions (in studio, or in the frontend), and to make our
lives easier.

Some important points are:
- we introduced new coding guidelines (camelCase, 80 chars width, ...)
- we have a brand new testing framework (still QUnit based)
- kanban view moved to the web addon
- calendar view (formerly web_calender) moved to web as well
- the tree view was removed
- all new code should be documented

We hope that this code is the start of a new era for the Odoo web
client, we want to have a high quality codebase, well documented, well
tested, well designed.

Work done by the framework team: mostly aab, ged, chm, dmo, qsm
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This commit introduce a full redesign of all JS views.  We started
basically from scratch.  The goal was to unify all the various views
under a common framework, to make them testable, to make then usable in
different conditions (in studio, or in the frontend), and to make our
lives easier.

Some important points are:
- we introduced new coding guidelines (camelCase, 80 chars width, ...)
- we have a brand new testing framework (still QUnit based)
- kanban view moved to the web addon
- calendar view (formerly web_calender) moved to web as well
- the tree view was removed
- all new code should be documented

We hope that this code is the start of a new era for the Odoo web
client, we want to have a high quality codebase, well documented, well
tested, well designed.

Work done by the framework team: mostly aab, ged, chm, dmo, qsm
</pre>
</div>
</content>
</entry>
<entry>
<title>[FIX] barcodes: fix FieldFloatScannable on firefox</title>
<updated>2017-03-24T13:07:07+00:00</updated>
<author>
<name>Nicolas Lempereur</name>
<email>nle@odoo.com</email>
</author>
<published>2017-03-24T10:04:21+00:00</published>
<link rel='alternate' type='text/html' href='http://erp.ceuconsult.com:9000/Odoo/commit/?id=8d948d92350c858e3f5534020968bbfda4c8d154'/>
<id>8d948d92350c858e3f5534020968bbfda4c8d154</id>
<content type='text'>
On firefox pressing special keys such as: Left Arrow or Backspace
trigger a keypress event.

This is different from google chrome which only generate a keydown and
keyup event.

There was thus two issue when using a FieldFloatScannable and firefox:

1. Keys such as ArrowLeft: would still be catched by FieldFloatScannable
   and be added programatically to the field but since Odoo didn't fix
   them a ASCII NUL character (0x0) would be added (in firefox it is
   represented by a large space).

2. Keys such as Backspace: would still be catched by FieldFloatScannable
   but were modified and corrected by Odoo so the corresponding ASCII
   character was added (ASCII BS character (0x8) for backspace).

The feature in FieldFloatScannable which add the character is used to
add characters for which the browser had been prevented to display them.

Thus this fix:

- for issue 1 and 2: only use the feature of FieldFloatScannable if the
  event was previously prevented and the current one is a forgery.

- for issue 2: add "Backspace" and "Delete" as specials characters which
  should not be modified or stopped by the scanner heuristic.

opw-706352
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
On firefox pressing special keys such as: Left Arrow or Backspace
trigger a keypress event.

This is different from google chrome which only generate a keydown and
keyup event.

There was thus two issue when using a FieldFloatScannable and firefox:

1. Keys such as ArrowLeft: would still be catched by FieldFloatScannable
   and be added programatically to the field but since Odoo didn't fix
   them a ASCII NUL character (0x0) would be added (in firefox it is
   represented by a large space).

2. Keys such as Backspace: would still be catched by FieldFloatScannable
   but were modified and corrected by Odoo so the corresponding ASCII
   character was added (ASCII BS character (0x8) for backspace).

The feature in FieldFloatScannable which add the character is used to
add characters for which the browser had been prevented to display them.

Thus this fix:

- for issue 1 and 2: only use the feature of FieldFloatScannable if the
  event was previously prevented and the current one is a forgery.

- for issue 2: add "Backspace" and "Delete" as specials characters which
  should not be modified or stopped by the scanner heuristic.

opw-706352
</pre>
</div>
</content>
</entry>
<entry>
<title>[FIX] barcode: value representation for scannable field float</title>
<updated>2016-01-04T12:58:13+00:00</updated>
<author>
<name>Arthur Maniet</name>
<email>ama@odoo.com</email>
</author>
<published>2016-01-04T12:53:49+00:00</published>
<link rel='alternate' type='text/html' href='http://erp.ceuconsult.com:9000/Odoo/commit/?id=1b9baf1ac23aaddcac959292a05da6da0dbc1c7b'/>
<id>1b9baf1ac23aaddcac959292a05da6da0dbc1c7b</id>
<content type='text'>
The value was stored as a string when it should have been a float.

opw-665376
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The value was stored as a string when it should have been a float.

opw-665376
</pre>
</div>
</content>
</entry>
<entry>
<title>[ADD] stock_barcode: field widget with barcodes scan + manual input</title>
<updated>2015-09-03T09:23:38+00:00</updated>
<author>
<name>Arthur Maniet</name>
<email>arthurmaniet@me.com</email>
</author>
<published>2015-09-03T09:17:45+00:00</published>
<link rel='alternate' type='text/html' href='http://erp.ceuconsult.com:9000/Odoo/commit/?id=cdb30b507ae7d1cf7205e78e67f693de17bb90d3'/>
<id>cdb30b507ae7d1cf7205e78e67f693de17bb90d3</id>
<content type='text'>
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.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
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.
</pre>
</div>
</content>
</entry>
</feed>
