Skip to content

Commit

Permalink
ground postDate
Browse files Browse the repository at this point in the history
postDate granularity is 'date' (not timestamp). This should be handled
automatically by the database, but in situations where the column is a
timestamp instead of just date, we want to make sure we have the same
time (00:00:00).
  • Loading branch information
ar committed Aug 30, 2022
1 parent 7168a1b commit 357b836
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion modules/minigl/src/main/java/org/jpos/gl/GLSession.java
Original file line number Diff line number Diff line change
Expand Up @@ -627,7 +627,7 @@ public void post (Journal journal, GLTransaction txn)
txn.setJournal (journal);
txn.setTimestamp (new Date());
if (txn.getPostDate() == null)
txn.setPostDate (txn.getTimestamp());
txn.setPostDate (Util.floor(txn.getTimestamp()));
else
invalidateCheckpoints (txn);
Collection rules = getRules (txn);
Expand Down

0 comments on commit 357b836

Please sign in to comment.