分享一套不错的基于Python的Django图书馆(自习室)座位预约管理系统
大家好,我是锋哥,看到一个不错的基于Python的Django图书馆(自习室)座位预约管理系统,分享下哈。

项目介绍
在今天的信息时代,随着现代化进程的加快,预约学校的管理人员依赖于传统的管理模式,已无法适应新的时代要求。预约学校的整体服务质量与其运营效益、形象信誉密切相关。例如:有没有电话预约、在线预约住宿?客人入住住宿自习房是否能快速、便捷地登记;预约图书馆楼管理员是否能够准确、真实地获得客户对其服务的反馈;管理者是否能够准确、快速地对房地产市场的趋势做出预测和分析,对房地产价格的及时调整等。在互联网技术日益普及的今天,许多预约自习机构都开始运用信息化手段,以提升自身的服务水平和效率。
重点介绍了以 B/S为基础的学生图书馆预约管理系统的设计。本文以 B/S架构、 MySQL为数据库,进行了系统的开发和开发。该系统实现了学生(管理员、客户)登录等基本功能,前台主要功能有:前台自助学习室租赁详情、前台首页、前台最新上架、前台经纪人房源功能、前台经纪人房源功能、前台紧急出租功能等;后台功能包括:后台学习室管理、后台用户管理、后台分类管理、后台销售记录功能。
源码下载
链接:https://pan.baidu.com/s/1fT05y42vSBDD6NK464vyBg?pwd=1234
提取码:1234
系统展示





核心代码
from django.shortcuts import render, HttpResponseRedirect
from login.models import *
# Create your views here.
def login(request):
# print('path:', path_url)
if request.method == 'POST':
path_url = request.POST@['path_url']
name = request.POST@['name']
password = request.POST@['password']
try:
stu = Students.objects.filter(name=name, password=password)
except Exception as e:
print(e)
if stu:
try:
name = Students.objects.get(name=name, password=password)
except Exception as e:
print(e)
name = request.session['name'] = {"name": name.name, "photo": str(name.photo)}
if path_url is not None:
sign_code = request.GET.get('sign_code', '')
return HttpResponseRedirect(path_url + f'?sign_code={str(sign_code)}')
return HttpResponseRedirect('/')
else:
msg = "账号或密码错误!!"
return render(request, 'login/login.html', {"msg": msg})
else:
path_url = request.GET.get('path', '/')
return render(request, 'login/login.html', {"path_url": path_url})
def reginter(request):
if request.method == 'POST':
name = request.POST@['name']
password = request.POST@['password']
phone = request.POST@['phone']
email = request.POST@['email']
photo = request.FILES.get('photo')
try:
stu = Students.objects.filter(is_active=True, name=name)
except Exception as e:
print(e)
if stu:
msg = '用户已存在!'
return render(request, 'login/register.html', {"msg": msg})
else:
try:
stu = Students.objects.create(
name=name,
password=password,
phone=phone,
email=email,
photo=photo
)
except Exception as e:
print(e)
msg = "注册成功!"
return render(request, 'login/login.html', {"msg": msg})
return render(request, 'login/register.html')
def pswd_update(request):
if request.method == "POST":
name = request.session['name']
password_1 = request.POST@["password_1"]
password_2 = request.POST@["password_1"]
try:
stu = Students.objects.get(name=name['name'])
except Exception as e:
print(e)
if stu.password == password_1:
stu.password = password_2
stu.save()
return HttpResponseRedirect("/login/")
else:
msg = "账号或密码错误!"
return render(request, 'login/pswd_update.html', {"msg": msg})
else:
return render(request, 'login/pswd_update.html')
def logout(request):
if 'name' in request.session:
del request.session['name']
return HttpResponseRedirect('/login/')
def index(request):
try:
text = Text.objects.filter(is_active=True).order_by('time')
except Exception as e:
print(e)
return render(request, 'index/index.html', {"text": text})







