feat: 页面修改

This commit is contained in:
陈狼 2025-02-17 09:39:17 +08:00
parent 9aea9eb294
commit 919f29699e
2 changed files with 15 additions and 10 deletions

View File

@ -8,6 +8,7 @@ use App\Utils\ApiResponseApp;
use App\model\Dictionary;
use App\model\ExchangeRate;
use hg\apidoc\annotation as Apidoc;
use support\Db;
@ -30,21 +31,25 @@ class CommonController
$Dictionary=Dictionary::all();
$res=[];
$ExchangeRate = ExchangeRate::all();
$res = [
"account_notice" => "Log in to link account and get 300 to 3,000 random points a day",
"vi_rate" => "2.49",
"trx_rate" => "0.00",
"nrly_rate" => "30",
"trx_rate1" => "",
"inr_rate" => "1.62",
"php_rate" => null,
"brl_rate" => "0.10",
// "vi_rate" => "2.49",
// "trx_rate" => "0.00",
// "nrly_rate" => "30",
// "trx_rate1" => "",
// "inr_rate" => "1.62",
// "php_rate" => null,
// "brl_rate" => "0.10",
"brl_fee" => "300",
"pkr_fee" => "300",
"pkr_rate" => "5",
// "pkr_rate" => "5",
"pkr_min" => "2000",
"brl_min" => "5000"
];
foreach ($ExchangeRate as $item) {
$res[strtolower($item['type']) . '_rate'] = $item['points'];
}
$col=['service_1','service_2','service_3','service_url','service_user_url','points'];
foreach($Dictionary as $key=>$value){
$res[$value->key]=$value->value;

View File

@ -88,7 +88,7 @@ class WithdrawController
$money = $money_no/100*$rate[0]['points'];
var_dump($money);
//用户积分减少$money
UserRewardDao::base($user_id, 1, -($money_no+500), '提现');
UserRewardDao::base($user_id, 1, -($money_no+300), '提现');
//大于1000等待管理员审核
if($money>=1000){
Withdraw::create([
@ -159,7 +159,7 @@ class WithdrawController
$userbank->save();
$rate = ExchangeRate::where('type','BDT')->get();
//计算积分
$money = $amount*100/$rate[0]['points']+500;
$money = $amount*100/$rate[0]['points']+300;
//用户id
$user_id=$request->data['id'];
//用户积分增加$money