-
Notifications
You must be signed in to change notification settings - Fork 44
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
Column sort for index crashes on fields containing multiple values #631
Comments
If you can do a small demo project and push it to github that would be very helpful. Judging from the stacktrace however, this does not look like it happens in the Fields Plugin, but I might be wrong |
Sorry I have taken so long to get back to this. I have a workaround that I don't particularly like because I feel it's a bit of a hack; but it both explains the problem and (kind of) solves it. If you look at the f:table template here: you will see the following code snippet:
The problem is that columns that are one-to-many associations cause the My workaround therefore looks at the but after some testing, discovered that according to So my working code replacing the above is:
I'm not sure of "the correct solution". We can say that |
I'm having a hard time describing this, but basically in the index view on any table in my project, if I click on the column heading to sort fields, things work fine, except when I click on a column whose elements are many-to-many; that generates a crash.
I'm at the very earliest stages in the application, just prototyping the data model. The views, controllers and services are the stock ones generated by "grails generate-all". The image attached shows the index page; clicking on either of the two rightmost columns causes the code to crash; all other columns sort just fine.
The crash looks like this:
The code in the controller that provokes this is the "respond" below at line 14:
I'm at the very earliest stages in the application, just prototyping the data model. The views, controllers and services are the stock ones generated by "grails generate-all". The image attached shows the index page; clicking on either of the two rightmost columns causes the code to crash; all other columns sort just fine.
gradle.properties:
grailsVersion=3.3.9
gormVersion=6.1.11.RELEASE
gradleWrapperVersion=3.5
The text was updated successfully, but these errors were encountered: