Make it possible to hide chores/batteries (closes #1069)

This commit is contained in:
Bernd Bestel
2020-12-20 10:19:44 +01:00
parent 31dbb95c58
commit 268b8e87d7
17 changed files with 239 additions and 23 deletions

View File

@@ -52,7 +52,7 @@ class CalendarService extends BaseService
{
$users = $this->getUsersService()->GetUsersAsDto();
$chores = $this->getDatabase()->chores();
$chores = $this->getDatabase()->chores()->where('active = 1');
$titlePrefix = $this->getLocalizationService()->__t('Chore due') . ': ';
foreach ($this->getChoresService()->GetCurrent() as $currentChoreEntry)
@@ -80,7 +80,7 @@ class CalendarService extends BaseService
if (GROCY_FEATURE_FLAG_BATTERIES)
{
$batteries = $this->getDatabase()->batteries();
$batteries = $this->getDatabase()->batteries()->where('active = 1');
$titlePrefix = $this->getLocalizationService()->__t('Battery charge cycle due') . ': ';
foreach ($this->getBatteriesService()->GetCurrent() as $currentBatteryEntry)