Commit 010b4916 authored by rlgy's avatar rlgy

update

parent f3ab64e3
...@@ -70,6 +70,9 @@ class CoinReleaseMemberController extends BaseController ...@@ -70,6 +70,9 @@ class CoinReleaseMemberController extends BaseController
$model->scenario = CoinReleaseMember::SCENARIOS_ADD; $model->scenario = CoinReleaseMember::SCENARIOS_ADD;
} }
if ($model->load($post) && $model->validate()) { if ($model->load($post) && $model->validate()) {
$model->amount = $model->amount * 1e8;
$model->release = $model->release * 1e8;
$model->freeze = $model->freeze * 1e8;
if ($model->save()) { if ($model->save()) {
return ['code' => 0, 'msg' => '添加成功']; return ['code' => 0, 'msg' => '添加成功'];
} }
...@@ -127,6 +130,7 @@ class CoinReleaseMemberController extends BaseController ...@@ -127,6 +130,7 @@ class CoinReleaseMemberController extends BaseController
/** /**
* 获取rule_id * 获取rule_id
*
* @return int * @return int
*/ */
private function getRuleId() private function getRuleId()
......
...@@ -23,7 +23,7 @@ ListAsset::register($this); ...@@ -23,7 +23,7 @@ ListAsset::register($this);
<tr> <tr>
<td><?= $coin_name ?></td> <td><?= $coin_name ?></td>
<td><?= $amount / 1e8 ?></td> <td><?= $amount / 1e8 ?></td>
<td><?= $release_amount ?></td> <td><?= $release_amount / 1e8 ?></td>
<td><?= $address ?></td> <td><?= $address ?></td>
</tr> </tr>
</tbody> </tbody>
......
...@@ -9,9 +9,21 @@ table.render({ ...@@ -9,9 +9,21 @@ table.render({
cols: [[ cols: [[
{field: 'mobile', title: '手机号'}, {field: 'mobile', title: '手机号'},
{field: 'coin', title: '币种'}, {field: 'coin', title: '币种'},
{field: 'amount', title: '总量'}, {
{field: 'release', title: '已解冻'}, field: 'amount', title: '总量', templet: function (d) {
{field: 'freeze', title: '已冻结'}, return d.amount / 1e8;
}
},
{
field: 'release', title: '已解冻', templet: function (d) {
return d.release / 1e8;
}
},
{
field: 'freeze', title: '已冻结', templet: function (d) {
return d.freeze / 1e8;
}
},
]] ]]
}); });
...@@ -29,7 +41,7 @@ upload.render({ ...@@ -29,7 +41,7 @@ upload.render({
} }
}); });
}, },
before: function(obj){ //obj参数包含的信息,跟 choose回调完全一致,可参见上文。 before: function (obj) { //obj参数包含的信息,跟 choose回调完全一致,可参见上文。
layer.load(); //上传loading layer.load(); //上传loading
} }
}); });
......
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