Commit d49fc02c authored by wwccw0591's avatar wwccw0591

pc

parent ce51d921
......@@ -463,6 +463,7 @@ class OrderServiceModel extends \Business\AbstractModel
public function getQmDeliveryLogList($memberId, $type = ApiConst::orderTypeBuy, $pageIndex = ApiConst::pageIndex, $pageSize = ApiConst::pageSize)
{
$QmDeliveryLogDao = \DAO\Order\QmDeliverymanLogModel::getInstance(DbNameConst::salveDBConnectName);
$orderDao = \DAO\Order\OrderModel::getInstance(DbNameConst::salveDBConnectName);
$orderGoodsDao = \DAO\Order\OrderGoodsModel::getInstance(DbNameConst::salveDBConnectName);
$orderCommonDao = \DAO\Order\OrderCommonModel::getInstance(DbNameConst::salveDBConnectName);
......@@ -471,6 +472,7 @@ class OrderServiceModel extends \Business\AbstractModel
if (empty($diliverymanId)) {
ErrorModel::throwException(CodeConfigModel::commonError);
}
$qmDeliveryLogList = $QmDeliveryLogDao->getListByDeliverymanIdAndTypeCache($diliverymanId, $type, $pageIndex, $pageSize);
$orderIds = array_column($qmDeliveryLogList['list'], 'orderId');
$where['delete_state'] = ApiConst::undeleteOrder;
......@@ -483,6 +485,7 @@ class OrderServiceModel extends \Business\AbstractModel
$goodsDao=\DAO\GoodsModel::getInstance();
$orderIds = array_column($orders['list'], 'orderId');
$orderCommons = $orderCommonDao->getAllByOrderIdsCache($orderIds, $diliverymanId, $orderCommonDao->orderCommonField);
//获得订单商品列表
if (!empty($orderIds)) {
$orderGoods = \Our\RedisHelper::cachedFunction(\Redis\Db5\OrderRedisModel::getInstance(), array(&$orderGoodsDao, 'getOrderGoodsByOrderIds'), array($orderIds, $this->orderGoodsField), \Our\ApiConst::oneDaySecond, array($memberId));
......
......@@ -29,7 +29,7 @@ class OrderCommonModel extends \DAO\AbstractModel
* @var string
*/
protected $_primaryKey = 'order_id';
public $orderCommonField = " reciver_name as reciverName,reciver_info as reciverInfo,daddress_id as daddressId,order_message as orderMessage,shipping_time as shippingTime";
public $orderCommonField = "order_id as orderId, reciver_name as reciverName,reciver_info as reciverInfo,daddress_id as daddressId,order_message as orderMessage,shipping_time as shippingTime";
public function init()
{
//$this->setDb();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment