[ARVADOS] updated: b99a8116f6c09ad0eb6442e271e7b2eb8c9caa91

git at public.curoverse.com git at public.curoverse.com
Tue Apr 8 01:58:24 EDT 2014


Summary of changes:
 .../assets/stylesheets/bootstrap-modal.css.scss    |  228 --------------------
 .../workbench/app/views/application/index.html.erb |    4 +-
 .../app/views/layouts/application.html.erb         |    1 +
 .../app/views/users/_setup_popup.html.erb          |  138 +++++++------
 .../workbench/app/views/users/_show_admin.html.erb |    6 +-
 apps/workbench/app/views/users/setup.js.erb        |    2 +-
 apps/workbench/app/views/users/setup_popup.js.erb  |    2 +-
 apps/workbench/test/integration_helper.rb          |    5 +-
 8 files changed, 85 insertions(+), 301 deletions(-)
 delete mode 100644 apps/workbench/app/assets/stylesheets/bootstrap-modal.css.scss

       via  b99a8116f6c09ad0eb6442e271e7b2eb8c9caa91 (commit)
       via  d983b07af43ffb43e7384eb29f0f2572091562b6 (commit)
       via  f5c3cc744f43b1ca9c52d69de381d9b78a2f183a (commit)
       via  de1ab039ce31f8565dae54f8c7c1786230ce3d77 (commit)
       via  dfd5b53fdec053ba4423e25e9b6e0ef0e31b7b5c (commit)
       via  4f4a7b5cd651f17cdb0a1eb0179be2ba89efe1c4 (commit)
       via  3fd0f2b1ee83ef0db86a1c1a24cfdc0ec153422c (commit)
       via  810ff7b787384c129c57cf0fecc034fec1e9b162 (commit)
       via  5dd1c07e56d32ae4c569ceffdbd4549bceb92de4 (commit)
      from  d0c88c9fbcee53fd74ec2afa965fe60a7ae2aa87 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.


commit b99a8116f6c09ad0eb6442e271e7b2eb8c9caa91
Author: Tom Clegg <tom at curoverse.com>
Date:   Tue Apr 8 01:55:17 2014 -0400

    Use bootstrap/theme style defaults for user setup modal and form.

diff --git a/apps/workbench/app/assets/stylesheets/bootstrap-modal.css.scss b/apps/workbench/app/assets/stylesheets/bootstrap-modal.css.scss
deleted file mode 100644
index 6eeb0c9..0000000
--- a/apps/workbench/app/assets/stylesheets/bootstrap-modal.css.scss
+++ /dev/null
@@ -1,29 +0,0 @@
-// Place all the styles related to the bootstrap modal here.
-
-.modal {
-  left: 50%;
-  bottom: auto;
-  right: auto;
-  padding: 0;
-  width: 400px;
-  margin-left: -250px;
-  background-color: #ffffff;
-  border: 2px solid #999999;
-  border-radius: 6px;
-  box-shadow: 0 3px 9px rgba(0, 0, 0, 0.5);
-  background-clip: padding-box;
-}
-
-.modal.fade.in {
-  top: 10%;
-}
-
-.modal-backdrop,
-.modal-backdrop.fade.in{
-  opacity: 0.7;
-  background: #fff;
-}
-
-#user-setup-modal-window{
-  overflow: hidden;
-}
diff --git a/apps/workbench/app/views/layouts/application.html.erb b/apps/workbench/app/views/layouts/application.html.erb
index 63cf67c..724fa9b 100644
--- a/apps/workbench/app/views/layouts/application.html.erb
+++ b/apps/workbench/app/views/layouts/application.html.erb
@@ -230,6 +230,7 @@
         </div>
   </div>
 
+  <%= yield :footer_html %>
   <%= piwik_tracking_tag %>
   <%= javascript_tag do %>
   <%= yield :footer_js %>
diff --git a/apps/workbench/app/views/users/_setup_popup.html.erb b/apps/workbench/app/views/users/_setup_popup.html.erb
index 784ab6e..c075ab5 100644
--- a/apps/workbench/app/views/users/_setup_popup.html.erb
+++ b/apps/workbench/app/views/users/_setup_popup.html.erb
@@ -1,79 +1,72 @@
-<%= form_tag setup_user_path, {id: 'setup_form', name: 'setup_form', method: 'get', 
-                    class: 'form-search', remote: true} do %>
+<div class="modal-dialog">
+  <div class="modal-content">
 
-  <div class="modal-header">
-    <button type="button" class="close" onClick="reset_form()" data-dismiss="modal" aria-hidden="true">×</button>
-    <h3 class="modal-title">Setup User</h4>
-  </div
+    <%= form_tag setup_user_path, {id: 'setup_form', name: 'setup_form', method: 'get',
+        class: 'form-search', remote: true} do %>
 
-  <div class="modal-body">
-    <% if @object%>
-      <% uuid = @object.uuid %>
-      <% email = @object.email %>
-    <% end %>
-    <% disable_email = uuid != nil %>
-    <% identity_url_prefix = @current_selections[:identity_url_prefix] %>
-    <% disable_url_prefix = identity_url_prefix != nil %>
-    <% selected_repo = @current_selections[:repo_name] %>
-    <% selected_vm = @current_selections[:vm_uuid] %>
+    <div class="modal-header">
+      <button type="button" class="close" onClick="reset_form()" data-dismiss="modal" aria-hidden="true">×</button>
+      <h4 class="modal-title">Setup User</h4>
+    </div>
+
+    <div class="modal-body">
+      <% if @object%>
+        <% uuid = @object.uuid %>
+        <% email = @object.email %>
+      <% end %>
+      <% disable_email = uuid != nil %>
+      <% identity_url_prefix = @current_selections[:identity_url_prefix] %>
+      <% disable_url_prefix = identity_url_prefix != nil %>
+      <% selected_repo = @current_selections[:repo_name] %>
+      <% selected_vm = @current_selections[:vm_uuid] %>
 
       <input id="user_uuid" maxlength="250" name="user_uuid" type="hidden" value="<%=uuid%>">
-      <div>
-        <table><tbody><div class="form-group">
-          <tr>
-            <% if disable_email %>
-              <td> Email </td>
-              <td> <input id="email" maxlength="250" name="email" type="text" value="<%=email%>" 
-                    disabled=true > </td>
-            <% else %>
-              <td> Email </td>
-              <td> <input id="email" maxlength="250" name="email" type="text" > </td>
-            <% end %>
-          </tr>
-          <tr>
-            <% if disable_url_prefix %>
-              <td> Identity URL Prefix &nbsp </td>
-              <td> <input id="openid_prefix" maxlength="250" name="openid_prefix" type="text" 
-                    value="<%=identity_url_prefix%>" disabled=true > </td>
-            <% else %>
-              <td> Openid Prefix </td>
-              <td> <input id="openid_prefix" maxlength="250" name="openid_prefix" type="text" 
-                    value="<%= Rails.configuration.default_openid_prefix %>"> </td>
-            <% end %>
-          </tr>
-          <tr>
-            <td> Repository Name </td>
-            <td> <input id="repo_name" maxlength="250" name="repo_name" type="text" value="<%=selected_repo%>">
-          </tr>
-          <tr>
-            <td> Virtual Machine </td>
-            <td>
-              <select name="vm_uuid">
-                <% if selected_vm %>
-                  <option value=""> Choose One: </option>
-                <% else %>
-                  <option value="" selected> Choose One: </option>
-                <% end %>
-                <% @vms.each do |vm| %>
-                  <% if selected_vm == vm.uuid %>
-                    <option value=<%=vm.uuid%> selected> <%=vm.hostname%> </option>
-                  <% else %> 
-                    <option value=<%=vm.uuid%> > <%=vm.hostname%> </option>
-                  <% end %>
-                <% end %>
-              </select>
-            </td>
-          </tr>
-        </div></tbody></table>
+      <div class="form-group">
+	<label for="email">Email</label>
+        <% if disable_email %>
+        <input class="form-control" id="email" maxlength="250" name="email" type="text" value="<%=email%>" disabled>
+        <% else %>
+        <input class="form-control" id="email" maxlength="250" name="email" type="text">
+        <% end %>
       </div>
-  </div>
+      <div class="form-group">
+        <label for="openid_prefix">Identity URL Prefix</label>
+        <% if disable_url_prefix %>
+        <input class="form-control" id="openid_prefix" maxlength="250" name="openid_prefix" type="text"
+               value="<%=identity_url_prefix%>" disabled=true>
+        <% else %>
+        <input class="form-control" id="openid_prefix" maxlength="250" name="openid_prefix" type="text"
+               value="<%= Rails.configuration.default_openid_prefix %>">
+        <% end %>
+      </div>
+      <div class="form-group">
+        <label for="repo_name">Repository Name</label>
+        <input class="form-control" id="repo_name" maxlength="250" name="repo_name" type="text" value="<%=selected_repo%>">
+      </div>
+      <div class="form-group">
+        <label for="vm_uuid">Virtual Machine</label>
+        <select class="form-control" name="vm_uuid">
+          <option value="" <%= 'selected' unless selected_vm %>>
+	    Choose One:
+	  </option>
+          <% @vms.each do |vm| %>
+            <option value="<%=vm.uuid%>"
+		    <%= 'selected' if selected_vm == vm.uuid %>>
+	      <%= vm.hostname %>
+	    </option>
+          <% end %>
+        </select>
+      </div>
+    </div>
 
-  <div class="modal-footer">
-    <button type="submit" id="register" class="btn btn-primary" autofocus>Submit</button>
-    <button class="btn btn-default" onClick="reset_form()" data-dismiss="modal" aria-hidden="true">Cancel</button>
-  </div>
+    <div class="modal-footer">
+      <button type="submit" id="register" class="btn btn-primary" autofocus>Submit</button>
+      <button class="btn btn-default" onClick="reset_form()" data-dismiss="modal" aria-hidden="true">Cancel</button>
+    </div>
 
-<% end %>
+    <% end #form %>
+  </div>
+</div>
 
 <script>
   var $input = $('input:text'),
diff --git a/apps/workbench/app/views/users/_show_admin.html.erb b/apps/workbench/app/views/users/_show_admin.html.erb
index 9c803c9..e2f5fdf 100644
--- a/apps/workbench/app/views/users/_show_admin.html.erb
+++ b/apps/workbench/app/views/users/_show_admin.html.erb
@@ -10,7 +10,6 @@ account.</p>
 
 <blockquote>
 <%= link_to "Setup #{@object.full_name}", setup_popup_user_url(id: @object.uuid),  {class: 'btn btn-primary', :remote => true, 'data-toggle' =>  "modal", 'data-target' => '#user-setup-modal-window'}  %>
-<div id="user-setup-modal-window" class="modal fade" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true"></div>
 </blockquote>
 
 <p>As an admin, you can deactivate and reset this user. This will remove all repository/VM permissions for the user. If you "setup" the user again, the user will have to sign the user agreement again.</p>
@@ -19,3 +18,6 @@ account.</p>
 <%= button_to "Deactivate #{@object.full_name}", unsetup_user_url(id: @object.uuid), class: 'btn btn-primary', confirm: "Are you sure you want to deactivate #{@object.full_name}?"%>
 </blockquote>
 
+<% content_for :footer_html do %>
+<div id="user-setup-modal-window" class="modal fade" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true"></div>
+<% end %>

-----------------------------------------------------------------------


hooks/post-receive
-- 




More information about the arvados-commits mailing list