minor fixes

This commit is contained in:
henry 2017-10-15 20:57:15 -04:00
parent a1ec57044c
commit fb340d0cba
3 changed files with 4 additions and 4 deletions

View file

@ -19,7 +19,7 @@ public interface CryptoCurrencyDao {
@Query("SELECT * FROM crypto_currency") @Query("SELECT * FROM crypto_currency")
List<CryptoCurrency> getAll(); List<CryptoCurrency> getAll();
@Query("SELECT * FROM crypto_currency WHERE id := id") @Query("SELECT * FROM crypto_currency WHERE id = :id")
CryptoCurrency getById(int id); CryptoCurrency getById(int id);
@Insert(onConflict = OnConflictStrategy.REPLACE) @Insert(onConflict = OnConflictStrategy.REPLACE)

View file

@ -23,8 +23,8 @@ public interface TransactionDao {
@Query("SELECT * FROM crypto_coin_transaction ORDER BY date ASC") @Query("SELECT * FROM crypto_coin_transaction ORDER BY date ASC")
LivePagedListProvider<Integer, CryptoCoinTransaction> transactionsByDate(); LivePagedListProvider<Integer, CryptoCoinTransaction> transactionsByDate();
@Query("SELECT * FROM crypto_coin_transaction WHERE account_id := idAccount ORDER BY date ASC") @Query("SELECT * FROM crypto_coin_transaction WHERE account_id = :idAccount ORDER BY date ASC")
LiveData<List<CryptoCoinTransaction>> getByIdAccount(long idAccount); LiveData<List<CryptoCoinTransaction>> getByIdAccount(long idAccount);
@Insert(onConflict = OnConflictStrategy.REPLACE) @Insert(onConflict = OnConflictStrategy.REPLACE)
public long[] insertTransaction(CryptoCoinTransaction... transactions); public long[] insertTransaction(CryptoCoinTransaction... transactions);

View file

@ -34,7 +34,7 @@ public class CryptoCoinBalanceViewHolder extends RecyclerView.ViewHolder {
cryptoCoinBalance.setText(""); cryptoCoinBalance.setText("");
} else { } else {
cryptoCoinName.setText(balance.getCoin().getLabel()); cryptoCoinName.setText(balance.getCoin().getLabel());
cryptoCoinBalance.setText(balance.getBalance()); //cryptoCoinBalance.setText(balance.getBalance());
} }
} }
} }