Python Forum
Display module variables and edit through webpage
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Display module variables and edit through webpage
#1
I am using Flask to implement a web application. My main application has different "modules" I can activate or deactivate by changing the boolean value for that specific module in a dedicated python file that lies in the server directory.

Now I want to show the user on the front-end the different fields with their flags in dropdown menus like that: Module1 : dropdown menu(True, False) And then the user can choose to change the status by setting it to False for example and clicking "save". This click would then set this flag to False in my config file.

Is that possible? And how would I go about implementing it? Right now I don't really care about user access rights. In this scenario I just have one user that wants to change the configuration of the app through the web browser.

Thank you
Reply
#2
What are your modules? In the simplest case you can just do something like this:
if myvar1:
   import module1
if myvar2:
   import module2 
Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
  webpage input module rudolphyaber 2 2,188 Feb-26-2019, 12:13 AM
Last Post: Larz60+
  display multiple sensors on webpage python flask jinja pascale 6 5,261 Jan-29-2019, 10:10 AM
Last Post: pascale
  flask requests display data from api on webpage with javacript pascale 0 2,775 Oct-25-2018, 08:30 PM
Last Post: pascale

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020