Prequel for Laravel. Clear and concise database management.

Overview

Prequel

Packagist Version Join our Discord Follow Protoqol on Twitter

TL;DR? Test Prequel here!

What is Prequel exactly?

Prequel is meant to be a database management tool for Laravel to replace the need for separate standalone database tools like phpMyAdmin, Sequel Pro or MySQL Workbench. With its (hopefully) clear and concise UI, Prequel is to be a modern and lightweight database browser/tool ready for the web of the future. Prequel's design is purposefully based on that of Laravel Telescope because (web-)developers today have enough to learn and master already, so let's help eachother out and make sure to not add anything virtually useless to that huge pile of knowledge.

Prequel Screenshot

Clear and concise database management

Installation

To install follow the instructions below.
$ composer require protoqol/prequel
$ php artisan prequel:install
When installation and publishing is done navigate to /prequel in your browser to see Prequel in action!

Updating

composer require protoqol/prequel:v1.2

When using Prequel 1.2 and up you can try and use the auto updater!

And else to update you can use the command specified below.
$ php artisan prequel:update

Issues, bugs and feature requests can be reported here!

Configuration

You might have noticed that, while publishing a config file appeared under config/prequel.php. That configuration file looks something like this.

Note that you can define PREQUEL_ENABLED in your .env file.

<?php

    [

        /*
        |--------------------------------------------------------------------------
        | Prequel Master Switch : boolean
        |--------------------------------------------------------------------------
        |
        | Manually disable/enable Prequel, if in production Prequel will always be
        | disabled. Reason being that nobody should ever be able to directly look
        | inside your database besides you or your dev team (obviously).
        |
        */

        'enabled' => env('PREQUEL_ENABLED', true),


        /*
        |--------------------------------------------------------------------------
        | Prequel Locale : string
        |--------------------------------------------------------------------------
        |
        | Choose what language Prequel should display in.
        |
        */

        'locale' => env('APP_LOCALE', 'en'),


        /*
        |--------------------------------------------------------------------------
        | Prequel Path
        |--------------------------------------------------------------------------
        |
        | The path where Prequel will be residing. Note that this does not affect
        | Prequel API routes.
        |
        */

        'path' => 'prequel',


        /*
        |--------------------------------------------------------------------------
        | Laravel asset generation suffix and namespace definition
        |--------------------------------------------------------------------------
        |
        | Here you can define your preferred asset suffixes and directory/namespaces.
        | Separate with a double backwards slash to define namespace and directory
        | location. Everything after the last '\\' will be treated as a suffix.
        | Note that the backslash needs to be escaped with an extra backslash
        |
        | For example
        |
        |  Configuration
        |     'suffixes' => [
        |           'model'  => 'Models\\Model',
        |           'seeder' => 'MyMadeUpSeederSuffix'
        |       ]
        |
        |  When generating for `users` table
        |     (directory) app/models/UserModel.php
        |     (qualified class) App\Models\UserModel
        |     (directory) database/seeds/UserMyMadeUpSeederSuffix.php
        |
        */

        'suffixes' => [
            'model'      => 'Models\\',
            'seeder'     => 'Seeder',
            'factory'    => 'Factory',
            'controller' => 'Controller',
            'resource'   => 'Resource',
        ],


        /*
        |--------------------------------------------------------------------------
        | Prequel Database Configuration : array
        |--------------------------------------------------------------------------
        |
        | This enables you to fully configure your database connection for Prequel.
        |
        */

        'database' => [
            'connection' => env('DB_CONNECTION', 'mysql'),
            'host'       => env('DB_HOST', '127.0.0.1'),
            'port'       => env('DB_PORT', '3306'),
            'database'   => env('DB_DATABASE', 'homestead'),
            'username'   => env('DB_USERNAME', 'homestead'),
            'password'   => env('DB_PASSWORD', 'secret'),
        ],


        /*
        |--------------------------------------------------------------------------
        | Prequel ignored databases and tables : array
        |--------------------------------------------------------------------------
        | Databases and tables that will be ignored during database discovery.
        |
        | Using 'mysql' => ['foo']  ignores only the mysql.foo table.
        | Using 'mysql' => ['*'] ignores the entire mysql database.
        |
        */

        'ignored' => [
            // 'information_schema'  => ['*'],
            // 'sys'                 => ['*'],
            // 'performance_schema'  => ['*'],
            // 'mysql'               => ['*'],
            '#mysql50#lost+found' => ['*'],
        ],


        /*
        |--------------------------------------------------------------------------
        | Prequel pagination per page : integer
        |--------------------------------------------------------------------------
        |
        | When Prequel retrieves paginated information, this is the number of
        | records that will be in each page.
        |
        */

        'pagination' => 100,


        /*
        |--------------------------------------------------------------------------
        | Prequel middleware : array
        |--------------------------------------------------------------------------
        |
        | Define custom middleware for Prequel to use.
        |
        | Ex. 'web', Protoqol\Prequel\Http\Middleware\Authorised::class
        |
        */

        'middleware' => [
            Protoqol\Prequel\Http\Middleware\Authorised::class,
        ],
    ];

Prequel Screenshot

Clear and concise database management

Contributing

See Contributing to see how you can contribute to Prequel!

Contributors

License

Prequel is licensed under the MIT License. Please see License File for more information.

Issues
  • [Feature] Beta dark theme

    [Feature] Beta dark theme

    PR Naming convention

    [FEATURE/FIX/REFACTOR/README] Your PR title

    Issue or feature explanation

    A short explanation as to why this is needed, or, would be a great addition to Prequel! Or a reference to an open issue. this is a theme switcher, to switch between the default light theme and a dark theme

    Proposed solution/change

    Short explanation how this was done. This was done by creating root css variables and dark theme css variables paired with custom tailwind classes. Calling this beta because certain things definitely need more work but I feel like its at a good place right now to let people start using it. but could use a designers take on it.

    opened by James-N-M 14
  • [BUG] Can't make it work with Homestead

    [BUG] Can't make it work with Homestead

    So I wanted to try this package, I installed on my project but I have this error message when I want go to /prequel

    prequel1

    This is the database connection on my .env file

    DB_CONNECTION=mysql DB_HOST=127.0.0.1 DB_PORT=33060 DB_DATABASE=prequel DB_USERNAME=homestead DB_PASSWORD=secret

    opened by godhandkiller 12
  • [FEATURE] Implement dark mode

    [FEATURE] Implement dark mode

    Implement a dark mode, create a button in the top-right that can be switched on and off like the other 2 buttons.

    good first issue 
    opened by QuintenJustus 12
  • [FEATURE] List of DBs that will be ignored by default added.

    [FEATURE] List of DBs that will be ignored by default added.

    Prevent to load specific DBs.

    Practical use

    • DB #mysql#lost+found is related with a bug in MySql. Is an invalid DB that will crash Prequel if it's present. I got this problem in laravel/homestead 8.5.
    • Remove from the listing specific DBs. Good to have if you want to limit the scope of discovery of Prequel.

    Love the project, thanks for do this

    opened by mchlbatista 10
  • [BUG] FatalThrowableError after installing the prequel

    [BUG] FatalThrowableError after installing the prequel

    Describe the bug After installing the prequel package using composer, I can't make run of the php artisan route:list command.

    Screenshots image

    BUG 
    opened by luigel 9
  • [FEATURE REQUEST] Tests for source code

    [FEATURE REQUEST] Tests for source code

    Is your feature request related to a problem? Please describe. It is best practice to include some sort of unit, integration or feature type tests with your libraries. I tend not to use an open source product / library if they don't have adequate tests. Not only does it help with code quality and reducing bugs, it gives the reader an idea of how the product functions without having to do a deep-dive into the code.

    Describe the solution you'd like I'd like to see some unit tests for both front and back-end code. I'm not proposing anything insane like even 80% code, but some framework to get contributors started.

    Additional context It'd be nice to know if this is something that the author doesn't think is important, thinks they didn't have time to do, thinks isn't important, or doesn't know how to implement effectively. Sharing this sentiment can help contributors understand how to best proceed and help the project.

    opened by aaronsaray 8
  • [BUG] Table 'users'

    [BUG] Table 'users'

    Describe the bug If selected any project database table it loads correct data but if select Users table it loads in any table the data of the current database project.

    To Reproduce Steps to reproduce the behavior:

    1. Go to current project users table
    2. Click on other project database users table
    3. See error

    Expected behavior Show data of selected database table, not the project installed prequel users table data.

    Screenshots

    alt text

    Desktop (please complete the following information):

    • Chrome
    • Version 75
    BUG 
    opened by ArielMejiaDev 8
  • [FIX] fixed error in DatabaseController

    [FIX] fixed error in DatabaseController

    PR Naming convention

    [FIX] fixed error in DatabaseController

    Issue or feature explanation

    After the recent update, Prequel started showing errors when trying to access to the tables in any database.

    Proposed solution/change

    There was a chunk of code in the DatabaseController which seems to have been pasted by mistake. Removing the code allows Prequel to work again.

    opened by lukadriel7 7
  • [BUG] Can not install on laravel 6

    [BUG] Can not install on laravel 6

    Problem 1 - Installation request for composer/composer (locked at 1.9.0) -> satisfiable by composer/composer[1.9.0]. - protoqol/prequel v1.22 requires composer/composer dev-master -> satisfiable by composer/composer[dev-master]. - protoqol/prequel v1.22.1 requires composer/composer dev-master -> satisfiable by composer/composer[dev-master]. - Conclusion: don't install composer/composer dev-master - Installation request for protoqol/prequel ^1.22 -> satisfiable by protoqol/prequel[v1.22, v1.22.1].

    opened by sctouch 7
  • [RFC] Adding i18n

    [RFC] Adding i18n

    Request For Comments: Internalization - i18n

    I was thinking about all the features that Prequel is still missing and i18n came across my mind, but I'm not really sure if this is worth looking into. That's why I opened this RFC.

    See points below for my thoughts about this.

    • Would this be helpful to people?
    • Is this worth investing time into?
    • Front-end or back-end implementation?
    • Are there people willing to translate this?

    What do you think?

    For those unaware of what i18n is, it's basically translating Prequel to other languages.
    help wanted RFC 
    opened by QuintenJustus 7
  • Mysql connection by socket

    Mysql connection by socket

    #148 fix

    opened by mcmc4519 0
  • Mysql socket connection

    Mysql socket connection

    Hi! Your application is awesome!

    Is your feature request related to a problem? Please describe. I have a connection to mysql by socket. When I try use prequel, I have an error: Could not create a valid database connection. In .env file I set a path to DB_SOCKET file.

    DB_SOCKET=/var/lib/mysqld/mysqld.sock

    Can we make a connection by socket?

    opened by mcmc4519 0
  • [FEATURE REQUEST]

    [FEATURE REQUEST]

    Please provide an option for setting the baseurl, so that we can use it under subfolders

    opened by nouphaltklm 0
  • Bump path-parse from 1.0.6 to 1.0.7

    Bump path-parse from 1.0.6 to 1.0.7

    Bumps path-parse from 1.0.6 to 1.0.7.

    Commits

    Dependabot compatibility score

    Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


    Dependabot commands and options

    You can trigger Dependabot actions by commenting on this PR:

    • @dependabot rebase will rebase this PR
    • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
    • @dependabot merge will merge this PR after your CI passes on it
    • @dependabot squash and merge will squash and merge this PR after your CI passes on it
    • @dependabot cancel merge will cancel a previously requested merge and block automerging
    • @dependabot reopen will reopen this PR if it is closed
    • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
    • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
    • @dependabot use these labels will set the current labels as the default for future PRs for this repo and language
    • @dependabot use these reviewers will set the current reviewers as the default for future PRs for this repo and language
    • @dependabot use these assignees will set the current assignees as the default for future PRs for this repo and language
    • @dependabot use this milestone will set the current milestone as the default for future PRs for this repo and language

    You can disable automated security fix PRs for this repo from the Security Alerts page.

    dependencies 
    opened by dependabot[bot] 0
  • [BUG] Custom Database Connection Name

    [BUG] Custom Database Connection Name

    Describe the bug Not support with custom connection name that difference from driver name. e.g: in config database.php i am using connections with name defaultdb and driver using mysql

    To Reproduce Assume you are using mysql database. Steps to reproduce the behavior:

    1. Edit 'config/database.php' edit in connection array key with driver mysql to other than mysql. eg:
        'connections' => [
            'mydb' => [
                  'driver' => 'mysql'
                  .....
    
    1. Leave the config/prequel.php as is
    2. Open prequel on browser
    3. Error with Exception Selected invalid or unsupported database driver

    Next try i change my config path prequel.database.connection to mydb, same like on database config Open prequel on browser, and is still error with message:

    Your database connection might not be supported yet, currently supported: 'mysql', 'pgsql'. (Yours is: 'mydb').
    

    Expected behavior Prequel database config must follow the configuration from the database config, and make the connection details such as host, port, database, username, password is optional in the prequel config, just store the connection name on prequel config, and follow the rest from database config.

    Screenshots https://ibb.co/9WMmwfz https://ibb.co/8M02W7d

    PHP Version

    • Version : 8.0.8

    Database type

    • Type : mysql
    • Version : 10.5.11-MariaDB

    Desktop (please complete the following information):

    • Browser : Chrome
    • Version : 92.0.4515.107
    opened by fauzie 0
  • [BUG] Updates Are Not Current

    [BUG] Updates Are Not Current

    Describe the bug Current version in top right which provides the updater dialog shows the incorrect installed version, and when clicked, shows and installs the incorrect version.

    My current version installed is 1.22.6 updater dialog shows 1.22.4

    To Reproduce Steps to reproduce the behavior:

    1. Go to dashboard
    2. Click on v1.22 top right corner
    3. Click Try auto-update button
    4. Script installs previous version of 1.22.4

    Expected behavior Dialog should not offer to install previous version, and top version should show the current version installed.

    Screenshots Screen Shot 2021-04-30 at 4 20 09 PM

    PHP Version

    • Version 8.0.3

    Database type

    • Type mysql
    • Version 8.0.19

    Desktop

    • Browser chrome
    • Version 90.0.4430.93 (Official Build) (x86_64)
    • macOS Big Sur 11.3
    • Laravel Valet Version: 2.14.1

    Additional context After the downgrade is completed, the composer.json lists the version as:

    "protoqol/prequel": "^v1.22.4"
    

    I don't believe that v is valid, but I'm not certain, I know I didn't use a v in the version when installing it.

    Also and very importantly, the config/prequel.php file is overwritten completely!

    opened by 19peaches 0
  • [BUG] Malformed UTF-8 characters

    [BUG] Malformed UTF-8 characters

    There was an error while loading this table. See the following: Malformed UTF-8 characters, possibly incorrectly encoded

    How to fix to read my tables with this encode?

    opened by msbtec 4
  • [i18n] Help translate Prequel!

    [i18n] Help translate Prequel!

    Internationalization

    It has been decided that i18n for Prequel is definitely something people are looking for, see #33. That's why I need you guys to help translate! I am unfortunately not a polyglot 😅

    Translators

    • Brazilian Portuguese by @HDVinnie & @oojunior
    • Hungarian by @M4ST3RX
    • Dutch by @QuintenJustus
    • Finnish by @HDVinnie & @PVRCK
    • Spanish by @chuckrincon

    How can I help translate?

    • Clone the Prequel repo and pull in the Dev branch
    • Create a new branch with the following naming convention: feature-lang-{your language here}.
    • Go into resources/lang/
    • Copy the en directory and rename it to the language you're translating to, e.g. fr for French.
    • Open the lang file inside the newly created directory and you're all set to start translation!
    • When you're done you can create a pull request!
    help wanted 
    opened by QuintenJustus 3
  • Additional database type support

    Additional database type support

    Why I need your help

    Currently I'm working on a lot of features, which included adding support for different database types namely postgresql but that takes a lot of time and keeps me from adding the other features. So because of the time it takes I'm inclined to push back db support to the release after the upcoming one. But then still, it takes a lot of time.

    My request

    Is anyone willing to help me out with adding support for sqlite and sqlserver?

    Support so far

    • mysql by @QuintenJustus
    • pgsql by @M4ST3RX
    FEATURE help wanted good first issue 
    opened by QuintenJustus 5
Releases(v1.22.61)
Owner
Protoqol
Protoqol Software Development - founded by @QuintenJustus
Protoqol
Laravel IDE Helper

Laravel IDE Helper Generator Complete PHPDocs, directly from the source This package generates helper files that enable your IDE to provide accurate a

Barry vd. Heuvel 11.8k Oct 21, 2021
⚙️ A Laravel package to decompose your installed packages, their dependencies, your app & server environment

Introduction Laravel Decomposer decomposes and lists all the installed packages and their dependencies along with the Laravel & the Server environment

LUBUS 501 Oct 12, 2021
This package extends the core file generators that are included with Laravel 5

Extended Migration Generators for Laravel 6, 7 and 8 Easily define the migration schema right in your make:migration command. The new commands this pa

Laracasts 2.4k Oct 18, 2021
Laravel API Documentation Generator

Laravel API Documentation Generator Automatically generate your API documentation from your existing Laravel/Lumen/Dingo routes. php artisan apidoc:ge

Marcel Pociot 3.1k Oct 15, 2021
Creates an 'artisan workflow:make' command to scaffold out a number of useful GitHub actions workflows for Laravel

Laravel workflow generator This creates a make:workflow artisan command to scaffold out a number of useful GitHub actions workflows for Laravel. Insta

Len Woodward 9 Jul 18, 2021
A cli tool for creating Laravel packages

Laravel Packager This package provides you with a simple tool to set up a new package and it will let you focus on the development of the package inst

JeroenG 1.1k Oct 18, 2021
⛔️ Laravel Tinx is archived and no longer maintained.

⛔️ Laravel Tinx (Deprecated) Laravel Tinx was archived on 12th December 2019 and is no longer maintained. Looking for a reloadable version of Laravel

James Furey 432 Oct 15, 2021
🍪 Write gorgeous documentation for your products using Markdown inside your Laravel app.

LaRecipe Write gorgeous documentations for your products using Markdown inside your Laravel app. LaRecipe ?? LaRecipe is simply a code-driven package

Saleem Hadad 1.9k Oct 17, 2021
InfyOm Laravel Generator - API, Scaffold, Tests, CRUD Laravel Generator

InfyOm Laravel Generator Generate Admin Panels CRUDs and APIs in Minutes with tons of other features and customizations with 3 different themes. Read

InfyOmLabs (InfyOm Technologies) 3.3k Oct 13, 2021
A handful of tools for PHP developers.

Belt A handful of tools for PHP developers. Version 2.0.0 is out now. Clear documentation, improved tests and code quality. Installation In case you w

Ilya 738 Sep 4, 2021
:rocket: A Smart CRUD Generator For Laravel

Features Generate your models, views, controllers, routes and migrations just in a few clicks. Models visualization through a graph presentation (New

Houssain Amrani 860 Oct 21, 2021
A MySQL Workbench plugin which exports a Model to Laravel 5 Migrations

MySQL Workbench Export Laravel 5 Migrations Plugin A MySQL Workbench plugin that allows for exporting a model to Laravel 5 migrations that follow PSR-

Brandon Eckenrode 889 Oct 16, 2021
[Package] Lumen Testing Helper for Packages Development

anik/testbench-lumen is a package, highly inspired by the orchestral/testbench. orchestral/testbench that is a tool for testing Laravel packages.

Syed Sirajul Islam Anik 5 May 9, 2021
A PHP-based sandboxing library with a full suite of configuration and validation options.

A full-scale PHP 5.4+ sandbox class that utilizes PHP-Parser to prevent sandboxed code from running unsafe code. It also utilizes FunctionParser to di

Corveda 165 Oct 15, 2021
ICEcoder is a browser based code editor, which provides a modern approach to building websites

ICEcoder Code editor awesomeness ...in your browser ICEcoder is a browser based code editor, which provides a modern approach to building websites. By

ICEcoder 1.3k Oct 5, 2021
Module Generator Composer Package For Laravel

Module Generator Installation You can install the package via composer: composer require teacoders/module-generator Run the command below to publish t

Tea Coders 20 Sep 6, 2021
A PHP webpage that uses string replacements to generate a binary on the fly that you can enter at setup in NEOS.

openpilot-installer-generator A PHP webpage that uses string replacements to generate a binary on the fly that you can enter at setup in NEOS. What is

null 14 Sep 25, 2021
Trial account generator for NoPing

NoPing account generator (beta version) Trial account generator for NoPing TODO It is working add some errors checks Add a good readme Host the server

Benjamin 6 Sep 14, 2021
Open Swoole IDE Helper

Open Swoole IDE Helper This repo works with Open Swoole since release version v4.7.1. This package contains IDE help files for OpenSwoole. You may use

Open Swoole 1 Oct 17, 2021