Displaying 2 results from an estimated 2 matches for "nic_id".
2009 Oct 06
0
[PATCH server] new host networking wui
...lete(:ip_address)
+ end
+ }
+ params[:bondings].each { |id,b|
+ unless b[:ip_address].nil?
+ # FIXME make this able to be v4 or v6 address
+ b[:ip_addresses] = [IpV4Address.new({ :address => b[:ip_address] })]
+ b.delete(:ip_address)
+ end
+
+ if b[:nic_ids].nil? || b[:nic_ids].size == 0
+ b[:nics] = []
+ else
+ b[:nics] = b[:nic_ids].collect { |n| Nic.find(n) }
+ b.delete(:nic_ids)
+ end
+
+ b[:interface_name] = b[:name] if b[:interface_name].nil? && !b[:name].nil?
+ }
+ params[:bondings].delete(...
2009 May 15
0
[PATCH server] use service layer for Network controller.
...@ip_address.errors.localize_error_messages.to_a }
- end
- end
-
- def edit_ip_address
- @ip_address = IpAddress.find(params[:id])
-
- @parent_type = params[:parent_type]
- @network = @ip_address.network if @ip_address.network_id
- @nic = @ip_address.nic if @ip_address.nic_id
- @bonding = @ip_address.bonding if @ip_address.bonding_id
+ alert = svc_create_ip_address(params[:ip_address])
+ render :json => {:object => "ip_address", :success => true, :alert => alert}
+ end
+ def edit_ip_address
+ svc_modify_ip_address(params[:parent_typ...