aboutsummaryrefslogtreecommitdiffstats
path: root/packages/torouter-web/tui/models
diff options
context:
space:
mode:
authorArturo FilastoĢ€ <hellais@torproject.org>2011-08-11 13:47:41 +0200
committerArturo FilastoĢ€ <hellais@torproject.org>2011-08-11 13:47:41 +0200
commit5f53648315b1ed94f263da7c13d1754073649e9c (patch)
tree351aafc66ddf294874a55bcde67fd30cc84629f2 /packages/torouter-web/tui/models
parent85bbadf931c74ec5bcbad7d3a5403b59b827db50 (diff)
downloadtorouter-5f53648315b1ed94f263da7c13d1754073649e9c.tar.gz
torouter-5f53648315b1ed94f263da7c13d1754073649e9c.zip
Add the base skeleton for the web user interface
Diffstat (limited to 'packages/torouter-web/tui/models')
-rw-r--r--packages/torouter-web/tui/models/router_config.py19
1 files changed, 19 insertions, 0 deletions
diff --git a/packages/torouter-web/tui/models/router_config.py b/packages/torouter-web/tui/models/router_config.py
new file mode 100644
index 0000000..e83f9aa
--- /dev/null
+++ b/packages/torouter-web/tui/models/router_config.py
@@ -0,0 +1,19 @@
+import web
+from config import db
+
+def new_config(conf):
+ db.insert('router_config',
+ essid=conf['essid'],
+ field1=conf['field1'],
+ field2=conf['field2']
+ )
+
+
+def write_config():
+ db.update('router_config',
+ essid=conf['essid'],
+ field1=conf['field1'],
+ field2=conf['field2']
+ )
+
+