Mailinglist Archive: yast-commit (1771 mails)

< Previous Next >
[yast-commit] <rest-service> network : vendor settings controller
  • From: Duncan Mac-Vicar P <dmacvicar@xxxxxxx>
  • Date: Fri, 21 Aug 2009 13:39:07 +0200
  • Message-id: <E1MiTqG-0006Xm-K1@xxxxxxxxxxxxxxxx>
ref: refs/heads/network
commit b4408bf84d5a6eb2012975fdbd7dd1254ebd9697
Author: Duncan Mac-Vicar P <dmacvicar@xxxxxxx>
Date: Wed Aug 19 18:11:29 2009 +0200

vendor settings controller
---
.../app/controllers/vendor_settings_controller.rb | 13 +++++++++++++
.../functional/vendor_settings_controller_test.rb | 10 ++++++++++
2 files changed, 23 insertions(+), 0 deletions(-)

diff --git a/webservice/app/controllers/vendor_settings_controller.rb
b/webservice/app/controllers/vendor_settings_controller.rb
new file mode 100644
index 0000000..0fb9b1d
--- /dev/null
+++ b/webservice/app/controllers/vendor_settings_controller.rb
@@ -0,0 +1,13 @@
+require 'vendor_setting'
+
+class VendorSettingsController < ApplicationController
+
+ def index
+ settings = VendorSetting.find(:all)
+ respond_to do |format|
+ format.xml { render :xml => settings.to_xml }
+ format.json { render :json => VendorSetting }
+ end
+ end
+
+end
diff --git a/webservice/test/functional/vendor_settings_controller_test.rb
b/webservice/test/functional/vendor_settings_controller_test.rb
new file mode 100644
index 0000000..20a66ca
--- /dev/null
+++ b/webservice/test/functional/vendor_settings_controller_test.rb
@@ -0,0 +1,10 @@
+
+require File.expand_path(File.dirname(__FILE__) + "/../test_helper")
+
+class VendorSettingsControllerTest < ActionController::TestCase
+
+ def index
+
+ end
+
+end
--
To unsubscribe, e-mail: yast-commit+unsubscribe@xxxxxxxxxxxx
For additional commands, e-mail: yast-commit+help@xxxxxxxxxxxx

< Previous Next >
This Thread
  • No further messages