All Downloads are FREE. Search and download functionalities are using the official Maven repository.

web.task.index.jsp Maven / Gradle / Ivy

There is a newer version: 4.7.219
Show newest version

<%@ page import="org.apache.synapse.task.TaskDescription" %>
<%@ page import="org.wso2.carbon.task.ui.internal.TaskClientConstants" %>
<%@ page import="org.wso2.carbon.task.ui.internal.TaskManagementClient" %>
<%@ page import="java.util.List" %>
<%@ page import="org.wso2.carbon.CarbonConstants" %>
<%@ page import="java.util.Collections" %>
<%@ page import="java.util.Comparator" %>
<%@ page import="org.wso2.carbon.task.stub.types.carbon.TaskData" %>
<%@ page import="org.owasp.encoder.Encode" %>
<%@ taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt" %>
<%@ taglib uri="http://wso2.org/projects/carbon/taglibs/carbontags.jar" prefix="carbon" %>

<%
    boolean disableAddTask = new Boolean((String) config.getServletContext().getAttribute(
            CarbonConstants.PRODUCT_XML_WSO2CARBON + TaskClientConstants.DISABLE_ADD_TASK));
%>






    
    

    

<% TaskManagementClient client; TaskData[] data = null; try { client = TaskManagementClient.getInstance(config, session); List descriptions = client.getAllTaskDescriptions(); data = client.getAllTaskData(); if (descriptions != null && !descriptions.isEmpty()) { %>


<% Collections.sort(descriptions, new Comparator() { public int compare(TaskDescription a, TaskDescription b) { return a.getName().compareTo(b.getName()); } }); if (data != null) { for (TaskData taskData : data) { if (taskData != null) { String name = taskData.getName(); String group = taskData.getGroup(); %> <% if (taskData.getArtifactContainerName() != null) { %> <% } else { %> <% } %> <% } } } %>
<% if (taskData.getArtifactContainerName() != null) { %> <%=Encode.forHtmlContent(name)%> <% if (taskData.getIsEdited()) { %> ( Edited )<% } %> <% } else { %> <%=Encode.forHtmlContent(name)%> <% } %>
<%} else {%>


<%}%> <% if(!disableAddTask) { %>
<% } %> <% } catch (Throwable e) { request.getSession().setAttribute(TaskClientConstants.EXCEPTION, e); %> <% } %>




© 2015 - 2025 Weber Informatics LLC | Privacy Policy