Feat[BE]: refactor document handling in transfer service and introduce document type constants

This commit is contained in:
aguhh18
2025-12-23 17:51:42 +07:00
parent c55fdb75a7
commit e935843cba
5 changed files with 73 additions and 53 deletions
@@ -20,4 +20,5 @@ type StockTransferDelivery struct {
StockTransfer *StockTransfer `gorm:"foreignKey:StockTransferId"`
Supplier *Supplier `gorm:"foreignKey:SupplierId"`
Items []StockTransferDeliveryItem `gorm:"foreignKey:StockTransferDeliveryId"`
Documents []Document `gorm:"foreignKey:DocumentableId;constraint:OnUpdate:CASCADE,OnDelete:CASCADE"`
}