Skip to content

[18.0][MIG] server_action_navigate: Migration to 18.0 #355

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 24 commits into
base: 18.0
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
24 commits
Select commit Hold shift + click to select a range
4dd0ec8
[ADD] server_action_navigate
legalsylvain Feb 25, 2020
8e4acb4
[IMP] server_action_navigate: black, isort, prettier
Nov 10, 2021
fd87fc3
[MIG] server_action_navigate: Migration to 13.0
Nov 16, 2021
d71b060
[FIX] server_action_navigate: fix default order in ir_action_server_n…
Nov 16, 2021
c7fc565
[IMP] server_action_navigate: black, isort, prettier
AshishHirapara Mar 17, 2022
492896c
[MIG] server_action_navigate: Migration to 14.0
AshishHirapara Mar 17, 2022
02ba2db
[UPD] Update server_action_navigate.pot
oca-travis Jul 5, 2022
828ea63
[UPD] README.rst
OCA-git-bot Jul 5, 2022
d6173ce
server_action_navigate 14.0.1.0.1
OCA-git-bot Jul 5, 2022
7bf7e97
FIX depenedencies in view
flotho Aug 19, 2022
5833b61
Update __manifest__.py
flotho Aug 19, 2022
4442f16
[UPD] Update server_action_navigate.pot
oca-travis Aug 19, 2022
254b2ad
server_action_navigate 14.0.1.0.2
OCA-git-bot Aug 19, 2022
06dad77
Update translation files
oca-transbot Aug 19, 2022
b8e70da
Translated using Weblate (French)
ypapouin Jul 17, 2023
037bdda
[UPD] README.rst
OCA-git-bot Sep 3, 2023
8d4780e
[MIG] server_action_navigate: Migration to 16.0
legalsylvain Dec 20, 2023
b9ec3c6
[IMP] server_action_navigate : improve test coverage, testing uninsta…
legalsylvain Mar 19, 2024
e800502
[IMP] server_action_navigate : Add test for the computation of the do…
legalsylvain Mar 19, 2024
c5af8b5
[UPD] Update server_action_navigate.pot
May 20, 2024
9991789
Update translation files
weblate May 20, 2024
d345d1a
Translated using Weblate (Italian)
mymage Jun 24, 2024
8d2cd88
[IMP] server_action_navigate: pre-commit auto fixes
BhaveshHeliconia Apr 28, 2025
064940f
[MIG] server_action_navigate: Migration to 18.0
BhaveshHeliconia Apr 28, 2025
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
136 changes: 136 additions & 0 deletions server_action_navigate/README.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,136 @@
=========================
Server Actions - Navigate
=========================

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

.. |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/licence-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%2Fserver--backend-lightgray.png?logo=github
:target: https://github.com/OCA/server-backend/tree/18.0/server_action_navigate
:alt: OCA/server-backend
.. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png
:target: https://translation.odoo-community.org/projects/server-backend-18-0/server-backend-18-0-server_action_navigate
: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/server-backend&target_branch=18.0
:alt: Try me on Runboat

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

This module provides a generic tool to have the possibility to see a
list of records associated to a given selection of records. This is
basically the UI version of ``recordset.mapped('field1.field2')``.

For example, if you use the sale module, you can configure an action to
see all the products that have been sold for a given selection of sale
orders.

**Table of contents**

.. contents::
:local:

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

- Go to 'Setting / Technical / Actions / Server Actions'
- Create a new item

|image1|

- Set a name that will be used for the Contextual Action
- Choose a model
- Select 'Navigate' option in the field 'Action To Do'
- Then, select a field of this model. It can be a ``one2many``,
``many2many``, ``many2one`` field.
- You can then optionally select another fields (#2) that belong to the
previous selected field (#1) relation model
- Once done, click on the 'Create Contextual Action' to generate a new
'More options' button.

**Extra options**

- You can define groups whose members will have access to that option.
- You can select an action that will be used to display the target field
list.

.. |image1| image:: https://raw.githubusercontent.com/OCA/server-backend/18.0/server_action_navigate/static/description/ir_actions_server_form.png

Usage
=====

- Go to a tree view, for a model for which you have defined a navigation
action.
- click on 'Action' Button

|image1|

- then click on the name of the configured Action and see the results

|image2|

.. |image1| image:: https://raw.githubusercontent.com/OCA/server-backend/18.0/server_action_navigate/static/description/res_users_tree.png
.. |image2| image:: https://raw.githubusercontent.com/OCA/server-backend/18.0/server_action_navigate/static/description/res_partner_category_tree.png

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

Bugs are tracked on `GitHub Issues <https://github.com/OCA/server-backend/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/server-backend/issues/new?body=module:%20server_action_navigate%0Aversion:%2018.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
-------

* GRAP

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

- Sylvain LE GAL (https://www.twitter.com/legalsylvain)
- Ashish Hirpara (https://ashish-hirpara.com)

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.

.. |maintainer-legalsylvain| image:: https://github.com/legalsylvain.png?size=40px
:target: https://github.com/legalsylvain
:alt: legalsylvain
.. |maintainer-ashishhirpara| image:: https://github.com/ashishhirpara.png?size=40px
:target: https://github.com/ashishhirpara
:alt: ashishhirpara

Current `maintainers <https://odoo-community.org/page/maintainer-role>`__:

|maintainer-legalsylvain| |maintainer-ashishhirpara|

This module is part of the `OCA/server-backend <https://github.com/OCA/server-backend/tree/18.0/server_action_navigate>`_ project on GitHub.

You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute.
2 changes: 2 additions & 0 deletions server_action_navigate/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
from . import models
from .hooks import uninstall_hook
18 changes: 18 additions & 0 deletions server_action_navigate/__manifest__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
# Copyright (C) 2020 - Today: GRAP (http://www.grap.coop)
# @author: Sylvain LE GAL (https://twitter.com/legalsylvain)
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).

{
"name": "Server Actions - Navigate",
"version": "18.0.1.0.0",
"author": "GRAP, Odoo Community Association (OCA)",
"summary": "Navigate between any items of any Odoo Models",
"category": "Tools",
"website": "https://github.com/OCA/server-backend",
"license": "AGPL-3",
"depends": ["base_automation"],
"maintainers": ["legalsylvain", "ashishhirpara"],
"data": ["security/ir.model.access.csv", "views/view_ir_actions_server.xml"],
"demo": ["demo/ir_actions_server.xml"],
"uninstall_hook": "uninstall_hook",
}
24 changes: 24 additions & 0 deletions server_action_navigate/demo/ir_actions_server.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!--
Copyright (C) 2020 - Today: GRAP (http://www.grap.coop)
@author: Sylvain LE GAL (https://twitter.com/legalsylvain)
License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
-->
<odoo>
<record id="navigate_partner_2_tags" model="ir.actions.server">
<field name="name">See Tags of Partners of Users</field>
<field name="state">navigate</field>
<field name="model_id" ref="base.model_res_users" />
</record>
<record id="navigate_line_1" model="ir.actions.server.navigate.line">
<field name="action_id" ref="navigate_partner_2_tags" />
<field name="field_id" ref="base.field_res_users__partner_id" />
</record>
<record id="navigate_line_2" model="ir.actions.server.navigate.line">
<field name="action_id" ref="navigate_partner_2_tags" />
<field name="field_id" ref="base.field_res_partner__category_id" />
</record>
<function model="ir.actions.server" name="create_action">
<value eval="[ref('navigate_partner_2_tags')]" />
</function>
</odoo>
7 changes: 7 additions & 0 deletions server_action_navigate/hooks.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
from odoo import SUPERUSER_ID, api


def uninstall_hook(cr, registry):
env = api.Environment(cr, SUPERUSER_ID, {})
env["ir.actions.server.navigate.line"].search([]).unlink()
env["ir.actions.server"].search([("state", "=", "navigate")]).unlink()
189 changes: 189 additions & 0 deletions server_action_navigate/i18n/fr.po
Original file line number Diff line number Diff line change
@@ -0,0 +1,189 @@
# Translation of Odoo Server.
# This file contains the translation of the following modules:
# * server_action_navigate
#
msgid ""
msgstr ""
"Project-Id-Version: Odoo Server 16.0\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2023-12-23 18:42+0000\n"
"PO-Revision-Date: 2023-12-23 18:42+0000\n"
"Last-Translator: \n"
"Language-Team: \n"
"Language: \n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: \n"
"Plural-Forms: \n"

#. module: server_action_navigate
#: model:ir.model.fields,field_description:server_action_navigate.field_ir_actions_server_navigate_line__action_id
msgid "Action"
msgstr ""

#. module: server_action_navigate
#: model:ir.model.fields,field_description:server_action_navigate.field_base_automation__state
#: model:ir.model.fields,field_description:server_action_navigate.field_ir_actions_server__state
#: model:ir.model.fields,field_description:server_action_navigate.field_ir_cron__state
msgid "Action To Do"
msgstr "Action à effectuer"

#. module: server_action_navigate
#: model:ir.model.fields,field_description:server_action_navigate.field_ir_actions_server_navigate_line__create_uid
msgid "Created by"
msgstr "Créé par"

#. module: server_action_navigate
#: model:ir.model.fields,field_description:server_action_navigate.field_ir_actions_server_navigate_line__create_date
msgid "Created on"
msgstr "Créé le"

#. module: server_action_navigate
#: model:ir.model.fields,help:server_action_navigate.field_base_automation__navigate_action_id
#: model:ir.model.fields,help:server_action_navigate.field_ir_actions_server__navigate_action_id
#: model:ir.model.fields,help:server_action_navigate.field_ir_cron__navigate_action_id
msgid ""
"Define here the action used when the navigation will be executed if empty, a "
"generic action will be used."
msgstr ""
"Définir ici l'action qui sera utilisé lors que la navigation sera exécutée. "
"Si le champs est vide, une action générique sera utilisée."

#. module: server_action_navigate
#: model_terms:ir.ui.view,arch_db:server_action_navigate.view_ir_actions_server_form
msgid "Delete Last Line"
msgstr "Supprimer la dernière ligne"

#. module: server_action_navigate
#: model:ir.model.fields,field_description:server_action_navigate.field_ir_actions_server_navigate_line__display_name
msgid "Display Name"
msgstr "Nom affiché"

#. module: server_action_navigate
#: model:ir.model.fields,field_description:server_action_navigate.field_ir_actions_server_navigate_line__field_id
msgid "Field"
msgstr "Champ"

#. module: server_action_navigate
#: model:ir.model.fields,field_description:server_action_navigate.field_ir_actions_server_navigate_line__field_domain_model_id
msgid "Field Model"
msgstr "Modèle du champ"

#. module: server_action_navigate
#: model:ir.model.fields,field_description:server_action_navigate.field_base_automation__navigate_model_id
#: model:ir.model.fields,field_description:server_action_navigate.field_ir_actions_server__navigate_model_id
#: model:ir.model.fields,field_description:server_action_navigate.field_ir_cron__navigate_model_id
msgid "Final Navigation Model"
msgstr "Modèle finale de navigation"

#. module: server_action_navigate
#: model:ir.model.fields,field_description:server_action_navigate.field_ir_actions_server_navigate_line__id
msgid "ID"
msgstr ""

#. module: server_action_navigate
#: model:ir.model.fields,field_description:server_action_navigate.field_ir_actions_server_navigate_line____last_update
msgid "Last Modified on"
msgstr "Dernière modification le"

#. module: server_action_navigate
#: model:ir.model.fields,field_description:server_action_navigate.field_ir_actions_server_navigate_line__write_uid
msgid "Last Updated by"
msgstr "Dernière mise à jour par"

#. module: server_action_navigate
#: model:ir.model.fields,field_description:server_action_navigate.field_ir_actions_server_navigate_line__write_date
msgid "Last Updated on"
msgstr "Dernière mise à jour le"

#. module: server_action_navigate
#: model:ir.model.fields.selection,name:server_action_navigate.selection__ir_actions_server__state__navigate
msgid "Navigate"
msgstr "Naviguer"

#. module: server_action_navigate
#: model:ir.model.fields,field_description:server_action_navigate.field_base_automation__navigate_line_ids
#: model:ir.model.fields,field_description:server_action_navigate.field_ir_actions_server__navigate_line_ids
#: model:ir.model.fields,field_description:server_action_navigate.field_ir_cron__navigate_line_ids
msgid "Navigate Lines"
msgstr "Lignes de navigation"

#. module: server_action_navigate
#: model:ir.model.fields,field_description:server_action_navigate.field_base_automation__navigate_model_technical_name
#: model:ir.model.fields,field_description:server_action_navigate.field_ir_actions_server__navigate_model_technical_name
#: model:ir.model.fields,field_description:server_action_navigate.field_ir_cron__navigate_model_technical_name
msgid "Navigate Model Technical Name"
msgstr "Nom technique du Modèle finale de navigation"

#. module: server_action_navigate
#: model:ir.model.fields,field_description:server_action_navigate.field_base_automation__navigate_action_id
#: model:ir.model.fields,field_description:server_action_navigate.field_ir_actions_server__navigate_action_id
#: model:ir.model.fields,field_description:server_action_navigate.field_ir_cron__navigate_action_id
msgid "Navigation Action"
msgstr "Action de navigation"

#. module: server_action_navigate
#: model_terms:ir.ui.view,arch_db:server_action_navigate.view_ir_actions_server_form
msgid "Navigation Options"
msgstr "Options de navigation"

#. module: server_action_navigate
#: model:ir.actions.server,name:server_action_navigate.navigate_partner_2_tags
msgid "See Tags of Partners of Users"
msgstr ""

#. module: server_action_navigate
#: model:ir.model,name:server_action_navigate.model_ir_actions_server
msgid "Server Action"
msgstr "Action du serveur"

#. module: server_action_navigate
#: model:ir.model,name:server_action_navigate.model_ir_actions_server_navigate_line
msgid "Server Actions Navigation Lines"
msgstr "Lignes de navigation de l'action-serveur"

#. module: server_action_navigate
#: model:ir.model.fields,help:server_action_navigate.field_ir_actions_server_navigate_line__field_domain_model_id
msgid "Technical field, used as a domain for the 'field' field."
msgstr "Champ technique, utilisé comme un domaine pour le champ 'Champ'."

#. module: server_action_navigate
#. odoo-python
#: code:addons/server_action_navigate/models/ir_actions_server.py:0
#, python-format
msgid ""
"The Action Server %s is not correctly set\n"
" : No fields defined"
msgstr ""
"L'action-serveur %s n'est pas correctement paramétrée\n"
" : Aucun champ défini"

#. module: server_action_navigate
#: model:ir.model.fields,help:server_action_navigate.field_base_automation__state
#: model:ir.model.fields,help:server_action_navigate.field_ir_actions_server__state
#: model:ir.model.fields,help:server_action_navigate.field_ir_cron__state
msgid ""
"Type of server action. The following values are available:\n"
"- 'Execute Python Code': a block of python code that will be executed\n"
"- 'Create a new Record': create a new record with new values\n"
"- 'Update a Record': update the values of a record\n"
"- 'Execute several actions': define an action that triggers several other "
"server actions\n"
"- 'Send Email': post a message, a note or send an email (Discuss)\n"
"- 'Add Followers': add followers to a record (Discuss)\n"
"- 'Create Next Activity': create an activity (Discuss)\n"
"- 'Send SMS Text Message': send SMS, log them on documents (SMS)"
msgstr ""
"Type d'action serveur. Les valeurs suivantes sont disponibles :\n"
"- 'Executer du code Python' : un bloc de code python qui sera exécuté\n"
"- 'Créer' : créer un nouvel enregistrement avec de nouvelles valeurs\n"
"- 'Mettre à jour un enregistrement' : mettre à jour les valeurs d'un "
"enregistrement\n"
"- 'Executer plusieurs actions' : définir une action qui déclenche plusieurs "
"autres actions serveur\n"
"- 'Envoyer E-Mail' : envoyer un e-mail automatiquement (Discutez)\n"
"- 'Ajouter Abonnés' : ajouter des abonnés à un enregistrement (Discutez)\n"
"- 'Créer une Nouvelle Activité' : créer une activité (Discutez)"

#~ msgid "See tags of Partners"
#~ msgstr "Voir les catégories des partenaires"
Loading