feat(sale): 新增变更单产品获取功能
- 添加 change包和相关结构体 - 实现 All 方法以获取变更单产品信息 - 集成客户端调用,确保功能完整
This commit is contained in:
parent
32247fa0f8
commit
d9ad631a28
32
erp/sale/change.go
Normal file
32
erp/sale/change.go
Normal file
@ -0,0 +1,32 @@
|
||||
package sale
|
||||
|
||||
import (
|
||||
"context"
|
||||
"git.kumo.work/shama/service/client"
|
||||
"time"
|
||||
)
|
||||
|
||||
type change struct {
|
||||
}
|
||||
|
||||
type ArgsChangeAllSearch struct {
|
||||
SaleId int64 // 销售合同id
|
||||
WorkflowId int64 // 审核id
|
||||
}
|
||||
type ChangeProduct struct {
|
||||
Id int64 `json:"id"`
|
||||
SaleProductID int64 `json:"saleProductID"`
|
||||
SaleCount int64 `json:"saleCount"`
|
||||
CreatedAt *time.Time `json:"createdAt"`
|
||||
UpdatedAt *time.Time `json:"updatedAt"`
|
||||
}
|
||||
|
||||
// All @TITLE 获取产品
|
||||
func (c *change) All(ctx context.Context, args ArgsChangeAllSearch) (reply []ChangeProduct, err error) {
|
||||
xClient, err := client.GetClient(c)
|
||||
if err != nil {
|
||||
return
|
||||
}
|
||||
err = xClient.Call(ctx, "All", args, &reply)
|
||||
return
|
||||
}
|
Loading…
x
Reference in New Issue
Block a user