incubator-deltacloud-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Michal Fojtik <mfoj...@redhat.com>
Subject Re: [PATCH core 6/6] Added XML representation of IP address
Date Fri, 27 Aug 2010 10:59:00 GMT
On 26/08/10 16:43 -0700, David Lutterkort wrote:
>On Wed, 2010-08-25 at 16:42 +0200, mfojtik@redhat.com wrote:
>> ---
>>  server/views/ip_addresses/index.xml.haml |    4 ++++
>>  server/views/ip_addresses/show.xml.haml  |   10 ++++++++++
>>  2 files changed, 14 insertions(+), 0 deletions(-)
>>  create mode 100644 server/views/ip_addresses/index.xml.haml
>>  create mode 100644 server/views/ip_addresses/show.xml.haml
>>
>> diff --git a/server/views/ip_addresses/show.xml.haml b/server/views/ip_addresses/show.xml.haml
>> new file mode 100644
>> index 0000000..e49493f
>> --- /dev/null
>> +++ b/server/views/ip_addresses/show.xml.haml
>> @@ -0,0 +1,10 @@
>> +- unless defined?(partial)
>> +  !!! XML
>> +%ip_address{ :href => ip_address_url(@ip_address.id), :id => @ip_address.id,
:type => "#{@ip_address.type}" }
>> +  %address<
>> +    =@ip_address.address
>> +  %state<
>> +    =@ip_address.state
>> +  %realm{:href => realm_url(@ip_address.realm_id), :id => @ip_address.realm_id}
>> +  %actions
>> +    %link{ :rel => "destroy", :method => "delete", :href => destroy_ip_address_url(@ip_address.id)}
>
>The link should only be included if the driver supports destroying IP
>addresses.

Agree.

  -- Michal

-- 
--------------------------------------------------------
Michal Fojtik, mfojtik@redhat.com, +420 532 294 4307
Ruby / Ruby On Rails Developer
Deltacloud API: http://deltacloud.org
--------------------------------------------------------

Mime
View raw message