\app\common\service\wechat\wowShoping

好物圈-商品收藏 服务类 Class Shoping

Summary

Methods
Properties
Constants
__construct()
add()
delete()
getError()
No public properties found
No constants found
No protected methods found
$error
N/A
initApiDriver()
model()
getProductListToAdd()
$wxappId
$ApiDriver
N/A

Properties

$error

$error : 

Type

$wxappId

$wxappId : 

Type

$ApiDriver

$ApiDriver : 

Type

Methods

__construct()

__construct(  $wxappId) 

构造方法 Shoping constructor.

Parameters

$wxappId

Throws

\app\common\exception\BaseException
\think\exception\DbException

add()

add(\think\Collection  $user, array  $goodsList) : boolean

添加好物圈商品收藏

Parameters

\think\Collection $user

用户信息

array $goodsList

商品列表

Throws

\app\common\exception\BaseException
\think\exception\DbException
\Exception

Returns

boolean

delete()

delete(  $id) : boolean

删除好物圈商品收藏

Parameters

$id

Throws

\app\common\exception\BaseException
\think\exception\DbException

Returns

boolean

getError()

getError() : mixed

返回错误信息

Returns

mixed

initApiDriver()

initApiDriver() 

实例化微信api驱动

Throws

\app\common\exception\BaseException
\think\exception\DbException

model()

model(integer|null  $id = null, array  $with = array('user')) : \app\common\model\wow\Shoping|null

获取好物圈订单记录模型

Parameters

integer|null $id
array $with

Throws

\think\exception\DbException

Returns

\app\common\model\wow\Shoping|null

getProductListToAdd()

getProductListToAdd(  $goodsList) : array

整理商品列表 (用于添加收藏接口)

Parameters

$goodsList

Returns

array