fix(BE-273): add object nonstock and supplier in response get one and fix name base to relation in dto

This commit is contained in:
Hafizh A. Y
2025-11-20 14:59:50 +07:00
parent b4b860b9d4
commit 228aedc215
64 changed files with 964 additions and 3576 deletions
+5 -2
View File
@@ -3,7 +3,10 @@ package entities
import "time"
type NonstockSupplier struct {
NonstockID uint `gorm:"primaryKey"`
SupplierID uint `gorm:"primaryKey"`
NonstockId uint `gorm:"not null"`
SupplierId uint `gorm:"not null"`
CreatedAt time.Time `gorm:"autoCreateTime"`
Nonstock Nonstock `gorm:"foreignKey:NonstockId;references:Id"`
Supplier Supplier `gorm:"foreignKey:SupplierId;references:Id"`
}