#116 - integration with slack #129
@@ -22,7 +22,7 @@ class DailySummaryRetriever
|
||||
|
krzysztofrewak
commented
Review
```suggestion
->whereTypes(VacationType::all()->filter(fn(VacationType $type): bool => $this->configRetriever->isVacation($type)))
```
krzysztofrewak
commented
Review
```suggestion
->whereTypes(VacationType::all()->filter(fn(VacationType $type): bool => $this->configRetriever->isVacation($type)))
```
krzysztofrewak
commented
Review
```suggestion
->whereTypes(VacationType::all()->filter(fn(VacationType $type): bool => !$this->configRetriever->isVacation($type)))
```
krzysztofrewak
commented
Review
```suggestion
->whereTypes(VacationType::all()->filter(fn(VacationType $type): bool => !$this->configRetriever->isVacation($type)))
```
|
||||
->with(["user", "vacationRequest"])
|
||||
->whereDate("date", $date)
|
||||
->approved()
|
||||
->whereTypes(VacationType::all()->filter(fn(VacationType $type) => $this->configRetriever->isVacation($type)))
|
||||
```suggestion
->whereTypes(VacationType::all()->filter(fn(VacationType $type): bool => $this->configRetriever->isVacation($type)))
```
```suggestion
->whereTypes(VacationType::all()->filter(fn(VacationType $type): bool => !$this->configRetriever->isVacation($type)))
```
|
||||
->whereTypes(VacationType::all()->filter(fn(VacationType $type): bool => $this->configRetriever->isVacation($type)))
|
||||
```suggestion
->whereTypes(VacationType::all()->filter(fn(VacationType $type): bool => $this->configRetriever->isVacation($type)))
```
```suggestion
->whereTypes(VacationType::all()->filter(fn(VacationType $type): bool => !$this->configRetriever->isVacation($type)))
```
|
||||
->get();
|
||||
}
|
||||
|
||||
@@ -32,7 +32,7 @@ class DailySummaryRetriever
|
||||
```suggestion
->whereTypes(VacationType::all()->filter(fn(VacationType $type): bool => $this->configRetriever->isVacation($type)))
```
```suggestion
->whereTypes(VacationType::all()->filter(fn(VacationType $type): bool => $this->configRetriever->isVacation($type)))
```
```suggestion
->whereTypes(VacationType::all()->filter(fn(VacationType $type): bool => !$this->configRetriever->isVacation($type)))
```
```suggestion
->whereTypes(VacationType::all()->filter(fn(VacationType $type): bool => !$this->configRetriever->isVacation($type)))
```
|
||||
->with(["user", "vacationRequest"])
|
||||
->whereDate("date", $date)
|
||||
->approved()
|
||||
->whereTypes(VacationType::all()->filter(fn(VacationType $type) => !$this->configRetriever->isVacation($type)))
|
||||
```suggestion
->whereTypes(VacationType::all()->filter(fn(VacationType $type): bool => $this->configRetriever->isVacation($type)))
```
```suggestion
->whereTypes(VacationType::all()->filter(fn(VacationType $type): bool => !$this->configRetriever->isVacation($type)))
```
|
||||
->whereTypes(VacationType::all()->filter(fn(VacationType $type): bool => !$this->configRetriever->isVacation($type)))
|
||||
```suggestion
->whereTypes(VacationType::all()->filter(fn(VacationType $type): bool => $this->configRetriever->isVacation($type)))
```
```suggestion
->whereTypes(VacationType::all()->filter(fn(VacationType $type): bool => !$this->configRetriever->isVacation($type)))
```
|
||||
->get();
|
||||
}
|
||||
|
||||
|
||||
```suggestion
->whereTypes(VacationType::all()->filter(fn(VacationType $type): bool => $this->configRetriever->isVacation($type)))
```
```suggestion
->whereTypes(VacationType::all()->filter(fn(VacationType $type): bool => $this->configRetriever->isVacation($type)))
```
```suggestion
->whereTypes(VacationType::all()->filter(fn(VacationType $type): bool => !$this->configRetriever->isVacation($type)))
```
```suggestion
->whereTypes(VacationType::all()->filter(fn(VacationType $type): bool => !$this->configRetriever->isVacation($type)))
```
|
||||
@@ -24,13 +24,13 @@ class DailySummary extends SignatureHandler
|
||||
```suggestion
$absences = $dailySummaryRetriever->getAbsences($now)
->map(fn(Vacation $vacation): string => $vacation->user->profile->full_name);
$remoteDays = $dailySummaryRetriever->getRemoteDays($now)
->map(fn(Vacation $vacation): string => $vacation->user->profile->full_name);
$birthdays = $dailySummaryRetriever->getBirthdays($now)
->map(fn(User $user): string => $user->profile->full_name);
```
```suggestion
$absences = $dailySummaryRetriever->getAbsences($now)
->map(fn(Vacation $vacation): string => $vacation->user->profile->full_name);
$remoteDays = $dailySummaryRetriever->getRemoteDays($now)
->map(fn(Vacation $vacation): string => $vacation->user->profile->full_name);
$birthdays = $dailySummaryRetriever->getBirthdays($now)
->map(fn(User $user): string => $user->profile->full_name);
```
What if we would have five more activities? Maybe this could be encapsulated somehow? What if we would have five more activities? Maybe this could be encapsulated somehow?
What if we would have five more activities? Maybe this could be encapsulated somehow? What if we would have five more activities? Maybe this could be encapsulated somehow?
|
||||
$now = Carbon::today();
|
||||
|
||||
$absences = $dailySummaryRetriever->getAbsences($now)
|
||||
->map(fn(Vacation $vacation) => $vacation->user->profile->full_name);
|
||||
```suggestion
$absences = $dailySummaryRetriever->getAbsences($now)
->map(fn(Vacation $vacation): string => $vacation->user->profile->full_name);
$remoteDays = $dailySummaryRetriever->getRemoteDays($now)
->map(fn(Vacation $vacation): string => $vacation->user->profile->full_name);
$birthdays = $dailySummaryRetriever->getBirthdays($now)
->map(fn(User $user): string => $user->profile->full_name);
```
What if we would have five more activities? Maybe this could be encapsulated somehow? What if we would have five more activities? Maybe this could be encapsulated somehow?
|
||||
->map(fn(Vacation $vacation): string => $vacation->user->profile->full_name);
|
||||
```suggestion
$absences = $dailySummaryRetriever->getAbsences($now)
->map(fn(Vacation $vacation): string => $vacation->user->profile->full_name);
$remoteDays = $dailySummaryRetriever->getRemoteDays($now)
->map(fn(Vacation $vacation): string => $vacation->user->profile->full_name);
$birthdays = $dailySummaryRetriever->getBirthdays($now)
->map(fn(User $user): string => $user->profile->full_name);
```
What if we would have five more activities? Maybe this could be encapsulated somehow? What if we would have five more activities? Maybe this could be encapsulated somehow?
|
||||
|
||||
$remoteDays = $dailySummaryRetriever->getRemoteDays($now)
|
||||
->map(fn(Vacation $vacation) => $vacation->user->profile->full_name);
|
||||
```suggestion
$absences = $dailySummaryRetriever->getAbsences($now)
->map(fn(Vacation $vacation): string => $vacation->user->profile->full_name);
$remoteDays = $dailySummaryRetriever->getRemoteDays($now)
->map(fn(Vacation $vacation): string => $vacation->user->profile->full_name);
$birthdays = $dailySummaryRetriever->getBirthdays($now)
->map(fn(User $user): string => $user->profile->full_name);
```
What if we would have five more activities? Maybe this could be encapsulated somehow? What if we would have five more activities? Maybe this could be encapsulated somehow?
|
||||
->map(fn(Vacation $vacation): string => $vacation->user->profile->full_name);
|
||||
```suggestion
$absences = $dailySummaryRetriever->getAbsences($now)
->map(fn(Vacation $vacation): string => $vacation->user->profile->full_name);
$remoteDays = $dailySummaryRetriever->getRemoteDays($now)
->map(fn(Vacation $vacation): string => $vacation->user->profile->full_name);
$birthdays = $dailySummaryRetriever->getBirthdays($now)
->map(fn(User $user): string => $user->profile->full_name);
```
What if we would have five more activities? Maybe this could be encapsulated somehow? What if we would have five more activities? Maybe this could be encapsulated somehow?
|
||||
|
||||
$birthdays = $dailySummaryRetriever->getBirthdays($now)
|
||||
->map(fn(User $user) => $user->profile->full_name);
|
||||
```suggestion
$absences = $dailySummaryRetriever->getAbsences($now)
->map(fn(Vacation $vacation): string => $vacation->user->profile->full_name);
$remoteDays = $dailySummaryRetriever->getRemoteDays($now)
->map(fn(Vacation $vacation): string => $vacation->user->profile->full_name);
$birthdays = $dailySummaryRetriever->getBirthdays($now)
->map(fn(User $user): string => $user->profile->full_name);
```
What if we would have five more activities? Maybe this could be encapsulated somehow? What if we would have five more activities? Maybe this could be encapsulated somehow?
|
||||
->map(fn(User $user): string => $user->profile->full_name);
|
||||
```suggestion
$absences = $dailySummaryRetriever->getAbsences($now)
->map(fn(Vacation $vacation): string => $vacation->user->profile->full_name);
$remoteDays = $dailySummaryRetriever->getRemoteDays($now)
->map(fn(Vacation $vacation): string => $vacation->user->profile->full_name);
$birthdays = $dailySummaryRetriever->getBirthdays($now)
->map(fn(User $user): string => $user->profile->full_name);
```
What if we would have five more activities? Maybe this could be encapsulated somehow? What if we would have five more activities? Maybe this could be encapsulated somehow?
|
||||
|
||||
$absencesAttachment = Attachment::create()
|
||||
->setTitle("Nieobecności :sunny:")
|
||||
|
||||
```suggestion
$absences = $dailySummaryRetriever->getAbsences($now)
->map(fn(Vacation $vacation): string => $vacation->user->profile->full_name);
$remoteDays = $dailySummaryRetriever->getRemoteDays($now)
->map(fn(Vacation $vacation): string => $vacation->user->profile->full_name);
$birthdays = $dailySummaryRetriever->getBirthdays($now)
->map(fn(User $user): string => $user->profile->full_name);
```
```suggestion
$absences = $dailySummaryRetriever->getAbsences($now)
->map(fn(Vacation $vacation): string => $vacation->user->profile->full_name);
$remoteDays = $dailySummaryRetriever->getRemoteDays($now)
->map(fn(Vacation $vacation): string => $vacation->user->profile->full_name);
$birthdays = $dailySummaryRetriever->getBirthdays($now)
->map(fn(User $user): string => $user->profile->full_name);
```
What if we would have five more activities? Maybe this could be encapsulated somehow? What if we would have five more activities? Maybe this could be encapsulated somehow?
What if we would have five more activities? Maybe this could be encapsulated somehow? What if we would have five more activities? Maybe this could be encapsulated somehow?
|
||||