0
0
mirror of https://github.com/go-gitea/gitea.git synced 2024-12-01 07:51:58 +01:00
gitea/routers
Sybren aa45777c92
Allow custom "created" timestamps in user creation API (#22549)
Allow back-dating user creation via the `adminCreateUser` API operation.
`CreateUserOption` now has an optional field `created_at`, which can
contain a datetime-formatted string. If this field is present, the
user's `created_unix` database field will be updated to its value.

This is important for Blender's migration of users from Phabricator to
Gitea. There are many users, and the creation timestamp of their account
can give us some indication as to how long someone's been part of the
community.

The back-dating is done in a separate query that just updates the user's
`created_unix` field. This was the easiest and cleanest way I could
find, as in the initial `INSERT` query the field always is set to "now".
2023-02-16 10:32:01 -06:00
..
api Allow custom "created" timestamps in user creation API (#22549) 2023-02-16 10:32:01 -06:00
common Add context cache as a request level cache (#22294) 2023-02-15 21:37:34 +08:00
install Add context cache as a request level cache (#22294) 2023-02-15 21:37:34 +08:00
private Add context cache as a request level cache (#22294) 2023-02-15 21:37:34 +08:00
utils
web fix incorrect role labels for migrated issues and comments (#22914) 2023-02-15 12:29:13 -05:00
init.go