Пример #1
0
 if ($intSbtWithdraw) {
     $objWithdrawM = new Keke_witkey_withdraw_class();
     if (isset($formhash) && kekezu::submitcheck($formhash)) {
         if ($gUserInfo['balance'] < floatval($intWithdrawCash)) {
             $tips['errors']['intWithdrawCash'] = '您的金额不足以提现';
             kekezu::show_msg($tips, $strUrl . "&strStep=1&intReset=1", NULL, NULL, 'error');
         }
         if (strtoupper(CHARSET) == 'GBK') {
             $pay_username = kekezu::utftogbk($pay_username);
             $pay_account = kekezu::utftogbk($pay_account);
         }
         $objWithdrawM->setWithdraw_cash(floatval($intWithdrawCash));
         $objWithdrawM->setUid($uid);
         $objWithdrawM->setUsername($username);
         $objWithdrawM->setPay_username($pay_username);
         $objWithdrawM->setWithdraw_status(1);
         $objWithdrawM->setApplic_time(time());
         $objWithdrawM->setPay_type($pay_type);
         $objWithdrawM->setPay_account($pay_account);
         $intWithdrawId = $objWithdrawM->create_keke_witkey_withdraw();
         if ($intWithdrawId) {
             unset($_SESSION['withdraw_cash']);
             $arrPayway = array_merge(keke_glob_class::get_bank(), keke_glob_class::get_online_pay());
             $data = array(':pay_way' => $arrPayway[$pay_type], ':pay_account' => $pay_account, ':pay_name' => $pay_username);
             keke_finance_class::init_mem('withdraw', $data);
             keke_finance_class::cash_out($uid, abs(floatval($intWithdrawCash)), 'withdraw', 0, 'withdraw', $intWithdrawId);
             kekezu::show_msg('提交成功等待审核', $strUrl . "&strStep=4&intWithdrawCash={$intWithdrawCash}&intWithdrawId={$intWithdrawId}&ver=1#userCenter", NULL, NULL, 'ok');
         } else {
             kekezu::show_msg('提交失败', $strUrl . "&strStep=4&intWithdrawCash={$intWithdrawCash}#userCenter", NULL, NULL, 'error');
         }
     }
Пример #2
0
                kekezu::admin_system_log($_lang['delete_audit_withdraw'] . $ids);
                break;
            case $_lang['mulit_review']:
                $withdraw_obj->setWhere(' withdraw_id in (' . $ids . ') ');
                $withdraw_arr = $withdraw_obj->query_keke_witkey_withdraw();
                foreach ($withdraw_arr as $k => $v) {
                    if ($v[withdraw_status] == 1) {
                        $fee = $v['withdraw_cash'] - keke_finance_class::get_to_cash($v['withdraw_cash']);
                        db_factory::execute(sprintf(' update %switkey_withdraw set fee=%.2f where withdraw_id=%d', TABLEPRE, $fee, $v['withdraw_id']));
                        $v_arr = array('网站名称' => $_K['sitename'], '提现方式' => $pay_way[$v['pay_type']], '帐户' => $v['pay_account'], '提现金额' => $v['withdraw_cash']);
                        keke_msg_class::notify_user($v['uid'], $v['username'], 'draw_success', $_lang['withdraw_success'], $v_arr);
                        $feed_arr = array("feed_username" => array("content" => $v['username'], "url" => "index.php?do=seller&id=" . $space_info['uid']), "action" => array("content" => $_lang['withdraw'], "url" => ""), "event" => array("content" => $_lang['withdraw_le'] . $v['withdraw_cash'] . $_lang['yuan'], "url" => ""));
                        kekezu::save_feed($feed_arr, $user_space_info['uid'], $user_space_info['username'], 'withdraw');
                        $withdraw_obj = new Keke_witkey_withdraw_class();
                        $withdraw_obj->setWhere(' withdraw_id in (' . $ids . ') ');
                        $withdraw_obj->setWithdraw_status(2);
                        $withdraw_obj->setProcess_uid($admin_info['uid']);
                        $withdraw_obj->setProcess_username($admin_info['username']);
                        $withdraw_obj->setProcess_time(time());
                        $withdraw_obj->edit_keke_witkey_withdraw();
                    }
                }
                kekezu::admin_system_log($_lang['audit_withdraw_apply'] . $ids);
                break;
        }
        kekezu::admin_show_msg($_lang['mulit_operate_success'], 'index.php?do=' . $do . '&view=' . $view, 3, '', 'success');
    } else {
        kekezu::admin_show_msg($_lang['choose_operate_item'], 'index.php?do=' . $do . '&view=' . $view, 3, '', 'warning');
    }
} elseif ($type == 'batch' && $pay_type == 'alipayjs') {
    $payment_config = kekezu::get_payment_config('alipayjs');