本文整理汇总了PHP中get_order_detail函数的典型用法代码示例。如果您正苦于以下问题:PHP get_order_detail函数的具体用法?PHP get_order_detail怎么用?PHP get_order_detail使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了get_order_detail函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的PHP代码示例。
示例1: order
function order()
{
switch ($_SERVER['REQUEST_METHOD']) {
case 'GET':
$order_id = isset($_REQUEST['id']) ? intval($_REQUEST['id']) : 0;
if ($order_id > 0) {
$r_data = get_order_detail($order_id, $user_id);
} else {
$page = isset($_REQUEST['page']) ? intval($_REQUEST['page']) : 1;
$limit = isset($_REQUEST['limit']) ? intval($_REQUEST['limit']) : 1;
$r_data = get_user_orders($user_id, $limit, $page);
}
// $record_count = $db->getOne("SELECT COUNT(*) FROM " .$ecs->table('order_info'). " WHERE user_id = '$user_id'");
return $r_data;
break;
case 'DELETE':
$order_id = isset($_REQUEST['id']) ? intval($_REQUEST['id']) : 0;
$user_id = $_SESSION['user_id'];
if (cancel_order($order_id, $user_id)) {
$r_data = 'Cancle Order Success!';
} else {
$r_data = 'Cancle Order Failed!';
}
return $r_data;
break;
default:
return 'This API can not support ' . $_SERVER['REQUEST_METHOD'] . ' method';
break;
}
}
开发者ID:jiusanzhou,项目名称:ecapi,代码行数:30,代码来源:lib_controller_order.php
示例2: add_order
function add_order($orderInfo)
{
$orderInfo = GetDefaultOrderInfo($orderInfo);
$dbh = new PDOConnection();
$order_id = AddOrderFromInfo($dbh, $orderInfo);
if (isset($orderInfo['lines'])) {
add_order_detail($dbh, $order_id, $orderInfo['lines']);
}
//return all order data to display on the order confirmation page
$orderConf = get_order_detail(array('details' => 1, 'order_id' => $order_id));
return $orderConf;
}
开发者ID:c-topherl,项目名称:brewCom,代码行数:12,代码来源:add_order.php
示例3: COUNT
$record_count = $db->getOne("SELECT COUNT(*) FROM " . $ecs->table('order_info') . " WHERE user_id = '{$user_id}'");
$pager = get_pager('user.php', array('act' => $action), $record_count, $page);
$orders = get_user_orders($user_id, $pager['size'], $pager['start']);
$merge = get_user_merge($user_id);
$smarty->assign('merge', $merge);
$smarty->assign('pager', $pager);
$smarty->assign('orders', $orders);
$smarty->display('user_transaction.dwt');
} elseif ($action == 'order_detail') {
include_once ROOT_PATH . 'includes/lib_transaction.php';
include_once ROOT_PATH . 'includes/lib_payment.php';
include_once ROOT_PATH . 'includes/lib_order.php';
include_once ROOT_PATH . 'includes/lib_clips.php';
$order_id = isset($_GET['order_id']) ? intval($_GET['order_id']) : 0;
/* 订单详情 */
$order = get_order_detail($order_id, $user_id);
if ($order === false) {
$err->show($_LANG['back_home_lnk'], './');
exit;
}
/* 是否显示添加到购物车 */
if ($order['extension_code'] != 'group_buy' && $order['extension_code'] != 'exchange_goods') {
$smarty->assign('allow_to_cart', 1);
}
/* 订单商品 */
$goods_list = order_goods($order_id);
foreach ($goods_list as $key => $value) {
$goods_list[$key]['market_price'] = price_format($value['market_price'], false);
$goods_list[$key]['goods_price'] = price_format($value['goods_price'], false);
$goods_list[$key]['subtotal'] = price_format($value['subtotal'], false);
}
开发者ID:BGCX261,项目名称:zishashop-svn-to-git,代码行数:31,代码来源:user.php
示例4: action_order_detail
function action_order_detail()
{
$user = $GLOBALS['user'];
$_CFG = $GLOBALS['_CFG'];
$_LANG = $GLOBALS['_LANG'];
$smarty = $GLOBALS['smarty'];
$db = $GLOBALS['db'];
$ecs = $GLOBALS['ecs'];
$user_id = $_SESSION['user_id'];
include_once ROOT_PATH . 'includes/lib_transaction.php';
include_once ROOT_PATH . 'includes/lib_payment.php';
include_once ROOT_PATH . 'includes/lib_order.php';
include_once ROOT_PATH . 'includes/lib_clips.php';
$order_id = isset($_GET['order_id']) ? intval($_GET['order_id']) : 0;
/* 订单详情 */
$order = get_order_detail($order_id, $user_id);
/* 退换货插件 www.68ecshop.com增加 */
$shipping_time = $db->getOne("SELECT shipping_time FROM " . $ecs->table('order_info') . " WHERE order_id = '{$order_id}'");
$now_time = gmtime();
$not_back = 0;
if ($GLOBALS['_CFG']['tuihuan_days_fahuo'] > 0) {
if (($now_time - $shipping_time) / 86400 < $GLOBALS['_CFG']['tuihuan_days_fahuo']) {
$not_back = 1;
}
}
if ($GLOBALS['_CFG']['tuihuan_days_qianshou'] > 0) {
if (($now_time - $shipping_time) / 86400 > $GLOBALS['_CFG']['tuihuan_days_qianshou']) {
$not_back = 1;
}
}
$smarty->assign('not_back', $not_back);
/* 退换货插件 www.68ecshop.com增加 */
if ($order === false) {
$err->show($_LANG['back_home_lnk'], './');
exit;
}
if ($db->getOne("select shipping_code from " . $ecs->table('shipping') . " where shipping_id=" . $order['shipping_id']) == "tc_express") {
$order['tc_express'] = 1;
$ko_order_sn = $db->getOne("select invoice_no from " . $ecs->table('delivery_order') . " where order_id=" . $order_id);
if ($ko_order_sn) {
$kos_order_id = $db->getOne("select order_id from " . $ecs->table('kuaidi_order') . " where order_sn='" . $ko_order_sn . "'");
}
$sql = "select * from " . $ecs->table('kuaidi_order_status') . " where order_id='{$kos_order_id}' order by status_id";
$res_status = $db->query($sql);
$have_shipping_info = 0;
$shipping_info = "";
while ($row_status = $db->fetchRow($res_status)) {
if ($row_status['status_display'] == 1) {
switch ($row_status['status_id']) {
case 1:
$shipping_info .= "您提交了订单,请等待确认。 (" . local_date('Y-m-d H:i:s', $row_status['status_time']) . ")";
break;
case 2:
$shipping_info .= "您的快件已经确认,等待快递员揽收。 (" . local_date('Y-m-d H:i:s', $row_status['status_time']) . ")";
break;
case 3:
$postman_id = $db->getOne("select postman_id from " . $ecs->table('kuaidi_order') . " where order_sn='" . $order['invoice_no'] . "'");
$postman_info = $db->getRow("select postman_name, mobile from " . $ecs->table('postman') . " where postman_id=" . $postman_id);
$shipping_info .= "您的快件正在派送,快递员:" . $postman_info['postman_name'] . ",电话:" . $postman_info['mobile'] . " (" . local_date('Y-m-d H:i:s', $row_status['status_time']) . ")";
break;
case 4:
$shipping_info .= "您的快件已经签收。 (" . local_date('Y-m-d H:i:s', $row_status['status_time']) . ")";
break;
case 5:
$shipping_info .= "您的快件已被拒收。 (" . local_date('Y-m-d H:i:s', $row_status['status_time']) . ")";
break;
case 6:
$shipping_info .= "您拒收的快件已被退回。 (" . local_date('Y-m-d H:i:s', $row_status['status_time']) . ")";
break;
case 7:
$shipping_info .= "您的快件已经取消。 (" . local_date('Y-m-d H:i:s', $row_status['status_time']) . ")";
break;
}
$shipping_info .= "<br>";
if ($row_status['status_id'] >= 1) {
$have_shipping_info++;
}
}
}
if ($have_shipping_info) {
$result_content = $shipping_info;
} else {
$result_content = '抱歉,暂时还没有该运单的物流信息哦!';
}
}
$smarty->assign('result_content', $result_content);
/* 是否显示添加到购物车 */
if ($order['extension_code'] != 'group_buy' && $order['extension_code'] != 'exchange_goods') {
$smarty->assign('allow_to_cart', 1);
}
/* 订单商品 */
$goods_list = order_goods($order_id);
foreach ($goods_list as $key => $value) {
$goods_list[$key]['market_price'] = price_format($value['market_price'], false);
$goods_list[$key]['goods_price'] = price_format($value['goods_price'], false);
$goods_list[$key]['subtotal'] = price_format($value['subtotal'], false);
$sql_back = "SELECT bg.*, bo.back_type FROM " . $ecs->table('back_goods') . " AS bg " . " LEFT JOIN " . $ecs->table('back_order') . " AS bo " . " ON bg.back_id = bo.back_id " . " WHERE bo.order_id = " . $order_id . " AND bg.goods_id = " . $value['goods_id'] . " AND bg.product_id = " . $value['product_id'] . " AND bg.status_back < 6";
$back_info = $db->getRow($sql_back);
if (count($back_info['back_id']) > 0) {
switch ($back_info['status_back']) {
//.........这里部分代码省略.........
开发者ID:seanguo166,项目名称:yinoos,代码行数:101,代码来源:user.php
示例5: date
/*
# ----------------------------------------------------------------------
# ORDER - EDIT: CONTROL
# ----------------------------------------------------------------------
*/
if(isset($_POST['btn-edit-order'])){
/*
# ----------------------------------------------------------------------
# DEFINED VARIABLE
# ----------------------------------------------------------------------
*/
$set_fulfilment_date = date("Y-m-d H:i:s");
$get_order_id = get_order_detail_by_number($order_number);
$order_detail = get_order_detail($get_order_id['order_id']);
$order_item = order_item($order_detail['order_id']);
$data_header_method = $_POST['order_payment_method'];
$data_header_name = escape_quote($_POST['order_confirm_name']);
$data_header_amount = clean_price($_POST['order_confirm_amount']);
$data_purchase_amount = $_POST['hidden_total_purchase'];
$data_shipping = $_POST['hidden_order_shipping_amount'];
$data_order_id = $_POST['hidden_order_id'];
$ship_address = ltrim(escape_quote($_POST['order_shipping_address']));
$ship_country = $_POST['order_shipping_country'];
$ship_province = $_POST['order_shipping_province'];
$ship_city = $_POST['order_shipping_city'];
/*
# ----------------------------------------------------------------------
开发者ID:nickyudha,项目名称:huntstreet-v3,代码行数:31,代码来源:control.php
示例6: get_pager
// print_r($sql);exit;
$pager = get_pager('user.php', array('act' => $action), $record_count, $page, $page_parm['count']);
$orders = GZ_get_user_orders($user_id, $pager['size'], $pager['start'], $type);
// print_r($orders);exit;
foreach ($orders as $key => $value) {
unset($orders[$key]['order_status']);
$orders[$key]['order_time'] = formatTime($value['order_time']);
$goods_list = GZ_order_goods($value['order_id']);
//$orders[$key]['ss'] = $goods_list;
$goods_list_t = array();
// $goods_list = API_DATA("SIMPLEGOODS", $goods_list);
foreach ($goods_list as $v) {
$goods_list_t[] = array("goods_id" => $v['goods_id'], "name" => $v['goods_name'], "goods_number" => $v['goods_number'], "subtotal" => price_format($v['subtotal'], false), "formated_shop_price" => price_format($v['goods_price'], false), "img" => array('small' => API_DATA('PHOTO', $v['goods_thumb']), 'thumb' => API_DATA('PHOTO', $v['goods_img']), 'url' => API_DATA('PHOTO', $v['original_img'])));
}
$orders[$key]['goods_list'] = $goods_list_t;
$order_detail = get_order_detail($value['order_id'], $user_id);
$orders[$key]['formated_integral_money'] = $order_detail['formated_integral_money'];
//积分 钱
$orders[$key]['formated_bonus'] = $order_detail['formated_bonus'];
//红包 钱
$orders[$key]['formated_shipping_fee'] = $order_detail['formated_shipping_fee'];
//运送费
if ($order_detail['pay_id'] > 0) {
$payment = payment_info($order_detail['pay_id']);
}
$subject = $orders[$key]['goods_list'][0]['name'] . '等' . count($orders[$key]['goods_list']) . '种商品';
$orders[$key]['order_info'] = array('pay_code' => $payment['pay_code'], 'order_amount' => $order_detail['order_amount'], 'order_id' => $order_detail['order_id'], 'subject' => $subject, 'desc' => $subject, 'order_sn' => $order_detail['order_sn']);
}
// print_r($orders);exit;
$pagero = array("total" => $pager['record_count'], "count" => count($orders), "more" => empty($pager['page_next']) ? 0 : 1);
GZ_Api::outPut($orders, $pagero);
开发者ID:dx8719,项目名称:ECMobile_Universal,代码行数:31,代码来源:list.php
示例7: return_action
$GLOBALS['db']->autoExecute($GLOBALS['ecs']->table('order_return'), $arr, 'UPDATE', "rec_id = '{$rec_id}'");
return_action($ret_id, RF_COMPLETE, $back_order['refund_status'], RC_APPLY_SUCCESS, $action_note);
} elseif ('canceled' == $operation) {
/* 标记订单为“取消”,记录取消原因 */
$cancel_note = isset($_REQUEST['cancel_note']) ? trim($_REQUEST['cancel_note']) : '';
$arr = array('return_status' => RF_CANCELED, 'refund_status' => FF_NOREFUND, 'is_check' => RC_APPLY_FALSE, 'to_buyer' => $cancel_note, 'actual_return' => 0);
$GLOBALS['db']->autoExecute($GLOBALS['ecs']->table('order_return'), $arr, 'UPDATE', "rec_id = '{$rec_id}'");
/*更新log*/
return_action($ret_id, RF_CANCELED, FF_NOREFUND, RC_APPLY_FALSE, $action_note);
} elseif ('invalid' == $operation) {
//TODO
} elseif ('refund' == $operation) {
include_once ROOT_PATH . 'includes/lib_transaction.php';
/* 定义当前时间 */
define('GMTIME_UTC', gmtime());
// 获取 UTC 时间戳
$order_goods = get_order_goods($order);
//订单商品
foreach ($order_goods['goods_list'] as $key => $value) {
$array_rec_id[] = $value['rec_id'];
}
$aftermarket_list = return_order_info_byId($order_id);
//退换货订单
foreach ($aftermarket_list as $key => $value) {
$array_rec_id1[] = $value['rec_id'];
}
$order_info = get_order_detail($order_id);
if (!array_diff($array_rec_id, $array_rec_id1)) {
//整单退换货
$return_count = return_order_info_byId($order_id, 0);
}
开发者ID:jianhuaixie,项目名称:yundds,代码行数:31,代码来源:aftermarket.php
示例8: elseif
$smarty->assign('shares', $shares);
$smarty->assign('yhcwebsite', $yhcwebsite);
$smarty->display('user_transaction.dwt');
} elseif ($action == 'order_detail') {
include_once ROOT_PATH . 'includes/lib_transaction.php';
include_once ROOT_PATH . 'includes/lib_payment.php';
include_once ROOT_PATH . 'includes/lib_order.php';
include_once ROOT_PATH . 'includes/lib_clips.php';
include_once ROOT_PATH . 'includes/upacp/common.php';
include_once ROOT_PATH . 'includes/upacp/SDKConfig.php';
include_once ROOT_PATH . 'includes/upacp/secureUtil.php';
include_once ROOT_PATH . 'includes/upacp/log.class.php';
include_once ROOT_PATH . 'includes/upacp/httpClient.php';
$order_id = isset($_GET['order_id']) ? intval($_GET['order_id']) : 0;
/* 订单详情 */
$order = get_order_detail($order_id, $user_id, '07');
if ($order === false) {
$err->show($_LANG['back_home_lnk'], './');
exit;
}
/* 是否显示添加到购物车 */
if ($order['extension_code'] != 'group_buy' && $order['extension_code'] != 'exchange_goods') {
$smarty->assign('allow_to_cart', 1);
}
/* 订单商品 */
$goods_list = order_goods($order_id);
foreach ($goods_list as $key => $value) {
$goods_list[$key]['market_price'] = price_format($value['market_price'], false);
$goods_list[$key]['goods_price'] = price_format($value['goods_price'], false);
$goods_list[$key]['subtotal'] = price_format($value['subtotal'], false);
}
开发者ID:naliduo,项目名称:ecshop,代码行数:31,代码来源:user.php
示例9: elseif
$smarty->assign('orders', $orders);
}
$smarty->display('order_list.dwt');
exit;
} elseif ($act == 'order_detail') {
if (!$_SESSION['user_id']) {
$smarty->display('login.dwt');
exit;
}
$id = isset($_GET['order_id']) ? intval($_GET['order_id']) : 0;
include_once ROOT_PATH . 'includes/lib_transaction.php';
include_once ROOT_PATH . 'includes/lib_payment.php';
include_once ROOT_PATH . 'includes/lib_order.php';
include_once ROOT_PATH . 'includes/lib_clips.php';
/* 订单详情 */
$order = get_order_detail($id, $_SESSION['user_id']);
if ($order === false) {
exit("对不起,该订单不存在");
}
require_once ROOT_PATH . 'languages/' . $_CFG['lang'] . '/user.php';
/* 订单商品 */
$goods_list = order_goods2($id);
if (empty($goods_list)) {
$tips = '<br><br>无效错误订单<br><br><a href=user.php?act=order_list class=red>返回我的订单</a>';
$smarty->assign('tips', $tips);
$smarty->display('order_done.dwt');
exit;
}
foreach ($goods_list as $key => $value) {
$goods_list[$key]['market_price'] = price_format($value['market_price'], false);
$goods_list[$key]['goods_price'] = price_format($value['goods_price'], false);
开发者ID:qgz,项目名称:ecshop,代码行数:31,代码来源:user.php
示例10: action_order_detail
function action_order_detail()
{
$user = $GLOBALS['user'];
$_CFG = $GLOBALS['_CFG'];
$_LANG = $GLOBALS['_LANG'];
$smarty = $GLOBALS['smarty'];
$db = $GLOBALS['db'];
$ecs = $GLOBALS['ecs'];
$user_id = $GLOBALS['user_id'];
include_once ROOT_PATH . 'includes/lib_transaction.php';
include_once ROOT_PATH . 'includes/lib_payment.php';
include_once ROOT_PATH . 'includes/lib_order.php';
include_once ROOT_PATH . 'includes/lib_clips.php';
include_once ROOT_PATH . 'kuaidi/kuaidi.php';
$order_id = isset($_GET['order_id']) ? intval($_GET['order_id']) : 0;
/* 订单详情 */
$order = get_order_detail($order_id, $user_id);
if ($order === false) {
$GLOBALS['err']->show($_LANG['back_home_lnk'], './');
exit;
}
/* 是否显示添加到购物车 */
if ($order['extension_code'] != 'group_buy' && $order['extension_code'] != 'exchange_goods') {
$smarty->assign('allow_to_cart', 1);
}
/* 订单商品 */
$goods_list = order_goods($order_id);
foreach ($goods_list as $key => $value) {
$goods_list[$key]['market_price'] = price_format($value['market_price'], false);
$goods_list[$key]['goods_price'] = price_format($value['goods_price'], false);
$goods_list[$key]['subtotal'] = price_format($value['subtotal'], false);
}
/* 设置能否修改使用余额数 */
if ($order['order_amount'] > 0) {
if ($order['order_status'] == OS_UNCONFIRMED || $order['order_status'] == OS_CONFIRMED) {
$user = user_info($order['user_id']);
if ($user['user_money'] + $user['credit_line'] > 0) {
$smarty->assign('allow_edit_surplus', 1);
$smarty->assign('max_surplus', sprintf($_LANG['max_surplus'], $user['user_money']));
}
}
}
/* 未发货,未付款时允许更换支付方式 */
if ($order['order_amount'] > 0 && $order['pay_status'] == PS_UNPAYED && $order['shipping_status'] == SS_UNSHIPPED) {
$payment_list = available_payment_list(false, 0, true);
/* 过滤掉当前支付方式和余额支付方式 */
if (is_array($payment_list)) {
foreach ($payment_list as $key => $payment) {
if ($payment['pay_id'] == $order['pay_id'] || $payment['pay_code'] == 'balance') {
unset($payment_list[$key]);
}
}
}
$smarty->assign('payment_list', $payment_list);
}
/* 订单 支付 配送 状态语言项 */
$order['order_status'] = $_LANG['os'][$order['order_status']];
$order['pay_status'] = $_LANG['ps'][$order['pay_status']];
$order['shipping_status'] = $_LANG['ss'][$order['shipping_status']];
//快递跟踪
$kuaidi = new Express();
$result = $kuaidi->getorder($order['shipping_name'], $order['invoice']);
$smarty->assign('kuaidi', $result['data'][0]);
$smarty->assign('order', $order);
$smarty->assign('goods_list', $goods_list);
$smarty->display('user_transaction.dwt');
}
开发者ID:moonlight-wang,项目名称:feilun,代码行数:67,代码来源:user9-9.php
示例11: array
$user = array();
$user['user_money'] = $user_info['user_money'] - $order['order_amount'];
update_user($_SESSION['user_id'], $user);
//修改白条消费记录支付状态
$bt_log_sql = "update " . $ecs->table('baitiao_log') . " set is_repay=1,repayed_date=" . gmtime() . " where order_id='{$order['order_id']}'";
$is_pay_bt = $db->query($bt_log_sql);
if ($is_pay_bt) {
show_message("支付成功");
} else {
show_message("支付失败");
}
}
}
$sql = "UPDATE " . $ecs->table('order_info') . " SET pay_id='{$pay_id}', pay_name='{$payment_info['pay_name']}', pay_fee='{$pay_fee}', order_amount='{$order_amount}'" . " WHERE order_id = '{$order_id}'";
$db->query($sql);
$order = get_order_detail($order_id, $user_id, true);
$payment_list = available_payment_list(false, 0, true);
$smarty->assign('order', $order);
$smarty->assign('action', 'repay_bt');
$smarty->assign('payment_list', $payment_list);
$smarty->display('user_transaction.dwt');
} elseif ($action == 'bonus') {
include_once ROOT_PATH . 'includes/lib_transaction.php';
$page = isset($_REQUEST['page']) ? intval($_REQUEST['page']) : 1;
$record_count = $db->getOne("SELECT COUNT(*) FROM " . $ecs->table('user_bonus') . " WHERE user_id = '{$user_id}'");
$pager = get_pager('user.php', array('act' => $action), $record_count, $page);
$bonus = get_user_bouns_list($user_id, $pager['size'], $pager['start']);
$smarty->assign('pager', $pager);
$smarty->assign('bonus', $bonus);
$smarty->display('user_transaction.dwt');
} elseif ($action == 'group_buy') {
开发者ID:tang7h,项目名称:jzmall,代码行数:31,代码来源:user.php
示例12: elseif
echo $json->encode($msg);
return;
}
$sql_replace = 'REPLACE INTO ' . $GLOBALS['ecs']->table('brush_order') . '(source_order_id,brush_order_sn,brusher_id,brush_platform)VALUES(' . "{$source_order_id},'{$brush_order_sn}',{$_SESSION['admin_id']},{$brush_platform})";
if ($GLOBALS['db']->query($sql_replace)) {
$msg['message'] = '刷单信息保存成功!系统将自动标记发货并过滤!';
$msg['id'] = $source_order_id;
} else {
$msg['message'] = '刷单信息保存失败!请联系技术人员!';
}
echo $json->encode($msg);
return;
} elseif ($_REQUEST['act'] == 'show_single_info') {
$order_id = intval($_REQUEST['order_id']);
$table = mysql_real_escape_string($_REQUEST['table']);
$order_info = get_order_detail($order_id, $table);
$sql_insert = 'INSERT INTO ' . $GLOBALS['ecs']->table('view_user_info') . '(order_id,admin_id)VALUES(' . "{$order_id},{$_SESSION['admin_id']})";
$GLOBALS['db']->query($sql_insert);
$msg = array('req_msg' => true, 'message' => "{$order_info['mobile']}<br>{$order_info['tel']}<br>{$order_info['province']}{$order_info['city']}{$order_info['district']}<br>{$order_info['address']}");
echo $json->encode($msg);
return;
} elseif ($_REQUEST['act'] == 'order_receipt') {
if (!admin_priv('order_receipt', '', false)) {
echo '对不起,您没有权限打印收据!';
return;
}
$order_id = intval($_REQUEST['order_id']);
$sql_select = 'SELECT g.goods_name,g.goods_price,g.goods_number,FROM_UNIXTIME(i.shipping_time, "%Y-%m-%d") shipping_date,' . 'i.final_amount,i.consignee FROM ' . $GLOBALS['ecs']->table('order_goods') . ' g, ' . $GLOBALS['ecs']->table('order_info') . " i WHERE i.order_id=g.order_id AND g.goods_price>0 AND g.is_gift<>1 AND i.shipping_status=1 AND i.order_id={$order_id}";
$goods_list = $GLOBALS['db']->getAll($sql_select);
if (empty($goods_list)) {
echo '订单尚未发货,或商品列表为空,请查证后再打印收据!';
开发者ID:554119220,项目名称:kjrscrm,代码行数:31,代码来源:order.php
示例13: get_user_order_list
public static function get_user_order_list()
{
include_once ROOT_PATH . 'includes/lib_transaction.php';
include_once ROOT_PATH . 'includes/lib_payment.php';
include_once ROOT_PATH . 'includes/lib_order.php';
include_once ROOT_PATH . 'includes/lib_clips.php';
global $db;
global $ecs;
$user_id = $_SESSION['user_id'];
if (!$user_id) {
return json_encode(array('code' => RES_FAIL, 'msg' => 'user_id not exsit'));
}
$orders = $db->getAll("SELECT * FROM " . $ecs->table('order_info') . " WHERE user_id = '{$user_id}' order by order_id DESC");
$res = array();
foreach ($orders as $v) {
$order_id = $v['order_id'];
$order_detail = $db->getAll("SELECT * FROM " . $ecs->table('order_goods') . " WHERE order_id = '{$order_id}'");
$v['detail'] = $order_detail;
$pay_online = get_order_detail($order_id, $user_id, true);
$v['pay_online'] = $pay_online;
array_push($res, $v);
}
return json_encode(array('code' => RES_SUCCSEE, 'orders' => $res));
}
开发者ID:fromzyy2ann,项目名称:mescake,代码行数:24,代码来源:user.php
示例14: add_order
break;
case 'add_order':
include_once __DIR__ . '/orders/add_order.php';
$responseArray['response'] = add_order($values);
$responseArray['status'] = 'success';
$responseArray['message'] = 'Added order';
break;
case 'get_orders':
include_once __DIR__ . '/orders/get_orders.php';
$responseArray['response'] = get_orders($values);
$responseArray['status'] = 'success';
$responseArray['message'] = 'Orders successfully read';
break;
case 'get_order_detail':
include_once __DIR__ . '/orders/get_orders.php';
$responseArray['response'] = get_order_detail($values);
$responseArray['status'] = 'success';
$responseArray['message'] = 'Order details successfully read';
break;
case 'get_delivery_options':
include_once __DIR__ . '/orders/get_delivery_options.php';
$responseArray['status'] = 'success';
$responseArray['message'] = 'This feature is not implemented, but always will return \'pickup\' for now';
$responseArray['response'] = get_delivery_options($values);
break;
default:
$responseArray['status'] = 'failure';
$responseArray['message'] = "Unknown function: {$function}";
}
echo json_encode($responseArray);
exit;
开发者ID:c-topherl,项目名称:brewCom,代码行数:31,代码来源:order_controller.php
示例15: get_user_articles
function get_user_articles($where, $page = 1, $size = 20)
{
$sql = 'SELECT article_id,order_id,is_open, title, author, click, add_time, file_url, open_type, keywords, description' . ' FROM ' . $GLOBALS['ecs']->table('article') . ' WHERE 1 = 1 AND ' . $where . ' ORDER BY article_type DESC, article_id DESC';
$res = $GLOBALS['db']->selectLimit($sql, $size, ($page - 1) * $size);
$arr = array();
if ($res) {
while ($row = $GLOBALS['db']->fetchRow($res)) {
$article_id = $row['article_id'];
$arr[$article_id]['id'] = $article_id;
$arr[$article_id]['title'] = $row['title'];
$arr[$article_id]['is_open'] = $row['is_open'];
$arr[$article_id]['keywords'] = $row['keywords'];
$arr[$article_id]['description'] = $row['description'];
$arr[$article_id]['short_title'] = $GLOBALS['_CFG']['article_title_length'] > 0 ? sub_str($row['title'], $GLOBALS['_CFG']['article_title_length']) : $row['title'];
$arr[$article_id]['author'] = empty($row['author']) || $row['author'] == '_SHOPHELP' ? $GLOBALS['_CFG']['shop_name'] : $row['author'];
$arr[$article_id]['url'] = build_uri('article', array('aid' => $article_id), $row['title']);
$arr[$article_id]['file_url'] = trim($row['file_url']);
$arr[$article_id]['add_time'] = date($GLOBALS['_CFG']['date_format'], $row['add_time']);
$arr[$article_id]['click'] = $row['click'];
$arr[$article_id]['order_id'] = $row['order_id'];
include_once ROOT_PATH . 'includes/lib_transaction.php';
/* 订单详情 */
$order_id = empty($row['order_id']) ? '0' : $row['order_id'];
$order = get_order_detail($order_id, $user_id);
$arr[$article_id]['order_sn'] = $order['order_sn'];
}
}
return $arr;
}
开发者ID:qgz,项目名称:ecshop,代码行数:29,代码来源:user.php
注:本文中的get_order_detail函数示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论