Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
W
wxh_internal_api
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
杨培培
wxh_internal_api
Commits
eb7bdd66
Commit
eb7bdd66
authored
Mar 21, 2019
by
杨培
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
论坛增加关注接口
parent
ed3f6baa
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
6 additions
and
4 deletions
+6
-4
bbs_test.php
example/bbs_test.php
+4
-3
User.php
src/bbs/User.php
+2
-1
No files found.
example/bbs_test.php
View file @
eb7bdd66
...
@@ -10,6 +10,7 @@ use internalApi\bbs\User;
...
@@ -10,6 +10,7 @@ use internalApi\bbs\User;
require
__DIR__
.
'/_init.php'
;
require
__DIR__
.
'/_init.php'
;
\internalApi\bbs\Test
::
setDebug
(
true
);
User
::
setDebug
();
$data
=
\internalApi\bbs\Test
::
index
(
'123123'
);
User
::
follow
(
12
,
31
,
true
);
print_r
(
$data
);
\ No newline at end of file
//print_r($data);
\ No newline at end of file
src/bbs/User.php
View file @
eb7bdd66
...
@@ -108,11 +108,12 @@ class User extends Client
...
@@ -108,11 +108,12 @@ class User extends Client
* @param bool $silent 是否静默关注,是则不会发送消息提示,默认否
* @param bool $silent 是否静默关注,是则不会发送消息提示,默认否
* @return void
* @return void
* @throws \internalApi\base\ApiException
* @throws \internalApi\base\ApiException
* 异常code:1 代表不能关注自己,2 代表不能关注此人,3 代表已经关注了,其它 code 为异常情况
* @throws \internalApi\base\ClientException
* @throws \internalApi\base\ClientException
*/
*/
public
static
function
follow
(
$uid
,
$followUid
,
$silent
=
false
)
public
static
function
follow
(
$uid
,
$followUid
,
$silent
=
false
)
{
{
return
self
::
call
(
'user.follow'
,
compact
(
'uid'
,
'followUid'
));
return
self
::
call
(
'user.follow'
,
compact
(
'uid'
,
'followUid'
,
'silent'
));
}
}
/**
/**
...
...
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