v0.1
This commit is contained in:
@@ -25,7 +25,7 @@ class Deal(BaseModel):
|
||||
created_at = Column(DateTime, nullable=False, comment='Дата создания')
|
||||
current_status = Column(Integer, nullable=False, comment='Текущий статус')
|
||||
|
||||
client_id = Column(Integer, ForeignKey('clients.id'), nullable=False, comment='ID клиента', cascade='all, delete-orphan')
|
||||
client_id = Column(Integer, ForeignKey('clients.id', ondelete='CASCADE'), nullable=False, comment='ID клиента')
|
||||
client = relationship('Client', backref='deals')
|
||||
|
||||
status_history = relationship('DealStatusHistory', back_populates='deal', cascade="all, delete-orphan")
|
||||
|
||||
Reference in New Issue
Block a user