Files
b2b/app/model/dbmodel/ps_product_attribute.go
2026-03-30 01:02:02 +02:00

81 lines
4.6 KiB
Go

// Code generated by gormcol. DO NOT EDIT.
package dbmodel
import (
"git.ma-al.com/goc_marek/gormcol"
"time"
)
const TableNamePsProductAttribute = "ps_product_attribute"
// PsProductAttribute mapped from table <ps_product_attribute>
type PsProductAttribute struct {
IDProductAttribute int32 `gorm:"column:id_product_attribute;primaryKey;autoIncrement:true;index:idx_product_attribute,priority:2;index:id_product_id_product_attribute,priority:1" json:"id_product_attribute"`
IDProduct int32 `gorm:"column:id_product;not null;uniqueIndex:product_default,priority:1;index:idx_id_product,priority:1;index:idx_product_attribute,priority:1;index:idx_ps_product_attribute,priority:1;index:id_product_id_product_attribute,priority:2;index:product_attribute_product,priority:1" json:"id_product"`
Reference *string `gorm:"column:reference;index:reference,priority:1" json:"reference"`
SupplierReference *string `gorm:"column:supplier_reference;index:supplier_reference,priority:1" json:"supplier_reference"`
Location *string `gorm:"column:location" json:"location"`
Ean13 *string `gorm:"column:ean13" json:"ean13"`
Isbn *string `gorm:"column:isbn" json:"isbn"`
Upc *string `gorm:"column:upc" json:"upc"`
WholesalePrice float64 `gorm:"column:wholesale_price;not null;default:0.000000" json:"wholesale_price"`
Price float64 `gorm:"column:price;not null;default:0.000000" json:"price"`
Ecotax float64 `gorm:"column:ecotax;not null;default:0.000000" json:"ecotax"`
Quantity int32 `gorm:"column:quantity;not null" json:"quantity"`
Weight float64 `gorm:"column:weight;not null;default:0.000000" json:"weight"`
UnitPriceImpact float64 `gorm:"column:unit_price_impact;not null;default:0.000000" json:"unit_price_impact"`
DefaultOn *bool `gorm:"column:default_on;uniqueIndex:product_default,priority:2" json:"default_on"`
MinimalQuantity int32 `gorm:"column:minimal_quantity;not null;default:1" json:"minimal_quantity"`
LowStockThreshold *int32 `gorm:"column:low_stock_threshold" json:"low_stock_threshold"`
LowStockAlert bool `gorm:"column:low_stock_alert;not null" json:"low_stock_alert"`
AvailableDate *time.Time `gorm:"column:available_date" json:"available_date"`
}
// TableName PsProductAttribute's table name
func (*PsProductAttribute) TableName() string {
return TableNamePsProductAttribute
}
var PsProductAttributeCols = struct {
IDProductAttribute gormcol.Field
IDProduct gormcol.Field
Reference gormcol.Field
SupplierReference gormcol.Field
Location gormcol.Field
Ean13 gormcol.Field
Isbn gormcol.Field
Upc gormcol.Field
WholesalePrice gormcol.Field
Price gormcol.Field
Ecotax gormcol.Field
Quantity gormcol.Field
Weight gormcol.Field
UnitPriceImpact gormcol.Field
DefaultOn gormcol.Field
MinimalQuantity gormcol.Field
LowStockThreshold gormcol.Field
LowStockAlert gormcol.Field
AvailableDate gormcol.Field
}{
IDProductAttribute: gormcol.Field{}.Set((&PsProductAttribute{}).TableName(), "id_product_attribute"),
IDProduct: gormcol.Field{}.Set((&PsProductAttribute{}).TableName(), "id_product"),
Reference: gormcol.Field{}.Set((&PsProductAttribute{}).TableName(), "reference"),
SupplierReference: gormcol.Field{}.Set((&PsProductAttribute{}).TableName(), "supplier_reference"),
Location: gormcol.Field{}.Set((&PsProductAttribute{}).TableName(), "location"),
Ean13: gormcol.Field{}.Set((&PsProductAttribute{}).TableName(), "ean13"),
Isbn: gormcol.Field{}.Set((&PsProductAttribute{}).TableName(), "isbn"),
Upc: gormcol.Field{}.Set((&PsProductAttribute{}).TableName(), "upc"),
WholesalePrice: gormcol.Field{}.Set((&PsProductAttribute{}).TableName(), "wholesale_price"),
Price: gormcol.Field{}.Set((&PsProductAttribute{}).TableName(), "price"),
Ecotax: gormcol.Field{}.Set((&PsProductAttribute{}).TableName(), "ecotax"),
Quantity: gormcol.Field{}.Set((&PsProductAttribute{}).TableName(), "quantity"),
Weight: gormcol.Field{}.Set((&PsProductAttribute{}).TableName(), "weight"),
UnitPriceImpact: gormcol.Field{}.Set((&PsProductAttribute{}).TableName(), "unit_price_impact"),
DefaultOn: gormcol.Field{}.Set((&PsProductAttribute{}).TableName(), "default_on"),
MinimalQuantity: gormcol.Field{}.Set((&PsProductAttribute{}).TableName(), "minimal_quantity"),
LowStockThreshold: gormcol.Field{}.Set((&PsProductAttribute{}).TableName(), "low_stock_threshold"),
LowStockAlert: gormcol.Field{}.Set((&PsProductAttribute{}).TableName(), "low_stock_alert"),
AvailableDate: gormcol.Field{}.Set((&PsProductAttribute{}).TableName(), "available_date"),
}