Search in sources :

Example 1 with ProcessInstanceListView

use of com.centurylink.mdw.plugin.designer.views.ProcessInstanceListView in project mdw-designer by CenturyLinkCloud.

the class WorkflowElementActionHandler method showInstances.

public void showInstances(WorkflowElement element) {
    if (element instanceof WorkflowProject) {
        // TODO myTasks is hardcoded
        WorkflowProject project = (WorkflowProject) element;
        try {
            IViewPart viewPart = getPage().showView("mdw.views.designer.list.myTasks");
            if (viewPart != null) {
                MyTasksView myTasksView = (MyTasksView) viewPart;
                myTasksView.setProject(project);
                myTasksView.refreshTable();
            }
        } catch (PartInitException ex) {
            PluginMessages.log(ex);
        }
    } else if (element instanceof WorkflowProcess) {
        try {
            IViewPart viewPart = getPage().showView("mdw.views.designer.process.instance.list");
            if (viewPart != null) {
                ProcessInstanceListView instancesView = (ProcessInstanceListView) viewPart;
                instancesView.setProcess((WorkflowProcess) element);
            }
        } catch (PartInitException ex) {
            PluginMessages.log(ex);
        }
    }
}
Also used : MyTasksView(com.centurylink.mdw.plugin.designer.views.MyTasksView) IViewPart(org.eclipse.ui.IViewPart) ProcessInstanceListView(com.centurylink.mdw.plugin.designer.views.ProcessInstanceListView) WorkflowProject(com.centurylink.mdw.plugin.project.model.WorkflowProject) PartInitException(org.eclipse.ui.PartInitException) WorkflowProcess(com.centurylink.mdw.plugin.designer.model.WorkflowProcess)

Example 2 with ProcessInstanceListView

use of com.centurylink.mdw.plugin.designer.views.ProcessInstanceListView in project mdw-designer by CenturyLinkCloud.

the class ProcessEditor method showInstances.

public void showInstances() {
    try {
        IViewPart viewPart = getSite().getPage().showView("mdw.views.designer.process.instance.list");
        if (viewPart != null) {
            ProcessInstanceListView instancesView = (ProcessInstanceListView) viewPart;
            instancesView.setProcess(getProcess());
        }
    } catch (PartInitException ex) {
        PluginMessages.log(ex);
    }
}
Also used : IViewPart(org.eclipse.ui.IViewPart) ProcessInstanceListView(com.centurylink.mdw.plugin.designer.views.ProcessInstanceListView) PartInitException(org.eclipse.ui.PartInitException)

Aggregations

ProcessInstanceListView (com.centurylink.mdw.plugin.designer.views.ProcessInstanceListView)2 IViewPart (org.eclipse.ui.IViewPart)2 PartInitException (org.eclipse.ui.PartInitException)2 WorkflowProcess (com.centurylink.mdw.plugin.designer.model.WorkflowProcess)1 MyTasksView (com.centurylink.mdw.plugin.designer.views.MyTasksView)1 WorkflowProject (com.centurylink.mdw.plugin.project.model.WorkflowProject)1