Commit Graph

21871 Commits

Author SHA1 Message Date
Geert Janssens
0131780b30 Add guile function to extract a lot's guid
Useful for debugging lot issues in reports.
2020-01-29 18:55:35 +08:00
Christopher Lam
00d00a4650 [report-utilities] fix overpayments calc
overpayment is lot->balance rather than split->amount.
2020-01-29 18:55:35 +08:00
Frank H. Ellenberger
3fd7f19f62 Merge branch 'PR609' into maint 2020-01-29 08:33:28 +01:00
Christopher Lam
e6b3c56568 [report-utilities] add gnc:dump-lot 2020-01-26 12:26:27 +08:00
Christopher Lam
88bfc8b477 [new-owner-report] refine payment->description
LHS payment description are memos from APAR splits
RHS payment description are memos from non-APAR splits
RHS payment description should match RHS payment amounts
2020-01-26 08:53:29 +08:00
Christopher Lam
3f324952d4 [new-owner-report] add interactivity to highlight linked rows
add javascript to highlight matching documents/payments via their
common link-id attribute.
2020-01-26 08:53:29 +08:00
Christopher Lam
5de18cf101 [new-owner-report] add invoice/txn link-id to tag via javascript
This commit adds a link-id attribute to describe <td> elements
containing invoice & payment details. Each link-id is the invoice or
transaction guid.
2020-01-26 08:53:29 +08:00
Christopher Lam
6ab936af1f [new-owner-report] LHS payments have no invoice details. remove code.
a previous commit had split LHS invoice vs payment handling. remove
invoice handling code in the payment section.
2020-01-26 08:53:29 +08:00
Christopher Lam
91b3c8cf3a [new-owner-report] LHS handle split->anchor differently
remove cell-anchor from add-row
no functional change
2020-01-26 08:53:29 +08:00
Christopher Lam
a9be5d406f [new-owner-report] compact code
* reuse split->anchor for RHS splits
* use invoice->anchor for invoice anchor
2020-01-26 08:53:29 +08:00
Christopher Lam
4839a56367 [new-owner-report] RHS invoice amount links to invoice posting
RHS invoice amounts links to the APAR posting split instead of a APAR
payment split.
2020-01-26 08:53:05 +08:00
Robert Fewell
ffe3aa792c Bug 797522 - Focus after reconcile jumps to a different account
After the use of the reconcile window, the keyboard focus may not be
on the current account register. This is due to the call for a gui
refresh which refreshes the pages in reverse qofinstance order and as
part of this there is a call to grab the keyboard focus on the register
sheet so the last one will have the keyboard focus which may not be the
current register, just depends on the order of creation.

To fix this, as part of the main window page changed callback a flag is
set on the current sheet to indicate it can grab the focus on refresh.
2020-01-25 12:03:37 +00:00
Robert Fewell
94cb96501e Change the way the focus is added to plugin_pages
This change corrects a previous commit and makes all the plugin_pages
follow the same format. In the previous commit a test was made for the
plugin_page to be equal to one returned from get_current_page which
would always be the case. With this change the respective plugin_page
is passed as a parameter to the 'page_changed' call back and it is this
that is tested against the current plugin_page.
2020-01-25 12:03:37 +00:00
Robert Fewell
7ee3f43037 Bug 797566 - Crash on use of context menu in importer
If the context menu key is used on the "Assign transfer account page"
the application will crash. This was down to the call back function
gnc_gen_trans_onPopupMenu_cb being defined with a second parameter of
GdkEvent but it should not have, removing this fixes the bug.
2020-01-25 12:03:37 +00:00
Christopher Lam
a9d51dd9e3 [new-owner-report] RHS invoice amount links APAR instead of transfer
because invoices can have more than 1 non-APAR split.
2020-01-24 22:58:06 +08:00
Christopher Lam
d91a9512a4 [new-owner-report] RHS payments with >1 non-APAR splits all shown
Payments by default have 1 non-APAR split. But UI allows modification
to multiple non-APAR splits. Render each in different line.
2020-01-24 22:34:34 +08:00
Christopher Lam
a01bfa6843 [new-owner-report] RHS partial amount/amount separated
RHS partial-amount and amount are shown in separate cells.

also modify test-owner-report.scm to allow pass

the $2.00 is strictly a RHS amount but I'm not sure how to exclude it
using sxpath.
2020-01-24 20:29:45 +08:00
Christopher Lam
8e34a7999d [new-owner-report] LHS invoice->RHS payments show partial amounts 2020-01-24 20:29:38 +08:00
Christopher Lam
cbb7431752 [new-owner-report] LHS payment->RHS invoices show partial amounts 2020-01-24 20:29:09 +08:00
Christopher Lam
3866d9bb7c [new-owner-report] refactor. separate LHS inv/pmt processing.
1. handle accumulation of totals and printing of balance-b/f row
earlier
2. separate LHS processing into invoice and payment.
2020-01-24 07:03:53 +08:00
Geert Janssens
a033b7b1e9 Merge branch 'bugs_ibi' of https://github.com/ekinonnakapito/gnucash into maint 2020-01-23 18:50:09 +01:00
Geert Janssens
ad612c482b Merge branch 'maint' of https://github.com/loftx/gnucash into maint 2020-01-23 15:34:11 +01:00
Geert Janssens
4537c1de36 Bug 794916 - Fails to find environment file at startup when installation prefix is '/opt'
Update on this bug. Before doing the binreloc dance on various
paths check if the calculated dynamic prefix is still the same
as the compile time PREFIX. If so, just stick with the compile
time path names as this means the application wasn't relocated
anyway. Only if the dynamic prefix is different, try to
recalculate the requested paths relative to the dynamic
prefix.
Together with the configure time fix to detect /etc/opt is
outside of the /opt prefix, this eliminates the need for further
special case handling of the sysconfig directory so that
special case handling is removed.
2020-01-22 22:40:11 +01:00
Geert Janssens
031d805bb2 Fix binreloc test for all install paths inside prefix
The FHS standard rules for a /opt based prefix sets a sysconfig dir to
/etc/opt/... which is outside of /opt. This was however not detected
properly. It now is.
2020-01-22 22:05:20 +01:00
Christopher Lam
93ff991b31 [new-aging] speedup/cleanup. delay txn type filtering of splits
APAR splits were filtered to exclude invalid txn types. Omit
filtering, and skip (and log) invalid txn types during each account
splits loop.
2020-01-22 21:51:24 +08:00
Christopher Lam
c29409f45a Bug 797591 - multiperiod b/s and PnL reports: add style sheet 'easy'
Change headers & subtotals row markup to "primary-subheading".
2020-01-22 19:58:21 +08:00
gnucash-dev
24b46b1c36 Update US Income Tax information for 2019. 2020-01-20 17:28:49 -08:00
loftx
7cd2495674 Add Invoice.Unpost() to Python Bindings 2020-01-20 20:26:53 +01:00
John Ralls
e51bc45e58 Bug 797588 - Gnucash segfaults when using mysql backend with empty password
Log an error and return if any of the required string elements is NULL.
2020-01-19 14:05:21 -08:00
John Ralls
08fd3e9797 Fix up indentation in gnc-keyring.c.
It was partly gnu-style.
2020-01-19 14:03:17 -08:00
Robert Fewell
2c45e0ecba The clear cached account model should be after the test
for book and root account
2020-01-19 13:26:02 +00:00
Robert Fewell
253707e199 Fix some account template issues 2020-01-19 13:25:03 +00:00
Christopher Lam
b9601e012c Bug 797584 - New-owner - bill amount field links to wrong account
Amounts formerly linked to the 'transfer' split which is not reliably
determined. Link to the APAR split instead.

Note whereby a payment spans multiple invoices, it'll link to the
first APAR payment split.
2020-01-19 09:24:24 +08:00
Christopher Lam
220eb95291 [new-aging] speed up by skipping several loops
Consider a list of APAR splits, from N accounts. For each account,
their splits needed to find unique valid owners.

Previous algorithm would loops splits several times (1) each split
finds its owner, and log invalid ones, and (2) delete owner
duplicates.

New algorithm will take the first split's owner, skip if invalid, then
process all owner-splits, the reloop with other-owners-splits. The
invalid-splits list is also managed within loops for better stack
handling.

Also use (ice-9 match) for conciseness.
2020-01-19 09:24:24 +08:00
Christopher Lam
e788480e34 [new-aging] replace split->lot->split->lot with split->lot
remove unnecessary call to get earliest-split
2020-01-19 09:23:57 +08:00
Geert Janssens
073e47801d Drop useless ifdefs
The parameter it checks is always defined these days
2020-01-17 18:25:43 +01:00
Geert Janssens
d8a304c2c9 Housekeeping - reduce the number of PACKAGE and VERSION related cmake variables
This starts by setting the gnucash version number in the 'project' call.
This will result in a number of variables set by cmake. The remainder
of this commit is to reuse the auto-generated
PROJECT_NAME, PROJECT_VERSION, PROJECT_VERSION_MAJOR
PROJECT_VERSION_MINOR, PROJECT_VERSION_PATCH and PROJECT_VERSION_TWEAK
instead of all the various instances of PACKAGE, GNUCASH_MAJOR_VERSION
and so on.

One parameter is worth mentioning - GETTEXT_PACKAGE
GnuCash is not using this directly (any more) but it has to be set before
including gi18n-lib.h.
2020-01-17 18:15:27 +01:00
Mike Alexander
aa961846c6 Remove the old XCode project. It is obsolete and CMake can create one 2020-01-17 01:32:42 -05:00
Geert Janssens
e91e84e7ed Bug 797569 - Swedish account templates not accessible
Turned out to be a bug introduced by our port to cmake.
The Windows special casing for Swedish account hierarchies
was never called at all.
This fix includes a fix for a const correctness compiler warning as well.
2020-01-15 16:23:47 +01:00
Christopher Lam
8618c25d50 Bug 797572 - part 2 - swap Debits/Credits, can show informal headers
Previously Credits was rendered before Debits. Change to formal
accounting convention. Can swap to informal headers if set by global
preference.
2020-01-15 19:04:46 +08:00
Christopher Lam
1dac9e1fc2 Bug 797572 - part 1 - don't accumulate Dr/Cr totals unless printed 2020-01-15 18:25:23 +08:00
Christopher Lam
c4ab772d4b Bug 797576 - xaccAccountOrder shouldn't sort account codes as base-36
Thanks to yegor for discovering it is unreliable for sorting. It has
been present since 50646f04
2020-01-15 18:25:16 +08:00
Christopher Lam
3db699786f [core-utils.i] declare prefs as ENUMs 2020-01-15 18:04:35 +08:00
Geert Janssens
08d685f4aa Define SET_ENUM in core-utils.i as well
Will be used to expose our settings related constants to guile
2020-01-15 09:29:27 +01:00
Christopher Lam
5ac7f1beaf Bug 797573 - Incorrect value of securities in the Asset Chart
Algorithms used xaccFooOrder to attempt strict ordering of Foo
objects. Unfortunately the internal definitions of xaccAccountOrder
does not guarantee a strict ordering of accounts.

Also remove unused split<? comparator.
2020-01-15 06:32:38 +08:00
Frank H. Ellenberger
d61453d3cf L12N:sv_AX Add Windows' name "Swedish_Åland Islands"
Patch from Bug 725296, but in theory it had better fit in Bug 797569.
2020-01-14 21:21:48 +01:00
Geert Janssens
826c826cc1 Bug 797569 - Swedish account templates not accessible
If environment variable LANG is set to 'Swedish_Sweden' (to work around a gettext bug
affecting Swedish locales) the wrong unix locale was substituted previnting
gnucash from finding the associated account hierarchy templates.
2020-01-13 22:25:36 +01:00
Christopher Lam
ead5c94787 Bug 797548 - multicolumn income statement: some closing entries are not ignored when within reporting period
Remove closing-entries substring/regex filter.

We will rely on the closing flag created with the Tools>Close Book
tool. This means very *old* closing entries will need to be re-done
via Tools>Close Book using the same date as the old closing entries.
2020-01-12 22:04:47 +08:00
Christopher Lam
fd24b01689 [new-aging] reuse string 2020-01-12 21:19:42 +08:00
Christopher Lam
6aff6e15f0 [new-aging] reinstate sort-by choices
- offer choices for sorting owners in each APAR list
- may be useful for ordering customer aging debts
- this means we remove the default owner->name sorting
2020-01-12 21:19:12 +08:00