Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
P
plugin
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
JIRA
JIRA
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
link33
plugin
Commits
d35d6cff
Commit
d35d6cff
authored
Apr 14, 2020
by
harrylee
Committed by
vipwzw
Apr 26, 2020
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix a bug for contentstorage
parent
390ba0d3
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
47 additions
and
47 deletions
+47
-47
storage.proto
plugin/dapp/storage/proto/storage.proto
+4
-4
storage.pb.go
plugin/dapp/storage/types/storage.pb.go
+43
-43
No files found.
plugin/dapp/storage/proto/storage.proto
View file @
d35d6cff
...
@@ -24,12 +24,12 @@ message StorageAction {
...
@@ -24,12 +24,12 @@ message StorageAction {
}
}
// 内容存证模型
// 内容存证模型
message
ContentOnlyNotaryStorage
{
message
ContentOnlyNotaryStorage
{
// Op 0表示创建 1表示追加add
int32
op
=
1
;
//长度需要小于512k
//长度需要小于512k
bytes
content
=
2
;
bytes
content
=
1
;
//自定义的主键,可以为空,如果没传,则用txhash为key
//自定义的主键,可以为空,如果没传,则用txhash为key
string
key
=
3
;
string
key
=
2
;
// Op 0表示创建 1表示追加add
int32
op
=
3
;
//字符串值
//字符串值
string
value
=
4
;
string
value
=
4
;
}
}
...
...
plugin/dapp/storage/types/storage.pb.go
View file @
d35d6cff
...
@@ -292,12 +292,12 @@ func (*StorageAction) XXX_OneofWrappers() []interface{} {
...
@@ -292,12 +292,12 @@ func (*StorageAction) XXX_OneofWrappers() []interface{} {
// 内容存证模型
// 内容存证模型
type
ContentOnlyNotaryStorage
struct
{
type
ContentOnlyNotaryStorage
struct
{
// Op 0表示创建 1表示追加add
Op
int32
`protobuf:"varint,1,opt,name=op,proto3" json:"op,omitempty"`
//长度需要小于512k
//长度需要小于512k
Content
[]
byte
`protobuf:"bytes,
2
,opt,name=content,proto3" json:"content,omitempty"`
Content
[]
byte
`protobuf:"bytes,
1
,opt,name=content,proto3" json:"content,omitempty"`
//自定义的主键,可以为空,如果没传,则用txhash为key
//自定义的主键,可以为空,如果没传,则用txhash为key
Key
string
`protobuf:"bytes,3,opt,name=key,proto3" json:"key,omitempty"`
Key
string
`protobuf:"bytes,2,opt,name=key,proto3" json:"key,omitempty"`
// Op 0表示创建 1表示追加add
Op
int32
`protobuf:"varint,3,opt,name=op,proto3" json:"op,omitempty"`
//字符串值
//字符串值
Value
string
`protobuf:"bytes,4,opt,name=value,proto3" json:"value,omitempty"`
Value
string
`protobuf:"bytes,4,opt,name=value,proto3" json:"value,omitempty"`
XXX_NoUnkeyedLiteral
struct
{}
`json:"-"`
XXX_NoUnkeyedLiteral
struct
{}
`json:"-"`
...
@@ -330,13 +330,6 @@ func (m *ContentOnlyNotaryStorage) XXX_DiscardUnknown() {
...
@@ -330,13 +330,6 @@ func (m *ContentOnlyNotaryStorage) XXX_DiscardUnknown() {
var
xxx_messageInfo_ContentOnlyNotaryStorage
proto
.
InternalMessageInfo
var
xxx_messageInfo_ContentOnlyNotaryStorage
proto
.
InternalMessageInfo
func
(
m
*
ContentOnlyNotaryStorage
)
GetOp
()
int32
{
if
m
!=
nil
{
return
m
.
Op
}
return
0
}
func
(
m
*
ContentOnlyNotaryStorage
)
GetContent
()
[]
byte
{
func
(
m
*
ContentOnlyNotaryStorage
)
GetContent
()
[]
byte
{
if
m
!=
nil
{
if
m
!=
nil
{
return
m
.
Content
return
m
.
Content
...
@@ -351,6 +344,13 @@ func (m *ContentOnlyNotaryStorage) GetKey() string {
...
@@ -351,6 +344,13 @@ func (m *ContentOnlyNotaryStorage) GetKey() string {
return
""
return
""
}
}
func
(
m
*
ContentOnlyNotaryStorage
)
GetOp
()
int32
{
if
m
!=
nil
{
return
m
.
Op
}
return
0
}
func
(
m
*
ContentOnlyNotaryStorage
)
GetValue
()
string
{
func
(
m
*
ContentOnlyNotaryStorage
)
GetValue
()
string
{
if
m
!=
nil
{
if
m
!=
nil
{
return
m
.
Value
return
m
.
Value
...
@@ -808,38 +808,38 @@ func init() {
...
@@ -808,38 +808,38 @@ func init() {
}
}
var
fileDescriptor_0d2c4ccf1453ffdb
=
[]
byte
{
var
fileDescriptor_0d2c4ccf1453ffdb
=
[]
byte
{
// 48
7
bytes of a gzipped FileDescriptorProto
// 48
8
bytes of a gzipped FileDescriptorProto
0x1f
,
0x8b
,
0x08
,
0x00
,
0x00
,
0x00
,
0x00
,
0x00
,
0x02
,
0xff
,
0xec
,
0x
95
,
0xcd
,
0x8e
,
0x9
4
,
0x40
,
0x1f
,
0x8b
,
0x08
,
0x00
,
0x00
,
0x00
,
0x00
,
0x00
,
0x02
,
0xff
,
0xec
,
0x
55
,
0xc1
,
0x8a
,
0xd
4
,
0x40
,
0x10
,
0x
c7
,
0x05
,
0x86
,
0x41
,
0x0a
,
0x96
,
0xec
,
0xb6
,
0xeb
,
0x06
,
0xa3
,
0x89
,
0x84
,
0xc3
,
0x66
,
0x10
,
0x
35
,
0xc9
,
0x64
,
0x62
,
0x2a
,
0xb3
,
0x61
,
0xb7
,
0x5d
,
0x97
,
0x88
,
0x82
,
0x21
,
0x87
,
0x65
,
0x
62
,
0xe2
,
0x1c
,
0xc6
,
0xab
,
0x89
,
0xba
,
0x9b
,
0x4d
,
0xc6
,
0x68
,
0x34
,
0xf6
,
0xfa
,
0x02
,
0x2c
,
0x
10
,
0x9c
,
0xc3
,
0x78
,
0x15
,
0xd4
,
0x95
,
0x85
,
0x11
,
0x45
,
0xb1
,
0xd7
,
0x1f
,
0xc8
,
0x86
,
0xc6
,
0x
e9
,
0xc8
,
0x64
,
0x48
,
0x37
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,
0xc7
,
0x47
,
0xa1
,
0xd5
,
0x7b
,
0xab
,
0x
0e
,
0x93
,
0x57
,
0x08
,
0xa7
,
0xac
,
0x2c
,
0x0c
,
0xfc
,
0x19
,
0xdc
,
0xc7
,
0x47
,
0xa1
,
0xc3
,
0x07
,
0x
00
,
0x7f
,
0x20
,
0x54
,
0xd0
,
0xce
,
0x1f
,
0x1f
,
0x43
,
0x40
,
0x59
,
0xca
,
0x36
,
0xdd
,
0x9f
,
0xb8
,
0x
eb
,
0x10
,
0x7f
,
0x20
,
0x44
,
0x50
,
0x93
,
0x4f
,
0x8e
,
0x21
,
0xa4
,
0x2c
,
0x63
,
0x5b
,
0xf3
,
0x27
,
0x
72
,
0xc1
,
0x41
,
0xef
,
0xcd
,
0x5c
,
0xbd
,
0x29
,
0x2f
,
0x7e
,
0x07
,
0x00
,
0x00
,
0xff
,
0xff
,
0x4a
,
0x
ae
,
0x7d
,
0xf0
,
0x30
,
0x7b
,
0x3d
,
0x57
,
0x6f
,
0xca
,
0x8b
,
0x3f
,
0x01
,
0x00
,
0x00
,
0xff
,
0xff
,
0x
d4
,
0x84
,
0x62
,
0x64
,
0x06
,
0x00
,
0x00
,
0x
38
,
0xc7
,
0xa7
,
0x39
,
0x64
,
0x06
,
0x00
,
0x00
,
}
}
// Reference imports to suppress errors if they are not otherwise used.
// Reference imports to suppress errors if they are not otherwise used.
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment