a
This commit is contained in:
@@ -483,11 +483,30 @@ func (v *StoreCoupons) TableIndex() [][]string {
|
|||||||
}
|
}
|
||||||
|
|
||||||
type AcctOrder struct {
|
type AcctOrder struct {
|
||||||
ID int64 `orm:"column(id)" json:"id"`
|
ModelIDCUL
|
||||||
VendorOrderID string `orm:"column(vendor_order_id);size(48)" json:"vendorOrderID"`
|
|
||||||
VendorID int `orm:"column(vendor_id)" json:"vendorID"`
|
VendorOrderID string `orm:"column(vendor_order_id)" json:"vendorOrderID"` //订单号
|
||||||
StoreID int `orm:"column(store_id)" json:"storeID"`
|
UserID string `orm:"column(user_id);size(48)" json:"userID"` //用户ID
|
||||||
UserID string `orm:"column(user_id);size(48);index" json:"userID"`
|
StoreID int `orm:"column(store_id)" json:"storeID"` //门店ID
|
||||||
|
OrderType int `json:"orderType"` //订单类型
|
||||||
|
Status int `json:"status"` //订单状态,待支付2,已支付5,支付成功110,支付失败115
|
||||||
|
PayPrice int `json:"payPrice"` //支付金额
|
||||||
|
OriginalData string `orm:"type(text)" json:"-"`
|
||||||
|
Comment string `orm:"size(255)" json:"comment"` //备注
|
||||||
|
}
|
||||||
|
|
||||||
|
func (v *AcctOrder) TableUnique() [][]string {
|
||||||
|
return [][]string{
|
||||||
|
[]string{"VendorOrderID"},
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
func (v *AcctOrder) TableIndex() [][]string {
|
||||||
|
return [][]string{
|
||||||
|
[]string{"CreatedAt"},
|
||||||
|
[]string{"StoreID"},
|
||||||
|
[]string{"UserID"},
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// 判断是否是购买平台自有物流
|
// 判断是否是购买平台自有物流
|
||||||
|
|||||||
@@ -2431,6 +2431,7 @@ func RefreshCouponsStatus(ctx *jxcontext.Context) (err error) {
|
|||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
|
|
||||||
func CreateStoreAcctOrder(ctx *jxcontext.Context, orderType, storeID, price int) (err error) {
|
func CreateStoreAcctOrder(ctx *jxcontext.Context, orderType, storeID, price int) (acctOrder *model.AcctOrder, err error) {
|
||||||
return err
|
|
||||||
|
return acctOrder, err
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -104,6 +104,7 @@ func Init() {
|
|||||||
orm.RegisterModel(&model.StoreAcct{})
|
orm.RegisterModel(&model.StoreAcct{})
|
||||||
orm.RegisterModel(&model.StoreAcctExpend{})
|
orm.RegisterModel(&model.StoreAcctExpend{})
|
||||||
orm.RegisterModel(&model.StoreAcctIncome{})
|
orm.RegisterModel(&model.StoreAcctIncome{})
|
||||||
|
orm.RegisterModel(&model.AcctOrder{})
|
||||||
|
|
||||||
// create table
|
// create table
|
||||||
orm.RunSyncdb("default", false, true)
|
orm.RunSyncdb("default", false, true)
|
||||||
|
|||||||
Reference in New Issue
Block a user