Use history table instance to migrate supply on sale column on history table

Closes #12379
This commit is contained in:
Cédric Krier committed 2023-07-15 00:36:31 +02:00
1 parent 9096dda5b4
commit 09794bbccd
1 file changed
+1 -1
+1 -1
View File
@@ -35,7 +35,7 @@ class Template(metaclass=PoolMeta):
table_h.column_rename('supply_on_sale', '_temp_supply_on_sale')
if cls._history:
h_table_h = cls.__table_handler__(module, history=True)
h_table = cls.__table__()
h_table = cls.__table_history__()
h_migrate_supply_on_sale = (
h_table_h.column_exist('supply_on_sale')
and h_table_h.column_is_type('supply_on_sale', 'BOOL'))