PHPackages                             czim/laravel-cms-models - 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. [Database &amp; ORM](/categories/database)
4. /
5. czim/laravel-cms-models

AbandonedArchivedLibrary[Database &amp; ORM](/categories/database)

czim/laravel-cms-models
=======================

Laravel CMS: Main Models Module Generator

1.7.3(6y ago)62.2k[9 issues](https://github.com/czim/laravel-cms-models/issues)PHPPHP &gt;=7.1.3

Since Nov 20Pushed 5y ago2 watchersCompare

[ Source](https://github.com/czim/laravel-cms-models)[ Packagist](https://packagist.org/packages/czim/laravel-cms-models)[ Docs](https://github.com/czim)[ RSS](/packages/czim-laravel-cms-models/feed)WikiDiscussions master Synced 2mo ago

READMEChangelogDependencies (14)Versions (59)Used By (0)

[![Latest Version on Packagist](https://camo.githubusercontent.com/d3956f742df8b1bc3ea1ee84f6d3d180e053826e0b4ec2b913dd9e2348b99eb5/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f637a696d2f6c61726176656c2d636d732d6d6f64656c732e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/czim/laravel-cms-models)[![Software License](https://camo.githubusercontent.com/55c0218c8f8009f06ad4ddae837ddd05301481fcf0dff8e0ed9dadda8780713e/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f6c6963656e73652d4d49542d627269676874677265656e2e7376673f7374796c653d666c61742d737175617265)](LICENSE.md)[![Build Status](https://camo.githubusercontent.com/c7b9757a0cd048670c92befcc480918072fbef2a43a5d1ce49d043b5497409b5/68747470733a2f2f7472617669732d63692e6f72672f637a696d2f6c61726176656c2d636d732d6d6f64656c732e7376673f6272616e63683d6d6173746572)](https://travis-ci.org/czim/laravel-cms-models)[![Coverage Status](https://camo.githubusercontent.com/19333f72c3bbdda9307479a5619f918c84c77d97f522a7de4bd27f51e03c1c80/68747470733a2f2f636f766572616c6c732e696f2f7265706f732f6769746875622f637a696d2f6c61726176656c2d636d732d6d6f64656c732f62616467652e7376673f6272616e63683d6d6173746572)](https://coveralls.io/github/czim/laravel-cms-models?branch=master)

CMS for Laravel - Main Models Module
====================================

[](#cms-for-laravel---main-models-module)

This module offers the means to edit Eloquent models through the Laravel CMS.

Features:

- Model listings
- Edit forms for creating and updating model records
- Elaborate (optional) module configuration and customization.
    - Customizable listing columns, scopes, filters, sorting, etc.
    - Customizable edit form html, fields, validation rules, create vs. edit forms, etc.
    - Customizable model references, display labels, etc.
- Support for Translatable models
- Support for Listify'd models, with drag/drop reordering
- Support for nested child-parent listings and breadcrumb trails

To be used to with the [Laravel CMS Core](https://github.com/czim/laravel-cms-core).

For a better end-user experience when using file uploads, installing the [Laravel CMS Upload Module](https://github.com/czim/laravel-cms-upload-module) is recommended.

Version Compatibility
---------------------

[](#version-compatibility)

LaravelPackage5.31.35.41.45.51.55.61.65.71.7Changelog
---------

[](#changelog)

[View the changelog](CHANGELOG.md).

Installation
------------

[](#installation)

Add the module class to your `cms-modules.php` configuration file:

```
    'modules' => [
        // ...
        Czim\CmsModels\Modules\ModelModuleGenerator::class,
    ],
```

Add the service provider to your `cms-modules.php` configuration file:

```
    'providers' => [
        // ...
        Czim\CmsModels\Providers\CmsModelsServiceProvider::class,
        // ...
    ],
```

To publish the config:

```
php artisan vendor:publish
```

Configuration
-------------

[](#configuration)

Models may be added with basic functionality by simply registering them in the `cms-models` config, or special CMS model configuration files may be created for them to customize them as needed.

### Adding and Configuring Models

[](#adding-and-configuring-models)

To register models with the CMS module, you can either:

- Add their full class name to the `cms-models.models` config array:

    ```
