]>
Dogcows Code - chaz/homebank/blob - src/hb-transaction.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/>.
21 #ifndef __HB_TRANSACTION_H__
22 #define __HB_TRANSACTION_H__
27 typedef struct _transaction Transaction
;
45 guint32 kxfer
; //strong link xfer key
48 Split
*splits
[TXN_MAX_SPLIT
+1];
51 GList
*same
; //used for import todo: change this
56 #include "hb-archive.h"
58 #define OF_OLDVALID (1<<0) //deprecated since 5.x
59 #define OF_INCOME (1<<1)
60 #define OF_AUTO (1<<2) //scheduled
61 #define OF_ADDED (1<<3) //tmp flag
62 #define OF_CHANGED (1<<4) //tmp flag
63 #define OF_OLDREMIND (1<<5) //deprecated since 5.x
64 #define OF_CHEQ2 (1<<6)
65 #define OF_LIMIT (1<<7) //scheduled
66 #define OF_SPLIT (1<<8)
71 TXN_STATUS_RECONCILED
,
77 Transaction
*da_transaction_malloc(void);
78 Transaction
*da_transaction_copy(Transaction
*src_txn
, Transaction
*dst_txn
);
79 Transaction
*da_transaction_init_from_template(Transaction
*txn
, Archive
*arc
);
80 Transaction
*da_transaction_clone(Transaction
*src_item
);
81 void da_transaction_clean(Transaction
*item
);
82 void da_transaction_free(Transaction
*item
);
84 GList
*da_transaction_new(void);
85 void da_transaction_destroy(void);
87 void da_transaction_queue_sort(GQueue
*queue
);
88 GList
*da_transaction_sort(GList
*list
);
89 gboolean
da_transaction_prepend(Transaction
*item
);
90 gboolean
da_transaction_insert_sorted(Transaction
*item
);
94 ** transaction edit type
99 TRANSACTION_EDIT_INHERIT
,
100 TRANSACTION_EDIT_MODIFY
104 guint
da_transaction_length(void);
105 void transaction_add_treeview(Transaction
*ope
, GtkWidget
*treeview
, guint32 accnum
);
106 void transaction_add(Transaction
*ope
, GtkWidget
*treeview
, guint32 accnum
);
108 gboolean
transaction_acc_move(Transaction
*txn
, guint32 okacc
, guint32 nkacc
);
110 Transaction
*transaction_xfer_child_strong_get(Transaction
*src
);
111 void transaction_xfer_search_or_add_child(GtkWindow
*parentwindow
, Transaction
*ope
, gboolean manual
);
112 void transaction_xfer_change_to_child(Transaction
*ope
, Transaction
*child
);
113 void transaction_xfer_sync_child(Transaction
*ope
, Transaction
*child
);
114 void transaction_xfer_remove_child(Transaction
*src
);
115 Transaction
*transaction_old_get_child_transfer(Transaction
*src
);
117 guint
transaction_tags_count(Transaction
*ope
);
118 void transaction_tags_clone(Transaction
*src_txn
, Transaction
*dst_txn
);
119 guint
transaction_tags_parse(Transaction
*ope
, const gchar
*tagstring
);
120 gchar
*transaction_tags_tostring(Transaction
*ope
);
121 gint
transaction_auto_assign(GList
*ope_list
, guint32 key
);
123 void da_transaction_consistency(Transaction
*item
);
This page took 0.044239 seconds and 4 git commands to generate.