Documentation ¶
Index ¶
- type Cart
- type Goods
- func (g *Goods) AddStock(goodsID, num int) (e error)
- func (g *Goods) Items(page, pagesize int, tag string) (items []dto.GoodsItemRes, e error)
- func (g *Goods) MarkedTag(goodsID int, tag string) (e error)
- func (g *Goods) New(name string, price int) (e error)
- func (g *Goods) Shop(goodsID, goodsNum, userID int) (e error)
- func (g *Goods) ShopEvent(event *event.ShopGoods) (e error)
- type Order
- type User
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Cart ¶
type Cart struct { Worker freedom.Worker //运行时,一个请求绑定一个运行时 CartRepo dependency.CartRepo //依赖倒置购物车资源库 CartFactory *aggregate.CartFactory //依赖注入购物车聚合根工厂 ShopFactory *aggregate.ShopFactory //依赖注入购买聚合根工厂 }
Cart 领域服务.
type Goods ¶
type Goods struct { Worker freedom.Worker //运行时,一个请求绑定一个运行时 GoodsRepo dependency.GoodsRepo //依赖倒置商品资源库 ShopFactory *aggregate.ShopFactory //依赖注入购买聚合根工厂 TX *domainevent.EventTransaction //依赖倒置事务组件 }
Goods 商品领域服务.
type Order ¶
type Order struct { Worker freedom.Worker //运行时,一个请求绑定一个运行时 OrderRepo dependency.OrderRepo //依赖倒置订单资源库 OrderFactory *aggregate.OrderFactory //依赖注入订单工厂 }
Order 订单领域服务.
type User ¶
type User struct { Worker freedom.Worker //运行时,一个请求绑定一个运行时 UserRepo dependency.UserRepo //依赖倒置用户资源库 Transaction *domainevent.EventTransaction //依赖注入事务组件 }
User 用户领域服务.
func (*User) ChangePassword ¶
ChangePassword 修改密码
func (*User) Register ¶
func (user *User) Register(req dto.RegisterUserReq) (result dto.UserInfoRes, e error)
Register .
Directories ¶
Path | Synopsis |
---|---|
Package po generated by 'freedom new-po' Package po generated by 'freedom new-po' Package po generated by 'freedom new-po' Package po generated by 'freedom new-po' Package po generated by 'freedom new-po' Package po generated by 'freedom new-po' Package po generated by 'freedom new-po'
|
Package po generated by 'freedom new-po' Package po generated by 'freedom new-po' Package po generated by 'freedom new-po' Package po generated by 'freedom new-po' Package po generated by 'freedom new-po' Package po generated by 'freedom new-po' Package po generated by 'freedom new-po' |
Click to show internal directories.
Click to hide internal directories.