|
|
|
@ -9,11 +9,12 @@ package siprp.ficha;
|
|
|
|
import java.awt.*;
|
|
|
|
import java.awt.*;
|
|
|
|
import javax.swing.*;
|
|
|
|
import javax.swing.*;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
import com.evolute.utils.ui.window.*;
|
|
|
|
/**
|
|
|
|
/**
|
|
|
|
*
|
|
|
|
*
|
|
|
|
* @author fpalma
|
|
|
|
* @author fpalma
|
|
|
|
*/
|
|
|
|
*/
|
|
|
|
public class FichaWindow extends JFrame
|
|
|
|
public class FichaWindow extends TabbedWindow
|
|
|
|
{
|
|
|
|
{
|
|
|
|
private UpperPanel upperPanel;
|
|
|
|
private UpperPanel upperPanel;
|
|
|
|
private EmpresaPanel empresaPanel;
|
|
|
|
private EmpresaPanel empresaPanel;
|
|
|
|
@ -22,34 +23,44 @@ public class FichaWindow extends JFrame
|
|
|
|
private ExamePanel examePanel;
|
|
|
|
private ExamePanel examePanel;
|
|
|
|
private RecomendacoesPanel recomendacoesPanel;
|
|
|
|
private RecomendacoesPanel recomendacoesPanel;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
private static int permissions[][] =
|
|
|
|
|
|
|
|
new int[][]{ { NEW_INDEX, CANCEL_INDEX, SAVE_INDEX, DELETE_INDEX, SELECT_BYNAME_INDEX } };
|
|
|
|
|
|
|
|
|
|
|
|
/** Creates a new instance of FichaWindow */
|
|
|
|
/** Creates a new instance of FichaWindow */
|
|
|
|
public FichaWindow()
|
|
|
|
public FichaWindow()
|
|
|
|
|
|
|
|
throws Exception
|
|
|
|
{
|
|
|
|
{
|
|
|
|
|
|
|
|
super( new UpperPanel(), new String[]{ "Empresa/Trabalhador", "Exame" },
|
|
|
|
|
|
|
|
createPermissions( permissions ) );
|
|
|
|
|
|
|
|
upperPanel = (UpperPanel) getUpperPanel();
|
|
|
|
setupComponents();
|
|
|
|
setupComponents();
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
private void setupComponents()
|
|
|
|
private void setupComponents()
|
|
|
|
{
|
|
|
|
{
|
|
|
|
setSize( 700, 550 );
|
|
|
|
setSize( 700, 570 );
|
|
|
|
setResizable( false );
|
|
|
|
setResizable( false );
|
|
|
|
setTitle( "Ficha de Aptid\u00e3o" );
|
|
|
|
setTitle( "Ficha de Aptid\u00e3o" );
|
|
|
|
|
|
|
|
|
|
|
|
upperPanel = new UpperPanel();
|
|
|
|
// upperPanel = new UpperPanel();
|
|
|
|
JTabbedPane tabbed = new JTabbedPane();
|
|
|
|
// JTabbedPane tabbed = new JTabbedPane();
|
|
|
|
getContentPane().setLayout( new BorderLayout() );
|
|
|
|
// getContentPane().setLayout( new BorderLayout() );
|
|
|
|
getContentPane().add( upperPanel, BorderLayout.NORTH );
|
|
|
|
// getContentPane().add( upperPanel, BorderLayout.NORTH );
|
|
|
|
getContentPane().add( tabbed, BorderLayout.CENTER );
|
|
|
|
// getContentPane().add( tabbed, BorderLayout.CENTER );
|
|
|
|
|
|
|
|
//
|
|
|
|
JPanel empresaTrabalhadorPanel = new JPanel();
|
|
|
|
// JPanel empresaTrabalhadorPanel = new JPanel();
|
|
|
|
JPanel exameRecomendacoesPanel = new JPanel();
|
|
|
|
// JPanel exameRecomendacoesPanel = new JPanel();
|
|
|
|
|
|
|
|
//
|
|
|
|
tabbed.add( "Empresa/Trabalhador", empresaTrabalhadorPanel );
|
|
|
|
// tabbed.add( "Empresa/Trabalhador", empresaTrabalhadorPanel );
|
|
|
|
tabbed.add( "Exame", exameRecomendacoesPanel );
|
|
|
|
// tabbed.add( "Exame", exameRecomendacoesPanel );
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
JPanel empresaTrabalhadorPanel = getTab( 0 );
|
|
|
|
|
|
|
|
JPanel exameRecomendacoesPanel = getTab( 1 );
|
|
|
|
|
|
|
|
|
|
|
|
GridBagLayout gridbag = new GridBagLayout();
|
|
|
|
GridBagLayout gridbag = new GridBagLayout();
|
|
|
|
empresaTrabalhadorPanel.setLayout( gridbag );
|
|
|
|
empresaTrabalhadorPanel.setLayout( gridbag );
|
|
|
|
GridBagConstraints constraints = new GridBagConstraints();
|
|
|
|
GridBagConstraints constraints = new GridBagConstraints();
|
|
|
|
constraints.insets = new Insets( 1, 1, 1, 1 );
|
|
|
|
constraints.insets = new Insets( 0, 1, 0, 1 );
|
|
|
|
constraints.fill = GridBagConstraints.BOTH;
|
|
|
|
constraints.fill = GridBagConstraints.BOTH;
|
|
|
|
constraints.weightx = 1;
|
|
|
|
constraints.weightx = 1;
|
|
|
|
constraints.gridwidth = GridBagConstraints.REMAINDER;
|
|
|
|
constraints.gridwidth = GridBagConstraints.REMAINDER;
|
|
|
|
@ -74,7 +85,7 @@ public class FichaWindow extends JFrame
|
|
|
|
gridbag = new GridBagLayout();
|
|
|
|
gridbag = new GridBagLayout();
|
|
|
|
exameRecomendacoesPanel.setLayout( gridbag );
|
|
|
|
exameRecomendacoesPanel.setLayout( gridbag );
|
|
|
|
constraints = new GridBagConstraints();
|
|
|
|
constraints = new GridBagConstraints();
|
|
|
|
constraints.insets = new Insets( 1, 1, 1, 1 );
|
|
|
|
constraints.insets = new Insets( 0, 1, 0, 1 );
|
|
|
|
constraints.fill = GridBagConstraints.BOTH;
|
|
|
|
constraints.fill = GridBagConstraints.BOTH;
|
|
|
|
constraints.weightx = 1;
|
|
|
|
constraints.weightx = 1;
|
|
|
|
constraints.gridwidth = GridBagConstraints.REMAINDER;
|
|
|
|
constraints.gridwidth = GridBagConstraints.REMAINDER;
|
|
|
|
|