diff --git a/base/src/org/compiere/model/MAcctSchemaDefault.java b/base/src/org/compiere/model/MAcctSchemaDefault.java index b8de7d0aba..c5aec04768 100644 --- a/base/src/org/compiere/model/MAcctSchemaDefault.java +++ b/base/src/org/compiere/model/MAcctSchemaDefault.java @@ -33,10 +33,12 @@ import org.compiere.util.KeyNamePair; */ public class MAcctSchemaDefault extends X_C_AcctSchema_Default { - /** - * - */ - private static final long serialVersionUID = 199959007595802866L; + + + /** + * + */ + private static final long serialVersionUID = 199959007595802866L; /** * Get Accounting Schema Default Info @@ -46,7 +48,7 @@ public class MAcctSchemaDefault extends X_C_AcctSchema_Default */ public static MAcctSchemaDefault get (Properties ctx, int C_AcctSchema_ID) { - String whereClause = "C_AcctSchema_ID=?"; + final String whereClause = "C_AcctSchema_ID=?"; return new Query(ctx,I_C_AcctSchema_Default.Table_Name,whereClause,null) .setParameters(C_AcctSchema_ID) .firstOnly(); diff --git a/base/src/org/compiere/model/MAcctSchemaElement.java b/base/src/org/compiere/model/MAcctSchemaElement.java index ec6f1aaeb0..b99c422dbf 100644 --- a/base/src/org/compiere/model/MAcctSchemaElement.java +++ b/base/src/org/compiere/model/MAcctSchemaElement.java @@ -40,10 +40,12 @@ import org.compiere.util.Msg; */ public final class MAcctSchemaElement extends X_C_AcctSchema_Element { - /** - * - */ - private static final long serialVersionUID = 4215184252533527719L; + + + /** + * + */ + private static final long serialVersionUID = 4215184252533527719L; /** @@ -61,7 +63,7 @@ public final class MAcctSchemaElement extends X_C_AcctSchema_Element s_log.fine("C_AcctSchema_ID=" + as.getC_AcctSchema_ID()); ArrayList list = new ArrayList(); - String whereClause = "C_AcctSchema_ID=? AND IsActive=?"; + final String whereClause = "C_AcctSchema_ID=? AND IsActive=?"; List elements= new Query(as.getCtx(), I_C_AcctSchema_Element.Table_Name,whereClause,as.get_TrxName()) .setParameters(as.getC_AcctSchema_ID(),"Y") .setOrderBy("SeqNo") diff --git a/base/src/org/compiere/model/MAcctSchemaGL.java b/base/src/org/compiere/model/MAcctSchemaGL.java index 89396a57f2..a2453a688f 100644 --- a/base/src/org/compiere/model/MAcctSchemaGL.java +++ b/base/src/org/compiere/model/MAcctSchemaGL.java @@ -35,10 +35,12 @@ import org.compiere.util.KeyNamePair; */ public class MAcctSchemaGL extends X_C_AcctSchema_GL { - /** - * - */ - private static final long serialVersionUID = 5303102649110271896L; + + + /** + * + */ + private static final long serialVersionUID = 5303102649110271896L; /** @@ -49,7 +51,7 @@ public class MAcctSchemaGL extends X_C_AcctSchema_GL */ public static MAcctSchemaGL get (Properties ctx, int C_AcctSchema_ID) { - String whereClause = "C_AcctSchema_ID=?"; + final String whereClause = "C_AcctSchema_ID=?"; return new Query(ctx,I_C_AcctSchema_GL.Table_Name,whereClause,null) .setParameters(C_AcctSchema_ID) .firstOnly(); diff --git a/base/src/org/compiere/model/MPInstance.java b/base/src/org/compiere/model/MPInstance.java index 44153a0397..8b6160a3d5 100644 --- a/base/src/org/compiere/model/MPInstance.java +++ b/base/src/org/compiere/model/MPInstance.java @@ -40,10 +40,11 @@ import org.compiere.util.Env; */ public class MPInstance extends X_AD_PInstance { - /** - * - */ - private static final long serialVersionUID = -5848424269552679604L; + + /** + * + */ + private static final long serialVersionUID = -5848424269552679604L; /** * Standard Constructor @@ -126,7 +127,7 @@ public class MPInstance extends X_AD_PInstance if (m_parameters != null) return m_parameters; //FR: [ 2214883 ] Remove SQL code and Replace for Query - red1 - String whereClause = "AD_PInstance_ID=?"; + final String whereClause = "AD_PInstance_ID=?"; List list = new Query(getCtx(), I_AD_PInstance_Para.Table_Name, whereClause, null) // @TODO: Review implications of using transaction .setParameters(getAD_PInstance_ID()) .list(); diff --git a/base/src/org/compiere/model/MPaySelection.java b/base/src/org/compiere/model/MPaySelection.java index 17f49e1821..5e5fa68e2f 100644 --- a/base/src/org/compiere/model/MPaySelection.java +++ b/base/src/org/compiere/model/MPaySelection.java @@ -30,10 +30,11 @@ import org.compiere.util.Env; */ public class MPaySelection extends X_C_PaySelection { - /** - * - */ - private static final long serialVersionUID = -6521282913549455131L; + + /** + * + */ + private static final long serialVersionUID = -6521282913549455131L; /** * Default Constructor @@ -84,7 +85,7 @@ public class MPaySelection extends X_C_PaySelection return m_lines; } //FR: [ 2214883 ] Remove SQL code and Replace for Query - red1 - String whereClause = "C_PaySelection_ID=?"; + final String whereClause = "C_PaySelection_ID=?"; List list = new Query(getCtx(), I_C_PaySelectionLine.Table_Name, whereClause, get_TrxName()) .setParameters(getC_PaySelection_ID()) .setOrderBy("Line") diff --git a/base/src/org/compiere/model/MPayment.java b/base/src/org/compiere/model/MPayment.java index cb2fa35baa..ab69dc1dfd 100644 --- a/base/src/org/compiere/model/MPayment.java +++ b/base/src/org/compiere/model/MPayment.java @@ -77,10 +77,12 @@ import org.compiere.util.ValueNamePair; public final class MPayment extends X_C_Payment implements DocAction, ProcessCall { - /** - * - */ - private static final long serialVersionUID = 6200327948230438741L; + + + /** + * + */ + private static final long serialVersionUID = 6200327948230438741L; /** * Get Payments Of BPartner @@ -92,7 +94,7 @@ public final class MPayment extends X_C_Payment public static MPayment[] getOfBPartner (Properties ctx, int C_BPartner_ID, String trxName) { //FR: [ 2214883 ] Remove SQL code and Replace for Query - red1 - String whereClause = "C_BPartner_ID=?"; + final String whereClause = "C_BPartner_ID=?"; List list = new Query(ctx, I_C_Payment.Table_Name, whereClause, trxName) .setParameters(C_BPartner_ID) .list(); diff --git a/base/src/org/compiere/model/MProductPricing.java b/base/src/org/compiere/model/MProductPricing.java index e7093f3e1d..ce7a321b2d 100644 --- a/base/src/org/compiere/model/MProductPricing.java +++ b/base/src/org/compiere/model/MProductPricing.java @@ -20,7 +20,6 @@ import java.math.BigDecimal; import java.sql.PreparedStatement; import java.sql.ResultSet; import java.sql.Timestamp; -import java.util.List; import java.util.logging.Level; import org.compiere.util.CLogger; @@ -719,7 +718,7 @@ public class MProductPricing return; // //FR: [ 2214883 ] Remove SQL code and Replace for Query - red1 - String whereClause = "M_Product_ID=?"; + final String whereClause = "M_Product_ID=?"; MProduct retValue = new Query(Env.getCtx(), I_M_Product.Table_Name, whereClause, null) .setParameters(m_M_Product_ID) .first(); diff --git a/base/src/org/compiere/model/MProject.java b/base/src/org/compiere/model/MProject.java index fc0f8a7d5e..984dfe4ed5 100644 --- a/base/src/org/compiere/model/MProject.java +++ b/base/src/org/compiere/model/MProject.java @@ -16,11 +16,8 @@ *****************************************************************************/ package org.compiere.model; -import java.sql.PreparedStatement; import java.sql.ResultSet; -import java.sql.SQLException; import java.sql.Timestamp; -import java.util.ArrayList; import java.util.List; import java.util.Properties; import java.util.logging.Level; @@ -36,10 +33,11 @@ import org.compiere.util.Env; */ public class MProject extends X_C_Project { - /** - * - */ - private static final long serialVersionUID = -1781787100948563589L; + + /** + * + */ + private static final long serialVersionUID = -1781787100948563589L; /** * Create new Project by copying @@ -206,7 +204,7 @@ public class MProject extends X_C_Project public MProjectLine[] getLines() { //FR: [ 2214883 ] Remove SQL code and Replace for Query - red1 - String whereClause = "C_Project_ID=?"; + final String whereClause = "C_Project_ID=?"; List list = new Query(getCtx(), I_C_ProjectLine.Table_Name, whereClause, get_TrxName()) .setParameters(getC_Project_ID()) .setOrderBy("Line") diff --git a/base/src/org/compiere/model/MRequestType.java b/base/src/org/compiere/model/MRequestType.java index 4fc9f4a006..ff3197b483 100644 --- a/base/src/org/compiere/model/MRequestType.java +++ b/base/src/org/compiere/model/MRequestType.java @@ -18,10 +18,8 @@ package org.compiere.model; import java.sql.PreparedStatement; import java.sql.ResultSet; -import java.sql.SQLException; import java.sql.Timestamp; import java.util.ArrayList; -import java.util.List; import java.util.Properties; import java.util.logging.Level; @@ -40,10 +38,11 @@ import org.compiere.util.Env; */ public class MRequestType extends X_R_RequestType { - /** - * - */ - private static final long serialVersionUID = 6235793036503665638L; + + /** + * + */ + private static final long serialVersionUID = 6235793036503665638L; /** * Get Request Type (cached) @@ -78,7 +77,7 @@ public class MRequestType extends X_R_RequestType int AD_Client_ID = Env.getAD_Client_ID(ctx); //FR: [ 2214883 ] Remove SQL code and Replace for Query - red1 - String whereClause = "AD_Client_ID IN (0," + AD_Client_ID + ")"; + final String whereClause = "AD_Client_ID IN (0," + AD_Client_ID + ")"; MRequestType retValue = new Query(ctx, I_R_RequestType.Table_Name, whereClause, null) .setOrderBy("IsDefault DESC, AD_Client_ID DESC") .first(); diff --git a/base/src/org/compiere/model/M_Element.java b/base/src/org/compiere/model/M_Element.java index 07e4e31050..c6e7a8ae02 100644 --- a/base/src/org/compiere/model/M_Element.java +++ b/base/src/org/compiere/model/M_Element.java @@ -33,10 +33,11 @@ import org.compiere.util.Msg; */ public class M_Element extends X_AD_Element { - /** - * - */ - private static final long serialVersionUID = -7426812810619889250L; + + /** + * + */ + private static final long serialVersionUID = -6644398794862560030L; /** * Get case sensitive Column Name @@ -107,7 +108,7 @@ public class M_Element extends X_AD_Element { if (AD_Column_ID ==0) return null; - String whereClause = "EXISTS (SELECT 1 FROM AD_Column c " + final String whereClause = "EXISTS (SELECT 1 FROM AD_Column c " + "WHERE c.AD_Element_ID=AD_Element.AD_Element_ID AND c.AD_Column_ID=?)"; M_Element retValue = new Query(ctx, Table_Name, whereClause, trxName) .setParameters(AD_Column_ID)