I have a ono-one relationship in my model. here is my view when
creating a new user.

def create_user (request, person_id):
    manipulator = Users.AddManipulator()
    new_data = request.POST.copy()

    if request.POST:
        new_data = request.POST.copy()

    errors = manipulator.get_validation_errors(new_data)

    if not errors:
        manipulator.do_html2python(new_data)
        manipulator.person = person_id
        new_user = manipulator.save(new_data)

        return HttpResponseRedirect ('../createUser/')
    else:
        errors = new_data = {}

    form = forms.FormWrapper (manipulator, new_data, errors)
    return render_to_response ('templates/create_user.html',
{'form':form})


--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/django-users
-~----------~----~----~----~------~----~------~--~---

Reply via email to