Package com.commander4j.gui

Examples of com.commander4j.gui.JLabel4j_std


    desktopPane.setBackground(Color.WHITE);
    desktopPane.setBounds(0, 0, 587, 631);
    getContentPane().add(desktopPane);
    desktopPane.setLayout(null);

    JLabel4j_std lblProcessOrder = new JLabel4j_std(lang.get("lbl_Process_Order"));
    lblProcessOrder.setHorizontalAlignment(SwingConstants.TRAILING);
    lblProcessOrder.setBounds(6, 12, 111, 16);
    desktopPane.add(lblProcessOrder);

    JLabel4j_std lblDescription = new JLabel4j_std(lang.get("lbl_Description"));
    lblDescription.setHorizontalAlignment(SwingConstants.TRAILING);
    lblDescription.setBounds(6, 43, 111, 16);
    desktopPane.add(lblDescription);

    textFieldProcessOrder = new JTextField4j();
    textFieldProcessOrder.addKeyListener(new KeyAdapter()
    {
      public void keyReleased(KeyEvent evt)
      {
        processOrderChanged(textFieldProcessOrder.getText());
      }
    });
    textFieldProcessOrder.setBounds(125, 10, 138, 22);
    desktopPane.add(textFieldProcessOrder);
    textFieldProcessOrder.setColumns(10);

    textFieldDescription = new JTextField4j();
    textFieldDescription.setEditable(false);
    textFieldDescription.setBounds(125, 38, 420, 22);
    desktopPane.add(textFieldDescription);
    textFieldDescription.setColumns(10);

    textFieldInspectionID = new JTextField4j();
    textFieldInspectionID.setEditable(false);
    textFieldInspectionID.setBounds(125, 69, 134, 22);
    desktopPane.add(textFieldInspectionID);
    textFieldInspectionID.setColumns(10);

    JLabel4j_std lblInspectionID = new JLabel4j_std(lang.get("lbl_Inspection_ID"));
    lblInspectionID.setHorizontalAlignment(SwingConstants.TRAILING);
    lblInspectionID.setBounds(6, 74, 111, 16);
    desktopPane.add(lblInspectionID);

    JLabel4j_std lblNewLabel_3 = new JLabel4j_std(lang.get("lbl_Activity_ID"));
    lblNewLabel_3.setBounds(30, 199, 111, 16);
    desktopPane.add(lblNewLabel_3);

    btnPrint = new JButton4j(lang.get("btn_Print"));
    btnPrint.setEnabled(false);
    btnPrint.addActionListener(new ActionListener()
    {
      public void actionPerformed(ActionEvent e)
      {
        Long sampleID = sample.generateSampleID();
        String activityID = ((JDBQMActivity) listActivities.getSelectedValue()).getActivityID();
        Timestamp ts = JUtility.getTimestampFromDate(sampleDateTime.getDate());
        sample.create(sampleID, po.getInspectionID(), activityID, po.getProcessOrder(), po.getMaterial(), textFieldUserData1.getText(), textFieldUserData2.getText(), ts);
        String pq = comboBoxPrintQueue.getSelectedItem().toString();
        buildSQL1Record(sampleID);
        String dpi = getDefaultDPI();
        if (dpi.equals("")==false)
        {
          dpi = "_" + dpi;
        }
        JLaunchReport.runReport("RPT_SAMPLE_LABEL"+dpi, listStatement, false, pq, Integer.valueOf(spinnerCopies.getValue().toString()), false);
        lblStatusBar.setText(Integer.valueOf(spinnerCopies.getValue().toString()) + " labels printed. " + sample.getSampleDate().toString());
      }
    });

    btnPrint.setIcon(Common.icon_print);
    btnPrint.setBounds(185, 535, 117, 29);
    desktopPane.add(btnPrint);

    btnClose = new JButton4j(lang.get("btn_Close"));
    btnClose.setIcon(Common.icon_close);
    btnClose.addActionListener(new ActionListener()
    {
      public void actionPerformed(ActionEvent e)
      {
        dispose();
      }
    });
    btnClose.setBounds(314, 535, 117, 29);
    desktopPane.add(btnClose);

    comboBoxPrintQueue.setBounds(145, 468, 388, 27);
    desktopPane.add(comboBoxPrintQueue);

    JLabel4j_std lblNewLabel_4 = new JLabel4j_std(lang.get("lbl_Print_Queue"));
    lblNewLabel_4.setHorizontalAlignment(SwingConstants.TRAILING);
    lblNewLabel_4.setBounds(6, 472, 138, 16);
    desktopPane.add(lblNewLabel_4);

    JLabel4j_std lblNewLabel_5 = new JLabel4j_std(lang.get("lbl_Number_Of_Labels"));
    lblNewLabel_5.setHorizontalAlignment(SwingConstants.TRAILING);
    lblNewLabel_5.setBounds(6, 442, 138, 16);
    desktopPane.add(lblNewLabel_5);

    spinnerCopies = new JSpinner();
    spinnerCopies.setBounds(149, 432, 37, 28);
    JSpinner.NumberEditor ne = new JSpinner.NumberEditor(spinnerCopies);
    ne.getTextField().setFont(Common.font_std);
    spinnerCopies.setEditor(ne);
    desktopPane.add(spinnerCopies);

    JButton btnProcessOrderLookup = new JButton();
    btnProcessOrderLookup.setIcon(Common.icon_lookup);
    btnProcessOrderLookup.addActionListener(new ActionListener()
    {
      public void actionPerformed(ActionEvent evt)
      {
        JLaunchLookup.dlgCriteriaDefault = "Ready";
        JLaunchLookup.dlgAutoExec = true;
        if (JLaunchLookup.processOrders())
        {
          textFieldProcessOrder.setText(JLaunchLookup.dlgResult);
          processOrderChanged(JLaunchLookup.dlgResult);
        }
      }
    });
    btnProcessOrderLookup.setBounds(261, 10, 21, 22);
    desktopPane.add(btnProcessOrderLookup);

    populatePrinterList(JPrint.getDefaultPrinterQueueName());
    String numberOfLabels = ctrl.getKeyValueWithDefault("QM SAMPLE LABELS", "4", "Number of Labels per Sample");
    spinnerCopies.setValue(Integer.valueOf(numberOfLabels));

    JLabel4j_std lblMaterial = new JLabel4j_std(lang.get("lbl_Material"));
    lblMaterial.setHorizontalAlignment(SwingConstants.TRAILING);
    lblMaterial.setBounds(6, 105, 111, 16);
    desktopPane.add(lblMaterial);

    textFieldMaterial = new JTextField4j();
    textFieldMaterial.setEditable(false);
    textFieldMaterial.setColumns(10);
    textFieldMaterial.setBounds(125, 100, 134, 22);
    desktopPane.add(textFieldMaterial);

    JLabel4j_std lblStatus = new JLabel4j_std(lang.get("lbl_Process_Order_Status"));
    lblStatus.setHorizontalAlignment(SwingConstants.TRAILING);
    lblStatus.setBounds(6, 136, 111, 16);
    desktopPane.add(lblStatus);

    textFieldStatus = new JTextField4j();
    textFieldStatus.setEditable(false);
    textFieldStatus.setColumns(10);
    textFieldStatus.setBounds(125, 131, 134, 22);
    desktopPane.add(textFieldStatus);

    JScrollPane scrollPane = new JScrollPane();
    scrollPane.setBounds(30, 215, 515, 206);
    desktopPane.add(scrollPane);

    listActivities = new JList4j();
    listActivities.setSelectionMode(ListSelectionModel.SINGLE_SELECTION);

    listActivities.addListSelectionListener(new ListSelectionListener()
    {
      public void valueChanged(ListSelectionEvent arg0)
      {
        printEnable();
      }
    });
    scrollPane.setViewportView(listActivities);

    JLabel4j_std lblResource = new JLabel4j_std(lang.get("lbl_Process_Order_Required_Resource"));
    lblResource.setHorizontalAlignment(SwingConstants.TRAILING);
    lblResource.setBounds(261, 74, 138, 16);
    desktopPane.add(lblResource);

    textFieldResource = new JTextField4j();
    textFieldResource.setEditable(false);
    textFieldResource.setColumns(10);
    textFieldResource.setBounds(411, 69, 134, 22);
    desktopPane.add(textFieldResource);

    dueDate = new JDateControl();
    dueDate.setEnabled(false);
    dueDate.setBounds(411, 103, 134, 28);
    dueDate.getEditor().setPreferredSize(new java.awt.Dimension(87, 19));
    dueDate.getEditor().setSize(87, 21);
    desktopPane.add(dueDate);

    JLabel4j_std lblDueDate = new JLabel4j_std(lang.get("lbl_Process_Order_Due_Date"));
    lblDueDate.setHorizontalAlignment(SwingConstants.TRAILING);
    lblDueDate.setBounds(261, 105, 138, 16);
    desktopPane.add(lblDueDate);

    lblUserData1 = new JLabel4j_std(lang.get("lbl_User_Data1"));
    lblUserData1.setHorizontalAlignment(SwingConstants.TRAILING);
    lblUserData1.setBounds(6, 167, 111, 16);
    desktopPane.add(lblUserData1);

    lblUserData2 = new JLabel4j_std(lang.get("lbl_User_Data2"));
    lblUserData2.setHorizontalAlignment(SwingConstants.TRAILING);
    lblUserData2.setBounds(288, 167, 111, 16);
    desktopPane.add(lblUserData2);

    DocumentFilter filter = new UppercaseDocumentFilter();
    textFieldUserData1 = new JTextField4j();
    textFieldUserData1.addKeyListener(new KeyAdapter()
    {

      @Override
      public void keyReleased(KeyEvent e)
      {
        printEnable();
      }
    });

    ((AbstractDocument) textFieldUserData1.getDocument()).setDocumentFilter(filter);
    textFieldUserData1.setColumns(20);
    textFieldUserData1.setBounds(125, 162, 134, 22);
    desktopPane.add(textFieldUserData1);

    textFieldUserData2 = new JTextField4j();
    textFieldUserData2.addKeyListener(new KeyAdapter()
    {
      @Override
      public void keyReleased(KeyEvent e)
      {
        printEnable();
      }
    });

    ((AbstractDocument) textFieldUserData2.getDocument()).setDocumentFilter(filter);
    textFieldUserData2.setColumns(20);
    textFieldUserData2.setBounds(411, 162, 134, 22);
    desktopPane.add(textFieldUserData2);

    lblStatusBar = new JLabel4j_std();
    lblStatusBar.setForeground(Color.RED);
    lblStatusBar.setBackground(Color.GRAY);
    lblStatusBar.setBounds(0, 568, 575, 21);
    desktopPane.add(lblStatusBar);
View Full Code Here


            }
          });
        }

        {
          jLabel1 = new JLabel4j_std();
          jDesktopPane1.add(jLabel1);
          jLabel1.setText(lang.get("lbl_Pallet_SSCC"));
          jLabel1.setBounds(7, 14, 133, 21);
          jLabel1.setHorizontalAlignment(SwingConstants.TRAILING);
        }
        {
          jLabel5 = new JLabel4j_std();
          jDesktopPane1.add(jLabel5);
          jLabel5.setBounds(7, 275, 133, 21);
          jLabel5.setHorizontalAlignment(SwingConstants.TRAILING);
          jLabel5.setText(lang.get("lbl_Material_UOM"));
        }

        {
          jLabel2 = new JLabel4j_std();
          jDesktopPane1.add(jLabel2);
          jLabel2.setText(lang.get("lbl_Material"));
          jLabel2.setHorizontalAlignment(SwingConstants.TRAILING);
          jLabel2.setBounds(7, 98, 133, 21);
        }
        {
          jTextFieldMaterial = new JTextField4j();
          AbstractDocument doc = (AbstractDocument) jTextFieldMaterial.getDocument();
          doc.setDocumentFilter(new JFixedSizeFilter(JDBMaterial.field_material));
          jDesktopPane1.add(jTextFieldMaterial);
          jTextFieldMaterial.setBounds(147, 98, 119, 21);
          jTextFieldMaterial.setEnabled(false);
        }
        {
          jLabel3 = new JLabel4j_std();
          jDesktopPane1.add(jLabel3);
          jLabel3.setText(lang.get("lbl_Material_Batch"));
          jLabel3.setHorizontalAlignment(SwingConstants.TRAILING);
          jLabel3.setBounds(7, 185, 133, 21);
        }
        {
          jTextFieldBatch = new JTextField4j();
          AbstractDocument doc = (AbstractDocument) jTextFieldBatch.getDocument();
          doc.setDocumentFilter(new JFixedSizeFilter(JDBMaterialBatch.field_batch_number));
          jDesktopPane1.add(jTextFieldBatch);
          jTextFieldBatch.setBounds(147, 185, 119, 21);
          jTextFieldBatch.setEnabled(false);
        }

        {
          jLabelProcessOrder = new JLabel4j_std();
          jDesktopPane1.add(jLabelProcessOrder);
          jLabelProcessOrder.setText(lang.get("lbl_Process_Order"));
          jLabelProcessOrder.setHorizontalAlignment(SwingConstants.TRAILING);
          jLabelProcessOrder.setBounds(7, 42, 133, 21);
        }
        {
          jTextFieldProcessOrder = new JTextField4j();
          AbstractDocument doc = (AbstractDocument) jTextFieldProcessOrder.getDocument();
          doc.setDocumentFilter(new JFixedSizeFilter(JDBProcessOrder.field_process_order));
          jDesktopPane1.add(jTextFieldProcessOrder);
          jTextFieldProcessOrder.setBounds(147, 42, 119, 21);
          jTextFieldProcessOrder.setEnabled(false);

        }
        {
          jLabel6 = new JLabel4j_std();
          jDesktopPane1.add(jLabel6);
          jLabel6.setText(lang.get("lbl_Material_UOM_EAN"));
          jLabel6.setHorizontalAlignment(SwingConstants.RIGHT);
          jLabel6.setHorizontalTextPosition(SwingConstants.RIGHT);
          jLabel6.setBounds(7, 356, 133, 21);
        }
        {
          jTextFieldEAN = new JTextField4j();
          jDesktopPane1.add(jTextFieldEAN);
          jTextFieldEAN.setBounds(147, 356, 119, 21);
          jTextFieldEAN.setFocusCycleRoot(true);
          jTextFieldEAN.setEnabled(false);
        }
        {
          jLabel7 = new JLabel4j_std();
          jDesktopPane1.add(jLabel7);
          jLabel7.setText(lang.get("lbl_Material_UOM_Variant"));
          jLabel7.setHorizontalAlignment(SwingConstants.RIGHT);
          jLabel7.setHorizontalTextPosition(SwingConstants.RIGHT);
          jLabel7.setBounds(7, 384, 133, 21);
        }
        {
          jTextFieldVariant = new JTextField4j();
          jDesktopPane1.add(jTextFieldVariant);
          jTextFieldVariant.setBounds(147, 384, 21, 21);
          jTextFieldVariant.setFocusCycleRoot(true);
          jTextFieldVariant.setEnabled(false);
        }
        {
          jLabelQuantity = new JLabel4j_std();
          jDesktopPane1.add(jLabelQuantity);
          jLabelQuantity.setText(lang.get("lbl_Pallet_Quantity"));
          jLabelQuantity.setHorizontalAlignment(SwingConstants.TRAILING);
          jLabelQuantity.setBounds(7, 245, 133, 21);
        }
        {
          jFormattedTextFieldQuantity = new JQuantityInput(new BigDecimal("0"));
          jDesktopPane1.add(jFormattedTextFieldQuantity);
          jFormattedTextFieldQuantity.setFont(Common.font_std);
          jFormattedTextFieldQuantity.setHorizontalAlignment(SwingConstants.TRAILING);
          jFormattedTextFieldQuantity.setBounds(147, 245, 91, 21);
          jFormattedTextFieldQuantity.setEnabled(false);

        }

        {
          jTextFieldProcessOrderDescription = new JTextField4j();
          jDesktopPane1.add(jTextFieldProcessOrderDescription);
          jTextFieldProcessOrderDescription.setBounds(147, 70, 287, 21);
          jTextFieldProcessOrderDescription.setEnabled(false);
        }
        {
          jLabel8 = new JLabel4j_std();
          jDesktopPane1.add(jLabel8);
          jLabel8.setText(lang.get("lbl_Description"));
          jLabel8.setHorizontalAlignment(SwingConstants.TRAILING);
          jLabel8.setBounds(7, 70, 133, 21);
        }
        {
          jLabel9 = new JLabel4j_std();
          jDesktopPane1.add(jLabel9);
          jLabel9.setText(lang.get("lbl_Description"));
          jLabel9.setHorizontalAlignment(SwingConstants.TRAILING);
          jLabel9.setBounds(7, 126, 133, 21);
        }
        {
          jTextFieldMaterialDescription = new JTextField4j();
          jDesktopPane1.add(jTextFieldMaterialDescription);
          jTextFieldMaterialDescription.setBounds(147, 126, 287, 21);
          jTextFieldMaterialDescription.setEnabled(false);

        }
        {
          jStatusText = new JLabel4j_std();
          jDesktopPane1.add(jStatusText);
          jStatusText.setForeground(new java.awt.Color(255, 0, 0));
          jStatusText.setBorder(BorderFactory.createBevelBorder(BevelBorder.LOWERED));
          jStatusText.setBounds(0, 490, 445, 21);
        }

        {
          jLabelQuantity_1 = new JLabel4j_std();
          jLabelQuantity_1.setHorizontalAlignment(SwingConstants.TRAILING);
          jLabelQuantity_1.setText(lang.get("lbl_Pallet_Base_Quantity"));
          jLabelQuantity_1.setBounds(7, 302, 133, 21);
          jDesktopPane1.add(jLabelQuantity_1);
        }

        {
          jFormattedTextFieldBaseQuantity = new JQuantityInput(new BigDecimal("0"));
          jFormattedTextFieldBaseQuantity.setFocusable(false);
          jFormattedTextFieldBaseQuantity.setEnabled(false);
          jFormattedTextFieldBaseQuantity.setHorizontalAlignment(SwingConstants.TRAILING);
          jFormattedTextFieldBaseQuantity.setFont(Common.font_std);
          jFormattedTextFieldBaseQuantity.setBounds(147, 302, 91, 21);
          jDesktopPane1.add(jFormattedTextFieldBaseQuantity);
        }

        {
          jTextFieldBaseUom = new JTextField4j();
          jTextFieldBaseUom.setEnabled(false);
          jTextFieldBaseUom.setFocusCycleRoot(true);
          jTextFieldBaseUom.setBounds(147, 329, 119, 21);
          jDesktopPane1.add(jTextFieldBaseUom);
        }

        {
          jLabelQuantity_2 = new JLabel4j_std();
          jLabelQuantity_2.setHorizontalAlignment(SwingConstants.TRAILING);
          jLabelQuantity_2.setText(lang.get("lbl_Pallet_Base_UOM"));
          jLabelQuantity_2.setBounds(7, 329, 133, 21);
          jDesktopPane1.add(jLabelQuantity_2);
        }

        {
          jLabelProductionDate_1 = new JLabel4j_std();
          jLabelProductionDate_1.setHorizontalAlignment(SwingConstants.TRAILING);
          jLabelProductionDate_1.setText(lang.get("lbl_Confirmed"));
          jLabelProductionDate_1.setBounds(7, 410, 133, 21);
          jDesktopPane1.add(jLabelProductionDate_1);
        }

        {
          checkBoxConfirmed.setBackground(Color.WHITE);
          checkBoxConfirmed.setText("");
          checkBoxConfirmed.setBounds(144, 410, 32, 24);
          checkBoxConfirmed.setEnabled(false);
          jDesktopPane1.add(checkBoxConfirmed);
        }

        {
          jLabel4 = new JLabel4j_std();
          jLabel4.setHorizontalAlignment(SwingConstants.TRAILING);
          jLabel4.setText(lang.get("lbl_Location_ID"));
          jLabel4.setBounds(7, 153, 133, 21);
          jDesktopPane1.add(jLabel4);
        }

        {
          jTextFieldLocation = new JTextField4j();
          jTextFieldLocation.setBounds(147, 153, 119, 21);
          jTextFieldLocation.setEnabled(false);
          jDesktopPane1.add(jTextFieldLocation);
        }

        {
          jLabel10 = new JLabel4j_std();
          jLabel10.setHorizontalAlignment(SwingConstants.TRAILING);
          jLabel10.setText(lang.get("lbl_Material_Batch_Status"));
          jLabel10.setBounds(7, 215, 133, 21);
          jDesktopPane1.add(jLabel10);
        }
View Full Code Here

                dispose();
              }
            });
          }
          {
            jLabel2 = new JLabel4j_std();
            jDesktopPane1.add(jLabel2);
            jLabel2.setText("by");
            jLabel2.setBounds(147, 112, 56, 21);
            jLabel2.setFont(new java.awt.Font("Dialog", 0, 12));
            jLabel2.setHorizontalAlignment(SwingConstants.CENTER);
          }
          {
            jLabel3 = new JLabel4j_std();
            jDesktopPane1.add(jLabel3);
            jLabel3.setText("David Garratt");
            jLabel3.setBounds(119, 133, 105, 14);
            jLabel3.setFont(new java.awt.Font("Dialog", 0, 12));
            jLabel3.setHorizontalAlignment(SwingConstants.CENTER);
          }
          {
            jLabel1 = new JLabel4j_std();
            jLabel1.setHorizontalAlignment(SwingConstants.CENTER);
            jDesktopPane1.add(jLabel1);
            jLabel1.setText("http://www.commander4j.com");
            jLabel1.setBounds(48, 175, 241, 14);
            jLabel1.setForeground(new java.awt.Color(0, 0, 255));
            jLabel1.addMouseListener(new MouseAdapter() {
              public void mouseClicked(MouseEvent evt) {
                if (HelpAvailable)
                {
                  try
                  {
                    desktop.browse(helpURI);
                  }
                  catch (Exception ex)
                  {
                    JUtility.errorBeep();
                    JOptionPane.showMessageDialog(Common.mainForm, ex.getMessage(), "Error", JOptionPane.ERROR_MESSAGE);
                  }
                }
              }

              public void mouseExited(MouseEvent evt) {
                Cursor normalCursor = new Cursor(Cursor.DEFAULT_CURSOR);
                setCursor(normalCursor);
              }

              public void mouseEntered(MouseEvent evt) {
                Cursor hourglassCursor = new Cursor(Cursor.HAND_CURSOR);
                setCursor(hourglassCursor);
              }
            });
          }
          {
            jLabel4 = new JLabel4j_std();
            jLabel4.setHorizontalAlignment(SwingConstants.CENTER);
            jDesktopPane1.add(jLabel4);
            jLabel4.setText("Email : support@commander4j.com");
            jLabel4.setBounds(44, 154, 242, 14);
            jLabel4.setForeground(new java.awt.Color(0, 0, 255));
            jLabel4.addMouseListener(new MouseAdapter() {
              public void mouseClicked(MouseEvent evt) {
                if (HelpAvailable)
                {
                  try
                  {
                    desktop.mail(mailtoURI);
                  }
                  catch (Exception ex)
                  {
                    JUtility.errorBeep();
                    JOptionPane.showMessageDialog(Common.mainForm, ex.getMessage(), "Error", JOptionPane.ERROR_MESSAGE);
                  }
                }
              }

              public void mouseExited(MouseEvent evt) {
                Cursor normalCursor = new Cursor(Cursor.DEFAULT_CURSOR);
                setCursor(normalCursor);
              }

              public void mouseEntered(MouseEvent evt) {
                Cursor hourglassCursor = new Cursor(Cursor.HAND_CURSOR);
                setCursor(hourglassCursor);
              }
            });
          }
          {
            String msg = "4001234567890123456789012345678901234567890";
            i = JEANImage.getAWTImage("xml/barcode/about.xml", msg);
            Graphics gph = i.getGraphics();
            jDesktopPane1.paintComponents(gph.create(0, 0, 200, 50));
          }
          {
            jLabel5 = new JLabel4j_std();
            jDesktopPane1.add(jLabel5);
            jLabel5.setText("Commander4j " + JVersion.getProgramVersion());
            jLabel5.setBounds(14, 7, 322, 35);
            jLabel5.setFont(new java.awt.Font("Serif", 1, 28));
            jLabel5.setForeground(new java.awt.Color(255, 0, 0));
View Full Code Here

    getContentPane().add(desktopPane);
    desktopPane.setLayout(null);

    setTitle("Results Enquiry");

    JLabel4j_std lblProcessOrder = new JLabel4j_std(lang.get("lbl_Process_Order"));
    lblProcessOrder.setBounds(6, 16, 111, 16);
    lblProcessOrder.setHorizontalAlignment(SwingConstants.TRAILING);
    desktopPane.add(lblProcessOrder);

    textFieldProcessOrder = new JTextField4j();
    textFieldProcessOrder.setBounds(123, 14, 119, 22);

    desktopPane.add(textFieldProcessOrder);
    textFieldProcessOrder.setColumns(10);

    btnClose = new JButton4j(lang.get("btn_Close"));
    btnClose.setBounds(397, 157, 117, 32);
    btnClose.setIcon(Common.icon_close);
    btnClose.addActionListener(new ActionListener()
    {
      public void actionPerformed(ActionEvent e)
      {
        dispose();
      }
    });
    desktopPane.add(btnClose);

    JButton4j btnSearch = new JButton4j(lang.get("btn_Search"));
    btnSearch.setBounds(45, 157, 117, 32);
    btnSearch.setIcon(Common.icon_search);
    btnSearch.addActionListener(new ActionListener()
    {
      public void actionPerformed(ActionEvent e)
      {
        populateTable();
      }
    });
    desktopPane.add(btnSearch);

    JButton btnProcessOrderLookup = new JButton();
    btnProcessOrderLookup.setIcon(Common.icon_lookup);
    btnProcessOrderLookup.setBounds(240, 14, 21, 22);
    btnProcessOrderLookup.addActionListener(new ActionListener()
    {
      public void actionPerformed(ActionEvent evt)
      {
        JLaunchLookup.dlgCriteriaDefault = "Ready";
        JLaunchLookup.dlgAutoExec = true;
        if (JLaunchLookup.processOrders())
        {
          textFieldProcessOrder.setText(JLaunchLookup.dlgResult);
        }
      }
    });
    desktopPane.add(btnProcessOrderLookup);

    lblStatusBar = new JLabel4j_std();
    lblStatusBar.setBounds(4, 612, 990, 21);
    lblStatusBar.setForeground(Color.RED);
    lblStatusBar.setBackground(Color.GRAY);
    desktopPane.add(lblStatusBar);

    scrollPaneResults = new JScrollPane();
    scrollPaneResults.setBounds(6, 198, 993, 410);
    scrollPaneResults.getViewport().setBackground(Common.color_tablebackground);
    desktopPane.setLayout(null);
    scrollPaneResults.setViewportView(table);
    desktopPane.add(scrollPaneResults);

    textFieldMaterial = new JTextField4j();
    textFieldMaterial.setColumns(10);
    textFieldMaterial.setBounds(386, 14, 119, 22);
    desktopPane.add(textFieldMaterial);

    JLabel4j_std lbl_material = new JLabel4j_std(lang.get("lbl_Material"));
    lbl_material.setHorizontalAlignment(SwingConstants.TRAILING);
    lbl_material.setBounds(263, 16, 111, 16);
    desktopPane.add(lbl_material);

    textFieldInspectionID = new JTextField4j();
    textFieldInspectionID.setColumns(10);
    textFieldInspectionID.setBounds(123, 115, 119, 22);
    desktopPane.add(textFieldInspectionID);

    lbl_inspection = new JLabel4j_std(lang.get("lbl_Inspection_ID"));
    lbl_inspection.setHorizontalAlignment(SwingConstants.TRAILING);
    lbl_inspection.setBounds(6, 120, 111, 16);
    desktopPane.add(lbl_inspection);

    JButton4j btnExcel = new JButton4j(lang.get("btn_Excel"));
    btnExcel.addActionListener(new ActionListener()
    {
      public void actionPerformed(ActionEvent arg0)
      {
        JExcel export = new JExcel();
        PreparedStatement temp = buildSQL();

        ResultSet rs;

        try
        {
          rs = temp.executeQuery();
          export.saveAs("qm_results.xls", rs, Common.mainForm);
        } catch (Exception e)
        {
          rs = null;

        }

      }
    });
    btnExcel.setIcon(Common.icon_XLS);
    btnExcel.setBounds(279, 157, 117, 32);
    desktopPane.add(btnExcel);

    JLabel4j_std label4j_std = new JLabel4j_std(lang.get("lbl_Sample_Date"));
    label4j_std.setHorizontalAlignment(SwingConstants.TRAILING);
    label4j_std.setBounds(6, 87, 108, 16);
    desktopPane.add(label4j_std);

    checkBoxSampleFrom = new JCheckBox4j();
    checkBoxSampleFrom.addActionListener(new ActionListener()
    {
      public void actionPerformed(ActionEvent e)
      {
        if (checkBoxSampleFrom.isSelected())
        {
          dateSampleFrom.setEnabled(true);
          calendarButtonsampleDateFrom.setEnabled(true);
        } else
        {
          dateSampleFrom.setEnabled(false);
          calendarButtonsampleDateFrom.setEnabled(false);
        }
      }
    });
    checkBoxSampleFrom.setBackground(Color.WHITE);
    checkBoxSampleFrom.setBounds(120, 80, 21, 25);
    desktopPane.add(checkBoxSampleFrom);

    dateSampleFrom = new JDateControl();
    dateSampleFrom.setFont(new Font("Arial", Font.PLAIN, 11));
    dateSampleFrom.setEnabled(false);
    dateSampleFrom.setBounds(142, 80, 128, 28);
    desktopPane.add(dateSampleFrom);

    checkBoxSampleTo = new JCheckBox4j();
    checkBoxSampleTo.addActionListener(new ActionListener()
    {
      public void actionPerformed(ActionEvent e)
      {
        if (checkBoxSampleTo.isSelected())
        {
          dateSampleTo.setEnabled(true);
          calendarButtonsampleDateTo.setEnabled(true);
        } else
        {
          dateSampleTo.setEnabled(false);
          calendarButtonsampleDateTo.setEnabled(false);
        }
      }
    });
    checkBoxSampleTo.setBackground(Color.WHITE);
    checkBoxSampleTo.setBounds(373, 80, 21, 25);
    desktopPane.add(checkBoxSampleTo);

    dateSampleTo = new JDateControl();
    dateSampleTo.setFont(new Font("Arial", Font.PLAIN, 11));
    dateSampleTo.setEnabled(false);
    dateSampleTo.setBounds(396, 80, 128, 25);
    desktopPane.add(dateSampleTo);

    JLabel4j_std label4j_std_1 = new JLabel4j_std(lang.get("lbl_User_Data1"));
    label4j_std_1.setHorizontalAlignment(SwingConstants.TRAILING);
    label4j_std_1.setBounds(6, 50, 111, 16);
    desktopPane.add(label4j_std_1);

    JLabel4j_std label4j_std_2 = new JLabel4j_std(lang.get("lbl_User_Data2"));
    label4j_std_2.setHorizontalAlignment(SwingConstants.TRAILING);
    label4j_std_2.setBounds(263, 50, 111, 16);
    desktopPane.add(label4j_std_2);

    textFieldUserData1 = new JTextField4j();
    textFieldUserData1.setColumns(10);
    textFieldUserData1.setBounds(123, 44, 138, 22);
    desktopPane.add(textFieldUserData1);

    textFieldUserData2 = new JTextField4j();
    textFieldUserData2.setColumns(10);
    textFieldUserData2.setBounds(386, 44, 138, 22);
    desktopPane.add(textFieldUserData2);

    calendarButtonsampleDateFrom = new JCalendarButton(dateSampleFrom);
    calendarButtonsampleDateFrom.setSize(21, 21);
    calendarButtonsampleDateFrom.setEnabled(false);
    calendarButtonsampleDateFrom.setLocation(273, 84);
    desktopPane.add(calendarButtonsampleDateFrom);

    calendarButtonsampleDateTo = new JCalendarButton(dateSampleTo);
    calendarButtonsampleDateTo.setSize(21, 21);
    calendarButtonsampleDateTo.setEnabled(false);
    calendarButtonsampleDateTo.setLocation(526, 84);
    desktopPane.add(calendarButtonsampleDateTo);

    SpinnerNumberModel jSpinnerIntModel = new SpinnerNumberModel();
    jSpinnerIntModel.setMinimum(1);
    jSpinnerIntModel.setMaximum(5000);
    jSpinnerIntModel.setStepSize(1);
    jSpinnerLimit = new JSpinner();
    JSpinner.NumberEditor ne = new JSpinner.NumberEditor(jSpinnerLimit);
    ne.getTextField().setFont(Common.font_std);
    jSpinnerLimit.setEditor(ne);
    jSpinnerLimit.setModel(jSpinnerIntModel);
    jSpinnerLimit.setBounds(456, 113, 68, 21);
    jSpinnerLimit.setValue(1000);
    jSpinnerLimit.getEditor().setSize(45, 21);
    desktopPane.add(jSpinnerLimit);

    jCheckBoxLimit = new JCheckBox4j();
    desktopPane.add(jCheckBoxLimit);
    jCheckBoxLimit.setBackground(new java.awt.Color(255, 255, 255));
    jCheckBoxLimit.setBounds(433, 113, 21, 21);
    jCheckBoxLimit.setSelected(true);
    jCheckBoxLimit.addActionListener(new ActionListener()
    {
      public void actionPerformed(ActionEvent evt)
      {
        if (jCheckBoxLimit.isSelected())
        {
          jSpinnerLimit.setEnabled(true);
        } else
        {
          jSpinnerLimit.setEnabled(false);
        }
      }
    });

    jLabel10 = new JLabel4j_std();
    desktopPane.add(jLabel10);
    jLabel10.setText(lang.get("lbl_Limit"));
    jLabel10.setHorizontalAlignment(SwingConstants.TRAILING);
    jLabel10.setBounds(353, 113, 77, 21);

    JScrollPane scrollPaneDictionary = new JScrollPane();
    scrollPaneDictionary.setBounds(559, 32, 440, 154);

    listDictionary = new JList4j<JCheckListItem>();

    ComboBoxModel<JCheckListItem> model = new DefaultComboBoxModel<JCheckListItem>(dict.getTestCheckListList());
    listDictionary.setModel(model);
    listDictionary.setCellRenderer(new MultiItemCheckListRenderer());
    listDictionary.addMouseListener(new MouseAdapter()
    {
      public void mouseClicked(MouseEvent event)
      {
        JList4j<?> list = (JList4j<?>) event.getSource();

        // Get index of item clicked

        int index = list.locationToIndex(event.getPoint());
        JCheckListItem item = (JCheckListItem) list.getModel().getElementAt(index);

        // Toggle selected state

        item.setSelected(!item.isSelected());

        // Repaint cell

        list.repaint(list.getCellBounds(index, index));
      }
    });

    scrollPaneDictionary.setViewportView(listDictionary);

    desktopPane.add(scrollPaneDictionary);

    JLabel4j_std label4j_std_3 = new JLabel4j_std(lang.get("lbl_Test_ID"));
    label4j_std_3.setBounds(559, 16, 111, 16);
    desktopPane.add(label4j_std_3);

    JButton btnInspectionIDLookup = new JButton();
    btnInspectionIDLookup.addActionListener(new ActionListener()
    {
View Full Code Here

    JDesktopPane desktopPane = new JDesktopPane();
    desktopPane.setBackground(Color.WHITE);
    desktopPane.setBounds(0, 0, 414, 185);
    getContentPane().add(desktopPane);
   
    JLabel4j_std lblListID = new JLabel4j_std(lang.get("lbl_List_ID"));
    lblListID.setBounds(8, 27, 87, 16);
    desktopPane.add(lblListID);
    lblListID.setHorizontalAlignment(SwingConstants.TRAILING);
   
    JLabel4j_std lblValue = new JLabel4j_std(lang.get("lbl_Value"));
    lblValue.setBounds(220, 27, 89, 16);
    desktopPane.add(lblValue);
    lblValue.setHorizontalAlignment(SwingConstants.TRAILING);
   
    textFieldListID = new JTextField4j();
    textFieldListID.addKeyListener(new KeyAdapter() {
      @Override
      public void keyReleased(KeyEvent arg0) {
        enableSave();
      }
    });
    textFieldListID.setEnabled(false);
    textFieldListID.setBounds(103, 22, 117, 28);
    desktopPane.add(textFieldListID);
    textFieldListID.setColumns(10);
     
    btnSave = new JButton4j(lang.get("btn_Save"));
    btnSave.setEnabled(false);
    btnSave.addActionListener(new ActionListener() {
      public void actionPerformed(ActionEvent arg0) {
        save();
      }
    });
    btnSave.setIcon(Common.icon_save);
    btnSave.setBounds(118, 143, 117, 29);
    desktopPane.add(btnSave);
   
    btnClose = new JButton4j(lang.get("btn_Close"));
    btnClose.addActionListener(new ActionListener() {
      public void actionPerformed(ActionEvent arg0) {
        dispose();
      }
    });
    btnClose.setIcon(Common.icon_close);
    btnClose.setBounds(240, 143, 117, 29);
    desktopPane.add(btnClose);
   
    textFieldValue = new JTextField4j();
    textFieldValue.addKeyListener(new KeyAdapter() {
      @Override
      public void keyReleased(KeyEvent e) {
        enableSave();
      }
    });
    textFieldValue.setEnabled(false);
    textFieldValue.setText("<dynamic>");
    textFieldValue.setColumns(10);
    textFieldValue.setBounds(329, 22, 60, 28);
    desktopPane.add(textFieldValue);
   
    JLabel4j_std lblDescription = new JLabel4j_std(lang.get("lbl_Description"));
    lblDescription.setHorizontalAlignment(SwingConstants.TRAILING);
    lblDescription.setBounds(6, 64, 89, 16);
    desktopPane.add(lblDescription);
   
    textFieldDescription = new JTextField4j();
    textFieldDescription.addKeyListener(new KeyAdapter() {
      @Override
      public void keyReleased(KeyEvent arg0) {
        enableSave();
      }
    });
    textFieldDescription.setColumns(10);
    textFieldDescription.setBounds(103, 57, 286, 28);
    desktopPane.add(textFieldDescription);
   
    JLabel4j_std lblSeq = new JLabel4j_std(lang.get("lbl_Sequence_ID"));
    lblSeq.setHorizontalAlignment(SwingConstants.TRAILING);
    lblSeq.setBounds(8, 99, 87, 16);
    desktopPane.add(lblSeq);   

    spinnerSequence = new JSpinner();
    spinnerSequence.addChangeListener(new ChangeListener() {
      public void stateChanged(ChangeEvent arg0) {
View Full Code Here

        jDesktopPane1 = new JDesktopPane();
        jDesktopPane1.setBackground(Common.color_app_window);
        getContentPane().add(jDesktopPane1, BorderLayout.CENTER);
        jDesktopPane1.setLayout(null);
        {
          jLabel1 = new JLabel4j_std();
          jDesktopPane1.add(jLabel1);
          jLabel1.setText(lang.get("lbl_Storage_Plant"));
          jLabel1.setBounds(256, 11, 129, 21);
          jLabel1.setHorizontalAlignment(SwingConstants.TRAILING);
        }
        {
          JButton4j btnExcel = new JButton4j(Common.icon_XLS);
          btnExcel.addActionListener(new ActionListener() {
            public void actionPerformed(ActionEvent arg0) {
              export();
            }
          });
          btnExcel.setText(lang.get("btn_Excel"));
          btnExcel.setMnemonic(lang.getMnemonicChar());
          btnExcel.setBounds(628, 110, 103, 32);
          jDesktopPane1.add(btnExcel);
        }
        {
          jTextFieldPlant = new JTextField4j();
          jDesktopPane1.add(jTextFieldPlant);
          jTextFieldPlant.setBounds(392, 11, 80, 21);
        }
        {
          jLabel3 = new JLabel4j_std();
          jDesktopPane1.add(jLabel3);
          jLabel3.setText(lang.get("lbl_Description"));
          jLabel3.setBounds(12, 77, 91, 21);
          jLabel3.setHorizontalAlignment(SwingConstants.TRAILING);
        }
        {
          jTextFieldDescription = new JTextField4j();
          jDesktopPane1.add(jTextFieldDescription);
          jTextFieldDescription.setBounds(112, 77, 360, 21);
        }
        {
          jScrollPane1 = new JScrollPane();
          jScrollPane1.getViewport().setBackground(Common.color_tablebackground);
          jDesktopPane1.add(jScrollPane1);
          jScrollPane1.setBounds(0, 150, 946, 335);
          {
            TableModel jTable1Model = new DefaultTableModel(new String[][] { { "One", "Two" }, { "Three", "Four" } }, new String[] { "Column 1", "Column 2" });
            jTable1 = new JTable();
            jTable1.setDefaultRenderer(Object.class, Common.renderer_table);
            jScrollPane1.setViewportView(jTable1);
            jTable1.setAutoResizeMode(JTable.AUTO_RESIZE_OFF);
            jTable1.getTableHeader().setFont(Common.font_table_header);
            jTable1.addMouseListener(new MouseAdapter() {
              public void mouseClicked(MouseEvent evt) {
                if (evt.getClickCount() == 2)
                {
                  if (Common.userList.getUser(Common.sessionID).isModuleAllowed("FRM_ADMIN_LOCATION_EDIT"))
                  {
                    editRecord();
                  }
                }
              }
            });
            jTable1.setModel(jTable1Model);

            {
              final JPopupMenu popupMenu = new JPopupMenu();
              addPopup(jTable1, popupMenu);

              {
                final JMenuItem4j newItemMenuItem = new JMenuItem4j(Common.icon_find);
                newItemMenuItem.addActionListener(new ActionListener() {
                  public void actionPerformed(final ActionEvent e) {
                    search();
                  }
                });
                newItemMenuItem.setText(lang.get("btn_Search"));
                popupMenu.add(newItemMenuItem);
              }

              {
                final JMenuItem4j newItemMenuItem = new JMenuItem4j(Common.icon_add);
                newItemMenuItem.setEnabled(Common.userList.getUser(Common.sessionID).isModuleAllowed("FRM_ADMIN_LOCATION_ADD"));
                newItemMenuItem.addActionListener(new ActionListener() {
                  public void actionPerformed(final ActionEvent e) {
                    addRecord();
                  }
                });
                newItemMenuItem.setText(lang.get("btn_Add"));
                popupMenu.add(newItemMenuItem);
              }

              {
                final JMenuItem4j newItemMenuItem = new JMenuItem4j(Common.icon_edit);
                newItemMenuItem.setEnabled(Common.userList.getUser(Common.sessionID).isModuleAllowed("FRM_ADMIN_LOCATION_EDIT"));
                newItemMenuItem.addActionListener(new ActionListener() {
                  public void actionPerformed(final ActionEvent e) {
                    editRecord();
                  }
                });
                newItemMenuItem.setText(lang.get("btn_Edit"));
                popupMenu.add(newItemMenuItem);
              }

              {
                final JMenuItem4j newItemMenuItem = new JMenuItem4j(Common.icon_delete);
                newItemMenuItem.setEnabled(Common.userList.getUser(Common.sessionID).isModuleAllowed("FRM_ADMIN_LOCATION_DELETE"));
                newItemMenuItem.addActionListener(new ActionListener() {
                  public void actionPerformed(final ActionEvent e) {
                    deleteRecord();
                  }
                });
                newItemMenuItem.setText(lang.get("btn_Delete"));
                popupMenu.add(newItemMenuItem);
              }

              {
                final JMenuItem4j newItemMenuItem = new JMenuItem4j(Common.icon_print);
                newItemMenuItem.addActionListener(new ActionListener() {
                  public void actionPerformed(final ActionEvent e) {
                    print();
                  }
                });
                newItemMenuItem.setText(lang.get("btn_Print"));
                popupMenu.add(newItemMenuItem);
              }

              {
                final JMenu4j sortByMenu = new JMenu4j();
                sortByMenu.setText(lang.get("lbl_Sort_By"));
                popupMenu.add(sortByMenu);

                {
                  final JMenuItem4j newItemMenuItem = new JMenuItem4j();
                  newItemMenuItem.addActionListener(new ActionListener() {
                    public void actionPerformed(final ActionEvent e) {
                      sortBy("LOCATION_ID");
                    }
                  });
                  newItemMenuItem.setText(lang.get("lbl_Storage_Location"));
                  sortByMenu.add(newItemMenuItem);
                }

                {
                  final JMenuItem4j newItemMenuItem = new JMenuItem4j();
                  newItemMenuItem.addActionListener(new ActionListener() {
                    public void actionPerformed(final ActionEvent e) {
                      sortBy("PLANT");
                    }
                  });
                  newItemMenuItem.setText(lang.get("lbl_Storage_Plant"));
                  sortByMenu.add(newItemMenuItem);
                }

                {
                  final JMenuItem4j newItemMenuItem = new JMenuItem4j();
                  newItemMenuItem.addActionListener(new ActionListener() {
                    public void actionPerformed(final ActionEvent e) {
                      sortBy("WAREHOUSE");
                    }
                  });
                  newItemMenuItem.setText(lang.get("lbl_Storage_Warehouse"));
                  sortByMenu.add(newItemMenuItem);
                }

                {
                  final JMenuItem4j newItemMenuItem = new JMenuItem4j();
                  newItemMenuItem.addActionListener(new ActionListener() {
                    public void actionPerformed(final ActionEvent e) {
                      sortBy("DESCRIPTION");
                    }
                  });
                  newItemMenuItem.setText(lang.get("lbl_Description"));
                  sortByMenu.add(newItemMenuItem);
                }

                {
                  final JMenuItem4j newItemMenuItem = new JMenuItem4j();
                  newItemMenuItem.addActionListener(new ActionListener() {
                    public void actionPerformed(final ActionEvent e) {
                      sortBy("GLN");
                    }
                  });
                  newItemMenuItem.setText(lang.get("lbl_GLN"));
                  sortByMenu.add(newItemMenuItem);
                }

                {
                  final JMenuItem4j newItemMenuItem = new JMenuItem4j();
                  newItemMenuItem.addActionListener(new ActionListener() {
                    public void actionPerformed(final ActionEvent e) {
                      sortBy("STORAGE_LOCATION");
                    }
                  });
                  newItemMenuItem.setText(lang.get("lbl_Storage_Location"));
                  sortByMenu.add(newItemMenuItem);
                }

                {
                  final JMenuItem4j newItemMenuItem = new JMenuItem4j();
                  newItemMenuItem.addActionListener(new ActionListener() {
                    public void actionPerformed(final ActionEvent e) {
                      sortBy("STORAGE_TYPE");
                    }
                  });
                  newItemMenuItem.setText(lang.get("lbl_Storage_Type"));
                  sortByMenu.add(newItemMenuItem);
                }

                {
                  final JMenuItem4j newItemMenuItem = new JMenuItem4j();
                  newItemMenuItem.addActionListener(new ActionListener() {
                    public void actionPerformed(final ActionEvent e) {
                      sortBy("STORAGE_SECTION");
                    }
                  });
                  newItemMenuItem.setText(lang.get("lbl_Storage_Section"));
                  sortByMenu.add(newItemMenuItem);
                }

                {
                  final JMenuItem4j newItemMenuItem = new JMenuItem4j();
                  newItemMenuItem.addActionListener(new ActionListener() {
                    public void actionPerformed(final ActionEvent e) {
                      sortBy("STORAGE_BIN");
                    }
                  });
                  newItemMenuItem.setText(lang.get("lbl_Storage_Bin"));
                  sortByMenu.add(newItemMenuItem);
                }
              }

              {
                final JMenu4j filterByMenu = new JMenu4j();
                filterByMenu.setText("Filter by");
                popupMenu.add(filterByMenu);

                {
                  final JMenuItem4j newItemMenuItem = new JMenuItem4j();
                  newItemMenuItem.addActionListener(new ActionListener() {
                    public void actionPerformed(final ActionEvent e) {
                      filterBy("LOCATION_ID");
                    }
                  });
                  newItemMenuItem.setText(lang.get("lbl_Storage_Location"));
                  filterByMenu.add(newItemMenuItem);
                }

                {
                  final JMenuItem4j newItemMenuItem = new JMenuItem4j();
                  newItemMenuItem.addActionListener(new ActionListener() {
                    public void actionPerformed(final ActionEvent e) {
                      filterBy("PLANT");
                    }
                  });
                  newItemMenuItem.setText(lang.get("lbl_Storage_Plant"));
                  filterByMenu.add(newItemMenuItem);
                }

                {
                  final JMenuItem4j newItemMenuItem = new JMenuItem4j();
                  newItemMenuItem.addActionListener(new ActionListener() {
                    public void actionPerformed(final ActionEvent e) {
                      filterBy("WAREHOUSE");
                    }
                  });
                  newItemMenuItem.setText(lang.get("lbl_Storage_Warehouse"));
                  filterByMenu.add(newItemMenuItem);
                }

                {
                  final JMenuItem4j newItemMenuItem = new JMenuItem4j();
                  newItemMenuItem.addActionListener(new ActionListener() {
                    public void actionPerformed(final ActionEvent e) {
                      filterBy("GLN");
                    }
                  });
                  newItemMenuItem.setText(lang.get("lbl_GLN"));
                  filterByMenu.add(newItemMenuItem);
                }

                {
                  final JMenuItem4j newItemMenuItem = new JMenuItem4j();
                  newItemMenuItem.addActionListener(new ActionListener() {
                    public void actionPerformed(final ActionEvent e) {
                      filterBy("DESCRIPTION");
                    }
                  });
                  newItemMenuItem.setText(lang.get("lbl_Description"));
                  filterByMenu.add(newItemMenuItem);
                }

                {
                  final JMenuItem4j newItemMenuItem = new JMenuItem4j();
                  newItemMenuItem.addActionListener(new ActionListener() {
                    public void actionPerformed(final ActionEvent e) {
                      filterBy("STORAGE_LOCATION");
                    }
                  });
                  newItemMenuItem.setText(lang.get("lbl_Storage_Location"));
                  filterByMenu.add(newItemMenuItem);
                }

                {
                  final JMenuItem4j newItemMenuItem = new JMenuItem4j();
                  newItemMenuItem.addActionListener(new ActionListener() {
                    public void actionPerformed(final ActionEvent e) {
                      filterBy("STORAGE_TYPE");
                    }
                  });
                  newItemMenuItem.setText(lang.get("lbl_Storage_Type"));
                  filterByMenu.add(newItemMenuItem);
                }

                {
                  final JMenuItem4j newItemMenuItem = new JMenuItem4j();
                  newItemMenuItem.addActionListener(new ActionListener() {
                    public void actionPerformed(final ActionEvent e) {
                      filterBy("STORAGE_SECTION");
                    }
                  });
                  newItemMenuItem.setText(lang.get("lbl_Storage_Section"));
                  filterByMenu.add(newItemMenuItem);
                }

                {
                  final JMenuItem4j newItemMenuItem = new JMenuItem4j();
                  newItemMenuItem.addActionListener(new ActionListener() {
                    public void actionPerformed(final ActionEvent e) {
                      filterBy("STORAGE_BIN");
                    }
                  });
                  newItemMenuItem.setText(lang.get("lbl_Storage_Bin"));
                  filterByMenu.add(newItemMenuItem);
                }

                {
                  filterByMenu.addSeparator();
                }

                {
                  final JMenuItem4j newItemMenuItem = new JMenuItem4j();
                  newItemMenuItem.addActionListener(new ActionListener() {
                    public void actionPerformed(final ActionEvent e) {
                      clearFilter();
                    }
                  });
                  newItemMenuItem.setText(lang.get("btn_Clear_Filter"));
                  filterByMenu.add(newItemMenuItem);
                }
              }
            }
          }
        }
        {
          jLabel2 = new JLabel4j_std();
          jDesktopPane1.add(jLabel2);
          jLabel2.setText(lang.get("lbl_Storage_Warehouse"));
          jLabel2.setBounds(472, 11, 103, 21);
          jLabel2.setHorizontalAlignment(SwingConstants.TRAILING);
        }
        {
          jTextFieldWarehouse = new JTextField4j();
          jDesktopPane1.add(jTextFieldWarehouse);
          jTextFieldWarehouse.setBounds(583, 11, 80, 21);
        }
        {
          jLabel4 = new JLabel4j_std();
          jDesktopPane1.add(jLabel4);
          jLabel4.setText(lang.get("lbl_Storage_Bin"));
          jLabel4.setBounds(681, 44, 113, 21);
          jLabel4.setHorizontalAlignment(SwingConstants.TRAILING);
        }
        {
          jTextFieldStorageBin = new JTextField4j();
          jDesktopPane1.add(jTextFieldStorageBin);
          jTextFieldStorageBin.setBounds(801, 44, 80, 21);
        }
        {
          jTextFieldLocationID = new JTextField4j();
          jDesktopPane1.add(jTextFieldLocationID);
          jTextFieldLocationID.setBounds(112, 11, 126, 21);
        }
        {
          jLabel5 = new JLabel4j_std();
          jDesktopPane1.add(jLabel5);
          jLabel5.setText(lang.get("lbl_Storage_Location"));
          jLabel5.setBounds(12, 11, 93, 21);
          jLabel5.setHorizontalAlignment(SwingConstants.TRAILING);
        }
        {
          jLabel6 = new JLabel4j_std();
          jDesktopPane1.add(jLabel6);
          jLabel6.setText(lang.get("lbl_Storage_GLN"));
          jLabel6.setHorizontalAlignment(SwingConstants.TRAILING);
          jLabel6.setBounds(681, 11, 114, 21);
        }
        {
          jTextFieldGLN = new JTextField4j();
          jDesktopPane1.add(jTextFieldGLN);
          jTextFieldGLN.setBounds(802, 11, 126, 21);
        }
        {
          jLabel7 = new JLabel4j_std();
          jDesktopPane1.add(jLabel7);
          jLabel7.setText(lang.get("lbl_Storage_Section"));
          jLabel7.setHorizontalAlignment(SwingConstants.TRAILING);
          jLabel7.setBounds(472, 44, 103, 21);
        }
        {
          jTextFieldStorageSection = new JTextField4j();
          jDesktopPane1.add(jTextFieldStorageSection);
          jTextFieldStorageSection.setBounds(583, 44, 80, 21);
        }
        {
          jLabel8 = new JLabel4j_std();
          jDesktopPane1.add(jLabel8);
          jLabel8.setText(lang.get("lbl_Storage_Location"));
          jLabel8.setHorizontalAlignment(SwingConstants.TRAILING);
          jLabel8.setBounds(0, 44, 105, 21);
        }
        {
          jTextFieldStorageLocation = new JTextField4j();
          jDesktopPane1.add(jTextFieldStorageLocation);
          jTextFieldStorageLocation.setBounds(112, 44, 105, 21);
        }
        {
          jLabel9 = new JLabel4j_std();
          jDesktopPane1.add(jLabel9);
          jLabel9.setText(lang.get("lbl_Storage_Type"));
          jLabel9.setHorizontalAlignment(SwingConstants.TRAILING);
          jLabel9.setBounds(235, 44, 149, 21);
        }
        {
          jTextFieldStorageType = new JTextField4j();
          jDesktopPane1.add(jTextFieldStorageType);
          jTextFieldStorageType.setBounds(391, 44, 80, 21);
        }
        {
          jLabel10 = new JLabel4j_std();
          jDesktopPane1.add(jLabel10);
          jLabel10.setText(lang.get("lbl_Sort_By"));
          jLabel10.setHorizontalAlignment(SwingConstants.TRAILING);
          jLabel10.setBounds(472, 77, 103, 21);
        }
        {
          ComboBoxModel<String> jComboBoxSortByModel = new DefaultComboBoxModel<String>(new String[] { "LOCATION_ID", "PLANT", "WAREHOUSE", "DESCRIPTION", "GLN", "STORAGE_LOCATION", "STORAGE_TYPE", "STORAGE_SECTION", "STORAGE_BIN" });
          jComboBoxSortBy = new JComboBox4j<String>();
          jDesktopPane1.add(jComboBoxSortBy);
          jComboBoxSortBy.setModel(jComboBoxSortByModel);
          jComboBoxSortBy.setBounds(582, 75, 231, 23);
          jComboBoxSortBy.setSelectedItem("LOCATION_ID,PLANT,WAREHOUSE");
          jComboBoxSortBy.setRequestFocusEnabled(false);
        }
        {
          jButtonSearch = new JButton4j(Common.icon_find);
          jDesktopPane1.add(jButtonSearch);
          jButtonSearch.setText(lang.get("btn_Search"));
          jButtonSearch.setMnemonic(lang.getMnemonicChar());
          jButtonSearch.setBounds(4, 110, 103, 32);
          jButtonSearch.addActionListener(new ActionListener() {
            public void actionPerformed(ActionEvent evt) {
              search();

            }
          });
        }
        {
          jButtonAdd = new JButton4j(Common.icon_add);
          jDesktopPane1.add(jButtonAdd);
          jButtonAdd.setText(lang.get("btn_Add"));
          jButtonAdd.setMnemonic(lang.getMnemonicChar());
          jButtonAdd.setEnabled(Common.userList.getUser(Common.sessionID).isModuleAllowed("FRM_ADMIN_LOCATION_ADD"));
          jButtonAdd.setBounds(212, 110, 103, 32);
          jButtonAdd.addActionListener(new ActionListener() {
            public void actionPerformed(ActionEvent evt) {
              addRecord();
            }
          });
        }
        {
          jButtonEdit = new JButton4j(Common.icon_edit);
          jDesktopPane1.add(jButtonEdit);
          jButtonEdit.setText(lang.get("btn_Edit"));
          jButtonEdit.setMnemonic(lang.getMnemonicChar());
          jButtonEdit.setEnabled(Common.userList.getUser(Common.sessionID).isModuleAllowed("FRM_ADMIN_LOCATION_EDIT"));
          jButtonEdit.setBounds(316, 110, 103, 32);
          jButtonEdit.addActionListener(new ActionListener() {
            public void actionPerformed(ActionEvent evt) {
              editRecord();
            }
          });
        }
        {
          jButtonDelete = new JButton4j(Common.icon_delete);
          jDesktopPane1.add(jButtonDelete);
          jButtonDelete.setText(lang.get("btn_Delete"));
          jButtonDelete.setMnemonic(lang.getMnemonicChar());
          jButtonDelete.setEnabled(Common.userList.getUser(Common.sessionID).isModuleAllowed("FRM_ADMIN_LOCATION_DELETE"));
          jButtonDelete.setBounds(420, 110, 103, 32);
          jButtonDelete.addActionListener(new ActionListener() {
            public void actionPerformed(ActionEvent evt) {
              deleteRecord();
            }
          });
        }
        {
          jButtonPrint = new JButton4j(Common.icon_report);
          jDesktopPane1.add(jButtonPrint);
          jButtonPrint.setText(lang.get("btn_Print"));
          jButtonPrint.setMnemonic(lang.getMnemonicChar());
          jButtonPrint.setBounds(524, 110, 103, 32);
          jButtonPrint.setEnabled(true);
          jButtonPrint.addActionListener(new ActionListener() {
            public void actionPerformed(ActionEvent evt) {
              print();
            }
          });
        }
        {
          jButtonHelp = new JButton4j(Common.icon_help);
          jDesktopPane1.add(jButtonHelp);
          jButtonHelp.setText(lang.get("btn_Help"));
          jButtonHelp.setMnemonic(lang.getMnemonicChar());
          jButtonHelp.setBounds(732, 110, 103, 32);
        }
        {

          jButtonClose = new JButton4j(Common.icon_close);
          jDesktopPane1.add(jButtonClose);
          jButtonClose.setText(lang.get("btn_Close"));
          jButtonClose.setMnemonic(lang.getMnemonicChar());
          jButtonClose.setBounds(836, 110, 103, 32);
          jButtonClose.addActionListener(new ActionListener() {
            public void actionPerformed(ActionEvent evt) {
              JDBQuery2.closeStatement(listStatement);
              dispose();
            }
          });
        }
        {
          jToggleButtonSequence = new JToggleButton();
          jDesktopPane1.add(jToggleButtonSequence);
          jToggleButtonSequence.setBounds(820, 77, 21, 21);
          jToggleButtonSequence.addActionListener(new ActionListener() {
            public void actionPerformed(ActionEvent evt) {
              setSequence(jToggleButtonSequence.isSelected());
            }
          });
        }

        {
          jStatusText = new JLabel4j_std();
          jStatusText.setForeground(new Color(255, 0, 0));
          jStatusText.setBackground(Color.GRAY);
          jStatusText.setBounds(0, 487, 941, 21);
          jDesktopPane1.add(jStatusText);
        }
View Full Code Here

                  });
                  newItemMenuItem.setText(lang.get("lbl_Material_UOM_Variant"));
                  sortByMenu.add(newItemMenuItem);
                }
                {
                  jStatusText = new JLabel4j_std();
                  jStatusText.setBounds(10, 540, 985, 21);
                  jDesktopPane1.add(jStatusText);
                  jStatusText.setForeground(new Color(255, 0, 0));
                  jStatusText.setBackground(Color.GRAY);
                }
              }
            }

          }
        }
        {
          jButtonSearch1 = new JButton4j(Common.icon_search);
          jDesktopPane1.add(jButtonSearch1);
          jButtonSearch1.setText(lang.get("btn_Search"));
          jButtonSearch1.setBounds(14, 176, 129, 28);
          jButtonSearch1.setMnemonic(java.awt.event.KeyEvent.VK_S);
          jButtonSearch1.addActionListener(new ActionListener() {
            public void actionPerformed(ActionEvent evt) {
              buildSQL();
              populateList();

            }
          });
        }
        {
          jTextFieldMaterial = new JTextField4j();
          jDesktopPane1.add(jTextFieldMaterial);
          jTextFieldMaterial.setBounds(134, 44, 120, 21);
        }
        {
          jTextFieldLocation = new JTextField4j();
          jDesktopPane1.add(jTextFieldLocation);
          jTextFieldLocation.setBounds(594, 44, 98, 21);
        }
        {
          jLabel1 = new JLabel4j_std();
          jDesktopPane1.add(jLabel1);
          jLabel1.setText(lang.get("lbl_Material"));
          jLabel1.setBounds(1, 44, 121, 21);
          jLabel1.setHorizontalAlignment(SwingConstants.TRAILING);
        }
        {
          jLabel3 = new JLabel4j_std();
          jDesktopPane1.add(jLabel3);
          jLabel3.setText(lang.get("lbl_Location_ID"));
          jLabel3.setBounds(485, 44, 103, 21);
        }
        {
          ComboBoxModel jComboBox2Model = new DefaultComboBoxModel(uomList);
          jComboBoxUOM = new JComboBox4j();
          jDesktopPane1.add(jComboBoxUOM);
          jComboBoxUOM.setModel(jComboBox2Model);
          jComboBoxUOM.setBounds(865, 75, 130, 23);
          jComboBoxUOM.setMaximumRowCount(12);
        }
        {
          jLabel4 = new JLabel4j_std();
          jDesktopPane1.add(jLabel4);
          jLabel3.setHorizontalAlignment(SwingConstants.TRAILING);
          jLabel4.setText(lang.get("lbl_Pallet_UOM"));
          jLabel4.setBounds(764, 77, 96, 21);
          jLabel4.setHorizontalAlignment(SwingConstants.TRAILING);
        }
        {
          jButtonHelp = new JButton4j(Common.icon_help);
          jDesktopPane1.add(jButtonHelp);
          jButtonHelp.setText(lang.get("btn_Help"));
          jButtonHelp.setBounds(582, 176, 129, 28);
          jButtonHelp.setMnemonic(lang.getMnemonicChar());
        }
        {
          jButtonClose = new JButton4j(Common.icon_close);
          jDesktopPane1.add(jButtonClose);
          jButtonClose.setText(lang.get("btn_Close"));
          jButtonClose.setBounds(866, 176, 129, 28);
          jButtonClose.setMnemonic(lang.getMnemonicChar());
          jButtonClose.addActionListener(new ActionListener() {
            public void actionPerformed(ActionEvent evt) {
              JDBQuery2.closeStatement(listStatement);
              dispose();
            }
          });
        }
        {
          jButtonPrint = new JButton4j(Common.icon_report);
          jDesktopPane1.add(jButtonPrint);
          jButtonPrint.setText(lang.get("btn_Print"));
          jButtonPrint.setBounds(298, 176, 129, 28);
          jButtonPrint.setEnabled(Common.userList.getUser(Common.sessionID).isModuleAllowed("RPT_PALLETS"));
          jButtonPrint.setMnemonic(lang.getMnemonicChar());
          jButtonPrint.addActionListener(new ActionListener() {
            public void actionPerformed(ActionEvent evt) {
              print();
            }
          });
        }
        {
          jButtonPrint = new JButton4j(Common.icon_report);
          jDesktopPane1.add(jButtonPrint);
          jButtonPrint.setText(lang.get("btn_Print_Summary"));
          jButtonPrint.setBounds(440, 176, 129, 28);
          jButtonPrint.setEnabled(Common.userList.getUser(Common.sessionID).isModuleAllowed("RPT_HIST_SUMMARY"));
          jButtonPrint.setMnemonic(lang.getMnemonicChar());
          jButtonPrint.addActionListener(new ActionListener() {
            public void actionPerformed(ActionEvent evt) {
              print_summary();
            }
          });
        }
        {
          jLabel10 = new JLabel4j_std();
          jDesktopPane1.add(jLabel10);
          jLabel10.setText(lang.get("lbl_Limit"));
          jLabel10.setHorizontalAlignment(SwingConstants.TRAILING);
          jLabel10.setBounds(661, 145, 87, 21);
        }
        {
          ComboBoxModel jComboBoxSortByModel = new DefaultComboBoxModel(new String[] { "TRANSACTION_REF,SSCC", "TRANSACTION_TYPE,TRANSACTION_SUBTYPE", "TRANSACTION_DATE,SSCC", "MATERIAL,BATCH_NUMBER", "MATERIAL,PROCESS_ORDER", "BATCH_NUMBER,MATERIAL", "PROCESS_ORDER", "QUANTITY",
              "DATE_OF_MANUFACTURE", "STATUS", "LOCATION_ID", "UOM", "EAN", "VARIANT" });
          jComboBoxSortBy = new JComboBox4j();
          jDesktopPane1.add(jComboBoxSortBy);
          jComboBoxSortBy.setModel(jComboBoxSortByModel);
          jComboBoxSortBy.setBounds(330, 143, 299, 23);
        }
        {
          ComboBoxModel jComboBoxDefaultPalletStatusModel = new DefaultComboBoxModel(Common.palletStatusIncBlank);
          jComboBoxPalletStatus = new JComboBox4j();
          jDesktopPane1.add(jComboBoxPalletStatus);
          jComboBoxPalletStatus.setModel(jComboBoxDefaultPalletStatusModel);
          jComboBoxPalletStatus.setBounds(844, 44, 150, 23);
        }
        {
          jLabel15 = new JLabel4j_std();
          jDesktopPane1.add(jLabel15);
          jLabel15.setText(lang.get("lbl_Pallet_Status"));
          jLabel15.setHorizontalAlignment(SwingConstants.TRAILING);
          jLabel15.setBounds(731, 44, 108, 21);
        }
        {
          jToggleButtonSequence = new JToggleButton();
          jToggleButtonSequence.setSelected(true);
          jDesktopPane1.add(jToggleButtonSequence);
          jToggleButtonSequence.setBounds(637, 145, 21, 21);
          jToggleButtonSequence.addActionListener(new ActionListener() {
            public void actionPerformed(ActionEvent evt) {
              setSequence(jToggleButtonSequence.isSelected());
            }
          });
        }
        {
          jLabelQuantity = new JLabel4j_std();
          jDesktopPane1.add(jLabelQuantity);
          jLabelQuantity.setText(lang.get("lbl_Pallet_Quantity"));
          jLabelQuantity.setHorizontalAlignment(SwingConstants.TRAILING);
          jLabelQuantity.setBounds(1, 110, 121, 21);
        }
        {

          jFormattedTextFieldQuantity = new JQuantityInput(new BigDecimal("0"));
          jDesktopPane1.add(jFormattedTextFieldQuantity);
          jFormattedTextFieldQuantity.setFont(Common.font_std);
          jFormattedTextFieldQuantity.setHorizontalAlignment(SwingConstants.TRAILING);
          jFormattedTextFieldQuantity.setBounds(161, 110, 70, 21);
          jFormattedTextFieldQuantity.setVerifyInputWhenFocusTarget(false);
          jFormattedTextFieldQuantity.setEnabled(false);
        }
        {
          jLabel2 = new JLabel4j_std();
          jDesktopPane1.add(jLabel2);
          jLabel2.setText(lang.get("lbl_Material_Batch"));
          jLabel2.setHorizontalAlignment(SwingConstants.TRAILING);
          jLabel2.setBounds(266, 44, 77, 21);
        }
        {
          jTextFieldBatch = new JTextField4j();
          jDesktopPane1.add(jTextFieldBatch);
          jTextFieldBatch.setBounds(347, 44, 100, 21);
        }
        {
          jLabelProcessOrder = new JLabel4j_std();
          jDesktopPane1.add(jLabelProcessOrder);
          jLabelProcessOrder.setText(lang.get("lbl_Process_Order"));
          jLabelProcessOrder.setHorizontalAlignment(SwingConstants.TRAILING);
          jLabelProcessOrder.setBounds(691, 110, 144, 21);
        }
        {
          jTextFieldProcessOrder = new JTextField4j();
          jDesktopPane1.add(jTextFieldProcessOrder);
          jTextFieldProcessOrder.setBounds(844, 110, 119, 21);
        }
        {
          jTextFieldEAN = new JTextField4j();
          jDesktopPane1.add(jTextFieldEAN);
          jTextFieldEAN.setBounds(594, 77, 119, 21);
          jTextFieldEAN.setFocusCycleRoot(true);
        }
        {
          jLabel5 = new JLabel4j_std();
          jDesktopPane1.add(jLabel5);
          jLabel5.setText(lang.get("lbl_Material_UOM_EAN"));
          jLabel5.setHorizontalAlignment(SwingConstants.RIGHT);
          jLabel5.setHorizontalTextPosition(SwingConstants.RIGHT);
          jLabel5.setBounds(485, 77, 103, 21);
        }
        {
          jLabel6 = new JLabel4j_std();
          jDesktopPane1.add(jLabel6);
          jLabel6.setText("/");
          jLabel6.setHorizontalAlignment(SwingConstants.CENTER);
          jLabel6.setHorizontalTextPosition(SwingConstants.RIGHT);
          jLabel6.setBounds(714, 77, 10, 21);
        }
        {
          jTextFieldVariant = new JTextField4j();
          jDesktopPane1.add(jTextFieldVariant);
          jTextFieldVariant.setBounds(725, 77, 21, 21);
          jTextFieldVariant.setFocusCycleRoot(true);
        }
        {
          jCheckBoxQuantity = new JCheckBox();
          jDesktopPane1.add(jCheckBoxQuantity);
          jCheckBoxQuantity.setBackground(new java.awt.Color(255, 255, 255));
          jCheckBoxQuantity.setBounds(129, 110, 21, 21);
          jCheckBoxQuantity.addActionListener(new ActionListener() {
            public void actionPerformed(ActionEvent evt) {
              if (jCheckBoxQuantity.isSelected())
              {
                jFormattedTextFieldQuantity.setValue(0);
                jFormattedTextFieldQuantity.setEnabled(true);
              }
              else
              {
                jFormattedTextFieldQuantity.setValue(0);
                jFormattedTextFieldQuantity.setEnabled(false);
              }
            }
          });
        }
        {
          jLabel7 = new JLabel4j_std();
          jDesktopPane1.add(jLabel7);
          jLabel7.setText(lang.get("lbl_Sort_By"));
          jLabel7.setHorizontalAlignment(SwingConstants.TRAILING);
          jLabel7.setBounds(161, 145, 158, 21);
        }
        {
          SpinnerNumberModel jSpinnerIntModel = new SpinnerNumberModel();
          jSpinnerIntModel.setMinimum(1);
          jSpinnerIntModel.setMaximum(100000);
          jSpinnerIntModel.setStepSize(1);

          jSpinnerLimit = new JSpinner();
          jDesktopPane1.add(jSpinnerLimit);
         
          jSpinnerLimit.setModel(jSpinnerIntModel);
          JSpinner.NumberEditor ne = new JSpinner.NumberEditor(jSpinnerLimit);
          ne.getTextField().setFont(Common.font_std);
          jSpinnerLimit.setEditor(ne);
          jSpinnerLimit.setBounds(776, 145, 73, 21);
          jSpinnerLimit.setValue(1000);
          jSpinnerLimit.getEditor().setSize(45, 21);
        }
        {
          jCheckBoxLimit = new JCheckBox();
          jDesktopPane1.add(jCheckBoxLimit);
          jCheckBoxLimit.setBackground(new java.awt.Color(255, 255, 255));
          jCheckBoxLimit.setBounds(755, 145, 21, 21);
          jCheckBoxLimit.setSelected(true);
          jCheckBoxLimit.addActionListener(new ActionListener() {
            public void actionPerformed(ActionEvent evt) {
              if (jCheckBoxLimit.isSelected())
              {
                jSpinnerLimit.setEnabled(true);
              }
              else
              {
                jSpinnerLimit.setEnabled(false);
              }
            }
          });
        }
        {
          jButtonLookupProcessOrder = new JButton4j(Common.icon_lookup);
          jDesktopPane1.add(jButtonLookupProcessOrder);
          jButtonLookupProcessOrder.setBounds(963, 110, 21, 21);
          jButtonLookupProcessOrder.addActionListener(new ActionListener() {
            public void actionPerformed(ActionEvent evt) {
              JLaunchLookup.dlgCriteriaDefault = "Ready";
              JLaunchLookup.dlgAutoExec = true;
              if (JLaunchLookup.processOrders())
              {
                jTextFieldProcessOrder.setText(JLaunchLookup.dlgResult);
              }
            }
          });
        }
        {
          jButtonLookupBatch = new JButton4j(Common.icon_lookup);
          jDesktopPane1.add(jButtonLookupBatch);
          jButtonLookupBatch.setBounds(446, 44, 21, 21);
          jButtonLookupBatch.addActionListener(new ActionListener() {
            public void actionPerformed(ActionEvent evt) {
              JLaunchLookup.dlgCriteriaDefault = jTextFieldMaterial.getText();
              JLaunchLookup.dlgAutoExec = true;
              if (JLaunchLookup.materialBatches())
              {
                jTextFieldBatch.setText(JLaunchLookup.dlgResult);
              }
            }
          });
        }
        {
          jButtonLookupMaterial = new JButton4j(Common.icon_lookup);
          jDesktopPane1.add(jButtonLookupMaterial);
          jButtonLookupMaterial.setBounds(253, 44, 21, 21);
          jButtonLookupMaterial.addActionListener(new ActionListener() {
            public void actionPerformed(ActionEvent evt) {
              JLaunchLookup.dlgAutoExec = false;
              JLaunchLookup.dlgCriteriaDefault = "";
              if (JLaunchLookup.materials())
              {
                jTextFieldMaterial.setText(JLaunchLookup.dlgResult);
              }
            }
          });
        }
        {
          jButtonLookupLocation = new JButton4j(Common.icon_lookup);
          jDesktopPane1.add(jButtonLookupLocation);
          jButtonLookupLocation.setBounds(691, 44, 21, 21);
          jButtonLookupLocation.addActionListener(new ActionListener() {
            public void actionPerformed(ActionEvent evt) {
              JLaunchLookup.dlgAutoExec = true;
              JLaunchLookup.dlgCriteriaDefault = "Y";
              if (JLaunchLookup.locations())
              {
                jTextFieldLocation.setText(JLaunchLookup.dlgResult);
              }
            }
          });
        }
        {
          jTextFieldSSCC = new JTextField4j();
          jDesktopPane1.add(jTextFieldSSCC);
          jTextFieldSSCC.setBounds(134, 77, 140, 21);
        }
        {
          jLabelSCC = new JLabel4j_std();
          jDesktopPane1.add(jLabelSCC);
          jLabelSCC.setText(lang.get("lbl_Pallet_SSCC"));
          jLabelSCC.setBounds(1, 77, 121, 21);
          jLabelSCC.setHorizontalAlignment(SwingConstants.TRAILING);
        }

        {
          jLabel8_1 = new JLabel4j_std();
          jLabel8_1.setHorizontalAlignment(SwingConstants.TRAILING);
          jLabel8_1.setText(lang.get("lbl_Despatch_No"));
          jLabel8_1.setBounds(266, 77, 77, 21);
          jDesktopPane1.add(jLabel8_1);
        }

        {
          jTextFieldDespatch_No = new JTextField4j();
          jTextFieldDespatch_No.setFocusCycleRoot(true);
          jTextFieldDespatch_No.setBounds(347, 77, 119, 21);
          jDesktopPane1.add(jTextFieldDespatch_No);
        }

        {
          jLabel1_1 = new JLabel4j_std();
          jLabel1_1.setHorizontalAlignment(SwingConstants.TRAILING);
          jLabel1_1.setText(lang.get("lbl_Transaction_Ref"));
          jLabel1_1.setBounds(485, 110, 103, 21);
          jDesktopPane1.add(jLabel1_1);
        }

        {
          transactionDateFrom = new JDateControl();
          transactionDateFrom.setBounds(154, 7, 128, 25);
          transactionDateFrom.setEnabled(false);
          jDesktopPane1.add(transactionDateFrom);
        }

        {
          jCheckBoxTransactionDate = new JCheckBox();
          jCheckBoxTransactionDate.addActionListener(new ActionListener() {
            public void actionPerformed(final ActionEvent e) {
              if (jCheckBoxTransactionDate.isSelected())
              {
                transactionDateFrom.setEnabled(true);
                transactionDateTo.setEnabled(true);
                calendarButtontransactionDateFrom.setEnabled(true);
                calendarButtontransactionDateTo.setEnabled(true);
              }
              else
              {
                transactionDateFrom.setEnabled(false);
                transactionDateTo.setEnabled(false);
                calendarButtontransactionDateFrom.setEnabled(false);
                calendarButtontransactionDateTo.setEnabled(false);
              }
            }
          });
          jCheckBoxTransactionDate.setBackground(new Color(255, 255, 255));
          jCheckBoxTransactionDate.setText("New JCheckBox");
          jCheckBoxTransactionDate.setBounds(129, 9, 21, 21);
          jDesktopPane1.add(jCheckBoxTransactionDate);
        }

        {
          jLabel1_2 = new JLabel4j_std();
          jLabel1_2.setHorizontalAlignment(SwingConstants.TRAILING);
          jLabel1_2.setText(lang.get("lbl_Transaction_Date"));
          jLabel1_2.setBounds(1, 12, 121, 21);
          jDesktopPane1.add(jLabel1_2);
        }

        {
          jLabel1_3 = new JLabel4j_std();
          jLabel1_3.setHorizontalAlignment(SwingConstants.TRAILING);
          jLabel1_3.setText(lang.get("lbl_Transaction_Type"));
          jLabel1_3.setBounds(495, 11, 93, 21);
          jDesktopPane1.add(jLabel1_3);
        }

        {
          jLabel1_4 = new JLabel4j_std();
          jLabel1_4.setHorizontalAlignment(SwingConstants.TRAILING);
          jLabel1_4.setText(lang.get("lbl_Transaction_Subtype"));
          jLabel1_4.setBounds(721, 11, 140, 23);
          jDesktopPane1.add(jLabel1_4);
        }

        {
          comboBoxTransactionType = new JComboBox4j();
          comboBoxTransactionType.setModel(new DefaultComboBoxModel(Common.transactionTypes));
          comboBoxTransactionType.setBounds(593, 11, 124, 23);
          jDesktopPane1.add(comboBoxTransactionType);
        }

        {
          comboBoxTransactionSubtype = new JComboBox4j();
          comboBoxTransactionSubtype.setModel(new DefaultComboBoxModel(Common.transactionSubTypes));
          comboBoxTransactionSubtype.setBounds(865, 11, 130, 23);
          jDesktopPane1.add(comboBoxTransactionSubtype);
        }

        {
          jTextFieldTransaction_Ref = new JTextField4j();
          jTextFieldTransaction_Ref.setBounds(595, 110, 87, 21);
          jDesktopPane1.add(jTextFieldTransaction_Ref);
        }

        {
          transactionDateTo = new JDateControl();
          transactionDateTo.setBounds(347, 7, 128, 25);
          transactionDateTo.setEnabled(false);
          jDesktopPane1.add(transactionDateTo);
        }

        {
          final JButton4j exportXlsButton = new JButton4j(Common.icon_XLS);
          exportXlsButton.addActionListener(new ActionListener() {
            public void actionPerformed(final ActionEvent e) {
              export();
            }
          });
          exportXlsButton.setText(lang.get("btn_Excel"));
          exportXlsButton.setBounds(724, 176, 129, 28);
          jDesktopPane1.add(exportXlsButton);
        }

        {
          jTextFieldUser = new JTextField4j();
          jTextFieldUser.setBounds(348, 110, 119, 21);
          jDesktopPane1.add(jTextFieldUser);
        }

        {
          jLabel5_1 = new JLabel4j_std();
          jLabel5_1.setHorizontalAlignment(SwingConstants.TRAILING);
          jLabel5_1.setText(lang.get("lbl_User_ID"));
          jLabel5_1.setBounds(266, 110, 77, 21);
          jDesktopPane1.add(jLabel5_1);
        }
View Full Code Here

            }
          });

        }
        {
          jLabel1 = new JLabel4j_std();
          jDesktopPane1.add(jLabel1);
          jLabel1.setText(lang.get("lbl_Pallet_SSCC"));
          jLabel1.setBounds(7, 6, 133, 21);
          jLabel1.setHorizontalAlignment(SwingConstants.TRAILING);
        }
        {
          jLabel5 = new JLabel4j_std();
          jDesktopPane1.add(jLabel5);
          jLabel5.setBounds(7, 280, 133, 21);
          jLabel5.setHorizontalAlignment(SwingConstants.TRAILING);
          jLabel5.setText(lang.get("lbl_Material_UOM"));
        }
        {
          jLabel15 = new JLabel4j_std();
          jDesktopPane1.add(jLabel15);
          jLabel15.setText(lang.get("lbl_Pallet_Status"));
          jLabel15.setHorizontalAlignment(SwingConstants.TRAILING);
          jLabel15.setBounds(7, 389, 133, 21);
        }
        {
          textFieldDespatchNo = new JTextField4j();
          textFieldDespatchNo.setFocusCycleRoot(true);
          textFieldDespatchNo.setEnabled(false);
          textFieldDespatchNo.setBounds(147, 446, 119, 21);
          textFieldDespatchNo.addKeyListener(new KeyAdapter() {
            public void keyReleased(KeyEvent evt) {
              despatchNoChanged();
            }
          });
          jDesktopPane1.add(textFieldDespatchNo);
        }
        {
          ComboBoxModel<String> jComboBox1Model = new DefaultComboBoxModel<String>(Common.palletStatus);
          jComboBoxDefaultPalletStatus = new JComboBox4j<String>();
          jDesktopPane1.add(jComboBoxDefaultPalletStatus);
          jComboBoxDefaultPalletStatus.setModel(jComboBox1Model);
          jComboBoxDefaultPalletStatus.setBounds(147, 389, 168, 23);
          jComboBoxDefaultPalletStatus.setEnabled(Common.userList.getUser(Common.sessionID).isModuleAllowed("FRM_ADMIN_PALLET_EDIT_STATUS"));
          jComboBoxDefaultPalletStatus.addActionListener(new ActionListener() {
            public void actionPerformed(ActionEvent evt) {
              jButtonSave.setEnabled(true);
              jButtonUndo.setEnabled(true);
            }
          });
        }
        {
          jLabel2 = new JLabel4j_std();
          jDesktopPane1.add(jLabel2);
          jLabel2.setText(lang.get("lbl_Material"));
          jLabel2.setHorizontalAlignment(SwingConstants.TRAILING);
          jLabel2.setBounds(7, 87, 133, 21);
        }
        {
          jTextFieldMaterial = new JTextField4j();
          AbstractDocument doc = (AbstractDocument) jTextFieldMaterial.getDocument();
          doc.setDocumentFilter(new JFixedSizeFilter(JDBMaterial.field_material));
          jDesktopPane1.add(jTextFieldMaterial);
          jTextFieldMaterial.setBounds(147, 87, 119, 21);
          jTextFieldMaterial.setEditable(Common.userList.getUser(Common.sessionID).isModuleAllowed("FRM_ADMIN_PALLET_EDIT_MATERIAL"));
          jTextFieldMaterial.addKeyListener(new KeyAdapter() {
            public void keyReleased(KeyEvent evt) {
              materialChanged();
            }
          });
        }
        {
          jButtonLookupMaterial = new JButton4j(Common.icon_lookup);
          jDesktopPane1.add(jButtonLookupMaterial);
          jButtonLookupMaterial.setBounds(266, 87, 21, 21);
          jButtonLookupMaterial.setEnabled(Common.userList.getUser(Common.sessionID).isModuleAllowed("FRM_ADMIN_PALLET_EDIT_MATERIAL"));
          jButtonLookupMaterial.addActionListener(new ActionListener() {
            public void actionPerformed(ActionEvent evt) {
              JLaunchLookup.dlgAutoExec = false;
              JLaunchLookup.dlgCriteriaDefault = "";
              if (JLaunchLookup.materials()) {
                jTextFieldMaterial.setText(JLaunchLookup.dlgResult);
                materialChanged();

              }
            }
          });
        }
        {
          jLabel3 = new JLabel4j_std();
          jDesktopPane1.add(jLabel3);
          jLabel3.setText(lang.get("lbl_Material_Batch"));
          jLabel3.setHorizontalAlignment(SwingConstants.TRAILING);
          jLabel3.setBounds(7, 141, 133, 21);
        }
        {
          jTextFieldBatch = new JTextField4j();
          AbstractDocument doc = (AbstractDocument) jTextFieldBatch.getDocument();
          doc.setDocumentFilter(new JFixedSizeFilter(JDBMaterialBatch.field_batch_number));
          jDesktopPane1.add(jTextFieldBatch);
          jTextFieldBatch.setBounds(147, 141, 119, 21);
          jTextFieldBatch.setEnabled(Common.userList.getUser(Common.sessionID).isModuleAllowed("FRM_ADMIN_PALLET_EDIT_BATCH"));
          jTextFieldBatch.addKeyListener(new KeyAdapter() {
            public void keyReleased(KeyEvent evt) {
              materialBatchChanged();
            }
          });
        }
        {
          jButtonLookupBatch = new JButton4j(Common.icon_lookup);
          jDesktopPane1.add(jButtonLookupBatch);
          jButtonLookupBatch.setBounds(266, 141, 21, 21);
          jButtonLookupBatch.setEnabled(Common.userList.getUser(Common.sessionID).isModuleAllowed("FRM_ADMIN_PALLET_EDIT_BATCH"));
          jButtonLookupBatch.addActionListener(new ActionListener() {
            public void actionPerformed(ActionEvent evt) {
              JLaunchLookup.dlgCriteriaDefault = jTextFieldMaterial.getText();
              JLaunchLookup.dlgAutoExec = true;
              if (JLaunchLookup.materialBatches()) {
                jTextFieldBatch.setText(JLaunchLookup.dlgResult);
                materialBatchChanged();
              }
            }
          });
        }
        {
          jLabel4 = new JLabel4j_std();
          jDesktopPane1.add(jLabel4);
          jLabel4.setText(lang.get("lbl_Location_ID"));
          jLabel4.setHorizontalAlignment(SwingConstants.TRAILING);
          jLabel4.setBounds(7, 226, 133, 21);
        }
        {
          jTextFieldLocation = new JTextField4j();
          AbstractDocument doc = (AbstractDocument) jTextFieldLocation.getDocument();
          doc.setDocumentFilter(new JFixedSizeFilter(JDBLocation.field_location_id));
          jDesktopPane1.add(jTextFieldLocation);
          jTextFieldLocation.setBounds(147, 226, 119, 21);
          jTextFieldLocation.setEnabled(Common.userList.getUser(Common.sessionID).isModuleAllowed("FRM_ADMIN_PALLET_EDIT_LOCATION"));
          jTextFieldLocation.addKeyListener(new KeyAdapter() {
            public void keyReleased(KeyEvent evt) {
              locationChanged();
            }
          });
        }
        {
          jButtonLookupLocation = new JButton4j(Common.icon_lookup);
          jDesktopPane1.add(jButtonLookupLocation);
          jButtonLookupLocation.setBounds(266, 226, 21, 21);
          jButtonLookupLocation.setEnabled(Common.userList.getUser(Common.sessionID).isModuleAllowed("FRM_ADMIN_PALLET_EDIT_LOCATION"));
          jButtonLookupLocation.addActionListener(new ActionListener() {
            public void actionPerformed(ActionEvent evt) {
              JLaunchLookup.dlgAutoExec = true;
              JLaunchLookup.dlgCriteriaDefault = "Y";
              if (JLaunchLookup.locations()) {
                jTextFieldLocation.setText(JLaunchLookup.dlgResult);
                locationChanged();
              }
            }
          });
        }
        {
          jLabelProcessOrder = new JLabel4j_std();
          jDesktopPane1.add(jLabelProcessOrder);
          jLabelProcessOrder.setText(lang.get("lbl_Process_Order"));
          jLabelProcessOrder.setHorizontalAlignment(SwingConstants.TRAILING);
          jLabelProcessOrder.setBounds(7, 33, 133, 21);
        }
        {
          jTextFieldProcessOrder = new JTextField4j();
          AbstractDocument doc = (AbstractDocument) jTextFieldProcessOrder.getDocument();
          doc.setDocumentFilter(new JFixedSizeFilter(JDBProcessOrder.field_process_order));
          jDesktopPane1.add(jTextFieldProcessOrder);
          jTextFieldProcessOrder.setBounds(147, 33, 119, 21);
          jTextFieldProcessOrder.setEnabled(Common.userList.getUser(Common.sessionID).isModuleAllowed("FRM_ADMIN_PALLET_EDIT_PROCESS_ORDER"));
          jTextFieldProcessOrder.addKeyListener(new KeyAdapter() {
            public void keyReleased(KeyEvent evt) {
              processOrderChanged();
            }
          });
        }
        {
          jButtonLookupProcessOrder = new JButton4j(Common.icon_lookup);
          jDesktopPane1.add(jButtonLookupProcessOrder);
          jButtonLookupProcessOrder.setBounds(266, 33, 21, 21);
          jButtonLookupProcessOrder.setEnabled(Common.userList.getUser(Common.sessionID).isModuleAllowed("FRM_ADMIN_PALLET_EDIT_PROCESS_ORDER"));
          jButtonLookupProcessOrder.addActionListener(new ActionListener() {
            public void actionPerformed(ActionEvent evt) {
              JLaunchLookup.dlgCriteriaDefault = "Ready";
              JLaunchLookup.dlgAutoExec = true;
              if (JLaunchLookup.processOrders()) {
                jTextFieldProcessOrder.setText(JLaunchLookup.dlgResult);
                processOrderChanged();
              }
            }
          });
        }
        {
          jLabel6 = new JLabel4j_std();
          jDesktopPane1.add(jLabel6);
          jLabel6.setText(lang.get("lbl_Material_UOM_EAN"));
          jLabel6.setHorizontalAlignment(SwingConstants.RIGHT);
          jLabel6.setHorizontalTextPosition(SwingConstants.RIGHT);
          jLabel6.setBounds(7, 335, 133, 21);
        }
        {
          jTextFieldLayers = new JTextField4j();
          jTextFieldLayers.setFocusCycleRoot(true);
          jTextFieldLayers.setEnabled(false);
          jTextFieldLayers.setBounds(147, 308, 32, 21);
          jDesktopPane1.add(jTextFieldLayers);
        }
        {
          lblLayers = new JLabel4j_std();
          lblLayers.setText(lang.get("lbl_Pallet_Layers"));
          lblLayers.setHorizontalTextPosition(SwingConstants.RIGHT);
          lblLayers.setHorizontalAlignment(SwingConstants.RIGHT);
          lblLayers.setBounds(7, 308, 133, 21);
          jDesktopPane1.add(lblLayers);
        }
        {
          jTextFieldEAN = new JTextField4j();
          jDesktopPane1.add(jTextFieldEAN);
          jTextFieldEAN.setBounds(147, 335, 111, 21);
          jTextFieldEAN.setFocusCycleRoot(true);
          jTextFieldEAN.setEnabled(false);
        }
        {
          jLabel7 = new JLabel4j_std();
          jDesktopPane1.add(jLabel7);
          jLabel7.setText(lang.get("lbl_Material_UOM_Variant"));
          jLabel7.setHorizontalAlignment(SwingConstants.RIGHT);
          jLabel7.setHorizontalTextPosition(SwingConstants.RIGHT);
          jLabel7.setBounds(266, 335, 74, 21);
        }
        {
          jTextFieldVariant = new JTextField4j();
          jDesktopPane1.add(jTextFieldVariant);
          jTextFieldVariant.setBounds(352, 335, 32, 21);
          jTextFieldVariant.setFocusCycleRoot(true);
          jTextFieldVariant.setEnabled(false);
        }
        {
          jLabelQuantity = new JLabel4j_std();
          jDesktopPane1.add(jLabelQuantity);
          jLabelQuantity.setText(lang.get("lbl_Pallet_Quantity"));
          jLabelQuantity.setHorizontalAlignment(SwingConstants.TRAILING);
          jLabelQuantity.setBounds(7, 253, 133, 21);
        }
        {
          jFormattedTextFieldQuantity = new JQuantityInput(new BigDecimal("0"));
          jDesktopPane1.add(jFormattedTextFieldQuantity);
          jFormattedTextFieldQuantity.setFont(Common.font_std);
          jFormattedTextFieldQuantity.setHorizontalAlignment(SwingConstants.TRAILING);
          jFormattedTextFieldQuantity.setBounds(147, 253, 91, 21);
          jFormattedTextFieldQuantity.setEnabled(Common.userList.getUser(Common.sessionID).isModuleAllowed("FRM_ADMIN_PALLET_EDIT_QUANTITY"));
          jFormattedTextFieldQuantity.addKeyListener(new KeyAdapter() {
            public void keyReleased(KeyEvent evt) {
              jButtonSave.setEnabled(true);
              jButtonUndo.setEnabled(true);
            }
          });

        }
        {
          jLabelDespatchNo = new JLabel4j_std();
          jDesktopPane1.add(jLabelDespatchNo);
          jLabelDespatchNo.setText(lang.get("lbl_Despatch_No"));
          jLabelDespatchNo.setHorizontalAlignment(SwingConstants.TRAILING);
          jLabelDespatchNo.setBounds(7, 444, 133, 25);
        }
        {
          jLabelProductionDate = new JLabel4j_std();
          jDesktopPane1.add(jLabelProductionDate);
          jLabelProductionDate.setText(lang.get("lbl_Pallet_DOM"));
          jLabelProductionDate.setHorizontalAlignment(SwingConstants.TRAILING);
          jLabelProductionDate.setBounds(7, 416, 133, 25);
        }
        {
          productionDate = new JDateControl();
          jDesktopPane1.add(productionDate);
          productionDate.setBounds(147, 416, 125, 25);
          productionDate.setEnabled(Common.userList.getUser(Common.sessionID).isModuleAllowed("FRM_ADMIN_PALLET_EDIT_PROD_DATE"));

        }

        productionDate.getEditor().addKeyListener(new KeyAdapter() {
          public void keyPressed(KeyEvent e) {
            jButtonSave.setEnabled(true);
            jButtonUndo.setEnabled(true);
          }
        });

        productionDate.addChangeListener(new ChangeListener() {
          public void stateChanged(final ChangeEvent e)

          {
            jButtonSave.setEnabled(true);
            jButtonUndo.setEnabled(true);
          }
        });

        {
          jTextFieldProcessOrderDescription = new JTextField4j();
          jDesktopPane1.add(jTextFieldProcessOrderDescription);
          jTextFieldProcessOrderDescription.setBounds(147, 60, 287, 21);
          jTextFieldProcessOrderDescription.setEnabled(false);
        }
        {
          jLabel8 = new JLabel4j_std();
          jDesktopPane1.add(jLabel8);
          jLabel8.setText(lang.get("lbl_Description"));
          jLabel8.setHorizontalAlignment(SwingConstants.TRAILING);
          jLabel8.setBounds(7, 60, 133, 21);
        }
        {
          jLabel9 = new JLabel4j_std();
          jDesktopPane1.add(jLabel9);
          jLabel9.setText(lang.get("lbl_Description"));
          jLabel9.setHorizontalAlignment(SwingConstants.TRAILING);
          jLabel9.setBounds(7, 114, 133, 21);
        }
        {
          jTextFieldMaterialDescription = new JTextField4j();
          jTextFieldMaterialDescription.setEditable(false);
          jDesktopPane1.add(jTextFieldMaterialDescription);
          jTextFieldMaterialDescription.setBounds(147, 114, 287, 21);
          jTextFieldMaterialDescription.setEnabled(false);
          jTextFieldMaterialDescription.addKeyListener(new KeyAdapter() {
            public void keyReleased(KeyEvent evt) {
              jButtonSave.setEnabled(true);
              jButtonUndo.setEnabled(true);
            }
          });
        }
        {
          jLabel10 = new JLabel4j_std();
          jDesktopPane1.add(jLabel10);
          jLabel10.setText(lang.get("lbl_Material_Batch_Status"));
          jLabel10.setHorizontalAlignment(SwingConstants.TRAILING);
          jLabel10.setBounds(7, 168, 133, 21);
        }
        {
          jTextFieldBatchStatus = new JTextField4j();
          jDesktopPane1.add(jTextFieldBatchStatus);
          jTextFieldBatchStatus.setBounds(147, 168, 119, 21);
          jTextFieldBatchStatus.setEnabled(false);
          jTextFieldBatchStatus.addKeyListener(new KeyAdapter() {
            public void keyReleased(KeyEvent evt) {
              jButtonSave.setEnabled(true);
              jButtonUndo.setEnabled(true);
            }
          });
        }
        {
          expiryDate = new JDateControl();
          expiryDate.addChangeListener(new ChangeListener() {
            public void stateChanged(ChangeEvent e) {
              jButtonSave.setEnabled(true);
              jButtonUndo.setEnabled(true);
            }
          });

          jDesktopPane1.add(expiryDate);
          expiryDate.setEnabled(false);
          expiryDate.setBounds(147, 195, 125, 25);
          expiryDate.getEditor().setPreferredSize(new java.awt.Dimension(87, 19));
          expiryDate.getEditor().setSize(87, 21);
        }
        {
          jLabelBatchExpiry = new JLabel4j_std();
          jDesktopPane1.add(jLabelBatchExpiry);
          jLabelBatchExpiry.setText(lang.get("lbl_Material_Batch_Expiry_Date"));
          jLabelBatchExpiry.setHorizontalAlignment(SwingConstants.TRAILING);
          jLabelBatchExpiry.setBounds(7, 199, 133, 21);
        }
        {
          jStatusText = new JLabel4j_std();
          jDesktopPane1.add(jStatusText);
          jStatusText.setForeground(new java.awt.Color(255, 0, 0));
          jStatusText.setBorder(BorderFactory.createBevelBorder(BevelBorder.LOWERED));
          jStatusText.setBounds(0, 540, 455, 21);
        }
        {
          jButton1 = new JButton4j(Common.icon_lookup);
          jDesktopPane1.add(jButton1);
          jButton1.setBounds(266, 168, 21, 21);
          jButton1.setEnabled(Common.userList.getUser(Common.sessionID).isModuleAllowed("FRM_ADMIN_MATERIAL_BATCH_EDIT"));
          jButton1.addActionListener(new ActionListener() {
            public void actionPerformed(ActionEvent evt) {
              JLaunchMenu.runForm("FRM_ADMIN_MATERIAL_BATCH_EDIT", jTextFieldMaterial.getText(), jTextFieldBatch.getText());
            }
          });
        }
        {
          jButtonEditBatch = new JButton4j(Common.icon_edit);
          jDesktopPane1.add(jButtonEditBatch);
          jButtonEditBatch.setBounds(278, 195, 21, 25);
          jButtonEditBatch.setEnabled(Common.userList.getUser(Common.sessionID).isModuleAllowed("FRM_ADMIN_MATERIAL_BATCH_EDIT"));
          jButtonEditBatch.addActionListener(new ActionListener() {
            public void actionPerformed(ActionEvent evt) {
              JLaunchMenu.runForm("FRM_ADMIN_MATERIAL_BATCH_EDIT", jTextFieldMaterial.getText(), jTextFieldBatch.getText());
            }
          });
        }

        {
          jButtonUndo = new JButton4j(Common.icon_undo);
          jButtonUndo.addActionListener(new ActionListener() {
            public void actionPerformed(ActionEvent e) {
              refresh();
            }
          });
          jButtonUndo.setMnemonic(KeyEvent.VK_U);
          jButtonUndo.setText(lang.get("btn_Undo"));
          jButtonUndo.setBounds(116, 502, 111, 32);
          jDesktopPane1.add(jButtonUndo);
        }

        {
          jLabelProductionDate_1 = new JLabel4j_std();
          jLabelProductionDate_1.setHorizontalAlignment(SwingConstants.TRAILING);
          jLabelProductionDate_1.setText(lang.get("lbl_Confirmed"));
          jLabelProductionDate_1.setBounds(7, 470, 133, 24);
          jDesktopPane1.add(jLabelProductionDate_1);
        }

        {

          checkBoxConfirmed.setBackground(Color.WHITE);
          checkBoxConfirmed.addActionListener(new ActionListener() {
            public void actionPerformed(final ActionEvent e) {
              jButtonSave.setEnabled(true);
              jButtonUndo.setEnabled(true);
            }
          });
          checkBoxConfirmed.setText("");
          checkBoxConfirmed.setBounds(143, 470, 32, 24);
          jDesktopPane1.add(checkBoxConfirmed);
        }
        {
          calendarButtonproductionDate = new JCalendarButton(productionDate);
          calendarButtonproductionDate.setBounds(275, 418, 21, 21);
          jDesktopPane1.add(calendarButtonproductionDate);
        }
        {
          calendarButtonexpiryDate = new JCalendarButton(expiryDate);
          calendarButtonexpiryDate.setBounds(275, 197, 21, 21);
          calendarButtonexpiryDate.setVisible(false);
          jDesktopPane1.add(calendarButtonexpiryDate);
        }
        {
          JLabel4j_std label = new JLabel4j_std();
          label.setText(lang.get("lbl_Customer_ID"));
          label.setHorizontalAlignment(SwingConstants.TRAILING);
          label.setBounds(12, 362, 128, 21);
          jDesktopPane1.add(label);

          textFieldCustomer = new JTextField4j();
          textFieldCustomer.addKeyListener(new KeyAdapter() {
            public void keyReleased(KeyEvent e) {
View Full Code Here

        jDesktopPane1 = new JDesktopPane();
        jDesktopPane1.setBackground(Common.color_edit_properties);
        this.getContentPane().add(jDesktopPane1, BorderLayout.CENTER);
        jDesktopPane1.setLayout(null);
        {
          jLabel1 = new JLabel4j_std();
          jDesktopPane1.add(jLabel1);
          jLabel1.setText(lang.get("lbl_UOM_Internal"));
          jLabel1.setHorizontalAlignment(SwingConstants.RIGHT);
          jLabel1.setHorizontalTextPosition(SwingConstants.RIGHT);
          jLabel1.setBounds(0, 10, 149, 21);
        }
        {
          jTextFieldUOM = new JTextField4j();
          jDesktopPane1.add(jTextFieldUOM);
          jTextFieldUOM.setHorizontalAlignment(SwingConstants.LEFT);
          jTextFieldUOM.setEditable(false);
          jTextFieldUOM.setPreferredSize(new java.awt.Dimension(100, 20));
          jTextFieldUOM.setBounds(155, 10, 51, 21);
          jTextFieldUOM.setEnabled(false);
        }
        {
          jLabel2 = new JLabel4j_std();
          jDesktopPane1.add(jLabel2);
          jLabel2.setText(lang.get("lbl_UOM_ISO"));
          jLabel2.setHorizontalAlignment(SwingConstants.RIGHT);
          jLabel2.setHorizontalTextPosition(SwingConstants.RIGHT);
          jLabel2.setBounds(0, 43, 149, 21);
        }
        {
          jTextFieldISO_UOM = new JTextField4j();
          AbstractDocument doc = (AbstractDocument) jTextFieldISO_UOM.getDocument();
          doc.setDocumentFilter(new JFixedSizeFilter(JDBUom.field_uom));
          jDesktopPane1.add(jTextFieldISO_UOM);
          jTextFieldISO_UOM.setPreferredSize(new java.awt.Dimension(40, 20));
          jTextFieldISO_UOM.setFocusCycleRoot(true);
          jTextFieldISO_UOM.setBounds(155, 43, 53, 21);
          jTextFieldISO_UOM.addKeyListener(new KeyAdapter() {
            public void keyTyped(KeyEvent evt) {
              jButtonUpdate.setEnabled(true);
            }
          });
        }
        {
          jButtonUpdate = new JButton4j(Common.icon_update);
          jDesktopPane1.add(jButtonUpdate);
          jButtonUpdate.setEnabled(false);
          jButtonUpdate.setText(lang.get("btn_Save"));
          jButtonUpdate.setMnemonic(lang.getMnemonicChar());
          jButtonUpdate.setHorizontalTextPosition(SwingConstants.RIGHT);
          jButtonUpdate.setBounds(45, 142, 110, 32);
          jButtonUpdate.addActionListener(new ActionListener() {
            public void actionPerformed(ActionEvent evt) {
              uom.setIsoUom(jTextFieldISO_UOM.getText().toUpperCase());
              uom.setDescription(jTextFieldDescription.getText().toUpperCase());
              uom.setLocalUom(jTextFieldLocal_UOM.getText().toUpperCase());
              uom.update();
              jButtonUpdate.setEnabled(false);
            }
          });
        }
        {
          jButtonHelp = new JButton4j(Common.icon_help);
          jDesktopPane1.add(jButtonHelp);
          jButtonHelp.setText(lang.get("btn_Help"));
          jButtonHelp.setMnemonic(lang.getMnemonicChar());
          jButtonHelp.setBounds(157, 142, 110, 32);
        }
        {
          jButtonClose = new JButton4j(Common.icon_close);
          jDesktopPane1.add(jButtonClose);
          jButtonClose.setText(lang.get("btn_Close"));
          jButtonClose.setMnemonic(lang.getMnemonicChar());
          jButtonClose.setBounds(269, 142, 110, 32);
          jButtonClose.addActionListener(new ActionListener() {
            public void actionPerformed(ActionEvent evt) {
              dispose();
            }
          });
        }
        {
          jLabel3 = new JLabel4j_std();
          jDesktopPane1.add(jLabel3);
          jLabel3.setText(lang.get("lbl_Description"));
          jLabel3.setHorizontalAlignment(SwingConstants.RIGHT);
          jLabel3.setHorizontalTextPosition(SwingConstants.RIGHT);
          jLabel3.setBounds(0, 109, 149, 21);
        }
        {
          jTextFieldLocal_UOM = new JTextField4j();
          jTextFieldLocal_UOM.addKeyListener(new KeyAdapter() {
            @Override
            public void keyTyped(KeyEvent e) {
              jButtonUpdate.setEnabled(true);
            }
          });
          jTextFieldLocal_UOM.setPreferredSize(new Dimension(40, 20));
          jTextFieldLocal_UOM.setFocusCycleRoot(true);
          jTextFieldLocal_UOM.setCaretPosition(0);
          jTextFieldLocal_UOM.setBounds(155, 76, 53, 21);
          jDesktopPane1.add(jTextFieldLocal_UOM);
        }
        {
          lblLocalUom = new JLabel4j_std();
          lblLocalUom.setText(lang.get("lbl_UOM_Local"));
          lblLocalUom.setHorizontalTextPosition(SwingConstants.RIGHT);
          lblLocalUom.setHorizontalAlignment(SwingConstants.RIGHT);
          lblLocalUom.setBounds(0, 76, 149, 21);
          jDesktopPane1.add(lblLocalUom);
View Full Code Here

    JDesktopPane desktopPane = new JDesktopPane();
    desktopPane.setBackground(Color.WHITE);
    desktopPane.setBounds(0, 0, 861, 207);
    getContentPane().add(desktopPane);
   
    JLabel4j_std lblInspectionID = new JLabel4j_std(lang.get("lbl_Inspection_ID"));
    lblInspectionID.setBounds(8, 27, 87, 16);
    desktopPane.add(lblInspectionID);
    lblInspectionID.setHorizontalAlignment(SwingConstants.TRAILING);
   
    JLabel4j_std lblActivityID = new JLabel4j_std(lang.get("lbl_Activity_ID"));
    lblActivityID.setBounds(6, 67, 89, 16);
    desktopPane.add(lblActivityID);
    lblActivityID.setHorizontalAlignment(SwingConstants.TRAILING);
   
    JLabel4j_std lblTestID = new JLabel4j_std(lang.get("lbl_Test_ID"));
    lblTestID.setBounds(188, 105, 98, 16);
    desktopPane.add(lblTestID);
    lblTestID.setHorizontalAlignment(SwingConstants.TRAILING);
   
    textFieldInspectionID = new JTextField4j();
    textFieldInspectionID.setEnabled(false);
    textFieldInspectionID.setBounds(108, 22, 153, 28);
    desktopPane.add(textFieldInspectionID);
    textFieldInspectionID.setColumns(10);
   
    JLabel4j_std label4j_std = new JLabel4j_std(lang.get("lbl_Sequence_ID"));
    label4j_std.setBounds(8, 105, 87, 16);
    desktopPane.add(label4j_std);
    label4j_std.setHorizontalAlignment(SwingConstants.TRAILING);
   
    comboBoxTestID = new JComboBox4j();
    comboBoxTestID.addActionListener(new ActionListener() {
      public void actionPerformed(ActionEvent arg0) {
        enableSave();
      }
    });
    comboBoxTestID.setBounds(298, 102, 542, 27);
    desktopPane.add(comboBoxTestID);
   
    spinnerSequence = new JSpinner();
    spinnerSequence.setBounds(108, 102, 68, 28);
    ne = new JSpinner.NumberEditor(spinnerSequence);
    ne.getTextField().setFont(Common.font_std);
    spinnerSequence.setEditor(ne);
    spinnerSequence.setValue(100);
    spinnerSequence.addChangeListener(new ChangeListener() {
      public void stateChanged(ChangeEvent arg0) {
        enableSave();
      }
    });
    desktopPane.add(spinnerSequence);
   
    textFieldInspectionDescription = new JTextField4j();
    textFieldInspectionDescription.setEnabled(false);
    textFieldInspectionDescription.setBounds(377, 22, 463, 28);
    desktopPane.add(textFieldInspectionDescription);
    textFieldInspectionDescription.setColumns(10);
   

   
    btnSave = new JButton4j(lang.get("btn_Save"));
    btnSave.setEnabled(false);
    btnSave.addActionListener(new ActionListener() {
      public void actionPerformed(ActionEvent arg0) {
        save();
      }
    });
    btnSave.setIcon(Common.icon_save);
    btnSave.setBounds(319, 154, 117, 29);
    desktopPane.add(btnSave);
   
    btnClose = new JButton4j(lang.get("btn_Close"));
    btnClose.addActionListener(new ActionListener() {
      public void actionPerformed(ActionEvent arg0) {
        dispose();
      }
    });
    btnClose.setIcon(Common.icon_close);
    btnClose.setBounds(440, 154, 117, 29);
    desktopPane.add(btnClose);
   
    JLabel4j_std label4j_std_1 = new JLabel4j_std(lang.get("lbl_Description"));
    label4j_std_1.setHorizontalAlignment(SwingConstants.TRAILING);
    label4j_std_1.setBounds(273, 27, 92, 16);
    desktopPane.add(label4j_std_1);
   
    textFieldActivityID = new JTextField4j();
    textFieldActivityID.setEnabled(false);
    textFieldActivityID.setText("<dynamic>");
    textFieldActivityID.setColumns(10);
    textFieldActivityID.setBounds(108, 62, 153, 28);
    desktopPane.add(textFieldActivityID);
   
    JLabel4j_std label4j_std_2 = new JLabel4j_std(lang.get("lbl_Description"));
    label4j_std_2.setHorizontalAlignment(SwingConstants.TRAILING);
    label4j_std_2.setBounds(267, 67, 98, 16);
    desktopPane.add(label4j_std_2);
   
    textFieldActivityDescription = new JTextField4j();
    textFieldActivityDescription.setEnabled(false);
    textFieldActivityDescription.setColumns(10);
View Full Code Here

TOP

Related Classes of com.commander4j.gui.JLabel4j_std

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.