diff --git a/cash_flow_statement/README.rst b/cash_flow_statement/README.rst new file mode 100644 index 000000000..8f08e93e2 --- /dev/null +++ b/cash_flow_statement/README.rst @@ -0,0 +1,41 @@ +Print Cash Flow Statement +========================= +Print Cash Flow Statement For Odoo V12 Community Edition + +Installation +============ +- www.odoo.com/documentation/12.0/setup/install.html +- Install our custom addon + +License +------- +GNU AFFERO GENERAL PUBLIC LICENSE, Version 3 (AGPLv3) +(http://www.gnu.org/licenses/agpl.html) + +Company +------- +* 'Cybrosys Techno Solutions `__ + +Credits +------- +* Developers: + IJAZ AHAMMED @ Cybrosys + VARSHA VIVEK @ Cybrosys + +Contacts +-------- +* Mail Contact : odoo@cybrosys.com + +Bug Tracker +----------- +Bugs are tracked on GitHub Issues. In case of trouble, please check there if your issue has already been reported. + +Maintainer +========== +This module is maintained by Cybrosys Technologies. + +For support and more information, please visit https://www.cybrosys.com + +Further information +=================== +HTML Description: ``__ diff --git a/cash_flow_statement/__init__.py b/cash_flow_statement/__init__.py new file mode 100644 index 000000000..42d647d19 --- /dev/null +++ b/cash_flow_statement/__init__.py @@ -0,0 +1,25 @@ +# -*- coding: utf-8 -*- +############################################################################# +# +# Cybrosys Technologies Pvt. Ltd. +# +# Copyright (C) 2019-TODAY Cybrosys Technologies(). +# Author: Ijaz Ahammed, Varsha Vivek () +# +# You can modify it under the terms of the GNU AFFERO +# GENERAL PUBLIC LICENSE (AGPL v3), Version 3. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU AFFERO GENERAL PUBLIC LICENSE (AGPL v3) for more details. +# +# You should have received a copy of the GNU AFFERO GENERAL PUBLIC LICENSE +# (AGPL v3) along with this program. +# If not, see . +# +############################################################################# + +from . import models +from . import reports +from . import wizard \ No newline at end of file diff --git a/cash_flow_statement/__manifest__.py b/cash_flow_statement/__manifest__.py new file mode 100644 index 000000000..c50170b41 --- /dev/null +++ b/cash_flow_statement/__manifest__.py @@ -0,0 +1,49 @@ +# -*- coding: utf-8 -*- +############################################################################# +# +# Cybrosys Technologies Pvt. Ltd. +# +# Copyright (C) 2019-TODAY Cybrosys Technologies(). +# Author: Ijaz Ahammed, Varsha Vivek () +# +# You can modify it under the terms of the GNU AFFERO +# GENERAL PUBLIC LICENSE (AGPL v3), Version 3. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU AFFERO GENERAL PUBLIC LICENSE (AGPL v3) for more details. +# +# You should have received a copy of the GNU AFFERO GENERAL PUBLIC LICENSE +# (AGPL v3) along with this program. +# If not, see . +# +############################################################################# + +{ + 'name': 'Print Cash Flow Statement', + 'version': '12.0.1.0.0', + 'summary': """Print pdf reports of cash flow statements """, + 'description': """Print pdf reports of cash flow statements """, + 'author': "Cybrosys Techno Solutions", + 'company': 'Cybrosys Techno Solutions', + 'maintainer': 'Cybrosys Techno Solutions', + 'website': "https://www.cybrosys.com", + 'category': 'Accounting', + 'depends': [ + 'account', + 'date_range', + 'report_xlsx', + ], + 'data': [ + 'security/ir.model.access.csv', + 'data/cash_flow_data.xml', + 'views/account_configuration.xml', + 'reports/cash_flow_report.xml', + ], + 'images': ['static/description/banner.png'], + 'license': 'AGPL-3', + 'installable': True, + 'application': False, + 'auto_install': False, +} \ No newline at end of file diff --git a/cash_flow_statement/data/cash_flow_data.xml b/cash_flow_statement/data/cash_flow_data.xml new file mode 100644 index 000000000..0b8139259 --- /dev/null +++ b/cash_flow_statement/data/cash_flow_data.xml @@ -0,0 +1,126 @@ + + + + + Cash Flow Statement + sum + + + + Operations + 1 + + detail_with_hierarchy + sum + + + Cash In + 1 + + detail_with_hierarchy + accounts + + + Cash Out + 2 + + detail_with_hierarchy + accounts + + + + Investing Activities + 2 + + detail_with_hierarchy + sum + + + Cash In + + detail_with_hierarchy + accounts + + + Cash Out + + detail_with_hierarchy + accounts + + + + Financing Activities + 3 + + detail_with_hierarchy + sum + + + + + Cash In + + detail_with_hierarchy + accounts + + + Cash Out + + detail_with_hierarchy + accounts + + + + Accounting Report + accounting.report + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Cash Flow Statement + accounting.report + ir.actions.act_window + form + form + + new + + + + + + diff --git a/cash_flow_statement/doc/RELEASE_NOTES.md b/cash_flow_statement/doc/RELEASE_NOTES.md new file mode 100644 index 000000000..2da710b0c --- /dev/null +++ b/cash_flow_statement/doc/RELEASE_NOTES.md @@ -0,0 +1,8 @@ +## Module + +#### 31.08.2019 +#### Version 12.0.1.0.0 +##### ADD +- Initial commit for cash_flow_statement + + diff --git a/cash_flow_statement/models/__init__.py b/cash_flow_statement/models/__init__.py new file mode 100644 index 000000000..21e726756 --- /dev/null +++ b/cash_flow_statement/models/__init__.py @@ -0,0 +1,23 @@ +# -*- coding: utf-8 -*- +############################################################################# +# +# Cybrosys Technologies Pvt. Ltd. +# +# Copyright (C) 2019-TODAY Cybrosys Technologies(). +# Author: Ijaz Ahammed, Varsha Vivek () +# +# You can modify it under the terms of the GNU AFFERO +# GENERAL PUBLIC LICENSE (AGPL v3), Version 3. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU AFFERO GENERAL PUBLIC LICENSE (AGPL v3) for more details. +# +# You should have received a copy of the GNU AFFERO GENERAL PUBLIC LICENSE +# (AGPL v3) along with this program. +# If not, see . +# +############################################################################# + +from . import cash_flow diff --git a/cash_flow_statement/models/cash_flow.py b/cash_flow_statement/models/cash_flow.py new file mode 100644 index 000000000..16508f9de --- /dev/null +++ b/cash_flow_statement/models/cash_flow.py @@ -0,0 +1,94 @@ +# -*- coding: utf-8 -*- +############################################################################# +# +# Cybrosys Technologies Pvt. Ltd. +# +# Copyright (C) 2019-TODAY Cybrosys Technologies(). +# Author: Ijaz Ahammed, Varsha Vivek () +# +# You can modify it under the terms of the GNU AFFERO +# GENERAL PUBLIC LICENSE (AGPL v3), Version 3. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU AFFERO GENERAL PUBLIC LICENSE (AGPL v3) for more details. +# +# You should have received a copy of the GNU AFFERO GENERAL PUBLIC LICENSE +# (AGPL v3) along with this program. +# If not, see . +# +############################################################################# + +from odoo import api, models, fields + + +class AccountFinancialReport(models.Model): + _name = "account.financial.report" + _description = "Account Report" + + @api.multi + @api.depends('parent_id', 'parent_id.level') + def _get_level(self): + '''Returns a dictionary with key=the ID of a record and value = the level of this + record in the tree structure.''' + for report in self: + level = 0 + if report.parent_id: + level = report.parent_id.level + 1 + report.level = level + + def _get_children_by_order(self): + '''returns a recordset of all the children computed recursively, + and sorted by sequence. Ready for the printing''' + res = self + children = self.search([('parent_id', 'in', self.ids)], order='sequence ASC') + if children: + for child in children: + res += child._get_children_by_order() + return res + + name = fields.Char('Report Name', required=True, translate=True) + parent_id = fields.Many2one('account.financial.report', 'Parent') + children_ids = fields.One2many('account.financial.report', 'parent_id', 'Account Report') + sequence = fields.Integer('Sequence') + level = fields.Integer(compute='_get_level', string='Level', store=True) + type = fields.Selection([ + ('sum', 'View'), + ('accounts', 'Accounts'), + ('account_type', 'Account Type'), + ('account_report', 'Report Value'), + ], 'Type', default='sum') + account_ids = fields.Many2many('account.account', 'account_account_financial_report', + 'report_line_id', 'account_id', 'Accounts') + account_report_id = fields.Many2one('account.financial.report', 'Report Value') + account_type_ids = fields.Many2many('account.account.type', + 'account_account_financial_report_type', + 'report_id', + 'account_type_id', + 'Account Types') + sign = fields.Selection([(-1, 'Reverse balance sign'), + (1, 'Preserve balance sign')], 'Sign on Reports', + required=True, default=1, + help='For accounts that are typically more debited than credited and that you would' + ' like to print as negative amounts in your reports, you should reverse the sign' + ' of the balance; e.g.: Expense account. The same applies for accounts that are' + ' typically more credited than debited and that you would like to print as positive' + ' amounts in your reports; e.g.: Income account.') + display_detail = fields.Selection([ + ('no_detail', 'No detail'), + ('detail_flat', 'Display children flat'), + ('detail_with_hierarchy', 'Display children with hierarchy') + ], 'Display details', default='detail_flat') + style_overwrite = fields.Selection([ + (0, 'Automatic formatting'), + (1, 'Main Title 1 (bold, underlined)'), + (2, 'Title 2 (bold)'), + (3, 'Title 3 (bold, smaller)'), + (4, 'Normal Text'), + (5, 'Italic Text (smaller)'), + (6, 'Smallest Text'), + ], 'Financial Report Style', default=0, + help="You can set up here the format you want this record to be displayed. " + "If you leave the automatic formatting, it will be computed based on the " + "financial reports hierarchy (auto-computed field 'level').") diff --git a/cash_flow_statement/reports/__init__.py b/cash_flow_statement/reports/__init__.py new file mode 100644 index 000000000..5f26ea047 --- /dev/null +++ b/cash_flow_statement/reports/__init__.py @@ -0,0 +1,23 @@ +# -*- coding: utf-8 -*- +############################################################################# +# +# Cybrosys Technologies Pvt. Ltd. +# +# Copyright (C) 2019-TODAY Cybrosys Technologies(). +# Author: Ijaz Ahammed, Varsha Vivek () +# +# You can modify it under the terms of the GNU AFFERO +# GENERAL PUBLIC LICENSE (AGPL v3), Version 3. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU AFFERO GENERAL PUBLIC LICENSE (AGPL v3) for more details. +# +# You should have received a copy of the GNU AFFERO GENERAL PUBLIC LICENSE +# (AGPL v3) along with this program. +# If not, see . +# +############################################################################# + +from . import cash_flow_report \ No newline at end of file diff --git a/cash_flow_statement/reports/cash_flow_report.py b/cash_flow_statement/reports/cash_flow_report.py new file mode 100644 index 000000000..e4e0e1e80 --- /dev/null +++ b/cash_flow_statement/reports/cash_flow_report.py @@ -0,0 +1,218 @@ +# -*- coding: utf-8 -*- +############################################################################# +# +# Cybrosys Technologies Pvt. Ltd. +# +# Copyright (C) 2019-TODAY Cybrosys Technologies(). +# Author: Ijaz Ahammed, Varsha Vivek () +# +# You can modify it under the terms of the GNU AFFERO +# GENERAL PUBLIC LICENSE (AGPL v3), Version 3. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU AFFERO GENERAL PUBLIC LICENSE (AGPL v3) for more details. +# +# You should have received a copy of the GNU AFFERO GENERAL PUBLIC LICENSE +# (AGPL v3) along with this program. +# If not, see . +# +############################################################################# + +import time +from odoo import api, models, fields, _ +from odoo.exceptions import UserError + + +class ReportFinancial(models.AbstractModel): + _name = 'report.cash_flow_statement.report_financial' + + def _compute_account_balance(self, accounts): + mapping = { + 'balance': "COALESCE(SUM(debit),0) - COALESCE(SUM(credit), 0) as balance", + 'debit': "COALESCE(SUM(debit), 0) as debit", + 'credit': "COALESCE(SUM(credit), 0) as credit", + } + + res = {} + for account in accounts: + res[account.id] = dict.fromkeys(mapping, 0.0) + if accounts: + tables, where_clause, where_params = self.env['account.move.line']._query_get() + tables = tables.replace('"', '') if tables else "account_move_line" + wheres = [""] + if where_clause.strip(): + wheres.append(where_clause.strip()) + filters = " AND ".join(wheres) + request = "SELECT account_id as id, " + ', '.join(mapping.values()) + \ + " FROM " + tables + \ + " WHERE account_id IN %s " \ + + filters + \ + " GROUP BY account_id" + params = (tuple(accounts._ids),) + tuple(where_params) + self.env.cr.execute(request, params) + for row in self.env.cr.dictfetchall(): + res[row['id']] = row + return res + + def _compute_report_balance(self, reports): + + res = {} + fields = ['credit', 'debit', 'balance'] + for report in reports: + if report.id in res: + continue + res[report.id] = dict((fn, 0.0) for fn in fields) + if report.type == 'accounts': + # it's the sum of credit or debit + res2 = self._compute_report_balance(report.parent_id) + for key, value in res2.items(): + cash_in_operation = self.env.ref('cash_flow_statement.cash_in_from_operation0') + cash_out_operation = self.env.ref('cash_flow_statement.cash_out_operation1') + cash_in_financial = self.env.ref('cash_flow_statement.cash_in_financial0') + cash_out_financial = self.env.ref('cash_flow_statement.cash_out_financial1') + cash_in_investing = self.env.ref('cash_flow_statement.cash_in_investing0') + cash_out_investing = self.env.ref('cash_flow_statement.cash_out_investing1') + if report == cash_in_operation or report == cash_in_financial or report == cash_in_investing: + res[report.id]['debit'] += value['debit'] + res[report.id]['balance'] += value['debit'] + elif report == cash_out_operation or report == cash_out_financial or report == cash_out_investing: + res[report.id]['credit'] += value['credit'] + res[report.id]['balance'] += -(value['credit']) + elif report.type == 'account_type': + # it's the sum the leaf accounts with such an account type + accounts = self.env['account.account'].search([('user_type_id', 'in', report.account_type_ids.ids)]) + res[report.id]['account'] = self._compute_account_balance(accounts) + for value in res[report.id]['account'].values(): + for field in fields: + res[report.id][field] += value.get(field) + elif report.type == 'account_report' and report.account_report_id: + # it's the amount of the linked + res[report.id]['account'] = self._compute_account_balance(report.account_ids) + for value in res[report.id]['account'].values(): + for field in fields: + res[report.id][field] += value.get(field) + + elif report.type == 'sum': + # it's the sum of the linked accounts + res[report.id]['account'] = self._compute_account_balance(report.account_ids) + for values in res[report.id]['account'].values(): + for field in fields: + res[report.id][field] += values.get(field) + return res + + def get_account_lines(self, data): + lines = [] + account_report = self.env['account.financial.report'].search([('id', '=', data['account_report_id'][0])]) + child_reports = account_report._get_children_by_order() + res = self.with_context(data.get('used_context'))._compute_report_balance(child_reports) + if data['enable_filter']: + comparison_res = self.with_context(data.get('comparison_context'))._compute_report_balance(child_reports) + for report_id, value in comparison_res.items(): + res[report_id]['comp_bal'] = value['balance'] + report_acc = res[report_id].get('account') + if report_acc: + for account_id, val in comparison_res[report_id].get('account').items(): + report_acc[account_id]['comp_bal'] = val['balance'] + + for report in child_reports: + vals = { + 'name': report.name, + 'balance': res[report.id]['balance'] * report.sign, + 'type': 'report', + 'level': bool(report.style_overwrite) and report.style_overwrite or report.level, + 'account_type': report.type or False, # used to underline the financial report balances + } + if data['debit_credit']: + vals['debit'] = res[report.id]['debit'] + vals['credit'] = res[report.id]['credit'] + + if data['enable_filter']: + vals['balance_cmp'] = res[report.id]['comp_bal'] * report.sign + + lines.append(vals) + if report.display_detail == 'no_detail': + # the rest of the loop is used to display the details of the financial report, so it's not needed here. + continue + if res[report.id].get('account'): + # if res[report.id].get('debit'): + sub_lines = [] + for account_id, value in res[report.id]['account'].items(): + # if there are accounts to display, we add them to the lines with a level equals to their level in + # the COA + 1 (to avoid having them with a too low level that would conflicts with the level of data + # financial reports for Assets, liabilities...) + flag = False + account = self.env['account.account'].browse(account_id) + + vals = { + 'name': account.code + ' ' + account.name, + 'balance': value['balance'] * report.sign or 0.0, + 'type': 'account', + 'level': report.display_detail == 'detail_with_hierarchy' and 4, + 'account_type': account.internal_type, + } + if data['debit_credit']: + vals['debit'] = value['debit'] + vals['credit'] = value['credit'] + if not account.company_id.currency_id.is_zero( + vals['debit']) or not account.company_id.currency_id.is_zero(vals['credit']): + flag = True + if not account.company_id.currency_id.is_zero(vals['balance']): + flag = True + if data['enable_filter']: + vals['balance_cmp'] = value['comp_bal'] * report.sign + if not account.company_id.currency_id.is_zero(vals['balance_cmp']): + flag = True + if flag: + sub_lines.append(vals) + lines += sorted(sub_lines, key=lambda sub_line: sub_line['name']) + return lines + + @api.model + def _get_report_values(self, docids, data=None): + print('success') + if not data.get('form') or not self.env.context.get('active_model') or not self.env.context.get('active_id'): + raise UserError(_("Form content is missing, this report cannot be printed.")) + + self.model = self.env.context.get('active_model') + docs = self.env[self.model].browse(self.env.context.get('active_id')) + report_lines = self.get_account_lines(data.get('form')) + return { + 'doc_ids': self.ids, + 'doc_model': self.model, + 'data': data['form'], + 'docs': docs, + 'time': time, + 'get_account_lines': report_lines, + } + + +class CashFlow(models.Model): + _inherit = 'account.account' + + def get_cash_flow_ids(self): + cash_flow_id = self.env.ref('cash_flow_statement.account_financial_report_cash_flow0') + if cash_flow_id: + return [('parent_id.id', '=', cash_flow_id.id)] + + cash_flow_type = fields.Many2one('account.financial.report', string="Cash Flow type", domain=get_cash_flow_ids) + + @api.onchange('cash_flow_type') + def onchange_cash_flow_type(self): + print(self._origin.id, "self.cash_flow_type", self._origin.cash_flow_type) + + for rec in self.cash_flow_type: + print('rec', rec) + # update new record + rec.write({ + 'account_ids': [(4, self._origin.id)] + }) + + if self._origin.cash_flow_type.ids: + for rec in self._origin.cash_flow_type: + print('delete', rec.name) + # remove old record + rec.write({ + 'account_ids': [(3, self._origin.id)] + }) diff --git a/cash_flow_statement/reports/cash_flow_report.xml b/cash_flow_statement/reports/cash_flow_report.xml new file mode 100644 index 000000000..e73dc2f1a --- /dev/null +++ b/cash_flow_statement/reports/cash_flow_report.xml @@ -0,0 +1,121 @@ + + + + + diff --git a/cash_flow_statement/security/ir.model.access.csv b/cash_flow_statement/security/ir.model.access.csv new file mode 100644 index 000000000..1d95d510e --- /dev/null +++ b/cash_flow_statement/security/ir.model.access.csv @@ -0,0 +1,3 @@ +id,name,model_id:id,group_id:id,perm_read,perm_write,perm_create,perm_unlink +access_cash_flow_report,account.financial.html.report,model_account_financial_report,,1,1,1,1 + diff --git a/cash_flow_statement/static/description/banner.png b/cash_flow_statement/static/description/banner.png new file mode 100644 index 000000000..8d0a28517 Binary files /dev/null and b/cash_flow_statement/static/description/banner.png differ diff --git a/cash_flow_statement/static/description/icon.png b/cash_flow_statement/static/description/icon.png new file mode 100644 index 000000000..7a6734288 Binary files /dev/null and b/cash_flow_statement/static/description/icon.png differ diff --git a/cash_flow_statement/static/description/images/account_day_book.jpeg b/cash_flow_statement/static/description/images/account_day_book.jpeg new file mode 100644 index 000000000..07e6902f6 Binary files /dev/null and b/cash_flow_statement/static/description/images/account_day_book.jpeg differ diff --git a/cash_flow_statement/static/description/images/account_reports_xlsx.jpeg b/cash_flow_statement/static/description/images/account_reports_xlsx.jpeg new file mode 100644 index 000000000..b3ce5bdcc Binary files /dev/null and b/cash_flow_statement/static/description/images/account_reports_xlsx.jpeg differ diff --git a/cash_flow_statement/static/description/images/bank_book_dynamic_reports.png b/cash_flow_statement/static/description/images/bank_book_dynamic_reports.png new file mode 100644 index 000000000..d74daba97 Binary files /dev/null and b/cash_flow_statement/static/description/images/bank_book_dynamic_reports.png differ diff --git a/cash_flow_statement/static/description/images/cash_book_dynamic_reports.png b/cash_flow_statement/static/description/images/cash_book_dynamic_reports.png new file mode 100644 index 000000000..35bd4aee9 Binary files /dev/null and b/cash_flow_statement/static/description/images/cash_book_dynamic_reports.png differ diff --git a/cash_flow_statement/static/description/images/cash_flow_statements-1.png b/cash_flow_statement/static/description/images/cash_flow_statements-1.png new file mode 100644 index 000000000..0af402c84 Binary files /dev/null and b/cash_flow_statement/static/description/images/cash_flow_statements-1.png differ diff --git a/cash_flow_statement/static/description/images/cash_flow_statements-2.png b/cash_flow_statement/static/description/images/cash_flow_statements-2.png new file mode 100644 index 000000000..b04bf52ad Binary files /dev/null and b/cash_flow_statement/static/description/images/cash_flow_statements-2.png differ diff --git a/cash_flow_statement/static/description/images/cash_flow_statements-2.png~ b/cash_flow_statement/static/description/images/cash_flow_statements-2.png~ new file mode 100644 index 000000000..3fa7dfcb2 Binary files /dev/null and b/cash_flow_statement/static/description/images/cash_flow_statements-2.png~ differ diff --git a/cash_flow_statement/static/description/images/cash_flow_statements-3.png b/cash_flow_statement/static/description/images/cash_flow_statements-3.png new file mode 100644 index 000000000..ea4511d82 Binary files /dev/null and b/cash_flow_statement/static/description/images/cash_flow_statements-3.png differ diff --git a/cash_flow_statement/static/description/images/cash_flow_statements-3.png~ b/cash_flow_statement/static/description/images/cash_flow_statements-3.png~ new file mode 100644 index 000000000..ea2f31cbf Binary files /dev/null and b/cash_flow_statement/static/description/images/cash_flow_statements-3.png~ differ diff --git a/cash_flow_statement/static/description/images/cash_flow_statements-4.png b/cash_flow_statement/static/description/images/cash_flow_statements-4.png new file mode 100644 index 000000000..9959e2e80 Binary files /dev/null and b/cash_flow_statement/static/description/images/cash_flow_statements-4.png differ diff --git a/cash_flow_statement/static/description/images/cash_flow_statements-5.png b/cash_flow_statement/static/description/images/cash_flow_statements-5.png new file mode 100644 index 000000000..a48e2611e Binary files /dev/null and b/cash_flow_statement/static/description/images/cash_flow_statements-5.png differ diff --git a/cash_flow_statement/static/description/images/cash_flow_statements-6.png b/cash_flow_statement/static/description/images/cash_flow_statements-6.png new file mode 100644 index 000000000..1a1ae5dd6 Binary files /dev/null and b/cash_flow_statement/static/description/images/cash_flow_statements-6.png differ diff --git a/cash_flow_statement/static/description/images/cash_flow_statements.png b/cash_flow_statement/static/description/images/cash_flow_statements.png new file mode 100644 index 000000000..180046121 Binary files /dev/null and b/cash_flow_statement/static/description/images/cash_flow_statements.png differ diff --git a/cash_flow_statement/static/description/images/checked.png b/cash_flow_statement/static/description/images/checked.png new file mode 100644 index 000000000..578cedb80 Binary files /dev/null and b/cash_flow_statement/static/description/images/checked.png differ diff --git a/cash_flow_statement/static/description/images/cybrosys.png b/cash_flow_statement/static/description/images/cybrosys.png new file mode 100644 index 000000000..d76b5bafb Binary files /dev/null and b/cash_flow_statement/static/description/images/cybrosys.png differ diff --git a/cash_flow_statement/static/description/images/day_book_dynamic_report.jpeg b/cash_flow_statement/static/description/images/day_book_dynamic_report.jpeg new file mode 100644 index 000000000..2409df5bb Binary files /dev/null and b/cash_flow_statement/static/description/images/day_book_dynamic_report.jpeg differ diff --git a/cash_flow_statement/static/description/images/dynamic_reports_pdf.png b/cash_flow_statement/static/description/images/dynamic_reports_pdf.png new file mode 100644 index 000000000..16745e06c Binary files /dev/null and b/cash_flow_statement/static/description/images/dynamic_reports_pdf.png differ diff --git a/cash_flow_statement/static/description/images/pos_multivariant-2.png~ b/cash_flow_statement/static/description/images/pos_multivariant-2.png~ new file mode 100644 index 000000000..979476ecf Binary files /dev/null and b/cash_flow_statement/static/description/images/pos_multivariant-2.png~ differ diff --git a/cash_flow_statement/static/description/images/pos_multivariant-3.png~ b/cash_flow_statement/static/description/images/pos_multivariant-3.png~ new file mode 100644 index 000000000..6951ae5d2 Binary files /dev/null and b/cash_flow_statement/static/description/images/pos_multivariant-3.png~ differ diff --git a/cash_flow_statement/static/description/images/print_voucher_receipts-4.png~ b/cash_flow_statement/static/description/images/print_voucher_receipts-4.png~ new file mode 100644 index 000000000..266acc022 Binary files /dev/null and b/cash_flow_statement/static/description/images/print_voucher_receipts-4.png~ differ diff --git a/cash_flow_statement/static/description/index.html b/cash_flow_statement/static/description/index.html new file mode 100644 index 000000000..ded6530fa --- /dev/null +++ b/cash_flow_statement/static/description/index.html @@ -0,0 +1,391 @@ + + +
cybrosys-logo
+ +
+
+
+

Cash-Flow Statements

+

Print pdf reports of cash flow statements

+
+

Key Highlights

+
    +
  • checkCash-flow statements for Odoo12 community edition.
  • +
+
    +
  • checkShows the amount of cash in and cash out flow.
  • +
+
    +
  • checkCan set accounts for each cash flow types.
  • +
+
    +
  • checkSeparately views the credit and debit values of each accounts. +
  • +
+ +
+
+
+
+ + + + + + +
+
+
+ + + +
+
+ +

Overview

+
+

+ Currently in Odoo community edition there is no Cash-Flow Statements. A cash flow statement is a financial statement that provides aggregate data regarding all cash inflows a company receives from its ongoing operations and external investment sources, also includes all cash outflows that pay for business activities and investments during a given period. +

+
+ +
+ +

Cash-Flow Statements

+
+
    + +
  • + checkCash-flow statements for Odoo12 community edition.
  • +
  • + checkShows the amount of cash in and out flow. +
  • +
  • + checkCan set accounts for each cash flow types.
  • +
  • + checkSeparately views the credit and debit values of each accounts.
  • +
+
+ + + +
+ +
+

Screenshots

+
+
+
+ + + +
+
+
+
+ + + + + + + + + + + +
+ + + +
+
    + + +
+
+
+
+
+ + +
+

Suggested Products

+
+ +
+ + +
+

Our Service

+
+ +
+
+
+

Our Industries

+
+ +
+
+
+ +
+
+

Trading

+

Easily procure and sell your products.

+
+
+
+
+ +
+
+

Manufacturing

+

Plan, track and schedule your operations.

+
+
+
+
+ +
+
+

Restaurant

+

Run your bar or restaurant methodical.

+
+
+
+
+ +
+
+

POS

+

Easy configuring and convivial selling.

+
+
+
+
+ +
+
+

E-commerce & Website

+

Mobile friendly, awe-inspiring product pages.

+
+
+
+
+ +
+
+

Hotel Management

+

An all-inclusive hotel management application.

+
+
+
+
+ +
+
+

Education

+

A Collaborative platform for educational management.

+
+
+
+
+ +
+
+

Service Management

+

Keep track of services and invoice accordingly.

+
+
+
+
+ +
+ + + +
+
+
+

Need Any Help?

+
+ +

If you have anything to share with us based on your use of this module, please let us know. We are ready to offer our support.

+
+

Email us

+

odoo@cybrosys.com / info@cybrosys.com

+ +
+
+

Contact Us

+ www.cybrosys.com +
+
+ +
+
+ + +
+
+
+ + + + +
+
+ +
+ + + + + + + + +
+
+
+ + diff --git a/cash_flow_statement/views/account_configuration.xml b/cash_flow_statement/views/account_configuration.xml new file mode 100644 index 000000000..cc06d3d4b --- /dev/null +++ b/cash_flow_statement/views/account_configuration.xml @@ -0,0 +1,96 @@ + + + + + account.financial.report.form + account.financial.report + +
+ + + + + + + + + + + + + + + + + + +
+
+
+ + + account.financial.report.tree + account.financial.report + + + + + + + + + + + + account.financial.report.search + account.financial.report + + + + + + + + + + + + + + + Financial Reports + ir.actions.act_window + account.financial.report + form + tree,form + + + + + + + + +
+ + Cash Flow + account.account + + + + + + + + + +
+ diff --git a/cash_flow_statement/wizard/__init__.py b/cash_flow_statement/wizard/__init__.py new file mode 100644 index 000000000..d7b6d72e0 --- /dev/null +++ b/cash_flow_statement/wizard/__init__.py @@ -0,0 +1,23 @@ +# -*- coding: utf-8 -*- +############################################################################# +# +# Cybrosys Technologies Pvt. Ltd. +# +# Copyright (C) 2019-TODAY Cybrosys Technologies(). +# Author: Ijaz Ahammed, Varsha Vivek () +# +# You can modify it under the terms of the GNU AFFERO +# GENERAL PUBLIC LICENSE (AGPL v3), Version 3. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU AFFERO GENERAL PUBLIC LICENSE (AGPL v3) for more details. +# +# You should have received a copy of the GNU AFFERO GENERAL PUBLIC LICENSE +# (AGPL v3) along with this program. +# If not, see . +# +############################################################################# + +from . import account_report \ No newline at end of file diff --git a/cash_flow_statement/wizard/account_report.py b/cash_flow_statement/wizard/account_report.py new file mode 100644 index 000000000..6aa1e3d61 --- /dev/null +++ b/cash_flow_statement/wizard/account_report.py @@ -0,0 +1,72 @@ +# -*- coding: utf-8 -*- +############################################################################# +# +# Cybrosys Technologies Pvt. Ltd. +# +# Copyright (C) 2019-TODAY Cybrosys Technologies(). +# Author: Ijaz Ahammed, Varsha Vivek () +# +# You can modify it under the terms of the GNU AFFERO +# GENERAL PUBLIC LICENSE (AGPL v3), Version 3. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU AFFERO GENERAL PUBLIC LICENSE (AGPL v3) for more details. +# +# You should have received a copy of the GNU AFFERO GENERAL PUBLIC LICENSE +# (AGPL v3) along with this program. +# If not, see . +# +############################################################################# + +from odoo import api, fields, models + + +class AccountingReport(models.TransientModel): + _name = "accounting.report" + _inherit = "account.common.report" + _description = "Accounting Report" + + @api.model + def _get_account_report(self): + reports = [] + if self._context.get('active_id'): + menu = self.env['ir.ui.menu'].browse(self._context.get('active_id')).name + reports = self.env['account.financial.report'].search([('name', 'ilike', menu)]) + return reports and reports[0] or False + + enable_filter = fields.Boolean(string='Enable Comparison') + account_report_id = fields.Many2one('account.financial.report', string='Account Reports', required=True, default=_get_account_report) + label_filter = fields.Char(string='Column Label', help="This label will be displayed on report to show the balance" + " computed for the given comparison filter.") + filter_cmp = fields.Selection([('filter_no', 'No Filters'), ('filter_date', 'Date')], string='Filter by', required=True, default='filter_no') + date_from_cmp = fields.Date(string='Start Date') + date_to_cmp = fields.Date(string='End Date') + debit_credit = fields.Boolean(string='Display Debit/Credit Columns', help="This option allows you to get more details about the way your balances are computed. Because it is space consuming, we do not allow to use it while doing a comparison.") + + 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 '' + if data['form']['filter_cmp'] == 'filter_date': + result['date_from'] = data['form']['date_from_cmp'] + result['date_to'] = data['form']['date_to_cmp'] + result['strict_range'] = True + return result + + @api.multi + def check_report(self): + res = super(AccountingReport, self).check_report() + data = {} + data['form'] = self.read(['account_report_id', 'date_from_cmp', 'date_to_cmp', 'journal_ids', 'filter_cmp', 'target_move'])[0] + for field in ['account_report_id']: + if isinstance(data['form'][field], tuple): + data['form'][field] = data['form'][field][0] + comparison_context = self._build_comparison_context(data) + res['data']['form']['comparison_context'] = comparison_context + return res + + def _print_report(self, data): + data['form'].update(self.read(['date_from_cmp', 'debit_credit', 'date_to_cmp', 'filter_cmp', 'account_report_id', 'enable_filter', 'label_filter', 'target_move'])[0]) + return self.env.ref('cash_flow_statement.action_report_financial').report_action(self, data=data, config=False) diff --git a/print_voucher_receipts/README.rst b/print_voucher_receipts/README.rst new file mode 100644 index 000000000..feaf82323 --- /dev/null +++ b/print_voucher_receipts/README.rst @@ -0,0 +1,40 @@ +Payment/Receipt voucher print +============================= +* Used to print payment/receipt voucher. + +Installation +============ +- www.odoo.com/documentation/12.0/setup/install.html +- Install our custom addon + +License +------- +GNU AFFERO GENERAL PUBLIC LICENSE, Version 3 (AGPLv3) +(http://www.gnu.org/licenses/agpl.html) + +Company +------- +* 'Cybrosys Techno Solutions `__ + +Credits +------- +* Developer: + odoo v12 - Varsha Vivek + +Contacts +-------- +* Mail Contact : odoo@cybrosys.com + +Bug Tracker +----------- +Bugs are tracked on GitHub Issues. In case of trouble, please check there if your issue has already been reported. + +Maintainer +========== +This module is maintained by Cybrosys Technologies. + +For support and more information, please visit https://www.cybrosys.com + +Further information +=================== +HTML Description: ``__ diff --git a/print_voucher_receipts/__init__.py b/print_voucher_receipts/__init__.py new file mode 100644 index 000000000..64e375b4b --- /dev/null +++ b/print_voucher_receipts/__init__.py @@ -0,0 +1,23 @@ +# -*- coding: utf-8 -*- +############################################################################# +# +# Cybrosys Technologies Pvt. Ltd. +# +# Copyright (C) 2019-TODAY Cybrosys Technologies(). +# Author: Varsha Vivek (odoo@cybrosys.com) +# +# You can modify it under the terms of the GNU AFFERO +# GENERAL PUBLIC LICENSE (AGPL v3), Version 3. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU AFFERO GENERAL PUBLIC LICENSE (AGPL v3) for more details. +# +# You should have received a copy of the GNU AFFERO GENERAL PUBLIC LICENSE +# (AGPL v3) along with this program. +# If not, see . +# +############################################################################# + +from . import models diff --git a/print_voucher_receipts/__manifest__.py b/print_voucher_receipts/__manifest__.py new file mode 100644 index 000000000..069017005 --- /dev/null +++ b/print_voucher_receipts/__manifest__.py @@ -0,0 +1,42 @@ +# -*- coding: utf-8 -*- +############################################################################# +# +# Cybrosys Technologies Pvt. Ltd. +# +# Copyright (C) 2019-TODAY Cybrosys Technologies(). +# Author: Varsha Vivek (odoo@cybrosys.com) +# +# You can modify it under the terms of the GNU AFFERO +# GENERAL PUBLIC LICENSE (AGPL v3), Version 3. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU AFFERO GENERAL PUBLIC LICENSE (AGPL v3) for more details. +# +# You should have received a copy of the GNU AFFERO GENERAL PUBLIC LICENSE +# (AGPL v3) along with this program. +# If not, see . +# +############################################################################# + +{ + 'name': 'Print Voucher Receipts', + 'version': '12.0.1.0.0', + 'summary': """Print receipts in account voucher""", + 'description': """Print receipts in account voucher""", + 'author': "Cybrosys Techno Solutions", + 'company': 'Cybrosys Techno Solutions', + 'maintaner': 'Cybrosys Techno Solutions', + 'website': "https://www.cybrosys.com", + 'category': 'Accounting', + 'depends': ['base', 'account_voucher'], + 'data': ['views/template.xml', + 'views/account_voucher_print.xml'], + 'images': ['static/description/banner.png'], + 'license': 'AGPL-3', + 'installable': True, + 'application': False, + 'auto_install': False, +} + diff --git a/print_voucher_receipts/doc/RELEASE_NOTES.md b/print_voucher_receipts/doc/RELEASE_NOTES.md new file mode 100644 index 000000000..abbea10e3 --- /dev/null +++ b/print_voucher_receipts/doc/RELEASE_NOTES.md @@ -0,0 +1,6 @@ +## Module + +#### 29.08.2019 +#### Version 12.0.1.0.0 +##### ADD +- Initial commit for print_voucher_receipts diff --git a/print_voucher_receipts/models/__init__.py b/print_voucher_receipts/models/__init__.py new file mode 100644 index 000000000..50ec3e13d --- /dev/null +++ b/print_voucher_receipts/models/__init__.py @@ -0,0 +1,23 @@ +# -*- coding: utf-8 -*- +############################################################################# +# +# Cybrosys Technologies Pvt. Ltd. +# +# Copyright (C) 2019-TODAY Cybrosys Technologies(). +# Author: Varsha Vivek (odoo@cybrosys.com) +# +# You can modify it under the terms of the GNU AFFERO +# GENERAL PUBLIC LICENSE (AGPL v3), Version 3. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU AFFERO GENERAL PUBLIC LICENSE (AGPL v3) for more details. +# +# You should have received a copy of the GNU AFFERO GENERAL PUBLIC LICENSE +# (AGPL v3) along with this program. +# If not, see . +# +############################################################################# + +from . import account_voucher_print diff --git a/print_voucher_receipts/models/account_voucher_print.py b/print_voucher_receipts/models/account_voucher_print.py new file mode 100644 index 000000000..d7c5b5d22 --- /dev/null +++ b/print_voucher_receipts/models/account_voucher_print.py @@ -0,0 +1,56 @@ +# -*- coding: utf-8 -*- +############################################################################# +# +# Cybrosys Technologies Pvt. Ltd. +# +# Copyright (C) 2019-TODAY Cybrosys Technologies(). +# Author: Varsha Vivek (odoo@cybrosys.com) +# +# You can modify it under the terms of the GNU AFFERO +# GENERAL PUBLIC LICENSE (AGPL v3), Version 3. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU AFFERO GENERAL PUBLIC LICENSE (AGPL v3) for more details. +# +# You should have received a copy of the GNU AFFERO GENERAL PUBLIC LICENSE +# (AGPL v3) along with this program. +# If not, see . +# +############################################################################# + +from odoo import api, models, fields + + +class AccountVoucher(models.Model): + """Inherit account.voucher model and enable the print option""" + _inherit = "account.voucher" + + @api.depends('amount') + def _compute_amount_total_words(self): + for receipt in self: + receipt.amount_total_words = receipt.currency_id.amount_to_text(receipt.amount) + + amount_total_words = fields.Char("Total (In Words)", compute="_compute_amount_total_words") + + @api.multi + def print_report(self): + """Method to print report""" + return self.env.ref( + 'print_voucher_receipts.action_print_receipt').report_action(self, data='') + + +class VoucherReceiptPrint(models.AbstractModel): + """Class for print the Qweb report""" + _name = 'report.print_voucher_receipts.print_voucher_receipt' + + @api.model + def _get_report_values(self, docids, data): + self.model = self.env.context.get('active_model') + docs = self.env.context.get('active_ids') + if docs == None: + docs = docids + return { + 'data': self.env['account.voucher'].search([('id', 'in', docs)]) + } diff --git a/print_voucher_receipts/static/description/banner.png b/print_voucher_receipts/static/description/banner.png new file mode 100644 index 000000000..f9e847d53 Binary files /dev/null and b/print_voucher_receipts/static/description/banner.png differ diff --git a/print_voucher_receipts/static/description/icon.png b/print_voucher_receipts/static/description/icon.png new file mode 100644 index 000000000..b9a96b37d Binary files /dev/null and b/print_voucher_receipts/static/description/icon.png differ diff --git a/print_voucher_receipts/static/description/icon.png~ b/print_voucher_receipts/static/description/icon.png~ new file mode 100644 index 000000000..5c1d3b967 Binary files /dev/null and b/print_voucher_receipts/static/description/icon.png~ differ diff --git a/print_voucher_receipts/static/description/images/account_day_book.jpeg b/print_voucher_receipts/static/description/images/account_day_book.jpeg new file mode 100644 index 000000000..07e6902f6 Binary files /dev/null and b/print_voucher_receipts/static/description/images/account_day_book.jpeg differ diff --git a/print_voucher_receipts/static/description/images/account_reports_xlsx.jpeg b/print_voucher_receipts/static/description/images/account_reports_xlsx.jpeg new file mode 100644 index 000000000..b3ce5bdcc Binary files /dev/null and b/print_voucher_receipts/static/description/images/account_reports_xlsx.jpeg differ diff --git a/print_voucher_receipts/static/description/images/bank_book_dynamic_reports.png b/print_voucher_receipts/static/description/images/bank_book_dynamic_reports.png new file mode 100644 index 000000000..d74daba97 Binary files /dev/null and b/print_voucher_receipts/static/description/images/bank_book_dynamic_reports.png differ diff --git a/print_voucher_receipts/static/description/images/cash_book_dynamic_reports.png b/print_voucher_receipts/static/description/images/cash_book_dynamic_reports.png new file mode 100644 index 000000000..35bd4aee9 Binary files /dev/null and b/print_voucher_receipts/static/description/images/cash_book_dynamic_reports.png differ diff --git a/print_voucher_receipts/static/description/images/checked.png b/print_voucher_receipts/static/description/images/checked.png new file mode 100644 index 000000000..578cedb80 Binary files /dev/null and b/print_voucher_receipts/static/description/images/checked.png differ diff --git a/print_voucher_receipts/static/description/images/cybrosys.png b/print_voucher_receipts/static/description/images/cybrosys.png new file mode 100644 index 000000000..d76b5bafb Binary files /dev/null and b/print_voucher_receipts/static/description/images/cybrosys.png differ diff --git a/print_voucher_receipts/static/description/images/day_book_dynamic_report.jpeg b/print_voucher_receipts/static/description/images/day_book_dynamic_report.jpeg new file mode 100644 index 000000000..2409df5bb Binary files /dev/null and b/print_voucher_receipts/static/description/images/day_book_dynamic_report.jpeg differ diff --git a/print_voucher_receipts/static/description/images/dynamic_reports_pdf.png b/print_voucher_receipts/static/description/images/dynamic_reports_pdf.png new file mode 100644 index 000000000..16745e06c Binary files /dev/null and b/print_voucher_receipts/static/description/images/dynamic_reports_pdf.png differ diff --git a/print_voucher_receipts/static/description/images/pos_multivariant-2.png~ b/print_voucher_receipts/static/description/images/pos_multivariant-2.png~ new file mode 100644 index 000000000..979476ecf Binary files /dev/null and b/print_voucher_receipts/static/description/images/pos_multivariant-2.png~ differ diff --git a/print_voucher_receipts/static/description/images/pos_multivariant-3.png~ b/print_voucher_receipts/static/description/images/pos_multivariant-3.png~ new file mode 100644 index 000000000..6951ae5d2 Binary files /dev/null and b/print_voucher_receipts/static/description/images/pos_multivariant-3.png~ differ diff --git a/print_voucher_receipts/static/description/images/print_voucher_receipts-1.png b/print_voucher_receipts/static/description/images/print_voucher_receipts-1.png new file mode 100644 index 000000000..de9b8cb03 Binary files /dev/null and b/print_voucher_receipts/static/description/images/print_voucher_receipts-1.png differ diff --git a/print_voucher_receipts/static/description/images/print_voucher_receipts-2.png b/print_voucher_receipts/static/description/images/print_voucher_receipts-2.png new file mode 100644 index 000000000..dc37b455f Binary files /dev/null and b/print_voucher_receipts/static/description/images/print_voucher_receipts-2.png differ diff --git a/print_voucher_receipts/static/description/images/print_voucher_receipts-3.png b/print_voucher_receipts/static/description/images/print_voucher_receipts-3.png new file mode 100644 index 000000000..fe3845cec Binary files /dev/null and b/print_voucher_receipts/static/description/images/print_voucher_receipts-3.png differ diff --git a/print_voucher_receipts/static/description/images/print_voucher_receipts-4.png b/print_voucher_receipts/static/description/images/print_voucher_receipts-4.png new file mode 100644 index 000000000..7e6d88913 Binary files /dev/null and b/print_voucher_receipts/static/description/images/print_voucher_receipts-4.png differ diff --git a/print_voucher_receipts/static/description/images/print_voucher_receipts-4.png~ b/print_voucher_receipts/static/description/images/print_voucher_receipts-4.png~ new file mode 100644 index 000000000..266acc022 Binary files /dev/null and b/print_voucher_receipts/static/description/images/print_voucher_receipts-4.png~ differ diff --git a/print_voucher_receipts/static/description/images/print_voucher_receipts-5.png b/print_voucher_receipts/static/description/images/print_voucher_receipts-5.png new file mode 100644 index 000000000..8c99a37a0 Binary files /dev/null and b/print_voucher_receipts/static/description/images/print_voucher_receipts-5.png differ diff --git a/print_voucher_receipts/static/description/images/print_voucher_receipts-6.png b/print_voucher_receipts/static/description/images/print_voucher_receipts-6.png new file mode 100644 index 000000000..67f5d6f57 Binary files /dev/null and b/print_voucher_receipts/static/description/images/print_voucher_receipts-6.png differ diff --git a/print_voucher_receipts/static/description/images/print_voucher_receipts.png b/print_voucher_receipts/static/description/images/print_voucher_receipts.png new file mode 100644 index 000000000..f7fc17c3d Binary files /dev/null and b/print_voucher_receipts/static/description/images/print_voucher_receipts.png differ diff --git a/print_voucher_receipts/static/description/index.html b/print_voucher_receipts/static/description/index.html new file mode 100644 index 000000000..e3347d110 --- /dev/null +++ b/print_voucher_receipts/static/description/index.html @@ -0,0 +1,376 @@ + + +
cybrosys-logo
+ +
+
+
+

Payment/Receipt Voucher Print

+

Print voucher receipts from invoicing

+
+

Key Highlights

+
    +
  • checkPayment/Receipt voucher print for Odoo12 community edition.
  • +
  • checkPrint customer payment voucher receipts.
  • +
  • checkPrint vendor voucher receipts.
  • +
+ +
+
+
+
+ + + + + + +
+
+
+ + + +
+
+ +

Overview

+
+

+ Payment/Receipt voucher print module helps with printing of voucher receipts. Currently there is no option for printing payments/receipts voucher. This module helps the user to print the vouchers from Odoo invoicing.

+
+ +
+ +

Payment/Receipt Voucher Print

+
+
    +
  • + checkPayment/Receipt voucher print for Odoo12 community edition.
  • +
  • + checkPrint customer payment voucher receipts.
  • + +
  • + checkPrint vendor voucher receipts.
  • +
+
+ + + +
+ +
+

Screenshots

+
+
+
+ + + +
+
+
+
+ + + + + + + + + + + + + +
+ + +
+
    + + +
+
+
+
+
+ + +
+

Suggested Products

+
+ +
+ + +
+

Our Service

+
+ +
+
+
+

Our Industries

+
+ +
+
+
+ +
+
+

Trading

+

Easily procure and sell your products.

+
+
+
+
+ +
+
+

Manufacturing

+

Plan, track and schedule your operations.

+
+
+
+
+ +
+
+

Restaurant

+

Run your bar or restaurant methodical.

+
+
+
+
+ +
+
+

POS

+

Easy configuring and convivial selling.

+
+
+
+
+ +
+
+

E-commerce & Website

+

Mobile friendly, awe-inspiring product pages.

+
+
+
+
+ +
+
+

Hotel Management

+

An all-inclusive hotel management application.

+
+
+
+
+ +
+
+

Education

+

A Collaborative platform for educational management.

+
+
+
+
+ +
+
+

Service Management

+

Keep track of services and invoice accordingly.

+
+
+
+
+ +
+ + + +
+
+
+

Need Any Help?

+
+ +

If you have anything to share with us based on your use of this module, please let us know. We are ready to offer our support.

+
+

Email us

+

odoo@cybrosys.com / info@cybrosys.com

+ +
+
+

Contact Us

+ www.cybrosys.com +
+
+ +
+
+ + +
+
+
+ + + + +
+
+ +
+ + + + + + + + +
+
+
+ + diff --git a/print_voucher_receipts/static/description/pos_book_order-17.png~ b/print_voucher_receipts/static/description/pos_book_order-17.png~ new file mode 100644 index 000000000..07f009cae Binary files /dev/null and b/print_voucher_receipts/static/description/pos_book_order-17.png~ differ diff --git a/print_voucher_receipts/views/account_voucher_print.xml b/print_voucher_receipts/views/account_voucher_print.xml new file mode 100644 index 000000000..f365e8ac2 --- /dev/null +++ b/print_voucher_receipts/views/account_voucher_print.xml @@ -0,0 +1,13 @@ + + + + + + diff --git a/print_voucher_receipts/views/template.xml b/print_voucher_receipts/views/template.xml new file mode 100644 index 000000000..1d65d2719 --- /dev/null +++ b/print_voucher_receipts/views/template.xml @@ -0,0 +1,152 @@ + + + + \ No newline at end of file diff --git a/product_catalogue/README.rst b/product_catalogue/README.rst new file mode 100644 index 000000000..829c22917 --- /dev/null +++ b/product_catalogue/README.rst @@ -0,0 +1,41 @@ +Product Catalogue +================= +* Enables the option for printing the catalogue for single/multi products +* Print Catalogue for Single product from the E-commerce website + +Installation +============ +- www.odoo.com/documentation/12.0/setup/install.html +- Install our custom addon + +License +------- +GNU AFFERO GENERAL PUBLIC LICENSE, Version 3 (AGPLv3) +(http://www.gnu.org/licenses/agpl.html) + +Company +------- +* `Cybrosys Techno Solutions `__ + +Credits +------- +* Developer: + Sayooj A O + +Contacts +-------- +* Mail Contact : odoo@cybrosys.com + +Bug Tracker +----------- +Bugs are tracked on GitHub Issues. In case of trouble, please check there if your issue has already been reported. + +Maintainer +========== +This module is maintained by Cybrosys Technologies. + +For support and more information, please visit https://www.cybrosys.com + +Further information +=================== +HTML Description: ``__ diff --git a/product_catalogue/__init__.py b/product_catalogue/__init__.py new file mode 100644 index 000000000..009bb5581 --- /dev/null +++ b/product_catalogue/__init__.py @@ -0,0 +1,24 @@ +# -*- coding: utf-8 -*- +############################################################################# +# +# Cybrosys Technologies Pvt. Ltd. +# +# Copyright (C) 2019-TODAY Cybrosys Technologies(). +# Author: Sayooj A O() +# +# You can modify it under the terms of the GNU AFFERO +# GENERAL PUBLIC LICENSE (AGPL v3), Version 3. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU AFFERO GENERAL PUBLIC LICENSE (AGPL v3) for more details. +# +# You should have received a copy of the GNU AFFERO GENERAL PUBLIC LICENSE +# (AGPL v3) along with this program. +# If not, see . +# +############################################################################# +from . import report +from . import controllers + diff --git a/product_catalogue/__manifest__.py b/product_catalogue/__manifest__.py new file mode 100644 index 000000000..9cb0a9b35 --- /dev/null +++ b/product_catalogue/__manifest__.py @@ -0,0 +1,48 @@ +# -*- coding: utf-8 -*- +############################################################################# +# +# Cybrosys Technologies Pvt. Ltd. +# +# Copyright (C) 2019-TODAY Cybrosys Technologies(). +# Author: Sayooj A O() +# +# You can modify it under the terms of the GNU AFFERO +# GENERAL PUBLIC LICENSE (AGPL v3), Version 3. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU AFFERO GENERAL PUBLIC LICENSE (AGPL v3) for more details. +# +# You should have received a copy of the GNU AFFERO GENERAL PUBLIC LICENSE +# (AGPL v3) along with this program. +# If not, see . +# +############################################################################# +{ + 'name': "Product Catalogue", + 'version': '12.0.1.0.0', + 'summary': """This module helps to print the catalogue of + the single/multi products from the backend and single product + from the E-commerce website + including details like images and specifications""", + 'description': """This module helps to print the catalogue of + the single/multi products from the backend and single product + from the E-commerce website + including details like images and specifications""", + 'category': 'Inventory', + 'author': 'Cybrosys Techno Solutions', + 'company': 'Cybrosys Techno Solutions', + 'maintainer': 'Cybrosys Techno Solutions', + 'website': "https://www.cybrosys.com", + 'depends': ['base', 'stock', 'website_sale'], + 'data': [ + 'views/report_button_website.xml', + 'report/product_catalog_report.xml', + 'report/product_catalog_template.xml', + ], + 'images': ['static/description/banner.png'], + 'license': "AGPL-3", + 'installable': True, + 'application': False, +} diff --git a/product_catalogue/controllers/__init__.py b/product_catalogue/controllers/__init__.py new file mode 100644 index 000000000..8b02407b5 --- /dev/null +++ b/product_catalogue/controllers/__init__.py @@ -0,0 +1,22 @@ +# -*- coding: utf-8 -*- +############################################################################# +# +# Cybrosys Technologies Pvt. Ltd. +# +# Copyright (C) 2019-TODAY Cybrosys Technologies(). +# Author: Sayooj A O() +# +# You can modify it under the terms of the GNU AFFERO +# GENERAL PUBLIC LICENSE (AGPL v3), Version 3. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU AFFERO GENERAL PUBLIC LICENSE (AGPL v3) for more details. +# +# You should have received a copy of the GNU AFFERO GENERAL PUBLIC LICENSE +# (AGPL v3) along with this program. +# If not, see . +# +############################################################################# +from . import main diff --git a/product_catalogue/controllers/main.py b/product_catalogue/controllers/main.py new file mode 100644 index 000000000..8339e29a7 --- /dev/null +++ b/product_catalogue/controllers/main.py @@ -0,0 +1,41 @@ +# -*- coding: utf-8 -*- +############################################################################# +# +# Cybrosys Technologies Pvt. Ltd. +# +# Copyright (C) 2019-TODAY Cybrosys Technologies(). +# Author: Sayooj A O() +# +# You can modify it under the terms of the GNU AFFERO +# GENERAL PUBLIC LICENSE (AGPL v3), Version 3. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU AFFERO GENERAL PUBLIC LICENSE (AGPL v3) for more details. +# +# You should have received a copy of the GNU AFFERO GENERAL PUBLIC LICENSE +# (AGPL v3) along with this program. +# If not, see . +# +############################################################################# + +from odoo import http +from odoo.http import request + + +class CataloguePrint(http.Controller): + """This class includes the function which fetch the details + about the corresponding product and print catalogue in + PDF format""" + + @http.route(['/report/pdf/catalogue_download'], type='http', auth='public') + def download_catalogue(self, product_id): + """In this function we are calling the report template + of the corresponding product and + downloads the catalogue in pdf format""" + pdf, _ = request.env.ref('product_catalogue.action_report_product_catalog')\ + .sudo().render_qweb_pdf([int(product_id)]) + pdfhttpheaders = [('Content-Type', 'application/pdf'), ('Content-Length', len(pdf)), + ('Content-Disposition', 'catalogue' + '.pdf;')] + return request.make_response(pdf, headers=pdfhttpheaders) diff --git a/product_catalogue/doc/RELEASE_NOTES.md b/product_catalogue/doc/RELEASE_NOTES.md new file mode 100644 index 000000000..5e43a2150 --- /dev/null +++ b/product_catalogue/doc/RELEASE_NOTES.md @@ -0,0 +1,6 @@ +## Module + +#### 26.08.2019 +#### Version 12.0.1.0.0 +##### ADD +- Initial commit for product_catalogue diff --git a/product_catalogue/report/__init__.py b/product_catalogue/report/__init__.py new file mode 100644 index 000000000..32f24acbc --- /dev/null +++ b/product_catalogue/report/__init__.py @@ -0,0 +1,22 @@ +# -*- coding: utf-8 -*- +############################################################################# +# +# Cybrosys Technologies Pvt. Ltd. +# +# Copyright (C) 2019-TODAY Cybrosys Technologies(). +# Author: Sayooj A O() +# +# You can modify it under the terms of the GNU AFFERO +# GENERAL PUBLIC LICENSE (AGPL v3), Version 3. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU AFFERO GENERAL PUBLIC LICENSE (AGPL v3) for more details. +# +# You should have received a copy of the GNU AFFERO GENERAL PUBLIC LICENSE +# (AGPL v3) along with this program. +# If not, see . +# +############################################################################# +from . import product_catalog diff --git a/product_catalogue/report/product_catalog.py b/product_catalogue/report/product_catalog.py new file mode 100644 index 000000000..6b752d990 --- /dev/null +++ b/product_catalogue/report/product_catalog.py @@ -0,0 +1,44 @@ +# -*- coding: utf-8 -*- +############################################################################# +# +# Cybrosys Technologies Pvt. Ltd. +# +# Copyright (C) 2019-TODAY Cybrosys Technologies(). +# Author: Sayooj A O() +# +# You can modify it under the terms of the GNU AFFERO +# GENERAL PUBLIC LICENSE (AGPL v3), Version 3. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU AFFERO GENERAL PUBLIC LICENSE (AGPL v3) for more details. +# +# You should have received a copy of the GNU AFFERO GENERAL PUBLIC LICENSE +# (AGPL v3) along with this program. +# If not, see . +# +############################################################################# + +from odoo import api, models + + +class ProductCatalogueReport(models.AbstractModel): + """ Model to contain the information related to printing the information about + the products""" + + _name = "report.product_catalogue.report_product_catalog" + + @api.model + def _get_report_values(self, docids, data=None): + """Get the report values. + :param : model + :param : docids + :param : data + :return : data + :return : Product template records""" + product = self.env['product.template'].browse(docids) + return { + 'data': data, + 'docs': product + } diff --git a/product_catalogue/report/product_catalog_report.xml b/product_catalogue/report/product_catalog_report.xml new file mode 100644 index 000000000..61d4695ec --- /dev/null +++ b/product_catalogue/report/product_catalog_report.xml @@ -0,0 +1,11 @@ + + + + \ No newline at end of file diff --git a/product_catalogue/report/product_catalog_template.xml b/product_catalogue/report/product_catalog_template.xml new file mode 100644 index 000000000..f668a9aaa --- /dev/null +++ b/product_catalogue/report/product_catalog_template.xml @@ -0,0 +1,126 @@ + + + + + + + \ No newline at end of file diff --git a/product_catalogue/static/description/Product_catalogue.gif b/product_catalogue/static/description/Product_catalogue.gif new file mode 100644 index 000000000..42770fe79 Binary files /dev/null and b/product_catalogue/static/description/Product_catalogue.gif differ diff --git a/product_catalogue/static/description/banner.png b/product_catalogue/static/description/banner.png new file mode 100644 index 000000000..749bc47f9 Binary files /dev/null and b/product_catalogue/static/description/banner.png differ diff --git a/product_catalogue/static/description/checked.png b/product_catalogue/static/description/checked.png new file mode 100644 index 000000000..578cedb80 Binary files /dev/null and b/product_catalogue/static/description/checked.png differ diff --git a/product_catalogue/static/description/cybrosys.png b/product_catalogue/static/description/cybrosys.png new file mode 100644 index 000000000..d76b5bafb Binary files /dev/null and b/product_catalogue/static/description/cybrosys.png differ diff --git a/product_catalogue/static/description/icon.png b/product_catalogue/static/description/icon.png new file mode 100644 index 000000000..df2fea217 Binary files /dev/null and b/product_catalogue/static/description/icon.png differ diff --git a/product_catalogue/static/description/index.html b/product_catalogue/static/description/index.html new file mode 100644 index 000000000..630f6b625 --- /dev/null +++ b/product_catalogue/static/description/index.html @@ -0,0 +1,378 @@ + + +
cybrosys-logo
+ +
+
+
+

Product Catalogue

+

Catalogue report for products.

+
+

Key Highlights

+
    +
  • check Enables the option to print single/multi product catalogue.
  • +
+
+
+
+
+ + + + + + +
+
+
+ + + +
+
+ +

Overview

+
+

+ The application lets the vendor to quickly print the catalogue of a single/multi product.

+
+ +
+ +

Product Catalogue

+
+
    + +
  • + checkAvailable in Odoo 12.0 community edition.
  • + +
  • + checkOption to print the catalogue of single/multi products.
  • +
+
+ + + +
+ +
+

Screenshots

+
+
+
+ + +
+ +
+ +
+
+ + + + +
+ +

Video

+
+

Product Catalogue

+ + +
+ Cybrosys Cover Video +
+ +
+
+ + + +
+
    + + +
+
+ + + + + +
+

Suggested Products

+
+ +
+ + +
+

Our Service

+
+ +
+
+
+

Our Industries

+
+ +
+
+
+ +
+
+

Trading

+

Easily procure and sell your products.

+
+
+
+
+ +
+
+

Manufacturing

+

Plan, track and schedule your operations.

+
+
+
+
+ +
+
+

Restaurant

+

Run your bar or restaurant methodical.

+
+
+
+
+ +
+
+

POS

+

Easy configuring and convivial selling.

+
+
+
+
+ +
+
+

E-commerce & Website

+

Mobile friendly, awe-inspiring product pages.

+
+
+
+
+ +
+
+

Hotel Management

+

An all-inclusive hotel management application.

+
+
+
+
+ +
+
+

Education

+

A Collaborative platform for educational management.

+
+
+
+
+ +
+
+

Service Management

+

Keep track of services and invoice accordingly.

+
+
+
+
+ +
+ + + +
+
+
+

Need Any Help?

+
+ +

If you have anything to share with us based on your use of this module, please let us know. We are ready to offer our support.

+
+

Email us

+

odoo@cybrosys.com / info@cybrosys.com

+ +
+
+

Contact Us

+ www.cybrosys.com +
+
+ +
+
+ + +
+
+
+ + + + +
+
+ +
+ + + + + + + + +
+
+
+ + diff --git a/product_catalogue/static/description/inventory_report.png b/product_catalogue/static/description/inventory_report.png new file mode 100644 index 000000000..3a9e7ef9d Binary files /dev/null and b/product_catalogue/static/description/inventory_report.png differ diff --git a/product_catalogue/static/description/inventory_valuation.png b/product_catalogue/static/description/inventory_valuation.png new file mode 100644 index 000000000..8946ee4cc Binary files /dev/null and b/product_catalogue/static/description/inventory_valuation.png differ diff --git a/product_catalogue/static/description/lot_serial_expiry.png b/product_catalogue/static/description/lot_serial_expiry.png new file mode 100644 index 000000000..a039607d3 Binary files /dev/null and b/product_catalogue/static/description/lot_serial_expiry.png differ diff --git a/product_catalogue/static/description/product-catalog-1.png b/product_catalogue/static/description/product-catalog-1.png new file mode 100644 index 000000000..2f47dae0d Binary files /dev/null and b/product_catalogue/static/description/product-catalog-1.png differ diff --git a/product_catalogue/static/description/product-catalog-2.png b/product_catalogue/static/description/product-catalog-2.png new file mode 100644 index 000000000..5f23726fd Binary files /dev/null and b/product_catalogue/static/description/product-catalog-2.png differ diff --git a/product_catalogue/static/description/product-catalog-3.png b/product_catalogue/static/description/product-catalog-3.png new file mode 100644 index 000000000..b8e65bd2c Binary files /dev/null and b/product_catalogue/static/description/product-catalog-3.png differ diff --git a/product_catalogue/static/description/product-catalog-4.png b/product_catalogue/static/description/product-catalog-4.png new file mode 100644 index 000000000..0e49a92d0 Binary files /dev/null and b/product_catalogue/static/description/product-catalog-4.png differ diff --git a/product_catalogue/static/description/product-catalog-5.png b/product_catalogue/static/description/product-catalog-5.png new file mode 100644 index 000000000..544035e8e Binary files /dev/null and b/product_catalogue/static/description/product-catalog-5.png differ diff --git a/product_catalogue/static/description/product-catalog-6.png b/product_catalogue/static/description/product-catalog-6.png new file mode 100644 index 000000000..e4ff96a1c Binary files /dev/null and b/product_catalogue/static/description/product-catalog-6.png differ diff --git a/product_catalogue/static/description/product-catalog-video.png b/product_catalogue/static/description/product-catalog-video.png new file mode 100644 index 000000000..367e3085f Binary files /dev/null and b/product_catalogue/static/description/product-catalog-video.png differ diff --git a/product_catalogue/static/description/remove_orders.png b/product_catalogue/static/description/remove_orders.png new file mode 100644 index 000000000..8096e2708 Binary files /dev/null and b/product_catalogue/static/description/remove_orders.png differ diff --git a/product_catalogue/static/description/scrap_report.png b/product_catalogue/static/description/scrap_report.png new file mode 100644 index 000000000..ffcdb579b Binary files /dev/null and b/product_catalogue/static/description/scrap_report.png differ diff --git a/product_catalogue/static/description/stock_ageing.png b/product_catalogue/static/description/stock_ageing.png new file mode 100644 index 000000000..92effb57b Binary files /dev/null and b/product_catalogue/static/description/stock_ageing.png differ diff --git a/product_catalogue/static/description/stock_move.png b/product_catalogue/static/description/stock_move.png new file mode 100644 index 000000000..c44db3e5d Binary files /dev/null and b/product_catalogue/static/description/stock_move.png differ diff --git a/product_catalogue/views/report_button_website.xml b/product_catalogue/views/report_button_website.xml new file mode 100644 index 000000000..ed1ebb15e --- /dev/null +++ b/product_catalogue/views/report_button_website.xml @@ -0,0 +1,18 @@ + + + + + + \ No newline at end of file