Commit 1499bf76 authored by wwccw0591's avatar wwccw0591

temp

parents f7cebc13 a8b38774
...@@ -959,7 +959,7 @@ class OrderConfirmUtil { ...@@ -959,7 +959,7 @@ class OrderConfirmUtil {
$memberId = $orderList[0]['buyer_id']; $memberId = $orderList[0]['buyer_id'];
$updateOrder = array(); $updateOrder = array();
$updateOrder['order_state'] = \Our\ApiConst::orderStateWaitConfirm; $updateOrder['order_state'] = \Our\ApiConst::orderStateWaitConfirm;
$updateOrder['is_receive_payment'] = \Our\ApiConst::one; $updateOrder['is_receive_payment'] = TIMESTAMP;
$updateOrder['payment_time'] = (isset($data['payment_time'])? strtotime($data['payment_time']) : TIMESTAMP); $updateOrder['payment_time'] = (isset($data['payment_time'])? strtotime($data['payment_time']) : TIMESTAMP);
$updateOrder['payment_type'] = $this->getOrderPaymentType($data['pay_type']); $updateOrder['payment_type'] = $this->getOrderPaymentType($data['pay_type']);
$orderUpdateResult = $orderModel->update($orderCon,$updateOrder); $orderUpdateResult = $orderModel->update($orderCon,$updateOrder);
......
...@@ -424,4 +424,6 @@ class ApiConst ...@@ -424,4 +424,6 @@ class ApiConst
const memberAvatarType = 5; const memberAvatarType = 5;
const arriveTimeRadius=1800;
} }
\ No newline at end of file
...@@ -268,14 +268,14 @@ class ShopkeeperServiceModel extends \Business\AbstractModel ...@@ -268,14 +268,14 @@ class ShopkeeperServiceModel extends \Business\AbstractModel
return $data; return $data;
} }
public function getRetrunDatas($storeId, $where, $pageIndex, $pageSize) public function getRetrunDatas($storeId, $where, $pageIndex, $pageSize,$order = array('gmt_update' => 'desc'))
{ {
$orderGoodsDao = \DAO\Order\OrderGoodsModel::getInstance(); $orderGoodsDao = \DAO\Order\OrderGoodsModel::getInstance();
$orderDao = \DAO\Order\OrderModel::getInstance(); $orderDao = \DAO\Order\OrderModel::getInstance();
$goodsDao = \DAO\GoodsModel::getInstance(); $goodsDao = \DAO\GoodsModel::getInstance();
$orderCommonDao = \DAO\Order\OrderCommonModel::getInstance(); $orderCommonDao = \DAO\Order\OrderCommonModel::getInstance();
$returnData = \Our\RedisHelper::cachedFunction(\Redis\Db5\OrderRedisModel::getInstance(), array(&$orderDao, 'getList'), array($where, $orderDao->getOrderDetailField(), $pageIndex, $pageSize, $order = array('gmt_update' => 'desc')), \Our\ApiConst::oneDaySecond, array($storeId)); $returnData = \Our\RedisHelper::cachedFunction(\Redis\Db5\OrderRedisModel::getInstance(), array(&$orderDao, 'getList'), array($where, $orderDao->getOrderDetailField(), $pageIndex, $pageSize, $order, \Our\ApiConst::oneDaySecond, array($storeId)));
//$returnData = $orderDao->getOrders($where, $this->orderListField, $pageIndex, $pageSize); //$returnData = $orderDao->getOrders($where, $this->orderListField, $pageIndex, $pageSize);
$orders = $returnData['list']; $orders = $returnData['list'];
if (!empty($orders)) { if (!empty($orders)) {
...@@ -306,6 +306,7 @@ class ShopkeeperServiceModel extends \Business\AbstractModel ...@@ -306,6 +306,7 @@ class ShopkeeperServiceModel extends \Business\AbstractModel
$value['orderAmount'] = $value['orderAmount'] + $value['couponAmount']; $value['orderAmount'] = $value['orderAmount'] + $value['couponAmount'];
$value['reciverInfo'] = unserialize($value['reciverInfo']); $value['reciverInfo'] = unserialize($value['reciverInfo']);
$value['dlyoPickupCode'] = intval(substr($value['orderSn'], ApiConst::positionPickupCodeBegin)); $value['dlyoPickupCode'] = intval(substr($value['orderSn'], ApiConst::positionPickupCodeBegin));
$value['shippingArrivalTimeEnd'] = $value['shippingArrivalTime'] + ApiConst::arriveTimeRadius;
if ($value['diliverymanId']) { if ($value['diliverymanId']) {
$diliverymanDao = DiliverymanModel::getInstance(); $diliverymanDao = DiliverymanModel::getInstance();
$res = \Our\RedisHelper::cachedFunction(\Redis\Db5\OrderRedisModel::getInstance(), array(&$diliverymanDao, 'findById'), array($value['diliverymanId']), \Our\ApiConst::oneDaySecond, array($value['diliverymanId'])); $res = \Our\RedisHelper::cachedFunction(\Redis\Db5\OrderRedisModel::getInstance(), array(&$diliverymanDao, 'findById'), array($value['diliverymanId']), \Our\ApiConst::oneDaySecond, array($value['diliverymanId']));
...@@ -362,6 +363,7 @@ class ShopkeeperServiceModel extends \Business\AbstractModel ...@@ -362,6 +363,7 @@ class ShopkeeperServiceModel extends \Business\AbstractModel
public function getOrders($memberId, $pageIndex, $pageSize, $orderState, $keyword) public function getOrders($memberId, $pageIndex, $pageSize, $orderState, $keyword)
{ {
$order = array('gmt_update' => 'desc');
$storeId = $this->_getStoreByMemberId($memberId); $storeId = $this->_getStoreByMemberId($memberId);
if (empty($storeId)) { if (empty($storeId)) {
ErrorModel::throwException(CodeConfigModel::paramsError); ErrorModel::throwException(CodeConfigModel::paramsError);
...@@ -382,6 +384,10 @@ class ShopkeeperServiceModel extends \Business\AbstractModel ...@@ -382,6 +384,10 @@ class ShopkeeperServiceModel extends \Business\AbstractModel
if ($orderState == ApiConst::oneHandred) { if ($orderState == ApiConst::oneHandred) {
$where .= ' and han_order.shipping_type=' . ApiConst::bySelf; $where .= ' and han_order.shipping_type=' . ApiConst::bySelf;
} else { } else {
$order=array(
'diliveryman_id'=>'asc',
'gmt_update'=>'asc'
);
$where .= ' and han_order.shipping_type=' . ApiConst::bySeller; $where .= ' and han_order.shipping_type=' . ApiConst::bySeller;
} }
...@@ -393,7 +399,7 @@ class ShopkeeperServiceModel extends \Business\AbstractModel ...@@ -393,7 +399,7 @@ class ShopkeeperServiceModel extends \Business\AbstractModel
} }
if (!empty($where)) { if (!empty($where)) {
$returnData = $this->getRetrunDatas($storeId, $where, $pageIndex, $pageSize); $returnData = $this->getRetrunDatas($storeId, $where, $pageIndex, $pageSize,$order);
} else { } else {
$returnData = new \stdClass(); $returnData = new \stdClass();
} }
...@@ -416,6 +422,23 @@ class ShopkeeperServiceModel extends \Business\AbstractModel ...@@ -416,6 +422,23 @@ class ShopkeeperServiceModel extends \Business\AbstractModel
return \Our\RedisHelper::cachedFunction(\Redis\Db5\OrderRedisModel::getInstance(), array(&$diliveryMan, 'getDeliveryManByStoreId'), array($storeId), \Our\ApiConst::oneHourCache, array($storeId)); return \Our\RedisHelper::cachedFunction(\Redis\Db5\OrderRedisModel::getInstance(), array(&$diliveryMan, 'getDeliveryManByStoreId'), array($storeId), \Our\ApiConst::oneHourCache, array($storeId));
} }
public function confirmReceivePayment($memberId,$orderId){
$memberDao = \DAO\MemberModel::getInstance();
$storeId = $memberDao->getInfo($memberId, 'store_id');
$orderDao=\DAO\Order\OrderModel::getInstance(DbNameConst::masterDBConnectName);
$where['order_id']=$orderId;
$where['store_id']=$storeId;
$count=$orderDao->getCountByWhere($where);
if($count){
$data['is_receive_payment']=TIMESTAMP;
$updateId=$orderDao->updateByOrderId($data,$orderId);
return $updateId;
}else{
ErrorModel::throwException(CodeConfigModel::notExsitOrder);
}
}
/** /**
* 订单详情 * 订单详情
*/ */
...@@ -467,6 +490,7 @@ class ShopkeeperServiceModel extends \Business\AbstractModel ...@@ -467,6 +490,7 @@ class ShopkeeperServiceModel extends \Business\AbstractModel
$returnData['receiveAmount'] = $returnData['goodsAmount'] - $returnData['couponAmount']; $returnData['receiveAmount'] = $returnData['goodsAmount'] - $returnData['couponAmount'];
$returnData['orderAmount'] = $returnData['orderAmount'] + $returnData['couponAmount']; $returnData['orderAmount'] = $returnData['orderAmount'] + $returnData['couponAmount'];
$returnData['dlyoPickupCode'] = intval(substr($returnData['orderSn'], ApiConst::positionPickupCodeBegin)); $returnData['dlyoPickupCode'] = intval(substr($returnData['orderSn'], ApiConst::positionPickupCodeBegin));
$returnData['shippingArrivalTimeEnd'] = $returnData['shippingArrivalTime'] + ApiConst::arriveTimeRadius;
} else { } else {
unset($returnData['reciverInfo']); unset($returnData['reciverInfo']);
} }
...@@ -846,28 +870,72 @@ class ShopkeeperServiceModel extends \Business\AbstractModel ...@@ -846,28 +870,72 @@ class ShopkeeperServiceModel extends \Business\AbstractModel
} }
public function getSellerCount($memberId)
{
$memberDao = \DAO\MemberModel::getInstance();
$storeId = $memberDao->getInfo($memberId, 'store_id');
$orderDao = \DAO\Order\OrderModel::getInstance(DbNameConst::salveDBConnectName);
$waitReceiveCount = $orderDao->getCountByOrderState($storeId, ApiConst::orderStateWaitConfirm);
$waitDeliveryCount = $orderDao->getCountByShippingTypeAndOrderState($storeId, ApiConst::bySeller, ApiConst::orderStateWaitRecieve);
$waitGetCount = $orderDao->getCountByShippingTypeAndOrderState($storeId, ApiConst::bySelf, ApiConst::orderStateWaitRecieve);
$orderCount=$waitReceiveCount+$waitDeliveryCount+$waitGetCount;
return array('waitReceiveCount' => $waitReceiveCount, 'waitDeliveryCount' => $waitDeliveryCount, 'waitGetCount' => $waitGetCount,'orderCount'=>$orderCount);
}
public function getSellerRefundCount($memberId)
{
$memberDao = \DAO\MemberModel::getInstance();
$storeId = $memberDao->getInfo($memberId, 'store_id');
$refundReturnDao = \DAO\Order\RefundReturnModel::getInstance(DbNameConst::salveDBConnectName);
//待处理
$waitRefundProccessCount = $refundReturnDao->getCountByRefundState($storeId, ApiConst::orderStateWaitConfirm);
$waitRefundReceiveCount = $refundReturnDao->getCountByRefundType($storeId, ApiConst::refundTypeGoods);
$refundCount=$waitRefundProccessCount+$waitRefundReceiveCount;
return array('waitRefundProccessCount' => $waitRefundProccessCount, 'waitRefundReceiveCount' => $waitRefundReceiveCount, 'refundCount' =>$refundCount);
}
public function getStorageAlarmCount($memberId)
{
$memberDao = \DAO\MemberModel::getInstance();
$storeId = $memberDao->getInfo($memberId, 'store_id');
$goodsDao=\DAO\GoodsModel::getInstance();
$alertCount=$goodsDao->getAlertCountByStoreId($storeId);
return array('alertCount'=>$alertCount);
}
public function getCount($memberId){
$orderCount=$this->getSellerCount($memberId);
$refundCount=$this->getSellerRefundCount($memberId);
$alertCount=$this->getStorageAlarmCount($memberId);
$res=array_merge($orderCount,$refundCount,$alertCount);
return $res;
}
public function getDiliveryMan($mobile){
$memberDao = \DAO\MemberModel::getInstance();
$member= $memberDao->getByMemberMobile($mobile);
return $member;
/** }
/**
* 登录业务 * 登录业务
* *
* @var \Business\User\LoginV2Model * @var \Business\User\LoginV2Model
*/ */
private private
static $_instance = null; static $_instance = null;
/** /**
* 单例模式获取类实例 * 单例模式获取类实例
* *
* @return \Business\User\LoginV2Model * @return \Business\User\LoginV2Model
*/ */
public public
static function getInstance() static function getInstance()
{ {
if (!(self::$_instance instanceof self)) { if (!(self::$_instance instanceof self)) {
self::$_instance = new self(); self::$_instance = new self();
} }
return self::$_instance; return self::$_instance;
} }
} }
...@@ -57,7 +57,14 @@ abstract class AbstractModel { ...@@ -57,7 +57,14 @@ abstract class AbstractModel {
return $result; return $result;
} }
public function getCountByWhere($where){
$this->setDb($this->dbName);
if(is_array($where)){
$where=$this->db->getSqlWhereByArray($where);
}
$count=$this->db->from($this->_tableName)->where($where)->fetchNum();
return $count;
}
public function lists($where=array(),$order='',$field='*',$pageIndex=0,$pageSize=20,$group = null){ public function lists($where=array(),$order='',$field='*',$pageIndex=0,$pageSize=20,$group = null){
$this->db->from($this->_tableName); $this->db->from($this->_tableName);
$this->db->where($where); $this->db->where($where);
......
...@@ -453,4 +453,12 @@ class GoodsModel extends \DAO\AbstractModel { ...@@ -453,4 +453,12 @@ class GoodsModel extends \DAO\AbstractModel {
return $goodses; return $goodses;
} }
public function getAlertCountByStoreId($storeId){
$where=Common::format(" store_id={0}",$storeId);
$where.=" and goods_storage<goods_storage_alarm";
$alertCount=$this->getCountByWhere($where);
return $alertCount;
}
} }
...@@ -345,7 +345,12 @@ class MemberModel extends \DAO\AbstractModel ...@@ -345,7 +345,12 @@ class MemberModel extends \DAO\AbstractModel
} }
return true; return true;
} }
public function getByMemberMobile($mobile){
$this->setDb($this->dbName);
$where['member_mobile'] = $mobile;
$result=$this->getOneByWhereWithField($where,"member_id as memberId,member_name as memberName,member_mobile as memberMobile");
return $result;
}
public function validRegisterInfo($where) public function validRegisterInfo($where)
{ {
if (!\Our\Common::checkMobilePhone($where['mobile'])) { if (!\Our\Common::checkMobilePhone($where['mobile'])) {
......
...@@ -39,21 +39,6 @@ class DiliverymanModel extends \DAO\AbstractModel ...@@ -39,21 +39,6 @@ class DiliverymanModel extends \DAO\AbstractModel
} }
public function getCount($where, $isArray = true)
{
$this->setDb();
if (!$isArray) {
$str = '$count = $this->db->from($this->_tableName)';
foreach ($where as $v) {
$str .= "->where('$v')";
}
$str .= "->fetchNum();";
eval($str);
return $count;
}
return $this->db->from($this->_tableName)->where($where)->fetchNum();
}
/** /**
* 获取单条数据 * 获取单条数据
* @param $where * @param $where
...@@ -80,6 +65,12 @@ class DiliverymanModel extends \DAO\AbstractModel ...@@ -80,6 +65,12 @@ class DiliverymanModel extends \DAO\AbstractModel
$where[$this->_primaryKey] = $id; $where[$this->_primaryKey] = $id;
return $this->find($where); return $this->find($where);
} }
public function getByMobile($mobile){
$this->setDb($this->dbName);
$where['mobile'] = $mobile;
$result=$this->find($where);
return $result;
}
public function getDeliveryManFields() public function getDeliveryManFields()
{ {
return array( return array(
......
...@@ -45,7 +45,7 @@ class OrderModel extends \DAO\AbstractModel ...@@ -45,7 +45,7 @@ class OrderModel extends \DAO\AbstractModel
public function getOrderDetailField() public function getOrderDetailField()
{ {
return 'order_id as orderId,coupon_id as couponId,refund_amount as refundAmount,order_sn as orderSn,pay_sn as paySn,store_name as storeName,add_time as addTime,store_id as storeId,goods_amount as goodsAmount,shipping_fee as shippingFee,order_amount as orderAmount,shipping_type as shippingType,payment_type as paymentType,order_state as orderState,shipping_fee as shippingFee,refund_state as refundState,order_type as orderType,is_receive_payment as isReceivePayment,payment_time as paymentTime,finnshed_time as finnshedTime,need_shipping_fee as needShippingFee,payment_code as paymentCode,buyer_id as buyerId,buyer_name as buyerName,refund_condition as refundCondition,delay_time as delayTime,gmt_update as gmtUpdate,diliveryman_id as diliverymanId'; return 'order_id as orderId,coupon_id as couponId,refund_amount as refundAmount,order_sn as orderSn,pay_sn as paySn,store_name as storeName,add_time as addTime,store_id as storeId,goods_amount as goodsAmount,shipping_fee as shippingFee,order_amount as orderAmount,shipping_type as shippingType,payment_type as paymentType,order_state as orderState,shipping_fee as shippingFee,refund_state as refundState,order_type as orderType,is_receive_payment as isReceivePayment,payment_time as paymentTime,finnshed_time as finnshedTime,need_shipping_fee as needShippingFee,payment_code as paymentCode,buyer_id as buyerId,buyer_name as buyerName,refund_condition as refundCondition,delay_time as delayTime,gmt_update as gmtUpdate,diliveryman_id as diliverymanId,shipping_arrival_time as shippingArrivalTime';
} }
public function getOrderShippingField() public function getOrderShippingField()
...@@ -233,6 +233,11 @@ class OrderModel extends \DAO\AbstractModel ...@@ -233,6 +233,11 @@ class OrderModel extends \DAO\AbstractModel
return $this->db->update($this->_tableName)->where($where)->rows($data)->execute(); return $this->db->update($this->_tableName)->where($where)->rows($data)->execute();
} }
public function updateByOrderId($data,$orderId){
$where['order_id']=$orderId;
$res=$this->update($where,$data);
return $res;
}
public function insert($data) public function insert($data)
{ {
$this->setDb(\Our\DbNameConst::masterDBConnectName); $this->setDb(\Our\DbNameConst::masterDBConnectName);
...@@ -1083,4 +1088,24 @@ class OrderModel extends \DAO\AbstractModel ...@@ -1083,4 +1088,24 @@ class OrderModel extends \DAO\AbstractModel
return self::$_instance; return self::$_instance;
} }
/**
* pcClient 获得订单数量
*/
public function getCountByOrderState($storeId,$orderState){
$where['store_id']=$storeId;
$where['order_state']=$orderState;
$count=$this->getCountByWhere($where);
return $count;
}
public function getCountByShippingTypeAndOrderState($storeId,$shippingType,$orderState){
$where['store_id']=$storeId;
$where['shipping_type']=$shippingType;
$where['order_state']=$orderState;
$count=$this->getCountByWhere($where);
return $count;
}
} }
...@@ -474,4 +474,28 @@ class RefundReturnModel extends \DAO\AbstractModel { ...@@ -474,4 +474,28 @@ class RefundReturnModel extends \DAO\AbstractModel {
return self::$_instance; return self::$_instance;
} }
/**
* @param $storeId
* @param $orderState
* @return mixed 待处理
*/
public function getCountByRefundState($storeId,$refundState){
$where['store_id']=$storeId;
$where['refund_state']=$refundState;
$count=$this->getCountByWhere($where);
return $count;
}
/**
* @param $storeId
* @param $orderState
* @return mixed 待收货
*/
public function getCountByRefundType($storeId,$refundType){
$where['store_id']=$storeId;
$where['refund_type']=$refundType;
$where['goods_state']=array('neq',ApiConst::four);
$count=$this->getCountByWhere($where);
return $count;
}
} }
...@@ -5,14 +5,15 @@ namespace Error; ...@@ -5,14 +5,15 @@ namespace Error;
/** /**
* 错误码设置类 * 错误码设置类
*/ */
class CodeConfigModel { class CodeConfigModel
{
//通用错误 //通用错误
const commonError=-1; const commonError = -1;
const paramsError=-2; const paramsError = -2;
//用户登录错误 //用户登录错误
const emptyUsername=10001; const emptyUsername = 10001;
const emptyPassword=10002; const emptyPassword = 10002;
const errorUsernameOrPassword=10003; const errorUsernameOrPassword = 10003;
const noLogin = 10005; const noLogin = 10005;
const memberNameLengthLimit = 10004; const memberNameLengthLimit = 10004;
...@@ -59,7 +60,7 @@ class CodeConfigModel { ...@@ -59,7 +60,7 @@ class CodeConfigModel {
const emptyMobile = 10046; const emptyMobile = 10046;
const sameWithOldMobile = 10047; const sameWithOldMobile = 10047;
const changeMobileFailed = 10048; const changeMobileFailed = 10048;
const wrongTelnumber=10049; const wrongTelnumber = 10049;
const memberBirthdayError = 10050; const memberBirthdayError = 10050;
const wxUserInfoAuthError = 10051; const wxUserInfoAuthError = 10051;
const emptyWxUserInfoAuth = 10052; const emptyWxUserInfoAuth = 10052;
...@@ -82,14 +83,14 @@ class CodeConfigModel { ...@@ -82,14 +83,14 @@ class CodeConfigModel {
const emptyEncryptedDataAndVi = 10069; const emptyEncryptedDataAndVi = 10069;
const getUnionidFailed = 10070; const getUnionidFailed = 10070;
const saveMemberMapppingFailed = 10071; const saveMemberMapppingFailed = 10071;
const emptyWxSetting=10072; const emptyWxSetting = 10072;
const getWxAccessTokenFail=10073; const getWxAccessTokenFail = 10073;
const wrongMappingDataForBindMembmer = 10074; const wrongMappingDataForBindMembmer = 10074;
const otherMemberOpenIdBindForMember = 10075; const otherMemberOpenIdBindForMember = 10075;
const updateMobileMembmerFailed = 10076; const updateMobileMembmerFailed = 10076;
const updateMobileMembmerMappingFailed = 10077; const updateMobileMembmerMappingFailed = 10077;
const currentMobileHasBeenBind = 10078; const currentMobileHasBeenBind = 10078;
const otherDriverLogin=10105; const otherDriverLogin = 10105;
const emptyLog = 10106; const emptyLog = 10106;
const writeLogFailed = 10107; const writeLogFailed = 10107;
const wrongTimeForReadLog = 10108; const wrongTimeForReadLog = 10108;
...@@ -101,17 +102,17 @@ class CodeConfigModel { ...@@ -101,17 +102,17 @@ class CodeConfigModel {
const unavailMemberState = 10114; const unavailMemberState = 10114;
//访问错误 //访问错误
const illegalAccess=200001; const illegalAccess = 200001;
const maxGetAccess=200002; const maxGetAccess = 200002;
const isLogin=200003; const isLogin = 200003;
const signWrong=200004; const signWrong = 200004;
const authError=200005; const authError = 200005;
const authExpire=200006; const authExpire = 200006;
//商品 //商品
const emptyCommonId=20001; const emptyCommonId = 20001;
const goodsNotExist=20002; const goodsNotExist = 20002;
const groupNotExist=20003; const groupNotExist = 20003;
//店铺相关错误代码 //店铺相关错误代码
...@@ -123,7 +124,7 @@ class CodeConfigModel { ...@@ -123,7 +124,7 @@ class CodeConfigModel {
const storeNotExistOrClose = 40006; const storeNotExistOrClose = 40006;
const emptyStoreId = 40007; const emptyStoreId = 40007;
const saveReportError = 40008; const saveReportError = 40008;
const stroeReceiveError=40009; const stroeReceiveError = 40009;
//购物车 //购物车
const wrongCartType = 50001; const wrongCartType = 50001;
...@@ -162,7 +163,7 @@ class CodeConfigModel { ...@@ -162,7 +163,7 @@ class CodeConfigModel {
const wrongBundlingForBuyNow = 50034; const wrongBundlingForBuyNow = 50034;
const wrongGoodsForBuyNow = 50035; const wrongGoodsForBuyNow = 50035;
const offlineGoodsListOrNotExist = 50036; const offlineGoodsListOrNotExist = 50036;
const goodsListNoStorage =50037; const goodsListNoStorage = 50037;
const emptyPBundlingdForOrder = 50038; const emptyPBundlingdForOrder = 50038;
const pBundlingOfflineForOrder = 50039; const pBundlingOfflineForOrder = 50039;
const pBundlingNoStorageForOrder = 50040; const pBundlingNoStorageForOrder = 50040;
...@@ -176,42 +177,42 @@ class CodeConfigModel { ...@@ -176,42 +177,42 @@ class CodeConfigModel {
const orderNotExist = 30001; const orderNotExist = 30001;
const orderError = 30002; const orderError = 30002;
const refundRefuseByStore = 30003; const refundRefuseByStore = 30003;
const emptyDescCredit=30012; const emptyDescCredit = 30012;
const emptyDeliveryCredit=30013; const emptyDeliveryCredit = 30013;
const emptyServiceCredit=30014; const emptyServiceCredit = 30014;
const emptyScores=30016; const emptyScores = 30016;
const emptyGoodsId=30017; const emptyGoodsId = 30017;
const notAllowCancel=30019; const notAllowCancel = 30019;
const notAllowComplete=30020; const notAllowComplete = 30020;
const refundSuccess=30021; const refundSuccess = 30021;
const returnErrorAfterPay=30022; const returnErrorAfterPay = 30022;
const returnBeyondTimeError=30023; const returnBeyondTimeError = 30023;
const applyError=30024; const applyError = 30024;
const notReturnAgree=30025; const notReturnAgree = 30025;
const isNotReturn=30026; const isNotReturn = 30026;
const isNotExpressType=30027; const isNotExpressType = 30027;
const notExistRefund=30028; const notExistRefund = 30028;
const sendRefundShippingFail=30029; const sendRefundShippingFail = 30029;
const alreadySendRefundShipping=30030; const alreadySendRefundShipping = 30030;
const buyerCancelError=30031; const buyerCancelError = 30031;
const refundCancelError=30032; const refundCancelError = 30032;
const storeCancelError=30033; const storeCancelError = 30033;
const systemCancelError=30034; const systemCancelError = 30034;
const systemReceivePayError=30035; const systemReceivePayError = 30035;
const complainError=30036; const complainError = 30036;
const paymentError=30037; const paymentError = 30037;
const modifyPriceError=30038; const modifyPriceError = 30038;
const spayPriceError=30039; const spayPriceError = 30039;
const sendError=30040; const sendError = 30040;
const receiveError=30041; const receiveError = 30041;
const evaluationError=30042; const evaluationError = 30042;
const lockError=30043; const lockError = 30043;
const deliverError=30044; const deliverError = 30044;
const deleteError=30045; const deleteError = 30045;
const restoreError=30046; const restoreError = 30046;
const shareError=30047; const shareError = 30047;
const orderDeleteError=30048; const orderDeleteError = 30048;
const noAddressForOrder = 30049; const noAddressForOrder = 30049;
const emptyCartIdsForOrder = 30050; const emptyCartIdsForOrder = 30050;
const emptyParamForOrder = 30051; const emptyParamForOrder = 30051;
...@@ -273,16 +274,17 @@ class CodeConfigModel { ...@@ -273,16 +274,17 @@ class CodeConfigModel {
const goodsStorageToDBFailedForOrder = 30107; const goodsStorageToDBFailedForOrder = 30107;
const blGoodsStorageToCacheFailedForOrder = 30108; const blGoodsStorageToCacheFailedForOrder = 30108;
const goodsStorageToCacheFailedForOrder = 30109; const goodsStorageToCacheFailedForOrder = 30109;
const notExistOrderGoods=300110; const notExistOrderGoods = 300110;
const notExsitDeliver=300111; const notExsitDeliver = 300111;
const notExsitOrder=300112; const notExsitOrder = 300112;
const alreadyExsitRefundGoods=300113; const alreadyExsitRefundGoods = 300113;
const notAllowDelete=300114; const notAllowDelete = 300114;
const noExpressDeliveryForOrder1 = 30115; const noExpressDeliveryForOrder1 = 30115;
const goodsNoStoreForCartOrOrder1 = 30116; const goodsNoStoreForCartOrOrder1 = 30116;
const platFormAreadyIn=300117; const platFormAreadyIn = 300117;
const confirmReceiveError = 300118;
const alreadyExsitDeliveryMan = 300119;
const noEnoughStorageForBundlingGoods = 30118; const noEnoughStorageForBundlingGoods = 30118;
const noOrderWaitToPay = 30119; const noOrderWaitToPay = 30119;
const wrongEvaluation = 30120; const wrongEvaluation = 30120;
...@@ -320,7 +322,7 @@ class CodeConfigModel { ...@@ -320,7 +322,7 @@ class CodeConfigModel {
const codeIsSixNumberString = 90015; const codeIsSixNumberString = 90015;
const codeIsSixNumberString1 = 90016; const codeIsSixNumberString1 = 90016;
const setMessageFail=90017; const setMessageFail = 90017;
//销售员 //销售员
const emptySaleGoodsId = 100001; const emptySaleGoodsId = 100001;
const emptySaleGoods = 100002; const emptySaleGoods = 100002;
...@@ -376,16 +378,16 @@ class CodeConfigModel { ...@@ -376,16 +378,16 @@ class CodeConfigModel {
const wrongCityCode = 140023; const wrongCityCode = 140023;
//消息,推送等 //消息,推送等
const removeMessage=150001; const removeMessage = 150001;
const pushConnectError=152001; const pushConnectError = 152001;
const pushIsNotOpen=152002; const pushIsNotOpen = 152002;
const sendMessageFail=152003; const sendMessageFail = 152003;
const sendLimitError=152004; const sendLimitError = 152004;
const updateReadedError=152005; const updateReadedError = 152005;
const noExistMessage=152006; const noExistMessage = 152006;
const noExistButton=152007; const noExistButton = 152007;
const isClicked=152008; const isClicked = 152008;
//广告位 //广告位
...@@ -397,46 +399,33 @@ class CodeConfigModel { ...@@ -397,46 +399,33 @@ class CodeConfigModel {
const storeEvaNotExist = 170001; const storeEvaNotExist = 170001;
const ViewTimeNotExist = 170002; const ViewTimeNotExist = 170002;
const cancleCollectionGoods = 170003; const cancleCollectionGoods = 170003;
const cancleCollectionStore= 170004; const cancleCollectionStore = 170004;
//底层异常 //底层异常
const elasticsError=900001; const elasticsError = 900001;
//分享错误码 //分享错误码
const shareGrowImageError=180001; const shareGrowImageError = 180001;
/** /**
* 获取错误码配置 * 获取错误码配置
*/ */
public static function getCodeConfig() { public static function getCodeConfig()
{
return array( return array(
self::commonError => "请求失败", self::commonError => "请求失败",
self::paramsError=>"参数有误", self::paramsError => "参数有误",
self::emptyUsername => "用户名不能为空", self::emptyUsername => "用户名不能为空",
self::emptyPassword=>"密码不能为空", self::emptyPassword => "密码不能为空",
self::errorUsernameOrPassword=>'用户名或密码错误', self::errorUsernameOrPassword => '用户名或密码错误',
self::illegalAccess=>"非法访问,还未授权,或者授权过期", self::illegalAccess => "非法访问,还未授权,或者授权过期",
self::wrongTelnumber=>"请输入正确的手机号码", self::wrongTelnumber => "请输入正确的手机号码",
self::maxGetAccess=>'今天授权次数已经用完', self::maxGetAccess => '今天授权次数已经用完',
self::isLogin=>'你已经登录', self::isLogin => '你已经登录',
self::signWrong => '签名错误', self::signWrong => '签名错误',
self::noLogin=>'您还没有登录', self::noLogin => '您还没有登录',
self::emptyMemberName => '昵称不能为空', self::emptyMemberName => '昵称不能为空',
self::memberNameLengthLimit => '昵称长度必须在1到24个字符之间', self::memberNameLengthLimit => '昵称长度必须在1到24个字符之间',
self::memberBirthdayError => '生日格式错误', self::memberBirthdayError => '生日格式错误',
...@@ -488,7 +477,7 @@ class CodeConfigModel { ...@@ -488,7 +477,7 @@ class CodeConfigModel {
self::wxAuthInfoLoginFailed => '微信授权登录失败', self::wxAuthInfoLoginFailed => '微信授权登录失败',
self::emptyOrWrongAuthUserType => '授权用户类型不能为空或者类型错误', self::emptyOrWrongAuthUserType => '授权用户类型不能为空或者类型错误',
self::registerMemberFailed => '注册账号失败', self::registerMemberFailed => '注册账号失败',
self::bindingUserNotExist=>'绑定的用户不存在', self::bindingUserNotExist => '绑定的用户不存在',
self::emptyMobileForLogin => '登录时手机号码不能为空', self::emptyMobileForLogin => '登录时手机号码不能为空',
self::memberExistBindingInfo => '您已经绑定过用户信息,如需绑定,请先解绑', self::memberExistBindingInfo => '您已经绑定过用户信息,如需绑定,请先解绑',
self::wrongMemberSex => '会员性别错误', self::wrongMemberSex => '会员性别错误',
...@@ -507,24 +496,24 @@ class CodeConfigModel { ...@@ -507,24 +496,24 @@ class CodeConfigModel {
self::uploadWxMemberAvatarFailed => '微信上传用户头像失败', self::uploadWxMemberAvatarFailed => '微信上传用户头像失败',
self::unavailMemberState => '您的账号已被禁用', self::unavailMemberState => '您的账号已被禁用',
//商品相关 //商品相关
self::emptyCommonId=> '商品主键不能为空', self::emptyCommonId => '商品主键不能为空',
self::goodsNotExist=> '商品不存在', self::goodsNotExist => '商品不存在',
self::groupNotExist=> '组合活动不存在或已下架', self::groupNotExist => '组合活动不存在或已下架',
//订单相关错误 //订单相关错误
self::orderNotExist => '订单不存在', self::orderNotExist => '订单不存在',
self::orderError => '订单信息错误', self::orderError => '订单信息错误',
self::refundRefuseByStore => '商家不同意退款,如有疑问请联系客服', self::refundRefuseByStore => '商家不同意退款,如有疑问请联系客服',
self::returnErrorAfterPay=>'货到付款订单在没确认收货前不能退款退货', self::returnErrorAfterPay => '货到付款订单在没确认收货前不能退款退货',
self::returnBeyondTimeError=>'收货超时订单不能退款', self::returnBeyondTimeError => '收货超时订单不能退款',
//店铺相关错误 //店铺相关错误
self::illegalFavStore=>'不能关注自己的店铺', self::illegalFavStore => '不能关注自己的店铺',
self::emptyStore=>'店铺不存在或者已关闭', self::emptyStore => '店铺不存在或者已关闭',
self::emptyReportStoreDesc=>'描述内容不能为空', self::emptyReportStoreDesc => '描述内容不能为空',
self::emptyReportStoreType=>'举报类型不能为空', self::emptyReportStoreType => '举报类型不能为空',
self::emptyStores => '没找到相关店铺', self::emptyStores => '没找到相关店铺',
self::stroeReceiveError=>'店铺接单错误', self::stroeReceiveError => '店铺接单错误',
//购物车相关 //购物车相关
self::wrongCartType => '加入购物车类型不能为空', self::wrongCartType => '加入购物车类型不能为空',
...@@ -556,7 +545,7 @@ class CodeConfigModel { ...@@ -556,7 +545,7 @@ class CodeConfigModel {
self::moveToFavoritesFailed => '移入收藏夹添加数据失败', self::moveToFavoritesFailed => '移入收藏夹添加数据失败',
self::moveToFavoritesDelCartFailed => '移入收藏夹删除购物车失败', self::moveToFavoritesDelCartFailed => '移入收藏夹删除购物车失败',
self::emptyCartIdsForCheckout => '购物车下单时购物车ID不能为空', self::emptyCartIdsForCheckout => '购物车下单时购物车ID不能为空',
self::storeNoDeliveryTypeForBuy =>'店铺没有设置配送方式,不能下单', self::storeNoDeliveryTypeForBuy => '店铺没有设置配送方式,不能下单',
self::storeNoPaywayForBuy => '店铺没有设置支付方式,不能下单', self::storeNoPaywayForBuy => '店铺没有设置支付方式,不能下单',
self::emptyGoodsIdOrBlIdForBuyNow => '立即购买时商品ID或者组合销售ID不能都为空', self::emptyGoodsIdOrBlIdForBuyNow => '立即购买时商品ID或者组合销售ID不能都为空',
self::emptyGoodsNumForBuyNow => '立即购买时商品ID或者组合销售ID不能都为空', self::emptyGoodsNumForBuyNow => '立即购买时商品ID或者组合销售ID不能都为空',
...@@ -572,9 +561,9 @@ class CodeConfigModel { ...@@ -572,9 +561,9 @@ class CodeConfigModel {
self::wrongAddCartForSelfStore => '店主不能添加自己店铺的商品到购物车', self::wrongAddCartForSelfStore => '店主不能添加自己店铺的商品到购物车',
self::pbundingGoodsCannotMoveToFavouites => '组合商品暂不支持移入收藏夹', self::pbundingGoodsCannotMoveToFavouites => '组合商品暂不支持移入收藏夹',
self::addressNotExist=>'地址不存在', self::addressNotExist => '地址不存在',
self::emptyAddressId=>'地址主键参数不能为空', self::emptyAddressId => '地址主键参数不能为空',
self::saveAddressFailed =>'地址保存失败', self::saveAddressFailed => '地址保存失败',
self::currLatLngNoAddress => '当前经纬度不存在收货地址', self::currLatLngNoAddress => '当前经纬度不存在收货地址',
self::emptyParamForMyAddress => '获取地址时参数不能为空', self::emptyParamForMyAddress => '获取地址时参数不能为空',
self::delAddressFailed => '地址删除失败', self::delAddressFailed => '地址删除失败',
...@@ -595,8 +584,8 @@ class CodeConfigModel { ...@@ -595,8 +584,8 @@ class CodeConfigModel {
self::wrongSmsCode => '您的验证码输入有误', self::wrongSmsCode => '您的验证码输入有误',
self::codeIsSixNumberString => '短信验证码是6位数值', self::codeIsSixNumberString => '短信验证码是6位数值',
self::codeIsSixNumberString1 => '短信验证码是61位数值', self::codeIsSixNumberString1 => '短信验证码是61位数值',
self::setMessageFail=>'消息设置失败', self::setMessageFail => '消息设置失败',
self::removeMessage=>'消息删除失败', self::removeMessage => '消息删除失败',
self::storeNotExistOrClose => '店铺不存在或者已关闭', self::storeNotExistOrClose => '店铺不存在或者已关闭',
self::emptyStoreId => '店铺ID不能为空', self::emptyStoreId => '店铺ID不能为空',
self::saveReportError => '保存举报信息失败', self::saveReportError => '保存举报信息失败',
...@@ -615,8 +604,8 @@ class CodeConfigModel { ...@@ -615,8 +604,8 @@ class CodeConfigModel {
self::emptyCityCode => '高德地图城市编码不能为空', self::emptyCityCode => '高德地图城市编码不能为空',
self::emptyGcId => '分类ID不能为空', self::emptyGcId => '分类ID不能为空',
self::emptyStoreIdForOnlineTopClass => '获取店铺一级在售分类时店铺ID不能为空', self::emptyStoreIdForOnlineTopClass => '获取店铺一级在售分类时店铺ID不能为空',
self::emptyStoreIdForOnlineChildrenClass =>'获取店铺下级分类及广告时店铺ID不能为空', self::emptyStoreIdForOnlineChildrenClass => '获取店铺下级分类及广告时店铺ID不能为空',
self::emtpyGcIdForOnlineChildrenClass =>'获取店铺下级分类及广告时分类ID不能为空', self::emtpyGcIdForOnlineChildrenClass => '获取店铺下级分类及广告时分类ID不能为空',
self::wrongGcIdForStoreIdChildrenClass => '店铺一级分类不能找到对应可售下级分类', self::wrongGcIdForStoreIdChildrenClass => '店铺一级分类不能找到对应可售下级分类',
self::folderUnwritable => '文件夹不可写', self::folderUnwritable => '文件夹不可写',
...@@ -627,31 +616,31 @@ class CodeConfigModel { ...@@ -627,31 +616,31 @@ class CodeConfigModel {
self::imageExtensionsWrong => '图片格式错误', self::imageExtensionsWrong => '图片格式错误',
self::emptyImageStr => '图片字符串不能为空', self::emptyImageStr => '图片字符串不能为空',
//推送 //推送
self::pushConnectError=>'推送连接有误', self::pushConnectError => '推送连接有误',
self::pushIsNotOpen=>'推送模块没打开,对方未能及时接收到消息!!!', self::pushIsNotOpen => '推送模块没打开,对方未能及时接收到消息!!!',
self::noExistMessage=>'消息不存在', self::noExistMessage => '消息不存在',
self::noExistButton=>'不存在此操作按钮', self::noExistButton => '不存在此操作按钮',
self::isClicked=>'此按钮已经点击过了', self::isClicked => '此按钮已经点击过了',
//订单 //订单
self::orderError=>'订单信息错误', self::orderError => '订单信息错误',
self::emptyDescCredit=>'店铺描述相符评分不能为空', self::emptyDescCredit => '店铺描述相符评分不能为空',
self::emptyDeliveryCredit=>'店铺物流服务评分不能为空', self::emptyDeliveryCredit => '店铺物流服务评分不能为空',
self::emptyServiceCredit=>'店铺物流服务评分不能为空', self::emptyServiceCredit => '店铺物流服务评分不能为空',
self::emptyScores=>'商品评分不能为空', self::emptyScores => '商品评分不能为空',
self::emptyGoodsId=>'商品id不能为空', self::emptyGoodsId => '商品id不能为空',
self::sendMessageFail=>'消息推送失败', self::sendMessageFail => '消息推送失败',
self::sendLimitError=>'每秒钟只发送一次消息谢谢!', self::sendLimitError => '每秒钟只发送一次消息谢谢!',
self::updateReadedError=>'更新消息为已读失败!', self::updateReadedError => '更新消息为已读失败!',
self::authError=>'授权参数有误', self::authError => '授权参数有误',
self::authExpire=>'授权过期', self::authExpire => '授权过期',
self::notAllowCancel=>'对不起,当前订单状态不允许取消', self::notAllowCancel => '对不起,当前订单状态不允许取消',
self::notAllowComplete=>'对不起,当前订单状态不允许确认收货', self::notAllowComplete => '对不起,当前订单状态不允许确认收货',
//优惠券 //优惠券
self::emptyCouponId=>'优惠券ID不能为空', self::emptyCouponId => '优惠券ID不能为空',
self::emptyCouponStoreId => '获取优惠券时店铺ID不能为空', self::emptyCouponStoreId => '获取优惠券时店铺ID不能为空',
self::emptyMemberCouponState => '优惠券状态不能为空', self::emptyMemberCouponState => '优惠券状态不能为空',
self::emptyMemberCouponMemberId => '获取我的优惠券时会员ID不能为空', self::emptyMemberCouponMemberId => '获取我的优惠券时会员ID不能为空',
...@@ -665,42 +654,42 @@ class CodeConfigModel { ...@@ -665,42 +654,42 @@ class CodeConfigModel {
self::emptyAdvs => '广告位内容为空', self::emptyAdvs => '广告位内容为空',
self::emptyAdvStore => '获取店铺广告位时店铺ID不能为空', self::emptyAdvStore => '获取店铺广告位时店铺ID不能为空',
self::storeEvaNotExist=>'卖家评价不存在', self::storeEvaNotExist => '卖家评价不存在',
self::refundSuccess=>'退款成功', self::refundSuccess => '退款成功',
self::ViewTimeNotExist=>'日期时间戳不能为空', self::ViewTimeNotExist => '日期时间戳不能为空',
self::cancleCollectionGoods=>'取消关注商品参数错误', self::cancleCollectionGoods => '取消关注商品参数错误',
self::cancleCollectionStore=>'取消关注店铺参数错误', self::cancleCollectionStore => '取消关注店铺参数错误',
self::applyError=>'申请平台介入失败', self::applyError => '申请平台介入失败',
self::notReturnAgree=>'卖家未同意退货', self::notReturnAgree => '卖家未同意退货',
self::isNotReturn=>'不是退货类型的订单', self::isNotReturn => '不是退货类型的订单',
self::isNotExpressType=>'退货方式不是快递', self::isNotExpressType => '退货方式不是快递',
self::notExistRefund=>'退款订单不存在', self::notExistRefund => '退款订单不存在',
self::sendRefundShippingFail=>'添加物流信息失败', self::sendRefundShippingFail => '添加物流信息失败',
self::alreadySendRefundShipping=>'退货信息已经提交', self::alreadySendRefundShipping => '退货信息已经提交',
self::buyerCancelError=>'买家取消订单失败,订单状态有误', self::buyerCancelError => '买家取消订单失败,订单状态有误',
self::refundCancelError=>'申请退款失败,订单状态有误', self::refundCancelError => '申请退款失败,订单状态有误',
self::storeCancelError=>'商家取消订单失败,订单状态有误', self::storeCancelError => '商家取消订单失败,订单状态有误',
self::systemCancelError=>'平台取消订单失败,订单状态有误', self::systemCancelError => '平台取消订单失败,订单状态有误',
self::systemReceivePayError=>'平台收款失败,订单状态有误', self::systemReceivePayError => '平台收款失败,订单状态有误',
self::complainError=>'买家投诉失败,订单状态有误', self::complainError => '买家投诉失败,订单状态有误',
self::paymentError=>'支付失败,订单状态有误', self::paymentError => '支付失败,订单状态有误',
self::modifyPriceError=>'调整运费失败,订单状态有误', self::modifyPriceError => '调整运费失败,订单状态有误',
self::spayPriceError=>'调整商品价格失败,订单状态有误', self::spayPriceError => '调整商品价格失败,订单状态有误',
self::sendError=>'发货失败,订单状态有误', self::sendError => '发货失败,订单状态有误',
self::receiveError=>'收货失败,订单状态有误', self::receiveError => '收货失败,订单状态有误',
self::evaluationError=>'评价失败,订单状态有误', self::evaluationError => '评价失败,订单状态有误',
self::lockError=>'锁定失败,订单状态有误', self::lockError => '锁定失败,订单状态有误',
self::deliverError=>'快递跟踪失败,订单状态有误', self::deliverError => '快递跟踪失败,订单状态有误',
self::notExsitDeliver=>'配送单不存在', self::notExsitDeliver => '配送单不存在',
self::notExsitOrder=>'订单不存在', self::notExsitOrder => '订单不存在',
self::alreadyExsitRefundGoods=>'退款订单已经存在', self::alreadyExsitRefundGoods => '退款订单已经存在',
self::notAllowDelete=>'当前订单状态不允许删除', self::notAllowDelete => '当前订单状态不允许删除',
self::platFormAreadyIn=>'您已经申请过平台介入', self::platFormAreadyIn => '您已经申请过平台介入',
self::deleteError=>'放入回收站失败,订单状态有误', self::deleteError => '放入回收站失败,订单状态有误',
self::restoreError=>'永久删除、从回收站还原失败,订单状态有误', self::restoreError => '永久删除、从回收站还原失败,订单状态有误',
self::shareError=>'分享失败,订单状态有误', self::shareError => '分享失败,订单状态有误',
self::orderDeleteError=>'订单删除失败', self::orderDeleteError => '订单删除失败',
self::noAddressForOrder => '下单前请选择收货地址', self::noAddressForOrder => '下单前请选择收货地址',
self::emptyCartIdsForOrder => '下单时购物车ID不能为空', self::emptyCartIdsForOrder => '下单时购物车ID不能为空',
self::emptyParamForOrder => '下单时参数不能为空', self::emptyParamForOrder => '下单时参数不能为空',
...@@ -711,6 +700,8 @@ class CodeConfigModel { ...@@ -711,6 +700,8 @@ class CodeConfigModel {
self::wrongStoreIdsForOrder => '下单时店铺参数错误', self::wrongStoreIdsForOrder => '下单时店铺参数错误',
self::wrongCartStoreForOrder => '下单时店铺购物车ID参数错误', self::wrongCartStoreForOrder => '下单时店铺购物车ID参数错误',
self::bundlingGoodsNotExist => '组合销售商品不存在', self::bundlingGoodsNotExist => '组合销售商品不存在',
self::confirmReceiveError => '确认收款失败',
self::alreadyExsitDeliveryMan=>'您的店铺已经存在此配送员',
self::noStorageForBundlingGoods => '组合销售商品库存不存在', self::noStorageForBundlingGoods => '组合销售商品库存不存在',
self::bundlingGoodsOfflineForCartOrOrder => '组合销售活动已下架', self::bundlingGoodsOfflineForCartOrOrder => '组合销售活动已下架',
self::goodsNoStoreForCartOrOrder => '商品库存不足', self::goodsNoStoreForCartOrOrder => '商品库存不足',
...@@ -765,35 +756,35 @@ class CodeConfigModel { ...@@ -765,35 +756,35 @@ class CodeConfigModel {
self::notExistOrderGoods => '退款商品不存在', self::notExistOrderGoods => '退款商品不存在',
self::noExpressDeliveryForOrder1 => '该店铺未配置快递配送', self::noExpressDeliveryForOrder1 => '该店铺未配置快递配送',
self::goodsNoStoreForCartOrOrder1 => '商品库存紧张,您的购买数量太多啦', self::goodsNoStoreForCartOrOrder1 => '商品库存紧张,您的购买数量太多啦',
self::noEnoughStorageForBundlingGoods =>'组合销售库存紧张,您购买的数量太多啦', self::noEnoughStorageForBundlingGoods => '组合销售库存紧张,您购买的数量太多啦',
self::noOrderWaitToPay => '您的订单已支付,请勿重复支付', self::noOrderWaitToPay => '您的订单已支付,请勿重复支付',
self::wrongEvaluation => '商品评论应在6-500字之间', self::wrongEvaluation => '商品评论应在6-500字之间',
self::selfGoodsForStoreOrder => '店主不能购买自己的商品', self::selfGoodsForStoreOrder => '店主不能购买自己的商品',
//销售员 //销售员
self::emptySaleGoodsId=>'商品id不能为空', self::emptySaleGoodsId => '商品id不能为空',
self::emptySaleGoods=>'销售商品不存在', self::emptySaleGoods => '销售商品不存在',
self::saleNotLogin=>'请先登录', self::saleNotLogin => '请先登录',
self::salePhoneError=>'获取验证码的手机号与用户手机号不一致', self::salePhoneError => '获取验证码的手机号与用户手机号不一致',
self::saleNotExist=>'你不是销售员', self::saleNotExist => '你不是销售员',
self::saleValidate=>'请先进行身份验证', self::saleValidate => '请先进行身份验证',
self::saleNotJoin=>'你没有参加这个销售活动', self::saleNotJoin => '你没有参加这个销售活动',
self::saleActOrGoodsNotExist=>'活动或商品不存在', self::saleActOrGoodsNotExist => '活动或商品不存在',
//意见信箱 //意见信箱
self::emptyFeedbackDescribe => '反馈内容不能为空', self::emptyFeedbackDescribe => '反馈内容不能为空',
self::emptyFeedbackTelepone => '联系方式不能为空', self::emptyFeedbackTelepone => '联系方式不能为空',
self::saveFeedbackError=>'保存意见反馈信息失败', self::saveFeedbackError => '保存意见反馈信息失败',
self::feedbackTelError=>'手机号码格式错误', self::feedbackTelError => '手机号码格式错误',
//分享 //分享
self::shareGrowImageError=>'分享图片生成有误', self::shareGrowImageError => '分享图片生成有误',
self::emptyWxSetting=>'微信小程序未配置', self::emptyWxSetting => '微信小程序未配置',
self::getWxAccessTokenFail=>'获得微信小程序token失败', self::getWxAccessTokenFail => '获得微信小程序token失败',
self::wrongMappingDataForBindMembmer => 'mapping数据错误', self::wrongMappingDataForBindMembmer => 'mapping数据错误',
self::otherMemberOpenIdBindForMember => '当前第三方账号已经绑定其他手机号码的账号', self::otherMemberOpenIdBindForMember => '当前第三方账号已经绑定其他手机号码的账号',
self::updateMobileMembmerFailed => '更新手机号对应会员信息失败', self::updateMobileMembmerFailed => '更新手机号对应会员信息失败',
self::updateMobileMembmerMappingFailed => '更新手机号码对应会员mapping信息失败', self::updateMobileMembmerMappingFailed => '更新手机号码对应会员mapping信息失败',
self::currentMobileHasBeenBind => '当前手机号码已经绑定其他微信,如需绑定,请先手机号码登录app进行微信解绑', self::currentMobileHasBeenBind => '当前手机号码已经绑定其他微信,如需绑定,请先手机号码登录app进行微信解绑',
self::otherDriverLogin=>'当前帐户在其他设备登录,假如不是您本人操作,请尽快修改密码', self::otherDriverLogin => '当前帐户在其他设备登录,假如不是您本人操作,请尽快修改密码',
self::elasticsError=>'全文索引连接出错', self::elasticsError => '全文索引连接出错',
self::emptyLog => '日志内容不能为空', self::emptyLog => '日志内容不能为空',
self::writeLogFailed => '日志写入失败', self::writeLogFailed => '日志写入失败',
self::wrongTimeForReadLog => '读日志时写入时间段查询开始时间不能大于结束时间', self::wrongTimeForReadLog => '读日志时写入时间段查询开始时间不能大于结束时间',
......
...@@ -147,9 +147,9 @@ class ShopkeeperController extends \Our\Controller_AbstractApi { ...@@ -147,9 +147,9 @@ class ShopkeeperController extends \Our\Controller_AbstractApi {
$keyword = isset($this->req['data']['keyword'])?$this->req['data']['keyword']:''; $keyword = isset($this->req['data']['keyword'])?$this->req['data']['keyword']:'';
$result = $this->shopkeeperService->getOrders($this->memberId,$pageIndex,$pageSize,$orderState,$keyword); $result = $this->shopkeeperService->getOrders($this->memberId,$pageIndex,$pageSize,$orderState,$keyword);
$this->success($result); $this->success($result);
if($result){ // if($result){
$this->success(array(),\Our\DescribeConst::successMessage,\Our\DescribeConst::successMessage); // $this->success(array(),\Our\DescribeConst::successMessage,\Our\DescribeConst::successMessage);
} // }
} }
/** /**
...@@ -196,6 +196,43 @@ class ShopkeeperController extends \Our\Controller_AbstractApi { ...@@ -196,6 +196,43 @@ class ShopkeeperController extends \Our\Controller_AbstractApi {
$goodsCommonService = \Business\Goods\GoodsCommonServiceModel::getInstance(); $goodsCommonService = \Business\Goods\GoodsCommonServiceModel::getInstance();
$pageIndex=$this->getPageIndex(); $pageIndex=$this->getPageIndex();
$pageSize=$this->getPageSize(); $pageSize=$this->getPageSize();
$res = $goodsCommonService->getGoodsStorageList($this->memberId, $pageIndex, $pageSize);
$memberDao = \DAO\MemberModel::getInstance();
$storeId = $memberDao->getInfo($this->memberId, 'store_id');
$res = $goodsCommonService->getGoodsStorageList($storeId, $pageIndex, $pageSize);
$this->success($res);
}
/**
* 获得订单数量
*/
public function countAction(){
$result = $this->shopkeeperService->getCount($this->memberId);
if(!empty($result)){
$this->success($result);
}
ErrorModel::throwException(CodeConfigModel::commonError);
}
public function receivePaymentAction(){
$shopkeeperService=\Business\Store\ShopkeeperServiceModel::getInstance();
$res=$shopkeeperService->confirmReceivePayment($this->memberId,$this->req['data']['orderId']);
if($res){
$this->success(array(),\Our\DescribeConst::successMessage);
}else{
ErrorModel::throwException(CodeConfigModel::confirmReceiveError);
}
}
/**
* 查询配送员
*
*/
public function searchDeliveryAction(){
$shopkeeperService=\Business\Store\ShopkeeperServiceModel::getInstance();
$res=$shopkeeperService->getDiliveryMan($this->req['data']['mobile']);
$res=$res?$res:new \stdClass();
$this->success($res,\Our\DescribeConst::successMessage);
} }
} }
...@@ -68,7 +68,7 @@ class UserController extends \Our\Controller_AbstractIndex { ...@@ -68,7 +68,7 @@ class UserController extends \Our\Controller_AbstractIndex {
$member['store_id']=$seller['storeId']; $member['store_id']=$seller['storeId'];
$member['seller_id']=$seller['sellerId']; $member['seller_id']=$seller['sellerId'];
$this->memberService->saveMember($member,'seller'); $this->memberService->saveMember($member,'seller');
$this->success(array('key'=>$this->key,'memberName'=>$member['member_name'],'memberAvatar'=>$member['memberAvatarUrl'],'memberId'=>(int)$member['member_id'])); $this->success(array('key'=>$this->key,'trueName'=>$seller['trueName'],'memberAvatar'=>$member['memberAvatarUrl'],'memberId'=>(int)$member['member_id'],'storeId'=>(int)$seller['storeId']));
}else{ }else{
ErrorModel::throwException(CodeConfigModel::errorUsernameOrPassword); ErrorModel::throwException(CodeConfigModel::errorUsernameOrPassword);
} }
......
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>简单的html5 File测试 for pic2base64</title>
<style>
</style>
</head>
<body>
<form action="/client/shopkeeper/count" method="post">
用户登录状态key:<input name="data[key]" value="73526b0db474f2a0e5f80c67301be73d"/><br />
<p id="img_area"></p>
<input type="submit" value="提交">
</form>
</body>
</html>
\ No newline at end of file
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>简单的html5 File测试 for pic2base64</title>
<style>
</style>
</head>
<body>
<form action="/client/shopkeeper/receivePayment" method="post">
用户登录状态key:<input name="data[key]" value="ceb72deab920ac0edb7272b2ed9dfa1e"/><br />
订单id:<input name="data[orderId]" value=""/><br />
<input type="submit" value="提交">
</form>
</body>
</html>
\ No newline at end of file
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>简单的html5 File测试 for pic2base64</title>
<style>
</style>
</head>
<body>
<form action="/client/shopkeeper/searchDelivery" method="post">
用户登录状态key:<input name="data[key]" value="73526b0db474f2a0e5f80c67301be73d"/><br />
配送员电话:<input name="data[mobile]" value="18305954587"/><br />
<input type="submit" value="提交">
</form>
</body>
</html>
\ No newline at end of file
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