Package com.commander4j.gui

Examples of com.commander4j.gui.JTextField4j


    lblUsedMemory.setText("Used Memory :");
    lblUsedMemory.setHorizontalAlignment(SwingConstants.TRAILING);
    lblUsedMemory.setBounds(530, 352, 91, 21);
    jDesktopPane1.add(lblUsedMemory);
   
    textFieldUsedMemory = new JTextField4j();
    textFieldUsedMemory.setText(String.valueOf((Runtime.getRuntime().totalMemory()-Runtime.getRuntime().freeMemory())/1024) + "k");
    textFieldUsedMemory.setHorizontalAlignment(SwingConstants.TRAILING);
    textFieldUsedMemory.setEnabled(false);
    textFieldUsedMemory.setEditable(false);
    textFieldUsedMemory.setBounds(632, 353, 119, 21);
    jDesktopPane1.add(textFieldUsedMemory);
   
    JLabel4j_std lblLocale = new JLabel4j_std();
    lblLocale.setText("Locale :");
    lblLocale.setHorizontalAlignment(SwingConstants.TRAILING);
    lblLocale.setBounds(476, 12, 58, 21);
    jDesktopPane1.add(lblLocale);
   
    textFieldLocale = new JTextField4j();
    textFieldLocale.setEnabled(false);
    textFieldLocale.setEditable(false);
    textFieldLocale.setBounds(539, 11, 58, 20);
    jDesktopPane1.add(textFieldLocale);
    textFieldLocale.setText(Locale.getDefault().getCountry()+","+Locale.getDefault().getLanguage());
View Full Code Here


          jLabel11.setText("User Home :");
          jLabel11.setHorizontalAlignment(SwingConstants.TRAILING);
          jLabel11.setBounds(27, 165, 90, 21);
        }
        {
          jTextFieldJavaHome = new JTextField4j();
          jDesktopPane1.add(jTextFieldJavaHome);
          jTextFieldJavaHome.setBounds(129, 42, 622, 20);
          jTextFieldJavaHome.setEditable(false);
          jTextFieldJavaHome.setEnabled(false);
        }
        {
          jTextFieldJavaVersion = new JTextField4j();
          jDesktopPane1.add(jTextFieldJavaVersion);
          jTextFieldJavaVersion.setBounds(129, 11, 100, 20);
          jTextFieldJavaVersion.setEditable(false);
          jTextFieldJavaVersion.setEnabled(false);
        }
        {
          jTextFieldJavaVMVersion = new JTextField4j();
          jDesktopPane1.add(jTextFieldJavaVMVersion);
          jTextFieldJavaVMVersion.setBounds(360, 11, 100, 20);
          jTextFieldJavaVMVersion.setEditable(false);
          jTextFieldJavaVMVersion.setEnabled(false);
        }
        {
          jTextFieldOSName = new JTextField4j();
          jDesktopPane1.add(jTextFieldOSName);
          jTextFieldOSName.setBounds(129, 73, 100, 20);
          jTextFieldOSName.setEditable(false);
          jTextFieldOSName.setEnabled(false);
        }
        {
          jTextFieldOSArchitecture = new JTextField4j();
          jDesktopPane1.add(jTextFieldOSArchitecture);
          jTextFieldOSArchitecture.setBounds(360, 73, 100, 20);
          jTextFieldOSArchitecture.setEditable(false);
          jTextFieldOSArchitecture.setEnabled(false);
        }
        {
          jTextFieldOSVersion = new JTextField4j();
          jDesktopPane1.add(jTextFieldOSVersion);
          jTextFieldOSVersion.setBounds(582, 73, 169, 20);
          jTextFieldOSVersion.setEditable(false);
          jTextFieldOSVersion.setEnabled(false);
        }
        {
          jTextFieldUserName = new JTextField4j();
          jDesktopPane1.add(jTextFieldUserName);
          jTextFieldUserName.setEditable(false);
          jTextFieldUserName.setBounds(129, 104, 231, 20);
        }
        {
          jTextFieldUserHome = new JTextField4j();
          jDesktopPane1.add(jTextFieldUserHome);
          jTextFieldUserHome.setEditable(false);
          jTextFieldUserHome.setBounds(129, 166, 624, 20);
          jTextFieldUserHome.setEnabled(false);
        }
        {
          jTextFieldUserDir = new JTextField4j();
          jDesktopPane1.add(jTextFieldUserDir);
          jTextFieldUserDir.setEditable(false);
          jTextFieldUserDir.setBounds(129, 197, 624, 20);
          jTextFieldUserDir.setEnabled(false);
        }
        {
          jTextFieldDatabaseProductName = new JTextField4j();
          jDesktopPane1.add(jTextFieldDatabaseProductName);
          jTextFieldDatabaseProductName.setEditable(false);
          jTextFieldDatabaseProductName.setBounds(129, 228, 231, 20);
          jTextFieldDatabaseProductName.setEnabled(false);
        }
        {
          jLabel5 = new JLabel4j_std();
          jDesktopPane1.add(jLabel5);
          jLabel5.setText("Base Dir :");
          jLabel5.setHorizontalAlignment(SwingConstants.TRAILING);
          jLabel5.setBounds(27, 196, 90, 21);
        }
        {
          jTextFieldDatabaseProductVersion = new JTextField4j();
          jDesktopPane1.add(jTextFieldDatabaseProductVersion);
          jTextFieldDatabaseProductVersion.setEditable(false);
          jTextFieldDatabaseProductVersion.setBounds(129, 259, 623, 20);
          jTextFieldDatabaseProductVersion.setEnabled(false);
        }
        {
          jLabel6 = new JLabel4j_std();
          jDesktopPane1.add(jLabel6);
          jLabel6.setText("Version :");
          jLabel6.setHorizontalAlignment(SwingConstants.TRAILING);
          jLabel6.setBounds(66, 320, 51, 21);
        }
        {
          jLabel12 = new JLabel4j_std();
          jDesktopPane1.add(jLabel12);
          jLabel12.setText("Database Name :");
          jLabel12.setHorizontalAlignment(SwingConstants.TRAILING);
          jLabel12.setBounds(17, 227, 100, 21);
        }
        {
          jTextFieldJDBCDriverName = new JTextField4j();
          jDesktopPane1.add(jTextFieldJDBCDriverName);
          jTextFieldJDBCDriverName.setEditable(false);
          jTextFieldJDBCDriverName.setBounds(129, 290, 231, 20);
          jTextFieldJDBCDriverName.setEnabled(false);
        }
        {
          jTextFieldJDBCDriverVersion = new JTextField4j();
          jDesktopPane1.add(jTextFieldJDBCDriverVersion);
          jTextFieldJDBCDriverVersion.setEditable(false);
          jTextFieldJDBCDriverVersion.setBounds(129, 321, 622, 20);
          jTextFieldJDBCDriverVersion.setEnabled(false);
        }
        {
          jLabel13 = new JLabel4j_std();
          jDesktopPane1.add(jLabel13);
          jLabel13.setText("Driver Name :");
          jLabel13.setHorizontalAlignment(SwingConstants.TRAILING);
          jLabel13.setBounds(37, 289, 80, 21);
        }
        {
          jTextFieldTotalMemory = new JTextField4j();
          jDesktopPane1.add(jTextFieldTotalMemory);
          jTextFieldTotalMemory.setEditable(false);
          jTextFieldTotalMemory.setEnabled(false);
          jTextFieldTotalMemory.setBounds(129, 352, 119, 21);
          jTextFieldTotalMemory.setHorizontalAlignment(SwingConstants.TRAILING);
        }
        {
          jTextFieldFreeMemory = new JTextField4j();
          jDesktopPane1.add(jTextFieldFreeMemory);
          jTextFieldFreeMemory.setEditable(false);
          jTextFieldFreeMemory.setEnabled(false);
          jTextFieldFreeMemory.setBounds(359, 352, 119, 21);
          jTextFieldFreeMemory.setHorizontalAlignment(SwingConstants.TRAILING);
        }
        {
          jLabel14 = new JLabel4j_std();
          jDesktopPane1.add(jLabel14);
          jLabel14.setText("Total Memory :");
          jLabel14.setHorizontalAlignment(SwingConstants.TRAILING);
          jLabel14.setBounds(12, 352, 105, 21);
        }
        {
          jLabel15 = new JLabel4j_std();
          jDesktopPane1.add(jLabel15);
          jLabel15.setText("Free Memory :");
          jLabel15.setHorizontalAlignment(SwingConstants.TRAILING);
          jLabel15.setBounds(254, 352, 91, 21);
        }

        {
          jLabel101 = new JLabel4j_std();
          jLabel101.setHorizontalAlignment(SwingConstants.TRAILING);
          jLabel101.setText("Client Name :");
          jLabel101.setBounds(24, 134, 93, 21);
          jDesktopPane1.add(jLabel101);
        }

        {
          jTextFieldClientName = new JTextField4j();
          jTextFieldClientName.setEditable(false);
          jTextFieldClientName.setBounds(129, 135, 231, 20);
          jTextFieldClientName.setText(JUtility.getClientName());
          jDesktopPane1.add(jTextFieldClientName);
        }

        {
          jLabel102 = new JLabel4j_std();
          jLabel102.setHorizontalAlignment(SwingConstants.TRAILING);
            jLabel102.setText("Application User Name :");
          jLabel102.setBounds(355, 103, 146, 21);
          jDesktopPane1.add(jLabel102);
        }

        {
          jTextFieldUserNameApp = new JTextField4j();
          jTextFieldUserNameApp.setEditable(false);
          jTextFieldUserNameApp.setBounds(520, 104, 231, 20);
          jTextFieldUserNameApp.setText(Common.userList.getUser(Common.sessionID).getUserId());
          jDesktopPane1.add(jTextFieldUserNameApp);
        }

        {
          jLabel102_1 = new JLabel4j_std();
          jLabel102_1.setHorizontalAlignment(SwingConstants.TRAILING);
          jLabel102_1.setText("Session ID :");
          jLabel102_1.setBounds(383, 134, 118, 21);
          jDesktopPane1.add(jLabel102_1);
        }

        {
          jTextFieldUserSessionID = new JTextField4j();
          jTextFieldUserSessionID.setEditable(false);
          jTextFieldUserSessionID.setBounds(520, 134, 231, 20);
          jDesktopPane1.add(jTextFieldUserSessionID);
        }

        {
          jTextFieldUserHostID = new JTextField4j();
          jTextFieldUserHostID.setEditable(false);
          jTextFieldUserHostID.setBounds(435, 228, 32, 20);
          jDesktopPane1.add(jTextFieldUserHostID);
        }

        {
          jLabel102_2 = new JLabel4j_std();
          jLabel102_2.setHorizontalAlignment(SwingConstants.TRAILING);
          jLabel102_2.setText("Host ID :");
          jLabel102_2.setBounds(383, 227, 51, 21);
          jDesktopPane1.add(jLabel102_2);
        }

        {
          jTextFieldUserHostDescription = new JTextField4j();
          jTextFieldUserHostDescription.setBounds(481, 228, 270, 20);
          jTextFieldUserHostDescription.setEditable(false);
          jDesktopPane1.add(jTextFieldUserHostDescription);
        }

        {
          jLabel102_3 = new JLabel4j_std();
          jLabel102_3.setHorizontalAlignment(SwingConstants.TRAILING);
          jLabel102_3.setText("Unique Host Ref :");
          jLabel102_3.setBounds(383, 289, 95, 21);
          jDesktopPane1.add(jLabel102_3);
        }

        {
          jTextFieldHosyUniqueRef = new JTextField4j();
          jTextFieldHosyUniqueRef.setEditable(false);
          jTextFieldHosyUniqueRef.setBounds(481, 289, 270, 20);
          jDesktopPane1.add(jTextFieldHosyUniqueRef);
        }
      }
View Full Code Here

      jPanelProcessOrder.setBorder(BorderFactory.createTitledBorder(lang.get("lbl_Process_Order")));
      jPanelProcessOrder.setLayout(null);
      jPanelProcessOrder.setBackground(new java.awt.Color(255, 255, 255));

      {
        jTextFieldProcessOrder = new JTextField4j();
        jPanelProcessOrder.add(jTextFieldProcessOrder);

        AbstractDocument doc = (AbstractDocument) jTextFieldProcessOrder.getDocument();
        doc.setDocumentFilter(new JFixedSizeFilter(JDBProcessOrder.field_process_order));
        jTextFieldProcessOrder.setBounds(161, 21, 119, 21);
        jTextFieldProcessOrder.addKeyListener(new KeyAdapter() {
          public void keyReleased(KeyEvent evt)
          {
            processOrderChanged(jTextFieldProcessOrder.getText());
          }
        });
      }

      jLabelProcessOrder = new JLabel4j_std();
      jPanelProcessOrder.add(jLabelProcessOrder);
      jLabelProcessOrder.setText(lang.get("lbl_Process_Order"));
      jLabelProcessOrder.setHorizontalAlignment(SwingConstants.TRAILING);
      jLabelProcessOrder.setBounds(12, 21, 142, 21);
      jTextFieldProcessOrderDescription = new JTextField4j();
      jPanelProcessOrder.add(jTextFieldProcessOrderDescription);
      jTextFieldProcessOrderDescription.setBounds(449, 21, 287, 21);
      jTextFieldProcessOrderDescription.setEditable(false);
      jTextFieldProcessOrderDescription.setEnabled(false);
      jLabelOrderDescription = new JLabel4j_std();
      jPanelProcessOrder.add(jLabelOrderDescription);
      jLabelOrderDescription.setText(lang.get("lbl_Description"));
      jLabelOrderDescription.setHorizontalAlignment(SwingConstants.TRAILING);
      jLabelOrderDescription.setBounds(306, 21, 136, 21);
      jLabelOrderStatus = new JLabel4j_std();
      jPanelProcessOrder.add(jLabelOrderStatus);
      jLabelOrderStatus.setText(lang.get("lbl_Process_Order_Status"));
      jLabelOrderStatus.setHorizontalAlignment(SwingConstants.TRAILING);
      jLabelOrderStatus.setBounds(290, 49, 152, 21);
      jSpinnerDueDate = new JDateControl();
      jPanelProcessOrder.add(jSpinnerDueDate);
      jSpinnerDueDate.setEnabled(false);
      jSpinnerDueDate.setBounds(161, 49, 137, 21);
      jSpinnerDueDate.getEditor().setOpaque(true);
      jSpinnerDueDate.setForeground(new java.awt.Color(238, 238, 238));
      jLabelDueDate = new JLabel4j_std();
      jPanelProcessOrder.add(jLabelDueDate);
      jLabelDueDate.setText(lang.get("lbl_Process_Order_Due_Date"));
      jLabelDueDate.setHorizontalAlignment(SwingConstants.TRAILING);
      jLabelDueDate.setBounds(12, 49, 142, 21);
      jTextFieldProcessOrderStatus = new JTextField4j();
      jPanelProcessOrder.add(jTextFieldProcessOrderStatus);
      jTextFieldProcessOrderStatus.setBounds(449, 49, 126, 21);
      jTextFieldProcessOrderStatus.setEditable(false);
      jTextFieldProcessOrderStatus.setEnabled(false);
      jTextFieldRecipe = new JTextField4j();
      jPanelProcessOrder.add(jTextFieldRecipe);
      jTextFieldRecipe.setBounds(161, 77, 139, 21);
      jTextFieldRecipe.setEditable(false);
      jTextFieldRecipe.setEnabled(false);
      jLabelRecipe = new JLabel4j_std();
      jPanelProcessOrder.add(jLabelRecipe);
      jLabelRecipe.setText(lang.get("lbl_Process_Order_Recipe"));
      jLabelRecipe.setHorizontalAlignment(SwingConstants.TRAILING);
      jLabelRecipe.setBounds(12, 77, 142, 21);
      jTextFieldLocation = new JTextField4j();
      jPanelProcessOrder.add(jTextFieldLocation);
      jTextFieldLocation.setBounds(449, 77, 126, 21);
      jTextFieldLocation.setEditable(false);
      jTextFieldLocation.setEnabled(false);
      jLabelLocation = new JLabel4j_std();
      jPanelProcessOrder.add(jLabelLocation);
      jLabelLocation.setText(lang.get("lbl_Location_ID"));
      jLabelLocation.setHorizontalAlignment(SwingConstants.TRAILING);
      jLabelLocation.setBounds(290, 77, 152, 21);
      jButtonPOLookup = new JButton4j(Common.icon_lookup);
      jPanelProcessOrder.add(jButtonPOLookup);
      jButtonPOLookup.setBounds(280, 21, 20, 20);
      jButtonPOLookup.addActionListener(new ActionListener() {
        public void actionPerformed(ActionEvent evt)
        {
          JLaunchLookup.dlgCriteriaDefault = "Ready";
          JLaunchLookup.dlgAutoExec = true;

          if (JLaunchLookup.processOrders())
          {
            String po = JLaunchLookup.dlgResult;
            processOrderChanged(po);
          }
        }
      });
      jPanelMaterial = new JPanel();
      jDesktopPane1.add(jPanelMaterial);
      jPanelMaterial.setBounds(7, 119, 748, 112);
      jPanelMaterial.setBorder(BorderFactory.createTitledBorder(lang.get("lbl_Material")));
      jPanelMaterial.setLayout(null);
      jPanelMaterial.setFont(Common.font_title);
      jPanelMaterial.setBackground(new java.awt.Color(255, 255, 255));
      jTextFieldMaterial = new JTextField4j();
      jPanelMaterial.add(jTextFieldMaterial);
      jTextFieldMaterial.setBounds(161, 21, 128, 21);
      jTextFieldMaterial.setEditable(false);
      jTextFieldMaterial.setEnabled(false);

      jLabelMaterial = new JLabel4j_std();
      jPanelMaterial.add(jLabelMaterial);
      jLabelMaterial.setText(lang.get("lbl_Material"));
      jLabelMaterial.setHorizontalAlignment(SwingConstants.TRAILING);
      jLabelMaterial.setBounds(12, 21, 142, 21);
      jTextFieldMaterialDescription = new JTextField4j();
      jPanelMaterial.add(jTextFieldMaterialDescription);
      jTextFieldMaterialDescription.setBounds(449, 21, 287, 21);
      jTextFieldMaterialDescription.setEditable(false);
      jTextFieldMaterialDescription.setEnabled(false);
      jLabelDescription = new JLabel4j_std();
      jPanelMaterial.add(jLabelDescription);
      jLabelDescription.setText(lang.get("lbl_Description"));
      jLabelDescription.setHorizontalAlignment(SwingConstants.TRAILING);
      jLabelDescription.setBounds(291, 21, 151, 21);
      jSpinnerShelfLife = new JSpinner();
      jPanelMaterial.add(jSpinnerShelfLife);
      jSpinnerShelfLife.setModel(shelflifenumbermodel);
      JSpinner.NumberEditor nec = new JSpinner.NumberEditor(jSpinnerShelfLife);
      nec.getTextField().setFont(Common.font_std);
      jSpinnerShelfLife.setEditor(nec);
      jSpinnerShelfLife.setBounds(161, 49, 63, 21);
      jSpinnerShelfLife.setEnabled(false);
      jTextFieldShelfLifeRoundingRule = new JTextField4j();
      jPanelMaterial.add(jTextFieldShelfLifeRoundingRule);
      jTextFieldShelfLifeRoundingRule.setBounds(638, 49, 98, 21);
      jTextFieldShelfLifeRoundingRule.setEditable(false);
      jTextFieldShelfLifeRoundingRule.setEnabled(false);
      jLabelRounding = new JLabel4j_std();
      jPanelMaterial.add(jLabelRounding);
      jLabelRounding.setText(lang.get("lbl_Material_Shelf_Life_Rounding_Rule"));
      jLabelRounding.setHorizontalAlignment(SwingConstants.TRAILING);
      jLabelRounding.setBounds(546, 49, 85, 21);
      jTextFieldShelfLifeUOM = new JTextField4j();
      jPanelMaterial.add(jTextFieldShelfLifeUOM);
      jTextFieldShelfLifeUOM.setBounds(449, 49, 91, 21);
      jTextFieldShelfLifeUOM.setEditable(false);
      jTextFieldShelfLifeUOM.setEnabled(false);
      jLabel1ShelfLifeUOM = new JLabel4j_std();
      jPanelMaterial.add(jLabel1ShelfLifeUOM);
      jLabel1ShelfLifeUOM.setText(lang.get("lbl_Material_Shelf_Life_UOM"));
      jLabel1ShelfLifeUOM.setHorizontalAlignment(SwingConstants.TRAILING);
      jLabel1ShelfLifeUOM.setBounds(281, 49, 161, 21);
      jLabelShelfLife = new JLabel4j_std();
      jPanelMaterial.add(jLabelShelfLife);
      jLabelShelfLife.setText(lang.get("lbl_Material_Shelf_Life"));
      jLabelShelfLife.setHorizontalAlignment(SwingConstants.TRAILING);
      jLabelShelfLife.setBounds(12, 49, 142, 21);
      jTextFieldLegacyCode = new JTextField4j();
      jPanelMaterial.add(jTextFieldLegacyCode);
      jTextFieldLegacyCode.setBounds(161, 77, 128, 21);
      jTextFieldLegacyCode.setEditable(false);
      jTextFieldLegacyCode.setEnabled(false);
      jLabelLegacyCode = new JLabel4j_std();
      jPanelMaterial.add(jLabelLegacyCode);
      jLabelLegacyCode.setText(lang.get("lbl_Material_Legacy_Code"));
      jLabelLegacyCode.setHorizontalAlignment(SwingConstants.TRAILING);
      jLabelLegacyCode.setBounds(12, 77, 142, 21);
      jLabelEAN = new JLabel4j_std();
      jPanelMaterial.add(jLabelEAN);
      jLabelEAN.setText(lang.get("lbl_Material_UOM_EAN"));
      jLabelEAN.setHorizontalAlignment(SwingConstants.RIGHT);
      jLabelEAN.setHorizontalTextPosition(SwingConstants.RIGHT);
      jLabelEAN.setBounds(291, 77, 151, 21);
      jTextFieldEAN = new JTextField4j();
      jPanelMaterial.add(jTextFieldEAN);
      jTextFieldEAN.setBounds(449, 77, 126, 21);
      jTextFieldEAN.setFocusCycleRoot(true);
      jTextFieldEAN.setEditable(false);
      jTextFieldEAN.setEnabled(false);
      jLabelVariant = new JLabel4j_std();
      jPanelMaterial.add(jLabelVariant);
      jLabelVariant.setText(lang.get("lbl_Material_UOM_Variant"));
      jLabelVariant.setHorizontalAlignment(SwingConstants.RIGHT);
      jLabelVariant.setHorizontalTextPosition(SwingConstants.RIGHT);
      jLabelVariant.setBounds(579, 77, 110, 21);
      jTextFieldVariant = new JTextField4j();
      jPanelMaterial.add(jTextFieldVariant);
      jTextFieldVariant.setBounds(701, 77, 35, 21);
      jTextFieldVariant.setFocusCycleRoot(true);
      jTextFieldVariant.setEditable(false);
      jTextFieldVariant.setEnabled(false);
      jPanelPallet = new JPanel();
      jDesktopPane1.add(jPanelPallet);
      jPanelPallet.setBounds(7, 231, 748, 84);
      jPanelPallet.setBorder(BorderFactory.createTitledBorder(null, lang.get("lbl_Pallet"), TitledBorder.LEADING, TitledBorder.TOP));
      jPanelPallet.setLayout(null);
      jPanelPallet.setFont(Common.font_std);
      jPanelPallet.setBackground(new java.awt.Color(255, 255, 255));
      jLabelQuantity = new JLabel4j_std();
      jPanelPallet.add(jLabelQuantity);
      jLabelQuantity.setText(lang.get("lbl_Pallet_Quantity"));
      jLabelQuantity.setHorizontalAlignment(SwingConstants.TRAILING);
      jLabelQuantity.setBounds(323, 21, 119, 21);
      comboBoxPrintQueue = new JComboBox4j();
      comboBoxPrintQueue.setBounds(116, 455, 621, 23);
      jDesktopPane1.add(comboBoxPrintQueue);

      {
        jTextFieldSSCC = new JTextField4j();
        jPanelPallet.add(jTextFieldSSCC);
        AbstractDocument doc = (AbstractDocument) jTextFieldSSCC.getDocument();
        doc.setDocumentFilter(new JFixedSizeFilter(JDBPallet.field_sscc));
        jTextFieldSSCC.setBounds(161, 18, 128, 21);
        jTextFieldSSCC.setEnabled(false);
        jTextFieldSSCC.addKeyListener(new KeyAdapter() {
          public void keyReleased(KeyEvent evt)
          {
            checkSSCC();
          }
        });
      }

      jSpinnerProductionDate = new JDateControl();
      jPanelPallet.add(jSpinnerProductionDate);
      jSpinnerProductionDate.setFont(new java.awt.Font("Dialog", 0, 12));
      jSpinnerProductionDate.setBounds(161, 45, 136, 21);
      jSpinnerProductionDate.getEditor().addKeyListener(new KeyAdapter() {
        public void keyPressed(KeyEvent e)
        {
          calcBBEBatch();
        }
      });
      jSpinnerProductionDate.addChangeListener(new ChangeListener() {
        public void stateChanged(final ChangeEvent e)
        {
          calcBBEBatch();
        }
      });

      try
      {
        jSpinnerProductionDate.setDate(JUtility.getSQLDate());
        jSpinnerProductionDate.setEnabled(false);
      } catch (Exception e)
      {
      }

      jLabelProductionDate = new JLabel4j_std();
      jPanelPallet.add(jLabelProductionDate);
      jLabelProductionDate.setText(lang.get("lbl_Pallet_DOM"));
      jLabelProductionDate.setHorizontalAlignment(SwingConstants.TRAILING);
      jLabelProductionDate.setBounds(12, 46, 122, 21);
      jFormattedTextFieldProdQuantity = new JQuantityInput(new BigDecimal("0"));
      jFormattedTextFieldProdQuantity.addPropertyChangeListener(new PropertyChangeListener() {
        public void propertyChange(PropertyChangeEvent arg0)
        {
          Color background = Color.WHITE;

          try
          {
            if (jTextFieldProcessOrder.getText().equals("") == false)
            {
              BigDecimal newval = new BigDecimal(jFormattedTextFieldProdQuantity.getValue().toString());
              int res = newval.compareTo(new BigDecimal(0));
              if (res == 0)
              {
                background = Color.YELLOW;
              }
            }
          } catch (Exception e)
          {
            background = Color.YELLOW;
          }
          jFormattedTextFieldProdQuantity.setBackground(background);
        }
      });
      jPanelPallet.add(jFormattedTextFieldProdQuantity);
      jFormattedTextFieldProdQuantity.setFont(Common.font_std);
      jFormattedTextFieldProdQuantity.setBounds(449, 21, 91, 21);
      jFormattedTextFieldProdQuantity.setValue(0);
      jFormattedTextFieldProdQuantity.setEnabled(false);
      jFormattedTextFieldProdQuantity.setHorizontalAlignment(SwingConstants.TRAILING);
      jFormattedTextFieldProdQuantity.addKeyListener(new KeyAdapter() {
        public void keyReleased(KeyEvent evt)
        {
          pallet.setUom(jTextFieldProductionUom.getText());
          pallet.setQuantity(JUtility.stringToBigDecimal(jFormattedTextFieldProdQuantity.getText().toString()));
          jFormattedTextFieldBaseQuantity.setText(pallet.getBaseQuantityAsString());
        }
      });
      jLabelSSCC = new JLabel4j_std();
      jPanelPallet.add(jLabelSSCC);
      jLabelSSCC.setText(lang.get("lbl_Pallet_SSCC"));
      jLabelSSCC.setHorizontalAlignment(SwingConstants.TRAILING);
      jLabelSSCC.setBounds(12, 18, 122, 21);
      jTextFieldProductionUom = new JTextField4j();
      jPanelPallet.add(jTextFieldProductionUom);
      jTextFieldProductionUom.setBounds(666, 21, 70, 21);
      jTextFieldProductionUom.setEditable(false);
      jTextFieldProductionUom.setEnabled(false);
      jLabelProductionEAN = new JLabel4j_std();
      jPanelPallet.add(jLabelProductionEAN);
      jLabelProductionEAN.setText(lang.get("lbl_Pallet_UOM"));
      jLabelProductionEAN.setHorizontalAlignment(SwingConstants.TRAILING);
      jLabelProductionEAN.setBounds(546, 21, 113, 21);
      jLabel2 = new JLabel4j_std();
      jPanelPallet.add(jLabel2);
      jLabel2.setText(lang.get("lbl_Pallet_Base_Quantity"));
      jLabel2.setHorizontalAlignment(SwingConstants.TRAILING);
      jLabel2.setBounds(323, 49, 119, 21);
      jLabel3 = new JLabel4j_std();
      jPanelPallet.add(jLabel3);
      jLabel3.setText(lang.get("lbl_Pallet_Base_UOM"));
      jLabel3.setHorizontalAlignment(SwingConstants.TRAILING);
      jLabel3.setBounds(546, 49, 113, 21);
      jTextFieldBaseUOM = new JTextField4j();
      jPanelPallet.add(jTextFieldBaseUOM);
      jTextFieldBaseUOM.setEditable(false);
      jTextFieldBaseUOM.setEnabled(false);
      jTextFieldBaseUOM.setBounds(666, 49, 70, 21);
      jFormattedTextFieldBaseQuantity = new JQuantityInput(new BigDecimal("0"));
      jPanelPallet.add(jFormattedTextFieldBaseQuantity);
      jFormattedTextFieldBaseQuantity.setFont(Common.font_std);
      jFormattedTextFieldBaseQuantity.setHorizontalAlignment(SwingConstants.TRAILING);
      jFormattedTextFieldBaseQuantity.setText("0.000");
      jFormattedTextFieldBaseQuantity.setEnabled(false);
      jFormattedTextFieldBaseQuantity.setBounds(449, 49, 91, 21);
      jCheckBoxProductionDate = new JCheckBox();
      jPanelPallet.add(jCheckBoxProductionDate);
      jCheckBoxProductionDate.setBackground(new java.awt.Color(255, 255, 255));
      jCheckBoxProductionDate.setBounds(139, 45, 21, 21);
      jCheckBoxProductionDate.setEnabled(false);
      jCheckBoxProductionDate.addActionListener(new ActionListener() {
        public void actionPerformed(ActionEvent evt)
        {
          enableField(jSpinnerProductionDate, jCheckBoxProductionDate.isSelected());
          enableField(calendarButtonjSpinnerProductionDate, jCheckBoxProductionDate.isSelected());
        }
      });
      jCheckBoxAutoSSCC = new JCheckBox();
      jCheckBoxAutoSSCC.addActionListener(new ActionListener() {
        public void actionPerformed(ActionEvent e)
        {
          checkSSCC();
        }
      });
      jCheckBoxAutoSSCC.setSelected(true);
      jCheckBoxAutoSSCC.setToolTipText("Auto SSCC");
      jCheckBoxAutoSSCC.setBackground(new Color(255, 255, 255));
      jCheckBoxAutoSSCC.setBounds(139, 18, 21, 21);
      jPanelPallet.add(jCheckBoxAutoSSCC);

      calendarButtonjSpinnerProductionDate = new JCalendarButton(jSpinnerProductionDate);
      calendarButtonjSpinnerProductionDate.setEnabled(false);
      calendarButtonjSpinnerProductionDate.setBounds(290, 47, 21, 21);
      jPanelPallet.add(calendarButtonjSpinnerProductionDate);
      jPanelBatch = new JPanel();
      jDesktopPane1.add(jPanelBatch);
      jPanelBatch.setBounds(7, 315, 748, 56);
      jPanelBatch.setLayout(null);
      jPanelBatch.setFont(Common.font_std);
      jPanelBatch.setBorder(BorderFactory.createTitledBorder(lang.get("lbl_Material_Batch")));
      jPanelBatch.setBackground(new java.awt.Color(255, 255, 255));
      jLabelBatch = new JLabel4j_std();
      jPanelBatch.add(jLabelBatch);
      jLabelBatch.setText(lang.get("lbl_Material_Batch"));
      jLabelBatch.setHorizontalAlignment(SwingConstants.TRAILING);
      jLabelBatch.setBounds(320, 21, 96, 21);

      jTextFieldBatch = new JTextField4j();
      jPanelBatch.add(jTextFieldBatch);
      AbstractDocument doc = (AbstractDocument) jTextFieldBatch.getDocument();
      doc.setDocumentFilter(new JFixedSizeFilter(JDBMaterialBatch.field_batch_number));
      jTextFieldBatch.setBounds(449, 21, 108, 21);
      jTextFieldBatch.setEnabled(false);

      jSpinnerExpiryDate = new JDateControl();
      jSpinnerExpiryDate.addFocusListener(new FocusAdapter() {
        @Override
        public void focusLost(FocusEvent arg0)
        {
          jSpinnerExpiryDate.setDate(material.getRoundedExpiryDate(jSpinnerExpiryDate.getDate()));
        }
      });
      jPanelBatch.add(jSpinnerExpiryDate);
      jSpinnerExpiryDate.setFont(Common.font_std);
      jSpinnerExpiryDate.setBounds(161, 17, 135, 25);
      jSpinnerExpiryDate.getEditor().setPreferredSize(new java.awt.Dimension(87, 19));
      jSpinnerExpiryDate.getEditor().setSize(87, 21);
      jSpinnerExpiryDate.setEnabled(false);
      jLabelBatchExpiry = new JLabel4j_std();
      jPanelBatch.add(jLabelBatchExpiry);
      jLabelBatchExpiry.setText(lang.get("lbl_Material_Batch_Expiry_Date"));
      jLabelBatchExpiry.setHorizontalAlignment(SwingConstants.TRAILING);
      jLabelBatchExpiry.setBounds(12, 17, 122, 21);
      jCheckBoxExpiry = new JCheckBox();
      jPanelBatch.add(jCheckBoxExpiry);
      jCheckBoxExpiry.setBounds(139, 17, 21, 21);
      jCheckBoxExpiry.setBackground(new java.awt.Color(255, 255, 255));
      jCheckBoxExpiry.setEnabled(false);
      jCheckBoxExpiry.addActionListener(new ActionListener() {
        public void actionPerformed(ActionEvent evt)
        {
          enableField(jSpinnerExpiryDate, jCheckBoxExpiry.isSelected());
          enableField(calendarButtonjSpinnerExpiryDate, jCheckBoxExpiry.isSelected());
          calcBBEBatch();
        }
      });
      jCheckBoxBatch = new JCheckBox();
      jPanelBatch.add(jCheckBoxBatch);
      jCheckBoxBatch.setEnabled(false);
      jCheckBoxBatch.setBackground(new java.awt.Color(255, 255, 255));
      jCheckBoxBatch.setBounds(422, 21, 21, 21);
      jCheckBoxBatch.addActionListener(new ActionListener() {
        public void actionPerformed(ActionEvent evt)
        {
          enableField(jTextFieldBatch, jCheckBoxBatch.isSelected());
          calcBBEBatch();
        }
      });
      jStatusText = new JLabel4j_std();
      jDesktopPane1.add(jStatusText);
      jStatusText.setForeground(new java.awt.Color(255, 0, 0));
      jStatusText.setBounds(0, 532, 761, 21);
      jStatusText.setBorder(BorderFactory.createBevelBorder(BevelBorder.LOWERED));
      jButtonReprint = new JButton4j(Common.icon_report);
      jButtonReprint.addActionListener(new ActionListener() {
        public void actionPerformed(ActionEvent e)
        {
          buildSQL(ssccList, ssccItems);
          String pq = comboBoxPrintQueue.getSelectedItem().toString();
         
           JLaunchReport.runReport(labelPrint.getPalletLabelReportName(pallet.getProcessOrder()), listStatement, jCheckBoxAutoPreview.isSelected(), pq,
              Integer.valueOf(jSpinnerCopies.getValue().toString()), checkBoxIncHeaderText.isSelected());

        }
      });
      jButtonReprint.setMnemonic(KeyEvent.VK_C);
      jButtonReprint.setText(lang.get("btn_Re_Print"));
      jButtonReprint.setBounds(248, 492, 126, 28);
      jButtonReprint.setEnabled(Common.userList.getUser(Common.sessionID).isModuleAllowed("FRM_PRODDEC_REPRINT"));
      jDesktopPane1.add(jButtonReprint);

      {
        final JPanel panel = new JPanel();
        panel.setBorder(new TitledBorder(null, lang.get("lbl_Options"), TitledBorder.DEFAULT_JUSTIFICATION, TitledBorder.DEFAULT_POSITION, null, null));
        panel.setBackground(Color.WHITE);
        panel.setFont(Common.font_title);
        panel.setLayout(null);
        panel.setBounds(7, 374, 748, 73);
        jDesktopPane1.add(panel);
        jLabelPrintLabel = new JLabel4j_std();
        jLabelPrintLabel.setBounds(0, 15, 129, 21);
        panel.add(jLabelPrintLabel);
        jLabelPrintLabel.setHorizontalAlignment(SwingConstants.TRAILING);
        jLabelPrintLabel.setText(lang.get("lbl_Print"));
        jCheckBoxAutoPrint = new JCheckBox();
        jCheckBoxAutoPrint.setBounds(139, 15, 21, 21);
        panel.add(jCheckBoxAutoPrint);
        jCheckBoxAutoPrint.setToolTipText("Auto SSCC");
        jCheckBoxAutoPrint.setSelected(true);
        jCheckBoxAutoPrint.setBackground(new Color(255, 255, 255));
        jCheckBoxAutoPrint.setText("New JCheckBox");
        jCheckBoxAutoPrint.setEnabled(Common.userList.getUser(Common.sessionID).isModuleAllowed("FRM_PRODDEC_PRINT"));
        jLabelPrintLabel_1 = new JLabel4j_std();
        jLabelPrintLabel_1.setBounds(282, 15, 138, 21);
        panel.add(jLabelPrintLabel_1);
        jLabelPrintLabel_1.setHorizontalTextPosition(SwingConstants.CENTER);
        jLabelPrintLabel_1.setHorizontalAlignment(SwingConstants.TRAILING);
        jLabelPrintLabel_1.setText(lang.get("lbl_Preview"));
        jCheckBoxAutoPreview = new JCheckBox();
        jCheckBoxAutoPreview.setBounds(424, 15, 21, 21);
        panel.add(jCheckBoxAutoPreview);
        jCheckBoxAutoPreview.setToolTipText("Auto SSCC");
        jCheckBoxAutoPreview.setSelected(true);
        jCheckBoxAutoPreview.setBackground(new Color(255, 255, 255));
        jCheckBoxAutoPreview.setText("New JCheckBox");
        jCheckBoxAutoPreview.setEnabled(Common.userList.getUser(Common.sessionID).isModuleAllowed("FRM_PRODDEC_PREVIEW"));
        jLabelPrintLabel_2 = new JLabel4j_std();
        jLabelPrintLabel_2.setHorizontalAlignment(SwingConstants.TRAILING);
        jLabelPrintLabel_2.setText(lang.get("lbl_Label_Header_Text"));
        jLabelPrintLabel_2.setBounds(10, 44, 119, 21);
        panel.add(jLabelPrintLabel_2);
        jCheckBoxAutoConfirm = new JCheckBox();
        jCheckBoxAutoConfirm.setBackground(Color.WHITE);
        jCheckBoxAutoConfirm.setText("New JCheckBox");
        jCheckBoxAutoConfirm.setBounds(424, 44, 21, 21);
        panel.add(jCheckBoxAutoConfirm);
        jCheckBoxAutoConfirm.setEnabled(Common.userList.getUser(Common.sessionID).isModuleAllowed("FRM_PRODDEC_CONFIRM"));
        jLabelQuantity_1 = new JLabel4j_std();
        jLabelQuantity_1.setBounds(474, 15, 201, 21);
        panel.add(jLabelQuantity_1);
        jLabelQuantity_1.setHorizontalAlignment(SwingConstants.RIGHT);
        jLabelQuantity_1.setText(lang.get("lbl_Number_of_SSCCs"));

        jSpinnerQuantity = new JSpinner();
        jSpinnerQuantity.addChangeListener(new ChangeListener() {
          public void stateChanged(final ChangeEvent e)
          {
            int t = Integer.valueOf(jSpinnerQuantity.getValue().toString());

            if (t <= 0)
            {
              jSpinnerQuantity.setValue(1);
            }

            if (t > 50)
            {
              jSpinnerQuantity.setValue(50);
            }
          }
        });
        jSpinnerQuantity.setBounds(687, 15, 49, 21);
        jSpinnerQuantity.setInputVerifier(null);
        jSpinnerQuantity.setModel(quantitynumbermodel);
        jSpinnerQuantity.setValue(1);
        JSpinner.NumberEditor ne = new JSpinner.NumberEditor(jSpinnerQuantity);
        ne.getTextField().setFont(Common.font_std);
        jSpinnerQuantity.setEditor(ne);
        panel.add(jSpinnerQuantity);

        jSpinnerCopies = new JSpinner();
        jSpinnerCopies.setBounds(687, 44, 49, 21);
        jSpinnerCopies.setInputVerifier(null);
        jSpinnerCopies.setModel(copiesnumbermodel);
        JSpinner.NumberEditor nec2 = new JSpinner.NumberEditor(jSpinnerCopies);
        nec2.getTextField().setFont(Common.font_std);
        jSpinnerCopies.setEditor(nec2);
        panel.add(jSpinnerCopies);

        labelCopies.setText((String) null);
        labelCopies.setHorizontalAlignment(SwingConstants.RIGHT);
        labelCopies.setBounds(474, 44, 201, 21);
        labelCopies.setText(lang.get("lbl_Labels_Per_SSCC"));
        panel.add(labelCopies);

        label_1 = new JLabel4j_std();
        label_1.setHorizontalAlignment(SwingConstants.TRAILING);
        label_1.setText(lang.get("lbl_Confirmed"));
        label_1.setBounds(292, 44, 129, 21);
        panel.add(label_1);

        checkBoxIncHeaderText = new JCheckBox();
        checkBoxIncHeaderText.setSelected(true);
        checkBoxIncHeaderText.setText("New JCheckBox");
        checkBoxIncHeaderText.setBackground(Color.WHITE);
        checkBoxIncHeaderText.setBounds(139, 44, 21, 21);
        panel.add(checkBoxIncHeaderText);

        textFieldBatchExtension = new JTextField4j();
        textFieldBatchExtension.setText("");
        textFieldBatchExtension.setBounds(561, 21, 39, 21);
        jPanelBatch.add(textFieldBatchExtension);

        calendarButtonjSpinnerExpiryDate = new JCalendarButton(jSpinnerExpiryDate);
View Full Code Here

    JLabel4j_std lblProcessOrder = new JLabel4j_std(lang.get("lbl_Process_Order"));
    lblProcessOrder.setBounds(6, 18, 111, 16);
    lblProcessOrder.setHorizontalAlignment(SwingConstants.TRAILING);
    desktopPane.add(lblProcessOrder);
   
    textFieldProcessOrder = new JTextField4j();
    textFieldProcessOrder.setBounds(125, 15, 138, 22);
    textFieldProcessOrder.addKeyListener(new KeyAdapter()
    {
      public void keyReleased(KeyEvent evt)
      {
        processOrderChanged(textFieldProcessOrder.getText());
      }
    });
    desktopPane.add(textFieldProcessOrder);
    textFieldProcessOrder.setColumns(10);
   
    JLabel4j_std lblNewLabel_3 = new JLabel4j_std(lang.get("lbl_Activity_ID"));
    lblNewLabel_3.setBounds(6, 98, 111, 16);
    lblNewLabel_3.setHorizontalAlignment(SwingConstants.TRAILING);
    desktopPane.add(lblNewLabel_3);
   
    btnClose = new JButton4j(lang.get("btn_Close"));
    btnClose.setBounds(877, 92, 117, 29);
    btnClose.setIcon(Common.icon_close);
    btnClose.addActionListener(new ActionListener() {
      public void actionPerformed(ActionEvent e) {
        dispose();
      }
    });
    desktopPane.add(btnClose);
   
    btnEdit = new JButton4j(lang.get("btn_Edit"));
    btnEdit.setBounds(748, 92, 117, 29);
    btnEdit.setIcon(Common.icon_edit);
    btnEdit.addActionListener(new ActionListener() {
      public void actionPerformed(ActionEvent e) {
        editRecord();
      }
    });
    desktopPane.add(btnEdit);
   
    JButton4j btnRefresh = new JButton4j(lang.get("btn_Refresh"));
    btnRefresh.setBounds(619, 92, 117, 29);
    btnRefresh.setIcon(Common.icon_refresh);
    btnRefresh.addActionListener(new ActionListener() {
      public void actionPerformed(ActionEvent e) {
        populateTable();
      }
    });
    desktopPane.add(btnRefresh);
   
    JButton btnProcessOrderLookup = new JButton();
    btnProcessOrderLookup.setIcon(Common.icon_lookup);
    btnProcessOrderLookup.setBounds(261, 15, 21, 22);
    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);
        }
      }
    });
    desktopPane.add(btnProcessOrderLookup);
   
    comboboxActivities = new JComboBox4j();
    comboboxActivities.setBounds(125, 93, 470, 28);
    comboboxActivities.addActionListener(new ActionListener() {
      public void actionPerformed(ActionEvent arg0) {
        populateTable();
      }
    });
    desktopPane.add(comboboxActivities);
   
    lblStatusBar = new JLabel4j_std();
    lblStatusBar.setBounds(8, 615, 990, 21);
    lblStatusBar.setForeground(Color.RED);
    lblStatusBar.setBackground(Color.GRAY);
    desktopPane.add(lblStatusBar);
   
    jScrollPane1 = new JScrollPane();
    jScrollPane1.setBounds(8, 139, 995, 470);
    jScrollPane1.getViewport().setBackground(Common.color_tablebackground);
    desktopPane.setLayout(null);
    desktopPane.add(jScrollPane1);

   
    initializeTable("","");
   
    textField4Material = new JTextField4j();
    textField4Material.setEnabled(false);
    textField4Material.setColumns(10);
    textField4Material.setBounds(413, 15, 138, 22);
    desktopPane.add(textField4Material);
   
    textFieldDescription = new JTextField4j();
    textFieldDescription.setEnabled(false);
    textFieldDescription.setColumns(10);
    textFieldDescription.setBounds(563, 15, 431, 22);
    desktopPane.add(textFieldDescription);
   
    JLabel4j_std lbl_material = new JLabel4j_std(lang.get("lbl_Material"));
    lbl_material.setHorizontalAlignment(SwingConstants.TRAILING);
    lbl_material.setBounds(294, 18, 111, 16);
    desktopPane.add(lbl_material);
   
    textField4InspectionID = new JTextField4j();
    textField4InspectionID.setEnabled(false);
    textField4InspectionID.setColumns(10);
    textField4InspectionID.setBounds(125, 52, 138, 22);
    desktopPane.add(textField4InspectionID);
   
    lbl_inspection = new JLabel4j_std(lang.get("lbl_Inspection_ID"));
    lbl_inspection.setHorizontalAlignment(SwingConstants.TRAILING);
    lbl_inspection.setBounds(6, 56, 111, 16);
    desktopPane.add(lbl_inspection);
   
    textField4jInspectionDescription = new JTextField4j();
    textField4jInspectionDescription.setEnabled(false);
    textField4jInspectionDescription.setColumns(10);
    textField4jInspectionDescription.setBounds(271, 52, 723, 22);
    desktopPane.add(textField4jInspectionDescription);
   
View Full Code Here

            jButtonHelp.setText(lang.get("btn_Help"));
            jButtonHelp.setBounds(734, 75, 120, 32);
            jButtonHelp.setMnemonic(lang.getMnemonicChar());
          }
          {
            textFieldText = new JTextField4j();
            textFieldText.setBounds(141, 45, 414, 20);
            jDesktopPane1.add(textFieldText);
            textFieldText.setColumns(10);

            textFieldResourceKey = new JTextField4j();
            textFieldResourceKey.setBounds(685, 12, 280, 20);
            jDesktopPane1.add(textFieldResourceKey);
            textFieldResourceKey.setColumns(10);

            textFieldMnemonic = new JTextField4j();
            textFieldMnemonic.setBounds(685, 45, 35, 20);
            jDesktopPane1.add(textFieldMnemonic);
            textFieldMnemonic.setColumns(10);
          }
          {
View Full Code Here

              dispose();
            }
          });
        }
        {
          jTextFieldCriteria = new JTextField4j();
          jDesktopPane1.add(jTextFieldCriteria);
          jTextFieldCriteria.setBounds(70, 35, 385, 21);
        }
        {
          ComboBoxModel<String> jComboBox1Model = new DefaultComboBoxModel<String>(dlg_table.getFieldNames());
View Full Code Here

    JLabel4j_std lblActivityID = new JLabel4j_std(lang.get("lbl_Activity_ID"));
    lblActivityID.setBounds(6, 67, 89, 16);
    desktopPane.add(lblActivityID);
    lblActivityID.setHorizontalAlignment(SwingConstants.TRAILING);
   
    textFieldInspectionID = new JTextField4j();
    textFieldInspectionID.setEnabled(false);
    textFieldInspectionID.setBounds(108, 22, 153, 28);
    desktopPane.add(textFieldInspectionID);
    textFieldInspectionID.setColumns(10);
   
   
    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(292, 113, 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(413, 113, 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.addKeyListener(new KeyAdapter() {
      @Override
      public void keyReleased(KeyEvent e) {
        enableSave();
      }
    });
    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.addKeyListener(new KeyAdapter() {
      @Override
      public void keyReleased(KeyEvent arg0) {
        enableSave();
      }
View Full Code Here

        jDesktopPane1 = new JDesktopPane();
        jDesktopPane1.setBackground(Color.WHITE);
        this.getContentPane().add(jDesktopPane1, BorderLayout.CENTER);
        jDesktopPane1.setPreferredSize(new java.awt.Dimension(462, 497));
        {
          jTextFieldSampleID = new JTextField4j();
          jTextFieldSampleID.addKeyListener(new KeyAdapter()
          {
            public void keyReleased(final KeyEvent e)
            {
              refresh();
            }
          });
          jDesktopPane1.setLayout(null);
          jDesktopPane1.add(jTextFieldSampleID);
          jTextFieldSampleID.setEditable(true);
          jTextFieldSampleID.setEnabled(true);
          jTextFieldSampleID.setBounds(147, 12, 77, 21);
        }
        {
          jButtonSave = new JButton4j(Common.icon_save);
          jDesktopPane1.add(jButtonSave);
          jButtonSave.setEnabled(true);
          jButtonSave.setText(lang.get("btn_Save"));
          jButtonSave.setMnemonic(lang.getMnemonicChar());
          jButtonSave.setBounds(111, 333, 100, 28);
          jButtonSave.addActionListener(new ActionListener()
          {
            public void actionPerformed(ActionEvent evt)
            {

              updateRecord();
            }
          });
        }
        {
          jButtonCancel = new JButton4j(Common.icon_close);
          jDesktopPane1.add(jButtonCancel);
          jButtonCancel.setText(lang.get("btn_Close"));
          jButtonCancel.setMnemonic(lang.getMnemonicChar());
          jButtonCancel.setBounds(315, 333, 100, 28);
          jButtonCancel.addActionListener(new ActionListener()
          {
            public void actionPerformed(ActionEvent evt)
            {
              dispose();
            }
          });
        }

        {
          lblSampleID = new JLabel4j_std();
          jDesktopPane1.add(lblSampleID);
          lblSampleID.setText(lang.get("lbl_SampleID"));
          lblSampleID.setBounds(7, 14, 133, 21);
          lblSampleID.setHorizontalAlignment(SwingConstants.TRAILING);
        }
        {
          lblUserData2 = new JLabel4j_std();
          jDesktopPane1.add(lblUserData2);
          lblUserData2.setBounds(7, 250, 133, 21);
          lblUserData2.setHorizontalAlignment(SwingConstants.TRAILING);
          lblUserData2.setText(lang.get("lbl_User_Data2"));
        }

        {
          lblMaterial = new JLabel4j_std();
          jDesktopPane1.add(lblMaterial);
          lblMaterial.setText(lang.get("lbl_Material"));
          lblMaterial.setHorizontalAlignment(SwingConstants.TRAILING);
          lblMaterial.setBounds(7, 118, 133, 21);
        }
        {
          jTextFieldMaterial = new JTextField4j();
          jDesktopPane1.add(jTextFieldMaterial);
          jTextFieldMaterial.setBounds(147, 116, 119, 21);
          jTextFieldMaterial.setEnabled(false);
        }
        {
          lblActivityID = new JLabel4j_std();
          jDesktopPane1.add(lblActivityID);
          lblActivityID.setText(lang.get("lbl_Activity_ID"));
          lblActivityID.setHorizontalAlignment(SwingConstants.TRAILING);
          lblActivityID.setBounds(7, 196, 133, 21);
        }
        {
          jTextFieldActivityID = new JTextField4j();
          jDesktopPane1.add(jTextFieldActivityID);
          jTextFieldActivityID.setBounds(147, 194, 119, 21);
          jTextFieldActivityID.setEnabled(false);
        }

        {
          lblProcessOrder = new JLabel4j_std();
          jDesktopPane1.add(lblProcessOrder);
          lblProcessOrder.setText(lang.get("lbl_Process_Order"));
          lblProcessOrder.setHorizontalAlignment(SwingConstants.TRAILING);
          lblProcessOrder.setBounds(7, 66, 133, 21);
        }
        {
          jTextFieldProcessOrder = new JTextField4j();
          jDesktopPane1.add(jTextFieldProcessOrder);
          jTextFieldProcessOrder.setBounds(147, 64, 119, 21);
          jTextFieldProcessOrder.setEnabled(false);

        }
        {
          jTextFieldUserData2 = new JTextField4j();
          jDesktopPane1.add(jTextFieldUserData2);
          jTextFieldUserData2.setBounds(147, 246, 119, 21);
          jTextFieldUserData2.setFocusCycleRoot(true);
        }
        {
          lblUserData1 = new JLabel4j_std();
          jDesktopPane1.add(lblUserData1);
          lblUserData1.setText(lang.get("lbl_User_Data1"));
          lblUserData1.setHorizontalAlignment(SwingConstants.TRAILING);
          lblUserData1.setBounds(7, 224, 133, 21);
        }

        {
          jTextFieldProcessOrderDescription = new JTextField4j();
          jDesktopPane1.add(jTextFieldProcessOrderDescription);
          jTextFieldProcessOrderDescription.setBounds(147, 90, 287, 21);
          jTextFieldProcessOrderDescription.setEnabled(false);
        }
        {
          lblProcessOrderDescription = new JLabel4j_std();
          jDesktopPane1.add(lblProcessOrderDescription);
          lblProcessOrderDescription.setText(lang.get("lbl_Description"));
          lblProcessOrderDescription.setHorizontalAlignment(SwingConstants.TRAILING);
          lblProcessOrderDescription.setBounds(7, 92, 133, 21);
        }
        {
          lblMaterialDescription = new JLabel4j_std();
          jDesktopPane1.add(lblMaterialDescription);
          lblMaterialDescription.setText(lang.get("lbl_Description"));
          lblMaterialDescription.setHorizontalAlignment(SwingConstants.TRAILING);
          lblMaterialDescription.setBounds(7, 144, 133, 21);
        }
        {
          jTextFieldMaterialDescription = new JTextField4j();
          jDesktopPane1.add(jTextFieldMaterialDescription);
          jTextFieldMaterialDescription.setBounds(147, 142, 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, 373, 510, 21);
        }

        {
          jTextFieldUserData1 = new JTextField4j();
          jTextFieldUserData1.setFocusCycleRoot(true);
          jTextFieldUserData1.setBounds(147, 220, 119, 21);
          jDesktopPane1.add(jTextFieldUserData1);
        }

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

        {
          jTextFieldInspectionID = new JTextField4j();
          jTextFieldInspectionID.setBounds(147, 168, 119, 21);
          jTextFieldInspectionID.setEnabled(false);
          jDesktopPane1.add(jTextFieldInspectionID);
        }
       
View Full Code Here

        jDesktopPane1.setBackground(Common.color_app_window);
        this.getContentPane().add(jDesktopPane1);
        jDesktopPane1.setPreferredSize(new java.awt.Dimension(577, 280));
        jDesktopPane1.setLayout(null);
        {
          textFieldTranslatedDescripton = new JTextField4j();
          textFieldTranslatedDescripton.setEditable(false);
          textFieldTranslatedDescripton.setFocusCycleRoot(true);
          textFieldTranslatedDescripton.setCaretPosition(0);
          textFieldTranslatedDescripton.setBounds(164, 60, 280, 21);
          jDesktopPane1.add(textFieldTranslatedDescripton);
        }
        {
          jLabel1 = new JLabel4j_std();
          jDesktopPane1.add(jLabel1);
          jLabel1.setText(lang.get("lbl_Module_ID"));
          jLabel1.setHorizontalAlignment(SwingConstants.RIGHT);
          jLabel1.setHorizontalTextPosition(SwingConstants.RIGHT);
          jLabel1.setBounds(0, 10, 152, 21);
        }
        {
          lblReportType = new JLabel4j_std();
          lblReportType.setText(lang.get("lbl_Module_Report_Type"));
          lblReportType.setHorizontalAlignment(SwingConstants.TRAILING);
          lblReportType.setBounds(0, 206, 152, 21);
          jDesktopPane1.add(lblReportType);
        }
        {
          jTextFieldModuleId = new JTextField4j();
          jDesktopPane1.add(jTextFieldModuleId);
          jTextFieldModuleId.setHorizontalAlignment(SwingConstants.LEFT);
          jTextFieldModuleId.setEditable(false);
          jTextFieldModuleId.setBounds(164, 10, 280, 21);
          jTextFieldModuleId.setEnabled(false);
        }
        {
          jTextFieldResourceKey = new JTextField4j();
          AbstractDocument doc = (AbstractDocument) jTextFieldResourceKey.getDocument();
          doc.setDocumentFilter(new JFixedSizeFilter(JDBModule.field_description));
          jDesktopPane1.add(jTextFieldResourceKey);
          jTextFieldResourceKey.setFocusCycleRoot(true);
          jTextFieldResourceKey.setBounds(164, 35, 280, 21);
          jTextFieldResourceKey.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.setHorizontalTextPosition(SwingConstants.RIGHT);
          jButtonUpdate.setMnemonic(lang.getMnemonicChar());
          jButtonUpdate.setBounds(136, 424, 112, 32);
          jButtonUpdate.addActionListener(new ActionListener() {
            public void actionPerformed(ActionEvent evt) {

              module.setResourceKey(jTextFieldResourceKey.getText());

              module.setIconFilename(jTextFieldIconFilename.getText());
              module.setHelpSetID(jTextFieldHelpsetid.getText());

              module.setType((String) jComboBoxType.getSelectedItem());
              module.setReportType((String) comboBox.getSelectedItem());

              if (jCheckBoxDesktop.isSelected())
                module.setDKActive("Y");
              else
                module.setDKActive("N");

              if (jCheckBoxScanner.isSelected())
                module.setRFActive("Y");
              else
                module.setRFActive("N");

              if (jCheckBoxPrintPreview.isSelected())
                module.setPrintPreview("Y");
              else
                module.setPrintPreview("N");

              if (jCheckBoxPrintDialog.isSelected())
                module.setPrintDialog("Y");
              else
                module.setPrintDialog("N");

              module.setPrintCopies(Integer.valueOf(jSpinnerPrintCopies.getValue().toString()));

              module.setReportFilename(jTextFieldReportFilename.getText());
              module.setExecFilename(jTextFieldExecFilename.getText());
              module.setExecDir(jTextFieldExecDir.getText());
             
              module.setAutoLabelCommandFilename(jTextFieldAutoLabelCommandFilename.getText());
              module.setAutoLabelLabelFilename(jTextFieldAutoLabelLabelFilename.getText());

              if (module.update() == false)
              {
                JUtility.errorBeep();
                JOptionPane.showMessageDialog(null, module.getErrorMessage(), lang.get("err_Error"), JOptionPane.ERROR_MESSAGE);
              }

              jButtonUpdate.setEnabled(false);
            }
          });
        }
        {

          jButtonClose = new JButton4j(Common.icon_close);
          jDesktopPane1.add(jButtonClose);
          jButtonClose.setText(lang.get("btn_Close"));
          jButtonClose.setMnemonic(lang.getMnemonicChar());
          jButtonClose.setBounds(364, 424, 112, 32);
          jButtonClose.addActionListener(new ActionListener() {
            public void actionPerformed(ActionEvent evt) {
              dispose();
            }
          });
        }
        {
          jLabel3 = new JLabel4j_std();
          jDesktopPane1.add(jLabel3);
          jLabel3.setText(lang.get("lbl_Module_Type"));
          jLabel3.setHorizontalAlignment(SwingConstants.RIGHT);
          jLabel3.setHorizontalTextPosition(SwingConstants.RIGHT);
          jLabel3.setBounds(0, 93, 152, 21);
        }
        {
          jLabel4 = new JLabel4j_std();
          jDesktopPane1.add(jLabel4);
          jLabel4.setText(lang.get("lbl_Module_Desktop"));
          jLabel4.setHorizontalAlignment(SwingConstants.RIGHT);
          jLabel4.setHorizontalTextPosition(SwingConstants.RIGHT);
          jLabel4.setBounds(0, 122, 152, 21);
        }
        {
          jLabel5 = new JLabel4j_std();
          jDesktopPane1.add(jLabel5);
          jLabel5.setText(lang.get("lbl_Description"));
          jLabel5.setHorizontalAlignment(SwingConstants.RIGHT);
          jLabel5.setHorizontalTextPosition(SwingConstants.RIGHT);
          jLabel5.setBounds(0, 60, 152, 21);
        }
        {
          comboBox = new JComboBox4j<String>();
          comboBox.addActionListener(new ActionListener() {
            public void actionPerformed(ActionEvent arg0) {
              jButtonUpdate.setEnabled(true);
            }
          });
          comboBox.setBounds(164, 206, 180, 23);
          comboBox.addItem("");
          comboBox.addItem("Standard");
          comboBox.addItem("Label");
          jDesktopPane1.add(comboBox);
        }
        {
          jComboBoxType = new JComboBox4j<String>();
          jDesktopPane1.add(jComboBoxType);
          jComboBoxType.setEnabled(true);
          jComboBoxType.setEditable(false);
          jComboBoxType.setLightWeightPopupEnabled(true);
          jComboBoxType.setIgnoreRepaint(false);
          jComboBoxType.setBounds(164, 93, 180, 23);
          jComboBoxType.addItem("EXEC");
          jComboBoxType.addItem("FORM");
          jComboBoxType.addItem("FUNCTION");
          jComboBoxType.addItem("MENU");
          jComboBoxType.addItem("REPORT");
          jComboBoxType.addItem("USER");
          jComboBoxType.addActionListener(new ActionListener() {
            public void actionPerformed(ActionEvent evt) {
              new_type = jComboBoxType.getSelectedItem();
              if (new_type != null)
              {
                if (new_type.equals(current_type) != true)
                {
                  // module_updated = true;
                  jButtonUpdate.setEnabled(true);
                  jButtonIconPreview.setIcon(JDBModule.getModuleIcon(jTextFieldIconFilename.getText(), (String) jComboBoxType.getSelectedItem()));
                }

                if (new_type.equals("REPORT") || new_type.equals("USER"))
                {
                  jTextFieldReportFilename.setEnabled(true);
                  jButtonReportFileChooser.setEnabled(true);
                  jCheckBoxPrintPreview.setEnabled(true);
                  jCheckBoxPrintDialog.setEnabled(true);
                  jSpinnerPrintCopies.setEnabled(true);
                  comboBox.setEnabled(true);
                  jTextFieldAutoLabelCommandFilename.setEnabled(true);
                  jTextFieldAutoLabelLabelFilename.setEnabled(true);
                  jButtonAutoLabelCommandFileChooser.setEnabled(true);
                  jButtonAutoLabelLabelDirChooser.setEnabled(true);
                }
                else
                {
                  jTextFieldReportFilename.setEnabled(false);
                  jButtonReportFileChooser.setEnabled(false);
                  jCheckBoxPrintPreview.setEnabled(false);
                  jCheckBoxPrintDialog.setEnabled(false);
                  jSpinnerPrintCopies.setEnabled(false);
                  comboBox.setEnabled(false);
                  jTextFieldAutoLabelCommandFilename.setEnabled(false);
                  jTextFieldAutoLabelLabelFilename.setEnabled(false);
                  jButtonAutoLabelCommandFileChooser.setEnabled(false);
                  jButtonAutoLabelLabelDirChooser.setEnabled(false);
                }

                if (new_type.equals("EXEC"))
                {
                  jTextFieldExecFilename.setEnabled(true);
                  jButtonExecFileChooser.setEnabled(true);
                  jTextFieldExecDir.setEnabled(true);
                  jButtonExecDirChooser.setEnabled(true);
                }
                else
                {
                  jTextFieldExecFilename.setEnabled(false);
                  jButtonExecFileChooser.setEnabled(false);
                  jTextFieldExecDir.setEnabled(false);
                  jButtonExecDirChooser.setEnabled(false);
                }
              }
            }
          });
        }
        {
          jCheckBoxScanner = new JCheckBox4j();
          jDesktopPane1.add(jCheckBoxScanner);
          jCheckBoxScanner.setSelected(true);
          jCheckBoxScanner.setBounds(164, 146, 21, 21);
          jCheckBoxScanner.setBackground(new java.awt.Color(255, 255, 255));
          jCheckBoxScanner.addActionListener(new ActionListener() {
            public void actionPerformed(ActionEvent evt) {
              // module_updated = true;
              jButtonUpdate.setEnabled(true);
            }
          });
        }
        {
          jCheckBoxDesktop = new JCheckBox4j();
          jDesktopPane1.add(jCheckBoxDesktop);
          jCheckBoxDesktop.setSelected(true);
          jCheckBoxDesktop.setBounds(164, 122, 21, 21);
          jCheckBoxDesktop.setBackground(new java.awt.Color(255, 255, 255));
          jCheckBoxDesktop.addActionListener(new ActionListener() {
            public void actionPerformed(ActionEvent evt) {
              // module_updated = true;
              jButtonUpdate.setEnabled(true);
            }
          });
        }
        {
          jLabel6 = new JLabel4j_std();
          jDesktopPane1.add(jLabel6);
          jLabel6.setText(lang.get("lbl_Module_Scanner"));
          jLabel6.setHorizontalAlignment(SwingConstants.RIGHT);
          jLabel6.setHorizontalTextPosition(SwingConstants.RIGHT);
          jLabel6.setBounds(0, 146, 152, 21);
        }

        {
          jLabelMnemonic = new JLabel4j_std();
          jDesktopPane1.add(jLabelMnemonic);
          jLabelMnemonic.setText(lang.get("lbl_Language_Mnemonic"));
          jLabelMnemonic.setBounds(449, 60, 112, 21);
          jLabelMnemonic.setHorizontalAlignment(SwingConstants.RIGHT);
          jLabelMnemonic.setHorizontalTextPosition(SwingConstants.RIGHT);
        }
        {
          jTextFieldMnemonic = new JTextField4j();
          jTextFieldMnemonic.setEditable(false);
          AbstractDocument doc = (AbstractDocument) jTextFieldMnemonic.getDocument();
          doc.setDocumentFilter(new JFixedSizeFilter(JDBModule.field_mneumonic));

          jDesktopPane1.add(jTextFieldMnemonic);
          jTextFieldMnemonic.setText("");

          jTextFieldMnemonic.setBounds(566, 60, 42, 21);
          jTextFieldMnemonic.setToolTipText("Character to underline");
          jTextFieldMnemonic.addKeyListener(new KeyAdapter() {
            public void keyTyped(KeyEvent evt) {
              jButtonUpdate.setEnabled(true);
            }
          });
        }
        {
          jLabel2 = new JLabel4j_std();
          jDesktopPane1.add(jLabel2);
          jLabel2.setText(lang.get("lbl_Module_Executable_Directory"));
          jLabel2.setBounds(0, 291, 152, 21);
          jLabel2.setHorizontalAlignment(SwingConstants.TRAILING);
        }
        {
          jTextFieldIconFilename = new JTextField4j();
          jDesktopPane1.add(jTextFieldIconFilename);
          jTextFieldIconFilename.setBounds(164, 177, 218, 22);
          jTextFieldIconFilename.addKeyListener(new KeyAdapter() {
            public void keyReleased(KeyEvent evt) {
              jButtonIconPreview.setIcon(JDBModule.getModuleIcon(jTextFieldIconFilename.getText(), (String) jComboBoxType.getSelectedItem()));
            }

            public void keyTyped(KeyEvent evt) {
              jButtonUpdate.setEnabled(true);
            }
          });
        }
        {
          jButtonIconFileChooser = new JButton4j();
          jDesktopPane1.add(jButtonIconFileChooser);
          jButtonIconFileChooser.setText("..");
          jButtonIconFileChooser.setBounds(383, 177, 17, 21);
          jButtonIconFileChooser.addActionListener(new ActionListener() {
            public void actionPerformed(ActionEvent evt) {

              JFileChooser loadIco = new JFileChooser();

              try
              {
                File f = new File(new File("./images").getCanonicalPath());
                loadIco.setCurrentDirectory(f);
                loadIco.addChoosableFileFilter(new JFileFilterImages());
                loadIco.setAcceptAllFileFilterUsed(false);
                loadIco.setSelectedFile(new File(jTextFieldIconFilename.getText()));
              }
              catch (Exception e)
              {
              }

              if (loadIco.showOpenDialog(jButtonIconFileChooser) == JFileChooser.APPROVE_OPTION)
              {
                File selectedFile;
                selectedFile = loadIco.getSelectedFile();

                if (selectedFile != null)
                {
                  if (jTextFieldIconFilename.getText().compareTo(selectedFile.getName()) != 0)
                  {
                    jTextFieldIconFilename.setText(selectedFile.getName());
                    jButtonIconPreview.setIcon(JDBModule.getModuleIcon(jTextFieldIconFilename.getText(), (String) jComboBoxType.getSelectedItem()));
                    jButtonUpdate.setEnabled(true);
                  }
                }
              }
            }
          });
        }
        {
          jButtonIconPreview = new JButton4j();
          jDesktopPane1.add(jButtonIconPreview);
          jButtonIconPreview.setBounds(292, 177, 23, 22);
          jButtonIconPreview.setBorderPainted(false);
          jButtonIconPreview.setContentAreaFilled(false);
          jButtonIconPreview.setRolloverEnabled(false);
          jButtonIconPreview.setRequestFocusEnabled(false);
        }
        {
          jTextFieldHelpsetid = new JTextField4j();
          AbstractDocument doc = (AbstractDocument) jTextFieldHelpsetid.getDocument();
          doc.setDocumentFilter(new JFixedSizeFilter(JDBModule.field_helpset_id));
          jDesktopPane1.add(jTextFieldHelpsetid);
          jTextFieldHelpsetid.setBounds(164, 318, 427, 21);
          jTextFieldHelpsetid.addKeyListener(new KeyAdapter() {
            public void keyTyped(KeyEvent evt) {

              jButtonUpdate.setEnabled(true);
            }
          });
        }
        {
          jLabel7 = new JLabel4j_std();
          jDesktopPane1.add(jLabel7);
          jLabel7.setText(lang.get("lbl_Module_Help"));
          jLabel7.setBounds(0, 318, 152, 21);
          jLabel7.setHorizontalAlignment(SwingConstants.TRAILING);
        }
        {
          jButtonHelp = new JButton4j(Common.icon_help);
          jDesktopPane1.add(jButtonHelp);
          jButtonHelp.setText(lang.get("btn_Help"));
          jButtonHelp.setBounds(250, 424, 112, 32);
          jButtonHelp.setMnemonic(lang.getMnemonicChar());
        }
        {
          jTextFieldReportFilename = new JTextField4j();
          jDesktopPane1.add(jTextFieldReportFilename);
          jTextFieldReportFilename.setBounds(164, 233, 218, 22);
          jTextFieldReportFilename.addKeyListener(new KeyAdapter() {
            public void keyTyped(KeyEvent evt) {
              jButtonUpdate.setEnabled(true);
            }

            public void keyReleased(KeyEvent evt) {
              jButtonIconPreview.setIcon(JDBModule.getModuleIcon(jTextFieldIconFilename.getText(), (String) jComboBoxType.getSelectedItem()));
            }
          });
        }
        {
          jLabel8 = new JLabel4j_std();
          jDesktopPane1.add(jLabel8);
          jLabel8.setText(lang.get("lbl_Module_Icon_Filename"));
          jLabel8.setHorizontalAlignment(SwingConstants.TRAILING);
          jLabel8.setBounds(0, 178, 152, 21);
        }
        {
          jButtonReportFileChooser = new JButton4j();
          jDesktopPane1.add(jButtonReportFileChooser);
          jButtonReportFileChooser.setText("..");
          jButtonReportFileChooser.setBounds(383, 234, 17, 21);
          jButtonReportFileChooser.addActionListener(new ActionListener() {
            public void actionPerformed(ActionEvent evt) {

              JFileChooser loadRpt = new JFileChooser();
              loadRpt.setAcceptAllFileFilterUsed(false);
              try
              {
                String path = "";
                if (((String) comboBox.getSelectedItem()).equals("Standard"))
                {
                  path = "./reports";
                }
                else
                {
                  path = "./labels";
                }
                File f = new File(new File(path).getCanonicalPath());
                loadRpt.setCurrentDirectory(f);

                if (((String) comboBox.getSelectedItem()).equals("Standard"))
                {
                  loadRpt.addChoosableFileFilter(new JFileFilterReports());
                }
                else
                {
                  loadRpt.addChoosableFileFilter(new JFileFilterLabels());
                }

                loadRpt.setSelectedFile(new File(jTextFieldReportFilename.getText()));
              }
              catch (Exception e)
              {
              }

              if (loadRpt.showOpenDialog(jButtonReportFileChooser) == JFileChooser.APPROVE_OPTION)
              {
                File selectedFile;
                selectedFile = loadRpt.getSelectedFile();

                if (selectedFile != null)
                {
                  if (jTextFieldReportFilename.getText().compareTo(selectedFile.getName()) != 0)
                  {
                    jTextFieldReportFilename.setText(selectedFile.getName());
                    jButtonUpdate.setEnabled(true);
                  }
                }
              }
            }
          });
        }
        {
          jTextFieldExecDir = new JTextField4j();
          jDesktopPane1.add(jTextFieldExecDir);
          jTextFieldExecDir.setBounds(164, 290, 427, 22);
          jTextFieldExecDir.addKeyListener(new KeyAdapter() {
            public void keyTyped(KeyEvent evt) {
              jButtonUpdate.setEnabled(true);
            }

            public void keyReleased(KeyEvent evt) {
              jButtonIconPreview.setIcon(JDBModule.getModuleIcon(jTextFieldIconFilename.getText(), (String) jComboBoxType.getSelectedItem()));
            }
          });
        }
        {
          jTextFieldExecFilename = new JTextField4j();
          jDesktopPane1.add(jTextFieldExecFilename);
          jTextFieldExecFilename.setBounds(164, 262, 427, 22);
          jTextFieldExecFilename.addKeyListener(new KeyAdapter() {
            public void keyTyped(KeyEvent evt) {
              jButtonUpdate.setEnabled(true);
View Full Code Here

            }
          });
        }
        {
          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<JDBUom> jComboBox2Model = new DefaultComboBoxModel<JDBUom>(uomList);
          jComboBoxUOM = new JComboBox4j<JDBUom>();
          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, 32);
          jButtonHelp.setMnemonic(lang.getMnemonicChar());
        }
        {
          jButtonClose = new JButton4j(Common.icon_close);
          jDesktopPane1.add(jButtonClose);
          jButtonClose.setText(lang.get("btn_Close"));
          jButtonClose.setBounds(866, 176, 129, 32);
          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, 32);
          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, 32);
          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<String> jComboBoxSortByModel = new DefaultComboBoxModel<String>(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<String>();
          jDesktopPane1.add(jComboBoxSortBy);
          jComboBoxSortBy.setModel(jComboBoxSortByModel);
          jComboBoxSortBy.setBounds(330, 143, 299, 23);
        }
        {
          ComboBoxModel<String> jComboBoxDefaultPalletStatusModel = new DefaultComboBoxModel<String>(Common.palletStatusIncBlank);
          jComboBoxPalletStatus = new JComboBox4j<String>();
          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 JCheckBox4j();
          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 JCheckBox4j();
          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 JCheckBox4j();
          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.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<String>();
          comboBoxTransactionType.setModel(new DefaultComboBoxModel<String>(Common.transactionTypes));
          comboBoxTransactionType.setBounds(593, 11, 124, 23);
          jDesktopPane1.add(comboBoxTransactionType);
        }

        {
          comboBoxTransactionSubtype = new JComboBox4j<String>();
          comboBoxTransactionSubtype.setModel(new DefaultComboBoxModel<String>(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, 32);
          jDesktopPane1.add(exportXlsButton);
        }

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

        {
View Full Code Here

TOP

Related Classes of com.commander4j.gui.JTextField4j

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.