Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/arzeroid/laravel-model-encryptable
A simple trait to encrypt attributes before saving to the database and to decrypt attributes before using their values.
https://github.com/arzeroid/laravel-model-encryptable
eloquent eloquent-models laravel laravel-framework laravel-package
Last synced: 5 days ago
JSON representation
A simple trait to encrypt attributes before saving to the database and to decrypt attributes before using their values.
- Host: GitHub
- URL: https://github.com/arzeroid/laravel-model-encryptable
- Owner: arzeroid
- License: mit
- Created: 2019-11-26T11:33:22.000Z (about 5 years ago)
- Default Branch: master
- Last Pushed: 2019-11-27T07:46:01.000Z (about 5 years ago)
- Last Synced: 2024-11-15T08:10:56.618Z (2 months ago)
- Topics: eloquent, eloquent-models, laravel, laravel-framework, laravel-package
- Language: PHP
- Homepage:
- Size: 3.91 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Laravel Model Encryptable
A simple trait to encrypt attributes before saving to the database and to decrypt attributes before using their values.
# Installation
Simply add the following line to your `composer.json` and run `composer update`
```
"arzeroid/laravel-model-encryptable": "^1.0",
```Or use composer to add it with the following command
```
composer require "arzeroid/laravel-model-encryptable"
```# Usage
Add the trait to your model and set your attributes to be encrypted in **encryptable** array
```php