Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
B
baas-ide
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
1
Merge Requests
1
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
guxukai
baas-ide
Commits
0df5d87e
Commit
0df5d87e
authored
Apr 05, 2016
by
Oleksii Matiiasevych
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix runTx constant call with args to real eth node
parent
e42c3e74
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
15 additions
and
1 deletion
+15
-1
universal-dapp.js
assets/js/universal-dapp.js
+15
-1
No files found.
assets/js/universal-dapp.js
View file @
0df5d87e
...
...
@@ -418,7 +418,21 @@ UniversalDApp.prototype.runTx = function( data, args, cb) {
if
(
!
this
.
vm
)
{
if
(
constant
&&
!
isConstructor
)
{
var
func
=
web3
.
eth
.
contract
(
[
args
.
abi
]
).
at
(
to
);
func
[
args
.
abi
.
name
].
call
(
cb
);
var
prepareCallArgs
=
function
(
callArgs
)
{
var
split
=
function
(
str
,
arr
)
{
if
(
str
===
""
)
return
arr
;
var
chunk
=
str
.
slice
(
0
,
64
);
arr
.
push
(
"0x"
+
chunk
);
return
split
(
str
.
slice
(
64
),
arr
);
}
return
split
(
callArgs
,
[]);
};
var
argsOnly
=
data
.
slice
(
10
);
var
callArgs
=
prepareCallArgs
(
argsOnly
);
callArgs
.
push
(
cb
);
func
[
args
.
abi
.
name
].
call
.
apply
(
this
,
callArgs
);
}
else
{
var
tx
=
{
from
:
self
.
options
.
getAddress
?
self
.
options
.
getAddress
()
:
web3
.
eth
.
accounts
[
0
],
...
...
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