改进 Drops 计算

This commit is contained in:
iVampireSP.com 2022-09-09 21:17:31 +08:00
parent 8521234bb2
commit ae972decd6
No known key found for this signature in database
GPG Key ID: 2F7B001CA27A8132
2 changed files with 5 additions and 2 deletions

View File

@ -20,8 +20,10 @@ function getDrops($user_id)
$multiple *= 10;
}
$drops = Cache::get($cache_key);
$drops = Cache::get($cache_key) / (config('drops.decimal') * $multiple);
// 除以 $multiple
$drops = $drops / $multiple;
return $drops;
}

View File

@ -9,6 +9,7 @@
use App\Http\Controllers\Controller;
use Alipay\EasySDK\Kernel\Util\ResponseChecker;
use Alipay\EasySDK\Kernel\Factory as AlipayFactory;
use Illuminate\Support\Facades\Log;
class BalanceController extends Controller
{
@ -87,7 +88,7 @@ public function show(Request $request, Balance $balance)
return view('pay', compact('html'));
}
} catch (Exception $e) {
dd($e->getMessage());
Log::error($e);
echo "调用失败," . $e->getMessage() . PHP_EOL;;
}