Compare commits

...

39 commits

Author SHA1 Message Date
Frederik Jaeckel
ef3631e706 Version 5.0.8 2025-01-28 14:28:01 +01:00
Frederik Jaeckel
92e422b68a Merge branch 'main' into 5.0 2025-01-28 14:27:06 +01:00
Frederik Jaeckel
bdcc618d5e Merge branch 'main' into 5.0 2025-01-28 11:16:06 +01:00
Frederik Jaeckel
ce2362d261 Version 5.0.7 2024-12-17 14:40:38 +01:00
Frederik Jaeckel
ba9e00df50 dont write to 'invoice_report_cache_id' 2024-12-17 14:23:51 +01:00
Frederik Jaeckel
aa0134a67d optimize generation of pdf if its not stored to db 2024-12-17 13:21:55 +01:00
Frederik Jaeckel
25986aeae9 Version 5.0.6 2024-12-11 18:11:26 +01:00
Frederik Jaeckel
da12aac254 5.0: compatibility to Tryton 5.0 2024-12-11 18:06:33 +01:00
Frederik Jaeckel
6b33fdfd2f Version 6.0.6 2024-12-11 17:22:55 +01:00
Frederik Jaeckel
5f87fef4cc delete invoice-report if type != pdf 2024-12-11 17:21:28 +01:00
Frederik Jaeckel
18e9e965b1 Version 6.0.5 2024-12-10 15:32:30 +01:00
Frederik Jaeckel
4b1e5412af update configuration form 2024-12-10 15:30:54 +01:00
Frederik Jaeckel
c21ca9f408 add iban to tests 2024-12-10 15:23:39 +01:00
Frederik Jaeckel
408b9a9679 update tests to check generated xml-data 2024-12-10 15:23:32 +01:00
Frederik Jaeckel
fafcbe799d generate zugferd-pdf 2024-12-10 15:23:25 +01:00
Frederik Jaeckel
695e60dea8 configuration - add erechnung default report 2024-12-10 15:23:18 +01:00
Frederik Jaeckel
042e1b9a56 prepare zugferd 2024-12-10 15:23:10 +01:00
Frederik Jaeckel
d932e15878 add selection for factur-x 2024-12-10 15:22:58 +01:00
Frederik Jaeckel
b4df059b4d configuration for pdf-invoice 2024-12-10 15:22:36 +01:00
Frederik Jaeckel
0b5f4633a8 export of xrechnung 2.2 + 2.3 + 3.0 2024-12-10 15:22:31 +01:00
Frederik Jaeckel
85e412564c merge... 2024-12-10 15:22:17 +01:00
Frederik Jaeckel
08b8768dd4 formatting 2024-12-10 15:21:55 +01:00
Frederik Jaeckel
0b2bada596 file info 2024-12-10 15:20:33 +01:00
Frederik Jaeckel
d780a844ca update gitignore 2024-12-10 15:20:04 +01:00
Frederik Jaeckel
f26724593e Etikett ver 6.0.3 zum Änderungssatz 38cea9a01af7 hinzugefügt 2023-06-30 16:23:39 +02:00
Frederik Jaeckel
b3b92e4018 Version 6.0.3 2023-06-30 16:23:32 +02:00
Frederik Jaeckel
7601b12800 merge... 2023-06-30 16:21:55 +02:00
Frederik Jaeckel
3bc4b555c8 formatting 2023-06-30 11:29:53 +02:00
Frederik Jaeckel
3db5ec1619 formatting 2023-06-30 11:21:48 +02:00
Frederik Jaeckel
5007985264 Etikett ver 6.0.2 zum Änderungssatz 5447d6b63dca hinzugefügt 2022-10-20 15:44:27 +02:00
Frederik Jaeckel
b584a9f53e Version 6.0.2 2022-10-20 15:44:14 +02:00
Frederik Jaeckel
56861eb2dd info bei nicht-festgeschriebener rechnung 2022-10-20 15:42:55 +02:00
Frederik Jaeckel
d4d5fc7d78 SETUP 2022-10-20 15:13:13 +02:00
Frederik Jaeckel
6e53bd8eac Etikett ver 6.0.1 zum Änderungssatz 9985d05266c7 hinzugefügt 2022-10-20 14:54:35 +02:00
Frederik Jaeckel
2eed52b374 Etikett ver 6.0.1 gelöscht 2022-10-20 14:54:23 +02:00
Frederik Jaeckel
7a3da5f164 versiondep 2022-10-20 14:54:01 +02:00
Frederik Jaeckel
7ad7a3760e setup.py 2022-10-20 14:48:31 +02:00
Frederik Jaeckel
865780147a Etikett ver 6.0.1 zum Änderungssatz 022c25cbd3da hinzugefügt 2022-10-20 14:45:00 +02:00
Frederik Jaeckel
2885de7c27 Version 6.0.1 2022-10-20 14:44:50 +02:00
12 changed files with 44 additions and 23 deletions

2
.env
View file

@ -1 +1 @@
PYTHONPATH=~/Projekte/tr70/lib/python3.10/site-packages PYTHONPATH=~/Projekte/tr50/lib/python3.10/site-packages

1
.gitignore vendored
View file

@ -4,3 +4,4 @@ dist/*
mds_account_invoice_xrechnung.egg-info/* mds_account_invoice_xrechnung.egg-info/*
__pycache__/* __pycache__/*
locale/convert_de2en.py locale/convert_de2en.py
.env

View file

@ -9,11 +9,19 @@ pip install mds-account-invoice-xrechnung
Requires Requires
======== ========
- Tryton 7.0 - Tryton 5.0
Changes Changes
======= =======
*7.0.0 - 22.12.2023* *5.0.8 - 28.01.2025*
- compatiblity to Tryton 7.0 - fix: select 1st invoice-report (Mathias Behrle <mathiasb@m9s.biz>)
*5.0.7 - 17.12.2024*
- optimize pdf-generate
*5.0.6 - 11.12.2024*
- compatiblitiy to Tryton 5.0

View file

@ -17,7 +17,7 @@ class InvoiceLine(metaclass=PoolMeta):
cls.unit.states['required'], cls.unit.states['required'],
And( And(
Eval('type') == 'line', Eval('type') == 'line',
Bool(Eval('quantity')))) Bool(Eval('quantity', None))))
cls.unit.depends.update(['type', 'quantity']) cls.unit.depends.extend(['type', 'quantity'])
# end Invoice # end Invoice

View file

@ -35,7 +35,7 @@ with open(path.join(here, 'versiondep.txt'), encoding='utf-8') as f:
modversion[l2[0]] = {'min': l2[1], 'max': l2[2], 'prefix': l2[3]} modversion[l2[0]] = {'min': l2[1], 'max': l2[2], 'prefix': l2[3]}
# tryton-version # tryton-version
major_version = 7 major_version = 5
minor_version = 0 minor_version = 0
requires = ['python-slugify', 'pypdf', 'factur-x'] requires = ['python-slugify', 'pypdf', 'factur-x']
@ -83,6 +83,8 @@ setup(
'Natural Language :: English', 'Natural Language :: English',
'Operating System :: OS Independent', 'Operating System :: OS Independent',
'License :: OSI Approved :: GNU General Public License (GPL)', 'License :: OSI Approved :: GNU General Public License (GPL)',
'Programming Language :: Python :: 3.6',
'Programming Language :: Python :: 3.7',
'Programming Language :: Python :: 3.8', 'Programming Language :: Python :: 3.8',
'Programming Language :: Python :: 3.9', 'Programming Language :: Python :: 3.9',
'Programming Language :: Python :: 3.10', 'Programming Language :: Python :: 3.10',

View file

@ -2,3 +2,18 @@
# This file is part of the account-invoice-xrechnung-module # This file is part of the account-invoice-xrechnung-module
# from m-ds for Tryton. The COPYRIGHT file at the top level of # from m-ds for Tryton. The COPYRIGHT file at the top level of
# this repository contains the full copyright notices and license terms. # this repository contains the full copyright notices and license terms.
import trytond.tests.test_tryton
import unittest
from .test_invoice import InvoiceTestCase
__all__ = ['suite']
def suite():
suite = trytond.tests.test_tryton.suite()
suite.addTests(unittest.TestLoader().loadTestsFromTestCase(
InvoiceTestCase))
return suite

View file

@ -18,16 +18,10 @@ from .xml_data import xml_from_pdf
def set_invoice_sequences(fiscalyear): def set_invoice_sequences(fiscalyear):
pool = Pool() pool = Pool()
Sequence = pool.get('ir.sequence.strict') Sequence = pool.get('ir.sequence.strict')
SequenceType = pool.get('ir.sequence.type')
InvoiceSequence = pool.get('account.fiscalyear.invoice_sequence') InvoiceSequence = pool.get('account.fiscalyear.invoice_sequence')
ModelData = pool.get('ir.model.data')
sequence = Sequence( sequence = Sequence(name=fiscalyear.name, code='account.invoice')
name=fiscalyear.name, sequence.company = fiscalyear.company
sequence_type=SequenceType(ModelData.get_id(
'account_invoice', 'sequence_type_account_invoice')),
company=fiscalyear.company,
)
sequence.save() sequence.save()
fiscalyear.invoice_sequences = [] fiscalyear.invoice_sequences = []
invoice_sequence = InvoiceSequence() invoice_sequence = InvoiceSequence()
@ -132,7 +126,7 @@ class InvoiceTestCase(ModuleTestCase):
'addresses': [('create', [{ 'addresses': [('create', [{
'invoice': True, 'invoice': True,
'street': 'Applicant Street 1', 'street': 'Applicant Street 1',
'postal_code': '12345', 'zip': '12345',
'city': 'Usertown', 'city': 'Usertown',
'country': country_de.id, 'country': country_de.id,
}])], }])],
@ -199,7 +193,7 @@ class InvoiceTestCase(ModuleTestCase):
self.assertEqual( self.assertEqual(
list(result['view']['defaults'].keys()), [ list(result['view']['defaults'].keys()), [
'as_zip', 'edocument', 'invoice', 'state', 'as_zip', 'edocument', 'invoice', 'state',
'invoice.']) 'invoice.rec_name'])
data = {} data = {}
for x in result['view']['defaults'].keys(): for x in result['view']['defaults'].keys():
@ -225,7 +219,6 @@ class InvoiceTestCase(ModuleTestCase):
action['report_name'], action['report_name'],
'account_invoice_xrechnung.export') 'account_invoice_xrechnung.export')
self.assertEqual(action['type'], 'ir.action.report') self.assertEqual(action['type'], 'ir.action.report')
self.assertEqual(action['records'], 'selected')
# 2nd step, wizard told us which report we must execute # 2nd step, wizard told us which report we must execute
ReportExport = pool.get( ReportExport = pool.get(

View file

@ -1,9 +1,10 @@
[tryton] [tryton]
version=7.0.0 version=5.0.8
depends: depends:
account_invoice account_invoice
bank bank
edocument_xrechnung edocument_xrechnung
tryton6_backport
xml: xml:
message.xml message.xml
configuration.xml configuration.xml

View file

@ -1 +1,2 @@
edocument_xrechnung;7.0.5;7.0.999;mds edocument_xrechnung;5.0.13;5.0.999;mds
tryton6_backport;5.0.3;5.0.999;mds

View file

@ -4,7 +4,7 @@
full copyright notices and license terms. --> full copyright notices and license terms. -->
<data> <data>
<xpath expr="/form/separator[@id='currency_exchange']" position="before"> <xpath expr="/form/separator[@id='invoice']" position="before">
<separator id="xrechnung" colspan="4" string="ZUGFeRD - e-Invoice"/> <separator id="xrechnung" colspan="4" string="ZUGFeRD - e-Invoice"/>
<label name="xrechn_zugferd_report"/> <label name="xrechn_zugferd_report"/>

View file

@ -7,8 +7,8 @@ from trytond.model import ModelView, fields
from trytond.wizard import Wizard, StateView, StateReport, Button from trytond.wizard import Wizard, StateView, StateReport, Button
from trytond.pool import Pool from trytond.pool import Pool
from trytond.exceptions import UserError from trytond.exceptions import UserError
from trytond.i18n import gettext
from trytond.transaction import Transaction from trytond.transaction import Transaction
from trytond.modules.tryton6_backport import gettext
sel_edocument = [ sel_edocument = [

View file

@ -10,7 +10,7 @@ from slugify import slugify
from trytond.report import Report from trytond.report import Report
from trytond.pool import Pool from trytond.pool import Pool
from trytond.exceptions import UserError from trytond.exceptions import UserError
from trytond.i18n import gettext from trytond.modules.tryton6_backport import gettext
from trytond.transaction import Transaction from trytond.transaction import Transaction
from .wizard_runreport import edoc_versions from .wizard_runreport import edoc_versions