A
A
Andrej Kopp2021-04-24 01:04:42
Laravel
Andrej Kopp, 2021-04-24 01:04:42

What nuances should be taken into account when creating a universal admin panel on Laravel?

Hello.

I would like to make a list of all the nuances and take them into account in advance before writing the admin panel on Laravel 8. At this stage, a package with laid-out pages has been created, multilingualism has been configured, the Jetstream package with Livewire has been selected for authorization, style files and js are configured and packaged via webpack.

The plans are to make co-dependent packages, upon installation of which a menu should be generated in the admin panel. For example, in the admin panel itself, there should not be anything other than displaying an authorized user and changing the language.

There are a couple more questions for general development:

  1. What should be stored in the database besides rights and roles?
  2. How to correctly generate a menu when installing other packages without using a database? (are there any good implementation examples on github?)
  3. Is it possible to use a single namespace for templates from other packages? Example:

    In the package provider:
    $this->loadViewsFrom(__DIR__.'/../resources/views/', 'sone');


    in the template file:
    {{ __('sone::admin.general')}} // вывод перевода
    {{ @include('sone::navigation.general')}}


  4. Is it worth initially giving rights and roles and menus with the admin panel? Or should it be split into separate packages?

Answer the question

In order to leave comments, you need to log in

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question