Ivan - Update model documentations.

This commit is contained in:
ivan 2017-05-11 16:37:03 -03:00
parent cb0cb7e16a
commit 145b73b3c8
13 changed files with 39 additions and 27 deletions

View File

@ -1,6 +1,7 @@
<?php
/**
* @api {OBJECT} APIKey APIKey
* @apiVersion 4.0.0
* @apiGroup Data Structures
* @apiParam {String} name Name of the APIKey.
* @apiParam {String} token Token of the APIKey.

View File

@ -1,6 +1,7 @@
<?php
/**
* @api {OBJECT} Article Article
* @apiVersion 4.0.0
* @apiGroup Data Structures
* @apiParam {Number} id Id of the article.
* @apiParam {String} title Title of the article.

View File

@ -1,8 +1,9 @@
<?php
/**
* @api {OBJECT} Article Article
* @api {OBJECT} Ban Ban
* @apiVersion 4.0.0
* @apiGroup Data Structures
* @apiParam {Email} email Email of the user banned.
* @apiParam {Email} email The email address that is banned.
*/
class Ban extends DataStore {

View File

@ -1,6 +1,7 @@
<?php
/**
* @api {OBJECT} CustomResponse CustomResponse
* @apiVersion 4.0.0
* @apiGroup Data Structures
* @apiParam {Number} id Id of the custom response.
* @apiParam {String} content Content of the custom response.

View File

@ -3,10 +3,11 @@ use RedBeanPHP\Facade as RedBean;
/**
* @api {OBJECT} Department Department
* @apiVersion 4.0.0
* @apiGroup Data Structures
* @apiParam {Number} id Id of the custom response.
* @apiParam {String} name Name of the custom response.
* @apiParam {[Staff](#api-Data_Structures-ObjectStaff)[]} owners Owners of the department.
* @apiParam {Number} id Id of the department.
* @apiParam {String} name Name of the department.
* @apiParam {[Staff](#api-Data_Structures-ObjectStaff)[]} owners List of owners of the department.
*/
class Department extends DataStore {

View File

@ -2,14 +2,15 @@
use RedBeanPHP\Facade as RedBean;
/**
* @api {OBJECT} Log Log
* @apiVersion 4.0.0
* @apiGroup Data Structures
* @apiParam {String} type The type of the log.
* @apiParam {String} to Destinatary of the log.
* @apiParam {String} to Object where the action was performed.
* @apiParam {Object} author Author of the log.
* @apiParam {String} author.name Name of the author.
* @apiParam {Number} author.id Id of the author.
* @apiParam {Boolean} author.staff Kind of author.
* @apiParam {String} date Date of creation of the log.
* @apiParam {Boolean} author.staff Indicates if the author is a staff.
* @apiParam {String} date Date of the log creation.
*/
class Log extends DataStore {

View File

@ -3,6 +3,7 @@ use RedBeanPHP\Facade as RedBean;
/**
* @api {OBJECT} MailTemplate MailTemplate
* @apiVersion 4.0.0
* @apiGroup Data Structures
* @apiParam {String} type The type of the mail template.
* @apiParam {String} subject The subject of the mail template.

View File

@ -1,15 +1,15 @@
<?php
/**
* @api {OBJECT} Staff Staff
* @apiVersion 4.0.0
* @apiGroup Data Structures
* @apiParam {Number} id The type of the mail template.
* @apiParam {String} name The subject of the mail template.
* @apiParam {String} email The language of the mail template.
* @apiParam {String} profilePic The body of the mail template.
* @apiParam {Number} level The language of the mail template.
* @apiParam {Object[]} departments The departments of the staff.
* @apiParam {[Ticket](#api-Data_Structures-ObjectTicket)[]} tickets The tickets of the staff.
* @apiParam {Number} lastLogin The last login of the staff.
* @apiParam {String} name Name of the staff member.
* @apiParam {String} email Email of the staff member.
* @apiParam {String} profilePic profilePic url of the staff member.
* @apiParam {Number} level Level of the staff member.
* @apiParam {Object[]} departments The departments the staff member has assigned.
* @apiParam {[Ticket](#api-Data_Structures-ObjectTicket)[]} tickets The tickets the staff member has assigned.
* @apiParam {Number} lastLogin The last login of the staff member.
*/
class Staff extends DataStore {

View File

@ -1,10 +1,11 @@
<?php
/**
* @api {OBJECT} Stat Stat
* @apiVersion 4.0.0
* @apiGroup Data Structures
* @apiParam {Number} date The date of the stat.
* @apiParam {String} type The type of the stat.
* @apiParam {Boolean} general The general of the stat.
* @apiParam {Number} date The date of the stat as a number in format YYYYMMDD.
* @apiParam {String} type The type of the stat. It can be CREATE_TICKET, CLOSE, SIGNUP, COMMENT, ASSIGN or UNASSIGN
* @apiParam {Boolean} general Indicates if the stat is from the general system or from a particular ticket.
* @apiParam {String} value The value of the stat.
*/

View File

@ -1,6 +1,7 @@
<?php
/**
* @api {OBJECT} Ticket Ticket
* @apiVersion 4.0.0
* @apiGroup Data Structures
* @apiParam {Number} ticketNumber The number of the ticket.
* @apiParam {String} title The title of the ticket.
@ -8,12 +9,12 @@
* @apiParam {Object} department The department of the ticket.
* @apiParam {Number} department.id The id of the department of the ticket.
* @apiParam {String} department.name The department's name of the ticket.
* @apiParam {String} file The file of the ticket.
* @apiParam {String} file The filename of the ticket if attached.
* @apiParam {String} language The language of the ticket.
* @apiParam {Boolean} unread The boolean to know if the user already readed or not.
* @apiParam {Boolean} unreadStaff The boolean to know if the staff already readed or not.
* @apiParam {Boolean} closed The boolean to know if the ticket is already closed or not.
* @apiParam {String} priority The priority of the ticket.
* @apiParam {Boolean} unread Indicates if the user has already read the last comment.
* @apiParam {Boolean} unreadStaff Indicates if the staff has already read the last comment.
* @apiParam {Boolean} closed Indicates if the ticket is closed.
* @apiParam {String} priority The priority of the ticket. It can be LOW, MEDIUM or HIGH.
* @apiParam {Object} author The author of the ticket.
* @apiParam {Number} author.id The id of the author of the ticket.
* @apiParam {String} author.name The author's name of the ticket.

View File

@ -1,15 +1,16 @@
<?php
/**
* @api {OBJECT} TicketEvent TicketEvent
* @apiVersion 4.0.0
* @apiGroup Data Structures
* @apiParam {String} type The type of the ticket event.
* @apiParam {String} type The type of the ticket event. It can be COMMENT, ASSIGN, UN_ASSIGN, CLOSE, RE_OPEN, DEPARTMENT_CHANGED or PRIORITY_CHANGED
* @apiParam {String} content The content of the ticket event.
* @apiParam {Object} author The author of the ticket event.
* @apiParam {Number} author.id The author's id of the ticket event.
* @apiParam {String} author.name The author's name of the ticket event.
* @apiParam {String} author.email The author's email of the ticket event.
* @apiParam {String} author.profilePic The author's profilePic of the ticket event.
* @apiParam {Boolean} author.staff The boolean to know if the author is staff or not.
* @apiParam {Boolean} author.staff Indicates if the author is a staff.
* @apiParam {String} date The date of the ticket event.
* @apiParam {String} file The file of the ticket event.
*/

View File

@ -1,6 +1,7 @@
<?php
/**
* @api {OBJECT} Topic Topic
* @apiVersion 4.0.0
* @apiGroup Data Structures
* @apiParam {Number} id Id of the topic.
* @apiParam {String} name Name of the topic.

View File

@ -3,11 +3,12 @@ use RedBeanPHP\Facade as RedBean;
/**
* @api {OBJECT} User User
* @apiVersion 4.0.0
* @apiGroup Data Structures
* @apiParam {String} email The email of the user.
* @apiParam {Number} id The id of the user.
* @apiParam {String} name The name of the user.
* @apiParam {Boolean} verified A boolean to know if the user is already verified or not.
* @apiParam {Boolean} verified Indicates if the user has verified the email.
*/
class User extends DataStore {