mirror of
https://github.com/Gnucash/gnucash.git
synced 2025-02-25 18:55:30 -06:00
Fix bug 590386 - Always use today for reconciliation statement date
Patch by Simon Arlott git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@18317 57a11ea4-9604-0410-9ed3-97b8803252fd
This commit is contained in:
parent
da8ef1797b
commit
1df9789ef1
@ -2535,7 +2535,7 @@
|
||||
<widget class="GtkTable" id="table3">
|
||||
<property name="border_width">6</property>
|
||||
<property name="visible">True</property>
|
||||
<property name="n_rows">14</property>
|
||||
<property name="n_rows">15</property>
|
||||
<property name="n_columns">4</property>
|
||||
<property name="homogeneous">False</property>
|
||||
<property name="row_spacing">0</property>
|
||||
@ -2694,8 +2694,8 @@
|
||||
<packing>
|
||||
<property name="left_attach">0</property>
|
||||
<property name="right_attach">1</property>
|
||||
<property name="top_attach">8</property>
|
||||
<property name="bottom_attach">9</property>
|
||||
<property name="top_attach">9</property>
|
||||
<property name="bottom_attach">10</property>
|
||||
<property name="x_options">fill</property>
|
||||
<property name="y_options"></property>
|
||||
</packing>
|
||||
@ -2773,6 +2773,30 @@
|
||||
</packing>
|
||||
</child>
|
||||
|
||||
<child>
|
||||
<widget class="GtkCheckButton" id="gconf/dialogs/reconcile/always_reconcile_to_today">
|
||||
<property name="visible">True</property>
|
||||
<property name="tooltip" translatable="yes">Always open the reconcile dialog using today's date for the statement date, regardless of previous reconciliations.</property>
|
||||
<property name="can_focus">True</property>
|
||||
<property name="label" translatable="yes">Always reconcile to t_oday</property>
|
||||
<property name="use_underline">True</property>
|
||||
<property name="relief">GTK_RELIEF_NORMAL</property>
|
||||
<property name="focus_on_click">True</property>
|
||||
<property name="active">False</property>
|
||||
<property name="inconsistent">False</property>
|
||||
<property name="draw_indicator">True</property>
|
||||
</widget>
|
||||
<packing>
|
||||
<property name="left_attach">0</property>
|
||||
<property name="right_attach">4</property>
|
||||
<property name="top_attach">8</property>
|
||||
<property name="bottom_attach">9</property>
|
||||
<property name="x_padding">12</property>
|
||||
<property name="x_options">fill</property>
|
||||
<property name="y_options"></property>
|
||||
</packing>
|
||||
</child>
|
||||
|
||||
<child>
|
||||
<widget class="GtkCheckButton" id="gconf/general/register/draw_vertical_lines">
|
||||
<property name="visible">True</property>
|
||||
@ -2789,8 +2813,8 @@
|
||||
<packing>
|
||||
<property name="left_attach">0</property>
|
||||
<property name="right_attach">4</property>
|
||||
<property name="top_attach">13</property>
|
||||
<property name="bottom_attach">14</property>
|
||||
<property name="top_attach">14</property>
|
||||
<property name="bottom_attach">15</property>
|
||||
<property name="x_padding">12</property>
|
||||
<property name="x_options">fill</property>
|
||||
<property name="y_options"></property>
|
||||
@ -2813,8 +2837,8 @@
|
||||
<packing>
|
||||
<property name="left_attach">0</property>
|
||||
<property name="right_attach">4</property>
|
||||
<property name="top_attach">12</property>
|
||||
<property name="bottom_attach">13</property>
|
||||
<property name="top_attach">13</property>
|
||||
<property name="bottom_attach">14</property>
|
||||
<property name="x_padding">12</property>
|
||||
<property name="x_options">fill</property>
|
||||
<property name="y_options"></property>
|
||||
@ -2837,8 +2861,8 @@
|
||||
<packing>
|
||||
<property name="left_attach">0</property>
|
||||
<property name="right_attach">4</property>
|
||||
<property name="top_attach">11</property>
|
||||
<property name="bottom_attach">12</property>
|
||||
<property name="top_attach">12</property>
|
||||
<property name="bottom_attach">13</property>
|
||||
<property name="x_padding">12</property>
|
||||
<property name="x_options">fill</property>
|
||||
<property name="y_options"></property>
|
||||
@ -2861,8 +2885,8 @@
|
||||
<packing>
|
||||
<property name="left_attach">0</property>
|
||||
<property name="right_attach">4</property>
|
||||
<property name="top_attach">10</property>
|
||||
<property name="bottom_attach">11</property>
|
||||
<property name="top_attach">11</property>
|
||||
<property name="bottom_attach">12</property>
|
||||
<property name="x_padding">12</property>
|
||||
<property name="x_options">fill</property>
|
||||
<property name="y_options"></property>
|
||||
@ -2890,8 +2914,8 @@
|
||||
<packing>
|
||||
<property name="left_attach">0</property>
|
||||
<property name="right_attach">2</property>
|
||||
<property name="top_attach">9</property>
|
||||
<property name="bottom_attach">10</property>
|
||||
<property name="top_attach">10</property>
|
||||
<property name="bottom_attach">11</property>
|
||||
<property name="x_options">fill</property>
|
||||
<property name="y_options"></property>
|
||||
</packing>
|
||||
|
@ -53,5 +53,21 @@
|
||||
</locale>
|
||||
</schema>
|
||||
|
||||
<schema>
|
||||
<key>/schemas/apps/gnucash/dialogs/reconcile/always_reconcile_to_today</key>
|
||||
<applyto>/apps/gnucash/dialogs/reconcile/always_reconcile_to_today</applyto>
|
||||
<owner>gnucash</owner>
|
||||
<type>bool</type>
|
||||
<default>FALSE</default>
|
||||
<locale name="C">
|
||||
<short>Always reconcile to today</short>
|
||||
<long>
|
||||
If active, always open the reconcile dialog using today's
|
||||
date for the statement date, regardless of previous
|
||||
reconciliations.
|
||||
</long>
|
||||
</locale>
|
||||
</schema>
|
||||
|
||||
</schemalist>
|
||||
</gconfschemafile>
|
||||
|
@ -1329,13 +1329,18 @@ gnc_get_reconcile_info (Account *account,
|
||||
gnc_numeric *new_ending,
|
||||
time_t *statement_date)
|
||||
{
|
||||
gboolean always_today;
|
||||
GDate date;
|
||||
time_t today;
|
||||
struct tm tm;
|
||||
|
||||
g_date_clear(&date, 1);
|
||||
|
||||
if (xaccAccountGetReconcileLastDate (account, statement_date))
|
||||
always_today = gnc_gconf_get_bool(GCONF_RECONCILE_SECTION,
|
||||
"always_reconcile_to_today", NULL);
|
||||
|
||||
if (!always_today &&
|
||||
xaccAccountGetReconcileLastDate (account, statement_date))
|
||||
{
|
||||
int months = 1, days = 0;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user