Compare commits
41 commits
Author | SHA1 | Date | |
---|---|---|---|
![]() |
791ee1b0ca | ||
![]() |
aa83ef23f6 | ||
![]() |
ef3631e706 | ||
![]() |
92e422b68a | ||
![]() |
bdcc618d5e | ||
![]() |
ce2362d261 | ||
![]() |
ba9e00df50 | ||
![]() |
aa0134a67d | ||
![]() |
25986aeae9 | ||
![]() |
da12aac254 | ||
![]() |
6b33fdfd2f | ||
![]() |
5f87fef4cc | ||
![]() |
18e9e965b1 | ||
![]() |
4b1e5412af | ||
![]() |
c21ca9f408 | ||
![]() |
408b9a9679 | ||
![]() |
fafcbe799d | ||
![]() |
695e60dea8 | ||
![]() |
042e1b9a56 | ||
![]() |
d932e15878 | ||
![]() |
b4df059b4d | ||
![]() |
0b5f4633a8 | ||
![]() |
85e412564c | ||
![]() |
08b8768dd4 | ||
![]() |
0b2bada596 | ||
![]() |
d780a844ca | ||
![]() |
f26724593e | ||
![]() |
b3b92e4018 | ||
![]() |
7601b12800 | ||
![]() |
3bc4b555c8 | ||
![]() |
3db5ec1619 | ||
![]() |
5007985264 | ||
![]() |
b584a9f53e | ||
![]() |
56861eb2dd | ||
![]() |
d4d5fc7d78 | ||
![]() |
6e53bd8eac | ||
![]() |
2eed52b374 | ||
![]() |
7a3da5f164 | ||
![]() |
7ad7a3760e | ||
![]() |
865780147a | ||
![]() |
2885de7c27 |
12 changed files with 48 additions and 23 deletions
2
.env
2
.env
|
@ -1 +1 @@
|
|||
PYTHONPATH=~/Projekte/tr70/lib/python3.10/site-packages
|
||||
PYTHONPATH=~/Projekte/tr50/lib/python3.10/site-packages
|
1
.gitignore
vendored
1
.gitignore
vendored
|
@ -4,3 +4,4 @@ dist/*
|
|||
mds_account_invoice_xrechnung.egg-info/*
|
||||
__pycache__/*
|
||||
locale/convert_de2en.py
|
||||
.env
|
||||
|
|
18
README.rst
18
README.rst
|
@ -9,11 +9,23 @@ pip install mds-account-invoice-xrechnung
|
|||
|
||||
Requires
|
||||
========
|
||||
- Tryton 7.0
|
||||
- Tryton 5.0
|
||||
|
||||
Changes
|
||||
=======
|
||||
|
||||
*7.0.0 - 22.12.2023*
|
||||
*5.0.10 - 11.02.2025*
|
||||
|
||||
- compatiblity to Tryton 7.0
|
||||
- Allow the export of paid invoices. (Mathias Behrle <mathiasb@m9s.biz>)
|
||||
|
||||
*5.0.8 - 28.01.2025*
|
||||
|
||||
- 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
|
||||
|
|
|
@ -17,7 +17,7 @@ class InvoiceLine(metaclass=PoolMeta):
|
|||
cls.unit.states['required'],
|
||||
And(
|
||||
Eval('type') == 'line',
|
||||
Bool(Eval('quantity'))))
|
||||
cls.unit.depends.update(['type', 'quantity'])
|
||||
Bool(Eval('quantity', None))))
|
||||
cls.unit.depends.extend(['type', 'quantity'])
|
||||
|
||||
# end Invoice
|
||||
|
|
4
setup.py
4
setup.py
|
@ -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]}
|
||||
|
||||
# tryton-version
|
||||
major_version = 7
|
||||
major_version = 5
|
||||
minor_version = 0
|
||||
|
||||
requires = ['python-slugify', 'pypdf', 'factur-x']
|
||||
|
@ -83,6 +83,8 @@ setup(
|
|||
'Natural Language :: English',
|
||||
'Operating System :: OS Independent',
|
||||
'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.9',
|
||||
'Programming Language :: Python :: 3.10',
|
||||
|
|
|
@ -2,3 +2,18 @@
|
|||
# This file is part of the account-invoice-xrechnung-module
|
||||
# from m-ds for Tryton. The COPYRIGHT file at the top level of
|
||||
# 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
|
||||
|
|
|
@ -18,16 +18,10 @@ from .xml_data import xml_from_pdf
|
|||
def set_invoice_sequences(fiscalyear):
|
||||
pool = Pool()
|
||||
Sequence = pool.get('ir.sequence.strict')
|
||||
SequenceType = pool.get('ir.sequence.type')
|
||||
InvoiceSequence = pool.get('account.fiscalyear.invoice_sequence')
|
||||
ModelData = pool.get('ir.model.data')
|
||||
|
||||
sequence = Sequence(
|
||||
name=fiscalyear.name,
|
||||
sequence_type=SequenceType(ModelData.get_id(
|
||||
'account_invoice', 'sequence_type_account_invoice')),
|
||||
company=fiscalyear.company,
|
||||
)
|
||||
sequence = Sequence(name=fiscalyear.name, code='account.invoice')
|
||||
sequence.company = fiscalyear.company
|
||||
sequence.save()
|
||||
fiscalyear.invoice_sequences = []
|
||||
invoice_sequence = InvoiceSequence()
|
||||
|
@ -132,7 +126,7 @@ class InvoiceTestCase(ModuleTestCase):
|
|||
'addresses': [('create', [{
|
||||
'invoice': True,
|
||||
'street': 'Applicant Street 1',
|
||||
'postal_code': '12345',
|
||||
'zip': '12345',
|
||||
'city': 'Usertown',
|
||||
'country': country_de.id,
|
||||
}])],
|
||||
|
@ -199,7 +193,7 @@ class InvoiceTestCase(ModuleTestCase):
|
|||
self.assertEqual(
|
||||
list(result['view']['defaults'].keys()), [
|
||||
'as_zip', 'edocument', 'invoice', 'state',
|
||||
'invoice.'])
|
||||
'invoice.rec_name'])
|
||||
|
||||
data = {}
|
||||
for x in result['view']['defaults'].keys():
|
||||
|
@ -225,7 +219,6 @@ class InvoiceTestCase(ModuleTestCase):
|
|||
action['report_name'],
|
||||
'account_invoice_xrechnung.export')
|
||||
self.assertEqual(action['type'], 'ir.action.report')
|
||||
self.assertEqual(action['records'], 'selected')
|
||||
|
||||
# 2nd step, wizard told us which report we must execute
|
||||
ReportExport = pool.get(
|
||||
|
|
|
@ -1,9 +1,10 @@
|
|||
[tryton]
|
||||
version=7.0.0
|
||||
version=5.0.9
|
||||
depends:
|
||||
account_invoice
|
||||
bank
|
||||
edocument_xrechnung
|
||||
tryton6_backport
|
||||
xml:
|
||||
message.xml
|
||||
configuration.xml
|
||||
|
|
|
@ -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
|
||||
|
|
|
@ -4,7 +4,7 @@
|
|||
full copyright notices and license terms. -->
|
||||
<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"/>
|
||||
<label name="xrechn_zugferd_report"/>
|
||||
|
|
|
@ -7,8 +7,8 @@ from trytond.model import ModelView, fields
|
|||
from trytond.wizard import Wizard, StateView, StateReport, Button
|
||||
from trytond.pool import Pool
|
||||
from trytond.exceptions import UserError
|
||||
from trytond.i18n import gettext
|
||||
from trytond.transaction import Transaction
|
||||
from trytond.modules.tryton6_backport import gettext
|
||||
|
||||
|
||||
sel_edocument = [
|
||||
|
|
|
@ -10,7 +10,7 @@ from slugify import slugify
|
|||
from trytond.report import Report
|
||||
from trytond.pool import Pool
|
||||
from trytond.exceptions import UserError
|
||||
from trytond.i18n import gettext
|
||||
from trytond.modules.tryton6_backport import gettext
|
||||
from trytond.transaction import Transaction
|
||||
from .wizard_runreport import edoc_versions
|
||||
|
||||
|
|
Loading…
Reference in a new issue