An Eloquent model and Query builder with support for MongoDB, using the original Laravel API. *This library extends the original Laravel classes, so it uses exactly the same methods.*
All other (unsupported) operations are implemented as dummy pass-through methods, because MongoDB does not use a predefined schema. Read more about the schema builder on http://laravel.com/docs/schema
All other (unsupported) operations are implemented as dummy pass-through methods, because MongoDB does not use a predefined schema. Read more about the schema builder on https://laravel.com/docs/6.0/migrations#tables
### Geospatial indexes
...
...
@@ -324,6 +323,7 @@ If you want to use MongoDB as your database backend, change the driver in `confi
'queue'=>'default',
'expire'=>60,
],
]
```
If you want to use MongoDB to handle failed jobs, change the database in `config/queue.php`:
...
...
@@ -332,7 +332,7 @@ If you want to use MongoDB to handle failed jobs, change the database in `config
'failed'=>[
'database'=>'mongodb',
'table'=>'failed_jobs',
],
],
```
And add the service provider in `config/app.php`:
...
...
@@ -705,7 +705,7 @@ For more information about model manipulation, check http://laravel.com/docs/elo
### Dates
Eloquent allows you to work with Carbon/DateTime objects instead of MongoDate objects. Internally, these dates will be converted to MongoDate objects when saved to the database. If you wish to use this functionality on non-default date fields, you will need to manually specify them as described here: http://laravel.com/docs/eloquent#date-mutators
Eloquent allows you to work with Carbon/DateTime objects instead of MongoDate objects. Internally, these dates will be converted to MongoDate objects when saved to the database. If you wish to use this functionality on non-default date fields, you will need to manually specify them as described here: https://laravel.com/docs/5.0/eloquent#date-mutators
Example:
...
...
@@ -782,7 +782,7 @@ class User extends Eloquent {
```
Other relations are not yet supported, but may be added in the future. Read more about these relations on http://laravel.com/docs/eloquent#relationships
Other relations are not yet supported, but may be added in the future. Read more about these relations on https://laravel.com/docs/master/eloquent-relationships