summaryrefslogtreecommitdiff
path: root/noncore/apps/qashmoney/account.h
authorchicken <chicken>2004-11-02 18:23:35 (UTC)
committer chicken <chicken>2004-11-02 18:23:35 (UTC)
commit029fc220470de74b7c1a148c9ea934c17686149f (patch) (unidiff)
tree115de8edc9142615b31d906770cb7978190e7af8 /noncore/apps/qashmoney/account.h
parentebdc2d346272bae27c867b855207993985df4450 (diff)
downloadopie-029fc220470de74b7c1a148c9ea934c17686149f.zip
opie-029fc220470de74b7c1a148c9ea934c17686149f.tar.gz
opie-029fc220470de74b7c1a148c9ea934c17686149f.tar.bz2
switching to sqlite3
Diffstat (limited to 'noncore/apps/qashmoney/account.h') (more/less context) (ignore whitespace changes)
-rwxr-xr-xnoncore/apps/qashmoney/account.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/noncore/apps/qashmoney/account.h b/noncore/apps/qashmoney/account.h
index f77f400..5bad4a1 100755
--- a/noncore/apps/qashmoney/account.h
+++ b/noncore/apps/qashmoney/account.h
@@ -1,31 +1,31 @@
1#ifndef ACCOUNT_H 1#ifndef ACCOUNT_H
2#define ACCOUNT_H 2#define ACCOUNT_H
3 3
4#include <qstring.h> 4#include <qstring.h>
5#include <qlistview.h> 5#include <qlistview.h>
6#include <qcombobox.h> 6#include <qcombobox.h>
7#include <sqlite.h> 7#include <sqlite3.h>
8 8
9class Account 9class Account
10 { 10 {
11 public: 11 public:
12 12
13 Account (); 13 Account ();
14 ~Account (); 14 ~Account ();
15 15
16 // This function adds a new account to the database. It takes the account name, parent, 16 // This function adds a new account to the database. It takes the account name, parent,
17 // initial balance and the account type, description, credit limit, statementbalancedate 17 // initial balance and the account type, description, credit limit, statementbalancedate
18 // as three integers, and the statementbalance amount 18 // as three integers, and the statementbalance amount
19 // The parent is an integer account id. Its -1 if there is no parent 19 // The parent is an integer account id. Its -1 if there is no parent
20 // The account types (so far) are 0=not defined 1=parent checking 2=child checking 20 // The account types (so far) are 0=not defined 1=parent checking 2=child checking
21 void addAccount ( QString, int, float, int, QString, float, int, int, int, float, const char * ); 21 void addAccount ( QString, int, float, int, QString, float, int, int, int, float, const char * );
22 22
23 // updates certain parts of an account 23 // updates certain parts of an account
24 void updateAccount ( QString name, QString description, QString currencycode, int accountid ); 24 void updateAccount ( QString name, QString description, QString currencycode, int accountid );
25 25
26 void setAccountExpanded ( int expanded, int accountid ); 26 void setAccountExpanded ( int expanded, int accountid );
27 int getAccountExpanded ( int id ); 27 int getAccountExpanded ( int id );
28 28
29 // Deletes an account 29 // Deletes an account
30 // Takes the accountid as its parameter 30 // Takes the accountid as its parameter
31 void deleteAccount ( int ); 31 void deleteAccount ( int );
@@ -59,42 +59,42 @@ class Account
59 // Takes the combobox address for its parameter 59 // Takes the combobox address for its parameter
60 int displayParentAccountNames ( QComboBox *, QString ); 60 int displayParentAccountNames ( QComboBox *, QString );
61 61
62 int getAccountType ( int ); // returns account type for given account id 62 int getAccountType ( int ); // returns account type for given account id
63 63
64 // The next three collectively return a date or balance 64 // The next three collectively return a date or balance
65 // They take the accountid as their parameters 65 // They take the accountid as their parameters
66 int getStatementDay ( int ); 66 int getStatementDay ( int );
67 int getStatementMonth ( int ); 67 int getStatementMonth ( int );
68 int getStatementYear ( int ); 68 int getStatementYear ( int );
69 float getStatementBalance ( int ); 69 float getStatementBalance ( int );
70 70
71 // Returns account description and name 71 // Returns account description and name
72 QString getAccountDescription ( int accountid ); 72 QString getAccountDescription ( int accountid );
73 QString getCurrencyCode ( int accountid ); 73 QString getCurrencyCode ( int accountid );
74 QString getAccountName ( int accountid ); 74 QString getAccountName ( int accountid );
75 QStringList getAccountNames (); 75 QStringList getAccountNames ();
76 QStringList getAccountIDs (); 76 QStringList getAccountIDs ();
77 QString getAccountBalance ( int accountid ); 77 QString getAccountBalance ( int accountid );
78 78
79 // returns account credit limit 79 // returns account credit limit
80 float getAccountCreditLimit ( int ); 80 float getAccountCreditLimit ( int );
81 81
82 // The primary database that stores all our data 82 // The primary database that stores all our data
83 sqlite *adb; 83 sqlite3 *adb;
84 }; 84 };
85 85
86class GreyBackgroundItem : public QListViewItem 86class GreyBackgroundItem : public QListViewItem
87 { 87 {
88 public: 88 public:
89 89
90 GreyBackgroundItem ( QListView *parent ); 90 GreyBackgroundItem ( QListView *parent );
91 GreyBackgroundItem ( QListView *parent, QString label1, QString label2, QString label3 ); 91 GreyBackgroundItem ( QListView *parent, QString label1, QString label2, QString label3 );
92 GreyBackgroundItem ( QListView *parent, QString label1, QString label2, QString label3, QString label4 ); 92 GreyBackgroundItem ( QListView *parent, QString label1, QString label2, QString label3, QString label4 );
93 GreyBackgroundItem ( QListView *parent, QString label1, QString label2, QString label3, QString label4, QString label5 ); 93 GreyBackgroundItem ( QListView *parent, QString label1, QString label2, QString label3, QString label4, QString label5 );
94 94
95 virtual void paintCell ( QPainter *p, const QColorGroup &cg, int column, int width, int alignment ); 95 virtual void paintCell ( QPainter *p, const QColorGroup &cg, int column, int width, int alignment );
96 96
97 }; 97 };
98 98
99#endif 99#endif
100 100