fix: Fixed wrong doc for softDeletes withTrashed method (#1688)

This commit is contained in:
Kristijan
2025-07-17 07:50:16 +02:00
committed by GitHub
parent 4dfc08a854
commit cff244b9b5
4 changed files with 4 additions and 4 deletions
+1 -1
View File
@@ -1411,7 +1411,7 @@ class ModelsCommand extends Command
if (in_array('Illuminate\\Database\\Eloquent\\SoftDeletes', $traits)) {
$modelName = $this->getClassNameInDestinationFile($model, get_class($model));
$builder = $this->getClassNameInDestinationFile($model, \Illuminate\Database\Eloquent\Builder::class);
$this->setMethod('withTrashed', $builder . '<static>|' . $modelName, []);
$this->setMethod('withTrashed', $builder . '<static>|' . $modelName, ['bool $withTrashed = true']);
$this->setMethod('withoutTrashed', $builder . '<static>|' . $modelName, []);
$this->setMethod('onlyTrashed', $builder . '<static>|' . $modelName, []);
}
@@ -160,7 +160,7 @@ use Illuminate\Database\Eloquent\SoftDeletes;
* @method static \Illuminate\Database\Eloquent\Builder<static>|\Barryvdh\LaravelIdeHelper\Tests\Console\ModelsCommand\GeneratePhpdocWithForcedFqn\Models\Post whereUuidNullable($value)
* @method static \Illuminate\Database\Eloquent\Builder<static>|\Barryvdh\LaravelIdeHelper\Tests\Console\ModelsCommand\GeneratePhpdocWithForcedFqn\Models\Post whereYearNotNullable($value)
* @method static \Illuminate\Database\Eloquent\Builder<static>|\Barryvdh\LaravelIdeHelper\Tests\Console\ModelsCommand\GeneratePhpdocWithForcedFqn\Models\Post whereYearNullable($value)
* @method static \Illuminate\Database\Eloquent\Builder<static>|\Barryvdh\LaravelIdeHelper\Tests\Console\ModelsCommand\GeneratePhpdocWithForcedFqn\Models\Post withTrashed()
* @method static \Illuminate\Database\Eloquent\Builder<static>|\Barryvdh\LaravelIdeHelper\Tests\Console\ModelsCommand\GeneratePhpdocWithForcedFqn\Models\Post withTrashed(bool $withTrashed = true)
* @method static \Illuminate\Database\Eloquent\Builder<static>|\Barryvdh\LaravelIdeHelper\Tests\Console\ModelsCommand\GeneratePhpdocWithForcedFqn\Models\Post withoutTrashed()
* @mixin \Eloquent
*/
@@ -166,7 +166,7 @@ use Illuminate\Support\Carbon;
* @method static EloquentBuilder<static>|Post whereUuidNullable($value)
* @method static EloquentBuilder<static>|Post whereYearNotNullable($value)
* @method static EloquentBuilder<static>|Post whereYearNullable($value)
* @method static EloquentBuilder<static>|Post withTrashed()
* @method static EloquentBuilder<static>|Post withTrashed(bool $withTrashed = true)
* @method static EloquentBuilder<static>|Post withoutTrashed()
* @mixin Eloquent
*/
@@ -16,7 +16,7 @@ use Illuminate\Database\Eloquent\SoftDeletes;
* @method static \Illuminate\Database\Eloquent\Builder<static>|Simple onlyTrashed()
* @method static \Illuminate\Database\Eloquent\Builder<static>|Simple query()
* @method static \Illuminate\Database\Eloquent\Builder<static>|Simple whereId($value)
* @method static \Illuminate\Database\Eloquent\Builder<static>|Simple withTrashed()
* @method static \Illuminate\Database\Eloquent\Builder<static>|Simple withTrashed(bool $withTrashed = true)
* @method static \Illuminate\Database\Eloquent\Builder<static>|Simple withoutTrashed()
* @mixin \Eloquent
*/