Class TicketUpdatesService

  • All Implemented Interfaces:
    org.exoplatform.services.rest.resource.ResourceContainer

    public class TicketUpdatesService
    extends Object
    implements org.exoplatform.services.rest.resource.ResourceContainer
    Created by eXo Platform SAS.
    Since:
    03/04/17
    Author:
    Ali Hamdi
    • Method Summary

      All Methods Static Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      javax.ws.rs.core.Response addCreator​(javax.servlet.http.HttpServletRequest request, javax.ws.rs.core.UriInfo uriInfo)  
      javax.ws.rs.core.Response addLogSpaces​(javax.servlet.http.HttpServletRequest request, javax.ws.rs.core.UriInfo uriInfo)  
      javax.ws.rs.core.Response addOpenLog​(javax.servlet.http.HttpServletRequest request, javax.ws.rs.core.UriInfo uriInfo)  
      javax.ws.rs.core.Response addOwner​(javax.servlet.http.HttpServletRequest request, javax.ws.rs.core.UriInfo uriInfo)  
      javax.ws.rs.core.Response cleanTFR​(javax.servlet.http.HttpServletRequest request, javax.ws.rs.core.UriInfo uriInfo)  
      javax.ws.rs.core.Response cleanTTR​(javax.servlet.http.HttpServletRequest request, javax.ws.rs.core.UriInfo uriInfo)  
      javax.ws.rs.core.Response getFirtTimeLogs​(javax.servlet.http.HttpServletRequest request, javax.ws.rs.core.UriInfo uriInfo, long startDate, long endDate)  
      javax.ws.rs.core.Response getLogs​(javax.ws.rs.core.UriInfo uriInfo, String newValue, String type)  
      javax.ws.rs.core.Response getResTimeLogs​(javax.servlet.http.HttpServletRequest request, javax.ws.rs.core.UriInfo uriInfo, long startDate, long endDate)  
      static <T> T getService​(Class<T> clazz, String containerName)  
      javax.ws.rs.core.Response getStats​(javax.ws.rs.core.UriInfo uriInfo, Boolean internal)  
      javax.ws.rs.core.Response getStatusTransitions​(javax.servlet.http.HttpServletRequest request, javax.ws.rs.core.UriInfo uriInfo)  
      javax.ws.rs.core.Response getTicketStat​(javax.servlet.http.HttpServletRequest request, javax.ws.rs.core.UriInfo uriInfo, String topic)  
      javax.ws.rs.core.Response getTimeLogs​(javax.servlet.http.HttpServletRequest request, javax.ws.rs.core.UriInfo uriInfo)  
      javax.ws.rs.core.Response getUpdates​(javax.ws.rs.core.UriInfo uriInfo, String from, String to)
      This endpoint will provide the lately updated tickets
      javax.ws.rs.core.Response setTimes​(javax.servlet.http.HttpServletRequest request, javax.ws.rs.core.UriInfo uriInfo)  
      javax.ws.rs.core.Response upadateWarning​(javax.servlet.http.HttpServletRequest request, javax.ws.rs.core.UriInfo uriInfo)  
      javax.ws.rs.core.Response upadatLogs​(javax.servlet.http.HttpServletRequest request, javax.ws.rs.core.UriInfo uriInfo)  
      javax.ws.rs.core.Response updateAssignee​(javax.servlet.http.HttpServletRequest request, javax.ws.rs.core.UriInfo uriInfo)  
      javax.ws.rs.core.Response updateLogsTimes​(javax.servlet.http.HttpServletRequest request, javax.ws.rs.core.UriInfo uriInfo)  
      javax.ws.rs.core.Response updatenav​(javax.servlet.http.HttpServletRequest request, javax.ws.rs.core.UriInfo uriInfo)  
      javax.ws.rs.core.Response updateTFR​(javax.servlet.http.HttpServletRequest request, javax.ws.rs.core.UriInfo uriInfo)  
      javax.ws.rs.core.Response updateTTR​(javax.servlet.http.HttpServletRequest request, javax.ws.rs.core.UriInfo uriInfo)  
    • Constructor Detail

      • TicketUpdatesService

        public TicketUpdatesService()
    • Method Detail

      • getUpdates

        @RolesAllowed("administrators")
        public javax.ws.rs.core.Response getUpdates​(@Context
                                                    javax.ws.rs.core.UriInfo uriInfo,
                                                    String from,
                                                    String to)
        This endpoint will provide the lately updated tickets
        Parameters:
        uriInfo - URI info
        from - Date to get updates from
        to - Date to get updates to
        Returns:
        Json array of updated tickets
      • getStats

        @RolesAllowed("administrators")
        public javax.ws.rs.core.Response getStats​(@Context
                                                  javax.ws.rs.core.UriInfo uriInfo,
                                                  Boolean internal)
      • getLogs

        @RolesAllowed("administrators")
        public javax.ws.rs.core.Response getLogs​(@Context
                                                 javax.ws.rs.core.UriInfo uriInfo,
                                                 String newValue,
                                                 String type)
      • getService

        public static <T> T getService​(Class<T> clazz,
                                       String containerName)
        Type Parameters:
        T - Type of class
        Parameters:
        clazz - service class
        containerName - portal container name
        Returns:
        the selected service
      • addCreator

        @RolesAllowed("administrators")
        public javax.ws.rs.core.Response addCreator​(@Context
                                                    javax.servlet.http.HttpServletRequest request,
                                                    @Context
                                                    javax.ws.rs.core.UriInfo uriInfo)
                                             throws Exception
        Throws:
        Exception
      • addOwner

        @RolesAllowed("administrators")
        public javax.ws.rs.core.Response addOwner​(@Context
                                                  javax.servlet.http.HttpServletRequest request,
                                                  @Context
                                                  javax.ws.rs.core.UriInfo uriInfo)
                                           throws Exception
        Throws:
        Exception
      • updateAssignee

        @RolesAllowed("administrators")
        public javax.ws.rs.core.Response updateAssignee​(@Context
                                                        javax.servlet.http.HttpServletRequest request,
                                                        @Context
                                                        javax.ws.rs.core.UriInfo uriInfo)
                                                 throws Exception
        Throws:
        Exception
      • upadateWarning

        @RolesAllowed("administrators")
        public javax.ws.rs.core.Response upadateWarning​(@Context
                                                        javax.servlet.http.HttpServletRequest request,
                                                        @Context
                                                        javax.ws.rs.core.UriInfo uriInfo)
                                                 throws Exception
        Throws:
        Exception
      • upadatLogs

        @RolesAllowed("administrators")
        public javax.ws.rs.core.Response upadatLogs​(@Context
                                                    javax.servlet.http.HttpServletRequest request,
                                                    @Context
                                                    javax.ws.rs.core.UriInfo uriInfo)
                                             throws Exception
        Throws:
        Exception
      • addLogSpaces

        @RolesAllowed("administrators")
        public javax.ws.rs.core.Response addLogSpaces​(@Context
                                                      javax.servlet.http.HttpServletRequest request,
                                                      @Context
                                                      javax.ws.rs.core.UriInfo uriInfo)
                                               throws Exception
        Throws:
        Exception
      • updatenav

        @RolesAllowed("administrators")
        public javax.ws.rs.core.Response updatenav​(@Context
                                                   javax.servlet.http.HttpServletRequest request,
                                                   @Context
                                                   javax.ws.rs.core.UriInfo uriInfo)
                                            throws Exception
        Throws:
        Exception
      • getFirtTimeLogs

        @RolesAllowed("administrators")
        public javax.ws.rs.core.Response getFirtTimeLogs​(@Context
                                                         javax.servlet.http.HttpServletRequest request,
                                                         @Context
                                                         javax.ws.rs.core.UriInfo uriInfo,
                                                         long startDate,
                                                         long endDate)
                                                  throws Exception
        Throws:
        Exception
      • getTicketStat

        @RolesAllowed("administrators")
        public javax.ws.rs.core.Response getTicketStat​(@Context
                                                       javax.servlet.http.HttpServletRequest request,
                                                       @Context
                                                       javax.ws.rs.core.UriInfo uriInfo,
                                                       String topic)
                                                throws Exception
        Throws:
        Exception
      • getResTimeLogs

        @RolesAllowed("administrators")
        public javax.ws.rs.core.Response getResTimeLogs​(@Context
                                                        javax.servlet.http.HttpServletRequest request,
                                                        @Context
                                                        javax.ws.rs.core.UriInfo uriInfo,
                                                        long startDate,
                                                        long endDate)
                                                 throws Exception
        Throws:
        Exception
      • getTimeLogs

        @RolesAllowed("administrators")
        public javax.ws.rs.core.Response getTimeLogs​(@Context
                                                     javax.servlet.http.HttpServletRequest request,
                                                     @Context
                                                     javax.ws.rs.core.UriInfo uriInfo)
                                              throws Exception
        Throws:
        Exception
      • updateTTR

        @RolesAllowed("administrators")
        public javax.ws.rs.core.Response updateTTR​(@Context
                                                   javax.servlet.http.HttpServletRequest request,
                                                   @Context
                                                   javax.ws.rs.core.UriInfo uriInfo)
                                            throws Exception
        Throws:
        Exception
      • cleanTTR

        @RolesAllowed("administrators")
        public javax.ws.rs.core.Response cleanTTR​(@Context
                                                  javax.servlet.http.HttpServletRequest request,
                                                  @Context
                                                  javax.ws.rs.core.UriInfo uriInfo)
                                           throws Exception
        Throws:
        Exception
      • updateTFR

        @RolesAllowed("administrators")
        public javax.ws.rs.core.Response updateTFR​(@Context
                                                   javax.servlet.http.HttpServletRequest request,
                                                   @Context
                                                   javax.ws.rs.core.UriInfo uriInfo)
                                            throws Exception
        Throws:
        Exception
      • cleanTFR

        @RolesAllowed("administrators")
        public javax.ws.rs.core.Response cleanTFR​(@Context
                                                  javax.servlet.http.HttpServletRequest request,
                                                  @Context
                                                  javax.ws.rs.core.UriInfo uriInfo)
                                           throws Exception
        Throws:
        Exception
      • getStatusTransitions

        @RolesAllowed("administrators")
        public javax.ws.rs.core.Response getStatusTransitions​(@Context
                                                              javax.servlet.http.HttpServletRequest request,
                                                              @Context
                                                              javax.ws.rs.core.UriInfo uriInfo)
                                                       throws Exception
        Throws:
        Exception
      • setTimes

        @RolesAllowed("administrators")
        public javax.ws.rs.core.Response setTimes​(@Context
                                                  javax.servlet.http.HttpServletRequest request,
                                                  @Context
                                                  javax.ws.rs.core.UriInfo uriInfo)
                                           throws Exception
        Throws:
        Exception
      • addOpenLog

        @RolesAllowed("administrators")
        public javax.ws.rs.core.Response addOpenLog​(@Context
                                                    javax.servlet.http.HttpServletRequest request,
                                                    @Context
                                                    javax.ws.rs.core.UriInfo uriInfo)
                                             throws Exception
        Throws:
        Exception
      • updateLogsTimes

        @RolesAllowed("administrators")
        public javax.ws.rs.core.Response updateLogsTimes​(@Context
                                                         javax.servlet.http.HttpServletRequest request,
                                                         @Context
                                                         javax.ws.rs.core.UriInfo uriInfo)
                                                  throws Exception
        Throws:
        Exception