| @@ 266-283 (lines=18) @@ | ||
| 263 | * |
|
| 264 | * @return array |
|
| 265 | */ |
|
| 266 | public function deposit($card_id, $code = []) |
|
| 267 | { |
|
| 268 | if (!is_string($card_id) || !is_array($code)) { |
|
| 269 | $this->setError('参数错误'); |
|
| 270 | ||
| 271 | return false; |
|
| 272 | } |
|
| 273 | ||
| 274 | $queryStr = []; |
|
| 275 | $queryStr['card_id'] = $card_id; |
|
| 276 | $queryStr['code'] = $code; |
|
| 277 | ||
| 278 | $this->apitype = 'card'; |
|
| 279 | $this->module = 'code'; |
|
| 280 | $res = $this->_post('deposit', $queryStr); |
|
| 281 | ||
| 282 | return $res; |
|
| 283 | } |
|
| 284 | ||
| 285 | /** |
|
| 286 | * 查询导入code数目 |
|
| @@ 317-334 (lines=18) @@ | ||
| 314 | * @param [array] $code 自定义code 数组 |
|
| 315 | * |
|
| 316 | */ |
|
| 317 | public function checkcode($card_id, $code = []) |
|
| 318 | { |
|
| 319 | if (!is_string($card_id) || !is_array($code)) { |
|
| 320 | $this->setError('参数错误'); |
|
| 321 | ||
| 322 | return false; |
|
| 323 | } |
|
| 324 | ||
| 325 | $queryStr = []; |
|
| 326 | $queryStr['card_id'] = $card_id; |
|
| 327 | $queryStr['code'] = $code; |
|
| 328 | ||
| 329 | $this->apitype = 'card'; |
|
| 330 | $this->module = 'code'; |
|
| 331 | $res = $this->_post('checkcode', $queryStr); |
|
| 332 | ||
| 333 | return $res; |
|
| 334 | } |
|
| 335 | ||
| 336 | /** |
|
| 337 | * 图文消息群发卡券 |
|
| @@ 369-386 (lines=18) @@ | ||
| 366 | * |
|
| 367 | * @return |
|
| 368 | */ |
|
| 369 | public function testwhitelist($openid = [], $username = []) |
|
| 370 | { |
|
| 371 | if (!is_array($openid) || !is_array($username)) { |
|
| 372 | $this->setError('参数错误'); |
|
| 373 | ||
| 374 | return false; |
|
| 375 | } |
|
| 376 | ||
| 377 | $queryStr = []; |
|
| 378 | $queryStr['openid'] = $openid; |
|
| 379 | $queryStr['username'] = $username; |
|
| 380 | ||
| 381 | $this->apitype = 'card'; |
|
| 382 | $this->module = 'testwhitelist'; |
|
| 383 | $res = $this->_post('set', $queryStr); |
|
| 384 | ||
| 385 | return $res; |
|
| 386 | } |
|
| 387 | ||
| 388 | /** |
|
| 389 | * 查询Code接口 |
|