Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Error Details
- Error 500: Executing action [random] of controller [qotd.QuoteController] caused exception: groovy.lang.MissingMethodException: No signature of method: static qotd.Quote.list() is applicable for argument types: () values: [] Possible solutions: is(java.lang.Object), wait(), wait(long), print(java.lang.Object), with(groovy.lang.Closure), print(java.io.PrintWriter)
- Servlet: grails
- URI: /qotd/grails/quote/random.dispatch
- Exception Message: No signature of method: static qotd.Quote.list() is applicable for argument types: () values: [] Possible solutions: is(java.lang.Object), wait(), wait(long), print(java.lang.Object), with(groovy.lang.Closure), print(java.io.PrintWriter)
- Caused by: No signature of method: static qotd.Quote.list() is applicable for argument types: () values: [] Possible solutions: is(java.lang.Object), wait(), wait(long), print(java.lang.Object), with(groovy.lang.Closure), print(java.io.PrintWriter)
- Class: QuoteController
- At Line: [8]
- Code Snippet:
- Stack Trace
- groovy.lang.MissingMethodException: No signature of method: static qotd.Quote.list() is applicable for argument types: () values: []
- Possible solutions: is(java.lang.Object), wait(), wait(long), print(java.lang.Object), with(groovy.lang.Closure), print(java.io.PrintWriter)
- at qotd.QuoteController$_closure3.doCall(QuoteController.groovy:8)
- at qotd.QuoteController$_closure3.doCall(QuoteController.groovy)
- at java.lang.Thread.run(Thread.java:722)
- /******************************/
- package qotd
- class QuoteController {
- def index = { redirect(action: home) }
- def home = { render("test " + qotd.Quote.class) }
- def random = {
- def allQuotes = Quote.list()
- if (allQuotes.size() > 0)
- {
- def randomId = new Random().next(allQuotes.size())
- randomQuote = allQuotes[randomId]
- }
- [ quote : randomQuote]
- }
- }
Add Comment
Please, Sign In to add comment