week: Create new weeks and change active one
Implement a way for admins to introduce new weeks and set them as the last active one. The last active week is the last one that is accessible to players, and will also prevent the graph from being displayed. Implement arrows for navigating between the weeks in the HTML.
This commit is contained in:
parent
635716c04b
commit
e08a46af3a
5 changed files with 153 additions and 4 deletions
|
@ -42,7 +42,11 @@ async fn index(mut db: Connection<Db>) -> Redirect {
|
|||
fn rocket() -> _ {
|
||||
rocket::build()
|
||||
.mount("/", FileServer::from(relative!("static_files")))
|
||||
.mount("/", routes![index, vote::fetch_vote_data, vote::vote, truth::create_truth, truth::edit_truth, week::week, week::update_week, auth::login])
|
||||
.mount("/", routes![index,
|
||||
vote::fetch_vote_data, vote::vote,
|
||||
truth::create_truth, truth::edit_truth,
|
||||
week::week, week::update_week, week::set_last_week, week::create_week,
|
||||
auth::login])
|
||||
.attach(database::stage())
|
||||
.attach(Template::fairing())
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue