Odoo 16 Development Book

Bundles

Odoo assets are grouped by bundles, where each bundle can be a list of different file paths for specific asset types such as XML, JS, CSS, and SCSS. Bundles are listed in the Odoo module's manifest file. These files use a global syntax, so one line declares the various files containing the assets. Adding a bundle to your module's __manifest__ file keeps important assets private, including dictionaries. The most important things in the various dictionaries are the names and values of the secret bundles and the list of files they contain. It will be as follows.

'assets': {
   'web.assets_common': [
       'web/static/lib/bootstrap/**/*',
       'web/static/src/js/boot.js',
       'web/static/ src/js/webclient.js',
   ],
   'web.assets_backend': [
       'web/static/src/xml/**/*',
   ],
   'web.assets_frontend': [
       'web/ static/src/scss/style.scss',
       'web/static/src/js/custom.js',
   ],
   'web.assets_qweb': [
       'web/static/src/xml/templates.xml',
   ],
   'web.qunit_suite_tests': [
       'web/static/src/js/webclient_tests.js',
   ],
   'web.qunit_mobile_suite_tests': [
       'web/static/tests/mock_tests.js',
   ],
},

    1. web.assets_common:

    This bundle contains the most common assets for web clients, websites, and POS. It should contain the sub-building blocks of the Odoo framework. Note that we have included a boot.js file that defines the Odoo module system.

    2. web.assets_backend:

    This bundle contains specific code for the web client (specifically his web client/action manager/view).

    3. web.assets_frontend:

    This bundle contains specific code for the public website (specifically for eCommerce, portal, forum, blog, etc.).

    4. web.assets_qweb:

    All static XML templates are used in the backend environment and POS.

    5. web.qunit_suite_tests:

    All JavaScript unit test code (tests, helpers, mocks).

    6. web.qunit_mobile_suite_tests:

    Mobile-specific unit test code.

location

Calicut

Cybrosys Technologies Pvt. Ltd.
Neospace, Kinfra Techno Park
Kakkancherry, Calicut
Kerala, India - 673635

location

Kochi

Cybrosys Technologies Pvt. Ltd.
1st Floor, Thapasya Building,
Infopark, Kakkanad,
Kochi, India - 682030.

location

Bangalore

Cybrosys Techno Solutions
The Estate, 8th Floor,
Dickenson Road,
Bangalore, India - 560042

Send Us A Message