-
Notifications
You must be signed in to change notification settings - Fork 295
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
LogicException in Model.php line 2702: Relationship method must return an object of type Illuminate\Database\Eloquent\Relations\Relation #239
Comments
Can you just try using different name for submit btn, something like this: $model = Menu::findOrFail($id);
$form = $formBuilder->create('App\Forms\MenuForm', [
'method' => 'PUT',
'model' => $model,
'url' => route('admin.menus.update', $id)
])->add('Submit', 'submit', [
'attr' => ['class' => 'btn btn-lg btn-success col-xs-12'],
'label' => 'Update'
]); |
@msonowal please let me know if that worked out for you. |
@kristijanhusak first of all thanks. It's working. but I really want to know why it was workin before and now not working I use to add buttons like that, but from now I have to use only Submit if I want to add button right? |
thank you for your reply
|
LogicException in Model.php line 2702:
Relationship method must return an object of type Illuminate\Database\Eloquent\Relations\Relation
but If I remove the last line it works fine i.e.
It is happening with latest updated version, previosuly it was working fine with my same project running version 1.6 but current version is 1.7
The text was updated successfully, but these errors were encountered: