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
785ccef5
Commit
785ccef5
authored
Aug 22, 2017
by
杨培
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
增加门户更新用户信息API
parent
866ca273
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
41 additions
and
6 deletions
+41
-6
xue_user.php
example/xue_user.php
+8
-6
client_config_dev.php
src/client_config_dev.php
+5
-0
User.php
src/portal/User.php
+28
-0
No files found.
example/xue_user.php
View file @
785ccef5
...
@@ -10,14 +10,16 @@ use internalApi\xue\User;
...
@@ -10,14 +10,16 @@ use internalApi\xue\User;
require
__DIR__
.
'/_init.php'
;
require
__DIR__
.
'/_init.php'
;
User
::
setDebug
(
true
);
//User::setDebug(true);
\internalApi\code\User
::
setDebug
();
//\internalApi\code\User::setDebug();
\internalApi\portal\User
::
setDebug
();
$uid
=
138
;
$uid
=
42
;
$data
=
[
$data
=
[
'nickname'
=>
'有名人士'
,
'nickname'
=>
'有名
\'
人士'
,
'avatar'
=>
'http://u.yunya.com/avatar?n='
.
urlencode
(
'世界'
)
.
'&s=m'
'avatar'
=>
'http://u.yunya.com/avatar?n='
.
urlencode
(
'世界'
)
.
'&s=m'
];
];
User
::
updateSync
(
$uid
,
$data
);
//User::updateSync($uid, $data);
\internalApi\code\User
::
updateSync
(
$uid
,
$data
);
//\internalApi\code\User::updateSync($uid, $data);
\internalApi\portal\User
::
updateSync
(
$uid
,
$data
);
src/client_config_dev.php
View file @
785ccef5
...
@@ -28,4 +28,9 @@ return [
...
@@ -28,4 +28,9 @@ return [
'clientId'
=>
'common'
,
'clientId'
=>
'common'
,
'clientSecret'
=>
'U2FsdGVkX19ZiutUoO6F'
'clientSecret'
=>
'U2FsdGVkX19ZiutUoO6F'
],
],
'portal'
=>
[
'apiUrl'
=>
'http://s.yunya.com/e/api/internal.php'
,
'clientId'
=>
'common'
,
'clientSecret'
=>
'TveYDczsq7LTllIUlM5t'
]
];
];
\ No newline at end of file
src/portal/User.php
0 → 100644
View file @
785ccef5
<?php
/**
* Created by PhpStorm.
* User: pader
* Date: 2017/8/22
* Time: 18:15
*/
namespace
internalApi\portal
;
use
internalApi\base\Client
;
class
User
extends
Client
{
/**
* 同步更新用户基本信息
*
* @param int $uid
* @param array $data
* @return bool
*/
public
static
function
updateSync
(
$uid
,
$data
)
{
return
self
::
call
(
'user.updateSync'
,
compact
(
'uid'
,
'data'
));
}
}
\ No newline at end of file
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