Mixed commit, user facebook issues

This commit is contained in:
2014-08-11 17:54:43 +02:00
parent 28192f8e39
commit 031e2bedea
19 changed files with 95 additions and 77 deletions
+7 -1
View File
@@ -18,6 +18,12 @@
button.btn.btn-primary data-t="obtain_token.obtain" onclick="Quser.authenticate_user(); return false" = t('user.obtain_token.obtain')
- unless current_user.blank? || ENV['QWAITER_MOBILE_EXPORT']=='yes'
javascript:
Qstorage = window.localStorage;
Qstorage.setItem('auth_token', '#{current_user.authentication_token}');
Qstorage.setItem('user_id', '#{current_user.id}');
window.location = '/index.html';
window.location = (Qstorage.getItem('root_url') || '/index.html') + '?user_id=#{current_user.id}&auth_token=#{current_user.authentication_token}';
// localStorage.setItem('auth_token', '#{current_user.authentication_token}');
// localStorage.setItem('user_id', '#{current_user.id}');
// window.location = $root_url + '?user_id=#{current_user.id}&auth_token=#{current_user.authentication_token}';
// debugger;
// QMobile.signed_in({user_id: '#{current_user.id}', auth_token: '#{current_user.authentication_token}'});