Download the PHP package islamwalied/one-click-module without Composer

On this page you can find all versions of the php package islamwalied/one-click-module. 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 one-click-module

One Click Module

OneClickModule is a Laravel package that simplifies creating and managing CRUD operations within a modular structure. It provides tools to generate complete modules or entities with all necessary files and safely remove them when no longer needed.

Key Features

Installation

Install via Composer:

The package auto-registers its service provider and commands using Laravel's discovery feature.

Requirements

Composer Configuration

Add the GD extension to your composer.json:

And Also Add Modules autoload to composer.json inside psr-4 append

Important Tip

you should run these commands or just the last one everytime you make new model in the module

Optional Dependency

For translatable fields, install:

Usage

The package provides two Artisan commands for managing modules and entities:

1. Create a Module or Entity

Generate a module or entity with full CRUD functionality:

Example

Interactive Setup
  1. Model Attributes: Define column names, types, and modifiers:

    • Example:

    • Supported types: string, json, integer, unsignedBigInteger, foreignId, boolean, text, longText, date, timestamp, decimal, float, double, enum, uuid, char, mediumText, tinyInteger, bigInteger.
    • Modifiers: nullable, unique, default=value.
  2. Foreign Keys: Specify the referenced table for foreignId or unsignedBigInteger:

    • Example:
  3. Enum Values: Provide allowed values for enum types:

    • Example:
  4. Translations: Enable and select translatable attributes:
    • Example:
Generated Files

Under Modules/{Module}:

2. Delete an Entity

Remove an entity and its associated files:

Example

Actions

Publishing Files

Enable all features by publishing necessary files:

Post-Generation Steps

  1. Register Providers: Ensure App\Providers\ModuleServiceProvider is in bootstrap/providers.php (auto-handled, but can be added manually):

  2. Run Migrations:

  3. Test API: Use tools like Postman to test endpoints (e.g., GET /api/v1/countries).

Configuration

No additional setup is required by default. For translatable fields, configure spatie/laravel-translatable.

Image Storage

The ImageTrait uses the public disk by default. Customize via filesystems.php or extend the trait.

Logging

After publishing logging files, update config/logging.php:

API Endpoints

Generated routes in Modules/{Module}/Http/Routes/{entity}.php:

Routes are prefixed with v1/ and include cors, lang, and throttle middleware. auth:sanctum is applied to store, update, and destroy.

Advanced Features

Attribute Modifiers

Supported modifiers:

Enum Columns

Define allowed values for enum types, included in migrations and validation.

Foreign Keys

For foreignId or unsignedBigInteger, migrations include constraints with cascade rules, and request classes include exists validation.

Translatable Fields

Uses Spatie\Translatable\HasTranslations for JSON-based translatable attributes.

Service-Repository Pattern

Notes

Contributing

  1. Fork the repository.
  2. Create a feature branch (git checkout -b feature/your-feature).
  3. Commit changes (git commit -m "Add your feature").
  4. Push the branch (git push origin feature/your-feature).
  5. Submit a Pull Request.

Issues

Report issues or suggestions at GitHub Issues.

License

Licensed under the MIT License.

Credits

Developed by Islam Walied. Thanks to the Laravel community for inspiration and support.


All versions of one-click-module with dependencies

PHP Build Version
Package Version
Requires php Version ^8.0
laravel/framework Version ^11.0|^12.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 islamwalied/one-click-module contains the following files

Loading the files please wait ...