Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Laravel 10 #203

Open
swus13 opened this issue Mar 4, 2023 · 3 comments
Open

Laravel 10 #203

swus13 opened this issue Mar 4, 2023 · 3 comments

Comments

@swus13
Copy link

swus13 commented Mar 4, 2023

Is the project dead?

Is there a way to use this package also in Laravel 10 via composer?

@joshbaumann
Copy link

joshbaumann commented Mar 6, 2023

@swus13 I've got this working in my Laravel 10 app. I am only using the Point class and the distanceSphere query method, but these are at least working for me.

Can reference my fork:

{
    "repositories": [
        {
            "type": "vcs",
            "url": "https://github.com/joshbaumann/laravel-mysql-spatial.git"
        }
    ]
}

Then update your dependency constraint to reference this branch:

{
    "require": {
        "grimzy/laravel-mysql-spatial": "dev-l10-compatibility",
    }
}

Finally, run: composer update

@swus13
Copy link
Author

swus13 commented Mar 7, 2023

@joshbaumann

thanks for that, unfortunately it doesn't work for me.
For polygon and point I get the following errors now.

Exception: Unknown database type polygon requested, Doctrine\DBAL\Platforms\MySQL80Platform may not support it. Exception: Unknown database type point requested, Doctrine\DBAL\Platforms\MySQL80Platform may not support it.

on this artisan call:
php artisan ide-helper:models -W

@Otajonov
Copy link

Otajonov commented Jun 7, 2023

Thanks @joshbaumann . I was upgrading an existing project taken from internet so i even dont have an idea how that package can be replaced with laravel 10 compatible alternatives. But with your repo, it just worked. Getting some warnings on debugbar but yet no exceptions. I am going to test if the project is still fully functionable.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants