Fill models with indexes when database is not updated but indexes

Closes #13347
This commit is contained in:
Cédric Krier committed 2024-06-18 20:41:06 +02:00
1 parent 9424176aa3
commit 85a5a09a53
1 file changed
+4
+4
View File
@@ -231,6 +231,10 @@ def load_module_graph(graph, pool, update=None, lang=None, indexes=True):
[[0, CurrentTimestamp(), module, 'activated'],
]))
module2state[module] = 'activated'
elif not update and indexes:
for model in classes['model']:
if hasattr(model, '_update_sql_indexes'):
models_with_indexes.add(model.__name__)
if not update:
pool.setup()