repo stringlengths 7 63 | file_url stringlengths 81 284 | file_path stringlengths 5 200 | content stringlengths 0 32.8k | language stringclasses 1 value | license stringclasses 7 values | commit_sha stringlengths 40 40 | retrieved_at stringdate 2026-01-04 15:02:33 2026-01-05 05:24:06 | truncated bool 2 classes |
|---|---|---|---|---|---|---|---|---|
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/tests/Feature/VacationEntitlementTest.php | tests/Feature/VacationEntitlementTest.php | <?php
namespace Tests\Feature;
use Carbon\Carbon;
use Tests\TestCase;
class VacationEntitlementTest extends TestCase
{
public function testCanCreateNotExpiringVacation()
{
Carbon::setTestNow(Carbon::parse('2020-01-01'));
}
}
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/tests/Feature/InviteLocationMemberTest.php | tests/Feature/InviteLocationMemberTest.php | <?php
namespace Tests\Feature;
use Tests\TestCase;
use App\Models\User;
use Livewire\Livewire;
use App\Models\Location;
use App\Mail\LocationInvitation;
use Illuminate\Support\Facades\Mail;
use Illuminate\Foundation\Testing\RefreshDatabase;
use App\Http\Livewire\Locations\LocationMemberManager;
class InviteLocationMemberTest extends TestCase
{
use RefreshDatabase;
public function test_members_can_be_invited_to_location()
{
Mail::fake();
$this->actingAs(
$user = User::factory([
'date_of_employment' => '2020-11-01 07:47:05',
'current_location_id' => $location = Location::factory()->create()
])->withOwnedAccount()->hasTargetHours([
'start_date' => '2020-11-01'
])->hasAttached($location, [
'role' => 'admin'
])->create()
);
Livewire::test(LocationMemberManager::class, ['location' => $user->currentLocation])
->set('addLocationMemberForm', [
'email' => 'test@example.com',
'role' => 'admin',
])->call('addLocationMember');
Mail::assertQueued(LocationInvitation::class);
$this->assertCount(1, $user->currentLocation->fresh()->locationInvitations);
}
public function test_member_invitations_can_be_cancelled()
{
$this->actingAs(
$user = User::factory([
'date_of_employment' => '2020-11-01 07:47:05',
])->withOwnedAccount()->hasTargetHours([
'start_date' => '2020-11-01'
])->hasAttached(Location::factory()->state(function (array $attributes, User $user) {
return ['owned_by' => $user->id];
}), [
'role' => 'admin'
])->create()
);
// Add the location member...
$component = Livewire::test(LocationMemberManager::class, ['location' => $user->locations()->first()])
->set('addLocationMemberForm', [
'email' => 'test@example.com',
'role' => 'admin',
])->call('addLocationMember');
$invitationId = $user->locations()->first()->locationInvitations->first()->id;
// Cancel the location invitation...
$component->call('cancelLocationInvitation', $invitationId);
$this->assertCount(0, $user->locations()->first()->locationInvitations);
}
}
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/tests/Feature/DeleteAbsenceTest.php | tests/Feature/DeleteAbsenceTest.php | <?php
namespace Tests\Feature;
use Tests\TestCase;
use App\Models\User;
use Livewire\Livewire;
use App\Models\Location;
use App\Http\Livewire\Absence\AbsenceManager;
class DeleteAbsenceTest extends TestCase
{
/**
* A basic feature test example.
*
* @return void
*/
public function test_can_delete_absence()
{
$this->actingAs($user = User::factory()->withOwnedAccount()->create());
$location = Location::factory()->create();
$location->users()->attach(
$user,
['role' => 'admin']
);
$user->switchLocation($location);
$absentType = $user->allLocations()->first()->absentTypes()->create([
'title' => 'Illness',
'location_id' => $user->allLocations()->first()->id,
'affect_vacation_times' => 1,
'affect_evaluations' => 1,
'evaluation_calculation_setting' => 'absent_to_target',
'regard_holidays' => 0,
'assign_new_users' => 0,
'remove_working_sessions_on_confirm' => 0
]);
$absentType->users()->sync($user);
$absence = $user->absences()->create([
'location_id' => $user->allLocations()->first()->id,
'vacation_days' => 2,
'paid_hours' => 16,
'starts_at' => '2020-12-12',
'ends_at' => '2020-12-12',
'full_day' => false,
'absence_type_id' => 1,
]);
Livewire::test(AbsenceManager::class, ['employee' => $user])->set([
'absenceIdBeingRemoved' => $absence->id
])->call('removeAbsence');
$this->assertCount(0, $user->fresh()->absences);
}
}
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/tests/Feature/AddTimeTrackingForOtherUserTest.php | tests/Feature/AddTimeTrackingForOtherUserTest.php | <?php
namespace Tests\Feature;
use Tests\TestCase;
use App\Models\User;
use Livewire\Livewire;
use App\Models\Location;
use App\Http\Livewire\TimeTracking\TimeTrackingManager;
class AddTimeTrackingForOtherUserTest extends TestCase
{
public function test_can_create_time_for_other_user()
{
$user = User::factory([
'date_of_employment' => '2020-11-01 07:47:05',
'current_location_id' => $location = Location::factory()->create()
])->withOwnedAccount()->hasTargetHours([
'start_date' => '2020-11-01'
])->hasAttached($location, [
'role' => 'admin'
])->create();
$location->users()->attach(
$otherUser = User::factory([
'current_location_id' => $location->id,
'date_of_employment' => '2020-11-01 07:47:05',
])->create(),
['role' => 'employee']
);
$this->actingAs($user);
Livewire::test(TimeTrackingManager::class)->set([
'managingTimeTrackingForId' => $otherUser->id,
'timeTrackingForm' => [
'description' => 'testing',
'date' => '17.11.2020',
'start_hour' => 9,
'start_minute' => 0,
'end_hour' => 17,
'end_minute' => 0
],
'pauseTimeForm' => [
[
'start_hour' => 12,
'start_minute' => 00,
'end_hour' => 12,
'end_minute' => 30
]
]
])->call('confirmAddTimeTracking');
$this->assertDatabaseHas('time_trackings', [
'user_id' => $otherUser->id,
'description' => 'testing'
]);
}
public function test_employee_cannot_create_time_for_other_user()
{
$user = User::factory([
'date_of_employment' => '2020-11-01 07:47:05',
'current_location_id' => $location = Location::factory()->create()
])->withOwnedAccount()->hasTargetHours([
'start_date' => '2020-11-01'
])->hasAttached($location, [
'role' => 'employee'
])->create();
$location->users()->attach(
$otherUser = User::factory([
'current_location_id' => $location->id,
'date_of_employment' => '2020-11-01 07:47:05',
])->create(),
['role' => 'employee']
);
$this->actingAs($user);
Livewire::test(TimeTrackingManager::class)->set([
'managingTimeTrackingForId' => $otherUser->id,
'timeTrackingForm' => [
'description' => 'testing',
'date' => '17.11.2020',
'start_hour' => 9,
'start_minute' => 0,
'end_hour' => 17,
'end_minute' => 0
],
'pauseTimeForm' => [
[
'start_hour' => 12,
'start_minute' => 00,
'end_hour' => 12,
'end_minute' => 30
]
]
])->call('confirmAddTimeTracking')->assertStatus(403);
$this->assertDatabaseCount('time_trackings', 0);
}
public function test_admin_cannot_create_time_for_other_location_user()
{
$user = User::factory([
'date_of_employment' => '2020-11-01 07:47:05',
'current_location_id' => $location = Location::factory()->create()
])->withOwnedAccount()->hasTargetHours([
'start_date' => '2020-11-01'
])->hasAttached($location, [
'role' => 'employee'
])->create();
$otherUser = User::factory([
'date_of_employment' => '2020-11-01 07:47:05',
'current_location_id' => $otherLocation = Location::factory()->create()
])->withOwnedAccount()->hasTargetHours([
'start_date' => '2020-11-01'
])->hasAttached($otherLocation, [
'role' => 'employee'
])->create();
$this->actingAs($user);
Livewire::test(TimeTrackingManager::class)->set([
'managingTimeTrackingForId' => $otherUser->id,
'timeTrackingForm' => [
'description' => 'testing',
'date' => '17.11.2020',
'start_hour' => 9,
'start_minute' => 0,
'end_hour' => 17,
'end_minute' => 0
],
'pauseTimeForm' => [
[
'start_hour' => 12,
'start_minute' => 00,
'end_hour' => 12,
'end_minute' => 30
]
]
])->call('confirmAddTimeTracking')->assertStatus(403);
$this->assertDatabaseCount('time_trackings', 0);
}
}
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/tests/Feature/AuthenticationTest.php | tests/Feature/AuthenticationTest.php | <?php
namespace Tests\Feature;
use Tests\TestCase;
use App\Models\User;
use App\Models\Location;
use App\Providers\RouteServiceProvider;
use Illuminate\Foundation\Testing\RefreshDatabase;
class AuthenticationTest extends TestCase
{
use RefreshDatabase;
public function test_login_screen_can_be_rendered()
{
$response = $this->get('/login');
$response->assertStatus(200);
}
public function test_users_can_authenticate_using_the_login_screen()
{
$user = User::factory()->create();
$location = Location::factory()->create();
$location->users()->attach(
$user,
['role' => 'admin']
);
$user->switchLocation($location);
$response = $this->post('/login', [
'email' => $user->email,
'password' => 'password',
]);
$this->assertAuthenticated();
$response->assertRedirect(RouteServiceProvider::HOME);
}
public function test_users_can_not_authenticate_with_invalid_password()
{
$user = User::factory()->create();
$this->post('/login', [
'email' => $user->email,
'password' => 'wrong-password',
]);
$this->assertGuest();
}
public function test_user_cannot_login_witout_associated_location()
{
$user = User::factory()
->create();
$response = $this->post('/login', [
'email' => $user->email,
'password' => 'password',
]);
$response->assertSessionHasErrors('email');
$this->assertGuest();
}
}
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/tests/Feature/TwoFactorAuthenticationSettingsTest.php | tests/Feature/TwoFactorAuthenticationSettingsTest.php | <?php
namespace Tests\Feature;
use App\Models\User;
use Illuminate\Foundation\Testing\RefreshDatabase;
use Laravel\Jetstream\Http\Livewire\TwoFactorAuthenticationForm;
use Livewire\Livewire;
use Tests\TestCase;
class TwoFactorAuthenticationSettingsTest extends TestCase
{
use RefreshDatabase;
public function test_two_factor_authentication_can_be_enabled()
{
$this->actingAs($user = User::factory()->create());
$this->withSession(['auth.password_confirmed_at' => time()]);
Livewire::test(TwoFactorAuthenticationForm::class)
->call('enableTwoFactorAuthentication');
$user = $user->fresh();
$this->assertNotNull($user->two_factor_secret);
$this->assertCount(8, $user->recoveryCodes());
}
public function test_recovery_codes_can_be_regenerated()
{
$this->actingAs($user = User::factory()->create());
$this->withSession(['auth.password_confirmed_at' => time()]);
$component = Livewire::test(TwoFactorAuthenticationForm::class)
->call('enableTwoFactorAuthentication')
->call('regenerateRecoveryCodes');
$user = $user->fresh();
$component->call('regenerateRecoveryCodes');
$this->assertCount(8, $user->recoveryCodes());
$this->assertCount(8, array_diff($user->recoveryCodes(), $user->fresh()->recoveryCodes()));
}
public function test_two_factor_authentication_can_be_disabled()
{
$this->actingAs($user = User::factory()->create());
$this->withSession(['auth.password_confirmed_at' => time()]);
$component = Livewire::test(TwoFactorAuthenticationForm::class)
->call('enableTwoFactorAuthentication');
$this->assertNotNull($user->fresh()->two_factor_secret);
$component->call('disableTwoFactorAuthentication');
$this->assertNull($user->fresh()->two_factor_secret);
}
}
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/tests/Feature/PasswordConfirmationTest.php | tests/Feature/PasswordConfirmationTest.php | <?php
namespace Tests\Feature;
use Tests\TestCase;
use App\Models\User;
use App\Models\Location;
use Laravel\Jetstream\Features;
use Illuminate\Foundation\Testing\RefreshDatabase;
class PasswordConfirmationTest extends TestCase
{
use RefreshDatabase;
public function test_confirm_password_screen_can_be_rendered()
{
$user = User::factory()->create();
$location = Location::factory()->create();
$location->users()->attach(
$user,
['role' => 'admin']
);
$user->switchLocation($location);
$response = $this->actingAs($user)->get('/user/confirm-password');
$response->assertStatus(200);
}
public function test_password_can_be_confirmed()
{
$user = User::factory()->create();
$response = $this->actingAs($user)->post('/user/confirm-password', [
'password' => 'password',
]);
$response->assertRedirect();
$response->assertSessionHasNoErrors();
}
public function test_password_is_not_confirmed_with_invalid_password()
{
$user = User::factory()->create();
$location = Location::factory()->create();
$location->users()->attach(
$user,
['role' => 'admin']
);
$user->switchLocation($location);
$response = $this->actingAs($user)->post('/user/confirm-password', [
'password' => 'wrong-password',
]);
$response->assertSessionHasErrors();
}
}
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/tests/Feature/ProfileInformationTest.php | tests/Feature/ProfileInformationTest.php | <?php
namespace Tests\Feature;
use App\Models\User;
use Illuminate\Foundation\Testing\RefreshDatabase;
use Laravel\Jetstream\Http\Livewire\UpdateProfileInformationForm;
use Livewire\Livewire;
use Tests\TestCase;
class ProfileInformationTest extends TestCase
{
use RefreshDatabase;
public function test_current_profile_information_is_available()
{
$this->actingAs($user = User::factory()->create());
$component = Livewire::test(UpdateProfileInformationForm::class);
$this->assertEquals($user->name, $component->state['name']);
$this->assertEquals($user->email, $component->state['email']);
}
public function test_profile_information_can_be_updated()
{
$this->actingAs($user = User::factory()->create());
Livewire::test(UpdateProfileInformationForm::class)
->set('state', ['name' => 'Test Name', 'email' => 'test@example.com'])
->call('updateProfileInformation');
$this->assertEquals('Test Name', $user->fresh()->name);
$this->assertEquals('test@example.com', $user->fresh()->email);
}
}
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/tests/Feature/PasswordResetTest.php | tests/Feature/PasswordResetTest.php | <?php
namespace Tests\Feature;
use App\Models\User;
use Illuminate\Auth\Notifications\ResetPassword;
use Illuminate\Foundation\Testing\RefreshDatabase;
use Illuminate\Support\Facades\Notification;
use Tests\TestCase;
class PasswordResetTest extends TestCase
{
use RefreshDatabase;
public function test_reset_password_link_screen_can_be_rendered()
{
$response = $this->get('/forgot-password');
$response->assertStatus(200);
}
public function test_reset_password_link_can_be_requested()
{
Notification::fake();
$user = User::factory()->create();
$response = $this->post('/forgot-password', [
'email' => $user->email,
]);
Notification::assertSentTo($user, ResetPassword::class);
}
public function test_reset_password_screen_can_be_rendered()
{
Notification::fake();
$user = User::factory()->create();
$response = $this->post('/forgot-password', [
'email' => $user->email,
]);
Notification::assertSentTo($user, ResetPassword::class, function ($notification) {
$response = $this->get('/reset-password/'.$notification->token);
$response->assertStatus(200);
return true;
});
}
public function test_password_can_be_reset_with_valid_token()
{
Notification::fake();
$user = User::factory()->create();
$response = $this->post('/forgot-password', [
'email' => $user->email,
]);
Notification::assertSentTo($user, ResetPassword::class, function ($notification) use ($user) {
$response = $this->post('/reset-password', [
'token' => $notification->token,
'email' => $user->email,
'password' => 'password',
'password_confirmation' => 'password',
]);
$response->assertSessionHasNoErrors();
return true;
});
}
}
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/tests/Feature/CreateLocationTest.php | tests/Feature/CreateLocationTest.php | <?php
namespace Tests\Feature;
use Tests\TestCase;
use App\Models\User;
use Livewire\Livewire;
use App\Http\Livewire\Locations\LocationManager;
use Illuminate\Foundation\Testing\RefreshDatabase;
class CreateLocationTest extends TestCase
{
use RefreshDatabase;
public function test_locations_can_be_created()
{
$this->actingAs(
$user = User::factory()
->withOwnedAccount()
->create()
);
Livewire::test(LocationManager::class, [
'account' => $user->ownedAccount,
'employee' => $user
])
->set([
'addLocationForm' => ['name' => 'Test Location']
])
->call('confirmAddLocation');
$this->assertEquals('Test Location', $user->fresh()->ownedLocations()->latest('id')->first()->name);
}
}
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/tests/Feature/AbsenceTest.php | tests/Feature/AbsenceTest.php | <?php
namespace Tests\Feature;
use Carbon\Carbon;
use Tests\TestCase;
use App\Models\User;
use Livewire\Livewire;
use App\Models\Location;
use App\Models\AbsenceType;
use App\Contracts\AddsAbsences;
use App\Contracts\ApprovesAbsence;
use Illuminate\Support\Facades\Bus;
use App\Contracts\AddsVacationEntitlements;
use App\Http\Livewire\Absence\AbsenceManager;
class AbsenceTest extends TestCase
{
protected $user;
protected $location;
public function setUp(): void
{
parent::setUp();
$this->user = User::factory([
'date_of_employment' => Carbon::make('2020-11-01'),
'current_location_id' => $this->location = Location::factory()->create()
])->withOwnedAccount()->hasTargetHours([
'start_date' => Carbon::make('2020-11-01')
])->hasAttached(
$this->location, [
'role' => 'admin'
]
)->create();
}
public function test_end_date_must_be_after_start_date()
{
$this->actingAs($this->user);
$absenceType = AbsenceType::factory([
'location_id' => $this->location->id,
])->create();
$absenceType->users()->sync($this->user);
Livewire::test(AbsenceManager::class)
->set(['addAbsenceForm' => [
'absence_type_id' => $absenceType->id,
'full_day' => false
]])->set([
'startDate' => "20.11.2020"
])->set([
'endDate' => "20.11.2020"
])->set([
'startHours' => 13
])->set([
'startMinutes' => 30
])->set([
'endHours' => 12
])->set([
'endMinutes' => 0
])->call('addAbsence')->assertHasErrors(['ends_at']);
}
public function test_can_create_half_day_vacation()
{
$this->actingAs($this->user);
$absenceType = AbsenceType::factory([
'location_id' => $this->location->id,
'title' => 'Urlaub',
'affect_vacation_times' => true,
'affect_evaluations' => true,
'evaluation_calculation_setting' => 'absent_to_target'
])->create();
$absenceType->users()->sync($this->user);
Livewire::test(AbsenceManager::class)
->set(['addAbsenceForm' => [
'absence_type_id' => $absenceType->id,
'full_day' => false
]])->set(['hideTime' => false])
->set([
'startDate' => "20.11.2020"
])->set([
'endDate' => "20.11.2020"
])->set([
'startHours' => 14
])->set([
'startMinutes' => 00
])->set([
'endHours' => 18
])->set([
'endMinutes' => 00
])->call('addAbsence');
$this->assertDatabaseHas('absences',[
'absence_type_id' => $absenceType->id,
'vacation_days' => 0.5,
'paid_hours' => 4
]);
}
public function test_can_create_half_day_vacation_for_less_than_a_half_day()
{
$this->actingAs($this->user);
$absenceType = AbsenceType::factory([
'location_id' => $this->location->id,
'title' => 'Urlaub',
'affect_vacation_times' => true,
'affect_evaluations' => true,
'evaluation_calculation_setting' => 'absent_to_target'
])->create();
$absenceType->users()->sync($this->user);
Livewire::test(AbsenceManager::class)
->set(['addAbsenceForm' => [
'absence_type_id' => $absenceType->id,
'full_day' => false
]])->set(['hideTime' => false])
->set([
'startDate' => "20.11.2020"
])->set([
'endDate' => "20.11.2020"
])->set([
'startHours' => 14
])->set([
'startMinutes' => 00
])->set([
'endHours' => 16
])->set([
'endMinutes' => 30
])->call('addAbsence');
$this->assertDatabaseHas('absences',[
'absence_type_id' => $absenceType->id,
'vacation_days' => 0.5,
'paid_hours' => 2.5
]);
}
public function test_can_create_half_days_vacation()
{
$this->actingAs($this->user);
$absenceType = AbsenceType::forceCreate([
'location_id' => $this->location->id,
'title' => 'Urlaub',
'affect_vacation_times' => true,
'affect_evaluations' => true,
'evaluation_calculation_setting' => 'absent_to_target'
]);
$absenceType->users()->sync($this->user);
Livewire::test(AbsenceManager::class)
->set(['addAbsenceForm' => [
'absence_type_id' => $absenceType->id,
'full_day' => false
]])->set(['hideTime' => false])
->set([
'startDate' => "19.11.2020"
])->set([
'endDate' => "20.11.2020"
])->set([
'startHours' => 22
])->set([
'startMinutes' => 00
])->set([
'endHours' => 2
])->set([
'endMinutes' => 30
])->call('addAbsence');
$this->assertDatabaseHas('absences',[
'absence_type_id' => $absenceType->id,
'vacation_days' => 1,
'paid_hours' => 4.5
]);
}
public function test_can_create_three_days_illness()
{
$this->actingAs($this->user);
$absenceType = AbsenceType::forceCreate([
'location_id' => $this->location->id,
'title' => 'Krankheit',
'affect_vacation_times' => false,
'affect_evaluations' => true,
'evaluation_calculation_setting' => 'absent_to_target'
]);
$absenceType->users()->sync($this->user);
Livewire::test(AbsenceManager::class)
->set(['addAbsenceForm' => [
'absence_type_id' => $absenceType->id,
'full_day' => false
]])->set(['hideTime' => false])
->set([
'startDate' => "18.11.2020"
])->set([
'endDate' => "20.11.2020"
])->set([
'startHours' => 22
])->set([
'startMinutes' => 00
])->set([
'endHours' => 2
])->set([
'endMinutes' => 30
])->call('addAbsence');
$this->assertDatabaseHas('absences',[
'absence_type_id' => $absenceType->id,
'vacation_days' => 0,
'paid_hours' => 12.5
]);
}
public function test_can_create_half_day_illness()
{
$this->actingAs($this->user);
$absenceType = AbsenceType::forceCreate([
'location_id' => $this->location->id,
'title' => 'Krankheit',
'affect_vacation_times' => false,
'affect_evaluations' => true,
'evaluation_calculation_setting' => 'absent_to_target'
]);
$absenceType->users()->sync($this->user);
Livewire::test(AbsenceManager::class)
->set(['addAbsenceForm' => [
'absence_type_id' => $absenceType->id,
'full_day' => false
]])->set(['hideTime' => false])
->set([
'startDate' => "20.11.2020"
])->set([
'endDate' => "20.11.2020"
])->set([
'startHours' => 14
])->set([
'startMinutes' => 00
])->set([
'endHours' => 16
])->set([
'endMinutes' => 30
])->call('addAbsence');
$this->assertDatabaseHas('absences',[
'absence_type_id' => $absenceType->id,
'paid_hours' => 2.5,
'vacation_days' => 0
]);
}
public function test_can_approve_two_week_vacation()
{
$this->actingAs($this->user);
$this->travelTo($this->user->date_of_employment);
$absenceType = AbsenceType::forceCreate([
'location_id' => $this->location->id,
'title' => 'Urlaub',
'affect_vacation_times' => true,
'affect_evaluations' => true,
'evaluation_calculation_setting' => 'absent_to_target'
]);
$absenceType->users()->sync($this->user);
$action = app(AddsVacationEntitlements::class);
$action->add($this->user, [
'name' => 'Jahresurlaub',
'starts_at' => '01.01.2020',
'ends_at' => '31.12.2020',
'days' => 30,
'expires' => true,
'transfer_remaining' => 0,
'end_of_transfer_period' => '01.03.2021'
]);
$action = app(AddsAbsences::class);
$action->add($this->user, $this->location, $this->user->id, [
'absence_type_id' => $absenceType->id,
'starts_at' => '20.11.2020 14:00',
'ends_at' => '27.11.2020 16:30',
'full_day' => true
]);
$this->assertDatabaseHas('absences',[
'absence_type_id' => $absenceType->id,
'paid_hours' => 48,
'vacation_days' => 6,
'status' => 'pending'
]);
Bus::fake();
$action = app(ApprovesAbsence::class);
$action->approve(
$this->user,
$this->location,
$this->user->absences->first()->id
);
$this->assertDatabaseHas('absences',[
'absence_type_id' => $absenceType->id,
'paid_hours' => 48,
'vacation_days' => 6,
'status' => 'confirmed'
]);
}
}
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/tests/Feature/DefaultRestingTimeTest.php | tests/Feature/DefaultRestingTimeTest.php | <?php
namespace Tests\Feature;
use Carbon\Carbon;
use Tests\TestCase;
use App\Models\User;
use App\Models\Duration;
use App\Models\Location;
use App\Models\TimeTracking;
use App\Actions\AddTimeTracking;
use App\Formatter\DateFormatter;
use App\Contracts\AddsTimeTrackings;
use App\Contracts\AddsDefaultRestingTime;
class DefaultRestingTimeTest extends TestCase
{
protected $user;
protected $location;
protected $dateFormatter;
public function setUp(): void
{
parent::setUp();
$this->dateFormatter = app(DateFormatter::class);
$this->user = User::factory([
'date_of_employment' => Carbon::make('2020-11-01'),
'current_location_id' => $this->location = Location::factory()->create()
])->withOwnedAccount()->hasTargetHours([
'start_date' => Carbon::make('2020-11-01')
])->hasAttached(
$this->location, [
'role' => 'admin'
]
)->create();
}
public function test_creates_default_resting_time()
{
$action = app(AddsDefaultRestingTime::class);
$action->add($this->location, [
'min_hours' => new Duration(21600), //6*60*60
'duration' => new Duration(1800) //30*60
]);
$action->add($this->location, [
'min_hours' => new Duration(39600), //11*60*60
'duration' => new Duration(2700) //45*60
]);
$this->assertDatabaseHas('default_resting_times',[
'min_hours' => '21600',
'location_id' => $this->location->id
]);
$this->assertDatabaseHas('default_resting_time_users',[
'user_id' => $this->user->id
]);
}
public function test_adds_default_resting_time_to_time_tracking()
{
$action = app(AddsDefaultRestingTime::class);
$action->add($this->location, [
'min_hours' => new Duration(21600), //6*60*60
'duration' => new Duration(1800) //30*60
]);
$action = app(AddsTimeTrackings::class);
$action->add($this->user, $this->location, $this->user->id, [
'starts_at' => $this->dateFormatter->formatDateTimeForView(Carbon::make('2020-11-17 09:00')),
'ends_at' => $this->dateFormatter->formatDateTimeForView(Carbon::make('2020-11-17 17:00')),
],[]);
$timeTracking = TimeTracking::where('starts_at','2020-11-17 09:00:00')->first();
$this->assertSame("1800", (string) $timeTracking->pause_time->inSeconds());
}
public function test_do_not_add_default_resting_time_if_pause_time_has_been_given()
{
$action = app(AddsDefaultRestingTime::class);
$action->add($this->location, [
'min_hours' => new Duration(21600), //6*60*60
'duration' => new Duration(1800) //30*60
]);
$action = app(AddsTimeTrackings::class);
$action->add($this->user, $this->location, $this->user->id, [
'starts_at' => $this->dateFormatter->formatDateTimeForView(Carbon::make('2020-11-17 09:00')),
'ends_at' => $this->dateFormatter->formatDateTimeForView(Carbon::make('2020-11-17 17:00')),
],[
[
'starts_at' => $this->dateFormatter->formatDateTimeForView(Carbon::make('2020-11-17 10:00')),
'ends_at' => $this->dateFormatter->formatDateTimeForView(Carbon::make('2020-11-17 10:15')),
]
]);
$timeTracking = TimeTracking::where('starts_at','2020-11-17 09:00:00')->first();
$this->assertSame("900", (string) $timeTracking->pause_time->inSeconds());
}
}
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/tests/Feature/UpdateTimeTrackingTest.php | tests/Feature/UpdateTimeTrackingTest.php | <?php
namespace Tests\Feature;
use Carbon\Carbon;
use Tests\TestCase;
use App\Models\User;
use App\Models\Location;
use App\Models\TimeTracking;
use App\Http\Livewire\TimeTracking\TimeTrackingManager;
use Livewire\Livewire;
class UpdateTimeTrackingTest extends TestCase
{
protected $user;
public function setUp(): void
{
parent::setUp();
$this->user = User::factory([
"date_of_employment" => Carbon::make('2020-11-16')
])->hasTargetHours([
"start_date" => Carbon::make('2020-11-16')
])->create();
$location = Location::factory()->create();
$location->users()->attach(
$this->user,
['role' => 'admin']
);
$this->user->switchLocation($location);
}
public function test_creates_time_in_correct_format()
{
$this->actingAs($this->user);
$timeTracking = TimeTracking::factory([
'user_id' => $this->user,
'location_id' => $this->user->currentLocation
])->create();
Livewire::test(TimeTrackingManager::class)->set([
'timeTrackingIdBeingUpdated' => $timeTracking->id,
'timeTrackingForm' => [
'description' => 'updated',
'date' => '17.11.2020',
'start_hour' => 9,
'start_minute' => 0,
'end_hour' => 17,
'end_minute' => 0
],
'pauseTimeForm' => [
[
'start_hour' => 12,
'start_minute' => 00,
'end_hour' => 12,
'end_minute' => 30
]
]
])->call('confirmUpdateTimeTracking');
$this->assertDatabaseHas('time_trackings', [
'user_id' => $this->user->id,
'starts_at' => '2020-11-17 09:00:00',
'pause_time' => 1800
]);
}
}
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/tests/Feature/ApiTokenPermissionsTest.php | tests/Feature/ApiTokenPermissionsTest.php | <?php
namespace Tests\Feature;
use App\Models\User;
use Illuminate\Foundation\Testing\RefreshDatabase;
use Illuminate\Support\Str;
use Laravel\Jetstream\Features;
use Laravel\Jetstream\Http\Livewire\ApiTokenManager;
use Livewire\Livewire;
use Tests\TestCase;
class ApiTokenPermissionsTest extends TestCase
{
use RefreshDatabase;
public function test_api_token_permissions_can_be_updated()
{
if (! Features::hasApiFeatures()) {
return $this->markTestSkipped('API support is not enabled.');
}
$this->actingAs($user = User::factory()->withPersonalTeam()->create());
$token = $user->tokens()->create([
'name' => 'Test Token',
'token' => Str::random(40),
'abilities' => ['create', 'read'],
]);
Livewire::test(ApiTokenManager::class)
->set(['managingPermissionsFor' => $token])
->set(['updateApiTokenForm' => [
'permissions' => [
'delete',
'missing-permission',
],
]])
->call('updateApiToken');
$this->assertTrue($user->fresh()->tokens->first()->can('delete'));
$this->assertFalse($user->fresh()->tokens->first()->can('read'));
$this->assertFalse($user->fresh()->tokens->first()->can('missing-permission'));
}
}
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/tests/Feature/HolidayTest.php | tests/Feature/HolidayTest.php | <?php
namespace Tests\Feature;
use App\Contracts\AddsPublicHoliday;
use Carbon\Carbon;
use Tests\TestCase;
use App\Models\User;
use App\Models\Account;
use App\Models\Location;
use App\Contracts\ImportsPublicHolidays;
class HolidayTest extends TestCase
{
public $user;
public $location;
public $account;
public function setUp(): void
{
parent::setUp();
$this->user = User::factory()->hasTargetHours([
"start_date" => Carbon::make('2020-11-16')
])->create();
$this->account = Account::forceCreate([
'owned_by' => $this->user->id,
'name' => "Account"
]);
$this->location = Location::forceCreate([
'account_id' => $this->account->id,
'owned_by' => $this->user->id,
'name' => "A Location",
'locale' => 'de',
'time_zone' => 'Europe/Berlin',
]);
}
/**
* A basic feature test example.
*
* @return void
*/
public function testRetrieveHolidays()
{
//will be green for mysql database
$this->markTestSkipped();
$action = app(ImportsPublicHolidays::class);
$action->import($this->location, 2020, "NW");
$this->assertDatabaseHas('public_holidays', [
"title" => "1. Weihnachtstag",
"day" => "2020-12-25"
]);
}
public function testCreatePublicHoliday()
{
/**
* @var AddsPublicHoliday
*/
$action = app(AddsPublicHoliday::class);
$action->add($this->location, [
'name' => 'TestHoliday',
'date' => '02.02.2020',
'half_day' => false
]);
$this->assertDatabaseHas('public_holidays', [
"title" => "TestHoliday",
"day" => "2020-02-02 00:00:00"
]);
}
}
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/tests/Feature/ChangeTimeTrackingForOtherUserTest.php | tests/Feature/ChangeTimeTrackingForOtherUserTest.php | <?php
namespace Tests\Feature;
use Tests\TestCase;
use App\Models\User;
use Livewire\Livewire;
use App\Models\Location;
use App\Http\Livewire\TimeTracking\TimeTrackingManager;
class ChangeTimeTrackingForOtherUserTest extends TestCase
{
/**
* A basic feature test example.
*
* @return void
*/
public function test_can_change_time_for_other_user()
{
$user = User::factory([
'date_of_employment' => '2020-11-01 07:47:05',
'current_location_id' => $location = Location::factory()->create()
])->withOwnedAccount()->hasTargetHours([
'start_date' => '2020-11-01'
])->hasAttached($location, [
'role' => 'admin'
])->create();
$location->users()->attach(
$otherUser = User::factory([
'current_location_id' => $location->id,
'date_of_employment' => '2020-11-01 07:47:05',
])->create(),
['role' => 'admin']
);
$timeTracking = $user->timeTrackings()->create([
'location_id' => $location->id,
'starts_at' => '2020-11-01 08:00:00',
'ends_at' => '2020-11-01 17:00:00'
]);
$this->actingAs($otherUser);
Livewire::test(TimeTrackingManager::class)->set([
'managingTimeTrackingForId' => $user->id,
'timeTrackingIdBeingUpdated' => $timeTracking->id,
'timeTrackingForm' => [
'description' => 'testing',
'date' => '01.11.2020',
'start_hour' => 9,
'start_minute' => 0,
'end_hour' => 17,
'end_minute' => 0
],
'pauseTimeForm' => [
[
'start_hour' => 12,
'start_minute' => 00,
'end_hour' => 12,
'end_minute' => 30
]
]
])->call('confirmUpdateTimeTracking');
$this->assertDatabaseHas('time_trackings', [
'user_id' => $user->id,
'starts_at' => '2020-11-01 09:00:00'
]);
}
/**
* A basic feature test example.
*
* @return void
*/
public function test_employee_cannot_change_time_for_other_user()
{
$user = User::factory([
'date_of_employment' => '2020-11-01 07:47:05',
'current_location_id' => $location = Location::factory()->create()
])->withOwnedAccount()->hasTargetHours([
'start_date' => '2020-11-01'
])->hasAttached($location, [
'role' => 'admin'
])->create();
$location->users()->attach(
$otherUser = User::factory([
'current_location_id' => $location->id,
'date_of_employment' => '2020-11-01 07:47:05',
])->create(),
['role' => 'employee']
);
$timeTracking = $user->timeTrackings()->create([
'location_id' => $location->id,
'starts_at' => '2020-11-01 08:00:00',
'ends_at' => '2020-11-01 17:00:00'
]);
$this->actingAs($otherUser);
Livewire::test(TimeTrackingManager::class)->set([
'managingTimeTrackingForId' => $user->id,
'timeTrackingIdBeingUpdated' => $timeTracking->id,
'timeTrackingForm' => [
'description' => 'testing',
'date' => '01.11.2020',
'start_hour' => 9,
'start_minute' => 0,
'end_hour' => 17,
'end_minute' => 0
],
'pauseTimeForm' => [
[
'start_hour' => 12,
'start_minute' => 00,
'end_hour' => 12,
'end_minute' => 30
]
]
])->call('confirmUpdateTimeTracking')->assertStatus(403);
$this->assertDatabaseHas('time_trackings', [
'user_id' => $user->id,
'starts_at' => '2020-11-01 08:00:00'
]);
}
public function test_admin_cannot_create_time_for_other_location_user()
{
$user = User::factory([
'date_of_employment' => '2020-11-01 07:47:05',
'current_location_id' => $location = Location::factory()->create()
])->withOwnedAccount()->hasTargetHours([
'start_date' => '2020-11-01'
])->hasAttached($location, [
'role' => 'employee'
])->create();
$otherUser = User::factory([
'date_of_employment' => '2020-11-01 07:47:05',
'current_location_id' => $otherLocation = Location::factory()->create()
])->withOwnedAccount()->hasTargetHours([
'start_date' => '2020-11-01'
])->hasAttached($otherLocation, [
'role' => 'employee'
])->create();
$timeTracking = $user->timeTrackings()->create([
'location_id' => $location->id,
'starts_at' => '2020-11-01 08:00:00',
'ends_at' => '2020-11-01 17:00:00'
]);
$this->actingAs($otherUser);
Livewire::test(TimeTrackingManager::class)->set([
'managingTimeTrackingForId' => $user->id,
'timeTrackingIdBeingUpdated' => $timeTracking->id,
'timeTrackingForm' => [
'description' => 'testing',
'date' => '01.11.2020',
'start_hour' => 9,
'start_minute' => 0,
'end_hour' => 17,
'end_minute' => 0
],
'pauseTimeForm' => [
[
'start_hour' => 12,
'start_minute' => 00,
'end_hour' => 12,
'end_minute' => 30
]
]
])->call('confirmUpdateTimeTracking')->assertStatus(403);
$this->assertDatabaseHas('time_trackings', [
'user_id' => $user->id,
'starts_at' => '2020-11-01 08:00:00'
]);
}
}
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/tests/Feature/DeleteLocationTest.php | tests/Feature/DeleteLocationTest.php | <?php
namespace Tests\Feature;
use Tests\TestCase;
use App\Models\User;
use Livewire\Livewire;
use App\Models\Location;
use App\Http\Livewire\Locations\LocationManager;
use Illuminate\Foundation\Testing\RefreshDatabase;
class DeleteLocationTest extends TestCase
{
use RefreshDatabase;
public function test_locations_can_be_deleted()
{
$this->actingAs(
$user = User::factory()
->withOwnedAccount()
->create()
);
$user->ownedLocations()
->save($location = Location::factory()->make());
$location->users()->attach(
$otherUser = User::factory()->create(),
['role' => 'test-role']
);
Livewire::test(LocationManager::class, [
'account' => $user->ownedAccount,
'employee' => $user
])->set([
'locationIdBeingRemoved' => $location->id
])->call('removeLocation');
$this->assertNull($location->fresh());
$this->assertCount(0, $otherUser->fresh()->locations);
}
}
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/tests/Feature/TimeTrackingTest.php | tests/Feature/TimeTrackingTest.php | <?php
namespace Tests\Feature;
use Carbon\Carbon;
use Tests\TestCase;
use App\Models\User;
use Livewire\Livewire;
use App\Models\Location;
use App\Actions\AddTimeTracking;
use App\Formatter\DateFormatter;
use App\Http\Livewire\TimeTracking\TimeTrackingManager;
class TimeTrackingTest extends TestCase
{
protected $user;
protected $location;
protected $dateFormatter;
public function setUp(): void
{
parent::setUp();
$this->dateFormatter = app(DateFormatter::class);
$this->user = User::factory([
'date_of_employment' => Carbon::make('2020-11-01'),
'current_location_id' => $this->location = Location::factory()->create()
])->withOwnedAccount()->hasTargetHours([
'start_date' => Carbon::make('2020-11-01')
])->hasAttached(
$this->location, [
'role' => 'admin'
]
)->create();
}
public function test_creates_time_in_correct_format()
{
$this->actingAs($this->user);
Livewire::test(TimeTrackingManager::class)->set([
'timeTrackingForm' => [
'description' => 'testing',
'date' => '17.11.2020',
'start_hour' => 9,
'start_minute' => 0,
'end_hour' => 17,
'end_minute' => 0
],
'pauseTimeForm' => [
[
'start_hour' => 12,
'start_minute' => 00,
'end_hour' => 12,
'end_minute' => 30
]
]
])->call('confirmAddTimeTracking');
$this->assertDatabaseHas('time_trackings', [
'user_id' => $this->user->id,
'starts_at' => '2020-11-17 09:00:00',
'pause_time' => 1800
]);
}
public function test_creates_correct_durations()
{
$this->actingAs($this->user);
$minutesDecimaArray = [
'01' => '0.02',
'02' => '0.03',
'03' => '0.05',
'04' => '0.07',
'05' => '0.08',
'06' => '0.10',
'07' => '0.12',
'08' => '0.13',
'09' => '0.15',
'10' => '0.17',
'11' => '0.18',
'12' => '0.20',
'13' => '0.22',
'14' => '0.23',
'15' => '0.25',
'16' => '0.27',
'17' => '0.28',
'18' => '0.30',
'19' => '0.32',
'20' => '0.33',
'21' => '0.35',
'22' => '0.37',
'23' => '0.38',
'24' => '0.40',
'25' => '0.42',
'26' => '0.43',
'27' => '0.45',
'28' => '0.47',
'29' => '0.48',
'30' => '0.50',
'31' => '0.52',
'32' => '0.53',
'33' => '0.55',
'34' => '0.57',
'35' => '0.58',
'36' => '0.60',
'37' => '0.62',
'38' => '0.63',
'39' => '0.65',
'40' => '0.67',
'41' => '0.68',
'42' => '0.70',
'43' => '0.72',
'44' => '0.73',
'45' => '0.75',
'46' => '0.77',
'47' => '0.78',
'48' => '0.80',
'49' => '0.82',
'50' => '0.83',
'51' => '0.85',
'52' => '0.87',
'53' => '0.88',
'54' => '0.90',
'55' => '0.92',
'56' => '0.93',
'57' => '0.95',
'58' => '0.97',
'59' => '0.98'
];
foreach ($minutesDecimaArray as $minutes => $decimal) {
$action = app(AddTimeTracking::class);
$action->add($this->user, $this->location, $this->user->id, [
'starts_at' => $this->dateFormatter->formatDateTimeForView(Carbon::make('2020-11-17 09:00')),
'ends_at' => $this->dateFormatter->formatDateTimeForView(Carbon::make("2020-11-17 09:{$minutes}"))
],[]);
/**
* @var TimeTracking
*/
$time = $this->user->timeTrackings()->where([
'starts_at' => '2020-11-17 09:00:00',
'ends_at' => '2020-11-17 09:'.$minutes.':00',
])->first();
$this->assertEquals($decimal, $time->balance);
$time->delete();
}
}
}
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/tests/Feature/CreateApiTokenTest.php | tests/Feature/CreateApiTokenTest.php | <?php
namespace Tests\Feature;
use App\Models\User;
use Illuminate\Foundation\Testing\RefreshDatabase;
use Laravel\Jetstream\Features;
use Laravel\Jetstream\Http\Livewire\ApiTokenManager;
use Livewire\Livewire;
use Tests\TestCase;
class CreateApiTokenTest extends TestCase
{
use RefreshDatabase;
public function test_api_tokens_can_be_created()
{
if (! Features::hasApiFeatures()) {
return $this->markTestSkipped('API support is not enabled.');
}
$this->actingAs($user = User::factory()->withPersonalTeam()->create());
Livewire::test(ApiTokenManager::class)
->set(['createApiTokenForm' => [
'name' => 'Test Token',
'permissions' => [
'read',
'update',
],
]])
->call('createApiToken');
$this->assertCount(1, $user->fresh()->tokens);
$this->assertEquals('Test Token', $user->fresh()->tokens->first()->name);
$this->assertTrue($user->fresh()->tokens->first()->can('read'));
$this->assertFalse($user->fresh()->tokens->first()->can('delete'));
}
}
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/tests/Feature/UpdatePasswordTest.php | tests/Feature/UpdatePasswordTest.php | <?php
namespace Tests\Feature;
use App\Models\User;
use Illuminate\Foundation\Testing\RefreshDatabase;
use Illuminate\Support\Facades\Hash;
use Laravel\Jetstream\Http\Livewire\UpdatePasswordForm;
use Livewire\Livewire;
use Tests\TestCase;
class UpdatePasswordTest extends TestCase
{
use RefreshDatabase;
public function test_password_can_be_updated()
{
$this->actingAs($user = User::factory()->create());
Livewire::test(UpdatePasswordForm::class)
->set('state', [
'current_password' => 'password',
'password' => 'new-password',
'password_confirmation' => 'new-password',
])
->call('updatePassword');
$this->assertTrue(Hash::check('new-password', $user->fresh()->password));
}
public function test_current_password_must_be_correct()
{
$this->actingAs($user = User::factory()->create());
Livewire::test(UpdatePasswordForm::class)
->set('state', [
'current_password' => 'wrong-password',
'password' => 'new-password',
'password_confirmation' => 'new-password',
])
->call('updatePassword')
->assertHasErrors(['current_password']);
$this->assertTrue(Hash::check('password', $user->fresh()->password));
}
public function test_new_passwords_must_match()
{
$this->actingAs($user = User::factory()->create());
Livewire::test(UpdatePasswordForm::class)
->set('state', [
'current_password' => 'password',
'password' => 'new-password',
'password_confirmation' => 'wrong-password',
])
->call('updatePassword')
->assertHasErrors(['password']);
$this->assertTrue(Hash::check('password', $user->fresh()->password));
}
}
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/tests/Feature/UpdateLocationMemberRoleTest.php | tests/Feature/UpdateLocationMemberRoleTest.php | <?php
namespace Tests\Feature;
use Tests\TestCase;
use App\Models\User;
use Livewire\Livewire;
use App\Models\Location;
use Illuminate\Foundation\Testing\RefreshDatabase;
use App\Http\Livewire\Locations\LocationMemberManager;
class UpdateLocationMemberRoleTest extends TestCase
{
use RefreshDatabase;
public function test_location_member_roles_can_be_updated()
{
$this->actingAs(
$user = User::factory()
->withOwnedAccount()
->create()
);
$location = $user->ownedLocations()
->save(Location::factory()->make());
$location->users()->attach(
$otherUser = User::factory()->create(),
['role' => 'admin']
);
$component = Livewire::test(LocationMemberManager::class, ['location' => $location->fresh()])
->set('managingRoleFor', $otherUser)
->set('currentRole', 'employee')
->call('updateRole');
$this->assertTrue($otherUser->fresh()->hasLocationRole(
$location,
'employee'
));
}
public function test_only_location_admin_can_update_location_owner_roles()
{
$user = User::factory()
->withOwnedAccount()
->create();
$location = $user->ownedLocations()
->save(Location::factory()->make());
$location->users()->attach(
$otherUser = User::factory()->create(),
['role' => 'employee']
);
$this->actingAs($otherUser);
$component = Livewire::test(LocationMemberManager::class, ['location' => $location->fresh()])
->set('managingRoleFor', $otherUser)
->set('currentRole', 'admin')
->call('updateRole')
->assertStatus(403);
$this->assertTrue(
$otherUser->fresh()->hasLocationRole($location, 'employee')
);
}
}
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/tests/Feature/RegistrationTest.php | tests/Feature/RegistrationTest.php | <?php
namespace Tests\Feature;
use Tests\TestCase;
use App\Models\User;
use App\Models\Account;
use App\Models\Location;
use Laravel\Jetstream\Jetstream;
use App\Providers\RouteServiceProvider;
use Illuminate\Foundation\Testing\RefreshDatabase;
class RegistrationTest extends TestCase
{
use RefreshDatabase;
public function test_registration_screen_can_be_rendered()
{
$response = $this->get('/register');
$response->assertStatus(200);
}
public function test_new_users_can_register()
{
$response = $this->post('/register', [
'name' => 'Test User',
'email' => 'test@example.com',
'password' => 'password',
'password_confirmation' => 'password',
'terms' => Jetstream::hasTermsAndPrivacyPolicyFeature() ? true : false,
]);
$this->assertAuthenticated();
$response->assertRedirect(RouteServiceProvider::HOME);
$this->assertDatabaseHas("accounts",[
'name' => "Test's Account"
]);
$this->assertDatabaseHas("locations",[
'name' => "Test's Location"
]);
$this->assertDatabaseHas("users",[
'name' => "Test User"
]);
//assert correct user relationships
$user = Jetstream::findUserByEmailOrFail('test@example.com')->with(['currentLocation.account'])->firstOrFail();
// user is assigned to new location - has role for laction?
$this->assertInstanceOf(Location::class, $user->currentLocation);
// location is assigned to Account
$this->assertInstanceOf(Account::class, $user->currentLocation->account);
// user owns new account
$account = $user->ownedAccount;
$this->assertInstanceOf(Account::class, $account);
}
}
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/tests/Feature/EvaluationTest.php | tests/Feature/EvaluationTest.php | <?php
namespace Tests\Feature;
use App\Daybreak;
use Carbon\Carbon;
use Tests\TestCase;
use App\Models\User;
use App\Report\Report;
use App\Models\Absence;
use App\Models\Account;
use App\Models\Location;
use App\Models\AbsenceType;
use App\Contracts\AddsAbsences;
use App\Contracts\AddsVacationEntitlements;
use App\Contracts\ApprovesAbsence;
use Illuminate\Support\Facades\Bus;
use App\Contracts\FiltersEvaluation;
use Daybreak\Caldav\Jobs\CreateCaldavEvent;
class EvaluationTest extends TestCase
{
public $user;
public $account;
public $location;
public function setUp(): void
{
parent::setUp();
$this->user = User::factory([
"date_of_employment" => '2020-11-16'
])->hasTargetHours([
"start_date" => Carbon::make('2020-11-16')
])->create();
$this->account = Account::forceCreate([
'owned_by' => $this->user->id,
'name' => "Account"
]);
$this->location = Location::forceCreate([
'account_id' => $this->account->id,
'owned_by' => $this->user->id,
'name' => "A Location",
'locale' => 'de',
'time_zone' => 'Europe/Berlin'
]);
$this->user->switchLocation($this->location);
}
//Krankheit
public function test_can_submit_fullday_illness()
{
$absenceType = AbsenceType::forceCreate([
'location_id' => $this->location->id,
'title' => 'Krankheit',
'affect_vacation_times' => false,
'affect_evaluations' => true,
'evaluation_calculation_setting' => 'absent_to_target'
]);
$this->user->absenceTypes()->sync($absenceType);
/**
* @var AddsAbsences
*/
$action = app(AddsAbsences::class);
$action->add($this->user, $this->location, $this->user->id, [
'absence_type_id' => $absenceType->id,
'starts_at' => '20.11.2020 00:00',
'ends_at' => '20.11.2020 00:00',
'full_day' => true,
'status' => 'confirmed'
]);
$this->assertDatabaseHas('absences', [
'starts_at' => '2020-11-20 00:00:00',
'ends_at' => '2020-11-20 23:59:59'
]);
Bus::fake();
/**
* @var ApprovesAbsence
*/
$approver = app(ApprovesAbsence::class);
$approver->approve(
$this->user,
$this->location,
Absence::first()->id
);
$this->assertDatabaseHas("absence_index",[
'date' => '2020-11-20 00:00:00',
'hours' => 8,
]);
if (Daybreak::hasCaldavFeature()) {
Bus::assertDispatched(CreateCaldavEvent::class);
}
/**
* @var FiltersEvaluation
*/
$action = app(FiltersEvaluation::class);
/**
* @var Report
*/
$report = $action->filter(
$this->user,
$this->location,
[
'fromDate' => '20.11.2020',
'toDate' => '20.11.2020'
]
);
$this->assertTrue(
$report->reportRows->first()->generate()->plannedHours()->isEqualTo(
$report->reportRows->first()->generate()->absentHours()
)
);
$this->assertEquals(
'0',
(string) $report->reportRows->first()->generate()->diff()
);
}
//Überstunden
//Urlaub
public function test_can_use_vacation_entitlement()
{
$this->travelTo($this->user->date_of_employment);
$absenceType = AbsenceType::forceCreate([
'location_id' => $this->location->id,
'title' => 'Urlaub',
'affect_vacation_times' => true,
'affect_evaluations' => true,
'evaluation_calculation_setting' => 'absent_to_target'
]);
$this->user->absenceTypes()->sync($absenceType);
/**
* @var AddsVacationEntitlements
*/
$action = app(AddsVacationEntitlements::class);
$action->add($this->user, [
'name' => "yearly allowance",
'starts_at' => "01.01.2021",
'ends_at' => "31.12.2021",
'days' => 2,
'expires' => false,
'transfer_remaining' => false
]);
/**
* @var AddsAbsences
*/
$action = app(AddsAbsences::class);
$action->add($this->user, $this->location, $this->user->id, [
'absence_type_id' => $absenceType->id,
'starts_at' => '29.11.2021 00:00',
'ends_at' => '30.11.2021 00:00',
'full_day' => true,
'status' => 'confirmed'
]);
Bus::fake();
/**
* @var ApprovesAbsence
*/
$approver = app(ApprovesAbsence::class);
$approver->approve(
$this->user,
$this->location,
Absence::first()->id
);
$this->assertDatabaseHas("absences",[
'id' => Absence::first()->id,
'status' => 'confirmed',
'vacation_days' => 2,
'paid_hours' => 16
]);
$this->assertDatabaseHas("vacation_entitlements",[
'name' => 'yearly allowance',
'status' => 'used',
]);
}
public function test_can_submit_future_vacation_entitlement()
{
$this->travelTo(Carbon::parse('2021-01-01'));
$absenceType = AbsenceType::forceCreate([
'location_id' => $this->location->id,
'title' => 'Urlaub',
'affect_vacation_times' => true,
'affect_evaluations' => true,
'evaluation_calculation_setting' => 'absent_to_target'
]);
$this->user->absenceTypes()->sync($absenceType);
/**
* @var AddsVacationEntitlements
*/
$action = app(AddsVacationEntitlements::class);
$action->add($this->user, [
'name' => "yearly allowance",
'starts_at' => "01.01.2022",
'ends_at' => "31.12.2022",
'days' => 10,
'expires' => false,
'transfer_remaining' => false
]);
/**
* @var AddsAbsences
*/
$action = app(AddsAbsences::class);
$action->add($this->user, $this->location, $this->user->id, [
'absence_type_id' => $absenceType->id,
'starts_at' => '29.11.2022 00:00',
'ends_at' => '30.11.2022 00:00',
'full_day' => true,
'status' => 'confirmed'
]);
Bus::fake();
/**
* @var ApprovesAbsence
*/
$approver = app(ApprovesAbsence::class);
$approver->approve(
$this->user,
$this->location,
Absence::first()->id
);
}
public function test_can_submit_vacation()
{
$this->travelTo($this->user->date_of_employment);
$absenceType = AbsenceType::forceCreate([
'location_id' => $this->location->id,
'title' => 'Urlaub',
'affect_vacation_times' => true,
'affect_evaluations' => true,
'evaluation_calculation_setting' => 'absent_to_target'
]);
$this->user->absenceTypes()->sync($absenceType);
/**
* @var AddsVacationEntitlements
*/
$action = app(AddsVacationEntitlements::class);
$action->add($this->user, [
'name' => "yearly allowance",
'starts_at' => "01.01.2021",
'ends_at' => "31.12.2021",
'days' => 2,
'expires' => false,
'transfer_remaining' => false
]);
/**
* @var AddsAbsences
*/
$action = app(AddsAbsences::class);
$action->add($this->user, $this->location, $this->user->id, [
'absence_type_id' => $absenceType->id,
'starts_at' => '29.11.2021 00:00',
'ends_at' => '30.11.2021 00:00',
'full_day' => true,
'status' => 'confirmed'
]);
Bus::fake();
/**
* @var ApprovesAbsence
*/
$approver = app(ApprovesAbsence::class);
$approver->approve(
$this->user,
$this->location,
Absence::first()->id
);
$this->assertDatabaseHas("absence_index",[
'date' => '2021-11-29 00:00:00',
'hours' => 8,
]);
$this->assertDatabaseHas("absence_index",[
'date' => '2021-11-30 00:00:00',
'hours' => 8,
]);
/**
* @var AddsVacationEntitlements
*/
$action = app(AddsVacationEntitlements::class);
$action->add($this->user, [
'name' => "additional allowance",
'starts_at' => "01.01.2021",
'ends_at' => "31.12.2021",
'days' => 2,
'expires' => false,
'transfer_remaining' => false
]);
/**
* @var AddsAbsences
*/
$action = app(AddsAbsences::class);
$action->add($this->user, $this->location, $this->user->id, [
'absence_type_id' => $absenceType->id,
'starts_at' => '06.12.2021 00:00',
'ends_at' => '07.12.2021 00:00',
'full_day' => true,
'status' => 'confirmed'
]);
/**
* @var ApprovesAbsence
*/
$approver = app(ApprovesAbsence::class);
$approver->approve(
$this->user,
$this->location,
Absence::where('starts_at','2021-12-06 00:00:00')->first()->id
);
}
//Wunschfrei
}
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/tests/Feature/EmailVerificationTest.php | tests/Feature/EmailVerificationTest.php | <?php
namespace Tests\Feature;
use App\Models\User;
use App\Providers\RouteServiceProvider;
use Illuminate\Auth\Events\Verified;
use Illuminate\Foundation\Testing\RefreshDatabase;
use Illuminate\Support\Facades\Event;
use Illuminate\Support\Facades\URL;
use Laravel\Fortify\Features;
use Tests\TestCase;
class EmailVerificationTest extends TestCase
{
use RefreshDatabase;
public function test_email_verification_screen_can_be_rendered()
{
if (! Features::enabled(Features::emailVerification())) {
return $this->markTestSkipped('Email verification not enabled.');
}
$user = User::factory()->create([
'email_verified_at' => null,
]);
$response = $this->actingAs($user)->get('/email/verify');
$response->assertStatus(200);
}
public function test_email_can_be_verified()
{
if (! Features::enabled(Features::emailVerification())) {
return $this->markTestSkipped('Email verification not enabled.');
}
Event::fake();
$user = User::factory()->create([
'email_verified_at' => null,
]);
$verificationUrl = URL::temporarySignedRoute(
'verification.verify',
now()->addMinutes(60),
['id' => $user->id, 'hash' => sha1($user->email)]
);
$response = $this->actingAs($user)->get($verificationUrl);
Event::assertDispatched(Verified::class);
$this->assertTrue($user->fresh()->hasVerifiedEmail());
$response->assertRedirect(RouteServiceProvider::HOME.'?verified=1');
}
public function test_email_can_not_verified_with_invalid_hash()
{
if (! Features::enabled(Features::emailVerification())) {
return $this->markTestSkipped('Email verification not enabled.');
}
$user = User::factory()->create([
'email_verified_at' => null,
]);
$verificationUrl = URL::temporarySignedRoute(
'verification.verify',
now()->addMinutes(60),
['id' => $user->id, 'hash' => sha1('wrong-email')]
);
$this->actingAs($user)->get($verificationUrl);
$this->assertFalse($user->fresh()->hasVerifiedEmail());
}
}
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/tests/Feature/BrowserSessionsTest.php | tests/Feature/BrowserSessionsTest.php | <?php
namespace Tests\Feature;
use App\Models\User;
use Illuminate\Foundation\Testing\RefreshDatabase;
use Laravel\Jetstream\Http\Livewire\LogoutOtherBrowserSessionsForm;
use Livewire\Livewire;
use Tests\TestCase;
class BrowserSessionsTest extends TestCase
{
use RefreshDatabase;
public function test_other_browser_sessions_can_be_logged_out()
{
$this->actingAs($user = User::factory()->create());
Livewire::test(LogoutOtherBrowserSessionsForm::class)
->set('password', 'password')
->call('logoutOtherBrowserSessions');
}
}
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/tests/Feature/DeleteUserAccountTest.php | tests/Feature/DeleteUserAccountTest.php | <?php
namespace Tests\Feature;
use App\Models\User;
use Illuminate\Foundation\Testing\RefreshDatabase;
use Laravel\Jetstream\Http\Livewire\DeleteUserForm;
use Livewire\Livewire;
use Tests\TestCase;
class DeleteUserAccountTest extends TestCase
{
use RefreshDatabase;
public function test_user_accounts_can_be_deleted()
{
$this->actingAs($user = User::factory()->create());
$component = Livewire::test(DeleteUserForm::class)
->set('password', 'password')
->call('deleteUser');
$this->assertNull($user->fresh());
}
public function test_correct_password_must_be_provided_before_account_can_be_deleted()
{
$this->actingAs($user = User::factory()->create());
Livewire::test(DeleteUserForm::class)
->set('password', 'wrong-password')
->call('deleteUser')
->assertHasErrors(['password']);
$this->assertNotNull($user->fresh());
}
}
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/tests/Feature/RemoveLocationMemberTest.php | tests/Feature/RemoveLocationMemberTest.php | <?php
namespace Tests\Feature;
use Tests\TestCase;
use App\Models\User;
use Livewire\Livewire;
use App\Models\Location;
use Illuminate\Foundation\Testing\RefreshDatabase;
use App\Http\Livewire\Locations\LocationMemberManager;
class RemoveLocationMemberTest extends TestCase
{
use RefreshDatabase;
public function test_location_members_can_be_removed_from_locations()
{
$user = User::factory()
->withOwnedAccount()
->create();
$location = $user->ownedLocations()->save($location = Location::factory()->make());
$location->users()->attach(
$otherUser = User::factory()->create(),
['role' => 'admin']
);
$this->actingAs($user);
$component = Livewire::test(LocationMemberManager::class, ['location' => $location])
->set('locationMemberIdBeingRemoved', $otherUser->id)
->call('removeLocationMember');
$this->assertCount(0, $location->fresh()->users);
}
public function test_only_location_admin_can_remove_location_members()
{
$user = User::factory()
->withOwnedAccount()
->create()
->ownedLocations()
->save($location = Location::factory()->make());
$location->users()->attach(
$otherUser = User::factory()->create(),
['role' => 'employee']
);
$this->actingAs($otherUser);
$component = Livewire::test(LocationMemberManager::class, ['location' => $location])
->set('locationMemberIdBeingRemoved', $user->id)
->call('removeLocationMember')
->assertStatus(403);
}
}
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/tests/Feature/LeaveLocationTest.php | tests/Feature/LeaveLocationTest.php | <?php
namespace Tests\Feature;
use Tests\TestCase;
use App\Models\User;
use Livewire\Livewire;
use App\Models\Location;
use Illuminate\Foundation\Testing\RefreshDatabase;
use App\Http\Livewire\Locations\LocationMemberManager;
class LeaveLocationTest extends TestCase
{
use RefreshDatabase;
public function test_users_can_leave_locations()
{
$user = User::factory()
->withOwnedAccount()
->create()
->ownedLocations()
->save($location = Location::factory()->make());
$location->users()->attach(
$otherUser = User::factory()->create(),
['role' => 'admin']
);
$this->assertCount(1, $location->fresh()->users);
$this->actingAs($otherUser);
Livewire::test(LocationMemberManager::class, ['location' => $location])
->call('leaveLocation');
$this->assertCount(0, $location->fresh()->users);
}
public function test_location_owners_cant_leave_their_own_location()
{
$this->actingAs(
$user = User::factory([
'date_of_employment' => '2020-11-01 07:47:05',
])->withOwnedAccount()->hasTargetHours([
'start_date' => '2020-11-01'
])->hasAttached($location = Location::factory()->state(
function (array $attributes, User $user) {
return ['owned_by' => $user->id];
}
), [
'role' => 'admin'
])->create()
);
Livewire::test(LocationMemberManager::class, ['location' => $user->ownedLocations->first()])
->call('leaveLocation')
->assertHasErrors(['location']);
$this->assertNotNull($user->fresh()->ownedLocations);
}
public function test_user_will_be_logged_out_when_location_gets_deleted()
{
$user = User::factory()->create();
$response = $this->actingAs($user)->get('/');
$this->assertGuest();
}
}
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/routes/web.php | routes/web.php | <?php
use Illuminate\Support\Facades\Route;
use App\Http\Controllers\ReportController;
use App\Http\Controllers\AbsenceController;
use App\Http\Controllers\AccountController;
use App\Http\Controllers\EditEmployeeController;
use App\Http\Controllers\TimeTrackingController;
use App\Http\Controllers\CurrentLocationController;
use App\Http\Controllers\LocationCalendarController;
use App\Http\Controllers\LocationSettingsController;
use App\Http\Controllers\LocationInvitationController;
use App\Http\Controllers\ShowEmployeesForAccountController;
use App\Http\Controllers\ShowLocationsForAccountController;
Route::group(['middleware' => 'auth'], function () {
Route::redirect('/', '/time-tracking', 301);
Route::put('/current-location', [CurrentLocationController::class, 'update'])
->name('current-location.update');
Route::get('location-invitations/{invitation}', [LocationInvitationController::class, 'accept'])
->name('location-invitations.accept');
Route::get('/time-tracking', [TimeTrackingController::class, 'index'])
->name('time-tracking');
Route::get('/absence', AbsenceController::class)
->name('absence');
Route::get('/report', ReportController::class)
->name('report');
Route::get('/location-settings', [LocationSettingsController::class, 'show'])
->name('location-settings');
Route::get('/location-calendar', [LocationCalendarController::class, 'show'])
->name('location-calendar');
Route::get('/accounts/{account}', [AccountController::class, 'show'])->name('accounts.show');
Route::get('/accounts/{account}/locations', ShowLocationsForAccountController::class)->name('locations');
Route::get('/accounts/{account}/employees', ShowEmployeesForAccountController::class)->name('employees');
Route::get('/accounts/{account}/employees/{employee}', EditEmployeeController::class)->name('employees.edit');
});
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/routes/channels.php | routes/channels.php | <?php
use Illuminate\Support\Facades\Broadcast;
/*
|--------------------------------------------------------------------------
| Broadcast Channels
|--------------------------------------------------------------------------
|
| Here you may register all of the event broadcasting channels that your
| application supports. The given channel authorization callbacks are
| used to check if an authenticated user can listen to the channel.
|
*/
Broadcast::channel('App.Models.User.{id}', function ($user, $id) {
return (int) $user->id === (int) $id;
});
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/routes/api.php | routes/api.php | <?php
use Illuminate\Http\Request;
use Illuminate\Support\Facades\Route;
/*
|--------------------------------------------------------------------------
| API Routes
|--------------------------------------------------------------------------
|
| Here is where you can register API routes for your application. These
| routes are loaded by the RouteServiceProvider within a group which
| is assigned the "api" middleware group. Enjoy building your API!
|
*/
// Route::middleware('auth:sanctum')->get('/user', function (Request $request) {
// return $request->user();
// });
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/routes/console.php | routes/console.php | <?php
use Illuminate\Foundation\Inspiring;
use Illuminate\Support\Facades\Artisan;
/*
|--------------------------------------------------------------------------
| Console Routes
|--------------------------------------------------------------------------
|
| This file is where you may define all of your Closure based console
| commands. Each Closure is bound to a command instance allowing a
| simple approach to interacting with each command's IO methods.
|
*/
Artisan::command('inspire', function () {
$this->comment(Inspiring::quote());
})->purpose('Display an inspiring quote');
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/public/index.php | public/index.php | <?php
use Illuminate\Contracts\Http\Kernel;
use Illuminate\Http\Request;
define('LARAVEL_START', microtime(true));
/*
|--------------------------------------------------------------------------
| Check If Application Is Under Maintenance
|--------------------------------------------------------------------------
|
| If the application is maintenance / demo mode via the "down" command we
| will require this file so that any prerendered template can be shown
| instead of starting the framework, which could cause an exception.
|
*/
if (file_exists(__DIR__.'/../storage/framework/maintenance.php')) {
require __DIR__.'/../storage/framework/maintenance.php';
}
/*
|--------------------------------------------------------------------------
| Register The Auto Loader
|--------------------------------------------------------------------------
|
| Composer provides a convenient, automatically generated class loader for
| this application. We just need to utilize it! We'll simply require it
| into the script here so we don't need to manually load our classes.
|
*/
require __DIR__.'/../vendor/autoload.php';
/*
|--------------------------------------------------------------------------
| Run The Application
|--------------------------------------------------------------------------
|
| Once we have the application, we can handle the incoming request using
| the application's HTTP kernel. Then, we will send the response back
| to this client's browser, allowing them to enjoy our application.
|
*/
$app = require_once __DIR__.'/../bootstrap/app.php';
$kernel = $app->make(Kernel::class);
$response = tap($kernel->handle(
$request = Request::capture()
))->send();
$kernel->terminate($request, $response);
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/config/app.php | config/app.php | <?php
return [
/*
|--------------------------------------------------------------------------
| Application Name
|--------------------------------------------------------------------------
|
| This value is the name of your application. This value is used when the
| framework needs to place the application's name in a notification or
| any other location as required by the application or its packages.
|
*/
'name' => env('APP_NAME', 'Laravel'),
/*
|--------------------------------------------------------------------------
| Application Environment
|--------------------------------------------------------------------------
|
| This value determines the "environment" your application is currently
| running in. This may determine how you prefer to configure various
| services the application utilizes. Set this in your ".env" file.
|
*/
'env' => env('APP_ENV', 'production'),
/*
|--------------------------------------------------------------------------
| Application Debug Mode
|--------------------------------------------------------------------------
|
| When your application is in debug mode, detailed error messages with
| stack traces will be shown on every error that occurs within your
| application. If disabled, a simple generic error page is shown.
|
*/
'debug' => (bool) env('APP_DEBUG', false),
/*
|--------------------------------------------------------------------------
| Application URL
|--------------------------------------------------------------------------
|
| This URL is used by the console to properly generate URLs when using
| the Artisan command line tool. You should set this to the root of
| your application so that it is used when running Artisan tasks.
|
*/
'url' => env('APP_URL', 'http://localhost'),
'asset_url' => env('ASSET_URL', null),
/*
|--------------------------------------------------------------------------
| Application Timezone
|--------------------------------------------------------------------------
|
| Here you may specify the default timezone for your application, which
| will be used by the PHP date and date-time functions. We have gone
| ahead and set this to a sensible default for you out of the box.
|
*/
'timezone' => env('TZ','UTC'),
/*
|--------------------------------------------------------------------------
| Application Locale Configuration
|--------------------------------------------------------------------------
|
| The application locale determines the default locale that will be used
| by the translation service provider. You are free to set this value
| to any of the locales which will be supported by the application.
|
*/
'locale' => 'de',
/*
|--------------------------------------------------------------------------
| Application Fallback Locale
|--------------------------------------------------------------------------
|
| The fallback locale determines the locale to use when the current one
| is not available. You may change the value to correspond to any of
| the language folders that are provided through your application.
|
*/
'fallback_locale' => 'en',
/*
|--------------------------------------------------------------------------
| Faker Locale
|--------------------------------------------------------------------------
|
| This locale will be used by the Faker PHP library when generating fake
| data for your database seeds. For example, this will be used to get
| localized telephone numbers, street address information and more.
|
*/
'faker_locale' => 'en_US',
/*
|--------------------------------------------------------------------------
| Encryption Key
|--------------------------------------------------------------------------
|
| This key is used by the Illuminate encrypter service and should be set
| to a random, 32 character string, otherwise these encrypted strings
| will not be safe. Please do this before deploying an application!
|
*/
'key' => env('APP_KEY'),
'cipher' => 'AES-256-CBC',
/*
|--------------------------------------------------------------------------
| Autoloaded Service Providers
|--------------------------------------------------------------------------
|
| The service providers listed here will be automatically loaded on the
| request to your application. Feel free to add your own services to
| this array to grant expanded functionality to your applications.
|
*/
'providers' => [
/*
* Laravel Framework Service Providers...
*/
Illuminate\Auth\AuthServiceProvider::class,
Illuminate\Broadcasting\BroadcastServiceProvider::class,
Illuminate\Bus\BusServiceProvider::class,
Illuminate\Cache\CacheServiceProvider::class,
Illuminate\Foundation\Providers\ConsoleSupportServiceProvider::class,
Illuminate\Cookie\CookieServiceProvider::class,
Illuminate\Database\DatabaseServiceProvider::class,
Illuminate\Encryption\EncryptionServiceProvider::class,
Illuminate\Filesystem\FilesystemServiceProvider::class,
Illuminate\Foundation\Providers\FoundationServiceProvider::class,
Illuminate\Hashing\HashServiceProvider::class,
Illuminate\Mail\MailServiceProvider::class,
Illuminate\Notifications\NotificationServiceProvider::class,
Illuminate\Pagination\PaginationServiceProvider::class,
Illuminate\Pipeline\PipelineServiceProvider::class,
Illuminate\Queue\QueueServiceProvider::class,
Illuminate\Redis\RedisServiceProvider::class,
Illuminate\Auth\Passwords\PasswordResetServiceProvider::class,
Illuminate\Session\SessionServiceProvider::class,
Illuminate\Translation\TranslationServiceProvider::class,
Illuminate\Validation\ValidationServiceProvider::class,
Illuminate\View\ViewServiceProvider::class,
/*
* Package Service Providers...
*/
/*
* Application Service Providers...
*/
App\Providers\AppServiceProvider::class,
App\Providers\AuthServiceProvider::class,
// App\Providers\BroadcastServiceProvider::class,
App\Providers\EventServiceProvider::class,
App\Providers\RouteServiceProvider::class,
App\Providers\FortifyServiceProvider::class,
App\Providers\JetstreamServiceProvider::class,
],
/*
|--------------------------------------------------------------------------
| Class Aliases
|--------------------------------------------------------------------------
|
| This array of class aliases will be registered when this application
| is started. However, feel free to register as many as you wish as
| the aliases are "lazy" loaded so they don't hinder performance.
|
*/
'aliases' => [
'App' => Illuminate\Support\Facades\App::class,
'Arr' => Illuminate\Support\Arr::class,
'Artisan' => Illuminate\Support\Facades\Artisan::class,
'Auth' => Illuminate\Support\Facades\Auth::class,
'Blade' => Illuminate\Support\Facades\Blade::class,
'Broadcast' => Illuminate\Support\Facades\Broadcast::class,
'Bus' => Illuminate\Support\Facades\Bus::class,
'Cache' => Illuminate\Support\Facades\Cache::class,
'Config' => Illuminate\Support\Facades\Config::class,
'Cookie' => Illuminate\Support\Facades\Cookie::class,
'Crypt' => Illuminate\Support\Facades\Crypt::class,
'DB' => Illuminate\Support\Facades\DB::class,
'Eloquent' => Illuminate\Database\Eloquent\Model::class,
'Event' => Illuminate\Support\Facades\Event::class,
'File' => Illuminate\Support\Facades\File::class,
'Gate' => Illuminate\Support\Facades\Gate::class,
'Hash' => Illuminate\Support\Facades\Hash::class,
'Http' => Illuminate\Support\Facades\Http::class,
'Lang' => Illuminate\Support\Facades\Lang::class,
'Log' => Illuminate\Support\Facades\Log::class,
'Mail' => Illuminate\Support\Facades\Mail::class,
'Notification' => Illuminate\Support\Facades\Notification::class,
'Password' => Illuminate\Support\Facades\Password::class,
'Queue' => Illuminate\Support\Facades\Queue::class,
'Redirect' => Illuminate\Support\Facades\Redirect::class,
// 'Redis' => Illuminate\Support\Facades\Redis::class,
'Request' => Illuminate\Support\Facades\Request::class,
'Response' => Illuminate\Support\Facades\Response::class,
'Route' => Illuminate\Support\Facades\Route::class,
'Schema' => Illuminate\Support\Facades\Schema::class,
'Session' => Illuminate\Support\Facades\Session::class,
'Storage' => Illuminate\Support\Facades\Storage::class,
'Str' => Illuminate\Support\Str::class,
'URL' => Illuminate\Support\Facades\URL::class,
'Validator' => Illuminate\Support\Facades\Validator::class,
'View' => Illuminate\Support\Facades\View::class,
],
'features' => [
// App\Providers\Features::projectBilling(),
// App\Providers\Features::employeePayroll(),
// App\Providers\Features::caldav()
]
];
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/config/logging.php | config/logging.php | <?php
use Monolog\Handler\NullHandler;
use Monolog\Handler\StreamHandler;
use Monolog\Handler\SyslogUdpHandler;
return [
/*
|--------------------------------------------------------------------------
| Default Log Channel
|--------------------------------------------------------------------------
|
| This option defines the default log channel that gets used when writing
| messages to the logs. The name specified in this option should match
| one of the channels defined in the "channels" configuration array.
|
*/
'default' => env('LOG_CHANNEL', 'stack'),
/*
|--------------------------------------------------------------------------
| Log Channels
|--------------------------------------------------------------------------
|
| Here you may configure the log channels for your application. Out of
| the box, Laravel uses the Monolog PHP logging library. This gives
| you a variety of powerful log handlers / formatters to utilize.
|
| Available Drivers: "single", "daily", "slack", "syslog",
| "errorlog", "monolog",
| "custom", "stack"
|
*/
'channels' => [
'stack' => [
'driver' => 'stack',
'channels' => ['single'],
'ignore_exceptions' => false,
],
'single' => [
'driver' => 'single',
'path' => storage_path('logs/laravel.log'),
'level' => env('LOG_LEVEL', 'debug'),
],
'daily' => [
'driver' => 'daily',
'path' => storage_path('logs/laravel.log'),
'level' => env('LOG_LEVEL', 'debug'),
'days' => 14,
],
'slack' => [
'driver' => 'slack',
'url' => env('LOG_SLACK_WEBHOOK_URL'),
'username' => 'Laravel Log',
'emoji' => ':boom:',
'level' => env('LOG_LEVEL', 'critical'),
],
'papertrail' => [
'driver' => 'monolog',
'level' => env('LOG_LEVEL', 'debug'),
'handler' => SyslogUdpHandler::class,
'handler_with' => [
'host' => env('PAPERTRAIL_URL'),
'port' => env('PAPERTRAIL_PORT'),
],
],
'stderr' => [
'driver' => 'monolog',
'handler' => StreamHandler::class,
'formatter' => env('LOG_STDERR_FORMATTER'),
'with' => [
'stream' => 'php://stderr',
],
],
'syslog' => [
'driver' => 'syslog',
'level' => env('LOG_LEVEL', 'debug'),
],
'errorlog' => [
'driver' => 'errorlog',
'level' => env('LOG_LEVEL', 'debug'),
],
'null' => [
'driver' => 'monolog',
'handler' => NullHandler::class,
],
'emergency' => [
'path' => storage_path('logs/laravel.log'),
],
],
];
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/config/session.php | config/session.php | <?php
use Illuminate\Support\Str;
return [
/*
|--------------------------------------------------------------------------
| Default Session Driver
|--------------------------------------------------------------------------
|
| This option controls the default session "driver" that will be used on
| requests. By default, we will use the lightweight native driver but
| you may specify any of the other wonderful drivers provided here.
|
| Supported: "file", "cookie", "database", "apc",
| "memcached", "redis", "dynamodb", "array"
|
*/
'driver' => env('SESSION_DRIVER', 'database'),
/*
|--------------------------------------------------------------------------
| Session Lifetime
|--------------------------------------------------------------------------
|
| Here you may specify the number of minutes that you wish the session
| to be allowed to remain idle before it expires. If you want them
| to immediately expire on the browser closing, set that option.
|
*/
'lifetime' => env('SESSION_LIFETIME', 120),
'expire_on_close' => false,
/*
|--------------------------------------------------------------------------
| Session Encryption
|--------------------------------------------------------------------------
|
| This option allows you to easily specify that all of your session data
| should be encrypted before it is stored. All encryption will be run
| automatically by Laravel and you can use the Session like normal.
|
*/
'encrypt' => false,
/*
|--------------------------------------------------------------------------
| Session File Location
|--------------------------------------------------------------------------
|
| When using the native session driver, we need a location where session
| files may be stored. A default has been set for you but a different
| location may be specified. This is only needed for file sessions.
|
*/
'files' => storage_path('framework/sessions'),
/*
|--------------------------------------------------------------------------
| Session Database Connection
|--------------------------------------------------------------------------
|
| When using the "database" or "redis" session drivers, you may specify a
| connection that should be used to manage these sessions. This should
| correspond to a connection in your database configuration options.
|
*/
'connection' => env('SESSION_CONNECTION', null),
/*
|--------------------------------------------------------------------------
| Session Database Table
|--------------------------------------------------------------------------
|
| When using the "database" session driver, you may specify the table we
| should use to manage the sessions. Of course, a sensible default is
| provided for you; however, you are free to change this as needed.
|
*/
'table' => 'sessions',
/*
|--------------------------------------------------------------------------
| Session Cache Store
|--------------------------------------------------------------------------
|
| While using one of the framework's cache driven session backends you may
| list a cache store that should be used for these sessions. This value
| must match with one of the application's configured cache "stores".
|
| Affects: "apc", "dynamodb", "memcached", "redis"
|
*/
'store' => env('SESSION_STORE', null),
/*
|--------------------------------------------------------------------------
| Session Sweeping Lottery
|--------------------------------------------------------------------------
|
| Some session drivers must manually sweep their storage location to get
| rid of old sessions from storage. Here are the chances that it will
| happen on a given request. By default, the odds are 2 out of 100.
|
*/
'lottery' => [2, 100],
/*
|--------------------------------------------------------------------------
| Session Cookie Name
|--------------------------------------------------------------------------
|
| Here you may change the name of the cookie used to identify a session
| instance by ID. The name specified here will get used every time a
| new session cookie is created by the framework for every driver.
|
*/
'cookie' => env(
'SESSION_COOKIE',
Str::slug(env('APP_NAME', 'laravel'), '_').'_session'
),
/*
|--------------------------------------------------------------------------
| Session Cookie Path
|--------------------------------------------------------------------------
|
| The session cookie path determines the path for which the cookie will
| be regarded as available. Typically, this will be the root path of
| your application but you are free to change this when necessary.
|
*/
'path' => '/',
/*
|--------------------------------------------------------------------------
| Session Cookie Domain
|--------------------------------------------------------------------------
|
| Here you may change the domain of the cookie used to identify a session
| in your application. This will determine which domains the cookie is
| available to in your application. A sensible default has been set.
|
*/
'domain' => env('SESSION_DOMAIN', null),
/*
|--------------------------------------------------------------------------
| HTTPS Only Cookies
|--------------------------------------------------------------------------
|
| By setting this option to true, session cookies will only be sent back
| to the server if the browser has a HTTPS connection. This will keep
| the cookie from being sent to you if it can not be done securely.
|
*/
'secure' => env('SESSION_SECURE_COOKIE'),
/*
|--------------------------------------------------------------------------
| HTTP Access Only
|--------------------------------------------------------------------------
|
| Setting this value to true will prevent JavaScript from accessing the
| value of the cookie and the cookie will only be accessible through
| the HTTP protocol. You are free to modify this option if needed.
|
*/
'http_only' => true,
/*
|--------------------------------------------------------------------------
| Same-Site Cookies
|--------------------------------------------------------------------------
|
| This option determines how your cookies behave when cross-site requests
| take place, and can be used to mitigate CSRF attacks. By default, we
| will set this value to "lax" since this is a secure default value.
|
| Supported: "lax", "strict", "none", null
|
*/
'same_site' => 'lax',
];
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/config/queue.php | config/queue.php | <?php
return [
/*
|--------------------------------------------------------------------------
| Default Queue Connection Name
|--------------------------------------------------------------------------
|
| Laravel's queue API supports an assortment of back-ends via a single
| API, giving you convenient access to each back-end using the same
| syntax for every one. Here you may define a default connection.
|
*/
'default' => env('QUEUE_CONNECTION', 'sync'),
/*
|--------------------------------------------------------------------------
| Queue Connections
|--------------------------------------------------------------------------
|
| Here you may configure the connection information for each server that
| is used by your application. A default configuration has been added
| for each back-end shipped with Laravel. You are free to add more.
|
| Drivers: "sync", "database", "beanstalkd", "sqs", "redis", "null"
|
*/
'connections' => [
'sync' => [
'driver' => 'sync',
],
'database' => [
'driver' => 'database',
'table' => 'jobs',
'queue' => 'default',
'retry_after' => 90,
],
'beanstalkd' => [
'driver' => 'beanstalkd',
'host' => 'localhost',
'queue' => 'default',
'retry_after' => 90,
'block_for' => 0,
],
'sqs' => [
'driver' => 'sqs',
'key' => env('AWS_ACCESS_KEY_ID'),
'secret' => env('AWS_SECRET_ACCESS_KEY'),
'prefix' => env('SQS_PREFIX', 'https://sqs.us-east-1.amazonaws.com/your-account-id'),
'queue' => env('SQS_QUEUE', 'your-queue-name'),
'suffix' => env('SQS_SUFFIX'),
'region' => env('AWS_DEFAULT_REGION', 'us-east-1'),
],
'redis' => [
'driver' => 'redis',
'connection' => 'default',
'queue' => env('REDIS_QUEUE', 'default'),
'retry_after' => 90,
'block_for' => null,
],
],
/*
|--------------------------------------------------------------------------
| Failed Queue Jobs
|--------------------------------------------------------------------------
|
| These options configure the behavior of failed queue job logging so you
| can control which database and table are used to store the jobs that
| have failed. You may change them to any database / table you wish.
|
*/
'failed' => [
'driver' => env('QUEUE_FAILED_DRIVER', 'database-uuids'),
'database' => env('DB_CONNECTION', 'mysql'),
'table' => 'failed_jobs',
],
];
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/config/debugbar.php | config/debugbar.php | <?php
return [
/*
|--------------------------------------------------------------------------
| Debugbar Settings
|--------------------------------------------------------------------------
|
| Debugbar is enabled by default, when debug is set to true in app.php.
| You can override the value by setting enable to true or false instead of null.
|
| You can provide an array of URI's that must be ignored (eg. 'api/*')
|
*/
'enabled' => env('DEBUGBAR_ENABLED', null),
'except' => [
'telescope*',
'horizon*',
],
/*
|--------------------------------------------------------------------------
| Storage settings
|--------------------------------------------------------------------------
|
| DebugBar stores data for session/ajax requests.
| You can disable this, so the debugbar stores data in headers/session,
| but this can cause problems with large data collectors.
| By default, file storage (in the storage folder) is used. Redis and PDO
| can also be used. For PDO, run the package migrations first.
|
*/
'storage' => [
'enabled' => true,
'driver' => 'socket',
'path' => storage_path('debugbar'),
'connection' => null,
'hostname' => '127.0.0.1',
'port' => 2304,
],
/*
|--------------------------------------------------------------------------
| Vendors
|--------------------------------------------------------------------------
|
| Vendor files are included by default, but can be set to false.
| This can also be set to 'js' or 'css', to only include javascript or css vendor files.
| Vendor files are for css: font-awesome (including fonts) and highlight.js (css files)
| and for js: jquery and and highlight.js
| So if you want syntax highlighting, set it to true.
| jQuery is set to not conflict with existing jQuery scripts.
|
*/
'include_vendors' => true,
/*
|--------------------------------------------------------------------------
| Capture Ajax Requests
|--------------------------------------------------------------------------
|
| The Debugbar can capture Ajax requests and display them. If you don't want this (ie. because of errors),
| you can use this option to disable sending the data through the headers.
|
| Optionally, you can also send ServerTiming headers on ajax requests for the Chrome DevTools.
*/
'capture_ajax' => true,
'add_ajax_timing' => false,
/*
|--------------------------------------------------------------------------
| Custom Error Handler for Deprecated warnings
|--------------------------------------------------------------------------
|
| When enabled, the Debugbar shows deprecated warnings for Symfony components
| in the Messages tab.
|
*/
'error_handler' => false,
/*
|--------------------------------------------------------------------------
| Clockwork integration
|--------------------------------------------------------------------------
|
| The Debugbar can emulate the Clockwork headers, so you can use the Chrome
| Extension, without the server-side code. It uses Debugbar collectors instead.
|
*/
'clockwork' => false,
/*
|--------------------------------------------------------------------------
| DataCollectors
|--------------------------------------------------------------------------
|
| Enable/disable DataCollectors
|
*/
'collectors' => [
'phpinfo' => true, // Php version
'messages' => true, // Messages
'time' => true, // Time Datalogger
'memory' => true, // Memory usage
'exceptions' => true, // Exception displayer
'log' => true, // Logs from Monolog (merged in messages if enabled)
'db' => true, // Show database (PDO) queries and bindings
'views' => true, // Views with their data
'route' => true, // Current route information
'auth' => false, // Display Laravel authentication status
'gate' => true, // Display Laravel Gate checks
'session' => true, // Display session data
'symfony_request' => true, // Only one can be enabled..
'mail' => true, // Catch mail messages
'laravel' => false, // Laravel version and environment
'events' => false, // All events fired
'default_request' => false, // Regular or special Symfony request logger
'logs' => false, // Add the latest log messages
'files' => false, // Show the included files
'config' => false, // Display config settings
'cache' => false, // Display cache events
'models' => true, // Display models
'livewire' => true, // Display Livewire (when available)
],
/*
|--------------------------------------------------------------------------
| Extra options
|--------------------------------------------------------------------------
|
| Configure some DataCollectors
|
*/
'options' => [
'auth' => [
'show_name' => true, // Also show the users name/email in the debugbar
],
'db' => [
'with_params' => true, // Render SQL with the parameters substituted
'backtrace' => true, // Use a backtrace to find the origin of the query in your files.
'backtrace_exclude_paths' => [], // Paths to exclude from backtrace. (in addition to defaults)
'timeline' => false, // Add the queries to the timeline
'explain' => [ // Show EXPLAIN output on queries
'enabled' => false,
'types' => ['SELECT'], // Deprecated setting, is always only SELECT
],
'hints' => false, // Show hints for common mistakes
'show_copy' => false, // Show copy button next to the query
],
'mail' => [
'full_log' => false,
],
'views' => [
'data' => false, //Note: Can slow down the application, because the data can be quite large..
],
'route' => [
'label' => true, // show complete route on bar
],
'logs' => [
'file' => null,
],
'cache' => [
'values' => true, // collect cache values
],
],
/*
|--------------------------------------------------------------------------
| Inject Debugbar in Response
|--------------------------------------------------------------------------
|
| Usually, the debugbar is added just before </body>, by listening to the
| Response after the App is done. If you disable this, you have to add them
| in your template yourself. See http://phpdebugbar.com/docs/rendering.html
|
*/
'inject' => true,
/*
|--------------------------------------------------------------------------
| DebugBar route prefix
|--------------------------------------------------------------------------
|
| Sometimes you want to set route prefix to be used by DebugBar to load
| its resources from. Usually the need comes from misconfigured web server or
| from trying to overcome bugs like this: http://trac.nginx.org/nginx/ticket/97
|
*/
'route_prefix' => '_debugbar',
/*
|--------------------------------------------------------------------------
| DebugBar route domain
|--------------------------------------------------------------------------
|
| By default DebugBar route served from the same domain that request served.
| To override default domain, specify it as a non-empty value.
*/
'route_domain' => null,
/*
|--------------------------------------------------------------------------
| DebugBar theme
|--------------------------------------------------------------------------
|
| Switches between light and dark theme. If set to auto it will respect system preferences
| Possible values: auto, light, dark
*/
'theme' => 'auto',
];
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/config/cache.php | config/cache.php | <?php
use Illuminate\Support\Str;
return [
/*
|--------------------------------------------------------------------------
| Default Cache Store
|--------------------------------------------------------------------------
|
| This option controls the default cache connection that gets used while
| using this caching library. This connection is used when another is
| not explicitly specified when executing a given caching function.
|
| Supported: "apc", "array", "database", "file",
| "memcached", "redis", "dynamodb"
|
*/
'default' => env('CACHE_DRIVER', 'file'),
/*
|--------------------------------------------------------------------------
| Cache Stores
|--------------------------------------------------------------------------
|
| Here you may define all of the cache "stores" for your application as
| well as their drivers. You may even define multiple stores for the
| same cache driver to group types of items stored in your caches.
|
| Supported drivers: "apc", "array", "database", "file",
| "memcached", "redis", "dynamodb", "null"
|
*/
'stores' => [
'apc' => [
'driver' => 'apc',
],
'array' => [
'driver' => 'array',
'serialize' => false,
],
'database' => [
'driver' => 'database',
'table' => 'cache',
'connection' => null,
],
'file' => [
'driver' => 'file',
'path' => storage_path('framework/cache/data'),
],
'memcached' => [
'driver' => 'memcached',
'persistent_id' => env('MEMCACHED_PERSISTENT_ID'),
'sasl' => [
env('MEMCACHED_USERNAME'),
env('MEMCACHED_PASSWORD'),
],
'options' => [
// Memcached::OPT_CONNECT_TIMEOUT => 2000,
],
'servers' => [
[
'host' => env('MEMCACHED_HOST', '127.0.0.1'),
'port' => env('MEMCACHED_PORT', 11211),
'weight' => 100,
],
],
],
'redis' => [
'driver' => 'redis',
'connection' => 'cache',
],
'dynamodb' => [
'driver' => 'dynamodb',
'key' => env('AWS_ACCESS_KEY_ID'),
'secret' => env('AWS_SECRET_ACCESS_KEY'),
'region' => env('AWS_DEFAULT_REGION', 'us-east-1'),
'table' => env('DYNAMODB_CACHE_TABLE', 'cache'),
'endpoint' => env('DYNAMODB_ENDPOINT'),
],
],
/*
|--------------------------------------------------------------------------
| Cache Key Prefix
|--------------------------------------------------------------------------
|
| When utilizing a RAM based store such as APC or Memcached, there might
| be other applications utilizing the same cache. So, we'll specify a
| value to get prefixed to all our keys so we can avoid collisions.
|
*/
'prefix' => env('CACHE_PREFIX', Str::slug(env('APP_NAME', 'laravel'), '_').'_cache'),
];
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/config/hashing.php | config/hashing.php | <?php
return [
/*
|--------------------------------------------------------------------------
| Default Hash Driver
|--------------------------------------------------------------------------
|
| This option controls the default hash driver that will be used to hash
| passwords for your application. By default, the bcrypt algorithm is
| used; however, you remain free to modify this option if you wish.
|
| Supported: "bcrypt", "argon", "argon2id"
|
*/
'driver' => 'bcrypt',
/*
|--------------------------------------------------------------------------
| Bcrypt Options
|--------------------------------------------------------------------------
|
| Here you may specify the configuration options that should be used when
| passwords are hashed using the Bcrypt algorithm. This will allow you
| to control the amount of time it takes to hash the given password.
|
*/
'bcrypt' => [
'rounds' => env('BCRYPT_ROUNDS', 10),
],
/*
|--------------------------------------------------------------------------
| Argon Options
|--------------------------------------------------------------------------
|
| Here you may specify the configuration options that should be used when
| passwords are hashed using the Argon algorithm. These will allow you
| to control the amount of time it takes to hash the given password.
|
*/
'argon' => [
'memory' => 1024,
'threads' => 2,
'time' => 2,
],
];
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/config/view.php | config/view.php | <?php
return [
/*
|--------------------------------------------------------------------------
| View Storage Paths
|--------------------------------------------------------------------------
|
| Most templating systems load templates from disk. Here you may specify
| an array of paths that should be checked for your views. Of course
| the usual Laravel view path has already been registered for you.
|
*/
'paths' => [
resource_path('views'),
],
/*
|--------------------------------------------------------------------------
| Compiled View Path
|--------------------------------------------------------------------------
|
| This option determines where all the compiled Blade templates will be
| stored for your application. Typically, this is within the storage
| directory. However, as usual, you are free to change this value.
|
*/
'compiled' => env(
'VIEW_COMPILED_PATH',
realpath(storage_path('framework/views'))
),
];
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/config/database.php | config/database.php | <?php
use Illuminate\Support\Str;
return [
/*
|--------------------------------------------------------------------------
| Default Database Connection Name
|--------------------------------------------------------------------------
|
| Here you may specify which of the database connections below you wish
| to use as your default connection for all database work. Of course
| you may use many connections at once using the Database library.
|
*/
'default' => env('DB_CONNECTION', 'mysql'),
/*
|--------------------------------------------------------------------------
| Database Connections
|--------------------------------------------------------------------------
|
| Here are each of the database connections setup for your application.
| Of course, examples of configuring each database platform that is
| supported by Laravel is shown below to make development simple.
|
|
| All database work in Laravel is done through the PHP PDO facilities
| so make sure you have the driver for your particular database of
| choice installed on your machine before you begin development.
|
*/
'connections' => [
'sqlite' => [
'driver' => 'sqlite',
'url' => env('DATABASE_URL'),
'database' => env('DB_DATABASE', database_path('database.sqlite')),
'prefix' => '',
'foreign_key_constraints' => env('DB_FOREIGN_KEYS', true),
],
'mysql' => [
'driver' => 'mysql',
'url' => env('DATABASE_URL'),
'host' => env('DB_HOST', '127.0.0.1'),
'port' => env('DB_PORT', '3306'),
'database' => env('DB_DATABASE', 'forge'),
'username' => env('DB_USERNAME', 'forge'),
'password' => env('DB_PASSWORD', ''),
'unix_socket' => env('DB_SOCKET', ''),
'charset' => 'utf8mb4',
'collation' => 'utf8mb4_unicode_ci',
'prefix' => '',
'prefix_indexes' => true,
'strict' => true,
'engine' => null,
'options' => extension_loaded('pdo_mysql') ? array_filter([
PDO::MYSQL_ATTR_SSL_CA => env('MYSQL_ATTR_SSL_CA'),
]) : [],
],
'pgsql' => [
'driver' => 'pgsql',
'url' => env('DATABASE_URL'),
'host' => env('DB_HOST', '127.0.0.1'),
'port' => env('DB_PORT', '5432'),
'database' => env('DB_DATABASE', 'forge'),
'username' => env('DB_USERNAME', 'forge'),
'password' => env('DB_PASSWORD', ''),
'charset' => 'utf8',
'prefix' => '',
'prefix_indexes' => true,
'schema' => 'public',
'sslmode' => 'prefer',
],
'sqlsrv' => [
'driver' => 'sqlsrv',
'url' => env('DATABASE_URL'),
'host' => env('DB_HOST', 'localhost'),
'port' => env('DB_PORT', '1433'),
'database' => env('DB_DATABASE', 'forge'),
'username' => env('DB_USERNAME', 'forge'),
'password' => env('DB_PASSWORD', ''),
'charset' => 'utf8',
'prefix' => '',
'prefix_indexes' => true,
],
],
/*
|--------------------------------------------------------------------------
| Migration Repository Table
|--------------------------------------------------------------------------
|
| This table keeps track of all the migrations that have already run for
| your application. Using this information, we can determine which of
| the migrations on disk haven't actually been run in the database.
|
*/
'migrations' => 'migrations',
/*
|--------------------------------------------------------------------------
| Redis Databases
|--------------------------------------------------------------------------
|
| Redis is an open source, fast, and advanced key-value store that also
| provides a richer body of commands than a typical key-value system
| such as APC or Memcached. Laravel makes it easy to dig right in.
|
*/
'redis' => [
'client' => env('REDIS_CLIENT', 'phpredis'),
'options' => [
'cluster' => env('REDIS_CLUSTER', 'redis'),
'prefix' => env('REDIS_PREFIX', Str::slug(env('APP_NAME', 'laravel'), '_').'_database_'),
],
'default' => [
'url' => env('REDIS_URL'),
'host' => env('REDIS_HOST', '127.0.0.1'),
'password' => env('REDIS_PASSWORD', null),
'port' => env('REDIS_PORT', '6379'),
'database' => env('REDIS_DB', '0'),
],
'cache' => [
'url' => env('REDIS_URL'),
'host' => env('REDIS_HOST', '127.0.0.1'),
'password' => env('REDIS_PASSWORD', null),
'port' => env('REDIS_PORT', '6379'),
'database' => env('REDIS_CACHE_DB', '1'),
],
],
];
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/config/services.php | config/services.php | <?php
return [
/*
|--------------------------------------------------------------------------
| Third Party Services
|--------------------------------------------------------------------------
|
| This file is for storing the credentials for third party services such
| as Mailgun, Postmark, AWS and more. This file provides the de facto
| location for this type of information, allowing packages to have
| a conventional file to locate the various service credentials.
|
*/
'mailgun' => [
'domain' => env('MAILGUN_DOMAIN'),
'secret' => env('MAILGUN_SECRET'),
'endpoint' => env('MAILGUN_ENDPOINT', 'api.mailgun.net'),
],
'postmark' => [
'token' => env('POSTMARK_TOKEN'),
],
'ses' => [
'key' => env('AWS_ACCESS_KEY_ID'),
'secret' => env('AWS_SECRET_ACCESS_KEY'),
'region' => env('AWS_DEFAULT_REGION', 'us-east-1'),
],
];
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/config/filesystems.php | config/filesystems.php | <?php
return [
/*
|--------------------------------------------------------------------------
| Default Filesystem Disk
|--------------------------------------------------------------------------
|
| Here you may specify the default filesystem disk that should be used
| by the framework. The "local" disk, as well as a variety of cloud
| based disks are available to your application. Just store away!
|
*/
'default' => env('FILESYSTEM_DRIVER', 'local'),
/*
|--------------------------------------------------------------------------
| Default Cloud Filesystem Disk
|--------------------------------------------------------------------------
|
| Many applications store files both locally and in the cloud. For this
| reason, you may specify a default "cloud" driver here. This driver
| will be bound as the Cloud disk implementation in the container.
|
*/
'cloud' => env('FILESYSTEM_CLOUD', 's3'),
/*
|--------------------------------------------------------------------------
| Filesystem Disks
|--------------------------------------------------------------------------
|
| Here you may configure as many filesystem "disks" as you wish, and you
| may even configure multiple disks of the same driver. Defaults have
| been setup for each driver as an example of the required options.
|
| Supported Drivers: "local", "ftp", "sftp", "s3"
|
*/
'disks' => [
'local' => [
'driver' => 'local',
'root' => storage_path('app'),
],
'public' => [
'driver' => 'local',
'root' => storage_path('app/public'),
'url' => env('APP_URL').'/storage',
'visibility' => 'public',
],
'backup-sftp' => [
'driver' => 'sftp',
'useAgent' => true,
'host' => env('APP_BACKUP_HOST'),
'username' => env('APP_BACKUP_USER'),
'port' => env('APP_BACKUP_HOST_PORT', 22),
'root' => env('APP_BACKUP_ROOT'),
],
// 's3' => [
// 'driver' => 's3',
// 'key' => env('AWS_ACCESS_KEY_ID'),
// 'secret' => env('AWS_SECRET_ACCESS_KEY'),
// 'region' => env('AWS_DEFAULT_REGION'),
// 'bucket' => env('AWS_BUCKET'),
// 'url' => env('AWS_URL'),
// 'endpoint' => env('AWS_ENDPOINT'),
// ],
],
/*
|--------------------------------------------------------------------------
| Symbolic Links
|--------------------------------------------------------------------------
|
| Here you may configure the symbolic links that will be created when the
| `storage:link` Artisan command is executed. The array keys should be
| the locations of the links and the values should be their targets.
|
*/
'links' => [
public_path('storage') => storage_path('app/public'),
],
];
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/config/mail.php | config/mail.php | <?php
return [
/*
|--------------------------------------------------------------------------
| Default Mailer
|--------------------------------------------------------------------------
|
| This option controls the default mailer that is used to send any email
| messages sent by your application. Alternative mailers may be setup
| and used as needed; however, this mailer will be used by default.
|
*/
'default' => env('MAIL_MAILER', 'smtp'),
/*
|--------------------------------------------------------------------------
| Mailer Configurations
|--------------------------------------------------------------------------
|
| Here you may configure all of the mailers used by your application plus
| their respective settings. Several examples have been configured for
| you and you are free to add your own as your application requires.
|
| Laravel supports a variety of mail "transport" drivers to be used while
| sending an e-mail. You will specify which one you are using for your
| mailers below. You are free to add additional mailers as required.
|
| Supported: "smtp", "sendmail", "mailgun", "ses",
| "postmark", "log", "array"
|
*/
'mailers' => [
'smtp' => [
'transport' => 'smtp',
'host' => env('MAIL_HOST', 'smtp.mailgun.org'),
'port' => env('MAIL_PORT', 587),
'encryption' => env('MAIL_ENCRYPTION', 'tls'),
'username' => env('MAIL_USERNAME'),
'password' => env('MAIL_PASSWORD'),
'timeout' => null,
'auth_mode' => null,
],
'ses' => [
'transport' => 'ses',
],
'mailgun' => [
'transport' => 'mailgun',
],
'postmark' => [
'transport' => 'postmark',
],
'sendmail' => [
'transport' => 'sendmail',
'path' => '/usr/sbin/sendmail -bs',
],
'log' => [
'transport' => 'log',
'channel' => env('MAIL_LOG_CHANNEL'),
],
'array' => [
'transport' => 'array',
],
],
/*
|--------------------------------------------------------------------------
| Global "From" Address
|--------------------------------------------------------------------------
|
| You may wish for all e-mails sent by your application to be sent from
| the same address. Here, you may specify a name and address that is
| used globally for all e-mails that are sent by your application.
|
*/
'from' => [
'address' => env('MAIL_FROM_ADDRESS', 'hello@example.com'),
'name' => env('MAIL_FROM_NAME', 'Example'),
],
/*
|--------------------------------------------------------------------------
| Markdown Mail Settings
|--------------------------------------------------------------------------
|
| If you are using Markdown based email rendering, you may configure your
| theme and component paths here, allowing you to customize the design
| of the emails. Or, you may simply stick with the Laravel defaults!
|
*/
'markdown' => [
'theme' => 'default',
'paths' => [
resource_path('views/vendor/mail'),
],
],
];
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/config/cors.php | config/cors.php | <?php
return [
/*
|--------------------------------------------------------------------------
| Cross-Origin Resource Sharing (CORS) Configuration
|--------------------------------------------------------------------------
|
| Here you may configure your settings for cross-origin resource sharing
| or "CORS". This determines what cross-origin operations may execute
| in web browsers. You are free to adjust these settings as needed.
|
| To learn more: https://developer.mozilla.org/en-US/docs/Web/HTTP/CORS
|
*/
'paths' => ['api/*', 'sanctum/csrf-cookie'],
'allowed_methods' => ['*'],
'allowed_origins' => ['*'],
'allowed_origins_patterns' => [],
'allowed_headers' => ['*'],
'exposed_headers' => [],
'max_age' => 0,
'supports_credentials' => false,
];
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/config/fortify.php | config/fortify.php | <?php
use App\Providers\RouteServiceProvider;
use Laravel\Fortify\Features;
return [
/*
|--------------------------------------------------------------------------
| Fortify Guard
|--------------------------------------------------------------------------
|
| Here you may specify which authentication guard Fortify will use while
| authenticating users. This value should correspond with one of your
| guards that is already present in your "auth" configuration file.
|
*/
'guard' => 'web',
/*
|--------------------------------------------------------------------------
| Fortify Password Broker
|--------------------------------------------------------------------------
|
| Here you may specify which password broker Fortify can use when a user
| is resetting their password. This configured value should match one
| of your password brokers setup in your "auth" configuration file.
|
*/
'passwords' => 'users',
/*
|--------------------------------------------------------------------------
| Username / Email
|--------------------------------------------------------------------------
|
| This value defines which model attribute should be considered as your
| application's "username" field. Typically, this might be the email
| address of the users but you are free to change this value here.
|
| Out of the box, Fortify expects forgot password and reset password
| requests to have a field named 'email'. If the application uses
| another name for the field you may define it below as needed.
|
*/
'username' => 'email',
'email' => 'email',
/*
|--------------------------------------------------------------------------
| Home Path
|--------------------------------------------------------------------------
|
| Here you may configure the path where users will get redirected during
| authentication or password reset when the operations are successful
| and the user is authenticated. You are free to change this value.
|
*/
'home' => RouteServiceProvider::HOME,
/*
|--------------------------------------------------------------------------
| Fortify Routes Prefix / Subdomain
|--------------------------------------------------------------------------
|
| Here you may specify which prefix Fortify will assign to all the routes
| that it registers with the application. If necessary, you may change
| subdomain under which all of the Fortify routes will be available.
|
*/
'prefix' => '',
'domain' => null,
/*
|--------------------------------------------------------------------------
| Fortify Routes Middleware
|--------------------------------------------------------------------------
|
| Here you may specify which middleware Fortify will assign to the routes
| that it registers with the application. If necessary, you may change
| these middleware but typically this provided default is preferred.
|
*/
'middleware' => ['web'],
/*
|--------------------------------------------------------------------------
| Rate Limiting
|--------------------------------------------------------------------------
|
| By default, Fortify will throttle logins to five requests per minute for
| every email and IP address combination. However, if you would like to
| specify a custom rate limiter to call then you may specify it here.
|
*/
'limiters' => [
'login' => 'login',
'two-factor' => 'two-factor',
],
/*
|--------------------------------------------------------------------------
| Register View Routes
|--------------------------------------------------------------------------
|
| Here you may specify if the routes returning views should be disabled as
| you may not need them when building your own application. This may be
| especially true if you're writing a custom single-page application.
|
*/
'views' => true,
/*
|--------------------------------------------------------------------------
| Features
|--------------------------------------------------------------------------
|
| Some of the Fortify features are optional. You may disable the features
| by removing them from this array. You're free to only remove some of
| these features or you can even remove all of these if you need to.
|
*/
'features' => [
Features::registration(),
Features::resetPasswords(),
// Features::emailVerification(),
Features::updateProfileInformation(),
Features::updatePasswords(),
// Features::twoFactorAuthentication([
// 'confirmPassword' => true,
// ]),
],
];
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/config/jetstream.php | config/jetstream.php | <?php
use Laravel\Jetstream\Features;
return [
/*
|--------------------------------------------------------------------------
| Jetstream Stack
|--------------------------------------------------------------------------
|
| This configuration value informs Jetstream which "stack" you will be
| using for your application. In general, this value is set for you
| during installation and will not need to be changed after that.
|
*/
'stack' => 'livewire',
/*
|--------------------------------------------------------------------------
| Jetstream Route Middleware
|--------------------------------------------------------------------------
|
| Here you may specify which middleware Jetstream will assign to the routes
| that it registers with the application. When necessary, you may modify
| these middleware; however, this default value is usually sufficient.
|
*/
'middleware' => ['web'],
/*
|--------------------------------------------------------------------------
| Features
|--------------------------------------------------------------------------
|
| Some of Jetstream's features are optional. You may disable the features
| by removing them from this array. You're free to only remove some of
| these features or you can even remove all of these if you need to.
|
*/
'features' => [
// Features::termsAndPrivacyPolicy(),
Features::profilePhotos(),
// Features::api(),
Features::teams(['invitations' => true]),
Features::accountDeletion(),
],
];
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/config/public_holidays.php | config/public_holidays.php | <?php
return [
'base_url' => 'https://feiertage-api.de/api/',
'countries' =>[
[
'title' => 'Badenwürtemberg',
'code' => 'BW'
], [
'title' => 'Bayern',
'code' => 'BY'
], [
'title' => 'Berlin',
'code' => 'BE'
], [
'title' => 'Brandenburg',
'code' => 'BB'
], [
'title' => 'Bremen',
'code' => 'HP'
], [
'title' => 'Hamburg',
'code' => 'HH'
], [
'title' => 'Hessen',
'code' => 'HE'
], [
'title' => 'Mecklenburgvorpommern',
'code' => 'MV'
], [
'title' => 'Niedersachsen',
'code' => 'NI'
], [
'title' => 'Nordrheinwestfalen',
'code' => 'NW'
], [
'title' => 'Rheinlandpfalz',
'code' => 'RP'
], [
'title' => 'Saarland',
'code' => 'SL'
], [
'title' => 'Sachsen',
'code' => 'SN'
], [
'title' => 'Sachsenanhalt',
'code' => 'ST'
], [
'title' => 'Schleswigholstein',
'code' => 'SH'
], [
'title' => 'Thueringen',
'code' => 'TH'
]
]
];
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/config/broadcasting.php | config/broadcasting.php | <?php
return [
/*
|--------------------------------------------------------------------------
| Default Broadcaster
|--------------------------------------------------------------------------
|
| This option controls the default broadcaster that will be used by the
| framework when an event needs to be broadcast. You may set this to
| any of the connections defined in the "connections" array below.
|
| Supported: "pusher", "redis", "log", "null"
|
*/
'default' => env('BROADCAST_DRIVER', 'null'),
/*
|--------------------------------------------------------------------------
| Broadcast Connections
|--------------------------------------------------------------------------
|
| Here you may define all of the broadcast connections that will be used
| to broadcast events to other systems or over websockets. Samples of
| each available type of connection are provided inside this array.
|
*/
'connections' => [
'pusher' => [
'driver' => 'pusher',
'key' => env('PUSHER_APP_KEY'),
'secret' => env('PUSHER_APP_SECRET'),
'app_id' => env('PUSHER_APP_ID'),
'options' => [
'cluster' => env('PUSHER_APP_CLUSTER'),
'useTLS' => true,
],
],
'ably' => [
'driver' => 'ably',
'key' => env('ABLY_KEY'),
],
'redis' => [
'driver' => 'redis',
'connection' => 'default',
],
'log' => [
'driver' => 'log',
],
'null' => [
'driver' => 'null',
],
],
];
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/config/auth.php | config/auth.php | <?php
return [
/*
|--------------------------------------------------------------------------
| Authentication Defaults
|--------------------------------------------------------------------------
|
| This option controls the default authentication "guard" and password
| reset options for your application. You may change these defaults
| as required, but they're a perfect start for most applications.
|
*/
'defaults' => [
'guard' => 'web',
'passwords' => 'users',
],
/*
|--------------------------------------------------------------------------
| Authentication Guards
|--------------------------------------------------------------------------
|
| Next, you may define every authentication guard for your application.
| Of course, a great default configuration has been defined for you
| here which uses session storage and the Eloquent user provider.
|
| All authentication drivers have a user provider. This defines how the
| users are actually retrieved out of your database or other storage
| mechanisms used by this application to persist your user's data.
|
| Supported: "session", "token"
|
*/
'guards' => [
'web' => [
'driver' => 'session',
'provider' => 'users',
],
'api' => [
'driver' => 'token',
'provider' => 'users',
'hash' => false,
],
],
/*
|--------------------------------------------------------------------------
| User Providers
|--------------------------------------------------------------------------
|
| All authentication drivers have a user provider. This defines how the
| users are actually retrieved out of your database or other storage
| mechanisms used by this application to persist your user's data.
|
| If you have multiple user tables or models you may configure multiple
| sources which represent each model / table. These sources may then
| be assigned to any extra authentication guards you have defined.
|
| Supported: "database", "eloquent"
|
*/
'providers' => [
'users' => [
'driver' => 'eloquent',
'model' => App\Models\User::class,
],
// 'users' => [
// 'driver' => 'database',
// 'table' => 'users',
// ],
],
/*
|--------------------------------------------------------------------------
| Resetting Passwords
|--------------------------------------------------------------------------
|
| You may specify multiple password reset configurations if you have more
| than one user table or model in the application and you want to have
| separate password reset settings based on the specific user types.
|
| The expire time is the number of minutes that the reset token should be
| considered valid. This security feature keeps tokens short-lived so
| they have less time to be guessed. You may change this as needed.
|
*/
'passwords' => [
'users' => [
'provider' => 'users',
'table' => 'password_resets',
'expire' => 60,
'throttle' => 60,
],
],
/*
|--------------------------------------------------------------------------
| Password Confirmation Timeout
|--------------------------------------------------------------------------
|
| Here you may define the amount of seconds before a password confirmation
| times out and the user is prompted to re-enter their password via the
| confirmation screen. By default, the timeout lasts for three hours.
|
*/
'password_timeout' => 10800,
];
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/config/sanctum.php | config/sanctum.php | <?php
return [
/*
|--------------------------------------------------------------------------
| Stateful Domains
|--------------------------------------------------------------------------
|
| Requests from the following domains / hosts will receive stateful API
| authentication cookies. Typically, these should include your local
| and production domains which access your API via a frontend SPA.
|
*/
'stateful' => explode(',', env(
'SANCTUM_STATEFUL_DOMAINS',
'localhost,localhost:3000,127.0.0.1,127.0.0.1:8000,::1'
)),
/*
|--------------------------------------------------------------------------
| Expiration Minutes
|--------------------------------------------------------------------------
|
| This value controls the number of minutes until an issued token will be
| considered expired. If this value is null, personal access tokens do
| not expire. This won't tweak the lifetime of first-party sessions.
|
*/
'expiration' => null,
/*
|--------------------------------------------------------------------------
| Sanctum Middleware
|--------------------------------------------------------------------------
|
| When authenticating your first-party SPA with Sanctum you may need to
| customize some of the middleware Sanctum uses while processing the
| request. You may change the middleware listed below as required.
|
*/
'middleware' => [
'verify_csrf_token' => App\Http\Middleware\VerifyCsrfToken::class,
'encrypt_cookies' => App\Http\Middleware\EncryptCookies::class,
],
];
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/database/factories/TargetHourFactory.php | database/factories/TargetHourFactory.php | <?php
namespace Database\Factories;
use Carbon\Carbon;
use App\Models\TargetHour;
use Illuminate\Database\Eloquent\Factories\Factory;
class TargetHourFactory extends Factory
{
/**
* The name of the factory's corresponding model.
*
* @var string
*/
protected $model = TargetHour::class;
/**
* Define the model's default state.
*
* @return array
*/
public function definition()
{
return [
"start_date" => Carbon::today(),
"hours_per" => "week",
"target_hours" => 40,
"target_limited" => false,
"is_mon" => true,
"mon" => 8,
"is_tue" => true,
"tue" => 8,
"is_wed" => true,
"wed" => 8,
"is_thu" => true,
"thu" => 8,
"is_fri" => true,
"fri" => 8,
"is_sat" => false,
"sat" => 0,
"is_sun" => false,
"sun" => 0
];
}
}
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/database/factories/VacationBanFactory.php | database/factories/VacationBanFactory.php | <?php
namespace Database\Factories;
use App\Models\VacationBan;
use Illuminate\Database\Eloquent\Factories\Factory;
class VacationBanFactory extends Factory
{
/**
* The name of the factory's corresponding model.
*
* @var string
*/
protected $model = VacationBan::class;
/**
* Define the model's default state.
*
* @return array
*/
public function definition()
{
return [
//
];
}
}
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/database/factories/LocationFactory.php | database/factories/LocationFactory.php | <?php
namespace Database\Factories;
use App\Models\User;
use App\Models\Account;
use App\Models\Location;
use Illuminate\Database\Eloquent\Factories\Factory;
class LocationFactory extends Factory
{
/**
* The name of the factory's corresponding model.
*
* @var string
*/
protected $model = Location::class;
/**
* Define the model's default state.
*
* @return array
*/
public function definition()
{
return [
'name' => $this->faker->unique()->company,
'owned_by' => User::factory(),
'account_id' => Account::factory(),
'time_zone' => 'Europe/Berlin',
'locale' => 'de',
'active' => true
];
}
}
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/database/factories/UserFactory.php | database/factories/UserFactory.php | <?php
namespace Database\Factories;
use App\Models\Account;
use App\Models\User;
use App\Models\Location;
use Illuminate\Support\Str;
use Illuminate\Database\Eloquent\Factories\Factory;
use LogicException;
class UserFactory extends Factory
{
/**
* The name of the factory's corresponding model.
*
* @var string
*/
protected $model = User::class;
/**
* Define the model's default state.
*
* @return array
*/
public function definition()
{
return [
'name' => $this->faker->name,
'email' => $this->faker->unique()->safeEmail,
'email_verified_at' => now(),
'date_of_employment' => now(),
'password' => '$2y$10$92IXUNpkjO0rOQ5byMi.Ye4oKoEa3Ro9llC/.og/at2.uheWG/igi', // password
'remember_token' => Str::random(10)
];
}
/**
* Indicate that the user should have own an account.
*
* @return $this
*/
public function withOwnedAccount()
{
return $this->has(
Account::factory()
->state(function (array $attributes, User $user) {
return [
'name' => $user->name.'\'s Account',
'owned_by' => $user->id,
];
}),
'ownedAccount'
);
}
}
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/database/factories/TimeTrackingFactory.php | database/factories/TimeTrackingFactory.php | <?php
namespace Database\Factories;
use App\Models\User;
use App\Models\Location;
use App\Models\TimeTracking;
use Illuminate\Database\Eloquent\Factories\Factory;
class TimeTrackingFactory extends Factory
{
/**
* The name of the factory's corresponding model.
*
* @var string
*/
protected $model = TimeTracking::class;
/**
* Define the model's default state.
*
* @return array
*/
public function definition()
{
return [
'location_id' => Location::factory(),
'user_id' => User::factory(),
'starts_at' => "2021-05-18 9:00.00",
'ends_at' => "2021-05-18 17:00.00",
'description' => "nothing",
];
}
}
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/database/factories/AbsenceFactory.php | database/factories/AbsenceFactory.php | <?php
namespace Database\Factories;
use App\Models\Absence;
use Illuminate\Database\Eloquent\Factories\Factory;
class AbsenceFactory extends Factory
{
/**
* The name of the factory's corresponding model.
*
* @var string
*/
protected $model = Absence::class;
/**
* Define the model's default state.
*
* @return array
*/
public function definition()
{
return [
//
];
}
}
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/database/factories/AbsenceTypeFactory.php | database/factories/AbsenceTypeFactory.php | <?php
namespace Database\Factories;
use App\Models\Location;
use App\Models\AbsenceType;
use Illuminate\Database\Eloquent\Factories\Factory;
class AbsenceTypeFactory extends Factory
{
/**
* The name of the factory's corresponding model.
*
* @var string
*/
protected $model = AbsenceType::class;
/**
* Define the model's default state.
*
* @return array
*/
public function definition()
{
return [
'location_id' => Location::factory(),
'title' => 'Urlaub',
'affect_vacation_times' => true,
'affect_evaluations' => true,
'evaluation_calculation_setting' => 'absent_to_target'
];
}
}
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/database/factories/AccountFactory.php | database/factories/AccountFactory.php | <?php
namespace Database\Factories;
use App\Models\User;
use App\Models\Account;
use Illuminate\Database\Eloquent\Factories\Factory;
class AccountFactory extends Factory
{
/**
* The name of the factory's corresponding model.
*
* @var string
*/
protected $model = Account::class;
/**
* Define the model's default state.
*
* @return array
*/
public function definition()
{
return [
'owned_by' => User::factory(),
'name' => $this->faker->unique()->company,
];
}
}
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/database/factories/PublicHolidayFactory.php | database/factories/PublicHolidayFactory.php | <?php
namespace Database\Factories;
use App\Models\PublicHoliday;
use Illuminate\Database\Eloquent\Factories\Factory;
class PublicHolidayFactory extends Factory
{
/**
* The name of the factory's corresponding model.
*
* @var string
*/
protected $model = PublicHoliday::class;
/**
* Define the model's default state.
*
* @return array
*/
public function definition()
{
return [
//
];
}
}
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/database/migrations/2020_12_09_100216_create_vacation_entitlements_transfer_table.php | database/migrations/2020_12_09_100216_create_vacation_entitlements_transfer_table.php | <?php
use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;
class CreateVacationEntitlementsTransferTable extends Migration
{
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
Schema::create('vacation_entitlements_transfer', function (Blueprint $table) {
$table->id();
$table->timestamps();
$table->foreignId('transferred_to_id')->constrained('vacation_entitlements')->cascadeOnDelete();
$table->foreignId('transferred_from_id')->constrained('vacation_entitlements')->cascadeOnDelete();
$table->decimal('days',4,1);
});
}
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
Schema::dropIfExists('vacation_entitlements_transfer');
}
}
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/database/migrations/2020_11_06_183851_create_locations_table.php | database/migrations/2020_11_06_183851_create_locations_table.php | <?php
use App\Models\User;
use App\Models\Account;
use Illuminate\Support\Facades\Schema;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Database\Migrations\Migration;
class CreateLocationsTable extends Migration
{
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
Schema::create('locations', function (Blueprint $table) {
$table->id();
$table->timestamps();
$table->string('name');
$table->boolean('active')->default(true);
$table->foreignId('owned_by');
$table->foreignId('account_id');
$table->string('time_zone')->nullable();
$table->string('locale')->default('de')->nullable();
});
}
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
Schema::dropIfExists('locations');
}
}
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/database/migrations/2020_11_37_091035_create_location_invitations_table.php | database/migrations/2020_11_37_091035_create_location_invitations_table.php | <?php
use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;
class CreateLocationInvitationsTable extends Migration
{
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
Schema::create('location_invitations', function (Blueprint $table) {
$table->id();
$table->foreignId('location_id')->constrained()->cascadeOnDelete();
$table->string('email')->unique();
$table->string('role');
$table->timestamps();
});
}
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
Schema::dropIfExists('location_invitations');
}
}
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/database/migrations/2020_10_25_102336_create_sessions_table.php | database/migrations/2020_10_25_102336_create_sessions_table.php | <?php
use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;
class CreateSessionsTable extends Migration
{
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
Schema::create('sessions', function (Blueprint $table) {
$table->string('id')->primary();
$table->foreignId('user_id')->nullable()->index();
$table->string('ip_address', 45)->nullable();
$table->text('user_agent')->nullable();
$table->text('payload');
$table->integer('last_activity')->index();
});
}
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
Schema::dropIfExists('sessions');
}
}
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/database/migrations/2020_11_12_131218_create_target_hours_table.php | database/migrations/2020_11_12_131218_create_target_hours_table.php | <?php
use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;
class CreateTargetHoursTable extends Migration
{
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
Schema::create('target_hours', function (Blueprint $table) {
$table->id();
$table->timestamps();
$table->foreignId('user_id')->constrained()->cascadeOnDelete();
$table->date('start_date');
$table->string('hours_per')->default('week');
$table->decimal('target_hours')->default(40);
$table->boolean('target_limited')->default(false);
//target hours based on weeks
$table->decimal('mon')->default(8);
$table->decimal('tue')->default(8);
$table->decimal('wed')->default(8);
$table->decimal('thu')->default(8);
$table->decimal('fri')->default(8);
$table->decimal('sat')->default(0);
$table->decimal('sun')->default(0);
//target hours based on month
$table->boolean('is_mon')->default(true);
$table->boolean('is_tue')->default(true);
$table->boolean('is_wed')->default(true);
$table->boolean('is_thu')->default(true);
$table->boolean('is_fri')->default(true);
$table->boolean('is_sat')->default(false);
$table->boolean('is_sun')->default(false);
$table->unique(['user_id','start_date']);
});
}
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
Schema::dropIfExists('target_hours');
}
}
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/database/migrations/2021_01_13_083730_create_working_session_actions_table.php | database/migrations/2021_01_13_083730_create_working_session_actions_table.php | <?php
use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;
class CreateWorkingSessionActionsTable extends Migration
{
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
Schema::create('working_session_actions', function (Blueprint $table) {
$table->id();
$table->timestamps();
$table->foreignId('working_session_id')->constrained()->cascadeOnDelete();
$table->string('action_type', 255);
$table->timestamp('action_time')->nullable();
});
}
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
Schema::dropIfExists('working_session_actions');
}
}
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/database/migrations/2021_05_14_113528_create_default_resting_time_table.php | database/migrations/2021_05_14_113528_create_default_resting_time_table.php | <?php
use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;
class CreateDefaultRestingTimeTable extends Migration
{
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
Schema::create('default_resting_times', function (Blueprint $table) {
$table->id();
$table->timestamps();
$table->foreignId('location_id')->constrained()->cascadeOnDelete();
$table->integer('min_hours'); //in seconds
$table->integer('duration'); //in seconds
});
Schema::create('default_resting_time_users', function (Blueprint $table) {
$table->id();
$table->timestamps();
$table->foreignId('default_resting_time_id')->constrained()->cascadeOnDelete();
$table->foreignId('user_id')->constrained()->cascadeOnDelete();
});
}
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
Schema::dropIfExists('default_resting_time_users');
Schema::dropIfExists('default_resting_times');
}
}
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/database/migrations/2020_11_28_123344_create_absence_index_table.php | database/migrations/2020_11_28_123344_create_absence_index_table.php | <?php
use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;
class CreateAbsenceIndexTable extends Migration
{
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
Schema::create('absence_index', function (Blueprint $table) {
$table->id();
$table->timestamps();
$table->date('date');
$table->foreignId('absence_type_id')->constrained();
$table->foreignId('user_id')->constrained();
$table->foreignId('location_id')->constrained();
$table->foreignId('absence_id')->constrained()->cascadeOnDelete();
$table->decimal('hours');
$table->unique([
'absence_type_id',
'absence_id',
'user_id',
'location_id',
'date',
'hours'
],'absence_unique');
});
}
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
Schema::dropIfExists('absence_index');
}
}
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/database/migrations/2014_10_12_000000_create_users_table.php | database/migrations/2014_10_12_000000_create_users_table.php | <?php
use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;
class CreateUsersTable extends Migration
{
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
Schema::create('users', function (Blueprint $table) {
//default
$table->id();
$table->string('name');
$table->string('email')->unique();
$table->timestamp('email_verified_at')->nullable();
$table->string('password');
$table->rememberToken();
$table->text('profile_photo_path')->nullable();
$table->timestamps();
$table->foreignId('account_id')->nullable();
$table->foreignId('current_location_id')->nullable();
$table->date('date_of_employment');
$table->decimal('opening_overtime_balance')->nullable();
$table->enum('locale', ['de','en'])->default('de');
});
}
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
Schema::dropIfExists('users');
}
}
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/database/migrations/2014_10_12_100000_create_password_resets_table.php | database/migrations/2014_10_12_100000_create_password_resets_table.php | <?php
use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;
class CreatePasswordResetsTable extends Migration
{
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
Schema::create('password_resets', function (Blueprint $table) {
$table->string('email')->index();
$table->string('token');
$table->timestamp('created_at')->nullable();
});
}
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
Schema::dropIfExists('password_resets');
}
}
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/database/migrations/2021_05_14_113639_add_pause_time_to_time_tracking.php | database/migrations/2021_05_14_113639_add_pause_time_to_time_tracking.php | <?php
use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;
class AddPauseTimeToTimeTracking extends Migration
{
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
Schema::table('time_trackings', function (Blueprint $table) {
$table->integer('pause_time')->nullable(); //in seconds
});
}
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
Schema::table('time_trackings', function (Blueprint $table) {
$table->dropColumn('pause_time');
});
}
}
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/database/migrations/2020_11_27_194315_create_public_holidays_table.php | database/migrations/2020_11_27_194315_create_public_holidays_table.php | <?php
use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;
class CreatePublicHolidaysTable extends Migration
{
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
Schema::create('public_holidays', function (Blueprint $table) {
$table->id();
$table->foreignId('location_id')->constrained();
$table->timestamps();
$table->string('title');
$table->date('day');
$table->boolean('public_holiday_half_day')->default(false);
});
}
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
Schema::dropIfExists('public_holidays');
}
}
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/database/migrations/2020_11_27_090855_create_location_user_table.php | database/migrations/2020_11_27_090855_create_location_user_table.php | <?php
use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;
class CreateLocationUserTable extends Migration
{
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
Schema::create('location_user', function (Blueprint $table) {
$table->id();
$table->foreignId('location_id');
$table->foreignId('user_id');
$table->string('role')->nullable();
$table->timestamps();
$table->unique(['user_id','location_id']);
});
}
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
Schema::dropIfExists('location_user');
}
}
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/database/migrations/2020_11_28_123320_create_vacation_entitlements_table.php | database/migrations/2020_11_28_123320_create_vacation_entitlements_table.php | <?php
use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;
class CreateVacationEntitlementsTable extends Migration
{
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
Schema::create('vacation_entitlements', function (Blueprint $table) {
$table->id();
$table->timestamps();
$table->foreignId('user_id')->constrained()->cascadeOnDelete();
$table->string('name');
$table->date('starts_at')->nullable();
$table->date('ends_at')->nullable();
$table->boolean('expires')->default(true);
$table->decimal('days',4,1)->default(0);
$table->string('status', 25)->default('expires');
$table->boolean('transfer_remaining')->default(false);
$table->date('end_of_transfer_period')->nullable();
// Sie können den Zeitraum eines Urlaubskontingents nur ändern, so lange die Anzahl verbrauchter Tage bzw. Stunden Null ist.
});
}
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
Schema::dropIfExists('vacation_budgets');
}
}
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/database/migrations/2019_08_19_000000_create_failed_jobs_table.php | database/migrations/2019_08_19_000000_create_failed_jobs_table.php | <?php
use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;
class CreateFailedJobsTable extends Migration
{
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
Schema::create('failed_jobs', function (Blueprint $table) {
$table->id();
$table->string('uuid')->unique();
$table->text('connection');
$table->text('queue');
$table->longText('payload');
$table->longText('exception');
$table->timestamp('failed_at')->useCurrent();
});
}
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
Schema::dropIfExists('failed_jobs');
}
}
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/database/migrations/2020_11_28_152309_create_pause_times_table.php | database/migrations/2020_11_28_152309_create_pause_times_table.php | <?php
use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;
class CreatePauseTimesTable extends Migration
{
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
Schema::create('pause_times', function (Blueprint $table) {
$table->id();
$table->timestamps();
$table->foreignId('time_tracking_id')->constrained()->cascadeOnDelete();
$table->timestamp('starts_at')->nullable();
$table->timestamp('ends_at')->nullable();
});
}
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
Schema::dropIfExists('pause_times');
}
}
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/database/migrations/2020_12_06_114347_create_absence_vacation_entitlement_table.php | database/migrations/2020_12_06_114347_create_absence_vacation_entitlement_table.php | <?php
use App\Models\Absence;
use Illuminate\Support\Facades\Schema;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Database\Migrations\Migration;
class CreateAbsenceVacationEntitlementTable extends Migration
{
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
Schema::create('absence_vacation_entitlement', function (Blueprint $table) {
$table->id();
$table->timestamps();
$table->foreignId('vacation_entitlement_id')->constrained()->cascadeOnDelete();
$table->foreignId('absence_id')->constrained()->cascadeOnDelete();
$table->decimal('used_days',4,1);
});
}
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
Schema::dropIfExists('absence_vacation_entitlement');
}
}
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/database/migrations/2020_11_06_191536_create_absence_types_table.php | database/migrations/2020_11_06_191536_create_absence_types_table.php | <?php
use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;
class CreateAbsenceTypesTable extends Migration
{
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
Schema::create('absence_types', function (Blueprint $table) {
$table->foreignId('location_id')->constrained();
$table->id();
$table->timestamps();
$table->string('title');
$table->boolean('affect_vacation_times')->default(false);
$table->boolean('affect_evaluations')->default(false);
// Refer to CreateNewUser.php for an explaination of these values
$table->enum(
'evaluation_calculation_setting',
['target_to_zero','absent_to_target','fixed_value','custom_value']
)->nullable();
// Feiertage berücksichtigen (An Feiertagen werden
// keine Urlaubstage verrechnet und in den Auswertungen
// zählen die Feiertagsstunden, nicht die Abwesenheitsstunden)
$table->boolean('regard_holidays')->default(true);
// Abwesenheitstyp automatisch neuen Mitarbeitern zuweisen
$table->boolean('assign_new_users')->default(true);
// Beim Bestätigen einer Abwesenheit, alle Zeiterfassungen im Zeitraum entfernen
$table->boolean('remove_working_sessions_on_confirm')->default(true);
});
}
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
Schema::dropIfExists('absence_types');
}
}
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/database/migrations/2021_05_14_114518_drop_manual_pause_from_time_trackings_table.php | database/migrations/2021_05_14_114518_drop_manual_pause_from_time_trackings_table.php | <?php
use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;
class DropManualPauseFromTimeTrackingsTable extends Migration
{
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
Schema::table('time_trackings', function (Blueprint $table) {
$table->dropColumn('manual_pause');
});
}
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
Schema::table('time_trackings', function (Blueprint $table) {
$table->integer('manual_pause');
});
}
}
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/database/migrations/2022_03_17_144634_add_account_admin_to_users_table.php | database/migrations/2022_03_17_144634_add_account_admin_to_users_table.php | <?php
use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;
class AddAccountAdminToUsersTable extends Migration
{
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
Schema::table('users', function (Blueprint $table) {
$table->boolean('is_account_admin')->default(false);
});
}
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
Schema::table('users', function (Blueprint $table) {
$table->dropColumn('is_account_admin');
});
}
}
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/database/migrations/2019_12_14_000001_create_personal_access_tokens_table.php | database/migrations/2019_12_14_000001_create_personal_access_tokens_table.php | <?php
use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;
class CreatePersonalAccessTokensTable extends Migration
{
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
Schema::create('personal_access_tokens', function (Blueprint $table) {
$table->bigIncrements('id');
$table->morphs('tokenable');
$table->string('name');
$table->string('token', 64)->unique();
$table->text('abilities')->nullable();
$table->timestamp('last_used_at')->nullable();
$table->timestamps();
});
}
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
Schema::dropIfExists('personal_access_tokens');
}
}
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/database/migrations/2021_01_13_061249_create_working_sessions_table.php | database/migrations/2021_01_13_061249_create_working_sessions_table.php | <?php
use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;
class CreateWorkingSessionsTable extends Migration
{
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
Schema::create('working_sessions', function (Blueprint $table) {
$table->id();
$table->timestamps();
$table->foreignId('user_id')->constrained()->cascadeOnDelete();
$table->foreignId('location_id')->constrained()->cascadeOnDelete();
$table->unique(['user_id','location_id']);
$table->string('status', 255);
});
}
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
Schema::dropIfExists('working_sessions');
}
}
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/database/migrations/2021_01_01_161847_add_unique_constraint_to_public_holidays_table.php | database/migrations/2021_01_01_161847_add_unique_constraint_to_public_holidays_table.php | <?php
use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;
class AddUniqueConstraintToPublicHolidaysTable extends Migration
{
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
Schema::table('public_holidays', function (Blueprint $table) {
$table->unique(['location_id', 'title','day']);
});
}
}
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/database/migrations/2020_11_25_095223_create_absence_type_user_table.php | database/migrations/2020_11_25_095223_create_absence_type_user_table.php | <?php
use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;
class CreateAbsenceTypeUserTable extends Migration
{
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
Schema::create('absence_type_user', function (Blueprint $table) {
$table->id();
$table->timestamps();
$table->foreignId('absence_type_id')->constrained()->cascadeOnDelete();
$table->foreignId('user_id');
$table->unique(['user_id','absence_type_id']);
});
}
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
Schema::dropIfExists('absence_type_user');
}
}
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/database/migrations/2020_11_27_194419_create_vacation_bans_table.php | database/migrations/2020_11_27_194419_create_vacation_bans_table.php | <?php
use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;
class CreateVacationBansTable extends Migration
{
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
Schema::create('vacation_bans', function (Blueprint $table) {
$table->foreignId('location_id')->constrained();
$table->id();
$table->timestamps();
$table->string('title');
$table->date('starts_at');
$table->date('ends_at');
$table->foreignId('absence_type_id')->constrained();
});
}
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
Schema::dropIfExists('vacation_bans');
}
}
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/database/migrations/2020_11_05_215502_create_accounts_table.php | database/migrations/2020_11_05_215502_create_accounts_table.php | <?php
use App\Models\User;
use Illuminate\Support\Facades\Schema;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Database\Migrations\Migration;
class CreateAccountsTable extends Migration
{
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
Schema::create('accounts', function (Blueprint $table) {
$table->foreignId('owned_by');
$table->id();
$table->timestamps();
$table->string('name');
});
}
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
Schema::dropIfExists('accounts');
}
}
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/database/migrations/2020_11_27_194115_create_absences_table.php | database/migrations/2020_11_27_194115_create_absences_table.php | <?php
use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;
class CreateAbsencesTable extends Migration
{
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
Schema::create('absences', function (Blueprint $table) {
$table->id();
$table->timestamps();
$table->foreignId('absence_type_id')->constrained();
$table->foreignId('user_id')->constrained();
$table->foreignId('location_id')->constrained();
$table->timestamp('starts_at')->nullable();
$table->timestamp('ends_at')->nullable();
$table->boolean('full_day')->default(true);
$table->boolean('force_calc_custom_hours')->default(false);
$table->decimal('paid_hours')->nullable(); //required if force_calc_custom_hours is true
$table->decimal('vacation_days')->nullable(); //required if force_calc_custom_hours is true
$table->string('status', 25)->default('pending');
});
}
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
Schema::dropIfExists('absences');
}
}
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/database/migrations/2014_10_12_200000_add_two_factor_columns_to_users_table.php | database/migrations/2014_10_12_200000_add_two_factor_columns_to_users_table.php | <?php
use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;
class AddTwoFactorColumnsToUsersTable extends Migration
{
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
Schema::table('users', function (Blueprint $table) {
$table->text('two_factor_secret')
->after('password')
->nullable();
$table->text('two_factor_recovery_codes')
->after('two_factor_secret')
->nullable();
});
}
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
Schema::table('users', function (Blueprint $table) {
$table->dropColumn('two_factor_secret', 'two_factor_recovery_codes');
});
}
}
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/database/migrations/2020_11_27_185238_create_time_trackings_table.php | database/migrations/2020_11_27_185238_create_time_trackings_table.php | <?php
use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;
class CreateTimeTrackingsTable extends Migration
{
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
Schema::create('time_trackings', function (Blueprint $table) {
$table->id();
$table->timestamps();
$table->foreignId('user_id')->constrained()->cascadeOnDelete();
$table->foreignId('location_id')->constrained()->cascadeOnDelete();
$table->timestamp('starts_at')->nullable();
$table->timestamp('ends_at')->nullable();
$table->text('description')->nullable();
$table->integer('manual_pause');
});
}
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
Schema::dropIfExists('time_trackings');
}
}
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/database/seeders/VacationBanSeeder.php | database/seeders/VacationBanSeeder.php | <?php
namespace Database\Seeders;
use Illuminate\Database\Seeder;
class VacationBanSeeder extends Seeder
{
/**
* Run the database seeds.
*
* @return void
*/
public function run()
{
//
}
}
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/database/seeders/AbsenceTypeSeeder.php | database/seeders/AbsenceTypeSeeder.php | <?php
namespace Database\Seeders;
use Illuminate\Database\Seeder;
class AbsenceTypeSeeder extends Seeder
{
/**
* Run the database seeds.
*
* @return void
*/
public function run()
{
//
}
}
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/database/seeders/TimeTrackingSeeder.php | database/seeders/TimeTrackingSeeder.php | <?php
namespace Database\Seeders;
use Illuminate\Database\Seeder;
class TimeTrackingSeeder extends Seeder
{
/**
* Run the database seeds.
*
* @return void
*/
public function run()
{
//
}
}
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/database/seeders/CompanySeeder.php | database/seeders/CompanySeeder.php | <?php
namespace Database\Seeders;
use Illuminate\Database\Seeder;
class CompanySeeder extends Seeder
{
/**
* Run the database seeds.
*
* @return void
*/
public function run()
{
//
}
}
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/database/seeders/PublicHolidaySeeder.php | database/seeders/PublicHolidaySeeder.php | <?php
namespace Database\Seeders;
use Illuminate\Database\Seeder;
class PublicHolidaySeeder extends Seeder
{
/**
* Run the database seeds.
*
* @return void
*/
public function run()
{
//
}
}
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/database/seeders/DatabaseSeeder.php | database/seeders/DatabaseSeeder.php | <?php
namespace Database\Seeders;
use Illuminate\Database\Seeder;
use Laravel\Jetstream\Jetstream;
use Laravel\Fortify\Contracts\CreatesNewUsers;
class DatabaseSeeder extends Seeder
{
/**
* Seed the application's database.
*
* @return void
*/
public function run()
{
app(CreatesNewUsers::class)->create([
'name' => 'Admin User',
'email' => 'admin@daybreak.corp',
'password' => 'admin1234',
'password_confirmation' => 'admin1234',
'terms' => Jetstream::hasTermsAndPrivacyPolicyFeature() ? true : false,
]);
}
}
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/database/seeders/AbsenceSeeder.php | database/seeders/AbsenceSeeder.php | <?php
namespace Database\Seeders;
use Illuminate\Database\Seeder;
class AbsenceSeeder extends Seeder
{
/**
* Run the database seeds.
*
* @return void
*/
public function run()
{
//
}
}
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/database/seeders/LocationSeeder.php | database/seeders/LocationSeeder.php | <?php
namespace Database\Seeders;
use Illuminate\Database\Seeder;
class LocationSeeder extends Seeder
{
/**
* Run the database seeds.
*
* @return void
*/
public function run()
{
//
}
}
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/database/seeders/EmployeeSeeder.php | database/seeders/EmployeeSeeder.php | <?php
namespace Database\Seeders;
use Illuminate\Database\Seeder;
class EmployeeSeeder extends Seeder
{
/**
* Run the database seeds.
*
* @return void
*/
public function run()
{
//
}
}
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
eporsche/daybreak | https://github.com/eporsche/daybreak/blob/622d67f67470933977f13a44b19849ddb1cc0d8c/resources/lang/vendor/backup/de/notifications.php | resources/lang/vendor/backup/de/notifications.php | <?php
return [
'exception_message' => 'Fehlermeldung: :message',
'exception_trace' => 'Fehlerverfolgung: :trace',
'exception_message_title' => 'Fehlermeldung',
'exception_trace_title' => 'Fehlerverfolgung',
'backup_failed_subject' => 'Backup von :application_name konnte nicht erstellt werden',
'backup_failed_body' => 'Wichtig: Beim Backup von :application_name ist ein Fehler aufgetreten',
'backup_successful_subject' => 'Erfolgreiches neues Backup von :application_name',
'backup_successful_subject_title' => 'Erfolgreiches neues Backup!',
'backup_successful_body' => 'Gute Nachrichten, ein neues Backup von :application_name wurde erfolgreich erstellt und in :disk_name gepeichert.',
'cleanup_failed_subject' => 'Aufräumen der Backups von :application_name schlug fehl.',
'cleanup_failed_body' => 'Beim aufräumen der Backups von :application_name ist ein Fehler aufgetreten',
'cleanup_successful_subject' => 'Aufräumen der Backups von :application_name backups erfolgreich',
'cleanup_successful_subject_title' => 'Aufräumen der Backups erfolgreich!',
'cleanup_successful_body' => 'Aufräumen der Backups von :application_name in :disk_name war erfolgreich.',
'healthy_backup_found_subject' => 'Die Backups von :application_name in :disk_name sind gesund',
'healthy_backup_found_subject_title' => 'Die Backups von :application_name sind Gesund',
'healthy_backup_found_body' => 'Die Backups von :application_name wurden als gesund eingestuft. Gute Arbeit!',
'unhealthy_backup_found_subject' => 'Wichtig: Die Backups für :application_name sind nicht gesund',
'unhealthy_backup_found_subject_title' => 'Wichtig: Die Backups für :application_name sind ungesund. :problem',
'unhealthy_backup_found_body' => 'Die Backups für :application_name in :disk_name sind ungesund.',
'unhealthy_backup_found_not_reachable' => 'Das Backup Ziel konnte nicht erreicht werden. :error',
'unhealthy_backup_found_empty' => 'Es gibt für die Anwendung noch gar keine Backups.',
'unhealthy_backup_found_old' => 'Das letzte Backup am :date ist zu lange her.',
'unhealthy_backup_found_unknown' => 'Sorry, ein genauer Grund konnte nicht gefunden werden.',
'unhealthy_backup_found_full' => 'Die Backups verbrauchen zu viel Platz. Aktuell wird :disk_usage belegt, dass ist höher als das erlaubte Limit von :disk_limit.',
];
| php | MIT | 622d67f67470933977f13a44b19849ddb1cc0d8c | 2026-01-05T05:21:01.959950Z | false |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.