[MIG] project_assignees : migrate to 16.0

This commit is contained in:
Boris Gallet
2023-11-02 09:14:47 +01:00
parent e6595ec6f7
commit 15b21771dd
4 changed files with 29 additions and 25 deletions

View File

@@ -3,7 +3,7 @@
{
"name": "project_assignees",
"version": "14.0.1.1.0",
"version": "16.0.1.1.0",
"author": "Elabore",
"website": "https://github.com/elabore-coop/project-tools",
"maintainer": "Stéphan Sainléger",
@@ -69,6 +69,7 @@ This module is maintained by Elabore.
"depends": [
"base",
"project",
"project_task_portal_form",
],
"qweb": [
# "static/src/xml/*.xml",

View File

@@ -4,10 +4,10 @@
#
msgid ""
msgstr ""
"Project-Id-Version: Odoo Server 14.0\n"
"Project-Id-Version: Odoo Server 16.0\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2022-07-26 07:38+0000\n"
"PO-Revision-Date: 2022-07-26 07:38+0000\n"
"POT-Creation-Date: 2023-11-02 07:56+0000\n"
"PO-Revision-Date: 2023-11-02 07:56+0000\n"
"Last-Translator: \n"
"Language-Team: \n"
"MIME-Version: 1.0\n"
@@ -16,17 +16,21 @@ msgstr ""
"Plural-Forms: \n"
#. module: project_assignees
#: model_terms:ir.ui.view,arch_db:project_assignees.portal_my_task_timebox
msgid "<strong>Other assignements</strong>"
#: model_terms:ir.ui.view,arch_db:project_assignees.portal_my_task_assignees
msgid "<strong>Other assignees</strong>"
msgstr "<strong>Autres intervenants</strong>"
#. module: project_assignees
#: model:ir.model.fields,field_description:project_assignees.field_project_task__assignee_ids |
msgid "Assignees" |
#: model:ir.model.fields,field_description:project_assignees.field_project_task__assignee_ids
msgid "Assignees"
msgstr "Autres assignations"
#. module: project_assignees
#: model_terms:ir.ui.view,arch_db:project_assignees.portal_my_task_assignees
msgid "Contact"
msgstr ""
#. module: project_assignees
#: model:ir.model,name:project_assignees.model_project_task
msgid "Task"
msgstr "Tâche"

View File

@@ -1,21 +1,20 @@
<?xml version="1.0" encoding="utf-8"?>
<odoo>
<template id="portal_my_task_assignees" name="My Task: Assignees" inherit_id="project.portal_my_task" priority="40">
<xpath expr="//div[hasclass('flex-grow-0')]/../../.." position="inside">
<div class="col-12 col-md-6 pb-2" t-if="task.assignee_ids">
<xpath expr="//t[@t-foreach='task.user_ids']" position="after">
<div class="col-12 col-md-12 pb-2" t-if="task.assignee_ids">
<strong>Other assignees</strong>
<div class="row">
<t t-foreach="task.assignee_ids" t-as="assignee">
<div class="col flex-grow-0 pr-3">
<img t-if="assignee.image" class="rounded-circle mt-1 o_portal_contact_img" t-att-src="image_data_uri(assignee.image)" alt="Contact" />
<img t-else="" class="rounded-circle mt-1 o_portal_contact_img" src="/web/static/src/img/user_menu_avatar.png" alt="Contact" />
<t t-foreach="task.assignee_ids" t-as="user">
<div class="d-flex mb-3 flex-nowrap">
<img class="rounded-circle mt-1 o_portal_contact_img" t-att-src="image_data_uri(user.avatar_1024)" alt="Contact"/>
<div class="ms-2">
<div t-esc="user" t-options='{"widget": "contact", "fields": ["name"]}'/>
<a t-attf-href="tel:{{user.phone}}" t-if="user.phone"><div t-esc="user" t-options='{"widget": "contact", "fields": ["phone"]}'/></a>
<a t-if="user.email" class="text-break" t-attf-href="mailto:{{user.email}}">
<div t-out="user" t-options='{"widget": "contact", "fields": ["email"]}'/>
</a>
</div>
<div class="col pl-md-0">
<strong>
<span t-field="assignee.name" />
</strong>
<span t-field="assignee.email" />
<span t-field="assignee.phone" />
</div>
</t>
</div>

View File

@@ -6,7 +6,7 @@
<field name="inherit_id" ref="project.view_task_form2" />
<field name="priority" eval="99" />
<field name="arch" type="xml">
<xpath expr="//field[@name='user_id']" position="after">
<xpath expr="//field[@name='user_ids']" position="after">
<field name="assignee_ids" widget="many2many_tags" />
</xpath>
</field>
@@ -19,7 +19,7 @@
<field name="priority" eval="99" />
<field name="arch" type="xml">
<filter name="my_tasks" position="attributes">
<attribute name="domain">['|', ('user_id', '=', uid), ('assignee_ids', 'in', uid)]</attribute>
<attribute name="domain">['|', ('user_ids', 'in', uid), ('assignee_ids', 'in', uid)]</attribute>
</filter>
<xpath expr="//field[@name='partner_id']" position="after">
<field name="assignee_ids" filter_domain="[('assignee_ids.user_ids.name', 'ilike', self)]"/>