Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
125 changes: 125 additions & 0 deletions project_task_description_portal/README.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,125 @@
.. image:: https://odoo-community.org/readme-banner-image
:target: https://odoo-community.org/get-involved?utm_source=readme
:alt: Odoo Community Association

=======================
Task Description Portal
=======================

..
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
!! This file is generated by oca-gen-addon-readme !!
!! changes will be overwritten. !!
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
!! source digest: sha256:55e80ba6201112a988c371689ef7571f36368b8993001e9ec73a0a7afbece80b
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!

.. |badge1| image:: https://img.shields.io/badge/maturity-Beta-yellow.png
:target: https://odoo-community.org/page/development-status
:alt: Beta
.. |badge2| image:: https://img.shields.io/badge/license-AGPL--3-blue.png
:target: http://www.gnu.org/licenses/agpl-3.0-standalone.html
:alt: License: AGPL-3
.. |badge3| image:: https://img.shields.io/badge/github-OCA%2Fproject-lightgray.png?logo=github
:target: https://github.com/OCA/project/tree/19.0/project_task_description_portal
:alt: OCA/project
.. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png
:target: https://translation.odoo-community.org/projects/project-19-0/project-19-0-project_task_description_portal
:alt: Translate me on Weblate
.. |badge5| image:: https://img.shields.io/badge/runboat-Try%20me-875A7B.png
:target: https://runboat.odoo-community.org/builds?repo=OCA/project&target_branch=19.0
:alt: Try me on Runboat

|badge1| |badge2| |badge3| |badge4| |badge5|

This module allows to add a dedicated task description that will be
shown to portal users.

**Table of contents**

.. contents::
:local:

Use Cases / Context
===================

Sometimes you need to provide a separate task description for portal
users. Eg original description contains some confidential information or
is simply too technical for a client.

Configuration
=============

No configuration is required.

Usage
=====

On the task form enable the "Use Portal Description" checkbox located in
the "Description" tab of the notebook.

|Use Portal Description|

A new tab "Portal Description" will become visible. Put task description
that you would like to show to portal users in that tab.

|Portal Description|

If "Use Portal Description" is disabled standard task description will
be show to portal users as before.

|Portal View|

.. |Use Portal Description| image:: https://raw.githubusercontent.com/OCA/project/19.0/project_task_description_portal/static/description/img/use_portal_description.png
.. |Portal Description| image:: https://raw.githubusercontent.com/OCA/project/19.0/project_task_description_portal/static/description/img/portal_description.png
.. |Portal View| image:: https://raw.githubusercontent.com/OCA/project/19.0/project_task_description_portal/static/description/img/portal_view.png

Known issues / Roadmap
======================

TODO

Would be nice to have this feature working for projects shared in "Edit
mode".

Bug Tracker
===========

Bugs are tracked on `GitHub Issues <https://github.com/OCA/project/issues>`_.
In case of trouble, please check there if your issue has already been reported.
If you spotted it first, help us to smash it by providing a detailed and welcomed
`feedback <https://github.com/OCA/project/issues/new?body=module:%20project_task_description_portal%0Aversion:%2019.0%0A%0A**Steps%20to%20reproduce**%0A-%20...%0A%0A**Current%20behavior**%0A%0A**Expected%20behavior**>`_.

Do not contact contributors directly about support or help with technical issues.

Credits
=======

Authors
-------

* Cetmix

Contributors
------------

Cetmix https://www.cetmix.com

- Ivan Sokolov

Maintainers
-----------

This module is maintained by the OCA.

.. image:: https://odoo-community.org/logo.png
:alt: Odoo Community Association
:target: https://odoo-community.org

OCA, or the Odoo Community Association, is a nonprofit organization whose
mission is to support the collaborative development of Odoo features and
promote its widespread use.

This module is part of the `OCA/project <https://github.com/OCA/project/tree/19.0/project_task_description_portal>`_ project on GitHub.

You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute.
1 change: 1 addition & 0 deletions project_task_description_portal/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
from . import models
16 changes: 16 additions & 0 deletions project_task_description_portal/__manifest__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
{
"name": "Task Description Portal",
"summary": "Dedicated task description for portal users",
"version": "19.0.1.0.0",
"category": "Project",
"website": "https://github.com/OCA/project",
"author": "Cetmix, Odoo Community Association (OCA)",
"license": "AGPL-3",
"depends": ["project"],
"data": [
"views/project_task_views.xml",
"views/project_portal_templates.xml",
],
"installable": True,
"application": False,
}
1 change: 1 addition & 0 deletions project_task_description_portal/controllers/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
from . import portal
12 changes: 12 additions & 0 deletions project_task_description_portal/controllers/portal.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
# Copyright (C) 2025 Cetmix OÜ
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
from odoo.addons.project.controllers.portal import ProjectCustomerPortal


class ProjectCustomerPortalInherit(ProjectCustomerPortal):
def _task_get_page_view_values(self, task, access_token, **kwargs):
"""Override to return portal description if enabled."""
values = super()._task_get_page_view_values(task, access_token, **kwargs)
if task.use_portal_description:
values["description"] = task.portal_description
return values
56 changes: 56 additions & 0 deletions project_task_description_portal/i18n/it.po
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
# Translation of Odoo Server.
# This file contains the translation of the following modules:
# * project_task_description_portal
#
msgid ""
msgstr ""
"Project-Id-Version: Odoo Server 16.0\n"
"Report-Msgid-Bugs-To: \n"
"PO-Revision-Date: 2025-03-18 19:06+0000\n"
"Last-Translator: mymage <stefano.consolaro@mymage.it>\n"
"Language-Team: none\n"
"Language: it\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: \n"
"Plural-Forms: nplurals=2; plural=n != 1;\n"
"X-Generator: Weblate 5.10.2\n"

#. module: project_task_description_portal
#: model_terms:ir.ui.view,arch_db:project_task_description_portal.view_task_form2_inherit
msgid "Add a description for portal users..."
msgstr "Aggiungi una descrizione per utenti portale..."

#. module: project_task_description_portal
#: model:ir.model.fields,help:project_task_description_portal.field_project_task__portal_description
msgid ""
"Description that will be shown to portal users if 'Use Portal Description' "
"is enabled"
msgstr ""
"Descrizione che verrà visualizzata dagli utenti portale se 'Usa descrizione "
"portale' è abilitata"

#. module: project_task_description_portal
#: model:ir.model.fields,help:project_task_description_portal.field_project_task__use_portal_description
msgid ""
"If enabled, portal users will see the portal description instead of the "
"standard one"
msgstr ""
"Se abilitata, gli utenti portale vedranno la descrizione portale al posto di "
"quella standard"

#. module: project_task_description_portal
#: model:ir.model.fields,field_description:project_task_description_portal.field_project_task__portal_description
#: model_terms:ir.ui.view,arch_db:project_task_description_portal.view_task_form2_inherit
msgid "Portal Description"
msgstr "Descrizione portale"

#. module: project_task_description_portal
#: model:ir.model,name:project_task_description_portal.model_project_task
msgid "Task"
msgstr "Lavoro"

#. module: project_task_description_portal
#: model:ir.model.fields,field_description:project_task_description_portal.field_project_task__use_portal_description
msgid "Use Portal Description"
msgstr "Usa descrizione portale"
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
# Translation of Odoo Server.
# This file contains the translation of the following modules:
# * project_task_description_portal
#
msgid ""
msgstr ""
"Project-Id-Version: Odoo Server 18.0\n"
"Report-Msgid-Bugs-To: \n"
"Last-Translator: \n"
"Language-Team: \n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: \n"
"Plural-Forms: \n"

#. module: project_task_description_portal
#: model_terms:ir.ui.view,arch_db:project_task_description_portal.view_task_form2_inherit
msgid "Add a description for portal users..."
msgstr ""

#. module: project_task_description_portal
#: model:ir.model.fields,help:project_task_description_portal.field_project_task__portal_description
msgid ""
"Description that will be shown to portal users if 'Use Portal Description' "
"is enabled"
msgstr ""

#. module: project_task_description_portal
#: model:ir.model.fields,help:project_task_description_portal.field_project_task__use_portal_description
msgid ""
"If enabled, portal users will see the portal description instead of the "
"standard one"
msgstr ""

#. module: project_task_description_portal
#: model:ir.model.fields,field_description:project_task_description_portal.field_project_task__portal_description
#: model_terms:ir.ui.view,arch_db:project_task_description_portal.view_task_form2_inherit
msgid "Portal Description"
msgstr ""

#. module: project_task_description_portal
#: model:ir.model,name:project_task_description_portal.model_project_task
msgid "Task"
msgstr ""

#. module: project_task_description_portal
#: model:ir.model.fields,field_description:project_task_description_portal.field_project_task__use_portal_description
msgid "Use Portal Description"
msgstr ""
56 changes: 56 additions & 0 deletions project_task_description_portal/i18n/pt.po
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
# Translation of Odoo Server.
# This file contains the translation of the following modules:
# * project_task_description_portal
#
msgid ""
msgstr ""
"Project-Id-Version: Odoo Server 16.0\n"
"Report-Msgid-Bugs-To: \n"
"PO-Revision-Date: 2025-03-17 18:07+0000\n"
"Last-Translator: Peter Romão <peterromao@yahoo.co.uk>\n"
"Language-Team: none\n"
"Language: pt\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: \n"
"Plural-Forms: nplurals=2; plural=n > 1;\n"
"X-Generator: Weblate 5.10.2\n"

#. module: project_task_description_portal
#: model_terms:ir.ui.view,arch_db:project_task_description_portal.view_task_form2_inherit
msgid "Add a description for portal users..."
msgstr "Adicionar uma descrição para utilizadores de portal..."

#. module: project_task_description_portal
#: model:ir.model.fields,help:project_task_description_portal.field_project_task__portal_description
msgid ""
"Description that will be shown to portal users if 'Use Portal Description' "
"is enabled"
msgstr ""
"Descrição que será exibida aos utilizadores de portal caso 'Utilizar "
"Descrição de Portal' esteja habilitado"

#. module: project_task_description_portal
#: model:ir.model.fields,help:project_task_description_portal.field_project_task__use_portal_description
msgid ""
"If enabled, portal users will see the portal description instead of the "
"standard one"
msgstr ""
"Se ativado, os utilizadores de portal verão a descrição para portal em vez "
"da padrão"

#. module: project_task_description_portal
#: model:ir.model.fields,field_description:project_task_description_portal.field_project_task__portal_description
#: model_terms:ir.ui.view,arch_db:project_task_description_portal.view_task_form2_inherit
msgid "Portal Description"
msgstr "Descrição de Portal"

#. module: project_task_description_portal
#: model:ir.model,name:project_task_description_portal.model_project_task
msgid "Task"
msgstr "Tarefa"

#. module: project_task_description_portal
#: model:ir.model.fields,field_description:project_task_description_portal.field_project_task__use_portal_description
msgid "Use Portal Description"
msgstr "Utilizar Descrição de Portal"
1 change: 1 addition & 0 deletions project_task_description_portal/models/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
from . import project_task
17 changes: 17 additions & 0 deletions project_task_description_portal/models/project_task.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
# Copyright (C) 2025 Cetmix OÜ
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
from odoo import fields, models


class ProjectTask(models.Model):
_inherit = "project.task"

use_portal_description = fields.Boolean(
help="If enabled, portal users will see the portal description"
" instead of the standard one",
)
portal_description = fields.Html(
sanitize_attributes=False,
help="Description that will be shown to portal users if "
"'Use Portal Description' is enabled",
)
3 changes: 3 additions & 0 deletions project_task_description_portal/pyproject.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
[build-system]
requires = ["whool"]
build-backend = "whool.buildapi"
1 change: 1 addition & 0 deletions project_task_description_portal/readme/CONFIGURE.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
No configuration is required.
1 change: 1 addition & 0 deletions project_task_description_portal/readme/CONTEXT.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Sometimes you need to provide a separate task description for portal users. Eg original description contains some confidential information or is simply too technical for a client.
3 changes: 3 additions & 0 deletions project_task_description_portal/readme/CONTRIBUTORS.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
Cetmix <https://www.cetmix.com>

- Ivan Sokolov
1 change: 1 addition & 0 deletions project_task_description_portal/readme/DESCRIPTION.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
This module allows to add a dedicated task description that will be shown to portal users.
3 changes: 3 additions & 0 deletions project_task_description_portal/readme/ROADMAP.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
TODO

Would be nice to have this feature working for projects shared in "Edit mode".
11 changes: 11 additions & 0 deletions project_task_description_portal/readme/USAGE.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
On the task form enable the "Use Portal Description" checkbox located in the "Description" tab of the notebook.

![Use Portal Description](../static/description/img/use_portal_description.png)

A new tab "Portal Description" will become visible. Put task description that you would like to show to portal users in that tab.

![Portal Description](../static/description/img/portal_description.png)

If "Use Portal Description" is disabled standard task description will be show to portal users as before.

![Portal View](../static/description/img/portal_view.png)
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Loading