diff --git a/src/Models/Model.php b/src/Models/Model.php index ffeb623..05dc650 100644 --- a/src/Models/Model.php +++ b/src/Models/Model.php @@ -7,6 +7,7 @@ use Illuminate\Database\Eloquent\Builder; use Illuminate\Database\Eloquent\Factories\HasFactory; use Illuminate\Database\Eloquent\SoftDeletes; +use Illuminate\Support\Carbon; use Playground\Models\Interfaces\WithChildrenInterface; use Playground\Models\Interfaces\WithCreatorInterface; use Playground\Models\Interfaces\WithModifierInterface; @@ -24,6 +25,11 @@ * @method Builder ScopeSort(Builder $builder, array|string $sort = null) * @method Builder|static sort(mixed $sort = null) * @method Builder scopeFilterTrash(Builder $builder, string $visibility = null) + * + * @property ?Carbon $deleted_at + * @property string $created_by_id + * @property string $modified_by_id + * @property string $owned_by_id */ abstract class Model extends UuidModel implements WithChildrenInterface, WithCreatorInterface, WithModifierInterface, WithOwnerInterface, WithParentInterface { diff --git a/src/Models/User.php b/src/Models/User.php index e7117c4..ccefb49 100644 --- a/src/Models/User.php +++ b/src/Models/User.php @@ -4,21 +4,86 @@ */ namespace Playground\Models; -use Illuminate\Contracts\Auth\MustVerifyEmail; use Illuminate\Database\Eloquent\Concerns\HasUuids; use Illuminate\Database\Eloquent\Factories\HasFactory; -use Illuminate\Database\Eloquent\SoftDeletes; use Illuminate\Foundation\Auth\User as Authenticatable; -use Illuminate\Notifications\Notifiable; +use Illuminate\Support\Carbon; /** * \Playground\Models\User + * + * @property string $id + * @property string $created_by_id + * @property string $modified_by_id + * @property string $user_type + * @property ?Carbon $created_at + * @property ?Carbon $updated_at + * @property ?Carbon $email_verified_at + * @property ?Carbon $banned_at + * @property ?Carbon $suspended_at + * @property int $gids + * @property int $po + * @property int $pg + * @property int $pw + * @property int $status + * @property int $rank + * @property int $size + * @property bool $active + * @property bool $banned + * @property bool $flagged + * @property bool $internal + * @property bool $locked + * @property bool $problem + * @property bool $suspended + * @property bool $unknown + * @property string $name + * @property string $email + * @property string $locale + * @property string $phone + * @property string $timezone + * @property string $role + * @property string $description + * @property string $image + * @property string $avatar + * @property array $abilities + * @property array $accounts + * @property array $address + * @property array $contact + * @property array $meta + * @property array $notes + * @property array $options + * @property array $registration + * @property array $roles + * @property array $permissions + * @property array $privileges + * @property array $ui + * + * NOTE: This model does not include all available Laravel and Playground + * features. Read more on the Playground Wiki. + * + * @link https://github.com/gammamatrix/playground/wiki + * + * Available traits and contracts: + * @see \Illuminate\Contracts\Auth\MustVerifyEmail + * @see \Illuminate\Database\Eloquent\SoftDeletes + * @see \Illuminate\Notifications\Notifiable + * @see \Laravel\Sanctum\HasApiTokens + * @see \Laravel\Sanctum\Contracts\HasApiTokens + * @see Interfaces\WithCreatorInterface + * @see Interfaces\WithModifierInterface + * @see Traits\ScopeFilterColumns + * @see Traits\ScopeFilterDates + * @see Traits\ScopeFilterFlags + * @see Traits\ScopeFilterIds + * @see Traits\ScopeFilterTrash + * @see Traits\ScopeSort + * @see Traits\WithCreator + * @see Traits\WithModifier */ -class User extends Authenticatable implements Contracts\Abilities, Contracts\Admin, Contracts\Privileges, Contracts\Role, MustVerifyEmail +class User extends Authenticatable implements Contracts\Abilities, Contracts\Admin, Contracts\Privileges, Contracts\Role { - use HasFactory, Notifiable; + use HasFactory; use HasUuids; - use SoftDeletes; use Traits\Abilities; use Traits\Admin; use Traits\Privileges; @@ -228,4 +293,6 @@ class User extends Authenticatable implements Contracts\Abilities, Contracts\Adm public $incrementing = false; protected $perPage = 250; + + protected $table = 'users'; }