fix(users): Missing primary social provider

Adds the User's provider to the list of connect social accounts, when it
is also a social account.

Fixes: #1032
This commit is contained in:
mleanos
2016-02-28 22:19:15 -08:00
parent 8830cd4331
commit f2e18e24f1
2 changed files with 11 additions and 0 deletions

View File

@@ -26,6 +26,12 @@ a:hover .header-profile-image {
padding-top: 11px !important;
padding-bottom: 11px !important;
}
.user-primary-account {
font-size: 30px;
top: 10px;
right: 10px;
position: absolute;
}
.error-text {
display: none;
}

View File

@@ -1,6 +1,11 @@
<section class="row" ng-controller="SocialAccountsController">
<h3 class="col-md-12 text-center" ng-show="hasConnectedAdditionalSocialAccounts()">Connected social accounts:</h3>
<div class="col-md-12 text-center">
<!-- If the user's provider field (primary) is a social account, show it here -->
<div ng-hide="user.provider === 'local'" class="social-account-container">
<img ng-src="/modules/users/client/img/buttons/{{user.provider}}.png">
<i class="glyphicon glyphicon-check text-success user-primary-account" data-toggle="popover" title="Primary: {{user.provider}}"></i>
</div>
<div ng-repeat="(providerName, providerData) in user.additionalProvidersData" class="social-account-container">
<img ng-src="/modules/users/client/img/buttons/{{providerName}}.png">
<a class="btn btn-danger btn-remove-account" ng-click="removeUserSocialAccount(providerName)">