Download the PHP package grnspc/addressable without Composer
On this page you can find all versions of the php package grnspc/addressable. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download grnspc/addressable
More information about grnspc/addressable
Files in grnspc/addressable
Package addressable
Short Description Laravel Addressable is a polymorphic Laravel package, for addressbook management. You can add addresses to any eloquent model with ease.
License MIT
Informations about the package addressable
GrnSpc Addresses
GrnSpc Addresses is a polymorphic Laravel package, for addressbook management. You can add addresses to any eloquent model with ease.
Installation
-
Install the package via composer:
-
Publish resources (migrations and config files):
-
Execute migrations via the following command:
- Done!
Usage
To add addresses support to your eloquent models simply use \Grnspc\Addresses\Traits\HasAddress
trait.
Adding an Address to a Model.
-
Method 1 - Via addAddress() Method
This method does a valadation check.
-
Method 2 - Via Eloquent Relationship
-
Method 3 - Create multiple new addresses
Updating an Address on a Model
-
Method 1 - Via updateAddress() Method
-
Method 2 - Via Eloquent Relationship
Deleting an Address on a Model
Delete a Single Address
-
Method 1 - Via deleteAddress() Method
-
Method 2 - Via Eloquent Relationship
Alternative way of address deletion
Delete a All Address
-
Method 1 - Via flushAddress() Method
-
Method 2 - Via Eloquent Relationship
Address Facade
Manage your Addresses on Model
The API is intuitive and very straight forward, so let's give it a quick look:
Check if a Model has Addresses
Get all Addresses for a Model
Get Latest Addresses for a Model
Scoping and Getting Primary Addresses
Scoping and Getting Billing Addresses
Scoping and Getting Shipping Addresses
Scoping Addresses by Country
Find all addresses within 5 kilometers radius from the latitude/longitude 51.1754012/-115.5715499
Changelog
Refer to the Changelog for a full history of the project.
Contributing & Protocols
Thank you for considering contributing to this project! The contribution guide can be found in CONTRIBUTING.md.
Bug reports, feature requests, and pull requests are very welcome.
- Versioning
- Pull Requests
- Coding Standards
- Feature Requests
- Git Flow
Security Vulnerabilities
If you discover a security vulnerability within this project, please submit an issue. All security vulnerabilities will be promptly addressed.
License
This software is released under The MIT License (MIT).
(c) 2014-2022 GrnSpc, Some rights reserved.
All versions of addressable with dependencies
illuminate/console Version ^8.0.0 || ^9.0.0
illuminate/database Version ^8.0.0 || ^9.0.0
illuminate/support Version ^8.0.0 || ^9.0.0
jackpopp/geodistance Version ^1.2.0
rinvex/countries Version ^8.1