Mailinglist Archive: yast-commit (883 mails)

< Previous Next >
[yast-commit] <rest-service> master : Drop check_permissions resource, unneeded
  • From: Klaus Kämpf <kkaempf@xxxxxxx>
  • Date: Tue, 7 Jul 2009 13:57:49 +0200
  • Message-id: <E1MO9J2-0000Ng-61@xxxxxxxxxxxxxxxx>
ref: refs/heads/master
commit f772d28730fb8d70678c2aff54ed5af100cc593f
Author: Klaus Kämpf <kkaempf@xxxxxxx>
Date: Tue Jul 7 13:57:49 2009 +0200

Drop check_permissions resource, unneeded
---
.../controllers/check_permissions_controller.rb | 26 --------------------
webservice/config/routes.rb | 1 -
2 files changed, 0 insertions(+), 27 deletions(-)

diff --git a/webservice/app/controllers/check_permissions_controller.rb
b/webservice/app/controllers/check_permissions_controller.rb
deleted file mode 100644
index 234ccaf..0000000
--- a/webservice/app/controllers/check_permissions_controller.rb
+++ /dev/null
@@ -1,26 +0,0 @@
-class CheckPermissionsController < ApplicationController
-
- before_filter :login_required
-
- def show
- right = "org.opensuse.yast." + params[:id]
- @cmd_ret = Hash.new
- if polkit_check( right, self.current_account.login) == :yes
- @cmd_ret["permission"] = "granted"
- else
- @cmd_ret["permission"] = "denied"
- end
- respond_to do |format|
- format.xml do
- render :xml => @cmd_ret.to_xml
- end
- format.json do
- render :json => @cmd_ret.to_json
- end
- format.html do
- render :xml => @cmd_ret.to_xml #return xml onl
- end
- end
- end
-
-end
diff --git a/webservice/config/routes.rb b/webservice/config/routes.rb
index 47b2a3c..10b8b7f 100644
--- a/webservice/config/routes.rb
+++ b/webservice/config/routes.rb
@@ -3,7 +3,6 @@ ActionController::Routing::Routes.draw do |map|
map.resource :session
map.resources :resources
map.resources :permissions, :requirements => {:id => /.*/}
- map.resource :check_permission
# login uses POST for both
map.login "/login.:format", :controller => 'sessions', :action => 'create'
map.logout "/logout.:format", :controller => 'sessions', :action => 'destroy'
--
To unsubscribe, e-mail: yast-commit+unsubscribe@xxxxxxxxxxxx
For additional commands, e-mail: yast-commit+help@xxxxxxxxxxxx

< Previous Next >
This Thread
  • No further messages