Very happy.
Made good progress. web form #CRUD now complete for first db table Song_Books working in #PrayerOfHannah
#RustLang #Axum #SeaOrm
All code on @Codeberg (which I see has been updated to use @forgejo ) at
https://codeberg.org/Dave42W/PrayerOfHannah
#CodeBerg #Forgejo
#crud #prayerofhannah #rustlang #axum #seaorm #codeberg #forgejo
Ok toasted sandwiches made and all in the freezer.
Now a bit of playing with #PrayerOfHannah using #RustLang
Got all #SeaOrm #Axum etc installed and going to define the first tables in the migration script (table definitions are going to be incredibly unstable for quite a while).
Enjoying a nice coffee too 😃
#prayerofhannah #rustlang #seaorm #axum
It has taken me ages but I finally have #SeaOrm migration creating and dropping an index. In the process, I think I have gained a better grasp of working with #RustLang Result
Should be useful when I revisit getting SeaOrm to work cleanly with #Axum StatusCode
All committed in #CodeBerg at https://codeberg.org/Dave42W/daves_dashboard
#seaorm #rustlang #axum #codeberg
Ok, in today's #RustLang I have managed to wrap #SeaOrm Update and Delete in transactions. In #Axum I've got Insert, Update and Delete redirecting url's properly.
There are a few cases where I would like to return nice HTTP status codes (such as if another user has deleted the row before your transaction starts).
Struggling to get those different responses to work as I want.
I keep putting off doing docs and tests 😉
But I now have full CRUD for my first table.
I had some difficulties using the PATCH method on my edit form, it wasn't routing as I expected, so updates use POST to a different route.
I need
- some better passing db errors to the user
- a delete confirmation
- checking for multi-user db changes
- transactions
- after insert/update/delete I should redirect to the list not simply call the method as the url is wrong.
#RustLang #Axum #SeaOrm #Handlebars_rs
#rustlang #axum #seaorm #handlebars_rs
Very excited. I have the parts working together for an incredibly, basic #RustLang web app. Using #Axum #Handlebars_rs #SeaOrm with #Sqlite all on #CodeBerg at https://codeberg.org/Dave42W/daves_dashboard
I've tidied the code and massively simplified it.
Getting to the point where I have a working environment to start building #PrayerOfHannah .
I do want to add doc strings, and tests so this becomes the simplest possible example of all the connections for a CRUD web app.
#rustlang #axum #handlebars_rs #seaorm #sqlite #codeberg #prayerofhannah
Close but struggling to connect #SeaOrm entities to #Axum handlers, I want get Json from the entity for rendering html with #Handlebars_rs ) and I want to get extracted form into entity struct so I can insert into database.
Caught in a mismatch of types and traits and funding the docs & examples either don't work or very confusing.
#RustLang learning curve is steep again.
#seaorm #axum #handlebars_rs #rustlang
Made good #RustLang progress this evening, no longer spending hours trying to understand compiler errors 😊
Working on my learning project "Daves Dashboard" code on #CodeBerg at https://codeberg.org/Dave42W/daves_dashboard
I've got #Axum #Handlebars_rs (including first partial template) and #SeaOrm working together neatly. Was a lot of setup for migrations but now also have autogenerated entity.
Next connect my model to the database using entity.
#rustlang #codeberg #axum #handlebars_rs #seaorm