mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-09-20 00:30:49 +00:00
Merge pull request #65556 from azat/dashboard-user-from-url
Parse user from URL for dashboard.html (useful for sharing)
This commit is contained in:
commit
2b3f1ef3aa
@ -506,6 +506,14 @@ let user = 'default';
|
||||
let password = '';
|
||||
let add_http_cors_header = (location.protocol != 'file:');
|
||||
|
||||
const current_url = new URL(window.location);
|
||||
/// Substitute user name if it's specified in the query string
|
||||
const user_from_url = current_url.searchParams.get('user');
|
||||
if (user_from_url) {
|
||||
user = user_from_url;
|
||||
}
|
||||
|
||||
|
||||
const errorCodeMessageMap = {
|
||||
516: 'Error authenticating with database. Please check your connection params and try again.'
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user