add 完善用户登录状态和未登录状态

This commit is contained in:
2024-09-05 03:22:23 +08:00
parent d32e0000ba
commit 23bff01191
27 changed files with 132 additions and 6 deletions
Binary file not shown.
+4
View File
@@ -9,6 +9,10 @@ def to_index(request):
site_title_first = "在星河中"
site_title = "在星河中"
site_one = "心之何如,有似万丈迷津,遥亘千里,其中并无舟子可渡人,除了自渡,他人爱莫能助。"
user = request.user
print("---------------------------")
print(user)
data = {"site_title_first":site_title_first,"site_title":site_title,"site_one":site_one}
return render(request, "html/index.html",data)