mirror of
https://github.com/OCA/account-reconcile.git
synced 2025-01-20 12:27:39 +02:00
0
bank_statement_journal_items/README.rst
Normal file
0
bank_statement_journal_items/README.rst
Normal file
1
bank_statement_journal_items/__init__.py
Normal file
1
bank_statement_journal_items/__init__.py
Normal file
@@ -0,0 +1 @@
|
||||
from . import models
|
||||
16
bank_statement_journal_items/__manifest__.py
Normal file
16
bank_statement_journal_items/__manifest__.py
Normal file
@@ -0,0 +1,16 @@
|
||||
# Copyright 2020 Camptocamp
|
||||
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
|
||||
|
||||
{
|
||||
"name": "Bank Statement Journal Items",
|
||||
"summary": "Add Journal Items button in the bank statements",
|
||||
"version": "13.0.1.0.0",
|
||||
"depends": ["account"],
|
||||
"author": "Camptocamp, Odoo Community Association (OCA)",
|
||||
"website": "http://www.github.com/OCA/account-reconcile",
|
||||
"category": "Finance",
|
||||
"data": ["views/bank_statement.xml"],
|
||||
"license": "AGPL-3",
|
||||
"auto_install": False,
|
||||
"installable": True,
|
||||
}
|
||||
1
bank_statement_journal_items/models/__init__.py
Normal file
1
bank_statement_journal_items/models/__init__.py
Normal file
@@ -0,0 +1 @@
|
||||
from . import account_bank_statement
|
||||
@@ -0,0 +1,24 @@
|
||||
# Copyright 2020 Camptocamp
|
||||
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
|
||||
|
||||
from odoo import models
|
||||
from odoo.tools.translate import _
|
||||
|
||||
|
||||
class AccountBankStatement(models.Model):
|
||||
|
||||
_inherit = "account.bank.statement"
|
||||
|
||||
def button_journal_items(self):
|
||||
return {
|
||||
"name": _("Journal Items"),
|
||||
"view_mode": "tree,form",
|
||||
"res_model": "account.move.line",
|
||||
"views": [
|
||||
(self.env.ref("account.view_move_line_tree").id, "tree"),
|
||||
(self.env.ref("account.view_move_line_form").id, "form"),
|
||||
],
|
||||
"type": "ir.actions.act_window",
|
||||
"domain": [("id", "in", self.mapped("move_line_ids").ids)],
|
||||
"context": {"journal_id": self.journal_id.id},
|
||||
}
|
||||
3
bank_statement_journal_items/readme/CONTRIBUTORS.rst
Normal file
3
bank_statement_journal_items/readme/CONTRIBUTORS.rst
Normal file
@@ -0,0 +1,3 @@
|
||||
* `Camptocamp <https://www.camptocamp.com>`_:
|
||||
|
||||
* Anna Janiszewska
|
||||
1
bank_statement_journal_items/readme/DESCRIPTION.rst
Normal file
1
bank_statement_journal_items/readme/DESCRIPTION.rst
Normal file
@@ -0,0 +1 @@
|
||||
This module adds a smart button on bank statement form view, allowing you to display its journal items.
|
||||
19
bank_statement_journal_items/views/bank_statement.xml
Normal file
19
bank_statement_journal_items/views/bank_statement.xml
Normal file
@@ -0,0 +1,19 @@
|
||||
<?xml version="1.0" encoding="utf-8" ?>
|
||||
<odoo>
|
||||
<record id="view_bank_statement_journal_items_form" model="ir.ui.view">
|
||||
<field name="name">account.bank.statement.journal.items.form</field>
|
||||
<field name="model">account.bank.statement</field>
|
||||
<field name="inherit_id" ref="account.view_bank_statement_form" />
|
||||
<field name="arch" type="xml">
|
||||
<xpath expr="//button[@name='button_journal_entries']" position="before">
|
||||
<button
|
||||
class="oe_stat_button"
|
||||
name="button_journal_items"
|
||||
string="Journal Items"
|
||||
type="object"
|
||||
icon="fa-bars"
|
||||
/>
|
||||
</xpath>
|
||||
</field>
|
||||
</record>
|
||||
</odoo>
|
||||
@@ -0,0 +1 @@
|
||||
../../../../bank_statement_journal_items
|
||||
6
setup/bank_statement_journal_items/setup.py
Normal file
6
setup/bank_statement_journal_items/setup.py
Normal file
@@ -0,0 +1,6 @@
|
||||
import setuptools
|
||||
|
||||
setuptools.setup(
|
||||
setup_requires=['setuptools-odoo'],
|
||||
odoo_addon=True,
|
||||
)
|
||||
Reference in New Issue
Block a user