public String charge(Properties ctx,int WindowNo,GridTab mTab,GridField mField,Object value){
  Integer C_Charge_ID=(Integer)value;
  if (C_Charge_ID == null || C_Charge_ID.intValue() == 0)   return "";
  String sql="SELECT ChargeAmt FROM C_Charge WHERE C_Charge_ID=?";
  PreparedStatement pstmt=null;
  ResultSet rs=null;
  try {
    pstmt=DB.prepareStatement(sql,null);
    pstmt.setInt(1,C_Charge_ID.intValue());
    rs=pstmt.executeQuery();
    if (rs.next()) {
      mTab.setValue("PriceEntered",rs.getBigDecimal(1));
    }
  }
 catch (  SQLException e) {
    log.log(Level.SEVERE,sql,e);
    return e.getLocalizedMessage();
  }
 finally {
    DB.close(rs,pstmt);
    rs=null;
    pstmt=null;
  }
  return tax(ctx,WindowNo,mTab,mField,value);
}

public String charge ( Properties ctx , int WindowNo , GridTab mTab , GridField mField , Object value ) { Integer C_Charge_ID = ( Integer ) value ; if ( C_Charge_ID == null || C_Charge_ID . intValue ( ) == 0 ) return "" ; String sql = "SELECT ChargeAmt FROM C_Charge WHERE C_Charge_ID=?" ; PreparedStatement pstmt = null ; ResultSet rs = null ; try { pstmt = DB . prepareStatement ( sql , null ) ; pstmt . setInt ( 1 , C_Charge_ID . intValue ( ) ) ; rs = pstmt . executeQuery ( ) ; if ( rs . next ( ) ) { mTab . setValue ( "PriceEntered" , rs . getBigDecimal ( 1 ) ) ; } } catch ( SQLException e ) { log . log ( Level . SEVERE , sql , e ) ; return e . getLocalizedMessage ( ) ; } finally { DB . close ( rs , pstmt ) ; rs = null ; pstmt = null ; } return tax ( ctx , WindowNo , mTab , mField , value ) ; }
invoice batch line - charge . - updates priceentered from charge calles tax
