fix: 提交支持自动创建用户和订单代码
This commit is contained in:
parent
d5e4c9590f
commit
402a7644e6
@ -117,3 +117,13 @@ func (b *BundleProvider) UpdateReconciliationStatusBySerialNumber(_ context.Cont
|
||||
func (b *BundleProvider) DeleteValueAddService(_ context.Context, req *bundle.DeleteValueAddServiceRequest) (res *bundle.CommonResponse, err error) {
|
||||
return logic.DeleteValueAddService(req)
|
||||
}
|
||||
|
||||
// 自动创建用户且实名且下订单
|
||||
func (b *BundleProvider) ListUnfinishedInfos(_ context.Context, req *bundle.AutoCreateUserAndOrderRequest) (res *bundle.UnfinishedInfos, err error) {
|
||||
return logic.ListUnfinishedInfos(req)
|
||||
}
|
||||
|
||||
// 自动创建用户且实名且下订单
|
||||
func (b *BundleProvider) SoftDeleteUnfinishedInfo(_ context.Context, req *bundle.SoftDeleteUnfinishedInfoRequest) (res *bundle.CommonResponse, err error) {
|
||||
return logic.SoftDeleteUnfinishedInfo(req)
|
||||
}
|
||||
|
@ -781,3 +781,65 @@ func DeleteValueAddService(req *bundle.DeleteValueAddServiceRequest) (res *bundl
|
||||
res.Msg = msg.SuccessDeletedOrderInfo
|
||||
return res, nil
|
||||
}
|
||||
|
||||
func ListUnfinishedInfos(req *bundle.AutoCreateUserAndOrderRequest) (res *bundle.UnfinishedInfos, err error) {
|
||||
res = new(bundle.UnfinishedInfos)
|
||||
res.UnfinishedInfos = make([]*bundle.UnfinishedInfo, 0)
|
||||
|
||||
// TODO 0.捞出指定数量的数据
|
||||
infos := make([]*model.FieePaymentAuto, 0)
|
||||
query := app.ModuleClients.BundleDB.Where("deleted_at is null")
|
||||
if req.Num != 0 {
|
||||
query.Limit(int(req.Num))
|
||||
}
|
||||
err = query.Find(&infos).Error
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
for _, info := range infos {
|
||||
unfinishedInfo := new(bundle.UnfinishedInfo)
|
||||
unfinishedInfo.ID = uint32(info.ID)
|
||||
unfinishedInfo.UserNum = info.UserNum
|
||||
unfinishedInfo.UserName = info.UserName
|
||||
unfinishedInfo.UserTelArea = info.UserTelArea
|
||||
unfinishedInfo.UserTel = info.UserTel
|
||||
unfinishedInfo.UserSex = info.UserSex
|
||||
unfinishedInfo.Nationality = info.Nationality
|
||||
unfinishedInfo.PlaceOfResidence = info.PlaceOfResidence
|
||||
unfinishedInfo.DocumentType = int32(info.DocumentType)
|
||||
unfinishedInfo.UserIdCardFrontUrl = info.UserIdCardFrontUrl
|
||||
unfinishedInfo.UserIdCardReverseUrl = info.UserIdCardReverseUrl
|
||||
unfinishedInfo.UserIdCardValidity = info.UserIdCardValidity
|
||||
unfinishedInfo.OrderNo = info.OrderNo
|
||||
unfinishedInfo.OrderPayAmount = info.OrderPayAmount
|
||||
unfinishedInfo.OrderSettlementAmount = info.OrderSettlementAmount
|
||||
unfinishedInfo.OrderFeeAmount = info.OrderFeeAmount
|
||||
unfinishedInfo.OrderPayCurrency = info.OrderPayCurrency
|
||||
unfinishedInfo.OrderAccountCurrency = info.OrderAccountCurrency
|
||||
unfinishedInfo.PayTime = info.PayTime.Format("2006-01-02 15:04:05")
|
||||
res.UnfinishedInfos = append(res.UnfinishedInfos, unfinishedInfo)
|
||||
}
|
||||
|
||||
return res, nil
|
||||
}
|
||||
|
||||
func SoftDeleteUnfinishedInfo(req *bundle.SoftDeleteUnfinishedInfoRequest) (res *bundle.CommonResponse, err error) {
|
||||
res = new(bundle.CommonResponse)
|
||||
|
||||
exist := new(model.FieePaymentAuto)
|
||||
// 查询未处理的数据
|
||||
err = app.ModuleClients.BundleDB.Model(&model.FieePaymentAuto{}).
|
||||
Where("id = ?", req.ID).
|
||||
First(&exist).Error
|
||||
if err != nil {
|
||||
return nil, errors.New("数据不存在")
|
||||
}
|
||||
|
||||
if err = app.ModuleClients.BundleDB.Where("id = ?", req.ID).
|
||||
Delete(&model.FieePaymentAuto{}).Error; err != nil {
|
||||
return res, errors.New("删除自动导入表数据失败")
|
||||
}
|
||||
|
||||
return res, nil
|
||||
}
|
||||
|
@ -161,3 +161,15 @@ func DeleteValueAddService(req *bundle.DeleteValueAddServiceRequest) (res *bundl
|
||||
res, err = dao.DeleteValueAddService(req)
|
||||
return
|
||||
}
|
||||
|
||||
func ListUnfinishedInfos(req *bundle.AutoCreateUserAndOrderRequest) (res *bundle.UnfinishedInfos, err error) {
|
||||
res = new(bundle.UnfinishedInfos)
|
||||
res, err = dao.ListUnfinishedInfos(req)
|
||||
return
|
||||
}
|
||||
|
||||
func SoftDeleteUnfinishedInfo(req *bundle.SoftDeleteUnfinishedInfoRequest) (res *bundle.CommonResponse, err error) {
|
||||
res = new(bundle.CommonResponse)
|
||||
res, err = dao.SoftDeleteUnfinishedInfo(req)
|
||||
return
|
||||
}
|
||||
|
29
internal/model/fiee_payment_auto.go
Normal file
29
internal/model/fiee_payment_auto.go
Normal file
@ -0,0 +1,29 @@
|
||||
package model
|
||||
|
||||
import (
|
||||
"gorm.io/gorm"
|
||||
"time"
|
||||
)
|
||||
|
||||
// 用来自动导入 来创建用户和订单的 数据
|
||||
type FieePaymentAuto struct {
|
||||
gorm.Model
|
||||
UserNum string `json:"userNum" gorm:"column:user_num;type:varchar(64);comment:用户编号"`
|
||||
UserName string `json:"userName" gorm:"column:user_name;type:varchar(128);comment:用户姓名"`
|
||||
UserTelArea string `json:"userTelArea" gorm:"column:user_tel_area;type:varchar(32);comment:用户手机号区号"`
|
||||
UserTel string `json:"userTel" gorm:"column:user_tel;type:varchar(32);comment:用户手机号"`
|
||||
UserSex string `json:"userSex" gorm:"column:user_sex;type:varchar(16);comment:用户性别"`
|
||||
Nationality string `json:"nationality" gorm:"column:nationality;type:varchar(128);comment:国籍"`
|
||||
PlaceOfResidence string `json:"placeOfResidence" gorm:"column:place_of_residence;type:varchar(512);comment:用户居住地"`
|
||||
DocumentType int `json:"documentType" gorm:"column:document_type;type:varchar(512);comment:证件类型:1护照 2身份证 3驾驶证 4居住证 5自拍照 6社保卡"`
|
||||
UserIdCardFrontUrl string `json:"userIdCardFrontUrl" gorm:"column:user_id_card_front_url;type:varchar(1024);comment:用户身份证正面"`
|
||||
UserIdCardReverseUrl string `json:"userIdCardReverseUrl" gorm:"column:user_id_card_reverse_url;type:varchar(1024);comment:用户身份证反面"`
|
||||
UserIdCardValidity string `json:"userIdCardValidity" gorm:"column:user_id_card_validity;type:varchar(64);comment:证件有效期"`
|
||||
OrderNo string `json:"orderNo" gorm:"column:order_no;type:varchar(128);comment:订单编号"`
|
||||
OrderPayAmount string `gorm:"column:order_pay_amount;type:decimal(20,2);comment:订单支付金额" json:"orderPayAmount"`
|
||||
OrderSettlementAmount string `gorm:"column:order_settlement_amount;type:decimal(20,2);comment:订单结算金额" json:"orderSettlementAmount"`
|
||||
OrderFeeAmount string `gorm:"column:order_fee_amount;type:decimal(20,2);comment:订单手续费金额" json:"orderFeeAmount"`
|
||||
OrderPayCurrency string `json:"orderPayCurrency" gorm:"column:order_pay_currency;type:varchar(16);comment:支付时的币种:cny人民币,usd美元"`
|
||||
OrderAccountCurrency string `json:"orderAccountCurrency" gorm:"column:order_account_currency;type:varchar(16);comment:账户上的币种: 暂时固定usd美元"`
|
||||
PayTime time.Time `gorm:"column:pay_time;type:datetime;default:null;comment:支付成功时间" json:"payTime"`
|
||||
}
|
@ -74,6 +74,10 @@ service Bundle {
|
||||
rpc CreateReconciliation(ReconciliationInfo) returns (CommonResponse) {} // 创建对账单
|
||||
rpc UpdateReconciliation(ReconciliationInfo) returns (CommonResponse) {} // 更新对账单
|
||||
rpc UpdateReconciliationStatusBySerialNumber(UpdateStatusAndPayTimeBySerialNumber) returns (CommonResponse) {} // 更新对账单
|
||||
|
||||
// 查出没处理的数据
|
||||
rpc ListUnfinishedInfos(AutoCreateUserAndOrderRequest) returns (UnfinishedInfos) {} // 查出没处理的数据
|
||||
rpc SoftDeleteUnfinishedInfo(SoftDeleteUnfinishedInfoRequest) returns (CommonResponse) {} // 软删除
|
||||
}
|
||||
message DeleteValueAddServiceRequest{
|
||||
string orderNo = 1;
|
||||
@ -830,4 +834,38 @@ message ConfirmWorkReq{
|
||||
|
||||
message ConfirmWorkResp{
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
message AutoCreateUserAndOrderRequest {
|
||||
int32 num = 1; // 处理数量
|
||||
}
|
||||
|
||||
message UnfinishedInfos {
|
||||
repeated UnfinishedInfo unfinishedInfos = 1;
|
||||
}
|
||||
|
||||
message UnfinishedInfo {
|
||||
uint32 ID = 1;
|
||||
string userNum = 2;
|
||||
string userName = 3;
|
||||
string userTelArea = 4;
|
||||
string userTel = 5;
|
||||
string userSex = 6;
|
||||
string nationality = 7;
|
||||
string placeOfResidence = 8;
|
||||
int32 documentType = 9;
|
||||
string userIdCardFrontUrl = 10;
|
||||
string userIdCardReverseUrl = 11;
|
||||
string userIdCardValidity = 12;
|
||||
string orderNo = 13;
|
||||
string orderPayAmount = 14;
|
||||
string orderSettlementAmount = 15;
|
||||
string orderFeeAmount = 16;
|
||||
string orderPayCurrency = 17;
|
||||
string orderAccountCurrency = 18;
|
||||
string payTime = 19;
|
||||
}
|
||||
|
||||
message SoftDeleteUnfinishedInfoRequest {
|
||||
uint32 ID = 1;
|
||||
}
|
||||
|
File diff suppressed because it is too large
Load Diff
@ -5,11 +5,11 @@ package bundle
|
||||
|
||||
import (
|
||||
fmt "fmt"
|
||||
math "math"
|
||||
proto "github.com/golang/protobuf/proto"
|
||||
_ "github.com/mwitkow/go-proto-validators"
|
||||
_ "google.golang.org/protobuf/types/descriptorpb"
|
||||
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.
|
||||
@ -447,3 +447,22 @@ func (this *ConfirmWorkReq) Validate() error {
|
||||
func (this *ConfirmWorkResp) Validate() error {
|
||||
return nil
|
||||
}
|
||||
func (this *AutoCreateUserAndOrderRequest) Validate() error {
|
||||
return nil
|
||||
}
|
||||
func (this *UnfinishedInfos) Validate() error {
|
||||
for _, item := range this.UnfinishedInfos {
|
||||
if item != nil {
|
||||
if err := github_com_mwitkow_go_proto_validators.CallValidatorIfExists(item); err != nil {
|
||||
return github_com_mwitkow_go_proto_validators.FieldError("UnfinishedInfos", err)
|
||||
}
|
||||
}
|
||||
}
|
||||
return nil
|
||||
}
|
||||
func (this *UnfinishedInfo) Validate() error {
|
||||
return nil
|
||||
}
|
||||
func (this *SoftDeleteUnfinishedInfoRequest) Validate() error {
|
||||
return nil
|
||||
}
|
||||
|
@ -1,7 +1,7 @@
|
||||
// Code generated by protoc-gen-go-triple. DO NOT EDIT.
|
||||
// versions:
|
||||
// - protoc-gen-go-triple v1.0.8
|
||||
// - protoc v4.24.0--rc1
|
||||
// - protoc v5.26.1
|
||||
// source: pb/bundle.proto
|
||||
|
||||
package bundle
|
||||
@ -50,11 +50,11 @@ type BundleClient interface {
|
||||
OrderRecordsListV2(ctx context.Context, in *OrderRecordsRequestV2, opts ...grpc_go.CallOption) (*OrderRecordsResponseV2, common.ErrorWithAttachment)
|
||||
OrderListByOrderNo(ctx context.Context, in *OrderInfoByOrderNoRequest, opts ...grpc_go.CallOption) (*OrderInfoByOrderNoResp, common.ErrorWithAttachment)
|
||||
OnlyAddValueListByOrderNo(ctx context.Context, in *OnlyAddValueListByOrderNoRequest, opts ...grpc_go.CallOption) (*OnlyAddValueListByOrderNoResp, common.ErrorWithAttachment)
|
||||
//增值套餐
|
||||
// 增值套餐
|
||||
CreateValueAddBundle(ctx context.Context, in *CreateValueAddBundleRequest, opts ...grpc_go.CallOption) (*CreateValueAddBundleResponse, common.ErrorWithAttachment)
|
||||
ValueAddBundleList(ctx context.Context, in *ValueAddBundleListRequest, opts ...grpc_go.CallOption) (*ValueAddBundleListResponse, common.ErrorWithAttachment)
|
||||
ValueAddBundleDetail(ctx context.Context, in *ValueAddBundleDetailRequest, opts ...grpc_go.CallOption) (*ValueAddBundleDetailResponse, common.ErrorWithAttachment)
|
||||
//新增值服务
|
||||
// 新增值服务
|
||||
SaveValueAddService(ctx context.Context, in *ValueAddServiceLang, opts ...grpc_go.CallOption) (*SaveResponse, common.ErrorWithAttachment)
|
||||
ValueAddServiceList(ctx context.Context, in *ValueAddServiceListRequest, opts ...grpc_go.CallOption) (*ValueAddServiceListResponse, common.ErrorWithAttachment)
|
||||
ValueAddServiceDetail(ctx context.Context, in *ValueAddServiceDetailRequest, opts ...grpc_go.CallOption) (*ValueAddServiceDetailResponse, common.ErrorWithAttachment)
|
||||
@ -75,11 +75,14 @@ type BundleClient interface {
|
||||
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)
|
||||
UpdateReconciliation(ctx context.Context, in *ReconciliationInfo, opts ...grpc_go.CallOption) (*CommonResponse, common.ErrorWithAttachment)
|
||||
UpdateReconciliationStatusBySerialNumber(ctx context.Context, in *UpdateStatusAndPayTimeBySerialNumber, opts ...grpc_go.CallOption) (*CommonResponse, common.ErrorWithAttachment)
|
||||
// 查出没处理的数据
|
||||
ListUnfinishedInfos(ctx context.Context, in *AutoCreateUserAndOrderRequest, opts ...grpc_go.CallOption) (*UnfinishedInfos, common.ErrorWithAttachment)
|
||||
SoftDeleteUnfinishedInfo(ctx context.Context, in *SoftDeleteUnfinishedInfoRequest, opts ...grpc_go.CallOption) (*CommonResponse, common.ErrorWithAttachment)
|
||||
}
|
||||
|
||||
type bundleClient struct {
|
||||
@ -134,6 +137,8 @@ type BundleClientImpl struct {
|
||||
CreateReconciliation func(ctx context.Context, in *ReconciliationInfo) (*CommonResponse, error)
|
||||
UpdateReconciliation func(ctx context.Context, in *ReconciliationInfo) (*CommonResponse, error)
|
||||
UpdateReconciliationStatusBySerialNumber func(ctx context.Context, in *UpdateStatusAndPayTimeBySerialNumber) (*CommonResponse, error)
|
||||
ListUnfinishedInfos func(ctx context.Context, in *AutoCreateUserAndOrderRequest) (*UnfinishedInfos, error)
|
||||
SoftDeleteUnfinishedInfo func(ctx context.Context, in *SoftDeleteUnfinishedInfoRequest) (*CommonResponse, error)
|
||||
}
|
||||
|
||||
func (c *BundleClientImpl) GetDubboStub(cc *triple.TripleConn) BundleClient {
|
||||
@ -430,6 +435,18 @@ func (c *bundleClient) UpdateReconciliationStatusBySerialNumber(ctx context.Cont
|
||||
return out, c.cc.Invoke(ctx, "/"+interfaceKey+"/UpdateReconciliationStatusBySerialNumber", in, out)
|
||||
}
|
||||
|
||||
func (c *bundleClient) ListUnfinishedInfos(ctx context.Context, in *AutoCreateUserAndOrderRequest, opts ...grpc_go.CallOption) (*UnfinishedInfos, common.ErrorWithAttachment) {
|
||||
out := new(UnfinishedInfos)
|
||||
interfaceKey := ctx.Value(constant.InterfaceKey).(string)
|
||||
return out, c.cc.Invoke(ctx, "/"+interfaceKey+"/ListUnfinishedInfos", in, out)
|
||||
}
|
||||
|
||||
func (c *bundleClient) SoftDeleteUnfinishedInfo(ctx context.Context, in *SoftDeleteUnfinishedInfoRequest, opts ...grpc_go.CallOption) (*CommonResponse, common.ErrorWithAttachment) {
|
||||
out := new(CommonResponse)
|
||||
interfaceKey := ctx.Value(constant.InterfaceKey).(string)
|
||||
return out, c.cc.Invoke(ctx, "/"+interfaceKey+"/SoftDeleteUnfinishedInfo", in, out)
|
||||
}
|
||||
|
||||
// BundleServer is the server API for Bundle service.
|
||||
// All implementations must embed UnimplementedBundleServer
|
||||
// for forward compatibility
|
||||
@ -456,11 +473,11 @@ type BundleServer interface {
|
||||
OrderRecordsListV2(context.Context, *OrderRecordsRequestV2) (*OrderRecordsResponseV2, error)
|
||||
OrderListByOrderNo(context.Context, *OrderInfoByOrderNoRequest) (*OrderInfoByOrderNoResp, error)
|
||||
OnlyAddValueListByOrderNo(context.Context, *OnlyAddValueListByOrderNoRequest) (*OnlyAddValueListByOrderNoResp, error)
|
||||
//增值套餐
|
||||
// 增值套餐
|
||||
CreateValueAddBundle(context.Context, *CreateValueAddBundleRequest) (*CreateValueAddBundleResponse, error)
|
||||
ValueAddBundleList(context.Context, *ValueAddBundleListRequest) (*ValueAddBundleListResponse, error)
|
||||
ValueAddBundleDetail(context.Context, *ValueAddBundleDetailRequest) (*ValueAddBundleDetailResponse, error)
|
||||
//新增值服务
|
||||
// 新增值服务
|
||||
SaveValueAddService(context.Context, *ValueAddServiceLang) (*SaveResponse, error)
|
||||
ValueAddServiceList(context.Context, *ValueAddServiceListRequest) (*ValueAddServiceListResponse, error)
|
||||
ValueAddServiceDetail(context.Context, *ValueAddServiceDetailRequest) (*ValueAddServiceDetailResponse, error)
|
||||
@ -481,11 +498,14 @@ type BundleServer interface {
|
||||
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)
|
||||
UpdateReconciliation(context.Context, *ReconciliationInfo) (*CommonResponse, error)
|
||||
UpdateReconciliationStatusBySerialNumber(context.Context, *UpdateStatusAndPayTimeBySerialNumber) (*CommonResponse, error)
|
||||
// 查出没处理的数据
|
||||
ListUnfinishedInfos(context.Context, *AutoCreateUserAndOrderRequest) (*UnfinishedInfos, error)
|
||||
SoftDeleteUnfinishedInfo(context.Context, *SoftDeleteUnfinishedInfoRequest) (*CommonResponse, error)
|
||||
mustEmbedUnimplementedBundleServer()
|
||||
}
|
||||
|
||||
@ -635,6 +655,12 @@ func (UnimplementedBundleServer) UpdateReconciliation(context.Context, *Reconcil
|
||||
func (UnimplementedBundleServer) UpdateReconciliationStatusBySerialNumber(context.Context, *UpdateStatusAndPayTimeBySerialNumber) (*CommonResponse, error) {
|
||||
return nil, status.Errorf(codes.Unimplemented, "method UpdateReconciliationStatusBySerialNumber not implemented")
|
||||
}
|
||||
func (UnimplementedBundleServer) ListUnfinishedInfos(context.Context, *AutoCreateUserAndOrderRequest) (*UnfinishedInfos, error) {
|
||||
return nil, status.Errorf(codes.Unimplemented, "method ListUnfinishedInfos not implemented")
|
||||
}
|
||||
func (UnimplementedBundleServer) SoftDeleteUnfinishedInfo(context.Context, *SoftDeleteUnfinishedInfoRequest) (*CommonResponse, error) {
|
||||
return nil, status.Errorf(codes.Unimplemented, "method SoftDeleteUnfinishedInfo not implemented")
|
||||
}
|
||||
func (s *UnimplementedBundleServer) XXX_SetProxyImpl(impl protocol.Invoker) {
|
||||
s.proxyImpl = impl
|
||||
}
|
||||
@ -2026,6 +2052,64 @@ func _Bundle_UpdateReconciliationStatusBySerialNumber_Handler(srv interface{}, c
|
||||
return interceptor(ctx, in, info, handler)
|
||||
}
|
||||
|
||||
func _Bundle_ListUnfinishedInfos_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc_go.UnaryServerInterceptor) (interface{}, error) {
|
||||
in := new(AutoCreateUserAndOrderRequest)
|
||||
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("ListUnfinishedInfos", 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_SoftDeleteUnfinishedInfo_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc_go.UnaryServerInterceptor) (interface{}, error) {
|
||||
in := new(SoftDeleteUnfinishedInfoRequest)
|
||||
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("SoftDeleteUnfinishedInfo", 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)
|
||||
}
|
||||
|
||||
// Bundle_ServiceDesc is the grpc_go.ServiceDesc for Bundle service.
|
||||
// It's only intended for direct use with grpc_go.RegisterService,
|
||||
// and not to be introspected or modified (even as a copy)
|
||||
@ -2221,6 +2305,14 @@ var Bundle_ServiceDesc = grpc_go.ServiceDesc{
|
||||
MethodName: "UpdateReconciliationStatusBySerialNumber",
|
||||
Handler: _Bundle_UpdateReconciliationStatusBySerialNumber_Handler,
|
||||
},
|
||||
{
|
||||
MethodName: "ListUnfinishedInfos",
|
||||
Handler: _Bundle_ListUnfinishedInfos_Handler,
|
||||
},
|
||||
{
|
||||
MethodName: "SoftDeleteUnfinishedInfo",
|
||||
Handler: _Bundle_SoftDeleteUnfinishedInfo_Handler,
|
||||
},
|
||||
},
|
||||
Streams: []grpc_go.StreamDesc{},
|
||||
Metadata: "pb/bundle.proto",
|
||||
|
Loading…
Reference in New Issue
Block a user