X-Git-Url: https://git.ktnx.net/?p=mobile-ledger.git;a=blobdiff_plain;f=app%2Fsrc%2Fmain%2Fjava%2Fnet%2Fktnx%2Fmobileledger%2FSaveTransactionTask.java;h=2e95a7d49b5f1cec0d381b3e6ef181325bf257b7;hp=3c2cb447975cb3d7406e5ddcd57600a12d49c196;hb=674b18d882411b94513d77c0aea39fd929a7a62b;hpb=cc080f415ad546183c7d92d8f58dddefb60560fe
diff --git a/app/src/main/java/net/ktnx/mobileledger/SaveTransactionTask.java b/app/src/main/java/net/ktnx/mobileledger/SaveTransactionTask.java
index 3c2cb447..2e95a7d4 100644
--- a/app/src/main/java/net/ktnx/mobileledger/SaveTransactionTask.java
+++ b/app/src/main/java/net/ktnx/mobileledger/SaveTransactionTask.java
@@ -1,3 +1,20 @@
+/*
+ * Copyright © 2018 Damyan Ivanov.
+ * This file is part of Mobile-Ledger.
+ * Mobile-Ledger is free software: you can distribute it and/or modify it
+ * under the term of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your opinion), any later version.
+ *
+ * Mobile-Ledger is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License terms for details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with Mobile-Ledger. If not, see .
+ */
+
package net.ktnx.mobileledger;
import android.content.SharedPreferences;
@@ -55,9 +72,9 @@ class SaveTransactionTask extends AsyncTask {
Iterator items = ltr.getItemsIterator();
while (items.hasNext()) {
LedgerTransactionItem item = items.next();
- params.add_pair("account", item.get_account_name());
- if (item.is_amount_set())
- params.add_pair("amount", String.format(Locale.US, "%1.2f", item.get_amount()));
+ params.add_pair("account", item.getAccountName());
+ if (item.isAmountSet())
+ params.add_pair("amount", String.format(Locale.US, "%1.2f", item.getAmount()));
else params.add_pair("amount", "");
}
}