Skip to content

Commit 4dae8f3

Browse files
committed
Merge PR #283 into 19.0
Signed-off-by simahawk
2 parents d40723c + 0cd9e3c commit 4dae8f3

25 files changed

Lines changed: 1300 additions & 0 deletions

edi_purchase_oca/README.rst

Lines changed: 89 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,89 @@
1+
.. image:: https://odoo-community.org/readme-banner-image
2+
:target: https://odoo-community.org/get-involved?utm_source=readme
3+
:alt: Odoo Community Association
4+
5+
============
6+
EDI Purchase
7+
============
8+
9+
..
10+
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
11+
!! This file is generated by oca-gen-addon-readme !!
12+
!! changes will be overwritten. !!
13+
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
14+
!! source digest: sha256:8ab40ab13f4a26ea0ba04ff19e53af88e490d1b2e783699454ae6255422e00c3
15+
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
16+
17+
.. |badge1| image:: https://img.shields.io/badge/maturity-Beta-yellow.png
18+
:target: https://odoo-community.org/page/development-status
19+
:alt: Beta
20+
.. |badge2| image:: https://img.shields.io/badge/license-LGPL--3-blue.png
21+
:target: http://www.gnu.org/licenses/lgpl-3.0-standalone.html
22+
:alt: License: LGPL-3
23+
.. |badge3| image:: https://img.shields.io/badge/github-OCA%2Fedi--framework-lightgray.png?logo=github
24+
:target: https://github.com/OCA/edi-framework/tree/19.0/edi_purchase_oca
25+
:alt: OCA/edi-framework
26+
.. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png
27+
:target: https://translation.odoo-community.org/projects/edi-framework-19-0/edi-framework-19-0-edi_purchase_oca
28+
:alt: Translate me on Weblate
29+
.. |badge5| image:: https://img.shields.io/badge/runboat-Try%20me-875A7B.png
30+
:target: https://runboat.odoo-community.org/builds?repo=OCA/edi-framework&target_branch=19.0
31+
:alt: Try me on Runboat
32+
33+
|badge1| |badge2| |badge3| |badge4| |badge5|
34+
35+
Handle purchase orders via EDI.
36+
37+
This is a base module to plug purchase processes with the EDI framework.
38+
39+
To handle inbound/outbound purchase orders, you need to create your own
40+
integration modules on top of this base module.
41+
42+
**Table of contents**
43+
44+
.. contents::
45+
:local:
46+
47+
Bug Tracker
48+
===========
49+
50+
Bugs are tracked on `GitHub Issues <https://github.com/OCA/edi-framework/issues>`_.
51+
In case of trouble, please check there if your issue has already been reported.
52+
If you spotted it first, help us to smash it by providing a detailed and welcomed
53+
`feedback <https://github.com/OCA/edi-framework/issues/new?body=module:%20edi_purchase_oca%0Aversion:%2019.0%0A%0A**Steps%20to%20reproduce**%0A-%20...%0A%0A**Current%20behavior**%0A%0A**Expected%20behavior**>`_.
54+
55+
Do not contact contributors directly about support or help with technical issues.
56+
57+
Credits
58+
=======
59+
60+
Authors
61+
-------
62+
63+
* ForgeFlow
64+
* Camptocamp
65+
66+
Contributors
67+
------------
68+
69+
- Lois Rilo lois.rilo@forgeflow.com
70+
- Simone Orsi simone.orsi@camptocamp.com
71+
- Phan Hong Phuc <phucph@trobz.com>
72+
- Maksym Yankin maksym.yankin@camptocamp.com
73+
74+
Maintainers
75+
-----------
76+
77+
This module is maintained by the OCA.
78+
79+
.. image:: https://odoo-community.org/logo.png
80+
:alt: Odoo Community Association
81+
:target: https://odoo-community.org
82+
83+
OCA, or the Odoo Community Association, is a nonprofit organization whose
84+
mission is to support the collaborative development of Odoo features and
85+
promote its widespread use.
86+
87+
This module is part of the `OCA/edi-framework <https://github.com/OCA/edi-framework/tree/19.0/edi_purchase_oca>`_ project on GitHub.
88+
89+
You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute.

edi_purchase_oca/__init__.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
from . import models

edi_purchase_oca/__manifest__.py

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
# Copyright 2022 ForgeFlow S.L. (https://www.forgeflow.com)
2+
# License LGPL-3.0 or later (http://www.gnu.org/licenses/lgpl).
3+
4+
{
5+
"name": "EDI Purchase",
6+
"summary": """
7+
Define EDI Configuration for Purchase Orders""",
8+
"version": "19.0.1.0.0",
9+
"license": "LGPL-3",
10+
"author": "ForgeFlow, Camptocamp, Odoo Community Association (OCA)",
11+
"website": "https://github.com/OCA/edi-framework",
12+
"depends": [
13+
"purchase",
14+
"edi_core_oca",
15+
"edi_record_metadata_oca",
16+
],
17+
"data": [
18+
# Data
19+
"data/edi_configuration.xml",
20+
# Views
21+
"views/edi_exchange_record_views.xml",
22+
"views/purchase_order_views.xml",
23+
"views/res_partner_view.xml",
24+
],
25+
"demo": [
26+
"demo/edi_backend.xml",
27+
"demo/edi_exchange_type.xml",
28+
"demo/edi_configuration.xml",
29+
],
30+
}
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
<?xml version="1.0" encoding="utf-8" ?>
2+
<odoo>
3+
<!-- Generic state change -->
4+
<record
5+
id="edi_conf_trigger_purchase_order_state_change"
6+
model="edi.configuration.trigger"
7+
>
8+
<field name="name">On PO state change</field>
9+
<field name="code">on_edi_purchase_order_state_change</field>
10+
<field name="description">Trigger when a purchase order state changes</field>
11+
<field name="model_id" ref="purchase.model_purchase_order" />
12+
</record>
13+
</odoo>
Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
<?xml version="1.0" encoding="utf-8" ?>
2+
<odoo>
3+
<record id="demo_edi_backend_type_purchase" model="edi.backend.type">
4+
<field name="name">Purchase DEMO</field>
5+
<field name="code">purchase_demo</field>
6+
</record>
7+
<record id="demo_edi_backend" model="edi.backend">
8+
<field name="name">purchase DEMO</field>
9+
<field name="backend_type_id" ref="demo_edi_backend_type_purchase" />
10+
</record>
11+
</odoo>
Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
<?xml version="1.0" encoding="UTF-8" ?>
2+
<odoo>
3+
<record id="demo_edi_configuration_confirmed" model="edi.configuration">
4+
<field name="name">Demo Purchase Order - order confirmed</field>
5+
<field
6+
name="description"
7+
>Show case how you can send out an order automatically</field>
8+
<field name="type_id" ref="demo_edi_exc_type_order_out" />
9+
<field name="backend_id" ref="demo_edi_backend" />
10+
<field name="model_id" ref="purchase.model_purchase_order" />
11+
<field name="trigger_id" ref="edi_conf_trigger_purchase_order_state_change" />
12+
<field name="snippet_do">
13+
# ('draft', 'RFQ'),
14+
# ('sent', 'RFQ Sent'),
15+
# ('to approve', 'To Approve'),
16+
# ('purchase', 'Purchase Order'),
17+
# ('cancel', 'Cancelled')
18+
if record.state == 'purchase':
19+
record._edi_send_via_edi(conf.type_id)
20+
</field>
21+
</record>
22+
<record id="demo_edi_configuration_cancelled" model="edi.configuration">
23+
<field name="name">Demo Purchase Order - order cancelled</field>
24+
<field
25+
name="description"
26+
>Show case how you can send out an order automatically</field>
27+
<field name="type_id" ref="demo_edi_exc_type_order_out" />
28+
<field name="backend_id" ref="demo_edi_backend" />
29+
<field name="model_id" ref="purchase.model_purchase_order" />
30+
<field name="trigger_id" ref="edi_conf_trigger_purchase_order_state_change" />
31+
<field name="snippet_do">
32+
if record.state == 'cancel':
33+
record._edi_send_via_edi(conf.type_id)
34+
</field>
35+
</record>
36+
</odoo>
Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
<?xml version="1.0" encoding="UTF-8" ?>
2+
<odoo>
3+
<record id="demo_edi_exc_type_order_out" model="edi.exchange.type">
4+
<field name="backend_type_id" ref="demo_edi_backend_type_purchase" />
5+
<field name="backend_id" ref="demo_edi_backend" />
6+
<field name="name">Demo Purchase Order out</field>
7+
<field name="code">demo_PurchaseOrder_out</field>
8+
<field name="direction">output</field>
9+
<field name="exchange_filename_pattern">{record_name}-{type.code}-{dt}</field>
10+
<field name="exchange_file_ext">xml</field>
11+
</record>
12+
</odoo>
Lines changed: 109 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,109 @@
1+
# Translation of Odoo Server.
2+
# This file contains the translation of the following modules:
3+
# * edi_purchase_oca
4+
#
5+
msgid ""
6+
msgstr ""
7+
"Project-Id-Version: Odoo Server 14.0\n"
8+
"Report-Msgid-Bugs-To: \n"
9+
"Last-Translator: \n"
10+
"Language-Team: \n"
11+
"MIME-Version: 1.0\n"
12+
"Content-Type: text/plain; charset=UTF-8\n"
13+
"Content-Transfer-Encoding: \n"
14+
"Plural-Forms: \n"
15+
16+
#. module: edi_purchase_oca
17+
#: model_terms:ir.ui.view,arch_db:edi_purchase_oca.purchase_order_form
18+
msgid "<span class=\"o_stat_text\">EDI</span>"
19+
msgstr ""
20+
21+
#. module: edi_purchase_oca
22+
#: model:ir.model.fields,field_description:edi_purchase_oca.field_purchase_order__disable_edi_auto
23+
msgid "Disable auto"
24+
msgstr ""
25+
26+
#. module: edi_purchase_oca
27+
#: model:ir.model.fields,field_description:edi_purchase_oca.field_purchase_order__display_name
28+
msgid "Display Name"
29+
msgstr ""
30+
31+
#. module: edi_purchase_oca
32+
#: model:ir.model.fields,field_description:edi_purchase_oca.field_purchase_order__origin_edi_endpoint_id
33+
msgid "EDI origin endpoint"
34+
msgstr ""
35+
36+
#. module: edi_purchase_oca
37+
#: model:ir.model.fields,field_description:edi_purchase_oca.field_purchase_order__origin_exchange_type_id
38+
msgid "EDI origin exchange type"
39+
msgstr ""
40+
41+
#. module: edi_purchase_oca
42+
#: model:ir.model.fields,field_description:edi_purchase_oca.field_purchase_order__origin_exchange_record_id
43+
msgid "EDI origin record"
44+
msgstr ""
45+
46+
#. module: edi_purchase_oca
47+
#: model:ir.model.fields,help:edi_purchase_oca.field_purchase_order__origin_exchange_record_id
48+
msgid "EDI record that originated this document."
49+
msgstr ""
50+
51+
#. module: edi_purchase_oca
52+
#: model:ir.model.fields,field_description:edi_purchase_oca.field_purchase_order__edi_config
53+
msgid "Edi Config"
54+
msgstr ""
55+
56+
#. module: edi_purchase_oca
57+
#: model:ir.model.fields,field_description:edi_purchase_oca.field_purchase_order__edi_has_form_config
58+
msgid "Edi Has Form Config"
59+
msgstr ""
60+
61+
#. module: edi_purchase_oca
62+
#: model:ir.model.fields,field_description:edi_purchase_oca.field_purchase_order__exchange_record_ids
63+
msgid "Exchange Record"
64+
msgstr ""
65+
66+
#. module: edi_purchase_oca
67+
#: model:ir.model.fields,field_description:edi_purchase_oca.field_purchase_order__exchange_record_count
68+
msgid "Exchange Record Count"
69+
msgstr ""
70+
71+
#. module: edi_purchase_oca
72+
#: model:ir.ui.menu,name:edi_purchase_oca.menu_purchase_edi_root
73+
msgid "Exchange records"
74+
msgstr ""
75+
76+
#. module: edi_purchase_oca
77+
#: model:ir.model.fields,field_description:edi_purchase_oca.field_purchase_order__id
78+
msgid "ID"
79+
msgstr ""
80+
81+
#. module: edi_purchase_oca
82+
#: model:ir.model.fields,field_description:edi_purchase_oca.field_purchase_order____last_update
83+
msgid "Last Modified on"
84+
msgstr ""
85+
86+
#. module: edi_purchase_oca
87+
#: model:ir.model,name:edi_purchase_oca.model_purchase_order
88+
msgid "Purchase Order"
89+
msgstr ""
90+
91+
#. module: edi_purchase_oca
92+
#: model:ir.actions.act_window,name:edi_purchase_oca.act_open_edi_exchange_record_purchase_order_view
93+
msgid "Purchase Order Exchange Record"
94+
msgstr ""
95+
96+
#. module: edi_purchase_oca
97+
#: model:ir.ui.menu,name:edi_purchase_oca.menu_purchase_edi_exchange_record
98+
msgid "Purchase Orders"
99+
msgstr ""
100+
101+
#. module: edi_purchase_oca
102+
#: model:ir.model.fields,help:edi_purchase_oca.field_purchase_order__origin_edi_endpoint_id
103+
msgid "Record generated via this endpoint"
104+
msgstr ""
105+
106+
#. module: edi_purchase_oca
107+
#: model:ir.model.fields,help:edi_purchase_oca.field_purchase_order__disable_edi_auto
108+
msgid "When marked, EDI automatic processing will be avoided"
109+
msgstr ""

0 commit comments

Comments
 (0)