>From a view, I call def assign_person_to_role which calls 
find_people_to_add_roles_and_relationships.  

User selects a person in the grid find_people_to_add_roles_and_relationships. 
Then I want to pass that value to assign_person_to_role 


def find_people_to_add_roles_and_relationships(): # this is the child 
controller that gets called.
    grid = SQLFORM.grid(db.auth_user, links=[dict(header='Add person to 
role',  body=lambda row: A('Assign person to role',_class="btn btn-success 
btn-mini", _href=URL('assign_person_to_role', args=row.id, 
vars=request.vars)))], links_placement = 'left') # THIS IS WRONG, JUST 
LEAVING IT HERE FOR ILLUSTRATION: "_href=URL('assign_person_to_role'"
    return dict(grid=grid)

def assign_person_to_role(): # This is the parent controller 
    find_people_to_add_roles_and_relationships, vars=request.vars # here is 
where it is called
    specific_person = db.auth_user(request.args(0))  or 
redirect(URL('find_people_to_add_roles_and_relationships')) # here is the 
value that I want passed. 
    return locals() 

I don't know how to exit the grid without a "redirect".  Don't want a 
redirect, just want an "exit" or "escape" so control drops down to the next 
line in assign_person_to_role 

thanks Massimo,

Alex

-- 
Resources:
- http://web2py.com
- http://web2py.com/book (Documentation)
- http://github.com/web2py/web2py (Source code)
- https://code.google.com/p/web2py/issues/list (Report Issues)
--- 
You received this message because you are subscribed to the Google Groups 
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to