Commit 896cfbfe authored by shajiaiming's avatar shajiaiming

fix

parent a43ae0f0
......@@ -260,10 +260,9 @@ class AirDropController extends Controller
echo date('Y-m-d H:i:s') . '暂无空投计划' . PHP_EOL;
return 0;
}
$node_params = Yii::$app->params['chain_parallel']['primary'];
$service = new Chain33Service($node_params);
foreach ($model as $key => $val) {
go(function () use ($val, $service) {
go(function () use ($val) {
\Co::sleep(0.5);
$id = $val['id'];
$to = $val['to_address'];
......@@ -271,10 +270,14 @@ class AirDropController extends Controller
$fee = 100000;
$note = '';
if (CoinAirDropTransfer::TYPE_COINS == $val['type']) {
$node_params = Yii::$app->params['chain_parallel']['primary'];
$service = new Chain33Service($node_params);
$execer = 'coins';
$createRawTransaction = $service->createRawTransaction($to, $amount, $fee, $note, $execer);
}
if (CoinAirDropTransfer::TYPE_TOKEN == $val['type']) {
$node_params = Yii::$app->params['chain_parallel']['parallel'];
$service = new Chain33Service($node_params);
$execer = 'user.p.mall.token';
$isToken = true;
$tokenSymbol = $val['coin_name'];
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment