71f110e02f4d02bc96906b8e18b7555e9177117e
[unfold.git] / portal / templates / fed4fire / fed4fire_home-view.html
1 {% extends "layout_base.html" %}
2 {% load portal_filters %}
3
4 {% block content %}
5 <!-- <div class="row">
6 {% widget '_widget-news.html' %}
7 </div> -->
8 {% if username %}
9 <div class="container dashboard">
10         <div class="row">
11                 <div class="col-md-3">
12                         <h3>
13                                 EXPERIMENT
14                         </h3>
15                         <div>
16                                 <a href="#"><img src="{{ STATIC_URL }}img/icon_slices.png" alt="" /></a>
17                         </div>
18                         <div>
19                                 <button id="slicerequestbtn" type="button" style="width: 150px;" class="btn btn-default"><span class="glyphicon glyphicon-plus"></span> Request slice</button>
20                         </div>
21                         <div>   
22                                 <div id="home-slice-list"><img src="{{ STATIC_URL }}img/loading.gif" alt="Loading Slices" /></div>
23                         </div>
24                          <div>
25                         <button id="jfed" type="button" class="btn btn-default" title="Some tools do their own slice creation and management.">
26                                 <span class="glyphicon glyphicon-globe"></span>Experiment now</button>
27                          </div>
28                         <div>
29                                 <ul><li>
30                                         <a class="button2" href='http://jfed.iminds.be/releases/r1389/webstart/experimenter/jfed-experimenter.jnlp'
31                                         title="Click here to start your experiment with jFed" 
32                                         onclick="return  launchApplication('http://jfed.iminds.be/releases/r1389/webstart/experimenter/jfed-experimenter.jnlp');">jFed</a>
33                                 </li></ul>
34                         </div>
35                 </div>
36                 <div class="col-md-3">
37                         <h3>MANAGEMENT</h3>
38                         <div>
39                                 <a href="/portal/institution"><img src="{{ STATIC_URL }}img/icon_authority_color.png" alt="" /></a>
40                         </div>
41                         <div>
42                                 <button id="validaterequestbtn" type="button" class="btn btn-default"><span class="glyphicon glyphicon-ok"></span> Validate Requests</button>
43                         </div>
44                 </div>
45                 <div class="col-md-3">
46                         <h3>
47                                 SUPPORT
48                         </h3>
49                         <div>
50                                 <a href="http://doc.fed4fire.eu/support.html"><img src="{{ STATIC_URL }}img/icon_support.png" alt="" /></a>
51                         </div>
52                         <div>
53                                 <button id="ticketbtn" type="button" style="width: 150px;" class="btn btn-default"><span class="glyphicon glyphicon-envelope"></span> Contact</button>
54                         </div>
55                         <p></p>
56                         <div>
57                         <button id="statbtn" type="button" style="width: 150px;" class="btn btn-default"><span class="glyphicon glyphicon-stats"></span>Testbeds' status</button>
58                         </div>
59                 </div>
60                 
61                 <div class="col-md-3">
62                         <h3>
63                                 ACCOUNT
64                         </h3>
65                         <div>
66                                 <a href="/portal/account/"><img src="{{ STATIC_URL }}img/icon_user_color.png" alt="" /></a>
67                         </div>
68                         <div>
69                                 <button id="logoutbtn" type="button" style="width: 150px;" class="btn btn-default" data-username="{{ username }}"><span class="glyphicon glyphicon-off"></span> Logout</button>
70                         </div>
71                         <div>
72                                 {% if person.last_name %}
73                                         {{person.first_name}} {{person.last_name}}<br />
74                                 {% endif %}
75                         <span class="label">Email:</span> <a href='/portal/account/'>{{person.email}}</a>
76                 </div>
77                 </div>
78         </div>
79 </div>
80 {% else %}
81 <div class="container-fluid home">
82         <div class="">
83                 <div class="col-sm-2"></div>
84                 <div class="col-sm-4 slogan">
85                         <h2>
86                                 Fed4FIRE Portal
87                         </h2>
88                         <h3>
89                                 Your easy access to Future Internet Research and Experimentation testbeds belonging to the Fed4FIRE federation.
90                         </h3>
91                         <h3>
92                                  <a href='http://doc.fed4fire.eu'>Want to learn more?</a>
93                         </h3>
94                 </div>
95                 <div class="col-sm-4 col-sm-offset-1" style="width:400px; top:16px; float:left;">
96                         <div class="row">
97                                 {% widget '_widget-login-user.html' %}
98                         </div>
99                 </div>
100                 <div class="col-sm-1"></div>
101         </div>
102 </div>
103 {% endif %}
104
105
106 <script type="text/javascript">
107         $(document).ready(function() {
108                 $('a.home-tab').click(function() {
109                         $('ul.nav-tabs li').removeClass('active');
110                         $(this).parent().addClass('active');
111                         $('div.home-panel').hide();
112                         $('div#'+$(this).data('panel')).show();
113                 });
114                 $('button#validaterequestbtn').click(function() {
115                         window.location="/portal/validate/";
116                 });
117                 $('button#ticketbtn').click(function() {
118                         window.location="/portal/contact/";
119                 });
120                 $('button#statbtn').click(function() {
121                 window.location="https://flsmonitor.fed4fire.eu";
122                 });
123                 $('button#signupbtn').click(function() {
124                         window.location="/portal/register/";
125                 });
126                 $('button#slicerequestbtn').click(function() {
127                         window.location="/portal/slice_request/";
128                 });
129 /*-------
130 List of slices has been moved in 
131 portal/templates/base.html
132 This should go into session
133 --------*/
134 });
135 </script>
136 <script type="text/javascript" src="{{STATIC_URL}}js/fed4fire_dtjava_orig.js"></script>
137 <script>
138         function launchApplication(jnlpfile) {
139         dtjava.launch(
140                 { url : jnlpfile },
141             {
142                 javafx : '2.2+',
143                 toolkit: 'swing'
144                 },
145                 {}
146         );
147         return false;
148      }
149 </script>
150 {% endblock %}