1 package org.enhydra.shark.swingclient.workflowadmin.application.actions; 2 3 import java.awt.event.*; 4 import javax.swing.*; 5 6 7 import org.enhydra.shark.swingclient.*; 8 import org.enhydra.shark.swingclient.workflowadmin.*; 9 import org.enhydra.shark.swingclient.workflowadmin.application.*; 10 11 17 public class RemoveApplicationMapping extends ActionBase { 18 19 public RemoveApplicationMapping (ApplicationMappingManagement pm) { 20 super(pm); 21 } 22 23 public void actionPerformed(ActionEvent e) { 24 ApplicationMappingManagement pm=(ApplicationMappingManagement)actionPanel; 25 SharkAdmin workflowAdmin=pm.getWorkflowAdmin(); 26 27 try { 28 String packageId=(String )pm.getExistingMappingsPanel().getColumnValueOfSelectedRow(0); 29 String processDefinitionId=(String )pm.getExistingMappingsPanel().getColumnValueOfSelectedRow(1); 30 String appId=(String )pm.getExistingMappingsPanel().getColumnValueOfSelectedRow(2); 31 32 SharkAdmin.getApplicationMappingsAdmin().removeApplicationMapping(packageId,processDefinitionId,appId); 33 } catch (Exception ex) { 34 JOptionPane.showMessageDialog(pm.getWindow(), 35 ResourceManager.getLanguageDependentString("MessageMappingCannotBeRemovedAtTheMoment"), 36 ResourceManager.getLanguageDependentString("WorkflowAdminTitle"), 37 JOptionPane.INFORMATION_MESSAGE); 38 return; 39 } 40 pm.refresh(true); 41 } 42 43 } 44 | Popular Tags |