Airport Guide Documentation

GlobalSettingController extends BaseController
in package

Global Setting Controller

This controller manages comprehensive global settings operations including site configuration, contact information, social media links, email settings, and branding assets. It provides functionality for managing global site settings with advanced configuration options and image upload capabilities for logos and favicons.

Table of Contents

Methods

__construct()  : void
Create a new GlobalSettingController instance.
index()  : View
Display the global settings management interface.
update()  : void
Update the global settings in storage.
UploadImageToServer()  : void
Upload images to server for global settings.

Methods

__construct()

Create a new GlobalSettingController instance.

public __construct() : void

Checks if user is logged in and has proper permissions for global settings management. Redirects to appropriate page if permissions are not met.

index()

Display the global settings management interface.

public index(Request $request) : View

Loads the current global settings and displays the settings management form. Provides access to all site-wide configuration options including contact info, social media links, email settings, and branding assets.

Parameters
$request : Request
Return values
View

update()

Update the global settings in storage.

public update(Request $request, int $id) : void

Validates and updates all global settings including contact information, social media links, email configuration, and site branding. Handles conditional field updates and logs activity. Returns JSON response for AJAX requests with success/error status.

Parameters
$request : Request
$id : int

UploadImageToServer()

Upload images to server for global settings.

public UploadImageToServer(Request $request) : void

Handles file upload for various global setting images including logos, favicons, and gallery photos. Validates file types and routes to appropriate processing methods. Supports multiple image types with different processing requirements.

Parameters
$request : Request

        
On this page

Search results