本文整理汇总了PHP中get_shipping_object函数的典型用法代码示例。如果您正苦于以下问题:PHP get_shipping_object函数的具体用法?PHP get_shipping_object怎么用?PHP get_shipping_object使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了get_shipping_object函数的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的PHP代码示例。
示例1: die
} else {
$result['error'] = 1;
$result['message'] = $GLOBALS['err']->last_message();
}
die($json->encode($result));
} else {
if ($action == 'track_packages') {
include_once ROOT_PATH . 'includes/lib_transaction.php';
include_once ROOT_PATH . 'includes/lib_order.php';
$page = isset($_REQUEST['page']) ? intval($_REQUEST['page']) : 1;
$orders = array();
$sql = "SELECT order_id,order_sn,invoice_no,shipping_id FROM " . $ecs->table('order_info') . " WHERE user_id = '{$user_id}' AND shipping_status = '" . SS_SHIPPED . "'";
$res = $db->query($sql);
$record_count = 0;
while ($item = $db->fetch_array($res)) {
$shipping = get_shipping_object($item['shipping_id']);
if (method_exists($shipping, 'query')) {
$query_link = $shipping->query($item['invoice_no']);
} else {
$query_link = $item['invoice_no'];
}
if ($query_link != $item['invoice_no']) {
$item['query_link'] = $query_link;
$orders[] = $item;
$record_count += 1;
}
}
$pager = get_pager('user.php', array('act' => $action), $record_count, $page);
$smarty->assign('pager', $pager);
$smarty->assign('orders', $orders);
$smarty->display('user_transaction.dwt');
开发者ID:BGCX261,项目名称:zishashop-svn-to-git,代码行数:31,代码来源:user.php
示例2: order_tracking
/**
* 订单跟踪
*/
public function order_tracking()
{
$order_id = I('get.order_id', 0);
$ajax = I('get.ajax', 0);
$where['user_id'] = $this->user_id;
$where['order_id'] = $order_id;
$orders = $this->model->table('order_info')->field('order_id, order_sn, invoice_no, shipping_name, shipping_id')->where($where)->find();
// 生成快递100查询接口链接
$shipping = get_shipping_object($orders['shipping_id']);
$query_link = $shipping->kuaidi100($orders['invoice_no']);
$get_content = Http::doGet($query_link);
$this->assign('title', L('order_tracking'));
$this->assign('trackinfo', $get_content);
$this->display('user_order_tracking.dwt');
}
开发者ID:ChanHarold,项目名称:ecshop,代码行数:18,代码来源:UserController.class.php
示例3: action_track_packages
function action_track_packages()
{
$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_order.php';
$page = isset($_REQUEST['page']) ? intval($_REQUEST['page']) : 1;
$orders = array();
$sql = "SELECT order_id,order_sn,invoice_no,shipping_id FROM " . $ecs->table('order_info') . " WHERE user_id = '{$user_id}' AND shipping_status = '" . SS_SHIPPED . "'";
$res = $db->query($sql);
$record_count = 0;
while ($item = $db->fetch_array($res)) {
$shipping = get_shipping_object($item['shipping_id']);
if (method_exists($shipping, 'query')) {
$query_link = $shipping->query($item['invoice_no']);
} else {
$query_link = $item['invoice_no'];
}
if ($query_link != $item['invoice_no']) {
$item['query_link'] = $query_link;
$orders[] = $item;
$record_count += 1;
}
}
$pager = get_pager('user.php', array('act' => $action), $record_count, $page);
$smarty->assign('pager', $pager);
$smarty->assign('orders', $orders);
$smarty->display('user_transaction.dwt');
}
开发者ID:seanguo166,项目名称:yinoos,代码行数:34,代码来源:user.php
示例4: foreach
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);
$goods_list[$key]['subtotal'] = price_format($value['subtotal'], false);
}
/* 订单 支付 配送 状态语言项 */
$order['order_status'] = $_LANG['os'][$order['order_status']];
$order['pay_status'] = $_LANG['ps'][$order['pay_status']];
$order['shipping_status'] = $_LANG['ss'][$order['shipping_status']];
$shipping = get_shipping_object($order['shipping_id']);
if (method_exists($shipping, 'query')) {
$query_link = $shipping->query($order['invoice_no']);
} else {
$query_link = $order['invoice_no'];
}
if ($query_link != $order['invoice_no']) {
$order['query_link'] = "[单号:" . $query_link . "]";
}
$smarty->assign('order', $order);
$smarty->assign('goods_list', $goods_list);
$smarty->assign('lang', $_LANG);
$smarty->assign('footer', get_footer());
$smarty->display('order_info.dwt');
exit;
} elseif ($act == 'cancel_order') {
开发者ID:nanhuacrab,项目名称:ecshop,代码行数:31,代码来源:user.php
注:本文中的get_shipping_object函数示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论