コード例 #1
0
 public function ys_end_time()
 {
     $order_list = db_factory::query(sprintf(" select * from %switkey_order where order_status='ok' and model_id=6 and ys_end_time<%d order by order_id desc ", TABLEPRE, time()));
     if (is_array($order_list)) {
         foreach ($order_list as $k => $v) {
             $obj = new goods_shop_class();
             $obj->dispose_order($v['order_id'], 'confirm', 'sys');
         }
     }
 }
コード例 #2
0
 public function notify_user($service_id, $service_status = '2')
 {
     global $_K;
     global $_lang;
     $service_obj = $this->_service_obj;
     $model_code = $this->_model_info['model_code'];
     switch ($model_code) {
         case "goods":
             $status_arr = goods_shop_class::get_goods_status();
             break;
         case "service":
             $status_arr = service_shop_class::get_service_status();
             break;
     }
     $message_obj = new keke_msg_class();
     $url = "<a href=\"" . $_K['siteurl'] . "/index.php?do=goods&id=" . $service_id . "\">" . $service_obj->getTitle() . "</a>";
     $v = array($_lang['service_type'] => $this->_model_info['model_name'], $_lang['goods_link'] => $url, $_lang['goods_status'] => $status_arr[$service_status], $_lang['pub_time'] => date('Y-m-d H:i:s', $service_obj->getOn_time()));
     $message_obj->send_message($this->_uid, $this->_username, "service_pub", $this->_model_info['model_name'] . $_lang['release_tips'], $v, $this->_user_info['email'], $this->_user_info['mobile']);
 }
コード例 #3
0
ファイル: index.php プロジェクト: huangbinzd/kppwGit
    die;
}
$intFollow = db_factory::get_count(sprintf('select count(*) from %s where uid = %d and fuid = %d', TABLEPRE . 'witkey_free_follow', intval($gUid), intval($arrServiceInfo['uid'])));
if ($gUid && $gUid !== $arrServiceInfo['uid']) {
    $myOrderInfo = db_factory::get_one("select a.order_status from " . TABLEPRE . "witkey_order a left join " . TABLEPRE . "witkey_order_detail b on a.order_id=b.order_id where b.obj_type='service' and b.obj_id={$id} and a.order_uid={$gUid}");
}
$page and $intPage = intval($page);
intval($intPage) and $p['page'] = intval($intPage) or $p['page'] = '1';
intval($intPagesize) and $p['page_size'] = intval($intPagesize) or $p['page_size'] = 10;
$objTime = new goods_time_class();
$objTime->validtaskstatus();
switch ($view) {
    case "content":
        break;
    case "sale":
        $arrStatus = goods_shop_class::get_order_status();
        $p['url'] = $strUrl . "&view=sale&intPagesize=" . $p['page_size'] . "&intPage=" . $p['page'];
        $p['anchor'] = '#pageT';
        $w = array();
        $w['a.order_status'] = "confirm";
        $t == 'today' and $ext_condit = 'day(date(from_unixtime(a.order_time)))=day(curdate())';
        $arrSaleArr = keke_shop_class::get_sale_info($intId, $w, $p, " a.order_time desc", $ext_condit);
        $arrSaleList = $arrSaleArr['sale_info'];
        $intCount = count($arrSaleList);
        $pages = $arrSaleArr['pages'];
        break;
    case "comment":
        $objComment = keke_comment_class::get_instance('service');
        $arrCommentDatas = $objComment->get_comment_list($intId, $strUrl, $intPage);
        $arrCommentLists = $arrCommentDatas['data'];
        $strPage = $arrCommentDatas['pages'];
コード例 #4
0
ファイル: shop_misc.php プロジェクト: huangbinzd/kppwGit
<?php

defined('ADMIN_KEKE') or exit('Access Denied');
$page = max($page, 1);
$limit = max($limit, 5);
$url = 'index.php?do=' . $do . '&model_id=' . $model_id . '&view=edit&service_id=' . $service_id . '&op=' . $op;
switch ($op) {
    case 'order':
        $order_obj = keke_table_class::get_instance('witkey_order');
        $goods_obj = keke_table_class::get_instance('witkey_service');
        $order_status_arr = goods_shop_class::get_order_status();
        $order_id_arr = db_factory::query(sprintf('select `order_id` from %switkey_order_detail where `obj_id`=%d and `obj_type`="service"', TABLEPRE, $service_id));
        $order_alls = array();
        foreach ($order_id_arr as $v) {
            $order_alls[] = $v['order_id'];
        }
        $order_str = implode(',', $order_alls);
        if ($order_str) {
            $wh = "model_id = 6 and `order_id` in ({$order_str})";
            $w['order_id'] and $wh .= " and order_id like '%{$w['order_id']}%' ";
            $w['order_username'] and $wh .= " and order_username like '%{$w['order_username']}%' ";
            $w['order_status'] and $wh .= " and order_status = '{$w['order_status']}' ";
            $ord['0'] && $ord['1'] and $wh .= ' order by ' . $ord['0'] . ' ' . $ord['1'] or $wh .= " order by order_time desc";
            intval($page) or $page = 1;
            intval($w['page_size']) and $page_size = intval($w['page_size']) or $page_size = '10';
            $url_str = "index.php?do=model&model_id=6&view=order&order_id={$w['order_id']}&order_name={$w['order_name']}&page={$page}&w[page_size]={$page_size}&ord[0]={$ord['0']}&ord[1]={$ord['1']}";
            $table_arr = $order_obj->get_grid($wh, $url_str, $page, $page_size, null, 1, 'ajax_dom');
            $order_arr = $table_arr['data'];
            $pages = $table_arr['pages'];
        } else {
        }
コード例 #5
0
ファイル: buyer_order.php プロジェクト: huangbinzd/kppwGit
                     kekezu::show_msg($resText, null, null, null, 'fail');
                 }
                 break;
             default:
                 kekezu::show_msg('访问页面不存在', 'index.php', 3, null, 'warning');
                 break;
         }
     }
 case 'step3':
     if ($arrServiceInfo['file_path']) {
         $arrFileLists = db_factory::query('select file_name,save_name from ' . TABLEPRE . 'witkey_file where save_name ="' . $arrServiceInfo['file_path'] . '"');
     }
     if (isset($action)) {
         switch ($action) {
             case 'confirm_file':
                 $objGoods = new goods_shop_class();
                 $resText = $objGoods->dispose_order($orderId, 'confirm');
                 unset($objGoods);
                 if (true === $resText) {
                     kekezu::show_msg('确认完成!', $strUrl . "&step=step4&orderId=" . $orderId, 3, null, 'ok');
                 } else {
                     kekezu::show_msg($resText, null, null, null, 'fail');
                 }
                 break;
             default:
                 kekezu::show_msg('访问页面不存在', 'index.php', 3, null, 'warning');
                 break;
         }
     }
     break;
 case 'step4':
コード例 #6
0
ファイル: goods_list.php プロジェクト: pengfeiaaa/web
                    keke_payitem_class::update_service_payitem_time($service_info['payitem_time'], $add_time, $v);
                }
                $res = goods_shop_class::set_service_status($key_ids, 2);
                $action = $_lang['mulit_pass'];
                break;
            case $_lang['mulit_nopass']:
                $res = goods_shop_class::set_service_status($key_ids, 4);
                foreach ($key_ids as $v) {
                    PayitemClass::refundPayitem($v, 'goods');
                }
                $action = '批量审核不通过';
                break;
            case $_lang['batch_shelves']:
                foreach ($key_ids as $v) {
                    $service_info = kekezu::get_table_data("*", "witkey_service", "service_id = {$v}");
                    $service_info = $service_info['0'];
                    $add_time = time() - $service_info['on_time'];
                    keke_payitem_class::update_service_payitem_time($service_info['payitem_time'], $add_time, $v);
                }
                $res = goods_shop_class::set_service_status($key_ids, 2);
                $action = $_lang['shelves'];
                break;
            case $_lang['batch_off_the_shelf']:
                $res = goods_shop_class::set_service_status($key_ids, 3);
                $action = $_lang['off_the_shelf'];
                break;
        }
        $res and kekezu::admin_show_msg($_lang['mulit'] . $action . $_lang['success'], $url_str, 2, $_lang['mulit'] . $action . $_lang['success'], 'success') or kekezu::admin_show_msg($_lang['mulit'] . $action . $_lang['fail'], $url_str, 2, $_lang['mulit'] . $action . $_lang['fail'], "warning");
    }
}
require keke_tpl_class::template('shop/' . $model_info['model_dir'] . '/admin/tpl/goods_' . $view);
コード例 #7
0
ファイル: goods_edit.php プロジェクト: huangbinzd/kppwGit
    $service_info = db_factory::get_one(sprintf("select * from %switkey_service where service_id='%d'", TABLEPRE, $service_id));
    if ($service_info['pic']) {
        $servicePics = explode(',', $service_info['pic']);
    }
    if ($service_info['file_path']) {
        $serviceFiles = explode(',', $service_info['file_path']);
    }
    $service_info['ext_fields'] = CustomClass::getExtDataList($service_info['service_id'], $service_info['model_id']);
    $service_info and extract($service_info) or $service_info = array();
    $indus_pid and $indus_arr = kekezu::get_industry($indus_pid, 0) or $indus_arr = array();
    if ($sbt_edit) {
        if ($ext_fds) {
            CustomClass::editExtData($pk['service_id'], $model_id, $ext_fds);
        }
        kekezu::admin_system_log($_lang['to_witkey_goods_name_is'] . $service_info['title'] . $_lang['to_edit_operate']);
        goods_shop_class::set_on_sale_num($pk['service_id'], $fds['service_status']);
        $service_obj = keke_table_class::get_instance('witkey_service');
        $c = $fds['content'];
        $fds = kekezu::escape($fds);
        $fds['content'] = $c;
        isset($fds['is_top']) or $fds['is_top'] = 0;
        $res = $service_obj->save($fds, $pk);
        kekezu::admin_show_msg($_lang['goods_edit_success'], 'index.php?do=model&model_id=6&view=list', 2, $_lang['goods_edit_success'], 'success');
    }
    if ($file_path) {
        $start = strripos($file_path, "/");
        $file_name = substr($file_path, $start + 1);
    }
} else {
    require S_ROOT . '/shop/' . $model_info['model_dir'] . '/admin/shop_misc.php';
}
コード例 #8
0
ファイル: goods_order.php プロジェクト: huangbinzd/kppwGit
$ord['0'] && $ord['1'] and $wh .= ' order by ' . $ord['0'] . ' ' . $ord['1'] or $wh .= " order by order_time desc";
intval($page) or $page = 1;
intval($w['page_size']) and $page_size = intval($w['page_size']) or $page_size = '10';
$url_str = "index.php?do=model&model_id=6&view=order&w[order_id]={$w['order_id']}&w[order_username]={$w['order_username']}&w[order_status]={$w['order_status']}&page={$page}&w[page_size]={$page_size}&ord[0]={$ord['0']}&ord[1]={$ord['1']}";
$table_arr = $order_obj->get_grid($wh, $url_str, $page, $page_size, null, 1, 'ajax_dom');
$order_arr = $table_arr['data'];
$pages = $table_arr['pages'];
switch ($ac) {
    case 'del':
        $order_obj = new Keke_witkey_order_class();
        $order_obj->setWhere("order_id = {$order_id}");
        $order_obj->del_keke_witkey_order();
        kekezu::admin_show_msg($_lang['operate_notice'], $url_str, 2, $_lang['delete_success'], 'success');
        break;
    case 'confirm':
        $obj = new goods_shop_class();
        $obj->dispose_order($order_id, 'confirm', 'sys', $url_str, $_SESSION['uid']);
        break;
}
if (isset($sbt_action)) {
    $order_obj = new Keke_witkey_order_class();
    sizeof($ckb) or kekezu::admin_show_msg($_lang['choose_operate_item'], $url, 3, '', 'warning');
    is_array($ckb) and $ids = implode(',', array_filter($ckb));
    $order_obj->setWhere("order_id in ({$ids})");
    if ($sbt_action) {
        $res = $order_obj->del_keke_witkey_order();
        kekezu::admin_system_log($_lang['mulit_recovery_articles']);
    }
    $res and kekezu::admin_show_msg($_lang['mulit_operate_success'], $url, 3, '', 'success') or kekezu::admin_show_msg($_lang['mulit_operate_fail'], $url, 3, '', 'warning');
}
function get_submit_method($order_id)