The situation is the following one:


It is a wizard with four forms (in this massimo helped me a time ago):



solicitud -> domicilio1 -> domicilio2 -> domicilo3 -> final

The code is the following one:

def solicitud():
    session.documento = None
    session.vars = None

    form = SQLFORM(db.MatriculasSolicitud, submit_button='Siguiente
>')

    if form.accepts(request.vars, session):
        session.documento =
request.vars.NumeroDocumento
        redirect(URL(r=request, f='domicilio', args=['1']))
    return dict(form=form)

def domicilio():
    if session.documento is None:
        redirect(URL(r=request, c='default', f='index'))

    if not len(request.args) > 0:
        redirect(URL(r=request, c='default', f='index'))

    tipodom = request.args[0]
    boton = 'Siguiente >'
    proximo = 'domicilio'
    if tipodom == '1':
        idtipo = 2
        parametro = '2'
    elif tipodom == '2':
        idtipo = 1
        parametro = '3'
    else:
        idtipo = 4
        boton = 'Aceptar'
        proximo = 'final'
        parametro = ''

    form = SQLFORM(db.DomiciliosSolicitud, submit_button=boton)

    if session.vars:
        form.vars = session.vars

    db.DomiciliosSolicitud.IdMatricula.default = session.documento
    db.DomiciliosSolicitud.IdTipoDomicilio.default = idtipo

    if form.accepts(request.vars, session):
        if idtipo != 4:
            session.vars = form.vars
        else:
            session.vars = None
        redirect(URL(r=request, f=proximo, args=parametro))
    return dict(form=form, tipodom=tipodom)


The domicilio loaded in domicilio1 will appear in the following forms,
being able to be modified in case of being necessary.

This works well with Opera and with IE, but with firefox the following
thing happens:

I fill the first form (solicitud): Ok
After filling the second form, acceptance and it does not go to the
third, but it shows me again the second. If the complete thing again,
now if it go to the third.
The same thing happens with the third one with regard to the quarter.

I repeat, with Opera and with IE it works well.
I it tried with firefox 3.0.x and 3.5 so much in windows as in
freebsd. Mistake is not produced, there are no messages of the
validators. Simply them it is necessary to load two times.

Regards
Jose

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"web2py Web Framework" group.
To post to this group, send email to web2py@googlegroups.com
To unsubscribe from this group, send email to 
web2py+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/web2py?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to