mirror of
https://github.com/knadh/listmonk.git
synced 2024-11-10 09:02:36 +08:00
Sory users by created_at
always.
This commit is contained in:
parent
83d3af3527
commit
3cbf67b943
1 changed files with 4 additions and 2 deletions
|
@ -1082,7 +1082,8 @@ UPDATE users SET
|
||||||
WHEN $9 > 0 THEN (SELECT id FROM roles WHERE id = $9 AND type = 'list')
|
WHEN $9 > 0 THEN (SELECT id FROM roles WHERE id = $9 AND type = 'list')
|
||||||
ELSE list_role_id END
|
ELSE list_role_id END
|
||||||
),
|
),
|
||||||
status=(CASE WHEN $10 != '' THEN $10::user_status ELSE status END)
|
status=(CASE WHEN $10 != '' THEN $10::user_status ELSE status END),
|
||||||
|
updated_at=NOW()
|
||||||
WHERE id=$1 AND (SELECT canEdit FROM u) = TRUE;
|
WHERE id=$1 AND (SELECT canEdit FROM u) = TRUE;
|
||||||
|
|
||||||
-- name: delete-users
|
-- name: delete-users
|
||||||
|
@ -1135,7 +1136,8 @@ FROM users
|
||||||
WHEN $3::TEXT != '' THEN email = $3
|
WHEN $3::TEXT != '' THEN email = $3
|
||||||
ELSE TRUE
|
ELSE TRUE
|
||||||
END
|
END
|
||||||
);
|
)
|
||||||
|
ORDER BY users.created_at;
|
||||||
|
|
||||||
|
|
||||||
-- name: get-api-tokens
|
-- name: get-api-tokens
|
||||||
|
|
Loading…
Reference in a new issue