server-backend icon indicating copy to clipboard operation
server-backend copied to clipboard

[19.0][MIG] base_user_role_company: Migration to 19.0

Open tishmen opened this issue 2 months ago • 1 comments

Scope

  • base_user_role_company only

Summary

  • Migrate to Odoo 19.0 following OCA guide.
  • Override parent unique constraint with company-aware one: UNIQUE(user_id, role_id, company_id).
  • Tests aligned with 19.0 (group_ids API).

Pre-commit

  • Verified locally; no additional changes applied beyond auto-fixes.

Temporary dependency

  • Added a temporary reference in root test-requirements.txt to install base_user_role from the PR ref, per OCA guidelines.

Tests

Command:

./odoo/odoo-bin -c odoo.conf -d bur19_tests_burco -i base_user_role,base_user_role_company --test-enable --test-tags "/base_user_role_company" --without-demo=all --log-level=info --stop-after-init

Result: green locally.

Depends on:

  • [ ] https://github.com/OCA/server-backend/pull/382

tishmen avatar Oct 09 '25 13:10 tishmen

Depends on #382.

Temporary dependency

  • Added a temporary reference in test-requirements.txt to install base_user_role from #382 (per OCA wiki above). This commit will be removed after the base PR merges.

Highlights

  • Unique constraint overridden to UNIQUE (user_id, role_id, company_id).
  • Company‑aware role enablement honored via active_company_ids.
  • Local tests green. Command used:
./odoo/odoo-bin -c odoo.conf -d bur19_tests_burco -i base_user_role,base_user_role_company --test-enable --test-tags "/base_user_role_company" --without-demo=all --log-level=info --stop-after-init

Maintainers ping

  • @dreispt (module), @sebalix @jcdrubay @novawish (base visibility).

Kept as draft until #382 is approved/merged; can flip to ready on request.

tishmen avatar Oct 09 '25 13:10 tishmen