|
@@ -51,6 +51,7 @@ class Money extends Common
|
|
|
$openid = $this->request->request("openid", "");
|
|
|
$params_from = $this->request->request("params_from",1);
|
|
|
$amounts = $this->request->request("amounts",0);
|
|
|
+ $jewelRate = config('site.money_to_jewel');
|
|
|
if (!$rechar_id && empty($amounts)) {
|
|
|
$this->error(__('Invalid parameters'));
|
|
|
}
|
|
@@ -66,9 +67,9 @@ class Money extends Common
|
|
|
$recharMode = new \app\common\model\RecharConfig();
|
|
|
$recharInfo = $recharMode->where(["id" => $rechar_id])->find();
|
|
|
} else {
|
|
|
- $amountsNew = $amounts * 100;
|
|
|
+ $amountsNew = $amounts * $jewelRate;
|
|
|
$recharInfo = [
|
|
|
- 'money' => $amountsNew,
|
|
|
+ 'money' => $amounts,
|
|
|
'jewel' => $amountsNew,
|
|
|
'jewel_full' => $amountsNew,
|
|
|
];
|
|
@@ -88,7 +89,7 @@ class Money extends Common
|
|
|
if ($userMoney > $maxMoney) {
|
|
|
$this->error('请先实名认证');
|
|
|
}
|
|
|
- }echo '<pre>';var_dump(3);exit;
|
|
|
+ }
|
|
|
if ($params_from == "ios") {
|
|
|
$jewel = $recharInfo['jewel'];
|
|
|
} else {
|