IDEMPIERE-37 Make iDempiere safer using saveEx instead of save / found and fix more cases using save - or ignoring the error of save
This commit is contained in:
parent
df7de8087a
commit
55e074dc5e
|
@ -232,7 +232,7 @@ public class DunningPrint extends SvrProcess
|
||||||
if (printed)
|
if (printed)
|
||||||
{
|
{
|
||||||
entry.setProcessed (true);
|
entry.setProcessed (true);
|
||||||
entry.save ();
|
entry.saveEx();
|
||||||
}
|
}
|
||||||
|
|
||||||
} // for all dunning letters
|
} // for all dunning letters
|
||||||
|
|
|
@ -609,7 +609,7 @@ public class ImportInvoice extends SvrProcess
|
||||||
imp.setAD_User_ID (user.getAD_User_ID ());
|
imp.setAD_User_ID (user.getAD_User_ID ());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
imp.save ();
|
imp.saveEx();
|
||||||
} // for all new BPartners
|
} // for all new BPartners
|
||||||
//
|
//
|
||||||
}
|
}
|
||||||
|
|
|
@ -610,7 +610,7 @@ public class ImportOrder extends SvrProcess
|
||||||
imp.setAD_User_ID (user.getAD_User_ID ());
|
imp.setAD_User_ID (user.getAD_User_ID ());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
imp.save ();
|
imp.saveEx();
|
||||||
} // for all new BPartners
|
} // for all new BPartners
|
||||||
//
|
//
|
||||||
}
|
}
|
||||||
|
|
|
@ -161,7 +161,7 @@ public class ProjectGenPO extends SvrProcess
|
||||||
}
|
}
|
||||||
order.setClientOrg (projectLine.getAD_Client_ID (), AD_Org_ID);
|
order.setClientOrg (projectLine.getAD_Client_ID (), AD_Org_ID);
|
||||||
order.setBPartner (bp);
|
order.setBPartner (bp);
|
||||||
order.save ();
|
order.saveEx();
|
||||||
// optionally save for consolidation
|
// optionally save for consolidation
|
||||||
if (m_ConsolidateDocument)
|
if (m_ConsolidateDocument)
|
||||||
m_pos.add(order);
|
m_pos.add(order);
|
||||||
|
|
|
@ -258,7 +258,7 @@ public class TableCreateColumns extends SvrProcess
|
||||||
element.setName(uuidColumn);
|
element.setName(uuidColumn);
|
||||||
element.setPrintName(uuidColumn);
|
element.setPrintName(uuidColumn);
|
||||||
}
|
}
|
||||||
element.save ();
|
element.saveEx();
|
||||||
}
|
}
|
||||||
column.setColumnName (element.getColumnName ());
|
column.setColumnName (element.getColumnName ());
|
||||||
column.setName (element.getName ());
|
column.setName (element.getName ());
|
||||||
|
|
|
@ -67,7 +67,7 @@ public class RequestEventHandler extends AbstractEventHandler implements Managed
|
||||||
MNote note = new MNote(Env.getCtx(), AD_Message_ID, eventData.getTo().getAD_User_ID(),
|
MNote note = new MNote(Env.getCtx(), AD_Message_ID, eventData.getTo().getAD_User_ID(),
|
||||||
X_R_Request.Table_ID, eventData.getRequestID(),
|
X_R_Request.Table_ID, eventData.getRequestID(),
|
||||||
eventData.getSubject(), eventData.getMessage(), null);
|
eventData.getSubject(), eventData.getMessage(), null);
|
||||||
note.save();
|
note.saveEx();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else if (topic.equals(IEventTopics.PO_BEFORE_NEW) || topic.equals(IEventTopics.PO_BEFORE_CHANGE)
|
else if (topic.equals(IEventTopics.PO_BEFORE_NEW) || topic.equals(IEventTopics.PO_BEFORE_CHANGE)
|
||||||
|
@ -390,7 +390,7 @@ public class RequestEventHandler extends AbstractEventHandler implements Managed
|
||||||
MNote note = new MNote(r.getCtx(), AD_Message_ID, AD_User_ID,
|
MNote note = new MNote(r.getCtx(), AD_Message_ID, AD_User_ID,
|
||||||
X_R_Request.Table_ID, r.getR_Request_ID(),
|
X_R_Request.Table_ID, r.getR_Request_ID(),
|
||||||
subject, message.toString(), r.get_TrxName());
|
subject, message.toString(), r.get_TrxName());
|
||||||
note.save();
|
note.saveEx();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -108,7 +108,7 @@ public class ProductPriceValidator implements ModelValidator {
|
||||||
{
|
{
|
||||||
pp1.setPrices(priceList, priceStd, priceLimit);
|
pp1.setPrices(priceList, priceStd, priceLimit);
|
||||||
pp1.setIsActive(isActive);
|
pp1.setIsActive(isActive);
|
||||||
pp1.save(po.get_TrxName());
|
pp1.saveEx(po.get_TrxName());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else if (type == TYPE_AFTER_DELETE)
|
else if (type == TYPE_AFTER_DELETE)
|
||||||
|
|
|
@ -52,7 +52,7 @@ public class TemplateValidate extends SvrProcess
|
||||||
{
|
{
|
||||||
MTemplate thisTemplate = new MTemplate(getCtx (), getRecord_ID (), get_TrxName ());
|
MTemplate thisTemplate = new MTemplate(getCtx (), getRecord_ID (), get_TrxName ());
|
||||||
thisTemplate.setIsValid (true);
|
thisTemplate.setIsValid (true);
|
||||||
thisTemplate.save ();
|
thisTemplate.saveEx();
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -184,7 +184,7 @@ public class WebProjectDeploy extends SvrProcess
|
||||||
thisHandler.cleanContainer(cc.get_ID());
|
thisHandler.cleanContainer(cc.get_ID());
|
||||||
// Reset Modified flag...
|
// Reset Modified flag...
|
||||||
stage.setIsModified(false);
|
stage.setIsModified(false);
|
||||||
stage.save(stage.get_TrxName());
|
stage.saveEx(stage.get_TrxName());
|
||||||
}
|
}
|
||||||
if (child.isSummary())
|
if (child.isSummary())
|
||||||
copyStage (child, path + stage.getRelativeURL() + "/");
|
copyStage (child, path + stage.getRelativeURL() + "/");
|
||||||
|
|
|
@ -277,7 +277,7 @@ public class AttachmentFileSystem implements IAttachmentStore {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
attach.m_items.remove(index);
|
attach.m_items.remove(index);
|
||||||
attach.save(); // must save here as the operation cannot be rolled back on filesystem
|
attach.saveEx(); // must save here as the operation cannot be rolled back on filesystem
|
||||||
if (log.isLoggable(Level.CONFIG)) log.config("Index=" + index + " - NewSize=" + attach.m_items.size());
|
if (log.isLoggable(Level.CONFIG)) log.config("Index=" + index + " - NewSize=" + attach.m_items.size());
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
|
@ -127,7 +127,7 @@ public class MCalendar extends X_C_Calendar
|
||||||
if (get_ID() == 0)
|
if (get_ID() == 0)
|
||||||
return null;
|
return null;
|
||||||
MYear year = new MYear (this);
|
MYear year = new MYear (this);
|
||||||
if (year.save())
|
year.saveEx();
|
||||||
year.createStdPeriods(locale);
|
year.createStdPeriods(locale);
|
||||||
//
|
//
|
||||||
return year;
|
return year;
|
||||||
|
|
|
@ -94,7 +94,7 @@ public class MCash extends X_C_Cash implements DocAction
|
||||||
|
|
||||||
// Create New Journal
|
// Create New Journal
|
||||||
retValue = new MCash (cb, dateAcct);
|
retValue = new MCash (cb, dateAcct);
|
||||||
retValue.save(trxName);
|
retValue.saveEx(trxName);
|
||||||
return retValue;
|
return retValue;
|
||||||
} // get
|
} // get
|
||||||
|
|
||||||
|
|
|
@ -93,7 +93,7 @@ public class MContainer extends X_CM_Container
|
||||||
if (cc == null) // new
|
if (cc == null) // new
|
||||||
cc = new MContainer (stage.getCtx (), 0, stage.get_TrxName ());
|
cc = new MContainer (stage.getCtx (), 0, stage.get_TrxName ());
|
||||||
cc.setStage (project, stage, path);
|
cc.setStage (project, stage, path);
|
||||||
cc.save ();
|
cc.saveEx();
|
||||||
if (!stage.isSummary ())
|
if (!stage.isSummary ())
|
||||||
{
|
{
|
||||||
cc.updateElements (project, stage, stage.get_TrxName ());
|
cc.updateElements (project, stage, stage.get_TrxName ());
|
||||||
|
@ -315,7 +315,7 @@ public class MContainer extends X_CM_Container
|
||||||
// PO.copyValues(new
|
// PO.copyValues(new
|
||||||
// X_CM_CStage_Element(project.getCtx(),tableKeys[i],trxName),
|
// X_CM_CStage_Element(project.getCtx(),tableKeys[i],trxName),
|
||||||
// thisContainerElement);
|
// thisContainerElement);
|
||||||
thisContainerElement.save (trxName);
|
thisContainerElement.saveEx(trxName);
|
||||||
// Remove Container from cache
|
// Remove Container from cache
|
||||||
thisHandler.cleanContainerElement (thisContainerElement
|
thisHandler.cleanContainerElement (thisContainerElement
|
||||||
.get_ID ());
|
.get_ID ());
|
||||||
|
@ -391,7 +391,7 @@ public class MContainer extends X_CM_Container
|
||||||
thisContainerTTable.setCM_Container_ID (stage.get_ID ());
|
thisContainerTTable.setCM_Container_ID (stage.get_ID ());
|
||||||
PO.copyValues (new X_CM_CStageTTable (project.getCtx (),
|
PO.copyValues (new X_CM_CStageTTable (project.getCtx (),
|
||||||
tableKeys[i], trxName), thisContainerTTable);
|
tableKeys[i], trxName), thisContainerTTable);
|
||||||
thisContainerTTable.save (trxName);
|
thisContainerTTable.saveEx(trxName);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -295,7 +295,7 @@ public class MDunningRunEntry extends X_C_DunningRunEntry
|
||||||
thisBPartner.setSOCreditStatus (X_C_BPartner.SOCREDITSTATUS_CreditStop);
|
thisBPartner.setSOCreditStatus (X_C_BPartner.SOCREDITSTATUS_CreditStop);
|
||||||
if (level.isSetPaymentTerm ())
|
if (level.isSetPaymentTerm ())
|
||||||
thisBPartner.setC_PaymentTerm_ID (level.getC_PaymentTerm_ID ());
|
thisBPartner.setC_PaymentTerm_ID (level.getC_PaymentTerm_ID ());
|
||||||
thisBPartner.save ();
|
thisBPartner.saveEx();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
return true;
|
return true;
|
||||||
|
|
|
@ -132,7 +132,7 @@ public class MInOut extends X_M_InOut implements DocAction
|
||||||
}
|
}
|
||||||
// Create Line
|
// Create Line
|
||||||
if (retValue.get_ID() == 0) // not saved yet
|
if (retValue.get_ID() == 0) // not saved yet
|
||||||
retValue.save(trxName);
|
retValue.saveEx(trxName);
|
||||||
// Create a line until qty is reached
|
// Create a line until qty is reached
|
||||||
for (int ll = 0; ll < storages.length; ll++)
|
for (int ll = 0; ll < storages.length; ll++)
|
||||||
{
|
{
|
||||||
|
@ -148,11 +148,11 @@ public class MInOut extends X_M_InOut implements DocAction
|
||||||
.multiply(oLines[i].getQtyEntered())
|
.multiply(oLines[i].getQtyEntered())
|
||||||
.divide(oLines[i].getQtyOrdered(), 12, BigDecimal.ROUND_HALF_UP));
|
.divide(oLines[i].getQtyOrdered(), 12, BigDecimal.ROUND_HALF_UP));
|
||||||
line.setC_Project_ID(oLines[i].getC_Project_ID());
|
line.setC_Project_ID(oLines[i].getC_Project_ID());
|
||||||
line.save(trxName);
|
line.saveEx(trxName);
|
||||||
// Delivered everything ?
|
// Delivered everything ?
|
||||||
qty = qty.subtract(lineQty);
|
qty = qty.subtract(lineQty);
|
||||||
// storage[ll].changeQtyOnHand(lineQty, !order.isSOTrx()); // Credit Memo not considered
|
// storage[ll].changeQtyOnHand(lineQty, !order.isSOTrx()); // Credit Memo not considered
|
||||||
// storage[ll].save(get_TrxName());
|
// storage[ll].saveEx(get_TrxName());
|
||||||
if (qty.signum() == 0)
|
if (qty.signum() == 0)
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
|
@ -1581,7 +1581,7 @@ public class MInvoice extends X_C_Invoice implements DocAction
|
||||||
if (bom.getDescription() != null)
|
if (bom.getDescription() != null)
|
||||||
newLine.setDescription(bom.getDescription());
|
newLine.setDescription(bom.getDescription());
|
||||||
newLine.setPrice();
|
newLine.setPrice();
|
||||||
newLine.save(get_TrxName());
|
newLine.saveEx(get_TrxName());
|
||||||
}
|
}
|
||||||
|
|
||||||
// Convert into Comment Line
|
// Convert into Comment Line
|
||||||
|
@ -2506,8 +2506,7 @@ public class MInvoice extends X_C_Invoice implements DocAction
|
||||||
msgall.toString(),
|
msgall.toString(),
|
||||||
get_TrxName());
|
get_TrxName());
|
||||||
alloc.setAD_Org_ID(getAD_Org_ID());
|
alloc.setAD_Org_ID(getAD_Org_ID());
|
||||||
if (alloc.save())
|
alloc.saveEx();
|
||||||
{
|
|
||||||
// Amount
|
// Amount
|
||||||
BigDecimal gt = getGrandTotal(true);
|
BigDecimal gt = getGrandTotal(true);
|
||||||
if (!isSOTrx())
|
if (!isSOTrx())
|
||||||
|
@ -2527,7 +2526,6 @@ public class MInvoice extends X_C_Invoice implements DocAction
|
||||||
throw new AdempiereException("Failed when processing document - " + alloc.getProcessMsg());
|
throw new AdempiereException("Failed when processing document - " + alloc.getProcessMsg());
|
||||||
// end added
|
// end added
|
||||||
alloc.saveEx();
|
alloc.saveEx();
|
||||||
}
|
|
||||||
|
|
||||||
return reversal;
|
return reversal;
|
||||||
}
|
}
|
||||||
|
|
|
@ -522,7 +522,7 @@ public class MLdapProcessor extends X_AD_LdapProcessor implements AdempiereProce
|
||||||
access.setR_InterestArea_ID (R_InterestArea_ID);
|
access.setR_InterestArea_ID (R_InterestArea_ID);
|
||||||
access.setIsError (error != null);
|
access.setIsError (error != null);
|
||||||
access.setSummary (info);
|
access.setSummary (info);
|
||||||
access.save ();
|
access.saveEx();
|
||||||
} // logAccess
|
} // logAccess
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|
|
@ -72,7 +72,7 @@ public class MMovementConfirm extends X_M_MovementConfirm implements DocAction
|
||||||
}
|
}
|
||||||
|
|
||||||
MMovementConfirm confirm = new MMovementConfirm (move);
|
MMovementConfirm confirm = new MMovementConfirm (move);
|
||||||
confirm.save(move.get_TrxName());
|
confirm.saveEx(move.get_TrxName());
|
||||||
MMovementLine[] moveLines = move.getLines(false);
|
MMovementLine[] moveLines = move.getLines(false);
|
||||||
for (int i = 0; i < moveLines.length; i++)
|
for (int i = 0; i < moveLines.length; i++)
|
||||||
{
|
{
|
||||||
|
|
|
@ -1620,7 +1620,7 @@ public class MOrder extends X_C_Order implements DocAction
|
||||||
newLine.setDescription (bomline.getDescription ());
|
newLine.setDescription (bomline.getDescription ());
|
||||||
//
|
//
|
||||||
newLine.setPrice ();
|
newLine.setPrice ();
|
||||||
newLine.save (get_TrxName());
|
newLine.saveEx(get_TrxName());
|
||||||
}
|
}
|
||||||
} */
|
} */
|
||||||
|
|
||||||
|
@ -1633,7 +1633,7 @@ public class MOrder extends X_C_Order implements DocAction
|
||||||
if (bom.getDescription() != null)
|
if (bom.getDescription() != null)
|
||||||
newLine.setDescription(bom.getDescription());
|
newLine.setDescription(bom.getDescription());
|
||||||
newLine.setPrice();
|
newLine.setPrice();
|
||||||
newLine.save(get_TrxName());
|
newLine.saveEx(get_TrxName());
|
||||||
}
|
}
|
||||||
|
|
||||||
// Convert into Comment Line
|
// Convert into Comment Line
|
||||||
|
@ -1651,7 +1651,7 @@ public class MOrder extends X_C_Order implements DocAction
|
||||||
if (line.getDescription () != null)
|
if (line.getDescription () != null)
|
||||||
description += " " + line.getDescription ();
|
description += " " + line.getDescription ();
|
||||||
line.setDescription (description);
|
line.setDescription (description);
|
||||||
line.save (get_TrxName());
|
line.saveEx(get_TrxName());
|
||||||
} // for all lines with BOM
|
} // for all lines with BOM
|
||||||
|
|
||||||
m_lines = null; // force requery
|
m_lines = null; // force requery
|
||||||
|
|
|
@ -93,7 +93,7 @@ public class MPackage extends X_M_Package
|
||||||
} // lines
|
} // lines
|
||||||
|
|
||||||
retValue.setBoxCount(1);
|
retValue.setBoxCount(1);
|
||||||
retValue.save();
|
retValue.saveEx();
|
||||||
|
|
||||||
return retValue;
|
return retValue;
|
||||||
} // create
|
} // create
|
||||||
|
|
|
@ -248,7 +248,7 @@ public class MPaymentTerm extends X_C_PaymentTerm
|
||||||
for (int i = 0; i < m_schedule.length; i++)
|
for (int i = 0; i < m_schedule.length; i++)
|
||||||
{
|
{
|
||||||
ips = new MInvoicePaySchedule (invoice, m_schedule[i]);
|
ips = new MInvoicePaySchedule (invoice, m_schedule[i]);
|
||||||
ips.save(invoice.get_TrxName());
|
ips.saveEx(invoice.get_TrxName());
|
||||||
if (log.isLoggable(Level.FINE)) log.fine(ips.toString());
|
if (log.isLoggable(Level.FINE)) log.fine(ips.toString());
|
||||||
remainder = remainder.subtract(ips.getDueAmt());
|
remainder = remainder.subtract(ips.getDueAmt());
|
||||||
} // for all schedules
|
} // for all schedules
|
||||||
|
@ -256,7 +256,7 @@ public class MPaymentTerm extends X_C_PaymentTerm
|
||||||
if (remainder.compareTo(Env.ZERO) != 0 && ips != null)
|
if (remainder.compareTo(Env.ZERO) != 0 && ips != null)
|
||||||
{
|
{
|
||||||
ips.setDueAmt(ips.getDueAmt().add(remainder));
|
ips.setDueAmt(ips.getDueAmt().add(remainder));
|
||||||
ips.save(invoice.get_TrxName());
|
ips.saveEx(invoice.get_TrxName());
|
||||||
if (log.isLoggable(Level.FINE)) log.fine("Remainder=" + remainder + " - " + ips);
|
if (log.isLoggable(Level.FINE)) log.fine("Remainder=" + remainder + " - " + ips);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -357,7 +357,7 @@ public class MPaymentTerm extends X_C_PaymentTerm
|
||||||
for (int i = 0; i < m_schedule.length; i++)
|
for (int i = 0; i < m_schedule.length; i++)
|
||||||
{
|
{
|
||||||
ops = new MOrderPaySchedule (order, m_schedule[i]);
|
ops = new MOrderPaySchedule (order, m_schedule[i]);
|
||||||
ops.save(order.get_TrxName());
|
ops.saveEx(order.get_TrxName());
|
||||||
if (log.isLoggable(Level.FINE)) log.fine(ops.toString());
|
if (log.isLoggable(Level.FINE)) log.fine(ops.toString());
|
||||||
remainder = remainder.subtract(ops.getDueAmt());
|
remainder = remainder.subtract(ops.getDueAmt());
|
||||||
} // for all schedules
|
} // for all schedules
|
||||||
|
@ -365,7 +365,7 @@ public class MPaymentTerm extends X_C_PaymentTerm
|
||||||
if (remainder.compareTo(Env.ZERO) != 0 && ops != null)
|
if (remainder.compareTo(Env.ZERO) != 0 && ops != null)
|
||||||
{
|
{
|
||||||
ops.setDueAmt(ops.getDueAmt().add(remainder));
|
ops.setDueAmt(ops.getDueAmt().add(remainder));
|
||||||
ops.save(order.get_TrxName());
|
ops.saveEx(order.get_TrxName());
|
||||||
if (log.isLoggable(Level.FINE)) log.fine("Remainder=" + remainder + " - " + ops);
|
if (log.isLoggable(Level.FINE)) log.fine("Remainder=" + remainder + " - " + ops);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -741,7 +741,7 @@ public class MPeriod extends X_C_Period
|
||||||
if (baseTypes.contains(DocBaseType))
|
if (baseTypes.contains(DocBaseType))
|
||||||
continue;
|
continue;
|
||||||
MPeriodControl pc = new MPeriodControl(this, DocBaseType);
|
MPeriodControl pc = new MPeriodControl(this, DocBaseType);
|
||||||
if (pc.save())
|
pc.saveEx();
|
||||||
count++;
|
count++;
|
||||||
baseTypes.add (DocBaseType);
|
baseTypes.add (DocBaseType);
|
||||||
}
|
}
|
||||||
|
|
|
@ -358,15 +358,13 @@ public class MProject extends X_C_Project
|
||||||
toPhase.setC_Project_ID (getC_Project_ID ());
|
toPhase.setC_Project_ID (getC_Project_ID ());
|
||||||
toPhase.setC_Order_ID (0);
|
toPhase.setC_Order_ID (0);
|
||||||
toPhase.setIsComplete (false);
|
toPhase.setIsComplete (false);
|
||||||
if (toPhase.save ())
|
toPhase.saveEx();
|
||||||
{
|
|
||||||
count++;
|
count++;
|
||||||
taskCount += toPhase.copyTasksFrom (fromPhases[i]);
|
taskCount += toPhase.copyTasksFrom (fromPhases[i]);
|
||||||
//BF 3067850 - monhate
|
//BF 3067850 - monhate
|
||||||
lineCount += toPhase.copyLinesFrom(fromPhases[i]);
|
lineCount += toPhase.copyLinesFrom(fromPhases[i]);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
|
||||||
if (fromPhases.length != count)
|
if (fromPhases.length != count)
|
||||||
log.warning("Count difference - Project=" + fromPhases.length + " <> Saved=" + count);
|
log.warning("Count difference - Project=" + fromPhases.length + " <> Saved=" + count);
|
||||||
|
|
||||||
|
|
|
@ -159,7 +159,7 @@ public class MProjectPhase extends X_C_ProjectPhase
|
||||||
PO.copyValues (fromLines[i], toLine, getAD_Client_ID (), getAD_Org_ID ());
|
PO.copyValues (fromLines[i], toLine, getAD_Client_ID (), getAD_Org_ID ());
|
||||||
toLine.setC_Project_ID(getC_Project_ID ());
|
toLine.setC_Project_ID(getC_Project_ID ());
|
||||||
toLine.setC_ProjectPhase_ID (getC_ProjectPhase_ID ());
|
toLine.setC_ProjectPhase_ID (getC_ProjectPhase_ID ());
|
||||||
if (toLine.save ())
|
toLine.saveEx();
|
||||||
count++;
|
count++;
|
||||||
}
|
}
|
||||||
if (fromLines.length != count)
|
if (fromLines.length != count)
|
||||||
|
@ -209,13 +209,12 @@ public class MProjectPhase extends X_C_ProjectPhase
|
||||||
MProjectTask toTask = new MProjectTask (getCtx (), 0, get_TrxName());
|
MProjectTask toTask = new MProjectTask (getCtx (), 0, get_TrxName());
|
||||||
PO.copyValues (fromTasks[i], toTask, getAD_Client_ID (), getAD_Org_ID ());
|
PO.copyValues (fromTasks[i], toTask, getAD_Client_ID (), getAD_Org_ID ());
|
||||||
toTask.setC_ProjectPhase_ID (getC_ProjectPhase_ID ());
|
toTask.setC_ProjectPhase_ID (getC_ProjectPhase_ID ());
|
||||||
if (toTask.save ()){
|
toTask.saveEx();
|
||||||
count++;
|
count++;
|
||||||
//BF 3067850 - monhate
|
//BF 3067850 - monhate
|
||||||
countLine += toTask.copyLinesFrom(fromTasks[i]);
|
countLine += toTask.copyLinesFrom(fromTasks[i]);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
|
||||||
if (fromTasks.length != count)
|
if (fromTasks.length != count)
|
||||||
log.warning("Count difference - ProjectPhase=" + fromTasks.length + " <> Saved=" + count);
|
log.warning("Count difference - ProjectPhase=" + fromTasks.length + " <> Saved=" + count);
|
||||||
|
|
||||||
|
|
|
@ -134,7 +134,7 @@ public class MProjectTask extends X_C_ProjectTask
|
||||||
toLine.setC_Project_ID(getC_Project_ID(false));
|
toLine.setC_Project_ID(getC_Project_ID(false));
|
||||||
toLine.setC_ProjectPhase_ID (getC_ProjectPhase_ID ());
|
toLine.setC_ProjectPhase_ID (getC_ProjectPhase_ID ());
|
||||||
toLine.setC_ProjectTask_ID(getC_ProjectTask_ID ());
|
toLine.setC_ProjectTask_ID(getC_ProjectTask_ID ());
|
||||||
if (toLine.save ())
|
toLine.saveEx();
|
||||||
count++;
|
count++;
|
||||||
}
|
}
|
||||||
if (fromLines.length != count)
|
if (fromLines.length != count)
|
||||||
|
|
|
@ -466,7 +466,7 @@ public class WebLogin
|
||||||
thisBPBankAccount.setA_Name (WebUtil.getParamOrNull (m_request, "A_Name"));
|
thisBPBankAccount.setA_Name (WebUtil.getParamOrNull (m_request, "A_Name"));
|
||||||
thisBPBankAccount.setAccountNo (WebUtil.getParamOrNull (m_request, "AccountNo"));
|
thisBPBankAccount.setAccountNo (WebUtil.getParamOrNull (m_request, "AccountNo"));
|
||||||
thisBPBankAccount.setRoutingNo (WebUtil.getParamOrNull (m_request, "RoutingNo"));
|
thisBPBankAccount.setRoutingNo (WebUtil.getParamOrNull (m_request, "RoutingNo"));
|
||||||
thisBPBankAccount.save ();
|
thisBPBankAccount.saveEx();
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
log.log(Level.WARNING, "Unknown request='" + m_mode + "'");
|
log.log(Level.WARNING, "Unknown request='" + m_mode + "'");
|
||||||
|
|
|
@ -488,7 +488,7 @@ public class WebUser
|
||||||
|
|
||||||
// save Location ***************************************
|
// save Location ***************************************
|
||||||
if (log.isLoggable(Level.FINE)) log.fine("LOC=" + m_loc);
|
if (log.isLoggable(Level.FINE)) log.fine("LOC=" + m_loc);
|
||||||
m_loc.save ();
|
m_loc.saveEx();
|
||||||
|
|
||||||
// save BP Location ***************************************
|
// save BP Location ***************************************
|
||||||
if (m_bpl.getC_BPartner_ID () != m_bp.getC_BPartner_ID())
|
if (m_bpl.getC_BPartner_ID () != m_bp.getC_BPartner_ID())
|
||||||
|
|
|
@ -253,7 +253,7 @@ public class ImportFixedAsset extends SvrProcess
|
||||||
if (!bpl.save ())
|
if (!bpl.save ())
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
ifa.save ();
|
ifa.saveEx();
|
||||||
} // for all new BPartners
|
} // for all new BPartners
|
||||||
rs.close ();
|
rs.close ();
|
||||||
pstmt.close ();
|
pstmt.close ();
|
||||||
|
@ -311,7 +311,7 @@ public class ImportFixedAsset extends SvrProcess
|
||||||
}
|
}
|
||||||
ifa.setM_Product_ID (product.getM_Product_ID());
|
ifa.setM_Product_ID (product.getM_Product_ID());
|
||||||
|
|
||||||
ifa.save ();
|
ifa.saveEx();
|
||||||
} // for all new Products
|
} // for all new Products
|
||||||
rs.close ();
|
rs.close ();
|
||||||
pstmt.close ();
|
pstmt.close ();
|
||||||
|
|
|
@ -746,7 +746,7 @@ public class VPAttributeDialog extends CDialog
|
||||||
// New Instance
|
// New Instance
|
||||||
if (m_changed || m_masi.getM_AttributeSetInstance_ID() == 0)
|
if (m_changed || m_masi.getM_AttributeSetInstance_ID() == 0)
|
||||||
{
|
{
|
||||||
m_masi.save ();
|
m_masi.saveEx();
|
||||||
m_M_AttributeSetInstance_ID = m_masi.getM_AttributeSetInstance_ID ();
|
m_M_AttributeSetInstance_ID = m_masi.getM_AttributeSetInstance_ID ();
|
||||||
m_M_AttributeSetInstanceName = m_masi.getDescription();
|
m_M_AttributeSetInstanceName = m_masi.getDescription();
|
||||||
}
|
}
|
||||||
|
@ -789,7 +789,7 @@ public class VPAttributeDialog extends CDialog
|
||||||
if (m_changed)
|
if (m_changed)
|
||||||
{
|
{
|
||||||
m_masi.setDescription ();
|
m_masi.setDescription ();
|
||||||
m_masi.save ();
|
m_masi.saveEx();
|
||||||
}
|
}
|
||||||
m_M_AttributeSetInstance_ID = m_masi.getM_AttributeSetInstance_ID ();
|
m_M_AttributeSetInstance_ID = m_masi.getM_AttributeSetInstance_ID ();
|
||||||
m_M_AttributeSetInstanceName = m_masi.getDescription();
|
m_M_AttributeSetInstanceName = m_masi.getDescription();
|
||||||
|
|
|
@ -245,7 +245,7 @@ public class DunningPrint extends SvrProcess
|
||||||
if (printed)
|
if (printed)
|
||||||
{
|
{
|
||||||
entry.setProcessed (true);
|
entry.setProcessed (true);
|
||||||
entry.save ();
|
entry.saveEx();
|
||||||
}
|
}
|
||||||
|
|
||||||
} // for all dunning letters
|
} // for all dunning letters
|
||||||
|
|
|
@ -979,7 +979,7 @@ public class WPAttributeDialog extends Window implements EventListener<Event>
|
||||||
// New Instance
|
// New Instance
|
||||||
if (m_changed || m_masi.getM_AttributeSetInstance_ID() == 0)
|
if (m_changed || m_masi.getM_AttributeSetInstance_ID() == 0)
|
||||||
{
|
{
|
||||||
m_masi.save ();
|
m_masi.saveEx();
|
||||||
m_M_AttributeSetInstance_ID = m_masi.getM_AttributeSetInstance_ID ();
|
m_M_AttributeSetInstance_ID = m_masi.getM_AttributeSetInstance_ID ();
|
||||||
m_M_AttributeSetInstanceName = m_masi.getDescription();
|
m_M_AttributeSetInstanceName = m_masi.getDescription();
|
||||||
}
|
}
|
||||||
|
@ -1026,7 +1026,7 @@ public class WPAttributeDialog extends Window implements EventListener<Event>
|
||||||
if (m_changed)
|
if (m_changed)
|
||||||
{
|
{
|
||||||
m_masi.setDescription ();
|
m_masi.setDescription ();
|
||||||
m_masi.save ();
|
m_masi.saveEx();
|
||||||
}
|
}
|
||||||
m_M_AttributeSetInstance_ID = m_masi.getM_AttributeSetInstance_ID ();
|
m_M_AttributeSetInstance_ID = m_masi.getM_AttributeSetInstance_ID ();
|
||||||
m_M_AttributeSetInstanceName = m_masi.getDescription();
|
m_M_AttributeSetInstanceName = m_masi.getDescription();
|
||||||
|
|
|
@ -810,7 +810,7 @@ public class Allocation
|
||||||
}
|
}
|
||||||
MBPartner bpartner = new MBPartner(Env.getCtx(), m_C_BPartner_ID, trxName);
|
MBPartner bpartner = new MBPartner(Env.getCtx(), m_C_BPartner_ID, trxName);
|
||||||
bpartner.setTotalOpenBalance();
|
bpartner.setTotalOpenBalance();
|
||||||
bpartner.save();
|
bpartner.saveEx();
|
||||||
paymentList.clear();
|
paymentList.clear();
|
||||||
amountList.clear();
|
amountList.clear();
|
||||||
|
|
||||||
|
|
|
@ -323,7 +323,7 @@ public class AssetServlet extends HttpServlet
|
||||||
if (msg.length () > 120)
|
if (msg.length () > 120)
|
||||||
msg = msg.substring (0, 119);
|
msg = msg.substring (0, 119);
|
||||||
ad.setDeliveryConfirmation (msg);
|
ad.setDeliveryConfirmation (msg);
|
||||||
ad.save ();
|
ad.saveEx();
|
||||||
// asset.saveEx(); not delivered
|
// asset.saveEx(); not delivered
|
||||||
}
|
}
|
||||||
catch (Exception ex1)
|
catch (Exception ex1)
|
||||||
|
|
|
@ -294,7 +294,7 @@ public class PaymentServlet extends HttpServlet
|
||||||
{
|
{
|
||||||
if (log.isLoggable(Level.FINE)) log.fine(payment.getErrorMessage());
|
if (log.isLoggable(Level.FINE)) log.fine(payment.getErrorMessage());
|
||||||
String errMsg = payment.getErrorMessage();
|
String errMsg = payment.getErrorMessage();
|
||||||
payment.save ();
|
payment.saveEx();
|
||||||
payment.setErrorMessage(errMsg);
|
payment.setErrorMessage(errMsg);
|
||||||
request.getSession().setAttribute(WebSessionCtx.HDR_MESSAGE, errMsg);
|
request.getSession().setAttribute(WebSessionCtx.HDR_MESSAGE, errMsg);
|
||||||
//
|
//
|
||||||
|
|
Loading…
Reference in New Issue