mirror of
https://gitlab.com/mbugroup/lti-api.git
synced 2026-05-20 13:31:56 +00:00
26 lines
971 B
Go
26 lines
971 B
Go
package entities
|
|
|
|
import (
|
|
"time"
|
|
|
|
"gorm.io/gorm"
|
|
)
|
|
|
|
type ExpenseRealization struct {
|
|
Id uint64 `gorm:"primaryKey;autoIncrement"`
|
|
ExpenseNonstockId *uint64 `gorm:""`
|
|
RealizationQty float64 `gorm:"type:numeric(15,3);not null"`
|
|
RealizationUnitPrice float64 `gorm:"type:numeric(15,3);not null"`
|
|
RealizationTotalPrice float64 `gorm:"type:numeric(15,3);not null"`
|
|
RealizationDate time.Time `gorm:"type:date;not null"`
|
|
Note *string `gorm:"type:text"`
|
|
CreatedBy *uint64 `gorm:""`
|
|
CreatedAt time.Time `gorm:"autoCreateTime"`
|
|
UpdatedAt time.Time `gorm:"autoUpdateTime"`
|
|
DeletedAt gorm.DeletedAt `gorm:"index" json:"-"`
|
|
|
|
// Relations
|
|
ExpenseNonstock *ExpenseNonstock `gorm:"foreignKey:ExpenseNonstockId;references:Id"`
|
|
CreatedUser *User `gorm:"foreignKey:CreatedBy;references:Id"`
|
|
}
|