diff --git a/fieldservice_stage_server_action/README.rst b/fieldservice_stage_server_action/README.rst new file mode 100644 index 0000000000..7a66a7a54f --- /dev/null +++ b/fieldservice_stage_server_action/README.rst @@ -0,0 +1,107 @@ +======================= +FSM Stage Server Action +======================= + +.. !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! + !! This file is generated by oca-gen-addon-readme !! + !! changes will be overwritten. !! + !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! + +.. |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%2Ffield--service-lightgray.png?logo=github + :target: https://github.com/OCA/field-service/tree/12.0/fieldservice_stage_server_action + :alt: OCA/field-service +.. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png + :target: https://translation.odoo-community.org/projects/field-service-12-0/field-service-12-0-fieldservice_stage_server_action + :alt: Translate me on Weblate +.. |badge5| image:: https://img.shields.io/badge/runbot-Try%20me-875A7B.png + :target: https://runbot.odoo-community.org/runbot/264/12.0 + :alt: Try me on Runbot + +|badge1| |badge2| |badge3| |badge4| |badge5| + +This module allows you to execute server actions when a FSM orders enters a +specific stage. + +**Table of contents** + +.. contents:: + :local: + +Configuration +============= + +* Go to Field Service > Configuration > Stages +* Create or select a stage +* Select or create a server action + +Usage +===== + +* Go to Field Service +* Select or create a FSM orders +* Move it to the stage configured before to trigger the execution of the + server action + +Bug Tracker +=========== + +Bugs are tracked on `GitHub Issues `_. +In case of trouble, please check there if your issue has already been reported. +If you spotted it first, help us smashing it by providing a detailed and welcomed +`feedback `_. + +Do not contact contributors directly about support or help with technical issues. + +Credits +======= + +Authors +~~~~~~~ + +* Open Source Integrators + +Contributors +~~~~~~~~~~~~ + +* Open Source Integrators + + * Wolfgang Hall + * Maxime Chambreuil + * Steve Campbell + +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-wolfhall| image:: https://github.com/wolfhall.png?size=40px + :target: https://github.com/wolfhall + :alt: wolfhall +.. |maintainer-max3903| image:: https://github.com/max3903.png?size=40px + :target: https://github.com/max3903 + :alt: max3903 +.. |maintainer-osi-scampbell| image:: https://github.com/osi-scampbell.png?size=40px + :target: https://github.com/osi-scampbell + :alt: osi-scampbell + +Current `maintainers `__: + +|maintainer-wolfhall| |maintainer-max3903| |maintainer-osi-scampbell| + +This module is part of the `OCA/field-service `_ project on GitHub. + +You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute. diff --git a/fieldservice_stage_server_action/__init__.py b/fieldservice_stage_server_action/__init__.py new file mode 100644 index 0000000000..a0d2c6cd29 --- /dev/null +++ b/fieldservice_stage_server_action/__init__.py @@ -0,0 +1,4 @@ +# Copyright (C) 2019, Open Source Integrators +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl). + +from . import models diff --git a/fieldservice_stage_server_action/__manifest__.py b/fieldservice_stage_server_action/__manifest__.py new file mode 100644 index 0000000000..3a8285af0f --- /dev/null +++ b/fieldservice_stage_server_action/__manifest__.py @@ -0,0 +1,21 @@ +# Copyright (C) 2019, Open Source Integrators +# # License LGPL-3.0 or later (http://www.gnu.org/licenses/lgpl). +{ + "name": "FSM Stage Server Action", + "summary": "Execute server actions when reaching a Field Service stage", + "version": "13.0.1.0.0", + "category": "Field Service", + "author": "Open Source Integrators, Odoo Community Association (OCA)", + "website": "https://github.com/ursais/osi-addons", + "depends": ["fieldservice", "base_automation"], + "data": [ + "data/ir_server_action.xml", + "data/fsm_stage.xml", + "data/base_automation.xml", + "views/fsm_stage.xml", + ], + "installable": True, + "license": "AGPL-3", + "development_status": "Beta", + "maintainers": ["wolfhall", "max3903", "osi-scampbell"], +} diff --git a/fieldservice_stage_server_action/data/base_automation.xml b/fieldservice_stage_server_action/data/base_automation.xml new file mode 100644 index 0000000000..6333aa630a --- /dev/null +++ b/fieldservice_stage_server_action/data/base_automation.xml @@ -0,0 +1,16 @@ + + + FSM Order Email Sender + + on_create_or_write + + multi + + + diff --git a/fieldservice_stage_server_action/data/fsm_stage.xml b/fieldservice_stage_server_action/data/fsm_stage.xml new file mode 100644 index 0000000000..8805f3519b --- /dev/null +++ b/fieldservice_stage_server_action/data/fsm_stage.xml @@ -0,0 +1,8 @@ + + + + + + + + diff --git a/fieldservice_stage_server_action/data/ir_server_action.xml b/fieldservice_stage_server_action/data/ir_server_action.xml new file mode 100644 index 0000000000..5deff9eedb --- /dev/null +++ b/fieldservice_stage_server_action/data/ir_server_action.xml @@ -0,0 +1,12 @@ + + + FSM Order Completed Parent + + multi + + + FSM Order Canceled Parent + + multi + + diff --git a/fieldservice_stage_server_action/i18n/de.po b/fieldservice_stage_server_action/i18n/de.po new file mode 100644 index 0000000000..db36bf626d --- /dev/null +++ b/fieldservice_stage_server_action/i18n/de.po @@ -0,0 +1,41 @@ +# Translation of Odoo Server. +# This file contains the translation of the following modules: +# * fieldservice_stage_server_action +# +msgid "" +msgstr "" +"Project-Id-Version: Odoo Server 12.0\n" +"Report-Msgid-Bugs-To: \n" +"Last-Translator: Automatically generated\n" +"Language-Team: none\n" +"Language: de\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" + +#. module: fieldservice_stage_server_action +#: model:ir.actions.server,name:fieldservice_stage_server_action.fsm_order_parent_canceled +msgid "FSM Order Canceled Parent" +msgstr "" + +#. module: fieldservice_stage_server_action +#: model:ir.actions.server,name:fieldservice_stage_server_action.fsm_order_parent_completed +msgid "FSM Order Completed Parent" +msgstr "" + +#. module: fieldservice_stage_server_action +#: model:base.automation,name:fieldservice_stage_server_action.fsm_order_email_sender +#: model:ir.actions.server,name:fieldservice_stage_server_action.fsm_order_email_sender_ir_actions_server +msgid "FSM Order Email Sender" +msgstr "" + +#. module: fieldservice_stage_server_action +#: model:ir.model,name:fieldservice_stage_server_action.model_fsm_stage +msgid "Field Service Stage" +msgstr "" + +#. module: fieldservice_stage_server_action +#: model:ir.model.fields,field_description:fieldservice_stage_server_action.field_fsm_stage__action_id +msgid "Server Action" +msgstr "" diff --git a/fieldservice_stage_server_action/i18n/es.po b/fieldservice_stage_server_action/i18n/es.po new file mode 100644 index 0000000000..28371f0cf3 --- /dev/null +++ b/fieldservice_stage_server_action/i18n/es.po @@ -0,0 +1,43 @@ +# Translation of Odoo Server. +# This file contains the translation of the following modules: +# * fieldservice_stage_server_action +# +msgid "" +msgstr "" +"Project-Id-Version: Odoo Server 12.0\n" +"Report-Msgid-Bugs-To: \n" +"PO-Revision-Date: 2019-12-10 21:04+0000\n" +"Last-Translator: Nelson Ram??rez S??nchez \n" +"Language-Team: none\n" +"Language: es\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 3.9.1\n" + +#. module: fieldservice_stage_server_action +#: model:ir.actions.server,name:fieldservice_stage_server_action.fsm_order_parent_canceled +msgid "FSM Order Canceled Parent" +msgstr "Pedido FSM cancelado padre" + +#. module: fieldservice_stage_server_action +#: model:ir.actions.server,name:fieldservice_stage_server_action.fsm_order_parent_completed +msgid "FSM Order Completed Parent" +msgstr "Pedido FSM Padre Completado" + +#. module: fieldservice_stage_server_action +#: model:base.automation,name:fieldservice_stage_server_action.fsm_order_email_sender +#: model:ir.actions.server,name:fieldservice_stage_server_action.fsm_order_email_sender_ir_actions_server +msgid "FSM Order Email Sender" +msgstr "Remitente de Correo de Pedido FSM" + +#. module: fieldservice_stage_server_action +#: model:ir.model,name:fieldservice_stage_server_action.model_fsm_stage +msgid "Field Service Stage" +msgstr "Etapa de Servicio de Campo" + +#. module: fieldservice_stage_server_action +#: model:ir.model.fields,field_description:fieldservice_stage_server_action.field_fsm_stage__action_id +msgid "Server Action" +msgstr "Acci??n de Servidor" diff --git a/fieldservice_stage_server_action/i18n/es_CL.po b/fieldservice_stage_server_action/i18n/es_CL.po new file mode 100644 index 0000000000..e97ce3d880 --- /dev/null +++ b/fieldservice_stage_server_action/i18n/es_CL.po @@ -0,0 +1,43 @@ +# Translation of Odoo Server. +# This file contains the translation of the following modules: +# * fieldservice_stage_server_action +# +msgid "" +msgstr "" +"Project-Id-Version: Odoo Server 12.0\n" +"Report-Msgid-Bugs-To: \n" +"PO-Revision-Date: 2019-12-10 21:04+0000\n" +"Last-Translator: Nelson Ram??rez S??nchez \n" +"Language-Team: none\n" +"Language: es_CL\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 3.9.1\n" + +#. module: fieldservice_stage_server_action +#: model:ir.actions.server,name:fieldservice_stage_server_action.fsm_order_parent_canceled +msgid "FSM Order Canceled Parent" +msgstr "Pedido FSM cancelado padre" + +#. module: fieldservice_stage_server_action +#: model:ir.actions.server,name:fieldservice_stage_server_action.fsm_order_parent_completed +msgid "FSM Order Completed Parent" +msgstr "Pedido FSM Padre Completado" + +#. module: fieldservice_stage_server_action +#: model:base.automation,name:fieldservice_stage_server_action.fsm_order_email_sender +#: model:ir.actions.server,name:fieldservice_stage_server_action.fsm_order_email_sender_ir_actions_server +msgid "FSM Order Email Sender" +msgstr "Remitente de Correo de Pedido FSM" + +#. module: fieldservice_stage_server_action +#: model:ir.model,name:fieldservice_stage_server_action.model_fsm_stage +msgid "Field Service Stage" +msgstr "Etapa de Servicio de Campo" + +#. module: fieldservice_stage_server_action +#: model:ir.model.fields,field_description:fieldservice_stage_server_action.field_fsm_stage__action_id +msgid "Server Action" +msgstr "Acci??n de Servidor" diff --git a/fieldservice_stage_server_action/i18n/fieldservice_stage_server_action.pot b/fieldservice_stage_server_action/i18n/fieldservice_stage_server_action.pot new file mode 100644 index 0000000000..dd6a6f4a59 --- /dev/null +++ b/fieldservice_stage_server_action/i18n/fieldservice_stage_server_action.pot @@ -0,0 +1,41 @@ +# Translation of Odoo Server. +# This file contains the translation of the following modules: +# * fieldservice_stage_server_action +# +msgid "" +msgstr "" +"Project-Id-Version: Odoo Server 12.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: fieldservice_stage_server_action +#: model:ir.actions.server,name:fieldservice_stage_server_action.fsm_order_parent_canceled +msgid "FSM Order Canceled Parent" +msgstr "" + +#. module: fieldservice_stage_server_action +#: model:ir.actions.server,name:fieldservice_stage_server_action.fsm_order_parent_completed +msgid "FSM Order Completed Parent" +msgstr "" + +#. module: fieldservice_stage_server_action +#: model:base.automation,name:fieldservice_stage_server_action.fsm_order_email_sender +#: model:ir.actions.server,name:fieldservice_stage_server_action.fsm_order_email_sender_ir_actions_server +msgid "FSM Order Email Sender" +msgstr "" + +#. module: fieldservice_stage_server_action +#: model:ir.model,name:fieldservice_stage_server_action.model_fsm_stage +msgid "Field Service Stage" +msgstr "" + +#. module: fieldservice_stage_server_action +#: model:ir.model.fields,field_description:fieldservice_stage_server_action.field_fsm_stage__action_id +msgid "Server Action" +msgstr "" + diff --git a/fieldservice_stage_server_action/i18n/pt_BR.po b/fieldservice_stage_server_action/i18n/pt_BR.po new file mode 100644 index 0000000000..29876a7551 --- /dev/null +++ b/fieldservice_stage_server_action/i18n/pt_BR.po @@ -0,0 +1,43 @@ +# Translation of Odoo Server. +# This file contains the translation of the following modules: +# * fieldservice_stage_server_action +# +msgid "" +msgstr "" +"Project-Id-Version: Odoo Server 12.0\n" +"Report-Msgid-Bugs-To: \n" +"PO-Revision-Date: 2020-06-17 16:19+0000\n" +"Last-Translator: Fernando Colus \n" +"Language-Team: none\n" +"Language: pt_BR\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 3.10\n" + +#. module: fieldservice_stage_server_action +#: model:ir.actions.server,name:fieldservice_stage_server_action.fsm_order_parent_canceled +msgid "FSM Order Canceled Parent" +msgstr "Pai do pedido cancelado" + +#. module: fieldservice_stage_server_action +#: model:ir.actions.server,name:fieldservice_stage_server_action.fsm_order_parent_completed +msgid "FSM Order Completed Parent" +msgstr "Pai do pedido completado" + +#. module: fieldservice_stage_server_action +#: model:base.automation,name:fieldservice_stage_server_action.fsm_order_email_sender +#: model:ir.actions.server,name:fieldservice_stage_server_action.fsm_order_email_sender_ir_actions_server +msgid "FSM Order Email Sender" +msgstr "Remetente do email do pedido" + +#. module: fieldservice_stage_server_action +#: model:ir.model,name:fieldservice_stage_server_action.model_fsm_stage +msgid "Field Service Stage" +msgstr "Est??gio de Servi??o de Campo" + +#. module: fieldservice_stage_server_action +#: model:ir.model.fields,field_description:fieldservice_stage_server_action.field_fsm_stage__action_id +msgid "Server Action" +msgstr "A????o do Servidor" diff --git a/fieldservice_stage_server_action/models/__init__.py b/fieldservice_stage_server_action/models/__init__.py new file mode 100644 index 0000000000..bf6468a89e --- /dev/null +++ b/fieldservice_stage_server_action/models/__init__.py @@ -0,0 +1,4 @@ +# Copyright (C) 2019, Open Source Integrators +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl). + +from . import fsm_stage diff --git a/fieldservice_stage_server_action/models/fsm_stage.py b/fieldservice_stage_server_action/models/fsm_stage.py new file mode 100644 index 0000000000..6bc8f63fa0 --- /dev/null +++ b/fieldservice_stage_server_action/models/fsm_stage.py @@ -0,0 +1,10 @@ +# Copyright (C) 2019, Open Source Integrators +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl). + +from odoo import fields, models + + +class FSMStage(models.Model): + _inherit = "fsm.stage" + + action_id = fields.Many2one("ir.actions.server", string="Server Action") diff --git a/fieldservice_stage_server_action/readme/CONFIGURE.rst b/fieldservice_stage_server_action/readme/CONFIGURE.rst new file mode 100644 index 0000000000..c851f5f506 --- /dev/null +++ b/fieldservice_stage_server_action/readme/CONFIGURE.rst @@ -0,0 +1,3 @@ +* Go to Field Service > Configuration > Stages +* Create or select a stage +* Select or create a server action diff --git a/fieldservice_stage_server_action/readme/CONTRIBUTORS.rst b/fieldservice_stage_server_action/readme/CONTRIBUTORS.rst new file mode 100644 index 0000000000..43c8618660 --- /dev/null +++ b/fieldservice_stage_server_action/readme/CONTRIBUTORS.rst @@ -0,0 +1,7 @@ +* Open Source Integrators + + * Wolfgang Hall + * Maxime Chambreuil + * Steve Campbell + +* Brian McMaster diff --git a/fieldservice_stage_server_action/readme/DESCRIPTION.rst b/fieldservice_stage_server_action/readme/DESCRIPTION.rst new file mode 100644 index 0000000000..d790577097 --- /dev/null +++ b/fieldservice_stage_server_action/readme/DESCRIPTION.rst @@ -0,0 +1,2 @@ +This module allows you to execute server actions when a FSM orders enters a +specific stage. diff --git a/fieldservice_stage_server_action/readme/USAGE.rst b/fieldservice_stage_server_action/readme/USAGE.rst new file mode 100644 index 0000000000..fac3244b28 --- /dev/null +++ b/fieldservice_stage_server_action/readme/USAGE.rst @@ -0,0 +1,4 @@ +* Go to Field Service +* Select or create a FSM orders +* Move it to the stage configured before to trigger the execution of the + server action diff --git a/fieldservice_stage_server_action/static/description/icon.png b/fieldservice_stage_server_action/static/description/icon.png new file mode 100644 index 0000000000..955674d8f0 Binary files /dev/null and b/fieldservice_stage_server_action/static/description/icon.png differ diff --git a/fieldservice_stage_server_action/static/description/index.html b/fieldservice_stage_server_action/static/description/index.html new file mode 100644 index 0000000000..144349b9f6 --- /dev/null +++ b/fieldservice_stage_server_action/static/description/index.html @@ -0,0 +1,721 @@ + + + + + + + FSM Stage Server Action + + + +
+

FSM Stage Server Action

+ + +

+ Beta + License: AGPL-3 + OCA/field-service + Translate me on Weblate + Try me on Runbot +

+

+ This module allows you to execute server actions when a FSM orders enters a + specific stage. +

+

Table of contents

+
+ +
+
+

Configuration

+
    +
  • Go to Field Service > Configuration > Stages
  • +
  • Create or select a stage
  • +
  • Select or create a server action
  • +
+
+
+

Usage

+
    +
  • Go to Field Service
  • +
  • Select or create a FSM orders
  • +
  • + Move it to the stage configured before to trigger the execution of the + server action +
  • +
+
+
+

Bug Tracker

+

+ Bugs are tracked on + GitHub Issues. In case of trouble, please check there if your issue has already been + reported. If you spotted it first, help us smashing it by providing a detailed + and welcomed + feedback. +

+

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

+
+
+

Credits

+
+

Authors

+
    +
  • Open Source Integrators
  • +
+
+
+

Contributors

+ +
+
+

Maintainers

+

This module is maintained by the OCA.

+ Odoo Community Association +

+ 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. +

+

+ Current + maintainers: +

+

+ wolfhall + max3903 + osi-scampbell +

+

+ This module is part of the + OCA/field-service + project on GitHub. +

+

+ You are welcome to contribute. To learn how please visit + https://odoo-community.org/page/Contribute. +

+
+
+
+ + diff --git a/fieldservice_stage_server_action/views/fsm_stage.xml b/fieldservice_stage_server_action/views/fsm_stage.xml new file mode 100644 index 0000000000..4e5b1e5574 --- /dev/null +++ b/fieldservice_stage_server_action/views/fsm_stage.xml @@ -0,0 +1,13 @@ + + + + fsm.server.action.stage.form + fsm.stage + + + + + + + +