You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I overrode both the DETAIL template and the EDIT template of my object/table (let's call it Foo). It has a relationship to another object/table, named Client:
I could really use some help on this one. Any tips on how to move forward?
One difference between the DETAIL and the EDIT screens/HTMLs is that in EDIT mode my relationship entity (Client) is displayed in a drop-down, whereas in the DETAIL screen it is a "clickable blue button". Maybe this causes side-effects in the "obj" object in jinja2?
Describe the bug
I overrode both the DETAIL template and the EDIT template of my object/table (let's call it Foo). It has a relationship to another object/table, named Client:
This Client object has a field/column, vhost, which is a String.
I have this snippet in my temple for both EDIT and DETAIL:
Then I am looking at my entity, the value is populated. When I am editing, I get an empty string.
What I SUSPECT: in EDIT mode the relationships are fetched in a lazy fashion, perhaps? I need to force the loading, perhaps? How?
To Reproduce
Well, in any of your objects/entities/tables, override EDIT and DETAIL templates and print a property of a related entity.
Environment (please complete the following information):
Starlette-Admin version: 0.13.1
ORM/ODMs: SQLAlchemy, psycopg2-binary==2.9.9
SQLAlchemy-serializer==1.4.1
Additional context
The text was updated successfully, but these errors were encountered: