Open DeadEye0112 opened 4 years ago
Hi @DeadEye0112, Thanks for your feedback. It definitely looks like a bug.
As a workaround could you edit your criteria0Grade
and criteria0Comment
fields, like this:
criteria0Grade: {
type: DataTypes.INTEGER,
field: 'criteria_0_grade' // define the name of your table column
},
criteria0Comment: {
type: DataTypes.STRING,
field: 'criteria_0_comment' // define the name of your table column
},
Hope it will help.
I confirm that the workaround works, I hope that the fix will not disappear on update.
Thanks for your answer!
Expected behavior
Expected to be able to click on my table in Forest Admin and see the contents of the table.
Actual behavior
Having the message "Oops, something went wrong".
Failure Logs
Context
I have a table named
ratings
having several columns named like this:criteria_0_grade
,criteria_1_grade
, etc... For an unknown reason, Lumber seems to map these columns tocriteria0_grade
triggering acolumn ratings.criteria0_grade does not exist
error. The problem seems to exist only with the two columns namecriteria_0_*
.In
models/ratings.js
, only the columns with a 0 does not have afield
field:Thanks for you help!