![]() |
Ryzom Account Management System
1.0
|
user entry point in the ticket system. More...
Public Member Functions | |
| __construct () | |
| A constructor. | |
| set ($values) | |
| sets the object's attributes. | |
| load_With_TUserId ($id) | |
| loads the object's attributes. | |
| update () | |
| update the object's attributes to the db. | |
| getPermission () | |
| get permission attribute of the object. | |
| getExternId () | |
| get externId attribute of the object. | |
| getTUserId () | |
| get tUserId attribute of the object. | |
| setPermission ($perm) | |
| set permission attribute of the object. | |
| setExternId ($id) | |
| set externId attribute of the object. | |
| setTUserId ($id) | |
| set tUserId attribute of the object. | |
Static Public Member Functions | |
| static | createTicketUser ($extern_id, $permission) |
| create a new ticket user. | |
| static | isMod ($user) |
| check if a ticket_user object is a mod or not. | |
| static | isAdmin ($user) |
| check if a ticket_user object is an admin or not. | |
| static | constr_TUserId ($id) |
| return constructed ticket_user object based on TUserId. | |
| static | getModsAndAdmins () |
| return a list of all mods/admins. | |
| static | constr_ExternId ($id) |
| return constructed ticket_user object based on ExternId. | |
| static | change_permission ($user_id, $perm) |
| change the permission of a ticket_user. | |
| static | get_email_by_user_id ($id) |
| return the email address of a ticket_user. | |
| static | get_username_from_id ($id) |
| return the username of a ticket_user. | |
| static | get_id_from_username ($username) |
| return the TUserId of a ticket_user by giving a username. | |
| static | get_id_from_email ($email) |
| return the ticket_user id from an email address. | |
Private Attributes | |
| $tUserId | |
| The id of the user inside the ticket system. | |
| $permission | |
| The permission of the user. | |
| $externId | |
| The id of the user account in the www (could be drupal,...) that is linked to the ticket_user. | |
user entry point in the ticket system.
The ticket_user makes a link between the entire ticket system's lib db and the www user, which is stored in another db (this is the external ID). The externalID could be the ID of a drupal user or wordpress user,.. The ticket_user also stores the permission of that user, this way the permission system is inside the lib itself and can be used in any www version that you like. permission 1 = user, 2 = mod, 3 = admin.
| __construct | ( | ) |
A constructor.
Empty constructor
| static change_permission | ( | $ | user_id, |
| $ | perm | ||
| ) | [static] |
change the permission of a ticket_user.
| $user_id | the TUserId of the entry. |
| $perm | the new permission value. |
| static constr_ExternId | ( | $ | id | ) | [static] |
return constructed ticket_user object based on ExternId.
| $id | the ExternId of the entry. |
| static constr_TUserId | ( | $ | id | ) | [static] |
return constructed ticket_user object based on TUserId.
| $id | the TUserId of the entry. |
| static createTicketUser | ( | $ | extern_id, |
| $ | permission | ||
| ) | [static] |
create a new ticket user.
| $extern_id | the id of the user account in the www version (drupal,...) |
| $permission | the permission that will be given to the user. 1=user, 2=mod, 3=admin |
| static get_email_by_user_id | ( | $ | id | ) | [static] |
return the email address of a ticket_user.
| $id | the TUserId of the entry. |
| static get_id_from_email | ( | $ | ) | [static] |
return the ticket_user id from an email address.
| the emailaddress of a user. |
| static get_id_from_username | ( | $ | username | ) | [static] |
return the TUserId of a ticket_user by giving a username.
| $username | the username of a user. |
| static get_username_from_id | ( | $ | id | ) | [static] |
return the username of a ticket_user.
| $id | the TUserId of the entry. |
| getExternId | ( | ) |
get externId attribute of the object.
| static getModsAndAdmins | ( | ) | [static] |
return a list of all mods/admins.
| getPermission | ( | ) |
get permission attribute of the object.
| getTUserId | ( | ) |
get tUserId attribute of the object.
| static isAdmin | ( | $ | user | ) | [static] |
check if a ticket_user object is an admin or not.
| $user | the ticket_user object itself |
| static isMod | ( | $ | user | ) | [static] |
check if a ticket_user object is a mod or not.
| $user | the ticket_user object itself |
| load_With_TUserId | ( | $ | id | ) |
loads the object's attributes.
loads the object's attributes by giving a TUserId.
| $id | the id of the ticket_user that should be loaded |
| set | ( | $ | values | ) |
sets the object's attributes.
| $values | should be an array of the form array('TUserId' => id, 'Permission' => perm, 'ExternId' => ext_id). |
| setExternId | ( | $ | id | ) |
set externId attribute of the object.
| $id | the external id. |
| setPermission | ( | $ | perm | ) |
set permission attribute of the object.
| $perm | integer that indicates the permission level. (1= user, 2= mod, 3= admin) |
| setTUserId | ( | $ | id | ) |
set tUserId attribute of the object.
| $id | the ticket_user id |
| update | ( | ) |
update the object's attributes to the db.
$externId [private] |
The id of the user account in the www (could be drupal,...) that is linked to the ticket_user.
$permission [private] |
The permission of the user.
$tUserId [private] |
The id of the user inside the ticket system.
1.7.6.1