Skip to main content
Pre-release

This release is a pre-release and may not be stable for production use.

Web Widget UoM

Beta License: AGPL-3 OCA/web Translate me on Weblate Try me on Runboat

This module allows the user to decide maximum how many decimal places should be displayed in the Odoo User Interface for each Unit of Measure.

If “Show only inputed decimals” is enabled on the UoM, the widget will show inputed decimals up to Decimal Places.

Table of contents

Usage

In the UoM form view specify the number of decimal places that should be displayed for each unit of Measure:

Decimal Places in UoM form view

In the view declaration, put widget=’uom’ attribute in the field tag:

...
<field name="arch" type="xml">
    <tree string="View name">
        ...
        <field name="product_qty" widget="uom"/>
        ...
    </tree>
</field>
...
<field name="arch" type="xml">
    <form string="View name">
        ...
        <field name="product_qty" widget="uom"/>
        ...
    </form>
</field>
...

Widget Options:

...
<field name="arch" type="xml">
    <tree string="View name">
        ...
        <field name="product_qty" widget="uom" options="{'uom_field': 'product_uom'}"/>
        ...
    </tree>
</field>
...

If the UoM field in the model is not declared under the name uom_id, the option uom_field must be specified with the appropriate field name.

Known issues / Roadmap

TODO

  1. Add caching by uom.id

Bug Tracker

Bugs are tracked on GitHub Issues. In case of trouble, please check there if your issue has already been reported. If you spotted it first, help us to smash it by providing a detailed and welcomed feedback.

Do not contact contributors directly about support or help with technical issues.

Credits

Authors

  • Giovanni Serra

Contributors

Maintainers

This module is maintained by the OCA.

Odoo Community Association

OCA, or the Odoo Community Association, is a nonprofit organization whose mission is to support the collaborative development of Odoo features and promote its widespread use.

This module is part of the OCA/web project on GitHub.

You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute.

Metadata

Release files for odoo14-addon-web-widget-uom 14.0.1.0.1.dev3

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Built distribution (wheel)

Table of built distributions (wheels) for odoo14-addon-web-widget-uom 14.0.1.0.1.dev3
File Interpreter ABI Platform
odoo14_addon_web_widget_uom-14.0.1.0.1.dev3-py3-none-any.whl Python 3 none any Details

Release files / odoo14_addon_web_widget_uom-14.0.1.0.1.dev3-py3-none-any.whl

Download URL odoo14_addon_web_widget_uom-14.0.1.0.1.dev3-py3-none-any.whl
Size 46.4 kB
Tags Python 3
SHA-256 checksum
How to use checksums
44827cf64426794769a460158adb2f3b17eb30965201efe9019c641411d4a15c
BLAKE2b-256 checksum
How to use checksums
3830fb5e3b1cd393ad262a3fb6cfc72d4d4f38b61ddaed71a40233c162723393
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.1 CPython/3.8.10
Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page