对账单增加接口
This commit is contained in:
parent
33c4db9cab
commit
e4e298d921
@ -20,3 +20,11 @@ func (c *ArtistInfoStatementProvider) StatementList(ctx context.Context, req *st
|
||||
}
|
||||
return rep, nil
|
||||
}
|
||||
|
||||
func (c *ArtistInfoStatementProvider) GetTxInfoByBatchUid(ctx context.Context, req *statement.GetTxInfoByBatchUidRequest) (rep *statement.GetTxInfoByBatchUidRespond, err error) {
|
||||
fmt.Println("第一处")
|
||||
if rep, err = c.statementLogic.GetTxInfoByBatchUid(req); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
return rep, nil
|
||||
}
|
||||
|
@ -39,3 +39,23 @@ func StatementList(artistUid string, state int32) (contractData []*statement.Con
|
||||
|
||||
return
|
||||
}
|
||||
|
||||
func GetArtistNameByBatchUid(batchUid string) (artworkTx model.ArtworkTx, err error) {
|
||||
if err = db.DB.Where("uid = ?", batchUid).Find(&artworkTx).Error; err != nil {
|
||||
zap.L().Error("get artworkTx info err", zap.Error(err))
|
||||
err = errors.New(m.ERROR_SELECT)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
}
|
||||
|
||||
func GetArtworkTxDetailByBatchUid(batchUid string) (artworkTxDetail []model.ArtworkTxDetail, err error) {
|
||||
if err = db.DB.Where("batch_uid = ?", batchUid).Find(&artworkTxDetail).Error; err != nil {
|
||||
zap.L().Error("get artworkTxDetail infos err", zap.Error(err))
|
||||
err = errors.New(m.ERROR_SELECT)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
}
|
||||
|
@ -9,6 +9,7 @@ import (
|
||||
|
||||
type IStatement interface {
|
||||
StatementList(req *statement.StatementListRequest) (rep *statement.StatementListRespond, err error)
|
||||
GetTxInfoByBatchUid(req *statement.GetTxInfoByBatchUidRequest) (rep *statement.GetTxInfoByBatchUidRespond, err error)
|
||||
}
|
||||
|
||||
func NewStatement() IStatement {
|
||||
@ -38,3 +39,34 @@ func (a *Statement) StatementList(req *statement.StatementListRequest) (rep *sta
|
||||
|
||||
return
|
||||
}
|
||||
|
||||
func (a *Statement) GetTxInfoByBatchUid(req *statement.GetTxInfoByBatchUidRequest) (rep *statement.GetTxInfoByBatchUidRespond, err error) {
|
||||
|
||||
rep = &statement.GetTxInfoByBatchUidRespond{}
|
||||
|
||||
//获取画家名
|
||||
artworkTx, err := dao.GetArtistNameByBatchUid(req.BatchUid)
|
||||
if err != nil {
|
||||
return
|
||||
}
|
||||
rep.ArtistName = artworkTx.ArtistName
|
||||
|
||||
//获取物权画作详细信息
|
||||
artworkTxDetails, err := dao.GetArtworkTxDetailByBatchUid(req.BatchUid)
|
||||
|
||||
artworkTxDetail := new(statement.ArtworkTxDetail)
|
||||
|
||||
for _, v := range artworkTxDetails {
|
||||
artworkTxDetail.TfNum = v.TfNum
|
||||
artworkTxDetail.ArtworkName = v.ArtworkName
|
||||
artworkTxDetail.Ruler = v.Ruler
|
||||
artworkTxDetail.SaleNo = v.SaleNo
|
||||
artworkTxDetail.CompleteDate = v.CompleteDate
|
||||
artworkTxDetail.MinPrice = v.MinPrice
|
||||
artworkTxDetail.SalePrice = v.SalePrice
|
||||
artworkTxDetail.GuaranteePrice = v.GuaranteePrice
|
||||
rep.ArtworkTxDetail = append(rep.ArtworkTxDetail, artworkTxDetail)
|
||||
}
|
||||
|
||||
return
|
||||
}
|
||||
|
@ -4,58 +4,25 @@ import "gorm.io/plugin/soft_delete"
|
||||
|
||||
// Contract 用户模型
|
||||
type Contract struct {
|
||||
ID int32 `gorm:"column:id;type:int(11);primary_key;AUTO_INCREMENT" json:"id"`
|
||||
Uid string `gorm:"column:uid;type:varchar(100);comment:合同表的唯一表示;NOT NULL" json:"uid"`
|
||||
ArtistUid string `gorm:"column:artist_uid;type:varchar(100);comment:画家uid;NOT NULL" json:"artist_uid"`
|
||||
ArtworkUid string `gorm:"column:artwork_uid;type:varchar(1000);comment:画作uid" json:"artwork_uid"`
|
||||
ContractId string `gorm:"column:contract_id;type:varchar(300);comment:合同id" json:"contract_id"`
|
||||
TransactionId string `gorm:"column:transaction_id;type:varchar(300);comment:交易id" json:"transaction_id"`
|
||||
Type int32 `gorm:"column:type;type:int(1);comment:合同类型 (1);NOT NULL" json:"type"`
|
||||
ViewUrl string `gorm:"column:view_url;type:varchar(500);comment:在线查看合同链接" json:"view_url"`
|
||||
DownloadUrl string `gorm:"column:download_url;type:varchar(500);comment:合同下载链接" json:"download_url"`
|
||||
State int32 `gorm:"column:state;type:int(1);comment:合同状态,1:未签署2:已签署;NOT NULL" json:"state"` //1 未签署 2 已签署
|
||||
Status int32 `gorm:"column:status;default:2;comment:2=锁定 3=解锁" json:"status" ` //跟随用户的锁定和解锁状态,用于控制数据的展示
|
||||
LockTime string `gorm:"column:lock_time;comment:锁定时间" json:"lockTime"`
|
||||
SignTime string `gorm:"column:sign_time;comment:签署时间" json:"sign_time"`
|
||||
BatchName string `gorm:"column:batch_name;comment:批次名" json:"batch_name"`
|
||||
BatchUid string `gorm:"column:batch_uid;comment:批次ID" json:"batch_uid"`
|
||||
StType int32 `gorm:"column:st_type;unqiueIndex:sttype_uid_batchtime_idx;comment:对账单类型 1=版权 2=物权;"`
|
||||
ArtworkInfo []ArtworkTxDetail `gorm:"foreignKey:BatchUid;references:BatchUid"` //当前批次的物权委托单详情
|
||||
CreatedAt int32 `gorm:"column:created_at;autoCreateTime"`
|
||||
UpdatedAt int32 `gorm:"column:updated_at;autoCreateTime"`
|
||||
DeletedAt soft_delete.DeletedAt
|
||||
}
|
||||
|
||||
//对账单画作物权
|
||||
type ArtworkTx struct {
|
||||
ID int32 `gorm:"column:id;type:int(11);primary_key;AUTO_INCREMENT" json:"id"`
|
||||
Uid string `gorm:"column:uid;type:varchar(100);comment:对账单画作物权表的唯一表示,即批次BatchUid;NOT NULL" json:"uid"`
|
||||
ArtistUid string `gorm:"column:artist_uid;type:varchar(100);comment:画家Uid;NOT NULL" json:"artist_uid"`
|
||||
ArtistName string `gorm:"column:artist_name;type:varchar(100);comment:画家名;NOT NULL" json:"artist_name"`
|
||||
BatchName string `gorm:"column:batch_name;comment:批次名" json:"batch_name"`
|
||||
CreatedAt int32 `gorm:"column:created_at;autoCreateTime"`
|
||||
UpdatedAt int32 `gorm:"column:updated_at;autoCreateTime"`
|
||||
DeletedAt soft_delete.DeletedAt
|
||||
}
|
||||
|
||||
// 对账单画作物权委托详情
|
||||
type ArtworkTxDetail struct {
|
||||
ID int32 `gorm:"column:id;type:int(11);primary_key;AUTO_INCREMENT" json:"id"`
|
||||
Uid string `gorm:"column:uid;type:varchar(100);comment:对账单画作物权详情表的唯一表示;NOT NULL" json:"uid"`
|
||||
BatchUid string `gorm:"column:batch_uid;type:varchar(100);comment:对账单画作物权表的唯一表示,即批次BatchUid;NOT NULL" json:"batch_uid"`
|
||||
TfNum string `gorm:"column:tf_num;unqiueIndex:batchid_tfnum_idx;comment:"泰丰画作编号"`
|
||||
ArtworkName string `gorm:"column:artwork_name;comment:画作名称"`
|
||||
Ruler string `gorm:"column:ruler;comment:平尺"`
|
||||
SaleNo string `gorm:"column:sale_no;comment:销售单号"`
|
||||
CompleteDate string `gorm:"column:complete_date;comment:成交日期"`
|
||||
MinPrice float32 `gorm:"column:min_price;comment:委托销售底价"`
|
||||
SalePrice float32 `gorm:"column:sale_price;comment:画作售价"`
|
||||
GuaranteePrice float32 `gorm:"column:guarantee_price;comment:已收取保证金;"`
|
||||
CreatedAt int32 `gorm:"column:created_at;autoCreateTime"`
|
||||
UpdatedAt int32 `gorm:"column:updated_at;autoCreateTime"`
|
||||
DeletedAt soft_delete.DeletedAt
|
||||
}
|
||||
|
||||
func (ArtworkTxDetail) TableName() string {
|
||||
return "artwork_tx_detail"
|
||||
ID int32 `gorm:"column:id;type:int(11);primary_key;AUTO_INCREMENT" json:"id"`
|
||||
Uid string `gorm:"column:uid;type:varchar(100);comment:合同表的唯一表示;NOT NULL" json:"uid"`
|
||||
ArtistUid string `gorm:"column:artist_uid;type:varchar(100);comment:画家uid;NOT NULL" json:"artist_uid"`
|
||||
ArtworkUid string `gorm:"column:artwork_uid;type:varchar(1000);comment:画作uid" json:"artwork_uid"`
|
||||
ContractId string `gorm:"column:contract_id;type:varchar(300);comment:合同id" json:"contract_id"`
|
||||
TransactionId string `gorm:"column:transaction_id;type:varchar(300);comment:交易id" json:"transaction_id"`
|
||||
Type int32 `gorm:"column:type;type:int(1);comment:合同类型 (1);NOT NULL" json:"type"`
|
||||
ViewUrl string `gorm:"column:view_url;type:varchar(500);comment:在线查看合同链接" json:"view_url"`
|
||||
DownloadUrl string `gorm:"column:download_url;type:varchar(500);comment:合同下载链接" json:"download_url"`
|
||||
State int32 `gorm:"column:state;type:int(1);comment:合同状态,1:未签署2:已签署;NOT NULL" json:"state"` //1 未签署 2 已签署
|
||||
Status int32 `gorm:"column:status;default:2;comment:2=锁定 3=解锁" json:"status" ` //跟随用户的锁定和解锁状态,用于控制数据的展示
|
||||
LockTime string `gorm:"column:lock_time;comment:锁定时间" json:"lockTime"`
|
||||
SignTime string `gorm:"column:sign_time;comment:签署时间" json:"sign_time"`
|
||||
BatchName string `gorm:"column:batch_name;comment:批次名" json:"batch_name"`
|
||||
BatchUid string `gorm:"column:batch_uid;comment:批次ID" json:"batch_uid"`
|
||||
StType int32 `gorm:"column:st_type;unqiueIndex:sttype_uid_batchtime_idx;comment:对账单类型 1=版权 2=物权;"`
|
||||
ArtworkTx *ArtworkTx `gorm:"foreignKey:BatchUid;references:Uid"` //当前批次的物权委托单
|
||||
ArtworkTxDetail []ArtworkTxDetail `gorm:"foreignKey:BatchUid;references:BatchUid"` //当前批次的物权委托单详情
|
||||
CreatedAt int32 `gorm:"column:created_at;autoCreateTime"`
|
||||
UpdatedAt int32 `gorm:"column:updated_at;autoCreateTime"`
|
||||
DeletedAt soft_delete.DeletedAt
|
||||
}
|
||||
|
37
cmd/model/statement.go
Normal file
37
cmd/model/statement.go
Normal file
@ -0,0 +1,37 @@
|
||||
package model
|
||||
|
||||
import "gorm.io/plugin/soft_delete"
|
||||
|
||||
//对账单画作物权
|
||||
type ArtworkTx struct {
|
||||
ID int32 `gorm:"column:id;type:int(11);primary_key;AUTO_INCREMENT" json:"id"`
|
||||
Uid string `gorm:"column:uid;type:varchar(100);comment:对账单画作物权表的唯一表示,即批次BatchUid;NOT NULL" json:"uid"`
|
||||
ArtistUid string `gorm:"column:artist_uid;type:varchar(100);comment:画家Uid;NOT NULL" json:"artist_uid"`
|
||||
ArtistName string `gorm:"column:artist_name;type:varchar(100);comment:画家名;NOT NULL" json:"artist_name"`
|
||||
BatchName string `gorm:"column:batch_name;comment:批次名" json:"batch_name"`
|
||||
CreatedAt int32 `gorm:"column:created_at;autoCreateTime"`
|
||||
UpdatedAt int32 `gorm:"column:updated_at;autoCreateTime"`
|
||||
DeletedAt soft_delete.DeletedAt
|
||||
}
|
||||
|
||||
// 对账单画作物权委托详情
|
||||
type ArtworkTxDetail struct {
|
||||
ID int32 `gorm:"column:id;type:int(11);primary_key;AUTO_INCREMENT" json:"id"`
|
||||
Uid string `gorm:"column:uid;type:varchar(100);comment:对账单画作物权详情表的唯一表示;NOT NULL" json:"uid"`
|
||||
BatchUid string `gorm:"column:batch_uid;type:varchar(100);comment:对账单画作物权表的唯一表示,即批次BatchUid;NOT NULL" json:"batch_uid"`
|
||||
TfNum string `gorm:"column:tf_num;unqiueIndex:batchid_tfnum_idx;comment:"泰丰画作编号"`
|
||||
ArtworkName string `gorm:"column:artwork_name;comment:画作名称"`
|
||||
Ruler string `gorm:"column:ruler;comment:平尺"`
|
||||
SaleNo string `gorm:"column:sale_no;comment:销售单号"`
|
||||
CompleteDate string `gorm:"column:complete_date;comment:成交日期"`
|
||||
MinPrice float32 `gorm:"column:min_price;comment:委托销售底价"`
|
||||
SalePrice float32 `gorm:"column:sale_price;comment:画作售价"`
|
||||
GuaranteePrice float32 `gorm:"column:guarantee_price;comment:已收取保证金;"`
|
||||
CreatedAt int32 `gorm:"column:created_at;autoCreateTime"`
|
||||
UpdatedAt int32 `gorm:"column:updated_at;autoCreateTime"`
|
||||
DeletedAt soft_delete.DeletedAt
|
||||
}
|
||||
|
||||
func (ArtworkTxDetail) TableName() string {
|
||||
return "artwork_tx_detail"
|
||||
}
|
@ -38,6 +38,9 @@ type Contracts struct {
|
||||
ExpirationTime string `protobuf:"bytes,11,opt,name=ExpirationTime,json=expiration_time,proto3" json:"ExpirationTime,omitempty"`
|
||||
LockTime string `protobuf:"bytes,12,opt,name=LockTime,json=lock_time,proto3" json:"LockTime,omitempty"`
|
||||
SignTime string `protobuf:"bytes,13,opt,name=SignTime,json=sign_time,proto3" json:"SignTime,omitempty"`
|
||||
BatchName string `protobuf:"bytes,14,opt,name=BatchName,json=batch_name,proto3" json:"BatchName,omitempty"`
|
||||
BatchUid string `protobuf:"bytes,15,opt,name=BatchUid,json=batch_uid,proto3" json:"BatchUid,omitempty"`
|
||||
ArtistName string `protobuf:"bytes,16,opt,name=ArtistName,json=artist_name,proto3" json:"ArtistName,omitempty"`
|
||||
}
|
||||
|
||||
func (x *Contracts) Reset() {
|
||||
@ -163,6 +166,138 @@ func (x *Contracts) GetSignTime() string {
|
||||
return ""
|
||||
}
|
||||
|
||||
func (x *Contracts) GetBatchName() string {
|
||||
if x != nil {
|
||||
return x.BatchName
|
||||
}
|
||||
return ""
|
||||
}
|
||||
|
||||
func (x *Contracts) GetBatchUid() string {
|
||||
if x != nil {
|
||||
return x.BatchUid
|
||||
}
|
||||
return ""
|
||||
}
|
||||
|
||||
func (x *Contracts) GetArtistName() string {
|
||||
if x != nil {
|
||||
return x.ArtistName
|
||||
}
|
||||
return ""
|
||||
}
|
||||
|
||||
type ArtworkTxDetail struct {
|
||||
state protoimpl.MessageState
|
||||
sizeCache protoimpl.SizeCache
|
||||
unknownFields protoimpl.UnknownFields
|
||||
|
||||
BatchUid string `protobuf:"bytes,1,opt,name=BatchUid,json=batch_uid,proto3" json:"BatchUid,omitempty"`
|
||||
TfNum string `protobuf:"bytes,2,opt,name=TfNum,proto3" json:"TfNum,omitempty"`
|
||||
ArtworkName string `protobuf:"bytes,3,opt,name=ArtworkName,json=artwork_name,proto3" json:"ArtworkName,omitempty"`
|
||||
Ruler string `protobuf:"bytes,4,opt,name=Ruler,json=ruler,proto3" json:"Ruler,omitempty"`
|
||||
SaleNo string `protobuf:"bytes,5,opt,name=SaleNo,json=sale_no,proto3" json:"SaleNo,omitempty"`
|
||||
CompleteDate string `protobuf:"bytes,6,opt,name=CompleteDate,json=complete_date,proto3" json:"CompleteDate,omitempty"`
|
||||
MinPrice float32 `protobuf:"fixed32,7,opt,name=MinPrice,json=min_price,proto3" json:"MinPrice,omitempty"`
|
||||
SalePrice float32 `protobuf:"fixed32,8,opt,name=SalePrice,json=sale_price,proto3" json:"SalePrice,omitempty"`
|
||||
GuaranteePrice float32 `protobuf:"fixed32,9,opt,name=GuaranteePrice,json=guarantee_price,proto3" json:"GuaranteePrice,omitempty"`
|
||||
}
|
||||
|
||||
func (x *ArtworkTxDetail) Reset() {
|
||||
*x = ArtworkTxDetail{}
|
||||
if protoimpl.UnsafeEnabled {
|
||||
mi := &file_statement_proto_msgTypes[1]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
}
|
||||
|
||||
func (x *ArtworkTxDetail) String() string {
|
||||
return protoimpl.X.MessageStringOf(x)
|
||||
}
|
||||
|
||||
func (*ArtworkTxDetail) ProtoMessage() {}
|
||||
|
||||
func (x *ArtworkTxDetail) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_statement_proto_msgTypes[1]
|
||||
if protoimpl.UnsafeEnabled && x != nil {
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
if ms.LoadMessageInfo() == nil {
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
return ms
|
||||
}
|
||||
return mi.MessageOf(x)
|
||||
}
|
||||
|
||||
// Deprecated: Use ArtworkTxDetail.ProtoReflect.Descriptor instead.
|
||||
func (*ArtworkTxDetail) Descriptor() ([]byte, []int) {
|
||||
return file_statement_proto_rawDescGZIP(), []int{1}
|
||||
}
|
||||
|
||||
func (x *ArtworkTxDetail) GetBatchUid() string {
|
||||
if x != nil {
|
||||
return x.BatchUid
|
||||
}
|
||||
return ""
|
||||
}
|
||||
|
||||
func (x *ArtworkTxDetail) GetTfNum() string {
|
||||
if x != nil {
|
||||
return x.TfNum
|
||||
}
|
||||
return ""
|
||||
}
|
||||
|
||||
func (x *ArtworkTxDetail) GetArtworkName() string {
|
||||
if x != nil {
|
||||
return x.ArtworkName
|
||||
}
|
||||
return ""
|
||||
}
|
||||
|
||||
func (x *ArtworkTxDetail) GetRuler() string {
|
||||
if x != nil {
|
||||
return x.Ruler
|
||||
}
|
||||
return ""
|
||||
}
|
||||
|
||||
func (x *ArtworkTxDetail) GetSaleNo() string {
|
||||
if x != nil {
|
||||
return x.SaleNo
|
||||
}
|
||||
return ""
|
||||
}
|
||||
|
||||
func (x *ArtworkTxDetail) GetCompleteDate() string {
|
||||
if x != nil {
|
||||
return x.CompleteDate
|
||||
}
|
||||
return ""
|
||||
}
|
||||
|
||||
func (x *ArtworkTxDetail) GetMinPrice() float32 {
|
||||
if x != nil {
|
||||
return x.MinPrice
|
||||
}
|
||||
return 0
|
||||
}
|
||||
|
||||
func (x *ArtworkTxDetail) GetSalePrice() float32 {
|
||||
if x != nil {
|
||||
return x.SalePrice
|
||||
}
|
||||
return 0
|
||||
}
|
||||
|
||||
func (x *ArtworkTxDetail) GetGuaranteePrice() float32 {
|
||||
if x != nil {
|
||||
return x.GuaranteePrice
|
||||
}
|
||||
return 0
|
||||
}
|
||||
|
||||
type StatementListRequest struct {
|
||||
state protoimpl.MessageState
|
||||
sizeCache protoimpl.SizeCache
|
||||
@ -177,7 +312,7 @@ type StatementListRequest struct {
|
||||
func (x *StatementListRequest) Reset() {
|
||||
*x = StatementListRequest{}
|
||||
if protoimpl.UnsafeEnabled {
|
||||
mi := &file_statement_proto_msgTypes[1]
|
||||
mi := &file_statement_proto_msgTypes[2]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
@ -190,7 +325,7 @@ func (x *StatementListRequest) String() string {
|
||||
func (*StatementListRequest) ProtoMessage() {}
|
||||
|
||||
func (x *StatementListRequest) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_statement_proto_msgTypes[1]
|
||||
mi := &file_statement_proto_msgTypes[2]
|
||||
if protoimpl.UnsafeEnabled && x != nil {
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
if ms.LoadMessageInfo() == nil {
|
||||
@ -203,7 +338,7 @@ func (x *StatementListRequest) ProtoReflect() protoreflect.Message {
|
||||
|
||||
// Deprecated: Use StatementListRequest.ProtoReflect.Descriptor instead.
|
||||
func (*StatementListRequest) Descriptor() ([]byte, []int) {
|
||||
return file_statement_proto_rawDescGZIP(), []int{1}
|
||||
return file_statement_proto_rawDescGZIP(), []int{2}
|
||||
}
|
||||
|
||||
func (x *StatementListRequest) GetArtistUid() string {
|
||||
@ -246,7 +381,7 @@ type StatementListRespond struct {
|
||||
func (x *StatementListRespond) Reset() {
|
||||
*x = StatementListRespond{}
|
||||
if protoimpl.UnsafeEnabled {
|
||||
mi := &file_statement_proto_msgTypes[2]
|
||||
mi := &file_statement_proto_msgTypes[3]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
@ -259,7 +394,7 @@ func (x *StatementListRespond) String() string {
|
||||
func (*StatementListRespond) ProtoMessage() {}
|
||||
|
||||
func (x *StatementListRespond) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_statement_proto_msgTypes[2]
|
||||
mi := &file_statement_proto_msgTypes[3]
|
||||
if protoimpl.UnsafeEnabled && x != nil {
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
if ms.LoadMessageInfo() == nil {
|
||||
@ -272,7 +407,7 @@ func (x *StatementListRespond) ProtoReflect() protoreflect.Message {
|
||||
|
||||
// Deprecated: Use StatementListRespond.ProtoReflect.Descriptor instead.
|
||||
func (*StatementListRespond) Descriptor() ([]byte, []int) {
|
||||
return file_statement_proto_rawDescGZIP(), []int{2}
|
||||
return file_statement_proto_rawDescGZIP(), []int{3}
|
||||
}
|
||||
|
||||
func (x *StatementListRespond) GetData() []*Contracts {
|
||||
@ -289,11 +424,215 @@ func (x *StatementListRespond) GetMsg() string {
|
||||
return ""
|
||||
}
|
||||
|
||||
type CreateTxContractRequest struct {
|
||||
state protoimpl.MessageState
|
||||
sizeCache protoimpl.SizeCache
|
||||
unknownFields protoimpl.UnknownFields
|
||||
|
||||
BatchUid string `protobuf:"bytes,1,opt,name=BatchUid,json=batch_uid,proto3" json:"BatchUid,omitempty"`
|
||||
}
|
||||
|
||||
func (x *CreateTxContractRequest) Reset() {
|
||||
*x = CreateTxContractRequest{}
|
||||
if protoimpl.UnsafeEnabled {
|
||||
mi := &file_statement_proto_msgTypes[4]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
}
|
||||
|
||||
func (x *CreateTxContractRequest) String() string {
|
||||
return protoimpl.X.MessageStringOf(x)
|
||||
}
|
||||
|
||||
func (*CreateTxContractRequest) ProtoMessage() {}
|
||||
|
||||
func (x *CreateTxContractRequest) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_statement_proto_msgTypes[4]
|
||||
if protoimpl.UnsafeEnabled && x != nil {
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
if ms.LoadMessageInfo() == nil {
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
return ms
|
||||
}
|
||||
return mi.MessageOf(x)
|
||||
}
|
||||
|
||||
// Deprecated: Use CreateTxContractRequest.ProtoReflect.Descriptor instead.
|
||||
func (*CreateTxContractRequest) Descriptor() ([]byte, []int) {
|
||||
return file_statement_proto_rawDescGZIP(), []int{4}
|
||||
}
|
||||
|
||||
func (x *CreateTxContractRequest) GetBatchUid() string {
|
||||
if x != nil {
|
||||
return x.BatchUid
|
||||
}
|
||||
return ""
|
||||
}
|
||||
|
||||
type CreateTxContractRespond struct {
|
||||
state protoimpl.MessageState
|
||||
sizeCache protoimpl.SizeCache
|
||||
unknownFields protoimpl.UnknownFields
|
||||
|
||||
Msg string `protobuf:"bytes,1,opt,name=Msg,json=msg,proto3" json:"Msg,omitempty"`
|
||||
}
|
||||
|
||||
func (x *CreateTxContractRespond) Reset() {
|
||||
*x = CreateTxContractRespond{}
|
||||
if protoimpl.UnsafeEnabled {
|
||||
mi := &file_statement_proto_msgTypes[5]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
}
|
||||
|
||||
func (x *CreateTxContractRespond) String() string {
|
||||
return protoimpl.X.MessageStringOf(x)
|
||||
}
|
||||
|
||||
func (*CreateTxContractRespond) ProtoMessage() {}
|
||||
|
||||
func (x *CreateTxContractRespond) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_statement_proto_msgTypes[5]
|
||||
if protoimpl.UnsafeEnabled && x != nil {
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
if ms.LoadMessageInfo() == nil {
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
return ms
|
||||
}
|
||||
return mi.MessageOf(x)
|
||||
}
|
||||
|
||||
// Deprecated: Use CreateTxContractRespond.ProtoReflect.Descriptor instead.
|
||||
func (*CreateTxContractRespond) Descriptor() ([]byte, []int) {
|
||||
return file_statement_proto_rawDescGZIP(), []int{5}
|
||||
}
|
||||
|
||||
func (x *CreateTxContractRespond) GetMsg() string {
|
||||
if x != nil {
|
||||
return x.Msg
|
||||
}
|
||||
return ""
|
||||
}
|
||||
|
||||
type GetTxInfoByBatchUidRequest struct {
|
||||
state protoimpl.MessageState
|
||||
sizeCache protoimpl.SizeCache
|
||||
unknownFields protoimpl.UnknownFields
|
||||
|
||||
BatchUid string `protobuf:"bytes,1,opt,name=BatchUid,json=batch_uid,proto3" json:"BatchUid,omitempty"`
|
||||
}
|
||||
|
||||
func (x *GetTxInfoByBatchUidRequest) Reset() {
|
||||
*x = GetTxInfoByBatchUidRequest{}
|
||||
if protoimpl.UnsafeEnabled {
|
||||
mi := &file_statement_proto_msgTypes[6]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
}
|
||||
|
||||
func (x *GetTxInfoByBatchUidRequest) String() string {
|
||||
return protoimpl.X.MessageStringOf(x)
|
||||
}
|
||||
|
||||
func (*GetTxInfoByBatchUidRequest) ProtoMessage() {}
|
||||
|
||||
func (x *GetTxInfoByBatchUidRequest) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_statement_proto_msgTypes[6]
|
||||
if protoimpl.UnsafeEnabled && x != nil {
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
if ms.LoadMessageInfo() == nil {
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
return ms
|
||||
}
|
||||
return mi.MessageOf(x)
|
||||
}
|
||||
|
||||
// Deprecated: Use GetTxInfoByBatchUidRequest.ProtoReflect.Descriptor instead.
|
||||
func (*GetTxInfoByBatchUidRequest) Descriptor() ([]byte, []int) {
|
||||
return file_statement_proto_rawDescGZIP(), []int{6}
|
||||
}
|
||||
|
||||
func (x *GetTxInfoByBatchUidRequest) GetBatchUid() string {
|
||||
if x != nil {
|
||||
return x.BatchUid
|
||||
}
|
||||
return ""
|
||||
}
|
||||
|
||||
type GetTxInfoByBatchUidRespond struct {
|
||||
state protoimpl.MessageState
|
||||
sizeCache protoimpl.SizeCache
|
||||
unknownFields protoimpl.UnknownFields
|
||||
|
||||
ArtistName string `protobuf:"bytes,1,opt,name=ArtistName,json=artist_name,proto3" json:"ArtistName,omitempty"`
|
||||
ArtworkTxDetail []*ArtworkTxDetail `protobuf:"bytes,2,rep,name=ArtworkTxDetail,json=artwork_tx_detail,proto3" json:"ArtworkTxDetail,omitempty"`
|
||||
Msg string `protobuf:"bytes,3,opt,name=Msg,json=msg,proto3" json:"Msg,omitempty"`
|
||||
}
|
||||
|
||||
func (x *GetTxInfoByBatchUidRespond) Reset() {
|
||||
*x = GetTxInfoByBatchUidRespond{}
|
||||
if protoimpl.UnsafeEnabled {
|
||||
mi := &file_statement_proto_msgTypes[7]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
}
|
||||
|
||||
func (x *GetTxInfoByBatchUidRespond) String() string {
|
||||
return protoimpl.X.MessageStringOf(x)
|
||||
}
|
||||
|
||||
func (*GetTxInfoByBatchUidRespond) ProtoMessage() {}
|
||||
|
||||
func (x *GetTxInfoByBatchUidRespond) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_statement_proto_msgTypes[7]
|
||||
if protoimpl.UnsafeEnabled && x != nil {
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
if ms.LoadMessageInfo() == nil {
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
return ms
|
||||
}
|
||||
return mi.MessageOf(x)
|
||||
}
|
||||
|
||||
// Deprecated: Use GetTxInfoByBatchUidRespond.ProtoReflect.Descriptor instead.
|
||||
func (*GetTxInfoByBatchUidRespond) Descriptor() ([]byte, []int) {
|
||||
return file_statement_proto_rawDescGZIP(), []int{7}
|
||||
}
|
||||
|
||||
func (x *GetTxInfoByBatchUidRespond) GetArtistName() string {
|
||||
if x != nil {
|
||||
return x.ArtistName
|
||||
}
|
||||
return ""
|
||||
}
|
||||
|
||||
func (x *GetTxInfoByBatchUidRespond) GetArtworkTxDetail() []*ArtworkTxDetail {
|
||||
if x != nil {
|
||||
return x.ArtworkTxDetail
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
func (x *GetTxInfoByBatchUidRespond) GetMsg() string {
|
||||
if x != nil {
|
||||
return x.Msg
|
||||
}
|
||||
return ""
|
||||
}
|
||||
|
||||
var File_statement_proto protoreflect.FileDescriptor
|
||||
|
||||
var file_statement_proto_rawDesc = []byte{
|
||||
0x0a, 0x0f, 0x73, 0x74, 0x61, 0x74, 0x65, 0x6d, 0x65, 0x6e, 0x74, 0x2e, 0x70, 0x72, 0x6f, 0x74,
|
||||
0x6f, 0x12, 0x09, 0x73, 0x74, 0x61, 0x74, 0x65, 0x6d, 0x65, 0x6e, 0x74, 0x22, 0x99, 0x03, 0x0a,
|
||||
0x6f, 0x12, 0x09, 0x73, 0x74, 0x61, 0x74, 0x65, 0x6d, 0x65, 0x6e, 0x74, 0x22, 0xf6, 0x03, 0x0a,
|
||||
0x09, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x73, 0x12, 0x21, 0x0a, 0x0b, 0x43, 0x6f,
|
||||
0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x55, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52,
|
||||
0x0c, 0x63, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x5f, 0x75, 0x69, 0x64, 0x12, 0x1d, 0x0a,
|
||||
@ -319,7 +658,31 @@ var file_statement_proto_rawDesc = []byte{
|
||||
0x0a, 0x08, 0x4c, 0x6f, 0x63, 0x6b, 0x54, 0x69, 0x6d, 0x65, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x09,
|
||||
0x52, 0x09, 0x6c, 0x6f, 0x63, 0x6b, 0x5f, 0x74, 0x69, 0x6d, 0x65, 0x12, 0x1b, 0x0a, 0x08, 0x53,
|
||||
0x69, 0x67, 0x6e, 0x54, 0x69, 0x6d, 0x65, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x73,
|
||||
0x69, 0x67, 0x6e, 0x5f, 0x74, 0x69, 0x6d, 0x65, 0x22, 0x7b, 0x0a, 0x14, 0x53, 0x74, 0x61, 0x74,
|
||||
0x69, 0x67, 0x6e, 0x5f, 0x74, 0x69, 0x6d, 0x65, 0x12, 0x1d, 0x0a, 0x09, 0x42, 0x61, 0x74, 0x63,
|
||||
0x68, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x62, 0x61, 0x74,
|
||||
0x63, 0x68, 0x5f, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x1b, 0x0a, 0x08, 0x42, 0x61, 0x74, 0x63, 0x68,
|
||||
0x55, 0x69, 0x64, 0x18, 0x0f, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x62, 0x61, 0x74, 0x63, 0x68,
|
||||
0x5f, 0x75, 0x69, 0x64, 0x12, 0x1f, 0x0a, 0x0a, 0x41, 0x72, 0x74, 0x69, 0x73, 0x74, 0x4e, 0x61,
|
||||
0x6d, 0x65, 0x18, 0x10, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x61, 0x72, 0x74, 0x69, 0x73, 0x74,
|
||||
0x5f, 0x6e, 0x61, 0x6d, 0x65, 0x22, 0xa0, 0x02, 0x0a, 0x0f, 0x41, 0x72, 0x74, 0x77, 0x6f, 0x72,
|
||||
0x6b, 0x54, 0x78, 0x44, 0x65, 0x74, 0x61, 0x69, 0x6c, 0x12, 0x1b, 0x0a, 0x08, 0x42, 0x61, 0x74,
|
||||
0x63, 0x68, 0x55, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x62, 0x61, 0x74,
|
||||
0x63, 0x68, 0x5f, 0x75, 0x69, 0x64, 0x12, 0x14, 0x0a, 0x05, 0x54, 0x66, 0x4e, 0x75, 0x6d, 0x18,
|
||||
0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x54, 0x66, 0x4e, 0x75, 0x6d, 0x12, 0x21, 0x0a, 0x0b,
|
||||
0x41, 0x72, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28,
|
||||
0x09, 0x52, 0x0c, 0x61, 0x72, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x5f, 0x6e, 0x61, 0x6d, 0x65, 0x12,
|
||||
0x14, 0x0a, 0x05, 0x52, 0x75, 0x6c, 0x65, 0x72, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05,
|
||||
0x72, 0x75, 0x6c, 0x65, 0x72, 0x12, 0x17, 0x0a, 0x06, 0x53, 0x61, 0x6c, 0x65, 0x4e, 0x6f, 0x18,
|
||||
0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x73, 0x61, 0x6c, 0x65, 0x5f, 0x6e, 0x6f, 0x12, 0x23,
|
||||
0x0a, 0x0c, 0x43, 0x6f, 0x6d, 0x70, 0x6c, 0x65, 0x74, 0x65, 0x44, 0x61, 0x74, 0x65, 0x18, 0x06,
|
||||
0x20, 0x01, 0x28, 0x09, 0x52, 0x0d, 0x63, 0x6f, 0x6d, 0x70, 0x6c, 0x65, 0x74, 0x65, 0x5f, 0x64,
|
||||
0x61, 0x74, 0x65, 0x12, 0x1b, 0x0a, 0x08, 0x4d, 0x69, 0x6e, 0x50, 0x72, 0x69, 0x63, 0x65, 0x18,
|
||||
0x07, 0x20, 0x01, 0x28, 0x02, 0x52, 0x09, 0x6d, 0x69, 0x6e, 0x5f, 0x70, 0x72, 0x69, 0x63, 0x65,
|
||||
0x12, 0x1d, 0x0a, 0x09, 0x53, 0x61, 0x6c, 0x65, 0x50, 0x72, 0x69, 0x63, 0x65, 0x18, 0x08, 0x20,
|
||||
0x01, 0x28, 0x02, 0x52, 0x0a, 0x73, 0x61, 0x6c, 0x65, 0x5f, 0x70, 0x72, 0x69, 0x63, 0x65, 0x12,
|
||||
0x27, 0x0a, 0x0e, 0x47, 0x75, 0x61, 0x72, 0x61, 0x6e, 0x74, 0x65, 0x65, 0x50, 0x72, 0x69, 0x63,
|
||||
0x65, 0x18, 0x09, 0x20, 0x01, 0x28, 0x02, 0x52, 0x0f, 0x67, 0x75, 0x61, 0x72, 0x61, 0x6e, 0x74,
|
||||
0x65, 0x65, 0x5f, 0x70, 0x72, 0x69, 0x63, 0x65, 0x22, 0x7b, 0x0a, 0x14, 0x53, 0x74, 0x61, 0x74,
|
||||
0x65, 0x6d, 0x65, 0x6e, 0x74, 0x4c, 0x69, 0x73, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74,
|
||||
0x12, 0x1d, 0x0a, 0x09, 0x41, 0x72, 0x74, 0x69, 0x73, 0x74, 0x55, 0x69, 0x64, 0x18, 0x01, 0x20,
|
||||
0x01, 0x28, 0x09, 0x52, 0x0a, 0x61, 0x72, 0x74, 0x69, 0x73, 0x74, 0x5f, 0x75, 0x69, 0x64, 0x12,
|
||||
@ -332,13 +695,45 @@ var file_statement_proto_rawDesc = []byte{
|
||||
0x04, 0x44, 0x61, 0x74, 0x61, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x14, 0x2e, 0x73, 0x74,
|
||||
0x61, 0x74, 0x65, 0x6d, 0x65, 0x6e, 0x74, 0x2e, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74,
|
||||
0x73, 0x52, 0x04, 0x64, 0x61, 0x74, 0x61, 0x12, 0x10, 0x0a, 0x03, 0x4d, 0x73, 0x67, 0x18, 0x02,
|
||||
0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x6d, 0x73, 0x67, 0x32, 0x60, 0x0a, 0x09, 0x53, 0x74, 0x61,
|
||||
0x74, 0x65, 0x6d, 0x65, 0x6e, 0x74, 0x12, 0x53, 0x0a, 0x0d, 0x53, 0x74, 0x61, 0x74, 0x65, 0x6d,
|
||||
0x65, 0x6e, 0x74, 0x4c, 0x69, 0x73, 0x74, 0x12, 0x1f, 0x2e, 0x73, 0x74, 0x61, 0x74, 0x65, 0x6d,
|
||||
0x65, 0x6e, 0x74, 0x2e, 0x53, 0x74, 0x61, 0x74, 0x65, 0x6d, 0x65, 0x6e, 0x74, 0x4c, 0x69, 0x73,
|
||||
0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1f, 0x2e, 0x73, 0x74, 0x61, 0x74, 0x65,
|
||||
0x6d, 0x65, 0x6e, 0x74, 0x2e, 0x53, 0x74, 0x61, 0x74, 0x65, 0x6d, 0x65, 0x6e, 0x74, 0x4c, 0x69,
|
||||
0x73, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x64, 0x22, 0x00, 0x42, 0x0e, 0x5a, 0x0c, 0x2e,
|
||||
0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x6d, 0x73, 0x67, 0x22, 0x36, 0x0a, 0x17, 0x43, 0x72, 0x65,
|
||||
0x61, 0x74, 0x65, 0x54, 0x78, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x52, 0x65, 0x71,
|
||||
0x75, 0x65, 0x73, 0x74, 0x12, 0x1b, 0x0a, 0x08, 0x42, 0x61, 0x74, 0x63, 0x68, 0x55, 0x69, 0x64,
|
||||
0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x62, 0x61, 0x74, 0x63, 0x68, 0x5f, 0x75, 0x69,
|
||||
0x64, 0x22, 0x2b, 0x0a, 0x17, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x54, 0x78, 0x43, 0x6f, 0x6e,
|
||||
0x74, 0x72, 0x61, 0x63, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x64, 0x12, 0x10, 0x0a, 0x03,
|
||||
0x4d, 0x73, 0x67, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x6d, 0x73, 0x67, 0x22, 0x39,
|
||||
0x0a, 0x1a, 0x47, 0x65, 0x74, 0x54, 0x78, 0x49, 0x6e, 0x66, 0x6f, 0x42, 0x79, 0x42, 0x61, 0x74,
|
||||
0x63, 0x68, 0x55, 0x69, 0x64, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x1b, 0x0a, 0x08,
|
||||
0x42, 0x61, 0x74, 0x63, 0x68, 0x55, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09,
|
||||
0x62, 0x61, 0x74, 0x63, 0x68, 0x5f, 0x75, 0x69, 0x64, 0x22, 0x97, 0x01, 0x0a, 0x1a, 0x47, 0x65,
|
||||
0x74, 0x54, 0x78, 0x49, 0x6e, 0x66, 0x6f, 0x42, 0x79, 0x42, 0x61, 0x74, 0x63, 0x68, 0x55, 0x69,
|
||||
0x64, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x64, 0x12, 0x1f, 0x0a, 0x0a, 0x41, 0x72, 0x74, 0x69,
|
||||
0x73, 0x74, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x61, 0x72,
|
||||
0x74, 0x69, 0x73, 0x74, 0x5f, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x46, 0x0a, 0x0f, 0x41, 0x72, 0x74,
|
||||
0x77, 0x6f, 0x72, 0x6b, 0x54, 0x78, 0x44, 0x65, 0x74, 0x61, 0x69, 0x6c, 0x18, 0x02, 0x20, 0x03,
|
||||
0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x73, 0x74, 0x61, 0x74, 0x65, 0x6d, 0x65, 0x6e, 0x74, 0x2e, 0x41,
|
||||
0x72, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x54, 0x78, 0x44, 0x65, 0x74, 0x61, 0x69, 0x6c, 0x52, 0x11,
|
||||
0x61, 0x72, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x5f, 0x74, 0x78, 0x5f, 0x64, 0x65, 0x74, 0x61, 0x69,
|
||||
0x6c, 0x12, 0x10, 0x0a, 0x03, 0x4d, 0x73, 0x67, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03,
|
||||
0x6d, 0x73, 0x67, 0x32, 0xa5, 0x02, 0x0a, 0x09, 0x53, 0x74, 0x61, 0x74, 0x65, 0x6d, 0x65, 0x6e,
|
||||
0x74, 0x12, 0x53, 0x0a, 0x0d, 0x53, 0x74, 0x61, 0x74, 0x65, 0x6d, 0x65, 0x6e, 0x74, 0x4c, 0x69,
|
||||
0x73, 0x74, 0x12, 0x1f, 0x2e, 0x73, 0x74, 0x61, 0x74, 0x65, 0x6d, 0x65, 0x6e, 0x74, 0x2e, 0x53,
|
||||
0x74, 0x61, 0x74, 0x65, 0x6d, 0x65, 0x6e, 0x74, 0x4c, 0x69, 0x73, 0x74, 0x52, 0x65, 0x71, 0x75,
|
||||
0x65, 0x73, 0x74, 0x1a, 0x1f, 0x2e, 0x73, 0x74, 0x61, 0x74, 0x65, 0x6d, 0x65, 0x6e, 0x74, 0x2e,
|
||||
0x53, 0x74, 0x61, 0x74, 0x65, 0x6d, 0x65, 0x6e, 0x74, 0x4c, 0x69, 0x73, 0x74, 0x52, 0x65, 0x73,
|
||||
0x70, 0x6f, 0x6e, 0x64, 0x22, 0x00, 0x12, 0x5c, 0x0a, 0x10, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65,
|
||||
0x54, 0x78, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x12, 0x22, 0x2e, 0x73, 0x74, 0x61,
|
||||
0x74, 0x65, 0x6d, 0x65, 0x6e, 0x74, 0x2e, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x54, 0x78, 0x43,
|
||||
0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x22,
|
||||
0x2e, 0x73, 0x74, 0x61, 0x74, 0x65, 0x6d, 0x65, 0x6e, 0x74, 0x2e, 0x43, 0x72, 0x65, 0x61, 0x74,
|
||||
0x65, 0x54, 0x78, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f,
|
||||
0x6e, 0x64, 0x22, 0x00, 0x12, 0x65, 0x0a, 0x13, 0x47, 0x65, 0x74, 0x54, 0x78, 0x49, 0x6e, 0x66,
|
||||
0x6f, 0x42, 0x79, 0x42, 0x61, 0x74, 0x63, 0x68, 0x55, 0x69, 0x64, 0x12, 0x25, 0x2e, 0x73, 0x74,
|
||||
0x61, 0x74, 0x65, 0x6d, 0x65, 0x6e, 0x74, 0x2e, 0x47, 0x65, 0x74, 0x54, 0x78, 0x49, 0x6e, 0x66,
|
||||
0x6f, 0x42, 0x79, 0x42, 0x61, 0x74, 0x63, 0x68, 0x55, 0x69, 0x64, 0x52, 0x65, 0x71, 0x75, 0x65,
|
||||
0x73, 0x74, 0x1a, 0x25, 0x2e, 0x73, 0x74, 0x61, 0x74, 0x65, 0x6d, 0x65, 0x6e, 0x74, 0x2e, 0x47,
|
||||
0x65, 0x74, 0x54, 0x78, 0x49, 0x6e, 0x66, 0x6f, 0x42, 0x79, 0x42, 0x61, 0x74, 0x63, 0x68, 0x55,
|
||||
0x69, 0x64, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x64, 0x22, 0x00, 0x42, 0x0e, 0x5a, 0x0c, 0x2e,
|
||||
0x2f, 0x3b, 0x73, 0x74, 0x61, 0x74, 0x65, 0x6d, 0x65, 0x6e, 0x74, 0x62, 0x06, 0x70, 0x72, 0x6f,
|
||||
0x74, 0x6f, 0x33,
|
||||
}
|
||||
@ -355,21 +750,31 @@ func file_statement_proto_rawDescGZIP() []byte {
|
||||
return file_statement_proto_rawDescData
|
||||
}
|
||||
|
||||
var file_statement_proto_msgTypes = make([]protoimpl.MessageInfo, 3)
|
||||
var file_statement_proto_msgTypes = make([]protoimpl.MessageInfo, 8)
|
||||
var file_statement_proto_goTypes = []interface{}{
|
||||
(*Contracts)(nil), // 0: statement.Contracts
|
||||
(*StatementListRequest)(nil), // 1: statement.StatementListRequest
|
||||
(*StatementListRespond)(nil), // 2: statement.StatementListRespond
|
||||
(*Contracts)(nil), // 0: statement.Contracts
|
||||
(*ArtworkTxDetail)(nil), // 1: statement.ArtworkTxDetail
|
||||
(*StatementListRequest)(nil), // 2: statement.StatementListRequest
|
||||
(*StatementListRespond)(nil), // 3: statement.StatementListRespond
|
||||
(*CreateTxContractRequest)(nil), // 4: statement.CreateTxContractRequest
|
||||
(*CreateTxContractRespond)(nil), // 5: statement.CreateTxContractRespond
|
||||
(*GetTxInfoByBatchUidRequest)(nil), // 6: statement.GetTxInfoByBatchUidRequest
|
||||
(*GetTxInfoByBatchUidRespond)(nil), // 7: statement.GetTxInfoByBatchUidRespond
|
||||
}
|
||||
var file_statement_proto_depIdxs = []int32{
|
||||
0, // 0: statement.StatementListRespond.Data:type_name -> statement.Contracts
|
||||
1, // 1: statement.Statement.StatementList:input_type -> statement.StatementListRequest
|
||||
2, // 2: statement.Statement.StatementList:output_type -> statement.StatementListRespond
|
||||
2, // [2:3] is the sub-list for method output_type
|
||||
1, // [1:2] is the sub-list for method input_type
|
||||
1, // [1:1] is the sub-list for extension type_name
|
||||
1, // [1:1] is the sub-list for extension extendee
|
||||
0, // [0:1] is the sub-list for field type_name
|
||||
1, // 1: statement.GetTxInfoByBatchUidRespond.ArtworkTxDetail:type_name -> statement.ArtworkTxDetail
|
||||
2, // 2: statement.Statement.StatementList:input_type -> statement.StatementListRequest
|
||||
4, // 3: statement.Statement.CreateTxContract:input_type -> statement.CreateTxContractRequest
|
||||
6, // 4: statement.Statement.GetTxInfoByBatchUid:input_type -> statement.GetTxInfoByBatchUidRequest
|
||||
3, // 5: statement.Statement.StatementList:output_type -> statement.StatementListRespond
|
||||
5, // 6: statement.Statement.CreateTxContract:output_type -> statement.CreateTxContractRespond
|
||||
7, // 7: statement.Statement.GetTxInfoByBatchUid:output_type -> statement.GetTxInfoByBatchUidRespond
|
||||
5, // [5:8] is the sub-list for method output_type
|
||||
2, // [2:5] is the sub-list for method input_type
|
||||
2, // [2:2] is the sub-list for extension type_name
|
||||
2, // [2:2] is the sub-list for extension extendee
|
||||
0, // [0:2] is the sub-list for field type_name
|
||||
}
|
||||
|
||||
func init() { file_statement_proto_init() }
|
||||
@ -391,7 +796,7 @@ func file_statement_proto_init() {
|
||||
}
|
||||
}
|
||||
file_statement_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} {
|
||||
switch v := v.(*StatementListRequest); i {
|
||||
switch v := v.(*ArtworkTxDetail); i {
|
||||
case 0:
|
||||
return &v.state
|
||||
case 1:
|
||||
@ -403,6 +808,18 @@ func file_statement_proto_init() {
|
||||
}
|
||||
}
|
||||
file_statement_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} {
|
||||
switch v := v.(*StatementListRequest); i {
|
||||
case 0:
|
||||
return &v.state
|
||||
case 1:
|
||||
return &v.sizeCache
|
||||
case 2:
|
||||
return &v.unknownFields
|
||||
default:
|
||||
return nil
|
||||
}
|
||||
}
|
||||
file_statement_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} {
|
||||
switch v := v.(*StatementListRespond); i {
|
||||
case 0:
|
||||
return &v.state
|
||||
@ -414,6 +831,54 @@ func file_statement_proto_init() {
|
||||
return nil
|
||||
}
|
||||
}
|
||||
file_statement_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} {
|
||||
switch v := v.(*CreateTxContractRequest); i {
|
||||
case 0:
|
||||
return &v.state
|
||||
case 1:
|
||||
return &v.sizeCache
|
||||
case 2:
|
||||
return &v.unknownFields
|
||||
default:
|
||||
return nil
|
||||
}
|
||||
}
|
||||
file_statement_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} {
|
||||
switch v := v.(*CreateTxContractRespond); i {
|
||||
case 0:
|
||||
return &v.state
|
||||
case 1:
|
||||
return &v.sizeCache
|
||||
case 2:
|
||||
return &v.unknownFields
|
||||
default:
|
||||
return nil
|
||||
}
|
||||
}
|
||||
file_statement_proto_msgTypes[6].Exporter = func(v interface{}, i int) interface{} {
|
||||
switch v := v.(*GetTxInfoByBatchUidRequest); i {
|
||||
case 0:
|
||||
return &v.state
|
||||
case 1:
|
||||
return &v.sizeCache
|
||||
case 2:
|
||||
return &v.unknownFields
|
||||
default:
|
||||
return nil
|
||||
}
|
||||
}
|
||||
file_statement_proto_msgTypes[7].Exporter = func(v interface{}, i int) interface{} {
|
||||
switch v := v.(*GetTxInfoByBatchUidRespond); i {
|
||||
case 0:
|
||||
return &v.state
|
||||
case 1:
|
||||
return &v.sizeCache
|
||||
case 2:
|
||||
return &v.unknownFields
|
||||
default:
|
||||
return nil
|
||||
}
|
||||
}
|
||||
}
|
||||
type x struct{}
|
||||
out := protoimpl.TypeBuilder{
|
||||
@ -421,7 +886,7 @@ func file_statement_proto_init() {
|
||||
GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
|
||||
RawDescriptor: file_statement_proto_rawDesc,
|
||||
NumEnums: 0,
|
||||
NumMessages: 3,
|
||||
NumMessages: 8,
|
||||
NumExtensions: 0,
|
||||
NumServices: 1,
|
||||
},
|
||||
|
@ -4,6 +4,8 @@ option go_package = "./;statement";
|
||||
|
||||
service Statement {
|
||||
rpc StatementList (StatementListRequest) returns (StatementListRespond) {}
|
||||
rpc CreateTxContract (CreateTxContractRequest) returns (CreateTxContractRespond) {}
|
||||
rpc GetTxInfoByBatchUid (GetTxInfoByBatchUidRequest) returns (GetTxInfoByBatchUidRespond) {}
|
||||
}
|
||||
|
||||
message Contracts{
|
||||
@ -19,8 +21,22 @@ message Contracts{
|
||||
int32 Status = 10 [json_name = "status"];
|
||||
string ExpirationTime = 11 [json_name = "expiration_time"];
|
||||
string LockTime = 12 [json_name = "lock_time"];
|
||||
string SignTime = 13 [json_name = "sign_time"];
|
||||
|
||||
string SignTime = 13 [json_name = "sign_time"];
|
||||
string BatchName = 14 [json_name = "batch_name"];
|
||||
string BatchUid = 15 [json_name = "batch_uid"];
|
||||
string ArtistName = 16 [json_name = "artist_name"];
|
||||
}
|
||||
|
||||
message ArtworkTxDetail{
|
||||
string BatchUid = 1 [json_name = "batch_uid"];
|
||||
string TfNum = 2 [json_name = "TfNum"];
|
||||
string ArtworkName = 3 [json_name = "artwork_name"];
|
||||
string Ruler = 4 [json_name = "ruler"];
|
||||
string SaleNo = 5 [json_name = "sale_no"];
|
||||
string CompleteDate = 6 [json_name = "complete_date"];
|
||||
float MinPrice = 7 [json_name = "min_price"];
|
||||
float SalePrice = 8 [json_name = "sale_price"];
|
||||
float GuaranteePrice = 9 [json_name = "guarantee_price"];
|
||||
}
|
||||
|
||||
message StatementListRequest {
|
||||
@ -33,4 +49,22 @@ message StatementListRequest {
|
||||
message StatementListRespond {
|
||||
repeated Contracts Data = 1 [json_name = "data"];
|
||||
string Msg = 2 [json_name = "msg"];
|
||||
}
|
||||
|
||||
message CreateTxContractRequest {
|
||||
string BatchUid = 1 [json_name = "batch_uid"];
|
||||
}
|
||||
|
||||
message CreateTxContractRespond {
|
||||
string Msg = 1 [json_name = "msg"];
|
||||
}
|
||||
|
||||
message GetTxInfoByBatchUidRequest {
|
||||
string BatchUid = 1 [json_name = "batch_uid"];
|
||||
}
|
||||
|
||||
message GetTxInfoByBatchUidRespond {
|
||||
string ArtistName = 1 [json_name = "artist_name"];
|
||||
repeated ArtworkTxDetail ArtworkTxDetail = 2 [json_name = "artwork_tx_detail"];
|
||||
string Msg = 3 [json_name = "msg"];
|
||||
}
|
@ -18,6 +18,9 @@ var _ = math.Inf
|
||||
func (this *Contracts) Validate() error {
|
||||
return nil
|
||||
}
|
||||
func (this *ArtworkTxDetail) Validate() error {
|
||||
return nil
|
||||
}
|
||||
func (this *StatementListRequest) Validate() error {
|
||||
return nil
|
||||
}
|
||||
@ -31,3 +34,22 @@ func (this *StatementListRespond) Validate() error {
|
||||
}
|
||||
return nil
|
||||
}
|
||||
func (this *CreateTxContractRequest) Validate() error {
|
||||
return nil
|
||||
}
|
||||
func (this *CreateTxContractRespond) Validate() error {
|
||||
return nil
|
||||
}
|
||||
func (this *GetTxInfoByBatchUidRequest) Validate() error {
|
||||
return nil
|
||||
}
|
||||
func (this *GetTxInfoByBatchUidRespond) Validate() error {
|
||||
for _, item := range this.ArtworkTxDetail {
|
||||
if item != nil {
|
||||
if err := github_com_mwitkow_go_proto_validators.CallValidatorIfExists(item); err != nil {
|
||||
return github_com_mwitkow_go_proto_validators.FieldError("ArtworkTxDetail", err)
|
||||
}
|
||||
}
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
@ -29,6 +29,8 @@ const _ = grpc_go.SupportPackageIsVersion7
|
||||
// For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.
|
||||
type StatementClient interface {
|
||||
StatementList(ctx context.Context, in *StatementListRequest, opts ...grpc_go.CallOption) (*StatementListRespond, common.ErrorWithAttachment)
|
||||
CreateTxContract(ctx context.Context, in *CreateTxContractRequest, opts ...grpc_go.CallOption) (*CreateTxContractRespond, common.ErrorWithAttachment)
|
||||
GetTxInfoByBatchUid(ctx context.Context, in *GetTxInfoByBatchUidRequest, opts ...grpc_go.CallOption) (*GetTxInfoByBatchUidRespond, common.ErrorWithAttachment)
|
||||
}
|
||||
|
||||
type statementClient struct {
|
||||
@ -36,7 +38,9 @@ type statementClient struct {
|
||||
}
|
||||
|
||||
type StatementClientImpl struct {
|
||||
StatementList func(ctx context.Context, in *StatementListRequest) (*StatementListRespond, error)
|
||||
StatementList func(ctx context.Context, in *StatementListRequest) (*StatementListRespond, error)
|
||||
CreateTxContract func(ctx context.Context, in *CreateTxContractRequest) (*CreateTxContractRespond, error)
|
||||
GetTxInfoByBatchUid func(ctx context.Context, in *GetTxInfoByBatchUidRequest) (*GetTxInfoByBatchUidRespond, error)
|
||||
}
|
||||
|
||||
func (c *StatementClientImpl) GetDubboStub(cc *triple.TripleConn) StatementClient {
|
||||
@ -57,11 +61,25 @@ func (c *statementClient) StatementList(ctx context.Context, in *StatementListRe
|
||||
return out, c.cc.Invoke(ctx, "/"+interfaceKey+"/StatementList", in, out)
|
||||
}
|
||||
|
||||
func (c *statementClient) CreateTxContract(ctx context.Context, in *CreateTxContractRequest, opts ...grpc_go.CallOption) (*CreateTxContractRespond, common.ErrorWithAttachment) {
|
||||
out := new(CreateTxContractRespond)
|
||||
interfaceKey := ctx.Value(constant.InterfaceKey).(string)
|
||||
return out, c.cc.Invoke(ctx, "/"+interfaceKey+"/CreateTxContract", in, out)
|
||||
}
|
||||
|
||||
func (c *statementClient) GetTxInfoByBatchUid(ctx context.Context, in *GetTxInfoByBatchUidRequest, opts ...grpc_go.CallOption) (*GetTxInfoByBatchUidRespond, common.ErrorWithAttachment) {
|
||||
out := new(GetTxInfoByBatchUidRespond)
|
||||
interfaceKey := ctx.Value(constant.InterfaceKey).(string)
|
||||
return out, c.cc.Invoke(ctx, "/"+interfaceKey+"/GetTxInfoByBatchUid", in, out)
|
||||
}
|
||||
|
||||
// StatementServer is the server API for Statement service.
|
||||
// All implementations must embed UnimplementedStatementServer
|
||||
// for forward compatibility
|
||||
type StatementServer interface {
|
||||
StatementList(context.Context, *StatementListRequest) (*StatementListRespond, error)
|
||||
CreateTxContract(context.Context, *CreateTxContractRequest) (*CreateTxContractRespond, error)
|
||||
GetTxInfoByBatchUid(context.Context, *GetTxInfoByBatchUidRequest) (*GetTxInfoByBatchUidRespond, error)
|
||||
mustEmbedUnimplementedStatementServer()
|
||||
}
|
||||
|
||||
@ -73,6 +91,12 @@ type UnimplementedStatementServer struct {
|
||||
func (UnimplementedStatementServer) StatementList(context.Context, *StatementListRequest) (*StatementListRespond, error) {
|
||||
return nil, status.Errorf(codes.Unimplemented, "method StatementList not implemented")
|
||||
}
|
||||
func (UnimplementedStatementServer) CreateTxContract(context.Context, *CreateTxContractRequest) (*CreateTxContractRespond, error) {
|
||||
return nil, status.Errorf(codes.Unimplemented, "method CreateTxContract not implemented")
|
||||
}
|
||||
func (UnimplementedStatementServer) GetTxInfoByBatchUid(context.Context, *GetTxInfoByBatchUidRequest) (*GetTxInfoByBatchUidRespond, error) {
|
||||
return nil, status.Errorf(codes.Unimplemented, "method GetTxInfoByBatchUid not implemented")
|
||||
}
|
||||
func (s *UnimplementedStatementServer) XXX_SetProxyImpl(impl protocol.Invoker) {
|
||||
s.proxyImpl = impl
|
||||
}
|
||||
@ -130,6 +154,64 @@ func _Statement_StatementList_Handler(srv interface{}, ctx context.Context, dec
|
||||
return interceptor(ctx, in, info, handler)
|
||||
}
|
||||
|
||||
func _Statement_CreateTxContract_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc_go.UnaryServerInterceptor) (interface{}, error) {
|
||||
in := new(CreateTxContractRequest)
|
||||
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("CreateTxContract", 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 _Statement_GetTxInfoByBatchUid_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc_go.UnaryServerInterceptor) (interface{}, error) {
|
||||
in := new(GetTxInfoByBatchUidRequest)
|
||||
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("GetTxInfoByBatchUid", 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)
|
||||
}
|
||||
|
||||
// Statement_ServiceDesc is the grpc_go.ServiceDesc for Statement service.
|
||||
// It's only intended for direct use with grpc_go.RegisterService,
|
||||
// and not to be introspected or modified (even as a copy)
|
||||
@ -141,6 +223,14 @@ var Statement_ServiceDesc = grpc_go.ServiceDesc{
|
||||
MethodName: "StatementList",
|
||||
Handler: _Statement_StatementList_Handler,
|
||||
},
|
||||
{
|
||||
MethodName: "CreateTxContract",
|
||||
Handler: _Statement_CreateTxContract_Handler,
|
||||
},
|
||||
{
|
||||
MethodName: "GetTxInfoByBatchUid",
|
||||
Handler: _Statement_GetTxInfoByBatchUid_Handler,
|
||||
},
|
||||
},
|
||||
Streams: []grpc_go.StreamDesc{},
|
||||
Metadata: "statement.proto",
|
||||
|
Loading…
Reference in New Issue
Block a user