diff --git a/account_move_budget/README.rst b/account_move_budget/README.rst new file mode 100644 index 000000000..4eb30b437 --- /dev/null +++ b/account_move_budget/README.rst @@ -0,0 +1,91 @@ +=================== +Account Move Budget +=================== + +.. !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! + !! This file is generated by oca-gen-addon-readme !! + !! changes will be overwritten. !! + !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! + +.. |badge1| image:: https://img.shields.io/badge/maturity-Beta-yellow.png + :target: https://odoo-community.org/page/development-status + :alt: Beta +.. |badge2| image:: https://img.shields.io/badge/licence-AGPL--3-blue.png + :target: http://www.gnu.org/licenses/agpl-3.0-standalone.html + :alt: License: AGPL-3 +.. |badge3| image:: https://img.shields.io/badge/github-OCA%2Faccount--financial--tools-lightgray.png?logo=github + :target: https://github.com/OCA/account-financial-tools/tree/13.0/account_move_budget + :alt: OCA/account-financial-tools +.. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png + :target: https://translation.odoo-community.org/projects/account-financial-tools-13-0/account-financial-tools-13-0-account_move_budget + :alt: Translate me on Weblate +.. |badge5| image:: https://img.shields.io/badge/runbot-Try%20me-875A7B.png + :target: https://runbot.odoo-community.org/runbot/92/13.0 + :alt: Try me on Runbot + +|badge1| |badge2| |badge3| |badge4| |badge5| + +This module allows to define accounting budgets. + +These budgets can then be used in MIS Builder reports, as an alternate +source. + +The difference between the MIS Builder Budget and this module is that +this module defines budgets irrespective of the MIS Builder Template. The +budget is thus agnostic of the reporting format. + +For example, the budgeted data can be used in a general Profit & Loss report +and at the same time can be used in a department or project expenses report. + +**Table of contents** + +.. contents:: + :local: + +Usage +===== + +In order to set up the budget items go to +*Invoicing / Accounting / Miscellaneous / Account Move Budgets*. + +Bug Tracker +=========== + +Bugs are tracked on `GitHub Issues `_. +In case of trouble, please check there if your issue has already been reported. +If you spotted it first, help us smashing it by providing a detailed and welcomed +`feedback `_. + +Do not contact contributors directly about support or help with technical issues. + +Credits +======= + +Authors +~~~~~~~ + +* Eficent + +Contributors +~~~~~~~~~~~~ + +* ForgeFlow, S.L. (https://www.eficent.com) + * Hector Villarreal + * Jordi Ballester Alomar + +Maintainers +~~~~~~~~~~~ + +This module is maintained by the OCA. + +.. image:: https://odoo-community.org/logo.png + :alt: Odoo Community Association + :target: https://odoo-community.org + +OCA, or the Odoo Community Association, is a nonprofit organization whose +mission is to support the collaborative development of Odoo features and +promote its widespread use. + +This module is part of the `OCA/account-financial-tools `_ project on GitHub. + +You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute. diff --git a/account_move_budget/__init__.py b/account_move_budget/__init__.py new file mode 100644 index 000000000..0650744f6 --- /dev/null +++ b/account_move_budget/__init__.py @@ -0,0 +1 @@ +from . import models diff --git a/account_move_budget/__manifest__.py b/account_move_budget/__manifest__.py new file mode 100644 index 000000000..88d0bb5df --- /dev/null +++ b/account_move_budget/__manifest__.py @@ -0,0 +1,20 @@ +# Copyright 2019 ForgeFlow S.L. (http://www.forgeflow.com) +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl). + +{ + "name": "Account Move Budget", + "summary": "Create Accounting Budgets", + "version": "13.0.1.0.0", + "category": "Accounting & Finance", + "website": "https://github.com/OCA/account-financial-tools", + "author": "ForgeFlow, " "Odoo Community Association (OCA)", + "license": "AGPL-3", + "application": False, + "installable": True, + "depends": ["account", "date_range"], + "data": [ + "security/ir.model.access.csv", + "views/account_move_budget_line_views.xml", + "views/account_move_budget_views.xml", + ], +} diff --git a/account_move_budget/i18n/account_move_budget.pot b/account_move_budget/i18n/account_move_budget.pot new file mode 100644 index 000000000..2d85f238d --- /dev/null +++ b/account_move_budget/i18n/account_move_budget.pot @@ -0,0 +1,385 @@ +# Translation of Odoo Server. +# This file contains the translation of the following modules: +# * account_move_budget +# +msgid "" +msgstr "" +"Project-Id-Version: Odoo Server 12.0\n" +"Report-Msgid-Bugs-To: \n" +"Last-Translator: <>\n" +"Language-Team: \n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: \n" +"Plural-Forms: \n" + +#. module: account_move_budget +#: code:addons/account_move_budget/models/account_move_budget.py:64 +#, python-format +msgid "%s (copy)" +msgstr "" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget_line__account_id +msgid "Account" +msgstr "" + +#. module: account_move_budget +#: model:ir.model,name:account_move_budget.model_account_move_budget +msgid "Account Move Budget" +msgstr "" + +#. module: account_move_budget +#: model:ir.model,name:account_move_budget.model_account_move_budget_line +msgid "Account Move Budget Line" +msgstr "" + +#. module: account_move_budget +#: model:ir.actions.act_window,name:account_move_budget.account_move_budget_act_window +#: model:ir.ui.menu,name:account_move_budget.account_move_budget_menu +msgid "Account Move Budgets" +msgstr "" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget__message_needaction +msgid "Action Needed" +msgstr "" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget__activity_ids +msgid "Activities" +msgstr "" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget__activity_state +msgid "Activity State" +msgstr "" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget_line__analytic_account_id +msgid "Analytic Account" +msgstr "" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget__message_attachment_count +msgid "Attachment Count" +msgstr "" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget_line__balance +msgid "Balance" +msgstr "" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget_line__budget_id +msgid "Budget" +msgstr "" + +#. module: account_move_budget +#: model:ir.actions.act_window,name:account_move_budget.account_move_budget_line_act_window +msgid "Budget Items" +msgstr "" + +#. module: account_move_budget +#: model_terms:ir.ui.view,arch_db:account_move_budget.account_move_budget_form_view +msgid "Budget Lines" +msgstr "" + +#. module: account_move_budget +#: model_terms:ir.ui.view,arch_db:account_move_budget.account_move_budget_form_view +msgid "Cancel" +msgstr "" + +#. module: account_move_budget +#: selection:account.move.budget,state:0 +msgid "Cancelled" +msgstr "" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget__company_id +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget_line__company_id +msgid "Company" +msgstr "" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget_line__company_currency_id +msgid "Company Currency" +msgstr "" + +#. module: account_move_budget +#: model_terms:ir.ui.view,arch_db:account_move_budget.account_move_budget_form_view +msgid "Confirm" +msgstr "" + +#. module: account_move_budget +#: selection:account.move.budget,state:0 +msgid "Confirmed" +msgstr "" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget__create_uid +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget_line__create_uid +msgid "Created by" +msgstr "" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget__create_date +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget_line__create_date +msgid "Created on" +msgstr "" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget_line__credit +msgid "Credit" +msgstr "" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget_line__date +msgid "Date" +msgstr "" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget__date_range_id +msgid "Date range" +msgstr "" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget_line__debit +msgid "Debit" +msgstr "" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget__description +msgid "Description" +msgstr "" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget__display_name +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget_line__display_name +msgid "Display Name" +msgstr "" + +#. module: account_move_budget +#: selection:account.move.budget,state:0 +msgid "Draft" +msgstr "" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget__message_follower_ids +msgid "Followers" +msgstr "" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget__message_channel_ids +msgid "Followers (Channels)" +msgstr "" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget__message_partner_ids +msgid "Followers (Partners)" +msgstr "" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget__date_from +msgid "From Date" +msgstr "" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget__id +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget_line__id +msgid "ID" +msgstr "" + +#. module: account_move_budget +#: model:ir.model.fields,help:account_move_budget.field_account_move_budget__message_unread +msgid "If checked new messages require your attention." +msgstr "" + +#. module: account_move_budget +#: model:ir.model.fields,help:account_move_budget.field_account_move_budget__message_needaction +msgid "If checked, new messages require your attention." +msgstr "" + +#. module: account_move_budget +#: model:ir.model.fields,help:account_move_budget.field_account_move_budget__message_has_error +msgid "If checked, some messages have a delivery error." +msgstr "" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget__message_is_follower +msgid "Is Follower" +msgstr "" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget_line__name +msgid "Label" +msgstr "" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget____last_update +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget_line____last_update +msgid "Last Modified on" +msgstr "" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget__write_uid +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget_line__write_uid +msgid "Last Updated by" +msgstr "" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget__write_date +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget_line__write_date +msgid "Last Updated on" +msgstr "" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget__line_ids +msgid "Line" +msgstr "" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget__message_main_attachment_id +msgid "Main Attachment" +msgstr "" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget__message_has_error +msgid "Message Delivery error" +msgstr "" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget__message_ids +msgid "Messages" +msgstr "" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget__name +#: model_terms:ir.ui.view,arch_db:account_move_budget.account_move_budget_form_view +msgid "Name" +msgstr "" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget__activity_date_deadline +msgid "Next Activity Deadline" +msgstr "" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget__activity_summary +msgid "Next Activity Summary" +msgstr "" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget__activity_type_id +msgid "Next Activity Type" +msgstr "" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget__message_needaction_counter +msgid "Number of Actions" +msgstr "" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget__message_has_error_counter +msgid "Number of error" +msgstr "" + +#. module: account_move_budget +#: model:ir.model.fields,help:account_move_budget.field_account_move_budget__message_needaction_counter +msgid "Number of messages which requires an action" +msgstr "" + +#. module: account_move_budget +#: model:ir.model.fields,help:account_move_budget.field_account_move_budget__message_has_error_counter +msgid "Number of messages with delivery error" +msgstr "" + +#. module: account_move_budget +#: model:ir.model.fields,help:account_move_budget.field_account_move_budget__message_unread_counter +msgid "Number of unread messages" +msgstr "" + +#. module: account_move_budget +#: selection:account.move.budget,activity_state:0 +msgid "Overdue" +msgstr "" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget_line__partner_id +msgid "Partner" +msgstr "" + +#. module: account_move_budget +#: selection:account.move.budget,activity_state:0 +msgid "Planned" +msgstr "" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget__activity_user_id +msgid "Responsible User" +msgstr "" + +#. module: account_move_budget +#: model_terms:ir.ui.view,arch_db:account_move_budget.account_move_budget_form_view +msgid "Set draft" +msgstr "" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget__state +msgid "State" +msgstr "" + +#. module: account_move_budget +#: model:ir.model.fields,help:account_move_budget.field_account_move_budget__activity_state +msgid "Status based on activities\n" +"Overdue: Due date is already passed\n" +"Today: Activity date is today\n" +"Planned: Future activities." +msgstr "" + +#. module: account_move_budget +#: model:ir.model.fields,help:account_move_budget.field_account_move_budget_line__balance +msgid "Technical field holding the debit - credit in order to open meaningful graph views from reports" +msgstr "" + +#. module: account_move_budget +#: code:addons/account_move_budget/models/account_move_budget_line.py:86 +#, python-format +msgid "The date must be within the budget period." +msgstr "" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget__date_to +msgid "To Date" +msgstr "" + +#. module: account_move_budget +#: selection:account.move.budget,activity_state:0 +msgid "Today" +msgstr "" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget__message_unread +msgid "Unread Messages" +msgstr "" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget__message_unread_counter +msgid "Unread Messages Counter" +msgstr "" + +#. module: account_move_budget +#: model:ir.model.fields,help:account_move_budget.field_account_move_budget_line__company_currency_id +msgid "Utility field to express amount currency" +msgstr "" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget__website_message_ids +msgid "Website Messages" +msgstr "" + +#. module: account_move_budget +#: model:ir.model.fields,help:account_move_budget.field_account_move_budget__website_message_ids +msgid "Website communication history" +msgstr "" + diff --git a/account_move_budget/i18n/fr.po b/account_move_budget/i18n/fr.po new file mode 100644 index 000000000..f4d5ea013 --- /dev/null +++ b/account_move_budget/i18n/fr.po @@ -0,0 +1,393 @@ +# Translation of Odoo Server. +# This file contains the translation of the following modules: +# * account_move_budget +# +msgid "" +msgstr "" +"Project-Id-Version: Odoo Server 12.0\n" +"Report-Msgid-Bugs-To: \n" +"PO-Revision-Date: 2019-10-17 10:32+0000\n" +"Last-Translator: Valaeys Stéphane \n" +"Language-Team: none\n" +"Language: fr\n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: \n" +"Plural-Forms: nplurals=2; plural=n > 1;\n" +"X-Generator: Weblate 3.8\n" + +#. module: account_move_budget +#: code:addons/account_move_budget/models/account_move_budget.py:64 +#, python-format +msgid "%s (copy)" +msgstr "%s (copie)" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget_line__account_id +msgid "Account" +msgstr "Compte" + +#. module: account_move_budget +#: model:ir.model,name:account_move_budget.model_account_move_budget +msgid "Account Move Budget" +msgstr "Budget comptable" + +#. module: account_move_budget +#: model:ir.model,name:account_move_budget.model_account_move_budget_line +msgid "Account Move Budget Line" +msgstr "Ligne de budget comptable" + +#. module: account_move_budget +#: model:ir.actions.act_window,name:account_move_budget.account_move_budget_act_window +#: model:ir.ui.menu,name:account_move_budget.account_move_budget_menu +msgid "Account Move Budgets" +msgstr "Budgets comptables" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget__message_needaction +msgid "Action Needed" +msgstr "Action requise" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget__activity_ids +msgid "Activities" +msgstr "Activités" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget__activity_state +msgid "Activity State" +msgstr "État de l'activité" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget_line__analytic_account_id +msgid "Analytic Account" +msgstr "Compte analytique" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget__message_attachment_count +msgid "Attachment Count" +msgstr "Nombre de pièces jointes" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget_line__balance +msgid "Balance" +msgstr "Solde" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget_line__budget_id +msgid "Budget" +msgstr "Budget" + +#. module: account_move_budget +#: model:ir.actions.act_window,name:account_move_budget.account_move_budget_line_act_window +msgid "Budget Items" +msgstr "Lignes budgétaires" + +#. module: account_move_budget +#: model_terms:ir.ui.view,arch_db:account_move_budget.account_move_budget_form_view +msgid "Budget Lines" +msgstr "Lignes budgétaires" + +#. module: account_move_budget +#: model_terms:ir.ui.view,arch_db:account_move_budget.account_move_budget_form_view +msgid "Cancel" +msgstr "Annuler" + +#. module: account_move_budget +#: selection:account.move.budget,state:0 +msgid "Cancelled" +msgstr "Annulé" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget__company_id +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget_line__company_id +msgid "Company" +msgstr "Société" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget_line__company_currency_id +msgid "Company Currency" +msgstr "Devise de la société" + +#. module: account_move_budget +#: model_terms:ir.ui.view,arch_db:account_move_budget.account_move_budget_form_view +msgid "Confirm" +msgstr "Confirmer" + +#. module: account_move_budget +#: selection:account.move.budget,state:0 +msgid "Confirmed" +msgstr "Confirmé" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget__create_uid +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget_line__create_uid +msgid "Created by" +msgstr "Créé par" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget__create_date +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget_line__create_date +msgid "Created on" +msgstr "Créé le" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget_line__credit +msgid "Credit" +msgstr "Crédit" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget_line__date +msgid "Date" +msgstr "Date" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget__date_range_id +msgid "Date range" +msgstr "Plage de date" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget_line__debit +msgid "Debit" +msgstr "Débit" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget__description +msgid "Description" +msgstr "Description" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget__display_name +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget_line__display_name +msgid "Display Name" +msgstr "Nom d'affichage" + +#. module: account_move_budget +#: selection:account.move.budget,state:0 +msgid "Draft" +msgstr "Brouillon" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget__message_follower_ids +msgid "Followers" +msgstr "Abonnés" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget__message_channel_ids +msgid "Followers (Channels)" +msgstr "Abonnés (Canaux)" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget__message_partner_ids +msgid "Followers (Partners)" +msgstr "Abonnés (Partenaires)" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget__date_from +msgid "From Date" +msgstr "À partir du" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget__id +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget_line__id +msgid "ID" +msgstr "ID" + +#. module: account_move_budget +#: model:ir.model.fields,help:account_move_budget.field_account_move_budget__message_unread +msgid "If checked new messages require your attention." +msgstr "Si coché, de nouveaux messages requièrent votre attention." + +#. module: account_move_budget +#: model:ir.model.fields,help:account_move_budget.field_account_move_budget__message_needaction +msgid "If checked, new messages require your attention." +msgstr "Si coché, de nouveaux messages requièrent votre attention." + +#. module: account_move_budget +#: model:ir.model.fields,help:account_move_budget.field_account_move_budget__message_has_error +msgid "If checked, some messages have a delivery error." +msgstr "Si coché, des messages ont un problème de livraison." + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget__message_is_follower +msgid "Is Follower" +msgstr "Est abonné" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget_line__name +msgid "Label" +msgstr "Libellé" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget____last_update +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget_line____last_update +msgid "Last Modified on" +msgstr "Modifié en dernier le" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget__write_uid +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget_line__write_uid +msgid "Last Updated by" +msgstr "Modifié en dernier par" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget__write_date +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget_line__write_date +msgid "Last Updated on" +msgstr "Modifié en dernier le" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget__line_ids +msgid "Line" +msgstr "Ligne" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget__message_main_attachment_id +msgid "Main Attachment" +msgstr "Pièce jointe principale" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget__message_has_error +msgid "Message Delivery error" +msgstr "Message d'erreur de livraison" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget__message_ids +msgid "Messages" +msgstr "Messages" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget__name +#: model_terms:ir.ui.view,arch_db:account_move_budget.account_move_budget_form_view +msgid "Name" +msgstr "Nom" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget__activity_date_deadline +msgid "Next Activity Deadline" +msgstr "Prochaine échéance d'activité" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget__activity_summary +msgid "Next Activity Summary" +msgstr "Résumé de la prochaine activité" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget__activity_type_id +msgid "Next Activity Type" +msgstr "Type de la prochaine activité" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget__message_needaction_counter +msgid "Number of Actions" +msgstr "Nombre d'actions" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget__message_has_error_counter +msgid "Number of error" +msgstr "Nombre d'erreurs" + +#. module: account_move_budget +#: model:ir.model.fields,help:account_move_budget.field_account_move_budget__message_needaction_counter +msgid "Number of messages which requires an action" +msgstr "Nombre de messages qui requièrent une action" + +#. module: account_move_budget +#: model:ir.model.fields,help:account_move_budget.field_account_move_budget__message_has_error_counter +msgid "Number of messages with delivery error" +msgstr "Nombre de messages qui ont une erreur de livraison" + +#. module: account_move_budget +#: model:ir.model.fields,help:account_move_budget.field_account_move_budget__message_unread_counter +msgid "Number of unread messages" +msgstr "Nombre de messages non lus" + +#. module: account_move_budget +#: selection:account.move.budget,activity_state:0 +msgid "Overdue" +msgstr "En retard" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget_line__partner_id +msgid "Partner" +msgstr "Partenaire" + +#. module: account_move_budget +#: selection:account.move.budget,activity_state:0 +msgid "Planned" +msgstr "Planifiée" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget__activity_user_id +msgid "Responsible User" +msgstr "Utilisateur responsable" + +#. module: account_move_budget +#: model_terms:ir.ui.view,arch_db:account_move_budget.account_move_budget_form_view +msgid "Set draft" +msgstr "Mettre en brouillon" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget__state +msgid "State" +msgstr "État" + +#. module: account_move_budget +#: model:ir.model.fields,help:account_move_budget.field_account_move_budget__activity_state +msgid "Status based on activities\n" +"Overdue: Due date is already passed\n" +"Today: Activity date is today\n" +"Planned: Future activities." +msgstr "" +"Statut basé sur les activités\n" +"En retard: La date d'échéance est déjà passée\n" +"Aujourd'hui: la date de l'activité est aujourd'hui\n" +"Planifiée: Activités futures." + +#. module: account_move_budget +#: model:ir.model.fields,help:account_move_budget.field_account_move_budget_line__balance +msgid "Technical field holding the debit - credit in order to open meaningful graph views from reports" +msgstr "" +"Champ technique qui enregistre débit - crédit de sorte à avoir des " +"représentations graphiques cohérentes à partir des rapports" + +#. module: account_move_budget +#: code:addons/account_move_budget/models/account_move_budget_line.py:86 +#, python-format +msgid "The date must be within the budget period." +msgstr "La date doit faire partie de la période du budget." + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget__date_to +msgid "To Date" +msgstr "jusqu'au" + +#. module: account_move_budget +#: selection:account.move.budget,activity_state:0 +msgid "Today" +msgstr "Aujourd'hui" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget__message_unread +msgid "Unread Messages" +msgstr "Messages non lus" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget__message_unread_counter +msgid "Unread Messages Counter" +msgstr "Nombre de messages non lus" + +#. module: account_move_budget +#: model:ir.model.fields,help:account_move_budget.field_account_move_budget_line__company_currency_id +msgid "Utility field to express amount currency" +msgstr "Champ technique pour exprimer le montant en devise" + +#. module: account_move_budget +#: model:ir.model.fields,field_description:account_move_budget.field_account_move_budget__website_message_ids +msgid "Website Messages" +msgstr "Messages du site web" + +#. module: account_move_budget +#: model:ir.model.fields,help:account_move_budget.field_account_move_budget__website_message_ids +msgid "Website communication history" +msgstr "Historique de la communication du site web" diff --git a/account_move_budget/models/__init__.py b/account_move_budget/models/__init__.py new file mode 100644 index 000000000..0a26d5031 --- /dev/null +++ b/account_move_budget/models/__init__.py @@ -0,0 +1,2 @@ +from . import account_move_budget +from . import account_move_budget_line diff --git a/account_move_budget/models/account_move_budget.py b/account_move_budget/models/account_move_budget.py new file mode 100644 index 000000000..715c20f1d --- /dev/null +++ b/account_move_budget/models/account_move_budget.py @@ -0,0 +1,71 @@ +# Copyright 2019 ACSONE SA/NV +# Copyright 2019 ForgeFlow S.L. (http://www.forgeflow.com) +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl). + +from odoo import _, api, fields, models + + +class AccountMoveBudget(models.Model): + _name = "account.move.budget" + _description = "Account Move Budget" + _inherit = ["mail.thread", "mail.activity.mixin"] + + name = fields.Char(required=True, track_visibility="onchange") + description = fields.Char(track_visibility="onchange") + date_range_id = fields.Many2one(comodel_name="date.range", string="Date range") + date_from = fields.Date( + required=True, string="From Date", track_visibility="onchange" + ) + date_to = fields.Date(required=True, string="To Date", track_visibility="onchange") + state = fields.Selection( + [("draft", "Draft"), ("confirmed", "Confirmed"), ("cancelled", "Cancelled")], + required=True, + default="draft", + track_visibility="onchange", + ) + line_ids = fields.One2many( + comodel_name="account.move.budget.line", inverse_name="budget_id", copy=True + ) + company_id = fields.Many2one( + comodel_name="res.company", + string="Company", + default=lambda self: self.env.company, + ) + + @api.returns("self", lambda value: value.id) + def copy(self, default=None): + self.ensure_one() + if default is None: + default = {} + if "name" not in default: + default["name"] = _("%s (copy)") % self.name + return super(AccountMoveBudget, self).copy(default=default) + + @api.onchange("date_range_id") + def _onchange_date_range(self): + for rec in self: + if rec.date_range_id: + rec.date_from = rec.date_range_id.date_start + rec.date_to = rec.date_range_id.date_end + + @api.onchange("date_from", "date_to") + def _onchange_dates(self): + for rec in self: + if rec.date_range_id: + if ( + rec.date_from != rec.date_range_id.date_start + or rec.date_to != rec.date_range_id.date_end + ): + rec.date_range_id = False + + def action_draft(self): + for rec in self: + rec.state = "draft" + + def action_cancel(self): + for rec in self: + rec.state = "cancelled" + + def action_confirm(self): + for rec in self: + rec.state = "confirmed" diff --git a/account_move_budget/models/account_move_budget_line.py b/account_move_budget/models/account_move_budget_line.py new file mode 100644 index 000000000..3bfff1d0d --- /dev/null +++ b/account_move_budget/models/account_move_budget_line.py @@ -0,0 +1,70 @@ +# Copyright 2019 ForgeFlow S.L. (http://www.forgeflow.com) +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl). + +from odoo import _, api, fields, models +from odoo.exceptions import ValidationError + + +class AccountMoveBudgetLine(models.Model): + _name = "account.move.budget.line" + _description = "Account Move Budget Line" + _order = "date desc, id desc" + + budget_id = fields.Many2one( + comodel_name="account.move.budget", + string="Budget", + required=True, + ondelete="cascade", + index=True, + ) + name = fields.Char(string="Label") + debit = fields.Monetary(default=0.0, currency_field="company_currency_id") + credit = fields.Monetary(default=0.0, currency_field="company_currency_id") + balance = fields.Monetary( + compute="_compute_store_balance", + store=True, + currency_field="company_currency_id", + help="Technical field holding the debit - " + "credit in order to open meaningful " + "graph views from reports", + ) + company_currency_id = fields.Many2one( + "res.currency", + related="company_id.currency_id", + string="Company Currency", + readonly=True, + help="Utility field to express amount currency", + store=True, + ) + account_id = fields.Many2one( + "account.account", + string="Account", + required=True, + index=True, + ondelete="cascade", + domain=[("deprecated", "=", False)], + default=lambda self: self._context.get("account_id", False), + ) + date = fields.Date(string="Date", index=True, required=True) + analytic_account_id = fields.Many2one( + "account.analytic.account", string="Analytic Account" + ) + company_id = fields.Many2one( + "res.company", + related="account_id.company_id", + string="Company", + store=True, + readonly=True, + ) + partner_id = fields.Many2one("res.partner", string="Partner", ondelete="restrict") + + @api.depends("debit", "credit") + def _compute_store_balance(self): + for line in self: + line.balance = line.debit - line.credit + + @api.constrains("date") + def _constraint_date(self): + for rec in self: + if rec.budget_id.date_from > rec.date or rec.budget_id.date_to < rec.date: + raise ValidationError(_("The date must be within the budget period.")) diff --git a/account_move_budget/readme/CONTRIBUTORS.rst b/account_move_budget/readme/CONTRIBUTORS.rst new file mode 100644 index 000000000..aded17936 --- /dev/null +++ b/account_move_budget/readme/CONTRIBUTORS.rst @@ -0,0 +1,3 @@ +* ForgeFlow, S.L. (https://www.forgeflow.com) + * Hector Villarreal + * Jordi Ballester Alomar diff --git a/account_move_budget/readme/DESCRIPTION.rst b/account_move_budget/readme/DESCRIPTION.rst new file mode 100644 index 000000000..b56898e3d --- /dev/null +++ b/account_move_budget/readme/DESCRIPTION.rst @@ -0,0 +1,11 @@ +This module allows to define accounting budgets. + +These budgets can then be used in MIS Builder reports, as an alternate +source. + +The difference between the MIS Builder Budget and this module is that +this module defines budgets irrespective of the MIS Builder Template. The +budget is thus agnostic of the reporting format. + +For example, the budgeted data can be used in a general Profit & Loss report +and at the same time can be used in a department or project expenses report. diff --git a/account_move_budget/readme/USAGE.rst b/account_move_budget/readme/USAGE.rst new file mode 100644 index 000000000..b16d7e229 --- /dev/null +++ b/account_move_budget/readme/USAGE.rst @@ -0,0 +1,2 @@ +In order to set up the budget items go to +*Invoicing / Accounting / Miscellaneous / Account Move Budgets*. diff --git a/account_move_budget/security/ir.model.access.csv b/account_move_budget/security/ir.model.access.csv new file mode 100644 index 000000000..abe158087 --- /dev/null +++ b/account_move_budget/security/ir.model.access.csv @@ -0,0 +1,5 @@ +id,name,model_id:id,group_id:id,perm_read,perm_write,perm_create,perm_unlink +access_account_move_budget,access_account_move_budget,model_account_move_budget,account.group_account_user,1,0,0,0 +access_account_move_budget_manager,access_account_move_budget_manager,model_account_move_budget,account.group_account_manager,1,1,1,1 +access_account_move_budget_line,access_account_move_budget_line,model_account_move_budget_line,account.group_account_user,1,0,0,0 +access_account_move_budget_line_manager,access_account_move_budget_line_manager,model_account_move_budget_line,account.group_account_manager,1,1,1,1 diff --git a/account_move_budget/static/description/icon.png b/account_move_budget/static/description/icon.png new file mode 100644 index 000000000..3a0328b51 Binary files /dev/null and b/account_move_budget/static/description/icon.png differ diff --git a/account_move_budget/static/description/index.html b/account_move_budget/static/description/index.html new file mode 100644 index 000000000..19496c42a --- /dev/null +++ b/account_move_budget/static/description/index.html @@ -0,0 +1,434 @@ + + + + + + +Account Move Budget + + + +
+

Account Move Budget

+ + +

Beta License: AGPL-3 OCA/account-financial-tools Translate me on Weblate Try me on Runbot

+

This module allows to define accounting budgets.

+

These budgets can then be used in MIS Builder reports, as an alternate +source.

+

The difference between the MIS Builder Budget and this module is that +this module defines budgets irrespective of the MIS Builder Template. The +budget is thus agnostic of the reporting format.

+

For example, the budgeted data can be used in a general Profit & Loss report +and at the same time can be used in a department or project expenses report.

+

Table of contents

+ +
+

Usage

+

In order to set up the budget items go to +Invoicing / Accounting / Miscellaneous / Account Move Budgets.

+
+
+

Bug Tracker

+

Bugs are tracked on GitHub Issues. +In case of trouble, please check there if your issue has already been reported. +If you spotted it first, help us smashing it by providing a detailed and welcomed +feedback.

+

Do not contact contributors directly about support or help with technical issues.

+
+
+

Credits

+
+

Authors

+
    +
  • Eficent
  • +
+
+
+

Contributors

+ +
+
+

Maintainers

+

This module is maintained by the OCA.

+Odoo Community Association +

OCA, or the Odoo Community Association, is a nonprofit organization whose +mission is to support the collaborative development of Odoo features and +promote its widespread use.

+

This module is part of the OCA/account-financial-tools project on GitHub.

+

You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute.

+
+
+
+ + diff --git a/account_move_budget/views/account_move_budget_line_views.xml b/account_move_budget/views/account_move_budget_line_views.xml new file mode 100644 index 000000000..a8d8c7c36 --- /dev/null +++ b/account_move_budget/views/account_move_budget_line_views.xml @@ -0,0 +1,32 @@ + + + + + Account Move Budget Line tree + account.move.budget.line + + + + + + + + + + + + + + + + Budget Items + account.move.budget.line + tree + [('budget_id', '=', active_id)] + {'default_budget_id': active_id} + + diff --git a/account_move_budget/views/account_move_budget_views.xml b/account_move_budget/views/account_move_budget_views.xml new file mode 100644 index 000000000..7272ded6a --- /dev/null +++ b/account_move_budget/views/account_move_budget_views.xml @@ -0,0 +1,106 @@ + + + + + account.move.budget.form + account.move.budget + +
+
+
+ +
+
+
+
+
+

+ +

+ +
+ + + + + + + + +
+
+ + + +
+
+
+
+ + account.move.budget.search + account.move.budget + + + + + + + + + account.move.budget.tree + account.move.budget + + + + + + + + + + + Account Move Budgets + account.move.budget + tree,form + [] + {} + + + Account Move Budgets + + + +
diff --git a/setup/account_move_budget/odoo/addons/account_move_budget b/setup/account_move_budget/odoo/addons/account_move_budget new file mode 120000 index 000000000..1ce527675 --- /dev/null +++ b/setup/account_move_budget/odoo/addons/account_move_budget @@ -0,0 +1 @@ +../../../../account_move_budget \ No newline at end of file diff --git a/setup/account_move_budget/setup.py b/setup/account_move_budget/setup.py new file mode 100644 index 000000000..28c57bb64 --- /dev/null +++ b/setup/account_move_budget/setup.py @@ -0,0 +1,6 @@ +import setuptools + +setuptools.setup( + setup_requires=['setuptools-odoo'], + odoo_addon=True, +)