Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
S
services
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
tencent
services
Commits
2a5548c6
Commit
2a5548c6
authored
May 08, 2019
by
王召彬
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'test' of
http://git.dev.2b3.cn/tencent/services
into test
parents
0e9e809c
67400b1e
Hide whitespace changes
Inline
Side-by-side
Showing
11 changed files
with
331 additions
and
315 deletions
+331
-315
src/Buyer/Lib/BuyerInterface.php
+11
-0
src/Coupon/Lib/CouponInterface.php
+3
-3
src/FlowCount/Lib/VisitorInterface.php
+27
-3
src/Goods/Lib/GoodsInterface.php
+119
-83
src/GroupBooking/Enum/GroupBookingCmqEnum.php
+7
-2
src/Order/Enum/OrderItemEnum.php
+4
-5
src/Order/Lib/OrderInterface.php
+97
-177
src/Recharge/Lib/RechargeInterface.php
+17
-10
src/SMS/Lib/SMSInterface.php
+10
-0
src/SellerDistribution/Lib/SellerDistributionInterface.php
+27
-12
src/TimesCard/Lib/TimesCardInterface.php
+9
-20
No files found.
src/Buyer/Lib/BuyerInterface.php
View file @
2a5548c6
...
@@ -14,6 +14,7 @@ use Swoft\Core\ResultInterface;
...
@@ -14,6 +14,7 @@ use Swoft\Core\ResultInterface;
* @method ResultInterface deferUpdateProfile(string $token, array $data)
* @method ResultInterface deferUpdateProfile(string $token, array $data)
* @method ResultInterface deferSelectUser(int $storeId, array $buyerIds, array $fields= ['*'])
* @method ResultInterface deferSelectUser(int $storeId, array $buyerIds, array $fields= ['*'])
* @method ResultInterface deferGetRefereeInfo($storeId,$buyerId)
* @method ResultInterface deferGetRefereeInfo($storeId,$buyerId)
* @method ResultInterface deferGetByNickname($nickname)
* Interface BuyerInterface
* Interface BuyerInterface
* @package App\Lib
* @package App\Lib
*/
*/
...
@@ -90,4 +91,13 @@ interface BuyerInterface
...
@@ -90,4 +91,13 @@ interface BuyerInterface
* @return mixed
* @return mixed
*/
*/
public
function
getRefereeInfo
(
$storeId
,
$buyerId
);
public
function
getRefereeInfo
(
$storeId
,
$buyerId
);
/**
* 获取(视图)买家信息 by nickname
* @param $nickname
* @return mixed
* @author work
*/
public
function
getByNickname
(
$nickname
);
}
}
\ No newline at end of file
src/Coupon/Lib/CouponInterface.php
View file @
2a5548c6
...
@@ -16,7 +16,7 @@ use Swoft\Core\ResultInterface;
...
@@ -16,7 +16,7 @@ use Swoft\Core\ResultInterface;
/**
/**
* The interface of coupon service
* The interface of coupon service
*
*
* @method ResultInterface deferCheckCoupon(int $buyerId, int $storeId, int $couponId,
int $itemId
)
* @method ResultInterface deferCheckCoupon(int $buyerId, int $storeId, int $couponId,
array $itemIds
)
* @method ResultInterface deferGetCouponRecvdList(int $buyerId, int $storeId, int $subStoreId = 0, int $itemId = 0)
* @method ResultInterface deferGetCouponRecvdList(int $buyerId, int $storeId, int $subStoreId = 0, int $itemId = 0)
* @method ResultInterface deferGetDataByCouponId(int $buyerId, int $storeId, int $couponId)
* @method ResultInterface deferGetDataByCouponId(int $buyerId, int $storeId, int $couponId)
*/
*/
...
@@ -40,10 +40,10 @@ interface CouponInterface
...
@@ -40,10 +40,10 @@ interface CouponInterface
* @param integer $buyerId
* @param integer $buyerId
* @param integer $storeId
* @param integer $storeId
* @param integer $couponId
* @param integer $couponId
* @param
integer $itemId
* @param
array $itemIds
* @return int|boolen 如果可用返回优惠券的面值,不可用返回false
* @return int|boolen 如果可用返回优惠券的面值,不可用返回false
*/
*/
public
function
checkCoupon
(
int
$buyerId
,
int
$storeId
,
int
$couponId
,
int
$itemId
);
public
function
checkCoupon
(
int
$buyerId
,
int
$storeId
,
int
$couponId
,
array
$itemIds
);
/**
/**
* 更新优惠券状态
* 更新优惠券状态
...
...
src/FlowCount/Lib/VisitorInterface.php
View file @
2a5548c6
...
@@ -11,7 +11,8 @@ namespace Hdll\Services\FlowCount\Lib;
...
@@ -11,7 +11,8 @@ namespace Hdll\Services\FlowCount\Lib;
use
Swoft\Core\ResultInterface
;
use
Swoft\Core\ResultInterface
;
/**
/**
* @method ResultInterface deferAdd($storeId, array $data)
* @method ResultInterface deferAdd(int $storeId, array $data)
* @method ResultInterface deferBrowseAndShare(int $storeId, int $type, array $itemIds)
* Interface VisitorInterface
* Interface VisitorInterface
* @package App\Lib
* @package App\Lib
*/
*/
...
@@ -19,7 +20,6 @@ interface VisitorInterface
...
@@ -19,7 +20,6 @@ interface VisitorInterface
{
{
/**
/**
*
* 添加访客
* 添加访客
* @param int $storeId
* @param int $storeId
* @param array $data
* @param array $data
...
@@ -30,6 +30,29 @@ interface VisitorInterface
...
@@ -30,6 +30,29 @@ interface VisitorInterface
* string $data['headImgUrl']=>'访客头像URL'
* string $data['headImgUrl']=>'访客头像URL'
* @return mixed
* @return mixed
*/
*/
public
function
add
(
$storeId
,
array
$data
);
public
function
add
(
int
$storeId
,
array
$data
);
/**
* 访问量和转发量
* @param int $storeId 店铺id
* @param int $type 类型:0普通商品 1砍价 2限时购 3拼团
* @param array $itemIds 商品或活动(活动指:砍价、限时购 、拼团)的id列表
* 说明:$itemIds 格式[1,2,3]
* @return ;
* 响应参数:
* [
* 'browseNum' => [
* 'itemId' => '统计数',
* 'itemId' => '统计数',
* ... ...
* ],
* 'shareNum' => [
* 'itemId' => '统计数',
* 'itemId' => '统计数',
* ... ...
* ]
* ]
*/
public
function
browseAndShare
(
int
$storeId
,
int
$type
,
array
$itemIds
);
}
}
\ No newline at end of file
src/Goods/Lib/GoodsInterface.php
View file @
2a5548c6
...
@@ -17,6 +17,10 @@ use Swoft\Core\ResultInterface;
...
@@ -17,6 +17,10 @@ use Swoft\Core\ResultInterface;
* @method ResultInterface deferGetServiceByGoodsId($storeId, $goodsId, $type = 3)
* @method ResultInterface deferGetServiceByGoodsId($storeId, $goodsId, $type = 3)
* @method ResultInterface deferGetReturnVisitByGoodsId($storeId, $goodsId, $type = 2)
* @method ResultInterface deferGetReturnVisitByGoodsId($storeId, $goodsId, $type = 2)
* @method ResultInterface deferListByIds($ids, $storeId)
* @method ResultInterface deferListByIds($ids, $storeId)
* @method ResultInterface deferGetSkuInfo($skuId, $goodsId, $storeId)
* @method ResultInterface deferGetSkuByIds($goodsId, $skuIds, $storeId)
* @method ResultInterface deferGetSkuByGoodsId($goodsId, $storeId)
* @method ResultInterface deferGetSpecAttributeByGoodsId($goodsId, $storeId)
* @method ResultInterface deferAfterServiceTmp($storeId)
* @method ResultInterface deferAfterServiceTmp($storeId)
* Interface GoodsInterface
* Interface GoodsInterface
* @package Hdll\Services\Goods\Lib
* @package Hdll\Services\Goods\Lib
...
@@ -24,85 +28,118 @@ use Swoft\Core\ResultInterface;
...
@@ -24,85 +28,118 @@ use Swoft\Core\ResultInterface;
interface
GoodsInterface
interface
GoodsInterface
{
{
/**
/**
* 获取商品
* 获取商品
* @param $storeId
* @param $storeId
* @return [
* @return [
* 'gcId' 商品类ID
* 'gcId' 商品类ID
* 'asId' 服务ID
* 'asId' 服务ID
* 'stock' 库存
* 'stock' 库存
* 'name' 名称
* 'name' 名称
* 'image' 图片
* 'image' 图片
* 'price' 价格
* 'price' 价格
* 'state' 状态
* 'state' 状态
* 'body' 描述
* 'body' 描述
* 'originalPrice' 原价
* 'originalPrice' 原价
* 'sales' 销量
* 'sales' 销量
* ]
* ]
* @param $id
* @param $id
* @return mixed
* @return mixed
* @author Administrator
* @author Administrator
*/
*/
public
function
get
(
$storeId
,
$id
);
public
function
get
(
$storeId
,
$id
);
/**
/**
* 增加商品销量
* 增加商品销量
* 减少商品库存
* 减少商品库存
* @param $storeId
* @param $storeId
* @param $goodsId
* @param $goodsId
* @return mixed
* @return mixed
* @author Administrator
* @author Administrator
*/
*/
public
function
incSales
(
$storeId
,
$goodsId
);
public
function
incSales
(
$storeId
,
$goodsId
);
/**
/**
* 减少商品销量
* 减少商品销量
* 增加商品库存
* 增加商品库存
* @param $storeId
* @param $storeId
* @param $goodsId
* @param $goodsId
* @return mixed
* @return mixed
* @author Administrator
* @author Administrator
*/
*/
public
function
decSales
(
$storeId
,
$goodsId
);
public
function
decSales
(
$storeId
,
$goodsId
);
/**
/**
* 获取商品服务
* 获取商品服务
* @param $storeId
* @param $storeId
* @param $goodsId
* @param $goodsId
* @param $type 1 付款后 2 服务前 3 服务后
* @param $type 1 付款后 2 服务前 3 服务后
* @return mixed
* @return mixed
* @author Administrator
* @author Administrator
*/
*/
public
function
getServiceByGoodsId
(
$storeId
,
$goodsId
,
$type
=
3
);
public
function
getServiceByGoodsId
(
$storeId
,
$goodsId
,
$type
=
3
);
/**
/**
* 获取用户回访
* 获取用户回访
* @param $storeId
* @param $storeId
* @param $goodsId
* @param $goodsId
* @param $type 1 之前 2 之后
* @param $type 1 之前 2 之后
* @return mixed
* @return mixed
* @author Administrator
* @author Administrator
*/
*/
public
function
getReturnVisitByGoodsId
(
$storeId
,
$goodsId
,
$type
=
2
);
public
function
getReturnVisitByGoodsId
(
$storeId
,
$goodsId
,
$type
=
2
);
/**
/**
* 获取商品列表 ids
* 获取商品列表 ids
* @param $ids
* @param $ids
* @param $storeId
* @param $storeId
* @param $order
* @param $order
* @return mixed
* @return mixed
* @author Administrator
* @author Administrator
*/
*/
public
function
listByIds
(
array
$ids
,
$storeId
,
$order
=
[
'id'
,
'DESC'
]);
public
function
listByIds
(
array
$ids
,
$storeId
,
$order
=
[
'id'
,
'DESC'
]);
/**
/**
* 添加后续服务模版
* 获取sku信息
* @param $storeId
* @param $skuId
* @return mixed
* @param $goodsId
* @author work
* @param $storeId
*/
* @return mixed
public
function
afterServiceTmp
(
$storeId
);
* @author work
}
*/
\ No newline at end of file
public
function
getSkuInfo
(
$skuId
,
$goodsId
,
$storeId
);
/**
* 获取多个sku信息
* @param $goodsId
* @param $skuIds
* @return mixed
* @author work
*/
public
function
getSkuByIds
(
$goodsId
,
$skuIds
,
$storeId
);
public
function
getSkuByGoodsId
(
$goodsId
,
$storeId
);
/**
* 获取商品规格属性
* @param $goodsId
* @param $storeId
* @return mixed
* @author work
*/
public
function
getSpecAttributeByGoodsId
(
$goodsId
,
$storeId
);
/**
* 添加后续服务模版
* @param $storeId
* @return mixed
* @author work
*/
public
function
afterServiceTmp
(
$storeId
);
}
src/GroupBooking/Enum/GroupBookingCmqEnum.php
View file @
2a5548c6
<?php
<?php
namespace
Hdll\Services\GroupBooking\Enum
;
namespace
Hdll\Services\GroupBooking\Enum
;
class
GroupBookingCmqEnum
{
class
GroupBookingCmqEnum
{
const
TOPIC
=
'groupBooking'
;
const
TOPIC
=
'groupBooking'
;
const
CLOSE_RECORD
=
'closeRecord'
;
const
CLOSE_RECORD
=
'closeRecord'
;
//关闭拼团
const
GROUP_BOOKING
=
'groupBooking'
;
//拼团成功回调
}
}
\ No newline at end of file
src/Order/Enum/OrderItemEnum.php
View file @
2a5548c6
...
@@ -17,9 +17,7 @@ class OrderItemEnum
...
@@ -17,9 +17,7 @@ class OrderItemEnum
const
LOCKED
=
4
;
//锁定
const
LOCKED
=
4
;
//锁定
//核销渠道
//核销方式
const
DELIVERED_BUYER_BTN
=
1
;
//买家按钮核销
const
DELIVERED_BTN
=
1
;
//按钮核销
const
DELIVERED_EMPLOYEE_CODE
=
2
;
//店员扫码核销
const
DELIVERED_CODE
=
2
;
//扫码核销
const
DELIVERED_SELLER_CODE
=
3
;
//店主扫码码核销
const
DELIVERED_SELLER_BTN
=
4
;
//店主按钮核销
}
}
\ No newline at end of file
src/Order/Lib/OrderInterface.php
View file @
2a5548c6
...
@@ -13,38 +13,41 @@ namespace Hdll\Services\Order\Lib;
...
@@ -13,38 +13,41 @@ namespace Hdll\Services\Order\Lib;
use
Swoft\Core\ResultInterface
;
use
Swoft\Core\ResultInterface
;
/**
/**
*
The interface of demo servic
e
*
order servci
e
*
*
* @method ResultInterface deferCreateOrder(int $buyerId,int $storeId,int $consigneeId,int $itemId,int $selectedNum,int $orderType,int $total,int $activityPrice,string $goodsName,string $goodsImage,string $activityName,int $goodsId,int $goodsPrice,string $message = ''); * @method ResultInterface deferGetOrderInfoBySn(int $storeId, string $orderSn, array $consigneeFields = [], array $itemFields = [])
* @method ResultInterface deferCreateOrder(int $buyerId,int $storeId,int $consigneeId,int $itemId,int $selectedNum,int $orderType,int $activityPrice,string $goodsName,string $goodsImage,string $activityName,int $goodsId,int $goodsPrice,string $message='',int $skuId=0,int $subStoreId=0,int $couponId=0);
* @method ResultInterface deferGetOrderInfo(int $storeId,int $orderId)
* @method ResultInterface deferGetOrderDetailBySubId(int $storeId,int $subOrderId,$ifSelf=true,bool $ifExtend=false)
* @method ResultInterface deferGetOrderDetailByPid(int $storeId,int $pId, $ifSelf=false, $ifExtend=false)
* @method ResultInterface deferGetOrderDetailByMainSn(int $storeId,string $orderSn, $ifSelf=false, $ifExtend=false)
* @method ResultInterface deferUpdateInfoById(int $storeId,int $orderId, array $updateInfo)
* @method ResultInterface deferUpdateInfoById(int $storeId,int $orderId, array $updateInfo)
* @method ResultInterface deferGetSimpleList($storeId, $condition, $fields = ['*'])
* @method ResultInterface deferUpdateInfoByIds(int $storeId,array $orderIds, array $updateInfo)
* @method ResultInterface deferUpdateInfoByIds(int $storeId,array $orderIds, array $updateInfo)
* @method ResultInterface deferCollectionClose(int $storeId, int $orderId)
* @method ResultInterface deferUpdateInfoByPids(int $storeId,array $pIds,array $updateInfo)
* @method ResultInterface deferGetOtherInfo(int $storeId, string $orderSn, array $consigneeFields = [], array $itemFields = [])
* @method ResultInterface deferUpdateMainOrderByPid(int $storeId,int $pId,array $mainData,array $subData=[])
* @method ResultInterface deferGetList(int $storeId,array $ids)
* @method ResultInterface deferUnconfirmedCount(int $storeId)
* @method ResultInterface deferUnconfirmedCount(int $storeId)
* @method ResultInterface deferGetOrder($orderSn)
* @method ResultInterface deferGetSubOrderListBySubIds(int $storeId,array $subIds)
* @method ResultInterface deferOrderCount(int $storeId,int $orderType,array $itemIds)
*/
*/
interface
OrderInterface
interface
OrderInterface
{
{
/**
/**
* 创建订单
* 创建订单
*
*
* @param int $buyerId
* @param integer $buyerId
* @param int $storeId
* @param integer $storeId
* @param int $consigneeId
* @param integer $consigneeId
* @param int $itemId
* @param integer $itemId
* @param int $selectedNum
* @param integer $selectedNum
* @param int $orderType
* @param integer $orderType
* @param int $total
* @param integer $activityPrice
* @param int $activityPrice
* @param string $goodsName
* @param string $goodsName
* @param string $goodsImage
* @param string $goodsImage
* @param string $activityName
* @param string $activityName
* @param int $goodsId
* @param int
eger
$goodsId
* @param int $goodsPrice
* @param int
eger
$goodsPrice
* @param string $message
* @param string $message
* @param integer $skuId
* @param integer $subStoreId
* @param integer $couponId
* @return mixed
* @return mixed
*/
*/
public
function
createOrder
(
public
function
createOrder
(
...
@@ -54,196 +57,112 @@ interface OrderInterface
...
@@ -54,196 +57,112 @@ interface OrderInterface
int
$itemId
,
int
$itemId
,
int
$selectedNum
,
int
$selectedNum
,
int
$orderType
,
int
$orderType
,
int
$total
,
int
$activityPrice
,
int
$activityPrice
,
string
$goodsName
,
string
$goodsName
,
string
$goodsImage
,
string
$goodsImage
,
string
$activityName
,
string
$activityName
,
int
$goodsId
,
int
$goodsId
,
int
$goodsPrice
,
int
$goodsPrice
,
string
$message
=
''
string
$message
=
''
,
int
$skuId
=
0
,
int
$subStoreId
=
0
,
int
$couponId
=
0
);
);
public
function
getOrderInfo
(
int
$storeId
,
int
$orderId
);
public
function
getOrderInfoBySn
(
int
$storeId
,
string
$orderSn
,
array
$consigneeFields
=
[],
array
$itemFields
=
[]);
public
function
updateInfoById
(
int
$storeId
,
int
$orderId
,
array
$updateInfo
);
public
function
closeOrder
(
int
$storeId
,
int
$orderId
);
/**
/**
* 获取订单数据
* 根据子订单ID查询订单详情
* 字段值
*
* `id`,
* @param integer $storeId 店铺ID
`orderSn`,
* @param integer $subOrderId 子订单ID
`paySn`,
* @param boolean $ifSelf 子订单是否只有自己
`orderType` '订单类型:0普通商品,1活动',
* @param boolean $ifExtend 是否涵带附加信息(如门店信息、上级信息等)
`storeId`, 店铺id
* @return array
`buyerId` ,买家id
*/
`itemId` '0',
public
function
getOrderDetailBySubId
(
int
$storeId
,
int
$subOrderId
,
$ifSelf
=
true
,
bool
$ifExtend
=
false
);
`consigneeId` '付款人(收货人)ID,当线下订单时为空',
/**
`goodsAmount` ,
* 根据主订单ID查询订单详情
`orderAmount` '订单应付款',
*
`actualAmount` '订单实付款',
* @param integer $storeId 店铺ID
`refundAmount` '退款金额',
* @param integer $pId 主订单ID
`state` '订单状态:0(已取消)10(默认):未付款;20:已付款;30:已发货/已预约;40:已收货/已核销;50-申请退款;60退款成功,70 已关闭,80,退款中,90,已评价',
* @param boolean $ifExtend 是否涵带附加信息(如门店信息、上级信息等)
`refundState` '0' COMMENT '退款状态:0是无退款,1是部分退款,2是全部退款',
* @return array
`refundMsg`'退款原因',
*/
`lockState` '锁定状态:0是正常,大于0是锁定',
public
function
getOrderDetailByPid
(
int
$storeId
,
int
$pId
,
$ifSelf
=
false
,
$ifExtend
=
false
);
`lockMsg` '订单锁定原因',
`balanceState` '对账状态:0-未对账,1-已对账',
/**
`balanceTime` '对账时间',
* 通过订主单orderSn获取订单信息
`message` ,
*
`reservationTime` ,
* @param integer $storeId
`createTime` 创建时间,
* @param string $orderSn
`updateTime` 更新时间,
* @param boolean $ifSelf 是否只有主订单信息
`deleteTime` 删除时间,
* @param boolean $ifExtend 是否涵带附加信息(如门店信息、上级信息等)
`sellerId` '卖家id',
* @return array
`deliveredTime` '核销时间',
*/
*
public
function
getOrderDetailByMainSn
(
int
$storeId
,
string
$orderSn
,
$ifSelf
=
false
,
$ifExtend
=
false
);
*
* @param $storeId
* @param $condition
* @param array $fields
* @return mixed
*/
public
function
getSimpleList
(
$storeId
,
$condition
,
$fields
=
[
'*'
]);
/**
/**
*
退款成功
*
根据子订单ID更新子订单信息
*
*
* @param int $storeId
* @param integer $storeId
* @param array $orderInfo
* @param integer $subId
* @return mixed
* @param array $updateInfo
* @return int
*/
*/
public
function
refundSuccess
(
int
$storeId
,
array
$order
Info
);
public
function
updateInfoById
(
int
$storeId
,
int
$subId
,
array
$update
Info
);
/**
/**
*
拼团关闭订单,含退款
*
根据子订单ID批量更新子订单信息
*
*
* @param int $storeId
* @param int $storeId
* @param int $orderId
* @param array $subIds
* @return mixed
* @param array $updateInfo
* @return int
*/
*/
public
function
collectionClose
(
int
$storeId
,
int
$orderId
);
public
function
updateInfoByIds
(
int
$storeId
,
array
$subIds
,
array
$updateInfo
);
/**
/**
*
批量更新
*
根据主订单ID批量更新子订单信息
*
*
* @param int $storeId
* @param int
eger
$storeId
* @param array $
order
Ids
* @param array $
p
Ids
* @param array $updateInfo
* @param array $updateInfo
* @return
mixed
* @return
int
*/
*/
public
function
updateInfoBy
Ids
(
int
$storeId
,
array
$orderIds
,
array
$updateInfo
);
public
function
updateInfoBy
Pids
(
int
$storeId
,
array
$pIds
,
array
$updateInfo
);
/**
/**
*
获取订单联系人信息,item信息用
*
根据主订单ID更新订单信息
*
*
* @param int $storeId
* @param int
eger
$storeId
* @param
string $orderSn
* @param
integer $pId
* @param array $
consigneeFields
* @param array $
mainData
* @param array $
itemFields
* @param array $
subData
* @return
mixed
* @return
bool
*/
*/
public
function
getOtherInfo
(
int
$storeId
,
string
$orderSn
,
array
$consigneeFields
=
[],
array
$itemFields
=
[]);
public
function
updateMainOrderByPid
(
int
$storeId
,
int
$pId
,
array
$mainData
,
array
$subData
=
[]);
/**
/**
* 批量获取订单信息
* 获取未入账统计
* [5]=>
* array(28) {
["id"]=>
string(1) "1"
["orderSn"]=>
string(20) "198bSA93091872375217"
["paySn"]=>
string(28) "4200000198201809300361147593"
["orderType"]=>
string(1) "0"
["storeId"]=>
string(3) "198"
["buyerId"]=>
string(1) "1"
["itemId"]=>
string(1) "1"
["consigneeId"]=>
string(1) "1"
["goodsAmount"]=>
string(1) "1"
["orderAmount"]=>
string(1) "1"
["actualAmount"]=>
string(1) "1"
["refundAmount"]=>
string(1) "1"
["state"]=>
string(2) "60"
["refundState"]=>
string(1) "2"
["refundMsg"]=>
string(30) "身体不适,暂时不做了"
["lockState"]=>
string(1) "0"
["lockMsg"]=>
string(0) ""
["balanceState"]=>
string(1) "0"
["balanceTime"]=>
string(1) "0"
["message"]=>
string(0) ""
["reservationTime"]=>
string(1) "0"
["createTime"]=>
string(10) "1538291872"
["updateTime"]=>
string(10) "1538291953"
["deleteTime"]=>
string(1) "0"
["sellerId"]=>
string(1) "6"
["deliveredTime"]=>
string(1) "0"
["commission"]=>
string(1) "0"
["items"]=>
array(1) {
[0]=>
array(2) {
["name"]=>
string(7) "商品1"
["image"]=>
string(72) "store-198/goods/tmp_7d07ba3c8e10c3cd65de8d98d00cbd5aace9e736ddde0c59.jpg"
}
}
}
}
*
* @param int $storeId
* @param int $storeId
* @param array $ids
* @return array
* @return mixed
*/
*/
public
function
getList
(
int
$storeId
,
array
$ids
);
public
function
unconfirmedCount
(
int
$storeId
);
/**
/**
*
统计核销
*
批量查询子订单信息
*
*
* array(2) {
* @param integer $storeId
["money"]=>
* @param array $subIds
string(1) "8"
* @return array
["orders"]=>
string(1) "6"
}
* @param int $storeId
* @return mixed
*/
*/
public
function
unconfirmedCount
(
int
$storeId
);
public
function
getSubOrderListBySubIds
(
int
$storeId
,
array
$subIds
);
public
function
getOrder
(
$orderSn
);
public
function
getTotal
(
int
$storeId
);
/**
* 商品、活动成交量统计
*
* @param integer $storeId
* @param integer $orderType 订单类型(参考OrderEnum订单类型的枚举)
* @param array $itemIds
* @return array
*/
public
function
orderCount
(
int
$storeId
,
int
$orderType
,
array
$itemIds
);
}
}
\ No newline at end of file
src/Recharge/Lib/RechargeInterface.php
View file @
2a5548c6
...
@@ -16,8 +16,8 @@ use Swoft\Core\ResultInterface;
...
@@ -16,8 +16,8 @@ use Swoft\Core\ResultInterface;
/**
/**
* The interface of demo service
* The interface of demo service
*
*
* @method ResultInterface defer
p
ayStatus(int $storeId,int $bargainbranchId,int $status,int $orderId)
* @method ResultInterface defer
P
ayStatus(int $storeId,int $bargainbranchId,int $status,int $orderId)
* @method ResultInterface defer
spendCardMoney( int $storeId,int $buyerId,int $itemOrderId,string $itemTitle,int $payMoney
)
* @method ResultInterface defer
SpendCardMoney(int $storeId, int $buyerId, array $subOrders
)
* @method ResultInterface deferReturnCardMoney( int $storeId,int $buyerId,int $itemOrderId,string $itemTitle,int $payMoney)
* @method ResultInterface deferReturnCardMoney( int $storeId,int $buyerId,int $itemOrderId,string $itemTitle,int $payMoney)
*/
*/
interface
RechargeInterface
interface
RechargeInterface
...
@@ -41,16 +41,23 @@ interface RechargeInterface
...
@@ -41,16 +41,23 @@ interface RechargeInterface
* 花费卡金额
* 花费卡金额
* @param int $storeId
* @param int $storeId
* @param int $buyerId
* @param int $buyerId
* @param int $goodOrderId
* @param array $subOrders
* $subOrders 示例:
* [
* [
* 'id' => 333,
* 'itemName' => 'namenamename',
* 'actualAmount' => 444,
* ],
* [
* 'id' => 555,
* 'itemName' => 'namenamename',
* 'actualAmount' => 666,
* ],
* ]
* @return mixed
* @return mixed
*/
*/
public
function
spendCardMoney
(
public
function
spendCardMoney
(
int
$storeId
,
int
$buyerId
,
array
$subOrders
);
int
$storeId
,
int
$buyerId
,
int
$itemOrderId
,
string
$itemTitle
,
int
$payMoney
);
/**
/**
* 退回储值卡金额
* 退回储值卡金额
...
...
src/SMS/Lib/SMSInterface.php
View file @
2a5548c6
...
@@ -22,6 +22,7 @@ use Swoft\Core\ResultInterface;
...
@@ -22,6 +22,7 @@ use Swoft\Core\ResultInterface;
* @method ResultInterface deferPayOrder(int $storeId,string $orderSn,int $payStatus)
* @method ResultInterface deferPayOrder(int $storeId,string $orderSn,int $payStatus)
* @method ResultInterface deferGetOrder(int $storeId,int $smsOId)
* @method ResultInterface deferGetOrder(int $storeId,int $smsOId)
* @method ResultInterface deferGetOrderBySn(int $storeId,string $sn)
* @method ResultInterface deferGetOrderBySn(int $storeId,string $sn)
* @method ResultInterface deferGetCountLeft(int $storeId)
*/
*/
interface
SMSInterface
interface
SMSInterface
{
{
...
@@ -63,5 +64,14 @@ interface SMSInterface
...
@@ -63,5 +64,14 @@ interface SMSInterface
* @return array
* @return array
*/
*/
public
function
getOrderBySn
(
int
$storeId
,
string
$sn
);
public
function
getOrderBySn
(
int
$storeId
,
string
$sn
);
/**
* 根据店铺id 获取剩余的短信条数
*
* @param integer $storeId
* @return int
*/
public
function
getCountLeft
(
int
$storeId
);
}
}
src/SellerDistribution/Lib/SellerDistributionInterface.php
View file @
2a5548c6
...
@@ -5,22 +5,26 @@
...
@@ -5,22 +5,26 @@
* Date: 2018/7/25
* Date: 2018/7/25
* Time: 14:00
* Time: 14:00
*/
*/
namespace
Hdll\Services\SellerDistribution\Lib
;
namespace
Hdll\Services\SellerDistribution\Lib
;
use
Swoft\Core\ResultInterface
;
use
Swoft\Core\ResultInterface
;
/**
/**
* @method ResultInterface deferSaveBill($orderId, $sellerId, $money)
* @method ResultInterface deferSaveBill($orderId, $sellerId, $money)
* @method ResultInterface deferGetCommission($sellerId)
* @method ResultInterface deferGetCommission($sellerId)
* @method ResultInterface deferAddBalance($sellerId, $money, $orderSn
=
'')
* @method ResultInterface deferAddBalance($sellerId, $money, $orderSn
=
'')
* @method ResultInterface deferReduceBalance($sellerId, $money, $orderSn
=
'')
* @method ResultInterface deferReduceBalance($sellerId, $money, $orderSn
=
'')
* @method ResultInterface deferListByOrderId($storeId, $orderId,$sellerId)
* @method ResultInterface deferListByOrderId($storeId, $orderId,
$sellerId)
* @method ResultInterface deferAddTotal($sellerId, $money, $orderSn
=
'')
* @method ResultInterface deferAddTotal($sellerId, $money, $orderSn
=
'')
* @method ResultInterface deferRefundAddBalance($sellerId, $money, $orderSn
=
'')
* @method ResultInterface deferRefundAddBalance($sellerId, $money, $orderSn
=
'')
* @method ResultInterface deferCountVip($storeId, $sellerId)
* @method ResultInterface deferCountVip($storeId, $sellerId)
* @method ResultInterface deferSumViewMoneyByStoreIds(array $storeIds)
* Interface SellerDistributionInterface
* Interface SellerDistributionInterface
* @package App\Lib
* @package App\Lib
*/
*/
interface
SellerDistributionInterface
{
interface
SellerDistributionInterface
{
/**
/**
...
@@ -53,7 +57,7 @@ interface SellerDistributionInterface{
...
@@ -53,7 +57,7 @@ interface SellerDistributionInterface{
* @return mixed
* @return mixed
* @author Administrator
* @author Administrator
*/
*/
public
function
addBalance
(
$sellerId
,
$money
,
$orderSn
=
''
);
public
function
addBalance
(
$sellerId
,
$money
,
$orderSn
=
''
);
/**
/**
* 减少佣金
* 减少佣金
...
@@ -62,7 +66,7 @@ interface SellerDistributionInterface{
...
@@ -62,7 +66,7 @@ interface SellerDistributionInterface{
* @return mixed
* @return mixed
* @author Administrator
* @author Administrator
*/
*/
public
function
reduceBalance
(
$sellerId
,
$money
,
$orderSn
=
''
);
public
function
reduceBalance
(
$sellerId
,
$money
,
$orderSn
=
''
);
/**
/**
...
@@ -73,7 +77,7 @@ interface SellerDistributionInterface{
...
@@ -73,7 +77,7 @@ interface SellerDistributionInterface{
* @return mixed
* @return mixed
* @author Administrator
* @author Administrator
*/
*/
public
function
listByOrderId
(
$storeId
,
$orderId
,
$sellerId
);
public
function
listByOrderId
(
$storeId
,
$orderId
,
$sellerId
);
/**
/**
* 更细对账表
* 更细对账表
...
@@ -83,7 +87,7 @@ interface SellerDistributionInterface{
...
@@ -83,7 +87,7 @@ interface SellerDistributionInterface{
* @return mixed
* @return mixed
* @author Administrator
* @author Administrator
*/
*/
public
function
updateBill
(
$storeId
,
$id
,
$balanceState
);
public
function
updateBill
(
$storeId
,
$id
,
$balanceState
);
/**
/**
* 增加累计提现
* 增加累计提现
...
@@ -92,7 +96,7 @@ interface SellerDistributionInterface{
...
@@ -92,7 +96,7 @@ interface SellerDistributionInterface{
* @return mixed
* @return mixed
* @author Administrator
* @author Administrator
*/
*/
public
function
addTotal
(
$sellerId
,
$money
,
$orderSn
=
''
);
public
function
addTotal
(
$sellerId
,
$money
,
$orderSn
=
''
);
/**
/**
...
@@ -102,7 +106,7 @@ interface SellerDistributionInterface{
...
@@ -102,7 +106,7 @@ interface SellerDistributionInterface{
* @return mixed
* @return mixed
* @author Administrator
* @author Administrator
*/
*/
public
function
refundAddBalance
(
$sellerId
,
$money
,
$orderSn
=
''
);
public
function
refundAddBalance
(
$sellerId
,
$money
,
$orderSn
=
''
);
/**
/**
...
@@ -113,4 +117,14 @@ interface SellerDistributionInterface{
...
@@ -113,4 +117,14 @@ interface SellerDistributionInterface{
* @author Administrator
* @author Administrator
*/
*/
public
function
countVip
(
$storeId
,
$sellerId
);
public
function
countVip
(
$storeId
,
$sellerId
);
/**
* 统计所有分销金额
* @param array $storeIds
* @return mixed
* @author work
*/
public
function
sumViewMoneyByStoreIds
(
array
$storeIds
);
}
}
\ No newline at end of file
src/TimesCard/Lib/TimesCardInterface.php
View file @
2a5548c6
...
@@ -16,8 +16,8 @@ use Swoft\Core\ResultInterface;
...
@@ -16,8 +16,8 @@ use Swoft\Core\ResultInterface;
/**
/**
* The interface of demo service
* The interface of demo service
*
*
* @method ResultInterface defer
p
ayStatus(int $storeId,int $bargainbranchId,int $status,int $orderId)
* @method ResultInterface defer
P
ayStatus(int $storeId,int $bargainbranchId,int $status,int $orderId)
* @method ResultInterface defer
spendTimesCard( int $storeId,int $buyerId,int $itemOrderId, int $usercardId,int $goodsId,string $itemTitle, int $time
s)
* @method ResultInterface defer
SpendTimesCard(int $storeId, int $buyerId, int $usercardId, array $subOrder
s)
* @method ResultInterface deferReturnCardTimes( int $storeId,int $buyerId,int $itemOrderId,int $goodsId,string $itemTitle,int $times)
* @method ResultInterface deferReturnCardTimes( int $storeId,int $buyerId,int $itemOrderId,int $goodsId,string $itemTitle,int $times)
* @method ResultInterface defergetTimesCardUserCardInfo(int $storeId, int $goodsId)
* @method ResultInterface defergetTimesCardUserCardInfo(int $storeId, int $goodsId)
*/
*/
...
@@ -40,25 +40,14 @@ interface TimesCardInterface
...
@@ -40,25 +40,14 @@ interface TimesCardInterface
/**
/**
* 花费卡次数
* 花费卡次数
*
* @param int $storeId // 商铺id
* @param integer $storeId
* @param int $buyerId // 买家ID
* @param integer $buyerId
* @param int $itemOrderId // 订单 id
* @param integer $usercardId
* @param int $usercardId // 用户卡id
* @param array $subOrders
* @param int $goodsId // 商品id
* @return bool
* @param string $itemTitle //商品名字
* @param int $times // 花费次数 传 1
* @return mixed
*/
*/
public
function
spendTimesCard
(
public
function
spendTimesCard
(
int
$storeId
,
int
$buyerId
,
int
$usercardId
,
array
$subOrders
);
int
$storeId
,
int
$buyerId
,
int
$itemOrderId
,
int
$usercardId
,
int
$goodsId
,
string
$itemTitle
,
int
$times
);
/**
/**
* 退回次卡数量
* 退回次卡数量
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment