upgrade-util icon indicating copy to clipboard operation
upgrade-util copied to clipboard

[FIX] util/method: added variable to add_view

Open ammu-odoo opened this issue 1 year ago • 2 comments

Description:

The util method add_view was previously used to create views for view_type such as form, tree, and qweb. However, it lacked support for setting the website_id, which limited its ability to create website-specific views.

This PR introduces a new website_id parameter to the add_view method. By adding this parameter, the method can now be used to create views specific to a website, enabling the creation of both backend views (form, tree, qweb) and frontend website views.

Changes:

  • Added website_id parameter to the add_view method.
  • Adjusted the SQL query to include website_id where applicable.
  • Website views can now be created using this method by passing the appropriate website_id.

This enhancement makes the add_view method more flexible, supporting both regular and website-specific views.

ammu-odoo avatar Sep 16 '24 13:09 ammu-odoo

Pull request status dashboard

robodoo avatar Sep 16 '24 13:09 robodoo

This doesn't work. The key website_id is not used in the query. Note that the column website_id isn't always present.

KangOl avatar Sep 19 '24 14:09 KangOl