Airport Guide Documentation

CityMaster extends Model
in package
uses HasFactory

CityMaster Model for managing city and airport master data relationships.

This model is used to create and manage city master data including city names, airport information, and geographic relationships. It provides a structured interface for storing and retrieving city-specific information such as city names, airport names, airport codes, and airport relationships. The model supports comprehensive city master data management including city-airport relationships, geographic organization, and airport code mapping for enhanced airport guide platform functionality and geographic data organization.

Tags
used-by
SitemapController::cityIndexNew()

Model to store processed city data

Table of Contents

Properties

$airport_code  : string
$airport_id  : int
$airport_name  : string
$city_name  : string
$created_at  : string
$id  : int
$updated_at  : string
$fillable  : array<string|int, mixed>
The attributes that are mass assignable for city master records.

Methods

__construct()  : void
Initialize the CityMaster model with the correct database table configuration.

Properties

$airport_code

public string $airport_code

The airport code identifier

$airport_id

public int $airport_id

The foreign key reference to the airport

$airport_name

public string $airport_name

The name of the airport

$city_name

public string $city_name

The name of the city

$created_at

public string $created_at

Timestamp when the record was created

$id

public int $id

The unique identifier for the city master record

$updated_at

public string $updated_at

Timestamp when the record was last updated

$fillable

The attributes that are mass assignable for city master records.

protected array<string|int, mixed> $fillable = ['id', 'city_name', 'airport_name', 'airport_code', 'airport_id', 'created_at', 'updated_at']

This property defines the fields that can be mass-assigned when creating or updating CityMaster records. It includes all essential city master fields such as identification, city names, airport information, airport codes, airport relationships, and metadata timestamps. The fillable attributes ensure data integrity while allowing efficient bulk operations for city master data management and geographic organization across different cities and airport relationships.

Methods

__construct()

Initialize the CityMaster model with the correct database table configuration.

public __construct() : void

This function is used to create a properly configured CityMaster model instance by setting the database table name from the configuration constants. It ensures that the model interacts with the correct database table for city master data information, which is essential for proper city-airport relationship storage and retrieval operations. The constructor dynamically assigns the table name based on the CITY_MASTER configuration constant to maintain flexibility and configuration-driven behavior for city master data management.


        
On this page

Search results