Skip to content

Commit

Permalink
Merge PR #46 into 17.0
Browse files Browse the repository at this point in the history
Signed-off-by max3903
  • Loading branch information
OCA-git-bot committed Jan 6, 2025
2 parents 453d56a + dd7df2d commit 1870159
Show file tree
Hide file tree
Showing 52 changed files with 6,417 additions and 33 deletions.
2 changes: 1 addition & 1 deletion l10n_mx_catalogs/__manifest__.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
"category": "Localization",
"version": "17.0.1.0.0",
"license": "LGPL-3",
"depends": ["l10n_mx"],
"depends": ["base"],
"data": [
"security/ir.model.access.csv",
"data/l10n_mx_catalogs.c_clave_unidad.csv",
Expand Down
4 changes: 2 additions & 2 deletions l10n_mx_cfdi/__manifest__.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@
"website": "https://github.com/OCA/l10n-mexico",
"license": "LGPL-3",
"category": "Accounting",
"version": "17.0.1.0.1",
"depends": ["account", "l10n_mx_catalogs"],
"version": "17.0.1.0.0",
"depends": ["l10n_mx_catalogs", "product"],
"external_dependencies": {
"python": ["facturama"],
},
Expand Down
10 changes: 4 additions & 6 deletions l10n_mx_cfdi/security/ir.model.access.csv
Original file line number Diff line number Diff line change
@@ -1,11 +1,9 @@
id,name,model_id:id,group_id:id,perm_read,perm_write,perm_create,perm_unlink
access_l10n_mx_cfdi_issuer,access_l10n_mx_cfdi_issuer,model_l10n_mx_cfdi_issuer,base.group_user,1,0,0,0
manage_l10n_mx_cfdi_issuer,manage_l10n_mx_cfdi_issuer,model_l10n_mx_cfdi_issuer,account.group_account_manager,1,1,1,1
access_l10n_mx_cfdi_cfdi_service,access_l10n_mx_cfdi_cfdi_service,l10n_mx_cfdi.model_l10n_mx_cfdi_cfdi_service,base.group_user,1,0,0,0
manage_l10n_mx_cfdi_cfdi_service,manage_l10n_mx_cfdi_cfdi_service,l10n_mx_cfdi.model_l10n_mx_cfdi_cfdi_service,base.group_system,1,1,1,1
l10n_mx_cfdi.access_l10n_mx_cfdi_cfdi_service_topup,access_l10n_mx_cfdi_cfdi_service_topup,l10n_mx_cfdi.model_l10n_mx_cfdi_cfdi_service_topup,base.group_user,1,0,0,0
l10n_mx_cfdi.admin_l10n_mx_cfdi_cfdi_service_topup,admin_l10n_mx_cfdi_cfdi_service_topup,l10n_mx_cfdi.model_l10n_mx_cfdi_cfdi_service_topup,base.group_system,1,1,1,1
access_l10n_mx_cfdi_cfdi_service_topup,access_l10n_mx_cfdi_cfdi_service_topup,model_l10n_mx_cfdi_cfdi_service_topup,base.group_user,1,0,0,0
admin_l10n_mx_cfdi_cfdi_service_topup,admin_l10n_mx_cfdi_cfdi_service_topup,model_l10n_mx_cfdi_cfdi_service_topup,base.group_system,1,1,1,1
access_l10n_mx_cfdi_document,Acceso a certificados 4.0,model_l10n_mx_cfdi_document,base.group_user,1,1,1,1
l10n_mx_cfdi.access_l10n_mx_cfdi_document_relation,access_l10n_mx_cfdi_document_relation,l10n_mx_cfdi.model_l10n_mx_cfdi_document_relation,base.group_user,1,1,1,1
l10n_mx_cfdi.access_l10n_mx_cfdi_series,access_l10n_mx_cfdi_series,l10n_mx_cfdi.model_l10n_mx_cfdi_series,base.group_user,1,0,0,0
l10n_mx_cfdi.manage_l10n_mx_cfdi_series,manage_l10n_mx_cfdi_series,l10n_mx_cfdi.model_l10n_mx_cfdi_series,account.group_account_manager,1,1,1,1
access_l10n_mx_cfdi_document_relation,access_l10n_mx_cfdi_document_relation,model_l10n_mx_cfdi_document_relation,base.group_user,1,1,1,1
access_l10n_mx_cfdi_series,access_l10n_mx_cfdi_series,model_l10n_mx_cfdi_series,base.group_user,1,0,0,0
2 changes: 1 addition & 1 deletion l10n_mx_cfdi/views/cfdi_documents_issued.xml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
<menuitem
id="menu_cfdi_documents_issued"
name="CFDI Emitidos"
parent="account.menu_finance_receivables"
parent="l10n_mx_cfdi.cfdi_menu"
groups="base.group_user"
action="action_l10n_mx_cfdi_documents_issued"
/>
Expand Down
7 changes: 1 addition & 6 deletions l10n_mx_cfdi/views/cfdi_menu.xml
Original file line number Diff line number Diff line change
@@ -1,10 +1,5 @@
<odoo>

<menuitem
id="cfdi_menu"
name="CFDI"
parent="account.menu_finance_configuration"
groups="base.group_user"
/>
<menuitem id="cfdi_menu" name="CFDI" groups="base.group_user" />

</odoo>
19 changes: 11 additions & 8 deletions l10n_mx_cfdi/views/product_template.xml
Original file line number Diff line number Diff line change
@@ -1,16 +1,19 @@
<odoo>
<record id="product_template_form_view_inherit" model="ir.ui.view">
<field
name="name"
>Product Template: CFDI code and measurement unit fields</field>
<field name="name">Product Template: CFDI code and measurement unit fields
</field>
<field name="model">product.template</field>
<field name="inherit_id" ref="product.product_template_form_view" />
<field name="arch" type="xml">
<xpath expr="//page[@name='invoicing']" position="inside">
<group string="CFDI">
<field name="l10n_mx_cfdi_product_code_id" />
<field name="l10n_mx_cfdi_product_measurement_unit_id" />
</group>
<xpath expr="//page" position="after">
<page name="CFDI">


<group string="CFDI">
<field name="l10n_mx_cfdi_product_code_id" />
<field name="l10n_mx_cfdi_product_measurement_unit_id" />
</group>
</page>
</xpath>
</field>
</record>
Expand Down
25 changes: 16 additions & 9 deletions l10n_mx_cfdi/views/res_partner.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,15 +4,22 @@
<field name="model">res.partner</field>
<field name="inherit_id" ref="base.view_partner_form" />
<field name="arch" type="xml">
<field name="property_account_position_id" position="attributes">
<attribute name="invisible">1</attribute>
</field>
<field name="property_account_position_id" position="after">
<field name="tax_regime" />
<field name="cfdi_use_id" />
<field name="payment_method_id" />
<field name="payment_form_id" />
</field>

<!-- <field name="property_account_position_id" position="attributes">-->
<!-- <attribute name="invisible">1</attribute>-->
<!-- </field>-->
<!-- <field name="property_account_position_id" position="after">-->
<xpath expr="//page" position="after">
<page name="CDFI">
<group>
<field name="tax_regime" />
<field name="cfdi_use_id" />
<field name="payment_method_id" />
<field name="payment_form_id" />
</group>
</page>
<!-- </field>-->
</xpath>
</field>
</record>
</odoo>
146 changes: 146 additions & 0 deletions l10n_mx_cfdi_account/README.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,146 @@
=======================
Mexico - CFDI - Account
=======================

..
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
!! This file is generated by oca-gen-addon-readme !!
!! changes will be overwritten. !!
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
!! source digest: sha256:26e47d930a46acf27c2c6e22f53f714adc3335be2cac745f521c692ad736dbcb
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
.. |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%2Fl10n--mexico-lightgray.png?logo=github
:target: https://github.com/OCA/l10n-mexico/tree/17.0/l10n_mx_cfdi_account
:alt: OCA/l10n-mexico
.. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png
:target: https://translation.odoo-community.org/projects/l10n-mexico-17-0/l10n-mexico-17-0-l10n_mx_cfdi_account
: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/l10n-mexico&target_branch=17.0
:alt: Try me on Runboat

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

This module provides electronic invoicing for Mexico:

- Generation of electronic invoices compliant with the CFDI 4.0
standard.
- Customization of fiscal documents according to user needs.
- Centralized management of electronic invoices within Odoo.
- Tracking and recording of issued and received fiscal documents.

**Table of contents**

.. contents::
:local:

Installation
============

Prior to installing this module, you need to create and configure your
account with one of the `supported PAC listed
here <https://github.com/OCA/l10n-mexico/blob/17.0/l10n_mx_cfdi/README.md>`__.

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

1. In the invoicing app, go to Customers > customers

1. Create a new customer with its corresponding id number and fiscal
name
2. In the contact form, go to Sales & purchase tab
3. In the Fiscal Information section add the following information:

- Fiscal regime
- Default CFDI usage
- Default payment method
- Default payment form

2. In the invoicing app, go to Customers > Products

1. Open an existing product or create a new one and enter the general
information
2. Go to the Accounting tab in the product form
3. Add the product code and the unit of measure corresponding to
authority regulations

Usage
=====

Invoices
--------

- Go to Customers > Invoices and create a new record
- Fill in the previously created customer, the client’s previously
added fiscal information is essential for the stamping process.
- Add any product that has its product fiscal code
- Open the CFDI tab and add the payment method, and payment form
- Select the Confirm button, the invoice will be stamped with the
mexican authority
- Select the Send button to send the invoice to the customer

Import CFDI
~~~~~~~~~~~

- Add the vendor bill xml file as an attachment in the chatter
- Click "Load from file" button

Payments
--------

If the invoice payment method is PPD, the payment will be included in
the CFDI lines when registering a payment.

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

- Cancel CFDI Documents
- Credit Notes

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

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

* Alexis López Zubieta <alexis.lopez@augetec.com> (Auge TEC)

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

- Alexis López Zubieta <alexis.lopez@augetec.com>
- Maxime Chambreuil <mchambreuil@opensourceintegrators.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/l10n-mexico <https://github.com/OCA/l10n-mexico/tree/17.0/l10n_mx_cfdi_account>`_ 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 l10n_mx_cfdi_account/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
from . import models
from . import wizards
25 changes: 25 additions & 0 deletions l10n_mx_cfdi_account/__manifest__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
{
"name": "Mexico - CFDI - Account",
"summary": "Mexico CFDI Account Integration",
"author": "Alexis López Zubieta <alexis.lopez@augetec.com> (Auge TEC), "
"Odoo Community Association (OCA)",
"website": "https://github.com/OCA/l10n-mexico",
"license": "LGPL-3",
"category": "Accounting",
"version": "17.0.1.0.0",
"depends": ["l10n_mx_cfdi", "l10n_mx"],
"data": [
"security/ir.model.access.csv",
"views/account_move.xml",
"views/account_payment_register.xml",
"views/account_payment.xml",
"views/res_config_settings.xml",
"wizards/document_cancel_form.xml",
"wizards/create_cfdi_publico_en_general.xml",
"wizards/account_invoice_send_views.xml",
"wizards/download_cfdi_files_wizard.xml",
"reports/report_external_layouts.xml",
"reports/report_invoice.xml",
"reports/report_payment.xml",
],
}
Loading

0 comments on commit 1870159

Please sign in to comment.