diff options
author | Craig Earls <enderw88@gmail.com> | 2013-02-13 09:36:44 -0700 |
---|---|---|
committer | Craig Earls <enderw88@gmail.com> | 2013-02-13 09:36:44 -0700 |
commit | db9ae7dd042ecc49c2390b19a0670029cdb4e5fe (patch) | |
tree | 184356be01806fd59c142f46509fa2b949b61d97 | |
parent | a13bcd4109711ea756727c6e8a00a262ad220dae (diff) | |
download | fork-ledger-db9ae7dd042ecc49c2390b19a0670029cdb4e5fe.tar.gz fork-ledger-db9ae7dd042ecc49c2390b19a0670029cdb4e5fe.tar.bz2 fork-ledger-db9ae7dd042ecc49c2390b19a0670029cdb4e5fe.zip |
Fixes workflow for using toggle-pending with clear-whole-transactions
-rw-r--r-- | lisp/ldg-reconcile.el | 5 | ||||
-rw-r--r-- | lisp/ldg-state.el | 13 |
2 files changed, 12 insertions, 6 deletions
diff --git a/lisp/ldg-reconcile.el b/lisp/ldg-reconcile.el index 25d2e981..cae27a01 100644 --- a/lisp/ldg-reconcile.el +++ b/lisp/ldg-reconcile.el @@ -83,7 +83,6 @@ (defun ledger-reconcile-toggle () (interactive) (let ((where (get-text-property (point) 'where)) - (account ledger-acct) (inhibit-read-only t) status) (when (ledger-reconcile-get-buffer where) @@ -173,7 +172,9 @@ (ledger-display-balance)) (defun ledger-reconcile-finish () - "Mark all pending transactions as cleared, save the buffers and exit reconcile mode" + "Mark all pending posting or transactions as cleared, depending + on ledger-reconcile-clear-whole-transactions, save the buffers + and exit reconcile mode" (interactive) (save-excursion (goto-char (point-min)) diff --git a/lisp/ldg-state.el b/lisp/ldg-state.el index 1ede3312..fad7d71c 100644 --- a/lisp/ldg-state.el +++ b/lisp/ldg-state.el @@ -219,11 +219,16 @@ dropped." (progn (delete-char 1) (if (and style (eq style 'cleared)) - (insert " *"))) + (progn + (insert " *") + (setq status 'cleared)))) (if (and style (eq style 'pending)) - (insert " ! ") - (insert " * ")) - (setq status t)))) + (progn + (insert " ! ") + (setq status 'pending)) + (progn + (insert " * ") + (setq status 'cleared)))))) status)) (provide 'ldg-state) |