On this page, you’ll find some details on multiple options available to extend WATS functionnalities.
This plugin allows users to attach files through the ticket update form or the frontend submission form. Files uploaded will be attached to the user rather than the ticket.
This plugin will allow you to add a file uploader to the ticket update form. It is convenient if you want to allow your users to attach files to the tickets through the frontend.
With this plugin, the mail notifications will use an HTML template and have a very professional look.
This plugin displays a list of most recent tickets in a sidebar widget.
With this plugin, you can add a sidebar widget to allow your users to jump to a ticket by ID.
WordPress includes a very powerfull hooking system to allow smooth code extension. This is the same for WATS! You can easily modify few parts of WATS thanks to the hooks. You can learn more about hooks on WordPress official site.
All these hooks will allow you to completely customize the notifications sent out by WATS. The first hook is a filtering hook. It can be used to modify the content of the mail notification for ticket updates.
$output = apply_filters('wats_fire_ticket_update_notification_filter',$output,$postID);
Then you also have one filtering hook for the mail subject.
$subject = apply_filters('wats_fire_ticket_update_notification_title_filter',$subject,$postID);
You also have two filtering hooks available for the rule based notification.
$output = apply_filters('wats_fire_rules_notification_filter',$output,$postID); $subject = apply_filters('wats_fire_rules_notification_title_filter',$subject,$postID);
Then, you have two filtering hooks for the new ticket notification for admins.
$output = apply_filters('wats_fire_admin_notification_filter',$output,$postID); $subject = apply_filters('wats_fire_admin_notification_title_filter',$subject,$postID);
Saved ticket metas
This action hook is fired when ticket metas are saved (when a new ticket is submitted through the admin or an existing ticket is updated).
A similar action hook is fired for new ticket submitted through the frontend submission form.
These hooks are usefull if you want to perform a special action when ticket metas are saved (for instance, send a specific email if a specific value has been set).
Frontend submission form
This filter hook will allow you to tweak the frontend submission form.
$output_array = apply_filters('wats_ticket_submit_form_output_array',$output_array);
The output_array contains the code associated to each section of the frontend submission form. You can unset those that you don’t need or modify the code. Here are the array keys : user_details, ticket_metas, category, ticket_title, ticket_description.
Ticket access denied
You have two filter hooks that you can use to tweak the message displayed when someone tries to access a ticket and the access is rejected.
The first one is for unauthenticated users. By default, it will display the login form.
The second one is for logged in users if the access couldn’t be granted (usually because access is restricted to ticket author).
This filter hook can be used to modify the message displayed when updates aren’t possible on a ticket. Updates are usually not possible when a ticket is closed or if the user has read only access.
echo apply_filters('wats_get_ticket_update_rights_message_filter', wats_get_ticket_update_rights_message());