mirror of
https://github.com/bringout/odoomates.git
synced 2026-04-18 04:12:04 +02:00
Initial commit: Odoomates Odoo packages (12 packages)
This commit is contained in:
commit
3b38c49bf0
526 changed files with 34983 additions and 0 deletions
47
odoo-bringout-odoomates-om_account_daily_reports/README.md
Normal file
47
odoo-bringout-odoomates-om_account_daily_reports/README.md
Normal file
|
|
@ -0,0 +1,47 @@
|
|||
# Cash Book, Day Book, Bank Book Financial Reports
|
||||
|
||||
Cash Book, Day Book and Bank Book Report For Odoo 16
|
||||
|
||||
## Installation
|
||||
|
||||
```bash
|
||||
pip install odoo-bringout-odoomates-om_account_daily_reports
|
||||
```
|
||||
|
||||
## Dependencies
|
||||
|
||||
This addon depends on:
|
||||
- account
|
||||
- accounting_pdf_reports
|
||||
|
||||
## Manifest Information
|
||||
|
||||
- **Name**: Cash Book, Day Book, Bank Book Financial Reports
|
||||
- **Version**: 16.0.1.0.2
|
||||
- **Category**: Invoicing Management
|
||||
- **License**: LGPL-3
|
||||
- **Installable**: True
|
||||
|
||||
## Source
|
||||
|
||||
Custom addon from bringout-odoomates vendor, addon `om_account_daily_reports`.
|
||||
|
||||
## License
|
||||
|
||||
This package maintains the original LGPL-3 license from the addon.
|
||||
|
||||
## Documentation
|
||||
|
||||
- Overview: doc/OVERVIEW.md
|
||||
- Architecture: doc/ARCHITECTURE.md
|
||||
- Models: doc/MODELS.md
|
||||
- Controllers: doc/CONTROLLERS.md
|
||||
- Wizards: doc/WIZARDS.md
|
||||
- Reports: doc/REPORTS.md
|
||||
- Security: doc/SECURITY.md
|
||||
- Install: doc/INSTALL.md
|
||||
- Usage: doc/USAGE.md
|
||||
- Configuration: doc/CONFIGURATION.md
|
||||
- Dependencies: doc/DEPENDENCIES.md
|
||||
- Troubleshooting: doc/TROUBLESHOOTING.md
|
||||
- FAQ: doc/FAQ.md
|
||||
|
|
@ -0,0 +1,32 @@
|
|||
# Architecture
|
||||
|
||||
```mermaid
|
||||
flowchart TD
|
||||
U[Users] -->|HTTP| V[Views and QWeb Templates]
|
||||
V --> C[Controllers]
|
||||
V --> W[Wizards – Transient Models]
|
||||
C --> M[Models and ORM]
|
||||
W --> M
|
||||
M --> R[Reports]
|
||||
DX[Data XML] --> M
|
||||
S[Security – ACLs and Groups] -. enforces .-> M
|
||||
|
||||
subgraph Om_account_daily_reports Module - om_account_daily_reports
|
||||
direction LR
|
||||
M:::layer
|
||||
W:::layer
|
||||
C:::layer
|
||||
V:::layer
|
||||
R:::layer
|
||||
S:::layer
|
||||
DX:::layer
|
||||
end
|
||||
|
||||
classDef layer fill:#eef8ff,stroke:#6ea8fe,stroke-width:1px
|
||||
```
|
||||
|
||||
Notes
|
||||
- Views include tree/form/kanban templates and report templates.
|
||||
- Controllers provide website/portal routes when present.
|
||||
- Wizards are UI flows implemented with `models.TransientModel`.
|
||||
- Data XML loads data/demo records; Security defines groups and access.
|
||||
|
|
@ -0,0 +1,3 @@
|
|||
# Configuration
|
||||
|
||||
Refer to Odoo settings for om_account_daily_reports. Configure related models, access rights, and options as needed.
|
||||
|
|
@ -0,0 +1,3 @@
|
|||
# Controllers
|
||||
|
||||
This module does not define custom HTTP controllers.
|
||||
|
|
@ -0,0 +1,6 @@
|
|||
# Dependencies
|
||||
|
||||
This addon depends on:
|
||||
|
||||
- [account](../../odoo-bringout-oca-ocb-account)
|
||||
- [accounting_pdf_reports](../../odoo-bringout-odoomates-accounting_pdf_reports)
|
||||
|
|
@ -0,0 +1,4 @@
|
|||
# FAQ
|
||||
|
||||
- Q: Which Odoo version? A: 16.0 (OCA/OCB packaged).
|
||||
- Q: How to enable? A: Start server with --addon om_account_daily_reports or install in UI.
|
||||
|
|
@ -0,0 +1,7 @@
|
|||
# Install
|
||||
|
||||
```bash
|
||||
pip install odoo-bringout-odoomates-om_account_daily_reports"
|
||||
# or
|
||||
uv pip install odoo-bringout-odoomates-om_account_daily_reports"
|
||||
```
|
||||
|
|
@ -0,0 +1,11 @@
|
|||
# Models
|
||||
|
||||
Detected core models and extensions in om_account_daily_reports.
|
||||
|
||||
```mermaid
|
||||
classDiagram
|
||||
```
|
||||
|
||||
Notes
|
||||
- Classes show model technical names; fields omitted for brevity.
|
||||
- Items listed under _inherit are extensions of existing models.
|
||||
|
|
@ -0,0 +1,6 @@
|
|||
# Overview
|
||||
|
||||
Packaged Odoo addon: om_account_daily_reports. Provides features documented in upstream Odoo 16 under this addon.
|
||||
|
||||
- Source: OCA/OCB 16.0, addon om_account_daily_reports
|
||||
- License: LGPL-3
|
||||
|
|
@ -0,0 +1,38 @@
|
|||
# Reports
|
||||
|
||||
Report definitions and templates in om_account_daily_reports.
|
||||
|
||||
```mermaid
|
||||
classDiagram
|
||||
class ReportDayBook
|
||||
AbstractModel <|-- ReportDayBook
|
||||
class ReportCashBook
|
||||
AbstractModel <|-- ReportCashBook
|
||||
class ReportBankBook
|
||||
AbstractModel <|-- ReportBankBook
|
||||
```
|
||||
|
||||
## Available Reports
|
||||
|
||||
### PDF/Document Reports
|
||||
- **Day Book** (PDF/Print)
|
||||
- **Cash Book** (PDF/Print)
|
||||
- **Bank Book** (PDF/Print)
|
||||
|
||||
|
||||
## Report Files
|
||||
|
||||
- **__init__.py** (Python logic)
|
||||
- **report_bankbook.py** (Python logic)
|
||||
- **report_bankbook.xml** (XML template/definition)
|
||||
- **report_cashbook.py** (Python logic)
|
||||
- **report_cashbook.xml** (XML template/definition)
|
||||
- **report_daybook.py** (Python logic)
|
||||
- **report_daybook.xml** (XML template/definition)
|
||||
- **reports.xml** (XML template/definition)
|
||||
|
||||
## Notes
|
||||
- Named reports above are accessible through Odoo's reporting menu
|
||||
- Python files define report logic and data processing
|
||||
- XML files contain report templates, definitions, and formatting
|
||||
- Reports are integrated with Odoo's printing and email systems
|
||||
|
|
@ -0,0 +1,34 @@
|
|||
# Security
|
||||
|
||||
Access control and security definitions in om_account_daily_reports.
|
||||
|
||||
## Access Control Lists (ACLs)
|
||||
|
||||
Model access permissions defined in:
|
||||
- **[ir.model.access.csv](../om_account_daily_reports/security/ir.model.access.csv)**
|
||||
- 2 model access rules
|
||||
|
||||
## Record Rules
|
||||
|
||||
Row-level security rules defined in:
|
||||
|
||||
```mermaid
|
||||
graph TB
|
||||
subgraph "Security Layers"
|
||||
A[Users] --> B[Groups]
|
||||
B --> C[Access Control Lists]
|
||||
C --> D[Models]
|
||||
B --> E[Record Rules]
|
||||
E --> F[Individual Records]
|
||||
end
|
||||
```
|
||||
|
||||
Security files overview:
|
||||
- **[ir.model.access.csv](../om_account_daily_reports/security/ir.model.access.csv)**
|
||||
- Model access permissions (CRUD rights)
|
||||
|
||||
Notes
|
||||
- Access Control Lists define which groups can access which models
|
||||
- Record Rules provide row-level security (filter records by user/group)
|
||||
- Security groups organize users and define permission sets
|
||||
- All security is enforced at the ORM level by Odoo
|
||||
|
|
@ -0,0 +1,5 @@
|
|||
# Troubleshooting
|
||||
|
||||
- Ensure Python and Odoo environment matches repo guidance.
|
||||
- Check database connectivity and logs if startup fails.
|
||||
- Validate that dependent addons listed in DEPENDENCIES.md are installed.
|
||||
|
|
@ -0,0 +1,7 @@
|
|||
# Usage
|
||||
|
||||
Start Odoo including this addon (from repo root):
|
||||
|
||||
```bash
|
||||
python3 scripts/nix_odoo_web_server.py --db-name mydb --addon om_account_daily_reports
|
||||
```
|
||||
|
|
@ -0,0 +1,10 @@
|
|||
# Wizards
|
||||
|
||||
Transient models exposed as UI wizards in om_account_daily_reports.
|
||||
|
||||
```mermaid
|
||||
classDiagram
|
||||
class AccountBankBookReport
|
||||
class AccountCashBookReport
|
||||
class AccountDayBookReport
|
||||
```
|
||||
|
|
@ -0,0 +1,45 @@
|
|||
=============================
|
||||
Odoo 16 Daily Financial Reports
|
||||
=============================
|
||||
|
||||
This module will add the reports like cash book report, bank book report and day book report
|
||||
|
||||
Installation
|
||||
============
|
||||
|
||||
To install this module, you need to:
|
||||
|
||||
Download the module and add it to your Odoo addons folder. Afterward, log on to
|
||||
your Odoo server and go to the Apps menu. Trigger the debug mode and update the
|
||||
list by clicking on the "Update Apps List" link. Now install the module by
|
||||
clicking on the install button.
|
||||
|
||||
Upgrade
|
||||
============
|
||||
|
||||
To upgrade this module, you need to:
|
||||
|
||||
Download the module and add it to your Odoo addons folder. Restart the server
|
||||
and log on to your Odoo server. Select the Apps menu and upgrade the module by
|
||||
clicking on the upgrade button.
|
||||
|
||||
|
||||
Configuration
|
||||
=============
|
||||
|
||||
There is Nothing to Configure
|
||||
|
||||
|
||||
Credits
|
||||
=======
|
||||
|
||||
Contributors
|
||||
------------
|
||||
|
||||
* Odoo Mates <odoomates@gmail.com>
|
||||
|
||||
|
||||
Author & Maintainer
|
||||
-------------------
|
||||
|
||||
This module is maintained by the Odoo Mates
|
||||
|
|
@ -0,0 +1,4 @@
|
|||
# -*- coding: utf-8 -*-
|
||||
|
||||
from . import wizard
|
||||
from . import report
|
||||
|
|
@ -0,0 +1,36 @@
|
|||
# -*- coding: utf-8 -*-
|
||||
# Part of Odoo. See LICENSE file for full copyright and licensing details.
|
||||
|
||||
{
|
||||
'name': 'Cash Book, Day Book, Bank Book Financial Reports',
|
||||
'version': '16.0.1.0.2',
|
||||
'category': 'Invoicing Management',
|
||||
'summary': 'Cash Book, Day Book and Bank Book Report For Odoo 16',
|
||||
'description': 'Cash Book, Day Book and Bank Book Report For Odoo 16',
|
||||
'sequence': '10',
|
||||
'author': 'Odoo Mates',
|
||||
'license': 'LGPL-3',
|
||||
'company': 'Odoo Mates',
|
||||
'maintainer': 'Odoo Mates',
|
||||
'support': 'odoomates@gmail.com',
|
||||
'website': 'https://www.odoomates.tech',
|
||||
'depends': ['account', 'accounting_pdf_reports'],
|
||||
'live_test_url': '',
|
||||
'demo': [],
|
||||
'data': [
|
||||
'security/ir.model.access.csv',
|
||||
'views/om_daily_reports.xml',
|
||||
'wizard/daybook.xml',
|
||||
'wizard/cashbook.xml',
|
||||
'wizard/bankbook.xml',
|
||||
'report/reports.xml',
|
||||
'report/report_daybook.xml',
|
||||
'report/report_cashbook.xml',
|
||||
'report/report_bankbook.xml',
|
||||
],
|
||||
'installable': True,
|
||||
'application': False,
|
||||
'auto_install': False,
|
||||
'live_test_url': 'https://www.youtube.com/watch?v=PEh-an8iCO0',
|
||||
'images': ['static/description/banner.gif'],
|
||||
}
|
||||
|
|
@ -0,0 +1,6 @@
|
|||
## Module <om_account_daily_reports>
|
||||
|
||||
#### 22.07.2022
|
||||
#### Version 16.0.1.0.0
|
||||
##### ADD
|
||||
- initial release
|
||||
|
|
@ -0,0 +1,371 @@
|
|||
# Translation of Odoo Server.
|
||||
# This file contains the translation of the following modules:
|
||||
# * om_account_daily_reports
|
||||
#
|
||||
msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: Odoo Server 16.0\n"
|
||||
"Report-Msgid-Bugs-To: \n"
|
||||
"POT-Creation-Date: 2024-04-26 14:55+0000\n"
|
||||
"PO-Revision-Date: 2024-04-26 14:55+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: om_account_daily_reports
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_bankbook
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_cashbook
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_daybook
|
||||
msgid "<strong>End Date:</strong>"
|
||||
msgstr "<strong>End Datum:</strong>"
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_bankbook
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_cashbook
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_daybook
|
||||
msgid "<strong>Journals:</strong>"
|
||||
msgstr "<strong>Dnevnici:</strong>"
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_bankbook
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_cashbook
|
||||
msgid "<strong>Sorted By:</strong>"
|
||||
msgstr "<strong>Sortiranjeed By:</strong>"
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_bankbook
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_cashbook
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_daybook
|
||||
msgid "<strong>Start Date:</strong>"
|
||||
msgstr "<strong>Start Datum:</strong>"
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_bankbook
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_cashbook
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_daybook
|
||||
msgid "<strong>Target Moves:</strong>"
|
||||
msgstr "<strong>Transakcije:</strong>"
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_bankbook
|
||||
msgid "Account Bank Book"
|
||||
msgstr "Račun Bank Book"
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_cashbook
|
||||
msgid "Account Cash Book"
|
||||
msgstr "Račun Cash Book"
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_daybook
|
||||
msgid "Account Day Book"
|
||||
msgstr "Račun Day Book"
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model:ir.model.fields,field_description:om_account_daily_reports.field_account_bankbook_report__account_ids
|
||||
#: model:ir.model.fields,field_description:om_account_daily_reports.field_account_cashbook_report__account_ids
|
||||
#: model:ir.model.fields,field_description:om_account_daily_reports.field_account_daybook_report__account_ids
|
||||
msgid "Accounts"
|
||||
msgstr "Konta"
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model:ir.model.fields.selection,name:om_account_daily_reports.selection__account_bankbook_report__display_account__all
|
||||
#: model:ir.model.fields.selection,name:om_account_daily_reports.selection__account_cashbook_report__display_account__all
|
||||
msgid "All"
|
||||
msgstr "Sve"
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model:ir.model.fields.selection,name:om_account_daily_reports.selection__account_bankbook_report__target_move__all
|
||||
#: model:ir.model.fields.selection,name:om_account_daily_reports.selection__account_cashbook_report__target_move__all
|
||||
#: model:ir.model.fields.selection,name:om_account_daily_reports.selection__account_daybook_report__target_move__all
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_bankbook
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_cashbook
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_daybook
|
||||
msgid "All Entries"
|
||||
msgstr "Sve stavke"
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_bankbook
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_cashbook
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_daybook
|
||||
msgid "Balance"
|
||||
msgstr "Saldo"
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model:ir.actions.act_window,name:om_account_daily_reports.action_account_bankbook_menu
|
||||
#: model:ir.actions.report,name:om_account_daily_reports.action_report_bank_book
|
||||
#: model:ir.model,name:om_account_daily_reports.model_report_om_account_daily_reports_report_bankbook
|
||||
#: model:ir.ui.menu,name:om_account_daily_reports.menu_bankbook
|
||||
msgid "Bank Book"
|
||||
msgstr "Bank Book"
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model:ir.model,name:om_account_daily_reports.model_account_bankbook_report
|
||||
msgid "Bank Book Report"
|
||||
msgstr "Bank Book Izvještaj"
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.account_report_bankbook_view
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.account_report_cashbook_view
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.account_report_daybook_view
|
||||
msgid "Cancel"
|
||||
msgstr "Otkaži"
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model:ir.actions.act_window,name:om_account_daily_reports.action_account_cashbook_menu
|
||||
#: model:ir.actions.report,name:om_account_daily_reports.action_report_cash_book
|
||||
#: model:ir.model,name:om_account_daily_reports.model_report_om_account_daily_reports_report_cashbook
|
||||
#: model:ir.ui.menu,name:om_account_daily_reports.menu_cashbook
|
||||
msgid "Cash Book"
|
||||
msgstr "Cash Book"
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model:ir.model,name:om_account_daily_reports.model_account_cashbook_report
|
||||
msgid "Cash Book Report"
|
||||
msgstr "Cash Book Izvještaj"
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model:ir.model.fields,field_description:om_account_daily_reports.field_account_bankbook_report__create_uid
|
||||
#: model:ir.model.fields,field_description:om_account_daily_reports.field_account_cashbook_report__create_uid
|
||||
#: model:ir.model.fields,field_description:om_account_daily_reports.field_account_daybook_report__create_uid
|
||||
msgid "Created by"
|
||||
msgstr "Kreirao"
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model:ir.model.fields,field_description:om_account_daily_reports.field_account_bankbook_report__create_date
|
||||
#: model:ir.model.fields,field_description:om_account_daily_reports.field_account_cashbook_report__create_date
|
||||
#: model:ir.model.fields,field_description:om_account_daily_reports.field_account_daybook_report__create_date
|
||||
msgid "Created on"
|
||||
msgstr "Kreirano"
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_bankbook
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_cashbook
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_daybook
|
||||
msgid "Credit"
|
||||
msgstr "Potražuje"
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_bankbook
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_cashbook
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_daybook
|
||||
msgid "Currency"
|
||||
msgstr "Valuta"
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model:ir.ui.menu,name:om_account_daily_reports.menu_finance_daily_reports
|
||||
msgid "Daily Reports"
|
||||
msgstr "Daily Reports"
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model:ir.model.fields.selection,name:om_account_daily_reports.selection__account_bankbook_report__sortby__sort_date
|
||||
#: model:ir.model.fields.selection,name:om_account_daily_reports.selection__account_cashbook_report__sortby__sort_date
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_bankbook
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_cashbook
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_daybook
|
||||
msgid "Date"
|
||||
msgstr "Datum"
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model:ir.actions.act_window,name:om_account_daily_reports.action_account_daybook_menu
|
||||
#: model:ir.actions.report,name:om_account_daily_reports.action_report_day_book
|
||||
#: model:ir.model,name:om_account_daily_reports.model_report_om_account_daily_reports_report_daybook
|
||||
#: model:ir.ui.menu,name:om_account_daily_reports.menu_daybook
|
||||
msgid "Day Book"
|
||||
msgstr "Day Book"
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model:ir.model,name:om_account_daily_reports.model_account_daybook_report
|
||||
msgid "Day Book Report"
|
||||
msgstr "Day Book Izvještaj"
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_bankbook
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_cashbook
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_daybook
|
||||
msgid "Debit"
|
||||
msgstr "Duguje"
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model:ir.model.fields,field_description:om_account_daily_reports.field_account_bankbook_report__display_account
|
||||
#: model:ir.model.fields,field_description:om_account_daily_reports.field_account_cashbook_report__display_account
|
||||
msgid "Display Accounts"
|
||||
msgstr "Prikaži računs"
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model:ir.model.fields,field_description:om_account_daily_reports.field_account_bankbook_report__display_name
|
||||
#: model:ir.model.fields,field_description:om_account_daily_reports.field_account_cashbook_report__display_name
|
||||
#: model:ir.model.fields,field_description:om_account_daily_reports.field_account_daybook_report__display_name
|
||||
msgid "Display Name"
|
||||
msgstr "Prikazani naziv"
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model:ir.model.fields,field_description:om_account_daily_reports.field_account_bankbook_report__date_to
|
||||
#: model:ir.model.fields,field_description:om_account_daily_reports.field_account_cashbook_report__date_to
|
||||
#: model:ir.model.fields,field_description:om_account_daily_reports.field_account_daybook_report__date_to
|
||||
msgid "End Date"
|
||||
msgstr "Datum završetka"
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_bankbook
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_cashbook
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_daybook
|
||||
msgid "Entry Label"
|
||||
msgstr "Entry Labela"
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#. odoo-python
|
||||
#: code:addons/om_account_daily_reports/report/report_bankbook.py:0
|
||||
#: code:addons/om_account_daily_reports/report/report_cashbook.py:0
|
||||
#: code:addons/om_account_daily_reports/report/report_daybook.py:0
|
||||
#, python-format
|
||||
msgid "Form content is missing, this report cannot be printed."
|
||||
msgstr "Nedostaju podaci sa forme, izvještaj se ne može ispisati."
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model:ir.model.fields,field_description:om_account_daily_reports.field_account_bankbook_report__id
|
||||
#: model:ir.model.fields,field_description:om_account_daily_reports.field_account_cashbook_report__id
|
||||
#: model:ir.model.fields,field_description:om_account_daily_reports.field_account_daybook_report__id
|
||||
msgid "ID"
|
||||
msgstr "ID"
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model:ir.model.fields,help:om_account_daily_reports.field_account_bankbook_report__initial_balance
|
||||
#: model:ir.model.fields,help:om_account_daily_reports.field_account_cashbook_report__initial_balance
|
||||
msgid ""
|
||||
"If you selected date, this field allow you to add a row to display the "
|
||||
"amount of debit/credit/balance that precedes the filter you've set."
|
||||
msgstr ""
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model:ir.model.fields,field_description:om_account_daily_reports.field_account_bankbook_report__initial_balance
|
||||
#: model:ir.model.fields,field_description:om_account_daily_reports.field_account_cashbook_report__initial_balance
|
||||
msgid "Include Initial Balances"
|
||||
msgstr "Include Initial Saldos"
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_bankbook
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_cashbook
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_daybook
|
||||
msgid "JRNL"
|
||||
msgstr "ŽURN"
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model:ir.model.fields.selection,name:om_account_daily_reports.selection__account_bankbook_report__sortby__sort_journal_partner
|
||||
#: model:ir.model.fields.selection,name:om_account_daily_reports.selection__account_cashbook_report__sortby__sort_journal_partner
|
||||
msgid "Journal & Partner"
|
||||
msgstr "Žurnal & Partner"
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_bankbook
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_cashbook
|
||||
msgid "Journal and Partner"
|
||||
msgstr "Dnevnik and Partner"
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model:ir.model.fields,field_description:om_account_daily_reports.field_account_bankbook_report__journal_ids
|
||||
#: model:ir.model.fields,field_description:om_account_daily_reports.field_account_cashbook_report__journal_ids
|
||||
#: model:ir.model.fields,field_description:om_account_daily_reports.field_account_daybook_report__journal_ids
|
||||
msgid "Journals"
|
||||
msgstr "Žurnali"
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model:ir.model.fields,field_description:om_account_daily_reports.field_account_bankbook_report____last_update
|
||||
#: model:ir.model.fields,field_description:om_account_daily_reports.field_account_cashbook_report____last_update
|
||||
#: model:ir.model.fields,field_description:om_account_daily_reports.field_account_daybook_report____last_update
|
||||
msgid "Last Modified on"
|
||||
msgstr "Zadnje mijenjano"
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model:ir.model.fields,field_description:om_account_daily_reports.field_account_bankbook_report__write_uid
|
||||
#: model:ir.model.fields,field_description:om_account_daily_reports.field_account_cashbook_report__write_uid
|
||||
#: model:ir.model.fields,field_description:om_account_daily_reports.field_account_daybook_report__write_uid
|
||||
msgid "Last Updated by"
|
||||
msgstr "Zadnji ažurirao"
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model:ir.model.fields,field_description:om_account_daily_reports.field_account_bankbook_report__write_date
|
||||
#: model:ir.model.fields,field_description:om_account_daily_reports.field_account_cashbook_report__write_date
|
||||
#: model:ir.model.fields,field_description:om_account_daily_reports.field_account_daybook_report__write_date
|
||||
msgid "Last Updated on"
|
||||
msgstr "Zadnje ažurirano"
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_bankbook
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_cashbook
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_daybook
|
||||
msgid "Move"
|
||||
msgstr "Kretanje"
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_bankbook
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_cashbook
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_daybook
|
||||
msgid "Partner"
|
||||
msgstr "Partner"
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model:ir.model.fields.selection,name:om_account_daily_reports.selection__account_bankbook_report__target_move__posted
|
||||
#: model:ir.model.fields.selection,name:om_account_daily_reports.selection__account_cashbook_report__target_move__posted
|
||||
#: model:ir.model.fields.selection,name:om_account_daily_reports.selection__account_daybook_report__target_move__posted
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_bankbook
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_cashbook
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_daybook
|
||||
msgid "Posted Entries"
|
||||
msgstr "Knjižene zapise"
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.account_report_bankbook_view
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.account_report_cashbook_view
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.account_report_daybook_view
|
||||
msgid "Print"
|
||||
msgstr "Ispis"
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_bankbook
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_cashbook
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_daybook
|
||||
msgid "Ref"
|
||||
msgstr "Ref"
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.account_report_bankbook_view
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.account_report_cashbook_view
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.account_report_daybook_view
|
||||
msgid "Report Options"
|
||||
msgstr "Izvještaj Options"
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model:ir.model.fields,field_description:om_account_daily_reports.field_account_bankbook_report__sortby
|
||||
#: model:ir.model.fields,field_description:om_account_daily_reports.field_account_cashbook_report__sortby
|
||||
msgid "Sort by"
|
||||
msgstr "Sortiraj po"
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model:ir.model.fields,field_description:om_account_daily_reports.field_account_bankbook_report__date_from
|
||||
#: model:ir.model.fields,field_description:om_account_daily_reports.field_account_cashbook_report__date_from
|
||||
#: model:ir.model.fields,field_description:om_account_daily_reports.field_account_daybook_report__date_from
|
||||
msgid "Start Date"
|
||||
msgstr "Početni datum"
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model:ir.model.fields,field_description:om_account_daily_reports.field_account_bankbook_report__target_move
|
||||
#: model:ir.model.fields,field_description:om_account_daily_reports.field_account_cashbook_report__target_move
|
||||
#: model:ir.model.fields,field_description:om_account_daily_reports.field_account_daybook_report__target_move
|
||||
msgid "Target Moves"
|
||||
msgstr "Ciljane stavke"
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model:ir.model.fields.selection,name:om_account_daily_reports.selection__account_bankbook_report__display_account__not_zero
|
||||
#: model:ir.model.fields.selection,name:om_account_daily_reports.selection__account_cashbook_report__display_account__not_zero
|
||||
msgid "With balance is not equal to 0"
|
||||
msgstr "Saldo je različit od 0"
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model:ir.model.fields.selection,name:om_account_daily_reports.selection__account_bankbook_report__display_account__movement
|
||||
#: model:ir.model.fields.selection,name:om_account_daily_reports.selection__account_cashbook_report__display_account__movement
|
||||
msgid "With movements"
|
||||
msgstr "With movements"
|
||||
|
|
@ -0,0 +1,371 @@
|
|||
# Translation of Odoo Server.
|
||||
# This file contains the translation of the following modules:
|
||||
# * om_account_daily_reports
|
||||
#
|
||||
msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: Odoo Server 16.0\n"
|
||||
"Report-Msgid-Bugs-To: \n"
|
||||
"POT-Creation-Date: 2024-04-26 14:55+0000\n"
|
||||
"PO-Revision-Date: 2024-04-26 14:55+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: om_account_daily_reports
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_bankbook
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_cashbook
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_daybook
|
||||
msgid "<strong>End Date:</strong>"
|
||||
msgstr ""
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_bankbook
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_cashbook
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_daybook
|
||||
msgid "<strong>Journals:</strong>"
|
||||
msgstr ""
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_bankbook
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_cashbook
|
||||
msgid "<strong>Sorted By:</strong>"
|
||||
msgstr ""
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_bankbook
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_cashbook
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_daybook
|
||||
msgid "<strong>Start Date:</strong>"
|
||||
msgstr ""
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_bankbook
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_cashbook
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_daybook
|
||||
msgid "<strong>Target Moves:</strong>"
|
||||
msgstr ""
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_bankbook
|
||||
msgid "Account Bank Book"
|
||||
msgstr ""
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_cashbook
|
||||
msgid "Account Cash Book"
|
||||
msgstr ""
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_daybook
|
||||
msgid "Account Day Book"
|
||||
msgstr ""
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model:ir.model.fields,field_description:om_account_daily_reports.field_account_bankbook_report__account_ids
|
||||
#: model:ir.model.fields,field_description:om_account_daily_reports.field_account_cashbook_report__account_ids
|
||||
#: model:ir.model.fields,field_description:om_account_daily_reports.field_account_daybook_report__account_ids
|
||||
msgid "Accounts"
|
||||
msgstr ""
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model:ir.model.fields.selection,name:om_account_daily_reports.selection__account_bankbook_report__display_account__all
|
||||
#: model:ir.model.fields.selection,name:om_account_daily_reports.selection__account_cashbook_report__display_account__all
|
||||
msgid "All"
|
||||
msgstr ""
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model:ir.model.fields.selection,name:om_account_daily_reports.selection__account_bankbook_report__target_move__all
|
||||
#: model:ir.model.fields.selection,name:om_account_daily_reports.selection__account_cashbook_report__target_move__all
|
||||
#: model:ir.model.fields.selection,name:om_account_daily_reports.selection__account_daybook_report__target_move__all
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_bankbook
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_cashbook
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_daybook
|
||||
msgid "All Entries"
|
||||
msgstr ""
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_bankbook
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_cashbook
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_daybook
|
||||
msgid "Balance"
|
||||
msgstr ""
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model:ir.actions.act_window,name:om_account_daily_reports.action_account_bankbook_menu
|
||||
#: model:ir.actions.report,name:om_account_daily_reports.action_report_bank_book
|
||||
#: model:ir.model,name:om_account_daily_reports.model_report_om_account_daily_reports_report_bankbook
|
||||
#: model:ir.ui.menu,name:om_account_daily_reports.menu_bankbook
|
||||
msgid "Bank Book"
|
||||
msgstr ""
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model:ir.model,name:om_account_daily_reports.model_account_bankbook_report
|
||||
msgid "Bank Book Report"
|
||||
msgstr ""
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.account_report_bankbook_view
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.account_report_cashbook_view
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.account_report_daybook_view
|
||||
msgid "Cancel"
|
||||
msgstr ""
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model:ir.actions.act_window,name:om_account_daily_reports.action_account_cashbook_menu
|
||||
#: model:ir.actions.report,name:om_account_daily_reports.action_report_cash_book
|
||||
#: model:ir.model,name:om_account_daily_reports.model_report_om_account_daily_reports_report_cashbook
|
||||
#: model:ir.ui.menu,name:om_account_daily_reports.menu_cashbook
|
||||
msgid "Cash Book"
|
||||
msgstr ""
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model:ir.model,name:om_account_daily_reports.model_account_cashbook_report
|
||||
msgid "Cash Book Report"
|
||||
msgstr ""
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model:ir.model.fields,field_description:om_account_daily_reports.field_account_bankbook_report__create_uid
|
||||
#: model:ir.model.fields,field_description:om_account_daily_reports.field_account_cashbook_report__create_uid
|
||||
#: model:ir.model.fields,field_description:om_account_daily_reports.field_account_daybook_report__create_uid
|
||||
msgid "Created by"
|
||||
msgstr ""
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model:ir.model.fields,field_description:om_account_daily_reports.field_account_bankbook_report__create_date
|
||||
#: model:ir.model.fields,field_description:om_account_daily_reports.field_account_cashbook_report__create_date
|
||||
#: model:ir.model.fields,field_description:om_account_daily_reports.field_account_daybook_report__create_date
|
||||
msgid "Created on"
|
||||
msgstr ""
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_bankbook
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_cashbook
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_daybook
|
||||
msgid "Credit"
|
||||
msgstr ""
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_bankbook
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_cashbook
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_daybook
|
||||
msgid "Currency"
|
||||
msgstr ""
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model:ir.ui.menu,name:om_account_daily_reports.menu_finance_daily_reports
|
||||
msgid "Daily Reports"
|
||||
msgstr ""
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model:ir.model.fields.selection,name:om_account_daily_reports.selection__account_bankbook_report__sortby__sort_date
|
||||
#: model:ir.model.fields.selection,name:om_account_daily_reports.selection__account_cashbook_report__sortby__sort_date
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_bankbook
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_cashbook
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_daybook
|
||||
msgid "Date"
|
||||
msgstr ""
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model:ir.actions.act_window,name:om_account_daily_reports.action_account_daybook_menu
|
||||
#: model:ir.actions.report,name:om_account_daily_reports.action_report_day_book
|
||||
#: model:ir.model,name:om_account_daily_reports.model_report_om_account_daily_reports_report_daybook
|
||||
#: model:ir.ui.menu,name:om_account_daily_reports.menu_daybook
|
||||
msgid "Day Book"
|
||||
msgstr ""
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model:ir.model,name:om_account_daily_reports.model_account_daybook_report
|
||||
msgid "Day Book Report"
|
||||
msgstr ""
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_bankbook
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_cashbook
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_daybook
|
||||
msgid "Debit"
|
||||
msgstr ""
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model:ir.model.fields,field_description:om_account_daily_reports.field_account_bankbook_report__display_account
|
||||
#: model:ir.model.fields,field_description:om_account_daily_reports.field_account_cashbook_report__display_account
|
||||
msgid "Display Accounts"
|
||||
msgstr ""
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model:ir.model.fields,field_description:om_account_daily_reports.field_account_bankbook_report__display_name
|
||||
#: model:ir.model.fields,field_description:om_account_daily_reports.field_account_cashbook_report__display_name
|
||||
#: model:ir.model.fields,field_description:om_account_daily_reports.field_account_daybook_report__display_name
|
||||
msgid "Display Name"
|
||||
msgstr ""
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model:ir.model.fields,field_description:om_account_daily_reports.field_account_bankbook_report__date_to
|
||||
#: model:ir.model.fields,field_description:om_account_daily_reports.field_account_cashbook_report__date_to
|
||||
#: model:ir.model.fields,field_description:om_account_daily_reports.field_account_daybook_report__date_to
|
||||
msgid "End Date"
|
||||
msgstr ""
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_bankbook
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_cashbook
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_daybook
|
||||
msgid "Entry Label"
|
||||
msgstr ""
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#. odoo-python
|
||||
#: code:addons/om_account_daily_reports/report/report_bankbook.py:0
|
||||
#: code:addons/om_account_daily_reports/report/report_cashbook.py:0
|
||||
#: code:addons/om_account_daily_reports/report/report_daybook.py:0
|
||||
#, python-format
|
||||
msgid "Form content is missing, this report cannot be printed."
|
||||
msgstr ""
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model:ir.model.fields,field_description:om_account_daily_reports.field_account_bankbook_report__id
|
||||
#: model:ir.model.fields,field_description:om_account_daily_reports.field_account_cashbook_report__id
|
||||
#: model:ir.model.fields,field_description:om_account_daily_reports.field_account_daybook_report__id
|
||||
msgid "ID"
|
||||
msgstr ""
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model:ir.model.fields,help:om_account_daily_reports.field_account_bankbook_report__initial_balance
|
||||
#: model:ir.model.fields,help:om_account_daily_reports.field_account_cashbook_report__initial_balance
|
||||
msgid ""
|
||||
"If you selected date, this field allow you to add a row to display the "
|
||||
"amount of debit/credit/balance that precedes the filter you've set."
|
||||
msgstr ""
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model:ir.model.fields,field_description:om_account_daily_reports.field_account_bankbook_report__initial_balance
|
||||
#: model:ir.model.fields,field_description:om_account_daily_reports.field_account_cashbook_report__initial_balance
|
||||
msgid "Include Initial Balances"
|
||||
msgstr ""
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_bankbook
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_cashbook
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_daybook
|
||||
msgid "JRNL"
|
||||
msgstr ""
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model:ir.model.fields.selection,name:om_account_daily_reports.selection__account_bankbook_report__sortby__sort_journal_partner
|
||||
#: model:ir.model.fields.selection,name:om_account_daily_reports.selection__account_cashbook_report__sortby__sort_journal_partner
|
||||
msgid "Journal & Partner"
|
||||
msgstr ""
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_bankbook
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_cashbook
|
||||
msgid "Journal and Partner"
|
||||
msgstr ""
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model:ir.model.fields,field_description:om_account_daily_reports.field_account_bankbook_report__journal_ids
|
||||
#: model:ir.model.fields,field_description:om_account_daily_reports.field_account_cashbook_report__journal_ids
|
||||
#: model:ir.model.fields,field_description:om_account_daily_reports.field_account_daybook_report__journal_ids
|
||||
msgid "Journals"
|
||||
msgstr ""
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model:ir.model.fields,field_description:om_account_daily_reports.field_account_bankbook_report____last_update
|
||||
#: model:ir.model.fields,field_description:om_account_daily_reports.field_account_cashbook_report____last_update
|
||||
#: model:ir.model.fields,field_description:om_account_daily_reports.field_account_daybook_report____last_update
|
||||
msgid "Last Modified on"
|
||||
msgstr ""
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model:ir.model.fields,field_description:om_account_daily_reports.field_account_bankbook_report__write_uid
|
||||
#: model:ir.model.fields,field_description:om_account_daily_reports.field_account_cashbook_report__write_uid
|
||||
#: model:ir.model.fields,field_description:om_account_daily_reports.field_account_daybook_report__write_uid
|
||||
msgid "Last Updated by"
|
||||
msgstr ""
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model:ir.model.fields,field_description:om_account_daily_reports.field_account_bankbook_report__write_date
|
||||
#: model:ir.model.fields,field_description:om_account_daily_reports.field_account_cashbook_report__write_date
|
||||
#: model:ir.model.fields,field_description:om_account_daily_reports.field_account_daybook_report__write_date
|
||||
msgid "Last Updated on"
|
||||
msgstr ""
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_bankbook
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_cashbook
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_daybook
|
||||
msgid "Move"
|
||||
msgstr ""
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_bankbook
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_cashbook
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_daybook
|
||||
msgid "Partner"
|
||||
msgstr ""
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model:ir.model.fields.selection,name:om_account_daily_reports.selection__account_bankbook_report__target_move__posted
|
||||
#: model:ir.model.fields.selection,name:om_account_daily_reports.selection__account_cashbook_report__target_move__posted
|
||||
#: model:ir.model.fields.selection,name:om_account_daily_reports.selection__account_daybook_report__target_move__posted
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_bankbook
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_cashbook
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_daybook
|
||||
msgid "Posted Entries"
|
||||
msgstr ""
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.account_report_bankbook_view
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.account_report_cashbook_view
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.account_report_daybook_view
|
||||
msgid "Print"
|
||||
msgstr ""
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_bankbook
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_cashbook
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.report_daybook
|
||||
msgid "Ref"
|
||||
msgstr ""
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.account_report_bankbook_view
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.account_report_cashbook_view
|
||||
#: model_terms:ir.ui.view,arch_db:om_account_daily_reports.account_report_daybook_view
|
||||
msgid "Report Options"
|
||||
msgstr ""
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model:ir.model.fields,field_description:om_account_daily_reports.field_account_bankbook_report__sortby
|
||||
#: model:ir.model.fields,field_description:om_account_daily_reports.field_account_cashbook_report__sortby
|
||||
msgid "Sort by"
|
||||
msgstr ""
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model:ir.model.fields,field_description:om_account_daily_reports.field_account_bankbook_report__date_from
|
||||
#: model:ir.model.fields,field_description:om_account_daily_reports.field_account_cashbook_report__date_from
|
||||
#: model:ir.model.fields,field_description:om_account_daily_reports.field_account_daybook_report__date_from
|
||||
msgid "Start Date"
|
||||
msgstr ""
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model:ir.model.fields,field_description:om_account_daily_reports.field_account_bankbook_report__target_move
|
||||
#: model:ir.model.fields,field_description:om_account_daily_reports.field_account_cashbook_report__target_move
|
||||
#: model:ir.model.fields,field_description:om_account_daily_reports.field_account_daybook_report__target_move
|
||||
msgid "Target Moves"
|
||||
msgstr ""
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model:ir.model.fields.selection,name:om_account_daily_reports.selection__account_bankbook_report__display_account__not_zero
|
||||
#: model:ir.model.fields.selection,name:om_account_daily_reports.selection__account_cashbook_report__display_account__not_zero
|
||||
msgid "With balance is not equal to 0"
|
||||
msgstr ""
|
||||
|
||||
#. module: om_account_daily_reports
|
||||
#: model:ir.model.fields.selection,name:om_account_daily_reports.selection__account_bankbook_report__display_account__movement
|
||||
#: model:ir.model.fields.selection,name:om_account_daily_reports.selection__account_cashbook_report__display_account__movement
|
||||
msgid "With movements"
|
||||
msgstr ""
|
||||
|
|
@ -0,0 +1,5 @@
|
|||
# -*- coding: utf-8 -*-
|
||||
|
||||
from . import report_daybook
|
||||
from . import report_cashbook
|
||||
from . import report_bankbook
|
||||
|
|
@ -0,0 +1,161 @@
|
|||
# -*- coding: utf-8 -*-
|
||||
|
||||
import time
|
||||
from odoo import api, models, _
|
||||
from odoo.exceptions import UserError
|
||||
|
||||
|
||||
class ReportBankBook(models.AbstractModel):
|
||||
_name = 'report.om_account_daily_reports.report_bankbook'
|
||||
_description = 'Bank Book'
|
||||
|
||||
def _get_account_move_entry(self, accounts, init_balance, sortby, display_account):
|
||||
"""
|
||||
:param:
|
||||
accounts: the recordset of accounts
|
||||
init_balance: boolean value of initial_balance
|
||||
sortby: sorting by date or partner and journal
|
||||
display_account: type of account(receivable, payable and both)
|
||||
|
||||
Returns a dictionary of accounts with following key and value {
|
||||
'code': account code,
|
||||
'name': account name,
|
||||
'debit': sum of total debit amount,
|
||||
'credit': sum of total credit amount,
|
||||
'balance': total balance,
|
||||
'amount_currency': sum of amount_currency,
|
||||
'move_lines': list of move line
|
||||
}
|
||||
"""
|
||||
cr = self.env.cr
|
||||
MoveLine = self.env['account.move.line']
|
||||
move_lines = {x: [] for x in accounts.ids}
|
||||
|
||||
# Prepare initial sql query and Get the initial move lines
|
||||
if init_balance:
|
||||
init_tables, init_where_clause, init_where_params = MoveLine.with_context(date_from=self.env.context.get('date_from'), date_to=False,initial_bal=True)._query_get()
|
||||
init_wheres = [""]
|
||||
if init_where_clause.strip():
|
||||
init_wheres.append(init_where_clause.strip())
|
||||
init_filters = " AND ".join(init_wheres)
|
||||
filters = init_filters.replace('account_move_line__move_id', 'm').replace('account_move_line', 'l')
|
||||
sql = ("""
|
||||
SELECT 0 AS lid,
|
||||
l.account_id AS account_id, '' AS ldate, '' AS lcode,
|
||||
0.0 AS amount_currency,'' AS lref,'Initial Balance' AS lname,
|
||||
COALESCE(SUM(l.credit),0.0) AS credit,COALESCE(SUM(l.debit),0.0) AS debit,COALESCE(SUM(l.debit),0) - COALESCE(SUM(l.credit),0) as balance,
|
||||
'' AS lpartner_id,'' AS move_name, '' AS currency_code,NULL AS currency_id,'' AS partner_name,
|
||||
'' AS mmove_id, '' AS invoice_id, '' AS invoice_type,'' AS invoice_number
|
||||
FROM account_move_line l
|
||||
LEFT JOIN account_move m ON (l.move_id = m.id)
|
||||
LEFT JOIN res_currency c ON (l.currency_id = c.id)
|
||||
LEFT JOIN res_partner p ON (l.partner_id = p.id)
|
||||
JOIN account_journal j ON (l.journal_id = j.id)
|
||||
JOIN account_account acc ON (l.account_id = acc.id)
|
||||
WHERE l.account_id IN %s""" + filters + 'GROUP BY l.account_id')
|
||||
params = (tuple(accounts.ids),) + tuple(init_where_params)
|
||||
cr.execute(sql, params)
|
||||
for row in cr.dictfetchall():
|
||||
move_lines[row.pop('account_id')].append(row)
|
||||
|
||||
sql_sort = 'l.date, l.move_id'
|
||||
if sortby == 'sort_journal_partner':
|
||||
sql_sort = 'j.code, p.name, l.move_id'
|
||||
|
||||
# Prepare sql query base on selected parameters from wizard
|
||||
tables, where_clause, where_params = MoveLine._query_get()
|
||||
wheres = [""]
|
||||
if where_clause.strip():
|
||||
wheres.append(where_clause.strip())
|
||||
filters = " AND ".join(wheres)
|
||||
filters = filters.replace('account_move_line__move_id', 'm').replace('account_move_line', 'l')
|
||||
if not accounts:
|
||||
journals = self.env['account.journal'].search([('type', '=', 'bank')])
|
||||
accounts = []
|
||||
for journal in journals:
|
||||
for acc_out in journal.outbound_payment_method_line_ids:
|
||||
if acc_out.payment_account_id:
|
||||
accounts.append(acc_out.payment_account_id.id)
|
||||
for acc_in in journal.inbound_payment_method_line_ids:
|
||||
if acc_in.payment_account_id:
|
||||
accounts.append(acc_in.payment_account_id.id)
|
||||
accounts = self.env['account.account'].search([('id', 'in', accounts)])
|
||||
|
||||
sql = ('''SELECT l.id AS lid, l.account_id AS account_id, l.date AS ldate, j.code AS lcode, l.currency_id, l.amount_currency, l.ref AS lref, l.name AS lname, COALESCE(l.debit,0) AS debit,
|
||||
COALESCE(l.credit,0) AS credit, COALESCE(SUM(l.debit),0) - COALESCE(SUM(l.credit), 0) AS balance,\
|
||||
m.name AS move_name, c.symbol AS currency_code, p.name AS partner_name\
|
||||
FROM account_move_line l\
|
||||
JOIN account_move m ON (l.move_id=m.id)\
|
||||
LEFT JOIN res_currency c ON (l.currency_id=c.id)\
|
||||
LEFT JOIN res_partner p ON (l.partner_id=p.id)\
|
||||
JOIN account_journal j ON (l.journal_id=j.id)\
|
||||
JOIN account_account acc ON (l.account_id = acc.id) \
|
||||
WHERE l.account_id IN %s ''' + filters + ''' GROUP BY l.id, l.account_id, l.date, j.code, l.currency_id, l.amount_currency, l.ref, l.name, m.name, c.symbol, p.name ORDER BY ''' + sql_sort)
|
||||
params = (tuple(accounts.ids),) + tuple(where_params)
|
||||
cr.execute(sql, params)
|
||||
|
||||
for row in cr.dictfetchall():
|
||||
balance = 0
|
||||
for line in move_lines.get(row['account_id']):
|
||||
balance += line['debit'] - line['credit']
|
||||
row['balance'] += balance
|
||||
move_lines[row.pop('account_id')].append(row)
|
||||
|
||||
# Calculate the debit, credit and balance for Accounts
|
||||
account_res = []
|
||||
for account in accounts:
|
||||
currency = account.currency_id and account.currency_id or account.company_id.currency_id
|
||||
res = dict((fn, 0.0) for fn in ['credit', 'debit', 'balance'])
|
||||
res['code'] = account.code
|
||||
res['name'] = account.name
|
||||
res['move_lines'] = move_lines[account.id]
|
||||
for line in res.get('move_lines'):
|
||||
res['debit'] += line['debit']
|
||||
res['credit'] += line['credit']
|
||||
res['balance'] = line['balance']
|
||||
if display_account == 'all':
|
||||
account_res.append(res)
|
||||
if display_account == 'movement' and res.get('move_lines'):
|
||||
account_res.append(res)
|
||||
if display_account == 'not_zero' and not currency.is_zero(res['balance']):
|
||||
account_res.append(res)
|
||||
return account_res
|
||||
|
||||
@api.model
|
||||
def _get_report_values(self, docids, data=None):
|
||||
if not data.get('form') or not self.env.context.get('active_model'):
|
||||
raise UserError(_("Form content is missing, this report cannot be printed."))
|
||||
model = self.env.context.get('active_model')
|
||||
docs = self.env[model].browse(self.env.context.get('active_ids', []))
|
||||
init_balance = data['form'].get('initial_balance', True)
|
||||
display_account = data['form'].get('display_account')
|
||||
|
||||
sortby = data['form'].get('sortby', 'sort_date')
|
||||
codes = []
|
||||
|
||||
if data['form'].get('journal_ids', False):
|
||||
codes = [journal.code for journal in
|
||||
self.env['account.journal'].search([('id', 'in', data['form']['journal_ids'])])]
|
||||
account_ids = data['form']['account_ids']
|
||||
accounts = self.env['account.account'].search([('id', 'in', account_ids)])
|
||||
if not accounts:
|
||||
journals = self.env['account.journal'].search([('type', '=', 'bank')])
|
||||
accounts = []
|
||||
for journal in journals:
|
||||
for acc_out in journal.outbound_payment_method_line_ids:
|
||||
if acc_out.payment_account_id:
|
||||
accounts.append(acc_out.payment_account_id.id)
|
||||
for acc_in in journal.inbound_payment_method_line_ids:
|
||||
if acc_in.payment_account_id:
|
||||
accounts.append(acc_in.payment_account_id.id)
|
||||
accounts = self.env['account.account'].search([('id', 'in', accounts)])
|
||||
record = self.with_context(data['form'].get('comparison_context', {}))._get_account_move_entry(accounts, init_balance, sortby, display_account)
|
||||
return {
|
||||
'doc_ids': docids,
|
||||
'doc_model': model,
|
||||
'data': data['form'],
|
||||
'docs': docs,
|
||||
'time': time,
|
||||
'Accounts': record,
|
||||
'print_journal': codes,
|
||||
}
|
||||
|
|
@ -0,0 +1,127 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<odoo>
|
||||
|
||||
<template id="report_bankbook">
|
||||
<t t-call="web.html_container">
|
||||
<t t-set="data_report_margin_top" t-value="12"/>
|
||||
<t t-set="data_report_header_spacing" t-value="9"/>
|
||||
<t t-set="data_report_dpi" t-value="110"/>
|
||||
<t t-call="web.internal_layout">
|
||||
<div class="page">
|
||||
<h2>Account Bank Book</h2>
|
||||
</div>
|
||||
<div class="row mt32">
|
||||
<div class="col-4">
|
||||
<strong>Journals:</strong>
|
||||
<p t-esc="', '.join([ lt or '' for lt in print_journal ])"/>
|
||||
</div>
|
||||
|
||||
<div class="col-2">
|
||||
<strong>Start Date:</strong>
|
||||
<p t-esc="data['date_from']"/>
|
||||
</div>
|
||||
<div class="col-2">
|
||||
|
||||
<strong>End Date:</strong>
|
||||
<p t-esc="data['date_to']"/>
|
||||
</div>
|
||||
<div class="col-2">
|
||||
<div style="width:70%;">
|
||||
<strong>Sorted By:</strong>
|
||||
<p t-if="data['sortby'] == 'sort_date'">Date</p>
|
||||
<p t-if="data['sortby'] == 'sort_journal_partner'">Journal and Partner</p>
|
||||
</div>
|
||||
|
||||
|
||||
</div>
|
||||
<div class="col-2">
|
||||
<strong>Target Moves:</strong>
|
||||
<p t-if="data['target_move'] == 'all'">All Entries</p>
|
||||
<p t-if="data['target_move'] == 'posted'">Posted Entries</p>
|
||||
</div>
|
||||
</div>
|
||||
<br/>
|
||||
|
||||
<table class="table table-sm table-reports">
|
||||
<thead>
|
||||
<tr class="text-center">
|
||||
<th>Date</th>
|
||||
<th>JRNL</th>
|
||||
<th>Partner</th>
|
||||
<th>Ref</th>
|
||||
<th>Move</th>
|
||||
<th>Entry Label</th>
|
||||
<th>Debit</th>
|
||||
<th>Credit</th>
|
||||
<th>Balance</th>
|
||||
<th groups="base.group_multi_currency">Currency</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<t t-foreach="Accounts" t-as="account">
|
||||
<tr style="font-weight: bold;">
|
||||
<td colspan="6">
|
||||
<span style="color: white;" t-esc="'..'"/>
|
||||
<span t-esc="account['code']"/>
|
||||
<span t-esc="account['name']"/>
|
||||
</td>
|
||||
<td class="text-end">
|
||||
<span t-esc="account['debit']"
|
||||
t-options="{'widget': 'monetary', 'display_currency': env.company.currency_id}"/>
|
||||
</td>
|
||||
<td class="text-end">
|
||||
<span t-esc="account['credit']"
|
||||
t-options="{'widget': 'monetary', 'display_currency': env.company.currency_id}"/>
|
||||
</td>
|
||||
<td class="text-end">
|
||||
<span t-esc="account['balance']"
|
||||
t-options="{'widget': 'monetary', 'display_currency': env.company.currency_id}"/>
|
||||
</td>
|
||||
<td groups="base.group_multi_currency"/>
|
||||
</tr>
|
||||
<tr t-foreach="account['move_lines']" t-as="line">
|
||||
<td>
|
||||
<span t-esc="line['ldate']"/>
|
||||
</td>
|
||||
<td>
|
||||
<span t-esc="line['lcode']"/>
|
||||
</td>
|
||||
<td>
|
||||
<span t-esc="line['partner_name']"/>
|
||||
</td>
|
||||
<td>
|
||||
<span t-if="line['lref']" t-esc="line['lref']"/>
|
||||
</td>
|
||||
<td>
|
||||
<span t-esc="line['move_name']"/>
|
||||
</td>
|
||||
<td>
|
||||
<span t-esc="line['lname']"/>
|
||||
</td>
|
||||
<td class="text-end">
|
||||
<span t-esc="line['debit']"
|
||||
t-options="{'widget': 'monetary', 'display_currency': env.company.currency_id}"/>
|
||||
</td>
|
||||
<td class="text-end">
|
||||
<span t-esc="line['credit']"
|
||||
t-options="{'widget': 'monetary', 'display_currency': env.company.currency_id}"/>
|
||||
</td>
|
||||
<td class="text-end">
|
||||
<span t-esc="line['balance']"
|
||||
t-options="{'widget': 'monetary', 'display_currency': env.company.currency_id}"/>
|
||||
</td>
|
||||
<td t-if="line['amount_currency']" class="text-end"
|
||||
groups="base.group_multi_currency">
|
||||
<span t-esc="line['amount_currency'] if line['amount_currency'] > 0.00 else ''"/>
|
||||
<span t-esc="line['currency_code'] if line['amount_currency'] > 0.00 else ''"/>
|
||||
</td>
|
||||
</tr>
|
||||
</t>
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
</t>
|
||||
</t>
|
||||
</template>
|
||||
|
||||
</odoo>
|
||||
|
|
@ -0,0 +1,160 @@
|
|||
# -*- coding: utf-8 -*-
|
||||
|
||||
import time
|
||||
from odoo import api, models, _
|
||||
from odoo.exceptions import UserError
|
||||
|
||||
|
||||
class ReportCashBook(models.AbstractModel):
|
||||
_name = 'report.om_account_daily_reports.report_cashbook'
|
||||
_description = 'Cash Book'
|
||||
|
||||
def _get_account_move_entry(self, accounts, init_balance, sortby, display_account):
|
||||
"""
|
||||
:param:
|
||||
accounts: the recordset of accounts
|
||||
init_balance: boolean value of initial_balance
|
||||
sortby: sorting by date or partner and journal
|
||||
display_account: type of account(receivable, payable and both)
|
||||
|
||||
Returns a dictionary of accounts with following key and value {
|
||||
'code': account code,
|
||||
'name': account name,
|
||||
'debit': sum of total debit amount,
|
||||
'credit': sum of total credit amount,
|
||||
'balance': total balance,
|
||||
'amount_currency': sum of amount_currency,
|
||||
'move_lines': list of move line
|
||||
}
|
||||
"""
|
||||
cr = self.env.cr
|
||||
MoveLine = self.env['account.move.line']
|
||||
move_lines = {x: [] for x in accounts.ids}
|
||||
|
||||
# Prepare initial sql query and Get the initial move lines
|
||||
if init_balance:
|
||||
init_tables, init_where_clause, init_where_params = MoveLine.with_context(date_from=self.env.context.get('date_from'), date_to=False,initial_bal=True)._query_get()
|
||||
init_wheres = [""]
|
||||
if init_where_clause.strip():
|
||||
init_wheres.append(init_where_clause.strip())
|
||||
init_filters = " AND ".join(init_wheres)
|
||||
filters = init_filters.replace('account_move_line__move_id', 'm').replace('account_move_line', 'l')
|
||||
sql = ("""
|
||||
SELECT 0 AS lid,
|
||||
l.account_id AS account_id, '' AS ldate, '' AS lcode,
|
||||
0.0 AS amount_currency,'' AS lref,'Initial Balance' AS lname,
|
||||
COALESCE(SUM(l.credit),0.0) AS credit,COALESCE(SUM(l.debit),0.0) AS debit,COALESCE(SUM(l.debit),0) - COALESCE(SUM(l.credit),0) as balance,
|
||||
'' AS lpartner_id,'' AS move_name, '' AS currency_code,NULL AS currency_id,'' AS partner_name,
|
||||
'' AS mmove_id, '' AS invoice_id, '' AS invoice_type,'' AS invoice_number
|
||||
FROM account_move_line l
|
||||
LEFT JOIN account_move m ON (l.move_id = m.id)
|
||||
LEFT JOIN res_currency c ON (l.currency_id = c.id)
|
||||
LEFT JOIN res_partner p ON (l.partner_id = p.id)
|
||||
JOIN account_journal j ON (l.journal_id = j.id)
|
||||
JOIN account_account acc ON (l.account_id = acc.id)
|
||||
WHERE l.account_id IN %s""" + filters + 'GROUP BY l.account_id')
|
||||
params = (tuple(accounts.ids),) + tuple(init_where_params)
|
||||
cr.execute(sql, params)
|
||||
for row in cr.dictfetchall():
|
||||
move_lines[row.pop('account_id')].append(row)
|
||||
|
||||
sql_sort = 'l.date, l.move_id'
|
||||
if sortby == 'sort_journal_partner':
|
||||
sql_sort = 'j.code, p.name, l.move_id'
|
||||
|
||||
# Prepare sql query base on selected parameters from wizard
|
||||
tables, where_clause, where_params = MoveLine._query_get()
|
||||
wheres = [""]
|
||||
if where_clause.strip():
|
||||
wheres.append(where_clause.strip())
|
||||
filters = " AND ".join(wheres)
|
||||
filters = filters.replace('account_move_line__move_id', 'm').replace('account_move_line', 'l')
|
||||
if not accounts:
|
||||
journals = self.env['account.journal'].search([('type', '=', 'cash')])
|
||||
accounts = []
|
||||
for journal in journals:
|
||||
for acc_out in journal.outbound_payment_method_line_ids:
|
||||
if acc_out.payment_account_id:
|
||||
accounts.append(acc_out.payment_account_id.id)
|
||||
for acc_in in journal.inbound_payment_method_line_ids:
|
||||
if acc_in.payment_account_id:
|
||||
accounts.append(acc_in.payment_account_id.id)
|
||||
accounts = self.env['account.account'].search([('id', 'in', accounts)])
|
||||
|
||||
sql = ('''SELECT l.id AS lid, l.account_id AS account_id, l.date AS ldate, j.code AS lcode, l.currency_id, l.amount_currency, l.ref AS lref, l.name AS lname, COALESCE(l.debit,0) AS debit, COALESCE(l.credit,0) AS credit, COALESCE(SUM(l.debit),0) - COALESCE(SUM(l.credit), 0) AS balance,\
|
||||
m.name AS move_name, c.symbol AS currency_code, p.name AS partner_name\
|
||||
FROM account_move_line l\
|
||||
JOIN account_move m ON (l.move_id=m.id)\
|
||||
LEFT JOIN res_currency c ON (l.currency_id=c.id)\
|
||||
LEFT JOIN res_partner p ON (l.partner_id=p.id)\
|
||||
JOIN account_journal j ON (l.journal_id=j.id)\
|
||||
JOIN account_account acc ON (l.account_id = acc.id) \
|
||||
WHERE l.account_id IN %s ''' + filters + ''' GROUP BY l.id, l.account_id, l.date, j.code, l.currency_id, l.amount_currency, l.ref, l.name, m.name, c.symbol, p.name ORDER BY ''' + sql_sort)
|
||||
params = (tuple(accounts.ids),) + tuple(where_params)
|
||||
cr.execute(sql, params)
|
||||
|
||||
for row in cr.dictfetchall():
|
||||
balance = 0
|
||||
for line in move_lines.get(row['account_id']):
|
||||
balance += line['debit'] - line['credit']
|
||||
row['balance'] += balance
|
||||
move_lines[row.pop('account_id')].append(row)
|
||||
|
||||
# Calculate the debit, credit and balance for Accounts
|
||||
account_res = []
|
||||
for account in accounts:
|
||||
currency = account.currency_id and account.currency_id or account.company_id.currency_id
|
||||
res = dict((fn, 0.0) for fn in ['credit', 'debit', 'balance'])
|
||||
res['code'] = account.code
|
||||
res['name'] = account.name
|
||||
res['move_lines'] = move_lines[account.id]
|
||||
for line in res.get('move_lines'):
|
||||
res['debit'] += line['debit']
|
||||
res['credit'] += line['credit']
|
||||
res['balance'] = line['balance']
|
||||
if display_account == 'all':
|
||||
account_res.append(res)
|
||||
if display_account == 'movement' and res.get('move_lines'):
|
||||
account_res.append(res)
|
||||
if display_account == 'not_zero' and not currency.is_zero(res['balance']):
|
||||
account_res.append(res)
|
||||
return account_res
|
||||
|
||||
@api.model
|
||||
def _get_report_values(self, docids, data=None):
|
||||
if not data.get('form') or not self.env.context.get('active_model'):
|
||||
raise UserError(_("Form content is missing, this report cannot be printed."))
|
||||
model = self.env.context.get('active_model')
|
||||
docs = self.env[model].browse(self.env.context.get('active_ids', []))
|
||||
init_balance = data['form'].get('initial_balance', True)
|
||||
display_account = data['form'].get('display_account')
|
||||
|
||||
sortby = data['form'].get('sortby', 'sort_date')
|
||||
codes = []
|
||||
|
||||
if data['form'].get('journal_ids', False):
|
||||
codes = [journal.code for journal in
|
||||
self.env['account.journal'].search([('id', 'in', data['form']['journal_ids'])])]
|
||||
account_ids = data['form']['account_ids']
|
||||
accounts = self.env['account.account'].search([('id', 'in', account_ids)])
|
||||
if not accounts:
|
||||
journals = self.env['account.journal'].search([('type', '=', 'cash')])
|
||||
accounts = []
|
||||
for journal in journals:
|
||||
for acc_out in journal.outbound_payment_method_line_ids:
|
||||
if acc_out.payment_account_id:
|
||||
accounts.append(acc_out.payment_account_id.id)
|
||||
for acc_in in journal.inbound_payment_method_line_ids:
|
||||
if acc_in.payment_account_id:
|
||||
accounts.append(acc_in.payment_account_id.id)
|
||||
accounts = self.env['account.account'].search([('id', 'in', accounts)])
|
||||
record = self.with_context(data['form'].get('comparison_context', {}))._get_account_move_entry(accounts, init_balance, sortby, display_account)
|
||||
return {
|
||||
'doc_ids': docids,
|
||||
'doc_model': model,
|
||||
'data': data['form'],
|
||||
'docs': docs,
|
||||
'time': time,
|
||||
'Accounts': record,
|
||||
'print_journal': codes,
|
||||
}
|
||||
|
|
@ -0,0 +1,128 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<odoo>
|
||||
|
||||
<template id="report_cashbook">
|
||||
<t t-call="web.html_container">
|
||||
<t t-set="data_report_margin_top" t-value="12"/>
|
||||
<t t-set="data_report_header_spacing" t-value="9"/>
|
||||
<t t-set="data_report_dpi" t-value="110"/>
|
||||
<t t-call="web.internal_layout">
|
||||
<div class="page">
|
||||
<h2>Account Cash Book</h2>
|
||||
</div>
|
||||
<div class="row mt32">
|
||||
<div class="col-4">
|
||||
<strong>Journals:</strong>
|
||||
<p t-esc="', '.join([ lt or '' for lt in print_journal ])"/>
|
||||
</div>
|
||||
|
||||
<div class="col-2">
|
||||
<strong>Start Date:</strong>
|
||||
<p t-esc="data['date_from']"/>
|
||||
</div>
|
||||
<div class="col-2">
|
||||
|
||||
<strong>End Date:</strong>
|
||||
<p t-esc="data['date_to']"/>
|
||||
</div>
|
||||
<div class="col-2">
|
||||
<div style="width:70%;">
|
||||
<strong>Sorted By:</strong>
|
||||
<p t-if="data['sortby'] == 'sort_date'">Date</p>
|
||||
<p t-if="data['sortby'] == 'sort_journal_partner'">Journal and Partner</p>
|
||||
</div>
|
||||
|
||||
|
||||
</div>
|
||||
<div class="col-2">
|
||||
<strong>Target Moves:</strong>
|
||||
<p t-if="data['target_move'] == 'all'">All Entries</p>
|
||||
<p t-if="data['target_move'] == 'posted'">Posted Entries</p>
|
||||
</div>
|
||||
</div>
|
||||
<br/>
|
||||
|
||||
<table class="table table-sm table-reports">
|
||||
<thead>
|
||||
<tr class="text-center">
|
||||
<th>Date</th>
|
||||
<th>JRNL</th>
|
||||
<th>Partner</th>
|
||||
<th>Ref</th>
|
||||
<th>Move</th>
|
||||
<th>Entry Label</th>
|
||||
<th>Debit</th>
|
||||
<th>Credit</th>
|
||||
<th>Balance</th>
|
||||
<th groups="base.group_multi_currency">Currency</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<t t-foreach="Accounts" t-as="account">
|
||||
<tr style="font-weight: bold;">
|
||||
<td colspan="6">
|
||||
<span style="color: white;" t-esc="'..'"/>
|
||||
<span t-esc="account['code']"/>
|
||||
<span t-esc="account['name']"/>
|
||||
</td>
|
||||
<td class="text-end">
|
||||
<span t-esc="account['debit']"
|
||||
t-options="{'widget': 'monetary', 'display_currency': env.company.currency_id}"/>
|
||||
</td>
|
||||
<td class="text-end">
|
||||
<span t-esc="account['credit']"
|
||||
t-options="{'widget': 'monetary', 'display_currency': env.company.currency_id}"/>
|
||||
</td>
|
||||
<td class="text-end">
|
||||
<span t-esc="account['balance']"
|
||||
t-options="{'widget': 'monetary', 'display_currency': env.company.currency_id}"/>
|
||||
</td>
|
||||
<td groups="base.group_multi_currency"/>
|
||||
</tr>
|
||||
<tr t-foreach="account['move_lines']" t-as="line">
|
||||
<td>
|
||||
<span t-esc="line['ldate']"/>
|
||||
</td>
|
||||
<td>
|
||||
<span t-esc="line['lcode']"/>
|
||||
</td>
|
||||
<td>
|
||||
<span t-esc="line['partner_name']"/>
|
||||
</td>
|
||||
<td>
|
||||
<span t-if="line['lref']" t-esc="line['lref']"/>
|
||||
</td>
|
||||
<td>
|
||||
<span t-esc="line['move_name']"/>
|
||||
</td>
|
||||
<td>
|
||||
<span t-esc="line['lname']"/>
|
||||
</td>
|
||||
<td class="text-end">
|
||||
<span t-esc="line['debit']"
|
||||
t-options="{'widget': 'monetary', 'display_currency': env.company.currency_id}"/>
|
||||
</td>
|
||||
<td class="text-end">
|
||||
<span t-esc="line['credit']"
|
||||
t-options="{'widget': 'monetary', 'display_currency': env.company.currency_id}"/>
|
||||
</td>
|
||||
<td class="text-end">
|
||||
<span t-esc="line['balance']"
|
||||
t-options="{'widget': 'monetary', 'display_currency': env.company.currency_id}"/>
|
||||
</td>
|
||||
<td t-if="line['amount_currency']" class="text-end"
|
||||
groups="base.group_multi_currency">
|
||||
<span t-esc="line['amount_currency'] if line['amount_currency'] > 0.00 else ''"/>
|
||||
<span t-esc="line['currency_code'] if line['amount_currency'] > 0.00 else ''"/>
|
||||
</td>
|
||||
</tr>
|
||||
</t>
|
||||
</tbody>
|
||||
|
||||
</table>
|
||||
|
||||
</t>
|
||||
</t>
|
||||
</template>
|
||||
|
||||
</odoo>
|
||||
|
|
@ -0,0 +1,116 @@
|
|||
# -*- coding: utf-8 -*-
|
||||
|
||||
import time
|
||||
from odoo import api, models, _
|
||||
from odoo.exceptions import UserError
|
||||
from datetime import timedelta, datetime
|
||||
|
||||
|
||||
class ReportDayBook(models.AbstractModel):
|
||||
_name = 'report.om_account_daily_reports.report_daybook'
|
||||
_description = 'Day Book'
|
||||
|
||||
def _get_account_move_entry(self, accounts, form_data, date):
|
||||
cr = self.env.cr
|
||||
MoveLine = self.env['account.move.line']
|
||||
init_wheres = [""]
|
||||
|
||||
init_tables, init_where_clause, init_where_params =MoveLine._query_get()
|
||||
if init_where_clause.strip():
|
||||
init_wheres.append(init_where_clause.strip())
|
||||
if form_data['target_move'] == 'posted':
|
||||
target_move = "AND m.state = 'posted'"
|
||||
else:
|
||||
target_move = ''
|
||||
|
||||
sql = ("""
|
||||
SELECT 0 AS lid,
|
||||
l.account_id AS account_id, l.date AS ldate, j.code AS lcode,
|
||||
l.amount_currency AS amount_currency,l.ref AS lref,l.name AS lname,
|
||||
COALESCE(SUM(l.credit),0.0) AS credit,COALESCE(l.debit,0) AS debit,COALESCE(SUM(l.debit),0) - COALESCE(SUM(l.credit),0) as balance,
|
||||
m.name AS move_name,
|
||||
c.symbol AS currency_code,
|
||||
p.name AS lpartner_id,
|
||||
m.id AS mmove_id
|
||||
FROM
|
||||
account_move_line l
|
||||
LEFT JOIN account_move m ON (l.move_id = m.id)
|
||||
LEFT JOIN res_currency c ON (l.currency_id = c.id)
|
||||
LEFT JOIN res_partner p ON (l.partner_id = p.id)
|
||||
JOIN account_journal j ON (l.journal_id = j.id)
|
||||
JOIN account_account acc ON (l.account_id = acc.id)
|
||||
WHERE
|
||||
l.account_id IN %s
|
||||
AND l.journal_id IN %s """ + target_move + """
|
||||
AND l.date = %s
|
||||
GROUP BY
|
||||
l.id,
|
||||
l.account_id,
|
||||
l.date,
|
||||
m.name,
|
||||
m.id,
|
||||
p.name,
|
||||
c.symbol,
|
||||
j.code,
|
||||
l.ref
|
||||
ORDER BY
|
||||
l.date DESC
|
||||
""")
|
||||
|
||||
where_params = (tuple(accounts.ids), tuple(form_data['journal_ids']), date)
|
||||
cr.execute(sql, where_params)
|
||||
data = cr.dictfetchall()
|
||||
res = {}
|
||||
debit = credit = balance = 0.00
|
||||
for line in data:
|
||||
debit += line['debit']
|
||||
credit += line['credit']
|
||||
balance += line['balance']
|
||||
res['debit'] = debit
|
||||
res['credit'] = credit
|
||||
res['balance'] = balance
|
||||
res['lines'] = data
|
||||
return res
|
||||
|
||||
@api.model
|
||||
def _get_report_values(self, docids, data=None):
|
||||
if not data.get('form') or not self.env.context.get('active_model'):
|
||||
raise UserError(_("Form content is missing, this report cannot be printed."))
|
||||
model = self.env.context.get('active_model')
|
||||
docs = self.env[model].browse(self.env.context.get('active_ids', []))
|
||||
form_data = data['form']
|
||||
|
||||
date_from = datetime.strptime(form_data['date_from'],
|
||||
'%Y-%m-%d').date()
|
||||
date_to = datetime.strptime(form_data['date_to'], '%Y-%m-%d').date()
|
||||
codes = []
|
||||
|
||||
if data['form'].get('journal_ids', False):
|
||||
codes = [journal.code for journal in
|
||||
self.env['account.journal'].search([('id', 'in', data['form']['journal_ids'])])]
|
||||
accounts = self.env['account.account'].search([])
|
||||
dates = []
|
||||
record = []
|
||||
days_total = date_to - date_from
|
||||
for day in range(days_total.days + 1):
|
||||
dates.append(date_from + timedelta(days=day))
|
||||
for date in dates:
|
||||
date_data = str(date)
|
||||
accounts_res = self.with_context(data['form'].get('comparison_context', {}))._get_account_move_entry(accounts, form_data, date_data)
|
||||
if accounts_res['lines']:
|
||||
record.append({
|
||||
'date': date,
|
||||
'debit': accounts_res['debit'],
|
||||
'credit': accounts_res['credit'],
|
||||
'balance': accounts_res['balance'],
|
||||
'move_lines': accounts_res['lines']
|
||||
})
|
||||
return {
|
||||
'doc_ids': docids,
|
||||
'doc_model': model,
|
||||
'data': data['form'],
|
||||
'docs': docs,
|
||||
'time': time,
|
||||
'Accounts': record,
|
||||
'print_journal': codes,
|
||||
}
|
||||
|
|
@ -0,0 +1,113 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<odoo>
|
||||
|
||||
<template id="report_daybook">
|
||||
<t t-call="web.html_container">
|
||||
<t t-set="data_report_margin_top" t-value="12"/>
|
||||
<t t-set="data_report_header_spacing" t-value="9"/>
|
||||
<t t-set="data_report_dpi" t-value="110"/>
|
||||
<t t-call="web.internal_layout">
|
||||
<div class="page">
|
||||
<h2>Account Day Book</h2>
|
||||
|
||||
<div class="row mt32">
|
||||
<div class="col-4">
|
||||
<strong>Journals:</strong>
|
||||
<p t-esc="', '.join([ lt or '' for lt in print_journal ])"/>
|
||||
</div>
|
||||
|
||||
<div class="col-3">
|
||||
<strong>Start Date:</strong>
|
||||
<p t-esc="data['date_from']"/>
|
||||
</div>
|
||||
<div class="col-3">
|
||||
<strong>End Date:</strong>
|
||||
<p t-esc="data['date_to']"/>
|
||||
</div>
|
||||
<div class="col-3">
|
||||
<strong>Target Moves:</strong>
|
||||
<p t-if="data['target_move'] == 'all'">All Entries</p>
|
||||
<p t-if="data['target_move'] == 'posted'">Posted Entries</p>
|
||||
</div>
|
||||
</div>
|
||||
<table class="table table-sm table-reports">
|
||||
<thead>
|
||||
<tr class="text-center">
|
||||
<th>Date</th>
|
||||
<th>JRNL</th>
|
||||
<th>Partner</th>
|
||||
<th>Ref</th>
|
||||
<th>Move</th>
|
||||
<th>Entry Label</th>
|
||||
<th>Debit</th>
|
||||
<th>Credit</th>
|
||||
<th>Balance</th>
|
||||
<th groups="base.group_multi_currency">Currency</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<t t-foreach="Accounts" t-as="account">
|
||||
<tr style="font-weight: bold;">
|
||||
<td colspan="6">
|
||||
<span style="color: white;" t-esc="'..'"/>
|
||||
<span t-esc="account['date']"/>
|
||||
</td>
|
||||
<td class="text-end">
|
||||
<span t-esc="account['debit']"
|
||||
t-options="{'widget': 'monetary', 'display_currency': res_company.currency_id}"/>
|
||||
</td>
|
||||
<td class="text-end">
|
||||
<span t-esc="account['credit']"
|
||||
t-options="{'widget': 'monetary', 'display_currency': res_company.currency_id}"/>
|
||||
</td>
|
||||
<td class="text-end">
|
||||
<span t-esc="account['balance']"
|
||||
t-options="{'widget': 'monetary', 'display_currency': res_company.currency_id}"/>
|
||||
</td>
|
||||
<td groups="base.group_multi_currency"/>
|
||||
</tr>
|
||||
<tr t-foreach="account['move_lines']" t-as="line">
|
||||
<td>
|
||||
<span t-esc="line['ldate']"/>
|
||||
</td>
|
||||
<td>
|
||||
<span t-esc="line['lcode']"/>
|
||||
</td>
|
||||
<td>
|
||||
<span t-esc="line['lpartner_id']"/>
|
||||
</td>
|
||||
<td>
|
||||
<span t-if="line['lref']" t-esc="line['lref']"/>
|
||||
</td>
|
||||
<td>
|
||||
<span t-esc="line['move_name']"/>
|
||||
</td>
|
||||
<td>
|
||||
<span t-esc="line['lname']"/>
|
||||
</td>
|
||||
<td class="text-end">
|
||||
<span t-esc="line['debit']"
|
||||
t-options="{'widget': 'monetary', 'display_currency': res_company.currency_id}"/>
|
||||
</td>
|
||||
<td class="text-end">
|
||||
<span t-esc="line['credit']"
|
||||
t-options="{'widget': 'monetary', 'display_currency': res_company.currency_id}"/>
|
||||
</td>
|
||||
<td class="text-end">
|
||||
<span t-esc="line['balance']"
|
||||
t-options="{'widget': 'monetary', 'display_currency': res_company.currency_id}"/>
|
||||
</td>
|
||||
<td class="text-end" groups="base.group_multi_currency">
|
||||
<span t-esc="line['amount_currency'] if line['amount_currency'] and line['amount_currency'] > 0.00 else ''"/>
|
||||
<span t-esc="line['currency_code'] if line['amount_currency'] and line['amount_currency'] > 0.00 else ''"/>
|
||||
</td>
|
||||
</tr>
|
||||
</t>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</t>
|
||||
</t>
|
||||
</template>
|
||||
|
||||
</odoo>
|
||||
|
|
@ -0,0 +1,30 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<odoo>
|
||||
<data>
|
||||
|
||||
<record id="action_report_day_book" model="ir.actions.report">
|
||||
<field name="name">Day Book</field>
|
||||
<field name="model">account.daybook.report</field>
|
||||
<field name="report_type">qweb-pdf</field>
|
||||
<field name="report_name">om_account_daily_reports.report_daybook</field>
|
||||
<field name="report_file">om_account_daily_reports.report_daybook</field>
|
||||
</record>
|
||||
|
||||
<record id="action_report_cash_book" model="ir.actions.report">
|
||||
<field name="name">Cash Book</field>
|
||||
<field name="model">account.cashbook.report</field>
|
||||
<field name="report_type">qweb-pdf</field>
|
||||
<field name="report_name">om_account_daily_reports.report_cashbook</field>
|
||||
<field name="report_file">om_account_daily_reports.report_cashbook</field>
|
||||
</record>
|
||||
|
||||
<record id="action_report_bank_book" model="ir.actions.report">
|
||||
<field name="name">Bank Book</field>
|
||||
<field name="model">account.bankbook.report</field>
|
||||
<field name="report_type">qweb-pdf</field>
|
||||
<field name="report_name">om_account_daily_reports.report_bankbook</field>
|
||||
<field name="report_file">om_account_daily_reports.report_bankbook</field>
|
||||
</record>
|
||||
|
||||
</data>
|
||||
</odoo>
|
||||
|
|
@ -0,0 +1,4 @@
|
|||
id,name,model_id:id,group_id:id,perm_read,perm_write,perm_create,perm_unlink
|
||||
access_account_daybook_report,access_account_daybook_report,model_account_daybook_report,account.group_account_manager,1,1,1,1
|
||||
access_account_cashbook_report,access_account_cashbook_report,model_account_cashbook_report,account.group_account_manager,1,1,1,1
|
||||
access_account_bankbook_report,access_account_bankbook_report,model_account_bankbook_report,account.group_account_manager,1,1,1,1
|
||||
|
Binary file not shown.
|
After Width: | Height: | Size: 54 KiB |
Binary file not shown.
|
After Width: | Height: | Size: 34 KiB |
|
|
@ -0,0 +1,55 @@
|
|||
<section class="oe_container oe_dark">
|
||||
<div class="col-md-12">
|
||||
<h2 class="oe_slogan" style="font-size: 35px;color:#2C0091"><b>Odoo 16 Daily Financial Reports</b></h2>
|
||||
</div>
|
||||
</section>
|
||||
|
||||
<section class="oe_container">
|
||||
<div class="oe_row oe_spaced">
|
||||
<div style="text-align:center;">
|
||||
<p class="fa fa-hand-o-right" style="color:CRIMSON;font-size: 25px;">
|
||||
<span style="color:#2dd280;font-size: 15px;">Day Book Report</span>
|
||||
</p><br/>
|
||||
<p class="fa fa-hand-o-right" style="color:CRIMSON;font-size: 25px;">
|
||||
<span style="color:#2dd280;font-size: 15px;">Bank Book Report</span>
|
||||
</p><br/>
|
||||
<p class="fa fa-hand-o-right" style="color:CRIMSON;font-size: 25px;">
|
||||
<span style="color:#2dd280;font-size: 15px;">Cash Book Report</span>
|
||||
</p><br/>
|
||||
</div>
|
||||
<br/>
|
||||
</div>
|
||||
</section>
|
||||
|
||||
|
||||
<hr style="width: 100%;height: 4px;background: #2C0091;margin: 0px 0px;">
|
||||
<hr style="width: 100%;height: 4px;background: #148963;margin: 0px 0px;">
|
||||
<section class="oe_container oe_dark">
|
||||
<div class="oe_row ">
|
||||
<div class="oe_slogan text-center">
|
||||
<img src="odoo_mates.png"/>
|
||||
<div style="color:#269900;">
|
||||
<h3 style="color:#2C0091;font-size: 25px;">If you need any help or want more features, just contact us:</h3><br>
|
||||
<h3 style="color:#2C0091;font-size: 20px;">Email: <a href="odoomates@gmail.com">odoomates@gmail.com</a> <br></h3>
|
||||
</div>
|
||||
<div class="oe_slogan">
|
||||
<h2>
|
||||
<a target="_blank" href="https://www.facebook.com/odoomate/" target="new">
|
||||
<i class="fa fa-facebook-square" style="font-size:38px;"></i>
|
||||
</a>
|
||||
<a target="_blank" href="https://twitter.com/odoomates/" target="new">
|
||||
<i class="fa fa-twitter" style="font-size:38px;"></i>
|
||||
</a>
|
||||
<a href="#" target="_blank">
|
||||
<i class="fa fa-linkedin" style="font-size:38px;"></i>
|
||||
</a>
|
||||
<a target="_blank" href="https://www.youtube.com/channel/UCVKlUZP7HAhdQgs-9iTJklQ">
|
||||
<i class="fa fa-youtube-play" style="font-size:38px;"></i>
|
||||
</a>
|
||||
</h2>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</section>
|
||||
<hr style="width: 100%;height: 4px;background: #148963;margin: 0px 0px;">
|
||||
<hr style="width: 100%;height: 4px;background: #2C0091;margin: 0px 0px;">
|
||||
Binary file not shown.
|
After Width: | Height: | Size: 7.6 KiB |
|
|
@ -0,0 +1,12 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<odoo>
|
||||
<data>
|
||||
|
||||
<menuitem id="menu_finance_daily_reports"
|
||||
name="Daily Reports"
|
||||
sequence="35"
|
||||
parent="account.menu_finance_reports"/>
|
||||
|
||||
</data>
|
||||
</odoo>
|
||||
|
||||
|
|
@ -0,0 +1,6 @@
|
|||
# -*- coding: utf-8 -*-
|
||||
|
||||
from . import account_daybook_report
|
||||
from . import account_cashbook_report
|
||||
from . import account_bankbook_report
|
||||
|
||||
|
|
@ -0,0 +1,83 @@
|
|||
# -*- coding: utf-8 -*-
|
||||
|
||||
from odoo import fields, models, api, _
|
||||
from datetime import date
|
||||
|
||||
|
||||
class AccountBankBookReport(models.TransientModel):
|
||||
_name = "account.bankbook.report"
|
||||
_description = "Bank Book Report"
|
||||
|
||||
def _get_default_account_ids(self):
|
||||
journals = self.env['account.journal'].search([('type', '=', 'bank')])
|
||||
accounts = []
|
||||
for journal in journals:
|
||||
if journal.default_account_id.id:
|
||||
accounts.append(journal.default_account_id.id)
|
||||
if journal.company_id.account_journal_payment_credit_account_id.id:
|
||||
accounts.append(journal.company_id.account_journal_payment_credit_account_id.id)
|
||||
if journal.company_id.account_journal_payment_debit_account_id.id:
|
||||
accounts.append(journal.company_id.account_journal_payment_debit_account_id.id)
|
||||
for acc_out in journal.outbound_payment_method_line_ids:
|
||||
if acc_out.payment_account_id:
|
||||
accounts.append(acc_out.payment_account_id.id)
|
||||
for acc_in in journal.inbound_payment_method_line_ids:
|
||||
if acc_in.payment_account_id:
|
||||
accounts.append(acc_in.payment_account_id.id)
|
||||
return accounts
|
||||
|
||||
date_from = fields.Date(string='Start Date', default=date.today(), required=True)
|
||||
date_to = fields.Date(string='End Date', default=date.today(), required=True)
|
||||
target_move = fields.Selection([('posted', 'Posted Entries'),
|
||||
('all', 'All Entries')], string='Target Moves', required=True,
|
||||
default='posted')
|
||||
journal_ids = fields.Many2many('account.journal', string='Journals', required=True,
|
||||
default=lambda self: self.env['account.journal'].search([]))
|
||||
account_ids = fields.Many2many('account.account', 'account_account_bankbook_report', 'report_line_id',
|
||||
'account_id', 'Accounts', default=_get_default_account_ids)
|
||||
|
||||
display_account = fields.Selection(
|
||||
[('all', 'All'), ('movement', 'With movements'),
|
||||
('not_zero', 'With balance is not equal to 0')],
|
||||
string='Display Accounts', required=True, default='movement')
|
||||
sortby = fields.Selection(
|
||||
[('sort_date', 'Date'), ('sort_journal_partner', 'Journal & Partner')],
|
||||
string='Sort by',
|
||||
required=True, default='sort_date')
|
||||
initial_balance = fields.Boolean(string='Include Initial Balances',
|
||||
help='If you selected date, this field allow you to add a row '
|
||||
'to display the amount of debit/credit/balance that precedes the '
|
||||
'filter you\'ve set.')
|
||||
|
||||
@api.onchange('account_ids')
|
||||
def onchange_account_ids(self):
|
||||
if self.account_ids:
|
||||
journals = self.env['account.journal'].search(
|
||||
[('type', '=', 'bank')])
|
||||
accounts = []
|
||||
for journal in journals:
|
||||
accounts.append(journal.company_id.account_journal_payment_credit_account_id.id)
|
||||
domain = {'account_ids': [('id', 'in', accounts)]}
|
||||
return {'domain': domain}
|
||||
|
||||
def _build_comparison_context(self, data):
|
||||
result = {}
|
||||
result['journal_ids'] = 'journal_ids' in data['form'] and data['form'][
|
||||
'journal_ids'] or False
|
||||
result['state'] = 'target_move' in data['form'] and data['form'][
|
||||
'target_move'] or ''
|
||||
result['date_from'] = data['form']['date_from'] or False
|
||||
result['date_to'] = data['form']['date_to'] or False
|
||||
result['strict_range'] = True if result['date_from'] else False
|
||||
return result
|
||||
|
||||
def check_report(self):
|
||||
data = {}
|
||||
data['form'] = self.read(['target_move', 'date_from', 'date_to', 'journal_ids', 'account_ids',
|
||||
'sortby', 'initial_balance', 'display_account'])[0]
|
||||
comparison_context = self._build_comparison_context(data)
|
||||
data['form']['comparison_context'] = comparison_context
|
||||
return self.env.ref(
|
||||
'om_account_daily_reports.action_report_bank_book').report_action(self,
|
||||
data=data)
|
||||
|
||||
|
|
@ -0,0 +1,83 @@
|
|||
# -*- coding: utf-8 -*-
|
||||
|
||||
from odoo import fields, models, api, _
|
||||
from datetime import date
|
||||
|
||||
|
||||
class AccountCashBookReport(models.TransientModel):
|
||||
_name = "account.cashbook.report"
|
||||
_description = "Cash Book Report"
|
||||
|
||||
def _get_default_account_ids(self):
|
||||
journals = self.env['account.journal'].search([('type', '=', 'cash')])
|
||||
accounts = []
|
||||
for journal in journals:
|
||||
if journal.default_account_id.id:
|
||||
accounts.append(journal.default_account_id.id)
|
||||
if journal.company_id.account_journal_payment_credit_account_id.id:
|
||||
accounts.append(journal.company_id.account_journal_payment_credit_account_id.id)
|
||||
if journal.company_id.account_journal_payment_debit_account_id.id:
|
||||
accounts.append(journal.company_id.account_journal_payment_debit_account_id.id)
|
||||
for acc_out in journal.outbound_payment_method_line_ids:
|
||||
if acc_out.payment_account_id:
|
||||
accounts.append(acc_out.payment_account_id.id)
|
||||
for acc_in in journal.inbound_payment_method_line_ids:
|
||||
if acc_in.payment_account_id:
|
||||
accounts.append(acc_in.payment_account_id.id)
|
||||
return accounts
|
||||
|
||||
date_from = fields.Date(string='Start Date', default=date.today(), required=True)
|
||||
date_to = fields.Date(string='End Date', default=date.today(), required=True)
|
||||
target_move = fields.Selection([('posted', 'Posted Entries'),
|
||||
('all', 'All Entries')], string='Target Moves', required=True,
|
||||
default='posted')
|
||||
journal_ids = fields.Many2many('account.journal', string='Journals', required=True,
|
||||
default=lambda self: self.env['account.journal'].search([]))
|
||||
account_ids = fields.Many2many('account.account', 'account_account_cashbook_report', 'report_line_id',
|
||||
'account_id', 'Accounts', default=_get_default_account_ids)
|
||||
|
||||
display_account = fields.Selection(
|
||||
[('all', 'All'), ('movement', 'With movements'),
|
||||
('not_zero', 'With balance is not equal to 0')],
|
||||
string='Display Accounts', required=True, default='movement')
|
||||
sortby = fields.Selection(
|
||||
[('sort_date', 'Date'), ('sort_journal_partner', 'Journal & Partner')],
|
||||
string='Sort by',
|
||||
required=True, default='sort_date')
|
||||
initial_balance = fields.Boolean(string='Include Initial Balances',
|
||||
help='If you selected date, this field allow you to add a row to'
|
||||
' display the amount of debit/credit/balance that precedes '
|
||||
'the filter you\'ve set.')
|
||||
|
||||
@api.onchange('account_ids')
|
||||
def onchange_account_ids(self):
|
||||
if self.account_ids:
|
||||
journals = self.env['account.journal'].search(
|
||||
[('type', '=', 'cash')])
|
||||
accounts = []
|
||||
for journal in journals:
|
||||
accounts.append(journal.company_id.account_journal_payment_credit_account_id.id)
|
||||
domain = {'account_ids': [('id', 'in', accounts)]}
|
||||
return {'domain': domain}
|
||||
|
||||
def _build_comparison_context(self, data):
|
||||
result = {}
|
||||
result['journal_ids'] = 'journal_ids' in data['form'] and data['form'][
|
||||
'journal_ids'] or False
|
||||
result['state'] = 'target_move' in data['form'] and data['form'][
|
||||
'target_move'] or ''
|
||||
result['date_from'] = data['form']['date_from'] or False
|
||||
result['date_to'] = data['form']['date_to'] or False
|
||||
result['strict_range'] = True if result['date_from'] else False
|
||||
return result
|
||||
|
||||
def check_report(self):
|
||||
data = {}
|
||||
data['form'] = self.read(['target_move', 'date_from', 'date_to', 'journal_ids', 'account_ids',
|
||||
'sortby', 'initial_balance', 'display_account'])[0]
|
||||
comparison_context = self._build_comparison_context(data)
|
||||
data['form']['comparison_context'] = comparison_context
|
||||
return self.env.ref(
|
||||
'om_account_daily_reports.action_report_cash_book').report_action(self,
|
||||
data=data)
|
||||
|
||||
|
|
@ -0,0 +1,40 @@
|
|||
# -*- coding: utf-8 -*-
|
||||
|
||||
from odoo import fields, models, _
|
||||
from datetime import date
|
||||
|
||||
|
||||
class AccountDayBookReport(models.TransientModel):
|
||||
_name = "account.daybook.report"
|
||||
_description = "Day Book Report"
|
||||
|
||||
date_from = fields.Date(string='Start Date', default=date.today(), required=True)
|
||||
date_to = fields.Date(string='End Date', default=date.today(), required=True)
|
||||
target_move = fields.Selection([('posted', 'Posted Entries'),
|
||||
('all', 'All Entries')], string='Target Moves', required=True,
|
||||
default='posted')
|
||||
journal_ids = fields.Many2many('account.journal', string='Journals', required=True,
|
||||
default=lambda self: self.env['account.journal'].search([]))
|
||||
account_ids = fields.Many2many('account.account', 'account_account_daybook_report', 'report_line_id',
|
||||
'account_id', 'Accounts')
|
||||
|
||||
def _build_comparison_context(self, data):
|
||||
result = {}
|
||||
result['journal_ids'] = 'journal_ids' in data['form'] and data['form']['journal_ids'] or False
|
||||
result['state'] = 'target_move' in data['form'] and data['form']['target_move'] or ''
|
||||
result['date_from'] = data['form']['date_from']
|
||||
result['date_to'] = data['form']['date_to']
|
||||
return result
|
||||
|
||||
def check_report(self):
|
||||
data = {}
|
||||
data['form'] = self.read(['target_move', 'date_from', 'date_to', 'journal_ids', 'account_ids'])[0]
|
||||
comparison_context = self._build_comparison_context(data)
|
||||
data['form']['comparison_context'] = comparison_context
|
||||
return self.env.ref(
|
||||
'om_account_daily_reports.action_report_day_book').report_action(self,
|
||||
data=data)
|
||||
|
||||
|
||||
|
||||
|
||||
|
|
@ -0,0 +1,56 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<odoo>
|
||||
|
||||
<record id="account_report_bankbook_view" model="ir.ui.view">
|
||||
<field name="name">Bank Book</field>
|
||||
<field name="model">account.bankbook.report</field>
|
||||
<field name="arch" type="xml">
|
||||
<form string="Report Options">
|
||||
<group>
|
||||
<group>
|
||||
<field name="target_move" widget="radio"/>
|
||||
</group>
|
||||
<group>
|
||||
<field name="sortby" widget="radio"/>
|
||||
<field name="display_account" invisible="1"/>
|
||||
</group>
|
||||
</group>
|
||||
<group>
|
||||
<field name="initial_balance"/>
|
||||
</group>
|
||||
<group col="4">
|
||||
<field name="date_from"/>
|
||||
<field name="date_to"/>
|
||||
</group>
|
||||
<group>
|
||||
<field name="account_ids" widget="many2many_tags" invisible="0"/>
|
||||
<field name="journal_ids" widget="many2many_tags"/>
|
||||
</group>
|
||||
<footer>
|
||||
<button name="check_report" string="Print" type="object" default_focus="1"
|
||||
class="oe_highlight"/>
|
||||
<button string="Cancel" class="btn btn-default" special="cancel"/>
|
||||
</footer>
|
||||
</form>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record id="action_account_bankbook_menu" model="ir.actions.act_window">
|
||||
<field name="name">Bank Book</field>
|
||||
<field name="type">ir.actions.act_window</field>
|
||||
<field name="res_model">account.bankbook.report</field>
|
||||
<field name="view_mode">form</field>
|
||||
<field name="view_id" ref="account_report_bankbook_view"/>
|
||||
<field name="target">new</field>
|
||||
</record>
|
||||
|
||||
<menuitem
|
||||
id="menu_bankbook"
|
||||
name="Bank Book"
|
||||
sequence="10"
|
||||
parent="om_account_daily_reports.menu_finance_daily_reports"
|
||||
action="action_account_bankbook_menu"
|
||||
groups="account.group_account_user,account.group_account_manager"
|
||||
/>
|
||||
|
||||
</odoo>
|
||||
|
|
@ -0,0 +1,56 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<odoo>
|
||||
|
||||
<record id="account_report_cashbook_view" model="ir.ui.view">
|
||||
<field name="name">Cash Book</field>
|
||||
<field name="model">account.cashbook.report</field>
|
||||
<field name="arch" type="xml">
|
||||
<form string="Report Options">
|
||||
<group>
|
||||
<group>
|
||||
<field name="target_move" widget="radio"/>
|
||||
</group>
|
||||
<group>
|
||||
<field name="sortby" widget="radio"/>
|
||||
<field name="display_account" invisible="1"/>
|
||||
</group>
|
||||
</group>
|
||||
<group>
|
||||
<field name="initial_balance"/>
|
||||
</group>
|
||||
<group col="4">
|
||||
<field name="date_from"/>
|
||||
<field name="date_to"/>
|
||||
</group>
|
||||
<group>
|
||||
<field name="account_ids" widget="many2many_tags" invisible="0"/>
|
||||
<field name="journal_ids" widget="many2many_tags"/>
|
||||
</group>
|
||||
<footer>
|
||||
<button name="check_report" string="Print" type="object" default_focus="1"
|
||||
class="oe_highlight"/>
|
||||
<button string="Cancel" class="btn btn-default" special="cancel"/>
|
||||
</footer>
|
||||
</form>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record id="action_account_cashbook_menu" model="ir.actions.act_window">
|
||||
<field name="name">Cash Book</field>
|
||||
<field name="type">ir.actions.act_window</field>
|
||||
<field name="res_model">account.cashbook.report</field>
|
||||
<field name="view_mode">form</field>
|
||||
<field name="view_id" ref="account_report_cashbook_view"/>
|
||||
<field name="target">new</field>
|
||||
</record>
|
||||
|
||||
<menuitem
|
||||
id="menu_cashbook"
|
||||
name="Cash Book"
|
||||
sequence="10"
|
||||
parent="om_account_daily_reports.menu_finance_daily_reports"
|
||||
action="action_account_cashbook_menu"
|
||||
groups="account.group_account_user,account.group_account_manager"
|
||||
/>
|
||||
|
||||
</odoo>
|
||||
|
|
@ -0,0 +1,48 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<odoo>
|
||||
|
||||
<record id="account_report_daybook_view" model="ir.ui.view">
|
||||
<field name="name">Day Book</field>
|
||||
<field name="model">account.daybook.report</field>
|
||||
<field name="arch" type="xml">
|
||||
<form string="Report Options">
|
||||
<group>
|
||||
<field name="target_move" widget="radio"/>
|
||||
</group>
|
||||
<group col="4">
|
||||
<field name="date_from"/>
|
||||
<field name="date_to"/>
|
||||
</group>
|
||||
<group>
|
||||
|
||||
<field name="journal_ids" widget="many2many_tags"/>
|
||||
<field name="account_ids" widget="many2many_tags" invisible="1"/>
|
||||
</group>
|
||||
<footer>
|
||||
<button name="check_report" string="Print" type="object" default_focus="1"
|
||||
class="oe_highlight"/>
|
||||
<button string="Cancel" class="btn btn-default" special="cancel"/>
|
||||
</footer>
|
||||
</form>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record id="action_account_daybook_menu" model="ir.actions.act_window">
|
||||
<field name="name">Day Book</field>
|
||||
<field name="type">ir.actions.act_window</field>
|
||||
<field name="res_model">account.daybook.report</field>
|
||||
<field name="view_mode">form</field>
|
||||
<field name="view_id" ref="account_report_daybook_view"/>
|
||||
<field name="target">new</field>
|
||||
</record>
|
||||
|
||||
<menuitem
|
||||
id="menu_daybook"
|
||||
name="Day Book"
|
||||
sequence="10"
|
||||
parent="om_account_daily_reports.menu_finance_daily_reports"
|
||||
action="action_account_daybook_menu"
|
||||
groups="account.group_account_user,account.group_account_manager"
|
||||
/>
|
||||
|
||||
</odoo>
|
||||
|
|
@ -0,0 +1,43 @@
|
|||
[project]
|
||||
name = "odoo-bringout-odoomates-om_account_daily_reports"
|
||||
version = "16.0.0"
|
||||
description = "Cash Book, Day Book, Bank Book Financial Reports - Cash Book, Day Book and Bank Book Report For Odoo 16"
|
||||
authors = [
|
||||
{ name = "Ernad Husremovic", email = "hernad@bring.out.ba" }
|
||||
]
|
||||
dependencies = [
|
||||
"odoo-bringout-oca-ocb-account>=16.0.0",
|
||||
"odoo-bringout-odoomates-accounting_pdf_reports>=16.0.0",
|
||||
"requests>=2.25.1"
|
||||
]
|
||||
readme = "README.md"
|
||||
requires-python = ">= 3.11"
|
||||
classifiers = [
|
||||
"Development Status :: 5 - Production/Stable",
|
||||
"Intended Audience :: Developers",
|
||||
"License :: OSI Approved :: GNU Lesser General Public License v3 (LGPLv3)",
|
||||
"Programming Language :: Python :: 3",
|
||||
"Programming Language :: Python :: 3.11",
|
||||
"Programming Language :: Python :: 3.12",
|
||||
"Topic :: Office/Business",
|
||||
]
|
||||
|
||||
[project.urls]
|
||||
homepage = "https://github.com/bringout/0"
|
||||
repository = "https://github.com/bringout/0"
|
||||
|
||||
[build-system]
|
||||
requires = ["hatchling"]
|
||||
build-backend = "hatchling.build"
|
||||
|
||||
[tool.hatch.metadata]
|
||||
allow-direct-references = true
|
||||
|
||||
[tool.hatch.build.targets.wheel]
|
||||
packages = ["om_account_daily_reports"]
|
||||
|
||||
[tool.rye]
|
||||
managed = true
|
||||
dev-dependencies = [
|
||||
"pytest>=8.4.1",
|
||||
]
|
||||
Loading…
Add table
Add a link
Reference in a new issue