/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

/*
 * JfrmArqueoFinal.java
 *
 * Created on 09-ene-2010, 18:16:14
 */

package src;

import javax.swing.JFrame;

/**
 *
 * @author Carlos
 */
public class JfrmArqueoFinal extends javax.swing.JFrame {

    Arqueo a=new Arqueo();
    Sucursal auxsuc=new Sucursal();
    Empleado e=new Empleado();
    

    /** Creates new form JfrmArqueoFinal */
    public JfrmArqueoFinal(Sucursal suc) {
        initComponents();
        auxsuc=suc;
        setResizable(false); //ASI QUITAMOS QUE SE PUEDA MAXIMIZAR
    }
    /** This method is called from within the constructor to
     * initialize the form.
     * WARNING: Do NOT modify this code. The content of this method is
     * always regenerated by the Form Editor.
     */
    @SuppressWarnings("unchecked")
    // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
    private void initComponents() {

        jLabel2 = new javax.swing.JLabel();
        jtxtSaldofinal = new javax.swing.JTextField();
        jLabel3 = new javax.swing.JLabel();
        jLabel6 = new javax.swing.JLabel();
        jLabel1 = new javax.swing.JLabel();
        jbtnComprobar = new javax.swing.JButton();

        setDefaultCloseOperation(javax.swing.WindowConstants.DISPOSE_ON_CLOSE);

        jLabel2.setText("INTRODUZCA EL SALDO DE SU CAJA");

        jtxtSaldofinal.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jtxtSaldofinalActionPerformed(evt);
            }
        });

        jLabel3.setText("€");

        jLabel6.setIcon(new javax.swing.ImageIcon(getClass().getResource("/src/InterfazMINI.gif"))); // NOI18N

        jLabel1.setFont(new java.awt.Font("Tahoma", 0, 18)); // NOI18N
        jLabel1.setForeground(new java.awt.Color(0, 0, 255));
        jLabel1.setText("   Arqueo Final");

        jbtnComprobar.setText("COMPROBAR");
        jbtnComprobar.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jbtnComprobarActionPerformed(evt);
            }
        });

        javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane());
        getContentPane().setLayout(layout);
        layout.setHorizontalGroup(
            layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(layout.createSequentialGroup()
                .addGap(18, 18, 18)
                .addComponent(jLabel6)
                .addGap(95, 95, 95)
                .addComponent(jLabel1)
                .addGap(159, 159, 159))
            .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, layout.createSequentialGroup()
                .addContainerGap()
                .addComponent(jLabel2, javax.swing.GroupLayout.DEFAULT_SIZE, 218, Short.MAX_VALUE)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                .addComponent(jtxtSaldofinal, javax.swing.GroupLayout.PREFERRED_SIZE, 57, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                .addComponent(jLabel3, javax.swing.GroupLayout.PREFERRED_SIZE, 9, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addGap(18, 18, 18)
                .addComponent(jbtnComprobar)
                .addGap(30, 30, 30))
        );
        layout.setVerticalGroup(
            layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(layout.createSequentialGroup()
                .addContainerGap()
                .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addComponent(jLabel6)
                    .addComponent(jLabel1))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabel2, javax.swing.GroupLayout.PREFERRED_SIZE, 29, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(jbtnComprobar)
                    .addComponent(jtxtSaldofinal, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(jLabel3))
                .addContainerGap(34, Short.MAX_VALUE))
        );

        pack();
    }// </editor-fold>//GEN-END:initComponents

    private void jtxtSaldofinalActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jtxtSaldofinalActionPerformed
        // TODO add your handling code here:
}//GEN-LAST:event_jtxtSaldofinalActionPerformed

    //BOTON COMPROBAR EL SALDO FINAL DE LA CAJA DEL EMPLEADO
    private void jbtnComprobarActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jbtnComprobarActionPerformed
        // TODO add your handling code here:
        
        a.ArqueoFinal(auxsuc,jtxtSaldofinal.getText());
}//GEN-LAST:event_jbtnComprobarActionPerformed

    /**
    * @param args the command line arguments
    */
   /* public static void main(String args[]) {
        java.awt.EventQueue.invokeLater(new Runnable() {
            public void run() {
                new JfrmArqueoFinal().setVisible(true);
            }
        });
    }*/

    // Variables declaration - do not modify//GEN-BEGIN:variables
    private javax.swing.JLabel jLabel1;
    private javax.swing.JLabel jLabel2;
    private javax.swing.JLabel jLabel3;
    private javax.swing.JLabel jLabel6;
    private javax.swing.JButton jbtnComprobar;
    private javax.swing.JTextField jtxtSaldofinal;
    // End of variables declaration//GEN-END:variables

}
