method not exist:think\db\Mongo->getFieldType
class Admin extends Model
{
protected $table = "admin";
public $schema = [
'_id' => 'string',
'groupid' => 'string', //所属分组
'username' => 'string',
'password' => 'string',
'code' => 'string',
'created' => 'int',
'logintime' => 'int'
];
}在控制器中实例化时$admin = new Admin(); 最佳答案