From a653afe140b7a0ddd9a45b05a4e987f528f8b3d4 Mon Sep 17 00:00:00 2001 From: Nick Muerdter Date: Tue, 24 Feb 2015 15:28:12 -0700 Subject: [PATCH] Add registration source to user listing page and also search the field. --- app/assets/javascripts/admin/views/api_users/table_view.js | 5 +++++ app/controllers/api/v1/users_controller.rb | 1 + 2 files changed, 6 insertions(+) diff --git a/app/assets/javascripts/admin/views/api_users/table_view.js b/app/assets/javascripts/admin/views/api_users/table_view.js index 6088e60c..8519058d 100644 --- a/app/assets/javascripts/admin/views/api_users/table_view.js +++ b/app/assets/javascripts/admin/views/api_users/table_view.js @@ -51,6 +51,11 @@ Admin.ApiUsersTableView = Ember.View.extend({ return time; }, }, + { + data: 'registration_source', + title: 'Registration Source', + defaultContent: '-', + }, { data: 'api_key_preview', title: 'API Key', diff --git a/app/controllers/api/v1/users_controller.rb b/app/controllers/api/v1/users_controller.rb index 8a7d9284..cf795ada 100644 --- a/app/controllers/api/v1/users_controller.rb +++ b/app/controllers/api/v1/users_controller.rb @@ -23,6 +23,7 @@ def index { :last_name => /#{params["search"]["value"]}/i }, { :email => /#{params["search"]["value"]}/i }, { :api_key => /#{params["search"]["value"]}/i }, + { :registration_source => /#{params["search"]["value"]}/i }, { :_id => /#{params["search"]["value"]}/i }, ]) end