1
0
mirror of https://github.com/e107inc/e107.git synced 2025-01-17 20:58:30 +01:00

social: Add New Provider includes all known scopes by default

Because it's probably quite common that the "email" scope be used by
default

See: https://github.com/e107inc/e107/issues/4115#issuecomment-622561908
This commit is contained in:
Nick Liu 2020-05-22 18:34:58 -05:00
parent 2c733cd3f1
commit c03945cd63
No known key found for this signature in database
GPG Key ID: 1167C5F9C9897637

View File

@ -662,13 +662,14 @@ class social_ui extends e_admin_ui
foreach ($fieldInfo as $fieldSlash => $description)
{
$field = str_replace("/", "][", $fieldSlash);
$placeholder = self::getPlaceholderFor($provider_name, $fieldSlash);
$frm_options = [
'size' => 'xxlarge',
'placeholder' => self::getPlaceholderFor($provider_name, $fieldSlash),
'placeholder' => $placeholder,
];
$text .= "<tr><td>".$this->getLabel($fieldSlash)."</td><td>";
$text .= $frm->text("social_login[$provider_name][$field]", $slcm->getProviderConfig($provider_name, $fieldSlash), 256, $frm_options);
$text .= $frm->text("social_login[$provider_name][$field]", $placeholder, 256, $frm_options);
$text .= "<div class='smalltext field-help'>$description</div>";
$text .= "</td></tr>";
}