https://github.com/mahmoudmohamedramadan/easy-model
A Laravel package for enjoyably managing database queries.
https://github.com/mahmoudmohamedramadan/easy-model
composer database easy-model eloquent laravel mssql mysql orm pdo sql sqlite sqlserver
Last synced: 2 days ago
JSON representation
A Laravel package for enjoyably managing database queries.
- Host: GitHub
- URL: https://github.com/mahmoudmohamedramadan/easy-model
- Owner: mahmoudmohamedramadan
- Created: 2024-09-30T08:51:27.000Z (7 months ago)
- Default Branch: 1.x
- Last Pushed: 2024-12-14T05:56:37.000Z (4 months ago)
- Last Synced: 2025-02-26T04:56:20.767Z (about 2 months ago)
- Topics: composer, database, easy-model, eloquent, laravel, mssql, mysql, orm, pdo, sql, sqlite, sqlserver
- Language: PHP
- Homepage:
- Size: 713 KB
- Stars: 7
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- Funding: .github/FUNDING.yml
Awesome Lists containing this project
README
# Easy Model



- - -
- [Overview](#overview)
- [Installation](#installation)
- [Usage](#usage)
- [Credits](#credits)
- [Support Me](#support-me)## Overview
Why this package?
**I am focused on simplifying the syntax to match my vision, making it easier for you to perform tasks that typically require more lines of code or effort in Laravel. I am also addressing issues that Laravel still faces. The package is actively maintained, and I regularly review closed PRs in Laravel to find methods to help achieve this.**
What makes this package featured?
- **Accelerated Query Performance:**
- Significantly improved query performance compared to native Laravel.- **Straightforward and Unified Syntax:**
- Provides a unified, consistent syntax for `Query Builder` and `Eloquent Builder`. For more details, see [Establish Query](SEARCH.md#establish-query).- **Resolved Ambiguous Exception:**
- Fixes the ambiguous exception that arises when using the same column in both models and their relationships during ordering.- **Simplified Relationship Ordering:**
- Easily order results by model relationships (`HasOne`, `HasMany`, `BelongsTo`, `BelongsToMany`) without referring to manual joins. Check out [Order Results](SEARCH.md#order-results) to learn more.- **Streamline Batch Updates:**
- Effortlessly perform multiple updates using concise methods, consult [update.md](UPDATE.md).- And more...
## Installation
Install the package by using [Composer](https://getcomposer.org/):
```SHELL
composer require ramadan/easy-model
```## Usage
> [!WARNING]
> Do not use both traits together, as doing so may lead to unexpected output. However, if you do, the most priority will be given to the **Searchable** trait.For comprehensive examples and in-depth usage guidelines, check out [search.md](SEARCH.md) and [update.md](UPDATE.md).
## Credits
- [Mahmoud Ramadan](https://github.com/mahmoudmohamedramadan)
- [Contributors](https://github.com/mahmoudmohamedramadan/easy-model/graphs/contributors)## Support me
- [PayPal](https://www.paypal.com/paypalme/mmramadan496)
## License
The MIT License (MIT).