summaryrefslogtreecommitdiff
Side-by-side diff
Diffstat (more/less context) (ignore whitespace changes)
-rw-r--r--noncore/apps/qashmoney/config.in4
-rwxr-xr-xnoncore/apps/qashmoney/qashmoney.pro8
-rwxr-xr-xnoncore/apps/qashmoney/transaction.cpp8
-rwxr-xr-xnoncore/apps/qashmoney/transfer.cpp4
-rw-r--r--packages1
5 files changed, 19 insertions, 6 deletions
diff --git a/noncore/apps/qashmoney/config.in b/noncore/apps/qashmoney/config.in
new file mode 100644
index 0000000..94c39b6
--- a/dev/null
+++ b/noncore/apps/qashmoney/config.in
@@ -0,0 +1,4 @@
+ config QASHMONEY
+ boolean "opie-qashmoney (money manager)"
+ default "n"
+ depends ( LIBQPE || LIBQPE-X11 ) && LIBOPIE
diff --git a/noncore/apps/qashmoney/qashmoney.pro b/noncore/apps/qashmoney/qashmoney.pro
index 1070767..8b4646a 100755
--- a/noncore/apps/qashmoney/qashmoney.pro
+++ b/noncore/apps/qashmoney/qashmoney.pro
@@ -38,4 +38,12 @@ SOURCES = qashmoney.cpp \
budgetdisplay.cpp \
currency.cpp
+INCLUDEPATH = $(OPIEDIR)/include
+DEPENDPATH = $(OPIEDIR)/include
+
+DESTDIR = $(OPIEDIR)/bin
+
unix:LIBS += -lm
LIBS += -lqpe -lqte -lstdc++ -lsqlite
+
+include ( $(OPIEDIR)/include.pro )
+
diff --git a/noncore/apps/qashmoney/transaction.cpp b/noncore/apps/qashmoney/transaction.cpp
index a3bd9e7..dcf46b1 100755
--- a/noncore/apps/qashmoney/transaction.cpp
+++ b/noncore/apps/qashmoney/transaction.cpp
@@ -26,12 +26,12 @@ Transaction::~Transaction ()
void Transaction::addTransaction ( QString description, QString payee, int accountid, int parentid, int number, int day, int month, int year, float amount, int cleared, int budgetid, int lineitemid )
{
- sqlite_exec_printf ( tdb, "insert into transactions values ( '%q', %i, %i, %i, %i, %i, %i, %.2f, %i, %i, 0, 0, 0, 0, 0, 0, %i, '%q', 0,
- 0, 0, 0, NULL );", 0, 0, 0, ( const char * ) payee, accountid, parentid, number, day, month, year, amount, cleared, budgetid, lineitemid, ( const char * ) description );
+ sqlite_exec_printf ( tdb, "insert into transactions values ( '%q', %i, %i, %i, %i, %i, %i, %.2f, %i, %i, 0, 0, 0, 0, 0, 0, %i, '%q', 0, "
+ "0, 0, 0, NULL );", 0, 0, 0, ( const char * ) payee, accountid, parentid, number, day, month, year, amount, cleared, budgetid, lineitemid, ( const char * ) description );
}
void Transaction::updateTransaction ( QString description, QString payee, int number, int day, int month, int year, float amount, int cleared, int budgetid, int lineitemid, int transactionid )
{
- sqlite_exec_printf ( tdb, "update transactions set reservedtwo = '%q', payee = '%q', number = %i, day = %i, month = %i, year = %i, amount = %.2f,
- cleared = %i, budgetid = %i, reservedone = %i where transid = %i;", 0, 0, 0, ( const char * ) description, ( const char * ) payee, number, day, month, year,
+ sqlite_exec_printf ( tdb, "update transactions set reservedtwo = '%q', payee = '%q', number = %i, day = %i, month = %i, year = %i, amount = %.2f,"
+ "cleared = %i, budgetid = %i, reservedone = %i where transid = %i;", 0, 0, 0, ( const char * ) description, ( const char * ) payee, number, day, month, year,
amount, cleared, budgetid, lineitemid, transactionid );
}
diff --git a/noncore/apps/qashmoney/transfer.cpp b/noncore/apps/qashmoney/transfer.cpp
index 568d584..c4bbaf9 100755
--- a/noncore/apps/qashmoney/transfer.cpp
+++ b/noncore/apps/qashmoney/transfer.cpp
@@ -34,6 +34,6 @@ void Transfer::addTransfer ( int fromaccount, int fromparent, int toaccount, int
void Transfer::updateTransfer ( int fromaccount, int fromparent, int toaccount, int toparent, int day, int month, int year, float amount, int cleared, int transferid )
{
- sqlite_exec_printf ( db, "update transfers set fromaccount = %i, fromparent = %i, toaccount = %i, toparent = %i, day = %i, month = %i, year = %i,
- amount = %.2f, cleared = %i where transferid = %i;", 0, 0, 0, fromaccount, fromparent, toaccount, toparent, day, month, year, amount, cleared, transferid );
+ sqlite_exec_printf ( db, "update transfers set fromaccount = %i, fromparent = %i, toaccount = %i, toparent = %i, day = %i, month = %i, year = %i,"
+ "amount = %.2f, cleared = %i where transferid = %i;", 0, 0, 0, fromaccount, fromparent, toaccount, toparent, day, month, year, amount, cleared, transferid );
}
diff --git a/packages b/packages
index c48eee8..0e6340f 100644
--- a/packages
+++ b/packages
@@ -121,4 +121,5 @@ CONFIG_PARASHOOT noncore/games/parashoot parashoot.pro
CONFIG_PICKBOARD inputmethods/pickboard pickboard.pro
CONFIG_QASTEROIDS noncore/games/qasteroids qasteroids.pro
+CONFIG_QASHMONEY noncore/apps/qashmoney qashmoney.pro
CONFIG_QCOP core/apps/qcop qcop.pro
CONFIG_QPDF noncore/graphics/qpdf qpdf.pro