IDEMPIERE-3874 Process Recalculate Cube not loading GL journal facts due to c_calendar_id
This commit is contained in:
parent
0a9d7335de
commit
eb82017e1e
|
@ -121,16 +121,12 @@ public class CalloutGLJournal extends CalloutEngine
|
|||
rs = pstmt.executeQuery();
|
||||
if (rs.next())
|
||||
{
|
||||
String PeriodType = rs.getString(1);
|
||||
Timestamp StartDate = rs.getTimestamp(2);
|
||||
Timestamp EndDate = rs.getTimestamp(3);
|
||||
if (PeriodType.equals("S")) // Standard Periods
|
||||
{
|
||||
// out of range - set to last day
|
||||
if (DateAcct == null
|
||||
|| DateAcct.before(StartDate) || DateAcct.after(EndDate))
|
||||
mTab.setValue("DateAcct", EndDate);
|
||||
}
|
||||
// out of range - set to last day
|
||||
if (DateAcct == null
|
||||
|| DateAcct.before(StartDate) || DateAcct.after(EndDate))
|
||||
mTab.setValue("DateAcct", EndDate);
|
||||
}
|
||||
}
|
||||
catch (SQLException e)
|
||||
|
|
|
@ -322,7 +322,10 @@ public class MJournal extends X_GL_Journal implements DocAction
|
|||
}
|
||||
else if (C_Period_ID != getC_Period_ID())
|
||||
{
|
||||
setC_Period_ID(C_Period_ID);
|
||||
/* special case when assigning an adjustment period */
|
||||
MPeriod currentPeriod = MPeriod.get(getCtx(), getC_Period_ID());
|
||||
if (currentPeriod.isStandardPeriod())
|
||||
setC_Period_ID(C_Period_ID);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -954,7 +954,10 @@ public class MJournalBatch extends X_GL_JournalBatch implements DocAction
|
|||
}
|
||||
else if (C_Period_ID != getC_Period_ID())
|
||||
{
|
||||
setC_Period_ID(C_Period_ID);
|
||||
/* special case when assigning an adjustment period */
|
||||
MPeriod currentPeriod = MPeriod.get(getCtx(), getC_Period_ID());
|
||||
if (currentPeriod.isStandardPeriod())
|
||||
setC_Period_ID(C_Period_ID);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue