add clear
This commit is contained in:
@@ -132,7 +132,7 @@ class Material extends AfficialAccount
|
||||
* @return mixed
|
||||
* @throws Exception
|
||||
*/
|
||||
public function getMaterial(string $media_id)
|
||||
public function getMaterial($media_id)
|
||||
{
|
||||
$this->request->setHost('api.weixin.qq.com');
|
||||
$this->request->setErrorField('errcode');
|
||||
@@ -154,7 +154,7 @@ class Material extends AfficialAccount
|
||||
* @return mixed
|
||||
* @throws Exception
|
||||
*/
|
||||
public function delMaterial(string $media_id)
|
||||
public function delMaterial($media_id)
|
||||
{
|
||||
$this->request->setHost('api.weixin.qq.com');
|
||||
$this->request->setErrorField('errcode');
|
||||
@@ -172,13 +172,13 @@ class Material extends AfficialAccount
|
||||
|
||||
/**
|
||||
* declare
|
||||
* @param string $media_id
|
||||
* @param $media_id
|
||||
* @param int $index
|
||||
* @param array $articles
|
||||
* @return mixed
|
||||
* @throws Exception
|
||||
*/
|
||||
public function modifyNewsMaterial(string $media_id, int $index, array $articles)
|
||||
public function modifyNewsMaterial($media_id, int $index, array $articles)
|
||||
{
|
||||
$this->request->setHost('api.weixin.qq.com');
|
||||
$this->request->setErrorField('errcode');
|
||||
@@ -227,11 +227,11 @@ class Material extends AfficialAccount
|
||||
* declare
|
||||
* @param int $offset
|
||||
* @param int $size
|
||||
* @param string $type
|
||||
* @param $type
|
||||
* @return mixed
|
||||
* @throws Exception
|
||||
*/
|
||||
public function getMaterialList(int $offset, int $size, string $type)
|
||||
public function getMaterialList(int $offset, int $size, $type)
|
||||
{
|
||||
$this->request->setHost('api.weixin.qq.com');
|
||||
$this->request->setErrorField('errcode');
|
||||
|
||||
@@ -53,10 +53,10 @@ class NewsManager extends AfficialAccount
|
||||
* <li>将消息密文和安全签名打包成xml格式</li>
|
||||
* </ol>
|
||||
*
|
||||
* @param $replyMsg string 公众平台待回复用户的消息,xml格式的字符串
|
||||
* @param $timeStamp string 时间戳,可以自己生成,也可以用URL参数的timestamp
|
||||
* @param $nonce string 随机串,可以自己生成,也可以用URL参数的nonce
|
||||
* @param &$encryptMsg string 加密后的可以直接回复用户的密文,包括msg_signature, timestamp, nonce, encrypt的xml格式的字符串,
|
||||
* @param $replyMsg 公众平台待回复用户的消息,xml格式的字符串
|
||||
* @param $timeStamp 时间戳,可以自己生成,也可以用URL参数的timestamp
|
||||
* @param $nonce 随机串,可以自己生成,也可以用URL参数的nonce
|
||||
* @param &$encryptMsg 加密后的可以直接回复用户的密文,包括msg_signature, timestamp, nonce, encrypt的xml格式的字符串,
|
||||
* 当return返回0时有效
|
||||
*
|
||||
* @return int 成功0,失败返回对应的错误码
|
||||
@@ -100,11 +100,11 @@ class NewsManager extends AfficialAccount
|
||||
* <li>对消息进行解密</li>
|
||||
* </ol>
|
||||
*
|
||||
* @param $msgSignature string 签名串,对应URL参数的msg_signature
|
||||
* @param $timestamp string 时间戳 对应URL参数的timestamp
|
||||
* @param $nonce string 随机串,对应URL参数的nonce
|
||||
* @param $postData string 密文,对应POST请求的数据
|
||||
* @param &$msg string 解密后的原文,当return返回0时有效
|
||||
* @param $msgSignature 签名串,对应URL参数的msg_signature
|
||||
* @param $timestamp 时间戳 对应URL参数的timestamp
|
||||
* @param $nonce 随机串,对应URL参数的nonce
|
||||
* @param $postData 密文,对应POST请求的数据
|
||||
* @param &$msg 解密后的原文,当return返回0时有效
|
||||
*
|
||||
* @return int 成功0,失败返回对应的错误码
|
||||
*/
|
||||
|
||||
@@ -20,41 +20,41 @@ class Subscribe extends AfficialAccount
|
||||
private $pushUrl = 'https://api.weixin.qq.com/cgi-bin/message/template/subscribe?access_token=';
|
||||
|
||||
/**
|
||||
* @param string $openid
|
||||
* @param $openid
|
||||
* @return Subscribe
|
||||
*/
|
||||
public function setOpenid(string $openid): Subscribe
|
||||
public function setOpenid($openid): Subscribe
|
||||
{
|
||||
$this->openid = $openid;
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param string $template_id
|
||||
* @param $template_id
|
||||
* @return Subscribe
|
||||
*/
|
||||
public function setTemplateId(string $template_id): Subscribe
|
||||
public function setTemplateId($template_id): Subscribe
|
||||
{
|
||||
$this->template_id = $template_id;
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param string $url
|
||||
* @param $url
|
||||
* @return Subscribe
|
||||
*/
|
||||
public function setUrl(string $url): Subscribe
|
||||
public function setUrl($url): Subscribe
|
||||
{
|
||||
$this->url = $url;
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param string $appid
|
||||
* @param string $path
|
||||
* @param $appid
|
||||
* @param $path
|
||||
* @return Subscribe
|
||||
*/
|
||||
public function setMiniprogram(string $appid, string $path): Subscribe
|
||||
public function setMiniprogram($appid, $path): Subscribe
|
||||
{
|
||||
$this->miniprogram['appid'] = $appid;
|
||||
$this->miniprogram['pagepath'] = $path;
|
||||
@@ -62,20 +62,20 @@ class Subscribe extends AfficialAccount
|
||||
}
|
||||
|
||||
/**
|
||||
* @param string $scene
|
||||
* @param $scene
|
||||
* @return Subscribe
|
||||
*/
|
||||
public function setScene(string $scene): Subscribe
|
||||
public function setScene($scene): Subscribe
|
||||
{
|
||||
$this->scene = $scene;
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param string $title
|
||||
* @param $title
|
||||
* @return Subscribe
|
||||
*/
|
||||
public function setTitle(string $title): Subscribe
|
||||
public function setTitle($title): Subscribe
|
||||
{
|
||||
$this->title = $title;
|
||||
return $this;
|
||||
|
||||
@@ -102,7 +102,7 @@ class Prpcrypt
|
||||
|
||||
/**
|
||||
* 随机生成16位字符串
|
||||
* @return string 生成的字符串
|
||||
* @return 生成的字符串
|
||||
*/
|
||||
function getRandomStr()
|
||||
{
|
||||
|
||||
@@ -10,7 +10,7 @@ class XMLParse
|
||||
{
|
||||
/**
|
||||
* 提取出xml数据包中的加密消息
|
||||
* @param string $xmltext 待提取的xml字符串
|
||||
* @param $xmltext 待提取的xml字符串
|
||||
* @return array 提取出的加密消息字符串
|
||||
*/
|
||||
public function extract($xmltext)
|
||||
|
||||
Reference in New Issue
Block a user