Commit Graph

23 Commits

Author SHA1 Message Date
efbb895ebe Cleaner ui for admin, repo settings, and user settings page () () 2017-03-15 23:39:38 +01:00
01d957677f Oauth2 consumer ()
* initial stuff for oauth2 login, fails on:
* login button on the signIn page to start the OAuth2 flow and a callback for each provider
Only GitHub is implemented for now
* show login button only when the OAuth2 consumer is configured (and activated)
* create macaron group for oauth2 urls
* prevent net/http in modules (other then oauth2)
* use a new data sessions oauth2 folder for storing the oauth2 session data
* add missing 2FA when this is enabled on the user
* add password option for OAuth2 user , for use with git over http and login to the GUI
* add tip for registering a GitHub OAuth application
* at startup of Gitea register all configured providers and also on adding/deleting of new providers
* custom handling of errors in oauth2 request init + show better tip
* add ExternalLoginUser model and migration script to add it to database
* link a external account to an existing account (still need to handle wrong login and signup) and remove if user is removed
* remove the linked external account from the user his settings
* if user is unknown we allow him to register a new account or link it to some existing account
* sign up with button on signin page (als change OAuth2Provider structure so we can store basic stuff about providers)

* from gorilla/sessions docs:
"Important Note: If you aren't using gorilla/mux, you need to wrap your handlers with context.ClearHandler as or else you will leak memory!"
(we're using gorilla/sessions for storing oauth2 sessions)

* use updated goth lib that now supports getting the OAuth2 user if the AccessToken is still valid instead of re-authenticating (prevent flooding the OAuth2 provider)
2017-02-22 08:14:37 +01:00
d67b278a0d feat: Able to disable non-admin to create new organization () 2017-02-14 20:16:00 +08:00
c0904f1942 Restrict creating organisations by user ()
* restrict creating organizations based on right on user

* revert bindata.go

* reverse vendor lib

* revert goimports change

* set AllowCreateOrganization default value to true

* revert locale

* added default value for AllowCreateOrganization

* fix typo in migration-comment

* fix comment

* add coments in migration
2016-12-31 10:33:30 +08:00
1f2e173a74 Refactor User.Id to User.ID 2016-07-24 01:08:22 +08:00
c083d76567 able to prohibit user login 2016-07-16 10:22:16 +08:00
59c965a5ec admin able to edit organization max repo creation 2015-12-11 19:24:57 -05:00
2a0bb1fa90 Limit repo creation 2015-12-10 12:37:53 -05:00
da2585c11e Indent all templates with tabs
This commit improves templates readability, since all of them use consistent
indent with all template command blocks indented too.

1. Indents both HTML containers such as <div>, <p> and Go HTML template blocks
   such as {{if}} {{with}}

2. Cleans all trailing white-space

3. Adds trailing last line-break to each file
2015-12-08 00:57:46 +01:00
6f0a41b8b2 Allow local import only for admin users 2015-11-03 18:40:52 -05:00
83e747bfda and and new admin edit user UI 2015-09-13 11:07:21 -04:00
6c7a93a3ac fix 2015-09-01 05:44:36 -04:00
f3aab5dbe3 Add full name field to admin's user edit page (fixes ) 2015-04-28 11:59:05 -04:00
d0e34c57cc Fix for deleting user when gogs instalation is on http://hostname/gogs 2015-03-13 20:17:20 +01:00
32dcaefafa fox 2014-11-17 14:53:41 -05:00
49193bebd2 UI: Confirmation box 2014-09-28 01:38:25 -04:00
7ba9257a7f Add suburl support 2014-09-19 20:11:34 -04:00
0055cbd365 Allow Gogs to run from a suburl behind a reverse proxy. e.g. http://mydomain.com/gogs/
Conflicts:
	modules/setting/setting.go

Conflicts:
	templates/repo/release/list.tmpl
	templates/user/dashboard/dashboard.tmpl

Conflicts:
	routers/repo/setting.go
2014-09-18 20:50:48 +02:00
8829174574 Finish new admin users pages 2014-08-29 15:32:52 +08:00
57f6ec672a bug fixed 2014-08-08 13:51:02 +08:00
5a97cc69ed Make possible for administrators to change user's password (fix proposal for ) 2014-07-18 05:30:57 +03:00
3ad20773a2 fix typos in users' editing template. 2014-06-30 20:12:55 +01:00
9924e65ca1 In progress of name template name constant 2014-06-22 13:14:03 -04:00