You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@deltacloud.apache.org by mf...@redhat.com on 2011/10/27 13:17:27 UTC
[PATCH core 7/8] CIMI: Added HAML for listing collection (index.xml.haml)
From: Michal Fojtik <mf...@redhat.com>
Signed-off-by: Michal fojtik <mf...@redhat.com>
---
.../cimi/machine_configurations/index.xml.haml | 8 ++++++++
server/views/cimi/machine_images/index.xml.haml | 8 ++++++++
server/views/cimi/machines/index.xml.haml | 8 ++++++++
server/views/cimi/volumes/index.xml.haml | 8 ++++++++
4 files changed, 32 insertions(+), 0 deletions(-)
create mode 100644 server/views/cimi/machine_configurations/index.xml.haml
create mode 100644 server/views/cimi/machine_images/index.xml.haml
create mode 100644 server/views/cimi/machines/index.xml.haml
create mode 100644 server/views/cimi/volumes/index.xml.haml
diff --git a/server/views/cimi/machine_configurations/index.xml.haml b/server/views/cimi/machine_configurations/index.xml.haml
new file mode 100644
index 0000000..f3b9b04
--- /dev/null
+++ b/server/views/cimi/machine_configurations/index.xml.haml
@@ -0,0 +1,8 @@
+%MachineConfigurationCollection{ :xmlns => CMWG_NAMESPACE }
+ %uri machineConfiguration
+ - @resources.each do |resource|
+ %machineConfiguration{ :href => resource[:href] }
+ %name Machine Configuration collection
+ %description That is just a test
+ %created 2011-09-12 11:37:28 UTC
+ %operation{ :rel => :add, :href => "/machine_configurations"}
diff --git a/server/views/cimi/machine_images/index.xml.haml b/server/views/cimi/machine_images/index.xml.haml
new file mode 100644
index 0000000..37d0e1e
--- /dev/null
+++ b/server/views/cimi/machine_images/index.xml.haml
@@ -0,0 +1,8 @@
+%MachineImageCollection{ :xmlns => CMWG_NAMESPACE }
+ %uri machineImage
+ - @resources.each do |resource|
+ %machineImage{ :href => resource[:href] }
+ %name Machine Config collection
+ %description The machine config collection
+ %created 2011-09-12 11:37:28 UTC
+ %operation{ :rel => :add, :href => "/machine_images"}
diff --git a/server/views/cimi/machines/index.xml.haml b/server/views/cimi/machines/index.xml.haml
new file mode 100644
index 0000000..d314a7d
--- /dev/null
+++ b/server/views/cimi/machines/index.xml.haml
@@ -0,0 +1,8 @@
+%MachineCollection{ :xmlns => CMWG_NAMESPACE }
+ %uri machine
+ - @resources.each do |resource|
+ %machine{ :href => resource[:href] }/
+ %name Machine collection
+ %description The machine collection
+ %created 2011-09-12 11:37:28 UTC
+ %operation{ :rel => :add, :href => "/machine_images"}/
diff --git a/server/views/cimi/volumes/index.xml.haml b/server/views/cimi/volumes/index.xml.haml
new file mode 100644
index 0000000..3706e36
--- /dev/null
+++ b/server/views/cimi/volumes/index.xml.haml
@@ -0,0 +1,8 @@
+%VolumeCollection{ :xmlns => CMWG_NAMESPACE }
+ %uri volume
+ - @resources.each do |resource|
+ %volume{ :href => resource[:href] }
+ %name Volume collection
+ %description The volume collection
+ %created 2011-09-12 11:37:28 UTC
+ %operation{ :rel => :add, :href => "/volumes"}
--
1.7.4.4