Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
Documentation
Project
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
Rachael Hu
Documentation
Commits
5c93dac0
Commit
5c93dac0
authored
Mar 31, 2016
by
Tom Laudeman
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Clarify roles, make prose more consistent
parent
232a6e88
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
18 additions
and
0 deletions
+18
-0
DBUser API.md
Requirements/DBUser API.md
+18
-0
No files found.
Requirements/DBUser API.md
View file @
5c93dac0
...
@@ -190,40 +190,58 @@ createUser(snac\data\User $user)
...
@@ -190,40 +190,58 @@ createUser(snac\data\User $user)
Add a user record. Minimal requirements is user id or email (which ever is used to login). Return true for
Add a user record. Minimal requirements is user id or email (which ever is used to login). Return true for
success.
success.
---
---
saveUser(snac
\d
ata
\U
ser $user)
saveUser(snac
\d
ata
\U
ser $user)
Update a user record. Verify that read-only fields match, overwrite everthing else with values from the User
Update a user record. Verify that read-only fields match, overwrite everthing else with values from the User
object. Return true for success.
object. Return true for success.
---
---
readUser($userID or $email)
readUser($userID or $email)
Return a User object for the user id or email. Return false on failure.
Return a User object for the user id or email. Return false on failure.
---
---
disableUser(snac
\d
ata
\U
ser $user)
disableUser(snac
\d
ata
\U
ser $user)
Disable log in to this account. Update table appuser.active to false. Return true on success.
Disable log in to this account. Update table appuser.active to false. Return true on success.
---
---
addUserRole(snac
\d
ata
\U
ser $user, $newRole)
addUserRole(snac
\d
ata
\U
ser $user, $newRole)
Add a role to the User via table appuser_role_link. Return true on success.
Add a role to the User via table appuser_role_link. Return true on success.
---
---
listRoles()
listRoles()
List all system roles. The simpliest form would be an associative list with keys: id, label, description.
List all system roles. The simpliest form would be an associative list with keys: id, label, description.
---
---
createRole($label, $description)
createRole($label, $description)
Create a new role with $label and $description. Return true on success.
Create a new role with $label and $description. Return true on success.
---
---
checkPassword(snac
\d
ata
\U
ser $user, $passwd)
checkPassword(snac
\d
ata
\U
ser $user, $passwd)
Check $passwd matches the password stored for snac
\d
ata
\U
ser. Return true on success.
Check $passwd matches the password stored for snac
\d
ata
\U
ser. Return true on success.
---
---
addSession(snac
\d
ata
\U
ser $user, $accessToken, $expire)
addSession(snac
\d
ata
\U
ser $user, $accessToken, $expire)
Add a new session token $accessToken with expiration time $expire for $user. Update if $accessToken exists.
Add a new session token $accessToken with expiration time $expire for $user. Update if $accessToken exists.
---
---
checkSessionActive(snac
\d
ata
\U
ser $user, $accessToken)
checkSessionActive(snac
\d
ata
\U
ser $user, $accessToken)
Check that a session is active (not expired) for $user and $accessToken. Time is assumed to be "now". Return
Check that a session is active (not expired) for $user and $accessToken. Time is assumed to be "now". Return
...
...
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