mirror of
https://gitlab.com/mbugroup/lti-api.git
synced 2026-05-20 13:31:56 +00:00
get field type to response detail recording
This commit is contained in:
@@ -9,7 +9,7 @@ import (
|
||||
type Warehouse struct {
|
||||
Id uint `gorm:"primaryKey"`
|
||||
Name string `gorm:"type:varchar(50);not null"`
|
||||
Type string `gorm:"not null"`
|
||||
Type string `gorm:"column:type;not null"`
|
||||
AreaId uint `gorm:"not null"`
|
||||
LocationId *uint
|
||||
KandangId *uint
|
||||
|
||||
@@ -33,6 +33,7 @@ type ProjectFlockRelationDTO struct {
|
||||
type WarehouseRelationDTO struct {
|
||||
Id uint `json:"id"`
|
||||
Name string `json:"name"`
|
||||
Type string `json:"type"`
|
||||
Location *LocationRelationDTO `json:"location,omitempty"`
|
||||
}
|
||||
|
||||
@@ -113,6 +114,7 @@ func ToWarehouseRelationDTO(e *entity.Warehouse) *WarehouseRelationDTO {
|
||||
return &WarehouseRelationDTO{
|
||||
Id: e.Id,
|
||||
Name: e.Name,
|
||||
Type: e.Type,
|
||||
Location: ToLocationRelationDTO(e.Location),
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user