Merge branch 'feature/import' into feature/add_frontend_dashboard

# Conflicts:
#	app/Http/Controllers/Api/V1/TimeEntryController.php
#	app/Providers/JetstreamServiceProvider.php
This commit is contained in:
Constantin Graf
2024-03-12 17:55:49 +01:00
96 changed files with 3444 additions and 109 deletions

View File

@@ -30,10 +30,7 @@ class TimeEntryIndexRequest extends FormRequest
'uuid',
new ExistsEloquent(User::class, null, function (Builder $builder): Builder {
/** @var Builder<User> $builder */
return $builder->whereHas('organizations', function (Builder $builder) {
/** @var Builder<Organization> $builder */
return $builder->whereKey($this->organization->getKey());
});
return $builder->belongsToOrganization($this->organization);
}),
],
// Filter only time entries that have a start date before (not including) the given date (example: 2021-12-31)

View File

@@ -33,10 +33,7 @@ class TimeEntryStoreRequest extends FormRequest
'uuid',
new ExistsEloquent(User::class, null, function (Builder $builder): Builder {
/** @var Builder<User> $builder */
return $builder->whereHas('organizations', function (Builder $builder) {
/** @var Builder<Organization> $builder */
return $builder->whereKey($this->organization->getKey());
});
return $builder->belongsToOrganization($this->organization);
}),
],
// ID of the task that the time entry should belong to
@@ -64,7 +61,7 @@ class TimeEntryStoreRequest extends FormRequest
'description' => [
'nullable',
'string',
'max:255',
'max:500',
],
// List of tag IDs
'tags' => [

View File

@@ -51,7 +51,7 @@ class TimeEntryUpdateRequest extends FormRequest
'description' => [
'nullable',
'string',
'max:255',
'max:500',
],
// List of tag IDs
'tags' => [