reworked slice/project forms
authorCiro Scognamiglio <ciro.scognamiglio@cslash.net>
Thu, 16 Apr 2015 16:12:00 +0000 (18:12 +0200)
committerCiro Scognamiglio <ciro.scognamiglio@cslash.net>
Thu, 16 Apr 2015 16:12:00 +0000 (18:12 +0200)
portal/static/css/fed4fire.css
portal/templates/fed4fire/fed4fire_home-view.html
portal/templates/fed4fire/fed4fire_projectrequest_view.html
portal/templates/fed4fire/fed4fire_slicerequest_view.html

index 99e57d4..2d83fcd 100644 (file)
@@ -36,6 +36,11 @@ h4 {
     letter-spacing:0.6pt;
     color:#201E62;
 }
+label {
+    font-weight:normal;
+    font-size:13px;
+    color:#201E62;
+}
 input[type=checkbox] {
   min-width:5px !important;
   margin-left:0 !important;
@@ -752,6 +757,15 @@ div.breadcrumbs {
     color:gray;
     font-size:10pt;
 }
+
+.sublabel {
+    color:gray;
+    font-style:italic;
+    font-weight:normal;
+}
+.tab-pane {
+    padding-top:25px;
+}
 /* Service Directory */
 
 div#appservices div.row {
index f4e6b4f..c278a1d 100644 (file)
@@ -29,7 +29,6 @@
                 <a href="/portal/slice_request"><img src="{{ STATIC_URL }}img/icon_slices_small.png" alt="" /></a>EXPERIMENT
             </h3>
             <div>
-                
                 <span class="glyphicon glyphicon-cog"></span> <a href="/portal/project_request/">Create/Join project</a>
             </div>
             <div class="dashboard-create-slice">
index 45d8a1a..456df96 100644 (file)
@@ -7,7 +7,13 @@
 <link rel="stylesheet" type="text/css" href="{{ STATIC_URL }}css/jquery.ui.combobox.css">
 {% endblock head %}
 {% block content %}
-<br />
+<div class="row">
+    <div class="col-md-12">
+         <div class="breadcrumbs" style="line-height: 3;">
+             Experiment &nbsp;>&nbsp; Create or join a Project
+         </div>
+    </div>
+</div>
 <div class="row">
     <div class="col-md-12">
         <ul class="nav nav-tabs nav-section">
 <div class="container tab-content">
 
     <div class="tab-pane active" id="new"> 
-        <div class="row">
-            <div class="col-md-12">
-                 <h3>Create a new Project</h3>
-            </div>
-        </div>
-    
         
         <div class="row">
-            <div class="col-md-12">
+            <div class="col-sm-6 col-sm-offset-3">
                 <form role="form" method="post" action="/portal/project_request">
                 {% csrf_token %}
-                  <div class="form-group">
-                    <input type="text" name="project_name" value="" style="width:380px;" placeholder="Name" required>
-                  </div>
-                  <div class="form-group">
-                    <select id="org_name" name="authority_name" class="form-control" style="width:380px" value="{{ organization }}" required> 
-                    {% if authorities %}
-                        {% for authority in authorities %}
-                            {% if authority.name %}
-                                <option value="{{ authority.authority_hrn }}" {% if authority.authority_hrn == authority_hrn %}selected{% endif %}>{{authority.name}}</option>
-                            {% else %}
-                                <option value="{{ authority.authority_hrn }}" {% if authority.authority_hrn == authority_hrn %}selected{% endif %}>{{authority.authority_hrn}}</option>
-                            {% endif %}
-                        {% endfor %} 
-                    {% endif %}
-                    </select>
-                  </div>
-                  
+                    <label>
+                        Please insert a name for your project under which you will be able to create slices <br />
+                        <span class="sublabel">
+                         The project name should only contain letters, numbers and the underscore character "_" <br />
+                        </span>
+                    </label>
+                    <div class="form-group">
+                        <input type="text" name="project_name" value="" style="width:100%;" title="The project name should not contain spaces but only letters, numbers and the underscore character" placeholder="Project name" required>
+                    </div>
+                    
+                    <label>
+                        The authority under which your project will be managed <br />
+                        Before you can access your newly created project a manager of this authority should approve the request.
+                    </label>
+                    <div class="form-group">
+                        <select id="org_name" name="authority_name" class="form-control" style="width:100%" value="{{ organization }}" required> 
+                        {% if authorities %}
+                            {% for authority in authorities %}
+                                {% if authority.name %}
+                                    <option value="{{ authority.authority_hrn }}" {% if authority.authority_hrn == authority_hrn %}selected{% endif %}>{{authority.name}}</option>
+                                {% else %}
+                                    <option value="{{ authority.authority_hrn }}" {% if authority.authority_hrn == authority_hrn %}selected{% endif %}>{{authority.authority_hrn}}</option>
+                                {% endif %}
+                            {% endfor %} 
+                        {% endif %}
+                        </select>
+                    </div>
                   
-                  <div class="form-group">
-                    <textarea id="purpose" name="purpose" class="form-control" rows="6" placeholder="Description" style="width:380px" title="Purpose of your project (informative)" required="required"></textarea>
-                  </div>
-                  <button type="submit" class="btn btn-onelab"><span class="glyphicon glyphicon-plus"></span> Send Request</button>
+                    <label>
+                        Please provide a description of the purpose for your project
+                    </label>
+                    <div class="form-group">
+                        <textarea id="purpose" name="purpose" class="form-control" rows="6" placeholder="Project description" style="width:100%" title="Purpose of your project (informative)" required="required"></textarea>
+                    </div>
+                    <button type="submit" class="btn btn-onelab"><span class="glyphicon glyphicon-plus"></span> Send Request</button>
                 </form>
         
             </div>
index 7e9ee0b..21ffb36 100644 (file)
@@ -9,7 +9,7 @@
                         </div>
                </div>
        </div>
-
+       
        {% if errors %}
        <div class="row">
                <div class="col-md-12">
        {% endif %}
        
        <div class="row">
-               <div class="col-md-8 el">
+               <div class="col-md-5 col-md-offset-3">
                        <form role="form" method="post">
                        {% csrf_token %}
-                         <div class="form-group" style="display:none">
-                           <input type="email" class="form-control" id="email" style="width:300px" value="{{ email }}" readonly="readonly">
-                         </div>
                          <div class="form-group">
-                           <input type="text" class="form-control" name="slice_name" id="slice_name" style="width:300px" placeholder="Slice name" value="{{slice_name}}" 
-                               title="Please enter a name for your slice"required="required">
+                            <input type="hidden" id="email" value="{{ email }}" readonly="readonly">
+                            <label>
+                                Please enter a name for your slice <br />
+                                <span class="sublabel">
+                                    The slice name should only contain letters, numbers and the underscore character "_" <br />
+                                </span>
+                            </label>
+                            <input type="text" class="form-control" name="slice_name" id="slice_name" style="width:100%" placeholder="Slice name" value="{{slice_name}}" required="required">
                          </div>
                          <div class="form-group">
-                               <input type="text" class="form-control" id="authority_hrn" name="org_name" style="width:300px" placeholder="Project" 
-                               title="Select a project under which you want to create your slice. Don't have any project yet! Create/Join project from the dashboard." required="required">
+                             <label>
+                                 Select a project under which you want your slice to be created <br />
+                                 If your are not part of any projects you can <a href="/portal/project_request/">join or create one</a>
+                             </label>
+                               <input type="text" class="form-control" id="authority_hrn" name="org_name" style="width:100%" placeholder="Project" 
+                                       title="Select a project under which you want to create your slice. Don't have any project yet! Create/Join project from the dashboard." required="required">
                          </div>
                          <div class="form-group">
-                           <input type="text" class="form-control" name="url" id="url" style="width:300px" placeholder="Experiment URL (if one exists)"
-                               title="Please provide the url of your experiment if you have one." value="{{url}}">
+                             <label>
+                                 Provide an URL for your experiment
+                             </label>
+                             <input type="text" class="form-control" name="url" id="url" style="width:100%" placeholder="Experiment URL (if one exists)"
+                                       title="Please provide the url of your experiment if you have one." value="{{url}}">
                          </div>
                          <div class="form-group">
-                               <textarea id="purpose" name="purpose" class="form-control" rows="6" placeholder="Experiment purpose" style="width:300px" 
-                               title="Purpose of your experiment (informative)" required="required">{{ purpose }}</textarea>
+                             <label>
+                        Please provide a description of the purpose for your experiment
+                   </label>
+                                 <textarea id="purpose" name="purpose" class="form-control" rows="6" placeholder="Experiment description" style="width:100%" 
+                                       title="Purpose of your experiment (informative)" required="required">{{ purpose }}</textarea>
                          </div>
                          <button type="submit" id=submit_pi class="btn btn-onelab"><span class="glyphicon glyphicon-plus"></span> Create slice</button>
                        </form>