Fix minor bug - History search for all with date

This commit is contained in:
GME 2019-06-14 18:21:50 +02:00
parent 48da18bfdd
commit cae0aec951

View file

@ -90,8 +90,9 @@ public class TransactionDao {
public List<Transaction> getAllTransactionBetweenDate(String wallet_hash, String start, String end, int number) throws Exception{
createTransactionDaoConnection();
QueryBuilder<Transaction, String> queryBuilder = transactionDao.queryBuilder();
queryBuilder.where().eq("transaction_from",wallet_hash).or().eq("transaction_to",wallet_hash);
queryBuilder.where().between("transaction_date", new BigInteger(start), new BigInteger(end));
queryBuilder.where().eq("transaction_from",wallet_hash)
.or().eq("transaction_to",wallet_hash)
.and().between("transaction_date", new BigInteger(start), new BigInteger(end));
if(number!=0){
queryBuilder.limit(new Long(number));