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
81 changes: 81 additions & 0 deletions edi_purchase_oca/README.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,81 @@
============
EDI Purchase
============

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

.. |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-LGPL--3-blue.png
:target: http://www.gnu.org/licenses/lgpl-3.0-standalone.html
:alt: License: LGPL-3
.. |badge3| image:: https://img.shields.io/badge/github-OCA%2Fedi--framework-lightgray.png?logo=github
:target: https://github.com/OCA/edi-framework/tree/18.0/edi_purchase_oca
:alt: OCA/edi-framework
.. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png
:target: https://translation.odoo-community.org/projects/edi-framework-18-0/edi-framework-18-0-edi_purchase_oca
: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/edi-framework&target_branch=18.0
:alt: Try me on Runboat

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

This module intends to create a base to be extended by local edi rules
for purchase. Assign the EDI Configuration on the partner form.

**Table of contents**

.. contents::
:local:

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

Bugs are tracked on `GitHub Issues <https://github.com/OCA/edi-framework/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/edi-framework/issues/new?body=module:%20edi_purchase_oca%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
-------

* ForgeFlow
* Camptocamp

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

- Lois Rilo lois.rilo@forgeflow.com
- Simone Orsi simone.orsi@camptocamp.com

- Phan Hong Phuc <phucph@trobz.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.

This module is part of the `OCA/edi-framework <https://github.com/OCA/edi-framework/tree/18.0/edi_purchase_oca>`_ 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 edi_purchase_oca/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
from . import models
30 changes: 30 additions & 0 deletions edi_purchase_oca/__manifest__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
# Copyright 2022 ForgeFlow S.L. (https://www.forgeflow.com)
# License LGPL-3.0 or later (http://www.gnu.org/licenses/lgpl).

{
"name": "EDI Purchase",
"summary": """
Define EDI Configuration for Purchase Orders""",
"version": "18.0.1.0.0",
"license": "LGPL-3",
"author": "ForgeFlow, Camptocamp, Odoo Community Association (OCA)",
"website": "https://github.com/OCA/edi-framework",
"depends": [
"purchase",
"edi_core_oca",
"edi_record_metadata_oca",
],
"data": [
# Data
"data/edi_configuration.xml",
# Views
"views/edi_exchange_record_views.xml",
"views/purchase_order_views.xml",
"views/res_partner_view.xml",
],
"demo": [
"demo/edi_backend.xml",
"demo/edi_exchange_type.xml",
"demo/edi_configuration.xml",
],
}
13 changes: 13 additions & 0 deletions edi_purchase_oca/data/edi_configuration.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
<?xml version="1.0" encoding="utf-8" ?>
<odoo>
<!-- Generic state change -->
<record
id="edi_conf_trigger_purchase_order_state_change"
model="edi.configuration.trigger"
>
<field name="name">On PO state change</field>
<field name="code">on_edi_purchase_order_state_change</field>
<field name="description">Trigger when a purchase order state changes</field>
<field name="model_id" ref="purchase.model_purchase_order" />
</record>
</odoo>
11 changes: 11 additions & 0 deletions edi_purchase_oca/demo/edi_backend.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
<?xml version="1.0" encoding="utf-8" ?>
<odoo>
<record id="demo_edi_backend_type_purchase" model="edi.backend.type">
<field name="name">Purchase DEMO</field>
<field name="code">purchase_demo</field>
</record>
<record id="demo_edi_backend" model="edi.backend">
<field name="name">purchase DEMO</field>
<field name="backend_type_id" ref="demo_edi_backend_type_purchase" />
</record>
</odoo>
36 changes: 36 additions & 0 deletions edi_purchase_oca/demo/edi_configuration.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
<?xml version="1.0" encoding="UTF-8" ?>
<odoo>
<record id="demo_edi_configuration_confirmed" model="edi.configuration">
<field name="name">Demo Purchase Order - order confirmed</field>
<field
name="description"
>Show case how you can send out an order automatically</field>
<field name="type_id" ref="demo_edi_exc_type_order_out" />
<field name="backend_id" ref="demo_edi_backend" />
<field name="model_id" ref="purchase.model_purchase_order" />
<field name="trigger_id" ref="edi_conf_trigger_purchase_order_state_change" />
<field name="snippet_do">
# ('draft', 'RFQ'),
# ('sent', 'RFQ Sent'),
# ('to approve', 'To Approve'),
# ('purchase', 'Purchase Order'),
# ('cancel', 'Cancelled')
if record.state == 'purchase':
record._edi_send_via_edi(conf.type_id)
</field>
</record>
<record id="demo_edi_configuration_cancelled" model="edi.configuration">
<field name="name">Demo Purchase Order - order cancelled</field>
<field
name="description"
>Show case how you can send out an order automatically</field>
<field name="type_id" ref="demo_edi_exc_type_order_out" />
<field name="backend_id" ref="demo_edi_backend" />
<field name="model_id" ref="purchase.model_purchase_order" />
<field name="trigger_id" ref="edi_conf_trigger_purchase_order_state_change" />
<field name="snippet_do">
if record.state == 'cancel':
record._edi_send_via_edi(conf.type_id)
</field>
</record>
</odoo>
12 changes: 12 additions & 0 deletions edi_purchase_oca/demo/edi_exchange_type.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
<?xml version="1.0" encoding="UTF-8" ?>
<odoo>
<record id="demo_edi_exc_type_order_out" model="edi.exchange.type">
<field name="backend_type_id" ref="demo_edi_backend_type_purchase" />
<field name="backend_id" ref="demo_edi_backend" />
<field name="name">Demo Purchase Order out</field>
<field name="code">demo_PurchaseOrder_out</field>
<field name="direction">output</field>
<field name="exchange_filename_pattern">{record_name}-{type.code}-{dt}</field>
<field name="exchange_file_ext">xml</field>
</record>
</odoo>
109 changes: 109 additions & 0 deletions edi_purchase_oca/i18n/edi_purchase_oca.pot
Original file line number Diff line number Diff line change
@@ -0,0 +1,109 @@
# Translation of Odoo Server.
# This file contains the translation of the following modules:
# * edi_purchase_oca
#
msgid ""
msgstr ""
"Project-Id-Version: Odoo Server 14.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: edi_purchase_oca
#: model_terms:ir.ui.view,arch_db:edi_purchase_oca.purchase_order_form
msgid "<span class=\"o_stat_text\">EDI</span>"
msgstr ""

#. module: edi_purchase_oca
#: model:ir.model.fields,field_description:edi_purchase_oca.field_purchase_order__disable_edi_auto
msgid "Disable auto"
msgstr ""

#. module: edi_purchase_oca
#: model:ir.model.fields,field_description:edi_purchase_oca.field_purchase_order__display_name
msgid "Display Name"
msgstr ""

#. module: edi_purchase_oca
#: model:ir.model.fields,field_description:edi_purchase_oca.field_purchase_order__origin_edi_endpoint_id
msgid "EDI origin endpoint"
msgstr ""

#. module: edi_purchase_oca
#: model:ir.model.fields,field_description:edi_purchase_oca.field_purchase_order__origin_exchange_type_id
msgid "EDI origin exchange type"
msgstr ""

#. module: edi_purchase_oca
#: model:ir.model.fields,field_description:edi_purchase_oca.field_purchase_order__origin_exchange_record_id
msgid "EDI origin record"
msgstr ""

#. module: edi_purchase_oca
#: model:ir.model.fields,help:edi_purchase_oca.field_purchase_order__origin_exchange_record_id
msgid "EDI record that originated this document."
msgstr ""

#. module: edi_purchase_oca
#: model:ir.model.fields,field_description:edi_purchase_oca.field_purchase_order__edi_config
msgid "Edi Config"
msgstr ""

#. module: edi_purchase_oca
#: model:ir.model.fields,field_description:edi_purchase_oca.field_purchase_order__edi_has_form_config
msgid "Edi Has Form Config"
msgstr ""

#. module: edi_purchase_oca
#: model:ir.model.fields,field_description:edi_purchase_oca.field_purchase_order__exchange_record_ids
msgid "Exchange Record"
msgstr ""

#. module: edi_purchase_oca
#: model:ir.model.fields,field_description:edi_purchase_oca.field_purchase_order__exchange_record_count
msgid "Exchange Record Count"
msgstr ""

#. module: edi_purchase_oca
#: model:ir.ui.menu,name:edi_purchase_oca.menu_purchase_edi_root
msgid "Exchange records"
msgstr ""

#. module: edi_purchase_oca
#: model:ir.model.fields,field_description:edi_purchase_oca.field_purchase_order__id
msgid "ID"
msgstr ""

#. module: edi_purchase_oca
#: model:ir.model.fields,field_description:edi_purchase_oca.field_purchase_order____last_update
msgid "Last Modified on"
msgstr ""

#. module: edi_purchase_oca
#: model:ir.model,name:edi_purchase_oca.model_purchase_order
msgid "Purchase Order"
msgstr ""

#. module: edi_purchase_oca
#: model:ir.actions.act_window,name:edi_purchase_oca.act_open_edi_exchange_record_purchase_order_view
msgid "Purchase Order Exchange Record"
msgstr ""

#. module: edi_purchase_oca
#: model:ir.ui.menu,name:edi_purchase_oca.menu_purchase_edi_exchange_record
msgid "Purchase Orders"
msgstr ""

#. module: edi_purchase_oca
#: model:ir.model.fields,help:edi_purchase_oca.field_purchase_order__origin_edi_endpoint_id
msgid "Record generated via this endpoint"
msgstr ""

#. module: edi_purchase_oca
#: model:ir.model.fields,help:edi_purchase_oca.field_purchase_order__disable_edi_auto
msgid "When marked, EDI automatic processing will be avoided"
msgstr ""
Loading
Loading