Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
T
token
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
wallet
token
Commits
597a0c79
Commit
597a0c79
authored
Nov 25, 2019
by
shajiaiming
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix
parent
2e16fe95
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
44 additions
and
0 deletions
+44
-0
Chain33Service.php
common/service/chain33/Chain33Service.php
+20
-0
IssueChainController.php
wallet/controllers/IssueChainController.php
+24
-0
No files found.
common/service/chain33/Chain33Service.php
View file @
597a0c79
...
...
@@ -394,6 +394,26 @@ class Chain33Service
}
/**
* 查询所有预创建的token GetTokens
* @param string $execer
* @param string $funcName
* @return array
*/
public
function
getTokens
(
$execer
,
$funcName
)
{
$params
=
[
'execer'
=>
$execer
,
'funcName'
=>
$funcName
,
'payload'
=>
[
'status'
=>
0
,
'queryAll'
=>
true
,
'symbolOnly'
=>
true
]
];
return
$this
->
send
(
$params
,
'Chain33.Query'
);
}
/**
* @param array $hashes
* @return array
*/
...
...
wallet/controllers/IssueChainController.php
View file @
597a0c79
...
...
@@ -4,6 +4,7 @@ namespace wallet\controllers;
use
common\models\psources\CoinPlatform
;
use
common\models\psources\CoinSupportedCoin
;
use
common\service\chain33\Chain33Service
;
use
Yii
;
use
wallet\base\BaseController
;
...
...
@@ -164,4 +165,26 @@ class IssueChainController extends BaseController
return
[
'code'
=>
$code
,
'msg'
=>
$msg
];
}
/**
* 查询所有预创建的token
* @param string execer
* @return array
*/
public
function
actionGetTokens
()
{
$data
=
null
;
$execer
=
\Yii
::
$app
->
request
->
post
(
'execer'
,
'token'
);
$node
=
Yii
::
$app
->
params
[
'chain_nodes'
][
'STO'
];
$service
=
new
Chain33Service
(
$node
);
$funcName
=
'GetTokens'
;
$result
=
$service
->
getTokens
(
'user.p.daitao.token'
,
$funcName
);
echo
json_encode
(
$result
);
exit
;
$code
=
0
;
$msg
=
'success'
;
doEnd
:
return
[
'code'
=>
$code
,
'msg'
=>
$msg
];
}
}
\ No newline at end of file
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