fix products listing
This commit is contained in:
122
app/model/dbmodel/ps_cart_rule.go
Normal file
122
app/model/dbmodel/ps_cart_rule.go
Normal file
@@ -0,0 +1,122 @@
|
||||
// Code generated by gormcol. DO NOT EDIT.
|
||||
|
||||
package dbmodel
|
||||
|
||||
import (
|
||||
"git.ma-al.com/goc_marek/gormcol"
|
||||
"time"
|
||||
)
|
||||
|
||||
const TableNamePsCartRule = "ps_cart_rule"
|
||||
|
||||
// PsCartRule mapped from table <ps_cart_rule>
|
||||
type PsCartRule struct {
|
||||
IDCartRule int32 `gorm:"column:id_cart_rule;primaryKey;autoIncrement:true" json:"id_cart_rule"`
|
||||
IDCustomer int32 `gorm:"column:id_customer;not null;index:id_customer,priority:1;index:id_customer_2,priority:1" json:"id_customer"`
|
||||
DateFrom time.Time `gorm:"column:date_from;not null;index:date_from,priority:1" json:"date_from"`
|
||||
DateTo time.Time `gorm:"column:date_to;not null;index:date_to,priority:1;index:group_restriction,priority:3;index:group_restriction_2,priority:4;index:id_customer,priority:3;index:id_customer_2,priority:4" json:"date_to"`
|
||||
Description *string `gorm:"column:description" json:"description"`
|
||||
Quantity int32 `gorm:"column:quantity;not null" json:"quantity"`
|
||||
QuantityPerUser int32 `gorm:"column:quantity_per_user;not null" json:"quantity_per_user"`
|
||||
Priority int32 `gorm:"column:priority;not null;default:1" json:"priority"`
|
||||
PartialUse bool `gorm:"column:partial_use;not null" json:"partial_use"`
|
||||
Code string `gorm:"column:code;not null" json:"code"`
|
||||
MinimumAmount float64 `gorm:"column:minimum_amount;not null;default:0.00" json:"minimum_amount"`
|
||||
MinimumAmountTax bool `gorm:"column:minimum_amount_tax;not null" json:"minimum_amount_tax"`
|
||||
MinimumAmountCurrency int32 `gorm:"column:minimum_amount_currency;not null" json:"minimum_amount_currency"`
|
||||
MinimumAmountShipping bool `gorm:"column:minimum_amount_shipping;not null" json:"minimum_amount_shipping"`
|
||||
CountryRestriction bool `gorm:"column:country_restriction;not null" json:"country_restriction"`
|
||||
CarrierRestriction bool `gorm:"column:carrier_restriction;not null" json:"carrier_restriction"`
|
||||
GroupRestriction bool `gorm:"column:group_restriction;not null;index:group_restriction,priority:1;index:group_restriction_2,priority:1" json:"group_restriction"`
|
||||
CartRuleRestriction bool `gorm:"column:cart_rule_restriction;not null" json:"cart_rule_restriction"`
|
||||
ProductRestriction bool `gorm:"column:product_restriction;not null" json:"product_restriction"`
|
||||
ShopRestriction bool `gorm:"column:shop_restriction;not null" json:"shop_restriction"`
|
||||
FreeShipping bool `gorm:"column:free_shipping;not null" json:"free_shipping"`
|
||||
ReductionPercent float64 `gorm:"column:reduction_percent;not null;default:0.00" json:"reduction_percent"`
|
||||
ReductionAmount float64 `gorm:"column:reduction_amount;not null;default:0.00" json:"reduction_amount"`
|
||||
ReductionTax bool `gorm:"column:reduction_tax;not null" json:"reduction_tax"`
|
||||
ReductionCurrency int32 `gorm:"column:reduction_currency;not null" json:"reduction_currency"`
|
||||
ReductionProduct int32 `gorm:"column:reduction_product;not null" json:"reduction_product"`
|
||||
ReductionExcludeSpecial bool `gorm:"column:reduction_exclude_special;not null" json:"reduction_exclude_special"`
|
||||
GiftProduct int32 `gorm:"column:gift_product;not null" json:"gift_product"`
|
||||
GiftProductAttribute int32 `gorm:"column:gift_product_attribute;not null" json:"gift_product_attribute"`
|
||||
Highlight bool `gorm:"column:highlight;not null;index:group_restriction_2,priority:3;index:id_customer_2,priority:3" json:"highlight"`
|
||||
Active bool `gorm:"column:active;not null;index:group_restriction,priority:2;index:group_restriction_2,priority:2;index:id_customer,priority:2;index:id_customer_2,priority:2" json:"active"`
|
||||
DateAdd time.Time `gorm:"column:date_add;not null" json:"date_add"`
|
||||
DateUpd time.Time `gorm:"column:date_upd;not null" json:"date_upd"`
|
||||
}
|
||||
|
||||
// TableName PsCartRule's table name
|
||||
func (*PsCartRule) TableName() string {
|
||||
return TableNamePsCartRule
|
||||
}
|
||||
|
||||
var PsCartRuleCols = struct {
|
||||
IDCartRule gormcol.Field
|
||||
IDCustomer gormcol.Field
|
||||
DateFrom gormcol.Field
|
||||
DateTo gormcol.Field
|
||||
Description gormcol.Field
|
||||
Quantity gormcol.Field
|
||||
QuantityPerUser gormcol.Field
|
||||
Priority gormcol.Field
|
||||
PartialUse gormcol.Field
|
||||
Code gormcol.Field
|
||||
MinimumAmount gormcol.Field
|
||||
MinimumAmountTax gormcol.Field
|
||||
MinimumAmountCurrency gormcol.Field
|
||||
MinimumAmountShipping gormcol.Field
|
||||
CountryRestriction gormcol.Field
|
||||
CarrierRestriction gormcol.Field
|
||||
GroupRestriction gormcol.Field
|
||||
CartRuleRestriction gormcol.Field
|
||||
ProductRestriction gormcol.Field
|
||||
ShopRestriction gormcol.Field
|
||||
FreeShipping gormcol.Field
|
||||
ReductionPercent gormcol.Field
|
||||
ReductionAmount gormcol.Field
|
||||
ReductionTax gormcol.Field
|
||||
ReductionCurrency gormcol.Field
|
||||
ReductionProduct gormcol.Field
|
||||
ReductionExcludeSpecial gormcol.Field
|
||||
GiftProduct gormcol.Field
|
||||
GiftProductAttribute gormcol.Field
|
||||
Highlight gormcol.Field
|
||||
Active gormcol.Field
|
||||
DateAdd gormcol.Field
|
||||
DateUpd gormcol.Field
|
||||
}{
|
||||
IDCartRule: gormcol.Field{}.Set((&PsCartRule{}).TableName(), "id_cart_rule"),
|
||||
IDCustomer: gormcol.Field{}.Set((&PsCartRule{}).TableName(), "id_customer"),
|
||||
DateFrom: gormcol.Field{}.Set((&PsCartRule{}).TableName(), "date_from"),
|
||||
DateTo: gormcol.Field{}.Set((&PsCartRule{}).TableName(), "date_to"),
|
||||
Description: gormcol.Field{}.Set((&PsCartRule{}).TableName(), "description"),
|
||||
Quantity: gormcol.Field{}.Set((&PsCartRule{}).TableName(), "quantity"),
|
||||
QuantityPerUser: gormcol.Field{}.Set((&PsCartRule{}).TableName(), "quantity_per_user"),
|
||||
Priority: gormcol.Field{}.Set((&PsCartRule{}).TableName(), "priority"),
|
||||
PartialUse: gormcol.Field{}.Set((&PsCartRule{}).TableName(), "partial_use"),
|
||||
Code: gormcol.Field{}.Set((&PsCartRule{}).TableName(), "code"),
|
||||
MinimumAmount: gormcol.Field{}.Set((&PsCartRule{}).TableName(), "minimum_amount"),
|
||||
MinimumAmountTax: gormcol.Field{}.Set((&PsCartRule{}).TableName(), "minimum_amount_tax"),
|
||||
MinimumAmountCurrency: gormcol.Field{}.Set((&PsCartRule{}).TableName(), "minimum_amount_currency"),
|
||||
MinimumAmountShipping: gormcol.Field{}.Set((&PsCartRule{}).TableName(), "minimum_amount_shipping"),
|
||||
CountryRestriction: gormcol.Field{}.Set((&PsCartRule{}).TableName(), "country_restriction"),
|
||||
CarrierRestriction: gormcol.Field{}.Set((&PsCartRule{}).TableName(), "carrier_restriction"),
|
||||
GroupRestriction: gormcol.Field{}.Set((&PsCartRule{}).TableName(), "group_restriction"),
|
||||
CartRuleRestriction: gormcol.Field{}.Set((&PsCartRule{}).TableName(), "cart_rule_restriction"),
|
||||
ProductRestriction: gormcol.Field{}.Set((&PsCartRule{}).TableName(), "product_restriction"),
|
||||
ShopRestriction: gormcol.Field{}.Set((&PsCartRule{}).TableName(), "shop_restriction"),
|
||||
FreeShipping: gormcol.Field{}.Set((&PsCartRule{}).TableName(), "free_shipping"),
|
||||
ReductionPercent: gormcol.Field{}.Set((&PsCartRule{}).TableName(), "reduction_percent"),
|
||||
ReductionAmount: gormcol.Field{}.Set((&PsCartRule{}).TableName(), "reduction_amount"),
|
||||
ReductionTax: gormcol.Field{}.Set((&PsCartRule{}).TableName(), "reduction_tax"),
|
||||
ReductionCurrency: gormcol.Field{}.Set((&PsCartRule{}).TableName(), "reduction_currency"),
|
||||
ReductionProduct: gormcol.Field{}.Set((&PsCartRule{}).TableName(), "reduction_product"),
|
||||
ReductionExcludeSpecial: gormcol.Field{}.Set((&PsCartRule{}).TableName(), "reduction_exclude_special"),
|
||||
GiftProduct: gormcol.Field{}.Set((&PsCartRule{}).TableName(), "gift_product"),
|
||||
GiftProductAttribute: gormcol.Field{}.Set((&PsCartRule{}).TableName(), "gift_product_attribute"),
|
||||
Highlight: gormcol.Field{}.Set((&PsCartRule{}).TableName(), "highlight"),
|
||||
Active: gormcol.Field{}.Set((&PsCartRule{}).TableName(), "active"),
|
||||
DateAdd: gormcol.Field{}.Set((&PsCartRule{}).TableName(), "date_add"),
|
||||
DateUpd: gormcol.Field{}.Set((&PsCartRule{}).TableName(), "date_upd"),
|
||||
}
|
||||
Reference in New Issue
Block a user