Download the PHP package connor-lock05/laravel-admin without Composer

On this page you can find all versions of the php package connor-lock05/laravel-admin. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package laravel-admin

Laravel Admin Panel

Latest Version on Packagist Total Downloads License

Table of Contents

Introduction

A Laravel Admin Panel for laravel applications providing a simple and easy to use interface to create, view, edit or delete model records.

Installation

You can install the package via Composer:

Usage

Accessing the admin panel

To access the admin panel there are two available methods of authorisation.

  1. You can use the ConnorLock05\LaravelAdmin\Middleware\RoleAuthorisation middleware. This will use the logged-in user to check they have the correct roles

    Requires the spatie/laravel-permission package to be installed

  2. Or you can use the ConnorLock05\LaravelAdmin\Middleware\IpAuthorisation middleware. This will use the ip origin for the request compared to a comma separated list of ip addresses defined in your .env file Define ADMIN_ALLOWED_IPS in your .env to a list of allowed IPs. i.e (ADMIN_ALLOWED_IPS=127.0.0.1,127.0.0.2)

When using RoleAuthorisation

  1. Run through the installation process for spatie/laravel-permission here
  2. You will need to add authentication middleware before the RoleAuthorisation middleware to ensure a user is logged in. Do this in the laravel-admin.php config file (See Configuration)
  3. You will need to create a role for the admin panel access and add this to your config file.

    See how to customise the admin config here

    By default, the 'Admin' role is allowed access to the admin panel.

Once logged in, visit /admin to get to the admin panel dashboard

Setting Up Models

To allow a model to be interacted with by the Admin panel, you need to use the ConnorLock05\LaravelAdmin\Traits\ModifiedByAdminPanel trait on a model This will then require you to define two functions: getModifiableFields and getFieldsForIndexView

getModifiableFields

The getModifiableFields function defines what fields are editable by the admin panel and the data type of the field. This function returns an associative array with strings (column names) as keys, and ConnorLock05\LaravelAdmin\Interfaces\Type as values.

There are several types defined:

Example

getFieldsForIndexView

The getFieldsForIndexView function defines what fields are shown in the list on the index view. This function returns a non-associative array of strings of column names to include

Example

Customisation

Configuration

To publish the configuration for this package, run

Overriding Views

To publish the views for overriding, run:

Views will be published to resources/views/vendor/admin/

License

Laravel Admin is open-sourced software licensed under the MIT license.


All versions of laravel-admin with dependencies

PHP Build Version
Package Version
Requires php Version ^8.2
laravel/framework Version ^11.0
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package connor-lock05/laravel-admin contains the following files

Loading the files please wait ....