4294521dfc
add scheduled nodes endpoint
2026-05-01 09:59:18 +03:00
e04931ac08
test that todays schedule only returns uncompleted nodes
2026-05-01 09:06:13 +03:00
1b2e44389c
add completed bool to scheduled node
2026-05-01 09:04:18 +03:00
f2840a3eb1
add find by user method in json scheduled node repo
2026-05-01 09:03:52 +03:00
07e34ffd46
add find by user method in plan repo
2026-05-01 09:02:34 +03:00
ec4dca87a6
test that all nodes up until given date are returned
2026-04-28 22:48:25 +03:00
2047cd72e7
test get todays schedule and use case with request
2026-04-28 22:38:43 +03:00
0ea300f4d2
add find by user method for scheduled nodes
2026-04-28 22:37:28 +03:00
a9265abeae
add node to scheduled node
2026-04-27 09:28:43 +03:00
d47a0235d2
add node to scheduled node entity and dto
2026-04-27 09:10:40 +03:00
bfacb5b62c
add today view route and template
2026-04-26 21:24:35 +03:00
8eb0f2366b
remove missed default value
2026-04-26 20:43:27 +03:00
cd40483cd4
remove default values from user constructors
...
Forcing every call site to be explicit about admin status and
password eliminates a class of bugs where an unintended
isAdmin=false or empty passwordHash could silently slip through.
The CreateUserTest case that asserted the isAdmin default is
dropped since the default no longer exists.
2026-04-26 10:46:07 +03:00
13da7c311a
return utc from clock
2026-04-26 10:32:08 +03:00
a65c9259fa
dont cast email to string, use new value method
2026-04-26 10:19:38 +03:00
632085f5b6
inject PasswordHasher into CreateUser and AuthenticateUser
...
Replace direct password_hash and password_verify calls with the
injected PasswordHasher so the bcrypt cost can be substituted out
in tests. Production wiring is handled by the container's autowiring
of BcryptPasswordHasher.
This commit alone breaks the test suite because the existing tests
construct these use cases without the new dependency; the next
commit restores green by introducing FakePasswordHasher.
2026-04-26 09:06:21 +03:00
b1247d2fa1
add PasswordHasher interface with bcrypt implementation
...
Introduce an injectable abstraction over password_hash and
password_verify so callers can be swapped for a fast fake in tests
without paying bcrypt's CPU cost. The bcrypt implementation is a
direct passthrough using PASSWORD_DEFAULT, matching the prior inline
behavior, so existing stored hashes continue to verify.
Wired into the DI container alongside the other auth primitives
(Clock, TokenGenerator). No callers reference it yet, so production
behavior is unchanged.
2026-04-26 09:06:17 +03:00
5a24f5bde4
read user from request in plan controller
2026-04-24 13:32:04 +03:00
5f207f7fcb
add login and register view methods
2026-04-24 13:28:40 +03:00
c9d5ad37b8
add auth controller
2026-04-24 13:28:22 +03:00
6c5833af5e
return user from create user use case
2026-04-24 13:27:15 +03:00
bb4e27a45b
add admin middleware
2026-04-24 13:26:38 +03:00
2666f40c27
add forbidden exception
2026-04-24 13:25:52 +03:00
d549cf914f
add auth middleware
2026-04-24 13:25:36 +03:00
05f4f334e6
add create session use case
2026-04-24 13:24:21 +03:00
de4d577781
add system clock
2026-04-24 13:23:38 +03:00
04712bdd2d
add clock interface
2026-04-24 13:23:30 +03:00
07040851ec
add random token generator
2026-04-24 13:23:12 +03:00
a0bea204b4
add token generator interface
2026-04-24 13:23:05 +03:00
762bbb7fda
add json session repository
2026-04-24 13:22:19 +03:00
503df8be7a
add session repository interface
2026-04-24 13:21:37 +03:00
b37e80147c
add create session dto
2026-04-24 13:21:28 +03:00
6fbdc82589
add session entity
2026-04-24 13:21:20 +03:00
79d9ece2ae
add authenticate user use case
2026-04-24 13:21:02 +03:00
20e4a6ee69
add authenticate user request
2026-04-24 13:20:30 +03:00
271f28936d
add unauthorized exception
2026-04-24 13:20:22 +03:00
ada29ea957
store password hash in json user repo
2026-04-24 13:19:15 +03:00
0f179e53c2
hash password in create user
2026-04-24 13:18:44 +03:00
016e98412b
add password hash to user entity
2026-04-24 13:18:33 +03:00
5093259063
add password hash to create user dto
2026-04-24 13:18:24 +03:00
261319078d
add password to create user request
2026-04-24 13:18:15 +03:00
96ad78425f
reject duplicate email in create user
2026-04-24 13:17:11 +03:00
ac461afcf0
implement find by email in json user repo
2026-04-24 13:16:41 +03:00
ee271e162e
add find by email to user repository
2026-04-24 13:16:11 +03:00
54db92a76c
persist is admin in json user repo
2026-04-24 13:15:24 +03:00
4157710187
pass is admin through create user
2026-04-24 13:14:57 +03:00
0e86af3e81
add is admin to user entity
2026-04-24 13:14:48 +03:00
affa1e7b1b
add is admin to create user dto
2026-04-24 13:14:39 +03:00
b9f7fcf148
add is admin to create user request
2026-04-24 13:14:30 +03:00
e664fead2c
parse json body in plan controller
2026-04-24 10:28:00 +03:00