mirror of
https://gitlab.com/mbugroup/lti-api.git
synced 2026-05-20 13:31:56 +00:00
4107cf19ec
- Implement CreateOne for stock transfer with multi-delivery and validation - Preload warehouse, location, and area relations in transfer response - Add audit log for transfer - Improve transaction handling and error management
19 lines
565 B
Go
19 lines
565 B
Go
package entities
|
|
|
|
import "time"
|
|
|
|
// DETAIL PRODUK
|
|
type StockTransferDetail struct {
|
|
Id uint64 `gorm:"primaryKey;autoIncrement"`
|
|
StockTransferId uint64
|
|
ProductId uint64
|
|
Quantity float64
|
|
CreatedAt time.Time
|
|
UpdatedAt time.Time
|
|
DeletedAt *time.Time `gorm:"index"`
|
|
// Relations
|
|
StockTransfer *StockTransfer `gorm:"foreignKey:StockTransferId"`
|
|
Product *Product `gorm:"foreignKey:ProductId"`
|
|
DeliveryItems []StockTransferDeliveryItem `gorm:"foreignKey:StockTransferDetailId"`
|
|
}
|