Repository navigation
[20.0][MIG] project_task_description_template: Migration to 20.0 - #1894
AyushPatel2021 wants to merge 32 commits into
Conversation
…tion templates for project tasks [BOT] post-merge updates
[UPD] Update project_task_description_template.pot [BOT] post-merge updates
Translated using Weblate (Spanish) Currently translated at 100.0% (16 of 16 strings) Translation: project-17.0/project-17.0-project_task_description_template Translate-URL: https://translation.odoo-community.org/projects/project-17-0/project-17-0-project_task_description_template/es/
[UPD] Update project_task_description_template.pot [BOT] post-merge updates
Updated by "Update PO files to match POT (msgmerge)" hook in Weblate. Translation: project-19.0/project-19.0-project_task_description_template Translate-URL: https://translation.odoo-community.org/projects/project-19-0/project-19-0-project_task_description_template/
Currently translated at 100.0% (17 of 17 strings) Translation: project-19.0/project-19.0-project_task_description_template Translate-URL: https://translation.odoo-community.org/projects/project-19-0/project-19-0-project_task_description_template/it/
Updated by "Update PO files to match POT (msgmerge)" hook in Weblate. Translation: project-19.0/project-19.0-project_task_description_template Translate-URL: https://translation.odoo-community.org/projects/project-19-0/project-19-0-project_task_description_template/
Currently translated at 100.0% (18 of 18 strings) Translation: project-19.0/project-19.0-project_task_description_template Translate-URL: https://translation.odoo-community.org/projects/project-19-0/project-19-0-project_task_description_template/it/
…eld wrapping The two onchange tests pinned the exact wrapper tag of the appended template text. Odoo core flips that wrapper between releases (<span> <-> <p>), so the hard-coded assertions break on every change. Compare against the template's own stored Html value instead, so both sides track whatever core produces.
Currently translated at 100.0% (18 of 18 strings) Translation: project-19.0/project-19.0-project_task_description_template Translate-URL: https://translation.odoo-community.org/projects/project-19-0/project-19-0-project_task_description_template/de/
Currently translated at 100.0% (18 of 18 strings) Translation: project-19.0/project-19.0-project_task_description_template Translate-URL: https://translation.odoo-community.org/projects/project-19-0/project-19-0-project_task_description_template/it/
The template field was not stored since the module was created, so the template used on a task was lost after saving it.
Templates can be linked to projects, so each project only proposes its own templates and the ones without projects.
Portal users can select the templates of their projects in the project sharing views, and a project can require them to select one on every new task.
Updated by "Update PO files to match POT (msgmerge)" hook in Weblate. Translation: project-19.0/project-19.0-project_task_description_template Translate-URL: https://translation.odoo-community.org/projects/project-19-0/project-19-0-project_task_description_template/
Currently translated at 100.0% (28 of 28 strings) Translation: project-19.0/project-19.0-project_task_description_template Translate-URL: https://translation.odoo-community.org/projects/project-19-0/project-19-0-project_task_description_template/it/
|
Hello @leemannd @ThiagoMForgeFlow @LoisRForgeFlow @CristianoMafraJunior, could you please review this migration of project_task_description_template to 20.0? Details are in the description. |
| access_model_project_task_description_template_user,access_model_project_task_description_template_user,project.task.description.template,project.group_project_user,r, | ||
| access_model_project_task_description_template_portal,Project Task Description Template: portal users,project.task.description.template,base.group_portal,r,"[ | ||
| ('project_ids', 'any', [ | ||
| ('privacy_visibility', '=', 'portal'), |
There was a problem hiding this comment.
In 20.0 invited_users is also a portal sharing mode, and core checks both (see the project, task and milestone portal rules). I think this rule should be: "('privacy_visibility', 'in', ['invited_users', 'portal'])"
| def _check_portal_task_description_template_required(self): | ||
| for project in self: | ||
| if ( | ||
| project.privacy_visibility == "portal" |
There was a problem hiding this comment.
Same here, considere "invited_users" new option.
- ir.model.access.csv and the record rules become ir.access.csv: the portal rule is now the domain of the portal read access, the company rule a restriction without group (same access as before). - Treat "invited_users" projects like "portal" ones, as core does: the portal access domain, the required template check and the project settings. - Tests: in 20.0 a portal project's partner is already a "view" collaborator, and new collaborators default to "view", so the test setup gives the portal user "edit" access instead of adding a duplicate collaborator. - Tests: cover the access rows (users read, managers create, company restriction), the unlink of a template and "invited_users" projects. Assisted-by: Claude Opus 5.5
605a282 to
f1af5e4
Compare
|
thanks, good catch. invited_users is now handled like portal in the access domain, the required template check and the project settings, with a test for it. folded into the migration commit. |
|
Ready to merge @leemannd: 2 approvals and CI is green. Thanks! |
Migration of project_task_description_template to 20.0.
Part of #1828
Assisted-by: Claude Opus 5.5