Skip to content

Commit 4e711cc

Browse files
authored
more spaces
1 parent 0ccd8d4 commit 4e711cc

File tree

1 file changed

+23
-7
lines changed

1 file changed

+23
-7
lines changed

readme.md

Lines changed: 23 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -288,19 +288,19 @@ $ php artisan es:indices:create my_new_index
288288
```bash
289289
$ php artisan es:indices:reindex my_index my_new_index
290290

291-
# you can control bulk size. Adjust it with your server.
291+
# Control bulk size. Adjust it with your server.
292292

293293
$ php artisan es:indices:reindex my_index my_new_index --bulk-size=2000
294294

295-
# you can also control query scroll value.
295+
# Control query scroll value.
296296

297297
$ php artisan es:indices:reindex my_index my_new_index --bulk-size=2000 --scroll=2m
298298

299-
# you can skip reindexing errors such as mapper parsing exceptions.
299+
# Skip reindexing errors such as mapper parsing exceptions.
300300

301301
$ php artisan es:indices:reindex my_index my_new_index --bulk-size=2000 --skip-errors
302302

303-
# To hide all reindexing errors and show the progres bar only.
303+
# Hide all reindexing errors and show the progres bar only.
304304

305305
$ php artisan es:indices:reindex my_index my_new_index --bulk-size=2000 --hide-errors
306306
```
@@ -436,8 +436,10 @@ $documents = ES::type("my_type")->select("title", "content")->take(10)->skip(5)-
436436
```
437437
##### Where clause
438438
```php
439-
ES::type("my_type")->where("status", "published")->get();
440-
#or
439+
ES::type("my_type")->where("status", "published")->get();
440+
441+
# or
442+
441443
ES::type("my_type")->where("status", "=", "published")->get();
442444
```
443445
##### Where greater than
@@ -463,7 +465,9 @@ ES::type("my_type")->where("title", "like", "foo")->get();
463465
##### Where field exists
464466
```php
465467
ES::type("my_type")->where("hobbies", "exists", true)->get();
468+
466469
# or
470+
467471
ES::type("my_type")->whereExists("hobbies", true)->get();
468472
```
469473
##### Where in clause
@@ -473,13 +477,17 @@ ES::type("my_type")->whereIn("id", [100, 150])->get();
473477
##### Where between clause
474478
```php
475479
ES::type("my_type")->whereBetween("id", 100, 150)->get();
480+
476481
# or
482+
477483
ES::type("my_type")->whereBetween("id", [100, 150])->get();
478484
```
479485
##### Where not clause
480486
```php
481487
ES::type("my_type")->whereNot("status", "published")->get();
488+
482489
# or
490+
483491
ES::type("my_type")->whereNot("status", "=", "published")->get();
484492
```
485493
##### Where not greater than
@@ -505,7 +513,9 @@ ES::type("my_type")->whereNot("title", "like", "foo")->get();
505513
##### Where not field exists
506514
```php
507515
ES::type("my_type")->whereNot("hobbies", "exists", true)->get();
516+
508517
# or
518+
509519
ES::type("my_type")->whereExists("hobbies", true)->get();
510520
```
511521
##### Where not in clause
@@ -515,16 +525,22 @@ ES::type("my_type")->whereNotIn("id", [100, 150])->get();
515525
##### Where not between clause
516526
```php
517527
ES::type("my_type")->whereNotBetween("id", 100, 150)->get();
528+
518529
# or
530+
519531
ES::type("my_type")->whereNotBetween("id", [100, 150])->get();
520532
```
521533

522534
##### Search by a distance from a geo point
523535
```php
524536
ES::type("my_type")->distance("location", ["lat" => -33.8688197, "lon" => 151.20929550000005], "10km")->get();
537+
525538
# or
539+
526540
ES::type("my_type")->distance("location", "-33.8688197,151.20929550000005", "10km")->get();
541+
527542
# or
543+
528544
ES::type("my_type")->distance("location", [151.20929550000005, -33.8688197], "10km")->get();
529545
```
530546

@@ -618,7 +634,7 @@ Package comes with a built-in caching layer based on laravel cache.
618634
```php
619635
ES::type("my_type")->search("foo")->remember(10)->get();
620636

621-
# you can specify a custom cache key
637+
# Specify a custom cache key
622638

623639
ES::type("my_type")->search("foo")->remember(10, "last_documents")->get();
624640

0 commit comments

Comments
 (0)