Search in sources :

Example 1 with DeleteTaskClickListener

use of org.activiti.explorer.ui.process.simple.editor.listener.DeleteTaskClickListener in project Activiti by Activiti.

the class TaskTable method generateActionButtons.

protected HorizontalLayout generateActionButtons(Object taskItemId) {
    HorizontalLayout actionButtons = new HorizontalLayout();
    FormDefinition form = taskFormModel.getForm(taskItemId);
    Button formButton = new Button(form == null ? i18nManager.getMessage(Messages.PROCESS_EDITOR_TASK_FORM_CREATE) : i18nManager.getMessage(Messages.PROCESS_EDITOR_TASK_FORM_EDIT));
    formButton.addListener(new ShowFormClickListener(taskFormModel, taskItemId));
    formButton.setData(taskItemId);
    actionButtons.addComponent(formButton);
    Button deleteTaskButton = new Button("-");
    deleteTaskButton.setData(taskItemId);
    deleteTaskButton.addListener(new DeleteTaskClickListener(this));
    actionButtons.addComponent(deleteTaskButton);
    Button addTaskButton = new Button("+");
    addTaskButton.setData(taskItemId);
    addTaskButton.addListener(new AddTaskClickListener(this));
    actionButtons.addComponent(addTaskButton);
    return actionButtons;
}
Also used : ShowFormClickListener(org.activiti.explorer.ui.process.simple.editor.listener.ShowFormClickListener) Button(com.vaadin.ui.Button) DeleteTaskClickListener(org.activiti.explorer.ui.process.simple.editor.listener.DeleteTaskClickListener) FormDefinition(org.activiti.workflow.simple.definition.form.FormDefinition) HorizontalLayout(com.vaadin.ui.HorizontalLayout) AddTaskClickListener(org.activiti.explorer.ui.process.simple.editor.listener.AddTaskClickListener)

Aggregations

Button (com.vaadin.ui.Button)1 HorizontalLayout (com.vaadin.ui.HorizontalLayout)1 AddTaskClickListener (org.activiti.explorer.ui.process.simple.editor.listener.AddTaskClickListener)1 DeleteTaskClickListener (org.activiti.explorer.ui.process.simple.editor.listener.DeleteTaskClickListener)1 ShowFormClickListener (org.activiti.explorer.ui.process.simple.editor.listener.ShowFormClickListener)1 FormDefinition (org.activiti.workflow.simple.definition.form.FormDefinition)1