2013-01-01 23:09:29 +01:00
|
|
|
<?php
|
|
|
|
|
|
|
|
final class PhabricatorGoogleConfigOptions
|
|
|
|
extends PhabricatorApplicationConfigOptions {
|
|
|
|
|
|
|
|
public function getName() {
|
|
|
|
return pht("Integration with Google");
|
|
|
|
}
|
|
|
|
|
|
|
|
public function getDescription() {
|
|
|
|
return pht("Google authentication and integration options.");
|
|
|
|
}
|
|
|
|
|
|
|
|
public function getOptions() {
|
|
|
|
return array(
|
|
|
|
$this->newOption('google.auth-enabled', 'bool', false)
|
2013-01-09 17:14:26 +01:00
|
|
|
->setBoolOptions(
|
2013-01-01 23:09:29 +01:00
|
|
|
array(
|
|
|
|
pht("Enable Google Authentication"),
|
2013-01-07 22:50:03 +01:00
|
|
|
pht("Disable Google Authentication"),
|
2013-01-01 23:09:29 +01:00
|
|
|
))
|
|
|
|
->setDescription(
|
|
|
|
pht(
|
|
|
|
'Allow users to login to Phabricator using Google credentials.')),
|
|
|
|
$this->newOption('google.registration-enabled', 'bool', true)
|
2013-01-09 17:14:26 +01:00
|
|
|
->setBoolOptions(
|
2013-01-01 23:09:29 +01:00
|
|
|
array(
|
|
|
|
pht("Enable Google Registration"),
|
2013-01-07 22:50:03 +01:00
|
|
|
pht("Disable Google Registration"),
|
2013-01-01 23:09:29 +01:00
|
|
|
))
|
|
|
|
->setDescription(
|
|
|
|
pht(
|
|
|
|
'Allow users to create new Phabricator accounts using Google '.
|
|
|
|
'credentials.')),
|
|
|
|
$this->newOption('google.auth-permanent', 'bool', false)
|
2013-01-09 17:14:26 +01:00
|
|
|
->setBoolOptions(
|
2013-01-01 23:09:29 +01:00
|
|
|
array(
|
|
|
|
pht("Permanently Bind Google Accounts"),
|
2013-01-07 22:50:03 +01:00
|
|
|
pht("Allow Google Account Unlinking"),
|
2013-01-01 23:09:29 +01:00
|
|
|
))
|
|
|
|
->setDescription(
|
|
|
|
pht(
|
|
|
|
'Are Phabricator accounts permanently bound to Google '.
|
|
|
|
'accounts?')),
|
|
|
|
$this->newOption('google.application-id', 'string', null)
|
|
|
|
->setDescription(
|
|
|
|
pht(
|
|
|
|
'Google "Client ID" to use for Google API access.')),
|
|
|
|
$this->newOption('google.application-secret', 'string', null)
|
2013-01-16 19:52:09 +01:00
|
|
|
->setMasked(true)
|
2013-01-01 23:09:29 +01:00
|
|
|
->setDescription(
|
|
|
|
pht(
|
|
|
|
'Google "Secret" to use for Google API access.')),
|
|
|
|
);
|
|
|
|
}
|
|
|
|
|
|
|
|
}
|