@ -68,8 +68,9 @@ class DepositRecordDailyRepository extends BaseRepository
$currentDeposit = $depositList[$record['deposit_id']];
if(time() - strtotime($record['create_time']) > 86400 * $currentDeposit['cycle'] and $record['status'] == 1){
$record->status = 2;
$record->status = 3;
$record->save();
app(UserAssetsRepository::class)->updateAssets($record['uid'], array('deposit' => $record['price']));
}
if ($item['diamond'] < $currentDeposit['diamond_max']) {
@ -99,6 +99,9 @@ class UserAssetsRepository extends BaseRepository
if (isset($data['stock']) and $data['stock']) {
$update['stock'] = $data['stock'];
if (isset($data['deposit']) and $data['deposit']) {
$update['deposit'] = $data['deposit'];
$updateData = array();
foreach ($update as $key => $value) {
if ($value) {
@ -85,7 +85,7 @@ class Auth extends BaseController
// app(UserAssetsLogRepository::class)->shareAward(1);
// app(DepositRecordDailyRepository::class)->runDaily();
event('pay_success_user_recharge', array('order_sn' => 'wxu2024041817195114'));
// event('pay_success_user_recharge', array('order_sn' => 'wxu2024041817195114'));
return app('json')->success();