mirror of
https://github.com/NaN-tic/trytond-aeat_347.git
synced 2023-12-14 02:03:00 +01:00
Use direct access to backend classes.
This commit is contained in:
parent
9b3b8de717
commit
70fe0ec291
5
party.py
5
party.py
|
@ -32,16 +32,15 @@ class Party(metaclass=PoolMeta):
|
|||
|
||||
@classmethod
|
||||
def __register__(cls, module_name):
|
||||
TableHandler = backend.get('TableHandler')
|
||||
cursor = Transaction().connection.cursor()
|
||||
table = TableHandler(cls, module_name)
|
||||
table = backend.TableHandler(cls, module_name)
|
||||
|
||||
created_347 = table.column_exist('include_347')
|
||||
|
||||
super(Party, cls).__register__(module_name)
|
||||
|
||||
# We need to reload table as it may be modified by __register__
|
||||
table = TableHandler(cls, module_name)
|
||||
table = backend.TableHandler(cls, module_name)
|
||||
if (not created_347 and table.column_exist('include_347')):
|
||||
sql_table = cls.__table__()
|
||||
identifier = Pool().get('party.identifier').__table__()
|
||||
|
|
Loading…
Reference in a new issue