Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AdvanceRequest ¶
type AdvanceRequest struct { OrderID string `bson:"order_id" json:"order_id"` //Order ID Status state.Code `bson:"status" json:"status"` //主状态 ExStatus state.Code `bson:"ex_status" json:"ex_status"` //自定义状态 Record *struct { Code string `bson:"code" json:"code"` Message string `bson:"message" json:"msg"` Paras map[string]string `bson:"paras" json:"paras,omitempty"` } `bson:"record" json:"record"` //自定义记录 }
type CreateRequest ¶
type CreateRequest struct { Scope ref.Scope `bson:"scope" json:"scope"` //所属业务域 Defined ref.Defined `bson:"defined" json:"defined"` //业务自定义键值 Purchaser ref.Collar `bson:"purchaser" json:"purchaser"` Provider ref.Collar `bson:"provider" json:"provider"` AddrID string `bson:"addr_id" json:"addr_id"` Title string `bson:"title" json:"title"` Amount money.Amount `bson:"amount" json:"amount"` Info *more.Input `bson:"info" json:"info"` Media *media.Input `bson:"media" json:"media"` Ctrl *ctrl.Ctrl `bson:"ctrl" json:"ctrl"` ExStatus state.Code `bson:"ex_status" json:"ex_status"` MatterArray []*Matter `bson:"matter_array" json:"matter_array"` }
type GetRequest ¶
type Matter ¶
type Matter struct { Ref ref.Collar `bson:"ref" json:"ref"` //The Matter Ref Title string `bson:"title" json:"title"` //The Matter Title Price money.Amount `bson:"price" json:"price"` //Origin Price Quantity int64 `bson:"quantity" json:"quantity"` //Order Quantity Amount money.Amount `bson:"amount" json:"amount"` //Order Amount For This Matter Requirement more.Array `bson:"requirement" json:"requirement"` //Other Requirement }
type Order ¶
type Order struct { Scope ref.Scope `bson:"scope" json:"scope"` //所属业务域 Defined ref.Defined `bson:"defined" json:"defined"` //业务自定义键值 ID ID `bson:"id" json:"id"` //订单ID Purchaser ref.Collar `bson:"purchaser" json:"purchaser"` //购买者 Provider ref.Collar `bson:"provider" json:"provider"` //提供者 Title string `bson:"title" json:"title"` //标题 Amount money.Amount `bson:"amount" json:"amount"` //订单金额 MatterArray []*Matter `bson:"matter_array" json:"matter_array"` //订单关联商品事物 Address *address.Address `bson:"address" json:"address"` //配送地址 Info more.More `bson:"info,omitempty" json:"info,omitempty"` //更多信息数据 Media media.More `bson:"media,omitempty" json:"media,omitempty"` //更多媒体数据 Ctrl *ctrl.Ctrl `bson:"ctrl,omitempty" json:"ctrl,omitempty"` //控制参数 Status state.Code `bson:"status" json:"status"` //主状态 ExStatus state.Code `bson:"ex_status" json:"ex_status"` //各流程自定义状态 RecordArray []*Record `bson:"record_array,omitempty" json:"record_array,omitempty"` //订单变化记录 BirthAt time.Time `bson:"birth_at" json:"birth_at"` //创建时间 ModifiedAt time.Time `bson:"modified_at" json:"modified_at"` //最后修改时间 }
type Service ¶
type Service interface { Create(req CreateRequest) (*Order, *errors.Error) Get(req GetRequest) (*Order, *errors.Error) Set(req SetRequest) *errors.Error Advance(req AdvanceRequest) *errors.Error }
type SetRequest ¶
Click to show internal directories.
Click to hide internal directories.