Arve Knudsen
47f13abf7a
Backend: Migrate to using non-global configuration ( #31856 )
...
Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com>
2021-03-10 12:41:29 +01:00
Hugo Häggmark
3d41267fc4
Chore: Moves common and response into separate packages ( #30298 )
...
* Chore: moves common and response into separate packages
* Chore: moves common and response into separate packages
* Update pkg/api/utils/common.go
Co-authored-by: Arve Knudsen <arve.knudsen@gmail.com>
* Chore: changes after PR comments
* Chore: move wrap to routing package
* Chore: move functions in common to response package
* Chore: move functions in common to response package
* Chore: formats imports
Co-authored-by: Arve Knudsen <arve.knudsen@gmail.com>
2021-01-15 14:43:20 +01:00
Arve Knudsen
294770f411
Chore: Handle wrapped errors ( #29223 )
...
* Chore: Handle wrapped errors
Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com>
Co-authored-by: Emil Tullstedt <emil.tullstedt@grafana.com>
2020-11-19 13:34:28 +01:00
kay delaney
b2dcf06b60
Backend: Adds route for well-known change password URL ( #28788 )
...
* Backend: Adds route for well-known change password URL
* Include 'dashboard/new' in backend routes
* Move index route handler registration out of "not logged in views" section
Co-authored-by: Arve Knudsen <arve.knudsen@gmail.com>
2020-11-10 22:36:35 +00:00
Arve Knudsen
a5d9196a53
Chore/fix lint issues ( #27704 )
...
* Chore: Fix linting issues
Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com>
2020-09-22 16:22:19 +02:00
Carl Bergquist
3fdd2648b1
Chore: Avoid aliasing importing models in api package ( #22492 )
2020-03-04 12:57:20 +01:00
twendt
ff6a082e23
Auth: Azure AD OAuth ( #20030 )
...
* Implement Azure AD oauth
* Use go-jose and cleanup
* Update go-jose in go.mod
* cleanup
* Add unit tests
* Fix scopes
* Add documentation page
* Improve documentation
* Convert extract_role into function.
* Do not use upn and replace unique_name with preferred_username
* Configure login button
* Use official microsoft icon and color from branding guideline.
* Add Azure AD config section in sample.ini.
2020-02-13 12:12:25 +03:00
Alexander Zobnin
8505d90768
Admin: New Admin User page ( #20498 )
...
* admin: user page to react WIP
* admin user page: basic view
* admin user page: refactor, extract orgs and permissions components
* admin user: change sessions actions styles
* admin user: add disable button
* user admin: add change grafana admin action
* user admin: able to change org role and remove org
* user admin: confirm force logout
* user admin: change org button style
* user admin: add confirm modals for critical actions
* user admin: lock down ldap user info
* user admin: align with latest design changes
* user admin: add LDAP sync
* admin user: confirm button
* user admin: add to org modal
* user admin: fix ConfirmButton story
* admin user: handle grafana admin change
* ConfirmButton: make styled component
* ConfirmButton: completely styled component
* User Admin: permissions section refactor
* admin user: refactor (orgs and sessions)
* ConfirmButton: able to set confirm variant
* admin user: inline org removal
* admin user: show ldap sync info only for ldap users
* admin user: edit profile
* ConfirmButton: some fixes after review
* Chore: fix storybook build
* admin user: rename handlers
* admin user: remove LdapUserPage import from routes
* Chore: fix ConfirmButton tests
* Chore: fix user api endpoint tests
* Chore: update failed test snapshots
* admin user: redux actions WIP
* admin user: use new ConfirmModal component for user profile
* admin user: use new ConfirmModal component for sessions
* admin user: use lockMessage
* ConfirmButton: use primary button as default
* admin user: fix ActionButton color
* UI: use Icon component for Modal
* UI: refactor ConfirmModal after Modal changes
* UI: add link button variant
* UI: able to use custom ConfirmButton
* Chore: fix type errors after ConfirmButton refactor
* Chore: revert Graph component changes (works with TS 3.7)
* Chore: use Forms.Button instead of ActionButton
* admin user: align items
* admin user: align add to org modal
* UI: organization picker component
* admin user: use org picker for AddToOrgModal
* admin user: org actions
* admin user: connect sessions actions
* admin user: updateUserPermissions action
* admin user: enable delete user action
* admin user: sync ldap user
* Chore: refactor, remove unused code
* Chore: refactor, move api calls to actions
* admin user: set user password action
* Chore: refactor, remove unused components
* admin user: set input focus on edit
* admin user: pass user into debug LDAP mapping
* UserAdminPage: Ux changes
* UserAdminPage: align buttons to the left
* UserAdminPage: align delete user button
* UserAdminPage: swap add to org modal buttons
* UserAdminPage: set password field to empty when editing
* UserAdminPage: fix tests
* Updated button border
* Chore: fix ConfirmButton after changes introduced in #21092
Co-authored-by: Torkel Ödegaard <torkel@grafana.com>
2020-01-13 17:10:19 +01:00
Arve Knudsen
35e0e078b7
pkg/util: Check errors ( #19832 )
...
* pkg/util: Check errors
* pkg/services: DRY up code
2019-10-23 10:40:12 +02:00
gotjosh
4181b30b75
API: Add createdAt
and updatedAt
to api/users/lookup ( #19496 )
...
* API: Add `createdAt` and `updatedAt` to api/users/lookup
In the past, we have added both `updatedAt` (#19004 ) and `createdAt` (#19475 ) to /api/users/:id
Turns out, api/users/lookup uses the same DTO for both. This fixes the serialization of both `createdAt` and `updatedAt`for this endpoint.
Also, adds a test to ensure no further regressions.
* Updated API documentation
2019-09-30 20:54:09 +01:00
Alexander Zobnin
ccf11fb7a2
SAML: add auth provider label ( #18197 )
2019-07-19 17:13:29 +03:00
Alexander Zobnin
5f0a7f43c3
Users: show badges for each auth provider ( #17869 )
...
* Users: show badges for each auth provider
* Chore: don't use functions in angular bindings
* Users: minor style changes to labels
* Chore: convert auth labels on the backed side, deduplicate frontend code
* Users: use authLabels everywhere instead of authModule
* User: fix edit user page style
* Users: minor fixes after review
2019-07-10 12:06:51 +03:00
Alexander Zobnin
dad894f1cc
API: get list of users with additional auth info ( #17305 )
...
* batch disable users
* batch revoke users tokens
* split batch disable user and revoke token
* API: get users with auth info and isExternal flag
* fix tests for batch disable users
* Users: refactor /api/users/search endpoint
* Users: use alias for "user" table
* Chore: add BatchDisableUsers() to the bus
* Users: order user list by id explicitly
* Users: return AuthModule from /api/users/:id endpoint
* Users: do not return unused fields
* Users: fix SearchUsers method after last changes
* User: return auth module as array for future purposes
* User: tests for SearchUsers()
* User: return only latest auth module in SearchUsers()
* User: fix JOIN, get only most recent auth module
2019-06-25 18:29:07 +03:00
Oleg Gaidarenko
9b7f9dd9be
LDAP: consistently name the LDAP entities ( #17203 )
2019-05-22 15:30:03 +03:00
Hugo Häggmark
dafcfd70a7
Fixed bug with getting teams for user
2019-02-22 14:07:18 +01:00
supercharlesliu
215242128b
Fix param
2018-11-19 17:09:45 +08:00
supercharlesliu
fb5c59c611
Add GET /api/users/:id/teams for orgAdmin
2018-11-19 17:08:10 +08:00
Torkel Ödegaard
8c9939df72
Adds backend hooks service so extensions can modify index data
2018-10-12 11:26:42 +02:00
Marcus Efraimsson
beddfdd86b
add api route for retrieving teams of signed in user
2018-08-08 10:26:05 +02:00
Julian Kornberger
0a415c50d0
Make golint happier
2018-03-22 22:38:44 +01:00
Julian Kornberger
7aab6a8887
Make golint happier
2018-03-22 12:40:21 +01:00
Dan Cech
c0ecdee375
rename Context to ReqContext
2018-03-07 11:54:50 -05:00
Dan Cech
338655dd37
move Context and session out of middleware
2018-03-06 18:16:49 -05:00
Torkel Ödegaard
011c582ebb
minor user avatar stuff
2017-08-18 14:49:04 +02:00
Torkel Ödegaard
9fb60c2fc8
Merge branch 'develop' into panel-title-menu-ux
2017-08-02 09:56:08 +02:00
Denis Doria
5aac2d2078
Include user Id on the lookup api ( #8698 )
...
Implements feature request #8682
2017-06-25 14:23:03 +02:00
Daniel Lee
233cd7af4a
WIP: add user group search
2017-06-12 15:49:09 +02:00
Daniel Lee
9efb6e76e9
users: adds search and pagination ( #7753 )
...
ref #7469 . Follow up change that adds proper paging with 50 results
per page as well as a search box to search by name, login or email.
2017-03-07 16:03:54 +01:00
Daniel Lee
96a3ed0ac3
docs: new /api/users/search route
...
ref #7469 . Description of new route that
adds paging for the users list.
2017-02-21 16:09:15 +01:00
Daniel Lee
193d468ed3
admin: adds paging to global user list
...
Currently there is a limit of 1000 users in the global
user list. This change introduces paging so that an
admin can see all users and not just the first 1000.
Adds a new route to the api - /api/users/search that
returns a list of users and a total count. It takes
two parameters perpage and page that enable paging.
Fixes #7469
2017-02-13 12:59:36 +01:00
Pavlos Daoglou
3e741315b4
[3743] Adds support for user search based on login or email ( #7334 )
...
* [3743] Adds support for user search based on login or email
* Use query parameter instead
* Use macaron Query() instead
2017-01-31 06:25:55 +01:00
Torkel Ödegaard
8fc6e4cfb0
fix(auth proxy, ldap): fixed so users cannot change password when ldap or auth proxy is enabled, fixes #2495 , do not allow user to change email or username depending on what property auth proxy is using, fixes #6903
2016-12-14 22:19:25 +01:00
bergquist
96e8ecfa7b
feat(cli): adds command to reset admin password
...
closes #5479
2016-12-09 15:25:02 +01:00
Torkel Ödegaard
fb57bf77da
ux(getting started): progress on getting started panel and persited help flag states, #6466
2016-11-09 10:41:39 +01:00
Mukesh
4038b4d17e
Set active org through admin api ( #5179 )
2016-05-26 06:51:23 +02:00
Torkel Ödegaard
370589d6c0
fix(org switch): fixed issue with switching orgs, fixes #4614
2016-04-09 13:27:06 -04:00
Torkel Ödegaard
3354365177
Api handler refactoring using the wrap and response func/type, fixed small issue in influxdb 0.9 response handling
2015-05-20 14:59:38 +02:00
Torkel Ödegaard
a8aab0cb2b
Worked on user administration page, a grafana server admin can now add and edit organization roles for any user, #2014
2015-05-19 11:47:14 +02:00
Torkel Ödegaard
fbc6bb2112
More refactoring of user http api, trying to reuse handlers for sign in user and admin operations
2015-05-18 19:06:19 +02:00
Torkel Ödegaard
5270c4bc74
refactorin api code for user routes, preparation for admin improvements, #2014
2015-05-18 17:52:23 +02:00
Torkel Ödegaard
04ca85fe89
Moved dashboard theme option from the dashboard to a persisted user setting, #1458
2015-02-28 14:30:08 +01:00
Torkel Ödegaard
26e4809e2e
Big Backend Refatoring: Renamed Account -> Org
2015-02-23 20:07:49 +01:00
Torkel Ödegaard
47c6c6e1b7
Added change password feature, Closes #1455
2015-02-19 16:09:49 +01:00
Torkel Ödegaard
10820f31c2
Changed go package path
2015-02-05 10:37:13 +01:00
Torkel Ödegaard
4ea5d80099
Various fixes to data access
2015-01-20 15:23:14 +01:00
Torkel Ödegaard
90925273a0
User / Account model split, User and account now seperate entities, collaborators are now AccountUsers
2015-01-19 18:01:04 +01:00