Compare commits

...

66 Commits

Author SHA1 Message Date
lzh
bfc409ed70 Merge branch 'dev-lzh' 2025-06-26 17:18:58 +08:00
lzh
0a4218757e ` 2025-06-26 09:19:23 +08:00
lzh
4f9b72928b "修正发布平台ID字段命名大小写不一致问题" 2025-06-25 15:21:53 +08:00
lzh
7468c2f442 "修正用户余额查询SQL中的字段别名拼写错误" 2025-06-25 13:48:54 +08:00
lzh
e4a9c3ac4d 优化套餐余额查询SQL,调整JOIN逻辑并简化查询条件 2025-06-25 11:56:09 +08:00
lzh
92c8e4d574 优化套餐余额更新方式,直接使用旧数据模型并改用Save方法 2025-06-25 10:13:57 +08:00
lzh
1b5b6037fd 增加待确认作品状态过滤条件 2025-06-25 09:33:29 +08:00
lzh
1885d2b8dc "优化用户余额查询的JOIN方式并添加分组" 2025-06-24 17:08:36 +08:00
lzh
f55af5f719 过滤待确认条件 2025-06-24 16:29:11 +08:00
lzh
043274e61f 添加余量信息已购买字段 2025-06-24 15:08:37 +08:00
lzh
0167e40f9e 过滤重复的作品id 2025-06-24 15:04:09 +08:00
lzh
46a6c5723f 过滤被删除的用户 2025-06-24 14:03:35 +08:00
lzh
bfa9fc4026 订单记录取最新 2025-06-24 13:38:16 +08:00
lzh
fb3b33a817 显示过期的套餐信息 2025-06-24 12:00:09 +08:00
lzh
70c4eacce4 1 2025-06-24 11:27:50 +08:00
lzh
f82a96907c 1 2025-06-23 14:24:12 +08:00
lzh
24c701d9a1 修改使用记录的用户名搜索 2025-06-23 14:11:07 +08:00
lzh
37bae4398d 修改使用记录排序 2025-06-23 13:55:29 +08:00
lzh
d3b82f4352 余量列表支持电话号码搜索 2025-06-23 10:37:04 +08:00
lzh
75a75e9480 时区错误修改 2025-06-20 16:57:01 +08:00
lzh
8528412c33 补充余量信息user_id 2025-06-20 16:36:11 +08:00
lzh
4e2faf05cb 添加未购买过滤 2025-06-20 16:18:20 +08:00
lzh
c6a65f4589 1 2025-06-20 15:54:06 +08:00
lzh
9e36dfde6b 扩展记录时间服务 2025-06-20 15:28:50 +08:00
lzh
9f5798c2be 扩展记录时间服务 2025-06-20 15:26:50 +08:00
lzh
e26829e19b 扩展记录用户名搜索 2025-06-20 15:24:24 +08:00
lzh
089d8af480 支持套餐名搜索 2025-06-20 15:10:39 +08:00
lzh
0fae4587d8 使用真实姓名搜索 2025-06-20 14:57:54 +08:00
lzh
2d9d620062 支持json搜索 2025-06-20 14:42:21 +08:00
lzh
f933e4887f 添加扩展时间字段 2025-06-20 14:14:44 +08:00
lzh
94e5c77f90 过期时间精确到秒 2025-06-20 14:06:24 +08:00
lzh
99c4b85a62 订单号字段错误修改 2025-06-20 10:41:20 +08:00
lzh
16f5e1f7ec 订单号字段错误修改 2025-06-20 10:37:38 +08:00
lzh
0429854814 订单号字段错误修改 2025-06-20 10:33:32 +08:00
lzh
9b6549f141 添加关联订单号字段 2025-06-20 10:27:00 +08:00
lzh
d85bfa4fa0 修改余量查询错误 2025-06-20 10:05:55 +08:00
lzh
f612f8ad23 补充缺失字段 2025-06-20 09:42:14 +08:00
lzh
fbea508cfe 使用真实姓名 2025-06-19 16:59:27 +08:00
lzh
02d0de5dad 使用真实姓名 2025-06-19 16:36:28 +08:00
lzh
0dce0b80a6 余量套餐状态添加 2025-06-19 16:00:51 +08:00
lzh
b151326427 余量信息电话号码添加 2025-06-19 15:53:56 +08:00
lzh
3d226f9c8d 更新proto文件 2025-06-19 15:09:16 +08:00
lzh
a6fddccda9 添加扩展类型字段 2025-06-19 14:52:54 +08:00
lzh
df0b742168 过滤空余量信息 2025-06-18 16:47:28 +08:00
lzh
a71942b0d4 过滤软删除的记录 2025-06-18 16:37:01 +08:00
lzh
370f0a08c1 过滤软删除的记录 2025-06-18 16:35:55 +08:00
lzh
2a137ad3fb 修改查询条件 2025-06-17 16:09:38 +08:00
lzh
3fae4f4ab7 modified: internal/dao/bundleExtend.go 2025-06-17 14:39:39 +08:00
lzh
32de65196b 添加确认状态 2025-06-17 14:14:09 +08:00
lzh
412350cf8a 修改错误信息 2025-06-16 14:29:18 +08:00
lzh
8a14905343 添加金额类型 2025-06-16 13:40:50 +08:00
lzh
07b6296867 添加金额类型 2025-06-16 11:05:18 +08:00
lzh
8c36da313e 时间格式修改 2025-06-16 10:58:45 +08:00
lzh
1d9b8bda3a 删除调试 2025-06-16 10:55:15 +08:00
lzh
2fe368cace 时间格式修改 2025-06-16 10:52:30 +08:00
lzh
7367bf1639 默认过期时间使用当前时间 2025-06-16 09:55:29 +08:00
lzh
6c7a1f9d44 提交时间类型修改 2025-06-16 09:03:39 +08:00
lzh
21504e78f2 补充金额字段 2025-06-15 14:35:39 +08:00
lzh
e6eb835a01 补充支付时间字段 2025-06-15 14:24:02 +08:00
lzh
74277a50ef 待确认记录查询 2025-06-15 13:50:20 +08:00
lzh
3e6382481c 1 2025-06-15 13:12:55 +08:00
lzh
459ae0d6fb 1 2025-06-15 12:26:30 +08:00
lzh
edbe9f2c0a 添加用户余量信息查询接口 2025-06-15 11:43:50 +08:00
lzh
99f04c1de2 添加用户余量信息查询接口 2025-06-15 11:34:51 +08:00
lzh
39a172f3dd 添加待确认记录查询 2025-06-14 16:31:01 +08:00
lzh
15e313f053 1 2025-06-14 11:41:00 +08:00
10 changed files with 3872 additions and 2363 deletions

View File

@ -4,9 +4,6 @@ import (
"context"
"micro-bundle/internal/logic"
"micro-bundle/pb/bundle"
"google.golang.org/grpc/codes"
"google.golang.org/grpc/status"
)
func (b *BundleProvider) BundleExtend(_ context.Context, req *bundle.BundleExtendRequest) (*bundle.BundleExtendResponse, error) {
@ -21,6 +18,10 @@ func (b *BundleProvider) GetBundleBalanceList(_ context.Context, req *bundle.Get
return logic.GetBundleBalanceList(req)
}
func (b *BundleProvider) GetBundleBalanceByUserId(_ context.Context, req *bundle.GetBundleBalanceByUserIdReq) (*bundle.GetBundleBalanceByUserIdResp, error) {
return logic.GetBundleBalanceByUserId(req)
}
func (b *BundleProvider) CreateBundleBalance(_ context.Context, req *bundle.CreateBundleBalanceReq) (*bundle.CreateBundleBalanceResp, error) {
return logic.CreateBundleBalance(req)
}
@ -42,5 +43,9 @@ func (b *BundleProvider) GetVedioWorkDetail(_ context.Context, req *bundle.GetVe
}
func (b *BundleProvider) ToBeComfirmedWorks(_ context.Context, req *bundle.ToBeComfirmedWorksReq) (*bundle.ToBeComfirmedWorksResp, error) {
return nil, status.Errorf(codes.Unimplemented, "method ToBeComfirmedWorks not implemented")
return logic.ToBeComfirmedWorks(req)
}
func (b *BundleProvider) ConfirmWork(_ context.Context, req *bundle.ConfirmWorkReq) (*bundle.ConfirmWorkResp, error) {
return logic.ConfirmWork(req)
}

View File

@ -2,6 +2,7 @@ package dao
import (
"errors"
"fmt"
"micro-bundle/internal/model"
"micro-bundle/pb/bundle"
"micro-bundle/pkg/app"
@ -9,6 +10,7 @@ import (
"strconv"
"time"
"dubbo.apache.org/dubbo-go/v3/common/logger"
"github.com/duke-git/lancet/v2/datetime"
"gorm.io/gorm"
@ -21,14 +23,19 @@ func AddBundleExtendRecord(data model.BundleExtensionRecords) error {
}
if data.AvailableDurationAdditional != 0 && data.TimeUnit != 0 {
record := model.BundleOrderRecords{}
if err := tx.Model(&model.BundleOrderRecords{}).Where(&model.BundleOrderRecords{CustomerID: strconv.Itoa(data.UserId)}).First(&record).Error; err != nil {
if err := tx.Model(&model.BundleOrderRecords{}).Where(&model.BundleOrderRecords{CustomerID: strconv.Itoa(data.UserId)}).Order("created_at desc").First(&record).Error; err != nil {
return err
}
var expireTime time.Time
if record.ExpirationTime != "" {
loc, _ := time.LoadLocation("Asia/Shanghai")
et, _ := time.ParseInLocation(time.DateTime, record.ExpirationTime, loc)
expireTime = et
} else {
expireTime = time.Now()
logger.Infof("过期时间为空,使用默认过期时间" + expireTime.Format(time.DateTime))
}
expireTime, err := time.Parse(time.DateOnly, record.ExpirationTime)
if err != nil {
return err
}
switch data.TimeUnit {
case 1:
expireTime = datetime.AddDay(expireTime, int64(data.AvailableDurationAdditional))
@ -39,9 +46,8 @@ func AddBundleExtendRecord(data model.BundleExtensionRecords) error {
default:
return errors.New("时间单位有误")
}
record.ExpirationTime = expireTime.Format(time.DateOnly)
err = tx.Model(&model.BundleOrderRecords{}).Save(&record).Error
return err
record.ExpirationTime = expireTime.Format(time.DateTime)
return tx.Model(&model.BundleOrderRecords{}).Where(&model.BundleOrderRecords{UUID: record.UUID}).Updates(&record).Error
}
return nil
})
@ -51,33 +57,40 @@ func GetBundleExtendRecordList(req *bundle.BundleExtendRecordsListRequest) (data
session := app.ModuleClients.BundleDB.Table("fiee_bundle.bundle_extension_records AS ber").
Select(`
ber.*,
u.nickname as user_name,
rn.name as user_name,
u.tel_num as user_phone_number
`).Joins("LEFT JOIN `micro-account`.`user` u on u.id = user_id")
`).Joins("LEFT JOIN `micro-account`.`user` u on u.id = user_id").
Joins("LEFT JOIN `micro-account`.`real_name` rn on u.real_name_id = rn.id").
Order("created_at desc")
if req.User != "" {
if utils.IsPhoneNumber(req.User) {
session = session.Where("u.tel_num = ?", req.User)
} else {
session = session.Where("u.nickname like ?", req.User)
session = session.Where("rn.name like ?", "%"+req.User+"%")
}
}
if req.Operator != "" {
if utils.IsPhoneNumber(req.Operator) {
session = session.Where("ber.operator_phone_number = ?", req.Operator)
} else {
session = session.Where("ber.operator_name like ?", req.Operator)
session = session.Where("ber.operator_name like ?", "%"+req.Operator+"%")
}
}
if req.Type != 0 {
session = session.Where("ber.`type` = ?", req.Type)
}
if req.StartTime != 0 {
session = session.Where("ber.created_at >= ?", time.UnixMilli(int64(req.StartTime)))
}
if req.EndTime != 0 {
session = session.Where("ber.created_at <= ?", time.UnixMilli(int64(req.EndTime)))
}
if req.AssociatedOrderNumber != "" {
session = session.Where("ber.associated_order_number like ?", "%"+req.AssociatedOrderNumber+"%")
}
if err = session.Count(&total).Error; err != nil {
return
}
if req.Page != 0 && req.PageSize != 0 {
session = session.Limit(int(req.PageSize)).Offset(int(req.Page-1) * int(req.PageSize))
}
@ -86,30 +99,47 @@ func GetBundleExtendRecordList(req *bundle.BundleExtendRecordsListRequest) (data
}
func GetBundleBalanceList(req *bundle.GetBundleBalanceListReq) (data []model.BundleBalancePo, total int64, err error) {
session := app.ModuleClients.BundleDB.Table("fiee_bundle.bundle_balance AS bb").
Select(`
bb .*,
bor.expiration_time as expired_time,
bor.bundle_name,
bor.status,
bor.uuid as order_uuid,
u.nickname as user_name,
u.tel_num as user_phone_number
`).
Joins("LEFT JOIN bundle_order_records bor on bor.customer_id = bb .user_id").
Joins("LEFT JOIN `micro-account`.`user` u on u.id = bb.user_id")
subQuery := app.ModuleClients.BundleDB.Table("bundle_order_records as bor1").
Select("bor1.*").
Joins(`INNER JOIN (
SELECT customer_id, MAX(created_at) AS max_created_time
FROM bundle_order_records
GROUP BY customer_id
) bor2 ON bor1.customer_id = bor2.customer_id AND bor1.created_at = bor2.max_created_time`)
session := app.ModuleClients.BundleDB.Table("`micro-account`.`user` AS u").
Select(`bb.*, bor.expiration_time as expired_time, bor.bundle_name, bor.status,
bor.uuid as order_uuid, rn.name as user_name,
u.tel_num as user_phone_number, u.id as user_id`).
Joins("LEFT JOIN `micro-account`.real_name rn ON u.real_name_id = rn.id").
Joins("LEFT JOIN (?) as bor ON bor.customer_id = u.id", subQuery).
Joins("LEFT JOIN fiee_bundle.bundle_balance bb ON u.id = bb.user_id AND bb.order_uuid = bor.uuid").
Where("rn.name IS NOT NULL").
Where("u.deleted_at = 0")
if req.UserName != "" {
session = session.Where("u.nickname like ?", "%"+req.UserName+"%")
if utils.IsPhoneNumber(req.UserName) {
session = session.Where("u.tel_num = ?", req.UserName)
} else {
session = session.Where("rn.name like ?", "%"+req.UserName+"%")
}
}
if req.Status != 0 {
session = session.Where("bor.status = ?", req.Status)
}
if req.BundleName != "" {
session = session.Where("bor.bundle_name like ?", "%"+req.BundleName+"%")
}
if req.ExpiredTimeEnd != 0 {
session = session.Where("bor.expiration_time <= ?", time.UnixMilli(req.ExpiredTimeEnd))
}
if req.ExpiredTimeStart != 0 {
session = session.Where("bor.expiration_time >= ?", time.UnixMilli(req.ExpiredTimeStart))
}
if req.Bought == 2 {
session = session.Where("bor.uuid IS NOT NULL")
}
if req.Bought == 1 {
session = session.Where("bor.uuid IS NULL")
}
err = session.Count(&total).Error
if err != nil {
return
@ -121,6 +151,36 @@ func GetBundleBalanceList(req *bundle.GetBundleBalanceListReq) (data []model.Bun
return
}
func GetBundleBalanceByUserId(req *bundle.GetBundleBalanceByUserIdReq) (data model.UserBundleBalancePo, err error) {
err = app.ModuleClients.BundleDB.Table("fiee_bundle.bundle_balance AS bb").
Select("bb.*,bor.uuid AS order_uuid, bor.bundle_name AS bundle_name, bor.status AS bundle_status, bor.pay_time AS pay_time, bor.expiration_time AS expired_time,bor.amount AS payment_amount,bor.amount_type AS payment_type").
Joins("LEFT JOIN bundle_order_records bor ON bor.uuid = bb.order_uuid").
Joins("LEFT JOIN `micro-account`.`user` u ON u.id = bb.user_id").
Where("bor.deleted_at IS NULL").
Where("bb.user_id = ?", req.UserId).
// Where("bor.expiration_time > ?", time.Now()).
Order("bb.created_at desc").
First(&data).Error
if err != nil {
return
}
var additionalInfo model.UserBundleBalancePo
err = app.ModuleClients.BundleDB.Model(&model.BundleExtensionRecords{}).
Select("user_id, SUM(account_additional) as account_additional, SUM(images_additional) as image_additional, SUM(video_additional) as video_additional, SUM(data_additional) as data_additional").
Where("type = 1"). // 手动扩展
Where("user_id = ?", req.UserId).
Where("created_at > ?", data.PayTime). // 判断扩展是否生效
First(&additionalInfo).Error
if err != nil {
return
}
data.AccountAdditional = additionalInfo.AccountAdditional
data.VideoAdditional = additionalInfo.VideoAdditional
data.ImageAdditional = additionalInfo.ImageAdditional
data.DataAnalysisAdditional = additionalInfo.DataAnalysisAdditional
return
}
func AddBundleBalanceByUserId(data model.BundleBalance) error {
return app.ModuleClients.BundleDB.Transaction(func(tx *gorm.DB) error {
oldData := model.BundleBalance{}
@ -128,9 +188,7 @@ func AddBundleBalanceByUserId(data model.BundleBalance) error {
return errors.New("用户还没有套餐信息")
}
newData := model.BundleBalance{
Model: gorm.Model{
ID: data.Model.ID,
},
Model: oldData.Model,
UserId: oldData.UserId,
OrderUUID: oldData.OrderUUID,
AccountNumber: oldData.AccountNumber + data.AccountNumber,
@ -150,7 +208,7 @@ func AddBundleBalanceByUserId(data model.BundleBalance) error {
newData.DataAnalysisConsumptionNumber > newData.DataAnalysisNumber {
return errors.New("套餐余量不足")
}
return tx.Model(&model.BundleBalance{}).Where("id = ?", oldData.ID).Updates(&newData).Error
return tx.Model(&model.BundleBalance{}).Where("id = ?", oldData.ID).Save(&newData).Error
})
}
@ -164,10 +222,10 @@ func GetUsedRecord(req *bundle.GetUsedRecordListReq) (data []model.CostLog, tota
session = session.Where("title = ?", req.Title)
}
if req.Platform != 0 {
session = session.Where("JSON_CONTAINS(platform_ids,?)", req.Platform)
session = session.Where(fmt.Sprintf("JSON_CONTAINS(platform_ids,'%d')", req.Platform))
}
if req.Account != 0 {
session = session.Where("JSON_CONTAINS(media_names,?)", req.Account)
if req.Account != "" {
session = session.Where(fmt.Sprintf(`JSON_CONTAINS(media_names,'"%s"')`, req.Account))
}
if req.SubmitTimeEnd != 0 {
session = session.Where("submit_time <= ?", time.UnixMilli(req.SubmitTimeEnd))
@ -198,7 +256,7 @@ func GetUsedRecord(req *bundle.GetUsedRecordListReq) (data []model.CostLog, tota
if req.Page != 0 && req.PageSize != 0 {
session = session.Offset(int(req.Page-1) * int(req.PageSize)).Limit(int(req.PageSize))
}
err = session.Find(&data).Error
err = session.Order("updated_at desc").Find(&data).Error
return
}
@ -212,8 +270,34 @@ func GetVedioWorkDetail(req *bundle.GetVedioWorkDetailReq) (data model.CastWorkV
return
}
// func ToBeComfirmedWorks(req *bundle.ToBeComfirmedWorksReq) (data []model.CastWork, err error) {
// // app.ModuleClients.BundleDB.Where(&model.CastWork{
// // ArtistUuid: req.ArtistUuid,
// // })
// }
func ToBeComfirmedWorks(req *bundle.ToBeComfirmedWorksReq) (data []model.CastWorkLog, total int64, unconfirmed int64, err error) {
subQuery := app.ModuleClients.BundleDB.
Table("cast_work_log").
Select("work_uuid, MAX(update_time) AS max_update_time").
Group("work_uuid").Where("work_status in ?", []int{4, 5, 6, 7})
err = app.ModuleClients.BundleDB.
Table("cast_work_log AS cwl").
Joins("INNER JOIN (?) AS t ON cwl.work_uuid = t.work_uuid AND cwl.update_time = t.max_update_time", subQuery).
Where("artist_uuid = ?", req.ArtistUuid).Where("confirmed_at = ?", 0).Count(&unconfirmed).Error
if err != nil {
return
}
session := app.ModuleClients.BundleDB.
Table("cast_work_log AS cwl").
Joins("INNER JOIN (?) AS t ON cwl.work_uuid = t.work_uuid AND cwl.update_time = t.max_update_time", subQuery).
Where("artist_uuid = ?", req.ArtistUuid)
err = session.Count(&total).Error
if err != nil {
return
}
if req.Page != 0 && req.PageSize != 0 {
session.Limit(int(req.PageSize)).Offset(int(req.Page-1) * int(req.PageSize))
}
err = session.Order("created_at desc").Find(&data).Error
return
}
func ConfirmWork(req *bundle.ConfirmWorkReq) error {
return app.ModuleClients.BundleDB.Model(&model.CastWorkLog{}).Where(&model.CastWorkLog{WorkUuid: req.WorkUuid}).Update("confirmed_at", time.Now().Unix()).Error
}

View File

@ -582,8 +582,8 @@ func GetReconciliationList(req *bundle.GetReconciliationListReq) (*bundle.GetRec
if req.PayChannel != 0 {
modelObj = modelObj.Where("pay_channel = ?", req.PayChannel)
}
if req.OrderNo != "" {
modelObj = modelObj.Where("order_no like ?", "%"+req.OrderNo+"%")
if req.BundleOrderOn != "" {
modelObj = modelObj.Where("order_no like ?", "%"+req.BundleOrderOn+"%")
}
if req.CreatedStart != "" && req.CreatedEnd != "" {
modelObj = modelObj.Where("created_at between ? and ?", req.CreatedStart, req.CreatedEnd)

View File

@ -1,11 +1,13 @@
package logic
import (
"errors"
"micro-bundle/internal/dao"
"micro-bundle/internal/model"
"micro-bundle/pb/bundle"
"time"
"dubbo.apache.org/dubbo-go/v3/common/logger"
"github.com/jinzhu/copier"
"github.com/samber/lo"
)
@ -23,21 +25,28 @@ func BundleExtend(req *bundle.BundleExtendRequest) (*bundle.BundleExtendResponse
AccountNumber: int(req.AccountAdditional),
ExpansionPacksNumber: 1,
}); err != nil {
return nil, err
return nil, errors.New("用户没有余量信息")
}
return nil, dao.AddBundleExtendRecord(data)
err := dao.AddBundleExtendRecord(data)
if err != nil {
logger.Error(err)
return nil, errors.New("创建扩展记录失败")
}
return nil, nil
}
func BundleExtendRecordsList(req *bundle.BundleExtendRecordsListRequest) (*bundle.BundleExtendRecordsListResponse, error) {
data, total, err := dao.GetBundleExtendRecordList(req)
if err != nil {
return nil, err
logger.Error(err)
return nil, errors.New("查询失败")
}
resp := &bundle.BundleExtendRecordsListResponse{}
resp.Total = total
resp.Data = lo.Map(data, func(m model.BundleExtendRecordItemPo, _ int) *bundle.BundleExtendRecordItem {
result := &bundle.BundleExtendRecordItem{}
copier.Copy(result, &m)
result.CreatedAt = uint64(m.CreatedAt.UnixMilli())
return result
})
return resp, nil
@ -46,24 +55,48 @@ func BundleExtendRecordsList(req *bundle.BundleExtendRecordsListRequest) (*bundl
func GetBundleBalanceList(req *bundle.GetBundleBalanceListReq) (*bundle.GetBundleBalanceListResp, error) {
data, total, err := dao.GetBundleBalanceList(req)
if err != nil {
return nil, err
logger.Error(err)
return nil, errors.New("查询失败")
}
resp := &bundle.GetBundleBalanceListResp{}
resp.Total = total
resp.Data = lo.Map(data, func(m model.BundleBalancePo, _ int) *bundle.BundleBalanceItem {
result := &bundle.BundleBalanceItem{}
copier.Copy(result, &m)
t, _ := time.Parse("2006-01-02", m.ExpirationTime)
loc, _ := time.LoadLocation("Asia/Shanghai")
t, _ := time.ParseInLocation(time.DateTime, m.ExpirationTime, loc)
if m.OrderUUID != "" {
result.Bought = 2
} else {
result.Bought = 1
}
result.ExpiredTime = t.UnixMilli()
return result
})
return resp, nil
}
func GetBundleBalanceByUserId(req *bundle.GetBundleBalanceByUserIdReq) (*bundle.GetBundleBalanceByUserIdResp, error) {
data, err := dao.GetBundleBalanceByUserId(req)
if err != nil {
logger.Error(err)
return nil, errors.New("查询失败")
}
result := &bundle.GetBundleBalanceByUserIdResp{}
copier.Copy(result, &data)
loc, _ := time.LoadLocation("Asia/Shanghai")
t, _ := time.ParseInLocation(time.DateTime, data.ExpiredTime, loc)
result.ExpiredTime = t.UnixMilli()
t, _ = time.ParseInLocation(time.DateTime, data.PayTime, loc)
result.PayTime = t.UnixMilli()
return result, nil
}
func AddBundleBalance(req *bundle.AddBundleBalanceReq) (*bundle.AddBundleBalanceResp, error) {
var data model.BundleBalance
if err := copier.Copy(&data, req); err != nil {
return nil, err
logger.Error(err)
return nil, errors.New("操作失败")
}
return nil, dao.AddBundleBalanceByUserId(data)
}
@ -71,15 +104,22 @@ func AddBundleBalance(req *bundle.AddBundleBalanceReq) (*bundle.AddBundleBalance
func CreateBundleBalance(req *bundle.CreateBundleBalanceReq) (*bundle.CreateBundleBalanceResp, error) {
var data model.BundleBalance
if err := copier.Copy(&data, req); err != nil {
return nil, err
logger.Error(err)
return nil, errors.New("操作失败")
}
return nil, dao.CreateBundleBalance(data)
err := dao.CreateBundleBalance(data)
if err != nil {
logger.Error(err)
return nil, errors.New("创建余量信息失败")
}
return nil, nil
}
func GetUsedRecord(req *bundle.GetUsedRecordListReq) (*bundle.GetUsedRecordListResp, error) {
data, total, err := dao.GetUsedRecord(req)
if err != nil {
return nil, err
logger.Error(err)
return nil, errors.New("查询失败")
}
resp := &bundle.GetUsedRecordListResp{}
resp.Total = total
@ -94,7 +134,8 @@ func GetUsedRecord(req *bundle.GetUsedRecordListReq) (*bundle.GetUsedRecordListR
func GetImageWorkDetail(req *bundle.GetImageWorkDetailReq) (*bundle.GetImageWorkDetailResp, error) {
data, err := dao.GetImageWorkDetail(req)
if err != nil {
return nil, err
logger.Error(err)
return nil, errors.New("查询失败")
}
result := &bundle.GetImageWorkDetailResp{}
err = copier.Copy(result, &data)
@ -104,7 +145,8 @@ func GetImageWorkDetail(req *bundle.GetImageWorkDetailReq) (*bundle.GetImageWork
func GetVedioWorkDetail(req *bundle.GetVedioWorkDetailReq) (*bundle.GetVedioeWorkDetailResp, error) {
data, err := dao.GetVedioWorkDetail(req)
if err != nil {
return nil, err
logger.Error(err)
return nil, errors.New("查询失败")
}
result := &bundle.GetVedioeWorkDetailResp{}
err = copier.Copy(result, &data)
@ -112,6 +154,23 @@ func GetVedioWorkDetail(req *bundle.GetVedioWorkDetailReq) (*bundle.GetVedioeWor
}
func ToBeComfirmedWorks(req *bundle.ToBeComfirmedWorksReq) (*bundle.ToBeComfirmedWorksResp, error) {
// data, err := dao.ToBeComfirmedWorks(req)
return nil, nil
data, total, unconfirmed, err := dao.ToBeComfirmedWorks(req)
if err != nil {
logger.Error(err)
return nil, errors.New("查询失败")
}
result := &bundle.ToBeComfirmedWorksResp{
Total: total,
Unconfirmed: unconfirmed,
}
result.Data = lo.Map(data, func(m model.CastWorkLog, _ int) *bundle.WorkItem {
result := &bundle.WorkItem{}
copier.Copy(result, &m)
return result
})
return result, nil
}
func ConfirmWork(req *bundle.ConfirmWorkReq) (*bundle.ConfirmWorkResp, error) {
return nil, dao.ConfirmWork(req)
}

View File

@ -88,12 +88,13 @@ type BundleExtensionRecords struct {
ImagesAdditional uint `gorm:"column:images_additional;type:int(11) unsigned;comment:图文额外增加" json:"images_additional"`
DataAdditional uint `gorm:"column:data_additional;type:int(11) unsigned;comment:数据额外增加" json:"data_additional"`
AvailableDurationAdditional uint `gorm:"column:available_duration_additional;type:int(11) unsigned;comment:可用时长增加" json:"available_duration_additional"`
TimeUnit uint `gorm:"column:time_unit;type:int(11) unsigned;comment:时间单位" json:"timeUnit"`
Type int `gorm:"column:type;type:tinyint(4);comment:类型 0:手动操作" json:"type"`
Type int `gorm:"column:type;type:tinyint(4);comment:类型 1:手动操作 2:自行购买" json:"type"`
Remark string `gorm:"column:remark;type:text;comment:备注" json:"remark"`
AssociatedorderNumber string `gorm:"column:associated_order_number;type:varchar(256);comment:关联订单号" json:"associatedOrderNumber"`
OperatorId int `gorm:"column:operator_id;type:int(11);comment:操作人id" json:"operator_id"`
OperatorName string `gorm:"column:operator_name;type:varchar(256)" json:"operatorName"`
OperatorPhoneNumber string `gorm:"column:operator_phone_number;type:varchar(256)" json:"operatorPhoneNumber"`
TimeUnit uint `gorm:"column:time_unit;type:int(11) unsigned;comment:时间单位" json:"timeUnit"`
}
// TableName 表名称
@ -102,16 +103,20 @@ func (*BundleExtensionRecords) TableName() string {
}
type BundleExtendRecordItemPo struct {
UserName string
UserPhoneNumber string
AccountAdditional int
ImagesAdditional int
DataAdditional int
VideoAdditional int
OperatorName string
OperatorPhoneNumber string
OrderUUID string
CreatedAt time.Time
UserName string
UserPhoneNumber string
AccountAdditional int
ImagesAdditional int
DataAdditional int
VideoAdditional int
AvailableDurationAdditional uint `gorm:"column:available_duration_additional;type:int(11) unsigned;comment:可用时长增加" json:"available_duration_additional"`
Type int
Remark string
OperatorName string
OperatorPhoneNumber string
AssociatedOrderNumber string `gorm:"column:associated_order_number;type:varchar(256);comment:关联订单号" json:"associatedOrderNumber"`
OrderUUID string
CreatedAt time.Time
}
type BundleExtendRecordItemDto struct {
@ -138,10 +143,10 @@ type BundleExtendRecordItemDto struct {
type BundleBalancePo struct {
UserId int `gorm:"column:user_id"`
UserName string `gorm:"column:user_name"`
UserPhoneNumber string `gorm:"column:user_phone_nmber"`
UserPhoneNumber string `gorm:"column:user_phone_number"`
BundleName string `gorm:"column:bundle_name"`
ExpirationTime string `gorm:"column:expired_time"`
BundleStatus int `gorm:"column:bundle_status"`
Status int `gorm:"column:status"`
OrderUUID string `gorm:"column:order_uuid"`
AccountNumber int `gorm:"column:account_number;not null"`
AccountConsumptionNumber int `gorm:"column:account_consumption_number;not null"`
@ -154,6 +159,30 @@ type BundleBalancePo struct {
ExpansionPacksNumber int `gorm:"column:expansion_packs_number;not null"`
}
type UserBundleBalancePo struct {
OrderUUID string `json:"orderUUID" gorm:"column:order_uuid"`
BundleUuid string `json:"bundleUuid" gorm:"column:bundle_uuid"`
BundleName string `json:"bundleName" gorm:"column:bundle_name"`
BundleStatus string `json:"bundleStatus" gorm:"column:bundle_status"`
PayTime string `json:"payTime" gorm:"column:pay_time"`
ExpiredTime string `json:"expiredTime" gorm:"column:expired_time"`
PaymentAmount string `json:"paymentAmount" gorm:"column:payment_amount"`
PaymentType int32 `json:"paymentType" gorm:"column:payment_type"`
AccountNumber int32 `json:"accountNumber" gorm:"column:account_number"`
AccountAdditional int32 `json:"accountAdditional" gorm:"column:account_additional"`
AccountConsumptionNumber int32 `json:"accountConsumptionNumber" gorm:"column:account_consumption_number"`
VideoNumber int32 `json:"videoNumber" gorm:"column:video_number"`
VideoAdditional int32 `json:"videoAdditional" gorm:"column:video_additional"`
VideoConsumptionNumber int32 `json:"videoConsumptionNumber" gorm:"column:video_consumption_number"`
ImageNumber int32 `json:"imageNumber" gorm:"column:image_number"`
ImageAdditional int32 `json:"imageAdditional" gorm:"column:image_additional"`
ImageConsumptionNumber int32 `json:"imageConsumptionNumber" gorm:"column:image_consumption_number"`
DataAnalysisNumber int32 `json:"dataAnalysisNumber" gorm:"column:data_analysis_number"`
DataAnalysisAdditional int32 `json:"dataAnalysisAdditional" gorm:"column:data_analysis_additional"`
DataAnalysisConsumptionNumber int32 `json:"dataAnalysisConsumptionNumber" gorm:"column:data_analysis_consumption_number"`
ExpansionPacksNumber int32 `json:"expansionPacksNumber" gorm:"column:expansion_packs_number"`
}
type BundleBalance struct {
gorm.Model
UserId int `gorm:"column:user_id;not null"`

View File

@ -1,6 +1,8 @@
package model
import "gorm.io/plugin/soft_delete"
import (
"gorm.io/plugin/soft_delete"
)
type CostLog struct {
Uuid string `gorm:"column:uuid;type:varchar(50);NOT NULL;primary_key;" json:"id"`
@ -85,3 +87,26 @@ type CastWork struct {
func (*CastWork) TableName() string {
return "cast_work"
}
type CastWorkLog struct {
Uuid string `gorm:"column:uuid;type:varchar(50);primary_key" json:"uuid"`
WorkUuid string `gorm:"column:work_uuid;type:varchar(50);comment:作品uuid;NOT NULL" json:"work_uuid"`
Title string `gorm:"column:title;type:varchar(50);NOT NULL" json:"title"`
Content string `gorm:"column:content;type:varchar(2000);NOT NULL" json:"content"`
WorkCategory int `gorm:"column:work_category;type:tinyint(1);default:1;comment: 1 图文 2 视频;NOT NULL" json:"work_category"`
UpdateTime string `gorm:"column:update_time;type:varchar(50);comment:更新时间;NOT NULL" json:"update_time"`
WorkStatus int `gorm:"column:work_status;type:tinyint(1);default:1;comment: 1 待提交 2 审核中 3 审核失败 4 待艺人确认 5 艺人驳回 6 发布成功 7 发布失败;NOT NULL" json:"work_status"`
PlatformIds string `gorm:"column:platform_ids;type:json;comment:发布平台ID集合 TIKTOK= 1, YOUTUBE = 2, INS = 3;NOT NULL" json:"platform_ids"`
ArtistName string `gorm:"column:artist_name;type:varchar(50);comment:艺人名称;NOT NULL" json:"artist_name"`
ArtistUuid string `gorm:"column:artist_uuid;type:varchar(50);comment:艺人ID;NOT NULL" json:"artist_uuid"`
MediaAccUserIds string `gorm:"column:media_acc_user_ids;type:json;comment:自媒体账号user_ids集合;NOT NULL" json:"media_acc_user_ids"`
MediaNames string `gorm:"column:media_names;type:varchar(600);comment:自媒体账号名称集合;NOT NULL" json:"media_names"`
ConfirmedAt int64 `gorm:"column:confirmed_at;type:int(11)" json:"confirmedAt"`
CreatedAt int `gorm:"column:created_at;type:int(11)" json:"created_at"`
UpdatedAt int `gorm:"column:updated_at;type:int(11)" json:"updated_at"`
DeletedAt uint64 `gorm:"column:deleted_at;type:bigint(20) unsigned" json:"deleted_at"`
}
func (m *CastWorkLog) TableName() string {
return "cast_work_log"
}

View File

@ -17,6 +17,10 @@ service Bundle {
rpc BundleListV2(BundleListRequest) returns(BundleListResponse) {}
rpc BundleDetailV2(BundleDetailRequest) returns(BundleDetailResponseV2) {}
rpc BundleListH5V2(BundleListRequest) returns(BundleListResponse) {}
rpc BundleLangDetailV2(BundleDetailRequest) returns(BundleProfileLang) {}
rpc BundleList(BundleListRequest) returns (BundleListResponse) {}
@ -45,15 +49,17 @@ service Bundle {
rpc ValueAddServiceDetail(ValueAddServiceDetailRequest) returns (ValueAddServiceDetailResponse) {}
rpc ValueAddServiceLangByUuidAndLanguage(ValueAddServiceDetailRequest)returns (ValueAddServiceLang) {}
rpc CalculatePrice(CalculatePriceRequest) returns (CalculatePriceResponse) {}
rpc BatchGetValueAddServiceLang(BatchGetValueAddServiceLangRequest) returns (BatchGetValueAddServiceLangResponse) {}
rpc DeleteValueAddService(DeleteValueAddServiceRequest) returns (CommonResponse) {}
//
rpc BundleExtend(BundleExtendRequest) returns (BundleExtendResponse) {} //
rpc BundleExtendRecordsList(BundleExtendRecordsListRequest) returns (BundleExtendRecordsListResponse) {} //
rpc GetBundleBalanceList(GetBundleBalanceListReq) returns (GetBundleBalanceListResp) {} //
rpc GetBundleBalanceByUserId(GetBundleBalanceByUserIdReq) returns (GetBundleBalanceByUserIdResp) {} //
rpc CreateBundleBalance(CreateBundleBalanceReq) returns (CreateBundleBalanceResp) {} //
rpc AddBundleBalance(AddBundleBalanceReq) returns (AddBundleBalanceResp) {} //
rpc AddBundleBalance(AddBundleBalanceReq) returns (AddBundleBalanceResp) {} //
// 使
rpc GetUsedRecordList(GetUsedRecordListReq) returns (GetUsedRecordListResp) {} // 使
@ -61,6 +67,7 @@ service Bundle {
rpc GetVedioWorkDetail(GetVedioWorkDetailReq) returns (GetVedioeWorkDetailResp) {} //
rpc ToBeComfirmedWorks(ToBeComfirmedWorksReq) returns (ToBeComfirmedWorksResp) {} //
rpc ConfirmWork(ConfirmWorkReq) returns (ConfirmWorkResp) {} //
//
rpc GetReconciliationList(GetReconciliationListReq) returns (GetReconciliationListResp) {} //
@ -68,13 +75,16 @@ service Bundle {
rpc UpdateReconciliation(ReconciliationInfo) returns (CommonResponse) {} //
rpc UpdateReconciliationStatusBySerialNumber(UpdateStatusAndPayTimeBySerialNumber) returns (CommonResponse) {} //
}
message DeleteValueAddServiceRequest{
string orderNo = 1;
uint64 userID = 2;
}
message GetReconciliationListReq{
string userName = 1;
string bundleName = 2;
int32 payStatus = 3;
int32 payChannel = 4;
string orderNo = 5;
string bundleOrderOn = 5;
string createdStart = 6;
string createdEnd = 7;
string payTimeStart = 8;
@ -83,6 +93,7 @@ message GetReconciliationListReq{
int32 page = 11;
int32 pageSize = 12;
repeated uint64 userIDS = 13;
string bundleAddOrderOn = 14;
}
message GetReconciliationListResp{
repeated ReconciliationInfo list = 1;
@ -119,6 +130,7 @@ message OrderInfoByOrderNoResp{
int32 dataNumber = 7;
int32 duration = 8;
string unit = 9;
string userName = 10;
}
message OrderCreateRecord{
@ -231,6 +243,7 @@ message BundleProfile {
repeated SelectValueAddService selectValueAddService = 17 [json_name = "SelectValueAddService"];
repeated BundleProfileLang bundleProfileLang = 18 [json_name = "bundleProfileLang"];
int32 imgOption = 19 [json_name = "imgOption"];
string fontColor = 20 [json_name = "fontColor"];
}
message BundleProfileLang {
string uuid = 1 [json_name = "uuid"];
@ -241,9 +254,15 @@ message BundleProfileLang {
string language = 6 [json_name = "language"];
string createdAt = 7 [json_name = "createdAt"];
string updatedAt = 8 [json_name = "updatedAt"];
//string bgImg1 = 9 [json_name = "bgImg1"];
//string bgImg2 = 10 [json_name = "bgImg2"];
// int64 sort = 11 [json_name = "sort"];
string contract = 9 [json_name = "contract"];
string companySign = 10 [json_name = "companySign"];
int64 contractDuration = 11 [json_name = "contractDuration"];
string fontColor = 12 [json_name = "fontColor"];
int64 sort = 13 [json_name = "sort"];
string bgImg1 = 14 [json_name = "bgImg1"];
string bgImg2 = 15 [json_name = "bgImg2"];
int64 shelfStatus = 16 [json_name = "shelfStatus"]; // 1 2
int32 imgOption = 17 [json_name = "imgOption"];
//repeated ValueAddServiceLang valueAddServiceLang = 12 [json_name = "ValueAddServiceLang"];
}
message SaveResponse {
@ -255,6 +274,8 @@ message SelectValueAddService {
string valueAddUuid = 1 [json_name = "valueAddUuid"];
string serviceName= 2 [json_name = "serviceName"];
bool isDisplay = 3 [json_name = "isDisplay"];
int32 serviceType = 4 [json_name = "serviceType"];
}
message DelBundleRequest {
string uuid = 1 [json_name = "uuid"];
@ -395,6 +416,7 @@ message OrderRecordsDetailRequest {
string orderNo = 2 [json_name = "orderNo"];
string customerID = 3 [json_name = "customerID"];
string bundleUUID = 4 [json_name = "bundleUUID"];
uint64 status = 5 [json_name = "status"];
}
message OrderRecordsDetailResponse {
@ -521,6 +543,14 @@ message CalculatePriceResponse{
string msg = 1;
float price = 2;
}
message BatchGetValueAddServiceLangRequest{
repeated string uuids = 1;
string language = 2;
}
message BatchGetValueAddServiceLangResponse{
string msg = 1;
repeated ValueAddServiceLang valueAddServiceLangList = 2;
}
//*********************************-over******************************************
message BundleExtendRequest{
@ -533,8 +563,10 @@ message BundleExtendRequest{
uint32 timeUnit = 7; // 1 2 3
string remark = 8;
string associatedorderNumber = 9;
string operatorName = 10;
string operatorPhoneNumber = 11;
uint64 operatorId = 10;
string operatorName = 11;
string operatorPhoneNumber = 12;
int32 type = 13;
}
message BundleExtendResponse{
@ -576,10 +608,11 @@ message GetBundleBalanceListReq{
string userName = 1;
int32 status = 2;
string bundleName = 3;
int64 expiredTimeStart = 4;
int64 expiredTimeEnd = 5;
int32 page = 6;
int32 pageSize = 7;
int32 bought = 4;
int64 expiredTimeStart = 5;
int64 expiredTimeEnd = 6;
int32 page = 7;
int32 pageSize = 8;
}
message GetBundleBalanceReq{
@ -608,11 +641,9 @@ message BundleBalanceItem{
int32 dataAnalysisNumber = 13;
int32 dataAnalysisConsumptionNumber = 14;
int32 expansionPacksNumber = 15;
int32 bought = 16;
}
message GetBundleBalanceResp{
int64 total = 1;
repeated BundleBalanceItem data = 2;
}
message GetBundleBalanceListResp{
int64 total = 1;
repeated BundleBalanceItem data = 2;
@ -658,7 +689,7 @@ message AddBundleBalanceResp{
message GetUsedRecordListReq{
string user = 1;
string operator = 2;
int32 account = 3;
string account = 3;
int32 platform = 4;
int32 type = 5;
string title = 6;
@ -681,7 +712,7 @@ message WorkCastItem{
uint32 workCategory = 5; // 1 2
string bundleUuid = 6; // ID uuid
string bundleName = 7; //
string platformIDs = 8; // ID集合 (json )
string platformIds = 8; // ID集合 (json )
string mediaNames = 9; //
string mediaAccIDs = 10; // ID集合
string workTitle = 11; //
@ -718,18 +749,54 @@ message ToBeComfirmedWorksReq{
int32 pageSize =3;
}
message workItem{
string uuid = 1;
string workUuid = 2;
string title = 3;
string content = 4;
uint32 workCategory = 5;
uint32 workStatus = 6;
string platformIds = 7;
string mediaNames = 8;
string mediaAccUserIds = 9;
int64 confirmedAt = 10;
int64 createdAt = 11; //
string artistName = 12;
string artistUuid = 13;
}
message ToBeComfirmedWorksResp{
string uuid = 1; // uuid
uint32 workCategory = 2; // 1 2
string platformIDs = 3; // ID集合 (json )
string mediaNames = 4; //
string mediaAccIDs = 5; // ID集合
string title = 6; //
string content = 7; //
string submitTime = 8; //
string operatorName = 9; //
string operatorPhone = 10; //
uint32 status = 11; // 1 2 3 4 5 6 7
int64 total = 1;
int64 unconfirmed = 2;
repeated workItem data = 3;
}
message GetBundleBalanceByUserIdReq{
int32 userId = 1;
}
message GetBundleBalanceByUserIdResp{
string orderUUID = 1;
string bundleUuid = 2; // ID uuid
string bundleName = 3; //
string bundleStatus = 4; //
int64 payTime = 5;
int64 expiredTime = 6;
string paymentAmount = 7;
int32 paymentType = 8;
int32 accountNumber = 9;
int32 accountAdditional = 10;
int32 accountConsumptionNumber = 11;
int32 videoNumber = 12;
int32 videoAdditional = 13;
int32 videoConsumptionNumber = 14;
int32 imageNumber = 15;
int32 imageAdditional = 16;
int32 imageConsumptionNumber = 17;
int32 dataAnalysisNumber = 18;
int32 dataAnalysisAdditional = 19;
int32 dataAnalysisConsumptionNumber = 20;
int32 expansionPacksNumber = 21;
}
message OnlyAddValueListByOrderNoRequest{
@ -752,4 +819,12 @@ message UpdateStatusAndPayTimeBySerialNumber {
string serialNumber = 1;
string payTime = 2;
int32 paymentStatus = 3;
}
message ConfirmWorkReq{
string workUuid = 1;
}
message ConfirmWorkResp{
}

File diff suppressed because it is too large Load Diff

View File

@ -5,11 +5,11 @@ package bundle
import (
fmt "fmt"
math "math"
proto "github.com/golang/protobuf/proto"
_ "google.golang.org/protobuf/types/descriptorpb"
_ "github.com/mwitkow/go-proto-validators"
github_com_mwitkow_go_proto_validators "github.com/mwitkow/go-proto-validators"
_ "google.golang.org/protobuf/types/descriptorpb"
math "math"
)
// Reference imports to suppress errors if they are not otherwise used.
@ -17,6 +17,9 @@ var _ = proto.Marshal
var _ = fmt.Errorf
var _ = math.Inf
func (this *DeleteValueAddServiceRequest) Validate() error {
return nil
}
func (this *GetReconciliationListReq) Validate() error {
return nil
}
@ -303,6 +306,19 @@ func (this *CalculatePriceRequest) Validate() error {
func (this *CalculatePriceResponse) Validate() error {
return nil
}
func (this *BatchGetValueAddServiceLangRequest) Validate() error {
return nil
}
func (this *BatchGetValueAddServiceLangResponse) Validate() error {
for _, item := range this.ValueAddServiceLangList {
if item != nil {
if err := github_com_mwitkow_go_proto_validators.CallValidatorIfExists(item); err != nil {
return github_com_mwitkow_go_proto_validators.FieldError("ValueAddServiceLangList", err)
}
}
}
return nil
}
func (this *BundleExtendRequest) Validate() error {
return nil
}
@ -334,16 +350,6 @@ func (this *GetBundleBalanceReq) Validate() error {
func (this *BundleBalanceItem) Validate() error {
return nil
}
func (this *GetBundleBalanceResp) Validate() error {
for _, item := range this.Data {
if item != nil {
if err := github_com_mwitkow_go_proto_validators.CallValidatorIfExists(item); err != nil {
return github_com_mwitkow_go_proto_validators.FieldError("Data", err)
}
}
}
return nil
}
func (this *GetBundleBalanceListResp) Validate() error {
for _, item := range this.Data {
if item != nil {
@ -397,7 +403,23 @@ func (this *GetVedioeWorkDetailResp) Validate() error {
func (this *ToBeComfirmedWorksReq) Validate() error {
return nil
}
func (this *WorkItem) Validate() error {
return nil
}
func (this *ToBeComfirmedWorksResp) Validate() error {
for _, item := range this.Data {
if item != nil {
if err := github_com_mwitkow_go_proto_validators.CallValidatorIfExists(item); err != nil {
return github_com_mwitkow_go_proto_validators.FieldError("Data", err)
}
}
}
return nil
}
func (this *GetBundleBalanceByUserIdReq) Validate() error {
return nil
}
func (this *GetBundleBalanceByUserIdResp) Validate() error {
return nil
}
func (this *OnlyAddValueListByOrderNoRequest) Validate() error {
@ -419,3 +441,9 @@ func (this *AddBundleInfo) Validate() error {
func (this *UpdateStatusAndPayTimeBySerialNumber) Validate() error {
return nil
}
func (this *ConfirmWorkReq) Validate() error {
return nil
}
func (this *ConfirmWorkResp) Validate() error {
return nil
}

View File

@ -1,7 +1,7 @@
// Code generated by protoc-gen-go-triple. DO NOT EDIT.
// versions:
// - protoc-gen-go-triple v1.0.8
// - protoc v5.26.1
// - protoc v3.20.3
// source: pb/bundle.proto
package bundle
@ -35,6 +35,8 @@ type BundleClient interface {
SaveBundle(ctx context.Context, in *BundleProfile, opts ...grpc_go.CallOption) (*SaveResponse, common.ErrorWithAttachment)
BundleListV2(ctx context.Context, in *BundleListRequest, opts ...grpc_go.CallOption) (*BundleListResponse, common.ErrorWithAttachment)
BundleDetailV2(ctx context.Context, in *BundleDetailRequest, opts ...grpc_go.CallOption) (*BundleDetailResponseV2, common.ErrorWithAttachment)
BundleListH5V2(ctx context.Context, in *BundleListRequest, opts ...grpc_go.CallOption) (*BundleListResponse, common.ErrorWithAttachment)
BundleLangDetailV2(ctx context.Context, in *BundleDetailRequest, opts ...grpc_go.CallOption) (*BundleProfileLang, common.ErrorWithAttachment)
BundleList(ctx context.Context, in *BundleListRequest, opts ...grpc_go.CallOption) (*BundleListResponse, common.ErrorWithAttachment)
BundleDetail(ctx context.Context, in *BundleDetailRequest, opts ...grpc_go.CallOption) (*BundleDetailResponse, common.ErrorWithAttachment)
CreateOrderRecord(ctx context.Context, in *OrderCreateRecord, opts ...grpc_go.CallOption) (*CommonResponse, common.ErrorWithAttachment)
@ -58,10 +60,13 @@ type BundleClient interface {
ValueAddServiceDetail(ctx context.Context, in *ValueAddServiceDetailRequest, opts ...grpc_go.CallOption) (*ValueAddServiceDetailResponse, common.ErrorWithAttachment)
ValueAddServiceLangByUuidAndLanguage(ctx context.Context, in *ValueAddServiceDetailRequest, opts ...grpc_go.CallOption) (*ValueAddServiceLang, common.ErrorWithAttachment)
CalculatePrice(ctx context.Context, in *CalculatePriceRequest, opts ...grpc_go.CallOption) (*CalculatePriceResponse, common.ErrorWithAttachment)
BatchGetValueAddServiceLang(ctx context.Context, in *BatchGetValueAddServiceLangRequest, opts ...grpc_go.CallOption) (*BatchGetValueAddServiceLangResponse, common.ErrorWithAttachment)
DeleteValueAddService(ctx context.Context, in *DeleteValueAddServiceRequest, opts ...grpc_go.CallOption) (*CommonResponse, common.ErrorWithAttachment)
// 余量管理
BundleExtend(ctx context.Context, in *BundleExtendRequest, opts ...grpc_go.CallOption) (*BundleExtendResponse, common.ErrorWithAttachment)
BundleExtendRecordsList(ctx context.Context, in *BundleExtendRecordsListRequest, opts ...grpc_go.CallOption) (*BundleExtendRecordsListResponse, common.ErrorWithAttachment)
GetBundleBalanceList(ctx context.Context, in *GetBundleBalanceListReq, opts ...grpc_go.CallOption) (*GetBundleBalanceListResp, common.ErrorWithAttachment)
GetBundleBalanceByUserId(ctx context.Context, in *GetBundleBalanceByUserIdReq, opts ...grpc_go.CallOption) (*GetBundleBalanceByUserIdResp, common.ErrorWithAttachment)
CreateBundleBalance(ctx context.Context, in *CreateBundleBalanceReq, opts ...grpc_go.CallOption) (*CreateBundleBalanceResp, common.ErrorWithAttachment)
AddBundleBalance(ctx context.Context, in *AddBundleBalanceReq, opts ...grpc_go.CallOption) (*AddBundleBalanceResp, common.ErrorWithAttachment)
// 使用记录
@ -69,6 +74,7 @@ type BundleClient interface {
GetImageWorkDetail(ctx context.Context, in *GetImageWorkDetailReq, opts ...grpc_go.CallOption) (*GetImageWorkDetailResp, common.ErrorWithAttachment)
GetVedioWorkDetail(ctx context.Context, in *GetVedioWorkDetailReq, opts ...grpc_go.CallOption) (*GetVedioeWorkDetailResp, common.ErrorWithAttachment)
ToBeComfirmedWorks(ctx context.Context, in *ToBeComfirmedWorksReq, opts ...grpc_go.CallOption) (*ToBeComfirmedWorksResp, common.ErrorWithAttachment)
ConfirmWork(ctx context.Context, in *ConfirmWorkReq, opts ...grpc_go.CallOption) (*ConfirmWorkResp, common.ErrorWithAttachment)
// 对账单
GetReconciliationList(ctx context.Context, in *GetReconciliationListReq, opts ...grpc_go.CallOption) (*GetReconciliationListResp, common.ErrorWithAttachment)
CreateReconciliation(ctx context.Context, in *ReconciliationInfo, opts ...grpc_go.CallOption) (*CommonResponse, common.ErrorWithAttachment)
@ -88,6 +94,8 @@ type BundleClientImpl struct {
SaveBundle func(ctx context.Context, in *BundleProfile) (*SaveResponse, error)
BundleListV2 func(ctx context.Context, in *BundleListRequest) (*BundleListResponse, error)
BundleDetailV2 func(ctx context.Context, in *BundleDetailRequest) (*BundleDetailResponseV2, error)
BundleListH5V2 func(ctx context.Context, in *BundleListRequest) (*BundleListResponse, error)
BundleLangDetailV2 func(ctx context.Context, in *BundleDetailRequest) (*BundleProfileLang, error)
BundleList func(ctx context.Context, in *BundleListRequest) (*BundleListResponse, error)
BundleDetail func(ctx context.Context, in *BundleDetailRequest) (*BundleDetailResponse, error)
CreateOrderRecord func(ctx context.Context, in *OrderCreateRecord) (*CommonResponse, error)
@ -109,15 +117,19 @@ type BundleClientImpl struct {
ValueAddServiceDetail func(ctx context.Context, in *ValueAddServiceDetailRequest) (*ValueAddServiceDetailResponse, error)
ValueAddServiceLangByUuidAndLanguage func(ctx context.Context, in *ValueAddServiceDetailRequest) (*ValueAddServiceLang, error)
CalculatePrice func(ctx context.Context, in *CalculatePriceRequest) (*CalculatePriceResponse, error)
BatchGetValueAddServiceLang func(ctx context.Context, in *BatchGetValueAddServiceLangRequest) (*BatchGetValueAddServiceLangResponse, error)
DeleteValueAddService func(ctx context.Context, in *DeleteValueAddServiceRequest) (*CommonResponse, error)
BundleExtend func(ctx context.Context, in *BundleExtendRequest) (*BundleExtendResponse, error)
BundleExtendRecordsList func(ctx context.Context, in *BundleExtendRecordsListRequest) (*BundleExtendRecordsListResponse, error)
GetBundleBalanceList func(ctx context.Context, in *GetBundleBalanceListReq) (*GetBundleBalanceListResp, error)
GetBundleBalanceByUserId func(ctx context.Context, in *GetBundleBalanceByUserIdReq) (*GetBundleBalanceByUserIdResp, error)
CreateBundleBalance func(ctx context.Context, in *CreateBundleBalanceReq) (*CreateBundleBalanceResp, error)
AddBundleBalance func(ctx context.Context, in *AddBundleBalanceReq) (*AddBundleBalanceResp, error)
GetUsedRecordList func(ctx context.Context, in *GetUsedRecordListReq) (*GetUsedRecordListResp, error)
GetImageWorkDetail func(ctx context.Context, in *GetImageWorkDetailReq) (*GetImageWorkDetailResp, error)
GetVedioWorkDetail func(ctx context.Context, in *GetVedioWorkDetailReq) (*GetVedioeWorkDetailResp, error)
ToBeComfirmedWorks func(ctx context.Context, in *ToBeComfirmedWorksReq) (*ToBeComfirmedWorksResp, error)
ConfirmWork func(ctx context.Context, in *ConfirmWorkReq) (*ConfirmWorkResp, error)
GetReconciliationList func(ctx context.Context, in *GetReconciliationListReq) (*GetReconciliationListResp, error)
CreateReconciliation func(ctx context.Context, in *ReconciliationInfo) (*CommonResponse, error)
UpdateReconciliation func(ctx context.Context, in *ReconciliationInfo) (*CommonResponse, error)
@ -178,6 +190,18 @@ func (c *bundleClient) BundleDetailV2(ctx context.Context, in *BundleDetailReque
return out, c.cc.Invoke(ctx, "/"+interfaceKey+"/BundleDetailV2", in, out)
}
func (c *bundleClient) BundleListH5V2(ctx context.Context, in *BundleListRequest, opts ...grpc_go.CallOption) (*BundleListResponse, common.ErrorWithAttachment) {
out := new(BundleListResponse)
interfaceKey := ctx.Value(constant.InterfaceKey).(string)
return out, c.cc.Invoke(ctx, "/"+interfaceKey+"/BundleListH5V2", in, out)
}
func (c *bundleClient) BundleLangDetailV2(ctx context.Context, in *BundleDetailRequest, opts ...grpc_go.CallOption) (*BundleProfileLang, common.ErrorWithAttachment) {
out := new(BundleProfileLang)
interfaceKey := ctx.Value(constant.InterfaceKey).(string)
return out, c.cc.Invoke(ctx, "/"+interfaceKey+"/BundleLangDetailV2", in, out)
}
func (c *bundleClient) BundleList(ctx context.Context, in *BundleListRequest, opts ...grpc_go.CallOption) (*BundleListResponse, common.ErrorWithAttachment) {
out := new(BundleListResponse)
interfaceKey := ctx.Value(constant.InterfaceKey).(string)
@ -304,6 +328,18 @@ func (c *bundleClient) CalculatePrice(ctx context.Context, in *CalculatePriceReq
return out, c.cc.Invoke(ctx, "/"+interfaceKey+"/CalculatePrice", in, out)
}
func (c *bundleClient) BatchGetValueAddServiceLang(ctx context.Context, in *BatchGetValueAddServiceLangRequest, opts ...grpc_go.CallOption) (*BatchGetValueAddServiceLangResponse, common.ErrorWithAttachment) {
out := new(BatchGetValueAddServiceLangResponse)
interfaceKey := ctx.Value(constant.InterfaceKey).(string)
return out, c.cc.Invoke(ctx, "/"+interfaceKey+"/BatchGetValueAddServiceLang", in, out)
}
func (c *bundleClient) DeleteValueAddService(ctx context.Context, in *DeleteValueAddServiceRequest, opts ...grpc_go.CallOption) (*CommonResponse, common.ErrorWithAttachment) {
out := new(CommonResponse)
interfaceKey := ctx.Value(constant.InterfaceKey).(string)
return out, c.cc.Invoke(ctx, "/"+interfaceKey+"/DeleteValueAddService", in, out)
}
func (c *bundleClient) BundleExtend(ctx context.Context, in *BundleExtendRequest, opts ...grpc_go.CallOption) (*BundleExtendResponse, common.ErrorWithAttachment) {
out := new(BundleExtendResponse)
interfaceKey := ctx.Value(constant.InterfaceKey).(string)
@ -322,6 +358,12 @@ func (c *bundleClient) GetBundleBalanceList(ctx context.Context, in *GetBundleBa
return out, c.cc.Invoke(ctx, "/"+interfaceKey+"/GetBundleBalanceList", in, out)
}
func (c *bundleClient) GetBundleBalanceByUserId(ctx context.Context, in *GetBundleBalanceByUserIdReq, opts ...grpc_go.CallOption) (*GetBundleBalanceByUserIdResp, common.ErrorWithAttachment) {
out := new(GetBundleBalanceByUserIdResp)
interfaceKey := ctx.Value(constant.InterfaceKey).(string)
return out, c.cc.Invoke(ctx, "/"+interfaceKey+"/GetBundleBalanceByUserId", in, out)
}
func (c *bundleClient) CreateBundleBalance(ctx context.Context, in *CreateBundleBalanceReq, opts ...grpc_go.CallOption) (*CreateBundleBalanceResp, common.ErrorWithAttachment) {
out := new(CreateBundleBalanceResp)
interfaceKey := ctx.Value(constant.InterfaceKey).(string)
@ -358,6 +400,12 @@ func (c *bundleClient) ToBeComfirmedWorks(ctx context.Context, in *ToBeComfirmed
return out, c.cc.Invoke(ctx, "/"+interfaceKey+"/ToBeComfirmedWorks", in, out)
}
func (c *bundleClient) ConfirmWork(ctx context.Context, in *ConfirmWorkReq, opts ...grpc_go.CallOption) (*ConfirmWorkResp, common.ErrorWithAttachment) {
out := new(ConfirmWorkResp)
interfaceKey := ctx.Value(constant.InterfaceKey).(string)
return out, c.cc.Invoke(ctx, "/"+interfaceKey+"/ConfirmWork", in, out)
}
func (c *bundleClient) GetReconciliationList(ctx context.Context, in *GetReconciliationListReq, opts ...grpc_go.CallOption) (*GetReconciliationListResp, common.ErrorWithAttachment) {
out := new(GetReconciliationListResp)
interfaceKey := ctx.Value(constant.InterfaceKey).(string)
@ -393,6 +441,8 @@ type BundleServer interface {
SaveBundle(context.Context, *BundleProfile) (*SaveResponse, error)
BundleListV2(context.Context, *BundleListRequest) (*BundleListResponse, error)
BundleDetailV2(context.Context, *BundleDetailRequest) (*BundleDetailResponseV2, error)
BundleListH5V2(context.Context, *BundleListRequest) (*BundleListResponse, error)
BundleLangDetailV2(context.Context, *BundleDetailRequest) (*BundleProfileLang, error)
BundleList(context.Context, *BundleListRequest) (*BundleListResponse, error)
BundleDetail(context.Context, *BundleDetailRequest) (*BundleDetailResponse, error)
CreateOrderRecord(context.Context, *OrderCreateRecord) (*CommonResponse, error)
@ -416,10 +466,13 @@ type BundleServer interface {
ValueAddServiceDetail(context.Context, *ValueAddServiceDetailRequest) (*ValueAddServiceDetailResponse, error)
ValueAddServiceLangByUuidAndLanguage(context.Context, *ValueAddServiceDetailRequest) (*ValueAddServiceLang, error)
CalculatePrice(context.Context, *CalculatePriceRequest) (*CalculatePriceResponse, error)
BatchGetValueAddServiceLang(context.Context, *BatchGetValueAddServiceLangRequest) (*BatchGetValueAddServiceLangResponse, error)
DeleteValueAddService(context.Context, *DeleteValueAddServiceRequest) (*CommonResponse, error)
// 余量管理
BundleExtend(context.Context, *BundleExtendRequest) (*BundleExtendResponse, error)
BundleExtendRecordsList(context.Context, *BundleExtendRecordsListRequest) (*BundleExtendRecordsListResponse, error)
GetBundleBalanceList(context.Context, *GetBundleBalanceListReq) (*GetBundleBalanceListResp, error)
GetBundleBalanceByUserId(context.Context, *GetBundleBalanceByUserIdReq) (*GetBundleBalanceByUserIdResp, error)
CreateBundleBalance(context.Context, *CreateBundleBalanceReq) (*CreateBundleBalanceResp, error)
AddBundleBalance(context.Context, *AddBundleBalanceReq) (*AddBundleBalanceResp, error)
// 使用记录
@ -427,6 +480,7 @@ type BundleServer interface {
GetImageWorkDetail(context.Context, *GetImageWorkDetailReq) (*GetImageWorkDetailResp, error)
GetVedioWorkDetail(context.Context, *GetVedioWorkDetailReq) (*GetVedioeWorkDetailResp, error)
ToBeComfirmedWorks(context.Context, *ToBeComfirmedWorksReq) (*ToBeComfirmedWorksResp, error)
ConfirmWork(context.Context, *ConfirmWorkReq) (*ConfirmWorkResp, error)
// 对账单
GetReconciliationList(context.Context, *GetReconciliationListReq) (*GetReconciliationListResp, error)
CreateReconciliation(context.Context, *ReconciliationInfo) (*CommonResponse, error)
@ -461,6 +515,12 @@ func (UnimplementedBundleServer) BundleListV2(context.Context, *BundleListReques
func (UnimplementedBundleServer) BundleDetailV2(context.Context, *BundleDetailRequest) (*BundleDetailResponseV2, error) {
return nil, status.Errorf(codes.Unimplemented, "method BundleDetailV2 not implemented")
}
func (UnimplementedBundleServer) BundleListH5V2(context.Context, *BundleListRequest) (*BundleListResponse, error) {
return nil, status.Errorf(codes.Unimplemented, "method BundleListH5V2 not implemented")
}
func (UnimplementedBundleServer) BundleLangDetailV2(context.Context, *BundleDetailRequest) (*BundleProfileLang, error) {
return nil, status.Errorf(codes.Unimplemented, "method BundleLangDetailV2 not implemented")
}
func (UnimplementedBundleServer) BundleList(context.Context, *BundleListRequest) (*BundleListResponse, error) {
return nil, status.Errorf(codes.Unimplemented, "method BundleList not implemented")
}
@ -524,6 +584,12 @@ func (UnimplementedBundleServer) ValueAddServiceLangByUuidAndLanguage(context.Co
func (UnimplementedBundleServer) CalculatePrice(context.Context, *CalculatePriceRequest) (*CalculatePriceResponse, error) {
return nil, status.Errorf(codes.Unimplemented, "method CalculatePrice not implemented")
}
func (UnimplementedBundleServer) BatchGetValueAddServiceLang(context.Context, *BatchGetValueAddServiceLangRequest) (*BatchGetValueAddServiceLangResponse, error) {
return nil, status.Errorf(codes.Unimplemented, "method BatchGetValueAddServiceLang not implemented")
}
func (UnimplementedBundleServer) DeleteValueAddService(context.Context, *DeleteValueAddServiceRequest) (*CommonResponse, error) {
return nil, status.Errorf(codes.Unimplemented, "method DeleteValueAddService not implemented")
}
func (UnimplementedBundleServer) BundleExtend(context.Context, *BundleExtendRequest) (*BundleExtendResponse, error) {
return nil, status.Errorf(codes.Unimplemented, "method BundleExtend not implemented")
}
@ -533,6 +599,9 @@ func (UnimplementedBundleServer) BundleExtendRecordsList(context.Context, *Bundl
func (UnimplementedBundleServer) GetBundleBalanceList(context.Context, *GetBundleBalanceListReq) (*GetBundleBalanceListResp, error) {
return nil, status.Errorf(codes.Unimplemented, "method GetBundleBalanceList not implemented")
}
func (UnimplementedBundleServer) GetBundleBalanceByUserId(context.Context, *GetBundleBalanceByUserIdReq) (*GetBundleBalanceByUserIdResp, error) {
return nil, status.Errorf(codes.Unimplemented, "method GetBundleBalanceByUserId not implemented")
}
func (UnimplementedBundleServer) CreateBundleBalance(context.Context, *CreateBundleBalanceReq) (*CreateBundleBalanceResp, error) {
return nil, status.Errorf(codes.Unimplemented, "method CreateBundleBalance not implemented")
}
@ -551,6 +620,9 @@ func (UnimplementedBundleServer) GetVedioWorkDetail(context.Context, *GetVedioWo
func (UnimplementedBundleServer) ToBeComfirmedWorks(context.Context, *ToBeComfirmedWorksReq) (*ToBeComfirmedWorksResp, error) {
return nil, status.Errorf(codes.Unimplemented, "method ToBeComfirmedWorks not implemented")
}
func (UnimplementedBundleServer) ConfirmWork(context.Context, *ConfirmWorkReq) (*ConfirmWorkResp, error) {
return nil, status.Errorf(codes.Unimplemented, "method ConfirmWork not implemented")
}
func (UnimplementedBundleServer) GetReconciliationList(context.Context, *GetReconciliationListReq) (*GetReconciliationListResp, error) {
return nil, status.Errorf(codes.Unimplemented, "method GetReconciliationList not implemented")
}
@ -794,6 +866,64 @@ func _Bundle_BundleDetailV2_Handler(srv interface{}, ctx context.Context, dec fu
return interceptor(ctx, in, info, handler)
}
func _Bundle_BundleListH5V2_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc_go.UnaryServerInterceptor) (interface{}, error) {
in := new(BundleListRequest)
if err := dec(in); err != nil {
return nil, err
}
base := srv.(dubbo3.Dubbo3GrpcService)
args := []interface{}{}
args = append(args, in)
md, _ := metadata.FromIncomingContext(ctx)
invAttachment := make(map[string]interface{}, len(md))
for k, v := range md {
invAttachment[k] = v
}
invo := invocation.NewRPCInvocation("BundleListH5V2", args, invAttachment)
if interceptor == nil {
result := base.XXX_GetProxyImpl().Invoke(ctx, invo)
return result, result.Error()
}
info := &grpc_go.UnaryServerInfo{
Server: srv,
FullMethod: ctx.Value("XXX_TRIPLE_GO_INTERFACE_NAME").(string),
}
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
result := base.XXX_GetProxyImpl().Invoke(ctx, invo)
return result, result.Error()
}
return interceptor(ctx, in, info, handler)
}
func _Bundle_BundleLangDetailV2_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc_go.UnaryServerInterceptor) (interface{}, error) {
in := new(BundleDetailRequest)
if err := dec(in); err != nil {
return nil, err
}
base := srv.(dubbo3.Dubbo3GrpcService)
args := []interface{}{}
args = append(args, in)
md, _ := metadata.FromIncomingContext(ctx)
invAttachment := make(map[string]interface{}, len(md))
for k, v := range md {
invAttachment[k] = v
}
invo := invocation.NewRPCInvocation("BundleLangDetailV2", args, invAttachment)
if interceptor == nil {
result := base.XXX_GetProxyImpl().Invoke(ctx, invo)
return result, result.Error()
}
info := &grpc_go.UnaryServerInfo{
Server: srv,
FullMethod: ctx.Value("XXX_TRIPLE_GO_INTERFACE_NAME").(string),
}
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
result := base.XXX_GetProxyImpl().Invoke(ctx, invo)
return result, result.Error()
}
return interceptor(ctx, in, info, handler)
}
func _Bundle_BundleList_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc_go.UnaryServerInterceptor) (interface{}, error) {
in := new(BundleListRequest)
if err := dec(in); err != nil {
@ -1403,6 +1533,64 @@ func _Bundle_CalculatePrice_Handler(srv interface{}, ctx context.Context, dec fu
return interceptor(ctx, in, info, handler)
}
func _Bundle_BatchGetValueAddServiceLang_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc_go.UnaryServerInterceptor) (interface{}, error) {
in := new(BatchGetValueAddServiceLangRequest)
if err := dec(in); err != nil {
return nil, err
}
base := srv.(dubbo3.Dubbo3GrpcService)
args := []interface{}{}
args = append(args, in)
md, _ := metadata.FromIncomingContext(ctx)
invAttachment := make(map[string]interface{}, len(md))
for k, v := range md {
invAttachment[k] = v
}
invo := invocation.NewRPCInvocation("BatchGetValueAddServiceLang", args, invAttachment)
if interceptor == nil {
result := base.XXX_GetProxyImpl().Invoke(ctx, invo)
return result, result.Error()
}
info := &grpc_go.UnaryServerInfo{
Server: srv,
FullMethod: ctx.Value("XXX_TRIPLE_GO_INTERFACE_NAME").(string),
}
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
result := base.XXX_GetProxyImpl().Invoke(ctx, invo)
return result, result.Error()
}
return interceptor(ctx, in, info, handler)
}
func _Bundle_DeleteValueAddService_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc_go.UnaryServerInterceptor) (interface{}, error) {
in := new(DeleteValueAddServiceRequest)
if err := dec(in); err != nil {
return nil, err
}
base := srv.(dubbo3.Dubbo3GrpcService)
args := []interface{}{}
args = append(args, in)
md, _ := metadata.FromIncomingContext(ctx)
invAttachment := make(map[string]interface{}, len(md))
for k, v := range md {
invAttachment[k] = v
}
invo := invocation.NewRPCInvocation("DeleteValueAddService", args, invAttachment)
if interceptor == nil {
result := base.XXX_GetProxyImpl().Invoke(ctx, invo)
return result, result.Error()
}
info := &grpc_go.UnaryServerInfo{
Server: srv,
FullMethod: ctx.Value("XXX_TRIPLE_GO_INTERFACE_NAME").(string),
}
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
result := base.XXX_GetProxyImpl().Invoke(ctx, invo)
return result, result.Error()
}
return interceptor(ctx, in, info, handler)
}
func _Bundle_BundleExtend_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc_go.UnaryServerInterceptor) (interface{}, error) {
in := new(BundleExtendRequest)
if err := dec(in); err != nil {
@ -1490,6 +1678,35 @@ func _Bundle_GetBundleBalanceList_Handler(srv interface{}, ctx context.Context,
return interceptor(ctx, in, info, handler)
}
func _Bundle_GetBundleBalanceByUserId_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc_go.UnaryServerInterceptor) (interface{}, error) {
in := new(GetBundleBalanceByUserIdReq)
if err := dec(in); err != nil {
return nil, err
}
base := srv.(dubbo3.Dubbo3GrpcService)
args := []interface{}{}
args = append(args, in)
md, _ := metadata.FromIncomingContext(ctx)
invAttachment := make(map[string]interface{}, len(md))
for k, v := range md {
invAttachment[k] = v
}
invo := invocation.NewRPCInvocation("GetBundleBalanceByUserId", args, invAttachment)
if interceptor == nil {
result := base.XXX_GetProxyImpl().Invoke(ctx, invo)
return result, result.Error()
}
info := &grpc_go.UnaryServerInfo{
Server: srv,
FullMethod: ctx.Value("XXX_TRIPLE_GO_INTERFACE_NAME").(string),
}
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
result := base.XXX_GetProxyImpl().Invoke(ctx, invo)
return result, result.Error()
}
return interceptor(ctx, in, info, handler)
}
func _Bundle_CreateBundleBalance_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc_go.UnaryServerInterceptor) (interface{}, error) {
in := new(CreateBundleBalanceReq)
if err := dec(in); err != nil {
@ -1664,6 +1881,35 @@ func _Bundle_ToBeComfirmedWorks_Handler(srv interface{}, ctx context.Context, de
return interceptor(ctx, in, info, handler)
}
func _Bundle_ConfirmWork_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc_go.UnaryServerInterceptor) (interface{}, error) {
in := new(ConfirmWorkReq)
if err := dec(in); err != nil {
return nil, err
}
base := srv.(dubbo3.Dubbo3GrpcService)
args := []interface{}{}
args = append(args, in)
md, _ := metadata.FromIncomingContext(ctx)
invAttachment := make(map[string]interface{}, len(md))
for k, v := range md {
invAttachment[k] = v
}
invo := invocation.NewRPCInvocation("ConfirmWork", args, invAttachment)
if interceptor == nil {
result := base.XXX_GetProxyImpl().Invoke(ctx, invo)
return result, result.Error()
}
info := &grpc_go.UnaryServerInfo{
Server: srv,
FullMethod: ctx.Value("XXX_TRIPLE_GO_INTERFACE_NAME").(string),
}
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
result := base.XXX_GetProxyImpl().Invoke(ctx, invo)
return result, result.Error()
}
return interceptor(ctx, in, info, handler)
}
func _Bundle_GetReconciliationList_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc_go.UnaryServerInterceptor) (interface{}, error) {
in := new(GetReconciliationListReq)
if err := dec(in); err != nil {
@ -1815,6 +2061,14 @@ var Bundle_ServiceDesc = grpc_go.ServiceDesc{
MethodName: "BundleDetailV2",
Handler: _Bundle_BundleDetailV2_Handler,
},
{
MethodName: "BundleListH5V2",
Handler: _Bundle_BundleListH5V2_Handler,
},
{
MethodName: "BundleLangDetailV2",
Handler: _Bundle_BundleLangDetailV2_Handler,
},
{
MethodName: "BundleList",
Handler: _Bundle_BundleList_Handler,
@ -1899,6 +2153,14 @@ var Bundle_ServiceDesc = grpc_go.ServiceDesc{
MethodName: "CalculatePrice",
Handler: _Bundle_CalculatePrice_Handler,
},
{
MethodName: "BatchGetValueAddServiceLang",
Handler: _Bundle_BatchGetValueAddServiceLang_Handler,
},
{
MethodName: "DeleteValueAddService",
Handler: _Bundle_DeleteValueAddService_Handler,
},
{
MethodName: "BundleExtend",
Handler: _Bundle_BundleExtend_Handler,
@ -1911,6 +2173,10 @@ var Bundle_ServiceDesc = grpc_go.ServiceDesc{
MethodName: "GetBundleBalanceList",
Handler: _Bundle_GetBundleBalanceList_Handler,
},
{
MethodName: "GetBundleBalanceByUserId",
Handler: _Bundle_GetBundleBalanceByUserId_Handler,
},
{
MethodName: "CreateBundleBalance",
Handler: _Bundle_CreateBundleBalance_Handler,
@ -1935,6 +2201,10 @@ var Bundle_ServiceDesc = grpc_go.ServiceDesc{
MethodName: "ToBeComfirmedWorks",
Handler: _Bundle_ToBeComfirmedWorks_Handler,
},
{
MethodName: "ConfirmWork",
Handler: _Bundle_ConfirmWork_Handler,
},
{
MethodName: "GetReconciliationList",
Handler: _Bundle_GetReconciliationList_Handler,