Daily updates from Odoo
Navigate
Branch
Wednesday, May 20, 2020
12 changes
New functionality added to Odoo
Studio users can now configure approval rules on form buttons, helping businesses require the right people to approve key actions before they happen. This gives small companies a simple way to add approval controls without custom development, though it applies only in form views and can be bypassed outside the web client.
Original PR description
Allow users to add approval rules on buttons through Studio. The rationale is that a lot of SMEs want to establish an approval process where doing an action on a record (typically through the use of…
Allow users to add approval rules on buttons through Studio. The rationale is that a lot of SMEs want to establish an approval process where doing an action on a record (typically through the use of a button) is limited to certain users (or must be approved by certain users). This commit add such a mechanism through the Studio application. The approval rules are stored through 2 models: - a `studio.approval.rule` model, which represents a single approval rule tied to a model and an action or method (e.g. `sale.order`/`action_confirm` or `sale.order`/298 where 298 is, say, the id of the window action of a wizard). An approval rule is linked to a group and a user can only it if they are a member of that group. - a `studio.approval.entry` model, which represents the approval (or rejection) of a rule for a specific record by a specific user. The main entry point for these models are: - `get_approval_spec` on `studio.approval.rule`, which returns a full description of the approval flow for a given action (and if the spec is requested for a specific record, also includes existing entries). - `check_approval` on `studio.approval.rule`, which checks whether the user can proceed with an action (method or action ID for a specific record); if some rules for the action have not yet been they will be automatically approved by the current user on the fly if they are allowed to approve them. - `set_approval` on `studio.approval.rule`, which records an entry for that rule (accepted or rejected) for a specific record. - `cancel_approval` on `studio.approval.rule`, which deletes an entry for that rule (accepted or rejected) for a specific record. On the client's side, several overrides have been added so that any click on a button which has been marked as being subject to approval through a `studio_approval` attribute on its node will first check server-side if the action can proceed through a call to `check_approval`; if the check is successful, the action proceeds; if not, it is stopped and a warning is displayed to the user. This commit also adds the necessary plumbing in `web_studio` to allow configuring these approval rules on any button of a form view. Current limitations of this implementation: - only buttons in form views support this mechanism - these checks are done through the web client only; a badly-intentioned user may bypass these checks through an rpc calls using their own credentials This is a simple feature made for quick and easy rules; any advanced use case should instead use automated actions based on complex rules - these will not be by-passable through rpc calls. But, for small companies that need a quick and easy way to restrict actions, this is a nice addition to Studio. Task-2092572 Community changes in odoo/odoo#48983
Odoo Studio users can now rearrange form tabs by dragging and dropping them. This makes it easier to customize screen layouts without developer support and keeps related information in the preferred order.
Original PR description
PURPOSE Allow the user to reorder tabs with the studio. task : 2157560
Enhancements to existing features
Gantt view items can now be dragged more smoothly, with a clearer visual preview showing where the item will land. This makes schedule adjustments easier and reduces uncertainty when moving tasks or bookings.
Original PR description
Purpose : The goal of this task is to make the drag & drop of the Gantt view smoother by having a continuous drag 'hovering over' the gantt view itself. even display the closest hovering hook with dashed border and with a transparent copy of the gantt pill being dragged like web studio. Spec : We have changed the drag function of draggable object with cloning and appending the dragged pill to the targetted hook with transparent copy. Task : 2205607
Email Marketing and Marketing Automation templates can now display company social media links even when the Website app is not installed. This ensures customers' social icons are populated from company information by default, while still using website-specific settings when available.
Original PR description
**PURPOSE:**
- Using Mass Mailing or Marketing Automation without website installed will not populate the links for your social media account.
- However, we do have those information on your company. We could then use those information to gather your social media links from your mass mailing.
**SPECIFICATION:**
- Currently social media icon details fetch from "Website" module > Settings > Social Media. But when customer doesn't have installed website module it does not display social media icons
Case: https://youtu.be/JOEZr5jJWAY
- Technical Details:
- add function for example "get_social_media_stuff" that will fetch details either from company setup information or website depends on installed application.
**LINKS:**
TaskID: 2036094
Closes https://github.com/odoo/enterprise/pull/10497This update changes how related records are included in several business reports so information is less likely to be unintentionally left out. It supports more complete reporting across sales, stock valuation, and website lead scoring while remaining mostly internal to the system.
Original PR description
Related to https://github.com/odoo/odoo/pull/49999.
Point of Sale can now use secure HTTPS connections in supported enterprise environments. This improves protection for POS traffic while preserving compatibility with IoT Box setups that still need special handling.
Original PR description
HTTPS had been disabled on SaaS to allow the use of the IoT Box that had no valid SSL certificate. As of V13.0, IoT Boxes connected to Enterprise DBs have a valid certificate. POS can then use HTTPS. Previously all requests made to `/pos/` URL we redirected to HTTP. We now set a cookie to differentiate in nginx POS requests that should not be redirected to HTTP. TaskID: 2191878
Code cleanup and technical improvements
Accounting-related actions that were only used by Enterprise have been moved from the community edition into the Enterprise accounting modules. This keeps the product structure cleaner and helps ensure accounting features are maintained in the edition where they are actually used.
Original PR description
Task [2201948](https://www.odoo.com/web#id=2201948&action=333&active_id=967&model=project.task&view_type=form&cids=1&menu_id=4720) Some actions were only used in enterprise but defined in community Linked PR: https://github.com/odoo/odoo/pull/46110
Miscellaneous changes
opw-[2256773](https://www.odoo.com/web#active_id=2256773&cids=1&id=2256773&menu_id=&model=project.task) The communication was sometimes shifted by one statement line because the reference matching check was sometimes done on the full coda line reference (8 digits) and sometimes on the first 4 digits. Forward-Port-Of: odoo/enterprise#10680
Original PR description
opw-[2256773](https://www.odoo.com/web#active_id=2256773&cids=1&id=2256773&menu_id=&model=project.task) The communication was sometimes shifted by one statement line because the reference matching check was sometimes done on the full coda line reference (8 digits) and sometimes on the first 4 digits. Forward-Port-Of: odoo/enterprise#10680
They should start with zero, see https://www.truugo.com/ubl/2.1/cl_unitofmeasure/ followup task# 2152487 Forward-Port-Of: odoo/enterprise#10687
Original PR description
They should start with zero, see https://www.truugo.com/ubl/2.1/cl_unitofmeasure/ followup task# 2152487 Forward-Port-Of: odoo/enterprise#10687
Forward port 65f0c0d (merged in saas-13.3) of commit 8a89528 (merged in 13.0) was not correctly adapted for the salary configurator internationalization introduced in saas-13.3. The `car_id` field is specific to the Belgian payroll which is no longer a dependency of `hr_contract_salary`. Forward-Port-Of: odoo/enterprise#10684
Original PR description
Forward port 65f0c0d (merged in saas-13.3) of commit 8a89528 (merged in 13.0) was not correctly adapted for the salary configurator internationalization introduced in saas-13.3. The `car_id` field is specific to the Belgian payroll which is no longer a dependency of `hr_contract_salary`. Forward-Port-Of: odoo/enterprise#10684
In studio, when we edit a sub x2many view that is not embedded, we duplicate the default view and embed it. This work fine by default, but it can be odd in case the particular view is using eg. a specific view thanks to a tree_view_ref context key on the x2many field, then editing it could totally change the content since we duplicate the default view and not the real view that was being displayed. With this changeset, we instead duplicate tree_view_ref if it is available. opw-2251643 Forwar
Original PR description
In studio, when we edit a sub x2many view that is not embedded, we duplicate the default view and embed it. This work fine by default, but it can be odd in case the particular view is using eg. a specific view thanks to a tree_view_ref context key on the x2many field, then editing it could totally change the content since we duplicate the default view and not the real view that was being displayed. With this changeset, we instead duplicate tree_view_ref if it is available. opw-2251643 Forward-Port-Of: odoo/enterprise#10508
MapBox's Legacy Static Images API seems to be soon to be retired: https://blog.mapbox.com/deprecating-studio-classic-styles-d8892ac38cb4 So eg. for new customer it seems that the tiles would not show, and after first June the API is soon to be totally retired. So this commit follow advices for migrating to use "Mapbox Static Tiles API" instead given in: https://docs.mapbox.com/help/troubleshooting/migrate-legacy-static-tiles-api/ opw-2243126 Forward-Port-Of: odoo/enterprise#10582 Forward-Por
Original PR description
MapBox's Legacy Static Images API seems to be soon to be retired: https://blog.mapbox.com/deprecating-studio-classic-styles-d8892ac38cb4 So eg. for new customer it seems that the tiles would not show, and after first June the API is soon to be totally retired. So this commit follow advices for migrating to use "Mapbox Static Tiles API" instead given in: https://docs.mapbox.com/help/troubleshooting/migrate-legacy-static-tiles-api/ opw-2243126 Forward-Port-Of: odoo/enterprise#10582 Forward-Port-Of: odoo/enterprise#10570