Commit Graph

67 Commits

Author SHA1 Message Date
projectmoon 6030827464 Remove unused REST semantics from cofd API. 2021-01-09 20:02:24 +00:00
projectmoon 7fe28ef82e Fix webpack publicPath to match server route. 2021-01-09 19:41:57 +00:00
projectmoon 78036394b1 Move cofd api endpoints into their own file 2021-01-09 19:39:35 +00:00
projectmoon ed79007c29 Update license in package.json to AGPL 2021-01-09 19:29:47 +00:00
projectmoon ee892a3f34 Adjust webpack config slightly for better generation. 2021-01-09 13:32:08 +00:00
projectmoon a34e8d24c6 Rename static directory to generated 2021-01-09 13:03:07 +00:00
projectmoon 55dff277ef Remove old comments in edit character script. 2021-01-09 12:59:11 +00:00
projectmoon ba7fc8268f Move typescript into source tree. 2021-01-09 12:57:13 +00:00
projectmoon 3ba7917455 Implement a bit more of the view character template. 2021-01-05 21:42:38 +00:00
projectmoon 0a128a7067 Remove more unneeded things 2021-01-05 21:33:21 +00:00
projectmoon b3253922df Clean up files and remove things that no longer need to exist. 2021-01-05 21:25:26 +00:00
projectmoon a729ccb4a2 Return semi-proper values from the protobuf HTTP API 2021-01-05 21:19:47 +00:00
projectmoon 8f1ddf89dd Reimplement attribute updtaes 2021-01-05 19:32:03 +00:00
projectmoon 63571d9711 WIP on reimplementing edit character script with typescript 2021-01-04 22:36:52 +00:00
projectmoon b4981dfc78 Compiles, assuming the user id will be in grpc metadata from auth interceptor. 2021-01-03 23:18:36 +00:00
projectmoon a867fdd831 WIP - at a crossroads where we need some kind of auth mechanism 2021-01-03 22:05:28 +00:00
projectmoon 81c1ace175 Add readme instructions, run proxy command. 2021-01-03 21:24:52 +00:00
projectmoon 924712f583 Successful (but very manual) grpc-web requests. 2021-01-03 20:42:54 +00:00
projectmoon 912c949844 Run npm commands for building in build.rs 2021-01-03 14:07:11 +00:00
projectmoon f9ceea17cf Move typescript stuff to static/scripts 2021-01-03 13:46:40 +00:00
projectmoon 616cbe5730 Move templates into src 2021-01-03 13:37:55 +00:00
projectmoon a16ffd0495 Serve templated templates with webpack-compiled JS injected. 2021-01-03 13:36:53 +00:00
projectmoon aa5fa59aab Add some working typescript code that imports manually compiled protos. 2021-01-02 23:11:09 +00:00
projectmoon 3a250230df Experimenting with tonic 2021-01-02 22:32:17 +00:00
projectmoon 8bee670778 Remove un-needed 'resources' functions. 2021-01-02 22:12:43 +00:00
projectmoon b042a32f82 RPC-ify update attribute API. 2021-01-02 22:11:58 +00:00
projectmoon f2edd91a72 Update skill value as rpc API (though not grpc) 2021-01-02 22:11:58 +00:00
projectmoon ee8f7e58e8 Implement updating skills. 2021-01-02 22:11:58 +00:00
projectmoon 0ca23b46c6 Switch to oneof field for game-specific information and values.
Having specific protobuf types for different game systems using the
same rule set (e.g. all the Chronicles of Darkness games) is untenable
because protobuf does not have inheritance or mixins.

Instead, we have one generic character sheet type, with a oneof field
for the game specifics. This will be used in conjunction with the
character's game system (stored in db) to render different stuff on
the character templates.

Without this, we'd wind up having duplicate templates, a lot more code
for handling specifics of each game system, and so on.
2021-01-01 23:34:50 +00:00
projectmoon 149b843927 Remove versioning from data type enum members 2021-01-01 22:56:41 +00:00
projectmoon 7a71d5ad0a Implement updating skills on the backend. 2021-01-01 00:40:48 +00:00
projectmoon 0b899293ca Update cargo dependencies. 2020-12-31 22:32:32 +00:00
projectmoon c35ac19060 Add ability to edit changeling characters. 2020-12-31 22:28:00 +00:00
projectmoon 255b55c8de Add skills to the character editor. 2020-12-31 22:21:05 +00:00
projectmoon 6156bba34d Skip loading owner of character for API. 2020-12-31 20:19:45 +00:00
projectmoon 2e2cf30755 Update readme for SQLx. 2020-12-31 14:11:28 +00:00
projectmoon ce4e02594d Add ability to pass in custom database path. 2020-12-31 14:11:28 +00:00
projectmoon 62f05060c0 Move migrations to refinery + barrel, enable 'offline' sqlx query checking 2020-12-31 14:11:28 +00:00
projectmoon e148b45edd Convert load user queries to compile-checked 2020-12-31 14:11:28 +00:00
projectmoon fb1c21d710 Clear out unused imports in db.rs 2020-12-31 14:11:28 +00:00
projectmoon 6f9d1e00bc Use sqlx result in db.rs 2020-12-31 14:11:28 +00:00
projectmoon 53501c3747 Convert character db methods to compile-checked queries 2020-12-31 14:11:28 +00:00
projectmoon 5ea07b8953 Rip out Diesel in favor of SQLx.
The primary benefit of this is to avoid Rocket's database integration,
which has become problematic in this codebase with the update to the
new async style. Because the async database API is actually
synchronous under the hood, this introduces some annoying lifetime
requirements that basically force us to use owned data everywhere.

The original pattern was to have a separate data layer that could
invoke queries from `self` (the db connection). By using a true async
database driver, we can get this back, because the lifetimes are once
again flexible instead of the ones forced by Rocket.
2020-12-31 14:11:28 +00:00
projectmoon bf2f49f68a Load character in API as common function. Fix attribute editing. 2020-12-29 14:01:07 +00:00
projectmoon 1f6f6432e1 Implement editing of attributes. 2020-12-27 21:49:08 +00:00
projectmoon 4023bdc08a Start of adding protobuf-based editable character sheet. 2020-12-27 21:03:10 +00:00
projectmoon 0c613cacda Update cargo.lock 2020-12-14 23:21:09 +00:00
projectmoon 2e8197eedc Change global databases to debug (for development) 2020-12-14 19:06:21 +00:00
projectmoon 8c8ed4f6ef Migrate to Rocket 0.5.
Rocket 0.5 is a major uprade, rewriting most of Rocket to be async.
Required many changes through the code, especially the database layer.
The new Rocket async database calls require Futures with 'static
lifetimes.

General:
 - Move to stable rust.
 - Most of codebase is now async.
 - Rocket migrations (e.g. Cookies to CookieJar).

Database:
 - Switched to owned data (&str -> String) for inserts because of the
   'static lifetime requirement on Rocket's DB future.
 - All database methods now asynchronous.

Pages:
 - Changed various routes to async.
 - Needed to add clone calls to some places because we need to use
   owned data multiple times (registration).
2020-12-13 21:58:39 +00:00
projectmoon 4024f32621 Serve protobuf files statically. 2020-12-09 22:21:52 +00:00