jarektkaczyk / eloquence-base

base for the Eloquence extensions + Searchable
https://softonsofa.com
MIT License
77 stars 69 forks source link

5.8 BelongsTo Relation fix #13

Closed OzanKurt closed 5 years ago

OzanKurt commented 5 years ago

@jarektkaczyk Please merge <3

jarektkaczyk commented 5 years ago

@OzanKurt thanks, could your write a failing test for that too?

OzanKurt commented 5 years ago

I don't know what you mean by that. :/

jarektkaczyk commented 5 years ago

@OzanKurt show me how it's broken in a sample code, that will do :)

thanks!

OzanKurt commented 5 years ago

Pretty simple,

// relation -> BelongsTo
Model::joinRelations(['relation'])->get();

the code above generates this Exception:

BadMethodCallException
Call to undefined method Illuminate\Database\Eloquent\Relations\BelongsTo::getQualifiedForeignKey()

I hope this helps.

ghost commented 5 years ago

Please add this update, as the implementation is broken in Laravel 5.8.

The change is documented in upgrade guide: https://laravel.com/docs/5.8/upgrade

jarektkaczyk commented 5 years ago

@studmon @OzanKurt tagged https://github.com/jarektkaczyk/eloquence-base/releases/tag/v5.6.3

coachops commented 5 years ago

Hi, @jarektkaczyk thanks for the great package. Just to say that this change appears to be breaking for Laravel 5.7. Is not the end of the world as easy to revert but thought perhaps it should go in a major point release?

jarektkaczyk commented 5 years ago

thanks, will look into it!

Regards, Jaroslaw Tkaczyk

SOFTonSOFA :: development with pleasure from Krakow, in Singapore

On Wed, 22 May 2019 at 14:46, coachops notifications@github.com wrote:

Hi, @jarektkaczyk https://github.com/jarektkaczyk thanks for the great package. Just to say that this change appears to be breaking for Laravel 5.7. Is not the end of the world as easy to revert but thought perhaps it should go in a major point release?

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/jarektkaczyk/eloquence-base/pull/13?email_source=notifications&email_token=ABU3TMTKZW72KEHELQTFFGDPWTT5FA5CNFSM4HADHOW2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGODV6CGKA#issuecomment-494674728, or mute the thread https://github.com/notifications/unsubscribe-auth/ABU3TMRHD56J4YM5UA36APDPWTT5FANCNFSM4HADHOWQ .