Tryton 6.8: indexes + tests changed
This commit is contained in:
parent
4ae07b962f
commit
e0e1fd07a7
8 changed files with 14 additions and 32 deletions
|
@ -9,11 +9,11 @@ pip install mds-cashbook-bookcategory
|
|||
|
||||
Requires
|
||||
========
|
||||
- Tryton 6.0
|
||||
- Tryton 6.8
|
||||
|
||||
Changes
|
||||
=======
|
||||
|
||||
*6.0.0 - 07.11.2022*
|
||||
*6.8.4 - 05.06.2023*
|
||||
|
||||
- init
|
||||
- code optimized, porting to Tryton 6.8
|
||||
|
|
4
book.py
4
book.py
|
@ -22,10 +22,10 @@ class CategoryCashbookRel(ModelSQL):
|
|||
__name__ = 'cashbook.bookcategory-rel'
|
||||
|
||||
category = fields.Many2One(
|
||||
string='Category', required=True, select=True,
|
||||
string='Category', required=True,
|
||||
model_name='cashbook.bookcategory', ondelete='CASCADE')
|
||||
cashbook = fields.Many2One(
|
||||
string='Cashbook', required=True, select=True,
|
||||
string='Cashbook', required=True,
|
||||
model_name='cashbook.book', ondelete='CASCADE')
|
||||
|
||||
# end CategoryCashbookRel
|
||||
|
|
|
@ -17,7 +17,7 @@ class Category(tree(separator=' / '), ModelSQL, ModelView):
|
|||
name = fields.Char(string='Name', required=True, translate=True)
|
||||
|
||||
parent = fields.Many2One(
|
||||
string='Parent', select=True,
|
||||
string='Parent',
|
||||
model_name='cashbook.bookcategory', ondelete='CASCADE')
|
||||
childs = fields.One2Many(
|
||||
string='Children', field='parent',
|
||||
|
|
3
setup.py
3
setup.py
|
@ -40,7 +40,7 @@ with open(path.join(here, 'versiondep.txt'), encoding='utf-8') as f:
|
|||
|
||||
# tryton-version
|
||||
major_version = 6
|
||||
minor_version = 0
|
||||
minor_version = 8
|
||||
|
||||
requires = []
|
||||
for dep in info.get('depends', []):
|
||||
|
@ -89,6 +89,7 @@ setup(name='%s_%s' % (PREFIX, MODULE),
|
|||
'License :: OSI Approved :: GNU General Public License (GPL)',
|
||||
'Programming Language :: Python :: 3.7',
|
||||
'Programming Language :: Python :: 3.8',
|
||||
'Programming Language :: Python :: 3.9',
|
||||
],
|
||||
|
||||
keywords='tryton cashbook category',
|
||||
|
|
|
@ -2,25 +2,3 @@
|
|||
# This file is part of the cashbook-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_category import CategoryTestCase
|
||||
|
||||
|
||||
__all__ = ['suite']
|
||||
|
||||
|
||||
class CashbookCategoryTestCase(CategoryTestCase):
|
||||
'Test cashbook module'
|
||||
module = 'cashbook_bookcategory'
|
||||
|
||||
# end CashbookCategoryTestCase
|
||||
|
||||
|
||||
def suite():
|
||||
suite = trytond.tests.test_tryton.suite()
|
||||
suite.addTests(unittest.TestLoader().loadTestsFromTestCase(
|
||||
CashbookCategoryTestCase))
|
||||
return suite
|
||||
|
|
|
@ -6,7 +6,7 @@
|
|||
from trytond.tests.test_tryton import with_transaction
|
||||
from trytond.pool import Pool
|
||||
from trytond.transaction import Transaction
|
||||
from trytond.modules.cashbook.tests import CashbookTestCase
|
||||
from trytond.modules.cashbook.tests.test_module import CashbookTestCase
|
||||
|
||||
|
||||
class CategoryTestCase(CashbookTestCase):
|
||||
|
@ -98,3 +98,6 @@ class CategoryTestCase(CashbookTestCase):
|
|||
self.assertEqual(len(book.categories), 0)
|
||||
|
||||
# end CategoryTestCase
|
||||
|
||||
|
||||
del CashbookTestCase
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
[tryton]
|
||||
version=6.0.0
|
||||
version=6.8.4
|
||||
depends:
|
||||
cashbook
|
||||
xml:
|
||||
|
|
|
@ -1,2 +1,2 @@
|
|||
cashbook;6.0.19;6.0.999;mds
|
||||
cashbook;6.8.28;6.8.999;mds
|
||||
|
||||
|
|
Loading…
Reference in a new issue