feat(backend): Update models and endpoints configuration
- Enhanced ticket and comment models with proper relationships - Updated client_profile model for better data handling - Improved auth endpoint with better error handling - Updated main app configuration and imports - Added new dependencies to requirements.txt - Enhanced tickets endpoint with attachment support
This commit is contained in:
@@ -126,6 +126,12 @@ class Ticket(Base):
|
||||
cascade="all, delete-orphan"
|
||||
)
|
||||
|
||||
attachments: Mapped[list["TicketAttachment"]] = relationship(
|
||||
"TicketAttachment",
|
||||
back_populates="ticket",
|
||||
cascade="all, delete-orphan"
|
||||
)
|
||||
|
||||
# ✅ AÑADIDOS: Constraints según schema.sql
|
||||
__table_args__ = (
|
||||
UniqueConstraint('tenant_id', 'ticket_number', name='uq_tickets_tenant_number'),
|
||||
|
||||
Reference in New Issue
Block a user