Merge f45f50571e52
This commit is contained in:
commit
6ae0aaaa82
|
@ -0,0 +1,8 @@
|
||||||
|
-- Feb 22, 2013 3:02:16 PM COT
|
||||||
|
-- IDEMPIERE-325 Complete AD based info window ( AD_InfoWindow ) implementation
|
||||||
|
UPDATE AD_InfoColumn SET IsDisplayed='N',Updated=TO_DATE('2013-02-22 15:02:16','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_InfoColumn_ID=200061
|
||||||
|
;
|
||||||
|
|
||||||
|
SELECT register_migration_script('201302221504_IDEMPIERE-325.sql') FROM dual
|
||||||
|
;
|
||||||
|
|
|
@ -0,0 +1,8 @@
|
||||||
|
-- Feb 22, 2013 3:02:16 PM COT
|
||||||
|
-- IDEMPIERE-325 Complete AD based info window ( AD_InfoWindow ) implementation
|
||||||
|
UPDATE AD_InfoColumn SET IsDisplayed='N',Updated=TO_TIMESTAMP('2013-02-22 15:02:16','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_InfoColumn_ID=200061
|
||||||
|
;
|
||||||
|
|
||||||
|
SELECT register_migration_script('201302221504_IDEMPIERE-325.sql') FROM dual
|
||||||
|
;
|
||||||
|
|
|
@ -71,7 +71,7 @@ public class DocumentTypeVerify extends SvrProcess
|
||||||
public static void createDocumentTypes(Properties ctx, int AD_Client_ID,
|
public static void createDocumentTypes(Properties ctx, int AD_Client_ID,
|
||||||
SvrProcess sp, String trxName)
|
SvrProcess sp, String trxName)
|
||||||
{
|
{
|
||||||
s_log.info("AD_Client_ID=" + AD_Client_ID);
|
if (s_log.isLoggable(Level.INFO)) s_log.info("AD_Client_ID=" + AD_Client_ID);
|
||||||
String sql = "SELECT rl.Value, rl.Name "
|
String sql = "SELECT rl.Value, rl.Name "
|
||||||
+ "FROM AD_Ref_List rl "
|
+ "FROM AD_Ref_List rl "
|
||||||
+ "WHERE rl.AD_Reference_ID=183"
|
+ "WHERE rl.AD_Reference_ID=183"
|
||||||
|
@ -129,7 +129,7 @@ public class DocumentTypeVerify extends SvrProcess
|
||||||
public static void createPeriodControls(Properties ctx, int AD_Client_ID,
|
public static void createPeriodControls(Properties ctx, int AD_Client_ID,
|
||||||
SvrProcess sp, String trxName)
|
SvrProcess sp, String trxName)
|
||||||
{
|
{
|
||||||
s_log.info("AD_Client_ID=" + AD_Client_ID);
|
if (s_log.isLoggable(Level.INFO)) s_log.info("AD_Client_ID=" + AD_Client_ID);
|
||||||
|
|
||||||
// Delete Duplicates
|
// Delete Duplicates
|
||||||
String sql = "DELETE C_PeriodControl pc1 "
|
String sql = "DELETE C_PeriodControl pc1 "
|
||||||
|
@ -143,7 +143,7 @@ public class DocumentTypeVerify extends SvrProcess
|
||||||
+ "FROM C_PeriodControl pc3 "
|
+ "FROM C_PeriodControl pc3 "
|
||||||
+ "GROUP BY C_Period_ID, DocBaseType)";
|
+ "GROUP BY C_Period_ID, DocBaseType)";
|
||||||
int no = DB.executeUpdate(sql, false, trxName);
|
int no = DB.executeUpdate(sql, false, trxName);
|
||||||
s_log.info("Duplicates deleted #" + no);
|
if (s_log.isLoggable(Level.INFO)) s_log.info("Duplicates deleted #" + no);
|
||||||
|
|
||||||
// Insert Missing
|
// Insert Missing
|
||||||
sql = "SELECT DISTINCT p.AD_Client_ID, p.C_Period_ID, dt.DocBaseType "
|
sql = "SELECT DISTINCT p.AD_Client_ID, p.C_Period_ID, dt.DocBaseType "
|
||||||
|
@ -174,7 +174,7 @@ public class DocumentTypeVerify extends SvrProcess
|
||||||
if (pc.save())
|
if (pc.save())
|
||||||
{
|
{
|
||||||
counter++;
|
counter++;
|
||||||
s_log.fine(pc.toString());
|
if (s_log.isLoggable(Level.FINE)) s_log.fine(pc.toString());
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
s_log.warning("Not saved: " + pc);
|
s_log.warning("Not saved: " + pc);
|
||||||
|
@ -192,7 +192,7 @@ public class DocumentTypeVerify extends SvrProcess
|
||||||
}
|
}
|
||||||
if (sp != null)
|
if (sp != null)
|
||||||
sp.addLog (0, null, new BigDecimal(counter), "@C_PeriodControl_ID@ @Created@");
|
sp.addLog (0, null, new BigDecimal(counter), "@C_PeriodControl_ID@ @Created@");
|
||||||
s_log.info("Inserted #" + counter);
|
if (s_log.isLoggable(Level.INFO)) s_log.info("Inserted #" + counter);
|
||||||
} // createPeriodControls
|
} // createPeriodControls
|
||||||
|
|
||||||
} // DocumentTypeVerify
|
} // DocumentTypeVerify
|
||||||
|
|
|
@ -147,7 +147,7 @@ public class SequenceCheck extends SvrProcess
|
||||||
sp.addLog(0, null, null,msglog.toString());
|
sp.addLog(0, null, null,msglog.toString());
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
s_log.fine("Sync #" + no);
|
if (s_log.isLoggable(Level.FINE)) s_log.fine("Sync #" + no);
|
||||||
}
|
}
|
||||||
if (no >= 0)
|
if (no >= 0)
|
||||||
return;
|
return;
|
||||||
|
@ -194,7 +194,7 @@ public class SequenceCheck extends SvrProcess
|
||||||
if (IDRangeEnd <= 0)
|
if (IDRangeEnd <= 0)
|
||||||
IDRangeEnd = DB.getSQLValue(null,
|
IDRangeEnd = DB.getSQLValue(null,
|
||||||
"SELECT MIN(IDRangeStart)-1 FROM AD_Replication");
|
"SELECT MIN(IDRangeStart)-1 FROM AD_Replication");
|
||||||
s_log.info("IDRangeEnd = " + IDRangeEnd);
|
if (s_log.isLoggable(Level.INFO)) s_log.info("IDRangeEnd = " + IDRangeEnd);
|
||||||
//
|
//
|
||||||
String sql = "SELECT * FROM AD_Sequence "
|
String sql = "SELECT * FROM AD_Sequence "
|
||||||
+ "WHERE IsTableID='Y' "
|
+ "WHERE IsTableID='Y' "
|
||||||
|
@ -239,7 +239,7 @@ public class SequenceCheck extends SvrProcess
|
||||||
DB.close(rs, pstmt);
|
DB.close(rs, pstmt);
|
||||||
rs = null; pstmt = null;
|
rs = null; pstmt = null;
|
||||||
}
|
}
|
||||||
s_log.fine("#" + counter);
|
if (s_log.isLoggable(Level.FINE)) s_log.fine("#" + counter);
|
||||||
} // checkTableID
|
} // checkTableID
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -136,8 +136,7 @@ public class Core {
|
||||||
* @return initialized PaymentProcessor or null
|
* @return initialized PaymentProcessor or null
|
||||||
*/
|
*/
|
||||||
public static PaymentProcessor getPaymentProcessor(MBankAccountProcessor mbap, PaymentInterface mp) {
|
public static PaymentProcessor getPaymentProcessor(MBankAccountProcessor mbap, PaymentInterface mp) {
|
||||||
if (s_log.isLoggable(Level.FINE))
|
if (s_log.isLoggable(Level.FINE)) s_log.fine("create for " + mbap);
|
||||||
s_log.fine("create for " + mbap);
|
|
||||||
|
|
||||||
MPaymentProcessor mpp = new MPaymentProcessor(mbap.getCtx(), mbap.getC_PaymentProcessor_ID(), mbap.get_TrxName());
|
MPaymentProcessor mpp = new MPaymentProcessor(mbap.getCtx(), mbap.getC_PaymentProcessor_ID(), mbap.get_TrxName());
|
||||||
String className = mpp.getPayProcessorClass();
|
String className = mpp.getPayProcessorClass();
|
||||||
|
@ -177,8 +176,7 @@ public class Core {
|
||||||
*/
|
*/
|
||||||
public static IShipmentProcessor getShipmentProcessor(MShipperFacade sf)
|
public static IShipmentProcessor getShipmentProcessor(MShipperFacade sf)
|
||||||
{
|
{
|
||||||
if (s_log.isLoggable(Level.FINE))
|
if (s_log.isLoggable(Level.FINE)) s_log.fine("create for " + sf);
|
||||||
s_log.fine("create for " + sf);
|
|
||||||
|
|
||||||
String className = sf.getShippingProcessorClass();
|
String className = sf.getShippingProcessorClass();
|
||||||
if (className == null || className.length() == 0)
|
if (className == null || className.length() == 0)
|
||||||
|
|
|
@ -232,7 +232,7 @@ public class DefaultModelFactory implements IModelFactory {
|
||||||
{
|
{
|
||||||
if (superClazz == PO.class)
|
if (superClazz == PO.class)
|
||||||
{
|
{
|
||||||
s_log.fine("Use: " + className);
|
if (s_log.isLoggable(Level.FINE)) s_log.fine("Use: " + className);
|
||||||
return clazz;
|
return clazz;
|
||||||
}
|
}
|
||||||
superClazz = superClazz.getSuperclass();
|
superClazz = superClazz.getSuperclass();
|
||||||
|
|
|
@ -13,6 +13,8 @@
|
||||||
*****************************************************************************/
|
*****************************************************************************/
|
||||||
package org.adempiere.exceptions;
|
package org.adempiere.exceptions;
|
||||||
|
|
||||||
|
import java.util.logging.Level;
|
||||||
|
|
||||||
import org.adempiere.exceptions.AdempiereException;
|
import org.adempiere.exceptions.AdempiereException;
|
||||||
import org.compiere.model.PO;
|
import org.compiere.model.PO;
|
||||||
import org.compiere.util.CLogger;
|
import org.compiere.util.CLogger;
|
||||||
|
@ -68,7 +70,7 @@ public class PORelationException extends AdempiereException {
|
||||||
|
|
||||||
public static void throwWrongKeyColumnCount(final PO po) {
|
public static void throwWrongKeyColumnCount(final PO po) {
|
||||||
|
|
||||||
logger.fine("Invoked with po " + po);
|
if (logger.isLoggable(Level.FINE)) logger.fine("Invoked with po " + po);
|
||||||
|
|
||||||
final Object[] msgParams = new Object[] { po.toString(),
|
final Object[] msgParams = new Object[] { po.toString(),
|
||||||
po.get_KeyColumns().length };
|
po.get_KeyColumns().length };
|
||||||
|
|
|
@ -26,6 +26,7 @@ import java.util.HashSet;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import java.util.Properties;
|
import java.util.Properties;
|
||||||
import java.util.Set;
|
import java.util.Set;
|
||||||
|
import java.util.logging.Level;
|
||||||
|
|
||||||
import org.adempiere.exceptions.AdempiereException;
|
import org.adempiere.exceptions.AdempiereException;
|
||||||
import org.adempiere.exceptions.PORelationException;
|
import org.adempiere.exceptions.PORelationException;
|
||||||
|
@ -143,7 +144,7 @@ public class MRelationType extends X_AD_RelationType implements IZoomProvider {
|
||||||
|
|
||||||
final List<MRelationType> result = evalResultSet(po, windowId, rs);
|
final List<MRelationType> result = evalResultSet(po, windowId, rs);
|
||||||
|
|
||||||
logger.info("There are " + result.size() + " matching types for "
|
if (logger.isLoggable(Level.INFO)) logger.info("There are " + result.size() + " matching types for "
|
||||||
+ po);
|
+ po);
|
||||||
|
|
||||||
return result;
|
return result;
|
||||||
|
@ -294,7 +295,7 @@ public class MRelationType extends X_AD_RelationType implements IZoomProvider {
|
||||||
parsedWhere, po.get_TrxName()).first();
|
parsedWhere, po.get_TrxName()).first();
|
||||||
final boolean match = result != null;
|
final boolean match = result != null;
|
||||||
|
|
||||||
logger.fine("whereClause='" + parsedWhere + "' matches po='" + po
|
if (logger.isLoggable(Level.FINE)) logger.fine("whereClause='" + parsedWhere + "' matches po='" + po
|
||||||
+ "':" + match);
|
+ "':" + match);
|
||||||
return match;
|
return match;
|
||||||
}
|
}
|
||||||
|
@ -328,7 +329,7 @@ public class MRelationType extends X_AD_RelationType implements IZoomProvider {
|
||||||
final String parsedWhere = Env.parseContext(privateCtx, -1, where,
|
final String parsedWhere = Env.parseContext(privateCtx, -1, where,
|
||||||
false);
|
false);
|
||||||
|
|
||||||
logger.fine("whereClause='" + where + "'; parsedWhere='" + parsedWhere
|
if (logger.isLoggable(Level.FINE)) logger.fine("whereClause='" + where + "'; parsedWhere='" + parsedWhere
|
||||||
+ "'");
|
+ "'");
|
||||||
|
|
||||||
return parsedWhere;
|
return parsedWhere;
|
||||||
|
|
|
@ -17,6 +17,7 @@ import java.util.ArrayList;
|
||||||
import java.util.HashSet;
|
import java.util.HashSet;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import java.util.Set;
|
import java.util.Set;
|
||||||
|
import java.util.logging.Level;
|
||||||
|
|
||||||
import org.compiere.model.MQuery;
|
import org.compiere.model.MQuery;
|
||||||
import org.compiere.model.PO;
|
import org.compiere.model.PO;
|
||||||
|
@ -83,7 +84,7 @@ public class ZoomInfoFactory {
|
||||||
public static List<ZoomInfoFactory.ZoomInfo> retrieveZoomInfos(final PO po,
|
public static List<ZoomInfoFactory.ZoomInfo> retrieveZoomInfos(final PO po,
|
||||||
final int windowID) {
|
final int windowID) {
|
||||||
|
|
||||||
logger.config("PO=" + po + " - AD_Window_ID=" + windowID);
|
if (logger.isLoggable(Level.CONFIG)) logger.config("PO=" + po + " - AD_Window_ID=" + windowID);
|
||||||
|
|
||||||
final List<ZoomInfoFactory.ZoomInfo> result = new ArrayList<ZoomInfoFactory.ZoomInfo>();
|
final List<ZoomInfoFactory.ZoomInfo> result = new ArrayList<ZoomInfoFactory.ZoomInfo>();
|
||||||
|
|
||||||
|
@ -94,7 +95,7 @@ public class ZoomInfoFactory {
|
||||||
|
|
||||||
if (alreadySeen.add(zoomInfo.destinationDisplay)) {
|
if (alreadySeen.add(zoomInfo.destinationDisplay)) {
|
||||||
|
|
||||||
logger.fine("Adding zoomInfo " + zoomInfo);
|
if (logger.isLoggable(Level.FINE)) logger.fine("Adding zoomInfo " + zoomInfo);
|
||||||
result.add(zoomInfo);
|
result.add(zoomInfo);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -106,13 +107,13 @@ public class ZoomInfoFactory {
|
||||||
|
|
||||||
if (alreadySeen.add(zoomInfo.destinationDisplay)) {
|
if (alreadySeen.add(zoomInfo.destinationDisplay)) {
|
||||||
|
|
||||||
logger.fine("Adding zoomInfo " + zoomInfo + " from "
|
if (logger.isLoggable(Level.FINE)) logger.fine("Adding zoomInfo " + zoomInfo + " from "
|
||||||
+ GenericZoomProvider.class.getSimpleName());
|
+ GenericZoomProvider.class.getSimpleName());
|
||||||
result.add(zoomInfo);
|
result.add(zoomInfo);
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
|
|
||||||
logger.fine("Skipping zoomInfo " + zoomInfo + " from "
|
if (logger.isLoggable(Level.FINE)) logger.fine("Skipping zoomInfo " + zoomInfo + " from "
|
||||||
+ GenericZoomProvider.class.getSimpleName()
|
+ GenericZoomProvider.class.getSimpleName()
|
||||||
+ " because there is already one for destination '"
|
+ " because there is already one for destination '"
|
||||||
+ zoomInfo.destinationDisplay + "'");
|
+ zoomInfo.destinationDisplay + "'");
|
||||||
|
|
|
@ -556,7 +556,7 @@ public class Doc_Order extends Doc
|
||||||
if (!tax.isZeroTax())
|
if (!tax.isZeroTax())
|
||||||
{
|
{
|
||||||
BigDecimal LineNetAmtTax = tax.calculateTax(LineNetAmt, true, precision);
|
BigDecimal LineNetAmtTax = tax.calculateTax(LineNetAmt, true, precision);
|
||||||
s_log.fine("LineNetAmt=" + LineNetAmt + " - Tax=" + LineNetAmtTax);
|
if (s_log.isLoggable(Level.FINE)) s_log.fine("LineNetAmt=" + LineNetAmt + " - Tax=" + LineNetAmtTax);
|
||||||
LineNetAmt = LineNetAmt.subtract(LineNetAmtTax);
|
LineNetAmt = LineNetAmt.subtract(LineNetAmtTax);
|
||||||
BigDecimal PriceListTax = tax.calculateTax(PriceList, true, precision);
|
BigDecimal PriceListTax = tax.calculateTax(PriceList, true, precision);
|
||||||
PriceList = PriceList.subtract(PriceListTax);
|
PriceList = PriceList.subtract(PriceListTax);
|
||||||
|
@ -697,7 +697,7 @@ public class Doc_Order extends Doc
|
||||||
if (!tax.isZeroTax())
|
if (!tax.isZeroTax())
|
||||||
{
|
{
|
||||||
BigDecimal LineNetAmtTax = tax.calculateTax(LineNetAmt, true, precision);
|
BigDecimal LineNetAmtTax = tax.calculateTax(LineNetAmt, true, precision);
|
||||||
s_log.fine("LineNetAmt=" + LineNetAmt + " - Tax=" + LineNetAmtTax);
|
if (s_log.isLoggable(Level.FINE)) s_log.fine("LineNetAmt=" + LineNetAmt + " - Tax=" + LineNetAmtTax);
|
||||||
LineNetAmt = LineNetAmt.subtract(LineNetAmtTax);
|
LineNetAmt = LineNetAmt.subtract(LineNetAmtTax);
|
||||||
BigDecimal PriceListTax = tax.calculateTax(PriceList, true, precision);
|
BigDecimal PriceListTax = tax.calculateTax(PriceList, true, precision);
|
||||||
PriceList = PriceList.subtract(PriceListTax);
|
PriceList = PriceList.subtract(PriceListTax);
|
||||||
|
|
|
@ -227,7 +227,7 @@ public class MAccount extends X_C_ValidCombination
|
||||||
s_log.log(Level.SEVERE, "Could not create new account - " + info);
|
s_log.log(Level.SEVERE, "Could not create new account - " + info);
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
s_log.fine("New: " + newAccount);
|
if (s_log.isLoggable(Level.FINE)) s_log.fine("New: " + newAccount);
|
||||||
return newAccount;
|
return newAccount;
|
||||||
} // get
|
} // get
|
||||||
|
|
||||||
|
@ -330,7 +330,7 @@ public class MAccount extends X_C_ValidCombination
|
||||||
else if (elementType.equals(MAcctSchemaElement.ELEMENTTYPE_UserElement2) && setValue)
|
else if (elementType.equals(MAcctSchemaElement.ELEMENTTYPE_UserElement2) && setValue)
|
||||||
vc.setUserElement2_ID(defaultValue);
|
vc.setUserElement2_ID(defaultValue);
|
||||||
}
|
}
|
||||||
s_log.fine("Client_ID="
|
if (s_log.isLoggable(Level.FINE)) s_log.fine("Client_ID="
|
||||||
+ vc.getAD_Client_ID() + ", Org_ID=" + vc.getAD_Org_ID()
|
+ vc.getAD_Client_ID() + ", Org_ID=" + vc.getAD_Org_ID()
|
||||||
+ " - AcctSchema_ID=" + vc.getC_AcctSchema_ID() + ", Account_ID=" + vc.getAccount_ID());
|
+ " - AcctSchema_ID=" + vc.getC_AcctSchema_ID() + ", Account_ID=" + vc.getAccount_ID());
|
||||||
return vc;
|
return vc;
|
||||||
|
|
|
@ -60,7 +60,7 @@ public final class MAcctSchemaElement extends X_C_AcctSchema_Element
|
||||||
if (retValue != null)
|
if (retValue != null)
|
||||||
return retValue;
|
return retValue;
|
||||||
|
|
||||||
s_log.fine("C_AcctSchema_ID=" + as.getC_AcctSchema_ID());
|
if (s_log.isLoggable(Level.FINE)) s_log.fine("C_AcctSchema_ID=" + as.getC_AcctSchema_ID());
|
||||||
ArrayList<MAcctSchemaElement> list = new ArrayList<MAcctSchemaElement>();
|
ArrayList<MAcctSchemaElement> list = new ArrayList<MAcctSchemaElement>();
|
||||||
|
|
||||||
final String whereClause = "C_AcctSchema_ID=? AND IsActive=?";
|
final String whereClause = "C_AcctSchema_ID=? AND IsActive=?";
|
||||||
|
@ -71,7 +71,7 @@ public final class MAcctSchemaElement extends X_C_AcctSchema_Element
|
||||||
|
|
||||||
for(MAcctSchemaElement ase : elements)
|
for(MAcctSchemaElement ase : elements)
|
||||||
{
|
{
|
||||||
s_log.fine(" - " + ase);
|
if (s_log.isLoggable(Level.FINE)) s_log.fine(" - " + ase);
|
||||||
if (ase.isMandatory() && ase.getDefaultValue() == 0)
|
if (ase.isMandatory() && ase.getDefaultValue() == 0)
|
||||||
s_log.log(Level.SEVERE, "No default value for " + ase.getName());
|
s_log.log(Level.SEVERE, "No default value for " + ase.getName());
|
||||||
list.add(ase);
|
list.add(ase);
|
||||||
|
|
|
@ -76,7 +76,7 @@ public class MArchive extends X_AD_Archive {
|
||||||
if (list.size() == 0)
|
if (list.size() == 0)
|
||||||
s_log.fine(sql.toString());
|
s_log.fine(sql.toString());
|
||||||
else
|
else
|
||||||
s_log.finer(sql.toString());
|
if (s_log.isLoggable(Level.FINER)) s_log.finer(sql.toString());
|
||||||
//
|
//
|
||||||
MArchive[] retValue = new MArchive[list.size()];
|
MArchive[] retValue = new MArchive[list.size()];
|
||||||
list.toArray(retValue);
|
list.toArray(retValue);
|
||||||
|
|
|
@ -6,13 +6,13 @@ import java.sql.ResultSet;
|
||||||
import java.sql.Timestamp;
|
import java.sql.Timestamp;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import java.util.Properties;
|
import java.util.Properties;
|
||||||
|
import java.util.logging.Level;
|
||||||
|
|
||||||
import org.adempiere.exceptions.FillMandatoryException;
|
import org.adempiere.exceptions.FillMandatoryException;
|
||||||
import org.compiere.process.DocAction;
|
import org.compiere.process.DocAction;
|
||||||
import org.compiere.process.DocumentEngine;
|
import org.compiere.process.DocumentEngine;
|
||||||
import org.compiere.process.ProcessInfo;
|
import org.compiere.process.ProcessInfo;
|
||||||
import org.compiere.process.ProjectClose;
|
import org.compiere.process.ProjectClose;
|
||||||
import org.compiere.util.CLogMgt;
|
|
||||||
import org.compiere.util.CLogger;
|
import org.compiere.util.CLogger;
|
||||||
import org.compiere.util.DB;
|
import org.compiere.util.DB;
|
||||||
import org.compiere.util.Env;
|
import org.compiere.util.Env;
|
||||||
|
@ -35,11 +35,11 @@ import org.idempiere.fa.util.POCacheLocal;
|
||||||
public class MAssetAddition extends X_A_Asset_Addition
|
public class MAssetAddition extends X_A_Asset_Addition
|
||||||
implements DocAction
|
implements DocAction
|
||||||
{
|
{
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
private static final long serialVersionUID = 5977180589101094202L;
|
private static final long serialVersionUID = 5977180589101094202L;
|
||||||
|
|
||||||
/** Static Logger */
|
/** Static Logger */
|
||||||
private static CLogger s_log = CLogger.getCLogger(MAssetAddition.class);
|
private static CLogger s_log = CLogger.getCLogger(MAssetAddition.class);
|
||||||
|
|
||||||
|
@ -386,7 +386,7 @@ public class MAssetAddition extends X_A_Asset_Addition
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
if(CLogMgt.isLevelFine()) s_log.fine("Entering: model=" + model + ", M_MatchInv_ID=" + M_MatchInv_ID + ", newRecord=" + newRecord + ", trxName=" + trxName);
|
if (s_log.isLoggable(Level.FINE)) s_log.fine("Entering: model=" + model + ", M_MatchInv_ID=" + M_MatchInv_ID + ", newRecord=" + newRecord + ", trxName=" + trxName);
|
||||||
|
|
||||||
final String qMatchInv_select = "SELECT"
|
final String qMatchInv_select = "SELECT"
|
||||||
+ " C_Invoice_ID"
|
+ " C_Invoice_ID"
|
||||||
|
@ -435,7 +435,7 @@ public class MAssetAddition extends X_A_Asset_Addition
|
||||||
*/
|
*/
|
||||||
SetGetUtil.updateColumns(model, null, query, trxName);
|
SetGetUtil.updateColumns(model, null, query, trxName);
|
||||||
|
|
||||||
if(CLogMgt.isLevelFine()) s_log.fine("Leaving: RETURN TRUE");
|
s_log.fine("Leaving: RETURN TRUE");
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -15,6 +15,7 @@ package org.compiere.model;
|
||||||
|
|
||||||
import java.sql.ResultSet;
|
import java.sql.ResultSet;
|
||||||
import java.util.Properties;
|
import java.util.Properties;
|
||||||
|
import java.util.logging.Level;
|
||||||
|
|
||||||
import org.compiere.model.MRefList;
|
import org.compiere.model.MRefList;
|
||||||
import org.compiere.model.PO;
|
import org.compiere.model.PO;
|
||||||
|
@ -103,7 +104,7 @@ public class MAssetChange extends X_A_Asset_Change
|
||||||
}
|
}
|
||||||
|
|
||||||
public static MAssetChange create(Properties ctx, String changeType, PO[] pos, boolean save, String trxName) {
|
public static MAssetChange create(Properties ctx, String changeType, PO[] pos, boolean save, String trxName) {
|
||||||
s_log.fine("Entering: changeType=" + changeType);
|
if (s_log.isLoggable(Level.FINE)) s_log.fine("Entering: changeType=" + changeType);
|
||||||
if (pos == null || pos.length == 0) {
|
if (pos == null || pos.length == 0) {
|
||||||
s_log.fine("Entering/Leaving: POs is empty");
|
s_log.fine("Entering/Leaving: POs is empty");
|
||||||
return null;
|
return null;
|
||||||
|
@ -117,7 +118,7 @@ public class MAssetChange extends X_A_Asset_Change
|
||||||
change.saveEx();
|
change.saveEx();
|
||||||
}
|
}
|
||||||
//
|
//
|
||||||
s_log.fine("Leaving: change=" + change);
|
if (s_log.isLoggable(Level.FINE)) s_log.fine("Leaving: change=" + change);
|
||||||
return change;
|
return change;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -21,6 +21,7 @@ import java.sql.ResultSet;
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import java.util.Properties;
|
import java.util.Properties;
|
||||||
|
import java.util.logging.Level;
|
||||||
|
|
||||||
import org.compiere.util.CLogger;
|
import org.compiere.util.CLogger;
|
||||||
import org.compiere.util.DB;
|
import org.compiere.util.DB;
|
||||||
|
@ -74,7 +75,7 @@ public class MAttribute extends X_M_Attribute
|
||||||
|
|
||||||
MAttribute[] retValue = new MAttribute[list.size ()];
|
MAttribute[] retValue = new MAttribute[list.size ()];
|
||||||
list.toArray (retValue);
|
list.toArray (retValue);
|
||||||
s_log.fine("AD_Client_ID=" + AD_Client_ID + " - #" + list.size());
|
if (s_log.isLoggable(Level.FINE)) s_log.fine("AD_Client_ID=" + AD_Client_ID + " - #" + list.size());
|
||||||
return retValue;
|
return retValue;
|
||||||
} // getOfClient
|
} // getOfClient
|
||||||
|
|
||||||
|
|
|
@ -61,11 +61,11 @@ public class MAttributeSetInstance extends X_M_AttributeSetInstance
|
||||||
// Load Instance if not 0
|
// Load Instance if not 0
|
||||||
if (M_AttributeSetInstance_ID != 0)
|
if (M_AttributeSetInstance_ID != 0)
|
||||||
{
|
{
|
||||||
s_log.fine("From M_AttributeSetInstance_ID=" + M_AttributeSetInstance_ID);
|
if (s_log.isLoggable(Level.FINE)) s_log.fine("From M_AttributeSetInstance_ID=" + M_AttributeSetInstance_ID);
|
||||||
return new MAttributeSetInstance (ctx, M_AttributeSetInstance_ID, null);
|
return new MAttributeSetInstance (ctx, M_AttributeSetInstance_ID, null);
|
||||||
}
|
}
|
||||||
// Get new from Product
|
// Get new from Product
|
||||||
s_log.fine("From M_Product_ID=" + M_Product_ID);
|
if (s_log.isLoggable(Level.FINE)) s_log.fine("From M_Product_ID=" + M_Product_ID);
|
||||||
if (M_Product_ID == 0)
|
if (M_Product_ID == 0)
|
||||||
return null;
|
return null;
|
||||||
String sql = "SELECT M_AttributeSet_ID, M_AttributeSetInstance_ID "
|
String sql = "SELECT M_AttributeSet_ID, M_AttributeSetInstance_ID "
|
||||||
|
|
|
@ -122,7 +122,7 @@ public class MBankAccountProcessor extends X_C_BankAccount_Processor {
|
||||||
s_log.warning("find - not found - AD_Client_ID=" + AD_Client_ID
|
s_log.warning("find - not found - AD_Client_ID=" + AD_Client_ID
|
||||||
+ ", C_Currency_ID=" + C_Currency_ID + ", Amt=" + Amt);
|
+ ", C_Currency_ID=" + C_Currency_ID + ", Amt=" + Amt);
|
||||||
else
|
else
|
||||||
s_log.fine("find - #" + list.size() + " - AD_Client_ID=" + AD_Client_ID
|
if (s_log.isLoggable(Level.FINE)) s_log.fine("find - #" + list.size() + " - AD_Client_ID=" + AD_Client_ID
|
||||||
+ ", C_Currency_ID=" + C_Currency_ID + ", Amt=" + Amt);
|
+ ", C_Currency_ID=" + C_Currency_ID + ", Amt=" + Amt);
|
||||||
MBankAccountProcessor[] retValue = new MBankAccountProcessor[list.size()];
|
MBankAccountProcessor[] retValue = new MBankAccountProcessor[list.size()];
|
||||||
list.toArray(retValue);
|
list.toArray(retValue);
|
||||||
|
|
|
@ -90,7 +90,7 @@ public class MChangeLog extends X_AD_ChangeLog
|
||||||
Integer id = (Integer)list.get(i);
|
Integer id = (Integer)list.get(i);
|
||||||
s_changeLog[i] = id.intValue();
|
s_changeLog[i] = id.intValue();
|
||||||
}
|
}
|
||||||
s_log.info("#" + s_changeLog.length);
|
if (s_log.isLoggable(Level.INFO)) s_log.info("#" + s_changeLog.length);
|
||||||
} // fillChangeLog
|
} // fillChangeLog
|
||||||
|
|
||||||
/** Change Log */
|
/** Change Log */
|
||||||
|
|
|
@ -19,6 +19,7 @@ package org.compiere.model;
|
||||||
import java.sql.ResultSet;
|
import java.sql.ResultSet;
|
||||||
import java.sql.Timestamp;
|
import java.sql.Timestamp;
|
||||||
import java.util.Properties;
|
import java.util.Properties;
|
||||||
|
import java.util.logging.Level;
|
||||||
|
|
||||||
import org.compiere.util.CLogger;
|
import org.compiere.util.CLogger;
|
||||||
import org.compiere.util.Env;
|
import org.compiere.util.Env;
|
||||||
|
@ -62,10 +63,10 @@ public class MContactInterest extends X_R_ContactInterest
|
||||||
{
|
{
|
||||||
retValue = new MContactInterest (ctx, R_InterestArea_ID, AD_User_ID,
|
retValue = new MContactInterest (ctx, R_InterestArea_ID, AD_User_ID,
|
||||||
isActive, trxName);
|
isActive, trxName);
|
||||||
s_log.fine("NOT found - " + retValue);
|
if (s_log.isLoggable(Level.FINE)) s_log.fine("NOT found - " + retValue);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
s_log.fine("Found - " + retValue);
|
if (s_log.isLoggable(Level.FINE)) s_log.fine("Found - " + retValue);
|
||||||
return retValue;
|
return retValue;
|
||||||
} // get
|
} // get
|
||||||
|
|
||||||
|
|
|
@ -251,7 +251,7 @@ public class MConversionRate extends X_C_Conversion_Rate
|
||||||
pstmt = null;
|
pstmt = null;
|
||||||
}
|
}
|
||||||
if (retValue == null)
|
if (retValue == null)
|
||||||
s_log.info ("getRate - not found - CurFrom=" + CurFrom_ID
|
if (s_log.isLoggable(Level.INFO)) s_log.info ("getRate - not found - CurFrom=" + CurFrom_ID
|
||||||
+ ", CurTo=" + CurTo_ID
|
+ ", CurTo=" + CurTo_ID
|
||||||
+ ", " + ConvDate
|
+ ", " + ConvDate
|
||||||
+ ", Type=" + ConversionType_ID + (ConversionType_ID==C_ConversionType_ID ? "" : "->" + C_ConversionType_ID)
|
+ ", Type=" + ConversionType_ID + (ConversionType_ID==C_ConversionType_ID ? "" : "->" + C_ConversionType_ID)
|
||||||
|
|
|
@ -6,8 +6,8 @@ package org.compiere.model;
|
||||||
import java.math.BigDecimal;
|
import java.math.BigDecimal;
|
||||||
import java.math.RoundingMode;
|
import java.math.RoundingMode;
|
||||||
import java.sql.Timestamp;
|
import java.sql.Timestamp;
|
||||||
|
import java.util.logging.Level;
|
||||||
|
|
||||||
import org.compiere.util.CLogMgt;
|
|
||||||
import org.compiere.util.CLogger;
|
import org.compiere.util.CLogger;
|
||||||
import org.compiere.util.Env;
|
import org.compiere.util.Env;
|
||||||
import org.idempiere.exceptions.NoCurrencyConversionException;
|
import org.idempiere.exceptions.NoCurrencyConversionException;
|
||||||
|
@ -97,7 +97,7 @@ public final class MConversionRateUtil
|
||||||
if (AmtName != null)
|
if (AmtName != null)
|
||||||
model.set_AttrValue(AmtName, amt);
|
model.set_AttrValue(AmtName, amt);
|
||||||
// Return amt
|
// Return amt
|
||||||
if (CLogMgt.isLevelFine()) s_log.fine("amt=" + sourceAmt + " * " + rate + "=" + amt + ", scale=" + stdPrecision);
|
if (s_log.isLoggable(Level.FINE)) s_log.fine("amt=" + sourceAmt + " * " + rate + "=" + amt + ", scale=" + stdPrecision);
|
||||||
return amt;
|
return amt;
|
||||||
} // convert
|
} // convert
|
||||||
}
|
}
|
||||||
|
|
|
@ -221,7 +221,7 @@ public class MCost extends X_M_Cost
|
||||||
// Standard costs - just Material Costs
|
// Standard costs - just Material Costs
|
||||||
if (MCostElement.COSTINGMETHOD_StandardCosting.equals(costingMethod))
|
if (MCostElement.COSTINGMETHOD_StandardCosting.equals(costingMethod))
|
||||||
{
|
{
|
||||||
s_log.finer("MaterialCosts = " + materialCost);
|
if (s_log.isLoggable(Level.FINER)) s_log.finer("MaterialCosts = " + materialCost);
|
||||||
return materialCost;
|
return materialCost;
|
||||||
}
|
}
|
||||||
if (MCostElement.COSTINGMETHOD_Fifo.equals(costingMethod)
|
if (MCostElement.COSTINGMETHOD_Fifo.equals(costingMethod)
|
||||||
|
@ -240,7 +240,7 @@ public class MCost extends X_M_Cost
|
||||||
if (costs.signum() == 0)
|
if (costs.signum() == 0)
|
||||||
return null;
|
return null;
|
||||||
|
|
||||||
s_log.finer("Sum Costs = " + costs);
|
if (s_log.isLoggable(Level.FINER)) s_log.finer("Sum Costs = " + costs);
|
||||||
int precision = as.getCostingPrecision();
|
int precision = as.getCostingPrecision();
|
||||||
if (percentage.signum() == 0) // no percentages
|
if (percentage.signum() == 0) // no percentages
|
||||||
{
|
{
|
||||||
|
@ -254,7 +254,7 @@ public class MCost extends X_M_Cost
|
||||||
costs = costs.add(percentCost);
|
costs = costs.add(percentCost);
|
||||||
if (costs.scale() > precision)
|
if (costs.scale() > precision)
|
||||||
costs = costs.setScale(precision, BigDecimal.ROUND_HALF_UP);
|
costs = costs.setScale(precision, BigDecimal.ROUND_HALF_UP);
|
||||||
s_log.finer("Sum Costs = " + costs + " (Add=" + percentCost + ")");
|
if (s_log.isLoggable(Level.FINER)) s_log.finer("Sum Costs = " + costs + " (Add=" + percentCost + ")");
|
||||||
return costs;
|
return costs;
|
||||||
} // getCurrentCost
|
} // getCurrentCost
|
||||||
|
|
||||||
|
@ -296,7 +296,7 @@ public class MCost extends X_M_Cost
|
||||||
throw new IllegalArgumentException("Unknown Costing Method = " + costingMethod);
|
throw new IllegalArgumentException("Unknown Costing Method = " + costingMethod);
|
||||||
if (retValue != null && retValue.signum() > 0)
|
if (retValue != null && retValue.signum() > 0)
|
||||||
{
|
{
|
||||||
s_log.fine(product.getName() + ", CostingMethod=" + costingMethod + " - " + retValue);
|
if (s_log.isLoggable(Level.FINE)) s_log.fine(product.getName() + ", CostingMethod=" + costingMethod + " - " + retValue);
|
||||||
return retValue;
|
return retValue;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -306,7 +306,7 @@ public class MCost extends X_M_Cost
|
||||||
retValue = getPOPrice(product, C_OrderLine_ID, as.getC_Currency_ID());
|
retValue = getPOPrice(product, C_OrderLine_ID, as.getC_Currency_ID());
|
||||||
if (retValue != null && retValue.signum() > 0)
|
if (retValue != null && retValue.signum() > 0)
|
||||||
{
|
{
|
||||||
s_log.fine(product.getName() + ", PO - " + retValue);
|
if (s_log.isLoggable(Level.FINE)) s_log.fine(product.getName() + ", PO - " + retValue);
|
||||||
return retValue;
|
return retValue;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -318,7 +318,7 @@ public class MCost extends X_M_Cost
|
||||||
MCost cost = get(product, M_ASI_ID, as, Org_ID, ce.getM_CostElement_ID(), product.get_TrxName());
|
MCost cost = get(product, M_ASI_ID, as, Org_ID, ce.getM_CostElement_ID(), product.get_TrxName());
|
||||||
if (cost != null && cost.getCurrentCostPrice().signum() > 0)
|
if (cost != null && cost.getCurrentCostPrice().signum() > 0)
|
||||||
{
|
{
|
||||||
s_log.fine(product.getName() + ", Standard - " + cost);
|
if (s_log.isLoggable(Level.FINE)) s_log.fine(product.getName() + ", Standard - " + cost);
|
||||||
return cost.getCurrentCostPrice();
|
return cost.getCurrentCostPrice();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -334,7 +334,7 @@ public class MCost extends X_M_Cost
|
||||||
retValue = getLastPOPrice(product, M_ASI_ID, 0, as.getC_Currency_ID());
|
retValue = getLastPOPrice(product, M_ASI_ID, 0, as.getC_Currency_ID());
|
||||||
if (retValue != null && retValue.signum() > 0)
|
if (retValue != null && retValue.signum() > 0)
|
||||||
{
|
{
|
||||||
s_log.fine(product.getName() + ", LastPO = " + retValue);
|
if (s_log.isLoggable(Level.FINE)) s_log.fine(product.getName() + ", LastPO = " + retValue);
|
||||||
return retValue;
|
return retValue;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -346,7 +346,7 @@ public class MCost extends X_M_Cost
|
||||||
retValue = getLastInvoicePrice(product, M_ASI_ID, 0, as.getC_Currency_ID());
|
retValue = getLastInvoicePrice(product, M_ASI_ID, 0, as.getC_Currency_ID());
|
||||||
if (retValue != null && retValue.signum() != 0)
|
if (retValue != null && retValue.signum() != 0)
|
||||||
{
|
{
|
||||||
s_log.fine(product.getName() + ", LastInv = " + retValue);
|
if (s_log.isLoggable(Level.FINE)) s_log.fine(product.getName() + ", LastInv = " + retValue);
|
||||||
return retValue;
|
return retValue;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -362,7 +362,7 @@ public class MCost extends X_M_Cost
|
||||||
retValue = getLastInvoicePrice(product, M_ASI_ID, 0, as.getC_Currency_ID());
|
retValue = getLastInvoicePrice(product, M_ASI_ID, 0, as.getC_Currency_ID());
|
||||||
if (retValue != null && retValue.signum() > 0)
|
if (retValue != null && retValue.signum() > 0)
|
||||||
{
|
{
|
||||||
s_log.fine(product.getName() + ", LastInv = " + retValue);
|
if (s_log.isLoggable(Level.FINE)) s_log.fine(product.getName() + ", LastInv = " + retValue);
|
||||||
return retValue;
|
return retValue;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -374,7 +374,7 @@ public class MCost extends X_M_Cost
|
||||||
retValue = getLastPOPrice(product, M_ASI_ID, 0, as.getC_Currency_ID());
|
retValue = getLastPOPrice(product, M_ASI_ID, 0, as.getC_Currency_ID());
|
||||||
if (retValue != null && retValue.signum() > 0)
|
if (retValue != null && retValue.signum() > 0)
|
||||||
{
|
{
|
||||||
s_log.fine(product.getName() + ", LastPO = " + retValue);
|
if (s_log.isLoggable(Level.FINE)) s_log.fine(product.getName() + ", LastPO = " + retValue);
|
||||||
return retValue;
|
return retValue;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -402,7 +402,7 @@ public class MCost extends X_M_Cost
|
||||||
if (price != null && price.signum() != 0)
|
if (price != null && price.signum() != 0)
|
||||||
{
|
{
|
||||||
retValue = price;
|
retValue = price;
|
||||||
s_log.fine(product.getName() + ", Product_PO = " + retValue);
|
if (s_log.isLoggable(Level.FINE)) s_log.fine(product.getName() + ", Product_PO = " + retValue);
|
||||||
return retValue;
|
return retValue;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -415,7 +415,7 @@ public class MCost extends X_M_Cost
|
||||||
retValue = price;
|
retValue = price;
|
||||||
}
|
}
|
||||||
|
|
||||||
s_log.fine(product.getName() + " = " + retValue);
|
if (s_log.isLoggable(Level.FINE)) s_log.fine(product.getName() + " = " + retValue);
|
||||||
return retValue;
|
return retValue;
|
||||||
} // getSeedCosts
|
} // getSeedCosts
|
||||||
|
|
||||||
|
@ -502,7 +502,7 @@ public class MCost extends X_M_Cost
|
||||||
|
|
||||||
if (retValue != null)
|
if (retValue != null)
|
||||||
{
|
{
|
||||||
s_log.finer(product.getName() + " = " + retValue);
|
if (s_log.isLoggable(Level.FINER)) s_log.finer(product.getName() + " = " + retValue);
|
||||||
return retValue;
|
return retValue;
|
||||||
}
|
}
|
||||||
return null;
|
return null;
|
||||||
|
@ -565,7 +565,7 @@ public class MCost extends X_M_Cost
|
||||||
|
|
||||||
if (retValue != null)
|
if (retValue != null)
|
||||||
{
|
{
|
||||||
s_log.finer(product.getName() + " = " + retValue);
|
if (s_log.isLoggable(Level.FINER)) s_log.finer(product.getName() + " = " + retValue);
|
||||||
return retValue;
|
return retValue;
|
||||||
}
|
}
|
||||||
return null;
|
return null;
|
||||||
|
@ -617,7 +617,7 @@ public class MCost extends X_M_Cost
|
||||||
|
|
||||||
if (retValue != null)
|
if (retValue != null)
|
||||||
{
|
{
|
||||||
s_log.finer(product.getName() + " = " + retValue);
|
if (s_log.isLoggable(Level.FINER)) s_log.finer(product.getName() + " = " + retValue);
|
||||||
return retValue;
|
return retValue;
|
||||||
}
|
}
|
||||||
return null;
|
return null;
|
||||||
|
@ -659,7 +659,7 @@ public class MCost extends X_M_Cost
|
||||||
{
|
{
|
||||||
BigDecimal cost = getCurrentCost(product, 0, ass[i], 0,
|
BigDecimal cost = getCurrentCost(product, 0, ass[i], 0,
|
||||||
null, Env.ONE, 0, false, trxNameUsed); // create non-zero costs
|
null, Env.ONE, 0, false, trxNameUsed); // create non-zero costs
|
||||||
s_log.info(product.getName() + " = " + cost);
|
if (s_log.isLoggable(Level.INFO)) s_log.info(product.getName() + " = " + cost);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -864,7 +864,7 @@ public class MCost extends X_M_Cost
|
||||||
BigDecimal matchQty = rs.getBigDecimal(2);
|
BigDecimal matchQty = rs.getBigDecimal(2);
|
||||||
if (matchQty == null)
|
if (matchQty == null)
|
||||||
{
|
{
|
||||||
s_log.finer("Movement=" + movementQty + ", StockQty=" + newStockQty);
|
if (s_log.isLoggable(Level.FINER)) s_log.finer("Movement=" + movementQty + ", StockQty=" + newStockQty);
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
// Assumption: everything is matched
|
// Assumption: everything is matched
|
||||||
|
@ -884,7 +884,7 @@ public class MCost extends X_M_Cost
|
||||||
BigDecimal newAmt = averageCurrent.add(averageIncrease);
|
BigDecimal newAmt = averageCurrent.add(averageIncrease);
|
||||||
newAmt = newAmt.setScale(as.getCostingPrecision(), BigDecimal.ROUND_HALF_UP);
|
newAmt = newAmt.setScale(as.getCostingPrecision(), BigDecimal.ROUND_HALF_UP);
|
||||||
newAverageAmt = newAmt.divide(newStockQty, as.getCostingPrecision(), BigDecimal.ROUND_HALF_UP);
|
newAverageAmt = newAmt.divide(newStockQty, as.getCostingPrecision(), BigDecimal.ROUND_HALF_UP);
|
||||||
s_log.finer("Movement=" + movementQty + ", StockQty=" + newStockQty
|
if (s_log.isLoggable(Level.FINER)) s_log.finer("Movement=" + movementQty + ", StockQty=" + newStockQty
|
||||||
+ ", Match=" + matchQty + ", Cost=" + cost + ", NewAvg=" + newAverageAmt);
|
+ ", Match=" + matchQty + ", Cost=" + cost + ", NewAvg=" + newAverageAmt);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -900,7 +900,7 @@ public class MCost extends X_M_Cost
|
||||||
//
|
//
|
||||||
if (newAverageAmt != null && newAverageAmt.signum() != 0)
|
if (newAverageAmt != null && newAverageAmt.signum() != 0)
|
||||||
{
|
{
|
||||||
s_log.finer(product.getName() + " = " + newAverageAmt);
|
if (s_log.isLoggable(Level.FINER)) s_log.finer(product.getName() + " = " + newAverageAmt);
|
||||||
return newAverageAmt;
|
return newAverageAmt;
|
||||||
}
|
}
|
||||||
return null;
|
return null;
|
||||||
|
@ -958,7 +958,7 @@ public class MCost extends X_M_Cost
|
||||||
BigDecimal matchQty = rs.getBigDecimal(2);
|
BigDecimal matchQty = rs.getBigDecimal(2);
|
||||||
if (matchQty == null)
|
if (matchQty == null)
|
||||||
{
|
{
|
||||||
s_log.finer("Movement=" + movementQty + ", StockQty=" + newStockQty);
|
if (s_log.isLoggable(Level.FINER)) s_log.finer("Movement=" + movementQty + ", StockQty=" + newStockQty);
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
// Assumption: everything is matched
|
// Assumption: everything is matched
|
||||||
|
@ -980,7 +980,7 @@ public class MCost extends X_M_Cost
|
||||||
BigDecimal newAmt = averageCurrent.add(averageIncrease);
|
BigDecimal newAmt = averageCurrent.add(averageIncrease);
|
||||||
newAmt = newAmt.setScale(as.getCostingPrecision(), BigDecimal.ROUND_HALF_UP);
|
newAmt = newAmt.setScale(as.getCostingPrecision(), BigDecimal.ROUND_HALF_UP);
|
||||||
newAverageAmt = newAmt.divide(newStockQty, as.getCostingPrecision(), BigDecimal.ROUND_HALF_UP);
|
newAverageAmt = newAmt.divide(newStockQty, as.getCostingPrecision(), BigDecimal.ROUND_HALF_UP);
|
||||||
s_log.finer("Movement=" + movementQty + ", StockQty=" + newStockQty
|
if (s_log.isLoggable(Level.FINER)) s_log.finer("Movement=" + movementQty + ", StockQty=" + newStockQty
|
||||||
+ ", Match=" + matchQty + ", Cost=" + cost + ", NewAvg=" + newAverageAmt);
|
+ ", Match=" + matchQty + ", Cost=" + cost + ", NewAvg=" + newAverageAmt);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -996,7 +996,7 @@ public class MCost extends X_M_Cost
|
||||||
//
|
//
|
||||||
if (newAverageAmt != null && newAverageAmt.signum() != 0)
|
if (newAverageAmt != null && newAverageAmt.signum() != 0)
|
||||||
{
|
{
|
||||||
s_log.finer(product.getName() + " = " + newAverageAmt);
|
if (s_log.isLoggable(Level.FINER)) s_log.finer(product.getName() + " = " + newAverageAmt);
|
||||||
return newAverageAmt;
|
return newAverageAmt;
|
||||||
}
|
}
|
||||||
return null;
|
return null;
|
||||||
|
@ -1082,7 +1082,7 @@ public class MCost extends X_M_Cost
|
||||||
QtyCost pp = new QtyCost (movementQty, Env.ZERO);
|
QtyCost pp = new QtyCost (movementQty, Env.ZERO);
|
||||||
fifo.add(pp);
|
fifo.add(pp);
|
||||||
}
|
}
|
||||||
s_log.finer("Movement=" + movementQty + ", Size=" + fifo.size());
|
if (s_log.isLoggable(Level.FINER)) s_log.finer("Movement=" + movementQty + ", Size=" + fifo.size());
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
// Assumption: everything is matched
|
// Assumption: everything is matched
|
||||||
|
@ -1117,7 +1117,7 @@ public class MCost extends X_M_Cost
|
||||||
QtyCost pp = new QtyCost (movementQty, cost);
|
QtyCost pp = new QtyCost (movementQty, cost);
|
||||||
fifo.add(pp);
|
fifo.add(pp);
|
||||||
}
|
}
|
||||||
s_log.finer("Movement=" + movementQty + ", Size=" + fifo.size());
|
if (s_log.isLoggable(Level.FINER)) s_log.finer("Movement=" + movementQty + ", Size=" + fifo.size());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
catch (SQLException e)
|
catch (SQLException e)
|
||||||
|
@ -1135,7 +1135,7 @@ public class MCost extends X_M_Cost
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
QtyCost pp = (QtyCost)fifo.get(0);
|
QtyCost pp = (QtyCost)fifo.get(0);
|
||||||
s_log.finer(product.getName() + " = " + pp.Cost);
|
if (s_log.isLoggable(Level.FINER)) s_log.finer(product.getName() + " = " + pp.Cost);
|
||||||
return pp.Cost;
|
return pp.Cost;
|
||||||
} // calculateFiFo
|
} // calculateFiFo
|
||||||
|
|
||||||
|
@ -1220,7 +1220,7 @@ public class MCost extends X_M_Cost
|
||||||
QtyCost pp = new QtyCost (movementQty, Env.ZERO);
|
QtyCost pp = new QtyCost (movementQty, Env.ZERO);
|
||||||
lifo.add(pp);
|
lifo.add(pp);
|
||||||
}
|
}
|
||||||
s_log.finer("Movement=" + movementQty + ", Size=" + lifo.size());
|
if (s_log.isLoggable(Level.FINER)) s_log.finer("Movement=" + movementQty + ", Size=" + lifo.size());
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
// Assumption: everything is matched
|
// Assumption: everything is matched
|
||||||
|
@ -1236,7 +1236,7 @@ public class MCost extends X_M_Cost
|
||||||
//
|
//
|
||||||
QtyCost pp = new QtyCost (movementQty, cost);
|
QtyCost pp = new QtyCost (movementQty, cost);
|
||||||
lifo.add(pp);
|
lifo.add(pp);
|
||||||
s_log.finer("Movement=" + movementQty + ", Size=" + lifo.size());
|
if (s_log.isLoggable(Level.FINER)) s_log.finer("Movement=" + movementQty + ", Size=" + lifo.size());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
catch (SQLException e)
|
catch (SQLException e)
|
||||||
|
@ -1254,7 +1254,7 @@ public class MCost extends X_M_Cost
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
QtyCost pp = (QtyCost)lifo.get(lifo.size()-1);
|
QtyCost pp = (QtyCost)lifo.get(lifo.size()-1);
|
||||||
s_log.finer(product.getName() + " = " + pp.Cost);
|
if (s_log.isLoggable(Level.FINER)) s_log.finer(product.getName() + " = " + pp.Cost);
|
||||||
return pp.Cost;
|
return pp.Cost;
|
||||||
} // calculateLiFo
|
} // calculateLiFo
|
||||||
|
|
||||||
|
@ -1672,7 +1672,7 @@ public class MCost extends X_M_Cost
|
||||||
{
|
{
|
||||||
if (CurrentQty.signum() < 0)
|
if (CurrentQty.signum() < 0)
|
||||||
{
|
{
|
||||||
throw new AverageCostingNegativeQtyException("Product(ID)="+getM_Product_ID()+", Current Qty="+getCurrentQty()+", New Current Qty="+CurrentQty
|
throw new AverageCostingNegativeQtyException("Product="+getM_Product().getName()+", Current Qty="+getCurrentQty()+", New Current Qty="+CurrentQty
|
||||||
+", CostElement="+ce.getName()+", Schema="+getC_AcctSchema().getName());
|
+", CostElement="+ce.getName()+", Schema="+getC_AcctSchema().getName());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -19,6 +19,7 @@ package org.compiere.model;
|
||||||
import java.sql.ResultSet;
|
import java.sql.ResultSet;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import java.util.Properties;
|
import java.util.Properties;
|
||||||
|
import java.util.logging.Level;
|
||||||
|
|
||||||
import org.compiere.util.CCache;
|
import org.compiere.util.CCache;
|
||||||
import org.compiere.util.CLogger;
|
import org.compiere.util.CLogger;
|
||||||
|
@ -100,7 +101,7 @@ public class MCostElement extends X_M_CostElement
|
||||||
if (list.size() > 0)
|
if (list.size() > 0)
|
||||||
retValue = list.get(0);
|
retValue = list.get(0);
|
||||||
if (list.size() > 1)
|
if (list.size() > 1)
|
||||||
s_log.info("More then one Material Cost Element for CostingMethod=" + CostingMethod);
|
if (s_log.isLoggable(Level.INFO)) s_log.info("More then one Material Cost Element for CostingMethod=" + CostingMethod);
|
||||||
return retValue;
|
return retValue;
|
||||||
} // getMaterialCostElement
|
} // getMaterialCostElement
|
||||||
|
|
||||||
|
|
|
@ -184,7 +184,7 @@ public class MCostQueue extends X_M_CostQueue
|
||||||
queue.setCurrentQty(newQty);
|
queue.setCurrentQty(newQty);
|
||||||
if (queue.save())
|
if (queue.save())
|
||||||
{
|
{
|
||||||
s_log.fine("Qty=" + remainingQty
|
if (s_log.isLoggable(Level.FINE)) s_log.fine("Qty=" + remainingQty
|
||||||
+ "(!), ASI=" + queue.getM_AttributeSetInstance_ID()
|
+ "(!), ASI=" + queue.getM_AttributeSetInstance_ID()
|
||||||
+ " - " + oldQty + " -> " + newQty);
|
+ " - " + oldQty + " -> " + newQty);
|
||||||
return queue.getCurrentCostPrice();
|
return queue.getCurrentCostPrice();
|
||||||
|
@ -204,7 +204,7 @@ public class MCostQueue extends X_M_CostQueue
|
||||||
queue.setCurrentQty(newQty);
|
queue.setCurrentQty(newQty);
|
||||||
if (queue.save())
|
if (queue.save())
|
||||||
{
|
{
|
||||||
s_log.fine("Qty=" + reduction
|
if (s_log.isLoggable(Level.FINE)) s_log.fine("Qty=" + reduction
|
||||||
+ ", ASI=" + queue.getM_AttributeSetInstance_ID()
|
+ ", ASI=" + queue.getM_AttributeSetInstance_ID()
|
||||||
+ " - " + oldQty + " -> " + newQty);
|
+ " - " + oldQty + " -> " + newQty);
|
||||||
remainingQty = remainingQty.subtract(reduction);
|
remainingQty = remainingQty.subtract(reduction);
|
||||||
|
@ -219,7 +219,7 @@ public class MCostQueue extends X_M_CostQueue
|
||||||
}
|
}
|
||||||
} // for queue
|
} // for queue
|
||||||
|
|
||||||
s_log.fine("RemainingQty=" + remainingQty);
|
if (s_log.isLoggable(Level.FINE)) s_log.fine("RemainingQty=" + remainingQty);
|
||||||
return null;
|
return null;
|
||||||
} // adjustQty
|
} // adjustQty
|
||||||
|
|
||||||
|
@ -275,7 +275,7 @@ public class MCostQueue extends X_M_CostQueue
|
||||||
lastPrice = queue.getCurrentCostPrice();
|
lastPrice = queue.getCurrentCostPrice();
|
||||||
BigDecimal costBatch = lastPrice.multiply(reduction);
|
BigDecimal costBatch = lastPrice.multiply(reduction);
|
||||||
cost = cost.add(costBatch);
|
cost = cost.add(costBatch);
|
||||||
s_log.fine("ASI=" + queue.getM_AttributeSetInstance_ID()
|
if (s_log.isLoggable(Level.FINE)) s_log.fine("ASI=" + queue.getM_AttributeSetInstance_ID()
|
||||||
+ " - Cost=" + lastPrice + " * Qty=" + reduction + " = " + costBatch);
|
+ " - Cost=" + lastPrice + " * Qty=" + reduction + " = " + costBatch);
|
||||||
remainingQty = remainingQty.subtract(reduction);
|
remainingQty = remainingQty.subtract(reduction);
|
||||||
// Done
|
// Done
|
||||||
|
|
|
@ -142,7 +142,7 @@ public final class MCountry extends X_C_Country
|
||||||
}
|
}
|
||||||
if (s_default == null)
|
if (s_default == null)
|
||||||
s_default = usa;
|
s_default = usa;
|
||||||
s_log.fine("#" + s_countries.size()
|
if (s_log.isLoggable(Level.FINE)) s_log.fine("#" + s_countries.size()
|
||||||
+ " - Default=" + s_default);
|
+ " - Default=" + s_default);
|
||||||
} // loadAllCountries
|
} // loadAllCountries
|
||||||
|
|
||||||
|
|
|
@ -3,6 +3,7 @@ import java.math.BigDecimal;
|
||||||
import java.math.RoundingMode;
|
import java.math.RoundingMode;
|
||||||
import java.sql.ResultSet;
|
import java.sql.ResultSet;
|
||||||
import java.util.Properties;
|
import java.util.Properties;
|
||||||
|
import java.util.logging.Level;
|
||||||
import java.util.logging.Logger;
|
import java.util.logging.Logger;
|
||||||
|
|
||||||
import org.compiere.model.Query;
|
import org.compiere.model.Query;
|
||||||
|
@ -372,7 +373,7 @@ public class MDepreciation extends X_A_Depreciation
|
||||||
amt_sl = amt_r.divide(new BigDecimal(A_RemainingLife_Year), getPrecision(), RoundingMode.HALF_UP);
|
amt_sl = amt_r.divide(new BigDecimal(A_RemainingLife_Year), getPrecision(), RoundingMode.HALF_UP);
|
||||||
// logging
|
// logging
|
||||||
if (CLogMgt.isLevelFinest()) {
|
if (CLogMgt.isLevelFinest()) {
|
||||||
s_log.fine("amt_r=" + amt_r + ", amt_ad1=amt_r*coef_ad1=" + amt_ad1 + ", amt_sl=amt_r/A_RemainingLife_Year=" + amt_sl + ", A_Current_Year=" + A_Current_Year + ", A_RemainingLife_Year=" + A_RemainingLife_Year);
|
if (s_log.isLoggable(Level.FINE)) s_log.fine("amt_r=" + amt_r + ", amt_ad1=amt_r*coef_ad1=" + amt_ad1 + ", amt_sl=amt_r/A_RemainingLife_Year=" + amt_sl + ", A_Current_Year=" + A_Current_Year + ", A_RemainingLife_Year=" + A_RemainingLife_Year);
|
||||||
}
|
}
|
||||||
|
|
||||||
/** If the first year or if the value depreciation value depreciation degressive more linear ... */
|
/** If the first year or if the value depreciation value depreciation degressive more linear ... */
|
||||||
|
@ -382,7 +383,7 @@ public class MDepreciation extends X_A_Depreciation
|
||||||
else {
|
else {
|
||||||
amtPerYear = amt_sl;
|
amtPerYear = amt_sl;
|
||||||
is_SL = true;
|
is_SL = true;
|
||||||
s_log.fine("*** PASS IT ON linear amt_sl= " + amt_sl + " ***");
|
if (s_log.isLoggable(Level.FINE)) s_log.fine("*** PASS IT ON linear amt_sl= " + amt_sl + " ***");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
|
@ -391,9 +392,9 @@ public class MDepreciation extends X_A_Depreciation
|
||||||
}
|
}
|
||||||
|
|
||||||
amt_r = amt_r.subtract(amtPerYear);
|
amt_r = amt_r.subtract(amtPerYear);
|
||||||
if (CLogMgt.isLevelFinest()) s_log.fine("year=" + curr_year + ", amtPerYear=" + amtPerYear + ", amt_r=" + amt_r); //logging
|
if (s_log.isLoggable(Level.FINE)) s_log.fine("year=" + curr_year + ", amtPerYear=" + amtPerYear + ", amt_r=" + amt_r); //logging
|
||||||
}
|
}
|
||||||
if (CLogMgt.isLevelFinest()) s_log.fine("amt_r=" + amt_r + ", amtPerYear=" + amtPerYear); //logging
|
if (s_log.isLoggable(Level.FINE)) s_log.fine("amt_r=" + amt_r + ", amtPerYear=" + amtPerYear); //logging
|
||||||
|
|
||||||
/** Damping value for the current month */
|
/** Damping value for the current month */
|
||||||
BigDecimal assetExp = getPeriodExp(A_Current_Period, amtPerYear);
|
BigDecimal assetExp = getPeriodExp(A_Current_Period, amtPerYear);
|
||||||
|
|
|
@ -2,7 +2,6 @@ package org.compiere.model;
|
||||||
import java.math.BigDecimal;
|
import java.math.BigDecimal;
|
||||||
import java.sql.CallableStatement;
|
import java.sql.CallableStatement;
|
||||||
import java.sql.ResultSet;
|
import java.sql.ResultSet;
|
||||||
import java.sql.SQLException;
|
|
||||||
import java.util.Properties;
|
import java.util.Properties;
|
||||||
import java.util.logging.Level;
|
import java.util.logging.Level;
|
||||||
|
|
||||||
|
|
|
@ -7,6 +7,7 @@ import java.util.ArrayList;
|
||||||
import java.util.Collection;
|
import java.util.Collection;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import java.util.Properties;
|
import java.util.Properties;
|
||||||
|
import java.util.logging.Level;
|
||||||
|
|
||||||
import org.compiere.model.MDocType;
|
import org.compiere.model.MDocType;
|
||||||
import org.compiere.model.MPeriod;
|
import org.compiere.model.MPeriod;
|
||||||
|
@ -94,7 +95,7 @@ public class MDepreciationExp extends X_A_Depreciation_Exp
|
||||||
//
|
//
|
||||||
depexp.updateFrom(assetwk);
|
depexp.updateFrom(assetwk);
|
||||||
//
|
//
|
||||||
s_log.fine("depexp=" + depexp);
|
if (s_log.isLoggable(Level.FINE)) s_log.fine("depexp=" + depexp);
|
||||||
return depexp;
|
return depexp;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -21,6 +21,8 @@ import java.util.ArrayList;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import java.util.Properties;
|
import java.util.Properties;
|
||||||
import java.util.StringTokenizer;
|
import java.util.StringTokenizer;
|
||||||
|
import java.util.logging.Level;
|
||||||
|
|
||||||
import static org.compiere.model.SystemIDs.*;
|
import static org.compiere.model.SystemIDs.*;
|
||||||
|
|
||||||
import org.compiere.util.CLogger;
|
import org.compiere.util.CLogger;
|
||||||
|
@ -44,7 +46,7 @@ public class MEntityType extends X_AD_EntityType
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
private static final long serialVersionUID = 8906219523978497906L;
|
private static final long serialVersionUID = 4670009709141738924L;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Get Entity Types
|
* Get Entity Types
|
||||||
|
@ -61,7 +63,7 @@ public class MEntityType extends X_AD_EntityType
|
||||||
.list();
|
.list();
|
||||||
s_entityTypes = new MEntityType[list.size()];
|
s_entityTypes = new MEntityType[list.size()];
|
||||||
list.toArray(s_entityTypes);
|
list.toArray(s_entityTypes);
|
||||||
s_log.finer("# " + s_entityTypes.length);
|
if (s_log.isLoggable(Level.FINER)) s_log.finer("# " + s_entityTypes.length);
|
||||||
return s_entityTypes;
|
return s_entityTypes;
|
||||||
} // getEntityTypes
|
} // getEntityTypes
|
||||||
|
|
||||||
|
@ -99,7 +101,7 @@ public class MEntityType extends X_AD_EntityType
|
||||||
list.add(s);
|
list.add(s);
|
||||||
retValue[i] = s;
|
retValue[i] = s;
|
||||||
}
|
}
|
||||||
s_log.finer(list.toString());
|
if (s_log.isLoggable(Level.FINER)) s_log.finer(list.toString());
|
||||||
return retValue;
|
return retValue;
|
||||||
} // getEntityTypeStrings
|
} // getEntityTypeStrings
|
||||||
|
|
||||||
|
@ -130,7 +132,7 @@ public class MEntityType extends X_AD_EntityType
|
||||||
}
|
}
|
||||||
String[] retValue = new String[list.size()];
|
String[] retValue = new String[list.size()];
|
||||||
list.toArray(retValue);
|
list.toArray(retValue);
|
||||||
s_log.finer(list.toString());
|
if (s_log.isLoggable(Level.FINER)) s_log.finer(list.toString());
|
||||||
return retValue;
|
return retValue;
|
||||||
} // getClathpaths
|
} // getClathpaths
|
||||||
|
|
||||||
|
@ -162,7 +164,7 @@ public class MEntityType extends X_AD_EntityType
|
||||||
}
|
}
|
||||||
String[] retValue = new String[list.size()];
|
String[] retValue = new String[list.size()];
|
||||||
list.toArray(retValue);
|
list.toArray(retValue);
|
||||||
s_log.finer(list.toString());
|
if (s_log.isLoggable(Level.FINER)) s_log.finer(list.toString());
|
||||||
return retValue;
|
return retValue;
|
||||||
} // getModelPackages
|
} // getModelPackages
|
||||||
|
|
||||||
|
|
|
@ -75,7 +75,7 @@ public class MFactAcct extends X_Fact_Acct
|
||||||
{
|
{
|
||||||
final String sql = "DELETE Fact_Acct WHERE AD_Table_ID=? AND Record_ID=?";
|
final String sql = "DELETE Fact_Acct WHERE AD_Table_ID=? AND Record_ID=?";
|
||||||
int no = DB.executeUpdateEx(sql, new Object[]{AD_Table_ID, Record_ID}, trxName);
|
int no = DB.executeUpdateEx(sql, new Object[]{AD_Table_ID, Record_ID}, trxName);
|
||||||
s_log.fine("delete - AD_Table_ID=" + AD_Table_ID + ", Record_ID=" + Record_ID + " - #" + no);
|
if (s_log.isLoggable(Level.FINE)) s_log.fine("delete - AD_Table_ID=" + AD_Table_ID + ", Record_ID=" + Record_ID + " - #" + no);
|
||||||
return no;
|
return no;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -70,7 +70,7 @@ public class MInOutConfirm extends X_M_InOutConfirm implements DocAction
|
||||||
MInOutConfirm confirm = confirmations[i];
|
MInOutConfirm confirm = confirmations[i];
|
||||||
if (confirm.getConfirmType().equals(confirmType))
|
if (confirm.getConfirmType().equals(confirmType))
|
||||||
{
|
{
|
||||||
s_log.info("create - existing: " + confirm);
|
if (s_log.isLoggable(Level.INFO)) s_log.info("create - existing: " + confirm);
|
||||||
return confirm;
|
return confirm;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -86,7 +86,7 @@ public class MInOutConfirm extends X_M_InOutConfirm implements DocAction
|
||||||
cLine.setInOutLine(sLine);
|
cLine.setInOutLine(sLine);
|
||||||
cLine.saveEx();
|
cLine.saveEx();
|
||||||
}
|
}
|
||||||
s_log.info("New: " + confirm);
|
if (s_log.isLoggable(Level.INFO)) s_log.info("New: " + confirm);
|
||||||
return confirm;
|
return confirm;
|
||||||
} // MInOutConfirm
|
} // MInOutConfirm
|
||||||
|
|
||||||
|
|
|
@ -21,6 +21,7 @@ import java.sql.PreparedStatement;
|
||||||
import java.sql.ResultSet;
|
import java.sql.ResultSet;
|
||||||
import java.sql.SQLException;
|
import java.sql.SQLException;
|
||||||
import java.util.Properties;
|
import java.util.Properties;
|
||||||
|
import java.util.logging.Level;
|
||||||
|
|
||||||
import org.adempiere.exceptions.DBException;
|
import org.adempiere.exceptions.DBException;
|
||||||
import org.compiere.util.CLogger;
|
import org.compiere.util.CLogger;
|
||||||
|
@ -80,7 +81,7 @@ public class MInvoiceTax extends X_C_InvoiceTax
|
||||||
{
|
{
|
||||||
retValue.set_TrxName(trxName);
|
retValue.set_TrxName(trxName);
|
||||||
retValue.setPrecision(precision);
|
retValue.setPrecision(precision);
|
||||||
s_log.fine("(old=" + oldTax + ") " + retValue);
|
if (s_log.isLoggable(Level.FINE)) s_log.fine("(old=" + oldTax + ") " + retValue);
|
||||||
return retValue;
|
return retValue;
|
||||||
}
|
}
|
||||||
// If the old tax was required and there is no MInvoiceTax for that
|
// If the old tax was required and there is no MInvoiceTax for that
|
||||||
|
@ -98,7 +99,7 @@ public class MInvoiceTax extends X_C_InvoiceTax
|
||||||
retValue.setC_Tax_ID(line.getC_Tax_ID());
|
retValue.setC_Tax_ID(line.getC_Tax_ID());
|
||||||
retValue.setPrecision(precision);
|
retValue.setPrecision(precision);
|
||||||
retValue.setIsTaxIncluded(line.isTaxIncluded());
|
retValue.setIsTaxIncluded(line.isTaxIncluded());
|
||||||
s_log.fine("(new) " + retValue);
|
if (s_log.isLoggable(Level.FINE)) s_log.fine("(new) " + retValue);
|
||||||
return retValue;
|
return retValue;
|
||||||
} // get
|
} // get
|
||||||
|
|
||||||
|
|
|
@ -19,6 +19,7 @@ package org.compiere.model;
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
import java.util.HashMap;
|
import java.util.HashMap;
|
||||||
import java.util.Iterator;
|
import java.util.Iterator;
|
||||||
|
import java.util.logging.Level;
|
||||||
|
|
||||||
import org.compiere.util.CCache;
|
import org.compiere.util.CCache;
|
||||||
import org.compiere.util.CLogger;
|
import org.compiere.util.CLogger;
|
||||||
|
@ -115,7 +116,7 @@ public class MLookupCache
|
||||||
lookupTarget.put(cacheKey, cacheData);
|
lookupTarget.put(cacheKey, cacheData);
|
||||||
}
|
}
|
||||||
|
|
||||||
s_log.fine("#" + lookupTarget.size());
|
if (s_log.isLoggable(Level.FINE)) s_log.fine("#" + lookupTarget.size());
|
||||||
return true;
|
return true;
|
||||||
} // loadFromCache
|
} // loadFromCache
|
||||||
|
|
||||||
|
@ -141,7 +142,7 @@ public class MLookupCache
|
||||||
for (int i = 0; i < toDelete.size(); i++)
|
for (int i = 0; i < toDelete.size(); i++)
|
||||||
s_loadedLookups.remove(toDelete.get(i));
|
s_loadedLookups.remove(toDelete.get(i));
|
||||||
int endNo = s_loadedLookups.size();
|
int endNo = s_loadedLookups.size();
|
||||||
s_log.fine("WindowNo=" + WindowNo
|
if (s_log.isLoggable(Level.FINE)) s_log.fine("WindowNo=" + WindowNo
|
||||||
+ " - " + startNo + " -> " + endNo);
|
+ " - " + startNo + " -> " + endNo);
|
||||||
} // cacheReset
|
} // cacheReset
|
||||||
|
|
||||||
|
|
|
@ -217,8 +217,7 @@ public class MLookupFactory
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
info.Query = newSQL;
|
info.Query = newSQL;
|
||||||
if (s_log.isLoggable(Level.FINE))
|
if (s_log.isLoggable(Level.FINE)) s_log.fine("getLookupInfo, newSQL ="+newSQL); //jz
|
||||||
s_log.fine("getLookupInfo, newSQL ="+newSQL); //jz
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// Direct Query - NO Validation/Security
|
// Direct Query - NO Validation/Security
|
||||||
|
@ -231,8 +230,7 @@ public class MLookupFactory
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
info.QueryDirect = newSQL;
|
info.QueryDirect = newSQL;
|
||||||
if (s_log.isLoggable(Level.FINE))
|
if (s_log.isLoggable(Level.FINE)) s_log.fine("getLookupInfo, newSQL ="+newSQL); //jz
|
||||||
s_log.fine("getLookupInfo, newSQL ="+newSQL); //jz
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// Validation
|
// Validation
|
||||||
|
@ -367,8 +365,7 @@ public class MLookupFactory
|
||||||
MLookupInfo retValue = (MLookupInfo)s_cacheRefTable.get(key.toString());
|
MLookupInfo retValue = (MLookupInfo)s_cacheRefTable.get(key.toString());
|
||||||
if (retValue != null)
|
if (retValue != null)
|
||||||
{
|
{
|
||||||
if (s_log.isLoggable(Level.FINEST))
|
if (s_log.isLoggable(Level.FINEST)) s_log.finest("Cache: " + retValue);
|
||||||
s_log.finest("Cache: " + retValue);
|
|
||||||
return retValue.cloneIt();
|
return retValue.cloneIt();
|
||||||
}
|
}
|
||||||
//
|
//
|
||||||
|
@ -556,8 +553,7 @@ public class MLookupFactory
|
||||||
else
|
else
|
||||||
realSQL.append(" ORDER BY 3");
|
realSQL.append(" ORDER BY 3");
|
||||||
|
|
||||||
if (s_log.isLoggable(Level.FINEST))
|
if (s_log.isLoggable(Level.FINEST)) s_log.finest("AD_Reference_Value_ID=" + AD_Reference_Value_ID + " - " + realSQL);
|
||||||
s_log.finest("AD_Reference_Value_ID=" + AD_Reference_Value_ID + " - " + realSQL);
|
|
||||||
if (overrideZoomWindow > 0)
|
if (overrideZoomWindow > 0)
|
||||||
{
|
{
|
||||||
ZoomWindow = overrideZoomWindow;
|
ZoomWindow = overrideZoomWindow;
|
||||||
|
@ -762,8 +758,7 @@ public class MLookupFactory
|
||||||
realSQL.append(" ORDER BY 3");
|
realSQL.append(" ORDER BY 3");
|
||||||
MQuery zoomQuery = null; // corrected in VLookup
|
MQuery zoomQuery = null; // corrected in VLookup
|
||||||
|
|
||||||
if (s_log.isLoggable(Level.FINE))
|
if (s_log.isLoggable(Level.FINE)) s_log.fine("ColumnName=" + ColumnName + " - " + realSQL);
|
||||||
s_log.fine("ColumnName=" + ColumnName + " - " + realSQL);
|
|
||||||
StringBuilder msginf = new StringBuilder().append(TableName).append(".").append(KeyColumn);
|
StringBuilder msginf = new StringBuilder().append(TableName).append(".").append(KeyColumn);
|
||||||
MLookupInfo lInfo = new MLookupInfo(realSQL.toString(), TableName,
|
MLookupInfo lInfo = new MLookupInfo(realSQL.toString(), TableName,
|
||||||
msginf.toString(), ZoomWindow, ZoomWindowPO, zoomQuery);
|
msginf.toString(), ZoomWindow, ZoomWindowPO, zoomQuery);
|
||||||
|
|
|
@ -1111,7 +1111,7 @@ public class MMatchPO extends X_M_MatchPO
|
||||||
if (errors == 0 && success == 0)
|
if (errors == 0 && success == 0)
|
||||||
;
|
;
|
||||||
else
|
else
|
||||||
s_log.info("Success #" + success + " - Error #" + errors);
|
if (s_log.isLoggable(Level.INFO)) s_log.info("Success #" + success + " - Error #" + errors);
|
||||||
} // consolidate
|
} // consolidate
|
||||||
|
|
||||||
//AZ Goodwill
|
//AZ Goodwill
|
||||||
|
|
|
@ -108,7 +108,7 @@ public class MOrderLine extends X_C_OrderLine
|
||||||
if (retValue == null)
|
if (retValue == null)
|
||||||
s_log.fine("-");
|
s_log.fine("-");
|
||||||
else
|
else
|
||||||
s_log.fine(retValue.toString());
|
if (s_log.isLoggable(Level.FINE)) s_log.fine(retValue.toString());
|
||||||
return retValue;
|
return retValue;
|
||||||
} // getNotReserved
|
} // getNotReserved
|
||||||
|
|
||||||
|
|
|
@ -101,7 +101,7 @@ public class MOrderTax extends X_C_OrderTax
|
||||||
{
|
{
|
||||||
retValue.setPrecision(precision);
|
retValue.setPrecision(precision);
|
||||||
retValue.set_TrxName(trxName);
|
retValue.set_TrxName(trxName);
|
||||||
s_log.fine("(old=" + oldTax + ") " + retValue);
|
if (s_log.isLoggable(Level.FINE)) s_log.fine("(old=" + oldTax + ") " + retValue);
|
||||||
return retValue;
|
return retValue;
|
||||||
}
|
}
|
||||||
// If the old tax was required and there is no MOrderTax for that
|
// If the old tax was required and there is no MOrderTax for that
|
||||||
|
@ -119,7 +119,7 @@ public class MOrderTax extends X_C_OrderTax
|
||||||
retValue.setC_Tax_ID(line.getC_Tax_ID());
|
retValue.setC_Tax_ID(line.getC_Tax_ID());
|
||||||
retValue.setPrecision(precision);
|
retValue.setPrecision(precision);
|
||||||
retValue.setIsTaxIncluded(line.isTaxIncluded());
|
retValue.setIsTaxIncluded(line.isTaxIncluded());
|
||||||
s_log.fine("(new) " + retValue);
|
if (s_log.isLoggable(Level.FINE)) s_log.fine("(new) " + retValue);
|
||||||
return retValue;
|
return retValue;
|
||||||
} // get
|
} // get
|
||||||
|
|
||||||
|
|
|
@ -202,7 +202,7 @@ public final class MPaySelectionCheck extends X_C_PaySelectionCheck
|
||||||
static public MPaySelectionCheck[] get (int C_PaySelection_ID,
|
static public MPaySelectionCheck[] get (int C_PaySelection_ID,
|
||||||
String PaymentRule, int startDocumentNo, String trxName)
|
String PaymentRule, int startDocumentNo, String trxName)
|
||||||
{
|
{
|
||||||
s_log.fine("C_PaySelection_ID=" + C_PaySelection_ID
|
if (s_log.isLoggable(Level.FINE)) s_log.fine("C_PaySelection_ID=" + C_PaySelection_ID
|
||||||
+ ", PaymentRule=" + PaymentRule + ", startDocumentNo=" + startDocumentNo);
|
+ ", PaymentRule=" + PaymentRule + ", startDocumentNo=" + startDocumentNo);
|
||||||
ArrayList<MPaySelectionCheck> list = new ArrayList<MPaySelectionCheck>();
|
ArrayList<MPaySelectionCheck> list = new ArrayList<MPaySelectionCheck>();
|
||||||
|
|
||||||
|
@ -300,11 +300,11 @@ public final class MPaySelectionCheck extends X_C_PaySelectionCheck
|
||||||
}
|
}
|
||||||
// Link to Invoice
|
// Link to Invoice
|
||||||
MPaySelectionLine[] psls = check.getPaySelectionLines(false);
|
MPaySelectionLine[] psls = check.getPaySelectionLines(false);
|
||||||
s_log.fine("confirmPrint - " + check + " (#SelectionLines=" + psls.length + ")");
|
if (s_log.isLoggable(Level.FINE)) s_log.fine("confirmPrint - " + check + " (#SelectionLines=" + psls.length + ")");
|
||||||
if (check.getQty() == 1 && psls != null && psls.length == 1)
|
if (check.getQty() == 1 && psls != null && psls.length == 1)
|
||||||
{
|
{
|
||||||
MPaySelectionLine psl = psls[0];
|
MPaySelectionLine psl = psls[0];
|
||||||
s_log.fine("Map to Invoice " + psl);
|
if (s_log.isLoggable(Level.FINE)) s_log.fine("Map to Invoice " + psl);
|
||||||
//
|
//
|
||||||
payment.setC_Invoice_ID (psl.getC_Invoice_ID());
|
payment.setC_Invoice_ID (psl.getC_Invoice_ID());
|
||||||
payment.setDiscountAmt (psl.getDiscountAmt());
|
payment.setDiscountAmt (psl.getDiscountAmt());
|
||||||
|
@ -352,7 +352,7 @@ public final class MPaySelectionCheck extends X_C_PaySelectionCheck
|
||||||
s_log.log(Level.SEVERE, "Check not saved: " + check);
|
s_log.log(Level.SEVERE, "Check not saved: " + check);
|
||||||
} // all checks
|
} // all checks
|
||||||
|
|
||||||
s_log.fine("Last Document No = " + lastDocumentNo);
|
if (s_log.isLoggable(Level.FINE)) s_log.fine("Last Document No = " + lastDocumentNo);
|
||||||
return lastDocumentNo;
|
return lastDocumentNo;
|
||||||
} // confirmPrint
|
} // confirmPrint
|
||||||
|
|
||||||
|
|
|
@ -18,6 +18,7 @@ package org.compiere.model;
|
||||||
|
|
||||||
import java.util.Calendar;
|
import java.util.Calendar;
|
||||||
import java.util.StringTokenizer;
|
import java.util.StringTokenizer;
|
||||||
|
import java.util.logging.Level;
|
||||||
|
|
||||||
import org.compiere.util.CLogger;
|
import org.compiere.util.CLogger;
|
||||||
|
|
||||||
|
@ -185,7 +186,7 @@ public class MPaymentValidate
|
||||||
if (sum % 10 == 0)
|
if (sum % 10 == 0)
|
||||||
return "";
|
return "";
|
||||||
|
|
||||||
s_log.fine("validateCreditCardNumber - " + creditCardNumber + " -> "
|
if (s_log.isLoggable(Level.FINE)) s_log.fine("validateCreditCardNumber - " + creditCardNumber + " -> "
|
||||||
+ ccNumber + ", Luhn=" + sum);
|
+ ccNumber + ", Luhn=" + sum);
|
||||||
return "CreditCardNumberError";
|
return "CreditCardNumberError";
|
||||||
} // validateCreditCardNumber
|
} // validateCreditCardNumber
|
||||||
|
@ -263,7 +264,7 @@ public class MPaymentValidate
|
||||||
}
|
}
|
||||||
if (!ccLengthOK)
|
if (!ccLengthOK)
|
||||||
{
|
{
|
||||||
s_log.fine("validateCreditCardNumber Length="
|
if (s_log.isLoggable(Level.FINE)) s_log.fine("validateCreditCardNumber Length="
|
||||||
+ ccLength + " <> " + ccLengthList);
|
+ ccLength + " <> " + ccLengthList);
|
||||||
return "CreditCardNumberError";
|
return "CreditCardNumberError";
|
||||||
}
|
}
|
||||||
|
@ -279,7 +280,7 @@ public class MPaymentValidate
|
||||||
ccIdentified = true;
|
ccIdentified = true;
|
||||||
}
|
}
|
||||||
if (!ccIdentified)
|
if (!ccIdentified)
|
||||||
s_log.fine("validateCreditCardNumber Type="
|
if (s_log.isLoggable(Level.FINE)) s_log.fine("validateCreditCardNumber Type="
|
||||||
+ creditCardType + " <> " + ccStartList);
|
+ creditCardType + " <> " + ccStartList);
|
||||||
|
|
||||||
//
|
//
|
||||||
|
@ -311,9 +312,9 @@ public class MPaymentValidate
|
||||||
}
|
}
|
||||||
catch (NumberFormatException ex)
|
catch (NumberFormatException ex)
|
||||||
{
|
{
|
||||||
s_log.fine("validateCreditCardVV - " + ex);
|
if (s_log.isLoggable(Level.FINE)) s_log.fine("validateCreditCardVV - " + ex);
|
||||||
}
|
}
|
||||||
s_log.fine("validateCreditCardVV - length=" + length);
|
if (s_log.isLoggable(Level.FINE)) s_log.fine("validateCreditCardVV - length=" + length);
|
||||||
return "CreditCardVVError";
|
return "CreditCardVVError";
|
||||||
} // validateCreditCardVV
|
} // validateCreditCardVV
|
||||||
|
|
||||||
|
@ -344,10 +345,10 @@ public class MPaymentValidate
|
||||||
}
|
}
|
||||||
catch (NumberFormatException ex)
|
catch (NumberFormatException ex)
|
||||||
{
|
{
|
||||||
s_log.fine("validateCreditCardVV - " + ex);
|
if (s_log.isLoggable(Level.FINE)) s_log.fine("validateCreditCardVV - " + ex);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
s_log.fine("validateCreditCardVV(4) CC=" + creditCardType + ", length=" + length);
|
if (s_log.isLoggable(Level.FINE)) s_log.fine("validateCreditCardVV(4) CC=" + creditCardType + ", length=" + length);
|
||||||
return "CreditCardVVError";
|
return "CreditCardVVError";
|
||||||
}
|
}
|
||||||
// Visa & MasterCard - 3 digits
|
// Visa & MasterCard - 3 digits
|
||||||
|
@ -363,10 +364,10 @@ public class MPaymentValidate
|
||||||
}
|
}
|
||||||
catch (NumberFormatException ex)
|
catch (NumberFormatException ex)
|
||||||
{
|
{
|
||||||
s_log.fine("validateCreditCardVV - " + ex);
|
if (s_log.isLoggable(Level.FINE)) s_log.fine("validateCreditCardVV - " + ex);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
s_log.fine("validateCreditCardVV(3) CC=" + creditCardType + ", length=" + length);
|
if (s_log.isLoggable(Level.FINE)) s_log.fine("validateCreditCardVV(3) CC=" + creditCardType + ", length=" + length);
|
||||||
return "CreditCardVVError";
|
return "CreditCardVVError";
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -179,7 +179,7 @@ public class MPeriod extends X_C_Period
|
||||||
rs = null; pstmt = null;
|
rs = null; pstmt = null;
|
||||||
}
|
}
|
||||||
if (retValue == null)
|
if (retValue == null)
|
||||||
s_log.info("No Standard Period for " + DateAcct
|
if (s_log.isLoggable(Level.INFO)) s_log.info("No Standard Period for " + DateAcct
|
||||||
+ " (AD_Client_ID=" + AD_Client_ID + ")");
|
+ " (AD_Client_ID=" + AD_Client_ID + ")");
|
||||||
return retValue;
|
return retValue;
|
||||||
}
|
}
|
||||||
|
|
|
@ -101,7 +101,7 @@ public class MProductCategory extends X_M_Product_Category
|
||||||
// TODO: LRU logic
|
// TODO: LRU logic
|
||||||
s_products.put(product, category);
|
s_products.put(product, category);
|
||||||
//
|
//
|
||||||
s_log.fine("M_Product_ID=" + M_Product_ID + "(" + category
|
if (s_log.isLoggable(Level.FINE)) s_log.fine("M_Product_ID=" + M_Product_ID + "(" + category
|
||||||
+ ") in M_Product_Category_ID=" + M_Product_Category_ID
|
+ ") in M_Product_Category_ID=" + M_Product_Category_ID
|
||||||
+ " - " + (category.intValue() == M_Product_Category_ID));
|
+ " - " + (category.intValue() == M_Product_Category_ID));
|
||||||
return category.intValue() == M_Product_Category_ID;
|
return category.intValue() == M_Product_Category_ID;
|
||||||
|
|
|
@ -98,7 +98,7 @@ public class MProductDownload extends X_M_ProductDownload
|
||||||
rs = null;
|
rs = null;
|
||||||
pstmt = null;
|
pstmt = null;
|
||||||
}
|
}
|
||||||
s_log.info("#" + count);
|
if (s_log.isLoggable(Level.INFO)) s_log.info("#" + count);
|
||||||
} // migrateDownloads
|
} // migrateDownloads
|
||||||
|
|
||||||
/** Logger */
|
/** Logger */
|
||||||
|
|
|
@ -54,7 +54,7 @@ public class MQuery implements Serializable
|
||||||
*/
|
*/
|
||||||
static public MQuery get (Properties ctx, int AD_PInstance_ID, String TableName)
|
static public MQuery get (Properties ctx, int AD_PInstance_ID, String TableName)
|
||||||
{
|
{
|
||||||
s_log.info("AD_PInstance_ID=" + AD_PInstance_ID + ", TableName=" + TableName);
|
if (s_log.isLoggable(Level.INFO)) s_log.info("AD_PInstance_ID=" + AD_PInstance_ID + ", TableName=" + TableName);
|
||||||
MQuery query = new MQuery(TableName);
|
MQuery query = new MQuery(TableName);
|
||||||
// Temporary Tables - add qualifier (not displayed)
|
// Temporary Tables - add qualifier (not displayed)
|
||||||
boolean isTemporaryTable = false;
|
boolean isTemporaryTable = false;
|
||||||
|
@ -139,7 +139,7 @@ public class MQuery implements Serializable
|
||||||
String Name = rs.getString(10);
|
String Name = rs.getString(10);
|
||||||
boolean isRange = "Y".equals(rs.getString(11));
|
boolean isRange = "Y".equals(rs.getString(11));
|
||||||
//
|
//
|
||||||
s_log.fine(ParameterName + " S=" + P_String + "-" + P_String_To
|
if (s_log.isLoggable(Level.FINE)) s_log.fine(ParameterName + " S=" + P_String + "-" + P_String_To
|
||||||
+ ", N=" + P_Number + "-" + P_Number_To + ", D=" + P_Date + "-" + P_Date_To
|
+ ", N=" + P_Number + "-" + P_Number_To + ", D=" + P_Date + "-" + P_Date_To
|
||||||
+ "; Name=" + Name + ", Info=" + Info + "-" + Info_To + ", Range=" + isRange);
|
+ "; Name=" + Name + ", Info=" + Info + "-" + Info_To + ", Range=" + isRange);
|
||||||
//
|
//
|
||||||
|
@ -147,7 +147,7 @@ public class MQuery implements Serializable
|
||||||
// This condition applies only to temporary tables - teo_sarca [ 2860022 ]
|
// This condition applies only to temporary tables - teo_sarca [ 2860022 ]
|
||||||
if (isTemporaryTable && !isFinancialReport && table != null && table.getColumn(ParameterName) == null)
|
if (isTemporaryTable && !isFinancialReport && table != null && table.getColumn(ParameterName) == null)
|
||||||
{
|
{
|
||||||
s_log.info("Skip parameter "+ParameterName+" because there is no column in table "+TableName);
|
if (s_log.isLoggable(Level.INFO)) s_log.info("Skip parameter "+ParameterName+" because there is no column in table "+TableName);
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -222,7 +222,7 @@ public class MQuery implements Serializable
|
||||||
DB.close(rs, pstmt);
|
DB.close(rs, pstmt);
|
||||||
rs = null; pstmt = null;
|
rs = null; pstmt = null;
|
||||||
}
|
}
|
||||||
s_log.info(query.toString());
|
if (s_log.isLoggable(Level.INFO)) s_log.info(query.toString());
|
||||||
return query;
|
return query;
|
||||||
} // get
|
} // get
|
||||||
|
|
||||||
|
|
|
@ -96,7 +96,7 @@ public class MRMATax extends X_M_RMATax
|
||||||
{
|
{
|
||||||
retValue.setPrecision(precision);
|
retValue.setPrecision(precision);
|
||||||
retValue.set_TrxName(trxName);
|
retValue.set_TrxName(trxName);
|
||||||
s_log.fine("(old=" + oldTax + ") " + retValue);
|
if (s_log.isLoggable(Level.FINE)) s_log.fine("(old=" + oldTax + ") " + retValue);
|
||||||
return retValue;
|
return retValue;
|
||||||
}
|
}
|
||||||
// If the old tax was required and there is no MOrderTax for that
|
// If the old tax was required and there is no MOrderTax for that
|
||||||
|
@ -114,7 +114,7 @@ public class MRMATax extends X_M_RMATax
|
||||||
retValue.setC_Tax_ID(line.getC_Tax_ID());
|
retValue.setC_Tax_ID(line.getC_Tax_ID());
|
||||||
retValue.setPrecision(precision);
|
retValue.setPrecision(precision);
|
||||||
retValue.setIsTaxIncluded(line.getParent().isTaxIncluded());
|
retValue.setIsTaxIncluded(line.getParent().isTaxIncluded());
|
||||||
s_log.fine("(new) " + retValue);
|
if (s_log.isLoggable(Level.FINE)) s_log.fine("(new) " + retValue);
|
||||||
return retValue;
|
return retValue;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -170,7 +170,7 @@ public class MRefList extends X_AD_Ref_List
|
||||||
if (retValue == null)
|
if (retValue == null)
|
||||||
{
|
{
|
||||||
retValue = "";
|
retValue = "";
|
||||||
s_log.info("getListDescription - Not found " + key);
|
if (s_log.isLoggable(Level.INFO)) s_log.info("getListDescription - Not found " + key);
|
||||||
}
|
}
|
||||||
s_cache.put(key, retValue);
|
s_cache.put(key, retValue);
|
||||||
//
|
//
|
||||||
|
|
|
@ -81,7 +81,7 @@ public final class MRegion extends X_C_Region
|
||||||
rs = null;
|
rs = null;
|
||||||
stmt = null;
|
stmt = null;
|
||||||
}
|
}
|
||||||
s_log.fine(s_regions.size() + " - default=" + s_default);
|
if (s_log.isLoggable(Level.FINE)) s_log.fine(s_regions.size() + " - default=" + s_default);
|
||||||
} // loadAllRegions
|
} // loadAllRegions
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
@ -119,7 +119,7 @@ public final class MRole extends X_AD_Role
|
||||||
*/
|
*/
|
||||||
public static MRole get (Properties ctx, int AD_Role_ID, int AD_User_ID, boolean reload)
|
public static MRole get (Properties ctx, int AD_Role_ID, int AD_User_ID, boolean reload)
|
||||||
{
|
{
|
||||||
s_log.info("AD_Role_ID=" + AD_Role_ID + ", AD_User_ID=" + AD_User_ID + ", reload=" + reload);
|
if (s_log.isLoggable(Level.INFO)) s_log.info("AD_Role_ID=" + AD_Role_ID + ", AD_User_ID=" + AD_User_ID + ", reload=" + reload);
|
||||||
String key = AD_Role_ID + "_" + AD_User_ID;
|
String key = AD_Role_ID + "_" + AD_User_ID;
|
||||||
MRole role = (MRole)s_roles.get (key);
|
MRole role = (MRole)s_roles.get (key);
|
||||||
if (role == null || reload)
|
if (role == null || reload)
|
||||||
|
@ -133,7 +133,7 @@ public final class MRole extends X_AD_Role
|
||||||
}
|
}
|
||||||
role.setAD_User_ID(AD_User_ID);
|
role.setAD_User_ID(AD_User_ID);
|
||||||
role.loadAccess(reload);
|
role.loadAccess(reload);
|
||||||
s_log.info(role.toString());
|
if (s_log.isLoggable(Level.INFO)) s_log.info(role.toString());
|
||||||
}
|
}
|
||||||
return role;
|
return role;
|
||||||
} // get
|
} // get
|
||||||
|
@ -2538,7 +2538,7 @@ public final class MRole extends X_AD_Role
|
||||||
pstmt1.setInt(1, getAD_Role_ID());
|
pstmt1.setInt(1, getAD_Role_ID());
|
||||||
pstmt1.setString(2, doc.getDocBaseType());
|
pstmt1.setString(2, doc.getDocBaseType());
|
||||||
|
|
||||||
s_log.info(sql1 + " : " + getAD_Role_ID() + " "
|
if (s_log.isLoggable(Level.INFO)) s_log.info(sql1 + " : " + getAD_Role_ID() + " "
|
||||||
+ doc.getDocBaseType());
|
+ doc.getDocBaseType());
|
||||||
rs1 = pstmt1.executeQuery();
|
rs1 = pstmt1.executeQuery();
|
||||||
|
|
||||||
|
@ -2563,7 +2563,7 @@ public final class MRole extends X_AD_Role
|
||||||
|
|
||||||
pstmt = DB.prepareStatement(sql, null);
|
pstmt = DB.prepareStatement(sql, null);
|
||||||
DB.setParameters(pstmt, params);
|
DB.setParameters(pstmt, params);
|
||||||
s_log.info(sql + " : " );
|
if (s_log.isLoggable(Level.INFO)) s_log.info(sql + " : " );
|
||||||
rs = pstmt.executeQuery();
|
rs = pstmt.executeQuery();
|
||||||
while (rs.next()) {
|
while (rs.next()) {
|
||||||
String op = rs.getString(1);
|
String op = rs.getString(1);
|
||||||
|
@ -2619,7 +2619,7 @@ public final class MRole extends X_AD_Role
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
s_log.info("Include "+role);
|
if (s_log.isLoggable(Level.INFO)) s_log.info("Include "+role);
|
||||||
|
|
||||||
if(role.isActive()){
|
if(role.isActive()){
|
||||||
this.m_includedRoles.add(role);
|
this.m_includedRoles.add(role);
|
||||||
|
|
|
@ -126,7 +126,7 @@ public class MRoleOrgAccess extends X_AD_Role_OrgAccess
|
||||||
counter++;
|
counter++;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
s_log.info(org + " - created #" + counter);
|
if (s_log.isLoggable(Level.INFO)) s_log.info(org + " - created #" + counter);
|
||||||
return counter != 0;
|
return counter != 0;
|
||||||
} // createForOrg
|
} // createForOrg
|
||||||
|
|
||||||
|
|
|
@ -449,7 +449,7 @@ public class MSequence extends X_AD_Sequence
|
||||||
// + " - Type=" + pstmt.getResultSetType() + " - Concur=" + pstmt.getResultSetConcurrency());
|
// + " - Type=" + pstmt.getResultSetType() + " - Concur=" + pstmt.getResultSetConcurrency());
|
||||||
if (rs.next())
|
if (rs.next())
|
||||||
{
|
{
|
||||||
s_log.fine("AD_Sequence_ID="+AD_Sequence_ID);
|
if (s_log.isLoggable(Level.FINE)) s_log.fine("AD_Sequence_ID="+AD_Sequence_ID);
|
||||||
|
|
||||||
PreparedStatement updateSQL = null;
|
PreparedStatement updateSQL = null;
|
||||||
try
|
try
|
||||||
|
@ -548,7 +548,7 @@ public class MSequence extends X_AD_Sequence
|
||||||
if (suffix != null && suffix.length() > 0)
|
if (suffix != null && suffix.length() > 0)
|
||||||
doc.append(Env.parseVariable(suffix, po, trxName, false));
|
doc.append(Env.parseVariable(suffix, po, trxName, false));
|
||||||
String documentNo = doc.toString();
|
String documentNo = doc.toString();
|
||||||
s_log.finer (documentNo + " (" + incrementNo + ")"
|
if (s_log.isLoggable(Level.FINER)) s_log.finer (documentNo + " (" + incrementNo + ")"
|
||||||
+ " - Sequence=" + AD_Sequence_ID + " [" + trx + "]");
|
+ " - Sequence=" + AD_Sequence_ID + " [" + trx + "]");
|
||||||
return documentNo;
|
return documentNo;
|
||||||
}
|
}
|
||||||
|
@ -596,7 +596,7 @@ public class MSequence extends X_AD_Sequence
|
||||||
MDocType dt = MDocType.get (Env.getCtx(), C_DocType_ID); // wrong for SERVER, but r/o
|
MDocType dt = MDocType.get (Env.getCtx(), C_DocType_ID); // wrong for SERVER, but r/o
|
||||||
if (dt != null && !dt.isDocNoControlled())
|
if (dt != null && !dt.isDocNoControlled())
|
||||||
{
|
{
|
||||||
s_log.finer("DocType_ID=" + C_DocType_ID + " Not DocNo controlled");
|
if (s_log.isLoggable(Level.FINER)) s_log.finer("DocType_ID=" + C_DocType_ID + " Not DocNo controlled");
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
if (definite && ! dt.isOverwriteSeqOnComplete()) {
|
if (definite && ! dt.isOverwriteSeqOnComplete()) {
|
||||||
|
@ -656,7 +656,7 @@ public class MSequence extends X_AD_Sequence
|
||||||
while (rs.next())
|
while (rs.next())
|
||||||
{
|
{
|
||||||
String tableName = rs.getString(1);
|
String tableName = rs.getString(1);
|
||||||
s_log.fine("Add: " + tableName);
|
if (s_log.isLoggable(Level.FINE)) s_log.fine("Add: " + tableName);
|
||||||
MSequence seq = new MSequence (ctx, AD_Client_ID, tableName, trxName);
|
MSequence seq = new MSequence (ctx, AD_Client_ID, tableName, trxName);
|
||||||
if (seq.save())
|
if (seq.save())
|
||||||
counter++;
|
counter++;
|
||||||
|
@ -678,7 +678,7 @@ public class MSequence extends X_AD_Sequence
|
||||||
rs = null;
|
rs = null;
|
||||||
pstmt = null;
|
pstmt = null;
|
||||||
}
|
}
|
||||||
s_log.info ("AD_Client_ID=" + AD_Client_ID
|
if (s_log.isLoggable(Level.INFO)) s_log.info ("AD_Client_ID=" + AD_Client_ID
|
||||||
+ " - created #" + counter
|
+ " - created #" + counter
|
||||||
+ " - success=" + success);
|
+ " - success=" + success);
|
||||||
return success;
|
return success;
|
||||||
|
|
|
@ -94,7 +94,7 @@ public class MStatusCategory extends X_R_StatusCategory
|
||||||
String sql = "UPDATE R_Status SET R_StatusCategory_ID=" + retValue.getR_StatusCategory_ID()
|
String sql = "UPDATE R_Status SET R_StatusCategory_ID=" + retValue.getR_StatusCategory_ID()
|
||||||
+ " WHERE R_StatusCategory_ID IS NULL AND AD_Client_ID=" + AD_Client_ID;
|
+ " WHERE R_StatusCategory_ID IS NULL AND AD_Client_ID=" + AD_Client_ID;
|
||||||
int no = DB.executeUpdate(sql, null);
|
int no = DB.executeUpdate(sql, null);
|
||||||
s_log.info("Default for AD_Client_ID=" + AD_Client_ID + " - Status #" + no);
|
if (s_log.isLoggable(Level.INFO)) s_log.info("Default for AD_Client_ID=" + AD_Client_ID + " - Status #" + no);
|
||||||
return retValue;
|
return retValue;
|
||||||
} // createDefault
|
} // createDefault
|
||||||
|
|
||||||
|
|
|
@ -67,10 +67,10 @@ public class MStorageOnHand extends X_M_StorageOnHand
|
||||||
.first();
|
.first();
|
||||||
|
|
||||||
if (retValue == null)
|
if (retValue == null)
|
||||||
s_log.fine("Not Found - M_Locator_ID=" + M_Locator_ID
|
if (s_log.isLoggable(Level.FINE)) s_log.fine("Not Found - M_Locator_ID=" + M_Locator_ID
|
||||||
+ ", M_Product_ID=" + M_Product_ID + ", M_AttributeSetInstance_ID=" + M_AttributeSetInstance_ID);
|
+ ", M_Product_ID=" + M_Product_ID + ", M_AttributeSetInstance_ID=" + M_AttributeSetInstance_ID);
|
||||||
else
|
else
|
||||||
s_log.fine("M_Locator_ID=" + M_Locator_ID
|
if (s_log.isLoggable(Level.FINE)) s_log.fine("M_Locator_ID=" + M_Locator_ID
|
||||||
+ ", M_Product_ID=" + M_Product_ID + ", M_AttributeSetInstance_ID=" + M_AttributeSetInstance_ID);
|
+ ", M_Product_ID=" + M_Product_ID + ", M_AttributeSetInstance_ID=" + M_AttributeSetInstance_ID);
|
||||||
return retValue;
|
return retValue;
|
||||||
} // get
|
} // get
|
||||||
|
@ -339,7 +339,7 @@ public class MStorageOnHand extends X_M_StorageOnHand
|
||||||
//
|
//
|
||||||
retValue = new MStorageOnHand (locator, M_Product_ID, M_AttributeSetInstance_ID);
|
retValue = new MStorageOnHand (locator, M_Product_ID, M_AttributeSetInstance_ID);
|
||||||
retValue.saveEx(trxName);
|
retValue.saveEx(trxName);
|
||||||
s_log.fine("New " + retValue);
|
if (s_log.isLoggable(Level.FINE)) s_log.fine("New " + retValue);
|
||||||
return retValue;
|
return retValue;
|
||||||
} // getCreate
|
} // getCreate
|
||||||
|
|
||||||
|
@ -380,7 +380,7 @@ public class MStorageOnHand extends X_M_StorageOnHand
|
||||||
storage.setQtyOnHand (storage.getQtyOnHand().add (diffQtyOnHand));
|
storage.setQtyOnHand (storage.getQtyOnHand().add (diffQtyOnHand));
|
||||||
if (s_log.isLoggable(Level.FINE)) {
|
if (s_log.isLoggable(Level.FINE)) {
|
||||||
StringBuilder diffText = new StringBuilder("(OnHand=").append(diffQtyOnHand).append(") -> ").append(storage.toString());
|
StringBuilder diffText = new StringBuilder("(OnHand=").append(diffQtyOnHand).append(") -> ").append(storage.toString());
|
||||||
s_log.fine(diffText.toString());
|
if (s_log.isLoggable(Level.FINE)) s_log.fine(diffText.toString());
|
||||||
}
|
}
|
||||||
return storage.save (trxName);
|
return storage.save (trxName);
|
||||||
} // add
|
} // add
|
||||||
|
|
|
@ -75,10 +75,10 @@ public class MStorageReservation extends X_M_StorageReservation {
|
||||||
rs = null; pstmt = null;
|
rs = null; pstmt = null;
|
||||||
}
|
}
|
||||||
if (retValue == null)
|
if (retValue == null)
|
||||||
s_log.fine("Not Found - M_Warehouse_ID=" + M_Warehouse_ID
|
if (s_log.isLoggable(Level.FINE)) s_log.fine("Not Found - M_Warehouse_ID=" + M_Warehouse_ID
|
||||||
+ ", M_Product_ID=" + M_Product_ID + ", M_AttributeSetInstance_ID=" + M_AttributeSetInstance_ID + ", IsSOTrx=" + isSOTrx);
|
+ ", M_Product_ID=" + M_Product_ID + ", M_AttributeSetInstance_ID=" + M_AttributeSetInstance_ID + ", IsSOTrx=" + isSOTrx);
|
||||||
else
|
else
|
||||||
s_log.fine("M_Warehouse_ID=" + M_Warehouse_ID
|
if (s_log.isLoggable(Level.FINE)) s_log.fine("M_Warehouse_ID=" + M_Warehouse_ID
|
||||||
+ ", M_Product_ID=" + M_Product_ID + ", M_AttributeSetInstance_ID=" + M_AttributeSetInstance_ID + ", IsSOTrx=" + isSOTrx);
|
+ ", M_Product_ID=" + M_Product_ID + ", M_AttributeSetInstance_ID=" + M_AttributeSetInstance_ID + ", IsSOTrx=" + isSOTrx);
|
||||||
return retValue;
|
return retValue;
|
||||||
} // get
|
} // get
|
||||||
|
@ -257,7 +257,7 @@ public class MStorageReservation extends X_M_StorageReservation {
|
||||||
storage.setQty (storage.getQty().add(diffQty));
|
storage.setQty (storage.getQty().add(diffQty));
|
||||||
if (s_log.isLoggable(Level.FINE)) {
|
if (s_log.isLoggable(Level.FINE)) {
|
||||||
StringBuilder diffText = new StringBuilder("(Qty=").append(diffQty).append(") -> ").append(storage.toString());
|
StringBuilder diffText = new StringBuilder("(Qty=").append(diffQty).append(") -> ").append(storage.toString());
|
||||||
s_log.fine(diffText.toString());
|
if (s_log.isLoggable(Level.FINE)) s_log.fine(diffText.toString());
|
||||||
}
|
}
|
||||||
return storage.save (trxName);
|
return storage.save (trxName);
|
||||||
} // add
|
} // add
|
||||||
|
@ -289,7 +289,7 @@ public class MStorageReservation extends X_M_StorageReservation {
|
||||||
//
|
//
|
||||||
retValue = new MStorageReservation (warehouse, M_Product_ID, M_AttributeSetInstance_ID, isSOTrx);
|
retValue = new MStorageReservation (warehouse, M_Product_ID, M_AttributeSetInstance_ID, isSOTrx);
|
||||||
retValue.saveEx(trxName);
|
retValue.saveEx(trxName);
|
||||||
s_log.fine("New " + retValue);
|
if (s_log.isLoggable(Level.FINE)) s_log.fine("New " + retValue);
|
||||||
return retValue;
|
return retValue;
|
||||||
} // getCreate
|
} // getCreate
|
||||||
|
|
||||||
|
|
|
@ -185,7 +185,7 @@ public class MStore extends X_W_Store
|
||||||
Collection<?> cc = s_cache.values();
|
Collection<?> cc = s_cache.values();
|
||||||
Object[] oo = cc.toArray();
|
Object[] oo = cc.toArray();
|
||||||
for (int i = 0; i < oo.length; i++)
|
for (int i = 0; i < oo.length; i++)
|
||||||
s_log.info(i + ": " + oo[i]);
|
if (s_log.isLoggable(Level.INFO)) s_log.info(i + ": " + oo[i]);
|
||||||
MStore[] retValue = new MStore[oo.length];
|
MStore[] retValue = new MStore[oo.length];
|
||||||
for (int i = 0; i < oo.length; i++)
|
for (int i = 0; i < oo.length; i++)
|
||||||
retValue[i] = (MStore)oo[i];
|
retValue[i] = (MStore)oo[i];
|
||||||
|
|
|
@ -92,8 +92,7 @@ public class MToolBarButtonRestrict extends X_AD_ToolBarButtonRestrict
|
||||||
**/
|
**/
|
||||||
public static int[] getOfWindow(Properties ctx, int AD_Role_ID, int AD_Window_ID, boolean reportViewer, String trxName)
|
public static int[] getOfWindow(Properties ctx, int AD_Role_ID, int AD_Window_ID, boolean reportViewer, String trxName)
|
||||||
{
|
{
|
||||||
if (s_log.isLoggable(Level.INFO))
|
if (s_log.isLoggable(Level.INFO)) s_log.info("sql="+GET_OF_WINDOW_SQL);
|
||||||
s_log.info("sql="+GET_OF_WINDOW_SQL);
|
|
||||||
|
|
||||||
int[] ids = DB.getIDsEx(trxName, GET_OF_WINDOW_SQL, Env.getAD_Client_ID(ctx), AD_Role_ID, AD_Window_ID, reportViewer ? "R" : "W");
|
int[] ids = DB.getIDsEx(trxName, GET_OF_WINDOW_SQL, Env.getAD_Client_ID(ctx), AD_Role_ID, AD_Window_ID, reportViewer ? "R" : "W");
|
||||||
|
|
||||||
|
@ -109,8 +108,7 @@ public class MToolBarButtonRestrict extends X_AD_ToolBarButtonRestrict
|
||||||
**/
|
**/
|
||||||
public static int[] getOfReport(Properties ctx, int AD_Role_ID, int AD_Process_ID, String trxName)
|
public static int[] getOfReport(Properties ctx, int AD_Role_ID, int AD_Process_ID, String trxName)
|
||||||
{
|
{
|
||||||
if (s_log.isLoggable(Level.INFO))
|
if (s_log.isLoggable(Level.INFO)) s_log.info("sql="+GET_OF_REPORT_SQL);
|
||||||
s_log.info("sql="+GET_OF_REPORT_SQL);
|
|
||||||
|
|
||||||
int[] ids = DB.getIDsEx(trxName, GET_OF_REPORT_SQL, Env.getAD_Client_ID(ctx), AD_Role_ID, AD_Process_ID, "R");
|
int[] ids = DB.getIDsEx(trxName, GET_OF_REPORT_SQL, Env.getAD_Client_ID(ctx), AD_Role_ID, AD_Process_ID, "R");
|
||||||
|
|
||||||
|
@ -120,8 +118,7 @@ public class MToolBarButtonRestrict extends X_AD_ToolBarButtonRestrict
|
||||||
/** Returns a list of restrictions to be applied according to the role for ad_tab toolbar buttons **/
|
/** Returns a list of restrictions to be applied according to the role for ad_tab toolbar buttons **/
|
||||||
public static int[] getOfTab(Properties ctx, int AD_Role_ID, int AD_Tab_ID, String trxName)
|
public static int[] getOfTab(Properties ctx, int AD_Role_ID, int AD_Tab_ID, String trxName)
|
||||||
{
|
{
|
||||||
if (s_log.isLoggable(Level.INFO))
|
if (s_log.isLoggable(Level.INFO)) s_log.info("sql="+GET_OF_TAB_SQL);
|
||||||
s_log.info("sql="+GET_OF_TAB_SQL);
|
|
||||||
|
|
||||||
int[] ids = DB.getIDsEx(trxName, GET_OF_TAB_SQL, Env.getAD_Client_ID(ctx), AD_Role_ID, AD_Tab_ID);
|
int[] ids = DB.getIDsEx(trxName, GET_OF_TAB_SQL, Env.getAD_Client_ID(ctx), AD_Role_ID, AD_Tab_ID);
|
||||||
|
|
||||||
|
|
|
@ -434,7 +434,7 @@ public class MUOMConversion extends X_C_UOM_Conversion
|
||||||
}
|
}
|
||||||
if (retValue == null)
|
if (retValue == null)
|
||||||
{
|
{
|
||||||
s_log.info ("NOT found - FromUOM=" + C_UOM_From_ID + ", ToUOM=" + C_UOM_To_ID);
|
if (s_log.isLoggable(Level.INFO)) s_log.info ("NOT found - FromUOM=" + C_UOM_From_ID + ", ToUOM=" + C_UOM_To_ID);
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -533,7 +533,7 @@ public class MUOMConversion extends X_C_UOM_Conversion
|
||||||
if (qtyPrice == null || qtyPrice.compareTo(Env.ZERO)==0
|
if (qtyPrice == null || qtyPrice.compareTo(Env.ZERO)==0
|
||||||
|| C_UOM_To_ID == 0|| M_Product_ID == 0)
|
|| C_UOM_To_ID == 0|| M_Product_ID == 0)
|
||||||
{
|
{
|
||||||
s_log.fine("No Conversion - QtyPrice=" + qtyPrice);
|
if (s_log.isLoggable(Level.FINE)) s_log.fine("No Conversion - QtyPrice=" + qtyPrice);
|
||||||
return qtyPrice;
|
return qtyPrice;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -547,7 +547,7 @@ public class MUOMConversion extends X_C_UOM_Conversion
|
||||||
return uom.round(retValue.multiply(qtyPrice), true);
|
return uom.round(retValue.multiply(qtyPrice), true);
|
||||||
return retValue.multiply(qtyPrice);
|
return retValue.multiply(qtyPrice);
|
||||||
}
|
}
|
||||||
s_log.fine("No Rate M_Product_ID=" + M_Product_ID);
|
if (s_log.isLoggable(Level.FINE)) s_log.fine("No Rate M_Product_ID=" + M_Product_ID);
|
||||||
return null;
|
return null;
|
||||||
} // convertProductFrom
|
} // convertProductFrom
|
||||||
|
|
||||||
|
@ -613,7 +613,7 @@ public class MUOMConversion extends X_C_UOM_Conversion
|
||||||
result = new MUOMConversion[list.size ()];
|
result = new MUOMConversion[list.size ()];
|
||||||
list.toArray (result);
|
list.toArray (result);
|
||||||
s_conversionProduct.put(key, result);
|
s_conversionProduct.put(key, result);
|
||||||
s_log.fine("getProductConversions - M_Product_ID=" + M_Product_ID + " #" + result.length);
|
if (s_log.isLoggable(Level.FINE)) s_log.fine("getProductConversions - M_Product_ID=" + M_Product_ID + " #" + result.length);
|
||||||
return result;
|
return result;
|
||||||
} // getProductConversions
|
} // getProductConversions
|
||||||
|
|
||||||
|
|
|
@ -90,7 +90,7 @@ public class MWarehousePrice extends X_RV_WarehousePrice
|
||||||
//
|
//
|
||||||
String finalSQL = MRole.getDefault().addAccessSQL(sql.toString(),
|
String finalSQL = MRole.getDefault().addAccessSQL(sql.toString(),
|
||||||
"RV_WarehousePrice", MRole.SQL_NOTQUALIFIED, MRole.SQL_RO);
|
"RV_WarehousePrice", MRole.SQL_NOTQUALIFIED, MRole.SQL_RO);
|
||||||
s_log.fine("find - M_PriceList_Version_ID=" + M_PriceList_Version_ID
|
if (s_log.isLoggable(Level.FINE)) s_log.fine("find - M_PriceList_Version_ID=" + M_PriceList_Version_ID
|
||||||
+ ", M_Warehouse_ID=" + M_Warehouse_ID
|
+ ", M_Warehouse_ID=" + M_Warehouse_ID
|
||||||
+ " - " + finalSQL);
|
+ " - " + finalSQL);
|
||||||
ArrayList<MWarehousePrice> list = new ArrayList<MWarehousePrice>();
|
ArrayList<MWarehousePrice> list = new ArrayList<MWarehousePrice>();
|
||||||
|
@ -125,7 +125,7 @@ public class MWarehousePrice extends X_RV_WarehousePrice
|
||||||
pstmt = null;
|
pstmt = null;
|
||||||
}
|
}
|
||||||
//
|
//
|
||||||
s_log.fine("find - #" + list.size());
|
if (s_log.isLoggable(Level.FINE)) s_log.fine("find - #" + list.size());
|
||||||
MWarehousePrice[] retValue = new MWarehousePrice[list.size()];
|
MWarehousePrice[] retValue = new MWarehousePrice[list.size()];
|
||||||
list.toArray(retValue);
|
list.toArray(retValue);
|
||||||
return retValue;
|
return retValue;
|
||||||
|
|
|
@ -1238,7 +1238,7 @@ public abstract class PO
|
||||||
*/
|
*/
|
||||||
public static void copyValues (PO from, PO to)
|
public static void copyValues (PO from, PO to)
|
||||||
{
|
{
|
||||||
s_log.fine("From ID=" + from.get_ID() + " - To ID=" + to.get_ID());
|
if (s_log.isLoggable(Level.FINE)) s_log.fine("From ID=" + from.get_ID() + " - To ID=" + to.get_ID());
|
||||||
// Different Classes
|
// Different Classes
|
||||||
if (from.getClass() != to.getClass())
|
if (from.getClass() != to.getClass())
|
||||||
{
|
{
|
||||||
|
|
|
@ -28,10 +28,10 @@ import java.sql.Timestamp;
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
import java.util.Collection;
|
import java.util.Collection;
|
||||||
import java.util.Properties;
|
import java.util.Properties;
|
||||||
|
import java.util.logging.Level;
|
||||||
|
|
||||||
import org.adempiere.exceptions.AdempiereException;
|
import org.adempiere.exceptions.AdempiereException;
|
||||||
import org.adempiere.exceptions.DBException;
|
import org.adempiere.exceptions.DBException;
|
||||||
import org.compiere.util.CLogMgt;
|
|
||||||
import org.compiere.util.CLogger;
|
import org.compiere.util.CLogger;
|
||||||
import org.compiere.util.DB;
|
import org.compiere.util.DB;
|
||||||
import org.compiere.util.Env;
|
import org.compiere.util.Env;
|
||||||
|
@ -120,7 +120,7 @@ public class SetGetUtil
|
||||||
{
|
{
|
||||||
for (SetGetModel model : models)
|
for (SetGetModel model : models)
|
||||||
{
|
{
|
||||||
if(CLogMgt.isLevelFinest()) s_log.finest("Model: " + model);
|
if (s_log.isLoggable(Level.FINEST)) s_log.finest("Model: " + model);
|
||||||
if (rs.next())
|
if (rs.next())
|
||||||
{
|
{
|
||||||
if (columnNames == null)
|
if (columnNames == null)
|
||||||
|
@ -149,12 +149,12 @@ public class SetGetUtil
|
||||||
}
|
}
|
||||||
//
|
//
|
||||||
ok = model.set_AttrValue(columnName, obj);
|
ok = model.set_AttrValue(columnName, obj);
|
||||||
if (CLogMgt.isLevelFinest()) s_log.finest("columnName=" + columnName + ", value=[" + obj + "][" + (obj != null ? obj.getClass().getName() : "null") + "], ok=" + ok);
|
if (s_log.isLoggable(Level.FINEST)) s_log.finest("columnName=" + columnName + ", value=[" + obj + "][" + (obj != null ? obj.getClass().getName() : "null") + "], ok=" + ok);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
s_log.finest("@NoResult@");
|
if (s_log.isLoggable(Level.FINEST)) s_log.finest("@NoResult@");
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -234,7 +234,7 @@ public class SetGetUtil
|
||||||
String[] includeFields, String[] excludeFields,
|
String[] includeFields, String[] excludeFields,
|
||||||
boolean trackOnlyChanges)
|
boolean trackOnlyChanges)
|
||||||
{
|
{
|
||||||
if (CLogMgt.isLevelFinest())
|
if (s_log.isLoggable(Level.FINEST))
|
||||||
{
|
{
|
||||||
s_log.finest("Entering: From=" + from+ " - To=" + to);
|
s_log.finest("Entering: From=" + from+ " - To=" + to);
|
||||||
// s_log.finest("includeFields=" + ARHIPAC.toString(includeFields));
|
// s_log.finest("includeFields=" + ARHIPAC.toString(includeFields));
|
||||||
|
@ -243,7 +243,7 @@ public class SetGetUtil
|
||||||
//
|
//
|
||||||
if (to == null || from == null)
|
if (to == null || from == null)
|
||||||
{
|
{
|
||||||
if (CLogMgt.isLevelFinest())
|
if (s_log.isLoggable(Level.FINEST))
|
||||||
{
|
{
|
||||||
s_log.finest("Leaving: to == null || from == null");
|
s_log.finest("Leaving: to == null || from == null");
|
||||||
Thread.dumpStack();
|
Thread.dumpStack();
|
||||||
|
@ -308,19 +308,19 @@ public class SetGetUtil
|
||||||
//-
|
//-
|
||||||
if (isExcluded)
|
if (isExcluded)
|
||||||
{
|
{
|
||||||
if (CLogMgt.isLevelFinest()) s_log.finest("Field " + colName + " [SKIP:excluded]");
|
if (s_log.isLoggable(Level.FINEST)) s_log.finest("Field " + colName + " [SKIP:excluded]");
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
int idx_to = to.get_ColumnIndex(colName);
|
int idx_to = to.get_ColumnIndex(colName);
|
||||||
if (idx_to < 0)
|
if (idx_to < 0)
|
||||||
{
|
{
|
||||||
if (CLogMgt.isLevelFinest()) s_log.finest("Field " + colName + " [SKIP:idx_to < 0]");
|
if (s_log.isLoggable(Level.FINEST)) s_log.finest("Field " + colName + " [SKIP:idx_to < 0]");
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
if (to.p_info.isVirtualColumn(idx_to) || to.p_info.isKey(idx_to))
|
if (to.p_info.isVirtualColumn(idx_to) || to.p_info.isKey(idx_to))
|
||||||
{ // KeyColumn
|
{ // KeyColumn
|
||||||
if (CLogMgt.isLevelFinest()) s_log.finest("Field " + colName + " [SKIP:virtual or key]");
|
if (s_log.isLoggable(Level.FINEST)) s_log.finest("Field " + colName + " [SKIP:virtual or key]");
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -331,10 +331,10 @@ public class SetGetUtil
|
||||||
{
|
{
|
||||||
copiedFields++;
|
copiedFields++;
|
||||||
}
|
}
|
||||||
if (CLogMgt.isLevelFinest()) s_log.finest("Field " + colName + "=[" + value + "], idx=" + idx_from + "->" + idx_to);
|
if (s_log.isLoggable(Level.FINEST)) s_log.finest("Field " + colName + "=[" + value + "], idx=" + idx_from + "->" + idx_to);
|
||||||
}
|
}
|
||||||
//
|
//
|
||||||
if (CLogMgt.isLevelFinest()) s_log.finest("Leaving: to=" + to);
|
if (s_log.isLoggable(Level.FINEST)) s_log.finest("Leaving: to=" + to);
|
||||||
return copiedFields;
|
return copiedFields;
|
||||||
} // copyValues
|
} // copyValues
|
||||||
|
|
||||||
|
|
|
@ -656,7 +656,7 @@ public class MPrintFormat extends X_AD_PrintFormat
|
||||||
int AD_Table_ID, int AD_PrintFormat_ID)
|
int AD_Table_ID, int AD_PrintFormat_ID)
|
||||||
{
|
{
|
||||||
int AD_Client_ID = Env.getAD_Client_ID(ctx);
|
int AD_Client_ID = Env.getAD_Client_ID(ctx);
|
||||||
s_log.info ("AD_Table_ID=" + AD_Table_ID + " - AD_Client_ID=" + AD_Client_ID);
|
if (s_log.isLoggable(Level.INFO)) s_log.info ("AD_Table_ID=" + AD_Table_ID + " - AD_Client_ID=" + AD_Client_ID);
|
||||||
|
|
||||||
MPrintFormat pf = new MPrintFormat(ctx, AD_PrintFormat_ID, null);
|
MPrintFormat pf = new MPrintFormat(ctx, AD_PrintFormat_ID, null);
|
||||||
pf.setAD_Table_ID (AD_Table_ID);
|
pf.setAD_Table_ID (AD_Table_ID);
|
||||||
|
@ -739,7 +739,7 @@ public class MPrintFormat extends X_AD_PrintFormat
|
||||||
static public MPrintFormat createFromReportView (Properties ctx, int AD_ReportView_ID, String ReportName)
|
static public MPrintFormat createFromReportView (Properties ctx, int AD_ReportView_ID, String ReportName)
|
||||||
{
|
{
|
||||||
int AD_Client_ID = Env.getAD_Client_ID(ctx);
|
int AD_Client_ID = Env.getAD_Client_ID(ctx);
|
||||||
s_log.info ("AD_ReportView_ID=" + AD_ReportView_ID + " - AD_Client_ID=" + AD_Client_ID + " - " + ReportName);
|
if (s_log.isLoggable(Level.INFO)) s_log.info ("AD_ReportView_ID=" + AD_ReportView_ID + " - AD_Client_ID=" + AD_Client_ID + " - " + ReportName);
|
||||||
|
|
||||||
MPrintFormat pf = new MPrintFormat(ctx, 0, null);
|
MPrintFormat pf = new MPrintFormat(ctx, 0, null);
|
||||||
pf.setAD_ReportView_ID (AD_ReportView_ID);
|
pf.setAD_ReportView_ID (AD_ReportView_ID);
|
||||||
|
@ -895,7 +895,7 @@ public class MPrintFormat extends X_AD_PrintFormat
|
||||||
//
|
//
|
||||||
MPrintFormatItem[] retValue = new MPrintFormatItem[list.size()];
|
MPrintFormatItem[] retValue = new MPrintFormatItem[list.size()];
|
||||||
list.toArray(retValue);
|
list.toArray(retValue);
|
||||||
s_log.info(format + " - #" + retValue.length);
|
if (s_log.isLoggable(Level.INFO)) s_log.info(format + " - #" + retValue.length);
|
||||||
return retValue;
|
return retValue;
|
||||||
} // createItems
|
} // createItems
|
||||||
|
|
||||||
|
@ -907,7 +907,7 @@ public class MPrintFormat extends X_AD_PrintFormat
|
||||||
*/
|
*/
|
||||||
static private MPrintFormatItem[] copyItems (MPrintFormat fromFormat, MPrintFormat toFormat)
|
static private MPrintFormatItem[] copyItems (MPrintFormat fromFormat, MPrintFormat toFormat)
|
||||||
{
|
{
|
||||||
s_log.info("From=" + fromFormat);
|
if (s_log.isLoggable(Level.INFO)) s_log.info("From=" + fromFormat);
|
||||||
ArrayList<MPrintFormatItem> list = new ArrayList<MPrintFormatItem>();
|
ArrayList<MPrintFormatItem> list = new ArrayList<MPrintFormatItem>();
|
||||||
|
|
||||||
MPrintFormatItem[] items = fromFormat.getItemsNotIn(toFormat.get_ID());
|
MPrintFormatItem[] items = fromFormat.getItemsNotIn(toFormat.get_ID());
|
||||||
|
@ -1003,7 +1003,7 @@ public class MPrintFormat extends X_AD_PrintFormat
|
||||||
private static MPrintFormat copy (Properties ctx, int from_AD_PrintFormat_ID,
|
private static MPrintFormat copy (Properties ctx, int from_AD_PrintFormat_ID,
|
||||||
int to_AD_PrintFormat_ID, int to_Client_ID)
|
int to_AD_PrintFormat_ID, int to_Client_ID)
|
||||||
{
|
{
|
||||||
s_log.info ("From AD_PrintFormat_ID=" + from_AD_PrintFormat_ID
|
if (s_log.isLoggable(Level.INFO)) s_log.info ("From AD_PrintFormat_ID=" + from_AD_PrintFormat_ID
|
||||||
+ ", To AD_PrintFormat_ID=" + to_AD_PrintFormat_ID
|
+ ", To AD_PrintFormat_ID=" + to_AD_PrintFormat_ID
|
||||||
+ ", To Client_ID=" + to_Client_ID);
|
+ ", To Client_ID=" + to_Client_ID);
|
||||||
if (from_AD_PrintFormat_ID == 0)
|
if (from_AD_PrintFormat_ID == 0)
|
||||||
|
|
|
@ -158,7 +158,7 @@ public final class Msg
|
||||||
s_log.log(Level.SEVERE, "Too few (" + msg.size() + ") Records found for " + AD_Language);
|
s_log.log(Level.SEVERE, "Too few (" + msg.size() + ") Records found for " + AD_Language);
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
s_log.info("Records=" + msg.size() + " - " + AD_Language);
|
if (s_log.isLoggable(Level.INFO)) s_log.info("Records=" + msg.size() + " - " + AD_Language);
|
||||||
return msg;
|
return msg;
|
||||||
} // initMsg
|
} // initMsg
|
||||||
|
|
||||||
|
@ -259,8 +259,7 @@ public final class Msg
|
||||||
//
|
//
|
||||||
if (retStr == null || retStr.length() == 0)
|
if (retStr == null || retStr.length() == 0)
|
||||||
{
|
{
|
||||||
if (s_log.isLoggable(Level.INFO))
|
if (s_log.isLoggable(Level.INFO)) s_log.info("NOT found: " + AD_Message);
|
||||||
s_log.info("NOT found: " + AD_Message);
|
|
||||||
return AD_Message;
|
return AD_Message;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -4,6 +4,7 @@
|
||||||
package org.idempiere.fa.process;
|
package org.idempiere.fa.process;
|
||||||
|
|
||||||
import java.lang.reflect.Field;
|
import java.lang.reflect.Field;
|
||||||
|
import java.util.logging.Level;
|
||||||
|
|
||||||
import org.adempiere.exceptions.AdempiereException;
|
import org.adempiere.exceptions.AdempiereException;
|
||||||
import org.compiere.process.ProcessInfoParameter;
|
import org.compiere.process.ProcessInfoParameter;
|
||||||
|
@ -85,7 +86,7 @@ public abstract class SvrProcess2 extends SvrProcess
|
||||||
//
|
//
|
||||||
if (!isSet)
|
if (!isSet)
|
||||||
{
|
{
|
||||||
s_log.info("Parameter not set - "+parameterName);
|
if (s_log.isLoggable(Level.INFO)) s_log.info("Parameter not set - "+parameterName);
|
||||||
}
|
}
|
||||||
} // for Field
|
} // for Field
|
||||||
}
|
}
|
||||||
|
|
|
@ -35,7 +35,7 @@ public class PipoDictionaryService implements IDictionaryService {
|
||||||
X_AD_Package_Imp_Proc adPackageImp = new X_AD_Package_Imp_Proc(Env.getCtx(),
|
X_AD_Package_Imp_Proc adPackageImp = new X_AD_Package_Imp_Proc(Env.getCtx(),
|
||||||
0, trxName);
|
0, trxName);
|
||||||
File zipFilepath = packageFile;
|
File zipFilepath = packageFile;
|
||||||
logger.info("zipFilepath->" + zipFilepath);
|
if (logger.isLoggable(Level.INFO)) logger.info("zipFilepath->" + zipFilepath);
|
||||||
String parentDir = Zipper.getParentDir(zipFilepath);
|
String parentDir = Zipper.getParentDir(zipFilepath);
|
||||||
File targetDir = new File(System.getProperty("java.io.tmpdir"));
|
File targetDir = new File(System.getProperty("java.io.tmpdir"));
|
||||||
Zipper.unpackFile(zipFilepath, targetDir);
|
Zipper.unpackFile(zipFilepath, targetDir);
|
||||||
|
@ -43,7 +43,7 @@ public class PipoDictionaryService implements IDictionaryService {
|
||||||
String dict_file = targetDir + File.separator + parentDir + File.separator
|
String dict_file = targetDir + File.separator + parentDir + File.separator
|
||||||
+ "dict" + File.separator + "PackOut.xml";
|
+ "dict" + File.separator + "PackOut.xml";
|
||||||
|
|
||||||
logger.info("dict file->" + dict_file);
|
if (logger.isLoggable(Level.INFO)) logger.info("dict file->" + dict_file);
|
||||||
|
|
||||||
// call XML Handler
|
// call XML Handler
|
||||||
String msg = packIn.importXML(dict_file, Env.getCtx(), trxName);
|
String msg = packIn.importXML(dict_file, Env.getCtx(), trxName);
|
||||||
|
@ -54,7 +54,7 @@ public class PipoDictionaryService implements IDictionaryService {
|
||||||
adPackageImp.saveEx();
|
adPackageImp.saveEx();
|
||||||
|
|
||||||
Trx.get(trxName, false).commit();
|
Trx.get(trxName, false).commit();
|
||||||
logger.info("commit " + trxName);
|
if (logger.isLoggable(Level.INFO)) logger.info("commit " + trxName);
|
||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
logger.log(Level.SEVERE, "importXML:", e);
|
logger.log(Level.SEVERE, "importXML:", e);
|
||||||
throw e;
|
throw e;
|
||||||
|
|
|
@ -25,12 +25,10 @@ public class AdempiereActivator implements BundleActivator {
|
||||||
@Override
|
@Override
|
||||||
public void start(BundleContext context) throws Exception {
|
public void start(BundleContext context) throws Exception {
|
||||||
this.context = context;
|
this.context = context;
|
||||||
if (logger.isLoggable(Level.INFO))
|
if (logger.isLoggable(Level.INFO)) logger.info(getName() + " " + getVersion() + " starting...");
|
||||||
logger.info(getName() + " " + getVersion() + " starting...");
|
|
||||||
installPackage();
|
installPackage();
|
||||||
start();
|
start();
|
||||||
if (logger.isLoggable(Level.INFO))
|
if (logger.isLoggable(Level.INFO)) logger.info(getName() + " " + getVersion() + " ready.");
|
||||||
logger.info(getName() + " " + getVersion() + " ready.");
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public String getName() {
|
public String getName() {
|
||||||
|
@ -80,11 +78,9 @@ public class AdempiereActivator implements BundleActivator {
|
||||||
if (pkg == null) {
|
if (pkg == null) {
|
||||||
packIn(trxName);
|
packIn(trxName);
|
||||||
install();
|
install();
|
||||||
if (logger.isLoggable(Level.INFO))
|
if (logger.isLoggable(Level.INFO)) logger.info(getName() + " " + version + " installed.");
|
||||||
logger.info(getName() + " " + version + " installed.");
|
|
||||||
} else {
|
} else {
|
||||||
if (logger.isLoggable(Level.INFO))
|
if (logger.isLoggable(Level.INFO)) logger.info(getName() + " " + version + " was installed: "
|
||||||
logger.info(getName() + " " + version + " was installed: "
|
|
||||||
+ pkg.getCreated());
|
+ pkg.getCreated());
|
||||||
}
|
}
|
||||||
Trx.get(trxName, false).commit();
|
Trx.get(trxName, false).commit();
|
||||||
|
@ -136,7 +132,7 @@ public class AdempiereActivator implements BundleActivator {
|
||||||
@Override
|
@Override
|
||||||
public void stop(BundleContext context) throws Exception {
|
public void stop(BundleContext context) throws Exception {
|
||||||
stop();
|
stop();
|
||||||
logger.info(context.getBundle().getSymbolicName() + " "
|
if (logger.isLoggable(Level.INFO)) logger.info(context.getBundle().getSymbolicName() + " "
|
||||||
+ context.getBundle().getHeaders().get("Bundle-Version")
|
+ context.getBundle().getHeaders().get("Bundle-Version")
|
||||||
+ " stopped.");
|
+ " stopped.");
|
||||||
}
|
}
|
||||||
|
|
|
@ -36,6 +36,7 @@ import java.text.SimpleDateFormat;
|
||||||
import java.util.Collection;
|
import java.util.Collection;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import java.util.Properties;
|
import java.util.Properties;
|
||||||
|
import java.util.logging.Level;
|
||||||
|
|
||||||
import javax.xml.xpath.XPathExpressionException;
|
import javax.xml.xpath.XPathExpressionException;
|
||||||
|
|
||||||
|
@ -565,10 +566,10 @@ public class ImportHelper {
|
||||||
.setParameters(value)
|
.setParameters(value)
|
||||||
.firstOnly();
|
.firstOnly();
|
||||||
|
|
||||||
s_log.info("Client_Value =[" + value + "]");
|
if (s_log.isLoggable(Level.INFO)) s_log.info("Client_Value =[" + value + "]");
|
||||||
if(result != null)
|
if(result != null)
|
||||||
{
|
{
|
||||||
s_log.info("AD_Client_ID = " + result.getAD_Client_ID());
|
if (s_log.isLoggable(Level.INFO)) s_log.info("AD_Client_ID = " + result.getAD_Client_ID());
|
||||||
}
|
}
|
||||||
|
|
||||||
return result;
|
return result;
|
||||||
|
|
|
@ -20,6 +20,7 @@ import java.awt.event.ActionEvent;
|
||||||
import java.awt.event.ActionListener;
|
import java.awt.event.ActionListener;
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
import java.util.logging.Level;
|
||||||
|
|
||||||
import javax.swing.JComponent;
|
import javax.swing.JComponent;
|
||||||
import javax.swing.JPopupMenu;
|
import javax.swing.JPopupMenu;
|
||||||
|
@ -60,7 +61,7 @@ public class AZoomAcross
|
||||||
|
|
||||||
public AZoomAcross(JComponent invoker, PO po, final int windowID) {
|
public AZoomAcross(JComponent invoker, PO po, final int windowID) {
|
||||||
|
|
||||||
logger.config("PO=" + po+", WindowID="+windowID);
|
if (logger.isLoggable(Level.CONFIG)) logger.config("PO=" + po+", WindowID="+windowID);
|
||||||
|
|
||||||
mkZoomTargets(po, windowID);
|
mkZoomTargets(po, windowID);
|
||||||
|
|
||||||
|
@ -97,7 +98,7 @@ public class AZoomAcross
|
||||||
windowID)) {
|
windowID)) {
|
||||||
|
|
||||||
if (zoomInfo.query.getRecordCount() == 0) {
|
if (zoomInfo.query.getRecordCount() == 0) {
|
||||||
logger.fine("No target records for destination "
|
if (logger.isLoggable(Level.FINE)) logger.fine("No target records for destination "
|
||||||
+ zoomInfo.destinationDisplay);
|
+ zoomInfo.destinationDisplay);
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
@ -115,7 +116,7 @@ public class AZoomAcross
|
||||||
final int AD_Window_ID = zoomInfo.windowId;
|
final int AD_Window_ID = zoomInfo.windowId;
|
||||||
final MQuery query = zoomInfo.query;
|
final MQuery query = zoomInfo.query;
|
||||||
|
|
||||||
logger.info("AD_Window_ID=" + AD_Window_ID
|
if (logger.isLoggable(Level.INFO)) logger.info("AD_Window_ID=" + AD_Window_ID
|
||||||
+ " - " + query);
|
+ " - " + query);
|
||||||
|
|
||||||
AWindow frame = new AWindow(null);
|
AWindow frame = new AWindow(null);
|
||||||
|
|
|
@ -649,10 +649,8 @@ DataStatusListener, IADTabpanel, IdSpace
|
||||||
GridField changedField = gridTab.getField(col);
|
GridField changedField = gridTab.getField(col);
|
||||||
String columnName = changedField.getColumnName();
|
String columnName = changedField.getColumnName();
|
||||||
ArrayList<?> dependants = gridTab.getDependantFields(columnName);
|
ArrayList<?> dependants = gridTab.getDependantFields(columnName);
|
||||||
if (logger.isLoggable(Level.CONFIG)) {
|
if (logger.isLoggable(Level.CONFIG)) logger.config("(" + gridTab.toString() + ") "
|
||||||
logger.config("(" + gridTab.toString() + ") "
|
|
||||||
+ columnName + " - Dependents=" + dependants.size());
|
+ columnName + " - Dependents=" + dependants.size());
|
||||||
}
|
|
||||||
if (dependants.size() == 0 && changedField.getCallout().length() > 0)
|
if (dependants.size() == 0 && changedField.getCallout().length() > 0)
|
||||||
{
|
{
|
||||||
return;
|
return;
|
||||||
|
@ -660,9 +658,8 @@ DataStatusListener, IADTabpanel, IdSpace
|
||||||
}
|
}
|
||||||
|
|
||||||
boolean noData = gridTab.getRowCount() == 0;
|
boolean noData = gridTab.getRowCount() == 0;
|
||||||
if (logger.isLoggable(Level.CONFIG)) {
|
if (logger.isLoggable(Level.CONFIG)) logger.config(gridTab.toString() + " - Rows=" + gridTab.getRowCount());
|
||||||
logger.config(gridTab.toString() + " - Rows=" + gridTab.getRowCount());
|
|
||||||
}
|
|
||||||
for (WEditor comp : editors)
|
for (WEditor comp : editors)
|
||||||
{
|
{
|
||||||
GridField mField = comp.getGridField();
|
GridField mField = comp.getGridField();
|
||||||
|
@ -769,9 +766,7 @@ DataStatusListener, IADTabpanel, IdSpace
|
||||||
}
|
}
|
||||||
|
|
||||||
Events.sendEvent(this, new Event(ON_DYNAMIC_DISPLAY_EVENT, this));
|
Events.sendEvent(this, new Event(ON_DYNAMIC_DISPLAY_EVENT, this));
|
||||||
if (logger.isLoggable(Level.CONFIG)) {
|
if (logger.isLoggable(Level.CONFIG)) logger.config(gridTab.toString() + " - fini - " + (col<=0 ? "complete" : "seletive"));
|
||||||
logger.config(gridTab.toString() + " - fini - " + (col<=0 ? "complete" : "seletive"));
|
|
||||||
}
|
|
||||||
} // dynamicDisplay
|
} // dynamicDisplay
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -1095,9 +1090,7 @@ DataStatusListener, IADTabpanel, IdSpace
|
||||||
if (Executions.getCurrent() == null) return;
|
if (Executions.getCurrent() == null) return;
|
||||||
|
|
||||||
int col = e.getChangedColumn();
|
int col = e.getChangedColumn();
|
||||||
if (logger.isLoggable(Level.CONFIG)) {
|
if (logger.isLoggable(Level.CONFIG)) logger.config("(" + gridTab + ") Col=" + col + ": " + e.toString());
|
||||||
logger.config("(" + gridTab + ") Col=" + col + ": " + e.toString());
|
|
||||||
}
|
|
||||||
|
|
||||||
// Process Callout
|
// Process Callout
|
||||||
GridField mField = gridTab.getField(col);
|
GridField mField = gridTab.getField(col);
|
||||||
|
|
|
@ -877,7 +877,7 @@ public abstract class AbstractADWindowContent extends AbstractUIPart implements
|
||||||
public void onAttachment()
|
public void onAttachment()
|
||||||
{
|
{
|
||||||
int record_ID = adTabbox.getSelectedGridTab().getRecord_ID();
|
int record_ID = adTabbox.getSelectedGridTab().getRecord_ID();
|
||||||
logger.info("Record_ID=" + record_ID);
|
if (logger.isLoggable(Level.INFO)) logger.info("Record_ID=" + record_ID);
|
||||||
|
|
||||||
if (record_ID == -1) // No Key
|
if (record_ID == -1) // No Key
|
||||||
{
|
{
|
||||||
|
@ -910,7 +910,7 @@ public abstract class AbstractADWindowContent extends AbstractUIPart implements
|
||||||
public void onChat()
|
public void onChat()
|
||||||
{
|
{
|
||||||
int recordId = adTabbox.getSelectedGridTab().getRecord_ID();
|
int recordId = adTabbox.getSelectedGridTab().getRecord_ID();
|
||||||
logger.info("Record_ID=" + recordId);
|
if (logger.isLoggable(Level.INFO)) logger.info("Record_ID=" + recordId);
|
||||||
|
|
||||||
if (recordId== -1) // No Key
|
if (recordId== -1) // No Key
|
||||||
{
|
{
|
||||||
|
@ -1244,8 +1244,7 @@ public abstract class AbstractADWindowContent extends AbstractUIPart implements
|
||||||
if (!detailTab)
|
if (!detailTab)
|
||||||
{
|
{
|
||||||
String dbInfo = e.getMessage();
|
String dbInfo = e.getMessage();
|
||||||
if (logger.isLoggable(Level.INFO))
|
if (logger.isLoggable(Level.INFO)) logger.info(dbInfo);
|
||||||
logger.info(dbInfo);
|
|
||||||
if (adTabbox.getSelectedGridTab() != null && adTabbox.getSelectedGridTab().isQueryActive())
|
if (adTabbox.getSelectedGridTab() != null && adTabbox.getSelectedGridTab().isQueryActive())
|
||||||
dbInfo = "[ " + dbInfo + " ]";
|
dbInfo = "[ " + dbInfo + " ]";
|
||||||
breadCrumb.setStatusDB(dbInfo, e);
|
breadCrumb.setStatusDB(dbInfo, e);
|
||||||
|
@ -2086,7 +2085,7 @@ public abstract class AbstractADWindowContent extends AbstractUIPart implements
|
||||||
{
|
{
|
||||||
Listitem li = iter.next();
|
Listitem li = iter.next();
|
||||||
if(li != null)
|
if(li != null)
|
||||||
logger.fine((String) li.getValue());
|
if (logger.isLoggable(Level.FINE)) logger.fine((String) li.getValue());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -2325,7 +2324,7 @@ public abstract class AbstractADWindowContent extends AbstractUIPart implements
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
logger.info(wButton.toString());
|
if (logger.isLoggable(Level.INFO)) logger.info(wButton.toString());
|
||||||
|
|
||||||
final String col = wButton.getColumnName();
|
final String col = wButton.getColumnName();
|
||||||
|
|
||||||
|
@ -2520,10 +2519,10 @@ public abstract class AbstractADWindowContent extends AbstractUIPart implements
|
||||||
String error = AEnv.postImmediate (curWindowNo, Env.getAD_Client_ID(ctx),
|
String error = AEnv.postImmediate (curWindowNo, Env.getAD_Client_ID(ctx),
|
||||||
tableIdRef, recordIdRef, force);
|
tableIdRef, recordIdRef, force);
|
||||||
|
|
||||||
|
onRefresh(true, false);
|
||||||
|
|
||||||
if (error != null)
|
if (error != null)
|
||||||
breadCrumb.setStatusLine(error, true);
|
breadCrumb.setStatusLine(error, true);
|
||||||
|
|
||||||
onRefresh(true, false);
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
@ -2559,7 +2558,7 @@ public abstract class AbstractADWindowContent extends AbstractUIPart implements
|
||||||
* Start Process ----
|
* Start Process ----
|
||||||
*/
|
*/
|
||||||
|
|
||||||
logger.config("Process_ID=" + wButton.getProcess_ID() + ", Record_ID=" + record_ID);
|
if (logger.isLoggable(Level.CONFIG)) logger.config("Process_ID=" + wButton.getProcess_ID() + ", Record_ID=" + record_ID);
|
||||||
|
|
||||||
if (wButton.getProcess_ID() == 0)
|
if (wButton.getProcess_ID() == 0)
|
||||||
{
|
{
|
||||||
|
|
|
@ -646,7 +646,7 @@ public class WListbox extends Listbox implements IMiniTable, TableValueChangeLis
|
||||||
// repaint the table
|
// repaint the table
|
||||||
this.repaint();
|
this.repaint();
|
||||||
|
|
||||||
logger.config("Row(rs)=" + getRowCount());
|
if (logger.isLoggable(Level.CONFIG)) logger.config("Row(rs)=" + getRowCount());
|
||||||
|
|
||||||
return;
|
return;
|
||||||
} // loadTable
|
} // loadTable
|
||||||
|
@ -725,7 +725,7 @@ public class WListbox extends Listbox implements IMiniTable, TableValueChangeLis
|
||||||
// repaint the table
|
// repaint the table
|
||||||
this.repaint();
|
this.repaint();
|
||||||
|
|
||||||
logger.config("Row(array)=" + getRowCount());
|
if (logger.isLoggable(Level.CONFIG)) logger.config("Row(array)=" + getRowCount());
|
||||||
|
|
||||||
return;
|
return;
|
||||||
} // loadTable
|
} // loadTable
|
||||||
|
|
|
@ -149,8 +149,7 @@ public abstract class ADForm extends Window implements EventListener<Event>
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
if (logger.isLoggable(Level.INFO))
|
if (logger.isLoggable(Level.INFO)) logger.info("AD_Form_ID=" + adFormID + " - Class=" + formName);
|
||||||
logger.info("AD_Form_ID=" + adFormID + " - Class=" + formName);
|
|
||||||
|
|
||||||
form = Extensions.getForm(formName);
|
form = Extensions.getForm(formName);
|
||||||
if (form != null)
|
if (form != null)
|
||||||
|
|
|
@ -19,6 +19,7 @@ import java.math.BigInteger;
|
||||||
import java.security.SecureRandom;
|
import java.security.SecureRandom;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import java.util.Properties;
|
import java.util.Properties;
|
||||||
|
import java.util.logging.Level;
|
||||||
|
|
||||||
import org.adempiere.exceptions.AdempiereException;
|
import org.adempiere.exceptions.AdempiereException;
|
||||||
import org.adempiere.util.Callback;
|
import org.adempiere.util.Callback;
|
||||||
|
@ -445,7 +446,7 @@ public class ResetPasswordPanel extends Window implements EventListener<Event>
|
||||||
user.saveEx();
|
user.saveEx();
|
||||||
|
|
||||||
if (sendEmail(user, newPassword))
|
if (sendEmail(user, newPassword))
|
||||||
logger.fine(user.getEMail());
|
if (logger.isLoggable(Level.FINE)) logger.fine(user.getEMail());
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
if (errorMsg.length() > 0)
|
if (errorMsg.length() > 0)
|
||||||
|
|
|
@ -19,6 +19,7 @@ package org.adempiere.webui.panel;
|
||||||
|
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
import java.util.logging.Level;
|
||||||
|
|
||||||
import org.adempiere.webui.AdempiereWebUI;
|
import org.adempiere.webui.AdempiereWebUI;
|
||||||
import org.adempiere.webui.component.ConfirmPanel;
|
import org.adempiere.webui.component.ConfirmPanel;
|
||||||
|
@ -110,7 +111,7 @@ public class WDocActionPanel extends Window implements EventListener<Event>, Dia
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
logger.fine("DocStatus=" + DocStatus
|
if (logger.isLoggable(Level.FINE)) logger.fine("DocStatus=" + DocStatus
|
||||||
+ ", DocAction=" + DocAction + ", OrderType=" + OrderType
|
+ ", DocAction=" + DocAction + ", OrderType=" + OrderType
|
||||||
+ ", IsSOTrx=" + IsSOTrx + ", Processing=" + Processing
|
+ ", IsSOTrx=" + IsSOTrx + ", Processing=" + Processing
|
||||||
+ ", AD_Table_ID=" +gridTab.getAD_Table_ID() + ", Record_ID=" + gridTab.getRecord_ID());
|
+ ", AD_Table_ID=" +gridTab.getAD_Table_ID() + ", Record_ID=" + gridTab.getRecord_ID());
|
||||||
|
@ -163,7 +164,7 @@ public class WDocActionPanel extends Window implements EventListener<Event>, Dia
|
||||||
if(doctypeId==null || doctypeId.intValue()==0){
|
if(doctypeId==null || doctypeId.intValue()==0){
|
||||||
doctypeId = (Integer)gridTab.getValue("C_DocTypeTarget_ID");
|
doctypeId = (Integer)gridTab.getValue("C_DocTypeTarget_ID");
|
||||||
}
|
}
|
||||||
logger.fine("get doctype: " + doctypeId);
|
if (logger.isLoggable(Level.FINE)) logger.fine("get doctype: " + doctypeId);
|
||||||
if (doctypeId != null) {
|
if (doctypeId != null) {
|
||||||
index = DocumentEngine.checkActionAccess(Env.getAD_Client_ID(Env.getCtx()),
|
index = DocumentEngine.checkActionAccess(Env.getAD_Client_ID(Env.getCtx()),
|
||||||
Env.getAD_Role_ID(Env.getCtx()),
|
Env.getAD_Role_ID(Env.getCtx()),
|
||||||
|
@ -319,7 +320,7 @@ public class WDocActionPanel extends Window implements EventListener<Event>, Dia
|
||||||
{
|
{
|
||||||
int index = getSelectedIndex();
|
int index = getSelectedIndex();
|
||||||
// Save Selection
|
// Save Selection
|
||||||
logger.config("DocAction=" + s_value[index]);
|
if (logger.isLoggable(Level.CONFIG)) logger.config("DocAction=" + s_value[index]);
|
||||||
gridTab.setValue("DocAction", s_value[index]);
|
gridTab.setValue("DocAction", s_value[index]);
|
||||||
} // save
|
} // save
|
||||||
|
|
||||||
|
|
|
@ -13,6 +13,7 @@
|
||||||
package org.adempiere.webui.util;
|
package org.adempiere.webui.util;
|
||||||
|
|
||||||
import java.util.Properties;
|
import java.util.Properties;
|
||||||
|
import java.util.logging.Level;
|
||||||
|
|
||||||
import org.adempiere.exceptions.AdempiereException;
|
import org.adempiere.exceptions.AdempiereException;
|
||||||
import org.adempiere.webui.editor.WEditor;
|
import org.adempiere.webui.editor.WEditor;
|
||||||
|
@ -62,23 +63,23 @@ public class GridTabDataBinder implements ValueChangeListener {
|
||||||
{
|
{
|
||||||
if(!gridField.isEditable(true))
|
if(!gridField.isEditable(true))
|
||||||
{
|
{
|
||||||
logger.config("(" + gridTab.toString() + ") " + e.getPropertyName());
|
if (logger.isLoggable(Level.CONFIG)) logger.config("(" + gridTab.toString() + ") " + e.getPropertyName());
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else if(!editor.isReadWrite())
|
else if(!editor.isReadWrite())
|
||||||
{
|
{
|
||||||
logger.config("(" + gridTab.toString() + ") " + e.getPropertyName());
|
if (logger.isLoggable(Level.CONFIG)) logger.config("(" + gridTab.toString() + ") " + e.getPropertyName());
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
logger.config("(" + gridTab.toString() + ") " + e.getPropertyName());
|
if (logger.isLoggable(Level.CONFIG)) logger.config("(" + gridTab.toString() + ") " + e.getPropertyName());
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
} // processed
|
} // processed
|
||||||
logger.config("(" + gridTab.toString() + ") "
|
if (logger.isLoggable(Level.CONFIG)) logger.config("(" + gridTab.toString() + ") "
|
||||||
+ e.getPropertyName() + "=" + e.getNewValue() + " (" + e.getOldValue() + ") "
|
+ e.getPropertyName() + "=" + e.getNewValue() + " (" + e.getOldValue() + ") "
|
||||||
+ (e.getOldValue() == null ? "" : e.getOldValue().getClass().getName()));
|
+ (e.getOldValue() == null ? "" : e.getOldValue().getClass().getName()));
|
||||||
|
|
||||||
|
|
|
@ -18,6 +18,7 @@
|
||||||
package org.adempiere.webui.window;
|
package org.adempiere.webui.window;
|
||||||
|
|
||||||
import java.util.Properties;
|
import java.util.Properties;
|
||||||
|
import java.util.logging.Level;
|
||||||
|
|
||||||
import org.compiere.util.CLogMgt;
|
import org.compiere.util.CLogMgt;
|
||||||
import org.compiere.util.CLogger;
|
import org.compiere.util.CLogger;
|
||||||
|
@ -119,7 +120,7 @@ public class FDialog
|
||||||
Properties ctx = Env.getCtx();
|
Properties ctx = Env.getCtx();
|
||||||
StringBuffer out = null;
|
StringBuffer out = null;
|
||||||
|
|
||||||
logger.info(adMessage + " - " + message);
|
if (logger.isLoggable(Level.INFO)) logger.info(adMessage + " - " + message);
|
||||||
|
|
||||||
out = constructMessage(adMessage, message);
|
out = constructMessage(adMessage, message);
|
||||||
|
|
||||||
|
@ -216,7 +217,7 @@ public class FDialog
|
||||||
Properties ctx = Env.getCtx();
|
Properties ctx = Env.getCtx();
|
||||||
StringBuffer out = new StringBuffer();
|
StringBuffer out = new StringBuffer();
|
||||||
|
|
||||||
logger.info(adMessage + " - " + message);
|
if (logger.isLoggable(Level.INFO)) logger.info(adMessage + " - " + message);
|
||||||
|
|
||||||
if (CLogMgt.isLevelFinest())
|
if (CLogMgt.isLevelFinest())
|
||||||
{
|
{
|
||||||
|
@ -347,7 +348,7 @@ public class FDialog
|
||||||
|
|
||||||
StringBuffer out = new StringBuffer();
|
StringBuffer out = new StringBuffer();
|
||||||
|
|
||||||
logger.info(adMessage + " - " + message);
|
if (logger.isLoggable(Level.INFO)) logger.info(adMessage + " - " + message);
|
||||||
|
|
||||||
if (CLogMgt.isLevelFinest())
|
if (CLogMgt.isLevelFinest())
|
||||||
{
|
{
|
||||||
|
|
|
@ -111,7 +111,7 @@ public class ReportCtl
|
||||||
*/
|
*/
|
||||||
static public boolean start (IProcessUI parent, int WindowNo, ProcessInfo pi)
|
static public boolean start (IProcessUI parent, int WindowNo, ProcessInfo pi)
|
||||||
{
|
{
|
||||||
s_log.info("start - " + pi);
|
if (s_log.isLoggable(Level.INFO)) s_log.info("start - " + pi);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Order Print
|
* Order Print
|
||||||
|
|
Loading…
Reference in New Issue