register
other register

Wednesday, January 14, 2009

Put Multiple Objects in the Returning Model in The Controller

In controller, you can put multiple objects in a model and return it. You can also pass on the parameters from the request to the model on returning it. For example:

class JetController {

def test = {
return ['key1': object1, 'key2': object2, 'key3': params.person.id]
}
}

No comments: