Package com.commander4j.bar

Examples of com.commander4j.bar.JEANBarcode


  public String splitPallet(String oldSSCC, BigDecimal splitQuantity)
  {
    String result = "";
    JDBPallet p = new JDBPallet(getHostID(), getSessionID());
    JEANBarcode bc = new JEANBarcode(getHostID(), getSessionID());
    p.setSSCC(oldSSCC);
    if (p.getPalletProperties())
    {
      if ((splitQuantity.compareTo(BigDecimal.ZERO) > 0))
      {
        if (splitQuantity.compareTo(p.getQuantity()) < 0)

        {
          // Generate a Transaction No and Write Original Pallet
          // Details to History
          Long txn = p.writePalletHistory(0, "SPLIT", "BEFORE");
          // Write back Transaction No so we don't create a new one
          // next time.
          p.setTransactionRef(txn);
          // Amend Quantity of Original Pallet
          p.setQuantity(p.getQuantity().subtract(splitQuantity));
          // Save amended record for Original Pallet
          p.update();
          // Write Amended records to history;
          p.writePalletHistory(txn, "SPLIT", "AFTER");
          // Create a new SSCC for split quantity
          result = bc.generateNewSSCC();
          // Update original pallet record with new SSCC
          p.setSSCC(result);
          // Change quantity to that of the split
          p.setQuantity(splitQuantity);
          // Create the new pallet and write to history at the same
View Full Code Here


    setSessionID(session);
    lf = new JDBLocation(getHostID(), getSessionID());
    lt = new JDBLocation(getHostID(), getSessionID());
    pal = new JDBPallet(getHostID(), getSessionID());
    ml = new JDBMaterialLocation(getHostID(), getSessionID());
    bar = new JEANBarcode(getHostID(), getSessionID());
    ctrl = new JDBControl(getHostID(), getSessionID());
    ctrl.getProperties("DEFAULT_LOCATION");
    home_location = ctrl.getKeyValue();
    allowDespatchToSelf = Boolean.valueOf(ctrl.getKeyValueWithDefault("DESPATCH_TO_SELF", "false", "Allow despatch to source location"));
  }
View Full Code Here

    return result;
  }

  public static void initEANBarcode()
  {
    Common.barcode = new JEANBarcode(Common.selectedHostID, Common.sessionID);
  }
View Full Code Here

  private void addRecord()
  {
    String addSSCC = JUtility.replaceNullStringwithBlank(JOptionPane.showInputDialog(Common.mainForm, lang.get("dlg_SSCC_Add")));
    if (addSSCC.equals("") == false)
    {
      JEANBarcode bc = new JEANBarcode(Common.selectedHostID, Common.sessionID);
      if (addSSCC.toUpperCase().equals("AUTO"))
      {
        do
        {
          addSSCC = bc.generateNewSSCC();
        } while (addSSCC.equals(""));
      }

      if (bc.isValidSSCCformat(addSSCC))
      {
        JLaunchMenu.runForm("FRM_ADMIN_PALLET_EDIT", addSSCC);
      } else
      {
        JOptionPane.showMessageDialog(Common.mainForm, bc.getErrorMessage(), lang.get("dlg_Error"), JOptionPane.ERROR_MESSAGE);
      }
    }
  }
View Full Code Here

  private void addRecord()
  {
    String addSSCC = JUtility.replaceNullStringwithBlank((String) JOptionPane.showInputDialog(Common.mainForm, lang.get("dlg_SSCC_Add"), null, JOptionPane.QUESTION_MESSAGE,Common.icon_confirm, null, null));
    if (addSSCC.equals("") == false)
    {
      JEANBarcode bc = new JEANBarcode(Common.selectedHostID, Common.sessionID);
      if (addSSCC.toUpperCase().equals("AUTO"))
      {
        do
        {
          addSSCC = bc.generateNewSSCC();
        } while (addSSCC.equals(""));
      }

      if (bc.isValidSSCCformat(addSSCC))
      {
        JLaunchMenu.runForm("FRM_ADMIN_PALLET_EDIT", addSSCC);
      } else
      {
        JOptionPane.showMessageDialog(Common.mainForm, bc.getErrorMessage(), lang.get("dlg_Error"), JOptionPane.ERROR_MESSAGE,Common.icon_confirm);
      }
    }
  }
View Full Code Here

              connectedOK = true;

              if (bcodeLoaded == false)
              {
                bcodeLoaded = true;
                bcode = new JEANBarcode(Common.sd.getData(sessionID, "selectedHost"), sessionID);
              }
            }
          } else
          {
            connectedOK = true;
View Full Code Here

              connectedOK = true;

              if (bcodeLoaded == false)
              {
                bcodeLoaded = true;
                bcode = new JEANBarcode(Common.sd.getData(sessionID, "selectedHost"), sessionID);
              }
            }
          } else
          {
            connectedOK = true;
View Full Code Here

    return result;
  }

  public static void initEANBarcode()
  {
    Common.barcode = new JEANBarcode(Common.selectedHostID, Common.sessionID);
  }
View Full Code Here

    setSessionID(session);
    lf = new JDBLocation(getHostID(), getSessionID());
    lt = new JDBLocation(getHostID(), getSessionID());
    pal = new JDBPallet(getHostID(), getSessionID());
    ml = new JDBMaterialLocation(getHostID(), getSessionID());
    bar = new JEANBarcode(getHostID(), getSessionID());
    ctrl = new JDBControl(getHostID(), getSessionID());
    ctrl.getProperties("DEFAULT_LOCATION");
    home_location = ctrl.getKeyValue();
    allowDespatchToSelf = Boolean.valueOf(ctrl.getKeyValueWithDefault("DESPATCH_TO_SELF", "false", "Allow despatch to source location"));
  }
View Full Code Here

TOP

Related Classes of com.commander4j.bar.JEANBarcode

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.