mirror of
https://github.com/Gnucash/gnucash.git
synced 2025-02-25 18:55:30 -06:00
Register (old+new): Duplicated transactions need a DateEntered as well.
git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@23046 57a11ea4-9604-0410-9ed3-97b8803252fd
This commit is contained in:
parent
85749ec058
commit
bae4862575
@ -1352,6 +1352,10 @@ gnc_tree_control_split_reg_duplicate_current (GncTreeViewSplitReg *view)
|
||||
|
||||
xaccTransSetDatePostedSecsNormalized (new_trans, date);
|
||||
|
||||
/* We also must set a new DateEntered on the new entry
|
||||
* because otherwise the ordering is not deterministic */
|
||||
xaccTransSetDateEnteredSecs(new_trans, gnc_time(NULL));
|
||||
|
||||
/* set per book option */
|
||||
gnc_set_num_action (new_trans, NULL, out_num, out_tnum);
|
||||
|
||||
|
@ -1453,6 +1453,9 @@ create_balancing_transaction(QofBook *book, Account *account,
|
||||
xaccTransSetCurrency(trans, xaccAccountGetCommodity(account));
|
||||
xaccTransSetDatePostedSecsNormalized(trans, statement_date);
|
||||
xaccTransSetDescription(trans, _("Balancing entry from reconcilation"));
|
||||
/* We also must set a new DateEntered on the new entry
|
||||
* because otherwise the ordering is not deterministic */
|
||||
xaccTransSetDateEnteredSecs(trans, gnc_time(NULL));
|
||||
|
||||
// 1. Split
|
||||
split = xaccMallocSplit(book);
|
||||
|
@ -634,6 +634,10 @@ gnc_split_register_duplicate_current (SplitRegister *reg)
|
||||
xaccTransBeginEdit (new_trans);
|
||||
gnc_copy_trans_onto_trans (trans, new_trans, FALSE, FALSE);
|
||||
xaccTransSetDatePostedSecsNormalized (new_trans, date);
|
||||
/* We also must set a new DateEntered on the new entry
|
||||
* because otherwise the ordering is not deterministic */
|
||||
xaccTransSetDateEnteredSecs(new_trans, gnc_time(NULL));
|
||||
|
||||
/* set per book option */
|
||||
gnc_set_num_action (new_trans, NULL, out_num, out_tnum);
|
||||
if (!reg->use_tran_num_for_num_field)
|
||||
|
Loading…
Reference in New Issue
Block a user