Статистика для дашборда #7

This commit is contained in:
2026-04-28 21:31:22 +03:00
parent 967a024d0c
commit c87d56bb49
18 changed files with 210 additions and 167 deletions
+4
View File
@@ -6,6 +6,7 @@
-export([generate_id/0]).
-export([list_users/0]).
-export([block/1, unblock/1]).
-export([count_users/0]).
%% Создание пользователя
create(Email, Password) ->
@@ -122,6 +123,9 @@ unblock(Id) ->
Error -> Error
end.
count_users() ->
mnesia:table_info(user, size).
%% Внутренние функции
generate_id() ->
base64:encode(crypto:strong_rand_bytes(16), #{mode => urlsafe, padding => false}).