Grails parameter passing -
basically using code below debugging. renders null , cannot figure out reason. , way else statement executed @ point. @ first didnt have save method thought might fix issue. may have scope of domains? of have them set session scope: class info { static scope = "session" string name string smokingstatus string[] symptom static constraints = { } }
else{//query did not find patient id def patinfo = new info() patinfo.name = "dennis" patinfo.smokingstatus = "former smoker" patinfo.symptom = ["cough"] patinfo.save() redirect(action:"display", params: [patinfo:patinfo]) //redirect(action:"login") //return login action , } } } def display(){ render params.name }
thanks appreciated.
you assign value of patinfo variable name patinfo in display action must use:
render params.patinfo
by example if use following:
redirect(action:"display", params: [duck:patinfo])
you must use:
render params.duck
Comments
Post a Comment