]>
Dogcows Code - chaz/homebank/blob - src/hb-filter.h
1 /* HomeBank -- Free, easy, personal accounting for everyone.
2 * Copyright (C) 1995-2016 Maxime DOYEN
4 * This file is part of HomeBank.
6 * HomeBank is free software; you can redistribute it and/or modify
7 * it under the terms of the GNU General Public License as published by
8 * the Free Software Foundation; either version 2 of the License, or
9 * (at your option) any later version.
11 * HomeBank is distributed in the hope that it will be useful,
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 * GNU General Public License for more details.
16 * You should have received a copy of the GNU General Public License
17 * along with this program. If not, see <http://www.gnu.org/licenses/>.
20 #ifndef __HB_FILTER_H__
21 #define __HB_FILTER_H__
43 FLT_RANGE_THISMONTH
= 0,
44 FLT_RANGE_LASTMONTH
= 1,
45 FLT_RANGE_THISQUARTER
= 2,
46 FLT_RANGE_LASTQUARTER
= 3,
47 FLT_RANGE_THISYEAR
= 4,
48 FLT_RANGE_LASTYEAR
= 5, //was not existing on 4.5
50 FLT_RANGE_LAST30DAYS
= 7,
51 FLT_RANGE_LAST60DAYS
= 8,
52 FLT_RANGE_LAST90DAYS
= 9,
53 FLT_RANGE_LAST12MONTHS
= 10,
57 FLT_RANGE_ALLDATE
= 14
72 FLT_STATUS_UNCATEGORIZED
= 0,
73 FLT_STATUS_UNRECONCILED
= 1,
74 FLT_STATUS_UNCLEARED
= 2,
75 FLT_STATUS_RECONCILED
= 3,
76 FLT_STATUS_CLEARED
= 4,
84 FLT_QSEARCH_MEMO
= 1<<0,
85 FLT_QSEARCH_INFO
= 1<<1,
86 FLT_QSEARCH_PAYEE
= 1<<2,
87 FLT_QSEARCH_CATEGORY
= 1<<3,
88 FLT_QSEARCH_TAGS
= 1<<4
92 typedef struct _filter Filter
;
96 guint32 mindate
, maxdate
;
101 gshort option
[FILTER_MAX
];
106 gboolean forceremind
;
107 gboolean paymode
[NUM_PAYMODE_MAX
];
108 gdouble minamount
, maxamount
;
117 Filter
*da_filter_malloc(void);
118 void da_filter_free(Filter
*flt
);
120 void filter_default_all_set(Filter
*flt
);
121 void filter_preset_daterange_set(Filter
*flt
, gint range
, guint32 kacc
);
122 void filter_preset_type_set(Filter
*flt
, gint value
);
123 void filter_preset_daterange_add_futuregap(Filter
*filter
, gint nbdays
);
124 void filter_preset_status_set(Filter
*flt
, gint value
);
125 gchar
*filter_daterange_text_get(Filter
*flt
);
126 gboolean
filter_txn_search_match(gchar
*needle
, Transaction
*txn
, gint flags
);
128 gint
filter_test(Filter
*flt
, Transaction
*ope
);
This page took 0.040096 seconds and 5 git commands to generate.