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
@@ -34,8 +34,16 @@ SOURCES = qashmoney.cpp \
calculator.cpp \
datepicker.cpp \
main.cpp \
budget.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
@@ -22,20 +22,20 @@ Transaction::~Transaction ()
{
sqlite_close ( tdb );
}
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 );
}
void Transaction::deleteTransaction ( int transid )
{
sqlite_exec_printf ( tdb, "delete from transactions where transid = %i;", 0, 0, 0, transid );
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
@@ -30,14 +30,14 @@ void Transfer::addTransfer ( int fromaccount, int fromparent, int toaccount, int
}
sqlite_exec_printf ( db, "insert into transfers values ( %i, %i, %i, %i, %i, %i, %i, 0, 0, %.2f, %i, 0, 0, 0, 0, 0, %i );", 0, 0, 0, fromaccount, fromparent, toaccount, toparent, day, month, year, amount, cleared, nextrowid );
}
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 );
}
void Transfer::deleteTransfer ( int transferid )
{
sqlite_exec_printf ( db, "delete from transfers where transferid = %i;", 0, 0, 0, transferid );
}
diff --git a/packages b/packages
index c48eee8..0e6340f 100644
--- a/packages
+++ b/packages
@@ -117,12 +117,13 @@ CONFIG_OPIETOOTH-APPLET noncore/net/opietooth/applet applet.pro
CONFIG_OPIETOOTH-MANAGER noncore/net/opietooth/manager manager.pro
CONFIG_OSEARCH core/pim/osearch osearch.pro
CONFIG_OXYGEN noncore/apps/oxygen oxygen.pro
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
CONFIG_QPDF2 noncore/graphics/qpdf2 qpdf2.pro
CONFIG_QUICKLAUNCHER core/tools/quicklauncher quicklauncher.pro
CONFIG_QWS core/qws qws.pro
CONFIG_REMOTE noncore/tools/remote remote.pro