Commit ea3afd4e authored by liuyuzhen's avatar liuyuzhen

购物车编辑问题

parent 89e31c7b
......@@ -91,6 +91,10 @@ class CartServiceModel extends \Business\AbstractModel{
if(!$result){
\Error\ErrorModel::throwException(\Error\CodeConfigModel::editDelCartFailed);
}
$updateResult = $cartDao->update(array('gmt_update'=>TIMESTAMP),array('goods_id'=>$cart['goods_id'],'buyer_id'=>$memberId));
if(!$updateResult){
\Error\ErrorModel::throwException(\Error\CodeConfigModel::editCartUploadCartFailed);
}
$memberStoreCartsKey = \Our\NameConst::memberStoreCartsPrefix.$memberId.\Our\NameConst::underline.$cart['store_id'];
$cartRedis->tableDel($memberStoreCartsKey);
return $result;
......
......@@ -164,6 +164,7 @@ class CodeConfigModel {
const pBundlingOfflineForOrder = 50039;
const pBundlingNoStorageForOrder = 50040;
const editDelCartFailed = 50041;
const editCartUploadCartFailed = 50042;
//订单相关错误码
......@@ -555,6 +556,7 @@ class CodeConfigModel {
self::pBundlingOfflineForOrder => '组合销售商品已经下架',
self::pBundlingNoStorageForOrder => '组合销售商品库存不足',
self::editDelCartFailed => '编辑购物车时删除数据失败',
self::editCartUploadCartFailed => '编辑购物车更新购物车时间失败',
self::addressNotExist=>'地址不存在',
self::emptyAddressId=>'地址主键参数不能为空',
......
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