mirror of
https://github.com/Gnucash/gnucash.git
synced 2025-02-25 18:55:30 -06:00
Bug 798565 - Import map editor entry deletion
When a top level bayesian entry is deleted, the book is not marked dirty and so the save button is not highlighted. Deleting individual entries did mark book dirty. Fixed in gnc_account_delete_all_bayes_maps by wrapping the deletion with xaccAccountBeginEdit/CommitEdit block.
This commit is contained in:
parent
0a8dcdcd81
commit
ce4768c357
@ -6101,10 +6101,13 @@ gnc_account_delete_all_bayes_maps (Account *acc)
|
|||||||
{
|
{
|
||||||
auto slots = qof_instance_get_slots_prefix (QOF_INSTANCE (acc), IMAP_FRAME_BAYES);
|
auto slots = qof_instance_get_slots_prefix (QOF_INSTANCE (acc), IMAP_FRAME_BAYES);
|
||||||
if (!slots.size()) return;
|
if (!slots.size()) return;
|
||||||
|
xaccAccountBeginEdit (acc);
|
||||||
for (auto const & entry : slots)
|
for (auto const & entry : slots)
|
||||||
{
|
{
|
||||||
qof_instance_slot_path_delete (QOF_INSTANCE (acc), {entry.first});
|
qof_instance_slot_path_delete (QOF_INSTANCE (acc), {entry.first});
|
||||||
}
|
}
|
||||||
|
qof_instance_set_dirty (QOF_INSTANCE(acc));
|
||||||
|
xaccAccountCommitEdit (acc);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user