Small change in report [skip ci]

This commit is contained in:
James Cole 2016-05-16 12:47:43 +02:00
parent fc4ab29244
commit 5ab8cb38d3
3 changed files with 3 additions and 12 deletions

View File

@ -141,13 +141,4 @@ class BillLine
$this->hit = $hit;
}
/**
* @return bool
*/
public function isHitAndActive():bool
{
return $this->hit && $this->active;
}
}

View File

@ -23,6 +23,7 @@ use FireflyIII\Repositories\Tag\TagRepositoryInterface;
use Illuminate\Database\Eloquent\Builder;
use Illuminate\Database\Query\JoinClause;
use Illuminate\Support\Collection;
use Log;
/**
* Class ReportHelper
@ -92,7 +93,7 @@ class ReportHelper implements ReportHelperInterface
$billLine->setHit(true);
}
if ($billLine->isHitAndActive()) {
if ($billLine->isActive()) {
$collection->addBill($billLine);
}
}

View File

@ -524,8 +524,7 @@ class AccountRepository implements AccountRepositoryInterface
$sum = '0';
foreach ($incomes as $entry) {
$amount = TransactionJournal::amountPositive($entry);
Log::debug('spentInPeriod amount: ' . $amount);
$sum = bcadd($sum, $amount);
$sum = bcadd($sum, $amount);
}
return $sum;