From c170e2050aca0ca38b770616d4d96f3a11cce599 Mon Sep 17 00:00:00 2001 From: Fabrice Bellamy <12b@distrilab.fr> Date: Wed, 16 Oct 2024 20:11:34 +0200 Subject: [PATCH] cargo loco generate scaffold server name:string domain:string --htmx --- nixin_farm/assets/views/base.html | 26 ++++ nixin_farm/assets/views/server/create.html | 54 ++++++++ nixin_farm/assets/views/server/edit.html | 73 +++++++++++ nixin_farm/assets/views/server/list.html | 27 ++++ nixin_farm/assets/views/server/show.html | 19 +++ nixin_farm/migration/src/lib.rs | 4 +- .../migration/src/m20241016_180911_servers.rs | 37 ++++++ nixin_farm/src/app.rs | 3 +- nixin_farm/src/controllers/mod.rs | 2 + nixin_farm/src/controllers/server.rs | 115 ++++++++++++++++++ nixin_farm/src/models/_entities/mod.rs | 3 +- nixin_farm/src/models/_entities/notes.rs | 2 +- nixin_farm/src/models/_entities/prelude.rs | 3 +- nixin_farm/src/models/_entities/servers.rs | 18 +++ nixin_farm/src/models/_entities/users.rs | 2 +- nixin_farm/src/models/mod.rs | 1 + nixin_farm/src/models/servers.rs | 7 ++ nixin_farm/src/views/mod.rs | 2 + nixin_farm/src/views/server.rs | 39 ++++++ nixin_farm/tests/models/mod.rs | 2 + nixin_farm/tests/models/servers.rs | 31 +++++ 21 files changed, 464 insertions(+), 6 deletions(-) create mode 100644 nixin_farm/assets/views/base.html create mode 100644 nixin_farm/assets/views/server/create.html create mode 100644 nixin_farm/assets/views/server/edit.html create mode 100644 nixin_farm/assets/views/server/list.html create mode 100644 nixin_farm/assets/views/server/show.html create mode 100644 nixin_farm/migration/src/m20241016_180911_servers.rs create mode 100644 nixin_farm/src/controllers/server.rs create mode 100644 nixin_farm/src/models/_entities/servers.rs create mode 100644 nixin_farm/src/models/servers.rs create mode 100644 nixin_farm/src/views/server.rs create mode 100644 nixin_farm/tests/models/servers.rs diff --git a/nixin_farm/assets/views/base.html b/nixin_farm/assets/views/base.html new file mode 100644 index 0000000..d0d8c43 --- /dev/null +++ b/nixin_farm/assets/views/base.html @@ -0,0 +1,26 @@ + + + + +
+