u12206050/elastic-app-scout-driver
Composer 安装命令:
composer require u12206050/elastic-app-scout-driver
包简介
Elastic app search driver for Laravel Scout
README 文档
README
Elastic App Search driver for Laravel Scout.
Contents
Compatibility
The current version of Elastic App Scout Driver has been tested with the following configuration:
- PHP 7.2-7.4
- Elasticsearch 7.0-7.6
- Laravel 6.x-7.x
- Laravel Scout 7.x-8.x
Requirements
- Laravel Scout
- Elasticsearch 7.0-7.6
- App Search 7.0-7.6
Installation
The library can be installed via Composer:
composer require u12206050/elastic-app-scout-driver
Configuration
Change the driver option in the config/scout.php file to elastic_app
php artisan vendor:publish --provider="ElasticAppScoutDriver\ServiceProvider"
Add your Elastic App Search url and key to you .env file
ELASTIC_APP_ENDPOINT=
ELASTIC_APP_KEY=
Basic usage
This driver uses Elastic App Search Meaning you can have alot more flexible where clauses available READ MORE
$orders = App\Order::search('')->where('created_at', [ 'from' => '2020-01-01T12:00:00+00:00', 'to' => '2020-12-31T12:00:00+00:00' ]);
When the query string is omitted, then all records are returned.
$orders = App\Order::search()->where('user_id', 1)->get();
Please refer to the official Laravel Scout documentation and the app search api for more details and usage examples.
Maintain
All PRs and RFCs are very welcome.
统计信息
- 总下载量: 68
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 1
- 点击次数: 0
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2020-10-01
