Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
N
nexpie-grafana-theme
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Registry
Registry
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Kornkitt Poolsup
nexpie-grafana-theme
Commits
44a2a648
Unverified
Commit
44a2a648
authored
Sep 16, 2019
by
Dominik Prokop
Committed by
GitHub
Sep 16, 2019
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Login: fix login page failing when navigating from reset password views (#19124)
parent
e968a2aa
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
6 additions
and
5 deletions
+6
-5
pkg/api/frontendsettings.go
+3
-0
pkg/api/login.go
+0
-4
public/app/core/components/Login/LoginCtrl.tsx
+3
-1
No files found.
pkg/api/frontendsettings.go
View file @
44a2a648
...
@@ -179,6 +179,9 @@ func (hs *HTTPServer) getFrontendSettingsMap(c *m.ReqContext) (map[string]interf
...
@@ -179,6 +179,9 @@ func (hs *HTTPServer) getFrontendSettingsMap(c *m.ReqContext) (map[string]interf
"exploreEnabled"
:
setting
.
ExploreEnabled
,
"exploreEnabled"
:
setting
.
ExploreEnabled
,
"googleAnalyticsId"
:
setting
.
GoogleAnalyticsId
,
"googleAnalyticsId"
:
setting
.
GoogleAnalyticsId
,
"disableLoginForm"
:
setting
.
DisableLoginForm
,
"disableLoginForm"
:
setting
.
DisableLoginForm
,
"disableUserSignUp"
:
!
setting
.
AllowUserSignUp
,
"loginHint"
:
setting
.
LoginHint
,
"passwordHint"
:
setting
.
PasswordHint
,
"externalUserMngInfo"
:
setting
.
ExternalUserMngInfo
,
"externalUserMngInfo"
:
setting
.
ExternalUserMngInfo
,
"externalUserMngLinkUrl"
:
setting
.
ExternalUserMngLinkUrl
,
"externalUserMngLinkUrl"
:
setting
.
ExternalUserMngLinkUrl
,
"externalUserMngLinkName"
:
setting
.
ExternalUserMngLinkName
,
"externalUserMngLinkName"
:
setting
.
ExternalUserMngLinkName
,
...
...
pkg/api/login.go
View file @
44a2a648
...
@@ -40,10 +40,6 @@ func (hs *HTTPServer) LoginView(c *models.ReqContext) {
...
@@ -40,10 +40,6 @@ func (hs *HTTPServer) LoginView(c *models.ReqContext) {
}
}
viewData
.
Settings
[
"oauth"
]
=
enabledOAuths
viewData
.
Settings
[
"oauth"
]
=
enabledOAuths
viewData
.
Settings
[
"disableUserSignUp"
]
=
!
setting
.
AllowUserSignUp
viewData
.
Settings
[
"loginHint"
]
=
setting
.
LoginHint
viewData
.
Settings
[
"passwordHint"
]
=
setting
.
PasswordHint
viewData
.
Settings
[
"disableLoginForm"
]
=
setting
.
DisableLoginForm
viewData
.
Settings
[
"samlEnabled"
]
=
setting
.
IsEnterprise
&&
hs
.
Cfg
.
SAMLEnabled
viewData
.
Settings
[
"samlEnabled"
]
=
setting
.
IsEnterprise
&&
hs
.
Cfg
.
SAMLEnabled
if
loginError
,
ok
:=
tryGetEncryptedCookie
(
c
,
LoginErrorCookieName
);
ok
{
if
loginError
,
ok
:=
tryGetEncryptedCookie
(
c
,
LoginErrorCookieName
);
ok
{
...
...
public/app/core/components/Login/LoginCtrl.tsx
View file @
44a2a648
...
@@ -9,7 +9,9 @@ import { getBackendSrv } from '@grafana/runtime';
...
@@ -9,7 +9,9 @@ import { getBackendSrv } from '@grafana/runtime';
import
{
hot
}
from
'react-hot-loader'
;
import
{
hot
}
from
'react-hot-loader'
;
import
appEvents
from
'app/core/app_events'
;
import
appEvents
from
'app/core/app_events'
;
const
isOauthEnabled
=
()
=>
Object
.
keys
(
config
.
oauth
).
length
>
0
;
const
isOauthEnabled
=
()
=>
{
return
!!
config
.
oauth
&&
Object
.
keys
(
config
.
oauth
).
length
>
0
;
};
export
interface
FormModel
{
export
interface
FormModel
{
user
:
string
;
user
:
string
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment