2017-11-19 4 views
1

I really don't know what the problem is!コール ReadConcern ::のIsDefault()

class RegisterController extends Controller 
{ 
    public function store(request $request) 
    { 

     $reg = Register::all(); 
     var_dump($reg); 

と登録はどうやらこれは、ライブラリの最新バージョンから取られた方法である

class Register extends Moloquent 
{ 

    protected $connection='mongodb'; 
    protected $collection='registers'; 

} 
+0

チェックを実行しますgithubの上でこの問題:https://github.com/mongodb/mongo

は、以下の内容を置き換えることによって、composer.lockファイルを更新し、一時的にこの問題を解決するために、 -php-library/issues/412 –

答えて

1

あるmongodb/mongodb

この方法は、バージョン番号1.1.2でも利用できます。

{ 
    "name": "mongodb/mongodb", 
    "version": "1.1.2", 
    "source": { 
     "type": "git", 
     "url": "https://github.com/mongodb/mongo-php-library.git", 
     "reference": "a307dd60e71e1291c60927ea4f3a1905146063f5" 
    }, 
    "dist": { 
     "type": "zip", 
     "url": "https://api.github.com/repos/mongodb/mongo-php-library/zipball/a307dd60e71e1291c60927ea4f3a1905146063f5", 
     "reference": "a307dd60e71e1291c60927ea4f3a1905146063f5", 
     "shasum": "" 
    }, 
    "require": { 
     "ext-mongodb": "^1.2.0", 
     "php": ">=5.4" 
    }, 
    "require-dev": { 
     "phpunit/phpunit": "^4.8" 
    }, 
    "type": "library", 
    "autoload": { 
     "psr-4": { 
      "MongoDB\\": "src/" 
     }, 
     "files": [ 
      "src/functions.php" 
     ] 
    }, 
    "notification-url": "https://packagist.org/downloads/", 
    "license": [ 
     "Apache-2.0" 
    ], 
    "authors": [ 
     { 
      "name": "Jeremy Mikola", 
      "email": "[email protected]" 
     }, 
     { 
      "name": "Hannes Magnusson", 
      "email": "[email protected]" 
     }, 
     { 
      "name": "Derick Rethans", 
      "email": "[email protected]" 
     } 
    ], 
    "description": "MongoDB driver library", 
    "homepage": "https://jira.mongodb.org/browse/PHPLIB", 
    "keywords": [ 
     "database", 
     "driver", 
     "mongodb", 
     "persistence" 
    ], 
    "time": "2017-02-16T18:40:32+00:00" 
}, 

そしてcomposer install