Compare commits

...

157 Commits

Author SHA1 Message Date
songchuang
354394d518 对账单代码测试修改 2023-04-18 16:00:10 +08:00
songchuang
b3ed666259 对账单代码测试修改 2023-04-18 15:21:06 +08:00
3822d5d404 Merge branch 'dev' of http://gitlab.fontree.cn/bugmaker/fonchain-artistinfo into dev 2023-04-18 15:11:25 +08:00
cd202e3485 Merge branch 'xjjdev' into dev 2023-04-18 15:11:17 +08:00
songchuang
1fdda25b00 对账单代码测试修改 2023-04-18 13:56:29 +08:00
songchuang
cf6e03365d 对账单测试 2023-04-18 11:06:57 +08:00
songchuang
f2bf3b0bdc 对账单配置文件修改 2023-04-18 10:28:54 +08:00
songchuang
4b2543ffda Merge branch 'songchuang' into dev 2023-04-17 09:40:16 +08:00
songchuang
2b9e317444 对账单后台管理部分代码提交 2023-04-17 09:35:03 +08:00
527339cd64 Merge branch 'xjjdev' into dev 2023-04-14 14:21:52 +08:00
9065d631ce Merge branch 'xjjdev' into dev 2023-04-14 13:58:02 +08:00
26e073f936 Merge branch 'xjjdev' into dev 2023-04-13 14:14:28 +08:00
ec4cc9cf4a Merge branch 'xjjdev' into dev 2023-04-13 10:27:03 +08:00
ceb3631037 Merge branch 'xjjdev' into dev 2023-04-13 09:23:51 +08:00
0b34600883 Merge branch 'xjjdev' into dev 2023-04-13 09:07:25 +08:00
f612737d94 Merge branch 'xjjdev' into dev 2023-04-12 17:51:30 +08:00
a8b5a734d1 Merge branch 'xjjdev' into dev 2023-04-12 10:08:03 +08:00
dc57a3c4e9 Merge branch 'dev' of http://gitlab.fontree.cn/bugmaker/fonchain-artistinfo into dev 2023-04-11 16:42:43 +08:00
3ee56b1433 Merge branch 'xjjdev' into dev 2023-04-11 16:42:38 +08:00
songchuang
6d247aa4a4 GetContractList接口修改 2023-04-11 14:50:49 +08:00
songchuang
920cfef5eb 测试修改 2023-04-11 14:43:43 +08:00
songchuang
929304e80d Merge branch 'songchuang' into dev 2023-04-11 12:33:53 +08:00
songchuang
9916e16d54 contract pb 2023-04-11 12:32:45 +08:00
songchuang
e7b8f40b50 contract列表代码修改 2023-04-11 12:30:23 +08:00
songchuang
e8baaf4e77 合同列表部分功能修改 2023-04-11 12:24:04 +08:00
songchuang
f70663a967 Merge branch 'jujin' into dev 2023-04-10 10:50:16 +08:00
4ea006f6f0 Merge branch 'xjjdev' 2023-04-09 13:42:44 +08:00
songchuang
be02805710 Merge branch 'jujin' of http://192.168.12.3:8090/bugmaker/fonchain-artistinfo into jujin 2023-04-07 15:51:23 +08:00
songchuang
5d68278904 Merge branch 'dev' into jujin 2023-04-07 15:50:01 +08:00
d7baf112ac Merge branch 'xjjdev' 2023-04-07 14:28:53 +08:00
2d26f15400 Merge branch 'xjjdev' into dev 2023-04-07 14:27:16 +08:00
songchuang
6af2d992aa Merge branch 'songchuang' into dev 2023-04-07 13:41:48 +08:00
3d08ba4ee2 环境变量测试3 2023-04-07 11:42:27 +08:00
4cba6ffd8c 环境变量测试2 2023-04-07 10:41:32 +08:00
8f7618b8bd 环境变量测试2 2023-04-07 10:33:48 +08:00
338439db59 环境变量测试 2023-04-07 10:20:05 +08:00
458c5e3bc8 修改dockerfile测试 2023-04-07 10:08:49 +08:00
1d9f336db3 Merge branch 'xjjdev' 2023-04-07 09:48:45 +08:00
36e39bf089 Merge branch 'xjjdev' into dev 2023-04-07 09:48:33 +08:00
04bd03022d Merge branch 'xjjdev' into dev 2023-04-07 08:08:34 +08:00
bc23ba6090 Merge branch 'xjjdev' 2023-04-06 14:50:43 +08:00
aa7edf420d Merge branch 'xjjdev' into dev 2023-04-06 14:50:26 +08:00
e5b80f16d2 增加对账单配置文件 2023-04-04 10:35:56 +08:00
00e3401985 完善对账单 2023-04-04 09:37:00 +08:00
586ec2a90f Merge branch 'xjjdev' 2023-04-04 08:55:09 +08:00
45f193589b Merge branch 'xjjdev' into dev 2023-04-04 08:48:13 +08:00
804aad3991 Merge branch 'xjjdev' 2023-04-04 08:45:41 +08:00
ce5ae4cdc2 Merge branch 'xjjdev' 2023-04-03 14:56:00 +08:00
5850452d28 Merge branch 'main' of http://192.168.12.3:8090/bugmaker/fonchain-artistinfo into jujin 2023-04-03 14:07:48 +08:00
4aa11fff20 开发对账单模块 2023-04-03 14:07:37 +08:00
747212fd29 合同表新增字段 2023-04-03 13:46:20 +08:00
0b70cfa251 Merge branch 'xjjdev' 2023-04-03 09:46:08 +08:00
77ddfb385a Merge branch 'xjjdev' 2023-04-01 10:03:23 +08:00
0847107720 Merge branch 'xjjdev' 2023-04-01 10:00:16 +08:00
c8ca3aa02f Merge branch 'xjjdev' 2023-04-01 09:54:17 +08:00
92dde6ee25 Merge branch 'xjjdev' 2023-04-01 09:37:45 +08:00
1eba4ba5be 增加基本画作历史记录的统计方式 2023-04-01 09:35:47 +08:00
a186312aa3 Merge branch 'xjjdev' 2023-03-31 17:37:34 +08:00
20ba130ac0 Merge branch 'xjjdev' 2023-03-31 17:04:46 +08:00
b1f8c17bfd Merge branch 'xjjdev' 2023-03-31 17:00:27 +08:00
ec1eba24cb update 2023-03-31 16:59:23 +08:00
6103b55f95 Merge branch 'xjjdev' 2023-03-31 16:46:29 +08:00
3ae240645d Merge branch 'xjjdev' 2023-03-31 16:45:46 +08:00
961c6dfbee Merge branch 'xjjdev' 2023-03-31 16:36:43 +08:00
82839afb83 Merge branch 'xjjdev' 2023-03-31 15:32:49 +08:00
e4be385783 Merge branch 'xjjdev' 2023-03-31 15:21:45 +08:00
9fbc31fdd2 Merge branch 'xjjdev' 2023-03-31 14:08:57 +08:00
f500dd922b Merge branch 'xjjdev' 2023-03-31 14:05:10 +08:00
db6e137598 Merge branch 'xjjdev' 2023-03-31 13:52:59 +08:00
c49275c1de Merge branch 'xjjdev' 2023-03-31 11:45:14 +08:00
73264cde5d Merge branch 'xjjdev' 2023-03-31 11:42:58 +08:00
519884feea Merge branch 'xjjdev' 2023-03-31 11:37:45 +08:00
586e140d4f Merge branch 'xjjdev' 2023-03-31 11:35:13 +08:00
ad7b9a21c9 Merge branch 'xjjdev' 2023-03-31 11:31:11 +08:00
b6706dbf5c Merge branch 'xjjdev' 2023-03-31 11:19:07 +08:00
af16e16c03 Merge branch 'xjjdev' 2023-03-31 10:07:54 +08:00
630c8f66ec Merge branch 'xjjdev' into dev 2023-03-31 09:41:03 +08:00
4161d4b498 Merge branch 'xjjdev' 2023-03-31 09:40:47 +08:00
195f3877b8 Merge branch 'xjjdev' into dev 2023-03-31 09:28:12 +08:00
ef12a59096 Merge branch 'xjjdev' 2023-03-31 09:28:01 +08:00
9edb0eae0b Merge branch 'xjjdev' 2023-03-30 15:46:33 +08:00
518315ecb7 Merge branch 'xjjdev' 2023-03-30 14:52:34 +08:00
8cc4a3fddd Merge branch 'xjjdev' 2023-03-30 14:38:29 +08:00
246de253b2 Merge branch 'xjjdev' 2023-03-30 14:30:36 +08:00
e13ea02eae Merge branch 'xjjdev' 2023-03-30 11:22:42 +08:00
70da4204c4 Merge branch 'xjjdev' 2023-03-30 11:14:47 +08:00
abad805a5e Merge branch 'xjjdev' 2023-03-30 11:06:11 +08:00
c2cbc5dfe0 Merge branch 'xjjdev' 2023-03-29 23:39:25 +08:00
80ed1c86c5 Merge branch 'xjjdev' into dev 2023-03-29 23:17:02 +08:00
def89683a5 Merge branch 'xjjdev' 2023-03-29 23:16:54 +08:00
129332ce1d Merge branch 'xjjdev' 2023-03-29 23:08:49 +08:00
219528bbab Merge branch 'xjjdev' into dev 2023-03-29 23:08:34 +08:00
fc8b822a53 修复画家数据统计接口数据分页问题 2023-03-29 22:37:23 +08:00
songchuang
187e2daf29 Merge branch 'main' of http://192.168.12.3:8090/bugmaker/fonchain-artistinfo 2023-03-29 13:38:58 +08:00
17cb609835 Merge branch 'xjjdev' 2023-03-29 11:54:05 +08:00
b58bf0c5f8 Merge branch 'xjjdev' into dev 2023-03-29 11:53:46 +08:00
songchuang
3816a5bbb7 Merge branch 'songchuang' into dev 2023-03-28 17:13:40 +08:00
songchuang
f898e79632 contract 接口修改 2023-03-28 17:11:39 +08:00
songchuang
a7be810101 Merge branch 'songchuang' into dev 2023-03-28 15:44:36 +08:00
songchuang
ab1e64b6e4 contract 增加ContractHistoryByLockMgmt接口 2023-03-28 15:42:30 +08:00
5b04150a2e Merge branch 'xjjdev' 2023-03-28 15:37:32 +08:00
6b5cf6dfe7 Merge branch 'xjjdev' into dev 2023-03-28 15:37:07 +08:00
c1db953f84 Merge branch 'xjjdev' 2023-03-27 11:14:45 +08:00
5d3faa442c Merge branch 'xjjdev' into dev 2023-03-27 11:14:23 +08:00
c506560932 Merge branch 'xjjdev' 2023-03-24 18:20:01 +08:00
006df23722 Merge branch 'xjjdev' into dev 2023-03-24 18:19:36 +08:00
1b274a0fce 修复mysql大小写不敏感导致的数据统计问题 2023-03-24 18:18:10 +08:00
b20fe7be3f Merge remote-tracking branch 'origin/dev' into jujin 2023-03-24 14:49:49 +08:00
95cfaf462a Merge branch 'main' of http://192.168.12.3:8090/bugmaker/fonchain-artistinfo into jujin 2023-03-24 14:49:31 +08:00
03f0934d8d Merge branch 'xjjdev' 2023-03-24 14:46:26 +08:00
2a82776897 Merge branch 'dev' of http://gitlab.fontree.cn/bugmaker/fonchain-artistinfo into dev 2023-03-24 14:41:27 +08:00
793a436630 Merge branch 'xjjdev' into dev 2023-03-24 14:41:14 +08:00
songchuang
669d28fa14 app.go 增加对账单部分代码 2023-03-24 14:36:45 +08:00
songchuang
d5eafd89e9 Merge branch 'songchuang' into dev 2023-03-24 14:34:53 +08:00
songchuang
76f6430231 配置文件修改 2023-03-24 14:33:46 +08:00
songchuang
c9721a18a1 Merge branch 'songchuang' into dev 2023-03-24 14:23:29 +08:00
songchuang
e3bd6c9076 init.go 添加自动生成对账单表 2023-03-24 14:19:56 +08:00
songchuang
deaeee5c16 Merge branch 'songchuang' into dev 2023-03-24 14:13:34 +08:00
songchuang
ac0200e952 对账单代码提交 2023-03-24 14:11:43 +08:00
e19bc5bd12 增加调试信息 2023-03-24 13:28:34 +08:00
99e496dd39 Merge remote-tracking branch 'origin/dev' into jujin 2023-03-24 13:23:49 +08:00
83ad5392b5 Merge branch 'main' of http://192.168.12.3:8090/bugmaker/fonchain-artistinfo into jujin 2023-03-24 13:23:09 +08:00
5475034aaa Merge branch 'xjjdev' into dev 2023-03-24 13:10:01 +08:00
0b794fa6a0 Merge branch 'xjjdev' into dev 2023-03-24 12:54:29 +08:00
54e27c2cf9 Merge branch 'xjjdev' into dev 2023-03-24 12:23:24 +08:00
f563dd4dd0 Merge branch 'dev' of http://gitlab.fontree.cn/bugmaker/fonchain-artistinfo into dev 2023-03-24 12:13:38 +08:00
556ba4bd9e Merge branch 'xjjdev' into dev 2023-03-24 12:13:28 +08:00
songchuang
3afa12c1e9 StatementList 修改 2023-03-24 11:50:20 +08:00
songchuang
5275280910 Merge branch 'songchuang' into dev 2023-03-24 10:59:41 +08:00
b56a020a16 Merge branch 'xjjdev' 2023-03-24 10:58:37 +08:00
songchuang
087ca51e06 contract 表 字段batchname改为batchtime 2023-03-24 10:58:37 +08:00
0068934084 Merge branch 'main' into dev 2023-03-24 10:58:21 +08:00
80f9266b6b Merge branch 'xjjdev' into dev 2023-03-24 10:58:17 +08:00
d11662845c Merge branch 'xjjdev' 2023-03-24 10:51:01 +08:00
f7f1c9dd8c Merge branch 'xjjdev' into dev 2023-03-24 10:50:35 +08:00
ee2c894f96 Merge branch 'main' of http://192.168.12.3:8090/bugmaker/fonchain-artistinfo into jujin 2023-03-24 10:33:28 +08:00
1491f5ffb6 Merge branch 'xjjdev' 2023-03-24 10:10:45 +08:00
85a561f06c Merge branch 'xjjdev' into dev 2023-03-24 10:10:35 +08:00
songchuang
690bc74f1d 物权表结构修改,修改部分物权代码 2023-03-24 09:41:11 +08:00
1dd6fc25f7 Merge branch 'xjjdev' 2023-03-24 09:39:59 +08:00
9012782ada Merge branch 'xjjdev' 2023-03-23 19:40:54 +08:00
7b85908482 Merge branch 'xjjdev' 2023-03-23 19:35:43 +08:00
64f754ac87 Merge branch 'xjjdev' 2023-03-23 19:20:58 +08:00
songchuang
6b9870d3bd 对账单添加接口,原合同部分修改 2023-03-23 18:31:10 +08:00
gy
fef475eae9 feat 2023-03-23 18:29:51 +08:00
gy
27bd2f891a feat 2023-03-23 18:22:30 +08:00
gy
d2297b9f1f feat dockerfile 瘦身加速构建 2023-03-23 18:18:03 +08:00
songchuang
e4e298d921 对账单增加接口 2023-03-23 17:17:29 +08:00
songchuang
33c4db9cab 对账单表修改 2023-03-23 14:01:06 +08:00
songchuang
f5f466c04d 对账单表修改 2023-03-23 13:59:32 +08:00
songchuang
ea2953dd09 对账单表修改 2023-03-23 13:22:07 +08:00
ebed3f6d24 Merge branch 'main' of http://192.168.12.3:8090/bugmaker/fonchain-artistinfo into jujin 2023-03-23 13:14:36 +08:00
songchuang
376674825b 对账单表修改 2023-03-23 11:52:18 +08:00
songchuang
1b5a52df12 Merge branch 'songchuang' into dev 2023-03-23 11:45:47 +08:00
songchuang
d70ee92564 对账单表修改 2023-03-23 11:42:51 +08:00
songchuang
00bb094a3c Merge branch 'songchuang' into dev 2023-03-22 16:27:07 +08:00
songchuang
baa1bea012 对账单代码上传 2023-03-22 16:16:16 +08:00
34 changed files with 5704 additions and 3563 deletions

View File

@ -5,7 +5,7 @@ cd ..
go build -ldflags "-s -w" -o ./build/artistinfo-dev ./cmd/app.go
docker rmi artistinfo-dev
docker rmi 121.229.45.214:9006/artistinfo-dev
docker build . -f .\DockerfileWindowsTest -t artistinfo-dev
docker build . -f .\DockerfileWindowsTest -t artistinfo-dev --build-arg BUILD_DATE=$(date)
docker tag artistinfo-dev 121.229.45.214:9006/artistinfo-dev
docker push 121.229.45.214:9006/artistinfo-dev
pause

View File

@ -4,7 +4,7 @@ MAINTAINER GY "wangyitao@163.com"
RUN go env -w GO111MODULE=on && \
go env -w GOPROXY=https://goproxy.cn,direct
WORKDIR /app
COPY fonchain-artistinfo /app/fonchain-artistinfo

View File

@ -7,11 +7,11 @@ RUN ln -sf /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shangh
#ENV TZ Asia/Shanghai
WORKDIR /app
WORKDIR /app/main-client
#通过名称引用
COPY ./build/app /app/artistinfo-dev
COPY ./build/app ./bin/mainServer
COPY ./conf/ /app/conf/
COPY ./conf/ ./conf/
# 在容器启动时输出环境变量BUILD_DATE的值
CMD ["/app/artistinfo-dev"]
WORKDIR /app/main-client/bin
CMD ["./mainServer"]

View File

@ -21,6 +21,9 @@ WORKDIR /build
COPY ./build/artistinfo-dev /app/artistinfo-dev
FROM alpine
ARG BUILD_DATE
ENV BUILD_DATE ${BUILD_DATE}
RUN sed -i 's/dl-cdn.alpinelinux.org/mirrors.aliyun.com/g' /etc/apk/repositories
RUN apk update --no-cache
RUN apk add --no-cache ca-certificates

View File

@ -2,6 +2,7 @@ package main
import (
"fmt"
"os"
"dubbo.apache.org/dubbo-go/v3/config"
@ -21,11 +22,13 @@ func main() {
config.SetProviderService(&controller.ArtistInfoArtworkProvider{})
config.SetProviderService(&controller.ArtistInfoArtshowProvider{})
config.SetProviderService(&controller.ArtistInfoContractProvider{})
// config.SetConsumerService(&controller.StatementServerProvider{})
config.SetProviderService(&controller.ArtistInfoStatementProvider{})
db.Init(m.SERVER_CONFIG)
cache.InitRedis(m.SERVER_CONFIG)
if err := config.Load(); err != nil {
panic(err)
}
buildDate := os.Getenv("BUILD_DATE")
fmt.Println("镜像生成时间:", buildDate)
select {}
}

View File

@ -0,0 +1,102 @@
package controller
import (
"context"
"fmt"
"github.com/fonchain/fonchain-artistinfo/cmd/internal/logic"
statement "github.com/fonchain/fonchain-artistinfo/pb/artistinfoStatement"
)
type ArtistInfoStatementProvider struct {
statement.UnimplementedStatementServer
statementLogic *logic.Statement
}
func (c *ArtistInfoStatementProvider) UploadExcelOneTx(ctx context.Context, req *statement.UploadExcelOneTxRequest) (rep *statement.UploadExcelOneTxRespond, err error) {
fmt.Println("第一处")
if rep, err = c.statementLogic.UploadExcelOneTx(req); err != nil {
return nil, err
}
return rep, nil
}
func (c *ArtistInfoStatementProvider) UploadExcelTwoTx(ctx context.Context, req *statement.UploadExcelTwoTxRequest) (rep *statement.UploadExcelTwoTxRespond, err error) {
fmt.Println("第一处")
if rep, err = c.statementLogic.UploadExcelTwoTx(req); err != nil {
return nil, err
}
return rep, nil
}
func (c *ArtistInfoStatementProvider) UploadExcelOneCopy(ctx context.Context, req *statement.UploadExcelOneCopyRequest) (rep *statement.UploadExcelOneCopyRespond, err error) {
fmt.Println("第一处")
if rep, err = c.statementLogic.UploadExcelOneCopy(req); err != nil {
return nil, err
}
return rep, nil
}
func (c *ArtistInfoStatementProvider) UploadExcelTwoCopy(ctx context.Context, req *statement.UploadExcelTwoCopyRequest) (rep *statement.UploadExcelTwoCopyRespond, err error) {
fmt.Println("第一处")
if rep, err = c.statementLogic.UploadExcelTwoCopy(req); err != nil {
return nil, err
}
return rep, nil
}
func (c *ArtistInfoStatementProvider) GetAllBatchTimeTx(ctx context.Context, req *statement.GetAllBatchTimeTxRequest) (rep *statement.GetAllBatchTimeTxRespond, err error) {
fmt.Println("第一处")
if rep, err = c.statementLogic.GetAllBatchTimeTx(req); err != nil {
return nil, err
}
return rep, nil
}
func (c *ArtistInfoStatementProvider) GetAllBatchTimeCopy(ctx context.Context, req *statement.GetAllBatchTimeCopyRequest) (rep *statement.GetAllBatchTimeCopyRespond, err error) {
fmt.Println("第一处")
if rep, err = c.statementLogic.GetAllBatchTimeCopy(req); err != nil {
return nil, err
}
return rep, nil
}
func (c *ArtistInfoStatementProvider) GetArtworkSoldTxDetailList(ctx context.Context, req *statement.GetArtworkSoldTxDetailListRequest) (rep *statement.GetArtworkSoldTxDetailListRespond, err error) {
fmt.Println("第一处")
if rep, err = c.statementLogic.GetArtworkSoldTxDetailList(req); err != nil {
return nil, err
}
return rep, nil
}
func (c *ArtistInfoStatementProvider) GetArtworkSoldCopyDetailList(ctx context.Context, req *statement.GetArtworkSoldCopyDetailListRequest) (rep *statement.GetArtworkSoldCopyDetailListRespond, err error) {
fmt.Println("第一处")
if rep, err = c.statementLogic.GetArtworkSoldCopyDetailList(req); err != nil {
return nil, err
}
return rep, nil
}
func (c *ArtistInfoStatementProvider) StatementList(ctx context.Context, req *statement.StatementListRequest) (rep *statement.StatementListRespond, err error) {
fmt.Println("第一处")
if rep, err = c.statementLogic.StatementList(req); err != nil {
return nil, err
}
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
}
func (c *ArtistInfoStatementProvider) GetCopyInfoByBatchUid(ctx context.Context, req *statement.GetCopyInfoByBatchUidRequest) (rep *statement.GetCopyInfoByBatchUidRespond, err error) {
fmt.Println("第一处")
if rep, err = c.statementLogic.GetCopyInfoByBatchUid(req); err != nil {
return nil, err
}
return rep, nil
}

View File

@ -1037,6 +1037,7 @@ func GetInvitedUserList(in *artistInfoUser.GetInvitedUserListRequest) (res *arti
if in.RealName != "" {
orm = orm.Where("rn.name like ?", "%"+in.RealName+"%")
}
fmt.Println("in.RealName", in.RealName)
if in.Keyword != "" {
searchWords := "%" + in.Keyword + "%"
orm = orm.Where("rn.name like ? OR sys_user.tel_num LIKE ? or sys_user.invited_code LIKE ?", searchWords, searchWords, searchWords)

View File

@ -95,6 +95,46 @@ func CreateArtworkContract(tx *gorm.DB, artworkUid []string, artistUid string, c
return
}
func StatementContractNo(artistUid, batchUid string) (err error) {
//画作有合同类型是26的都是 点击过"著作权代理转让服务合同"的
var contract model.Contract
if err = db.DB.Where("artist_uid = ? AND batch_uid = ?", artistUid, batchUid).First(&contract).Error; err != nil && err != gorm.ErrRecordNotFound {
zap.L().Error("get contract info err", zap.Error(err))
err = errors.New(m.ERROR_SELECT)
return
}
//err 为空则查询到,返回画作合同已存在的错误
if err == nil {
err = errors.New(m.ARTWORK_CONTRACT_EXISTS)
}
return
}
func CreateStatementContract(tx *gorm.DB, artistUid, batchUid, batchTime string, contractType int32) (err error) {
var uid uuid.UUID
if uid, err = uuid.NewV4(); err != nil {
err = errors.New(m.ERROR_UID)
return
}
contract := &model.Contract{
Uid: uid.String(),
ArtistUid: artistUid,
Type: contractType,
BatchTime: batchTime,
BatchUid: batchUid,
}
if err = tx.Create(contract).Error; err != nil {
zap.L().Error("create contract err", zap.Error(err))
err = errors.New(m.CREATE_ERROR)
return
}
return
}
func GetArtistNoByUid(artistUid string) (err error) {
var user model.User
if err = db.DB.Where("mgmt_artist_uid = ?", artistUid).First(&user).Error; err != nil {
@ -105,15 +145,34 @@ func GetArtistNoByUid(artistUid string) (err error) {
return
}
func GetContractList(artistUid string, pageSize, offset int32) (contracts []*contract.Contracts, err error) {
func GetContractList(artistUid string, pageSize, offset, status int32) (contracts []*contract.Contracts, err error) {
var contractSlice []model.Contract
if err = db.DB.Where("artist_uid = ?", artistUid).Order("ID asc").Limit(int(pageSize)).Offset(int(offset)).Find(&contractSlice).Error; err != nil {
zap.L().Error("get contracts info err", zap.Error(err))
err = errors.New(m.CREATE_ERROR)
return
// if err = db.DB.Where("artist_uid = ? AND status = ?", artistUid, status).Order("ID asc").Limit(int(pageSize)).Offset(int(offset)).Find(&contractSlice).Error; err != nil {
// zap.L().Error("get contracts info err", zap.Error(err))
// err = errors.New(m.CREATE_ERROR)
// return
// }
if status == 2 {
//未签署且画家未解锁
if err = db.DB.Where("artist_uid = ? AND type != 4 AND type != 7 AND state = ? AND status = ?", artistUid, 1, 2).Order("ID asc").Limit(int(pageSize)).Offset(int(offset)).Find(&contractSlice).Error; err != nil {
zap.L().Error("get contracts info err", zap.Error(err))
fmt.Println("GetContractList错误为:", err)
err = errors.New(m.ERROR_SELECT)
return
}
} else if status == 3 {
//画家解锁(解锁之后,未签署的合同也变成历史合同)
if err = db.DB.Where("(artist_uid = ? AND type != 4 AND type != 7) AND ((state = ? AND status = ?) OR (status = ?))", artistUid, 2, 2, 3).Order("ID asc").Limit(int(pageSize)).Offset(int(offset)).Find(&contractSlice).Error; err != nil {
zap.L().Error("get contracts info err", zap.Error(err))
fmt.Println("GetContractList错误为:", err)
err = errors.New(m.ERROR_SELECT)
return
}
} else {
err = errors.New("画家锁定值出错!")
}
fmt.Println("第二处")
for _, v := range contractSlice {
contcontract := &contract.Contracts{
ContractUid: v.Uid,
@ -145,16 +204,11 @@ func GetArtistInfoById(artistUid string) (user model.User, err error) {
return
}
func ContractList(artist_uid string, state int32) (ContractData []*contract.Contracts, err error) {
// if state != 0 {
// if state == 2 {
// state = 3
// }
// }
func ContractList(artist_uid string, req *contract.ContractListRequest, offset int32) (contractData []*contract.Contracts, err error) {
var contracts []model.Contract
if err = db.DB.Where("artist_uid = ? AND type != 4 AND state = ?", artist_uid, state).Find(&contracts).Error; err != nil {
//在画家被锁定状态下查询
if err = db.DB.Where("artist_uid = ? AND type != 4 AND type != 7 AND state = ? AND status = ?", artist_uid, req.State, 2).Order("ID asc").Limit(int(req.PageSize)).Offset(int(offset)).Find(&contracts).Error; err != nil {
zap.L().Error("get contracts info err", zap.Error(err))
err = errors.New(m.ERROR_SELECT)
return
@ -177,7 +231,7 @@ func ContractList(artist_uid string, state int32) (ContractData []*contract.Cont
SignTime: v.SignTime,
}
ContractData = append(ContractData, Contract)
contractData = append(contractData, Contract)
}
return
@ -193,12 +247,21 @@ func GetContractInfo(contractUid string) (contractInfo model.Contract, err error
}
func UpdateContract(tx *gorm.DB, req *contract.SignContractRequest) (err error) {
fmt.Println("第一处1111")
if err = tx.Model(&model.Contract{}).Where("uid = ?", req.ContractUid).Updates(model.Contract{ViewUrl: req.ViewPdfUrl, DownloadUrl: req.DownloadUrl, ContractId: req.ContractNo, TransactionId: req.TransactionId, State: 1}).Error; err != nil {
zap.L().Error("update contract info err", zap.Error(err))
err = errors.New(m.UPDATE_FAILED)
return
//对账单这边只有TransactionId需要改变
if req.ViewPdfUrl == "" {
if err = tx.Model(&model.Contract{}).Where("uid = ?", req.ContractUid).Updates(model.Contract{TransactionId: req.TransactionId, State: 1}).Error; err != nil {
zap.L().Error("update contract info err", zap.Error(err))
err = errors.New(m.UPDATE_FAILED)
return
}
} else {
if err = tx.Model(&model.Contract{}).Where("uid = ?", req.ContractUid).Updates(model.Contract{ViewUrl: req.ViewPdfUrl, DownloadUrl: req.DownloadUrl, ContractId: req.ContractNo, TransactionId: req.TransactionId, State: 1}).Error; err != nil {
zap.L().Error("update contract info err", zap.Error(err))
err = errors.New(m.UPDATE_FAILED)
return
}
}
return
}
@ -263,6 +326,15 @@ func ContractTxList(uid string, state int32) (contracts []model.Contract, err er
}
func GetContractUrlTx(batchUid string) (contract model.Contract, err error) {
if err = db.DB.Where("batch_uid = ?", batchUid).First(&contract).Error; err != nil {
zap.L().Error("get contract info err", zap.Error(err))
err = errors.New(m.ERROR_SELECT)
return
}
return
}
// func UpdateArtworkState(tx *gorm.DB, id int32) (err error) { //无用
// var artworkState model.ArtworkState
// if err = tx.Where("artwork_id = ? and state = ? ", id, 7).First(&artworkState).Error; err != nil {

View File

@ -0,0 +1,352 @@
package dao
import (
"errors"
"github.com/fonchain/fonchain-artistinfo/cmd/model"
statement "github.com/fonchain/fonchain-artistinfo/pb/artistinfoStatement"
db "github.com/fonchain/fonchain-artistinfo/pkg/db"
"github.com/fonchain/fonchain-artistinfo/pkg/m"
"go.uber.org/zap"
"gorm.io/gorm"
)
func IsExistArtworkTx(batchTime, artistUid string) (exist bool, artworkTx *model.ArtworkTx, err error) {
if err = db.DB.Where("batch_time = ? AND artist_uid = ?", batchTime, artistUid).First(&artworkTx).Error; err != nil {
if err == gorm.ErrRecordNotFound {
return true, nil, nil
} else {
zap.L().Error("get artworkTx info err", zap.Error(err))
err = errors.New(m.ERROR_SELECT)
return
}
}
return
}
func IsExistArtworkCopy(batchTime, artistUid string) (exist bool, artworkCopy *model.ArtworkCopy, err error) {
if err = db.DB.Where("batch_time = ? AND artist_uid = ?", batchTime, artistUid).First(&artworkCopy).Error; err != nil {
if err == gorm.ErrRecordNotFound {
return true, nil, nil
} else {
zap.L().Error("get artworkCopy info err", zap.Error(err))
err = errors.New(m.ERROR_SELECT)
return
}
}
return
}
func CreateArtworkTx(tx *gorm.DB, uid, batchTime, artistUid, asrtistName string) (err error) {
artworkTx := &model.ArtworkTx{
Uid: uid,
ArtistUid: artistUid,
ArtistName: asrtistName,
BatchTime: batchTime,
}
if err = tx.Create(&artworkTx).Error; err != nil {
zap.L().Error("create artworkTx err", zap.Error(err))
err = errors.New(m.CREATE_ERROR)
return
}
return
}
func CreateArtworkCopy(tx *gorm.DB, uid, batchTime, artistUid, asrtistName string) (err error) {
artworkCopy := &model.ArtworkCopy{
Uid: uid,
ArtistUid: artistUid,
ArtistName: asrtistName,
BatchTime: batchTime,
}
if err = tx.Create(&artworkCopy).Error; err != nil {
zap.L().Error("create artworkCopy err", zap.Error(err))
err = errors.New(m.CREATE_ERROR)
return
}
return
}
func CreateArtworkTxDetail(tx *gorm.DB, uid1, uid2 string, excelOneInfo *statement.ExcelOneInfo) (err error) {
artworkTxDetail := &model.ArtworkTxDetail{
Uid: uid2,
BatchUid: uid1,
TfNum: excelOneInfo.TfNum,
ArtworkName: excelOneInfo.ArtistName,
Ruler: excelOneInfo.Ruler,
MinPrice: excelOneInfo.MinPrice,
GuaranteePrice: excelOneInfo.GuaranteePrice,
}
if err = tx.Create(&artworkTxDetail).Error; err != nil {
zap.L().Error("create artworkTxDetail err", zap.Error(err))
err = errors.New(m.CREATE_ERROR)
return
}
return
}
func CreateArtworkCopyDetail(tx *gorm.DB, uid1, uid2 string, excelOneInfo *statement.ExcelOneInfo) (err error) {
artworkCopyDetail := &model.ArtworkCopyDetail{
Uid: uid2,
BatchUid: uid1,
TfNum: excelOneInfo.TfNum,
ArtworkName: excelOneInfo.ArtistName,
Ruler: excelOneInfo.Ruler,
MinPrice: excelOneInfo.MinPrice,
GuaranteePrice: excelOneInfo.GuaranteePrice,
}
if err = tx.Create(&artworkCopyDetail).Error; err != nil {
zap.L().Error("create artworkCopyDetail err", zap.Error(err))
err = errors.New(m.CREATE_ERROR)
return
}
return
}
func IsExistArtworkTxDetail(uid, tfNum string) (count int64, err error) {
if err = db.DB.Model(&model.ArtworkTxDetail{}).Where("batch_uid = ? AND tf_num = ?", uid, tfNum).Count(&count).Error; err != nil {
zap.L().Error("get artworkTxDetail num err", zap.Error(err))
err = errors.New(m.ERROR_SELECT)
return
}
return
}
func IsExistArtworkCopyDetail(uid, tfNum string) (count int64, err error) {
if err = db.DB.Model(&model.ArtworkCopyDetail{}).Where("batch_uid = ? AND tf_num = ?", uid, tfNum).Count(&count).Error; err != nil {
zap.L().Error("get artworkCopyDetail num err", zap.Error(err))
err = errors.New(m.ERROR_SELECT)
return
}
return
}
func IsExistArtworkSoldTxDetail(uid, tfNum string) (count int64, err error) {
if err = db.DB.Model(&model.ArtworkSoldTxDetail{}).Where("batch_uid = ? AND tf_num = ?", uid, tfNum).Count(&count).Error; err != nil {
zap.L().Error("get artworkSoldTxDetail num err", zap.Error(err))
err = errors.New(m.ERROR_SELECT)
return
}
return
}
func IsExistArtworkSoldCopyDetail(uid, tfNum string) (count int64, err error) {
if err = db.DB.Model(&model.ArtworkSoldCopyDetail{}).Where("batch_uid = ? AND tf_num = ?", uid, tfNum).Count(&count).Error; err != nil {
zap.L().Error("get artworkSoldCopyDetail num err", zap.Error(err))
err = errors.New(m.ERROR_SELECT)
return
}
return
}
func CreateArtworkSoldTxDetail(tx *gorm.DB, uid1, uid2 string, excelTwoInfo *statement.ExcelTwoInfo) (err error) {
artworkSoldTxDetail := &model.ArtworkSoldTxDetail{
Uid: uid2,
BatchUid: uid1, //批次uid
TfNum: excelTwoInfo.TfNum,
ArtworkName: excelTwoInfo.ArtistName,
Ruler: excelTwoInfo.Ruler,
SaleNo: excelTwoInfo.SaleNo,
CompleteDate: excelTwoInfo.CompleteDate,
SalePrice: excelTwoInfo.SalePrice,
}
if err = tx.Create(&artworkSoldTxDetail).Error; err != nil {
zap.L().Error("create artworkSoldTxDetail err", zap.Error(err))
err = errors.New(m.CREATE_ERROR)
return
}
return
}
func CreateArtworkSoldCopyDetail(tx *gorm.DB, uid1, uid2 string, excelTwoInfo *statement.ExcelTwoInfo) (err error) {
artworkSoldCopyDetail := &model.ArtworkSoldCopyDetail{
Uid: uid2,
BatchUid: uid1, //批次uid
TfNum: excelTwoInfo.TfNum,
ArtworkName: excelTwoInfo.ArtistName,
Ruler: excelTwoInfo.Ruler,
SaleNo: excelTwoInfo.SaleNo,
CompleteDate: excelTwoInfo.CompleteDate,
SalePrice: excelTwoInfo.SalePrice,
}
if err = tx.Create(&artworkSoldCopyDetail).Error; err != nil {
zap.L().Error("create artworkSoldCopyDetail err", zap.Error(err))
err = errors.New(m.CREATE_ERROR)
return
}
return
}
func GetAllBatchTimeTx() (batchTime []string, err error) {
if err = db.DB.Where("DISTINCT batch_time").Find(&model.ArtworkTx{}).Pluck("batch_time", &batchTime).Error; err != nil {
zap.L().Error("get artworkTxList info err", zap.Error(err))
err = errors.New(m.ERROR_SELECT)
return
}
return
}
func GetAllBatchTimeCopy() (batchTime []string, err error) {
if err = db.DB.Where("DISTINCT batch_time").Find(&model.ArtworkCopy{}).Pluck("batch_time", &batchTime).Error; err != nil {
zap.L().Error("get artworkTxList info err", zap.Error(err))
err = errors.New(m.ERROR_SELECT)
return
}
return
}
func GetArtworkTxList(query *gorm.DB, num, offset int32) (artworkTxList []model.ArtworkTx, err error) {
if err = query.Model(&artworkTxList).Order("ID asc").Limit(int(num)).Offset(int(offset)).Error; err != nil {
zap.L().Error("get artworkTxList info err", zap.Error(err))
err = errors.New(m.ERROR_SELECT)
return
}
return
}
func GetArtworkCopyList(query *gorm.DB, num, offset int32) (artworkCopyList []model.ArtworkCopy, err error) {
if err = query.Model(&artworkCopyList).Order("ID asc").Limit(int(num)).Offset(int(offset)).Error; err != nil {
zap.L().Error("get artworkCopyList info err", zap.Error(err))
err = errors.New(m.ERROR_SELECT)
return
}
return
}
func GetArtworkSoldTxDetailList(batchUid string) (artworkSoldTxDetail []model.ArtworkSoldTxDetail, err error) {
if err = db.DB.Where("batch_uid = ?", batchUid).Find(&artworkSoldTxDetail).Error; err != nil {
zap.L().Error("get artworkSoldTxDetail info err", zap.Error(err))
err = errors.New(m.ERROR_SELECT)
return
}
return
}
func UpdateArtworkTxStatus(tx *gorm.DB, batchUid string, state int32) (err error) {
if err = tx.Model(&model.ArtworkTx{}).Where("uid = ?", batchUid).Update("state", 2).Error; err != nil {
zap.L().Error("update artworkTx info err", zap.Error(err))
err = errors.New(m.UPDATE_FAILED)
return
}
return
}
func UpdateArtworkCopyStatus(tx *gorm.DB, batchUid string, state int32) (err error) {
if err = tx.Model(&model.ArtworkCopy{}).Where("uid = ?", batchUid).Update("state", 2).Error; err != nil {
zap.L().Error("update artworkCopy info err", zap.Error(err))
err = errors.New(m.UPDATE_FAILED)
return
}
return
}
func StatementList(artistUid string, state int32) (contractData []*statement.Contracts, err error) {
var contracts []model.Contract
if err = db.DB.Where("artist_uid = ? AND state = ? AND (type == 4 OR type == 7)", artistUid, state).Find(&contracts).Error; err != nil {
zap.L().Error("get contracts info err", zap.Error(err))
err = errors.New(m.ERROR_SELECT)
return
}
for _, v := range contracts {
Contract := &statement.Contracts{
ContractUid: v.Uid,
ArtistUid: v.ArtistUid,
ArtworkUid: v.ArtworkUid,
ContractId: v.ContractId,
TransactionId: v.TransactionId,
Type: v.Type,
ViewUrl: v.ViewUrl,
DownloadUrl: v.DownloadUrl,
State: v.State,
Status: int32(v.Status),
LockTime: v.LockTime,
SignTime: v.SignTime,
BatchTime: v.BatchTime,
BatchUid: v.BatchUid,
}
contractData = append(contractData, Contract)
}
return
}
func GetTxArtistNameByBatchUid(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
}
func GetArtworkSoldTxDetailByBatchUid(batchUid string) (artworkSoldTxDetail []model.ArtworkSoldTxDetail, err error) {
if err = db.DB.Where("batch_uid = ?", batchUid).Find(&artworkSoldTxDetail).Error; err != nil {
zap.L().Error("get artworkSoldTxDetail infos err", zap.Error(err))
err = errors.New(m.ERROR_SELECT)
return
}
return
}
func GetCopyArtistNameByBatchUid(batchUid string) (artworkCopy model.ArtworkCopy, err error) {
if err = db.DB.Where("uid = ?", batchUid).Find(&artworkCopy).Error; err != nil {
zap.L().Error("get artworkCopy info err", zap.Error(err))
err = errors.New(m.ERROR_SELECT)
return
}
return
}
func GetArtworkCopyDetailByBatchUid(batchUid string) (artworkCopyDetail []model.ArtworkCopyDetail, err error) {
if err = db.DB.Where("batch_uid = ?", batchUid).Find(&artworkCopyDetail).Error; err != nil {
zap.L().Error("get artworkCopyDetail infos err", zap.Error(err))
err = errors.New(m.ERROR_SELECT)
return
}
return
}
func GetArtworkSoldCopyDetailByBatchUid(batchUid string) (artworkSoldCopyDetail []model.ArtworkSoldCopyDetail, err error) {
if err = db.DB.Where("batch_uid = ?", batchUid).Find(&artworkSoldCopyDetail).Error; err != nil {
zap.L().Error("get artworkSoldCopyDetail infos err", zap.Error(err))
err = errors.New(m.ERROR_SELECT)
return
}
return
}

View File

@ -78,7 +78,6 @@ func (a *Contract) CreateContract(req *contract.CreateContractRequest) (rep *con
return
}
} else {
fmt.Println("第一处112")
return
}
@ -128,6 +127,26 @@ func (a *Contract) CreateContract(req *contract.CreateContractRequest) (rep *con
}
}
//这里是对账单的物权合同!!!注意!!!
case 4:
//查看画家该批次是否已经有了合同,没有继续
if err = dao.StatementContractNo(req.ArtistUid, req.BatchUid); err == gorm.ErrRecordNotFound {
} else {
return
}
//创建物权合同类型4
if err = dao.CreateStatementContract(tx, req.ArtistUid, req.BatchUid, req.BatchTime, 4); err != nil {
tx.Rollback()
return
}
//修改对账单将State状态值改为2
if err = dao.UpdateArtworkTxStatus(tx, req.BatchUid, 2); err != nil {
tx.Rollback()
return
}
case 5:
for _, v := range req.ArtworkUid {
//查看画作合同是否已经存在,不存在继续类型5
@ -146,6 +165,25 @@ func (a *Contract) CreateContract(req *contract.CreateContractRequest) (rep *con
}
}
//这里是对账单的物权合同!!!注意!!!
case 7:
//查看画家该批次是否已经有了合同,没有继续
if err = dao.StatementContractNo(req.ArtistUid, req.BatchUid); err == gorm.ErrRecordNotFound {
} else {
return
}
//创建物权合同类型4
if err = dao.CreateStatementContract(tx, req.ArtistUid, req.BatchUid, req.BatchTime, 7); err != nil {
tx.Rollback()
return
}
//修改对账单将State状态值改为2
if err = dao.UpdateArtworkCopyStatus(tx, req.BatchUid, 2); err != nil {
tx.Rollback()
return
}
default:
err = errors.New("type值出错!")
return rep, err
@ -174,7 +212,7 @@ func (a *Contract) ContractListMgmt(req *contract.ContractListMgmtRequest) (rep
offset := (req.Page - 1) * req.Num
//获取该用户的所有合同
contracts, err := dao.GetContractList(req.ArtistUid, req.Num, offset)
contracts, err := dao.GetContractList(req.ArtistUid, req.Num, offset, req.Status)
if err != nil {
return
}
@ -184,6 +222,7 @@ func (a *Contract) ContractListMgmt(req *contract.ContractListMgmtRequest) (rep
}
func (a *Contract) ContractList(req *contract.ContractListRequest) (rep *contract.ContractListRespond, err error) {
rep = &contract.ContractListRespond{}
//查看是否有该画家
user, err := dao.GetArtistInfoById(req.ArtistUid)
@ -191,16 +230,26 @@ func (a *Contract) ContractList(req *contract.ContractListRequest) (rep *contrac
return
}
fmt.Println("user:", user)
//画家被解锁直接返回空值
if !user.IsLock {
return
}
ContractData, err := dao.ContractList(user.MgmtArtistUid, req.State)
//合同分页查询操作
if req.Page < 1 {
req.Page = 1
}
if req.PageSize < 1 {
req.PageSize = 15
}
offset := (req.Page - 1) * req.PageSize
ContractData, err := dao.ContractList(user.MgmtArtistUid, req, offset)
if err != nil {
return
}
rep = &contract.ContractListRespond{
Data: ContractData,
}
rep.Data = ContractData
return
}
@ -237,6 +286,36 @@ func (a *Contract) FinishContract(req *contract.FinishContractRequest) (rep *con
return
}
func (a *Contract) GetContractInfoByContractUid(req *contract.GetContractInfoByContractUidRequest) (rep *contract.GetContractInfoByContractUidRespond, err error) {
rep = &contract.GetContractInfoByContractUidRespond{}
contractInfo, err := dao.GetContractInfo(req.ContractUid)
if err != nil {
return
}
contract := &contract.Contracts{
ContractUid: contractInfo.Uid,
ArtistUid: contractInfo.ArtistUid,
ArtworkUid: contractInfo.ArtworkUid,
ContractId: contractInfo.ContractId,
TransactionId: contractInfo.TransactionId,
Type: contractInfo.Type,
ViewUrl: contractInfo.ViewUrl,
DownloadUrl: contractInfo.DownloadUrl,
State: contractInfo.State,
Status: contractInfo.Status,
LockTime: contractInfo.LockTime,
SignTime: contractInfo.SignTime,
BatchTime: contractInfo.BatchTime,
BatchUid: contractInfo.BatchUid,
}
rep.Data = contract
return
}
// func (a *Contract) SignContract(req *contract.SignContractRequest) (rep *contract.SignContractRespond, err error) {
// rep = &contract.SignContractRespond{}
@ -671,34 +750,6 @@ func (a *Contract) FinishContract(req *contract.FinishContractRequest) (rep *con
// return rep, nil
// }
func (a *Contract) GetContractInfoByContractUid(req *contract.GetContractInfoByContractUidRequest) (rep *contract.GetContractInfoByContractUidRespond, err error) {
rep = &contract.GetContractInfoByContractUidRespond{}
contractInfo, err := dao.GetContractInfo(req.ContractUid)
if err != nil {
return
}
contract := &contract.Contracts{
ContractUid: contractInfo.Uid,
ArtistUid: contractInfo.ArtistUid,
ArtworkUid: contractInfo.ArtworkUid,
ContractId: contractInfo.ContractId,
TransactionId: contractInfo.TransactionId,
Type: contractInfo.Type,
ViewUrl: contractInfo.ViewUrl,
DownloadUrl: contractInfo.DownloadUrl,
State: contractInfo.State,
Status: contractInfo.Status,
LockTime: contractInfo.LockTime,
SignTime: contractInfo.SignTime,
}
rep.Data = contract
return
}
// func (a *Contract) ContractTxList(req *contract.ContractTxListRequest) (rep *contract.ContractTxListRespond, err error) {
// rep = &contract.ContractTxListRespond{}

View File

@ -0,0 +1,594 @@
package logic
import (
"fmt"
"github.com/fonchain/fonchain-artistinfo/cmd/internal/dao"
statement "github.com/fonchain/fonchain-artistinfo/pb/artistinfoStatement"
db "github.com/fonchain/fonchain-artistinfo/pkg/db"
"github.com/fonchain/fonchain-artistinfo/pkg/util"
"gorm.io/gorm"
)
type IStatement interface {
UploadExcelOneTx(req *statement.UploadExcelOneTxRequest) (rep *statement.UploadExcelOneTxRespond, err error)
UploadExcelTwoTx(req *statement.UploadExcelTwoTxRequest) (rep *statement.UploadExcelTwoTxRespond, err error)
UploadExcelOneCopy(req *statement.UploadExcelOneCopyRequest) (rep *statement.UploadExcelOneCopyRespond, err error)
UploadExcelTwoCopy(req *statement.UploadExcelTwoCopyRequest) (rep *statement.UploadExcelTwoCopyRespond, err error)
GetAllBatchTimeTx(req *statement.GetAllBatchTimeTxRequest) (rep *statement.GetAllBatchTimeTxRespond, err error)
GetArtworkSoldTxDetailList(req *statement.GetArtworkSoldTxDetailListRequest) (rep *statement.GetArtworkSoldTxDetailListRespond, err error)
StatementList(req *statement.StatementListRequest) (rep *statement.StatementListRespond, err error)
GetTxInfoByBatchUid(req *statement.GetTxInfoByBatchUidRequest) (rep *statement.GetTxInfoByBatchUidRespond, err error)
GetCopyInfoByBatchUid(req *statement.GetCopyInfoByBatchUidRequest) (rep *statement.GetCopyInfoByBatchUidRespond, err error)
}
func NewStatement() IStatement {
return &Statement{}
}
type Statement struct {
}
func (a *Statement) UploadExcelOneTx(req *statement.UploadExcelOneTxRequest) (rep *statement.UploadExcelOneTxRespond, err error) {
rep = &statement.UploadExcelOneTxRespond{}
fmt.Println("req.ExcelOneInfo", req.ExcelOneInfo)
//开启事务,遇到错误就回滚
tx := db.DB.Begin()
defer func() {
if err != nil {
tx.Rollback()
} else {
tx.Commit()
}
}()
for _, v := range req.ExcelOneInfo {
//查看是否已经被生成了批次,没有的就生成物权批次
exist, artworkTx, err := dao.IsExistArtworkTx(v.BatchTime, v.ArtistUid)
if err != nil {
return rep, err
}
if exist {
//获取批次uid
uid1, err := util.GetUid()
if err != nil {
return rep, err
}
//生成批次
err = dao.CreateArtworkTx(tx, uid1, v.BatchTime, v.ArtistUid, v.ArtistName)
if err != nil {
return rep, err
}
//对账单画作物权委托详情uid
uid2, err := util.GetUid()
if err != nil {
return rep, err
}
//将数据插入对账单画作物权委托详情
err = dao.CreateArtworkTxDetail(tx, uid1, uid2, v)
if err != nil {
return rep, err
}
} else {
//查看画作是否已经被该批次录入过,被录入过就跳过
count, err := dao.IsExistArtworkTxDetail(artworkTx.Uid, v.TfNum)
if err != nil {
return rep, err
}
if count != 1 {
continue
}
//获取批次uid
uid, err := util.GetUid()
if err != nil {
return rep, err
}
err = dao.CreateArtworkTxDetail(tx, artworkTx.Uid, uid, v)
if err != nil {
return rep, err
}
}
}
return
}
func (a *Statement) UploadExcelTwoTx(req *statement.UploadExcelTwoTxRequest) (rep *statement.UploadExcelTwoTxRespond, err error) {
rep = &statement.UploadExcelTwoTxRespond{}
//开启事务,遇到错误就回滚
tx := db.DB.Begin()
defer func() {
if err != nil {
tx.Rollback()
} else {
tx.Commit()
}
}()
for _, v := range req.ExcelTwoInfo {
//查看是否已经被生成了物权批次
exist, artworkTx, err := dao.IsExistArtworkTx(v.BatchTime, v.ArtistUid)
if err != nil {
return rep, err
}
//没有的就生成物权批次
if exist {
//获取批次uid
uid1, err := util.GetUid()
if err != nil {
return rep, err
}
//生成批次
err = dao.CreateArtworkTx(tx, uid1, v.BatchTime, v.ArtistUid, v.ArtistName)
if err != nil {
return rep, err
}
//对账单画作物权委托详情uid
uid2, err := util.GetUid()
if err != nil {
return rep, err
}
//将数据插入对账单画作物权销售委托详情
err = dao.CreateArtworkSoldTxDetail(tx, uid1, uid2, v)
if err != nil {
return rep, err
}
} else {
//查看画作是否已经被该批次录入过,被录入过就跳过
count, err := dao.IsExistArtworkSoldTxDetail(artworkTx.Uid, v.TfNum)
if err != nil {
return rep, err
}
if count != 1 {
continue
}
//获取批次uid
uid, err := util.GetUid()
if err != nil {
return rep, err
}
err = dao.CreateArtworkSoldTxDetail(tx, artworkTx.Uid, uid, v)
if err != nil {
return rep, err
}
}
}
return
}
func (a *Statement) UploadExcelOneCopy(req *statement.UploadExcelOneCopyRequest) (rep *statement.UploadExcelOneCopyRespond, err error) {
rep = &statement.UploadExcelOneCopyRespond{}
//开启事务,遇到错误就回滚
tx := db.DB.Begin()
defer func() {
if err != nil {
tx.Rollback()
} else {
tx.Commit()
}
}()
for _, v := range req.ExcelOneInfo {
//查看是否已经被生成了批次,没有的就生成版权批次
exist, artworkCopy, err := dao.IsExistArtworkCopy(v.BatchTime, v.ArtistUid)
if err != nil {
return rep, err
}
if exist {
//获取批次uid
uid1, err := util.GetUid()
if err != nil {
return rep, err
}
//生成批次
err = dao.CreateArtworkCopy(tx, uid1, v.BatchTime, v.ArtistUid, v.ArtistName)
if err != nil {
tx.Rollback()
return rep, err
}
//对账单画作物权委托详情uid
uid2, err := util.GetUid()
if err != nil {
return rep, err
}
//将数据插入对账单画作物权委托详情
err = dao.CreateArtworkCopyDetail(tx, uid1, uid2, v)
if err != nil {
return rep, err
}
} else {
count, err := dao.IsExistArtworkCopyDetail(artworkCopy.Uid, v.TfNum)
if err != nil {
return rep, err
}
if count != 1 {
continue
}
//获取批次uid
uid, err := util.GetUid()
if err != nil {
return rep, err
}
err = dao.CreateArtworkCopyDetail(tx, artworkCopy.Uid, uid, v)
if err != nil {
return rep, err
}
}
}
return
}
func (a *Statement) UploadExcelTwoCopy(req *statement.UploadExcelTwoCopyRequest) (rep *statement.UploadExcelTwoCopyRespond, err error) {
rep = &statement.UploadExcelTwoCopyRespond{}
//开启事务,遇到错误就回滚
tx := db.DB.Begin()
defer func() {
if err != nil {
tx.Rollback()
} else {
tx.Commit()
}
}()
for _, v := range req.ExcelTwoInfo {
//查看是否已经被生成了物权批次
exist, artworkCopy, err := dao.IsExistArtworkCopy(v.BatchTime, v.ArtistUid)
if err != nil {
return rep, err
}
//没有的就生成物权批次
if exist {
//获取批次uid
uid1, err := util.GetUid()
if err != nil {
return rep, err
}
//生成批次
err = dao.CreateArtworkCopy(tx, uid1, v.BatchTime, v.ArtistUid, v.ArtistName)
if err != nil {
tx.Rollback()
return rep, err
}
//对账单画作物权委托详情uid
uid2, err := util.GetUid()
if err != nil {
return rep, err
}
//将数据插入对账单画作物权销售委托详情
err = dao.CreateArtworkSoldCopyDetail(tx, uid1, uid2, v)
if err != nil {
return rep, err
}
} else {
//查看画作是否已经被该批次录入过,被录入过就跳过
count, err := dao.IsExistArtworkSoldCopyDetail(artworkCopy.Uid, v.TfNum)
if err != nil {
return rep, err
}
if count != 1 {
continue
}
//获取批次uid
uid, err := util.GetUid()
if err != nil {
return rep, err
}
err = dao.CreateArtworkSoldCopyDetail(tx, artworkCopy.Uid, uid, v)
if err != nil {
return rep, err
}
}
}
return
}
func (a *Statement) GetAllBatchTimeTx(req *statement.GetAllBatchTimeTxRequest) (rep *statement.GetAllBatchTimeTxRespond, err error) {
rep = &statement.GetAllBatchTimeTxRespond{}
//batchTime去重查询只获取batchTime字段值
batchTime, err := dao.GetAllBatchTimeTx()
if err != nil {
return
}
rep.BatchTime = batchTime
return
}
func (a *Statement) GetAllBatchTimeCopy(req *statement.GetAllBatchTimeCopyRequest) (rep *statement.GetAllBatchTimeCopyRespond, err error) {
rep = &statement.GetAllBatchTimeCopyRespond{}
//batchTime去重查询只获取batchTime字段值
batchTime, err := dao.GetAllBatchTimeCopy()
if err != nil {
return
}
rep.BatchTime = batchTime
return
}
func (a *Statement) GetArtworkSoldTxDetailList(req *statement.GetArtworkSoldTxDetailListRequest) (rep *statement.GetArtworkSoldTxDetailListRespond, err error) {
rep = &statement.GetArtworkSoldTxDetailListRespond{}
artistList := &statement.ArtistList{}
artworkSoldDetailList := &statement.ArtworkSoldDetailList{}
var query *gorm.DB = db.DB // 初始化query变量
//画家姓名不为空,模糊查询(根据画家姓名的某个字也可以查询)
if req.ArtistName != "" {
query = query.Where("artist_name LiKE ?", "%"+req.ArtistName+"%")
}
//批次不为空
if req.BatchTime != "" {
query = query.Where("batch_time = ?", req.BatchTime)
}
//画家姓名不为空
if req.State != 0 {
query = query.Where("state = ?", req.State)
}
//合同分页查询操作
if req.Page < 1 {
req.Page = 1
}
if req.Num < 1 {
req.Num = 15
}
offset := (req.Page - 1) * req.Num
artworkTxList, err := dao.GetArtworkTxList(query, req.Num, offset)
if err != nil {
return
}
for _, v := range artworkTxList {
artistList.BatchUid = v.Uid
artistList.ArtistName = v.ArtistName
artistList.BatchTime = v.BatchTime
artistList.State = v.State
//当已经签署了合同时
if v.State == 3 {
//获取合同预览和下载链接
contract, err := dao.GetContractUrlTx(v.Uid)
if err != nil {
return rep, err
}
artistList.ViewUrl = contract.ViewUrl
artistList.DownloadUrl = contract.DownloadUrl
} else {
artistList.ViewUrl = ""
artistList.DownloadUrl = ""
}
//查询对账单画作物权销售委托详情
artworkSoldTxDetail, err := dao.GetArtworkSoldTxDetailList(v.Uid)
if err != nil {
return rep, err
}
//获取该画家该批次所有的已售出的画信息
for _, m := range artworkSoldTxDetail {
artworkSoldDetailList.ArtworkName = m.ArtworkName
artworkSoldDetailList.TfNum = m.TfNum
artworkSoldDetailList.Ruler = m.Ruler
artworkSoldDetailList.SaleNo = m.SaleNo
artworkSoldDetailList.CompleteDate = m.CompleteDate
artworkSoldDetailList.SalePrice = m.SalePrice
artistList.ArtworkSoldDetailList = append(artistList.ArtworkSoldDetailList, artworkSoldDetailList)
}
rep.ArtistList = append(rep.ArtistList, artistList)
}
return
}
func (a *Statement) GetArtworkSoldCopyDetailList(req *statement.GetArtworkSoldCopyDetailListRequest) (rep *statement.GetArtworkSoldCopyDetailListRespond, err error) {
rep = &statement.GetArtworkSoldCopyDetailListRespond{}
artistList := &statement.ArtistList{}
artworkSoldDetailList := &statement.ArtworkSoldDetailList{}
var query *gorm.DB = db.DB // 初始化query变量
//画家姓名不为空
if req.ArtistName != "" {
query = query.Where("artist_name LiKE ?", "%"+req.ArtistName+"%")
}
//批次不为空
if req.BatchTime != "" {
query = query.Where("batch_time = ?", req.BatchTime)
}
//画家姓名不为空
if req.State != 0 {
query = query.Where("state = ?", req.State)
}
//合同分页查询操作
if req.Page < 1 {
req.Page = 1
}
if req.Num < 1 {
req.Num = 15
}
offset := (req.Page - 1) * req.Num
artworkCopyList, err := dao.GetArtworkCopyList(query, req.Num, offset)
if err != nil {
return
}
for _, v := range artworkCopyList {
artistList.BatchUid = v.Uid
artistList.ArtistName = v.ArtistName
artistList.BatchTime = v.BatchTime
artistList.State = v.State
//当已经签署了合同时
if v.State == 3 {
//获取合同预览和下载链接
contract, err := dao.GetContractUrlTx(v.Uid)
if err != nil {
return rep, err
}
artistList.ViewUrl = contract.ViewUrl
artistList.DownloadUrl = contract.DownloadUrl
} else {
artistList.ViewUrl = ""
artistList.DownloadUrl = ""
}
//查询对账单画作物权销售委托详情
artworkSoldTxDetail, err := dao.GetArtworkSoldTxDetailList(v.Uid)
if err != nil {
return rep, err
}
//获取该画家该批次所有的已售出的画信息
for _, m := range artworkSoldTxDetail {
artworkSoldDetailList.ArtworkName = m.ArtworkName
artworkSoldDetailList.TfNum = m.TfNum
artworkSoldDetailList.Ruler = m.Ruler
artworkSoldDetailList.SaleNo = m.SaleNo
artworkSoldDetailList.CompleteDate = m.CompleteDate
artworkSoldDetailList.SalePrice = m.SalePrice
artistList.ArtworkSoldDetailList = append(artistList.ArtworkSoldDetailList, artworkSoldDetailList)
}
rep.ArtistList = append(rep.ArtistList, artistList)
}
return
}
func (a *Statement) StatementList(req *statement.StatementListRequest) (rep *statement.StatementListRespond, err error) {
//查看是否有该画家
user, err := dao.GetArtistInfoById(req.ArtistUid)
if err != nil {
return
}
ContractData, err := dao.StatementList(user.MgmtArtistUid, req.State)
if err != nil {
return
}
rep = &statement.StatementListRespond{
Data: ContractData,
}
return
}
func (a *Statement) GetTxInfoByBatchUid(req *statement.GetTxInfoByBatchUidRequest) (rep *statement.GetTxInfoByBatchUidRespond, err error) {
rep = &statement.GetTxInfoByBatchUidRespond{}
//获取画家名
artworkTx, err := dao.GetTxArtistNameByBatchUid(req.BatchUid)
if err != nil {
return
}
rep.ArtistName = artworkTx.ArtistName
//获取物权画作详细信息
artworkTxDetails, err := dao.GetArtworkTxDetailByBatchUid(req.BatchUid)
if err != nil {
return
}
rep.ArtistName = artworkTx.ArtistName
//获取物权画作被售卖详细信息
artworkSoldTxDetails, err := dao.GetArtworkSoldTxDetailByBatchUid(req.BatchUid)
if err != nil {
return
}
artworkTxDetail := new(statement.ArtworkTxDetail)
artworkSoldTxDetail := new(statement.ArtworkSoldTxDetail)
for _, v := range artworkTxDetails {
artworkTxDetail.TfNum = v.TfNum
artworkTxDetail.ArtworkName = v.ArtworkName
artworkTxDetail.Ruler = v.Ruler
artworkTxDetail.MinPrice = v.MinPrice
artworkTxDetail.GuaranteePrice = v.GuaranteePrice
rep.ArtworkTxDetail = append(rep.ArtworkTxDetail, artworkTxDetail)
}
for _, v := range artworkSoldTxDetails {
artworkSoldTxDetail.TfNum = v.TfNum
artworkSoldTxDetail.ArtworkName = v.ArtworkName
artworkSoldTxDetail.Ruler = v.Ruler
artworkSoldTxDetail.SaleNo = v.SaleNo
artworkSoldTxDetail.CompleteDate = v.CompleteDate
artworkSoldTxDetail.SalePrice = v.SalePrice
rep.ArtworkSoldTxDetail = append(rep.ArtworkSoldTxDetail, artworkSoldTxDetail)
}
return
}
func (a *Statement) GetCopyInfoByBatchUid(req *statement.GetCopyInfoByBatchUidRequest) (rep *statement.GetCopyInfoByBatchUidRespond, err error) {
rep = &statement.GetCopyInfoByBatchUidRespond{}
//获取画家名
artworkTx, err := dao.GetCopyArtistNameByBatchUid(req.BatchUid)
if err != nil {
return
}
rep.ArtistName = artworkTx.ArtistName
//获取版权画作详细信息
artworkTxDetails, err := dao.GetArtworkCopyDetailByBatchUid(req.BatchUid)
if err != nil {
return
}
rep.ArtistName = artworkTx.ArtistName
//获取版权画作被售卖详细信息
artworkSoldTxDetails, err := dao.GetArtworkSoldCopyDetailByBatchUid(req.BatchUid)
if err != nil {
return
}
artworkCopyDetail := new(statement.ArtworkCopyDetail)
artworkSoldCopyDetail := new(statement.ArtworkSoldCopyDetail)
for _, v := range artworkTxDetails {
artworkCopyDetail.TfNum = v.TfNum
artworkCopyDetail.ArtworkName = v.ArtworkName
artworkCopyDetail.Ruler = v.Ruler
artworkCopyDetail.MinPrice = v.MinPrice
artworkCopyDetail.GuaranteePrice = v.GuaranteePrice
rep.ArtworkCopyDetail = append(rep.ArtworkCopyDetail, artworkCopyDetail)
}
for _, v := range artworkSoldTxDetails {
artworkSoldCopyDetail.TfNum = v.TfNum
artworkSoldCopyDetail.ArtworkName = v.ArtworkName
artworkSoldCopyDetail.Ruler = v.Ruler
artworkSoldCopyDetail.SaleNo = v.SaleNo
artworkSoldCopyDetail.CompleteDate = v.CompleteDate
artworkSoldCopyDetail.MinPrice = v.MinPrice
artworkSoldCopyDetail.SalePrice = v.SalePrice
artworkSoldCopyDetail.GuaranteePrice = v.GuaranteePrice
rep.ArtworkSoldCopyDetail = append(rep.ArtworkSoldCopyDetail, artworkSoldCopyDetail)
}
return
}

View File

@ -1,51 +0,0 @@
package model
// 对账单委托画作批次
type StatementBatch struct {
Model
// StType int32 `gorm:"column:st_type;unqiueIndex:sttype_uid_batchtime_idx;comment:对账单类型 1=版权 2=物权;"`
ArtistUid string `gorm:"column:artist_uid;unqiueIndex:sttype_uid_batchtime_idx;comment:画家uid"`
ArtistName string `gorm:"column:artist_name;comment:画家姓名;"`
BatchTime string `gorm:"column:batch_time;unqiueIndex:sttype_uid_batchtime_idx;comment:批次时间;"`
FlowStatus int32 `gorm:"column:flow_status;default:1;comment:流程状态 1=未生成 2=已生成未签署 3=已签署"`
// FileUrl string `gorm:"column:file_url,comment:对账单文件地址;"`
EntrustList []ArtworkEntrustDetail `gorm:"foreignKey:BatchId"` //当前批次的委托单详情
SalesList []ArtworkSalesDetail `gorm:"foreignKey:BatchId"` //当前批次的销售单详情
}
func (StatementBatch) TableName() string {
return "statement_batch"
}
// 对账单画作委托详情
type ArtworkEntrustDetail struct {
Model
BatchId int64 `gorm:"column:batch_id;unqiueIndex:batchid_tfnum_idx;comment:批次id;"`
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:委托销售底价"`
GuaranteePrice float32 `gorm:"column:guarantee_price;comment:已收取保证金;"`
}
func (ArtworkEntrustDetail) TableName() string {
return "artwork_entrust_detail"
}
//对账单画作销售详情
type ArtworkSalesDetail struct {
Model
BatchId int64 `gorm:"column:batch_id;unqiueIndex:batchid_tfnum_idx;comment:批次id;"`
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:成交日期"`
}
func (ArtworkSalesDetail) TableName() string {
return "artwork_sales_detail"
}

View File

@ -4,22 +4,29 @@ 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:合同类型;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:合同状态;NOT NULL" json:"state"` //1 未签署
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"`
BatchId int32 `gorm:"column:batch_id;comment:批次ID" json:"batch_id"`
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
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;default:1;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"`
BatchTime string `gorm:"column:batch_time;comment:批次时间" json:"batch_time"`
BatchUid string `gorm:"column:batch_uid;comment:批次ID" json:"batch_uid"`
ArtworkTx *ArtworkTx `gorm:"foreignKey:BatchUid;references:Uid"` //当前批次的物权委托单
ArtworkCopy *ArtworkCopy `gorm:"foreignKey:BatchUid;references:Uid"` //当前批次的版权委托单
ArtworkTxDetail []ArtworkTxDetail `gorm:"foreignKey:BatchUid;references:BatchUid"` //当前批次的物权委托单详情
ArtworkSoldTxDetail []ArtworkSoldTxDetail `gorm:"foreignKey:BatchUid;references:BatchUid"` //当前批次的已被售卖物权委托单详情
ArtworkCopyDetail []ArtworkCopyDetail `gorm:"foreignKey:BatchUid;references:BatchUid"` //当前批次的版权委托单详情
ArtworkSoldCopyDetail []ArtworkSoldCopyDetail `gorm:"foreignKey:BatchUid;references:BatchUid"` //当前批次的已被售卖版权委托单详情
CreatedAt int32 `gorm:"column:created_at;autoCreateTime"`
UpdatedAt int32 `gorm:"column:updated_at;autoCreateTime"`
DeletedAt soft_delete.DeletedAt
OldMgmtDataId int32 `gorm:"column:old_mgmt_data_id"` //老画家宝中的id
}

98
cmd/model/statement.go Normal file
View File

@ -0,0 +1,98 @@
package model
import "gorm.io/plugin/soft_delete"
const (
InitPage = 1
PageSize = 15
)
//对账单画作物权
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:对账单画作物权表的唯一表示,即批次Uid;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"`
BatchTime string `gorm:"column:batch_time;comment:批次时间" json:"batch_time"`
State int32 `gorm:"column:state;default:1;type:int(1);comment:对账单状态,1:未生成合同 2:已生成数据库一条合同数据(不管画家有没有点击过都是已生成未签署) 3:已签署(画家在画家宝那边签署了合同);NOT NULL" json:"state"`
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:对账单画作物权表的唯一表示,即批次Uid;NOT NULL" json:"batch_uid"`
TfNum string `gorm:"column:tf_num;unqiueIndex:batchid_tfnum_idx;comment:"泰丰画作编号"`
ArtworkName string `gorm:"column:artwork_name;comment:画作名称"`
Ruler float32 `gorm:"column:ruler;comment:平尺"`
MinPrice float32 `gorm:"column:min_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
}
// 对账单画作物权销售委托详情(该画家一个批次的全部已被售卖了的画作)
type ArtworkSoldTxDetail 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:对账单画作物权表的唯一表示,即批次Uid;NOT NULL" json:"batch_uid"`
TfNum string `gorm:"column:tf_num;unqiueIndex:batchid_tfnum_idx;comment:"泰丰画作编号"`
ArtworkName string `gorm:"column:artwork_name;comment:画作名称"`
Ruler float32 `gorm:"column:ruler;comment:平尺"`
SaleNo string `gorm:"column:sale_no;comment:销售单号"`
CompleteDate string `gorm:"column:complete_date;comment:成交日期"`
SalePrice float32 `gorm:"column:sale_price;comment:画作售价"`
CreatedAt int32 `gorm:"column:created_at;autoCreateTime"`
UpdatedAt int32 `gorm:"column:updated_at;autoCreateTime"`
DeletedAt soft_delete.DeletedAt
}
//对账单画作版权
type ArtworkCopy struct {
ID int32 `gorm:"column:id;type:int(11);primary_key;AUTO_INCREMENT" json:"id"`
Uid string `gorm:"column:uid;type:varchar(100);comment:对账单画作版权表的唯一表示,即批次Uid;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"`
BatchTime string `gorm:"column:batch_time;comment:批次时间" json:"batch_time"`
State int32 `gorm:"column:state;default:1;type:int(1);comment:对账单状态,1:未生成合同 2:已生成数据库一条合同数据(不管画家有没有点击过都是已生成未签署) 3:已签署(画家在画家宝那边签署了合同);NOT NULL" json:"state"`
CreatedAt int32 `gorm:"column:created_at;autoCreateTime"`
UpdatedAt int32 `gorm:"column:updated_at;autoCreateTime"`
DeletedAt soft_delete.DeletedAt
}
// 对账单画作版权委托详情(该画家一个批次的全部画作)
type ArtworkCopyDetail 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:对账单画作版权表的唯一表示,即批次Uid;NOT NULL" json:"batch_uid"`
TfNum string `gorm:"column:tf_num;unqiueIndex:batchid_tfnum_idx;comment:"泰丰画作编号"`
ArtworkName string `gorm:"column:artwork_name;comment:画作名称"`
Ruler float32 `gorm:"column:ruler;comment:平尺"`
MinPrice float32 `gorm:"column:min_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
}
// 对账单画作版权委托售卖详情(该画家一个批次的全部已被售卖了的画作)
type ArtworkSoldCopyDetail 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:对账单画作版权表的唯一表示,即批次Uid;NOT NULL" json:"batch_uid"`
TfNum string `gorm:"column:tf_num;unqiueIndex:batchid_tfnum_idx;comment:"泰丰画作编号"`
ArtworkName string `gorm:"column:artwork_name;comment:画作名称"`
Ruler float32 `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
}

0
conf/buildDate Normal file
View File

View File

@ -10,7 +10,7 @@ mode = dev #正式prod #测试dev
# DbName = artistmgmttest
Db = mysql
DbHost = 127.0.0.1
DbPort = 13307
DbPort = 3306
DbUser = root
DbPassWord = 123456
DbName = artistmgmtprod

View File

@ -27,6 +27,9 @@ dubbo:
ArtistInfoContractProvider:
interface: com.fontree.microservices.common.ArtistInfoContract
retries: 100
ArtistInfoStatementProvider:
interface: com.fontree.microservices.common.ArtistInfoStatement
retries: 100
#ContractProvider:
# interface: com.fontree.microservices.common.Contract
# retries: 0

View File

@ -31,6 +31,9 @@ dubbo:
ArtistInfoContractProvider:
interface: com.fontree.microservices.common.ArtistInfoContract
retries: 100
ArtistInfoStatementProvider:
interface: com.fontree.microservices.common.ArtistInfoStatement
retries: 100
#ContractProvider:
# interface: com.fontree.microservices.common.Contract
# retries: 0

View File

@ -31,6 +31,9 @@ dubbo:
ArtistInfoContractProvider:
interface: com.fontree.microservices.common.ArtistInfoContract
retries: 100
ArtistInfoStatementProvider:
interface: com.fontree.microservices.common.ArtistInfoStatement
retries: 100
consumer:
request-timeout: 120s
references:

View File

@ -31,6 +31,9 @@ dubbo:
ArtistInfoContractProvider:
interface: com.fontree.microservices.common.ArtistInfoContract
retries: 100
ArtistInfoStatementProvider:
interface: com.fontree.microservices.common.ArtistInfoStatement
retries: 100
#ContractProvider:
# interface: com.fontree.microservices.common.Contract
# retries: 0

View File

@ -31,6 +31,9 @@ dubbo:
ArtistInfoContractProvider:
interface: com.fontree.microservices.common.ArtistInfoContract
retries: 100
ArtistInfoStatementProvider:
interface: com.fontree.microservices.common.ArtistInfoStatement
retries: 100
#ContractProvider:
# interface: com.fontree.microservices.common.Contract
# retries: 0

0
docs/README.md Normal file
View File

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@ -1,418 +0,0 @@
// Code generated by protoc-gen-go-triple. DO NOT EDIT.
// versions:
// - protoc-gen-go-triple v1.0.8
// - protoc v4.22.0--rc2
// source: pb/artistinfoStatement.proto
package artistinfoStatement
import (
context "context"
protocol "dubbo.apache.org/dubbo-go/v3/protocol"
dubbo3 "dubbo.apache.org/dubbo-go/v3/protocol/dubbo3"
invocation "dubbo.apache.org/dubbo-go/v3/protocol/invocation"
grpc_go "github.com/dubbogo/grpc-go"
codes "github.com/dubbogo/grpc-go/codes"
metadata "github.com/dubbogo/grpc-go/metadata"
status "github.com/dubbogo/grpc-go/status"
common "github.com/dubbogo/triple/pkg/common"
constant "github.com/dubbogo/triple/pkg/common/constant"
triple "github.com/dubbogo/triple/pkg/triple"
emptypb "google.golang.org/protobuf/types/known/emptypb"
)
// This is a compile-time assertion to ensure that this generated file
// is compatible with the grpc package it is being compiled against.
const _ = grpc_go.SupportPackageIsVersion7
// StatementClient is the client API for Statement service.
//
// 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 {
CreateStatementBatch(ctx context.Context, in *StatementBatchRequest, opts ...grpc_go.CallOption) (*CreateStatementBatchResponse, common.ErrorWithAttachment)
BatchCreateStatementBatch(ctx context.Context, in *BatchCreateStatementBatchRequest, opts ...grpc_go.CallOption) (*emptypb.Empty, common.ErrorWithAttachment)
GetStatementBatchList(ctx context.Context, in *GetStatementBatchListRequest, opts ...grpc_go.CallOption) (*GetStatementBatchListResponse, common.ErrorWithAttachment)
GetStatementBatchTimeMenus(ctx context.Context, in *GetStatementBatchListRequest, opts ...grpc_go.CallOption) (*GetStatementBatchTimeMenusResponse, common.ErrorWithAttachment)
CreateStatementDetail(ctx context.Context, in *StatementDetailRequest, opts ...grpc_go.CallOption) (*CreateStatementDetailResponse, common.ErrorWithAttachment)
BatchCreateStatementDetail(ctx context.Context, in *BatchCreateStatementDetailRequest, opts ...grpc_go.CallOption) (*emptypb.Empty, common.ErrorWithAttachment)
GetStatementDetailList(ctx context.Context, in *GetStatementDetailListRequest, opts ...grpc_go.CallOption) (*GetStatementDetailListResponse, common.ErrorWithAttachment)
}
type statementClient struct {
cc *triple.TripleConn
}
type StatementClientImpl struct {
CreateStatementBatch func(ctx context.Context, in *StatementBatchRequest) (*CreateStatementBatchResponse, error)
BatchCreateStatementBatch func(ctx context.Context, in *BatchCreateStatementBatchRequest) (*emptypb.Empty, error)
GetStatementBatchList func(ctx context.Context, in *GetStatementBatchListRequest) (*GetStatementBatchListResponse, error)
GetStatementBatchTimeMenus func(ctx context.Context, in *GetStatementBatchListRequest) (*GetStatementBatchTimeMenusResponse, error)
CreateStatementDetail func(ctx context.Context, in *StatementDetailRequest) (*CreateStatementDetailResponse, error)
BatchCreateStatementDetail func(ctx context.Context, in *BatchCreateStatementDetailRequest) (*emptypb.Empty, error)
GetStatementDetailList func(ctx context.Context, in *GetStatementDetailListRequest) (*GetStatementDetailListResponse, error)
}
func (c *StatementClientImpl) GetDubboStub(cc *triple.TripleConn) StatementClient {
return NewStatementClient(cc)
}
func (c *StatementClientImpl) XXX_InterfaceName() string {
return "artistinfo.Statement"
}
func NewStatementClient(cc *triple.TripleConn) StatementClient {
return &statementClient{cc}
}
func (c *statementClient) CreateStatementBatch(ctx context.Context, in *StatementBatchRequest, opts ...grpc_go.CallOption) (*CreateStatementBatchResponse, common.ErrorWithAttachment) {
out := new(CreateStatementBatchResponse)
interfaceKey := ctx.Value(constant.InterfaceKey).(string)
return out, c.cc.Invoke(ctx, "/"+interfaceKey+"/CreateStatementBatch", in, out)
}
func (c *statementClient) BatchCreateStatementBatch(ctx context.Context, in *BatchCreateStatementBatchRequest, opts ...grpc_go.CallOption) (*emptypb.Empty, common.ErrorWithAttachment) {
out := new(emptypb.Empty)
interfaceKey := ctx.Value(constant.InterfaceKey).(string)
return out, c.cc.Invoke(ctx, "/"+interfaceKey+"/BatchCreateStatementBatch", in, out)
}
func (c *statementClient) GetStatementBatchList(ctx context.Context, in *GetStatementBatchListRequest, opts ...grpc_go.CallOption) (*GetStatementBatchListResponse, common.ErrorWithAttachment) {
out := new(GetStatementBatchListResponse)
interfaceKey := ctx.Value(constant.InterfaceKey).(string)
return out, c.cc.Invoke(ctx, "/"+interfaceKey+"/GetStatementBatchList", in, out)
}
func (c *statementClient) GetStatementBatchTimeMenus(ctx context.Context, in *GetStatementBatchListRequest, opts ...grpc_go.CallOption) (*GetStatementBatchTimeMenusResponse, common.ErrorWithAttachment) {
out := new(GetStatementBatchTimeMenusResponse)
interfaceKey := ctx.Value(constant.InterfaceKey).(string)
return out, c.cc.Invoke(ctx, "/"+interfaceKey+"/GetStatementBatchTimeMenus", in, out)
}
func (c *statementClient) CreateStatementDetail(ctx context.Context, in *StatementDetailRequest, opts ...grpc_go.CallOption) (*CreateStatementDetailResponse, common.ErrorWithAttachment) {
out := new(CreateStatementDetailResponse)
interfaceKey := ctx.Value(constant.InterfaceKey).(string)
return out, c.cc.Invoke(ctx, "/"+interfaceKey+"/CreateStatementDetail", in, out)
}
func (c *statementClient) BatchCreateStatementDetail(ctx context.Context, in *BatchCreateStatementDetailRequest, opts ...grpc_go.CallOption) (*emptypb.Empty, common.ErrorWithAttachment) {
out := new(emptypb.Empty)
interfaceKey := ctx.Value(constant.InterfaceKey).(string)
return out, c.cc.Invoke(ctx, "/"+interfaceKey+"/BatchCreateStatementDetail", in, out)
}
func (c *statementClient) GetStatementDetailList(ctx context.Context, in *GetStatementDetailListRequest, opts ...grpc_go.CallOption) (*GetStatementDetailListResponse, common.ErrorWithAttachment) {
out := new(GetStatementDetailListResponse)
interfaceKey := ctx.Value(constant.InterfaceKey).(string)
return out, c.cc.Invoke(ctx, "/"+interfaceKey+"/GetStatementDetailList", in, out)
}
// StatementServer is the server API for Statement service.
// All implementations must embed UnimplementedStatementServer
// for forward compatibility
type StatementServer interface {
CreateStatementBatch(context.Context, *StatementBatchRequest) (*CreateStatementBatchResponse, error)
BatchCreateStatementBatch(context.Context, *BatchCreateStatementBatchRequest) (*emptypb.Empty, error)
GetStatementBatchList(context.Context, *GetStatementBatchListRequest) (*GetStatementBatchListResponse, error)
GetStatementBatchTimeMenus(context.Context, *GetStatementBatchListRequest) (*GetStatementBatchTimeMenusResponse, error)
CreateStatementDetail(context.Context, *StatementDetailRequest) (*CreateStatementDetailResponse, error)
BatchCreateStatementDetail(context.Context, *BatchCreateStatementDetailRequest) (*emptypb.Empty, error)
GetStatementDetailList(context.Context, *GetStatementDetailListRequest) (*GetStatementDetailListResponse, error)
mustEmbedUnimplementedStatementServer()
}
// UnimplementedStatementServer must be embedded to have forward compatible implementations.
type UnimplementedStatementServer struct {
proxyImpl protocol.Invoker
}
func (UnimplementedStatementServer) CreateStatementBatch(context.Context, *StatementBatchRequest) (*CreateStatementBatchResponse, error) {
return nil, status.Errorf(codes.Unimplemented, "method CreateStatementBatch not implemented")
}
func (UnimplementedStatementServer) BatchCreateStatementBatch(context.Context, *BatchCreateStatementBatchRequest) (*emptypb.Empty, error) {
return nil, status.Errorf(codes.Unimplemented, "method BatchCreateStatementBatch not implemented")
}
func (UnimplementedStatementServer) GetStatementBatchList(context.Context, *GetStatementBatchListRequest) (*GetStatementBatchListResponse, error) {
return nil, status.Errorf(codes.Unimplemented, "method GetStatementBatchList not implemented")
}
func (UnimplementedStatementServer) GetStatementBatchTimeMenus(context.Context, *GetStatementBatchListRequest) (*GetStatementBatchTimeMenusResponse, error) {
return nil, status.Errorf(codes.Unimplemented, "method GetStatementBatchTimeMenus not implemented")
}
func (UnimplementedStatementServer) CreateStatementDetail(context.Context, *StatementDetailRequest) (*CreateStatementDetailResponse, error) {
return nil, status.Errorf(codes.Unimplemented, "method CreateStatementDetail not implemented")
}
func (UnimplementedStatementServer) BatchCreateStatementDetail(context.Context, *BatchCreateStatementDetailRequest) (*emptypb.Empty, error) {
return nil, status.Errorf(codes.Unimplemented, "method BatchCreateStatementDetail not implemented")
}
func (UnimplementedStatementServer) GetStatementDetailList(context.Context, *GetStatementDetailListRequest) (*GetStatementDetailListResponse, error) {
return nil, status.Errorf(codes.Unimplemented, "method GetStatementDetailList not implemented")
}
func (s *UnimplementedStatementServer) XXX_SetProxyImpl(impl protocol.Invoker) {
s.proxyImpl = impl
}
func (s *UnimplementedStatementServer) XXX_GetProxyImpl() protocol.Invoker {
return s.proxyImpl
}
func (s *UnimplementedStatementServer) XXX_ServiceDesc() *grpc_go.ServiceDesc {
return &Statement_ServiceDesc
}
func (s *UnimplementedStatementServer) XXX_InterfaceName() string {
return "artistinfo.Statement"
}
func (UnimplementedStatementServer) mustEmbedUnimplementedStatementServer() {}
// UnsafeStatementServer may be embedded to opt out of forward compatibility for this service.
// Use of this interface is not recommended, as added methods to StatementServer will
// result in compilation errors.
type UnsafeStatementServer interface {
mustEmbedUnimplementedStatementServer()
}
func RegisterStatementServer(s grpc_go.ServiceRegistrar, srv StatementServer) {
s.RegisterService(&Statement_ServiceDesc, srv)
}
func _Statement_CreateStatementBatch_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc_go.UnaryServerInterceptor) (interface{}, error) {
in := new(StatementBatchRequest)
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("CreateStatementBatch", 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_BatchCreateStatementBatch_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc_go.UnaryServerInterceptor) (interface{}, error) {
in := new(BatchCreateStatementBatchRequest)
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("BatchCreateStatementBatch", 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_GetStatementBatchList_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc_go.UnaryServerInterceptor) (interface{}, error) {
in := new(GetStatementBatchListRequest)
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("GetStatementBatchList", 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_GetStatementBatchTimeMenus_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc_go.UnaryServerInterceptor) (interface{}, error) {
in := new(GetStatementBatchListRequest)
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("GetStatementBatchTimeMenus", 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_CreateStatementDetail_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc_go.UnaryServerInterceptor) (interface{}, error) {
in := new(StatementDetailRequest)
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("CreateStatementDetail", 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_BatchCreateStatementDetail_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc_go.UnaryServerInterceptor) (interface{}, error) {
in := new(BatchCreateStatementDetailRequest)
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("BatchCreateStatementDetail", 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_GetStatementDetailList_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc_go.UnaryServerInterceptor) (interface{}, error) {
in := new(GetStatementDetailListRequest)
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("GetStatementDetailList", 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)
var Statement_ServiceDesc = grpc_go.ServiceDesc{
ServiceName: "artistinfo.Statement",
HandlerType: (*StatementServer)(nil),
Methods: []grpc_go.MethodDesc{
{
MethodName: "CreateStatementBatch",
Handler: _Statement_CreateStatementBatch_Handler,
},
{
MethodName: "BatchCreateStatementBatch",
Handler: _Statement_BatchCreateStatementBatch_Handler,
},
{
MethodName: "GetStatementBatchList",
Handler: _Statement_GetStatementBatchList_Handler,
},
{
MethodName: "GetStatementBatchTimeMenus",
Handler: _Statement_GetStatementBatchTimeMenus_Handler,
},
{
MethodName: "CreateStatementDetail",
Handler: _Statement_CreateStatementDetail_Handler,
},
{
MethodName: "BatchCreateStatementDetail",
Handler: _Statement_BatchCreateStatementDetail_Handler,
},
{
MethodName: "GetStatementDetailList",
Handler: _Statement_GetStatementDetailList_Handler,
},
},
Streams: []grpc_go.StreamDesc{},
Metadata: "pb/artistinfoStatement.proto",
}

File diff suppressed because it is too large Load Diff

View File

@ -0,0 +1,230 @@
syntax = "proto3";
package statement;
option go_package = "./;statement";
service Statement {
rpc UploadExcelOneTx (UploadExcelOneTxRequest) returns (UploadExcelOneTxRespond) {}
rpc UploadExcelTwoTx (UploadExcelTwoTxRequest) returns (UploadExcelTwoTxRespond) {}
rpc UploadExcelOneCopy (UploadExcelOneCopyRequest) returns (UploadExcelOneCopyRespond) {}
rpc UploadExcelTwoCopy (UploadExcelTwoCopyRequest) returns (UploadExcelTwoCopyRespond) {}
rpc GetAllBatchTimeTx (GetAllBatchTimeTxRequest) returns (GetAllBatchTimeTxRespond) {}
rpc GetAllBatchTimeCopy (GetAllBatchTimeCopyRequest) returns (GetAllBatchTimeCopyRespond) {}
rpc GetArtworkSoldTxDetailList (GetArtworkSoldTxDetailListRequest) returns (GetArtworkSoldTxDetailListRespond) {}
rpc GetArtworkSoldCopyDetailList (GetArtworkSoldCopyDetailListRequest) returns (GetArtworkSoldCopyDetailListRespond) {}
rpc StatementList (StatementListRequest) returns (StatementListRespond) {}
rpc GetTxInfoByBatchUid (GetTxInfoByBatchUidRequest) returns (GetTxInfoByBatchUidRespond) {}
rpc GetCopyInfoByBatchUid (GetCopyInfoByBatchUidRequest) returns (GetCopyInfoByBatchUidRespond) {}
}
message Contracts{
string contractUid = 1 [json_name = "contract_uid"];
string artistUid = 2 [json_name = "artist_uid"];
string artworkUid = 3 [json_name = "artwork_uid"];
string contractId = 4 [json_name = "contract_id"];
string transactionId = 5 [json_name = "transaction_id"];
int32 type = 6 [json_name = "type"];
string viewUrl = 7 [json_name = "view_url"];
string downloadUrl = 8 [json_name = "download_url"];
int32 state = 9 [json_name = "state"];
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 batchTime = 14 [json_name = "batch_time"];
string batchUid = 15 [json_name = "batch_uid"];
}
message ArtworkTxDetail{
string batchUid = 1 [json_name = "batch_uid"];
string tfNum = 2 [json_name = "TfNum"];
string artworkName = 3 [json_name = "artwork_name"];
float ruler = 4 [json_name = "ruler"];
float minPrice = 5 [json_name = "min_price"];
float guaranteePrice = 6 [json_name = "guarantee_price"];
}
message ArtworkSoldTxDetail{
string batchUid = 1 [json_name = "batch_uid"];
string tfNum = 2 [json_name = "TfNum"];
string artworkName = 3 [json_name = "artwork_name"];
float 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 ArtworkCopyDetail{
string batchUid = 1 [json_name = "batch_uid"];
string tfNum = 2 [json_name = "TfNum"];
string artworkName = 3 [json_name = "artwork_name"];
float ruler = 4 [json_name = "ruler"];
float minPrice = 5 [json_name = "min_price"];
float guaranteePrice = 6 [json_name = "guarantee_price"];
}
message ArtworkSoldCopyDetail{
string batchUid = 1 [json_name = "batch_uid"];
string tfNum = 2 [json_name = "TfNum"];
string artworkName = 3 [json_name = "artwork_name"];
float 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 ExcelOneInfo {
string artistUid = 1 [json_name = "artist_uid"];
string batchTime = 2 [json_name = "batch_time"];
string artistName = 3 [json_name = "artist_uid"];
string tfNum = 4 [json_name = "tf_num"];
string artworkName = 5 [json_name = "artwork_name"];
float ruler = 6 [json_name = "ruler"];
float minPrice = 7 [json_name = "min_price"];
float guaranteePrice = 8 [json_name = "guarantee_price"];
}
message ExcelTwoInfo{
string artistUid = 1 [json_name = "artist_uid"];
string batchTime = 2 [json_name = "batch_time"];
string artistName = 3 [json_name = "artist_uid"];
string tfNum = 4 [json_name = "tf_num"];
string artworkName = 5 [json_name = "artwork_name"];
float ruler = 6 [json_name = "ruler"];
string saleNo = 7 [json_name = "saleNo"];
string completeDate = 8 [json_name = "complete_date"];
float salePrice = 9 [json_name = "salePrice"];
}
message ArtworkSoldDetailList{
string artworkName = 6 [json_name = "artwork_name"];
string tfNum = 7 [json_name = "tf_num"];
float ruler = 8 [json_name = "ruler"];
string saleNo = 9 [json_name = "saleNo"];
string completeDate = 10 [json_name = "complete_date"];
float salePrice = 11 [json_name = "salePrice"];
}
message ArtistList {
string batchUid = 1 [json_name = "batch_uid"];
string artistName = 2 [json_name = "artist_uid"];
string batchTime = 3 [json_name = "batch_time"];
int32 state = 4 [json_name = "state"];
int32 status = 5 [json_name = "status"];
string viewUrl = 6 [json_name = "view_url"];
string downloadUrl = 7 [json_name = "download_url"];
repeated ArtworkSoldDetailList artworkSoldDetailList = 8 [json_name = "artwork_sold_detail_list"];
}
message UploadExcelOneTxRequest {
repeated ExcelOneInfo excelOneInfo = 1 [json_name = "excel_one_info"];
}
message UploadExcelOneTxRespond {
string msg = 1 [json_name = "msg"];
}
message UploadExcelTwoTxRequest {
repeated ExcelTwoInfo excelTwoInfo = 1 [json_name = "excel_one_info"];
}
message UploadExcelTwoTxRespond {
string msg = 1 [json_name = "msg"];
}
message UploadExcelOneCopyRequest {
repeated ExcelOneInfo excelOneInfo = 1 [json_name = "excel_one_info"];
}
message UploadExcelOneCopyRespond {
string msg = 1 [json_name = "msg"];
}
message UploadExcelTwoCopyRequest {
repeated ExcelTwoInfo excelTwoInfo = 1 [json_name = "excel_one_info"];
}
message UploadExcelTwoCopyRespond {
string msg = 1 [json_name = "msg"];
}
message GetAllBatchTimeTxRequest {
}
message GetAllBatchTimeTxRespond {
repeated string BatchTime = 1 [json_name = "batch_time"];
string msg = 2 [json_name = "msg"];
}
message GetAllBatchTimeCopyRequest {
}
message GetAllBatchTimeCopyRespond {
repeated string BatchTime = 1 [json_name = "batch_time"];
string msg = 2 [json_name = "msg"];
}
message GetArtworkSoldTxDetailListRequest {
string artistName = 1 [json_name = "artist_name"];
string batchTime = 2 [json_name = "batch_time"];
int32 state = 3 [json_name = "state"];
int32 page = 4 [json_name = "page"];
int32 num = 5 [json_name = "num"];
}
message GetArtworkSoldTxDetailListRespond {
repeated ArtistList artist_list = 1 [json_name = "artist_list"];
string msg = 2 [json_name = "msg"];
}
message GetArtworkSoldCopyDetailListRequest {
string artistName = 1 [json_name = "artist_name"];
string batchTime = 2 [json_name = "batch_time"];
int32 state = 3 [json_name = "state"];
int32 page = 4 [json_name = "page"];
int32 num = 5 [json_name = "num"];
}
message GetArtworkSoldCopyDetailListRespond {
repeated ArtistList artist_list = 1 [json_name = "artist_list"];
string msg = 2 [json_name = "msg"];
}
message StatementListRequest {
string artistUid = 1 [json_name = "artist_uid"];
int32 pageSize = 2 [json_name="pageSize"];
int32 page = 3 [json_name="page"];
int32 state = 4 [json_name="state"];
}
message StatementListRespond {
repeated Contracts data = 1 [json_name = "data"];
string msg = 2 [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"];
repeated ArtworkSoldTxDetail artworkSoldTxDetail = 3 [json_name = "artwork_sold_tx_detail"];
string msg = 4 [json_name = "msg"];
}
message GetCopyInfoByBatchUidRequest {
string batchUid = 1 [json_name = "batch_uid"];
}
message GetCopyInfoByBatchUidRespond {
string artistName = 1 [json_name = "artist_name"];
repeated ArtworkCopyDetail artworkCopyDetail = 2 [json_name = "artwork_copy_detail"];
repeated ArtworkSoldCopyDetail artworkSoldCopyDetail = 3 [json_name = "artwork_sold_copy_detail"];
string msg = 4 [json_name = "msg"];
}

View File

@ -0,0 +1,194 @@
// Code generated by protoc-gen-gogo. DO NOT EDIT.
// source: Statement.proto
package statement
import (
fmt "fmt"
math "math"
proto "github.com/golang/protobuf/proto"
github_com_mwitkow_go_proto_validators "github.com/mwitkow/go-proto-validators"
)
// Reference imports to suppress errors if they are not otherwise used.
var _ = proto.Marshal
var _ = fmt.Errorf
var _ = math.Inf
func (this *Contracts) Validate() error {
return nil
}
func (this *ArtworkTxDetail) Validate() error {
return nil
}
func (this *ArtworkSoldTxDetail) Validate() error {
return nil
}
func (this *ArtworkCopyDetail) Validate() error {
return nil
}
func (this *ArtworkSoldCopyDetail) Validate() error {
return nil
}
func (this *ExcelOneInfo) Validate() error {
return nil
}
func (this *ExcelTwoInfo) Validate() error {
return nil
}
func (this *ArtworkSoldDetailList) Validate() error {
return nil
}
func (this *ArtistList) Validate() error {
for _, item := range this.ArtworkSoldDetailList {
if item != nil {
if err := github_com_mwitkow_go_proto_validators.CallValidatorIfExists(item); err != nil {
return github_com_mwitkow_go_proto_validators.FieldError("ArtworkSoldDetailList", err)
}
}
}
return nil
}
func (this *UploadExcelOneTxRequest) Validate() error {
for _, item := range this.ExcelOneInfo {
if item != nil {
if err := github_com_mwitkow_go_proto_validators.CallValidatorIfExists(item); err != nil {
return github_com_mwitkow_go_proto_validators.FieldError("ExcelOneInfo", err)
}
}
}
return nil
}
func (this *UploadExcelOneTxRespond) Validate() error {
return nil
}
func (this *UploadExcelTwoTxRequest) Validate() error {
for _, item := range this.ExcelTwoInfo {
if item != nil {
if err := github_com_mwitkow_go_proto_validators.CallValidatorIfExists(item); err != nil {
return github_com_mwitkow_go_proto_validators.FieldError("ExcelTwoInfo", err)
}
}
}
return nil
}
func (this *UploadExcelTwoTxRespond) Validate() error {
return nil
}
func (this *UploadExcelOneCopyRequest) Validate() error {
for _, item := range this.ExcelOneInfo {
if item != nil {
if err := github_com_mwitkow_go_proto_validators.CallValidatorIfExists(item); err != nil {
return github_com_mwitkow_go_proto_validators.FieldError("ExcelOneInfo", err)
}
}
}
return nil
}
func (this *UploadExcelOneCopyRespond) Validate() error {
return nil
}
func (this *UploadExcelTwoCopyRequest) Validate() error {
for _, item := range this.ExcelTwoInfo {
if item != nil {
if err := github_com_mwitkow_go_proto_validators.CallValidatorIfExists(item); err != nil {
return github_com_mwitkow_go_proto_validators.FieldError("ExcelTwoInfo", err)
}
}
}
return nil
}
func (this *UploadExcelTwoCopyRespond) Validate() error {
return nil
}
func (this *GetAllBatchTimeTxRequest) Validate() error {
return nil
}
func (this *GetAllBatchTimeTxRespond) Validate() error {
return nil
}
func (this *GetAllBatchTimeCopyRequest) Validate() error {
return nil
}
func (this *GetAllBatchTimeCopyRespond) Validate() error {
return nil
}
func (this *GetArtworkSoldTxDetailListRequest) Validate() error {
return nil
}
func (this *GetArtworkSoldTxDetailListRespond) Validate() error {
for _, item := range this.ArtistList {
if item != nil {
if err := github_com_mwitkow_go_proto_validators.CallValidatorIfExists(item); err != nil {
return github_com_mwitkow_go_proto_validators.FieldError("ArtistList", err)
}
}
}
return nil
}
func (this *GetArtworkSoldCopyDetailListRequest) Validate() error {
return nil
}
func (this *GetArtworkSoldCopyDetailListRespond) Validate() error {
for _, item := range this.ArtistList {
if item != nil {
if err := github_com_mwitkow_go_proto_validators.CallValidatorIfExists(item); err != nil {
return github_com_mwitkow_go_proto_validators.FieldError("ArtistList", err)
}
}
}
return nil
}
func (this *StatementListRequest) Validate() error {
return nil
}
func (this *StatementListRespond) 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 *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)
}
}
}
for _, item := range this.ArtworkSoldTxDetail {
if item != nil {
if err := github_com_mwitkow_go_proto_validators.CallValidatorIfExists(item); err != nil {
return github_com_mwitkow_go_proto_validators.FieldError("ArtworkSoldTxDetail", err)
}
}
}
return nil
}
func (this *GetCopyInfoByBatchUidRequest) Validate() error {
return nil
}
func (this *GetCopyInfoByBatchUidRespond) Validate() error {
for _, item := range this.ArtworkCopyDetail {
if item != nil {
if err := github_com_mwitkow_go_proto_validators.CallValidatorIfExists(item); err != nil {
return github_com_mwitkow_go_proto_validators.FieldError("ArtworkCopyDetail", err)
}
}
}
for _, item := range this.ArtworkSoldCopyDetail {
if item != nil {
if err := github_com_mwitkow_go_proto_validators.CallValidatorIfExists(item); err != nil {
return github_com_mwitkow_go_proto_validators.FieldError("ArtworkSoldCopyDetail", err)
}
}
}
return nil
}

View File

@ -0,0 +1,597 @@
// Code generated by protoc-gen-go-triple. DO NOT EDIT.
// versions:
// - protoc-gen-go-triple v1.0.8
// - protoc v3.21.8
// source: Statement.proto
package statement
import (
context "context"
protocol "dubbo.apache.org/dubbo-go/v3/protocol"
dubbo3 "dubbo.apache.org/dubbo-go/v3/protocol/dubbo3"
invocation "dubbo.apache.org/dubbo-go/v3/protocol/invocation"
grpc_go "github.com/dubbogo/grpc-go"
codes "github.com/dubbogo/grpc-go/codes"
metadata "github.com/dubbogo/grpc-go/metadata"
status "github.com/dubbogo/grpc-go/status"
common "github.com/dubbogo/triple/pkg/common"
constant "github.com/dubbogo/triple/pkg/common/constant"
triple "github.com/dubbogo/triple/pkg/triple"
)
// This is a compile-time assertion to ensure that this generated file
// is compatible with the grpc package it is being compiled against.
const _ = grpc_go.SupportPackageIsVersion7
// StatementClient is the client API for Statement service.
//
// 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 {
UploadExcelOneTx(ctx context.Context, in *UploadExcelOneTxRequest, opts ...grpc_go.CallOption) (*UploadExcelOneTxRespond, common.ErrorWithAttachment)
UploadExcelTwoTx(ctx context.Context, in *UploadExcelTwoTxRequest, opts ...grpc_go.CallOption) (*UploadExcelTwoTxRespond, common.ErrorWithAttachment)
UploadExcelOneCopy(ctx context.Context, in *UploadExcelOneCopyRequest, opts ...grpc_go.CallOption) (*UploadExcelOneCopyRespond, common.ErrorWithAttachment)
UploadExcelTwoCopy(ctx context.Context, in *UploadExcelTwoCopyRequest, opts ...grpc_go.CallOption) (*UploadExcelTwoCopyRespond, common.ErrorWithAttachment)
GetAllBatchTimeTx(ctx context.Context, in *GetAllBatchTimeTxRequest, opts ...grpc_go.CallOption) (*GetAllBatchTimeTxRespond, common.ErrorWithAttachment)
GetAllBatchTimeCopy(ctx context.Context, in *GetAllBatchTimeCopyRequest, opts ...grpc_go.CallOption) (*GetAllBatchTimeCopyRespond, common.ErrorWithAttachment)
GetArtworkSoldTxDetailList(ctx context.Context, in *GetArtworkSoldTxDetailListRequest, opts ...grpc_go.CallOption) (*GetArtworkSoldTxDetailListRespond, common.ErrorWithAttachment)
GetArtworkSoldCopyDetailList(ctx context.Context, in *GetArtworkSoldCopyDetailListRequest, opts ...grpc_go.CallOption) (*GetArtworkSoldCopyDetailListRespond, common.ErrorWithAttachment)
StatementList(ctx context.Context, in *StatementListRequest, opts ...grpc_go.CallOption) (*StatementListRespond, common.ErrorWithAttachment)
GetTxInfoByBatchUid(ctx context.Context, in *GetTxInfoByBatchUidRequest, opts ...grpc_go.CallOption) (*GetTxInfoByBatchUidRespond, common.ErrorWithAttachment)
GetCopyInfoByBatchUid(ctx context.Context, in *GetCopyInfoByBatchUidRequest, opts ...grpc_go.CallOption) (*GetCopyInfoByBatchUidRespond, common.ErrorWithAttachment)
}
type statementClient struct {
cc *triple.TripleConn
}
type StatementClientImpl struct {
UploadExcelOneTx func(ctx context.Context, in *UploadExcelOneTxRequest) (*UploadExcelOneTxRespond, error)
UploadExcelTwoTx func(ctx context.Context, in *UploadExcelTwoTxRequest) (*UploadExcelTwoTxRespond, error)
UploadExcelOneCopy func(ctx context.Context, in *UploadExcelOneCopyRequest) (*UploadExcelOneCopyRespond, error)
UploadExcelTwoCopy func(ctx context.Context, in *UploadExcelTwoCopyRequest) (*UploadExcelTwoCopyRespond, error)
GetAllBatchTimeTx func(ctx context.Context, in *GetAllBatchTimeTxRequest) (*GetAllBatchTimeTxRespond, error)
GetAllBatchTimeCopy func(ctx context.Context, in *GetAllBatchTimeCopyRequest) (*GetAllBatchTimeCopyRespond, error)
GetArtworkSoldTxDetailList func(ctx context.Context, in *GetArtworkSoldTxDetailListRequest) (*GetArtworkSoldTxDetailListRespond, error)
GetArtworkSoldCopyDetailList func(ctx context.Context, in *GetArtworkSoldCopyDetailListRequest) (*GetArtworkSoldCopyDetailListRespond, error)
StatementList func(ctx context.Context, in *StatementListRequest) (*StatementListRespond, error)
GetTxInfoByBatchUid func(ctx context.Context, in *GetTxInfoByBatchUidRequest) (*GetTxInfoByBatchUidRespond, error)
GetCopyInfoByBatchUid func(ctx context.Context, in *GetCopyInfoByBatchUidRequest) (*GetCopyInfoByBatchUidRespond, error)
}
func (c *StatementClientImpl) GetDubboStub(cc *triple.TripleConn) StatementClient {
return NewStatementClient(cc)
}
func (c *StatementClientImpl) XXX_InterfaceName() string {
return "statement.Statement"
}
func NewStatementClient(cc *triple.TripleConn) StatementClient {
return &statementClient{cc}
}
func (c *statementClient) UploadExcelOneTx(ctx context.Context, in *UploadExcelOneTxRequest, opts ...grpc_go.CallOption) (*UploadExcelOneTxRespond, common.ErrorWithAttachment) {
out := new(UploadExcelOneTxRespond)
interfaceKey := ctx.Value(constant.InterfaceKey).(string)
return out, c.cc.Invoke(ctx, "/"+interfaceKey+"/UploadExcelOneTx", in, out)
}
func (c *statementClient) UploadExcelTwoTx(ctx context.Context, in *UploadExcelTwoTxRequest, opts ...grpc_go.CallOption) (*UploadExcelTwoTxRespond, common.ErrorWithAttachment) {
out := new(UploadExcelTwoTxRespond)
interfaceKey := ctx.Value(constant.InterfaceKey).(string)
return out, c.cc.Invoke(ctx, "/"+interfaceKey+"/UploadExcelTwoTx", in, out)
}
func (c *statementClient) UploadExcelOneCopy(ctx context.Context, in *UploadExcelOneCopyRequest, opts ...grpc_go.CallOption) (*UploadExcelOneCopyRespond, common.ErrorWithAttachment) {
out := new(UploadExcelOneCopyRespond)
interfaceKey := ctx.Value(constant.InterfaceKey).(string)
return out, c.cc.Invoke(ctx, "/"+interfaceKey+"/UploadExcelOneCopy", in, out)
}
func (c *statementClient) UploadExcelTwoCopy(ctx context.Context, in *UploadExcelTwoCopyRequest, opts ...grpc_go.CallOption) (*UploadExcelTwoCopyRespond, common.ErrorWithAttachment) {
out := new(UploadExcelTwoCopyRespond)
interfaceKey := ctx.Value(constant.InterfaceKey).(string)
return out, c.cc.Invoke(ctx, "/"+interfaceKey+"/UploadExcelTwoCopy", in, out)
}
func (c *statementClient) GetAllBatchTimeTx(ctx context.Context, in *GetAllBatchTimeTxRequest, opts ...grpc_go.CallOption) (*GetAllBatchTimeTxRespond, common.ErrorWithAttachment) {
out := new(GetAllBatchTimeTxRespond)
interfaceKey := ctx.Value(constant.InterfaceKey).(string)
return out, c.cc.Invoke(ctx, "/"+interfaceKey+"/GetAllBatchTimeTx", in, out)
}
func (c *statementClient) GetAllBatchTimeCopy(ctx context.Context, in *GetAllBatchTimeCopyRequest, opts ...grpc_go.CallOption) (*GetAllBatchTimeCopyRespond, common.ErrorWithAttachment) {
out := new(GetAllBatchTimeCopyRespond)
interfaceKey := ctx.Value(constant.InterfaceKey).(string)
return out, c.cc.Invoke(ctx, "/"+interfaceKey+"/GetAllBatchTimeCopy", in, out)
}
func (c *statementClient) GetArtworkSoldTxDetailList(ctx context.Context, in *GetArtworkSoldTxDetailListRequest, opts ...grpc_go.CallOption) (*GetArtworkSoldTxDetailListRespond, common.ErrorWithAttachment) {
out := new(GetArtworkSoldTxDetailListRespond)
interfaceKey := ctx.Value(constant.InterfaceKey).(string)
return out, c.cc.Invoke(ctx, "/"+interfaceKey+"/GetArtworkSoldTxDetailList", in, out)
}
func (c *statementClient) GetArtworkSoldCopyDetailList(ctx context.Context, in *GetArtworkSoldCopyDetailListRequest, opts ...grpc_go.CallOption) (*GetArtworkSoldCopyDetailListRespond, common.ErrorWithAttachment) {
out := new(GetArtworkSoldCopyDetailListRespond)
interfaceKey := ctx.Value(constant.InterfaceKey).(string)
return out, c.cc.Invoke(ctx, "/"+interfaceKey+"/GetArtworkSoldCopyDetailList", in, out)
}
func (c *statementClient) StatementList(ctx context.Context, in *StatementListRequest, opts ...grpc_go.CallOption) (*StatementListRespond, common.ErrorWithAttachment) {
out := new(StatementListRespond)
interfaceKey := ctx.Value(constant.InterfaceKey).(string)
return out, c.cc.Invoke(ctx, "/"+interfaceKey+"/StatementList", 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)
}
func (c *statementClient) GetCopyInfoByBatchUid(ctx context.Context, in *GetCopyInfoByBatchUidRequest, opts ...grpc_go.CallOption) (*GetCopyInfoByBatchUidRespond, common.ErrorWithAttachment) {
out := new(GetCopyInfoByBatchUidRespond)
interfaceKey := ctx.Value(constant.InterfaceKey).(string)
return out, c.cc.Invoke(ctx, "/"+interfaceKey+"/GetCopyInfoByBatchUid", in, out)
}
// StatementServer is the server API for Statement service.
// All implementations must embed UnimplementedStatementServer
// for forward compatibility
type StatementServer interface {
UploadExcelOneTx(context.Context, *UploadExcelOneTxRequest) (*UploadExcelOneTxRespond, error)
UploadExcelTwoTx(context.Context, *UploadExcelTwoTxRequest) (*UploadExcelTwoTxRespond, error)
UploadExcelOneCopy(context.Context, *UploadExcelOneCopyRequest) (*UploadExcelOneCopyRespond, error)
UploadExcelTwoCopy(context.Context, *UploadExcelTwoCopyRequest) (*UploadExcelTwoCopyRespond, error)
GetAllBatchTimeTx(context.Context, *GetAllBatchTimeTxRequest) (*GetAllBatchTimeTxRespond, error)
GetAllBatchTimeCopy(context.Context, *GetAllBatchTimeCopyRequest) (*GetAllBatchTimeCopyRespond, error)
GetArtworkSoldTxDetailList(context.Context, *GetArtworkSoldTxDetailListRequest) (*GetArtworkSoldTxDetailListRespond, error)
GetArtworkSoldCopyDetailList(context.Context, *GetArtworkSoldCopyDetailListRequest) (*GetArtworkSoldCopyDetailListRespond, error)
StatementList(context.Context, *StatementListRequest) (*StatementListRespond, error)
GetTxInfoByBatchUid(context.Context, *GetTxInfoByBatchUidRequest) (*GetTxInfoByBatchUidRespond, error)
GetCopyInfoByBatchUid(context.Context, *GetCopyInfoByBatchUidRequest) (*GetCopyInfoByBatchUidRespond, error)
mustEmbedUnimplementedStatementServer()
}
// UnimplementedStatementServer must be embedded to have forward compatible implementations.
type UnimplementedStatementServer struct {
proxyImpl protocol.Invoker
}
func (UnimplementedStatementServer) UploadExcelOneTx(context.Context, *UploadExcelOneTxRequest) (*UploadExcelOneTxRespond, error) {
return nil, status.Errorf(codes.Unimplemented, "method UploadExcelOneTx not implemented")
}
func (UnimplementedStatementServer) UploadExcelTwoTx(context.Context, *UploadExcelTwoTxRequest) (*UploadExcelTwoTxRespond, error) {
return nil, status.Errorf(codes.Unimplemented, "method UploadExcelTwoTx not implemented")
}
func (UnimplementedStatementServer) UploadExcelOneCopy(context.Context, *UploadExcelOneCopyRequest) (*UploadExcelOneCopyRespond, error) {
return nil, status.Errorf(codes.Unimplemented, "method UploadExcelOneCopy not implemented")
}
func (UnimplementedStatementServer) UploadExcelTwoCopy(context.Context, *UploadExcelTwoCopyRequest) (*UploadExcelTwoCopyRespond, error) {
return nil, status.Errorf(codes.Unimplemented, "method UploadExcelTwoCopy not implemented")
}
func (UnimplementedStatementServer) GetAllBatchTimeTx(context.Context, *GetAllBatchTimeTxRequest) (*GetAllBatchTimeTxRespond, error) {
return nil, status.Errorf(codes.Unimplemented, "method GetAllBatchTimeTx not implemented")
}
func (UnimplementedStatementServer) GetAllBatchTimeCopy(context.Context, *GetAllBatchTimeCopyRequest) (*GetAllBatchTimeCopyRespond, error) {
return nil, status.Errorf(codes.Unimplemented, "method GetAllBatchTimeCopy not implemented")
}
func (UnimplementedStatementServer) GetArtworkSoldTxDetailList(context.Context, *GetArtworkSoldTxDetailListRequest) (*GetArtworkSoldTxDetailListRespond, error) {
return nil, status.Errorf(codes.Unimplemented, "method GetArtworkSoldTxDetailList not implemented")
}
func (UnimplementedStatementServer) GetArtworkSoldCopyDetailList(context.Context, *GetArtworkSoldCopyDetailListRequest) (*GetArtworkSoldCopyDetailListRespond, error) {
return nil, status.Errorf(codes.Unimplemented, "method GetArtworkSoldCopyDetailList not implemented")
}
func (UnimplementedStatementServer) StatementList(context.Context, *StatementListRequest) (*StatementListRespond, error) {
return nil, status.Errorf(codes.Unimplemented, "method StatementList not implemented")
}
func (UnimplementedStatementServer) GetTxInfoByBatchUid(context.Context, *GetTxInfoByBatchUidRequest) (*GetTxInfoByBatchUidRespond, error) {
return nil, status.Errorf(codes.Unimplemented, "method GetTxInfoByBatchUid not implemented")
}
func (UnimplementedStatementServer) GetCopyInfoByBatchUid(context.Context, *GetCopyInfoByBatchUidRequest) (*GetCopyInfoByBatchUidRespond, error) {
return nil, status.Errorf(codes.Unimplemented, "method GetCopyInfoByBatchUid not implemented")
}
func (s *UnimplementedStatementServer) XXX_SetProxyImpl(impl protocol.Invoker) {
s.proxyImpl = impl
}
func (s *UnimplementedStatementServer) XXX_GetProxyImpl() protocol.Invoker {
return s.proxyImpl
}
func (s *UnimplementedStatementServer) XXX_ServiceDesc() *grpc_go.ServiceDesc {
return &Statement_ServiceDesc
}
func (s *UnimplementedStatementServer) XXX_InterfaceName() string {
return "statement.Statement"
}
func (UnimplementedStatementServer) mustEmbedUnimplementedStatementServer() {}
// UnsafeStatementServer may be embedded to opt out of forward compatibility for this service.
// Use of this interface is not recommended, as added methods to StatementServer will
// result in compilation errors.
type UnsafeStatementServer interface {
mustEmbedUnimplementedStatementServer()
}
func RegisterStatementServer(s grpc_go.ServiceRegistrar, srv StatementServer) {
s.RegisterService(&Statement_ServiceDesc, srv)
}
func _Statement_UploadExcelOneTx_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc_go.UnaryServerInterceptor) (interface{}, error) {
in := new(UploadExcelOneTxRequest)
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("UploadExcelOneTx", 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_UploadExcelTwoTx_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc_go.UnaryServerInterceptor) (interface{}, error) {
in := new(UploadExcelTwoTxRequest)
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("UploadExcelTwoTx", 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_UploadExcelOneCopy_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc_go.UnaryServerInterceptor) (interface{}, error) {
in := new(UploadExcelOneCopyRequest)
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("UploadExcelOneCopy", 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_UploadExcelTwoCopy_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc_go.UnaryServerInterceptor) (interface{}, error) {
in := new(UploadExcelTwoCopyRequest)
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("UploadExcelTwoCopy", 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_GetAllBatchTimeTx_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc_go.UnaryServerInterceptor) (interface{}, error) {
in := new(GetAllBatchTimeTxRequest)
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("GetAllBatchTimeTx", 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_GetAllBatchTimeCopy_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc_go.UnaryServerInterceptor) (interface{}, error) {
in := new(GetAllBatchTimeCopyRequest)
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("GetAllBatchTimeCopy", 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_GetArtworkSoldTxDetailList_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc_go.UnaryServerInterceptor) (interface{}, error) {
in := new(GetArtworkSoldTxDetailListRequest)
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("GetArtworkSoldTxDetailList", 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_GetArtworkSoldCopyDetailList_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc_go.UnaryServerInterceptor) (interface{}, error) {
in := new(GetArtworkSoldCopyDetailListRequest)
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("GetArtworkSoldCopyDetailList", 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_StatementList_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc_go.UnaryServerInterceptor) (interface{}, error) {
in := new(StatementListRequest)
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("StatementList", 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)
}
func _Statement_GetCopyInfoByBatchUid_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc_go.UnaryServerInterceptor) (interface{}, error) {
in := new(GetCopyInfoByBatchUidRequest)
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("GetCopyInfoByBatchUid", 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)
var Statement_ServiceDesc = grpc_go.ServiceDesc{
ServiceName: "statement.Statement",
HandlerType: (*StatementServer)(nil),
Methods: []grpc_go.MethodDesc{
{
MethodName: "UploadExcelOneTx",
Handler: _Statement_UploadExcelOneTx_Handler,
},
{
MethodName: "UploadExcelTwoTx",
Handler: _Statement_UploadExcelTwoTx_Handler,
},
{
MethodName: "UploadExcelOneCopy",
Handler: _Statement_UploadExcelOneCopy_Handler,
},
{
MethodName: "UploadExcelTwoCopy",
Handler: _Statement_UploadExcelTwoCopy_Handler,
},
{
MethodName: "GetAllBatchTimeTx",
Handler: _Statement_GetAllBatchTimeTx_Handler,
},
{
MethodName: "GetAllBatchTimeCopy",
Handler: _Statement_GetAllBatchTimeCopy_Handler,
},
{
MethodName: "GetArtworkSoldTxDetailList",
Handler: _Statement_GetArtworkSoldTxDetailList_Handler,
},
{
MethodName: "GetArtworkSoldCopyDetailList",
Handler: _Statement_GetArtworkSoldCopyDetailList_Handler,
},
{
MethodName: "StatementList",
Handler: _Statement_StatementList_Handler,
},
{
MethodName: "GetTxInfoByBatchUid",
Handler: _Statement_GetTxInfoByBatchUid_Handler,
},
{
MethodName: "GetCopyInfoByBatchUid",
Handler: _Statement_GetCopyInfoByBatchUid_Handler,
},
},
Streams: []grpc_go.StreamDesc{},
Metadata: "Statement.proto",
}

View File

@ -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"`
BatchTime string `protobuf:"bytes,14,opt,name=BatchTime,json=batch_time,proto3" json:"BatchTime,omitempty"`
BatchUid string `protobuf:"bytes,15,opt,name=BatchUid,json=batch_uid,proto3" json:"BatchUid,omitempty"`
StType int32 `protobuf:"varint,16,opt,name=StType,json=st_type,proto3" json:"StType,omitempty"`
}
func (x *Contracts) Reset() {
@ -163,6 +166,27 @@ func (x *Contracts) GetSignTime() string {
return ""
}
func (x *Contracts) GetBatchTime() string {
if x != nil {
return x.BatchTime
}
return ""
}
func (x *Contracts) GetBatchUid() string {
if x != nil {
return x.BatchUid
}
return ""
}
func (x *Contracts) GetStType() int32 {
if x != nil {
return x.StType
}
return 0
}
type CreateContractRequest struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache
@ -170,7 +194,9 @@ type CreateContractRequest struct {
ArtistUid string `protobuf:"bytes,1,opt,name=ArtistUid,json=artist_uid,proto3" json:"ArtistUid,omitempty"`
ArtworkUid []string `protobuf:"bytes,2,rep,name=ArtworkUid,json=artwork_uid,proto3" json:"ArtworkUid,omitempty"`
Type int32 `protobuf:"varint,3,opt,name=Type,json=type,proto3" json:"Type,omitempty"`
BatchUid string `protobuf:"bytes,3,opt,name=BatchUid,json=batch_uid,proto3" json:"BatchUid,omitempty"`
BatchTime string `protobuf:"bytes,4,opt,name=BatchTime,json=batch_time,proto3" json:"BatchTime,omitempty"`
Type int32 `protobuf:"varint,5,opt,name=Type,json=type,proto3" json:"Type,omitempty"`
}
func (x *CreateContractRequest) Reset() {
@ -219,6 +245,20 @@ func (x *CreateContractRequest) GetArtworkUid() []string {
return nil
}
func (x *CreateContractRequest) GetBatchUid() string {
if x != nil {
return x.BatchUid
}
return ""
}
func (x *CreateContractRequest) GetBatchTime() string {
if x != nil {
return x.BatchTime
}
return ""
}
func (x *CreateContractRequest) GetType() int32 {
if x != nil {
return x.Type
@ -279,8 +319,9 @@ type ContractListMgmtRequest struct {
unknownFields protoimpl.UnknownFields
ArtistUid string `protobuf:"bytes,1,opt,name=ArtistUid,json=artist_uid,proto3" json:"ArtistUid,omitempty"`
Page int32 `protobuf:"varint,2,opt,name=Page,json=page,proto3" json:"Page,omitempty"`
Num int32 `protobuf:"varint,3,opt,name=Num,json=num,proto3" json:"Num,omitempty"`
Status int32 `protobuf:"varint,2,opt,name=Status,json=status,proto3" json:"Status,omitempty"`
Page int32 `protobuf:"varint,3,opt,name=Page,json=page,proto3" json:"Page,omitempty"`
Num int32 `protobuf:"varint,4,opt,name=Num,json=num,proto3" json:"Num,omitempty"`
}
func (x *ContractListMgmtRequest) Reset() {
@ -322,6 +363,13 @@ func (x *ContractListMgmtRequest) GetArtistUid() string {
return ""
}
func (x *ContractListMgmtRequest) GetStatus() int32 {
if x != nil {
return x.Status
}
return 0
}
func (x *ContractListMgmtRequest) GetPage() int32 {
if x != nil {
return x.Page
@ -1379,7 +1427,7 @@ var File_contract_proto protoreflect.FileDescriptor
var file_contract_proto_rawDesc = []byte{
0x0a, 0x0e, 0x63, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f,
0x12, 0x0e, 0x61, 0x72, 0x74, 0x69, 0x73, 0x74, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74,
0x22, 0x99, 0x03, 0x0a, 0x09, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x73, 0x12, 0x21,
0x22, 0xee, 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, 0x09, 0x41, 0x72, 0x74, 0x69, 0x73, 0x74, 0x55, 0x69, 0x64, 0x18, 0x02,
@ -1404,192 +1452,203 @@ var file_contract_proto_rawDesc = []byte{
0x6d, 0x65, 0x12, 0x1b, 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, 0x6b, 0x0a, 0x15,
0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 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, 0x1f, 0x0a, 0x0a, 0x41, 0x72, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x55,
0x69, 0x64, 0x18, 0x02, 0x20, 0x03, 0x28, 0x09, 0x52, 0x0b, 0x61, 0x72, 0x74, 0x77, 0x6f, 0x72,
0x6b, 0x5f, 0x75, 0x69, 0x64, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x03, 0x20,
0x01, 0x28, 0x05, 0x52, 0x04, 0x74, 0x79, 0x70, 0x65, 0x22, 0x29, 0x0a, 0x15, 0x43, 0x72, 0x65,
0x61, 0x74, 0x65, 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, 0x5e, 0x0a, 0x17, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74,
0x4c, 0x69, 0x73, 0x74, 0x4d, 0x67, 0x6d, 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, 0x12,
0x0a, 0x04, 0x50, 0x61, 0x67, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x04, 0x70, 0x61,
0x67, 0x65, 0x12, 0x10, 0x0a, 0x03, 0x4e, 0x75, 0x6d, 0x18, 0x03, 0x20, 0x01, 0x28, 0x05, 0x52,
0x03, 0x6e, 0x75, 0x6d, 0x22, 0x5a, 0x0a, 0x17, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74,
0x4c, 0x69, 0x73, 0x74, 0x4d, 0x67, 0x6d, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x64, 0x12,
0x2d, 0x0a, 0x04, 0x44, 0x61, 0x74, 0x61, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x19, 0x2e,
0x61, 0x72, 0x74, 0x69, 0x73, 0x74, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 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,
0x22, 0x7a, 0x0a, 0x13, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 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, 0x1a, 0x0a, 0x08, 0x50, 0x61, 0x67, 0x65, 0x53, 0x69,
0x7a, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x08, 0x70, 0x61, 0x67, 0x65, 0x53, 0x69,
0x7a, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, 0x67, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x05,
0x52, 0x04, 0x70, 0x61, 0x67, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x53, 0x74, 0x61, 0x74, 0x65, 0x18,
0x04, 0x20, 0x01, 0x28, 0x05, 0x52, 0x05, 0x73, 0x74, 0x61, 0x74, 0x65, 0x22, 0x56, 0x0a, 0x13,
0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x4c, 0x69, 0x73, 0x74, 0x52, 0x65, 0x73, 0x70,
0x6f, 0x6e, 0x64, 0x12, 0x2d, 0x0a, 0x04, 0x44, 0x61, 0x74, 0x61, 0x18, 0x01, 0x20, 0x03, 0x28,
0x09, 0x52, 0x09, 0x73, 0x69, 0x67, 0x6e, 0x5f, 0x74, 0x69, 0x6d, 0x65, 0x12, 0x1d, 0x0a, 0x09,
0x42, 0x61, 0x74, 0x63, 0x68, 0x54, 0x69, 0x6d, 0x65, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x09, 0x52,
0x0a, 0x62, 0x61, 0x74, 0x63, 0x68, 0x5f, 0x74, 0x69, 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, 0x17, 0x0a, 0x06, 0x53, 0x74, 0x54, 0x79,
0x70, 0x65, 0x18, 0x10, 0x20, 0x01, 0x28, 0x05, 0x52, 0x07, 0x73, 0x74, 0x5f, 0x74, 0x79, 0x70,
0x65, 0x22, 0xa7, 0x01, 0x0a, 0x15, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x43, 0x6f, 0x6e, 0x74,
0x72, 0x61, 0x63, 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, 0x1f, 0x0a, 0x0a, 0x41, 0x72,
0x74, 0x77, 0x6f, 0x72, 0x6b, 0x55, 0x69, 0x64, 0x18, 0x02, 0x20, 0x03, 0x28, 0x09, 0x52, 0x0b,
0x61, 0x72, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x5f, 0x75, 0x69, 0x64, 0x12, 0x1b, 0x0a, 0x08, 0x42,
0x61, 0x74, 0x63, 0x68, 0x55, 0x69, 0x64, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x62,
0x61, 0x74, 0x63, 0x68, 0x5f, 0x75, 0x69, 0x64, 0x12, 0x1d, 0x0a, 0x09, 0x42, 0x61, 0x74, 0x63,
0x68, 0x54, 0x69, 0x6d, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x62, 0x61, 0x74,
0x63, 0x68, 0x5f, 0x74, 0x69, 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18,
0x05, 0x20, 0x01, 0x28, 0x05, 0x52, 0x04, 0x74, 0x79, 0x70, 0x65, 0x22, 0x29, 0x0a, 0x15, 0x43,
0x72, 0x65, 0x61, 0x74, 0x65, 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, 0x76, 0x0a, 0x17, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61,
0x63, 0x74, 0x4c, 0x69, 0x73, 0x74, 0x4d, 0x67, 0x6d, 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, 0x16, 0x0a, 0x06, 0x53, 0x74, 0x61, 0x74, 0x75, 0x73, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05,
0x52, 0x06, 0x73, 0x74, 0x61, 0x74, 0x75, 0x73, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, 0x67, 0x65,
0x18, 0x03, 0x20, 0x01, 0x28, 0x05, 0x52, 0x04, 0x70, 0x61, 0x67, 0x65, 0x12, 0x10, 0x0a, 0x03,
0x4e, 0x75, 0x6d, 0x18, 0x04, 0x20, 0x01, 0x28, 0x05, 0x52, 0x03, 0x6e, 0x75, 0x6d, 0x22, 0x5a,
0x0a, 0x17, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x4c, 0x69, 0x73, 0x74, 0x4d, 0x67,
0x6d, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x64, 0x12, 0x2d, 0x0a, 0x04, 0x44, 0x61, 0x74,
0x61, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x19, 0x2e, 0x61, 0x72, 0x74, 0x69, 0x73, 0x74,
0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 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, 0x22, 0x7a, 0x0a, 0x13, 0x43, 0x6f,
0x6e, 0x74, 0x72, 0x61, 0x63, 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, 0x1a, 0x0a, 0x08, 0x50, 0x61, 0x67, 0x65, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x02, 0x20, 0x01,
0x28, 0x05, 0x52, 0x08, 0x70, 0x61, 0x67, 0x65, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x12, 0x0a, 0x04,
0x50, 0x61, 0x67, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x05, 0x52, 0x04, 0x70, 0x61, 0x67, 0x65,
0x12, 0x14, 0x0a, 0x05, 0x53, 0x74, 0x61, 0x74, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x05, 0x52,
0x05, 0x73, 0x74, 0x61, 0x74, 0x65, 0x22, 0x56, 0x0a, 0x13, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61,
0x63, 0x74, 0x4c, 0x69, 0x73, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x64, 0x12, 0x2d, 0x0a,
0x04, 0x44, 0x61, 0x74, 0x61, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x19, 0x2e, 0x61, 0x72,
0x74, 0x69, 0x73, 0x74, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 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, 0x22, 0xb2,
0x02, 0x0a, 0x13, 0x53, 0x69, 0x67, 0x6e, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 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, 0x21, 0x0a, 0x0b, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63,
0x74, 0x55, 0x69, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x63, 0x6f, 0x6e, 0x74,
0x72, 0x61, 0x63, 0x74, 0x5f, 0x75, 0x69, 0x64, 0x12, 0x14, 0x0a, 0x05, 0x54, 0x6f, 0x6b, 0x65,
0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x74, 0x6f, 0x6b, 0x65, 0x6e, 0x12, 0x1b,
0x0a, 0x08, 0x48, 0x74, 0x6d, 0x6c, 0x54, 0x79, 0x70, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09,
0x52, 0x09, 0x68, 0x74, 0x6d, 0x6c, 0x5f, 0x74, 0x79, 0x70, 0x65, 0x12, 0x19, 0x0a, 0x07, 0x45,
0x6e, 0x76, 0x54, 0x79, 0x70, 0x65, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x65, 0x6e,
0x76, 0x5f, 0x74, 0x79, 0x70, 0x65, 0x12, 0x20, 0x0a, 0x0a, 0x56, 0x69, 0x65, 0x77, 0x50, 0x64,
0x66, 0x55, 0x72, 0x6c, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x76, 0x69, 0x65, 0x77,
0x5f, 0x70, 0x64, 0x66, 0x5f, 0x75, 0x72, 0x6c, 0x12, 0x21, 0x0a, 0x0b, 0x44, 0x6f, 0x77, 0x6e,
0x6c, 0x6f, 0x61, 0x64, 0x55, 0x72, 0x6c, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x64,
0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x5f, 0x75, 0x72, 0x6c, 0x12, 0x1f, 0x0a, 0x0a, 0x43,
0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x4e, 0x6f, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52,
0x0b, 0x63, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x5f, 0x6e, 0x6f, 0x12, 0x25, 0x0a, 0x0d,
0x54, 0x72, 0x61, 0x6e, 0x73, 0x61, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x64, 0x18, 0x09, 0x20,
0x01, 0x28, 0x09, 0x52, 0x0e, 0x74, 0x72, 0x61, 0x6e, 0x73, 0x61, 0x63, 0x74, 0x69, 0x6f, 0x6e,
0x5f, 0x69, 0x64, 0x22, 0x42, 0x0a, 0x13, 0x53, 0x69, 0x67, 0x6e, 0x43, 0x6f, 0x6e, 0x74, 0x72,
0x61, 0x63, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x64, 0x12, 0x19, 0x0a, 0x07, 0x4a, 0x75,
0x6d, 0x70, 0x55, 0x72, 0x6c, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x6a, 0x75, 0x6d,
0x70, 0x5f, 0x75, 0x72, 0x6c, 0x12, 0x10, 0x0a, 0x03, 0x4d, 0x73, 0x67, 0x18, 0x02, 0x20, 0x01,
0x28, 0x09, 0x52, 0x03, 0x6d, 0x73, 0x67, 0x22, 0x61, 0x0a, 0x15, 0x46, 0x69, 0x6e, 0x69, 0x73,
0x68, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74,
0x12, 0x25, 0x0a, 0x0d, 0x74, 0x72, 0x61, 0x6e, 0x73, 0x61, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x49,
0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x74, 0x72, 0x61, 0x6e, 0x73, 0x61, 0x63,
0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x69, 0x64, 0x12, 0x21, 0x0a, 0x0b, 0x43, 0x6f, 0x6e, 0x74, 0x72,
0x61, 0x63, 0x74, 0x55, 0x69, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x63, 0x6f,
0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x5f, 0x75, 0x69, 0x64, 0x22, 0x5b, 0x0a, 0x15, 0x46, 0x69,
0x6e, 0x69, 0x73, 0x68, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x52, 0x65, 0x73, 0x70,
0x6f, 0x6e, 0x64, 0x12, 0x30, 0x0a, 0x08, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x18,
0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x19, 0x2e, 0x61, 0x72, 0x74, 0x69, 0x73, 0x74, 0x43, 0x6f,
0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x2e, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x73,
0x52, 0x03, 0x6d, 0x73, 0x67, 0x12, 0x10, 0x0a, 0x03, 0x4d, 0x73, 0x67, 0x18, 0x02, 0x20, 0x01,
0x28, 0x09, 0x52, 0x03, 0x6d, 0x73, 0x67, 0x22, 0x6e, 0x0a, 0x15, 0x43, 0x6f, 0x6e, 0x74, 0x72,
0x61, 0x63, 0x74, 0x54, 0x78, 0x4c, 0x69, 0x73, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74,
0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x02, 0x69, 0x64,
0x12, 0x1b, 0x0a, 0x08, 0x50, 0x61, 0x67, 0x65, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x02, 0x20, 0x01,
0x28, 0x05, 0x52, 0x09, 0x70, 0x61, 0x67, 0x65, 0x5f, 0x73, 0x69, 0x7a, 0x65, 0x12, 0x12, 0x0a,
0x04, 0x50, 0x61, 0x67, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x05, 0x52, 0x04, 0x70, 0x61, 0x67,
0x65, 0x12, 0x14, 0x0a, 0x05, 0x53, 0x74, 0x61, 0x74, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x05,
0x52, 0x05, 0x73, 0x74, 0x61, 0x74, 0x65, 0x22, 0x58, 0x0a, 0x15, 0x43, 0x6f, 0x6e, 0x74, 0x72,
0x61, 0x63, 0x74, 0x54, 0x78, 0x4c, 0x69, 0x73, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x64,
0x12, 0x2d, 0x0a, 0x04, 0x44, 0x61, 0x74, 0x61, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x19,
0x2e, 0x61, 0x72, 0x74, 0x69, 0x73, 0x74, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x2e,
0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x73, 0x52, 0x04, 0x44, 0x61, 0x74, 0x61, 0x12,
0x10, 0x0a, 0x03, 0x4d, 0x73, 0x67, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x6d, 0x73,
0x67, 0x22, 0x49, 0x0a, 0x23, 0x47, 0x65, 0x74, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74,
0x49, 0x6e, 0x66, 0x6f, 0x42, 0x79, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x55, 0x69,
0x64, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x22, 0x0a, 0x0b, 0x43, 0x6f, 0x6e, 0x74,
0x72, 0x61, 0x63, 0x74, 0x55, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0d, 0x63,
0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x5f, 0x6e, 0x61, 0x6d, 0x65, 0x22, 0x66, 0x0a, 0x23,
0x47, 0x65, 0x74, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x49, 0x6e, 0x66, 0x6f, 0x42,
0x79, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x55, 0x69, 0x64, 0x52, 0x65, 0x73, 0x70,
0x6f, 0x6e, 0x64, 0x12, 0x2d, 0x0a, 0x04, 0x44, 0x61, 0x74, 0x61, 0x18, 0x01, 0x20, 0x01, 0x28,
0x0b, 0x32, 0x19, 0x2e, 0x61, 0x72, 0x74, 0x69, 0x73, 0x74, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61,
0x63, 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, 0x22, 0xb2, 0x02, 0x0a, 0x13, 0x53, 0x69, 0x67, 0x6e, 0x43, 0x6f, 0x6e,
0x74, 0x72, 0x61, 0x63, 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, 0x21, 0x0a, 0x0b, 0x43,
0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x55, 0x69, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09,
0x52, 0x0c, 0x63, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x5f, 0x75, 0x69, 0x64, 0x12, 0x14,
0x0a, 0x05, 0x54, 0x6f, 0x6b, 0x65, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x74,
0x6f, 0x6b, 0x65, 0x6e, 0x12, 0x1b, 0x0a, 0x08, 0x48, 0x74, 0x6d, 0x6c, 0x54, 0x79, 0x70, 0x65,
0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x68, 0x74, 0x6d, 0x6c, 0x5f, 0x74, 0x79, 0x70,
0x65, 0x12, 0x19, 0x0a, 0x07, 0x45, 0x6e, 0x76, 0x54, 0x79, 0x70, 0x65, 0x18, 0x05, 0x20, 0x01,
0x28, 0x09, 0x52, 0x08, 0x65, 0x6e, 0x76, 0x5f, 0x74, 0x79, 0x70, 0x65, 0x12, 0x20, 0x0a, 0x0a,
0x56, 0x69, 0x65, 0x77, 0x50, 0x64, 0x66, 0x55, 0x72, 0x6c, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09,
0x52, 0x0c, 0x76, 0x69, 0x65, 0x77, 0x5f, 0x70, 0x64, 0x66, 0x5f, 0x75, 0x72, 0x6c, 0x12, 0x21,
0x0a, 0x0b, 0x44, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x55, 0x72, 0x6c, 0x18, 0x07, 0x20,
0x01, 0x28, 0x09, 0x52, 0x0c, 0x64, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x5f, 0x75, 0x72,
0x6c, 0x12, 0x1f, 0x0a, 0x0a, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x4e, 0x6f, 0x18,
0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x63, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x5f,
0x6e, 0x6f, 0x12, 0x25, 0x0a, 0x0d, 0x54, 0x72, 0x61, 0x6e, 0x73, 0x61, 0x63, 0x74, 0x69, 0x6f,
0x6e, 0x49, 0x64, 0x18, 0x09, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x74, 0x72, 0x61, 0x6e, 0x73,
0x61, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x69, 0x64, 0x22, 0x42, 0x0a, 0x13, 0x53, 0x69, 0x67,
0x6e, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x64,
0x12, 0x19, 0x0a, 0x07, 0x4a, 0x75, 0x6d, 0x70, 0x55, 0x72, 0x6c, 0x18, 0x01, 0x20, 0x01, 0x28,
0x09, 0x52, 0x08, 0x6a, 0x75, 0x6d, 0x70, 0x5f, 0x75, 0x72, 0x6c, 0x12, 0x10, 0x0a, 0x03, 0x4d,
0x73, 0x67, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x6d, 0x73, 0x67, 0x22, 0x61, 0x0a,
0x15, 0x46, 0x69, 0x6e, 0x69, 0x73, 0x68, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x52,
0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x25, 0x0a, 0x0d, 0x74, 0x72, 0x61, 0x6e, 0x73, 0x61,
0x63, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x74,
0x72, 0x61, 0x6e, 0x73, 0x61, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x69, 0x64, 0x12, 0x21, 0x0a,
0x0b, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x55, 0x69, 0x64, 0x18, 0x02, 0x20, 0x01,
0x28, 0x09, 0x52, 0x0c, 0x63, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x5f, 0x75, 0x69, 0x64,
0x22, 0x5b, 0x0a, 0x15, 0x46, 0x69, 0x6e, 0x69, 0x73, 0x68, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61,
0x63, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x64, 0x12, 0x30, 0x0a, 0x08, 0x43, 0x6f, 0x6e,
0x74, 0x72, 0x61, 0x63, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x19, 0x2e, 0x61, 0x72,
0x74, 0x69, 0x73, 0x74, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x2e, 0x43, 0x6f, 0x6e,
0x74, 0x72, 0x61, 0x63, 0x74, 0x73, 0x52, 0x03, 0x6d, 0x73, 0x67, 0x12, 0x10, 0x0a, 0x03, 0x4d,
0x73, 0x67, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x6d, 0x73, 0x67, 0x22, 0x6e, 0x0a,
0x15, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x54, 0x78, 0x4c, 0x69, 0x73, 0x74, 0x52,
0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01,
0x28, 0x05, 0x52, 0x02, 0x69, 0x64, 0x12, 0x1b, 0x0a, 0x08, 0x50, 0x61, 0x67, 0x65, 0x53, 0x69,
0x7a, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x09, 0x70, 0x61, 0x67, 0x65, 0x5f, 0x73,
0x69, 0x7a, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x50, 0x61, 0x67, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28,
0x05, 0x52, 0x04, 0x70, 0x61, 0x67, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x53, 0x74, 0x61, 0x74, 0x65,
0x18, 0x04, 0x20, 0x01, 0x28, 0x05, 0x52, 0x05, 0x73, 0x74, 0x61, 0x74, 0x65, 0x22, 0x58, 0x0a,
0x15, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x54, 0x78, 0x4c, 0x69, 0x73, 0x74, 0x52,
0x65, 0x73, 0x70, 0x6f, 0x6e, 0x64, 0x12, 0x2d, 0x0a, 0x04, 0x44, 0x61, 0x74, 0x61, 0x18, 0x01,
0x20, 0x03, 0x28, 0x0b, 0x32, 0x19, 0x2e, 0x61, 0x72, 0x74, 0x69, 0x73, 0x74, 0x43, 0x6f, 0x6e,
0x74, 0x72, 0x61, 0x63, 0x74, 0x2e, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x73, 0x52,
0x04, 0x44, 0x61, 0x74, 0x61, 0x12, 0x10, 0x0a, 0x03, 0x4d, 0x73, 0x67, 0x18, 0x02, 0x20, 0x01,
0x28, 0x09, 0x52, 0x03, 0x6d, 0x73, 0x67, 0x22, 0x49, 0x0a, 0x23, 0x47, 0x65, 0x74, 0x43, 0x6f,
0x03, 0x6d, 0x73, 0x67, 0x22, 0x24, 0x0a, 0x12, 0x47, 0x65, 0x74, 0x43, 0x6f, 0x6e, 0x74, 0x72,
0x61, 0x63, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x64,
0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x02, 0x69, 0x64, 0x22, 0xfd, 0x03, 0x0a, 0x15, 0x55,
0x70, 0x64, 0x61, 0x74, 0x65, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x52, 0x65, 0x71,
0x75, 0x65, 0x73, 0x74, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x04,
0x52, 0x02, 0x69, 0x64, 0x12, 0x16, 0x0a, 0x06, 0x55, 0x73, 0x65, 0x72, 0x49, 0x64, 0x18, 0x02,
0x20, 0x01, 0x28, 0x03, 0x52, 0x06, 0x75, 0x73, 0x65, 0x72, 0x49, 0x64, 0x12, 0x16, 0x0a, 0x06,
0x43, 0x61, 0x72, 0x64, 0x49, 0x64, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x63, 0x61,
0x72, 0x64, 0x49, 0x64, 0x12, 0x1e, 0x0a, 0x0a, 0x4d, 0x67, 0x6d, 0x74, 0x55, 0x73, 0x65, 0x72,
0x49, 0x64, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x6d, 0x67, 0x6d, 0x74, 0x55, 0x73,
0x65, 0x72, 0x49, 0x64, 0x12, 0x1c, 0x0a, 0x09, 0x41, 0x72, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x49,
0x64, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x61, 0x72, 0x74, 0x77, 0x6f, 0x72, 0x6b,
0x49, 0x64, 0x12, 0x1e, 0x0a, 0x0a, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x49, 0x64,
0x18, 0x06, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x63, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74,
0x49, 0x64, 0x12, 0x24, 0x0a, 0x0d, 0x54, 0x72, 0x61, 0x6e, 0x73, 0x61, 0x63, 0x74, 0x69, 0x6f,
0x6e, 0x49, 0x64, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0d, 0x74, 0x72, 0x61, 0x6e, 0x73,
0x61, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x64, 0x12, 0x12, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65,
0x18, 0x08, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x74, 0x79, 0x70, 0x65, 0x12, 0x18, 0x0a, 0x07,
0x42, 0x61, 0x74, 0x63, 0x68, 0x49, 0x64, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x52, 0x07, 0x62,
0x61, 0x74, 0x63, 0x68, 0x49, 0x64, 0x12, 0x1c, 0x0a, 0x09, 0x42, 0x61, 0x74, 0x63, 0x68, 0x4e,
0x61, 0x6d, 0x65, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x62, 0x61, 0x74, 0x63, 0x68,
0x4e, 0x61, 0x6d, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x56, 0x69, 0x65, 0x77, 0x55, 0x72, 0x6c, 0x18,
0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x76, 0x69, 0x65, 0x77, 0x55, 0x72, 0x6c, 0x12, 0x20,
0x0a, 0x0b, 0x44, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x55, 0x72, 0x6c, 0x18, 0x0c, 0x20,
0x01, 0x28, 0x09, 0x52, 0x0b, 0x64, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64, 0x55, 0x72, 0x6c,
0x12, 0x14, 0x0a, 0x05, 0x53, 0x74, 0x61, 0x74, 0x65, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x03, 0x52,
0x05, 0x73, 0x74, 0x61, 0x74, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65,
0x54, 0x69, 0x6d, 0x65, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x75, 0x70, 0x64, 0x61,
0x74, 0x65, 0x54, 0x69, 0x6d, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65,
0x54, 0x69, 0x6d, 0x65, 0x18, 0x0f, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x63, 0x72, 0x65, 0x61,
0x74, 0x65, 0x54, 0x69, 0x6d, 0x65, 0x12, 0x26, 0x0a, 0x0e, 0x45, 0x78, 0x70, 0x69, 0x72, 0x61,
0x74, 0x69, 0x6f, 0x6e, 0x54, 0x69, 0x6d, 0x65, 0x18, 0x10, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e,
0x65, 0x78, 0x70, 0x69, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x54, 0x69, 0x6d, 0x65, 0x12, 0x1a,
0x0a, 0x08, 0x53, 0x69, 0x67, 0x6e, 0x54, 0x69, 0x6d, 0x65, 0x18, 0x11, 0x20, 0x01, 0x28, 0x09,
0x52, 0x08, 0x73, 0x69, 0x67, 0x6e, 0x54, 0x69, 0x6d, 0x65, 0x22, 0x17, 0x0a, 0x15, 0x55, 0x70,
0x64, 0x61, 0x74, 0x65, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x52, 0x65, 0x73, 0x70,
0x6f, 0x6e, 0x64, 0x22, 0x4f, 0x0a, 0x17, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x43, 0x6f, 0x6e,
0x74, 0x72, 0x61, 0x63, 0x74, 0x54, 0x78, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x0e,
0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x02, 0x69, 0x64, 0x12, 0x24,
0x0a, 0x0d, 0x54, 0x72, 0x61, 0x6e, 0x73, 0x61, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x64, 0x18,
0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0d, 0x74, 0x72, 0x61, 0x6e, 0x73, 0x61, 0x63, 0x74, 0x69,
0x6f, 0x6e, 0x49, 0x64, 0x22, 0x19, 0x0a, 0x17, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x43, 0x6f,
0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x54, 0x78, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x64, 0x32,
0xe3, 0x05, 0x0a, 0x0e, 0x41, 0x72, 0x74, 0x69, 0x73, 0x74, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61,
0x63, 0x74, 0x12, 0x60, 0x0a, 0x0e, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x43, 0x6f, 0x6e, 0x74,
0x72, 0x61, 0x63, 0x74, 0x12, 0x25, 0x2e, 0x61, 0x72, 0x74, 0x69, 0x73, 0x74, 0x43, 0x6f, 0x6e,
0x74, 0x72, 0x61, 0x63, 0x74, 0x2e, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x43, 0x6f, 0x6e, 0x74,
0x72, 0x61, 0x63, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x25, 0x2e, 0x61, 0x72,
0x74, 0x69, 0x73, 0x74, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x2e, 0x43, 0x72, 0x65,
0x61, 0x74, 0x65, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f,
0x6e, 0x64, 0x22, 0x00, 0x12, 0x66, 0x0a, 0x10, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74,
0x4c, 0x69, 0x73, 0x74, 0x4d, 0x67, 0x6d, 0x74, 0x12, 0x27, 0x2e, 0x61, 0x72, 0x74, 0x69, 0x73,
0x74, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x2e, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61,
0x63, 0x74, 0x4c, 0x69, 0x73, 0x74, 0x4d, 0x67, 0x6d, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73,
0x74, 0x1a, 0x27, 0x2e, 0x61, 0x72, 0x74, 0x69, 0x73, 0x74, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61,
0x63, 0x74, 0x2e, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x4c, 0x69, 0x73, 0x74, 0x4d,
0x67, 0x6d, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x64, 0x22, 0x00, 0x12, 0x5a, 0x0a, 0x0c,
0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x4c, 0x69, 0x73, 0x74, 0x12, 0x23, 0x2e, 0x61,
0x72, 0x74, 0x69, 0x73, 0x74, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x2e, 0x43, 0x6f,
0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x4c, 0x69, 0x73, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73,
0x74, 0x1a, 0x23, 0x2e, 0x61, 0x72, 0x74, 0x69, 0x73, 0x74, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61,
0x63, 0x74, 0x2e, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x4c, 0x69, 0x73, 0x74, 0x52,
0x65, 0x73, 0x70, 0x6f, 0x6e, 0x64, 0x22, 0x00, 0x12, 0x5a, 0x0a, 0x0c, 0x53, 0x69, 0x67, 0x6e,
0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x12, 0x23, 0x2e, 0x61, 0x72, 0x74, 0x69, 0x73,
0x74, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x2e, 0x53, 0x69, 0x67, 0x6e, 0x43, 0x6f,
0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x23, 0x2e,
0x61, 0x72, 0x74, 0x69, 0x73, 0x74, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x2e, 0x53,
0x69, 0x67, 0x6e, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f,
0x6e, 0x64, 0x22, 0x00, 0x12, 0x60, 0x0a, 0x0e, 0x46, 0x69, 0x6e, 0x69, 0x73, 0x68, 0x43, 0x6f,
0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x12, 0x25, 0x2e, 0x61, 0x72, 0x74, 0x69, 0x73, 0x74, 0x43,
0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x2e, 0x46, 0x69, 0x6e, 0x69, 0x73, 0x68, 0x43, 0x6f,
0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x25, 0x2e,
0x61, 0x72, 0x74, 0x69, 0x73, 0x74, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x2e, 0x46,
0x69, 0x6e, 0x69, 0x73, 0x68, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x52, 0x65, 0x73,
0x70, 0x6f, 0x6e, 0x64, 0x22, 0x00, 0x12, 0x60, 0x0a, 0x0e, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61,
0x63, 0x74, 0x54, 0x78, 0x4c, 0x69, 0x73, 0x74, 0x12, 0x25, 0x2e, 0x61, 0x72, 0x74, 0x69, 0x73,
0x74, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x2e, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61,
0x63, 0x74, 0x54, 0x78, 0x4c, 0x69, 0x73, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a,
0x25, 0x2e, 0x61, 0x72, 0x74, 0x69, 0x73, 0x74, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74,
0x2e, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x54, 0x78, 0x4c, 0x69, 0x73, 0x74, 0x52,
0x65, 0x73, 0x70, 0x6f, 0x6e, 0x64, 0x22, 0x00, 0x12, 0x8a, 0x01, 0x0a, 0x1c, 0x47, 0x65, 0x74,
0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x49, 0x6e, 0x66, 0x6f, 0x42, 0x79, 0x43, 0x6f,
0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x55, 0x69, 0x64, 0x12, 0x33, 0x2e, 0x61, 0x72, 0x74, 0x69,
0x73, 0x74, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x2e, 0x47, 0x65, 0x74, 0x43, 0x6f,
0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x49, 0x6e, 0x66, 0x6f, 0x42, 0x79, 0x43, 0x6f, 0x6e, 0x74,
0x72, 0x61, 0x63, 0x74, 0x55, 0x69, 0x64, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x22,
0x0a, 0x0b, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x55, 0x69, 0x64, 0x18, 0x01, 0x20,
0x01, 0x28, 0x09, 0x52, 0x0d, 0x63, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x5f, 0x6e, 0x61,
0x6d, 0x65, 0x22, 0x66, 0x0a, 0x23, 0x47, 0x65, 0x74, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63,
0x74, 0x49, 0x6e, 0x66, 0x6f, 0x42, 0x79, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x55,
0x69, 0x64, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x64, 0x12, 0x2d, 0x0a, 0x04, 0x44, 0x61, 0x74,
0x61, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x19, 0x2e, 0x61, 0x72, 0x74, 0x69, 0x73, 0x74,
0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 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, 0x22, 0x24, 0x0a, 0x12, 0x47, 0x65,
0x74, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74,
0x12, 0x0e, 0x0a, 0x02, 0x49, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x02, 0x69, 0x64,
0x22, 0xfd, 0x03, 0x0a, 0x15, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x43, 0x6f, 0x6e, 0x74, 0x72,
0x61, 0x63, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44,
0x18, 0x01, 0x20, 0x01, 0x28, 0x04, 0x52, 0x02, 0x69, 0x64, 0x12, 0x16, 0x0a, 0x06, 0x55, 0x73,
0x65, 0x72, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, 0x06, 0x75, 0x73, 0x65, 0x72,
0x49, 0x64, 0x12, 0x16, 0x0a, 0x06, 0x43, 0x61, 0x72, 0x64, 0x49, 0x64, 0x18, 0x03, 0x20, 0x01,
0x28, 0x09, 0x52, 0x06, 0x63, 0x61, 0x72, 0x64, 0x49, 0x64, 0x12, 0x1e, 0x0a, 0x0a, 0x4d, 0x67,
0x6d, 0x74, 0x55, 0x73, 0x65, 0x72, 0x49, 0x64, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a,
0x6d, 0x67, 0x6d, 0x74, 0x55, 0x73, 0x65, 0x72, 0x49, 0x64, 0x12, 0x1c, 0x0a, 0x09, 0x41, 0x72,
0x74, 0x77, 0x6f, 0x72, 0x6b, 0x49, 0x64, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x61,
0x72, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x49, 0x64, 0x12, 0x1e, 0x0a, 0x0a, 0x43, 0x6f, 0x6e, 0x74,
0x72, 0x61, 0x63, 0x74, 0x49, 0x64, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x63, 0x6f,
0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x49, 0x64, 0x12, 0x24, 0x0a, 0x0d, 0x54, 0x72, 0x61, 0x6e,
0x73, 0x61, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x64, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52,
0x0d, 0x74, 0x72, 0x61, 0x6e, 0x73, 0x61, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x64, 0x12, 0x12,
0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x18, 0x08, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x74, 0x79,
0x70, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x42, 0x61, 0x74, 0x63, 0x68, 0x49, 0x64, 0x18, 0x09, 0x20,
0x01, 0x28, 0x03, 0x52, 0x07, 0x62, 0x61, 0x74, 0x63, 0x68, 0x49, 0x64, 0x12, 0x1c, 0x0a, 0x09,
0x42, 0x61, 0x74, 0x63, 0x68, 0x4e, 0x61, 0x6d, 0x65, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x09, 0x52,
0x09, 0x62, 0x61, 0x74, 0x63, 0x68, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x56, 0x69,
0x65, 0x77, 0x55, 0x72, 0x6c, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x76, 0x69, 0x65,
0x77, 0x55, 0x72, 0x6c, 0x12, 0x20, 0x0a, 0x0b, 0x44, 0x6f, 0x77, 0x6e, 0x6c, 0x6f, 0x61, 0x64,
0x55, 0x72, 0x6c, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x64, 0x6f, 0x77, 0x6e, 0x6c,
0x6f, 0x61, 0x64, 0x55, 0x72, 0x6c, 0x12, 0x14, 0x0a, 0x05, 0x53, 0x74, 0x61, 0x74, 0x65, 0x18,
0x0d, 0x20, 0x01, 0x28, 0x03, 0x52, 0x05, 0x73, 0x74, 0x61, 0x74, 0x65, 0x12, 0x1e, 0x0a, 0x0a,
0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x54, 0x69, 0x6d, 0x65, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x09,
0x52, 0x0a, 0x75, 0x70, 0x64, 0x61, 0x74, 0x65, 0x54, 0x69, 0x6d, 0x65, 0x12, 0x1e, 0x0a, 0x0a,
0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x54, 0x69, 0x6d, 0x65, 0x18, 0x0f, 0x20, 0x01, 0x28, 0x09,
0x52, 0x0a, 0x63, 0x72, 0x65, 0x61, 0x74, 0x65, 0x54, 0x69, 0x6d, 0x65, 0x12, 0x26, 0x0a, 0x0e,
0x45, 0x78, 0x70, 0x69, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x54, 0x69, 0x6d, 0x65, 0x18, 0x10,
0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x65, 0x78, 0x70, 0x69, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e,
0x54, 0x69, 0x6d, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x53, 0x69, 0x67, 0x6e, 0x54, 0x69, 0x6d, 0x65,
0x18, 0x11, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x73, 0x69, 0x67, 0x6e, 0x54, 0x69, 0x6d, 0x65,
0x22, 0x17, 0x0a, 0x15, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61,
0x63, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x64, 0x22, 0x4f, 0x0a, 0x17, 0x55, 0x70, 0x64,
0x61, 0x74, 0x65, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x54, 0x78, 0x52, 0x65, 0x71,
0x75, 0x65, 0x73, 0x74, 0x12, 0x0e, 0x0a, 0x02, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03,
0x52, 0x02, 0x69, 0x64, 0x12, 0x24, 0x0a, 0x0d, 0x54, 0x72, 0x61, 0x6e, 0x73, 0x61, 0x63, 0x74,
0x69, 0x6f, 0x6e, 0x49, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0d, 0x74, 0x72, 0x61,
0x6e, 0x73, 0x61, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x64, 0x22, 0x19, 0x0a, 0x17, 0x55, 0x70,
0x64, 0x61, 0x74, 0x65, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x54, 0x78, 0x52, 0x65,
0x73, 0x70, 0x6f, 0x6e, 0x64, 0x32, 0xe3, 0x05, 0x0a, 0x0e, 0x41, 0x72, 0x74, 0x69, 0x73, 0x74,
0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x12, 0x60, 0x0a, 0x0e, 0x43, 0x72, 0x65, 0x61,
0x74, 0x65, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x12, 0x25, 0x2e, 0x61, 0x72, 0x74,
0x69, 0x73, 0x74, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x2e, 0x43, 0x72, 0x65, 0x61,
0x74, 0x65, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73,
0x74, 0x1a, 0x25, 0x2e, 0x61, 0x72, 0x74, 0x69, 0x73, 0x74, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61,
0x63, 0x74, 0x2e, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63,
0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x64, 0x22, 0x00, 0x12, 0x66, 0x0a, 0x10, 0x43, 0x6f,
0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x4c, 0x69, 0x73, 0x74, 0x4d, 0x67, 0x6d, 0x74, 0x12, 0x27,
0x72, 0x61, 0x63, 0x74, 0x55, 0x69, 0x64, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x33,
0x2e, 0x61, 0x72, 0x74, 0x69, 0x73, 0x74, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x2e,
0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x4c, 0x69, 0x73, 0x74, 0x4d, 0x67, 0x6d, 0x74,
0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x27, 0x2e, 0x61, 0x72, 0x74, 0x69, 0x73, 0x74,
0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x2e, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63,
0x74, 0x4c, 0x69, 0x73, 0x74, 0x4d, 0x67, 0x6d, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x64,
0x22, 0x00, 0x12, 0x5a, 0x0a, 0x0c, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x4c, 0x69,
0x73, 0x74, 0x12, 0x23, 0x2e, 0x61, 0x72, 0x74, 0x69, 0x73, 0x74, 0x43, 0x6f, 0x6e, 0x74, 0x72,
0x61, 0x63, 0x74, 0x2e, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x4c, 0x69, 0x73, 0x74,
0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x23, 0x2e, 0x61, 0x72, 0x74, 0x69, 0x73, 0x74,
0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x2e, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63,
0x74, 0x4c, 0x69, 0x73, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x64, 0x22, 0x00, 0x12, 0x5a,
0x0a, 0x0c, 0x53, 0x69, 0x67, 0x6e, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x12, 0x23,
0x2e, 0x61, 0x72, 0x74, 0x69, 0x73, 0x74, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x2e,
0x53, 0x69, 0x67, 0x6e, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x52, 0x65, 0x71, 0x75,
0x65, 0x73, 0x74, 0x1a, 0x23, 0x2e, 0x61, 0x72, 0x74, 0x69, 0x73, 0x74, 0x43, 0x6f, 0x6e, 0x74,
0x72, 0x61, 0x63, 0x74, 0x2e, 0x53, 0x69, 0x67, 0x6e, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63,
0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x64, 0x22, 0x00, 0x12, 0x60, 0x0a, 0x0e, 0x46, 0x69,
0x6e, 0x69, 0x73, 0x68, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x12, 0x25, 0x2e, 0x61,
0x72, 0x74, 0x69, 0x73, 0x74, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x2e, 0x46, 0x69,
0x6e, 0x69, 0x73, 0x68, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x52, 0x65, 0x71, 0x75,
0x65, 0x73, 0x74, 0x1a, 0x25, 0x2e, 0x61, 0x72, 0x74, 0x69, 0x73, 0x74, 0x43, 0x6f, 0x6e, 0x74,
0x72, 0x61, 0x63, 0x74, 0x2e, 0x46, 0x69, 0x6e, 0x69, 0x73, 0x68, 0x43, 0x6f, 0x6e, 0x74, 0x72,
0x61, 0x63, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x64, 0x22, 0x00, 0x12, 0x60, 0x0a, 0x0e,
0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x54, 0x78, 0x4c, 0x69, 0x73, 0x74, 0x12, 0x25,
0x2e, 0x61, 0x72, 0x74, 0x69, 0x73, 0x74, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x2e,
0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x54, 0x78, 0x4c, 0x69, 0x73, 0x74, 0x52, 0x65,
0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x25, 0x2e, 0x61, 0x72, 0x74, 0x69, 0x73, 0x74, 0x43, 0x6f,
0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x2e, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x54,
0x78, 0x4c, 0x69, 0x73, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x64, 0x22, 0x00, 0x12, 0x8a,
0x01, 0x0a, 0x1c, 0x47, 0x65, 0x74, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x49, 0x6e,
0x66, 0x6f, 0x42, 0x79, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x55, 0x69, 0x64, 0x12,
0x33, 0x2e, 0x61, 0x72, 0x74, 0x69, 0x73, 0x74, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74,
0x2e, 0x47, 0x65, 0x74, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x49, 0x6e, 0x66, 0x6f,
0x42, 0x79, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x55, 0x69, 0x64, 0x52, 0x65, 0x71,
0x75, 0x65, 0x73, 0x74, 0x1a, 0x33, 0x2e, 0x61, 0x72, 0x74, 0x69, 0x73, 0x74, 0x43, 0x6f, 0x6e,
0x74, 0x72, 0x61, 0x63, 0x74, 0x2e, 0x47, 0x65, 0x74, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63,
0x74, 0x49, 0x6e, 0x66, 0x6f, 0x42, 0x79, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x55,
0x69, 0x64, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x64, 0x22, 0x00, 0x42, 0x13, 0x5a, 0x11, 0x2e,
0x2f, 0x3b, 0x61, 0x72, 0x74, 0x69, 0x73, 0x74, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74,
0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
0x47, 0x65, 0x74, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x49, 0x6e, 0x66, 0x6f, 0x42,
0x79, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x55, 0x69, 0x64, 0x52, 0x65, 0x73, 0x70,
0x6f, 0x6e, 0x64, 0x22, 0x00, 0x42, 0x13, 0x5a, 0x11, 0x2e, 0x2f, 0x3b, 0x61, 0x72, 0x74, 0x69,
0x73, 0x74, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74,
0x6f, 0x33,
}
var (

View File

@ -31,12 +31,17 @@ message Contracts{
string ExpirationTime = 11 [json_name = "expiration_time"];
string LockTime = 12 [json_name = "lock_time"];
string SignTime = 13 [json_name = "sign_time"];
string BatchTime = 14 [json_name = "batch_time"];
string BatchUid = 15 [json_name = "batch_uid"];
int32 StType = 16 [json_name = "st_type"];
}
message CreateContractRequest {
string ArtistUid = 1 [json_name="artist_uid"];
repeated string ArtworkUid = 2 [json_name="artwork_uid"];
int32 Type = 3 [json_name="type"];
string BatchUid = 3 [json_name="batch_uid"];
string BatchTime = 4 [json_name="batch_time"];
int32 Type = 5 [json_name="type"];
}
message CreateContractRespond{
@ -45,8 +50,9 @@ message CreateContractRespond{
message ContractListMgmtRequest{
string ArtistUid = 1 [json_name = "artist_uid"];
int32 Page = 2 [json_name = "page"];
int32 Num = 3 [json_name = "num"];
int32 Status = 2 [json_name = "status"];
int32 Page = 3 [json_name = "page"];
int32 Num = 4 [json_name = "num"];
}
message ContractListMgmtRespond{
@ -59,7 +65,6 @@ message ContractListRequest {
int32 PageSize = 2 [json_name="pageSize"];
int32 Page = 3 [json_name="page"];
int32 State = 4 [json_name="state"];
}
message ContractListRespond {

View File

@ -121,9 +121,12 @@ func migration() {
&model.ArtshowArtistIndex{}, //画展-画家指数
&model.ArtshowArtistSupplement{}, //画展-画家补充信息
&model.Contract{}, //合同
&model.StatementBatch{}, //对账单批次
&model.ArtworkEntrustDetail{}, //
&model.ArtworkSalesDetail{}, //
&model.ArtworkTx{}, //对账单画作物权
&model.ArtworkTxDetail{}, //对账单画作物权委托详情
&model.ArtworkSoldTxDetail{}, //对账单画作物权销售委托详情
&model.ArtworkCopy{}, //对账单画作版权
&model.ArtworkCopyDetail{}, //对账单画作版权委托详情
&model.ArtworkSoldCopyDetail{}, //对账单画作版权委托售卖详情
)
if err != nil {
fmt.Println("register table fail")

View File

@ -75,4 +75,7 @@ const (
ERROR_BATCH_INSERT = "批量插入失败"
CREATE_BATCH_SUCCESS = "批量插入成功"
ERROR_UPDATE_STATEMENT = "更新对账单状态失败"
ERROR_CRE_ART = "创建失败"
)

View File

@ -2,6 +2,7 @@ package util
import (
"bytes"
"errors"
"fmt"
"io"
"io/ioutil"
@ -14,6 +15,7 @@ import (
"github.com/fonchain/fonchain-artistinfo/pkg/m"
"github.com/fonchain/utils/objstorage"
uuid "github.com/satori/go.uuid"
)
// IdCardTurnAge 身份证号读取年龄
@ -165,3 +167,13 @@ func Post(url, data string) (string, error) {
// str := (*string)(unsafe.Pointer(&respBytes))
return string(respBytes), nil
}
// 生成uid
func GetUid() (uuids string, err error) {
var uid uuid.UUID
if uid, err = uuid.NewV4(); err != nil {
err = errors.New(m.ERROR_UID)
return "", err
}
return uid.String(), nil
}