Program: 6102
Project: 6102
Buggy source:
private void stateTransition(char cTrans){
  if (cTrans == '\n') {
    if (m_sBarcode.length() > 0) {
      String sCode=m_sBarcode.toString();
      if (sCode.startsWith("String_Node_Str")) {
        try {
          CustomerInfoExt newcustomer=dlSales.findCustomerExt(sCode);
          if (newcustomer == null) {
            Toolkit.getDefaultToolkit().beep();
            new MessageInf(MessageInf.SGN_WARNING,AppLocal.getIntString("String_Node_Str")).show(this);
          }
 else {
            m_oTicket.setCustomer(newcustomer);
            m_jTicketId.setText(m_oTicket.getName(m_oTicketExt));
          }
        }
 catch (        BasicException e) {
          Toolkit.getDefaultToolkit().beep();
          new MessageInf(MessageInf.SGN_WARNING,AppLocal.getIntString("String_Node_Str"),e).show(this);
        }
        stateToZero();
      }
 else       if (sCode.length() == 13 && sCode.startsWith("String_Node_Str")) {
        ProductInfoExt oProduct=new ProductInfoExt();
        oProduct.setReference(null);
        oProduct.setCode(sCode);
        oProduct.setName("String_Node_Str" + sCode.substring(3,7));
        oProduct.setPriceSell(Double.parseDouble(sCode.substring(7,12)) / 100);
        oProduct.setTaxCategoryInfo((TaxCategoryInfo)taxcategoriesmodel.getSelectedItem());
        addTicketLine(oProduct,1.0,includeTaxes(oProduct.getTaxCategoryInfo(),oProduct.getPriceSell()));
      }
 else       if (sCode.length() == 13 && sCode.startsWith("String_Node_Str")) {
        incProductByCodePrice(sCode.substring(0,7),Double.parseDouble(sCode.substring(7,12)) / 100);
      }
 else {
        incProductByCode(sCode);
      }
    }
 else {
      Toolkit.getDefaultToolkit().beep();
    }
  }
 else {
    m_sBarcode.append(cTrans);
    if (cTrans == '\u007f') {
      stateToZero();
    }
 else     if ((cTrans == '0') && (m_iNumberStatus == NUMBER_INPUTZERO)) {
      m_jPrice.setText("String_Node_Str");
    }
 else     if ((cTrans == '1' || cTrans == '2' || cTrans == '3' || cTrans == '4' || cTrans == '5' || cTrans == '6' || cTrans == '7' || cTrans == '8' || cTrans == '9') && (m_iNumberStatus == NUMBER_INPUTZERO)) {
      m_jPrice.setText(Character.toString(cTrans));
      m_iNumberStatus=NUMBER_INPUTINT;
      m_iNumberStatusInput=NUMBERVALID;
    }
 else     if ((cTrans == '0' || cTrans == '1' || cTrans == '2' || cTrans == '3' || cTrans == '4' || cTrans == '5' || cTrans == '6' || cTrans == '7' || cTrans == '8' || cTrans == '9') && (m_iNumberStatus == NUMBER_INPUTINT)) {
      m_jPrice.setText(m_jPrice.getText() + cTrans);
    }
 else     if (cTrans == '.' && m_iNumberStatus == NUMBER_INPUTZERO) {
      m_jPrice.setText("String_Node_Str");
      m_iNumberStatus=NUMBER_INPUTZERODEC;
    }
 else     if (cTrans == '.' && m_iNumberStatus == NUMBER_INPUTINT) {
      m_jPrice.setText(m_jPrice.getText() + "String_Node_Str");
      m_iNumberStatus=NUMBER_INPUTDEC;
    }
 else     if ((cTrans == '0') && (m_iNumberStatus == NUMBER_INPUTZERODEC || m_iNumberStatus == NUMBER_INPUTDEC)) {
      m_jPrice.setText(m_jPrice.getText() + cTrans);
    }
 else     if ((cTrans == '1' || cTrans == '2' || cTrans == '3' || cTrans == '4' || cTrans == '5' || cTrans == '6' || cTrans == '7' || cTrans == '8' || cTrans == '9') && (m_iNumberStatus == NUMBER_INPUTZERODEC || m_iNumberStatus == NUMBER_INPUTDEC)) {
      m_jPrice.setText(m_jPrice.getText() + cTrans);
      m_iNumberStatus=NUMBER_INPUTDEC;
      m_iNumberStatusInput=NUMBERVALID;
    }
 else     if (cTrans == '*' && (m_iNumberStatus == NUMBER_INPUTINT || m_iNumberStatus == NUMBER_INPUTDEC)) {
      m_jPor.setText("String_Node_Str");
      m_iNumberStatus=NUMBER_PORZERO;
    }
 else     if (cTrans == '*' && (m_iNumberStatus == NUMBER_INPUTZERO || m_iNumberStatus == NUMBER_INPUTZERODEC)) {
      m_jPrice.setText("String_Node_Str");
      m_jPor.setText("String_Node_Str");
      m_iNumberStatus=NUMBER_PORZERO;
    }
 else     if ((cTrans == '0') && (m_iNumberStatus == NUMBER_PORZERO)) {
      m_jPor.setText("String_Node_Str");
    }
 else     if ((cTrans == '1' || cTrans == '2' || cTrans == '3' || cTrans == '4' || cTrans == '5' || cTrans == '6' || cTrans == '7' || cTrans == '8' || cTrans == '9') && (m_iNumberStatus == NUMBER_PORZERO)) {
      m_jPor.setText("String_Node_Str" + Character.toString(cTrans));
      m_iNumberStatus=NUMBER_PORINT;
      m_iNumberStatusPor=NUMBERVALID;
    }
 else     if ((cTrans == '0' || cTrans == '1' || cTrans == '2' || cTrans == '3' || cTrans == '4' || cTrans == '5' || cTrans == '6' || cTrans == '7' || cTrans == '8' || cTrans == '9') && (m_iNumberStatus == NUMBER_PORINT)) {
      m_jPor.setText(m_jPor.getText() + cTrans);
    }
 else     if (cTrans == '.' && m_iNumberStatus == NUMBER_PORZERO) {
      m_jPor.setText("String_Node_Str");
      m_iNumberStatus=NUMBER_PORZERODEC;
    }
 else     if (cTrans == '.' && m_iNumberStatus == NUMBER_PORINT) {
      m_jPor.setText(m_jPor.getText() + "String_Node_Str");
      m_iNumberStatus=NUMBER_PORDEC;
    }
 else     if ((cTrans == '0') && (m_iNumberStatus == NUMBER_PORZERODEC || m_iNumberStatus == NUMBER_PORDEC)) {
      m_jPor.setText(m_jPor.getText() + cTrans);
    }
 else     if ((cTrans == '1' || cTrans == '2' || cTrans == '3' || cTrans == '4' || cTrans == '5' || cTrans == '6' || cTrans == '7' || cTrans == '8' || cTrans == '9') && (m_iNumberStatus == NUMBER_PORZERODEC || m_iNumberStatus == NUMBER_PORDEC)) {
      m_jPor.setText(m_jPor.getText() + cTrans);
      m_iNumberStatus=NUMBER_PORDEC;
      m_iNumberStatusPor=NUMBERVALID;
    }
 else     if (cTrans == '\u00a7' && m_iNumberStatusInput == NUMBERVALID && m_iNumberStatusPor == NUMBERZERO) {
      if (m_App.getDeviceScale().existsScale() && m_App.getAppUserView().getUser().hasPermission("String_Node_Str")) {
        try {
          Double value=m_App.getDeviceScale().readWeight();
          if (value != null) {
            ProductInfoExt product=getInputProduct();
            addTicketLine(product,value.doubleValue(),product.getPriceSell());
          }
        }
 catch (        ScaleException e) {
          Toolkit.getDefaultToolkit().beep();
          new MessageInf(MessageInf.SGN_WARNING,AppLocal.getIntString("String_Node_Str"),e).show(this);
          stateToZero();
        }
      }
 else {
        Toolkit.getDefaultToolkit().beep();
      }
    }
 else     if (cTrans == '\u00a7' && m_iNumberStatusInput == NUMBERZERO && m_iNumberStatusPor == NUMBERZERO) {
      int i=m_ticketlines.getSelectedIndex();
      if (i < 0) {
        Toolkit.getDefaultToolkit().beep();
      }
 else       if (m_App.getDeviceScale().existsScale()) {
        try {
          Double value=m_App.getDeviceScale().readWeight();
          if (value != null) {
            TicketLineInfo oLine=m_oTicket.getLine(i);
            oLine.setMultiply(value.doubleValue());
            oLine.setPrice(Math.abs(oLine.getPrice()));
            paintTicketLine(i,oLine);
          }
        }
 catch (        ScaleException e) {
          Toolkit.getDefaultToolkit().beep();
          new MessageInf(MessageInf.SGN_WARNING,AppLocal.getIntString("String_Node_Str"),e).show(this);
          stateToZero();
        }
      }
 else {
        Toolkit.getDefaultToolkit().beep();
      }
    }
 else     if (cTrans == '+' && m_iNumberStatusInput == NUMBERZERO && m_iNumberStatusPor == NUMBERZERO) {
      int i=m_ticketlines.getSelectedIndex();
      if (i < 0) {
        Toolkit.getDefaultToolkit().beep();
      }
 else {
        TicketLineInfo oLine=m_oTicket.getLine(i);
        oLine.setMultiply(oLine.getMultiply() + 1.0);
        paintTicketLine(i,oLine);
      }
    }
 else     if (cTrans == '-' && m_iNumberStatusInput == NUMBERZERO && m_iNumberStatusPor == NUMBERZERO && m_App.getAppUserView().getUser().hasPermission("String_Node_Str")) {
      int i=m_ticketlines.getSelectedIndex();
      if (i < 0) {
        Toolkit.getDefaultToolkit().beep();
      }
 else {
        TicketLineInfo oLine=m_oTicket.getLine(i);
        oLine.setMultiply(oLine.getMultiply() - 1.0);
        if (oLine.getMultiply() <= 0.0) {
          removeTicketLine(i);
        }
 else {
          paintTicketLine(i,oLine);
        }
      }
    }
 else     if (cTrans == '+' && m_iNumberStatusInput == NUMBERZERO && m_iNumberStatusPor == NUMBERVALID) {
      int i=m_ticketlines.getSelectedIndex();
      if (i < 0) {
        Toolkit.getDefaultToolkit().beep();
      }
 else {
        double dPor=getPorValue();
        TicketLineInfo oLine=m_oTicket.getLine(i);
        oLine.setMultiply(dPor);
        oLine.setPrice(Math.abs(oLine.getPrice()));
        paintTicketLine(i,oLine);
      }
    }
 else     if (cTrans == '-' && m_iNumberStatusInput == NUMBERZERO && m_iNumberStatusPor == NUMBERVALID && m_App.getAppUserView().getUser().hasPermission("String_Node_Str")) {
      int i=m_ticketlines.getSelectedIndex();
      if (i < 0) {
        Toolkit.getDefaultToolkit().beep();
      }
 else {
        double dPor=getPorValue();
        TicketLineInfo oLine=m_oTicket.getLine(i);
        oLine.setMultiply(dPor);
        oLine.setPrice(-Math.abs(oLine.getPrice()));
        paintTicketLine(i,oLine);
      }
    }
 else     if (cTrans == '+' && m_iNumberStatusInput == NUMBERVALID && m_iNumberStatusPor == NUMBERZERO && m_App.getAppUserView().getUser().hasPermission("String_Node_Str")) {
      ProductInfoExt product=getInputProduct();
      addTicketLine(product,1.0,product.getPriceSell());
    }
 else     if (cTrans == '-' && m_iNumberStatusInput == NUMBERVALID && m_iNumberStatusPor == NUMBERZERO && m_App.getAppUserView().getUser().hasPermission("String_Node_Str")) {
      ProductInfoExt product=getInputProduct();
      addTicketLine(product,1.0,-product.getPriceSell());
    }
 else     if (cTrans == '+' && m_iNumberStatusInput == NUMBERVALID && m_iNumberStatusPor == NUMBERVALID && m_App.getAppUserView().getUser().hasPermission("String_Node_Str")) {
      ProductInfoExt product=getInputProduct();
      addTicketLine(product,getPorValue(),product.getPriceSell());
    }
 else     if (cTrans == '-' && m_iNumberStatusInput == NUMBERVALID && m_iNumberStatusPor == NUMBERVALID && m_App.getAppUserView().getUser().hasPermission("String_Node_Str")) {
      ProductInfoExt product=getInputProduct();
      addTicketLine(product,getPorValue(),-product.getPriceSell());
    }
 else     if (cTrans == ' ' || cTrans == '=') {
      if (m_oTicket.getLinesCount() > 0) {
        if (closeTicket(m_oTicket,m_oTicketExt)) {
          m_ticketsbag.deleteTicket();
        }
 else {
          refreshTicket();
        }
      }
 else {
        Toolkit.getDefaultToolkit().beep();
      }
    }
  }
}

Fixed version (ground truth):
private void stateTransition(char cTrans){
  if (cTrans == '\n') {
    if (m_sBarcode.length() > 0) {
      String sCode=m_sBarcode.toString();
      if (sCode.startsWith("String_Node_Str")) {
        try {
          CustomerInfoExt newcustomer=dlSales.findCustomerExt(sCode);
          if (newcustomer == null) {
            Toolkit.getDefaultToolkit().beep();
            new MessageInf(MessageInf.SGN_WARNING,AppLocal.getIntString("String_Node_Str")).show(this);
          }
 else {
            m_oTicket.setCustomer(newcustomer);
            m_jTicketId.setText(m_oTicket.getName(m_oTicketExt));
          }
        }
 catch (        BasicException e) {
          Toolkit.getDefaultToolkit().beep();
          new MessageInf(MessageInf.SGN_WARNING,AppLocal.getIntString("String_Node_Str"),e).show(this);
        }
        stateToZero();
      }
 else       if (sCode.length() == 13 && sCode.startsWith("String_Node_Str")) {
        ProductInfoExt oProduct=new ProductInfoExt();
        oProduct.setReference(null);
        oProduct.setCode(sCode);
        oProduct.setName("String_Node_Str" + sCode.substring(3,7));
        oProduct.setPriceSell(Double.parseDouble(sCode.substring(7,12)) / 100);
        oProduct.setTaxCategoryInfo((TaxCategoryInfo)taxcategoriesmodel.getSelectedItem());
        addTicketLine(oProduct,1.0,includeTaxes(oProduct.getTaxCategoryInfo(),oProduct.getPriceSell()));
      }
 else       if (sCode.length() == 13 && sCode.startsWith("String_Node_Str")) {
        incProductByCodePrice(sCode.substring(0,7),Double.parseDouble(sCode.substring(7,12)) / 100);
      }
 else {
        incProductByCode(sCode);
      }
    }
 else {
      Toolkit.getDefaultToolkit().beep();
    }
  }
 else {
    m_sBarcode.append(cTrans);
    if (cTrans == '\u007f') {
      stateToZero();
    }
 else     if ((cTrans == '0') && (m_iNumberStatus == NUMBER_INPUTZERO)) {
      m_jPrice.setText("String_Node_Str");
    }
 else     if ((cTrans == '1' || cTrans == '2' || cTrans == '3' || cTrans == '4' || cTrans == '5' || cTrans == '6' || cTrans == '7' || cTrans == '8' || cTrans == '9') && (m_iNumberStatus == NUMBER_INPUTZERO)) {
      m_jPrice.setText(Character.toString(cTrans));
      m_iNumberStatus=NUMBER_INPUTINT;
      m_iNumberStatusInput=NUMBERVALID;
    }
 else     if ((cTrans == '0' || cTrans == '1' || cTrans == '2' || cTrans == '3' || cTrans == '4' || cTrans == '5' || cTrans == '6' || cTrans == '7' || cTrans == '8' || cTrans == '9') && (m_iNumberStatus == NUMBER_INPUTINT)) {
      m_jPrice.setText(m_jPrice.getText() + cTrans);
    }
 else     if (cTrans == '.' && m_iNumberStatus == NUMBER_INPUTZERO) {
      m_jPrice.setText("String_Node_Str");
      m_iNumberStatus=NUMBER_INPUTZERODEC;
    }
 else     if (cTrans == '.' && m_iNumberStatus == NUMBER_INPUTINT) {
      m_jPrice.setText(m_jPrice.getText() + "String_Node_Str");
      m_iNumberStatus=NUMBER_INPUTDEC;
    }
 else     if ((cTrans == '0') && (m_iNumberStatus == NUMBER_INPUTZERODEC || m_iNumberStatus == NUMBER_INPUTDEC)) {
      m_jPrice.setText(m_jPrice.getText() + cTrans);
    }
 else     if ((cTrans == '1' || cTrans == '2' || cTrans == '3' || cTrans == '4' || cTrans == '5' || cTrans == '6' || cTrans == '7' || cTrans == '8' || cTrans == '9') && (m_iNumberStatus == NUMBER_INPUTZERODEC || m_iNumberStatus == NUMBER_INPUTDEC)) {
      m_jPrice.setText(m_jPrice.getText() + cTrans);
      m_iNumberStatus=NUMBER_INPUTDEC;
      m_iNumberStatusInput=NUMBERVALID;
    }
 else     if (cTrans == '*' && (m_iNumberStatus == NUMBER_INPUTINT || m_iNumberStatus == NUMBER_INPUTDEC)) {
      m_jPor.setText("String_Node_Str");
      m_iNumberStatus=NUMBER_PORZERO;
    }
 else     if (cTrans == '*' && (m_iNumberStatus == NUMBER_INPUTZERO || m_iNumberStatus == NUMBER_INPUTZERODEC)) {
      m_jPrice.setText("String_Node_Str");
      m_jPor.setText("String_Node_Str");
      m_iNumberStatus=NUMBER_PORZERO;
    }
 else     if ((cTrans == '0') && (m_iNumberStatus == NUMBER_PORZERO)) {
      m_jPor.setText("String_Node_Str");
    }
 else     if ((cTrans == '1' || cTrans == '2' || cTrans == '3' || cTrans == '4' || cTrans == '5' || cTrans == '6' || cTrans == '7' || cTrans == '8' || cTrans == '9') && (m_iNumberStatus == NUMBER_PORZERO)) {
      m_jPor.setText("String_Node_Str" + Character.toString(cTrans));
      m_iNumberStatus=NUMBER_PORINT;
      m_iNumberStatusPor=NUMBERVALID;
    }
 else     if ((cTrans == '0' || cTrans == '1' || cTrans == '2' || cTrans == '3' || cTrans == '4' || cTrans == '5' || cTrans == '6' || cTrans == '7' || cTrans == '8' || cTrans == '9') && (m_iNumberStatus == NUMBER_PORINT)) {
      m_jPor.setText(m_jPor.getText() + cTrans);
    }
 else     if (cTrans == '.' && m_iNumberStatus == NUMBER_PORZERO) {
      m_jPor.setText("String_Node_Str");
      m_iNumberStatus=NUMBER_PORZERODEC;
    }
 else     if (cTrans == '.' && m_iNumberStatus == NUMBER_PORINT) {
      m_jPor.setText(m_jPor.getText() + "String_Node_Str");
      m_iNumberStatus=NUMBER_PORDEC;
    }
 else     if ((cTrans == '0') && (m_iNumberStatus == NUMBER_PORZERODEC || m_iNumberStatus == NUMBER_PORDEC)) {
      m_jPor.setText(m_jPor.getText() + cTrans);
    }
 else     if ((cTrans == '1' || cTrans == '2' || cTrans == '3' || cTrans == '4' || cTrans == '5' || cTrans == '6' || cTrans == '7' || cTrans == '8' || cTrans == '9') && (m_iNumberStatus == NUMBER_PORZERODEC || m_iNumberStatus == NUMBER_PORDEC)) {
      m_jPor.setText(m_jPor.getText() + cTrans);
      m_iNumberStatus=NUMBER_PORDEC;
      m_iNumberStatusPor=NUMBERVALID;
    }
 else     if (cTrans == '\u00a7' && m_iNumberStatusInput == NUMBERVALID && m_iNumberStatusPor == NUMBERZERO) {
      if (m_App.getDeviceScale().existsScale() && m_App.getAppUserView().getUser().hasPermission("String_Node_Str")) {
        try {
          Double value=m_App.getDeviceScale().readWeight();
          if (value != null) {
            ProductInfoExt product=getInputProduct();
            addTicketLine(product,value.doubleValue(),product.getPriceSell());
          }
        }
 catch (        ScaleException e) {
          Toolkit.getDefaultToolkit().beep();
          new MessageInf(MessageInf.SGN_WARNING,AppLocal.getIntString("String_Node_Str"),e).show(this);
          stateToZero();
        }
      }
 else {
        Toolkit.getDefaultToolkit().beep();
      }
    }
 else     if (cTrans == '\u00a7' && m_iNumberStatusInput == NUMBERZERO && m_iNumberStatusPor == NUMBERZERO) {
      int i=m_ticketlines.getSelectedIndex();
      if (i < 0) {
        Toolkit.getDefaultToolkit().beep();
      }
 else       if (m_App.getDeviceScale().existsScale()) {
        try {
          Double value=m_App.getDeviceScale().readWeight();
          if (value != null) {
            TicketLineInfo newline=new TicketLineInfo(m_oTicket.getLine(i));
            newline.setMultiply(value.doubleValue());
            newline.setPrice(Math.abs(newline.getPrice()));
            paintTicketLine(i,newline);
          }
        }
 catch (        ScaleException e) {
          Toolkit.getDefaultToolkit().beep();
          new MessageInf(MessageInf.SGN_WARNING,AppLocal.getIntString("String_Node_Str"),e).show(this);
          stateToZero();
        }
      }
 else {
        Toolkit.getDefaultToolkit().beep();
      }
    }
 else     if (cTrans == '+' && m_iNumberStatusInput == NUMBERZERO && m_iNumberStatusPor == NUMBERZERO) {
      int i=m_ticketlines.getSelectedIndex();
      if (i < 0) {
        Toolkit.getDefaultToolkit().beep();
      }
 else {
        TicketLineInfo newline=new TicketLineInfo(m_oTicket.getLine(i));
        newline.setMultiply(newline.getMultiply() + 1.0);
        paintTicketLine(i,newline);
      }
    }
 else     if (cTrans == '-' && m_iNumberStatusInput == NUMBERZERO && m_iNumberStatusPor == NUMBERZERO && m_App.getAppUserView().getUser().hasPermission("String_Node_Str")) {
      int i=m_ticketlines.getSelectedIndex();
      if (i < 0) {
        Toolkit.getDefaultToolkit().beep();
      }
 else {
        TicketLineInfo newline=new TicketLineInfo(m_oTicket.getLine(i));
        newline.setMultiply(newline.getMultiply() - 1.0);
        if (newline.getMultiply() <= 0.0) {
          removeTicketLine(i);
        }
 else {
          paintTicketLine(i,newline);
        }
      }
    }
 else     if (cTrans == '+' && m_iNumberStatusInput == NUMBERZERO && m_iNumberStatusPor == NUMBERVALID) {
      int i=m_ticketlines.getSelectedIndex();
      if (i < 0) {
        Toolkit.getDefaultToolkit().beep();
      }
 else {
        double dPor=getPorValue();
        TicketLineInfo newline=new TicketLineInfo(m_oTicket.getLine(i));
        newline.setMultiply(dPor);
        newline.setPrice(Math.abs(newline.getPrice()));
        paintTicketLine(i,newline);
      }
    }
 else     if (cTrans == '-' && m_iNumberStatusInput == NUMBERZERO && m_iNumberStatusPor == NUMBERVALID && m_App.getAppUserView().getUser().hasPermission("String_Node_Str")) {
      int i=m_ticketlines.getSelectedIndex();
      if (i < 0) {
        Toolkit.getDefaultToolkit().beep();
      }
 else {
        double dPor=getPorValue();
        TicketLineInfo newline=new TicketLineInfo(m_oTicket.getLine(i));
        newline.setMultiply(dPor);
        newline.setPrice(-Math.abs(newline.getPrice()));
        paintTicketLine(i,newline);
      }
    }
 else     if (cTrans == '+' && m_iNumberStatusInput == NUMBERVALID && m_iNumberStatusPor == NUMBERZERO && m_App.getAppUserView().getUser().hasPermission("String_Node_Str")) {
      ProductInfoExt product=getInputProduct();
      addTicketLine(product,1.0,product.getPriceSell());
    }
 else     if (cTrans == '-' && m_iNumberStatusInput == NUMBERVALID && m_iNumberStatusPor == NUMBERZERO && m_App.getAppUserView().getUser().hasPermission("String_Node_Str")) {
      ProductInfoExt product=getInputProduct();
      addTicketLine(product,1.0,-product.getPriceSell());
    }
 else     if (cTrans == '+' && m_iNumberStatusInput == NUMBERVALID && m_iNumberStatusPor == NUMBERVALID && m_App.getAppUserView().getUser().hasPermission("String_Node_Str")) {
      ProductInfoExt product=getInputProduct();
      addTicketLine(product,getPorValue(),product.getPriceSell());
    }
 else     if (cTrans == '-' && m_iNumberStatusInput == NUMBERVALID && m_iNumberStatusPor == NUMBERVALID && m_App.getAppUserView().getUser().hasPermission("String_Node_Str")) {
      ProductInfoExt product=getInputProduct();
      addTicketLine(product,getPorValue(),-product.getPriceSell());
    }
 else     if (cTrans == ' ' || cTrans == '=') {
      if (m_oTicket.getLinesCount() > 0) {
        if (closeTicket(m_oTicket,m_oTicketExt)) {
          m_ticketsbag.deleteTicket();
        }
 else {
          refreshTicket();
        }
      }
 else {
        Toolkit.getDefaultToolkit().beep();
      }
    }
  }
}