1
0
mirror of https://github.com/LaCasemate/fab-manager.git synced 2024-12-02 13:24:20 +01:00
fab-manager/app/views/api/auth_providers/active.json.jbuilder
2019-03-25 14:57:48 +01:00

13 lines
426 B
Ruby

json.partial! 'api/auth_providers/auth_provider', auth_provider: @provider
json.mapping @provider.sso_fields
json.link_to_sso_profile @provider.link_to_sso_profile
if @provider.providable_type == DatabaseProvider.name
json.link_to_sso_connect '/#'
else
json.link_to_sso_connect "/users/auth/#{@provider.strategy_name}"
end
if @provider.providable_type == OAuth2Provider.name
json.domain @provider.providable.domain
end