deltacloud-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From mfoj...@apache.org
Subject git commit: Core: Fixed action link for DELETE action for storage_volumes and storage_snapshots (DTACLOUD-232)
Date Wed, 13 Jun 2012 12:43:34 GMT
Updated Branches:
  refs/heads/master 138adab33 -> e9a17f619


Core: Fixed action link for DELETE action for storage_volumes and storage_snapshots (DTACLOUD-232)


Project: http://git-wip-us.apache.org/repos/asf/deltacloud/repo
Commit: http://git-wip-us.apache.org/repos/asf/deltacloud/commit/e9a17f61
Tree: http://git-wip-us.apache.org/repos/asf/deltacloud/tree/e9a17f61
Diff: http://git-wip-us.apache.org/repos/asf/deltacloud/diff/e9a17f61

Branch: refs/heads/master
Commit: e9a17f619f585f061593cc15332473bafddff2b1
Parents: 138adab
Author: Michal Fojtik <mfojtik@redhat.com>
Authored: Wed Jun 13 14:44:25 2012 +0200
Committer: Michal fojtik <mfojtik@redhat.com>
Committed: Wed Jun 13 14:44:25 2012 +0200

----------------------------------------------------------------------
 server/views/storage_snapshots/show.html.haml |    2 +-
 server/views/storage_volumes/new.html.haml    |   42 ++++++++++---------
 server/views/storage_volumes/show.html.haml   |    2 +-
 3 files changed, 24 insertions(+), 22 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/deltacloud/blob/e9a17f61/server/views/storage_snapshots/show.html.haml
----------------------------------------------------------------------
diff --git a/server/views/storage_snapshots/show.html.haml b/server/views/storage_snapshots/show.html.haml
index 0f378c2..bc76e3c 100644
--- a/server/views/storage_snapshots/show.html.haml
+++ b/server/views/storage_snapshots/show.html.haml
@@ -19,4 +19,4 @@
     %li
       %div{ :'data-role' => 'controlgroup', :'data-type' => "horizontal" }
         - if driver.respond_to?(:destroy_storage_snapshot)
-          =link_to_action "Delete", destroy_storage_snapshot_url(@storage_snapshot.id), :delete
+          =link_to_action "Delete", api_url_for("storage_snapshots/#{@storage_snapshot.id}"),
:delete

http://git-wip-us.apache.org/repos/asf/deltacloud/blob/e9a17f61/server/views/storage_volumes/new.html.haml
----------------------------------------------------------------------
diff --git a/server/views/storage_volumes/new.html.haml b/server/views/storage_volumes/new.html.haml
index ff8a83f..115721f 100644
--- a/server/views/storage_volumes/new.html.haml
+++ b/server/views/storage_volumes/new.html.haml
@@ -1,21 +1,23 @@
-%h1 Create new storage volume
+=header "Create new Storage Volume"
 
-%form{ :action => storage_volumes_url, :method => :post }
-  %p
-    %label
-      Name:
-    %input{ :name => 'name', :size => 30 } (optional)
-  %p
-    %label
-      Snapshot ID:
-    %input{ :name => 'snapshot_id', :size => 30 } (optional)
-  %p
-    %label
-      Capacity (in GB):
-    %input{ :name => "capacity", :size => 3, :value => "1"}
-  %p
-    %label
-      Realm ID:
-    %input{ :name => "realm_id", :size => 10, :value => driver.realms(credentials).first.id}
-  %p
-    %input{ :type => :submit, :name => "commit", :value => "create" }/
+
+%div{ :'data-role' => :content, :'data-theme' => 'c', :class => 'middle-dialog'}
+  %form{ :action => storage_volumes_url, :method => :post }
+    %p
+      %label
+        Name:
+      %input{ :name => 'name', :size => 30 } (optional)
+    %p
+      %label
+        Snapshot ID:
+      %input{ :name => 'snapshot_id', :size => 30 } (optional)
+    %p
+      %label
+        Capacity (in GB):
+      %input{ :name => "capacity", :size => 3, :value => "1"}
+    %p
+      %label
+        Realm ID:
+      %input{ :name => "realm_id", :size => 10, :value => driver.realms(credentials).first.id}
+    %p
+      %input{ :type => :submit, :name => "commit", :value => "create" }/

http://git-wip-us.apache.org/repos/asf/deltacloud/blob/e9a17f61/server/views/storage_volumes/show.html.haml
----------------------------------------------------------------------
diff --git a/server/views/storage_volumes/show.html.haml b/server/views/storage_volumes/show.html.haml
index 31a0833..2ac9944 100644
--- a/server/views/storage_volumes/show.html.haml
+++ b/server/views/storage_volumes/show.html.haml
@@ -37,7 +37,7 @@
         - if ["AVAILABLE", "IN-USE"].include?(@storage_volume.state)
           =link_to_action "Snapshot", api_url_for("storage_snapshots/new?volume_id=#{@storage_volume.id}"),
:get
           - unless @storage_volume.instance_id
-            =link_to_action "Delete", destroy_storage_volume_url(@storage_volume.id), :delete
+            =link_to_action "Delete", api_url_for("storage_volumes/#{@storage_volume.id}"),
:delete
             =link_to_action "Attach", api_url_for("storage_volumes/#{@storage_volume.id}/attach_instance"),
:get
           - if @storage_volume.instance_id
             =link_to_action "Detach", detach_storage_volume_url(@storage_volume.id), :post


Mime
View raw message