Menu

## State extends Model
in package
uses HasFactory

State.php : 28

Class State

Model for managing states/provinces in countries.

##### Tags

mixin

### Table of Contents

#### Properties

$city : Collection|array<string|int, City>
$country : Country
$country_id : int
$created_at : DateTime
$id : int
$name : string
$school : Collection|array<string|int, School>
$status : int
$updated_at : DateTime
$userprofile : Collection|array<string|int, Userprofile>
$fillable : array<string|int, mixed>
  The attributes that are mass assignable.
$table : string
  The table associated with the model.

#### Methods

city() : HasMany
  Get cities in this state.
country() : BelongsTo
  Get the country for this state.
school() : HasMany
  Get schools in this state.
userprofile() : HasMany
  Get user profiles from this state.

### Properties

#### $city read-only

State.php : 0
`public Collection|array<string|int, City> $city`

#### $country read-only

State.php : 0
`public Country $country`

#### $country_id

State.php : 0
`public int $country_id`

#### $created_at

State.php : 0
`public DateTime $created_at`

#### $id

State.php : 0
`public int $id`

#### $name

State.php : 0
`public string $name`

#### $school read-only

State.php : 0
`public Collection|array<string|int, School> $school`

#### $status

State.php : 0
`public int $status`

#### $updated_at

State.php : 0
`public DateTime $updated_at`

#### $userprofile read-only

State.php : 0
`public Collection|array<string|int, Userprofile> $userprofile`

#### $fillable

State.php : 46

The attributes that are mass assignable.

`protected array<string|int, mixed> $fillable = ['country_id', 'name', 'status']`

#### $table

State.php : 39

The table associated with the model.

`protected string $table = 'states'`

### Methods

#### city()

State.php : 85

Get cities in this state.

`public city() : HasMany`

##### Return values

HasMany

#### country()

State.php : 55

Get the country for this state.

`public country() : BelongsTo`

##### Return values

BelongsTo

#### school()

State.php : 65

Get schools in this state.

`public school() : HasMany`

##### Return values

HasMany

#### userprofile()

State.php : 75

Get user profiles from this state.

`public userprofile() : HasMany`

##### Return values

HasMany

## Search results