-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathmain.py
45 lines (34 loc) · 1.25 KB
/
main.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
import asyncio
from fastapi import FastAPI
from fastapi.responses import HTMLResponse
app = FastAPI()
@app.get("/")
async def root():
return HTMLResponse(str(open("test.html").read()), status_code=200)
@app.get("/addnewitem")
async def root():
return HTMLResponse(str(open("addnewitem.html").read()), status_code=200)
@app.get("/additem.php")
async def root():
return HTMLResponse(str(open("additem.php").read()), status_code=200)
@app.get("/removeitem")
async def root():
return HTMLResponse(str(open("removeitem.html").read()), status_code=200)
@app.get("/remitem.php")
async def root():
return HTMLResponse(str(open("remitem.php").read()), status_code=200)
@app.get("/rentitem")
async def root():
return HTMLResponse(str(open("rentitem.html").read()), status_code=200)
@app.get("/rentitem.php")
async def root():
return HTMLResponse(str(open("rentitem.php").read()), status_code=200)
@app.get("/unrentitem")
async def root():
return HTMLResponse(str(open("unrentitem.html").read()), status_code=200)
@app.get("/unrentitem.php")
async def root():
return HTMLResponse(str(open("unrentitem.php").read()), status_code=200)
@app.get("/search.php")
async def root():
return HTMLResponse(str(open("search.php").read()), status_code=200)