Lab as a Service 2.0
[laas.git] / src / templates / workflow / viewport-element.html
1 {% extends "layout.html" %}
2 {% load bootstrap3 %}
3 {% load staticfiles %}
4
5 {% block basecontent %}
6
7     <div id="wrapper">
8         <!-- Page Content -->
9         <div id="page-wrapper">
10
11             {% block content %}
12
13             {% endblock content %}
14         </div>
15         <!-- /#page-wrapper -->
16     </div>
17     {% block vport_comm %}
18              <script type="text/javascript">
19                 var step_count = {{ step_number|default:0 }};
20                 var active_step = {{ active_step|default:0 }};
21                 var render_correct = {{ render_correct|default:"false" }};
22                 var title = "{{ step_title|default:"Workflow Step" }}";
23                 var description = "{{ description|default:"Contact the admins, because this field should have something else filled in here" }}";
24                 if(render_correct){
25                     parent.update_context();
26                 }
27                 parent.update_description(title, description);
28             </script>
29
30     {% endblock vport_comm %}
31     {% block validate_step %}
32         <script>
33
34             function step_is_valid()
35             {
36                 valid = confirm("Is this form valid?");
37                 if( valid )
38                 {
39                     return true;
40                 }
41                 else{
42                     return false;
43                 }
44             }
45
46             function onError()
47             {
48                 alert("Error: something!");
49             }
50         </script>
51
52     {% endblock validate_step %}
53
54     <script>
55     function step_on_leave() {
56     {% block onleave %}
57         alert("override onleave");
58     {% endblock %}
59     }
60     </script>
61
62     <div class="messages">
63         {% block element_messages %}
64         {% bootstrap_messages %}
65         {% endblock %}
66     </div>
67
68     <!-- /#wrapper -->
69 {% endblock basecontent %}