From a2f22fcaa3415b90d01ee04574818ec9595275a0 Mon Sep 17 00:00:00 2001 From: Marc Florisson Date: Fri, 14 Dec 2012 11:47:11 +0100 Subject: add api_key management --- app/controllers/api_keys_controller.rb | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) create mode 100644 app/controllers/api_keys_controller.rb (limited to 'app/controllers/api_keys_controller.rb') diff --git a/app/controllers/api_keys_controller.rb b/app/controllers/api_keys_controller.rb new file mode 100644 index 000000000..fea8f66b3 --- /dev/null +++ b/app/controllers/api_keys_controller.rb @@ -0,0 +1,17 @@ +class ApiKeysController < ChouetteController + defaults :resource_class => Api::V1::ApiKey + + belongs_to :referential + + def create + create! { referential_path(@referential) } + end + def update + update! { referential_path(@referential) } + end + def destroy + destroy! { referential_path(@referential) } + end + +end + -- cgit v1.2.3