🐛 Remember to alias builtin apps before inferring
This commit is contained in:
parent
63d2c31763
commit
bb8884f419
1 changed files with 2 additions and 0 deletions
|
|
@ -45,6 +45,8 @@ class ModelMeta(type(TortoiseModel)):
|
|||
inferred_app = module_parts[-2]
|
||||
else:
|
||||
inferred_app = module_parts[-1]
|
||||
# Rewrite builtin apps to ohmyapi_* alias
|
||||
inferred_app = inferred_app.replace("ohmyapi.builtin.", "ohmyapi_")
|
||||
meta.app = inferred_app
|
||||
|
||||
# Prefix table name if not explicitly set
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue