Skip to content

Commit

Permalink
Merge a451bb6 into 7c1f4bc
Browse files Browse the repository at this point in the history
  • Loading branch information
kittiu committed Apr 10, 2019
2 parents 7c1f4bc + a451bb6 commit 4b67654
Show file tree
Hide file tree
Showing 14 changed files with 693 additions and 0 deletions.
84 changes: 84 additions & 0 deletions account_payment_show_invoice/README.rst
@@ -0,0 +1,84 @@
============================
Account Payment Show Invoice
============================

.. !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
!! 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%2Faccount--payment-lightgray.png?logo=github
:target: https://github.com/OCA/account-payment/tree/12.0/account_payment_show_invoice
:alt: OCA/account-payment
.. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png
:target: https://translation.odoo-community.org/projects/account-payment-12-0/account-payment-12-0-account_payment_show_invoice
:alt: Translate me on Weblate
.. |badge5| image:: https://img.shields.io/badge/runbot-Try%20me-875A7B.png
:target: https://runbot.odoo-community.org/runbot/96/12.0
:alt: Try me on Runbot

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

This module extends the tree view of payments to show the paid invoices
related to the payments using the vendor reference by default.

**Table of contents**

.. contents::
:local:

Usage
=====

To use this module, you need to:

#. Go to 'Invoicing > Vendors > Payments' or to 'Invoicing > Customers >
Payments'
#. There you can see a new column *Invoices*.

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

Bugs are tracked on `GitHub Issues <https://github.com/OCA/account-payment/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 <https://github.com/OCA/account-payment/issues/new?body=module:%20account_payment_show_invoice%0Aversion:%2012.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
~~~~~~~

* Eficent

Contributors
~~~~~~~~~~~~

* Lois Rilo <lois.rilo@eficent.com>
* Kitti Upariphutthiphong <kittiu@ecosoft.co.th>

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/account-payment <https://github.com/OCA/account-payment/tree/12.0/account_payment_show_invoice>`_ project on GitHub.

You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute.
3 changes: 3 additions & 0 deletions account_payment_show_invoice/__init__.py
@@ -0,0 +1,3 @@
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).

from . import models
18 changes: 18 additions & 0 deletions account_payment_show_invoice/__manifest__.py
@@ -0,0 +1,18 @@
# Copyright 2017 Eficent Business and IT Consulting Services, S.L.
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
{
"name": "Account Payment Show Invoice",
"summary": "Extends the tree view of payments to show the paid invoices "
"related to the payments using the vendor reference by default",
"version": "12.0.1.0.0",
"category": "Account-payment",
"website": "https://odoo-community.org/",
"author": "Eficent, Odoo Community Association (OCA)",
"license": "AGPL-3",
"application": False,
"installable": True,
"depends": ["account"],
"data": [
"views/account_payment_view.xml",
],
}
27 changes: 27 additions & 0 deletions account_payment_show_invoice/i18n/account_payment_show_invoice.pot
@@ -0,0 +1,27 @@
# Translation of Odoo Server.
# This file contains the translation of the following modules:
# * account_payment_show_invoice
#
msgid ""
msgstr ""
"Project-Id-Version: Odoo Server 12.0\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2019-03-29 08:10+0000\n"
"PO-Revision-Date: 2019-03-29 08:10+0000\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: account_payment_show_invoice
#: model:ir.model.fields,field_description:account_payment_show_invoice.field_account_payment__invoice_vendor_references
msgid "Invoices"
msgstr ""

#. module: account_payment_show_invoice
#: model:ir.model,name:account_payment_show_invoice.model_account_payment
msgid "Payments"
msgstr ""

3 changes: 3 additions & 0 deletions account_payment_show_invoice/models/__init__.py
@@ -0,0 +1,3 @@
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).

from . import account_payment
19 changes: 19 additions & 0 deletions account_payment_show_invoice/models/account_payment.py
@@ -0,0 +1,19 @@
# Copyright 2017 Eficent Business and IT Consulting Services, S.L.
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).

from odoo import api, fields, models


class AccountPayment(models.Model):
_inherit = 'account.payment'

@api.multi
def _compute_invoice_vendor_references(self):
for payment in self:
ref = payment.invoice_ids.mapped(lambda x: x.reference or x.number)
ref.sort()
payment.invoice_vendor_references = ', '.join(ref)

invoice_vendor_references = fields.Char(
string='Ref Invoices',
compute=_compute_invoice_vendor_references)
2 changes: 2 additions & 0 deletions account_payment_show_invoice/readme/CONTRIBUTORS.rst
@@ -0,0 +1,2 @@
* Lois Rilo <lois.rilo@eficent.com>
* Kitti Upariphutthiphong <kittiu@ecosoft.co.th>
2 changes: 2 additions & 0 deletions account_payment_show_invoice/readme/DESCRIPTION.rst
@@ -0,0 +1,2 @@
This module extends the tree view of payments to show the paid invoices
related to the payments using the vendor reference by default.
5 changes: 5 additions & 0 deletions account_payment_show_invoice/readme/USAGE.rst
@@ -0,0 +1,5 @@
To use this module, you need to:

#. Go to 'Invoicing > Vendors > Payments' or to 'Invoicing > Customers >
Payments'
#. There you can see a new column *Invoices*.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit 4b67654

Please sign in to comment.