Commit Graph
5 Commits
Author SHA1 Message Date
Joseph Caburnay 60775b0f62 [REF] barcodes,*: convert BarcodeParser to js class
*: barcodes_gs1_nomenclature,point_of_sale

In this commit, we are converting the `BarcodeParser` to js class. As a
consequence, instead of having 2 options of instantiating the parser -- via
nomenclature_id or via nomenclature -- we are removing the first option.
Instantiating the parser will now only require the built nomenclature object.
This is possible because in all the pathways where the parser is instantiated,
the web services are ready, meaning `rpc` and/or `orm` services are ready. As a
result, the consumer of the parser can just build the nomenclature object itself
by fetching the nomenclature details from the server. A helper static method
called `fetchNomenclature` is introduced in the `BarcodeParser` class to aid in
building the nomenclature object it needed.

Furthermore, the methods that return the required nomenclature and rule fields
are converted to static fields which can still be patched (check
barcodes_gs1_nomenclature in enterprise).

closes odoo/odoo#120228

Related: odoo/enterprise#40582
Signed-off-by: Samuel Degueldre <sad@odoo.com>
2023-05-03 12:39:40 +02:00
Michael (mcm) ff0d6dd580 [REF] *: replace odoo module by native one
This commit converts almost all odoo module by native module.
The goal is to deprecate odoo.define in favor of native module and then
simplify boot.js by removing the regexp that finds module dependencies.

task id: 3162300

closes odoo/odoo#117305

Related: odoo/enterprise#39118
Signed-off-by: Géry Debongnie <ged@odoo.com>
2023-04-03 17:07:24 +02:00
Aaron Bohy 49297bc7bb [REM] *: remove legacy basic views + some fields/widgets
This commit removes the legacy implementation of the form, kanban
and list views. It also removes the legacy view widget registry,
and all legacy widgets it contained. The legacy field registry
couldn't be removed yet as some fields are still used (e.g. in
client actions: FieldMany2One, FieldMany2ManyTags...), and
sometimes accessed from that registry (e.g. uom service). More
clean up will come later. Note that all tests using legacy views
have thus been removed, even though the tested feature might still
remain (e.g. FieldMany2One tests have been removed, but that field
is still there). However, those features are deprecated and
unlikely to evolve. They should be removed in the next saas, or the
one after.

Finally, this commit also removes the legacy view dialogs.

Task 3168640

Part-of: odoo/odoo#111809
2023-02-08 13:27:58 +01:00
FrancoisGe 106dc30beb [FIX] barcodes: barcode_trigger does not work in the new view
Before this commit, in new views, it is no longer possible to click
on buttons with barcode_trigger="..." using a barcode scanner.

Why:
New views no longer propagate all attributes to the button.

How to reproduce:
- Go to a form view with a button with barcode_trigger="doit"
- Scan "O-BTN.doit", "Enter".

Before this commit:
 Nothing happens.

After this commit:
    An event click is applied to the button.

closes odoo/odoo#102423

X-original-commit: b4cb2ee2662173e08f671eb736130f8332265de7
Signed-off-by: Georis François (fge) <fge@odoo.com>
2022-10-07 14:36:49 +02:00
Joseph Caburnay ec2b66fb13 [REF] barcodes,web: barcode_handler and field_float_scannable to wowl
closes odoo/odoo#102150

X-original-commit: c57a0ada02bfc1f02b3516f92f87b510942c5a87
Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>
2022-10-04 20:57:44 +02:00