diff options
Diffstat (limited to 'examples')
-rw-r--r-- | examples/tutorial01/polls/migrations/mod.rs | 3 | ||||
-rw-r--r-- | examples/tutorial01/polls/mod.rs | 9 | ||||
-rw-r--r-- | examples/tutorial01/polls/models.rs | 3 |
3 files changed, 15 insertions, 0 deletions
diff --git a/examples/tutorial01/polls/migrations/mod.rs b/examples/tutorial01/polls/migrations/mod.rs new file mode 100644 index 0000000..64efe8d --- /dev/null +++ b/examples/tutorial01/polls/migrations/mod.rs @@ -0,0 +1,3 @@ +use tosin::db::migration::{Migration, gather}; + +gather!(); diff --git a/examples/tutorial01/polls/mod.rs b/examples/tutorial01/polls/mod.rs index d22af0f..0b039d9 100644 --- a/examples/tutorial01/polls/mod.rs +++ b/examples/tutorial01/polls/mod.rs @@ -1,4 +1,13 @@ +use tosin::apps::AppConfig; + +mod migrations; +pub mod models; pub mod urls; pub mod views; pub use urls::urls; + +pub const APP: AppConfig = AppConfig { + name: module_path!(), + migrations: migrations::migrations, +}; diff --git a/examples/tutorial01/polls/models.rs b/examples/tutorial01/polls/models.rs new file mode 100644 index 0000000..82aa7fd --- /dev/null +++ b/examples/tutorial01/polls/models.rs @@ -0,0 +1,3 @@ +use tosin::db::models::{Model, Id}; + +// TODO define models |