diff --git a/repondeur/zam_repondeur/visam/models/membership.py b/repondeur/zam_repondeur/visam/models/membership.py index 04b85b395..fe30cfb8b 100644 --- a/repondeur/zam_repondeur/visam/models/membership.py +++ b/repondeur/zam_repondeur/visam/models/membership.py @@ -21,6 +21,8 @@ class UserMembership(Base): __tablename__ = "users_chambres" + __repr_keys__ = ("user", "chambre", "organisation") + user_pk = Column( Integer, ForeignKey("users.pk", onupdate="CASCADE", ondelete="CASCADE"), diff --git a/repondeur/zam_repondeur/visam/models/organisation.py b/repondeur/zam_repondeur/visam/models/organisation.py index 822bb9291..b466d4a75 100644 --- a/repondeur/zam_repondeur/visam/models/organisation.py +++ b/repondeur/zam_repondeur/visam/models/organisation.py @@ -8,6 +8,8 @@ class Organisation(Base): __tablename__ = "organisations" + __repr_keys__ = ("name",) + pk = Column(Integer, primary_key=True) name: str = Column(Text, nullable=False, unique=True)