Replies: 1 comment
-
|
This isn't a correct relationship. The code expectations is working correctly as what's being defined in Model and Nova Resource. However, What's in the schema doesn't tally what's in rhe Model |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Laravel Version:
10.10
Nova Version:
4.0
PHP Version:
8.1
Database Driver & Version:
MySQL 8.0
Operating System and Version:
macOS
Browser Type and Version:
Chrome 101
Description:
I'm encountering an issue with polymorphic relationships in Laravel Nova where the
itemable_modelcolumn is not found in thecardablestable, leading to a SQL error. The exact error message is:Detailed Steps to Reproduce the Issue on a Fresh Nova Installation:
Create Migrations:
cardstable:cardablestable:Define Models:
Define Nova Resource:
Run Migrations:
Expected Outcome:
The polymorphic relationships should be set up correctly, and data should be inserted into the
cardablestable without any SQL errors.Actual Outcome:
I encountered the following error:
Beta Was this translation helpful? Give feedback.
All reactions