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
f5f24cf7
Commit
f5f24cf7
authored
Nov 27, 2019
by
shajiaiming
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix
parent
c5a9ccb8
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
8 additions
and
5 deletions
+8
-5
IssueChainTransferController.php
console/controllers/IssueChainTransferController.php
+8
-5
IssueCoinController.php
console/controllers/IssueCoinController.php
+0
-0
No files found.
console/controllers/IssueChainTransferController.php
View file @
f5f24cf7
...
...
@@ -3,6 +3,7 @@
namespace
console\controllers
;
use
common\models\psources\CoinIssueRevokeRecord
;
use
common\models\psources\CoinPlatformWithHold
;
use
Yii
;
use
yii\console\Controller
;
use
yii\helpers\ArrayHelper
;
...
...
@@ -63,9 +64,11 @@ class IssueChainTransferController extends Controller
return
0
;
}
$node
=
Yii
::
$app
->
params
[
'chain_nodes'
][
'STO'
];
$chain_service
=
new
Chain33Service
(
$node
);
foreach
(
$model
as
$val
)
{
$platform
=
CoinPlatformWithHold
::
find
()
->
select
(
'platform'
)
->
where
([
'id'
=>
$val
->
coin
->
chain_id
])
->
one
();
$node
=
Yii
::
$app
->
params
[
'chain_nodes'
][
strtoupper
(
$platform
->
platform
)];
$chain_service
=
new
Chain33Service
(
$node
);
//执行1.2构造
$result
=
$chain_service
->
createRawTokenFinishTx
(
$val
->
coin
->
symbol
,
$val
->
coin
->
owner
);
if
(
null
!=
$result
[
'error'
])
{
...
...
@@ -79,7 +82,6 @@ class IssueChainTransferController extends Controller
$txHex
=
$result
[
'result'
];
$privkey
=
'8ac19c0b8858ccd6ed34e2bce0f11be2fc696e658d0b98fb1d3ef85ec5a3992c'
;
#$privkey = $val->coin->chain->private_key;
$expire
=
'1m'
;
//执行1.2签名
$signRawTx
=
$chain_service
->
signRawTx
(
$privkey
,
$txHex
,
$expire
);
...
...
@@ -141,10 +143,11 @@ class IssueChainTransferController extends Controller
return
0
;
}
$node
=
Yii
::
$app
->
params
[
'chain_nodes'
][
'STO'
];
$service
=
new
Chain33Service
(
$node
);
$current_time
=
time
();
foreach
(
$model
as
$val
)
{
$platform
=
CoinPlatformWithHold
::
find
()
->
select
(
'platform'
)
->
where
([
'id'
=>
$val
->
coin
->
chain_id
])
->
one
();
$node
=
Yii
::
$app
->
params
[
'chain_nodes'
][
strtoupper
(
$platform
->
platform
)];
if
(
1
==
$step
)
{
$result
=
$this
->
queryTransaction
(
$node
,
$val
->
pre_send_transaction
);
#$result = $service->QueryTransaction($val->pre_send_transaction);
...
...
console/controllers/IssueCoinController.php
deleted
100644 → 0
View file @
c5a9ccb8
This diff is collapsed.
Click to expand it.
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