private function createUsersTable()
    {
        Schema::create('users', function ($table) {
            foreach ($this->fields as $field => $value) {
                $query = $table->$value['type']($field);

                if (isset($value['extra'])) {
                    $query->$value['extra']();
                }
            }

            $table->foreign('role_id')->references('id')->on('roles');
            $table->timestamps();
            $table->softDeletes();
        });
    }
private function createUsersTable()
    {
        Schema::create('users', function ($table) {
            foreach ($this->fields as $field => $value) {
                $query = $table->$value['type']($field);

                if (isset($value['extra'])) {
                    $query->$value['extra']();
                }
            }

            $table->foreign('role_id')->references('id')->on('roles');
            $table->timestamps();
            $table->softDeletes();
        });
    }
private function createUsersTable ( ) { Schema :: create ( 'users' , function ( $ table ) { foreach ( $ this -> fields as $ field => $ value ) { $ query = $ table -> $ value [ 'type' ] ( $ field ) ; if ( isset ( $ value [ 'extra' ] ) ) { $ query -> $ value [ 'extra' ] ( ) ; } } $ table -> foreign ( 'role_id' ) -> references ( 'id' ) -> on ( 'roles' ) ; $ table -> timestamps ( ) ; $ table -> softDeletes ( ) ; } ) ; }
Create a new Users table with
all the required fields
Create a new Users table with all the required fields