Commit Graph

20217 Commits

Author SHA1 Message Date
John Ralls
93f3a8ea82 Fix build of jenny.c on 32-bit builds, mingw-w64. 2018-08-23 11:49:49 -07:00
Robert Fewell
3456596a1c Bug 796814 - Changing a book's read-only threshold doesn't immediately affect open registers
Add test for change of read-only threshold to helper function for the
gnc_book_options_dialog_apply_cb which will then do a gui refresh.
2018-08-22 20:40:17 +01:00
Robert Fewell
67ee1d99a4 Bug 796812 - gnc_date_cell_get_date and gnc_date_cell_get_date_gdate have different date validation behaviour - part 2
Change the two register get_help functions to use gnc_date_cell_get_date
with the warn parameter FALSE, this way we only get one warning when the
date is out of range.

Also as no functions use gnc_date_cell_get_date_gdate it can be removed.
2018-08-22 20:38:36 +01:00
Robert Fewell
aabae1caf9 Bug 796812 - gnc_date_cell_get_date and gnc_date_cell_get_date_gdate have different date validation behaviour - part 1
Add gboolean parameter to gnc_date_cell_get_date to enable warning for
the date out of range dialogue and update every occurrence accordingly.
2018-08-22 20:36:51 +01:00
Robert Fewell
dd49756f4e Bug 796813 - Date validation inconsistent
Change gnc_split_register_save_date_cell function and the equivalent one
 in gncEntryLedgerModel to use time64 version of gnc_date_cell_get_date
which includes the warning for dates out of range.
2018-08-22 20:35:54 +01:00
Robert Fewell
4a3c6f8f85 Change saving to .gcm and Kvp for GNC_FEATURE_REG_SORT_FILTER
For the LD_GL save the filter and sort settings to the .gcm always.
For the rest, keep saving the filter and sort settings to kvp only
when the GNC_FEATURE_REG_SORT_FILTER is not set, if set then save
only to the .gcm file. This will be set on first use in version
4.0 where a conversion will be run to only use the .gcm meta file.
2018-08-19 16:06:17 +01:00
Robert Fewell
995e6b0f95 White space and tabs changed in search-date.c 2018-08-19 11:59:25 +01:00
Robert Fewell
39b24325d9 Bug 796725 - 4 of 6 Date Posted options fail to return
matching transactions.

gnc_date_edit_get_date returns the time64 value set to 00:00:00 for the
day entered so for the LTE and GT options gnc_date_edit_get_date_end
needs to be used for 23:59:59. For finding transactions on the date,
the use of QOF_DATE_MATCH_DAY needs to be used.
2018-08-19 11:55:43 +01:00
Geert Janssens
54a5097c60 Bug 796777 - CVE-2008-1391: Integer overflow in included strfmon function
We only used strfmon in one source file to generate three fixed format
strings. Instead of updating to a newer strfmon in borrowed I have
chosen to reimplement the string formatters for these strings in C++.
Note this is *not* a full c++ conversion of the full functionality
of assistant-loan. Only the string parsing has been redone.
2018-08-17 16:23:12 +02:00
Geert Janssens
34cb4925a4 Compile assistant-loan as c++
Fix only c++ compatibility issues, which primarily boils down
to dealing with stricter type checking.
2018-08-17 16:23:12 +02:00
Robert Fewell
6ba47846c0 Improve the generation of the filter text 2018-08-17 11:31:25 +01:00
Robert Fewell
a650693d07 New feature for register sort/filter settings move. 2018-08-17 11:31:25 +01:00
Robert Fewell
9423e0913b Remove white space and re-indent gnc-features.c 2018-08-17 11:31:25 +01:00
Robert Fewell
c6001d855a Allow loading the sort and filter settings for the GL
By default the GL loads the last 30 days but this can be changed and
saved depending on requirements.
2018-08-17 11:31:25 +01:00
Robert Fewell
ed05b89518 Load the sort and filter settings to the .gcm file.
Load the sort and filter settings first from the .gcm file and if none
are found try the account kvp entries. This is part of a transition to
saving and loading these settings only in the .gcm file.
2018-08-17 11:31:25 +01:00
Robert Fewell
13c5b53931 Save the sort and filter settings to the .gcm file
Save the sort and filter settings to the .gcm file as well as the
account kvp. If default entries are saved then the corresponding entry
in the .gcm file will be removed. This is part of a transition to saving
 these settings only in the .gcm file.
2018-08-17 11:31:25 +01:00
Robert Fewell
72a29a83af Fix the save option on sort/filter dialog
When unticking the save option on the sort and filter dialog the actual
save items are not cleared so check for this and clear the saved items.
2018-08-17 11:31:25 +01:00
Robert Fewell
8a0ee0e38f Hide the filter/sort save button when appropiate 2018-08-17 11:31:25 +01:00
Robert Fewell
e281b50b29 Add new filter option to register
Add new option to the register filter so that it will display the last
number of days based on current day. This is stored as an extra element
on the end of account filter setting.
2018-08-17 11:31:25 +01:00
Robert Fewell
97a566ae28 Creating filter was leaking while being put together 2018-08-17 11:31:25 +01:00
Robert Fewell
6eac7e1ed0 There is no reason why you can not just have an end date
Change the logic so the date checks are not nested.
2018-08-17 11:31:25 +01:00
Robert Fewell
632c7c724e Update the filter when General Journal created. 2018-08-17 11:31:25 +01:00
Robert Fewell
d74ec9aa6c Only show update the summary bar left labels when present 2018-08-17 11:31:25 +01:00
Robert Fewell
3f9a8977c1 Add the summary bar to the GL and subaccount registers
Add the summary bar to the General Journal and sub account register but
only show sort and filter labels.
2018-08-17 11:31:25 +01:00
Robert Fewell
b50c8a57fa Show whether there is a filter on the right of the summary bar
On the right of the summary bar indicate whether there is a filter and
if there is display a tooltip with the settings. Also the filter label
can be altered by the css class "gnc-class-highlight".
2018-08-17 11:31:25 +01:00
Robert Fewell
b4db066d84 Add the sort order to the right of the summary bar
Add the sort order to the right of the summary bar with a tooltip that
shows whether ascending or descending and an arrow. When arrow can
also be emphasized with css by using the class "gnc-class-highlight".
2018-08-17 11:31:25 +01:00
Robert Fewell
c3724431e9 Add a parameter to add_summary_label to specify packing order
Add boolean pack_start to add_summary_label to indicate whether the
labels should be packed at the start or end of the summary bar.
2018-08-17 11:31:24 +01:00
John Ralls
4464469484 Revert changes associated with Bug 775368
Return commodity-utilities.scm to its state at 5803c141.
Too many changes in between to do a straight revert.
2018-08-16 16:12:14 -07:00
John Ralls
88597d0b64 Merge branch 'remove-timespec' into maint 2018-08-16 10:54:51 -07:00
John Ralls
c08dee67ba Preserve timespec-using functions in Guile bindings.
There's an example of use in text-extras.scm, function
gnc-pricedb-create.

Unfortunately the deprecation messages issue no warnings.
2018-08-16 10:47:41 -07:00
John Ralls
e9098d08d2 Change ISO date format to remove fractional seconds. 2018-08-13 16:19:39 -07:00
John Ralls
35fabe2690 Remove Timespec from gnc-date. 2018-08-13 16:19:39 -07:00
John Ralls
20f6e4e690 Remove Timespec from the SQL backend. 2018-08-13 11:52:43 -07:00
John Ralls
755773ac4c Clean up timespec comments in the XML backend.
Noting where the word must stay; most significantly for KVP types and for
parsing Version 1 XML files.
2018-08-13 11:52:43 -07:00
John Ralls
b32a8a9390 Remove time64_to_string and string_to_time64 and their tests.
Each was used exactly once and simply wrapped a function call.
Also replace static function time_parse_failure that just returned a
constant with the constant.
2018-08-13 11:52:43 -07:00
John Ralls
62b17ca5db Timespec removal, engine odds-and-ends. 2018-08-13 11:52:43 -07:00
John Ralls
358cd979d9 Remove Timespec from the main engine classes (Transaction, Split, & Account. 2018-08-13 11:52:42 -07:00
John Ralls
fee589b28c Remove Timespec from pricedb.
Includes removing the time64 specialized functions because the regular ones
handle time64 now.
2018-08-13 11:52:42 -07:00
John Ralls
92a8cf330a Timespec->time64 in business code. 2018-08-13 11:52:42 -07:00
Robert Fewell
44c3dc836a Bug 796785 - dates cannot be keyboard entered on vendor bill
transactions

Make the gncEntryLedgerModel 'get_date_help' function the same format
as that used in the register.
2018-08-13 15:47:12 +01:00
John Ralls
c8b372e390 Convert GNC_TYPE_TIMESPEC to GNC_TYPE_TIME64, Kvp::Type::Timespec to Kvp::Type::Time64
They have to go together because of using gvalues to hide KVP from most of
GnuCash.
2018-08-12 16:12:19 -07:00
John Ralls
b60aef9d2a Remove timespec2dmy.
It had only two uses and one was in a test. Replace those calls with
gnc_localtime_r.
2018-08-12 16:12:19 -07:00
John Ralls
6f89bd62b3 Remove timespec from gnucash/gnome.
With a little API bleed into engine.
2018-08-12 16:12:19 -07:00
John Ralls
e796120359 Remove Timespec from gnucash/gnome-utils.
Plus a bit of bleed into gnome because of deleted functions.
2018-08-12 16:12:18 -07:00
John Ralls
dd8732402f Remove all timespecs from the register. 2018-08-12 16:12:18 -07:00
John Ralls
6846a68691 Remove two unused functions, one of which used Timespec. 2018-08-12 16:12:18 -07:00
John Ralls
e3dce951c7 Remove Timespec from qif importer. 2018-08-12 16:12:18 -07:00
Geert Janssens
14335b7862 Merge branch 'Bug796788' of https://github.com/Bob-IT/gnucash into maint 2018-08-11 21:04:26 +02:00
Robert Fewell
b3f1104d39 Fix a possible transient parent dialogue warning 2018-08-11 18:01:53 +01:00
Robert Fewell
19d6eb9028 Improve the button sensitivity function 2018-08-11 18:01:45 +01:00