From 68e7ec857be7814f77213577218a50eb6482461d Mon Sep 17 00:00:00 2001 From: Martin Edenhofer Date: Mon, 7 Oct 2013 07:26:24 +0200 Subject: [PATCH] Reset client settings and local storage on switch to user. --- .../app/controllers/_application_controller_table.js.coffee | 2 +- app/assets/javascripts/app/controllers/users.js.coffee | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/app/assets/javascripts/app/controllers/_application_controller_table.js.coffee b/app/assets/javascripts/app/controllers/_application_controller_table.js.coffee index 66b00a909..7e247a58f 100644 --- a/app/assets/javascripts/app/controllers/_application_controller_table.js.coffee +++ b/app/assets/javascripts/app/controllers/_application_controller_table.js.coffee @@ -135,7 +135,7 @@ class App.ControllerTable extends App.Controller record = App[ attribute.relation ].find( object[rowWithoutId] ) object[row.name] = record.name - @log 'error', 'table', 'header', header, 'overview', dataTypesForCols, 'objects', data.objects + @log 'debug', 'table', 'header', header, 'overview', dataTypesForCols, 'objects', data.objects table = App.view('generic/table')( header: header overview: dataTypesForCols diff --git a/app/assets/javascripts/app/controllers/users.js.coffee b/app/assets/javascripts/app/controllers/users.js.coffee index 78ddcccdc..3ea116c47 100644 --- a/app/assets/javascripts/app/controllers/users.js.coffee +++ b/app/assets/javascripts/app/controllers/users.js.coffee @@ -37,6 +37,7 @@ class Index extends App.Controller callback: (e) -> e.preventDefault() user_id = $(e.target).parent().parent().data('id') + App.Auth._logout() window.location = App.Config.get('api_path') + '/sessions/switch/' + user_id } ]