Replies: 2 comments 3 replies
-
Do you know that? You formulate a question and an answer comes almost automatically? When I wrote my question "Could I adjust my own Router?", I thought: yes, why not? And now I've simply changed the router class. Sorry for this pointless entry. |
Beta Was this translation helpful? Give feedback.
-
Hi Juan, as it's "a time ago" I have to double check the modifications I made. But as a first intro: the "problem" was this part in routing.py
As you can see while initializing the class the routes are set. And because of that they were "executed". The class now looks like:
In addition I made a change in my views/view_home.py as the classes no longer inherit from page, but from router, like:
Now you have to adjust the main.py as well:
I have to combine this examples in one new project to double check if it's running as expected. But I think that's it. You can now add as many views as you want. Could you please check as well if it's working for you? |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
Question
I have a simple setup with a routing and differernt view files to seperate the content of the views from my main.py.
I want to use session storage to use values in different views.
Unfortunately the content of the view is loaded at startup and it is not updated while switching back and forth.
How can I achieve this? Could I adjust my own Router (and if yes "How?") or is there any other simple way?
Flow:
Code sample
Error message
------------------------------------------------------
Beta Was this translation helpful? Give feedback.
All reactions