WalletLog::addLog($wallet_id, ($value*-1), " From user ($users_id) ".$user->getUser()." - ".$description , $json_data, "success", "addBalance to main wallet");
}
}
public function saveBalance($users_id, $value) {
if(!User::isAdmin()){
return false;
}
$wallet = $this->getWallet($users_id);
$balance = $wallet->getBalance();
$wallet->setBalance($value);
$wallet_id = $wallet->save();
$description = "Admin set your balance, from {$balance} to {$value}";
$description = "Transfer Balance {$value} from <strong>YOU</strong> to user <a href='{$global['webSiteRootURL']}channel/{$users_id_to}'>{$identificationTo}</a>";
$description = "Transfer Balance {$value} from user <a href='{$global['webSiteRootURL']}channel/{$users_id_from}'>{$identificationFrom}</a> to <strong>YOU</strong>";