mirror of
https://github.com/Garmelon/Arbeitszeitdokumentationsgenerator.git
synced 2026-04-12 16:55:04 +02:00
Use relative links
This commit is contained in:
parent
b73efa7b28
commit
9e18b8940f
5 changed files with 5 additions and 5 deletions
|
|
@ -29,7 +29,7 @@ submit.addEventListener("click", async () => {
|
||||||
try {
|
try {
|
||||||
showStatus("Generiere...");
|
showStatus("Generiere...");
|
||||||
|
|
||||||
const response = await fetch("/", {
|
const response = await fetch(".", {
|
||||||
method: "post",
|
method: "post",
|
||||||
body: new URLSearchParams(data),
|
body: new URLSearchParams(data),
|
||||||
});
|
});
|
||||||
|
|
|
||||||
|
|
@ -30,7 +30,7 @@ pub async fn get() -> Markup {
|
||||||
"Want to use "
|
"Want to use "
|
||||||
a href="https://github.com/kit-sdq/TimeSheetGenerator" { "TimeSheetGenerator" }
|
a href="https://github.com/kit-sdq/TimeSheetGenerator" { "TimeSheetGenerator" }
|
||||||
"-compatible JSON instead? "
|
"-compatible JSON instead? "
|
||||||
a href="/tsg" { "Go here!" }
|
a href="tsg/" { "Go here!" }
|
||||||
}
|
}
|
||||||
|
|
||||||
div #header {
|
div #header {
|
||||||
|
|
|
||||||
|
|
@ -33,7 +33,7 @@ submit.addEventListener("click", async () => {
|
||||||
try {
|
try {
|
||||||
showStatus("Generiere...");
|
showStatus("Generiere...");
|
||||||
|
|
||||||
const response = await fetch("/tsg", {
|
const response = await fetch(".", {
|
||||||
method: "post",
|
method: "post",
|
||||||
headers: { "Content-Type": "application/json" },
|
headers: { "Content-Type": "application/json" },
|
||||||
body: dataJson,
|
body: dataJson,
|
||||||
|
|
|
||||||
|
|
@ -23,7 +23,7 @@ pub async fn get() -> Markup {
|
||||||
|
|
||||||
p {
|
p {
|
||||||
"Want to use a fancy-looking form instead? "
|
"Want to use a fancy-looking form instead? "
|
||||||
a href="/" { "Go here!" }
|
a href=".." { "Go here!" }
|
||||||
}
|
}
|
||||||
|
|
||||||
textarea name="global" placeholder="Global.json" {}
|
textarea name="global" placeholder="Global.json" {}
|
||||||
|
|
|
||||||
|
|
@ -16,7 +16,7 @@ async fn main() -> anyhow::Result<()> {
|
||||||
|
|
||||||
let app = Router::<()>::new()
|
let app = Router::<()>::new()
|
||||||
.route("/", get(endpoints::index::get).post(endpoints::index::post))
|
.route("/", get(endpoints::index::get).post(endpoints::index::post))
|
||||||
.route("/tsg", get(endpoints::tsg::get).post(endpoints::tsg::post));
|
.route("/tsg/", get(endpoints::tsg::get).post(endpoints::tsg::post));
|
||||||
let listener = TcpListener::bind(args.addr).await?;
|
let listener = TcpListener::bind(args.addr).await?;
|
||||||
axum::serve(listener, app).await?;
|
axum::serve(listener, app).await?;
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue