b7a583b2c4
* Feature: Ability to switch between multiple accounts * Fix rubocop * Fix assigned inboxes * fix auth json * Add account switcher in UI * fix ordering on administrate * Add switch accounts to sidebar * add account id * Fix schema.rb timestamp * Revert "add account id" This reverts commit 27570f50ef584cb9a5f69454f43f630b318c8807. * Add a check for account Co-authored-by: Pranav Raj Sreepuram <pranavrajs@gmail.com>
22 lines
712 B
Ruby
22 lines
712 B
Ruby
json.data do
|
|
json.id resource.id
|
|
json.provider resource.provider
|
|
json.uid resource.uid
|
|
json.name resource.name
|
|
json.nickname resource.nickname
|
|
json.email resource.email
|
|
json.account_id resource.active_account_user.account_id
|
|
json.pubsub_token resource.pubsub_token
|
|
json.role resource.active_account_user.role
|
|
json.inviter_id resource.active_account_user.inviter_id
|
|
json.confirmed resource.confirmed?
|
|
json.avatar_url resource.avatar_url
|
|
json.accounts do
|
|
json.array! resource.account_users do |account_user|
|
|
json.id account_user.account_id
|
|
json.name account_user.account.name
|
|
json.active_at account_user.active_at
|
|
json.role account_user.role
|
|
end
|
|
end
|
|
end
|