Download the PHP package tonnyorg/laraseed without Composer

On this page you can find all versions of the php package tonnyorg/laraseed. 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 laraseed

LaraSeed

Package built to extend the capabilities of the Seeders and simplify the Models of your Laravel application.

Current features:

Installing the package

Configure tonnyorg/laraseed as a composer dependency running composer require tonnyorg/laraseed.

Register the package in your application's providers array (config/app.php):


Features & How-tos

Seeders trait

Useful for scenarios when you need to run seeders on production. You can store those seeders that you have run already to prevent them to run again in the future. Imagine that you have a "migrations" table for your seeders, that's it.

Instructions:

In order to use this feature, you need to run the package's migrations through php artisan migrate, that will create the seeders table used by this feature.

Once you're done, the next step is to make use of the SeedersHandler class from your database/seeds/DatabaseSeeder.php file:

The final step is to replace the call method with try. So instead of:

you are going to write it up like this:

Version variable

Imagine that you have CloudFlare or any other strong cache handler; then compiling your assets and updating the version number in the CSS and JS files is not a big deal. However, in order to burst the cache of your images you need to run a manual process and/or tag them with another name.

This feature allows you to have a "version number" based on the number of commits in your repository. That said, you only have to append ?v={{ config('laraseed.revision_number) }} everytime you place a new image on your theme (e.g. your header and footer logo images).

Instructions:

In order to make use of this feature, the first step is to publish the configuration file:

Add the LARASEED_REVISION_NUMBER=1 to your .env file.

And finally, update it everytime you release your project through the command:

Administrator model

By default, Laravel asumes that we want to use a User model for any kind of user across our application; this Administrator model allows you to separate the capabilities of your users and your staff.

I know what you are thinking about, YES!, we have ACL packages and so, but this model results helpful when your management application and your customer's one are separated and when you need to restrict the access of your management application to your staff only.

Instructions:

The first step to make use of this feature is to copy the migration file:

Run the migrations just after to create the administrators and the administrator_password_resets tables (because... we also need it, right?):

Once you're done, don't forget to add the configuration pieces in your config/auth.php file:

Finally, create a model through php artisan make:model Administrator and copy the default properties (of the User model).

Optional:

Per convenience, I also include a migration to rename the default password_resets table to user_password_resets.

We need to publish this migration:

And run the migration:

Once you're done with the migrations, then just update your config/auth.php file with the new table name:

Soft deletes

Simple migrations to add deleted_at column to your users and (if installed) your administrators tables.

Instructions:

Publish the migration:

And run the migration:

Base models

One of the more "juicy" parts of this package is the base models, which are just abstract classes that you can use as a "bootstrap" class for your models.

We have 3 types of base models: Model, SoftModel and Authenticatable, it's up to you which one to use (the SoftModel ones require your tables to have the deleted_at column).

So to clarify, looking at TonnyORG\LaraSeed\Models\Base namespace there are 3 classes:

Inside the TonnyORG\LaraSeed\Models namespace we also have 4 more classes:

Instructions:

To make use of these classes, you just need to make your models and extend from them instead of the original Illuminate\Database\Eloquent\Model class:

and:


Final notes

To-Dos

License

License details here.


All versions of laraseed with dependencies

PHP Build Version
Package Version
Requires laravel/framework Version ^7.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 tonnyorg/laraseed contains the following files

Loading the files please wait ....