IDEMPIERE-1979 / fix NPE on initial query
This commit is contained in:
parent
aa9dc46a27
commit
f8a1d6adfd
|
@ -713,7 +713,7 @@ public class InfoWindow extends InfoPanel implements ValueChangeListener, EventL
|
||||||
* when query not by click requery button, reuse prev where clause
|
* when query not by click requery button, reuse prev where clause
|
||||||
* IDEMPIERE-1979
|
* IDEMPIERE-1979
|
||||||
*/
|
*/
|
||||||
if (!isQueryByUser){
|
if (!isQueryByUser && prevWhereClause != null){
|
||||||
return prevWhereClause;
|
return prevWhereClause;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -828,7 +828,7 @@ public class InfoWindow extends InfoPanel implements ValueChangeListener, EventL
|
||||||
protected void setParameters(PreparedStatement pstmt, boolean forCount)
|
protected void setParameters(PreparedStatement pstmt, boolean forCount)
|
||||||
throws SQLException {
|
throws SQLException {
|
||||||
// when query not by click requery button, reuse parameter value
|
// when query not by click requery button, reuse parameter value
|
||||||
if (!isQueryByUser){
|
if (!isQueryByUser && prevParameterValues != null){
|
||||||
for (int parameterIndex = 0; parameterIndex < prevParameterValues.size(); parameterIndex++){
|
for (int parameterIndex = 0; parameterIndex < prevParameterValues.size(); parameterIndex++){
|
||||||
setParameter (pstmt, parameterIndex + 1, prevParameterValues.get(parameterIndex), prevQueryOperators.get(parameterIndex));
|
setParameter (pstmt, parameterIndex + 1, prevParameterValues.get(parameterIndex), prevQueryOperators.get(parameterIndex));
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue