- handle exceptional msg(e.g. userapplycancel, lock, unlock).

This commit is contained in:
gazebo
2018-08-03 15:55:00 +08:00
parent a5fd029457
commit 4862649d77
7 changed files with 51 additions and 25 deletions

View File

@@ -78,6 +78,8 @@ const (
)
const (
OrderStatusUnlocked = -25
OrderStatusLocked = -20
OrderStatusApplyUrgeOrder = -15
OrderStatusApplyRefund = -10
OrderStatusApplyCancel = -5

View File

@@ -12,6 +12,7 @@ func Order2Status(order *GoodsOrder) (retVal *OrderStatus) {
Status: order.Status,
VendorStatus: order.VendorStatus,
StatusTime: order.StatusTime,
LockStatus: order.LockStatus,
}
return retVal
}

View File

@@ -127,6 +127,7 @@ type OrderStatus struct {
DuplicatedCount int // 收到的重复状态转换(或消息)数,一般是由于重发造成的
Remark string `orm:"size(255)"`
ModelTimeInfo
LockStatus int `orm:"-"` // todo 只是用于传递状态,应该可以优化掉
}
func (v *OrderStatus) TableIndex() [][]string {