|
|
@@ -37,9 +37,30 @@ class Wallet extends BaseController
|
|
|
$product = SanJinService::$PRODUCT;
|
|
|
$list = [];
|
|
|
foreach($data as $k => $v) {
|
|
|
+ $config = [];
|
|
|
foreach($product as $pv) {
|
|
|
if ($k == $pv['type']) {
|
|
|
- $config = $pv;
|
|
|
+ if ($config) {
|
|
|
+ if (empty($config['range'])) {
|
|
|
+ $config['range'][] = $config;
|
|
|
+ }
|
|
|
+ if ($pv['min'] < $config['min']) {
|
|
|
+ $config['min'] = $pv['min'];
|
|
|
+ }
|
|
|
+ if ($pv['max'] > $config['max']) {
|
|
|
+ $config['max'] = $pv['max'];
|
|
|
+ }
|
|
|
+ if ($pv['rate'] < $config['rate']) {
|
|
|
+ $config['max_rate'] = $config['rate'];
|
|
|
+ $config['min_rate'] = $pv['rate'];
|
|
|
+ }
|
|
|
+ if ($pv['rate'] > $config['rate']) {
|
|
|
+ $config['max_rate'] = $pv['rate'];
|
|
|
+ }
|
|
|
+ $config['range'][] = $pv;
|
|
|
+ } else {
|
|
|
+ $config = $pv;
|
|
|
+ }
|
|
|
}
|
|
|
}
|
|
|
$list[] = [
|
|
|
@@ -48,6 +69,7 @@ class Wallet extends BaseController
|
|
|
'config' => $config ?? [],
|
|
|
];
|
|
|
}
|
|
|
+
|
|
|
return $this->success([
|
|
|
'list' => $list,
|
|
|
]);
|
|
|
@@ -98,7 +120,7 @@ class Wallet extends BaseController
|
|
|
$receivingType = ConfigService::getVal("receiving_type");
|
|
|
//自动充值
|
|
|
if ($receivingType == 1) {
|
|
|
- $res = WalletService::getRechargeImageAddress($member_id, $address);
|
|
|
+ $res = WalletService::getRechargeImageAddress($member_id);
|
|
|
$qrCode = $res['full_path'];
|
|
|
} else {
|
|
|
//手动充值
|