debianmacno-cupsweb
Last change
on this file since 7f1e63c was
7f1e63c,
checked in by Edward Z. Yang <edwardzyang@…>, 16 years ago
|
Make sipbmp3web work on scripts.
Signed-off-by: Edward Z. Yang <edwardzyang@…>
|
-
Property mode set to
100644
|
File size:
885 bytes
|
Line | |
---|
1 | """Main Controller""" |
---|
2 | from sipbmp3web.lib.base import BaseController |
---|
3 | from tg import expose, flash, require, url, request, redirect |
---|
4 | from pylons.i18n import ugettext as _ |
---|
5 | #from tg import redirect, validate |
---|
6 | from sipbmp3web.model import DBSession, metadata |
---|
7 | from sipbmp3web.controllers.error import ErrorController |
---|
8 | from sipbmp3web import model |
---|
9 | from catwalk.tg2 import Catwalk |
---|
10 | from repoze.what import predicates |
---|
11 | from sipbmp3web.controllers.secure import SecureController |
---|
12 | from remctl import remctl |
---|
13 | |
---|
14 | class RootController(BaseController): |
---|
15 | admin = Catwalk(model, DBSession) |
---|
16 | error = ErrorController() |
---|
17 | |
---|
18 | @expose('sipbmp3web.templates.index') |
---|
19 | def index(self): |
---|
20 | out = dict() |
---|
21 | out["volume"] = remctl("zygorthian-space-raiders.mit.edu", command=["v", "get"]).stdout |
---|
22 | return out |
---|
23 | |
---|
24 | @expose('sipbmp3web.templates.about') |
---|
25 | def about(self): |
---|
26 | return dict() |
---|
27 | |
---|
Note: See
TracBrowser
for help on using the repository browser.