mirror of
https://gitlab.com/flectra-hq/flectra.git
synced 2025-02-25 18:55:21 -06:00
[INIT] Inception of Flectra from Odoo
Flectra is Forked from Odoo v11 commit : (6135e82d73)
This commit is contained in:
10
.github/ISSUE_TEMPLATE.md
vendored
Normal file
10
.github/ISSUE_TEMPLATE.md
vendored
Normal file
@@ -0,0 +1,10 @@
|
||||
Impacted versions:
|
||||
|
||||
Steps to reproduce:
|
||||
|
||||
Current behavior:
|
||||
|
||||
Expected behavior:
|
||||
|
||||
Video/Screenshot link (optional):
|
||||
|
||||
9
.github/PULL_REQUEST_TEMPLATE.md
vendored
Normal file
9
.github/PULL_REQUEST_TEMPLATE.md
vendored
Normal file
@@ -0,0 +1,9 @@
|
||||
Description of the issue/feature this PR addresses:
|
||||
|
||||
Current behavior before PR:
|
||||
|
||||
Desired behavior after PR is merged:
|
||||
|
||||
|
||||
--
|
||||
I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
|
||||
40
.gitignore
vendored
Normal file
40
.gitignore
vendored
Normal file
@@ -0,0 +1,40 @@
|
||||
# sphinx build directories
|
||||
_build/
|
||||
|
||||
# dotfiles
|
||||
.*
|
||||
!.gitignore
|
||||
!.mailmap
|
||||
# compiled python files
|
||||
*.py[co]
|
||||
__pycache__/
|
||||
# setup.py egg_info
|
||||
*.egg-info
|
||||
# emacs backup files
|
||||
*~
|
||||
# hg stuff
|
||||
*.orig
|
||||
status
|
||||
# odoo filestore
|
||||
odoo/filestore
|
||||
# maintenance migration scripts
|
||||
odoo/addons/base/maintenance
|
||||
|
||||
# generated for windows installer?
|
||||
install/win32/*.bat
|
||||
install/win32/meta.py
|
||||
|
||||
# needed only when building for win32
|
||||
setup/win32/static/less/
|
||||
setup/win32/static/wkhtmltopdf/
|
||||
setup/win32/static/postgresql*.exe
|
||||
|
||||
# various virtualenv
|
||||
/bin/
|
||||
/build/
|
||||
/dist/
|
||||
/include/
|
||||
/lib/
|
||||
/man/
|
||||
/share/
|
||||
/src/
|
||||
954
.tx/config
Normal file
954
.tx/config
Normal file
@@ -0,0 +1,954 @@
|
||||
[main]
|
||||
host = https://www.transifex.com
|
||||
type = PO
|
||||
|
||||
[odoo-11.base]
|
||||
file_filter = odoo/addons/base/i18n/<lang>.po
|
||||
source_file = odoo/addons/base/i18n/base.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.account]
|
||||
file_filter = addons/account/i18n/<lang>.po
|
||||
source_file = addons/account/i18n/account.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.account_analytic_default]
|
||||
file_filter = addons/account_analytic_default/i18n/<lang>.po
|
||||
source_file = addons/account_analytic_default/i18n/account_analytic_default.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.account_asset]
|
||||
file_filter = addons/account_asset/i18n/<lang>.po
|
||||
source_file = addons/account_asset/i18n/account_asset.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.account_bank_statement_import]
|
||||
file_filter = addons/account_bank_statement_import/i18n/<lang>.po
|
||||
source_file = addons/account_bank_statement_import/i18n/account_bank_statement_import.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.account_budget]
|
||||
file_filter = addons/account_budget/i18n/<lang>.po
|
||||
source_file = addons/account_budget/i18n/account_budget.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.account_cancel]
|
||||
file_filter = addons/account_cancel/i18n/<lang>.po
|
||||
source_file = addons/account_cancel/i18n/account_cancel.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.account_check_printing]
|
||||
file_filter = addons/account_check_printing/i18n/<lang>.po
|
||||
source_file = addons/account_check_printing/i18n/account_check_printing.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.account_invoicing]
|
||||
file_filter = addons/account_invoicing/i18n/<lang>.po
|
||||
source_file = addons/account_invoicing/i18n/account_invoicing.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.account_payment]
|
||||
file_filter = addons/account_payment/i18n/<lang>.po
|
||||
source_file = addons/account_payment/i18n/account_payment.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.account_tax_python]
|
||||
file_filter = addons/account_tax_python/i18n/<lang>.po
|
||||
source_file = addons/account_tax_python/i18n/account_tax_python.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.account_test]
|
||||
file_filter = addons/account_test/i18n/<lang>.po
|
||||
source_file = addons/account_test/i18n/account_test.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.account_voucher]
|
||||
file_filter = addons/account_voucher/i18n/<lang>.po
|
||||
source_file = addons/account_voucher/i18n/account_voucher.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.analytic]
|
||||
file_filter = addons/analytic/i18n/<lang>.po
|
||||
source_file = addons/analytic/i18n/analytic.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.anonymization]
|
||||
file_filter = addons/anonymization/i18n/<lang>.po
|
||||
source_file = addons/anonymization/i18n/anonymization.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.association]
|
||||
file_filter = addons/association/i18n/<lang>.po
|
||||
source_file = addons/association/i18n/association.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.auth_crypt]
|
||||
file_filter = addons/auth_crypt/i18n/<lang>.po
|
||||
source_file = addons/auth_crypt/i18n/auth_crypt.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.auth_ldap]
|
||||
file_filter = addons/auth_ldap/i18n/<lang>.po
|
||||
source_file = addons/auth_ldap/i18n/auth_ldap.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.auth_oauth]
|
||||
file_filter = addons/auth_oauth/i18n/<lang>.po
|
||||
source_file = addons/auth_oauth/i18n/auth_oauth.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.auth_signup]
|
||||
file_filter = addons/auth_signup/i18n/<lang>.po
|
||||
source_file = addons/auth_signup/i18n/auth_signup.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.barcodes]
|
||||
file_filter = addons/barcodes/i18n/<lang>.po
|
||||
source_file = addons/barcodes/i18n/barcodes.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.base_address_city]
|
||||
file_filter = addons/base_address_city/i18n/<lang>.po
|
||||
source_file = addons/base_address_city/i18n/base_address_city.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.base_address_extended]
|
||||
file_filter = addons/base_address_extended/i18n/<lang>.po
|
||||
source_file = addons/base_address_extended/i18n/base_address_extended.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.base_automation]
|
||||
file_filter = addons/base_automation/i18n/<lang>.po
|
||||
source_file = addons/base_automation/i18n/base_automation.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.base_gengo]
|
||||
file_filter = addons/base_gengo/i18n/<lang>.po
|
||||
source_file = addons/base_gengo/i18n/base_gengo.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.base_geolocalize]
|
||||
file_filter = addons/base_geolocalize/i18n/<lang>.po
|
||||
source_file = addons/base_geolocalize/i18n/base_geolocalize.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.base_iban]
|
||||
file_filter = addons/base_iban/i18n/<lang>.po
|
||||
source_file = addons/base_iban/i18n/base_iban.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.base_import]
|
||||
file_filter = addons/base_import/i18n/<lang>.po
|
||||
source_file = addons/base_import/i18n/base_import.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.base_import_module]
|
||||
file_filter = addons/base_import_module/i18n/<lang>.po
|
||||
source_file = addons/base_import_module/i18n/base_import_module.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.base_setup]
|
||||
file_filter = addons/base_setup/i18n/<lang>.po
|
||||
source_file = addons/base_setup/i18n/base_setup.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.base_sparse_field]
|
||||
file_filter = addons/base_sparse_field/i18n/<lang>.po
|
||||
source_file = addons/base_sparse_field/i18n/base_sparse_field.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.base_vat]
|
||||
file_filter = addons/base_vat/i18n/<lang>.po
|
||||
source_file = addons/base_vat/i18n/base_vat.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.base_vat_autocomplete]
|
||||
file_filter = addons/base_vat_autocomplete/i18n/<lang>.po
|
||||
source_file = addons/base_vat_autocomplete/i18n/base_vat_autocomplete.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.board]
|
||||
file_filter = addons/board/i18n/<lang>.po
|
||||
source_file = addons/board/i18n/board.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.bus]
|
||||
file_filter = addons/bus/i18n/<lang>.po
|
||||
source_file = addons/bus/i18n/bus.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.calendar]
|
||||
file_filter = addons/calendar/i18n/<lang>.po
|
||||
source_file = addons/calendar/i18n/calendar.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.calendar_sms]
|
||||
file_filter = addons/calendar_sms/i18n/<lang>.po
|
||||
source_file = addons/calendar_sms/i18n/calendar_sms.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.contacts]
|
||||
file_filter = addons/contacts/i18n/<lang>.po
|
||||
source_file = addons/contacts/i18n/contacts.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.crm]
|
||||
file_filter = addons/crm/i18n/<lang>.po
|
||||
source_file = addons/crm/i18n/crm.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.crm_livechat]
|
||||
file_filter = addons/crm_livechat/i18n/<lang>.po
|
||||
source_file = addons/crm_livechat/i18n/crm_livechat.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.crm_phone_validation]
|
||||
file_filter = addons/crm_phone_validation/i18n/<lang>.po
|
||||
source_file = addons/crm_phone_validation/i18n/crm_phone_validation.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.crm_project]
|
||||
file_filter = addons/crm_project/i18n/<lang>.po
|
||||
source_file = addons/crm_project/i18n/crm_project.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.decimal_precision]
|
||||
file_filter = addons/decimal_precision/i18n/<lang>.po
|
||||
source_file = addons/decimal_precision/i18n/decimal_precision.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.delivery]
|
||||
file_filter = addons/delivery/i18n/<lang>.po
|
||||
source_file = addons/delivery/i18n/delivery.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.document]
|
||||
file_filter = addons/document/i18n/<lang>.po
|
||||
source_file = addons/document/i18n/document.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.event]
|
||||
file_filter = addons/event/i18n/<lang>.po
|
||||
source_file = addons/event/i18n/event.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.event_sale]
|
||||
file_filter = addons/event_sale/i18n/<lang>.po
|
||||
source_file = addons/event_sale/i18n/event_sale.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.fetchmail]
|
||||
file_filter = addons/fetchmail/i18n/<lang>.po
|
||||
source_file = addons/fetchmail/i18n/fetchmail.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.fleet]
|
||||
file_filter = addons/fleet/i18n/<lang>.po
|
||||
source_file = addons/fleet/i18n/fleet.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.gamification]
|
||||
file_filter = addons/gamification/i18n/<lang>.po
|
||||
source_file = addons/gamification/i18n/gamification.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.gamification_sale_crm]
|
||||
file_filter = addons/gamification_sale_crm/i18n/<lang>.po
|
||||
source_file = addons/gamification_sale_crm/i18n/gamification_sale_crm.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.google_account]
|
||||
file_filter = addons/google_account/i18n/<lang>.po
|
||||
source_file = addons/google_account/i18n/google_account.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.google_calendar]
|
||||
file_filter = addons/google_calendar/i18n/<lang>.po
|
||||
source_file = addons/google_calendar/i18n/google_calendar.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.google_drive]
|
||||
file_filter = addons/google_drive/i18n/<lang>.po
|
||||
source_file = addons/google_drive/i18n/google_drive.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.google_spreadsheet]
|
||||
file_filter = addons/google_spreadsheet/i18n/<lang>.po
|
||||
source_file = addons/google_spreadsheet/i18n/google_spreadsheet.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.hr]
|
||||
file_filter = addons/hr/i18n/<lang>.po
|
||||
source_file = addons/hr/i18n/hr.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.hr_attendance]
|
||||
file_filter = addons/hr_attendance/i18n/<lang>.po
|
||||
source_file = addons/hr_attendance/i18n/hr_attendance.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.hr_contract]
|
||||
file_filter = addons/hr_contract/i18n/<lang>.po
|
||||
source_file = addons/hr_contract/i18n/hr_contract.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.hr_expense]
|
||||
file_filter = addons/hr_expense/i18n/<lang>.po
|
||||
source_file = addons/hr_expense/i18n/hr_expense.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.hr_expense_check]
|
||||
file_filter = addons/hr_expense_check/i18n/<lang>.po
|
||||
source_file = addons/hr_expense_check/i18n/hr_expense_check.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.hr_gamification]
|
||||
file_filter = addons/hr_gamification/i18n/<lang>.po
|
||||
source_file = addons/hr_gamification/i18n/hr_gamification.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.hr_holidays]
|
||||
file_filter = addons/hr_holidays/i18n/<lang>.po
|
||||
source_file = addons/hr_holidays/i18n/hr_holidays.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.hr_maintenance]
|
||||
file_filter = addons/hr_maintenance/i18n/<lang>.po
|
||||
source_file = addons/hr_maintenance/i18n/hr_maintenance.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.hr_org_chart]
|
||||
file_filter = addons/hr_org_chart/i18n/<lang>.po
|
||||
source_file = addons/hr_org_chart/i18n/hr_org_chart.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.hr_payroll]
|
||||
file_filter = addons/hr_payroll/i18n/<lang>.po
|
||||
source_file = addons/hr_payroll/i18n/hr_payroll.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.hr_payroll_account]
|
||||
file_filter = addons/hr_payroll_account/i18n/<lang>.po
|
||||
source_file = addons/hr_payroll_account/i18n/hr_payroll_account.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.hr_recruitment]
|
||||
file_filter = addons/hr_recruitment/i18n/<lang>.po
|
||||
source_file = addons/hr_recruitment/i18n/hr_recruitment.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.hr_recruitment_survey]
|
||||
file_filter = addons/hr_recruitment_survey/i18n/<lang>.po
|
||||
source_file = addons/hr_recruitment_survey/i18n/hr_recruitment_survey.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.hr_timesheet]
|
||||
file_filter = addons/hr_timesheet/i18n/<lang>.po
|
||||
source_file = addons/hr_timesheet/i18n/hr_timesheet.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.hr_timesheet_attendance]
|
||||
file_filter = addons/hr_timesheet_attendance/i18n/<lang>.po
|
||||
source_file = addons/hr_timesheet_attendance/i18n/hr_timesheet_attendance.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.iap]
|
||||
file_filter = addons/iap/i18n/<lang>.po
|
||||
source_file = addons/iap/i18n/iap.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.im_livechat]
|
||||
file_filter = addons/im_livechat/i18n/<lang>.po
|
||||
source_file = addons/im_livechat/i18n/im_livechat.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.link_tracker]
|
||||
file_filter = addons/link_tracker/i18n/<lang>.po
|
||||
source_file = addons/link_tracker/i18n/link_tracker.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.lunch]
|
||||
file_filter = addons/lunch/i18n/<lang>.po
|
||||
source_file = addons/lunch/i18n/lunch.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.mail]
|
||||
file_filter = addons/mail/i18n/<lang>.po
|
||||
source_file = addons/mail/i18n/mail.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.maintenance]
|
||||
file_filter = addons/maintenance/i18n/<lang>.po
|
||||
source_file = addons/maintenance/i18n/maintenance.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.mass_mailing]
|
||||
file_filter = addons/mass_mailing/i18n/<lang>.po
|
||||
source_file = addons/mass_mailing/i18n/mass_mailing.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.mass_mailing_event]
|
||||
file_filter = addons/mass_mailing_event/i18n/<lang>.po
|
||||
source_file = addons/mass_mailing_event/i18n/mass_mailing_event.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.mass_mailing_event_track]
|
||||
file_filter = addons/mass_mailing_event_track/i18n/<lang>.po
|
||||
source_file = addons/mass_mailing_event_track/i18n/mass_mailing_event_track.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.membership]
|
||||
file_filter = addons/membership/i18n/<lang>.po
|
||||
source_file = addons/membership/i18n/membership.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.mrp]
|
||||
file_filter = addons/mrp/i18n/<lang>.po
|
||||
source_file = addons/mrp/i18n/mrp.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.mrp_byproduct]
|
||||
file_filter = addons/mrp_byproduct/i18n/<lang>.po
|
||||
source_file = addons/mrp_byproduct/i18n/mrp_byproduct.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.mrp_repair]
|
||||
file_filter = addons/mrp_repair/i18n/<lang>.po
|
||||
source_file = addons/mrp_repair/i18n/mrp_repair.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.note]
|
||||
file_filter = addons/note/i18n/<lang>.po
|
||||
source_file = addons/note/i18n/note.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.note_pad]
|
||||
file_filter = addons/note_pad/i18n/<lang>.po
|
||||
source_file = addons/note_pad/i18n/note_pad.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.pad]
|
||||
file_filter = addons/pad/i18n/<lang>.po
|
||||
source_file = addons/pad/i18n/pad.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.pad_project]
|
||||
file_filter = addons/pad_project/i18n/<lang>.po
|
||||
source_file = addons/pad_project/i18n/pad_project.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.payment]
|
||||
file_filter = addons/payment/i18n/<lang>.po
|
||||
source_file = addons/payment/i18n/payment.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.payment_adyen]
|
||||
file_filter = addons/payment_adyen/i18n/<lang>.po
|
||||
source_file = addons/payment_adyen/i18n/payment_adyen.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.payment_authorize]
|
||||
file_filter = addons/payment_authorize/i18n/<lang>.po
|
||||
source_file = addons/payment_authorize/i18n/payment_authorize.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.payment_buckaroo]
|
||||
file_filter = addons/payment_buckaroo/i18n/<lang>.po
|
||||
source_file = addons/payment_buckaroo/i18n/payment_buckaroo.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.payment_ogone]
|
||||
file_filter = addons/payment_ogone/i18n/<lang>.po
|
||||
source_file = addons/payment_ogone/i18n/payment_ogone.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.payment_paypal]
|
||||
file_filter = addons/payment_paypal/i18n/<lang>.po
|
||||
source_file = addons/payment_paypal/i18n/payment_paypal.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.payment_payumoney]
|
||||
file_filter = addons/payment_payumoney/i18n/<lang>.po
|
||||
source_file = addons/payment_payumoney/i18n/payment_payumoney.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.payment_sips]
|
||||
file_filter = addons/payment_sips/i18n/<lang>.po
|
||||
source_file = addons/payment_sips/i18n/payment_sips.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.payment_stripe]
|
||||
file_filter = addons/payment_stripe/i18n/<lang>.po
|
||||
source_file = addons/payment_stripe/i18n/payment_stripe.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.payment_transfer]
|
||||
file_filter = addons/payment_transfer/i18n/<lang>.po
|
||||
source_file = addons/payment_transfer/i18n/payment_transfer.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.phone_validation]
|
||||
file_filter = addons/phone_validation/i18n/<lang>.po
|
||||
source_file = addons/phone_validation/i18n/phone_validation.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.point_of_sale]
|
||||
file_filter = addons/point_of_sale/i18n/<lang>.po
|
||||
source_file = addons/point_of_sale/i18n/point_of_sale.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.portal]
|
||||
file_filter = addons/portal/i18n/<lang>.po
|
||||
source_file = addons/portal/i18n/portal.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.pos_cache]
|
||||
file_filter = addons/pos_cache/i18n/<lang>.po
|
||||
source_file = addons/pos_cache/i18n/pos_cache.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.pos_data_drinks]
|
||||
file_filter = addons/pos_data_drinks/i18n/<lang>.po
|
||||
source_file = addons/pos_data_drinks/i18n/pos_data_drinks.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.pos_discount]
|
||||
file_filter = addons/pos_discount/i18n/<lang>.po
|
||||
source_file = addons/pos_discount/i18n/pos_discount.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.pos_mercury]
|
||||
file_filter = addons/pos_mercury/i18n/<lang>.po
|
||||
source_file = addons/pos_mercury/i18n/pos_mercury.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.pos_reprint]
|
||||
file_filter = addons/pos_reprint/i18n/<lang>.po
|
||||
source_file = addons/pos_reprint/i18n/pos_reprint.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.pos_restaurant]
|
||||
file_filter = addons/pos_restaurant/i18n/<lang>.po
|
||||
source_file = addons/pos_restaurant/i18n/pos_restaurant.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.pos_sale]
|
||||
file_filter = addons/pos_sale/i18n/<lang>.po
|
||||
source_file = addons/pos_sale/i18n/pos_sale.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.procurement_jit]
|
||||
file_filter = addons/procurement_jit/i18n/<lang>.po
|
||||
source_file = addons/procurement_jit/i18n/procurement_jit.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.product]
|
||||
file_filter = addons/product/i18n/<lang>.po
|
||||
source_file = addons/product/i18n/product.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.product_email_template]
|
||||
file_filter = addons/product_email_template/i18n/<lang>.po
|
||||
source_file = addons/product_email_template/i18n/product_email_template.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.product_expiry]
|
||||
file_filter = addons/product_expiry/i18n/<lang>.po
|
||||
source_file = addons/product_expiry/i18n/product_expiry.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.product_extended]
|
||||
file_filter = addons/product_extended/i18n/<lang>.po
|
||||
source_file = addons/product_extended/i18n/product_extended.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.product_margin]
|
||||
file_filter = addons/product_margin/i18n/<lang>.po
|
||||
source_file = addons/product_margin/i18n/product_margin.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.project]
|
||||
file_filter = addons/project/i18n/<lang>.po
|
||||
source_file = addons/project/i18n/project.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.project_timesheet_holidays]
|
||||
file_filter = addons/project_timesheet_holidays/i18n/<lang>.po
|
||||
source_file = addons/project_timesheet_holidays/i18n/project_timesheet_holidays.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.purchase]
|
||||
file_filter = addons/purchase/i18n/<lang>.po
|
||||
source_file = addons/purchase/i18n/purchase.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.purchase_mrp]
|
||||
file_filter = addons/purchase_mrp/i18n/<lang>.po
|
||||
source_file = addons/purchase_mrp/i18n/purchase_mrp.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.purchase_requisition]
|
||||
file_filter = addons/purchase_requisition/i18n/<lang>.po
|
||||
source_file = addons/purchase_requisition/i18n/purchase_requisition.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.rating]
|
||||
file_filter = addons/rating/i18n/<lang>.po
|
||||
source_file = addons/rating/i18n/rating.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.rating_project]
|
||||
file_filter = addons/rating_project/i18n/<lang>.po
|
||||
source_file = addons/rating_project/i18n/rating_project.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.report_intrastat]
|
||||
file_filter = addons/report_intrastat/i18n/<lang>.po
|
||||
source_file = addons/report_intrastat/i18n/report_intrastat.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.resource]
|
||||
file_filter = addons/resource/i18n/<lang>.po
|
||||
source_file = addons/resource/i18n/resource.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.sale]
|
||||
file_filter = addons/sale/i18n/<lang>.po
|
||||
source_file = addons/sale/i18n/sale.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.sale_crm]
|
||||
file_filter = addons/sale_crm/i18n/<lang>.po
|
||||
source_file = addons/sale_crm/i18n/sale_crm.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.sale_expense]
|
||||
file_filter = addons/sale_expense/i18n/<lang>.po
|
||||
source_file = addons/sale_expense/i18n/sale_expense.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.sale_management]
|
||||
file_filter = addons/sale_management/i18n/<lang>.po
|
||||
source_file = addons/sale_management/i18n/sale_management.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.sale_margin]
|
||||
file_filter = addons/sale_margin/i18n/<lang>.po
|
||||
source_file = addons/sale_margin/i18n/sale_margin.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.sale_mrp]
|
||||
file_filter = addons/sale_mrp/i18n/<lang>.po
|
||||
source_file = addons/sale_mrp/i18n/sale_mrp.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.sale_order_dates]
|
||||
file_filter = addons/sale_order_dates/i18n/<lang>.po
|
||||
source_file = addons/sale_order_dates/i18n/sale_order_dates.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.sale_payment]
|
||||
file_filter = addons/sale_payment/i18n/<lang>.po
|
||||
source_file = addons/sale_payment/i18n/sale_payment.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.sale_service_rating]
|
||||
file_filter = addons/sale_service_rating/i18n/<lang>.po
|
||||
source_file = addons/sale_service_rating/i18n/sale_service_rating.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.sale_stock]
|
||||
file_filter = addons/sale_stock/i18n/<lang>.po
|
||||
source_file = addons/sale_stock/i18n/sale_stock.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.sale_timesheet]
|
||||
file_filter = addons/sale_timesheet/i18n/<lang>.po
|
||||
source_file = addons/sale_timesheet/i18n/sale_timesheet.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.sales_team]
|
||||
file_filter = addons/sales_team/i18n/<lang>.po
|
||||
source_file = addons/sales_team/i18n/sales_team.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.sms]
|
||||
file_filter = addons/sms/i18n/<lang>.po
|
||||
source_file = addons/sms/i18n/sms.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.stock]
|
||||
file_filter = addons/stock/i18n/<lang>.po
|
||||
source_file = addons/stock/i18n/stock.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.stock_account]
|
||||
file_filter = addons/stock_account/i18n/<lang>.po
|
||||
source_file = addons/stock_account/i18n/stock_account.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.stock_dropshipping]
|
||||
file_filter = addons/stock_dropshipping/i18n/<lang>.po
|
||||
source_file = addons/stock_dropshipping/i18n/stock_dropshipping.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.stock_landed_costs]
|
||||
file_filter = addons/stock_landed_costs/i18n/<lang>.po
|
||||
source_file = addons/stock_landed_costs/i18n/stock_landed_costs.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.stock_picking_batch]
|
||||
file_filter = addons/stock_picking_batch/i18n/<lang>.po
|
||||
source_file = addons/stock_picking_batch/i18n/stock_picking_batch.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.survey]
|
||||
file_filter = addons/survey/i18n/<lang>.po
|
||||
source_file = addons/survey/i18n/survey.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.survey_crm]
|
||||
file_filter = addons/survey_crm/i18n/<lang>.po
|
||||
source_file = addons/survey_crm/i18n/survey_crm.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.theme_bootswatch]
|
||||
file_filter = addons/theme_bootswatch/i18n/<lang>.po
|
||||
source_file = addons/theme_bootswatch/i18n/theme_bootswatch.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.transifex]
|
||||
file_filter = addons/transifex/i18n/<lang>.po
|
||||
source_file = addons/transifex/i18n/transifex.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.theme_default]
|
||||
file_filter = addons/theme_default/i18n/<lang>.po
|
||||
source_file = addons/theme_default/i18n/theme_default.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.utm]
|
||||
file_filter = addons/utm/i18n/<lang>.po
|
||||
source_file = addons/utm/i18n/utm.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.web]
|
||||
file_filter = addons/web/i18n/<lang>.po
|
||||
source_file = addons/web/i18n/web.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.web_diagram]
|
||||
file_filter = addons/web_diagram/i18n/<lang>.po
|
||||
source_file = addons/web_diagram/i18n/web_diagram.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.web_editor]
|
||||
file_filter = addons/web_editor/i18n/<lang>.po
|
||||
source_file = addons/web_editor/i18n/web_editor.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.web_kanban_gauge]
|
||||
file_filter = addons/web_kanban_gauge/i18n/<lang>.po
|
||||
source_file = addons/web_kanban_gauge/i18n/web_kanban_gauge.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.web_planner]
|
||||
file_filter = addons/web_planner/i18n/<lang>.po
|
||||
source_file = addons/web_planner/i18n/web_planner.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.web_settings_dashboard]
|
||||
file_filter = addons/web_settings_dashboard/i18n/<lang>.po
|
||||
source_file = addons/web_settings_dashboard/i18n/web_settings_dashboard.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.web_tour]
|
||||
file_filter = addons/web_tour/i18n/<lang>.po
|
||||
source_file = addons/web_tour/i18n/web_tour.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.website]
|
||||
file_filter = addons/website/i18n/<lang>.po
|
||||
source_file = addons/website/i18n/website.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.website_blog]
|
||||
file_filter = addons/website_blog/i18n/<lang>.po
|
||||
source_file = addons/website_blog/i18n/website_blog.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.website_crm]
|
||||
file_filter = addons/website_crm/i18n/<lang>.po
|
||||
source_file = addons/website_crm/i18n/website_crm.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.website_crm_partner_assign]
|
||||
file_filter = addons/website_crm_partner_assign/i18n/<lang>.po
|
||||
source_file = addons/website_crm_partner_assign/i18n/website_crm_partner_assign.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.website_customer]
|
||||
file_filter = addons/website_customer/i18n/<lang>.po
|
||||
source_file = addons/website_customer/i18n/website_customer.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.website_event]
|
||||
file_filter = addons/website_event/i18n/<lang>.po
|
||||
source_file = addons/website_event/i18n/website_event.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.website_event_questions]
|
||||
file_filter = addons/website_event_questions/i18n/<lang>.po
|
||||
source_file = addons/website_event_questions/i18n/website_event_questions.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.website_event_sale]
|
||||
file_filter = addons/website_event_sale/i18n/<lang>.po
|
||||
source_file = addons/website_event_sale/i18n/website_event_sale.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.website_event_track]
|
||||
file_filter = addons/website_event_track/i18n/<lang>.po
|
||||
source_file = addons/website_event_track/i18n/website_event_track.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.website_form]
|
||||
file_filter = addons/website_form/i18n/<lang>.po
|
||||
source_file = addons/website_form/i18n/website_form.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.website_forum]
|
||||
file_filter = addons/website_forum/i18n/<lang>.po
|
||||
source_file = addons/website_forum/i18n/website_forum.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.website_forum_doc]
|
||||
file_filter = addons/website_forum_doc/i18n/<lang>.po
|
||||
source_file = addons/website_forum_doc/i18n/website_forum_doc.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.website_gengo]
|
||||
file_filter = addons/website_gengo/i18n/<lang>.po
|
||||
source_file = addons/website_gengo/i18n/website_gengo.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.website_hr]
|
||||
file_filter = addons/website_hr/i18n/<lang>.po
|
||||
source_file = addons/website_hr/i18n/website_hr.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.website_hr_recruitment]
|
||||
file_filter = addons/website_hr_recruitment/i18n/<lang>.po
|
||||
source_file = addons/website_hr_recruitment/i18n/website_hr_recruitment.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.website_links]
|
||||
file_filter = addons/website_links/i18n/<lang>.po
|
||||
source_file = addons/website_links/i18n/website_links.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.website_livechat]
|
||||
file_filter = addons/website_livechat/i18n/<lang>.po
|
||||
source_file = addons/website_livechat/i18n/website_livechat.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.website_mail]
|
||||
file_filter = addons/website_mail/i18n/<lang>.po
|
||||
source_file = addons/website_mail/i18n/website_mail.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.website_mail_channel]
|
||||
file_filter = addons/website_mail_channel/i18n/<lang>.po
|
||||
source_file = addons/website_mail_channel/i18n/website_mail_channel.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.website_mass_mailing]
|
||||
file_filter = addons/website_mass_mailing/i18n/<lang>.po
|
||||
source_file = addons/website_mass_mailing/i18n/website_mass_mailing.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.website_membership]
|
||||
file_filter = addons/website_membership/i18n/<lang>.po
|
||||
source_file = addons/website_membership/i18n/website_membership.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.website_partner]
|
||||
file_filter = addons/website_partner/i18n/<lang>.po
|
||||
source_file = addons/website_partner/i18n/website_partner.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.website_payment]
|
||||
file_filter = addons/website_payment/i18n/<lang>.po
|
||||
source_file = addons/website_payment/i18n/website_payment.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.website_quote]
|
||||
file_filter = addons/website_quote/i18n/<lang>.po
|
||||
source_file = addons/website_quote/i18n/website_quote.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.website_rating]
|
||||
file_filter = addons/website_rating/i18n/<lang>.po
|
||||
source_file = addons/website_rating/i18n/website_rating.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.website_rating_project]
|
||||
file_filter = addons/website_rating_project/i18n/<lang>.po
|
||||
source_file = addons/website_rating_project/i18n/website_rating_project.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.website_sale]
|
||||
file_filter = addons/website_sale/i18n/<lang>.po
|
||||
source_file = addons/website_sale/i18n/website_sale.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.website_sale_comparison]
|
||||
file_filter = addons/website_sale_comparison/i18n/<lang>.po
|
||||
source_file = addons/website_sale_comparison/i18n/website_sale_comparison.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.website_sale_delivery]
|
||||
file_filter = addons/website_sale_delivery/i18n/<lang>.po
|
||||
source_file = addons/website_sale_delivery/i18n/website_sale_delivery.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.website_sale_digital]
|
||||
file_filter = addons/website_sale_digital/i18n/<lang>.po
|
||||
source_file = addons/website_sale_digital/i18n/website_sale_digital.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.website_sale_management]
|
||||
file_filter = addons/website_sale_management/i18n/<lang>.po
|
||||
source_file = addons/website_sale_management/i18n/website_sale_management.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.website_sale_options]
|
||||
file_filter = addons/website_sale_options/i18n/<lang>.po
|
||||
source_file = addons/website_sale_options/i18n/website_sale_options.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.website_sale_stock]
|
||||
file_filter = addons/website_sale_stock/i18n/<lang>.po
|
||||
source_file = addons/website_sale_stock/i18n/website_sale_stock.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.website_sale_wishlist]
|
||||
file_filter = addons/website_sale_wishlist/i18n/<lang>.po
|
||||
source_file = addons/website_sale_wishlist/i18n/website_sale_wishlist.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.website_slides]
|
||||
file_filter = addons/website_slides/i18n/<lang>.po
|
||||
source_file = addons/website_slides/i18n/website_slides.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.website_theme_install]
|
||||
file_filter = addons/website_theme_install/i18n/<lang>.po
|
||||
source_file = addons/website_theme_install/i18n/website_theme_install.pot
|
||||
source_lang = en
|
||||
|
||||
[odoo-11.website_twitter]
|
||||
file_filter = addons/website_twitter/i18n/<lang>.po
|
||||
source_file = addons/website_twitter/i18n/website_twitter.pot
|
||||
source_lang = en
|
||||
|
||||
14
CONTRIBUTING.md
Normal file
14
CONTRIBUTING.md
Normal file
@@ -0,0 +1,14 @@
|
||||
Contributing to Odoo
|
||||
====================
|
||||
|
||||
[Full contribution guidelines](https://github.com/odoo/odoo/wiki/Contributing)
|
||||
|
||||
TL;DR
|
||||
|
||||
* If you [make a pull request](https://github.com/odoo/odoo/wiki/Contributing#making-pull-requests),
|
||||
do not create an issue! Use the PR description for that
|
||||
* Issues are handled with a much lower priority than pull requests
|
||||
* Use this [template](https://github.com/odoo/odoo/tree/11.0/.github/ISSUE_TEMPLATE.md)
|
||||
when reporting issues. Please search for duplicates first!
|
||||
* Pull requests must be made against the [correct version](https://github.com/odoo/odoo/wiki/Contributing#against-which-version-should-i-submit-a-patch)
|
||||
* There are restrictions on the kind of [changes allowed in stable series](https://github.com/odoo/odoo/wiki/Contributing#what-does-stable-mean)
|
||||
15
COPYRIGHT
Normal file
15
COPYRIGHT
Normal file
@@ -0,0 +1,15 @@
|
||||
|
||||
Most of the files are
|
||||
|
||||
Copyright (c) 2004-2015 Odoo S.A.
|
||||
|
||||
Many files also contain contributions from third
|
||||
parties. In this case the original copyright of
|
||||
the contributions can be traced through the
|
||||
history of the source version control system.
|
||||
|
||||
When that is not the case, the files contain a prominent
|
||||
notice stating the original copyright and applicable
|
||||
license, or come with their own dedicated COPYRIGHT
|
||||
and/or LICENSE file.
|
||||
|
||||
859
LICENSE
Normal file
859
LICENSE
Normal file
@@ -0,0 +1,859 @@
|
||||
|
||||
For copyright information, please see the COPYRIGHT file.
|
||||
|
||||
Odoo is published under the GNU LESSER GENERAL PUBLIC LICENSE, Version 3
|
||||
(LGPLv3), as included below. Since the LGPL is a set of additional
|
||||
permissions on top of the GPL, the text of the GPL is included at the
|
||||
bottom as well.
|
||||
|
||||
Some external libraries and contributions bundled with Odoo may be published
|
||||
under other GPL-compatible licenses. For these, please refer to the relevant
|
||||
source files and/or license files, in the source code tree.
|
||||
|
||||
**************************************************************************
|
||||
|
||||
GNU LESSER GENERAL PUBLIC LICENSE
|
||||
Version 3, 29 June 2007
|
||||
|
||||
Copyright (C) 2007 Free Software Foundation, Inc. <http://fsf.org/>
|
||||
Everyone is permitted to copy and distribute verbatim copies
|
||||
of this license document, but changing it is not allowed.
|
||||
|
||||
|
||||
This version of the GNU Lesser General Public License incorporates
|
||||
the terms and conditions of version 3 of the GNU General Public
|
||||
License, supplemented by the additional permissions listed below.
|
||||
|
||||
0. Additional Definitions.
|
||||
|
||||
As used herein, "this License" refers to version 3 of the GNU Lesser
|
||||
General Public License, and the "GNU GPL" refers to version 3 of the GNU
|
||||
General Public License.
|
||||
|
||||
"The Library" refers to a covered work governed by this License,
|
||||
other than an Application or a Combined Work as defined below.
|
||||
|
||||
An "Application" is any work that makes use of an interface provided
|
||||
by the Library, but which is not otherwise based on the Library.
|
||||
Defining a subclass of a class defined by the Library is deemed a mode
|
||||
of using an interface provided by the Library.
|
||||
|
||||
A "Combined Work" is a work produced by combining or linking an
|
||||
Application with the Library. The particular version of the Library
|
||||
with which the Combined Work was made is also called the "Linked
|
||||
Version".
|
||||
|
||||
The "Minimal Corresponding Source" for a Combined Work means the
|
||||
Corresponding Source for the Combined Work, excluding any source code
|
||||
for portions of the Combined Work that, considered in isolation, are
|
||||
based on the Application, and not on the Linked Version.
|
||||
|
||||
The "Corresponding Application Code" for a Combined Work means the
|
||||
object code and/or source code for the Application, including any data
|
||||
and utility programs needed for reproducing the Combined Work from the
|
||||
Application, but excluding the System Libraries of the Combined Work.
|
||||
|
||||
1. Exception to Section 3 of the GNU GPL.
|
||||
|
||||
You may convey a covered work under sections 3 and 4 of this License
|
||||
without being bound by section 3 of the GNU GPL.
|
||||
|
||||
2. Conveying Modified Versions.
|
||||
|
||||
If you modify a copy of the Library, and, in your modifications, a
|
||||
facility refers to a function or data to be supplied by an Application
|
||||
that uses the facility (other than as an argument passed when the
|
||||
facility is invoked), then you may convey a copy of the modified
|
||||
version:
|
||||
|
||||
a) under this License, provided that you make a good faith effort to
|
||||
ensure that, in the event an Application does not supply the
|
||||
function or data, the facility still operates, and performs
|
||||
whatever part of its purpose remains meaningful, or
|
||||
|
||||
b) under the GNU GPL, with none of the additional permissions of
|
||||
this License applicable to that copy.
|
||||
|
||||
3. Object Code Incorporating Material from Library Header Files.
|
||||
|
||||
The object code form of an Application may incorporate material from
|
||||
a header file that is part of the Library. You may convey such object
|
||||
code under terms of your choice, provided that, if the incorporated
|
||||
material is not limited to numerical parameters, data structure
|
||||
layouts and accessors, or small macros, inline functions and templates
|
||||
(ten or fewer lines in length), you do both of the following:
|
||||
|
||||
a) Give prominent notice with each copy of the object code that the
|
||||
Library is used in it and that the Library and its use are
|
||||
covered by this License.
|
||||
|
||||
b) Accompany the object code with a copy of the GNU GPL and this license
|
||||
document.
|
||||
|
||||
4. Combined Works.
|
||||
|
||||
You may convey a Combined Work under terms of your choice that,
|
||||
taken together, effectively do not restrict modification of the
|
||||
portions of the Library contained in the Combined Work and reverse
|
||||
engineering for debugging such modifications, if you also do each of
|
||||
the following:
|
||||
|
||||
a) Give prominent notice with each copy of the Combined Work that
|
||||
the Library is used in it and that the Library and its use are
|
||||
covered by this License.
|
||||
|
||||
b) Accompany the Combined Work with a copy of the GNU GPL and this license
|
||||
document.
|
||||
|
||||
c) For a Combined Work that displays copyright notices during
|
||||
execution, include the copyright notice for the Library among
|
||||
these notices, as well as a reference directing the user to the
|
||||
copies of the GNU GPL and this license document.
|
||||
|
||||
d) Do one of the following:
|
||||
|
||||
0) Convey the Minimal Corresponding Source under the terms of this
|
||||
License, and the Corresponding Application Code in a form
|
||||
suitable for, and under terms that permit, the user to
|
||||
recombine or relink the Application with a modified version of
|
||||
the Linked Version to produce a modified Combined Work, in the
|
||||
manner specified by section 6 of the GNU GPL for conveying
|
||||
Corresponding Source.
|
||||
|
||||
1) Use a suitable shared library mechanism for linking with the
|
||||
Library. A suitable mechanism is one that (a) uses at run time
|
||||
a copy of the Library already present on the user's computer
|
||||
system, and (b) will operate properly with a modified version
|
||||
of the Library that is interface-compatible with the Linked
|
||||
Version.
|
||||
|
||||
e) Provide Installation Information, but only if you would otherwise
|
||||
be required to provide such information under section 6 of the
|
||||
GNU GPL, and only to the extent that such information is
|
||||
necessary to install and execute a modified version of the
|
||||
Combined Work produced by recombining or relinking the
|
||||
Application with a modified version of the Linked Version. (If
|
||||
you use option 4d0, the Installation Information must accompany
|
||||
the Minimal Corresponding Source and Corresponding Application
|
||||
Code. If you use option 4d1, you must provide the Installation
|
||||
Information in the manner specified by section 6 of the GNU GPL
|
||||
for conveying Corresponding Source.)
|
||||
|
||||
5. Combined Libraries.
|
||||
|
||||
You may place library facilities that are a work based on the
|
||||
Library side by side in a single library together with other library
|
||||
facilities that are not Applications and are not covered by this
|
||||
License, and convey such a combined library under terms of your
|
||||
choice, if you do both of the following:
|
||||
|
||||
a) Accompany the combined library with a copy of the same work based
|
||||
on the Library, uncombined with any other library facilities,
|
||||
conveyed under the terms of this License.
|
||||
|
||||
b) Give prominent notice with the combined library that part of it
|
||||
is a work based on the Library, and explaining where to find the
|
||||
accompanying uncombined form of the same work.
|
||||
|
||||
6. Revised Versions of the GNU Lesser General Public License.
|
||||
|
||||
The Free Software Foundation may publish revised and/or new versions
|
||||
of the GNU Lesser General Public License from time to time. Such new
|
||||
versions will be similar in spirit to the present version, but may
|
||||
differ in detail to address new problems or concerns.
|
||||
|
||||
Each version is given a distinguishing version number. If the
|
||||
Library as you received it specifies that a certain numbered version
|
||||
of the GNU Lesser General Public License "or any later version"
|
||||
applies to it, you have the option of following the terms and
|
||||
conditions either of that published version or of any later version
|
||||
published by the Free Software Foundation. If the Library as you
|
||||
received it does not specify a version number of the GNU Lesser
|
||||
General Public License, you may choose any version of the GNU Lesser
|
||||
General Public License ever published by the Free Software Foundation.
|
||||
|
||||
If the Library as you received it specifies that a proxy can decide
|
||||
whether future versions of the GNU Lesser General Public License shall
|
||||
apply, that proxy's public statement of acceptance of any version is
|
||||
permanent authorization for you to choose that version for the
|
||||
Library.
|
||||
|
||||
**************************************************************************
|
||||
|
||||
GNU GENERAL PUBLIC LICENSE
|
||||
Version 3, 29 June 2007
|
||||
|
||||
Copyright (C) 2007 Free Software Foundation, Inc. <http://fsf.org/>
|
||||
Everyone is permitted to copy and distribute verbatim copies
|
||||
of this license document, but changing it is not allowed.
|
||||
|
||||
Preamble
|
||||
|
||||
The GNU General Public License is a free, copyleft license for
|
||||
software and other kinds of works.
|
||||
|
||||
The licenses for most software and other practical works are designed
|
||||
to take away your freedom to share and change the works. By contrast,
|
||||
the GNU General Public License is intended to guarantee your freedom to
|
||||
share and change all versions of a program--to make sure it remains free
|
||||
software for all its users. We, the Free Software Foundation, use the
|
||||
GNU General Public License for most of our software; it applies also to
|
||||
any other work released this way by its authors. You can apply it to
|
||||
your programs, too.
|
||||
|
||||
When we speak of free software, we are referring to freedom, not
|
||||
price. Our General Public Licenses are designed to make sure that you
|
||||
have the freedom to distribute copies of free software (and charge for
|
||||
them if you wish), that you receive source code or can get it if you
|
||||
want it, that you can change the software or use pieces of it in new
|
||||
free programs, and that you know you can do these things.
|
||||
|
||||
To protect your rights, we need to prevent others from denying you
|
||||
these rights or asking you to surrender the rights. Therefore, you have
|
||||
certain responsibilities if you distribute copies of the software, or if
|
||||
you modify it: responsibilities to respect the freedom of others.
|
||||
|
||||
For example, if you distribute copies of such a program, whether
|
||||
gratis or for a fee, you must pass on to the recipients the same
|
||||
freedoms that you received. You must make sure that they, too, receive
|
||||
or can get the source code. And you must show them these terms so they
|
||||
know their rights.
|
||||
|
||||
Developers that use the GNU GPL protect your rights with two steps:
|
||||
(1) assert copyright on the software, and (2) offer you this License
|
||||
giving you legal permission to copy, distribute and/or modify it.
|
||||
|
||||
For the developers' and authors' protection, the GPL clearly explains
|
||||
that there is no warranty for this free software. For both users' and
|
||||
authors' sake, the GPL requires that modified versions be marked as
|
||||
changed, so that their problems will not be attributed erroneously to
|
||||
authors of previous versions.
|
||||
|
||||
Some devices are designed to deny users access to install or run
|
||||
modified versions of the software inside them, although the manufacturer
|
||||
can do so. This is fundamentally incompatible with the aim of
|
||||
protecting users' freedom to change the software. The systematic
|
||||
pattern of such abuse occurs in the area of products for individuals to
|
||||
use, which is precisely where it is most unacceptable. Therefore, we
|
||||
have designed this version of the GPL to prohibit the practice for those
|
||||
products. If such problems arise substantially in other domains, we
|
||||
stand ready to extend this provision to those domains in future versions
|
||||
of the GPL, as needed to protect the freedom of users.
|
||||
|
||||
Finally, every program is threatened constantly by software patents.
|
||||
States should not allow patents to restrict development and use of
|
||||
software on general-purpose computers, but in those that do, we wish to
|
||||
avoid the special danger that patents applied to a free program could
|
||||
make it effectively proprietary. To prevent this, the GPL assures that
|
||||
patents cannot be used to render the program non-free.
|
||||
|
||||
The precise terms and conditions for copying, distribution and
|
||||
modification follow.
|
||||
|
||||
TERMS AND CONDITIONS
|
||||
|
||||
0. Definitions.
|
||||
|
||||
"This License" refers to version 3 of the GNU General Public License.
|
||||
|
||||
"Copyright" also means copyright-like laws that apply to other kinds of
|
||||
works, such as semiconductor masks.
|
||||
|
||||
"The Program" refers to any copyrightable work licensed under this
|
||||
License. Each licensee is addressed as "you". "Licensees" and
|
||||
"recipients" may be individuals or organizations.
|
||||
|
||||
To "modify" a work means to copy from or adapt all or part of the work
|
||||
in a fashion requiring copyright permission, other than the making of an
|
||||
exact copy. The resulting work is called a "modified version" of the
|
||||
earlier work or a work "based on" the earlier work.
|
||||
|
||||
A "covered work" means either the unmodified Program or a work based
|
||||
on the Program.
|
||||
|
||||
To "propagate" a work means to do anything with it that, without
|
||||
permission, would make you directly or secondarily liable for
|
||||
infringement under applicable copyright law, except executing it on a
|
||||
computer or modifying a private copy. Propagation includes copying,
|
||||
distribution (with or without modification), making available to the
|
||||
public, and in some countries other activities as well.
|
||||
|
||||
To "convey" a work means any kind of propagation that enables other
|
||||
parties to make or receive copies. Mere interaction with a user through
|
||||
a computer network, with no transfer of a copy, is not conveying.
|
||||
|
||||
An interactive user interface displays "Appropriate Legal Notices"
|
||||
to the extent that it includes a convenient and prominently visible
|
||||
feature that (1) displays an appropriate copyright notice, and (2)
|
||||
tells the user that there is no warranty for the work (except to the
|
||||
extent that warranties are provided), that licensees may convey the
|
||||
work under this License, and how to view a copy of this License. If
|
||||
the interface presents a list of user commands or options, such as a
|
||||
menu, a prominent item in the list meets this criterion.
|
||||
|
||||
1. Source Code.
|
||||
|
||||
The "source code" for a work means the preferred form of the work
|
||||
for making modifications to it. "Object code" means any non-source
|
||||
form of a work.
|
||||
|
||||
A "Standard Interface" means an interface that either is an official
|
||||
standard defined by a recognized standards body, or, in the case of
|
||||
interfaces specified for a particular programming language, one that
|
||||
is widely used among developers working in that language.
|
||||
|
||||
The "System Libraries" of an executable work include anything, other
|
||||
than the work as a whole, that (a) is included in the normal form of
|
||||
packaging a Major Component, but which is not part of that Major
|
||||
Component, and (b) serves only to enable use of the work with that
|
||||
Major Component, or to implement a Standard Interface for which an
|
||||
implementation is available to the public in source code form. A
|
||||
"Major Component", in this context, means a major essential component
|
||||
(kernel, window system, and so on) of the specific operating system
|
||||
(if any) on which the executable work runs, or a compiler used to
|
||||
produce the work, or an object code interpreter used to run it.
|
||||
|
||||
The "Corresponding Source" for a work in object code form means all
|
||||
the source code needed to generate, install, and (for an executable
|
||||
work) run the object code and to modify the work, including scripts to
|
||||
control those activities. However, it does not include the work's
|
||||
System Libraries, or general-purpose tools or generally available free
|
||||
programs which are used unmodified in performing those activities but
|
||||
which are not part of the work. For example, Corresponding Source
|
||||
includes interface definition files associated with source files for
|
||||
the work, and the source code for shared libraries and dynamically
|
||||
linked subprograms that the work is specifically designed to require,
|
||||
such as by intimate data communication or control flow between those
|
||||
subprograms and other parts of the work.
|
||||
|
||||
The Corresponding Source need not include anything that users
|
||||
can regenerate automatically from other parts of the Corresponding
|
||||
Source.
|
||||
|
||||
The Corresponding Source for a work in source code form is that
|
||||
same work.
|
||||
|
||||
2. Basic Permissions.
|
||||
|
||||
All rights granted under this License are granted for the term of
|
||||
copyright on the Program, and are irrevocable provided the stated
|
||||
conditions are met. This License explicitly affirms your unlimited
|
||||
permission to run the unmodified Program. The output from running a
|
||||
covered work is covered by this License only if the output, given its
|
||||
content, constitutes a covered work. This License acknowledges your
|
||||
rights of fair use or other equivalent, as provided by copyright law.
|
||||
|
||||
You may make, run and propagate covered works that you do not
|
||||
convey, without conditions so long as your license otherwise remains
|
||||
in force. You may convey covered works to others for the sole purpose
|
||||
of having them make modifications exclusively for you, or provide you
|
||||
with facilities for running those works, provided that you comply with
|
||||
the terms of this License in conveying all material for which you do
|
||||
not control copyright. Those thus making or running the covered works
|
||||
for you must do so exclusively on your behalf, under your direction
|
||||
and control, on terms that prohibit them from making any copies of
|
||||
your copyrighted material outside their relationship with you.
|
||||
|
||||
Conveying under any other circumstances is permitted solely under
|
||||
the conditions stated below. Sublicensing is not allowed; section 10
|
||||
makes it unnecessary.
|
||||
|
||||
3. Protecting Users' Legal Rights From Anti-Circumvention Law.
|
||||
|
||||
No covered work shall be deemed part of an effective technological
|
||||
measure under any applicable law fulfilling obligations under article
|
||||
11 of the WIPO copyright treaty adopted on 20 December 1996, or
|
||||
similar laws prohibiting or restricting circumvention of such
|
||||
measures.
|
||||
|
||||
When you convey a covered work, you waive any legal power to forbid
|
||||
circumvention of technological measures to the extent such circumvention
|
||||
is effected by exercising rights under this License with respect to
|
||||
the covered work, and you disclaim any intention to limit operation or
|
||||
modification of the work as a means of enforcing, against the work's
|
||||
users, your or third parties' legal rights to forbid circumvention of
|
||||
technological measures.
|
||||
|
||||
4. Conveying Verbatim Copies.
|
||||
|
||||
You may convey verbatim copies of the Program's source code as you
|
||||
receive it, in any medium, provided that you conspicuously and
|
||||
appropriately publish on each copy an appropriate copyright notice;
|
||||
keep intact all notices stating that this License and any
|
||||
non-permissive terms added in accord with section 7 apply to the code;
|
||||
keep intact all notices of the absence of any warranty; and give all
|
||||
recipients a copy of this License along with the Program.
|
||||
|
||||
You may charge any price or no price for each copy that you convey,
|
||||
and you may offer support or warranty protection for a fee.
|
||||
|
||||
5. Conveying Modified Source Versions.
|
||||
|
||||
You may convey a work based on the Program, or the modifications to
|
||||
produce it from the Program, in the form of source code under the
|
||||
terms of section 4, provided that you also meet all of these conditions:
|
||||
|
||||
a) The work must carry prominent notices stating that you modified
|
||||
it, and giving a relevant date.
|
||||
|
||||
b) The work must carry prominent notices stating that it is
|
||||
released under this License and any conditions added under section
|
||||
7. This requirement modifies the requirement in section 4 to
|
||||
"keep intact all notices".
|
||||
|
||||
c) You must license the entire work, as a whole, under this
|
||||
License to anyone who comes into possession of a copy. This
|
||||
License will therefore apply, along with any applicable section 7
|
||||
additional terms, to the whole of the work, and all its parts,
|
||||
regardless of how they are packaged. This License gives no
|
||||
permission to license the work in any other way, but it does not
|
||||
invalidate such permission if you have separately received it.
|
||||
|
||||
d) If the work has interactive user interfaces, each must display
|
||||
Appropriate Legal Notices; however, if the Program has interactive
|
||||
interfaces that do not display Appropriate Legal Notices, your
|
||||
work need not make them do so.
|
||||
|
||||
A compilation of a covered work with other separate and independent
|
||||
works, which are not by their nature extensions of the covered work,
|
||||
and which are not combined with it such as to form a larger program,
|
||||
in or on a volume of a storage or distribution medium, is called an
|
||||
"aggregate" if the compilation and its resulting copyright are not
|
||||
used to limit the access or legal rights of the compilation's users
|
||||
beyond what the individual works permit. Inclusion of a covered work
|
||||
in an aggregate does not cause this License to apply to the other
|
||||
parts of the aggregate.
|
||||
|
||||
6. Conveying Non-Source Forms.
|
||||
|
||||
You may convey a covered work in object code form under the terms
|
||||
of sections 4 and 5, provided that you also convey the
|
||||
machine-readable Corresponding Source under the terms of this License,
|
||||
in one of these ways:
|
||||
|
||||
a) Convey the object code in, or embodied in, a physical product
|
||||
(including a physical distribution medium), accompanied by the
|
||||
Corresponding Source fixed on a durable physical medium
|
||||
customarily used for software interchange.
|
||||
|
||||
b) Convey the object code in, or embodied in, a physical product
|
||||
(including a physical distribution medium), accompanied by a
|
||||
written offer, valid for at least three years and valid for as
|
||||
long as you offer spare parts or customer support for that product
|
||||
model, to give anyone who possesses the object code either (1) a
|
||||
copy of the Corresponding Source for all the software in the
|
||||
product that is covered by this License, on a durable physical
|
||||
medium customarily used for software interchange, for a price no
|
||||
more than your reasonable cost of physically performing this
|
||||
conveying of source, or (2) access to copy the
|
||||
Corresponding Source from a network server at no charge.
|
||||
|
||||
c) Convey individual copies of the object code with a copy of the
|
||||
written offer to provide the Corresponding Source. This
|
||||
alternative is allowed only occasionally and noncommercially, and
|
||||
only if you received the object code with such an offer, in accord
|
||||
with subsection 6b.
|
||||
|
||||
d) Convey the object code by offering access from a designated
|
||||
place (gratis or for a charge), and offer equivalent access to the
|
||||
Corresponding Source in the same way through the same place at no
|
||||
further charge. You need not require recipients to copy the
|
||||
Corresponding Source along with the object code. If the place to
|
||||
copy the object code is a network server, the Corresponding Source
|
||||
may be on a different server (operated by you or a third party)
|
||||
that supports equivalent copying facilities, provided you maintain
|
||||
clear directions next to the object code saying where to find the
|
||||
Corresponding Source. Regardless of what server hosts the
|
||||
Corresponding Source, you remain obligated to ensure that it is
|
||||
available for as long as needed to satisfy these requirements.
|
||||
|
||||
e) Convey the object code using peer-to-peer transmission, provided
|
||||
you inform other peers where the object code and Corresponding
|
||||
Source of the work are being offered to the general public at no
|
||||
charge under subsection 6d.
|
||||
|
||||
A separable portion of the object code, whose source code is excluded
|
||||
from the Corresponding Source as a System Library, need not be
|
||||
included in conveying the object code work.
|
||||
|
||||
A "User Product" is either (1) a "consumer product", which means any
|
||||
tangible personal property which is normally used for personal, family,
|
||||
or household purposes, or (2) anything designed or sold for incorporation
|
||||
into a dwelling. In determining whether a product is a consumer product,
|
||||
doubtful cases shall be resolved in favor of coverage. For a particular
|
||||
product received by a particular user, "normally used" refers to a
|
||||
typical or common use of that class of product, regardless of the status
|
||||
of the particular user or of the way in which the particular user
|
||||
actually uses, or expects or is expected to use, the product. A product
|
||||
is a consumer product regardless of whether the product has substantial
|
||||
commercial, industrial or non-consumer uses, unless such uses represent
|
||||
the only significant mode of use of the product.
|
||||
|
||||
"Installation Information" for a User Product means any methods,
|
||||
procedures, authorization keys, or other information required to install
|
||||
and execute modified versions of a covered work in that User Product from
|
||||
a modified version of its Corresponding Source. The information must
|
||||
suffice to ensure that the continued functioning of the modified object
|
||||
code is in no case prevented or interfered with solely because
|
||||
modification has been made.
|
||||
|
||||
If you convey an object code work under this section in, or with, or
|
||||
specifically for use in, a User Product, and the conveying occurs as
|
||||
part of a transaction in which the right of possession and use of the
|
||||
User Product is transferred to the recipient in perpetuity or for a
|
||||
fixed term (regardless of how the transaction is characterized), the
|
||||
Corresponding Source conveyed under this section must be accompanied
|
||||
by the Installation Information. But this requirement does not apply
|
||||
if neither you nor any third party retains the ability to install
|
||||
modified object code on the User Product (for example, the work has
|
||||
been installed in ROM).
|
||||
|
||||
The requirement to provide Installation Information does not include a
|
||||
requirement to continue to provide support service, warranty, or updates
|
||||
for a work that has been modified or installed by the recipient, or for
|
||||
the User Product in which it has been modified or installed. Access to a
|
||||
network may be denied when the modification itself materially and
|
||||
adversely affects the operation of the network or violates the rules and
|
||||
protocols for communication across the network.
|
||||
|
||||
Corresponding Source conveyed, and Installation Information provided,
|
||||
in accord with this section must be in a format that is publicly
|
||||
documented (and with an implementation available to the public in
|
||||
source code form), and must require no special password or key for
|
||||
unpacking, reading or copying.
|
||||
|
||||
7. Additional Terms.
|
||||
|
||||
"Additional permissions" are terms that supplement the terms of this
|
||||
License by making exceptions from one or more of its conditions.
|
||||
Additional permissions that are applicable to the entire Program shall
|
||||
be treated as though they were included in this License, to the extent
|
||||
that they are valid under applicable law. If additional permissions
|
||||
apply only to part of the Program, that part may be used separately
|
||||
under those permissions, but the entire Program remains governed by
|
||||
this License without regard to the additional permissions.
|
||||
|
||||
When you convey a copy of a covered work, you may at your option
|
||||
remove any additional permissions from that copy, or from any part of
|
||||
it. (Additional permissions may be written to require their own
|
||||
removal in certain cases when you modify the work.) You may place
|
||||
additional permissions on material, added by you to a covered work,
|
||||
for which you have or can give appropriate copyright permission.
|
||||
|
||||
Notwithstanding any other provision of this License, for material you
|
||||
add to a covered work, you may (if authorized by the copyright holders of
|
||||
that material) supplement the terms of this License with terms:
|
||||
|
||||
a) Disclaiming warranty or limiting liability differently from the
|
||||
terms of sections 15 and 16 of this License; or
|
||||
|
||||
b) Requiring preservation of specified reasonable legal notices or
|
||||
author attributions in that material or in the Appropriate Legal
|
||||
Notices displayed by works containing it; or
|
||||
|
||||
c) Prohibiting misrepresentation of the origin of that material, or
|
||||
requiring that modified versions of such material be marked in
|
||||
reasonable ways as different from the original version; or
|
||||
|
||||
d) Limiting the use for publicity purposes of names of licensors or
|
||||
authors of the material; or
|
||||
|
||||
e) Declining to grant rights under trademark law for use of some
|
||||
trade names, trademarks, or service marks; or
|
||||
|
||||
f) Requiring indemnification of licensors and authors of that
|
||||
material by anyone who conveys the material (or modified versions of
|
||||
it) with contractual assumptions of liability to the recipient, for
|
||||
any liability that these contractual assumptions directly impose on
|
||||
those licensors and authors.
|
||||
|
||||
All other non-permissive additional terms are considered "further
|
||||
restrictions" within the meaning of section 10. If the Program as you
|
||||
received it, or any part of it, contains a notice stating that it is
|
||||
governed by this License along with a term that is a further
|
||||
restriction, you may remove that term. If a license document contains
|
||||
a further restriction but permits relicensing or conveying under this
|
||||
License, you may add to a covered work material governed by the terms
|
||||
of that license document, provided that the further restriction does
|
||||
not survive such relicensing or conveying.
|
||||
|
||||
If you add terms to a covered work in accord with this section, you
|
||||
must place, in the relevant source files, a statement of the
|
||||
additional terms that apply to those files, or a notice indicating
|
||||
where to find the applicable terms.
|
||||
|
||||
Additional terms, permissive or non-permissive, may be stated in the
|
||||
form of a separately written license, or stated as exceptions;
|
||||
the above requirements apply either way.
|
||||
|
||||
8. Termination.
|
||||
|
||||
You may not propagate or modify a covered work except as expressly
|
||||
provided under this License. Any attempt otherwise to propagate or
|
||||
modify it is void, and will automatically terminate your rights under
|
||||
this License (including any patent licenses granted under the third
|
||||
paragraph of section 11).
|
||||
|
||||
However, if you cease all violation of this License, then your
|
||||
license from a particular copyright holder is reinstated (a)
|
||||
provisionally, unless and until the copyright holder explicitly and
|
||||
finally terminates your license, and (b) permanently, if the copyright
|
||||
holder fails to notify you of the violation by some reasonable means
|
||||
prior to 60 days after the cessation.
|
||||
|
||||
Moreover, your license from a particular copyright holder is
|
||||
reinstated permanently if the copyright holder notifies you of the
|
||||
violation by some reasonable means, this is the first time you have
|
||||
received notice of violation of this License (for any work) from that
|
||||
copyright holder, and you cure the violation prior to 30 days after
|
||||
your receipt of the notice.
|
||||
|
||||
Termination of your rights under this section does not terminate the
|
||||
licenses of parties who have received copies or rights from you under
|
||||
this License. If your rights have been terminated and not permanently
|
||||
reinstated, you do not qualify to receive new licenses for the same
|
||||
material under section 10.
|
||||
|
||||
9. Acceptance Not Required for Having Copies.
|
||||
|
||||
You are not required to accept this License in order to receive or
|
||||
run a copy of the Program. Ancillary propagation of a covered work
|
||||
occurring solely as a consequence of using peer-to-peer transmission
|
||||
to receive a copy likewise does not require acceptance. However,
|
||||
nothing other than this License grants you permission to propagate or
|
||||
modify any covered work. These actions infringe copyright if you do
|
||||
not accept this License. Therefore, by modifying or propagating a
|
||||
covered work, you indicate your acceptance of this License to do so.
|
||||
|
||||
10. Automatic Licensing of Downstream Recipients.
|
||||
|
||||
Each time you convey a covered work, the recipient automatically
|
||||
receives a license from the original licensors, to run, modify and
|
||||
propagate that work, subject to this License. You are not responsible
|
||||
for enforcing compliance by third parties with this License.
|
||||
|
||||
An "entity transaction" is a transaction transferring control of an
|
||||
organization, or substantially all assets of one, or subdividing an
|
||||
organization, or merging organizations. If propagation of a covered
|
||||
work results from an entity transaction, each party to that
|
||||
transaction who receives a copy of the work also receives whatever
|
||||
licenses to the work the party's predecessor in interest had or could
|
||||
give under the previous paragraph, plus a right to possession of the
|
||||
Corresponding Source of the work from the predecessor in interest, if
|
||||
the predecessor has it or can get it with reasonable efforts.
|
||||
|
||||
You may not impose any further restrictions on the exercise of the
|
||||
rights granted or affirmed under this License. For example, you may
|
||||
not impose a license fee, royalty, or other charge for exercise of
|
||||
rights granted under this License, and you may not initiate litigation
|
||||
(including a cross-claim or counterclaim in a lawsuit) alleging that
|
||||
any patent claim is infringed by making, using, selling, offering for
|
||||
sale, or importing the Program or any portion of it.
|
||||
|
||||
11. Patents.
|
||||
|
||||
A "contributor" is a copyright holder who authorizes use under this
|
||||
License of the Program or a work on which the Program is based. The
|
||||
work thus licensed is called the contributor's "contributor version".
|
||||
|
||||
A contributor's "essential patent claims" are all patent claims
|
||||
owned or controlled by the contributor, whether already acquired or
|
||||
hereafter acquired, that would be infringed by some manner, permitted
|
||||
by this License, of making, using, or selling its contributor version,
|
||||
but do not include claims that would be infringed only as a
|
||||
consequence of further modification of the contributor version. For
|
||||
purposes of this definition, "control" includes the right to grant
|
||||
patent sublicenses in a manner consistent with the requirements of
|
||||
this License.
|
||||
|
||||
Each contributor grants you a non-exclusive, worldwide, royalty-free
|
||||
patent license under the contributor's essential patent claims, to
|
||||
make, use, sell, offer for sale, import and otherwise run, modify and
|
||||
propagate the contents of its contributor version.
|
||||
|
||||
In the following three paragraphs, a "patent license" is any express
|
||||
agreement or commitment, however denominated, not to enforce a patent
|
||||
(such as an express permission to practice a patent or covenant not to
|
||||
sue for patent infringement). To "grant" such a patent license to a
|
||||
party means to make such an agreement or commitment not to enforce a
|
||||
patent against the party.
|
||||
|
||||
If you convey a covered work, knowingly relying on a patent license,
|
||||
and the Corresponding Source of the work is not available for anyone
|
||||
to copy, free of charge and under the terms of this License, through a
|
||||
publicly available network server or other readily accessible means,
|
||||
then you must either (1) cause the Corresponding Source to be so
|
||||
available, or (2) arrange to deprive yourself of the benefit of the
|
||||
patent license for this particular work, or (3) arrange, in a manner
|
||||
consistent with the requirements of this License, to extend the patent
|
||||
license to downstream recipients. "Knowingly relying" means you have
|
||||
actual knowledge that, but for the patent license, your conveying the
|
||||
covered work in a country, or your recipient's use of the covered work
|
||||
in a country, would infringe one or more identifiable patents in that
|
||||
country that you have reason to believe are valid.
|
||||
|
||||
If, pursuant to or in connection with a single transaction or
|
||||
arrangement, you convey, or propagate by procuring conveyance of, a
|
||||
covered work, and grant a patent license to some of the parties
|
||||
receiving the covered work authorizing them to use, propagate, modify
|
||||
or convey a specific copy of the covered work, then the patent license
|
||||
you grant is automatically extended to all recipients of the covered
|
||||
work and works based on it.
|
||||
|
||||
A patent license is "discriminatory" if it does not include within
|
||||
the scope of its coverage, prohibits the exercise of, or is
|
||||
conditioned on the non-exercise of one or more of the rights that are
|
||||
specifically granted under this License. You may not convey a covered
|
||||
work if you are a party to an arrangement with a third party that is
|
||||
in the business of distributing software, under which you make payment
|
||||
to the third party based on the extent of your activity of conveying
|
||||
the work, and under which the third party grants, to any of the
|
||||
parties who would receive the covered work from you, a discriminatory
|
||||
patent license (a) in connection with copies of the covered work
|
||||
conveyed by you (or copies made from those copies), or (b) primarily
|
||||
for and in connection with specific products or compilations that
|
||||
contain the covered work, unless you entered into that arrangement,
|
||||
or that patent license was granted, prior to 28 March 2007.
|
||||
|
||||
Nothing in this License shall be construed as excluding or limiting
|
||||
any implied license or other defenses to infringement that may
|
||||
otherwise be available to you under applicable patent law.
|
||||
|
||||
12. No Surrender of Others' Freedom.
|
||||
|
||||
If conditions are imposed on you (whether by court order, agreement or
|
||||
otherwise) that contradict the conditions of this License, they do not
|
||||
excuse you from the conditions of this License. If you cannot convey a
|
||||
covered work so as to satisfy simultaneously your obligations under this
|
||||
License and any other pertinent obligations, then as a consequence you may
|
||||
not convey it at all. For example, if you agree to terms that obligate you
|
||||
to collect a royalty for further conveying from those to whom you convey
|
||||
the Program, the only way you could satisfy both those terms and this
|
||||
License would be to refrain entirely from conveying the Program.
|
||||
|
||||
13. Use with the GNU Affero General Public License.
|
||||
|
||||
Notwithstanding any other provision of this License, you have
|
||||
permission to link or combine any covered work with a work licensed
|
||||
under version 3 of the GNU Affero General Public License into a single
|
||||
combined work, and to convey the resulting work. The terms of this
|
||||
License will continue to apply to the part which is the covered work,
|
||||
but the special requirements of the GNU Affero General Public License,
|
||||
section 13, concerning interaction through a network will apply to the
|
||||
combination as such.
|
||||
|
||||
14. Revised Versions of this License.
|
||||
|
||||
The Free Software Foundation may publish revised and/or new versions of
|
||||
the GNU General Public License from time to time. Such new versions will
|
||||
be similar in spirit to the present version, but may differ in detail to
|
||||
address new problems or concerns.
|
||||
|
||||
Each version is given a distinguishing version number. If the
|
||||
Program specifies that a certain numbered version of the GNU General
|
||||
Public License "or any later version" applies to it, you have the
|
||||
option of following the terms and conditions either of that numbered
|
||||
version or of any later version published by the Free Software
|
||||
Foundation. If the Program does not specify a version number of the
|
||||
GNU General Public License, you may choose any version ever published
|
||||
by the Free Software Foundation.
|
||||
|
||||
If the Program specifies that a proxy can decide which future
|
||||
versions of the GNU General Public License can be used, that proxy's
|
||||
public statement of acceptance of a version permanently authorizes you
|
||||
to choose that version for the Program.
|
||||
|
||||
Later license versions may give you additional or different
|
||||
permissions. However, no additional obligations are imposed on any
|
||||
author or copyright holder as a result of your choosing to follow a
|
||||
later version.
|
||||
|
||||
15. Disclaimer of Warranty.
|
||||
|
||||
THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY
|
||||
APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT
|
||||
HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY
|
||||
OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO,
|
||||
THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
|
||||
PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM
|
||||
IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF
|
||||
ALL NECESSARY SERVICING, REPAIR OR CORRECTION.
|
||||
|
||||
16. Limitation of Liability.
|
||||
|
||||
IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
|
||||
WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS
|
||||
THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY
|
||||
GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE
|
||||
USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF
|
||||
DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD
|
||||
PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS),
|
||||
EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF
|
||||
SUCH DAMAGES.
|
||||
|
||||
17. Interpretation of Sections 15 and 16.
|
||||
|
||||
If the disclaimer of warranty and limitation of liability provided
|
||||
above cannot be given local legal effect according to their terms,
|
||||
reviewing courts shall apply local law that most closely approximates
|
||||
an absolute waiver of all civil liability in connection with the
|
||||
Program, unless a warranty or assumption of liability accompanies a
|
||||
copy of the Program in return for a fee.
|
||||
|
||||
END OF TERMS AND CONDITIONS
|
||||
|
||||
How to Apply These Terms to Your New Programs
|
||||
|
||||
If you develop a new program, and you want it to be of the greatest
|
||||
possible use to the public, the best way to achieve this is to make it
|
||||
free software which everyone can redistribute and change under these terms.
|
||||
|
||||
To do so, attach the following notices to the program. It is safest
|
||||
to attach them to the start of each source file to most effectively
|
||||
state the exclusion of warranty; and each file should have at least
|
||||
the "copyright" line and a pointer to where the full notice is found.
|
||||
|
||||
<one line to give the program's name and a brief idea of what it does.>
|
||||
Copyright (C) <year> <name of author>
|
||||
|
||||
This program is free software: you can redistribute it and/or modify
|
||||
it under the terms of the GNU General Public License as published by
|
||||
the Free Software Foundation, either version 3 of the License, or
|
||||
(at your option) any later version.
|
||||
|
||||
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 General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
Also add information on how to contact you by electronic and paper mail.
|
||||
|
||||
If the program does terminal interaction, make it output a short
|
||||
notice like this when it starts in an interactive mode:
|
||||
|
||||
<program> Copyright (C) <year> <name of author>
|
||||
This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
|
||||
This is free software, and you are welcome to redistribute it
|
||||
under certain conditions; type `show c' for details.
|
||||
|
||||
The hypothetical commands `show w' and `show c' should show the appropriate
|
||||
parts of the General Public License. Of course, your program's commands
|
||||
might be different; for a GUI interface, you would use an "about box".
|
||||
|
||||
You should also get your employer (if you work as a programmer) or school,
|
||||
if any, to sign a "copyright disclaimer" for the program, if necessary.
|
||||
For more information on this, and how to apply and follow the GNU GPL, see
|
||||
<http://www.gnu.org/licenses/>.
|
||||
|
||||
The GNU General Public License does not permit incorporating your program
|
||||
into proprietary programs. If your program is a subroutine library, you
|
||||
may consider it more useful to permit linking proprietary applications with
|
||||
the library. If this is what you want to do, use the GNU Lesser General
|
||||
Public License instead of this License. But first, please read
|
||||
<http://www.gnu.org/philosophy/why-not-lgpl.html>.
|
||||
|
||||
|
||||
**************************************************************************
|
||||
43
MANIFEST.in
Normal file
43
MANIFEST.in
Normal file
@@ -0,0 +1,43 @@
|
||||
include requirements.txt
|
||||
include LICENSE
|
||||
include README.md
|
||||
recursive-include odoo *.css
|
||||
recursive-include odoo *.csv
|
||||
recursive-include odoo *.doc
|
||||
recursive-include odoo *.eml
|
||||
recursive-include odoo *.eot
|
||||
recursive-include odoo *.gif
|
||||
recursive-include odoo *.html
|
||||
recursive-include odoo *.ico
|
||||
recursive-include odoo *.jpeg
|
||||
recursive-include odoo *.jpg
|
||||
recursive-include odoo *.js
|
||||
recursive-include odoo *.less
|
||||
recursive-include odoo *.md
|
||||
recursive-include odoo *.mp3
|
||||
recursive-include odoo *.ogg
|
||||
recursive-include odoo *.otf
|
||||
recursive-include odoo *.pdf
|
||||
recursive-include odoo *.png
|
||||
recursive-include odoo *.po
|
||||
recursive-include odoo *.rml
|
||||
recursive-include odoo *.rng
|
||||
recursive-include odoo *.rst
|
||||
recursive-include odoo *.sass
|
||||
recursive-include odoo *.sql
|
||||
recursive-include odoo *.svg
|
||||
recursive-include odoo *.template
|
||||
recursive-include odoo *.txt
|
||||
recursive-include odoo *.ttf
|
||||
recursive-include odoo *.woff
|
||||
recursive-include odoo *.woff2
|
||||
recursive-include odoo *.wsdl
|
||||
recursive-include odoo *.xls
|
||||
recursive-include odoo *.xsd
|
||||
recursive-include odoo *.xsl
|
||||
recursive-include odoo *.xml
|
||||
recursive-include odoo *.yml
|
||||
recursive-include odoo/addons/l10n_mx_edi *.xslt *.key *.cer *.txt
|
||||
recursive-include odoo/addons/l10n_mx_reports *.xslt
|
||||
recursive-exclude * *.py[co]
|
||||
recursive-exclude * *.hg*
|
||||
9
Makefile
Normal file
9
Makefile
Normal file
@@ -0,0 +1,9 @@
|
||||
# NOTE: please keep your version of sass up to date: sudo gem update
|
||||
.PHONY: watch css
|
||||
SASS_FILES=$(wildcard addons/*/static/src/css/*.sass openerp/addons/*/static/src/css/*.sass)
|
||||
CSS_FILES=$(patsubst %.sass,%.css,${SASS_FILES})
|
||||
css: ${CSS_FILES}
|
||||
%.css: %.sass
|
||||
sass -t expanded --compass --unix-newlines --sourcemap=none $< $@
|
||||
watch:
|
||||
sass -t expanded --compass --unix-newlines --sourcemap=none --watch .:.
|
||||
33
README.md
Normal file
33
README.md
Normal file
@@ -0,0 +1,33 @@
|
||||
[](http://runbot.odoo.com/runbot)
|
||||
[](http://www.odoo.com/documentation/11.0)
|
||||
[](https://www.odoo.com/forum/help-1)
|
||||
[](http://nightly.odoo.com/)
|
||||
|
||||
Odoo
|
||||
----
|
||||
|
||||
Odoo is a suite of web based open source business apps.
|
||||
|
||||
The main Odoo Apps include an <a href="https://www.odoo.com/page/crm">Open Source CRM</a>,
|
||||
<a href="https://www.odoo.com/page/website-builder">Website Builder</a>,
|
||||
<a href="https://www.odoo.com/page/e-commerce">eCommerce</a>,
|
||||
<a href="https://www.odoo.com/page/warehouse">Warehouse Management</a>,
|
||||
<a href="https://www.odoo.com/page/project-management">Project Management</a>,
|
||||
<a href="https://www.odoo.com/page/accounting">Billing & Accounting</a>,
|
||||
<a href="https://www.odoo.com/page/point-of-sale">Point of Sale</a>,
|
||||
<a href="https://www.odoo.com/page/employees">Human Resources</a>,
|
||||
<a href="https://www.odoo.com/page/lead-automation">Marketing</a>,
|
||||
<a href="https://www.odoo.com/page/manufacturing">Manufacturing</a>,
|
||||
<a href="https://www.odoo.com/page/purchase">Purchase Management</a>,
|
||||
<a href="https://www.odoo.com/#apps">...</a>
|
||||
|
||||
Odoo Apps can be used as stand-alone applications, but they also integrate seamlessly so you get
|
||||
a full-featured <a href="https://www.odoo.com">Open Source ERP</a> when you install several Apps.
|
||||
|
||||
|
||||
Getting started with Odoo
|
||||
-------------------------
|
||||
For a standard installation please follow the <a href="https://www.odoo.com/documentation/11.0/setup/install.html">Setup instructions</a>
|
||||
from the documentation.
|
||||
|
||||
Then follow <a href="https://www.odoo.com/documentation/11.0/tutorials.html">the developer tutorials</a>
|
||||
68
addons/account/README.md
Normal file
68
addons/account/README.md
Normal file
@@ -0,0 +1,68 @@
|
||||
Odoo Accounting
|
||||
---------------
|
||||
|
||||
The Odoo <a href="https://www.odoo.com/page/accounting">Open Source Accounting</a> app allows a better way to
|
||||
collaborate with your accountants, your customers and control your suppliers.
|
||||
|
||||
Activate features on demand, from integrated analytic accounting to budget,
|
||||
assets and multiple companies consolidation.
|
||||
|
||||
A Smart User Interface
|
||||
----------------------
|
||||
|
||||
Record transactions in a few clicks and easily manage all financial activities
|
||||
in one place. Odoo's user interface is designed with productivity in mind.
|
||||
|
||||
A Better Way To Work – Together
|
||||
-------------------------------
|
||||
|
||||
Share access to your latest business numbers with your team and your accountant
|
||||
– so everyone is up to speed. From work, home or on the go.
|
||||
|
||||
Connect Your Bank Accounts
|
||||
--------------------------
|
||||
|
||||
Import your bank statements and reconcile them in just a few clicks. Prepare
|
||||
payment orders based on your supplier invoices and payment terms.
|
||||
|
||||
Electronic invoicing and automated follow-ups
|
||||
---------------------------------------------
|
||||
|
||||
Create and send professional invoices & get paid online. Get rid of the stress
|
||||
of having to constantly remind your debtors. Simply set-up and automate
|
||||
follow-ups to get paid quickly.
|
||||
|
||||
Sales Integration
|
||||
-----------------
|
||||
|
||||
Automatically create invoices from sales orders, delivery orders or base them
|
||||
on time and material. Re-invoice expenses on projects to your customer in just
|
||||
a few clicks.
|
||||
|
||||
|
||||
Purchase Integration
|
||||
--------------------
|
||||
|
||||
Control supplier invocies based on purchase orders. Get real-time inventory
|
||||
valuation reports automatically posted in your accounts.
|
||||
|
||||
Multi-Level Analytic Accounting
|
||||
-------------------------------
|
||||
|
||||
Integrate your analytic accounting operations with timesheets, projects,
|
||||
invoices, expenses, etc. No need to record transactions, all analytic entries
|
||||
are posted automatically following your business rules.
|
||||
|
||||
Everything you need to grow
|
||||
---------------------------
|
||||
|
||||
Manage your assets, track expenses, control budgets, multi-level analytic
|
||||
accounting; Odoo has all the features you need to sustain all your business
|
||||
activities.
|
||||
|
||||
Scale With Your Organization
|
||||
----------------------------
|
||||
|
||||
Odoo supports multiple currencies, multiple users with different access rights,
|
||||
multiple companies with real time consolidation and unlimited analytic plans.
|
||||
|
||||
51
addons/account/__init__.py
Normal file
51
addons/account/__init__.py
Normal file
@@ -0,0 +1,51 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
# Part of Odoo. See LICENSE file for full copyright and licensing details.
|
||||
|
||||
from . import controllers
|
||||
from . import models
|
||||
from . import wizard
|
||||
from . import report
|
||||
|
||||
from odoo import api, SUPERUSER_ID
|
||||
|
||||
SYSCOHADA_LIST = ['BJ', 'BF', 'CM', 'CF', 'KM', 'CG', 'CI', 'GA', 'GN', 'GW', 'GQ', 'ML', 'NE', 'CD', 'SN', 'TD', 'TG']
|
||||
|
||||
def _auto_install_l10n(cr, registry):
|
||||
#check the country of the main company (only) and eventually load some module needed in that country
|
||||
env = api.Environment(cr, SUPERUSER_ID, {})
|
||||
country_code = env.user.company_id.country_id.code
|
||||
if country_code:
|
||||
#auto install localization module(s) if available
|
||||
module_list = []
|
||||
if country_code in SYSCOHADA_LIST:
|
||||
#countries using OHADA Chart of Accounts
|
||||
module_list.append('l10n_syscohada')
|
||||
elif country_code == 'GB':
|
||||
module_list.append('l10n_uk')
|
||||
elif country_code == 'DE':
|
||||
module_list.append('l10n_de_skr03')
|
||||
module_list.append('l10n_de_skr04')
|
||||
else:
|
||||
if env['ir.module.module'].search([('name', '=', 'l10n_' + country_code.lower())]):
|
||||
module_list.append('l10n_' + country_code.lower())
|
||||
else:
|
||||
module_list.append('l10n_generic_coa')
|
||||
if country_code == 'US':
|
||||
module_list.append('account_plaid')
|
||||
module_list.append('account_check_printing')
|
||||
if country_code in ['US', 'AU', 'NZ', 'CA', 'CO', 'EC', 'ES', 'FR', 'IN', 'MX', 'UK']:
|
||||
module_list.append('account_yodlee')
|
||||
if country_code in SYSCOHADA_LIST + [
|
||||
'AT', 'BE', 'CA', 'CO', 'DE', 'EC', 'ES', 'ET', 'FR', 'GR', 'IT', 'LU', 'MX', 'NL', 'NO',
|
||||
'PL', 'PT', 'RO', 'SI', 'TR', 'UK', 'VE', 'VN'
|
||||
]:
|
||||
module_list.append('base_vat')
|
||||
|
||||
#european countries will be using SEPA
|
||||
europe = env.ref('base.europe', raise_if_not_found=False)
|
||||
if europe:
|
||||
europe_country_codes = [x.code for x in europe.country_ids]
|
||||
if country_code in europe_country_codes:
|
||||
module_list.append('account_sepa')
|
||||
module_ids = env['ir.module.module'].search([('name', 'in', module_list), ('state', '=', 'uninstalled')])
|
||||
module_ids.sudo().button_install()
|
||||
83
addons/account/__manifest__.py
Normal file
83
addons/account/__manifest__.py
Normal file
@@ -0,0 +1,83 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
# Part of Odoo. See LICENSE file for full copyright and licensing details.
|
||||
{
|
||||
'name' : 'Invoicing',
|
||||
'version' : '1.1',
|
||||
'summary': 'Send Invoices and Track Payments',
|
||||
'sequence': 30,
|
||||
'description': """
|
||||
Core mechanisms for the accounting modules. To display the menuitems, install the module account_invoicing.
|
||||
""",
|
||||
'category': 'Accounting',
|
||||
'website': 'https://www.odoo.com/page/billing',
|
||||
'images' : ['images/accounts.jpeg','images/bank_statement.jpeg','images/cash_register.jpeg','images/chart_of_accounts.jpeg','images/customer_invoice.jpeg','images/journal_entries.jpeg'],
|
||||
'depends' : ['base_setup', 'product', 'analytic', 'web_planner', 'portal'],
|
||||
'data': [
|
||||
'security/account_security.xml',
|
||||
'security/ir.model.access.csv',
|
||||
'data/data_account_type.xml',
|
||||
'data/account_data.xml',
|
||||
'views/account_menuitem.xml',
|
||||
'views/account_payment_view.xml',
|
||||
'wizard/account_reconcile_view.xml',
|
||||
'wizard/account_unreconcile_view.xml',
|
||||
'wizard/account_move_reversal_view.xml',
|
||||
'views/account_view.xml',
|
||||
'views/account_report.xml',
|
||||
'data/mail_template_data.xml',
|
||||
'wizard/account_invoice_refund_view.xml',
|
||||
'wizard/account_validate_move_view.xml',
|
||||
'wizard/account_invoice_state_view.xml',
|
||||
'wizard/pos_box.xml',
|
||||
'views/account_end_fy.xml',
|
||||
'views/account_invoice_view.xml',
|
||||
'views/partner_view.xml',
|
||||
'views/product_view.xml',
|
||||
'views/account_analytic_view.xml',
|
||||
'views/account_tip_data.xml',
|
||||
'views/account.xml',
|
||||
'views/report_invoice.xml',
|
||||
'report/account_invoice_report_view.xml',
|
||||
'views/report_overdue.xml',
|
||||
'views/account_cash_rounding_view.xml',
|
||||
'wizard/account_report_common_view.xml',
|
||||
'wizard/account_report_print_journal_view.xml',
|
||||
'views/report_journal.xml',
|
||||
'wizard/account_report_partner_ledger_view.xml',
|
||||
'views/report_partnerledger.xml',
|
||||
'wizard/account_report_general_ledger_view.xml',
|
||||
'views/report_generalledger.xml',
|
||||
'wizard/account_report_trial_balance_view.xml',
|
||||
'views/report_trialbalance.xml',
|
||||
'views/account_financial_report_data.xml',
|
||||
'wizard/account_financial_report_view.xml',
|
||||
'views/report_financial.xml',
|
||||
'wizard/account_report_aged_partner_balance_view.xml',
|
||||
'views/report_agedpartnerbalance.xml',
|
||||
'views/tax_adjustments.xml',
|
||||
'wizard/wizard_tax_adjustments_view.xml',
|
||||
'views/res_config_settings_views.xml',
|
||||
'views/web_planner_data.xml',
|
||||
'views/account_journal_dashboard_view.xml',
|
||||
'views/account_portal_templates.xml',
|
||||
'report/account_report_payment_receipt_templates.xml',
|
||||
'data/payment_receipt_data.xml',
|
||||
'wizard/setup_wizards_view.xml',
|
||||
'views/account_dashboard_setup_bar.xml',
|
||||
'wizard/account_report_tax_view.xml',
|
||||
'views/report_tax.xml',
|
||||
],
|
||||
'demo': [
|
||||
'demo/account_demo.xml',
|
||||
],
|
||||
'qweb': [
|
||||
"static/src/xml/account_reconciliation.xml",
|
||||
"static/src/xml/account_payment.xml",
|
||||
"static/src/xml/account_report_backend.xml",
|
||||
"static/src/xml/account_dashboard_setup_bar.xml",
|
||||
],
|
||||
'installable': True,
|
||||
'application': False,
|
||||
'auto_install': False,
|
||||
'post_init_hook': '_auto_install_l10n',
|
||||
}
|
||||
5
addons/account/controllers/__init__.py
Normal file
5
addons/account/controllers/__init__.py
Normal file
@@ -0,0 +1,5 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
# Part of Odoo. See LICENSE file for full copyright and licensing details.
|
||||
|
||||
from . import mail
|
||||
from . import portal
|
||||
29
addons/account/controllers/mail.py
Normal file
29
addons/account/controllers/mail.py
Normal file
@@ -0,0 +1,29 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
# Part of Odoo. See LICENSE file for full copyright and licensing details.
|
||||
|
||||
import werkzeug
|
||||
|
||||
from odoo.addons.mail.controllers.main import MailController
|
||||
from odoo.exceptions import AccessError
|
||||
from odoo.http import request
|
||||
from odoo.tools.misc import consteq
|
||||
|
||||
|
||||
class MailController(MailController):
|
||||
|
||||
def _redirect_to_record(cls, model, res_id, access_token=None):
|
||||
# If the current user doesn't have access to the invoice, but provided
|
||||
# a valid access token, redirect him to the front-end view.
|
||||
if model == 'account.invoice' and res_id and access_token:
|
||||
uid = request.session.uid or request.env.ref('base.public_user').id
|
||||
record_sudo = request.env[model].sudo().browse(res_id).exists()
|
||||
try:
|
||||
record_sudo.sudo(uid).check_access_rights('read')
|
||||
record_sudo.sudo(uid).check_access_rule('read')
|
||||
except AccessError:
|
||||
if record_sudo.access_token and consteq(record_sudo.access_token, access_token):
|
||||
record_action = record_sudo.with_context(
|
||||
force_website=True).get_access_action(uid)
|
||||
if record_action['type'] == 'ir.actions.act_url':
|
||||
return werkzeug.utils.redirect(record_action['url'])
|
||||
return super(MailController, cls)._redirect_to_record(model, res_id, access_token=access_token)
|
||||
150
addons/account/controllers/portal.py
Normal file
150
addons/account/controllers/portal.py
Normal file
@@ -0,0 +1,150 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
# Part of Odoo. See LICENSE file for full copyright and licensing details.
|
||||
|
||||
from odoo import http, _
|
||||
from odoo.addons.portal.controllers.portal import CustomerPortal, pager as portal_pager
|
||||
from odoo.exceptions import AccessError
|
||||
from odoo.http import request
|
||||
from odoo.tools import consteq
|
||||
|
||||
|
||||
class PortalAccount(CustomerPortal):
|
||||
|
||||
def _get_account_invoice_domain(self):
|
||||
partner = request.env.user.partner_id
|
||||
domain = [
|
||||
('type', 'in', ['out_invoice', 'out_refund']),
|
||||
('message_partner_ids', 'child_of', [partner.commercial_partner_id.id]),
|
||||
('state', 'in', ['open', 'paid', 'cancel'])
|
||||
]
|
||||
return domain
|
||||
|
||||
def _prepare_portal_layout_values(self):
|
||||
values = super(PortalAccount, self)._prepare_portal_layout_values()
|
||||
invoice_count = request.env['account.invoice'].search_count(self._get_account_invoice_domain())
|
||||
values['invoice_count'] = invoice_count
|
||||
return values
|
||||
|
||||
# ------------------------------------------------------------
|
||||
# My Invoices
|
||||
# ------------------------------------------------------------
|
||||
|
||||
def _invoice_check_access(self, invoice_id, access_token=None):
|
||||
invoice = request.env['account.invoice'].browse([invoice_id])
|
||||
invoice_sudo = invoice.sudo()
|
||||
try:
|
||||
invoice.check_access_rights('read')
|
||||
invoice.check_access_rule('read')
|
||||
except AccessError:
|
||||
if not access_token or not consteq(invoice_sudo.access_token, access_token):
|
||||
raise
|
||||
return invoice_sudo
|
||||
|
||||
def _invoice_get_page_view_values(self, invoice, access_token, **kwargs):
|
||||
values = {
|
||||
'page_name': 'invoice',
|
||||
'invoice': invoice,
|
||||
}
|
||||
if access_token:
|
||||
values['no_breadcrumbs'] = True
|
||||
values['access_token'] = access_token
|
||||
|
||||
if kwargs.get('error'):
|
||||
values['error'] = kwargs['error']
|
||||
if kwargs.get('warning'):
|
||||
values['warning'] = kwargs['warning']
|
||||
if kwargs.get('success'):
|
||||
values['success'] = kwargs['success']
|
||||
|
||||
return values
|
||||
|
||||
@http.route(['/my/invoices', '/my/invoices/page/<int:page>'], type='http', auth="user", website=True)
|
||||
def portal_my_invoices(self, page=1, date_begin=None, date_end=None, sortby=None, **kw):
|
||||
values = self._prepare_portal_layout_values()
|
||||
partner = request.env.user.partner_id
|
||||
AccountInvoice = request.env['account.invoice']
|
||||
|
||||
domain = self._get_account_invoice_domain()
|
||||
|
||||
searchbar_sortings = {
|
||||
'date': {'label': _('Invoice Date'), 'order': 'date_invoice desc'},
|
||||
'duedate': {'label': _('Due Date'), 'order': 'date_due desc'},
|
||||
'name': {'label': _('Reference'), 'order': 'name desc'},
|
||||
'state': {'label': _('Status'), 'order': 'state'},
|
||||
}
|
||||
# default sort by order
|
||||
if not sortby:
|
||||
sortby = 'date'
|
||||
order = searchbar_sortings[sortby]['order']
|
||||
|
||||
archive_groups = self._get_archive_groups('account.invoice', domain)
|
||||
if date_begin and date_end:
|
||||
domain += [('create_date', '>', date_begin), ('create_date', '<=', date_end)]
|
||||
|
||||
# count for pager
|
||||
invoice_count = AccountInvoice.search_count(domain)
|
||||
# pager
|
||||
pager = portal_pager(
|
||||
url="/my/invoices",
|
||||
url_args={'date_begin': date_begin, 'date_end': date_end, 'sortby': sortby},
|
||||
total=invoice_count,
|
||||
page=page,
|
||||
step=self._items_per_page
|
||||
)
|
||||
# content according to pager and archive selected
|
||||
invoices = AccountInvoice.search(domain, order=order, limit=self._items_per_page, offset=pager['offset'])
|
||||
values.update({
|
||||
'date': date_begin,
|
||||
'invoices': invoices,
|
||||
'page_name': 'invoice',
|
||||
'pager': pager,
|
||||
'archive_groups': archive_groups,
|
||||
'default_url': '/my/invoices',
|
||||
'searchbar_sortings': searchbar_sortings,
|
||||
'sortby': sortby,
|
||||
})
|
||||
return request.render("account.portal_my_invoices", values)
|
||||
|
||||
@http.route(['/my/invoices/<int:invoice_id>'], type='http', auth="public", website=True)
|
||||
def portal_my_invoice_detail(self, invoice_id, access_token=None, **kw):
|
||||
try:
|
||||
invoice_sudo = self._invoice_check_access(invoice_id, access_token)
|
||||
except AccessError:
|
||||
return request.redirect('/my')
|
||||
|
||||
values = self._invoice_get_page_view_values(invoice_sudo, access_token, **kw)
|
||||
return request.render("account.portal_invoice_page", values)
|
||||
|
||||
@http.route(['/my/invoices/pdf/<int:invoice_id>'], type='http', auth="public", website=True)
|
||||
def portal_my_invoice_report(self, invoice_id, access_token=None, **kw):
|
||||
try:
|
||||
invoice_sudo = self._invoice_check_access(invoice_id, access_token)
|
||||
except AccessError:
|
||||
return request.redirect('/my')
|
||||
|
||||
# print report as sudo, since it require access to taxes, payment term, ... and portal
|
||||
# does not have those access rights.
|
||||
pdf = request.env.ref('account.account_invoices').sudo().render_qweb_pdf([invoice_sudo.id])[0]
|
||||
pdfhttpheaders = [
|
||||
('Content-Type', 'application/pdf'),
|
||||
('Content-Length', len(pdf)),
|
||||
]
|
||||
return request.make_response(pdf, headers=pdfhttpheaders)
|
||||
|
||||
# ------------------------------------------------------------
|
||||
# My Home
|
||||
# ------------------------------------------------------------
|
||||
|
||||
def details_form_validate(self, data):
|
||||
error, error_message = super(PortalAccount, self).details_form_validate(data)
|
||||
# prevent VAT/name change if invoices exist
|
||||
partner = request.env['res.users'].browse(request.uid).partner_id
|
||||
invoices = request.env['account.invoice'].sudo().search_count([('partner_id', '=', partner.id), ('state', 'not in', ['draft', 'cancel'])])
|
||||
if invoices:
|
||||
if 'vat' in data and (data['vat'] or False) != (partner.vat or False):
|
||||
error['vat'] = 'error'
|
||||
error_message.append(_('Changing VAT number is not allowed once invoices have been issued for your account. Please contact us directly for this operation.'))
|
||||
if 'name' in data and (data['name'] or False) != (partner.name or False):
|
||||
error['name'] = 'error'
|
||||
error_message.append(_('Changing your name is not allowed once invoices have been issued for your account. Please contact us directly for this operation.'))
|
||||
return error, error_message
|
||||
164
addons/account/data/account_data.xml
Normal file
164
addons/account/data/account_data.xml
Normal file
@@ -0,0 +1,164 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<odoo>
|
||||
<data noupdate="1">
|
||||
|
||||
<!-- TAGS FOR CASH FLOW STATEMENT -->
|
||||
|
||||
<record id="account_tag_operating" model="account.account.tag">
|
||||
<field name="name">Operating Activities</field>
|
||||
<field name="applicability">accounts</field>
|
||||
</record>
|
||||
<record id="account_tag_financing" model="account.account.tag">
|
||||
<field name="name">Financing Activities</field>
|
||||
<field name="applicability">accounts</field>
|
||||
</record>
|
||||
<record id="account_tag_investing" model="account.account.tag">
|
||||
<field name="name">Investing & Extraordinary Activities</field>
|
||||
<field name="applicability">accounts</field>
|
||||
</record>
|
||||
|
||||
<!--
|
||||
Payment terms
|
||||
-->
|
||||
<record id="account_payment_term_immediate" model="account.payment.term">
|
||||
<field name="name">Immediate Payment</field>
|
||||
<field name="note">Payment terms: Immediate Payment</field>
|
||||
</record>
|
||||
|
||||
<record id="account_payment_term_15days" model="account.payment.term">
|
||||
<field name="name">15 Days</field>
|
||||
<field name="note">Payment terms: 15 Days</field>
|
||||
<field name="line_ids" eval="[(5, 0), (0, 0, {'value': 'balance', 'value_amount': 0.0, 'sequence': 500, 'days': 15, 'option': 'day_after_invoice_date'})]"/>
|
||||
</record>
|
||||
|
||||
<record forcecreate="True" id="decimal_payment" model="decimal.precision">
|
||||
<field name="name">Payment Terms</field>
|
||||
<field name="digits">6</field>
|
||||
</record>
|
||||
|
||||
<record id="account_payment_term_net" model="account.payment.term">
|
||||
<field name="name">30 Net Days</field>
|
||||
<field name="note">Payment terms: 30 Net Days</field>
|
||||
<field name="line_ids" eval="[(5, 0), (0, 0, {'value': 'balance', 'value_amount': 0.0, 'sequence': 500, 'days': 30, 'option': 'day_after_invoice_date'})]"/>
|
||||
</record>
|
||||
|
||||
<!--
|
||||
Account Statement Sequences
|
||||
-->
|
||||
<record id="sequence_reconcile_seq" model="ir.sequence">
|
||||
<field name="name">Account reconcile sequence</field>
|
||||
<field name="code">account.reconcile</field>
|
||||
<field name="prefix">A</field>
|
||||
<field eval="1" name="number_next"/>
|
||||
<field eval="1" name="number_increment"/>
|
||||
<field eval="False" name="company_id"/>
|
||||
</record>
|
||||
<!--
|
||||
Invoice requests (deprecated)
|
||||
-->
|
||||
<record id="req_link_invoice" model="res.request.link">
|
||||
<field name="name">Invoice</field>
|
||||
<field name="object">account.invoice</field>
|
||||
</record>
|
||||
|
||||
<!-- Account-related subtypes for messaging / Chatter -->
|
||||
<record id="mt_invoice_validated" model="mail.message.subtype">
|
||||
<field name="name">Validated</field>
|
||||
<field name="res_model">account.invoice</field>
|
||||
<field name="default" eval="False"/>
|
||||
<field name="description">Invoice validated</field>
|
||||
</record>
|
||||
<record id="mt_invoice_paid" model="mail.message.subtype">
|
||||
<field name="name">Paid</field>
|
||||
<field name="res_model">account.invoice</field>
|
||||
<field name="default" eval="False"/>
|
||||
<field name="description">Invoice paid</field>
|
||||
</record>
|
||||
<record id="mt_invoice_created" model="mail.message.subtype">
|
||||
<field name="name">Invoice Created</field>
|
||||
<field name="res_model">account.invoice</field>
|
||||
<field name="default" eval="False"/>
|
||||
<field name="hidden" eval="True"/>
|
||||
<field name="description">Invoice Created</field>
|
||||
</record>
|
||||
|
||||
<!-- Payment methods -->
|
||||
<record id="account_payment_method_manual_in" model="account.payment.method">
|
||||
<field name="name">Manual</field>
|
||||
<field name="code">manual</field>
|
||||
<field name="payment_type">inbound</field>
|
||||
</record>
|
||||
<record id="account_payment_method_manual_out" model="account.payment.method">
|
||||
<field name="name">Manual</field>
|
||||
<field name="code">manual</field>
|
||||
<field name="payment_type">outbound</field>
|
||||
</record>
|
||||
|
||||
<!-- Payment sequences -->
|
||||
<record id="sequence_payment_customer_invoice" model="ir.sequence">
|
||||
<field name="name">Payments customer invoices sequence</field>
|
||||
<field name="code">account.payment.customer.invoice</field>
|
||||
<field name="prefix">CUST.IN/%(range_year)s/</field>
|
||||
<field eval="1" name="number_next"/>
|
||||
<field eval="1" name="number_increment"/>
|
||||
<field eval="True" name="use_date_range"/>
|
||||
<field eval="False" name="company_id"/>
|
||||
<field name="padding">4</field>
|
||||
</record>
|
||||
<record id="sequence_payment_customer_refund" model="ir.sequence">
|
||||
<field name="name">Payments customer credit notes sequence</field>
|
||||
<field name="code">account.payment.customer.refund</field>
|
||||
<field name="prefix">CUST.OUT/%(range_year)s/</field>
|
||||
<field eval="1" name="number_next"/>
|
||||
<field eval="1" name="number_increment"/>
|
||||
<field eval="True" name="use_date_range"/>
|
||||
<field eval="False" name="company_id"/>
|
||||
<field name="padding">4</field>
|
||||
</record>
|
||||
<record id="sequence_payment_supplier_invoice" model="ir.sequence">
|
||||
<field name="name">Payments supplier invoices sequence</field>
|
||||
<field name="code">account.payment.supplier.invoice</field>
|
||||
<field name="prefix">SUPP.OUT/%(range_year)s/</field>
|
||||
<field eval="1" name="number_next"/>
|
||||
<field eval="1" name="number_increment"/>
|
||||
<field eval="True" name="use_date_range"/>
|
||||
<field eval="False" name="company_id"/>
|
||||
<field name="padding">4</field>
|
||||
</record>
|
||||
<record id="sequence_payment_supplier_refund" model="ir.sequence">
|
||||
<field name="name">Payments supplier credit notes sequence</field>
|
||||
<field name="code">account.payment.supplier.refund</field>
|
||||
<field name="prefix">SUPP.IN/%(range_year)s/</field>
|
||||
<field eval="1" name="number_next"/>
|
||||
<field eval="1" name="number_increment"/>
|
||||
<field eval="True" name="use_date_range"/>
|
||||
<field eval="False" name="company_id"/>
|
||||
<field name="padding">4</field>
|
||||
</record>
|
||||
<record id="sequence_payment_transfer" model="ir.sequence">
|
||||
<field name="name">Payments transfer sequence</field>
|
||||
<field name="code">account.payment.transfer</field>
|
||||
<field name="prefix">TRANS/%(range_year)s/</field>
|
||||
<field eval="1" name="number_next"/>
|
||||
<field eval="1" name="number_increment"/>
|
||||
<field eval="True" name="use_date_range"/>
|
||||
<field eval="False" name="company_id"/>
|
||||
<field name="padding">4</field>
|
||||
</record>
|
||||
|
||||
<!-- Account Tax Group -->
|
||||
<record id="tax_group_taxes" model="account.tax.group">
|
||||
<field name="name">Taxes</field>
|
||||
<field name="sequence">0</field>
|
||||
</record>
|
||||
|
||||
<!-- Partner Trust Property -->
|
||||
<record forcecreate="True" id="default_followup_trust" model="ir.property">
|
||||
<field name="name">Followup Trust Property</field>
|
||||
<field name="fields_id" search="[('model', '=', 'res.partner'), ('name', '=', 'trust')]"/>
|
||||
<field name="value">normal</field>
|
||||
<field name="type">selection</field>
|
||||
</record>
|
||||
|
||||
</data>
|
||||
</odoo>
|
||||
85
addons/account/data/data_account_type.xml
Normal file
85
addons/account/data/data_account_type.xml
Normal file
@@ -0,0 +1,85 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<odoo>
|
||||
<data noupdate="1">
|
||||
<!-- account.account.type -->
|
||||
<record model="account.account.type" id="data_account_type_receivable">
|
||||
<field name="name">Receivable</field>
|
||||
<field name="type">receivable</field>
|
||||
<field name="include_initial_balance" eval="True"/>
|
||||
</record>
|
||||
<record model="account.account.type" id="data_account_type_payable">
|
||||
<field name="name">Payable</field>
|
||||
<field name="type">payable</field>
|
||||
<field name="include_initial_balance" eval="True"/>
|
||||
</record>
|
||||
<record model="account.account.type" id="data_account_type_liquidity">
|
||||
<field name="name">Bank and Cash</field>
|
||||
<field name="type">liquidity</field>
|
||||
<field name="include_initial_balance" eval="True"/>
|
||||
</record>
|
||||
<record model="account.account.type" id="data_account_type_credit_card">
|
||||
<field name="name">Credit Card</field>
|
||||
<field name="type">liquidity</field>
|
||||
<field name="include_initial_balance" eval="True"/>
|
||||
</record>
|
||||
<record model="account.account.type" id="data_account_type_current_assets">
|
||||
<field name="name">Current Assets</field>
|
||||
<field name="type">other</field>
|
||||
<field name="include_initial_balance" eval="True"/>
|
||||
</record>
|
||||
<record model="account.account.type" id="data_account_type_non_current_assets">
|
||||
<field name="name">Non-current Assets</field>
|
||||
<field name="type">other</field>
|
||||
<field name="include_initial_balance" eval="True"/>
|
||||
</record>
|
||||
<record model="account.account.type" id="data_account_type_prepayments">
|
||||
<field name="name">Prepayments</field>
|
||||
<field name="type">other</field>
|
||||
<field name="include_initial_balance" eval="True"/>
|
||||
</record>
|
||||
<record model="account.account.type" id="data_account_type_fixed_assets">
|
||||
<field name="name">Fixed Assets</field>
|
||||
<field name="type">other</field>
|
||||
<field name="include_initial_balance" eval="True"/>
|
||||
</record>
|
||||
<record model="account.account.type" id="data_account_type_current_liabilities">
|
||||
<field name="name">Current Liabilities</field>
|
||||
<field name="type">other</field>
|
||||
<field name="include_initial_balance" eval="True"/>
|
||||
</record>
|
||||
<record model="account.account.type" id="data_account_type_non_current_liabilities">
|
||||
<field name="name">Non-current Liabilities</field>
|
||||
<field name="type">other</field>
|
||||
<field name="include_initial_balance" eval="True"/>
|
||||
</record>
|
||||
<record model="account.account.type" id="data_account_type_equity">
|
||||
<field name="name">Equity</field>
|
||||
<field name="include_initial_balance" eval="True"/>
|
||||
</record>
|
||||
<record model="account.account.type" id="data_unaffected_earnings">
|
||||
<field name="name">Current Year Earnings</field>
|
||||
<field name="include_initial_balance" eval="True"/>
|
||||
</record>
|
||||
<record model="account.account.type" id="data_account_type_other_income">
|
||||
<field name="name">Other Income</field>
|
||||
<field name="type">other</field>
|
||||
</record>
|
||||
<record model="account.account.type" id="data_account_type_revenue">
|
||||
<field name="name">Income</field>
|
||||
<field name="type">other</field>
|
||||
</record>
|
||||
<record model="account.account.type" id="data_account_type_depreciation">
|
||||
<field name="name">Depreciation</field>
|
||||
<field name="type">other</field>
|
||||
</record>
|
||||
<record model="account.account.type" id="data_account_type_expenses">
|
||||
<field name="name">Expenses</field>
|
||||
<field name="type">other</field>
|
||||
</record>
|
||||
<record model="account.account.type" id="data_account_type_direct_costs">
|
||||
<field name="name">Cost of Revenue</field>
|
||||
<field name="type">other</field>
|
||||
</record>
|
||||
</data>
|
||||
</odoo>
|
||||
|
||||
140
addons/account/data/mail_template_data.xml
Normal file
140
addons/account/data/mail_template_data.xml
Normal file
@@ -0,0 +1,140 @@
|
||||
<?xml version="1.0" ?>
|
||||
<odoo>
|
||||
|
||||
<!-- Mail template are declared in a NOUPDATE block
|
||||
so users can freely customize/delete them -->
|
||||
<data noupdate="1">
|
||||
<!--Email template -->
|
||||
<record id="email_template_edi_invoice" model="mail.template">
|
||||
<field name="name">Invoicing: Invoice email</field>
|
||||
<field name="email_from">${(object.user_id.email and '%s <%s>' % (object.user_id.name, object.user_id.email) or '')|safe}</field>
|
||||
<field name="subject">${object.company_id.name} Invoice (Ref ${object.number or 'n/a'})</field>
|
||||
<field name="partner_to">${object.partner_id.id}</field>
|
||||
<field name="model_id" ref="account.model_account_invoice"/>
|
||||
<field name="auto_delete" eval="True"/>
|
||||
<field name="report_template" ref="account_invoices"/>
|
||||
<field name="report_name">Invoice_${(object.number or '').replace('/','_')}_${object.state == 'draft' and 'draft' or ''}</field>
|
||||
<field name="lang">${object.partner_id.lang}</field>
|
||||
<field name="body_html" type="html">
|
||||
<div>
|
||||
<p>Dear ${object.partner_id.name}
|
||||
% set access_action = object.with_context(force_website=True).get_access_action()
|
||||
% set is_online = access_action and access_action['type'] == 'ir.actions.act_url'
|
||||
% set access_url = object.get_mail_url()
|
||||
|
||||
% if object.partner_id.parent_id:
|
||||
(<i>${object.partner_id.parent_id.name}</i>)
|
||||
% endif
|
||||
,</p>
|
||||
<p>Here is, in attachment, your
|
||||
% if object.number:
|
||||
invoice <strong>${object.number}</strong>
|
||||
% else:
|
||||
invoice
|
||||
% endif
|
||||
% if object.origin:
|
||||
(with reference: ${object.origin})
|
||||
% endif
|
||||
amounting in <strong>${object.amount_total} ${object.currency_id.name}</strong>
|
||||
from ${object.company_id.name}.
|
||||
</p>
|
||||
|
||||
% if is_online:
|
||||
<br/><br/>
|
||||
<center>
|
||||
<a href="${access_url}" style="background-color: #1abc9c; padding: 20px; text-decoration: none; color: #fff; border-radius: 5px; font-size: 16px;" class="o_default_snippet_text">View Invoice</a>
|
||||
</center>
|
||||
% endif
|
||||
<br/><br/>
|
||||
|
||||
% if object.state=='paid':
|
||||
<p>This invoice is already paid.</p>
|
||||
% else:
|
||||
<p>Please remit payment at your earliest convenience.</p>
|
||||
% endif
|
||||
|
||||
<p>Thank you,</p>
|
||||
<p style="color:#888888">
|
||||
% if object.user_id and object.user_id.signature:
|
||||
${object.user_id.signature | safe}
|
||||
% endif
|
||||
</p>
|
||||
</div></field>
|
||||
</record>
|
||||
|
||||
<!--Default Notification Email template for invoices-->
|
||||
<record id="account.mail_template_data_notification_email_account_invoice" model="mail.template">
|
||||
<field name="name">Account: Invoice notification header</field>
|
||||
<field name="subject">${object.subject}</field>
|
||||
<field name="model_id" ref="mail.model_mail_message"/>
|
||||
<field name="auto_delete" eval="True"/>
|
||||
<field name="body_html" type="html">
|
||||
<div>
|
||||
% set record = ctx.get('record')
|
||||
% set company = record and record.company_id or user.company_id
|
||||
<table border="0" width="100%" cellpadding="0" bgcolor="#ededed" style="padding: 20px; background-color: #ededed; border-collapse:separate;" summary="o_mail_notification">
|
||||
<tbody>
|
||||
<!-- HEADER -->
|
||||
<tr>
|
||||
<td align="center" style="min-width: 590px;">
|
||||
<table width="590" border="0" cellpadding="0" bgcolor="#875A7B" style="min-width: 590px; background-color: rgb(135,90,123); padding: 20px; border-collapse:separate;">
|
||||
<tr>
|
||||
<td valign="middle">
|
||||
<span style="font-size:20px; color:white; font-weight: bold;">
|
||||
Invoice ${object.record_name}
|
||||
</span>
|
||||
</td>
|
||||
<td valign="middle" align="right">
|
||||
<img src="/logo.png?company=${company.id}" style="padding: 0px; margin: 0px; height: auto; width: 80px;" alt="${company.name}"/>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</td>
|
||||
</tr>
|
||||
<!-- CONTENT -->
|
||||
<tr>
|
||||
<td align="center" style="min-width: 590px;">
|
||||
<table width="590" border="0" cellpadding="0" bgcolor="#ffffff" style="min-width: 590px; background-color: rgb(255, 255, 255); padding: 20px; border-collapse:separate;">
|
||||
<tbody>
|
||||
<td valign="top" style="font-family:Arial,Helvetica,sans-serif; color: #555; font-size: 14px;">
|
||||
${object.body | safe}
|
||||
</td>
|
||||
</tbody>
|
||||
</table>
|
||||
</td>
|
||||
</tr>
|
||||
<!-- FOOTER -->
|
||||
<tr>
|
||||
<td align="center" style="min-width: 590px;">
|
||||
<table width="590" border="0" cellpadding="0" bgcolor="#875A7B" style="min-width: 590px; background-color: rgb(135,90,123); padding: 20px; border-collapse:separate;">
|
||||
<tr>
|
||||
<td valign="middle" align="left" style="color: #fff; padding-top: 10px; padding-bottom: 10px; font-size: 12px;">
|
||||
${company.name}<br/>
|
||||
${company.phone or ''}
|
||||
</td>
|
||||
<td valign="middle" align="right" style="color: #fff; padding-top: 10px; padding-bottom: 10px; font-size: 12px;">
|
||||
% if company.email:
|
||||
<a href="mailto:${company.email}" style="text-decoration:none; color: white;">${company.email}</a><br/>
|
||||
% endif
|
||||
% if company.website:
|
||||
<a href="${company.website}" style="text-decoration:none; color: white;">
|
||||
${company.website}
|
||||
</a>
|
||||
% endif
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td align="center">
|
||||
Powered by <a target="_blank" href="https://www.odoo.com">Odoo</a>.
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</div></field>
|
||||
</record>
|
||||
|
||||
</data>
|
||||
</odoo>
|
||||
45
addons/account/data/payment_receipt_data.xml
Normal file
45
addons/account/data/payment_receipt_data.xml
Normal file
@@ -0,0 +1,45 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<odoo>
|
||||
<data noupdate="1">
|
||||
|
||||
<!--Email template -->
|
||||
<record id="mail_template_data_payment_receipt" model="mail.template">
|
||||
<field name="name">Payment Receipt - Send by Email</field>
|
||||
<field name="subject">${object.company_id.name} Payment Receipt (Ref ${object.name or 'n/a' })</field>
|
||||
<field name="partner_to">${object.partner_id.id}</field>
|
||||
<field name="model_id" ref="account.model_account_payment"/>
|
||||
<field name="auto_delete" eval="True"/>
|
||||
<field name="report_template" ref="account.action_report_payment_receipt"/>
|
||||
<field name="report_name">${(object.name or '').replace('/','-')}</field>
|
||||
<field name="lang">${object.partner_id.lang}</field>
|
||||
<field name="body_html" type="xml">
|
||||
<p>Dear ${object.partner_id.name},</p>
|
||||
<p>Thank you for your payment.<br />Here is your payment receipt <strong>${(object.name or '').replace('/','-')}</strong> amounting to <strong>${object.amount} ${object.currency_id.name}</strong> from ${object.company_id.name}.</p>
|
||||
<p>If you have any questions, please do not hesitate to contact us.</p>
|
||||
<p>Best regards,
|
||||
% if user and user.signature:
|
||||
${user.signature | safe}
|
||||
% endif
|
||||
</p>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<act_window name="Send Receipt By Email"
|
||||
res_model="mail.compose.message"
|
||||
src_model="account.payment"
|
||||
view_mode="form"
|
||||
target="new"
|
||||
key2="client_action_relate"
|
||||
id="account_send_payment_receipt_by_email_action"
|
||||
context="{
|
||||
'default_model': 'account.payment',
|
||||
'mail_post_autofollow': True,
|
||||
'default_composition_mode': 'comment',
|
||||
'default_use_template': True,
|
||||
'default_res_id': active_id,
|
||||
'default_template_id': ref('account.mail_template_data_payment_receipt'),
|
||||
'force_email': True,
|
||||
}"
|
||||
/>
|
||||
</data>
|
||||
</odoo>
|
||||
70
addons/account/demo/account_bank_statement.yml
Normal file
70
addons/account/demo/account_bank_statement.yml
Normal file
@@ -0,0 +1,70 @@
|
||||
-
|
||||
Create demo bank statement
|
||||
-
|
||||
!python {model: ir.model.data, id: False} : |
|
||||
default_company = self.env['res.company']._company_default_get('account.journal')
|
||||
journal = self.env['account.journal'].search([('type', '=', 'bank'), ('company_id', '=', default_company.id)], limit=1)
|
||||
import time
|
||||
if journal:
|
||||
vals = {
|
||||
'name': 'demo_bank_statement_1',
|
||||
'journal_id': journal.id,
|
||||
'date': time.strftime('%Y')+'-01-01',
|
||||
'name': "BNK/2014/001",
|
||||
'balance_end_real': '8998.2',
|
||||
'balance_start': 5103.0
|
||||
}
|
||||
self._update('account.bank.statement', 'account', vals, 'demo_bank_statement_1')
|
||||
vals = {
|
||||
'ref': '',
|
||||
'statement_id': ref('account.demo_bank_statement_1'),
|
||||
'sequence': 1,
|
||||
'name': "SAJ/2014/002 and SAJ/2014/003",
|
||||
'journal_id': journal.id,
|
||||
'amount': 1175.0,
|
||||
'date': time.strftime('%Y')+'-01-01',
|
||||
'partner_id': ref('base.res_partner_2'),
|
||||
}
|
||||
self._update('account.bank.statement.line', 'account', vals, 'demo_bank_statement_line_1')
|
||||
vals = {
|
||||
'ref': '',
|
||||
'statement_id': ref('account.demo_bank_statement_1'),
|
||||
'sequence': 2,
|
||||
'name': "Bank fees",
|
||||
'journal_id': journal.id,
|
||||
'amount': -32.58,
|
||||
'date': time.strftime('%Y')+'-01-01',
|
||||
}
|
||||
self._update('account.bank.statement.line', 'account', vals, 'demo_bank_statement_line_2')
|
||||
vals = {
|
||||
'ref': '',
|
||||
'statement_id': ref('account.demo_bank_statement_1'),
|
||||
'sequence': 3,
|
||||
'name': "Prepayment",
|
||||
'journal_id': journal.id,
|
||||
'amount': 650.0,
|
||||
'date': time.strftime('%Y')+'-01-01',
|
||||
'partner_id': ref('base.res_partner_12'),
|
||||
}
|
||||
self._update('account.bank.statement.line', 'account', vals, 'demo_bank_statement_line_3')
|
||||
vals = {
|
||||
'ref': '',
|
||||
'statement_id': ref('account.demo_bank_statement_1'),
|
||||
'sequence': 4,
|
||||
'name': "First 2000 € of SAJ/2014/001",
|
||||
'journal_id': journal.id,
|
||||
'amount': 2000.0,
|
||||
'date': time.strftime('%Y')+'-01-01',
|
||||
'partner_id': ref('base.res_partner_12'),
|
||||
}
|
||||
self._update('account.bank.statement.line', 'account', vals, 'demo_bank_statement_line_4')
|
||||
vals = {
|
||||
'ref': '',
|
||||
'statement_id': ref('account.demo_bank_statement_1'),
|
||||
'sequence': 5,
|
||||
'name': "Last Year Interests",
|
||||
'journal_id': journal.id,
|
||||
'amount': 102.78,
|
||||
'date': time.strftime('%Y')+'-01-01',
|
||||
}
|
||||
self._update('account.bank.statement.line', 'account', vals, 'demo_bank_statement_line_5')
|
||||
56
addons/account/demo/account_demo.xml
Normal file
56
addons/account/demo/account_demo.xml
Normal file
@@ -0,0 +1,56 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<odoo>
|
||||
<data>
|
||||
|
||||
<!-- TAGS FOR RETRIEVING THE DEMO ACCOUNTS -->
|
||||
|
||||
<record id="demo_capital_account" model="account.account.tag">
|
||||
<field name="name">Demo Capital Account</field>
|
||||
</record>
|
||||
<record id="demo_stock_account" model="account.account.tag">
|
||||
<field name="name">Demo Stock Account</field>
|
||||
</record>
|
||||
<record id="demo_sale_of_land_account" model="account.account.tag">
|
||||
<field name="name">Demo Sale of Land Account</field>
|
||||
</record>
|
||||
<record id="demo_ceo_wages_account" model="account.account.tag">
|
||||
<field name="name">Demo CEO Wages Account</field>
|
||||
</record>
|
||||
<record id="demo_coffee_machine_account" model="account.account.tag">
|
||||
<field name="name">Demo Coffe Machine Account</field>
|
||||
</record>
|
||||
<!-- Payment Terms -->
|
||||
|
||||
<record id="account_payment_term" model="account.payment.term">
|
||||
<field name="name">End of Following Month</field>
|
||||
<field name="note">Payment terms: End of Following Month</field>
|
||||
<field name="line_ids" eval="[(5, 0), (0, 0, {'value': 'balance', 'value_amount': 0.0, 'sequence': 500, 'days': 0, 'option': 'last_day_following_month'})]"/>
|
||||
</record>
|
||||
|
||||
<record id="account_payment_term_advance" model="account.payment.term">
|
||||
<field name="name">30% Advance End of Following Month</field>
|
||||
<field name="note">Payment terms: 30% Advance End of Following Month</field>
|
||||
<field name="line_ids" eval="[(5, 0), (0, 0, {'value': 'percent', 'value_amount': 30.0, 'sequence': 400, 'days': 0, 'option': 'day_after_invoice_date'}),
|
||||
(0, 0, {'value': 'balance', 'value_amount': 0.0, 'sequence': 500, 'days': 0, 'option': 'last_day_following_month'})]"/>
|
||||
</record>
|
||||
|
||||
<record id="base.user_demo" model="res.users">
|
||||
<field name="groups_id" eval="[(4,ref('account.group_account_invoice'))]"/>
|
||||
</record>
|
||||
|
||||
<!-- Add Payment terms on some demo partners -->
|
||||
<record id="base.res_partner_2" model="res.partner">
|
||||
<field name="property_payment_term_id" ref="account.account_payment_term_net"/>
|
||||
</record>
|
||||
<record id="base.res_partner_12" model="res.partner">
|
||||
<field name="property_payment_term_id" ref="account_payment_term"/>
|
||||
<field name="property_supplier_payment_term_id" ref="account_payment_term"/>
|
||||
</record>
|
||||
<record id="base.res_partner_4" model="res.partner">
|
||||
<field name="property_supplier_payment_term_id" ref="account.account_payment_term_net"/>
|
||||
</record>
|
||||
<record id="base.res_partner_1" model="res.partner">
|
||||
<field name="property_supplier_payment_term_id" ref="account_payment_term"/>
|
||||
</record>
|
||||
</data>
|
||||
</odoo>
|
||||
185
addons/account/demo/account_invoice_demo.yml
Normal file
185
addons/account/demo/account_invoice_demo.yml
Normal file
@@ -0,0 +1,185 @@
|
||||
-
|
||||
Set the context for customer invoices because the 'type' field is readonly in invoice form views, so it value won't be considered by the yaml import
|
||||
-
|
||||
!record {model: account.invoice, id: demo_invoice_1}:
|
||||
partner_id: base.res_partner_12
|
||||
user_id: base.user_demo
|
||||
reference_type: none
|
||||
payment_term_id: account.account_payment_term
|
||||
type: 'out_invoice'
|
||||
date_invoice: !eval time.strftime('%Y-%m')+'-01'
|
||||
invoice_line_ids:
|
||||
- product_id: product.consu_delivery_02
|
||||
price_unit: 642.0
|
||||
quantity: 5
|
||||
- product_id: product.consu_delivery_03
|
||||
price_unit: 280.0
|
||||
quantity: 5.0
|
||||
-
|
||||
!python {model: account.invoice, id: demo_invoice_1}:
|
||||
self.action_invoice_open()
|
||||
-
|
||||
!record {model: account.invoice, id: demo_invoice_2}:
|
||||
partner_id: base.res_partner_2
|
||||
type: 'out_invoice'
|
||||
date_invoice: !eval time.strftime('%Y-%m')+'-08'
|
||||
invoice_line_ids:
|
||||
- product_id: product.consu_delivery_03
|
||||
price_unit: 50.0
|
||||
quantity: 3
|
||||
- product_id: product.consu_delivery_01
|
||||
price_unit: 25
|
||||
quantity: 20
|
||||
-
|
||||
!python {model: account.invoice, id: demo_invoice_2}:
|
||||
self.action_invoice_open()
|
||||
-
|
||||
!record {model: account.invoice, id: demo_invoice_3}:
|
||||
partner_id: base.res_partner_2
|
||||
type: 'out_invoice'
|
||||
date_invoice: !eval time.strftime('%Y-%m')+'-08'
|
||||
invoice_line_ids:
|
||||
- product_id: product.consu_delivery_01
|
||||
price_unit: 90.0
|
||||
quantity: 5
|
||||
- product_id: product.consu_delivery_03
|
||||
price_unit: 15.0
|
||||
quantity: 5.0
|
||||
-
|
||||
!python {model: account.invoice, id: demo_invoice_3}:
|
||||
self.action_invoice_open()
|
||||
-
|
||||
Create an invoice that will generate a followup
|
||||
-
|
||||
!record {model: account.invoice, id: demo_invoice_followup}:
|
||||
partner_id: base.res_partner_2
|
||||
user_id: base.user_demo
|
||||
reference_type: none
|
||||
payment_term_id: account.account_payment_term_immediate
|
||||
type: 'out_invoice'
|
||||
date_invoice: !eval (datetime.today() + timedelta(days=-15)).strftime('%Y-%m-%d')
|
||||
invoice_line_ids:
|
||||
- product_id: product.consu_delivery_02
|
||||
price_unit: 642.0
|
||||
quantity: 5
|
||||
- product_id: product.consu_delivery_03
|
||||
price_unit: 280.0
|
||||
quantity: 5.0
|
||||
-
|
||||
!python {model: account.invoice, id: demo_invoice_followup}:
|
||||
self.action_invoice_open()
|
||||
-
|
||||
Set the context for supplier bills because the 'type' field is readonly in invoice form views, so it value won't be considered by the yaml import
|
||||
-
|
||||
!context
|
||||
type: 'in_invoice'
|
||||
-
|
||||
!record {model: account.invoice, id: demo_invoice_0}:
|
||||
partner_id: base.res_partner_12
|
||||
user_id: base.user_demo
|
||||
reference_type: none
|
||||
payment_term_id: account.account_payment_term
|
||||
type: 'in_invoice'
|
||||
date_invoice: !eval time.strftime('%Y-%m')+'-01'
|
||||
invoice_line_ids:
|
||||
- price_unit: 10.0
|
||||
quantity: 1.0
|
||||
product_id: product.product_delivery_01
|
||||
uom_id: product.product_uom_unit
|
||||
- price_unit: 4.0
|
||||
quantity: 1.0
|
||||
product_id: product.product_order_01
|
||||
uom_id: product.product_uom_unit
|
||||
-
|
||||
!record {model: account.invoice, id: demo_invoice_january_wages}:
|
||||
partner_id: base.res_partner_12
|
||||
type: 'in_invoice'
|
||||
date_invoice: !eval time.strftime('%Y-%m')+'-01'
|
||||
-
|
||||
!python {model: ir.model.data, id: False} : |
|
||||
line_vals = {
|
||||
'invoice_id': ref('demo_invoice_january_wages'),
|
||||
'name': "CEO wages",
|
||||
'price_unit': 10000,
|
||||
}
|
||||
default_company = self.env['res.company']._company_default_get('account.account')
|
||||
account = self.env['account.account'].search([('tag_ids', 'in', [ref('account.demo_ceo_wages_account')]), ('company_id', '=', default_company.id)], limit=1)
|
||||
if not account:
|
||||
account = self.env['account.account'].search([('user_type_id', '=', ref('account.data_account_type_expenses')), ('company_id', '=', default_company.id)], limit=1)
|
||||
if account:
|
||||
line_vals['account_id'] = account.id
|
||||
self._update('account.invoice.line', 'account', line_vals, 'ceo_wages_line')
|
||||
self.env['account.invoice'].browse(ref('demo_invoice_january_wages')).action_invoice_open()
|
||||
-
|
||||
!record {model: account.invoice, id: demo_invoice_equipment_purchase}:
|
||||
partner_id: base.res_partner_1
|
||||
type: 'in_invoice'
|
||||
date_invoice: !eval time.strftime('%Y-%m')+'-15'
|
||||
-
|
||||
!python {model: ir.model.data, id: False} : |
|
||||
line_vals = {
|
||||
'invoice_id': ref('demo_invoice_equipment_purchase'),
|
||||
'name': "Coffee Machine with huge 'employee\'s performances boosting perk'",
|
||||
'price_unit': 4999.99,
|
||||
}
|
||||
account_default_company = self.env['res.company']._company_default_get('account.account')
|
||||
account_id = self.env['account.account'].search([('tag_ids', 'in', [ref('account.demo_coffee_machine_account')]), ('company_id', '=', account_default_company.id)], limit=1).id
|
||||
if not account_id:
|
||||
account_id = self.env['account.account'].search([('user_type_id', '=', ref('account.data_account_type_expenses')), ('company_id', '=', account_default_company.id)], limit=1).id
|
||||
if account_id:
|
||||
line_vals['account_id'] = account_id
|
||||
tax_default_company = self.env['res.company']._company_default_get('account.tax')
|
||||
tax_id = self.env['account.tax'].search([('type_tax_use', '=', 'purchase'), ('amount', '>', 0), ('company_id', '=', tax_default_company.id)], limit=1).id
|
||||
if tax_id:
|
||||
line_vals['invoice_line_tax_ids'] = [(6, 0, [tax_id])]
|
||||
self._update('account.invoice.line', 'account', line_vals, 'coffee_machine_line')
|
||||
self.env['account.invoice'].browse(ref('demo_invoice_equipment_purchase'))._onchange_invoice_line_ids()
|
||||
self.env['account.invoice'].browse(ref('demo_invoice_equipment_purchase')).action_invoice_open()
|
||||
|
||||
-
|
||||
!python {model: account.bank.statement.line, id: False} : |
|
||||
default_company = self.env['res.company']._company_default_get('account.account')
|
||||
account = self.env['account.account'].search([
|
||||
('user_type_id', '=', ref('account.data_account_type_revenue')),
|
||||
('tag_ids', 'in', [ref('account.account_tag_financing')]),
|
||||
('company_id', '=', default_company.id)], limit=1)
|
||||
line = self.env.ref('account.demo_bank_statement_line_5')
|
||||
if not line.journal_entry_ids and account:
|
||||
line.write({'account_id': account.id})
|
||||
line.fast_counterpart_creation()
|
||||
-
|
||||
!python {model: ir.model.data, id: False} : |
|
||||
from datetime import datetime
|
||||
from dateutil.relativedelta import relativedelta
|
||||
default_company = self.env['res.company']._company_default_get('account.journal')
|
||||
vals = {
|
||||
'journal_id': self.env['account.journal'].search([('type', '=', 'general'), ('company_id', '=', default_company.id)], limit=1).id,
|
||||
'date': datetime.now().replace(day=1,month=1) - relativedelta(days=1),
|
||||
'ref': 'Company Creation',
|
||||
}
|
||||
self._update('account.move', 'account', vals, 'demo_opening_move')
|
||||
-
|
||||
!python {model: ir.model.data, id: False} : |
|
||||
journal_default_company = self.env['res.company']._company_default_get('account.journal')
|
||||
bank_journal = self.env['account.journal'].search([('type', '=', 'bank'), ('company_id', '=', journal_default_company.id)], limit=1)
|
||||
if bank_journal:
|
||||
bank_account_id = bank_journal.default_debit_account_id.id
|
||||
account_default_company = self.env['res.company']._company_default_get('account.account')
|
||||
fixed_asset_account_id = self.env['account.account'].search([('user_type_id', 'in', (ref('account.data_account_type_fixed_assets'),ref('account.data_account_type_current_assets'))), ('company_id', '=', account_default_company.id)], limit=1).id
|
||||
equity_account_id = self.env['account.account'].search([('user_type_id', '=', ref('account.data_account_type_equity')), ('tag_ids', 'in', [ref('account.demo_capital_account')]), ('company_id', '=', account_default_company.id)], limit=1).id
|
||||
if bank_account_id and fixed_asset_account_id and equity_account_id:
|
||||
self.with_context({'check_move_validity': False})._update('account.move.line', 'account', {
|
||||
'move_id': ref('account.demo_opening_move'),
|
||||
'name': 'Opening Entry',
|
||||
'debit': 5103,
|
||||
'account_id': bank_account_id}, 'opening_line_1')
|
||||
self.with_context({'check_move_validity': False})._update('account.move.line', 'account', {
|
||||
'move_id': ref('account.demo_opening_move'),
|
||||
'name': 'Opening Entry',
|
||||
'debit': 13447,
|
||||
'account_id': fixed_asset_account_id}, 'opening_line_2')
|
||||
self.with_context({'check_move_validity': False})._update('account.move.line', 'account', {
|
||||
'move_id': ref('account.demo_opening_move'),
|
||||
'name': 'Opening Entry',
|
||||
'credit': 18550,
|
||||
'account_id': equity_account_id}, 'opening_line_3')
|
||||
37
addons/account/demo/account_statement_operations.yml
Normal file
37
addons/account/demo/account_statement_operations.yml
Normal file
@@ -0,0 +1,37 @@
|
||||
-
|
||||
!python {model: ir.model.data, id: False} : |
|
||||
account_id = self.env['account.account'].search([('user_type_id', '=', ref('account.data_account_type_expenses')), ('tag_ids', '=', ref('account_tag_operating'))], limit=1).id
|
||||
vals = {
|
||||
'name': "Discount For Early Payment",
|
||||
'label': 'Discount',
|
||||
'amount_type': 'percentage',
|
||||
'amount': -7,
|
||||
}
|
||||
if account_id:
|
||||
vals['account_id'] = account_id
|
||||
self._update(cr, uid, 'account.reconcile.model', 'account', vals, 'account_reconcile_model_1')
|
||||
-
|
||||
!python {model: ir.model.data, id: False} : |
|
||||
account_id = self.env['account.account'].search([('user_type_id', '=', ref('account.data_account_type_expenses')), ('tag_ids', '=', ref('account_tag_operating'))], limit=1).id
|
||||
vals = {
|
||||
'name': "Bank Fees",
|
||||
'label': 'Bank Fees',
|
||||
'amount_type': 'percentage',
|
||||
'amount': 100.0,
|
||||
}
|
||||
if account_id:
|
||||
vals['account_id'] = account_id
|
||||
self._update(cr, uid, 'account.reconcile.model', 'account', vals, 'account_reconcile_model_2')
|
||||
-
|
||||
!python {model: ir.model.data, id: False} : |
|
||||
account_id = self.env['account.account'].search([('user_type_id', '=', ref('account.data_account_type_revenue')), ('tag_ids', '=', ref('account_tag_operating'))], limit=1).id
|
||||
vals = {
|
||||
'name': "Profit / Loss",
|
||||
'label': 'Profit / Loss',
|
||||
'amount_type': 'percentage',
|
||||
'amount': 100.0,
|
||||
}
|
||||
if account_id:
|
||||
vals['account_id'] = account_id
|
||||
self._update(cr, uid, 'account.reconcile.model', 'account', vals, 'account_reconcile_model_3')
|
||||
-
|
||||
BIN
addons/account/doc/account_anglo_saxon.ods
Normal file
BIN
addons/account/doc/account_anglo_saxon.ods
Normal file
Binary file not shown.
BIN
addons/account/doc/account_anglo_saxon.pdf
Normal file
BIN
addons/account/doc/account_anglo_saxon.pdf
Normal file
Binary file not shown.
10925
addons/account/i18n/account.pot
Normal file
10925
addons/account/i18n/account.pot
Normal file
File diff suppressed because it is too large
Load Diff
11445
addons/account/i18n/af.po
Normal file
11445
addons/account/i18n/af.po
Normal file
File diff suppressed because it is too large
Load Diff
11445
addons/account/i18n/am.po
Normal file
11445
addons/account/i18n/am.po
Normal file
File diff suppressed because it is too large
Load Diff
11910
addons/account/i18n/ar.po
Normal file
11910
addons/account/i18n/ar.po
Normal file
File diff suppressed because it is too large
Load Diff
11450
addons/account/i18n/bg.po
Normal file
11450
addons/account/i18n/bg.po
Normal file
File diff suppressed because it is too large
Load Diff
11730
addons/account/i18n/bs.po
Normal file
11730
addons/account/i18n/bs.po
Normal file
File diff suppressed because it is too large
Load Diff
12184
addons/account/i18n/ca.po
Normal file
12184
addons/account/i18n/ca.po
Normal file
File diff suppressed because it is too large
Load Diff
11491
addons/account/i18n/cs.po
Normal file
11491
addons/account/i18n/cs.po
Normal file
File diff suppressed because it is too large
Load Diff
12067
addons/account/i18n/da.po
Normal file
12067
addons/account/i18n/da.po
Normal file
File diff suppressed because it is too large
Load Diff
12130
addons/account/i18n/de.po
Normal file
12130
addons/account/i18n/de.po
Normal file
File diff suppressed because it is too large
Load Diff
12012
addons/account/i18n/el.po
Normal file
12012
addons/account/i18n/el.po
Normal file
File diff suppressed because it is too large
Load Diff
11442
addons/account/i18n/en_GB.po
Normal file
11442
addons/account/i18n/en_GB.po
Normal file
File diff suppressed because it is too large
Load Diff
12353
addons/account/i18n/es.po
Normal file
12353
addons/account/i18n/es.po
Normal file
File diff suppressed because it is too large
Load Diff
11544
addons/account/i18n/es_AR.po
Normal file
11544
addons/account/i18n/es_AR.po
Normal file
File diff suppressed because it is too large
Load Diff
11544
addons/account/i18n/es_BO.po
Normal file
11544
addons/account/i18n/es_BO.po
Normal file
File diff suppressed because it is too large
Load Diff
11545
addons/account/i18n/es_CL.po
Normal file
11545
addons/account/i18n/es_CL.po
Normal file
File diff suppressed because it is too large
Load Diff
11544
addons/account/i18n/es_CO.po
Normal file
11544
addons/account/i18n/es_CO.po
Normal file
File diff suppressed because it is too large
Load Diff
11544
addons/account/i18n/es_CR.po
Normal file
11544
addons/account/i18n/es_CR.po
Normal file
File diff suppressed because it is too large
Load Diff
11544
addons/account/i18n/es_DO.po
Normal file
11544
addons/account/i18n/es_DO.po
Normal file
File diff suppressed because it is too large
Load Diff
11544
addons/account/i18n/es_EC.po
Normal file
11544
addons/account/i18n/es_EC.po
Normal file
File diff suppressed because it is too large
Load Diff
11544
addons/account/i18n/es_PE.po
Normal file
11544
addons/account/i18n/es_PE.po
Normal file
File diff suppressed because it is too large
Load Diff
11544
addons/account/i18n/es_PY.po
Normal file
11544
addons/account/i18n/es_PY.po
Normal file
File diff suppressed because it is too large
Load Diff
11544
addons/account/i18n/es_VE.po
Normal file
11544
addons/account/i18n/es_VE.po
Normal file
File diff suppressed because it is too large
Load Diff
12137
addons/account/i18n/et.po
Normal file
12137
addons/account/i18n/et.po
Normal file
File diff suppressed because it is too large
Load Diff
11449
addons/account/i18n/eu.po
Normal file
11449
addons/account/i18n/eu.po
Normal file
File diff suppressed because it is too large
Load Diff
11512
addons/account/i18n/fa.po
Normal file
11512
addons/account/i18n/fa.po
Normal file
File diff suppressed because it is too large
Load Diff
11726
addons/account/i18n/fi.po
Normal file
11726
addons/account/i18n/fi.po
Normal file
File diff suppressed because it is too large
Load Diff
11444
addons/account/i18n/fo.po
Normal file
11444
addons/account/i18n/fo.po
Normal file
File diff suppressed because it is too large
Load Diff
12331
addons/account/i18n/fr.po
Normal file
12331
addons/account/i18n/fr.po
Normal file
File diff suppressed because it is too large
Load Diff
11442
addons/account/i18n/fr_CA.po
Normal file
11442
addons/account/i18n/fr_CA.po
Normal file
File diff suppressed because it is too large
Load Diff
11452
addons/account/i18n/gl.po
Normal file
11452
addons/account/i18n/gl.po
Normal file
File diff suppressed because it is too large
Load Diff
11522
addons/account/i18n/he.po
Normal file
11522
addons/account/i18n/he.po
Normal file
File diff suppressed because it is too large
Load Diff
11940
addons/account/i18n/hr.po
Normal file
11940
addons/account/i18n/hr.po
Normal file
File diff suppressed because it is too large
Load Diff
12051
addons/account/i18n/hu.po
Normal file
12051
addons/account/i18n/hu.po
Normal file
File diff suppressed because it is too large
Load Diff
12276
addons/account/i18n/id.po
Normal file
12276
addons/account/i18n/id.po
Normal file
File diff suppressed because it is too large
Load Diff
11470
addons/account/i18n/it.po
Normal file
11470
addons/account/i18n/it.po
Normal file
File diff suppressed because it is too large
Load Diff
11508
addons/account/i18n/ja.po
Normal file
11508
addons/account/i18n/ja.po
Normal file
File diff suppressed because it is too large
Load Diff
11444
addons/account/i18n/ka.po
Normal file
11444
addons/account/i18n/ka.po
Normal file
File diff suppressed because it is too large
Load Diff
11453
addons/account/i18n/kab.po
Normal file
11453
addons/account/i18n/kab.po
Normal file
File diff suppressed because it is too large
Load Diff
11455
addons/account/i18n/ko.po
Normal file
11455
addons/account/i18n/ko.po
Normal file
File diff suppressed because it is too large
Load Diff
11451
addons/account/i18n/lo.po
Normal file
11451
addons/account/i18n/lo.po
Normal file
File diff suppressed because it is too large
Load Diff
11598
addons/account/i18n/lt.po
Normal file
11598
addons/account/i18n/lt.po
Normal file
File diff suppressed because it is too large
Load Diff
11461
addons/account/i18n/lv.po
Normal file
11461
addons/account/i18n/lv.po
Normal file
File diff suppressed because it is too large
Load Diff
11452
addons/account/i18n/mk.po
Normal file
11452
addons/account/i18n/mk.po
Normal file
File diff suppressed because it is too large
Load Diff
11451
addons/account/i18n/mn.po
Normal file
11451
addons/account/i18n/mn.po
Normal file
File diff suppressed because it is too large
Load Diff
11509
addons/account/i18n/nb.po
Normal file
11509
addons/account/i18n/nb.po
Normal file
File diff suppressed because it is too large
Load Diff
11452
addons/account/i18n/ne.po
Normal file
11452
addons/account/i18n/ne.po
Normal file
File diff suppressed because it is too large
Load Diff
12337
addons/account/i18n/nl.po
Normal file
12337
addons/account/i18n/nl.po
Normal file
File diff suppressed because it is too large
Load Diff
11442
addons/account/i18n/nl_BE.po
Normal file
11442
addons/account/i18n/nl_BE.po
Normal file
File diff suppressed because it is too large
Load Diff
12036
addons/account/i18n/pl.po
Normal file
12036
addons/account/i18n/pl.po
Normal file
File diff suppressed because it is too large
Load Diff
11459
addons/account/i18n/pt.po
Normal file
11459
addons/account/i18n/pt.po
Normal file
File diff suppressed because it is too large
Load Diff
12342
addons/account/i18n/pt_BR.po
Normal file
12342
addons/account/i18n/pt_BR.po
Normal file
File diff suppressed because it is too large
Load Diff
11762
addons/account/i18n/ro.po
Normal file
11762
addons/account/i18n/ro.po
Normal file
File diff suppressed because it is too large
Load Diff
12039
addons/account/i18n/ru.po
Normal file
12039
addons/account/i18n/ru.po
Normal file
File diff suppressed because it is too large
Load Diff
11459
addons/account/i18n/sk.po
Normal file
11459
addons/account/i18n/sk.po
Normal file
File diff suppressed because it is too large
Load Diff
11450
addons/account/i18n/sl.po
Normal file
11450
addons/account/i18n/sl.po
Normal file
File diff suppressed because it is too large
Load Diff
11444
addons/account/i18n/sq.po
Normal file
11444
addons/account/i18n/sq.po
Normal file
File diff suppressed because it is too large
Load Diff
11460
addons/account/i18n/sr.po
Normal file
11460
addons/account/i18n/sr.po
Normal file
File diff suppressed because it is too large
Load Diff
11526
addons/account/i18n/sr@latin.po
Normal file
11526
addons/account/i18n/sr@latin.po
Normal file
File diff suppressed because it is too large
Load Diff
11640
addons/account/i18n/sv.po
Normal file
11640
addons/account/i18n/sv.po
Normal file
File diff suppressed because it is too large
Load Diff
11444
addons/account/i18n/th.po
Normal file
11444
addons/account/i18n/th.po
Normal file
File diff suppressed because it is too large
Load Diff
12050
addons/account/i18n/tr.po
Normal file
12050
addons/account/i18n/tr.po
Normal file
File diff suppressed because it is too large
Load Diff
12015
addons/account/i18n/uk.po
Normal file
12015
addons/account/i18n/uk.po
Normal file
File diff suppressed because it is too large
Load Diff
11587
addons/account/i18n/vi.po
Normal file
11587
addons/account/i18n/vi.po
Normal file
File diff suppressed because it is too large
Load Diff
11626
addons/account/i18n/zh_CN.po
Normal file
11626
addons/account/i18n/zh_CN.po
Normal file
File diff suppressed because it is too large
Load Diff
11468
addons/account/i18n/zh_TW.po
Normal file
11468
addons/account/i18n/zh_TW.po
Normal file
File diff suppressed because it is too large
Load Diff
16
addons/account/models/__init__.py
Normal file
16
addons/account/models/__init__.py
Normal file
@@ -0,0 +1,16 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
|
||||
from . import partner
|
||||
from . import account
|
||||
from . import account_payment
|
||||
from . import account_invoice
|
||||
from . import account_bank_statement
|
||||
from . import account_move
|
||||
from . import chart_template
|
||||
from . import account_analytic_line
|
||||
from . import account_journal_dashboard
|
||||
from . import product
|
||||
from . import company
|
||||
from . import res_config_settings
|
||||
from . import web_planner
|
||||
from . import account_cash_rounding
|
||||
1042
addons/account/models/account.py
Normal file
1042
addons/account/models/account.py
Normal file
File diff suppressed because it is too large
Load Diff
59
addons/account/models/account_analytic_line.py
Normal file
59
addons/account/models/account_analytic_line.py
Normal file
@@ -0,0 +1,59 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
|
||||
from odoo import api, fields, models, _
|
||||
from math import copysign
|
||||
|
||||
|
||||
class AccountAnalyticLine(models.Model):
|
||||
_inherit = 'account.analytic.line'
|
||||
_description = 'Analytic Line'
|
||||
_order = 'date desc'
|
||||
|
||||
amount = fields.Monetary(currency_field='company_currency_id')
|
||||
product_uom_id = fields.Many2one('product.uom', string='Unit of Measure')
|
||||
product_id = fields.Many2one('product.product', string='Product')
|
||||
general_account_id = fields.Many2one('account.account', string='Financial Account', ondelete='restrict', readonly=True,
|
||||
related='move_id.account_id', store=True, domain=[('deprecated', '=', False)])
|
||||
move_id = fields.Many2one('account.move.line', string='Move Line', ondelete='cascade', index=True)
|
||||
code = fields.Char(size=8)
|
||||
ref = fields.Char(string='Ref.')
|
||||
company_currency_id = fields.Many2one('res.currency', related='company_id.currency_id', readonly=True,
|
||||
help='Utility field to express amount currency')
|
||||
currency_id = fields.Many2one('res.currency', related='move_id.currency_id', string='Account Currency', store=True, help="The related account currency if not equal to the company one.", readonly=True)
|
||||
amount_currency = fields.Monetary(related='move_id.amount_currency', store=True, help="The amount expressed in the related account currency if not equal to the company one.", readonly=True)
|
||||
analytic_amount_currency = fields.Monetary(string='Amount Currency', compute="_get_analytic_amount_currency", help="The amount expressed in the related account currency if not equal to the company one.", readonly=True)
|
||||
partner_id = fields.Many2one('res.partner', related='account_id.partner_id', string='Partner', store=True, readonly=True)
|
||||
|
||||
def _get_analytic_amount_currency(self):
|
||||
for line in self:
|
||||
line.analytic_amount_currency = abs(line.amount_currency) * copysign(1, line.amount)
|
||||
|
||||
@api.v8
|
||||
@api.onchange('product_id', 'product_uom_id', 'unit_amount', 'currency_id')
|
||||
def on_change_unit_amount(self):
|
||||
if not self.product_id:
|
||||
return {}
|
||||
|
||||
result = 0.0
|
||||
prod_accounts = self.product_id.product_tmpl_id._get_product_accounts()
|
||||
unit = self.product_uom_id
|
||||
account = prod_accounts['expense']
|
||||
if not unit or self.product_id.uom_po_id.category_id.id != unit.category_id.id:
|
||||
unit = self.product_id.uom_po_id
|
||||
|
||||
# Compute based on pricetype
|
||||
amount_unit = self.product_id.price_compute('standard_price', uom=unit)[self.product_id.id]
|
||||
amount = amount_unit * self.unit_amount or 0.0
|
||||
result = self.currency_id.round(amount) * -1
|
||||
self.amount = result
|
||||
self.general_account_id = account
|
||||
self.product_uom_id = unit
|
||||
|
||||
@api.model
|
||||
def view_header_get(self, view_id, view_type):
|
||||
context = (self._context or {})
|
||||
header = False
|
||||
if context.get('account_id', False):
|
||||
analytic_account = self.env['account.analytic.account'].search([('id', '=', context['account_id'])], limit=1)
|
||||
header = _('Entries: ') + (analytic_account.name or '')
|
||||
return header
|
||||
1016
addons/account/models/account_bank_statement.py
Normal file
1016
addons/account/models/account_bank_statement.py
Normal file
File diff suppressed because it is too large
Load Diff
47
addons/account/models/account_cash_rounding.py
Normal file
47
addons/account/models/account_cash_rounding.py
Normal file
@@ -0,0 +1,47 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
|
||||
from odoo import models, fields, api, _
|
||||
from odoo.tools import float_round
|
||||
|
||||
|
||||
class AccountCashRounding(models.Model):
|
||||
"""
|
||||
In some countries, we need to be able to make appear on an invoice a rounding line, appearing there only because the
|
||||
smallest coinage has been removed from the circulation. For example, in Switerzland invoices have to be rounded to
|
||||
0.05 CHF because coins of 0.01 CHF and 0.02 CHF aren't used anymore.
|
||||
see https://en.wikipedia.org/wiki/Cash_rounding for more details.
|
||||
"""
|
||||
_name = 'account.cash.rounding'
|
||||
_description = 'Account Rounding'
|
||||
|
||||
name = fields.Char(string='Name', translate=True, required=True)
|
||||
rounding = fields.Float(string='Rounding Precision', required=True,
|
||||
help='Represent the non-zero value smallest coinage (for example, 0.05).')
|
||||
strategy = fields.Selection([('biggest_tax', 'Modify tax amount'), ('add_invoice_line', 'Add a rounding line')],
|
||||
string='Rounding Strategy', default='add_invoice_line', required=True,
|
||||
help='Specify which way will be used to round the invoice amount to the rounding precision')
|
||||
account_id = fields.Many2one('account.account', string='Account')
|
||||
rounding_method = fields.Selection(string='Rounding Method', required=True,
|
||||
selection=[('UP', 'UP'), ('DOWN', 'DOWN'), ('HALF-UP', 'HALF-UP')],
|
||||
default='HALF-UP', help='The tie-breaking rule used for float rounding operations')
|
||||
|
||||
@api.multi
|
||||
def round(self, amount):
|
||||
"""Compute the rounding on the amount passed as parameter.
|
||||
|
||||
:param amount: the amount to round
|
||||
:return: the rounded amount depending the rounding value and the rounding method
|
||||
"""
|
||||
return float_round(amount, precision_rounding=self.rounding, rounding_method=self.rounding_method)
|
||||
|
||||
@api.multi
|
||||
def compute_difference(self, currency, amount):
|
||||
"""Compute the difference between the base_amount and the amount after rounding.
|
||||
For example, base_amount=23.91, after rounding=24.00, the result will be 0.09.
|
||||
|
||||
:param currency: The currency.
|
||||
:param amount: The amount
|
||||
:return: round(difference)
|
||||
"""
|
||||
difference = self.round(amount) - amount
|
||||
return currency.round(difference)
|
||||
1804
addons/account/models/account_invoice.py
Normal file
1804
addons/account/models/account_invoice.py
Normal file
File diff suppressed because it is too large
Load Diff
443
addons/account/models/account_journal_dashboard.py
Normal file
443
addons/account/models/account_journal_dashboard.py
Normal file
@@ -0,0 +1,443 @@
|
||||
import json
|
||||
from datetime import datetime, timedelta
|
||||
|
||||
from babel.dates import format_datetime, format_date
|
||||
|
||||
from odoo import models, api, _, fields
|
||||
from odoo.release import version
|
||||
from odoo.tools import DEFAULT_SERVER_DATE_FORMAT as DF
|
||||
from odoo.tools.misc import formatLang
|
||||
|
||||
class account_journal(models.Model):
|
||||
_inherit = "account.journal"
|
||||
|
||||
@api.one
|
||||
def _kanban_dashboard(self):
|
||||
self.kanban_dashboard = json.dumps(self.get_journal_dashboard_datas())
|
||||
|
||||
@api.one
|
||||
def _kanban_dashboard_graph(self):
|
||||
if (self.type in ['sale', 'purchase']):
|
||||
self.kanban_dashboard_graph = json.dumps(self.get_bar_graph_datas())
|
||||
elif (self.type in ['cash', 'bank']):
|
||||
self.kanban_dashboard_graph = json.dumps(self.get_line_graph_datas())
|
||||
|
||||
kanban_dashboard = fields.Text(compute='_kanban_dashboard')
|
||||
kanban_dashboard_graph = fields.Text(compute='_kanban_dashboard_graph')
|
||||
show_on_dashboard = fields.Boolean(string='Show journal on dashboard', help="Whether this journal should be displayed on the dashboard or not", default=True)
|
||||
color = fields.Integer("Color Index", default=0)
|
||||
account_setup_bank_data_done = fields.Boolean(string='Bank setup marked as done', related='company_id.account_setup_bank_data_done', help="Technical field used in the special view for the setup bar step.")
|
||||
|
||||
def _graph_title_and_key(self):
|
||||
if self.type == 'sale':
|
||||
return ['', _('Sales: Untaxed Total')]
|
||||
elif self.type == 'purchase':
|
||||
return ['', _('Purchase: Untaxed Total')]
|
||||
elif self.type == 'cash':
|
||||
return ['', _('Cash: Balance')]
|
||||
elif self.type == 'bank':
|
||||
return ['', _('Bank: Balance')]
|
||||
|
||||
@api.multi
|
||||
def get_line_graph_datas(self):
|
||||
data = []
|
||||
today = datetime.today()
|
||||
last_month = today + timedelta(days=-30)
|
||||
bank_stmt = []
|
||||
# Query to optimize loading of data for bank statement graphs
|
||||
# Return a list containing the latest bank statement balance per day for the
|
||||
# last 30 days for current journal
|
||||
query = """SELECT a.date, a.balance_end
|
||||
FROM account_bank_statement AS a,
|
||||
(SELECT c.date, max(c.id) AS stmt_id
|
||||
FROM account_bank_statement AS c
|
||||
WHERE c.journal_id = %s
|
||||
AND c.date > %s
|
||||
AND c.date <= %s
|
||||
GROUP BY date, id
|
||||
ORDER BY date, id) AS b
|
||||
WHERE a.id = b.stmt_id;"""
|
||||
|
||||
self.env.cr.execute(query, (self.id, last_month, today))
|
||||
bank_stmt = self.env.cr.dictfetchall()
|
||||
|
||||
last_bank_stmt = self.env['account.bank.statement'].search([('journal_id', 'in', self.ids),('date', '<=', last_month.strftime(DF))], order="date desc, id desc", limit=1)
|
||||
start_balance = last_bank_stmt and last_bank_stmt[0].balance_end or 0
|
||||
|
||||
locale = self._context.get('lang') or 'en_US'
|
||||
show_date = last_month
|
||||
#get date in locale format
|
||||
name = format_date(show_date, 'd LLLL Y', locale=locale)
|
||||
short_name = format_date(show_date, 'd MMM', locale=locale)
|
||||
data.append({'x':short_name,'y':start_balance, 'name':name})
|
||||
|
||||
for stmt in bank_stmt:
|
||||
#fill the gap between last data and the new one
|
||||
number_day_to_add = (datetime.strptime(stmt.get('date'), DF) - show_date).days
|
||||
last_balance = data[len(data) - 1]['y']
|
||||
for day in range(0,number_day_to_add + 1):
|
||||
show_date = show_date + timedelta(days=1)
|
||||
#get date in locale format
|
||||
name = format_date(show_date, 'd LLLL Y', locale=locale)
|
||||
short_name = format_date(show_date, 'd MMM', locale=locale)
|
||||
data.append({'x': short_name, 'y':last_balance, 'name': name})
|
||||
#add new stmt value
|
||||
data[len(data) - 1]['y'] = stmt.get('balance_end')
|
||||
|
||||
#continue the graph if the last statement isn't today
|
||||
if show_date != today:
|
||||
number_day_to_add = (today - show_date).days
|
||||
last_balance = data[len(data) - 1]['y']
|
||||
for day in range(0,number_day_to_add):
|
||||
show_date = show_date + timedelta(days=1)
|
||||
#get date in locale format
|
||||
name = format_date(show_date, 'd LLLL Y', locale=locale)
|
||||
short_name = format_date(show_date, 'd MMM', locale=locale)
|
||||
data.append({'x': short_name, 'y':last_balance, 'name': name})
|
||||
|
||||
[graph_title, graph_key] = self._graph_title_and_key()
|
||||
color = '#875A7B' if '+e' in version else '#7c7bad'
|
||||
return [{'values': data, 'title': graph_title, 'key': graph_key, 'area': True, 'color': color}]
|
||||
|
||||
@api.multi
|
||||
def get_bar_graph_datas(self):
|
||||
data = []
|
||||
today = datetime.strptime(fields.Date.context_today(self), DF)
|
||||
data.append({'label': _('Past'), 'value':0.0, 'type': 'past'})
|
||||
day_of_week = int(format_datetime(today, 'e', locale=self._context.get('lang') or 'en_US'))
|
||||
first_day_of_week = today + timedelta(days=-day_of_week+1)
|
||||
for i in range(-1,4):
|
||||
if i==0:
|
||||
label = _('This Week')
|
||||
elif i==3:
|
||||
label = _('Future')
|
||||
else:
|
||||
start_week = first_day_of_week + timedelta(days=i*7)
|
||||
end_week = start_week + timedelta(days=6)
|
||||
if start_week.month == end_week.month:
|
||||
label = str(start_week.day) + '-' +str(end_week.day)+ ' ' + format_date(end_week, 'MMM', locale=self._context.get('lang') or 'en_US')
|
||||
else:
|
||||
label = format_date(start_week, 'd MMM', locale=self._context.get('lang') or 'en_US')+'-'+format_date(end_week, 'd MMM', locale=self._context.get('lang') or 'en_US')
|
||||
data.append({'label':label,'value':0.0, 'type': 'past' if i<0 else 'future'})
|
||||
|
||||
# Build SQL query to find amount aggregated by week
|
||||
(select_sql_clause, query_args) = self._get_bar_graph_select_query()
|
||||
query = ''
|
||||
start_date = (first_day_of_week + timedelta(days=-7))
|
||||
for i in range(0,6):
|
||||
if i == 0:
|
||||
query += "("+select_sql_clause+" and date < '"+start_date.strftime(DF)+"')"
|
||||
elif i == 5:
|
||||
query += " UNION ALL ("+select_sql_clause+" and date >= '"+start_date.strftime(DF)+"')"
|
||||
else:
|
||||
next_date = start_date + timedelta(days=7)
|
||||
query += " UNION ALL ("+select_sql_clause+" and date >= '"+start_date.strftime(DF)+"' and date < '"+next_date.strftime(DF)+"')"
|
||||
start_date = next_date
|
||||
|
||||
self.env.cr.execute(query, query_args)
|
||||
query_results = self.env.cr.dictfetchall()
|
||||
for index in range(0, len(query_results)):
|
||||
if query_results[index].get('aggr_date') != None:
|
||||
data[index]['value'] = query_results[index].get('total')
|
||||
|
||||
[graph_title, graph_key] = self._graph_title_and_key()
|
||||
return [{'values': data, 'title': graph_title, 'key': graph_key}]
|
||||
|
||||
def _get_bar_graph_select_query(self):
|
||||
"""
|
||||
Returns a tuple containing the base SELECT SQL query used to gather
|
||||
the bar graph's data as its first element, and the arguments dictionary
|
||||
for it as its second.
|
||||
"""
|
||||
return ("""SELECT sum(residual_company_signed) as total, min(date) as aggr_date
|
||||
FROM account_invoice
|
||||
WHERE journal_id = %(journal_id)s and state = 'open'""", {'journal_id':self.id})
|
||||
|
||||
@api.multi
|
||||
def get_journal_dashboard_datas(self):
|
||||
currency = self.currency_id or self.company_id.currency_id
|
||||
number_to_reconcile = last_balance = account_sum = 0
|
||||
title = ''
|
||||
number_draft = number_waiting = number_late = 0
|
||||
sum_draft = sum_waiting = sum_late = 0.0
|
||||
if self.type in ['bank', 'cash']:
|
||||
last_bank_stmt = self.env['account.bank.statement'].search([('journal_id', 'in', self.ids)], order="date desc, id desc", limit=1)
|
||||
last_balance = last_bank_stmt and last_bank_stmt[0].balance_end or 0
|
||||
#Get the number of items to reconcile for that bank journal
|
||||
self.env.cr.execute("""SELECT COUNT(DISTINCT(line.id))
|
||||
FROM account_bank_statement_line AS line
|
||||
LEFT JOIN account_bank_statement AS st
|
||||
ON line.statement_id = st.id
|
||||
WHERE st.journal_id IN %s AND st.state = 'open' AND line.amount != 0.0
|
||||
AND not exists (select 1 from account_move_line aml where aml.statement_line_id = line.id)
|
||||
""", (tuple(self.ids),))
|
||||
number_to_reconcile = self.env.cr.fetchone()[0]
|
||||
# optimization to read sum of balance from account_move_line
|
||||
account_ids = tuple(ac for ac in [self.default_debit_account_id.id, self.default_credit_account_id.id] if ac)
|
||||
if account_ids:
|
||||
amount_field = 'balance' if (not self.currency_id or self.currency_id == self.company_id.currency_id) else 'amount_currency'
|
||||
query = """SELECT sum(%s) FROM account_move_line WHERE account_id in %%s AND date <= %%s;""" % (amount_field,)
|
||||
self.env.cr.execute(query, (account_ids, fields.Date.today(),))
|
||||
query_results = self.env.cr.dictfetchall()
|
||||
if query_results and query_results[0].get('sum') != None:
|
||||
account_sum = query_results[0].get('sum')
|
||||
#TODO need to check if all invoices are in the same currency than the journal!!!!
|
||||
elif self.type in ['sale', 'purchase']:
|
||||
title = _('Bills to pay') if self.type == 'purchase' else _('Invoices owed to you')
|
||||
|
||||
(query, query_args) = self._get_open_bills_to_pay_query()
|
||||
self.env.cr.execute(query, query_args)
|
||||
query_results_to_pay = self.env.cr.dictfetchall()
|
||||
|
||||
(query, query_args) = self._get_draft_bills_query()
|
||||
self.env.cr.execute(query, query_args)
|
||||
query_results_drafts = self.env.cr.dictfetchall()
|
||||
|
||||
today = datetime.today()
|
||||
query = """SELECT amount_total, currency_id AS currency, type FROM account_invoice WHERE journal_id = %s AND date < %s AND state = 'open';"""
|
||||
self.env.cr.execute(query, (self.id, today))
|
||||
late_query_results = self.env.cr.dictfetchall()
|
||||
(number_waiting, sum_waiting) = self._count_results_and_sum_amounts(query_results_to_pay, currency)
|
||||
(number_draft, sum_draft) = self._count_results_and_sum_amounts(query_results_drafts, currency)
|
||||
(number_late, sum_late) = self._count_results_and_sum_amounts(late_query_results, currency)
|
||||
|
||||
difference = currency.round(last_balance-account_sum) + 0.0
|
||||
return {
|
||||
'number_to_reconcile': number_to_reconcile,
|
||||
'account_balance': formatLang(self.env, currency.round(account_sum) + 0.0, currency_obj=currency),
|
||||
'last_balance': formatLang(self.env, currency.round(last_balance) + 0.0, currency_obj=currency),
|
||||
'difference': formatLang(self.env, difference, currency_obj=currency) if difference else False,
|
||||
'number_draft': number_draft,
|
||||
'number_waiting': number_waiting,
|
||||
'number_late': number_late,
|
||||
'sum_draft': formatLang(self.env, currency.round(sum_draft) + 0.0, currency_obj=currency),
|
||||
'sum_waiting': formatLang(self.env, currency.round(sum_waiting) + 0.0, currency_obj=currency),
|
||||
'sum_late': formatLang(self.env, currency.round(sum_late) + 0.0, currency_obj=currency),
|
||||
'currency_id': currency.id,
|
||||
'bank_statements_source': self.bank_statements_source,
|
||||
'title': title,
|
||||
}
|
||||
|
||||
def _get_open_bills_to_pay_query(self):
|
||||
"""
|
||||
Returns a tuple contaning the SQL query used to gather the open bills
|
||||
data as its first element, and the arguments dictionary to use to run
|
||||
it as its second.
|
||||
"""
|
||||
return ("""SELECT state, amount_total, currency_id AS currency
|
||||
FROM account_invoice
|
||||
WHERE journal_id = %(journal_id)s AND state = 'open';""", {'journal_id':self.id})
|
||||
|
||||
def _get_draft_bills_query(self):
|
||||
"""
|
||||
Returns a tuple containing as its first element the SQL query used to
|
||||
gather the bills in draft state data, and the arguments
|
||||
dictionary to use to run it as its second.
|
||||
"""
|
||||
return ("""SELECT state, amount_total, currency_id AS currency
|
||||
FROM account_invoice
|
||||
WHERE journal_id = %(journal_id)s AND state = 'draft';""", {'journal_id':self.id})
|
||||
|
||||
def _count_results_and_sum_amounts(self, results_dict, target_currency):
|
||||
""" Loops on a query result to count the total number of invoices and sum
|
||||
their amount_total field (expressed in the given target currency).
|
||||
"""
|
||||
rslt_count = 0
|
||||
rslt_sum = 0.0
|
||||
for result in results_dict:
|
||||
cur = self.env['res.currency'].browse(result.get('currency'))
|
||||
rslt_count += 1
|
||||
rslt_sum += cur.compute(result.get('amount_total'), target_currency)
|
||||
return (rslt_count, rslt_sum)
|
||||
|
||||
@api.multi
|
||||
def action_create_new(self):
|
||||
ctx = self._context.copy()
|
||||
model = 'account.invoice'
|
||||
if self.type == 'sale':
|
||||
ctx.update({'journal_type': self.type, 'default_type': 'out_invoice', 'type': 'out_invoice', 'default_journal_id': self.id})
|
||||
if ctx.get('refund'):
|
||||
ctx.update({'default_type':'out_refund', 'type':'out_refund'})
|
||||
view_id = self.env.ref('account.invoice_form').id
|
||||
elif self.type == 'purchase':
|
||||
ctx.update({'journal_type': self.type, 'default_type': 'in_invoice', 'type': 'in_invoice', 'default_journal_id': self.id})
|
||||
if ctx.get('refund'):
|
||||
ctx.update({'default_type': 'in_refund', 'type': 'in_refund'})
|
||||
view_id = self.env.ref('account.invoice_supplier_form').id
|
||||
else:
|
||||
ctx.update({'default_journal_id': self.id, 'view_no_maturity': True})
|
||||
view_id = self.env.ref('account.view_move_form').id
|
||||
model = 'account.move'
|
||||
return {
|
||||
'name': _('Create invoice/bill'),
|
||||
'type': 'ir.actions.act_window',
|
||||
'view_type': 'form',
|
||||
'view_mode': 'form',
|
||||
'res_model': model,
|
||||
'view_id': view_id,
|
||||
'context': ctx,
|
||||
}
|
||||
|
||||
@api.multi
|
||||
def create_cash_statement(self):
|
||||
ctx = self._context.copy()
|
||||
ctx.update({'journal_id': self.id, 'default_journal_id': self.id, 'default_journal_type': 'cash'})
|
||||
return {
|
||||
'name': _('Create cash statement'),
|
||||
'type': 'ir.actions.act_window',
|
||||
'view_type': 'form',
|
||||
'view_mode': 'form',
|
||||
'res_model': 'account.bank.statement',
|
||||
'context': ctx,
|
||||
}
|
||||
|
||||
@api.multi
|
||||
def action_open_reconcile(self):
|
||||
if self.type in ['bank', 'cash']:
|
||||
# Open reconciliation view for bank statements belonging to this journal
|
||||
bank_stmt = self.env['account.bank.statement'].search([('journal_id', 'in', self.ids)])
|
||||
return {
|
||||
'type': 'ir.actions.client',
|
||||
'tag': 'bank_statement_reconciliation_view',
|
||||
'context': {'statement_ids': bank_stmt.ids, 'company_ids': self.mapped('company_id').ids},
|
||||
}
|
||||
else:
|
||||
# Open reconciliation view for customers/suppliers
|
||||
action_context = {'show_mode_selector': False, 'company_ids': self.mapped('company_id').ids}
|
||||
if self.type == 'sale':
|
||||
action_context.update({'mode': 'customers'})
|
||||
elif self.type == 'purchase':
|
||||
action_context.update({'mode': 'suppliers'})
|
||||
return {
|
||||
'type': 'ir.actions.client',
|
||||
'tag': 'manual_reconciliation_view',
|
||||
'context': action_context,
|
||||
}
|
||||
|
||||
@api.multi
|
||||
def open_action(self):
|
||||
"""return action based on type for related journals"""
|
||||
action_name = self._context.get('action_name', False)
|
||||
if not action_name:
|
||||
if self.type == 'bank':
|
||||
action_name = 'action_bank_statement_tree'
|
||||
elif self.type == 'cash':
|
||||
action_name = 'action_view_bank_statement_tree'
|
||||
elif self.type == 'sale':
|
||||
action_name = 'action_invoice_tree1'
|
||||
elif self.type == 'purchase':
|
||||
action_name = 'action_invoice_tree2'
|
||||
else:
|
||||
action_name = 'action_move_journal_line'
|
||||
|
||||
_journal_invoice_type_map = {
|
||||
('sale', None): 'out_invoice',
|
||||
('purchase', None): 'in_invoice',
|
||||
('sale', 'refund'): 'out_refund',
|
||||
('purchase', 'refund'): 'in_refund',
|
||||
('bank', None): 'bank',
|
||||
('cash', None): 'cash',
|
||||
('general', None): 'general',
|
||||
}
|
||||
invoice_type = _journal_invoice_type_map[(self.type, self._context.get('invoice_type'))]
|
||||
|
||||
ctx = self._context.copy()
|
||||
ctx.pop('group_by', None)
|
||||
ctx.update({
|
||||
'journal_type': self.type,
|
||||
'default_journal_id': self.id,
|
||||
'search_default_journal_id': self.id,
|
||||
'default_type': invoice_type,
|
||||
'type': invoice_type
|
||||
})
|
||||
|
||||
[action] = self.env.ref('account.%s' % action_name).read()
|
||||
action['context'] = ctx
|
||||
action['domain'] = self._context.get('use_domain', [])
|
||||
account_invoice_filter = self.env.ref('account.view_account_invoice_filter', False)
|
||||
if action_name in ['action_invoice_tree1', 'action_invoice_tree2']:
|
||||
action['search_view_id'] = account_invoice_filter and account_invoice_filter.id or False
|
||||
if action_name in ['action_bank_statement_tree', 'action_view_bank_statement_tree']:
|
||||
action['views'] = False
|
||||
action['view_id'] = False
|
||||
return action
|
||||
|
||||
@api.multi
|
||||
def open_spend_money(self):
|
||||
return self.open_payments_action('outbound')
|
||||
|
||||
@api.multi
|
||||
def open_collect_money(self):
|
||||
return self.open_payments_action('inbound')
|
||||
|
||||
@api.multi
|
||||
def open_transfer_money(self):
|
||||
return self.open_payments_action('transfer')
|
||||
|
||||
@api.multi
|
||||
def open_payments_action(self, payment_type):
|
||||
ctx = self._context.copy()
|
||||
ctx.update({
|
||||
'default_payment_type': payment_type,
|
||||
'default_journal_id': self.id
|
||||
})
|
||||
ctx.pop('group_by', None)
|
||||
action_rec = self.env['ir.model.data'].xmlid_to_object('account.action_account_payments')
|
||||
if action_rec:
|
||||
action = action_rec.read([])[0]
|
||||
action['context'] = ctx
|
||||
action['domain'] = [('journal_id','=',self.id),('payment_type','=',payment_type)]
|
||||
return action
|
||||
|
||||
@api.multi
|
||||
def open_action_with_context(self):
|
||||
action_name = self.env.context.get('action_name', False)
|
||||
if not action_name:
|
||||
return False
|
||||
ctx = dict(self.env.context, default_journal_id=self.id)
|
||||
if ctx.get('search_default_journal', False):
|
||||
ctx.update(search_default_journal_id=self.id)
|
||||
ctx.pop('group_by', None)
|
||||
ir_model_obj = self.env['ir.model.data']
|
||||
model, action_id = ir_model_obj.get_object_reference('account', action_name)
|
||||
[action] = self.env[model].browse(action_id).read()
|
||||
action['context'] = ctx
|
||||
if ctx.get('use_domain', False):
|
||||
action['domain'] = ['|', ('journal_id', '=', self.id), ('journal_id', '=', False)]
|
||||
action['name'] += ' for journal ' + self.name
|
||||
return action
|
||||
|
||||
@api.multi
|
||||
def create_bank_statement(self):
|
||||
"""return action to create a bank statements. This button should be called only on journals with type =='bank'"""
|
||||
self.bank_statements_source = 'manual'
|
||||
action = self.env.ref('account.action_bank_statement_tree').read()[0]
|
||||
action.update({
|
||||
'views': [[False, 'form']],
|
||||
'context': "{'default_journal_id': " + str(self.id) + "}",
|
||||
})
|
||||
return action
|
||||
|
||||
#####################
|
||||
# Setup Steps Stuff #
|
||||
#####################
|
||||
@api.model
|
||||
def retrieve_account_dashboard_setup_bar(self):
|
||||
""" Returns the data used by the setup bar on the Accounting app dashboard."""
|
||||
company = self.env.user.company_id
|
||||
return {
|
||||
'show_setup_bar': not company.account_setup_bar_closed,
|
||||
'company': company.account_setup_company_data_done,
|
||||
'bank': company.account_setup_bank_data_done,
|
||||
'fiscal_year': company.account_setup_fy_data_done,
|
||||
'chart_of_accounts': company.account_setup_coa_done,
|
||||
'initial_balance': company.opening_move_posted(),
|
||||
}
|
||||
|
||||
def mark_bank_setup_as_done_action(self):
|
||||
""" Marks the 'bank setup' step as done in the setup bar and in the company."""
|
||||
self.company_id.account_setup_bank_data_done = True
|
||||
|
||||
def unmark_bank_setup_as_done_action(self):
|
||||
""" Marks the 'bank setup' step as not done in the setup bar and in the company."""
|
||||
self.company_id.account_setup_bank_data_done = False
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user