Improve errors associated with adding new login providers

Summary:
Ref T1536.

  - When users try to add a one-of provider which already exists, give them a better error (a dialog explaining what's up with reasonable choices).
  - Disable such providers and label why they're disabled on the "new provider" screen.

Test Plan:
{F47012}

{F47013}

Reviewers: chad, btrahan

Reviewed By: chad

CC: aran

Maniphest Tasks: T1536

Differential Revision: https://secure.phabricator.com/D6256
This commit is contained in:
epriestley
2013-06-20 14:13:53 -07:00
parent 619069e234
commit 46a7c61c80
6 changed files with 106 additions and 51 deletions

View File

@@ -14,6 +14,13 @@ final class AphrontDialogView extends AphrontView {
private $headerColor = PhabricatorActionHeaderView::HEADER_DARK_GREY;
private $footers = array();
private $isStandalone;
private $method = 'POST';
public function setMethod($method) {
$this->method = $method;
return $this;
}
public function setIsStandalone($is_standalone) {
$this->isStandalone = $is_standalone;
@@ -159,7 +166,7 @@ final class AphrontDialogView extends AphrontView {
$form_attributes = array(
'action' => $this->submitURI,
'method' => 'post',
'method' => $this->method,
'id' => $this->formID,
);