PHPackages                             connor-lock05/laravel-admin - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Admin Panels](/categories/admin)
4. /
5. connor-lock05/laravel-admin

ActiveLibrary[Admin Panels](/categories/admin)

connor-lock05/laravel-admin
===========================

Adds an admin panel to a Laravel Application allowing for a UI to modify model data

1.3.3(1y ago)036MITPHPPHP ^8.2

Since Aug 23Pushed 1y ago1 watchersCompare

[ Source](https://github.com/Conarix/laravel-admin)[ Packagist](https://packagist.org/packages/connor-lock05/laravel-admin)[ RSS](/packages/connor-lock05-laravel-admin/feed)WikiDiscussions main Synced 3d ago

READMEChangelogDependencies (1)Versions (11)Used By (0)

Laravel Admin Panel
===================

[](#laravel-admin-panel)

[![Latest Version on Packagist](https://camo.githubusercontent.com/4dd77238d1b1a4e0822f527033f83a15daa0193bd2d293ef8e802988bb0091bb/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f636f6e6e6f722d6c6f636b30352f6c61726176656c2d61646d696e2e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/connor-lock05/laravel-admin)[![Total Downloads](https://camo.githubusercontent.com/0d6c05c197af6782e910e384e77cf95a9ee60dc9c2cb322e04f29a7acd3bea23/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f636f6e6e6f722d6c6f636b30352f6c61726176656c2d61646d696e2e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/connor-lock05/laravel-admin)[![License](https://camo.githubusercontent.com/def5cb1a3f72e2d36133fa9b7463bcf52013f688eca82be9e2f697acd5bf90b6/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f6c2f636f6e6e6f722d6c6f636b30352f6c61726176656c2d61646d696e2e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/connor-lock05/laravel-admin)

Table of Contents
-----------------

[](#table-of-contents)

- [Introduction](#introduction)
- [Installation](#installation)
- [Usage](#usage)
    - [Accessing the Admin Panel](#accessing-the-admin-panel)
    - [Setting Up Models](#setting-up-models)
- [Customisation](#customisation)
    - [Configuration](#configuration)
    - [Overriding Views](#overriding-views)
- [License](#license)

Introduction
------------

[](#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
------------

[](#installation)

You can install the package via Composer:

```
composer require connor-lock05/laravel-admin
```

Usage
-----

[](#usage)

### Accessing the admin panel

[](#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

[](#when-using-roleauthorisation)

1. Run through the installation process for spatie/laravel-permission [here](https://spatie.be/docs/laravel-permission/v6/installation-laravel)
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](#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](#configuration)
>
> 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

[](#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

[](#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:

- `ConnorLock05\LaravelAdmin\Types\Text` This is a string field
- `ConnorLock05\LaravelAdmin\Types\Number` This is an integer field
- `ConnorLock05\LaravelAdmin\Types\Password` This is a password field, the value won't be added to the field on edit and if a value is not provided it will not be updated
- `ConnorLock05\LaravelAdmin\Types\Picklist` This is a select field, an array of options is provided on creation where keys are the option label and the value is the option value
- `ConnorLock05\LaravelAdmin\Types\TextArea` This is a text area field (intended for text column types)
- `ConnorLock05\LaravelAdmin\Types\Related` This is a related field, a model is provided on instantiation alongside an optional 'referenceColumn' which is the column name for the field to use as the option label (primary key column is default)

> Example

```
public static function getModifiableFields(): array
{
    return [
        'title' => new Text(),
        'user_id' => new Related(User::class, 'name'),
        'body' => new TextArea()
    ];
}
```

#### getFieldsForIndexView

[](#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

```
public static function getFieldsForIndexView(): array
{
    return [
        'name',
        'email'
    ];
}
```

Customisation
-------------

[](#customisation)

### Configuration

[](#configuration)

To publish the configuration for this package, run

```
php artisan vendor:publish --tag="admin-config"
```

### Overriding Views

[](#overriding-views)

To publish the views for overriding, run:

```
php artisan vendor:publish --tag="admin-views"
```

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

License
-------

[](#license)

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

###  Health Score

29

—

LowBetter than 57% of packages

Maintenance33

Infrequent updates — may be unmaintained

Popularity7

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity59

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~1 days

Total

10

Last Release

665d ago

PHP version history (2 changes)1.0.0PHP 8.2.\*

1.3.1PHP ^8.2

### Community

Maintainers

![](https://www.gravatar.com/avatar/02d8c1dec58f3d42210d1cfd575868f779dcc48919c8e497e819c244112772ea?d=identicon)[Connor-Lock05](/maintainers/Connor-Lock05)

---

Top Contributors

[![Conarix](https://avatars.githubusercontent.com/u/42944992?v=4)](https://github.com/Conarix "Conarix (11 commits)")

### Embed Badge

![Health badge](/badges/connor-lock05-laravel-admin/health.svg)

```
[![Health](https://phpackages.com/badges/connor-lock05-laravel-admin/health.svg)](https://phpackages.com/packages/connor-lock05-laravel-admin)
```

###  Alternatives

[backpack/crud

Quickly build admin interfaces using Laravel, Bootstrap and JavaScript.

3.4k3.7M223](/packages/backpack-crud)[dcat-plus/laravel-admin

dcat-plus admin

1474.0k10](/packages/dcat-plus-laravel-admin)[duncanmcclean/statamic-cargo

Comprehensive e-commerce addon for Statamic. Build bespoke e-commerce sites without the complexity.

3417.0k](/packages/duncanmcclean-statamic-cargo)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
