Skip to content

Instantly share code, notes, and snippets.

@olivermt
Created March 17, 2011 15:27
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save olivermt/874515 to your computer and use it in GitHub Desktop.
Save olivermt/874515 to your computer and use it in GitHub Desktop.
package no.cipr.safari.model
import grails.converters.XML
class SearchController {
def transient modelSearchService
def transient depositionalSearchService
def index = {
def distinct = modelSearchService.listDistinctGrossDepEnv()//works just fine
render distinct as XML
}
def architecturalFlow = {
listGrossDep {
action {
def grossDepMap = this.modelSearchService.listDistinctGrossDepEnv()
[grossDep: grossDepMap]
}
on("success").to "showResult"
}
showResult {
}
}
}
java.lang.NullPointerException: Cannot invoke method listDistinctGrossDepEnv() on null object
at no.cipr.safari.model.SearchController$_closure2_closure3.doCall(SearchController.groovy:31)
at no.cipr.safari.model.SearchController$_closure2_closure3.doCall(SearchController.groovy)
at no.cipr.safari.model.SearchController$_closure2.doCall(SearchController.groovy:30)
at no.cipr.safari.model.SearchController$_closure2.doCall(SearchController.groovy)
at java.lang.Thread.run(Thread.java:637)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment