This article covers manipulating Tickets in your activeCollab setup using the API Wrapper.
object ActiveCollab::findTicketById(int $project_id, int $ticket_id) - Fetches an ActiveCollabTicket object
Parameters:
project_id - id of the Project which contains the Ticket ticket_id - id of a specific Ticket
Return value: Object instance of ActiveCollabTicket
object $ticket = new ActiveCollabTicket(int $project_id) - Creates a new ActiveCollabTicket object
Parameters:
project_id - id of the Project in which the Ticket will be created
Variable value: Object instance of ActiveCollabTicket
These methods are called out through an ticket object.
• setCreatedByEmail(string $email) - Sets an email of the user who created this ticket
• setCreatedByName(string $name) - Sets the name of the user who created this ticket
• setName(string $name) - Sets the name of this ticket
• setBody(string $body) - Sets the description of this ticket
• setPriority(int $priority) - Sets the priority of this ticket; the priority parameter can be a combination of the following constants: ACTIVECOLLAB_PRIORITY_LOWEST, ACTIVECOLLAB_PRIORITY_LOW, ACTIVECOLLAB_PRIORITY_NORMAL, ACTIVECOLLAB_PRIORITY_HIGH, ACTIVECOLLAB_PRIORITY_HIGHEST
• setTags(array of string $tagArr) - Sets tags for this ticket
• setVisibility(int $visibility) - Sets the visibility of this ticket; the visibility parameter can be a combination of the following constants: ACTIVECOLLAB_VISIBILITY_PRIVATE, ACTIVECOLLAB_VISIBILITY_NORMAL
• setDueOn(timestamp $date) - Sets the date when the ticket is due
• setParentId(int $parent_id) - Sets the parent for this ticket
• setMilestoneId(int $milestone_id) - Sets the milestone for this ticket
• setAssignees(array of int $assignees, int $responsible_person) - Sets assignees and responsible person for this ticket
• addAttachments(array of file $arr_files) - Adds array of files to a ticket
• save(void) - Saves the ticket object into activeCollab