informatique:php:laravel
Différences
Ci-dessous, les différences entre deux révisions de la page.
Les deux révisions précédentesRévision précédenteProchaine révision | Révision précédenteProchaine révisionLes deux révisions suivantes | ||
informatique:php:laravel [23/08/2023 18:11] – [Error catcher] cyrille | informatique:php:laravel [24/09/2023 17:51] – [Data, ORM, Eloquent] cyrille | ||
---|---|---|---|
Ligne 250: | Ligne 250: | ||
* [[https:// | * [[https:// | ||
* [[https:// | * [[https:// | ||
+ | |||
+ | ==== Boot & initialize Trait ==== | ||
+ | |||
+ | Eloquent peut booter et initialiser les Traits utilisés par les modèles, en utilisant la méthode de nommage **boot< | ||
+ | |||
+ | https:// | ||
==== Model validation ==== | ==== Model validation ==== | ||
Ligne 636: | Ligne 642: | ||
* [[https:// | * [[https:// | ||
+ | ==== PhpDoc ==== | ||
+ | |||
+ | Merci à [[https:// | ||
+ | |||
+ | < | ||
+ | /** | ||
+ | * @mixin \Illuminate\Database\Eloquent\Builder | ||
+ | * | ||
+ | * @method static \Illuminate\Database\Eloquent\Builder|static query() | ||
+ | * @method static static make(array $attributes = []) | ||
+ | * @method static static create(array $attributes = []) | ||
+ | * @method static static forceCreate(array $attributes) | ||
+ | * @method \App\Models\User firstOrNew(array $attributes = [], array $values = []) | ||
+ | * @method \App\Models\User firstOrFail($columns = [' | ||
+ | * @method \App\Models\User firstOrCreate(array $attributes, | ||
+ | * @method \App\Models\User firstOr($columns = [' | ||
+ | * @method \App\Models\User firstWhere($column, | ||
+ | * @method \App\Models\User updateOrCreate(array $attributes, | ||
+ | * @method null|static first($columns = [' | ||
+ | * @method static static findOrFail($id, | ||
+ | * @method static static findOrNew($id, | ||
+ | * @method static null|static find($id, $columns = [' | ||
+ | * | ||
+ | * @property-read int $id | ||
+ | * | ||
+ | * @property string $first_name | ||
+ | * @property string $last_name | ||
+ | * @property \Illuminate\Support\Collection|null $favorite_songs | ||
+ | * @property int $stars | ||
+ | * | ||
+ | * @property-read \Illuminate\Support\Carbon $created_at | ||
+ | * @property-read \Illuminate\Support\Carbon $updated_at | ||
+ | * @property-read \Illuminate\Support\Carbon $deleted_at | ||
+ | * | ||
+ | * @property-read string $full_name | ||
+ | * | ||
+ | * @property-read \App\Models\Avatar $avatar | ||
+ | * @property-read \App\Models\Biography|null $biography | ||
+ | * @property-read \Illuminate\Database\Eloquent\Collection|\App\Models\Post[] $posts | ||
+ | * | ||
+ | * @method \Illuminate\Database\Eloquent\Builder|static age(int $age) | ||
+ | */ | ||
+ | </ | ||
==== Wordpress and Laravel ==== | ==== Wordpress and Laravel ==== |
informatique/php/laravel.txt · Dernière modification : 26/04/2024 09:19 de cyrille