Skip to content
This repository
  • 2 commits
  • 4 files changed
  • 0 comments
  • 1 contributor
2  controllers/designer.py
@@ -110,7 +110,7 @@ def build():
110 110
111 111 shutil.rmtree(sourcedir)
112 112
113   - return dict(mess='Your course is being built')
  113 + return dict(mess='Your course is ready',course_url='static/'+coursename+'/index.html' )
114 114 else:
115 115 moddata = {}
116 116
BIN  static/images/spinner10.gif
1  views/designer/build.html
@@ -9,6 +9,7 @@
9 9
10 10 {{ if mess:}}
11 11 <h1>{{=mess}}</h1>
  12 + You can access your course here: <a href="/{{=request.application}}/{{=course_url}}">Here</a>
12 13
13 14 {{ else: }}
14 15 <h4>Module Index</h4>
20 views/designer/index.html
@@ -8,7 +8,7 @@
8 8 <h5>{{=descr}}</h5>
9 9
10 10
11   -<form name="mainform" action="/{{=request.application}}/{{=request.controller}}/build" method="get">
  11 +<form name="mainform" action="/{{=request.application}}/{{=request.controller}}/build" method="get" onsubmit="unhide_img('spinner'); return true;">
12 12 Project Name: <input type="text" value="Short name, no spaces" name="projectname" /> <br/>
13 13 Description: <input type="text" size="100" value="Enter a short description" name="projectdescription" /> <br /> <br />
14 14
@@ -26,9 +26,25 @@
26 26 <input type="submit" value="Submit" />
27 27 </form>
28 28
29   -
  29 +<div style="align: center;">
  30 + <img id="spinner" src="/courselib/static/images/spinner10.gif" style="display: none;">
  31 +</div>
30 32 {{pass}}
31 33
  34 +<script type="text/javascript">
  35 + function unhide_img(id) {
  36 + var i = document.getElementById('spinner');
  37 + i.style.display = "block";
  38 + }
  39 + function show_image(src) {
  40 + var img = document.createElement("img");
  41 + img.src = src;
  42 + spinner = document.getElementById('spinner');
  43 + spinner.appendChild(img);
  44 + alert(img.src);
  45 + }
  46 +</script>
  47 +
32 48 {{block right_sidebar}}
33 49
34 50

No commit comments for this range

Something went wrong with that request. Please try again.