| @@ 79-91 (lines=13) @@ | ||
| 76 | /** |
|
| 77 | * {@inheritdoc}. |
|
| 78 | */ |
|
| 79 | protected function getCodeFields($state = null) |
|
| 80 | { |
|
| 81 | ||
| 82 | $result = array_merge([ |
|
| 83 | 'appid' => $this->clientId, |
|
| 84 | 'redirect_uri' => $this->redirectUrl, |
|
| 85 | 'response_type' => 'code', |
|
| 86 | 'scope' => $this->formatScopes($this->scopes, $this->scopeSeparator), |
|
| 87 | 'state' => $state ?: md5(time()), |
|
| 88 | ], $this->parameters); |
|
| 89 | ||
| 90 | return $result; |
|
| 91 | } |
|
| 92 | ||
| 93 | /** |
|
| 94 | * 获取 access token的路径. |
|
| @@ 79-88 (lines=10) @@ | ||
| 76 | /** |
|
| 77 | * {@inheritdoc}. |
|
| 78 | */ |
|
| 79 | protected function getCodeFields($state = null) |
|
| 80 | { |
|
| 81 | return array_merge([ |
|
| 82 | 'appid' => $this->clientId, |
|
| 83 | 'redirect_uri' => $this->redirectUrl, |
|
| 84 | 'response_type' => 'code', |
|
| 85 | 'scope' => $this->formatScopes($this->scopes, $this->scopeSeparator), |
|
| 86 | 'state' => $state ?: md5(time()), |
|
| 87 | ], $this->parameters); |
|
| 88 | } |
|
| 89 | ||
| 90 | /** |
|
| 91 | * {@inheritdoc}. |
|