fixed paths
This commit is contained in:
@@ -176,7 +176,8 @@ pub async fn home_handler(
|
||||
context.insert("title", &state.app_name);
|
||||
context.insert("current_sort", &sort_field);
|
||||
context.insert("current_order", &order);
|
||||
context.insert("current_page", "leaderboard"); // NEW
|
||||
context.insert("current_page", "leaderboard");
|
||||
context.insert("prefix", "");
|
||||
|
||||
match TEMPLATES.render("index.html", &context) {
|
||||
Ok(html) => Ok(Html(html)),
|
||||
@@ -205,6 +206,8 @@ pub async fn report_details_handler(
|
||||
"score",
|
||||
&((report.benchmark.multi_thread.score + report.benchmark.single_thread.score) / 2),
|
||||
);
|
||||
context.insert("current_page", "details");
|
||||
context.insert("prefix", "../");
|
||||
|
||||
match TEMPLATES.render("details.html", &context) {
|
||||
Ok(html) => Ok(Html(html)),
|
||||
@@ -403,6 +406,7 @@ pub async fn analytics_handler(
|
||||
context.insert("json_data", &json_data);
|
||||
context.insert("data", &data);
|
||||
context.insert("current_page", "analytics");
|
||||
context.insert("prefix", "");
|
||||
|
||||
match TEMPLATES.render("analytics.html", &context) {
|
||||
Ok(html) => Ok(Html(html)),
|
||||
|
||||
Reference in New Issue
Block a user