You should probably store the state in the session, so after the initial
form submission, re-loads can read the values from the session.
Anthony
On Monday, February 16, 2015 at 11:23:07 AM UTC-5, Boris Aramis Aguilar
RodrÃguez wrote:
>
> Hi, currently I'm using LOAD and components on a project. The problem is
> that when using a timeout for auto-reloading the component then the current
> view state is lost, let me explain:
>
> 1. A controller called performance_matrix.py has a method index(); that
> method receives request.vars and depending on received variable x it
> displays a different type of data.
>
> 2. The view performance_matrix/index.html is quite simple, because it has
> just the LOAD inside of it to load the component that displays a matrix
> depending on an x variable.
>
> {{extend 'layout.html'}}
> {{block center}}
> {{=LOAD('performance_matrix','index.load',ajax=True, times = "infinity",
> timeout=1000*60)}}
> {{end}}
>
> 3. The file performance_matrix/index.load contains the view of the
> component, it has a form that when you change values on it it makes a POST
> to the server with the new x variable that changes what the view displays.
>
> 4. The problem is, that when timeout within the load happends, then
> requested variable x is lost so the state of the displayed view gets back
> to default I don't want this behavior; i want the timeout to happend and
> send whatever vars I currently have in the state of the component.
>
> Any help i would appreciate it.
>
> Thanks!
>
--
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.