Authored by liangxs

php测试数据

... ... @@ -457,11 +457,13 @@ class HomeController extends AbstractAction
$uid = $this->_uid;
$address = UserModel::getAddressData($uid);
//以下为测试数据
$address['hasRelataions'] = 'true';
$this->_view->display('address_modify', array(
'addressModifyPage' => true,
'pageFooter' => true,
'address' => $address,
'changeable' => true,
'showAddBtn' => (count($address) <= 5),
));
}
... ... @@ -1055,6 +1057,22 @@ class HomeController extends AbstractAction
$this->setTitle('订单详情');
$this->setNavHeader('订单详情', true, false);
//以下是添加的测试数据
$orderDetail['hasChanged'] = 'false';
//以下是判断能否修改地址
if ($orderDetail['orderStatus'] === '待付款' || $orderDetail['orderStatus'] === '备货中' ) {
if ($orderDetail['hasChanged'] === 'false') {
$changeable = 'true';
}else{
$changeable = 'false';
}
}else{
$changeable = 'false';
}
$orderDetail['changeable'] = $changeable;
$this->_view->display('order-detail', array(
'orderDetailPage' => true,
'serviceUrl' => 'http://chat8.live800.com/live800/chatClient/chatbox.jsp?companyID=620092&configID=149091&jid=8732423409&info=',
... ... @@ -1064,9 +1082,7 @@ class HomeController extends AbstractAction
'orderTotalFormat' => isset($orderDetail['goodsAmount']) ? sprintf("%d", $orderDetail['goodsAmount']) : 0,
'orderCount' => isset($orderDetail['orderCount']) ? intval($orderDetail['orderCount']) : 0,
'isOldUser' => (isset($_COOKIE['_isOldUser']) && $_COOKIE['_isOldUser'] == '4') ? 'true' : 'false',
'uid' => $this->_uid,
'changeable' => true
'uid' => $this->_uid
));
}
... ...