casweb/cas.py | 6 ++++++
casweb/templates/index.html | 14 ++++++++++++++
2 files changed, 20 insertions(+)
New commits:
commit b696e86b2066cc151088a0d29dcf0bf62322b4a5
Author: adam stokes <astokes(a)fedoraproject.org>
Date: Tue Feb 2 14:08:18 2010 -0500
- web updates
diff --git a/casweb/cas.py b/casweb/cas.py
index 6dc0da5..25a60f4 100644
--- a/casweb/cas.py
+++ b/casweb/cas.py
@@ -24,6 +24,7 @@ urls = (
'/', 'index',
'/job/(\d+)/(.*)', 'job',
'/jobs', 'jobs',
+ '/job_submit', 'job_submit',
)
# build connection
@@ -50,5 +51,10 @@ class jobs:
allJobs = casDB.getAllJobs()
return render.base(render.jobs(allJobs))
+class job_submit:
+ def POST(self):
+ i = web.input()
+ raise web.seeother('/')
+
app = web.application(urls, globals(), autoreload=False)
application = app.wsgifunc()
diff --git a/casweb/templates/index.html b/casweb/templates/index.html
index e3580f2..33bd838 100644
--- a/casweb/templates/index.html
+++ b/casweb/templates/index.html
@@ -3,6 +3,20 @@ $def with (userdoc)
Welcome to the CAS web frontend. This application gives the ability to view recent jobs,
schedule new jobs, and perform minor maintenance work through the administration panel.
+<h3>Submit Job</h3>
+<form method="post" action="$ctx.homepath/job_submit">
+ <fieldset>
+ <legend>Requirements</legend>
+ <label for="id">Unique ID</label>
+ <input type="text" name="id" size="15" /><br/>
+ <label for="email">Email</label>
+ <input type="text" name="email" size="15" /><br/>
+ <label for="file_url">Location</label>
+ <input type="text" name="file_url" size="50" /><br/>
+ <input type="submit" value="Create Job"/>
+ </fieldset>
+</form>
+
<h3>Documentation</h3>
Latest CAS Documentation is located @ $:userdoc
$# vim:ts=2 sw=2 et