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
20999292
Commit
20999292
authored
Apr 28, 2019
by
mdj33
Committed by
vipwzw
May 05, 2019
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
modify 0 amount process
parent
9b7c5006
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
8 additions
and
1 deletion
+8
-1
paracross.go
plugin/dapp/paracross/commands/paracross.go
+1
-1
superaccount.go
plugin/dapp/paracross/executor/superaccount.go
+7
-0
No files found.
plugin/dapp/paracross/commands/paracross.go
View file @
20999292
...
@@ -329,7 +329,7 @@ func nodeGroupApply(cmd *cobra.Command, args []string) {
...
@@ -329,7 +329,7 @@ func nodeGroupApply(cmd *cobra.Command, args []string) {
return
return
}
}
payload
:=
&
pt
.
ParaNodeGroupApply
{
Op
:
op
,
Addrs
:
addrs
,
CoinsFrozen
:
int64
(
math
.
Trunc
((
coins
)
*
1e4
))
*
1e4
}
payload
:=
&
pt
.
ParaNodeGroupApply
{
Op
:
op
,
Addrs
:
addrs
,
CoinsFrozen
:
int64
(
math
.
Trunc
((
coins
+
0.0000001
)
*
1e4
))
*
1e4
}
params
:=
&
rpctypes
.
CreateTxIn
{
params
:=
&
rpctypes
.
CreateTxIn
{
Execer
:
types
.
ExecName
(
pt
.
ParaX
),
Execer
:
types
.
ExecName
(
pt
.
ParaX
),
ActionName
:
"NodeGroupApply"
,
ActionName
:
"NodeGroupApply"
,
...
...
plugin/dapp/paracross/executor/superaccount.go
View file @
20999292
...
@@ -494,6 +494,9 @@ func (a *action) nodeGroupCoinsFrozen(addrs []string, configCoinsFrozen int64) (
...
@@ -494,6 +494,9 @@ func (a *action) nodeGroupCoinsFrozen(addrs []string, configCoinsFrozen int64) (
if
configCoinsFrozen
<
confCoins
{
if
configCoinsFrozen
<
confCoins
{
return
nil
,
pt
.
ErrParaNodeGroupFrozenCoinsNotEnough
return
nil
,
pt
.
ErrParaNodeGroupFrozenCoinsNotEnough
}
}
if
configCoinsFrozen
==
0
{
return
receipt
,
nil
}
var
logs
[]
*
types
.
ReceiptLog
var
logs
[]
*
types
.
ReceiptLog
var
kv
[]
*
types
.
KeyValue
var
kv
[]
*
types
.
KeyValue
...
@@ -522,6 +525,10 @@ func (a *action) nodeGroupCoinsActive(addrs []string, configCoinsFrozen int64) (
...
@@ -522,6 +525,10 @@ func (a *action) nodeGroupCoinsActive(addrs []string, configCoinsFrozen int64) (
realExec
:=
string
(
types
.
GetRealExecName
(
a
.
tx
.
Execer
))
realExec
:=
string
(
types
.
GetRealExecName
(
a
.
tx
.
Execer
))
realExecAddr
:=
dapp
.
ExecAddress
(
realExec
)
realExecAddr
:=
dapp
.
ExecAddress
(
realExec
)
if
configCoinsFrozen
==
0
{
return
receipt
,
nil
}
for
_
,
addr
:=
range
addrs
{
for
_
,
addr
:=
range
addrs
{
r
,
err
:=
a
.
coinsAccount
.
ExecActive
(
addr
,
realExecAddr
,
configCoinsFrozen
)
r
,
err
:=
a
.
coinsAccount
.
ExecActive
(
addr
,
realExecAddr
,
configCoinsFrozen
)
if
err
!=
nil
{
if
err
!=
nil
{
...
...
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