Commit graph

232 commits

Author SHA1 Message Date
dDogge
37bbbb6098 Added SignWeeklyReport function and 2 corresponding test, also small change to WeeklyReport.go 2024-03-17 20:33:53 +01:00
Imbus
e03727613d Extremely important formatting 2024-03-17 20:04:29 +01:00
dDogge
8a34fc07fa Weekly_report fixed for real this time 2024-03-17 19:58:44 +01:00
dDogge
b93df693d2 Fixed weekly_report 2024-03-17 19:56:16 +01:00
Imbus
3683552af8 Verbose debug printing in register endpoint 2024-03-17 19:33:13 +01:00
Imbus
9240d5e052 Verbose debug printing in login endpoint 2024-03-17 19:24:13 +01:00
dDogge
3e00a532cf Added handler for GetWeeklyReport 2024-03-17 18:05:54 +01:00
dDogge
a77e57e496 Added GetWeeklyReport function and corresponding test 2024-03-17 17:58:02 +01:00
dDogge
c90d495636 Added new types and changed SQL since apperently sqlite does use autoincrement 2024-03-17 17:47:31 +01:00
Imbus
ec46d29423 Merge branch 'imbs' into dev 2024-03-17 16:56:00 +01:00
Imbus
d6fc0594a9 Splitting backend endpoints into smaller bits 2024-03-17 16:55:40 +01:00
Imbus
1be3ee89c2 Merge branch 'dev' of github.com:imbus64/TTime into dev 2024-03-17 16:42:02 +01:00
Imbus
ec36054bd9 Merge branch 'imbs' into dev 2024-03-17 16:41:51 +01:00
Imbus
670ed46d51 WeeklyReport type as represented in the db 2024-03-17 16:41:29 +01:00
dDogge
21cc7ff8a3 Added signed_by attribute to weekly_report SQL table 2024-03-17 15:34:48 +01:00
Imbus
7c21677310 Migrations fix in go 2024-03-17 14:38:20 +01:00
Imbus
0d053add5e Add some sanity checking in SubmitWeeklyReport route 2024-03-17 04:16:26 +01:00
Imbus
23dd22eab5 Json field alias for WeeklyReport 2024-03-17 04:14:40 +01:00
Imbus
2e44d14370 Extending test script 2024-03-17 03:39:31 +01:00
Imbus
c13378d3b9 Proper login endpoint functionality 2024-03-17 01:32:10 +01:00
Imbus
c6d9307979 Fix for CreateProject handler 2024-03-16 22:57:48 +01:00
Imbus
d99de54c5d Major changes related to reports 2024-03-16 22:47:19 +01:00
Imbus
3526decbad Merge imbs 2024-03-16 17:46:08 +01:00
Imbus
151d6de39b Tygo for go->typescript type generation 2024-03-16 17:43:38 +01:00
Imbus
17c8a17ebf IF EXISTS condition in salts table 2024-03-16 17:32:51 +01:00
Imbus
47d7d9fe3c Activity type database changes with interface changes in go 2024-03-16 17:22:55 +01:00
dDogge
04e17a1721 Added comments to various functions 2024-03-15 16:57:42 +01:00
dDogge
018dc24516 Handler for GetProject from db.go added in global_stage.go 2024-03-15 16:45:26 +01:00
dDogge
581209742a Added GetProject in db.go and corresponding test 2024-03-15 16:45:26 +01:00
Imbus
fb67825e29 Experimental port to CGO-free modernc.org/sqlite, no more WSL 2024-03-15 11:02:33 +01:00
dDogge
2409598c6e Handler ProjectRoleChange in global_state.go added for ChangeUserRole in db.go 2024-03-14 23:06:10 +01:00
dDogge
f2a4c417aa Handler ListAllUsersProject in global_state.go added for GetAllUsersProject in db.go 2024-03-14 22:56:50 +01:00
dDogge
34ad6ac777 Handler ListAllUsers in global_state.go added for GetAllUserApplication in db.go 2024-03-14 22:48:06 +01:00
Imbus
aa7c5de1fc GetUserProjects handler 2024-03-14 21:25:14 +01:00
Imbus
e1153934c6 Database interface extension, GetAllProjects, GetUserRole, GetProjectsForUser 2024-03-14 19:48:49 +01:00
Imbus
5e8af6098b Merge branch 'imbs' into dev 2024-03-14 18:27:12 +01:00
Imbus
a291972f82 Makefile targets for generating UML 2024-03-14 18:14:28 +01:00
dDogge
676d6637a2 Added GetAllUsersApplication and corresponding test 2024-03-14 16:25:54 +01:00
dDogge
0e1ea15cc9 Added GetAllUsersProject and corresponding test 2024-03-14 16:01:56 +01:00
Imbus
be04ba148d Merge imbs 2024-03-14 14:37:50 +01:00
Imbus
0824a344e3 Target for dumping database content to file 2024-03-14 14:10:25 +01:00
Imbus
dd4809d631 Merge branch 'dev' of github.com:imbus64/TTime into dev 2024-03-14 14:08:27 +01:00
Imbus
3790e8a3c6 Test cleaning 2024-03-14 13:48:56 +01:00
Imbus
d12e3a26ef Role change database interface with corresponding tests 2024-03-14 13:47:04 +01:00
Imbus
6c8abf1f53 Database refactor and test coverage 2024-03-14 13:39:56 +01:00
dDogge
f0745c5a75 Added ChangeUserRole and corresponding test, also GetProjectId should be fixed. 2024-03-14 13:27:57 +01:00
Imbus
1c87380db7 Mounting handler for adding project 2024-03-13 17:52:37 +01:00
Imbus
25fdf3bb9b Nuke dead code 2024-03-13 12:29:15 +01:00
Imbus
c4632104a8 Commenting out trigger related to salts 2024-03-13 11:46:17 +01:00
Imbus
736cebe036 Sql comments and salts table 2024-03-12 20:44:54 +01:00
Imbus
9b67a580da Gluecode for database/handlers 2024-03-12 20:44:40 +01:00
borean
ad4d439887 cleanup 2024-03-08 15:07:25 +01:00
borean
f8277617a9 Merge remote-tracking branch 'refs/remotes/origin/dev' into dev 2024-03-08 15:02:18 +01:00
borean
6acfdd36b2 cleanup 2024-03-08 14:56:24 +01:00
borean
0b23c5f8f1 Merge branch 'borean-dev' into dev 2024-03-08 14:55:10 +01:00
Imbus
394b283712 Typo 2024-03-08 11:25:31 +01:00
Imbus
02c9c502b8 Eralchemy2 target for generating er diagrams 2024-03-08 11:22:09 +01:00
Imbus
a7ebfe7110 Ignore formatter output in main 2024-03-08 10:32:02 +01:00
Imbus
efc95e7fea Add target for formatting swag docs & formatting swag docs 2024-03-08 10:30:17 +01:00
Imbus
b52f13ee8b Better developer feedback 2024-03-08 10:25:22 +01:00
Imbus
d4a2a00f69 Makefile update with doc generation and convenience installers 2024-03-08 10:17:51 +01:00
Imbus
ae0b0895b2 Version controlling generated docs 2024-03-08 10:17:27 +01:00
Imbus
13c12b424a Mounting handlers and basic swagger docs example 2024-03-08 10:16:56 +01:00
Imbus
f75cb7e9fc Pulling in deps related to swagger 2024-03-08 10:15:05 +01:00
Imbus
bb81a2973e Moving main out of cmd to accomodate swag cli tool 2024-03-08 09:10:20 +01:00
Imbus
944f9b6ccc Removed overly verbose debug printing from db migration 2024-03-08 07:48:25 +01:00
Imbus
12536d5e89 Fixing inconsistent sql in db interface 2024-03-08 07:47:32 +01:00
Imbus
a77b388f8e Warning in make migrate target 2024-03-08 07:34:26 +01:00
Imbus
f5d5eee267 Breaking changes in projects table related to naming 2024-03-08 07:33:58 +01:00
Imbus
553ba2c7c6 New project_role table to represent possible roles 2024-03-08 07:33:31 +01:00
borean
eec3a45509 Added GetProjectId and AddUserToProject, WIP 2024-03-07 23:24:54 +01:00
borean
5a85f2bf81 first draft of AddTimeReport in db.go 2024-03-07 21:57:27 +01:00
borean
7ed986e4eb update 2024-03-07 20:58:50 +01:00
dDogge
bd434c3da7 Added template for various new functions in db.go and corresponding tests in db_test.go 2024-03-07 14:25:28 +01:00
dDogge
18eefab292 Implemented PromoteToAdmin and corresponding Test 2024-03-07 13:21:47 +01:00
dDogge
3adf0b7ef5 Admin SQL table added 2024-03-07 13:09:09 +01:00
Imbus
acff254aa5 Indirect -> direct dependency in go.mod 2024-03-07 12:13:29 +01:00
Imbus
3175c62e6d Carmack level testing instructions 2024-03-07 11:33:06 +01:00
Imbus
c5f0bc509e Makefile target for installing just (hack of doom) 2024-03-06 15:15:41 +01:00
Imbus
d023bb0adf Untested implementation of login and renew endpoints 2024-03-06 12:51:46 +01:00
Imbus
f484674524 Pulled in jwt middleware for fiber 2024-03-06 12:51:00 +01:00
Imbus
85d080cebb Set fiber as direct dependency 2024-03-06 11:24:53 +01:00
Imbus
70ae359856 Example of how to extend the API 2024-03-06 10:14:54 +01:00
Imbus
9d39ff5bc2 Re-implemented demo button 2024-03-06 09:41:36 +01:00
borean
ae9ee91bc4 file correction 2024-03-04 19:34:35 +01:00
borean
a22dcb9f4e first push, broken import, WIP 2024-03-04 02:50:02 +01:00
Imbus
7a12b946a6 Fixing some issues found by the linter 2024-03-02 04:29:50 +01:00
Imbus
c54eccc625 golangci-lint in CI as well as a makefile target 2024-03-02 04:18:29 +01:00
Imbus
63596db60c Migrations readme warnings 2024-03-02 02:40:17 +01:00
Imbus
469f866554 Cleaning up examples in main and splitting the code into suitable packages 2024-03-02 02:38:26 +01:00
Imbus
5cefed405f Reduce verbosity of the tests 2024-03-02 02:31:20 +01:00
Imbus
a749857c98 User_roles table constraints 2024-03-01 07:47:06 +01:00
Imbus
b39ce645d6 Proper interface for the database 2024-02-29 20:33:20 +01:00
Imbus
4d510e5c51 Rename App -> Server, less confusing 2024-02-29 20:02:13 +01:00
Imbus
568fb0323e Makefile changes related to watch 2024-02-29 07:29:12 +01:00
Imbus
d51b9f78c2 Porting to fiber 2024-02-28 11:29:32 +01:00
Imbus
4c7a3fd9a0 Pulling in fiber as a dep 2024-02-28 11:28:57 +01:00
Imbus
4c7e660a20 Correcting path in makefile 2024-02-28 10:58:32 +01:00
Imbus
523a211933 Merge 2024-02-28 10:36:36 +01:00
Imbus
47040c8dc2 Format target 2024-02-28 10:34:51 +01:00
Imbus
2349fad4f4 Make use of the config 2024-02-28 08:39:42 +01:00
Imbus
34c0712825 Moving the migrations directory into database for embedding 2024-02-28 03:30:05 +01:00
Imbus
e1cd596c13 Config parsing and database api changes 2024-02-28 03:21:13 +01:00
Imbus
06632c16da Better interface for writeconfig 2024-02-27 23:11:27 +01:00
Imbus
9d6cddb724 Various breaking changes to the database schema 2024-02-27 08:05:07 +01:00
Imbus
229ebc3a08 AddProject database interface with tests 2024-02-27 07:59:42 +01:00
Imbus
6f51151d64 Save backups in a backup directory 2024-02-27 07:45:38 +01:00
Imbus
6c82aa2047 Backup target for makefile 2024-02-27 07:43:20 +01:00
Imbus
6e48c0a088 Database migration readme 2024-02-27 06:09:09 +01:00
Imbus
ce1ce89b00 Some more example database interface code 2024-02-27 05:51:16 +01:00
Imbus
60e7b73f66 Unique username constraint on users table 2024-02-27 05:50:28 +01:00
Imbus
06076f93b7 Database interactions demo 2024-02-27 05:00:04 +01:00
Imbus
5be29d86af Makefile changes so that test depends on db.sqlite3 2024-02-27 04:59:24 +01:00
Imbus
296ed987d8 Make tests verbose and disable testing cache 2024-02-27 04:56:12 +01:00
Imbus
033402ffaf Mistake in migration scripts 2024-02-26 00:13:39 +01:00
Imbus
3ba446be5b Splitting migration scripts 2024-02-26 00:12:13 +01:00
Imbus
f9eb67da11 Direct dependency specification in go.mod 2024-02-26 00:06:04 +01:00
Imbus
b5fd6a1c4b Draft version of the SQL tables 2024-02-20 20:24:53 +01:00
Imbus
973ab1db1d Config file TOML parsing with basic tests 2024-02-20 20:13:53 +01:00
Imbus
3b51c69948 Typo2 2024-02-20 15:55:15 +01:00
Imbus
dec43d2dba Typo 2024-02-20 15:54:40 +01:00
Imbus
540e8bcc79 Watch target for makefile in backend 2024-02-20 15:42:45 +01:00
Imbus
4554ddab6d Better button handler server-side 2024-02-20 15:26:28 +01:00
Imbus
dd99d0de9d Implementation details in backend readme 2024-02-13 09:54:47 +01:00
Imbus
4d39978af6 Go package name change 2024-02-13 09:20:49 +01:00
Imbus
c9cd13747f Stateful http handler demo 2024-02-13 09:19:25 +01:00
Imbus
5c73ef922e More on go in backend readme 2024-02-13 08:52:15 +01:00
Imbus
1586ed22ef Readme for backend 2024-02-13 08:33:35 +01:00
Imbus
2e7d72b022 Typo 2024-02-12 17:23:42 +01:00
Imbus
5d8d5c6fde Better feedback when starting server 2024-02-12 17:20:42 +01:00
Imbus
62662f0c81 Clean target update 2024-02-12 13:11:25 +01:00
Imbus
29d5885b67 Go server draft 2024-02-12 12:40:49 +01:00