Skip to content

[20.0][MIG] base_tier_validation: Migration to 20.0 - #94

Open
Pani-k-folk wants to merge 290 commits into
OCA:20.0from
ecosoft-odoo:20.0-mig-base_tier_validation
Open

Pani-k-folk wants to merge 290 commits into
OCA:20.0from
ecosoft-odoo:20.0-mig-base_tier_validation

Conversation

@Pani-k-folk

@Pani-k-folk Pani-k-folk commented Oct 8, 2026 •

Copy link
Copy Markdown

Changes

  • Security: ir.model.access and ir.rule were merged into ir.access. Converted to security/ir.access.csv; the multi-company rules are now group-less restriction rows that keep their original xmlids.
  • OWL 3: useState → proxy, and component variables in templates now use this..
  • Icons: Font Awesome is no longer loaded in the backend. Switched to Material Symbols (oi + data-icon). A post-migration script updates the reminder activity type icon (fa-bell → notifications), because that record is noupdate.
  • Tests: BaseCommon now runs as a plain internal user, so this module sets _test_user_groups = None. Test ACLs now use ir.access.
  • ORM: Query.subselect() only accepts SQL arguments, and the reviewer_ids search no longer builds != [False].
  • Lint: fixes for ruff 0.16 and pylint-odoo 10

Assisted-by: Claude Opus 5.5 (migration changes were reviewed and tested by me)

etobella and others added 30 commits October 8, 2026 14:39
Currently translated at 80.0% (60 of 75 strings)

Translation: server-ux-13.0/server-ux-13.0-base_tier_validation
Translate-URL: https://translation.odoo-community.org/projects/server-ux-13-0/server-ux-13-0-base_tier_validation/es/
- When use approve by sequence, still approve tier of the same reviewer
- When using approve_sequence option in any tier.definition there can be inconsistencies in the systray notifications
Currently translated at 96.1% (73 of 76 strings)

Translation: server-ux-13.0/server-ux-13.0-base_tier_validation
Translate-URL: https://translation.odoo-community.org/projects/server-ux-13-0/server-ux-13-0-base_tier_validation/zh_CN/
This commit splits the state condition checking
part into another method, allowing inheriting
modules to override the conditions as needed.
Currently translated at 87.3% (76 of 87 strings)

Translation: server-ux-14.0/server-ux-14.0-base_tier_validation
Translate-URL: https://translation.odoo-community.org/projects/server-ux-14-0/server-ux-14-0-base_tier_validation/es/
…ications from requested tier validations

TT29001
@OCA-git-bot OCA-git-bot added mod:base_tier_validation Module base_tier_validation series:20.0 labels Oct 8, 2026
@Pani-k-folk
Pani-k-folk marked this pull request as ready for review October 8, 2026 08:55
@Pani-k-folk
Pani-k-folk force-pushed the 20.0-mig-base_tier_validation branch from fdc7a73 to 3cffdb1 Compare October 8, 2026 09:21
@bosd

bosd commented Oct 9, 2026

Copy link
Copy Markdown
Contributor

Hi @Pani-k-folk, thanks for starting the 20.0 migration! Heads-up: there's still a batch of 19.0 PRs for base_tier_validation in review (overview in #96). If some get merged while this is open, they'll need to come along with the migration, or be ported afterwards with oca-port. Happy to help with that.

@Pani-k-folk

Copy link
Copy Markdown
Author

Thanks @bosd, and thanks for the overview in #96!

If any of those 19.0 PRs get merged before this one, please leave a comment here. If I have time, I'll bring them into this branch. If I'm busy, feel free to forward-port them with oca-port afterwards, as you suggested.

@bybc19

bybc19 commented Oct 12, 2026

Copy link
Copy Markdown

Two Owl 3 issues on Odoo 20 at commit eac2ae9 (base_tier_validation):

  1. TierReviewMenu: the webclient fails to start with
    Component "TierReviewMenu" defines a static "props" or "defaultProps", which Owl 3 ignores.
    The component consumes no props, so removing static props = []; is enough
    (same pattern as the native Odoo 20 ActivityMenu systray item).

  2. ReviewsTable (form.tier_validation field widget): the component reads this.props.record
    but never binds props. Under Owl 3 this.props is undefined and opening any form that
    shows the review table fails with
    TypeError: Cannot read properties of undefined (reading 'record')
    Binding the standard field props, as native Odoo 20 field widgets do
    (e.g. BooleanField: props = useProps(booleanFieldProps)), fixes it.

--- a/base_tier_validation/static/src/components/tier_review_menu/tier_review_menu.esm.js
+++ b/base_tier_validation/static/src/components/tier_review_menu/tier_review_menu.esm.js
@@ -8,7 +8,6 @@
 export class TierReviewMenu extends Component {
     static components = {Dropdown};
-    static props = [];
     static template = "base_tier_validation.TierReviewMenu";

--- a/base_tier_validation/static/src/components/tier_review_widget/tier_review_widget.esm.js
+++ b/base_tier_validation/static/src/components/tier_review_widget/tier_review_widget.esm.js
@@ -1,8 +1,11 @@
-import {Component, proxy} from "@odoo/owl";
+import {Component, proxy, useProps} from "@odoo/owl";
 import {registry} from "@web/core/registry";
+import {standardFieldProps} from "@web/views/fields/standard_field_props";
 import {useService} from "@web/core/utils/hooks";

 export class ReviewsTable extends Component {
+    props = useProps(standardFieldProps);
+
     setup() {

With both changes the review table renders on purchase orders, transfers and manufacturing
orders in browser runs (console clean). This only covers the two errors above; it is not a
claim that every tier validation UI flow has been verified.

@Pani-k-folk
Pani-k-folk force-pushed the 20.0-mig-base_tier_validation branch from eac2ae9 to b45d5fb Compare October 14, 2026 02:25
@Pani-k-folk

Copy link
Copy Markdown
Author

Thanks @bybc19 for the detailed report and the patch!
Both fixes are now included in the migration commit (b45d5fb).

While re-checking against current OCB, I also declared tierReviewCounter and tierReviewGroups as mail.store fields through a small Store patch, the same way core declares activityCounter. In Odoo 20 the store is no longer a reactive Proxy, so this keeps the systray badge reactive. It also gives tierReviewGroups a [] default, so opening the systray before the first fetch no longer crashes.

Tested on current OCB 20.0 (405561c46) with invoices, in both normal and debug=assets mode

@BhaveshHeliconia BhaveshHeliconia left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

mod:base_tier_validation Module base_tier_validation series:20.0

Projects

None yet

Development

Successfully merging this pull request may close these issues.