]>
Dogcows Code - chaz/homebank/blob - src/hb-transaction.h
1 /* HomeBank -- Free, easy, personal accounting for everyone.
2 * Copyright (C) 1995-2019 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/>.
21 #ifndef __HB_TRANSACTION_H__
22 #define __HB_TRANSACTION_H__
27 typedef struct _transaction Transaction
;
30 #include "hb-account.h"
47 guint32 kxfer
; //strong link xfer key
58 GList
*same
; //used for import todo: change this
61 #include "hb-archive.h"
63 #define OF_OLDVALID (1<<0) //deprecated since 5.x
64 #define OF_INCOME (1<<1)
65 #define OF_AUTO (1<<2) //scheduled
66 #define OF_ADDED (1<<3) //tmp flag
67 #define OF_CHANGED (1<<4) //tmp flag
68 #define OF_OLDREMIND (1<<5) //deprecated since 5.x
69 #define OF_CHEQ2 (1<<6)
70 #define OF_LIMIT (1<<7) //scheduled
71 #define OF_SPLIT (1<<8)
76 TXN_STATUS_RECONCILED
,
89 Transaction
*da_transaction_malloc(void);
90 //Transaction *da_transaction_copy(Transaction *src_txn, Transaction *dst_txn);
91 Transaction
*da_transaction_init_from_template(Transaction
*txn
, Archive
*arc
);
92 Transaction
*da_transaction_set_default_template(Transaction
*txn
);
93 Transaction
*da_transaction_clone(Transaction
*src_item
);
94 void da_transaction_clean(Transaction
*item
);
95 void da_transaction_free(Transaction
*item
);
97 GList
*da_transaction_new(void);
98 void da_transaction_destroy(void);
100 void da_transaction_queue_sort(GQueue
*queue
);
101 GList
*da_transaction_sort(GList
*list
);
102 gboolean
da_transaction_prepend(Transaction
*item
);
103 gboolean
da_transaction_insert_sorted(Transaction
*item
);
107 ** transaction edit type
111 TRANSACTION_EDIT_ADD
,
112 TRANSACTION_EDIT_INHERIT
,
113 TRANSACTION_EDIT_MODIFY
117 guint
da_transaction_length(void);
119 void transaction_remove(Transaction
*ope
);
120 void transaction_changed(Transaction
*txn
);
121 gboolean
da_transaction_insert_memo(Transaction
*item
);
122 Transaction
*transaction_add(GtkWindow
*parent
, Transaction
*ope
);
124 gboolean
transaction_acc_move(Transaction
*txn
, guint32 okacc
, guint32 nkacc
);
126 Transaction
*transaction_xfer_child_strong_get(Transaction
*src
);
127 void transaction_xfer_search_or_add_child(GtkWindow
*parent
, Transaction
*ope
, guint32 kdstacc
);
128 void transaction_xfer_change_to_child(Transaction
*ope
, Transaction
*child
);
129 void transaction_xfer_child_sync(Transaction
*s_txn
, Transaction
*child
);
130 void transaction_xfer_remove_child(Transaction
*src
);
131 Transaction
*transaction_old_get_child_transfer(Transaction
*src
);
133 guint
transaction_auto_assign(GList
*ope_list
, guint32 key
);
135 void da_transaction_consistency(Transaction
*item
);
138 gint
transaction_similar_mark(Account
*acc
, guint32 daygap
);
139 void transaction_similar_unmark(Account
*acc
);
This page took 0.042765 seconds and 4 git commands to generate.