Update 42.深入模型.md

pull/774/head
Ron 2021-04-22 09:22:49 +08:00 committed by GitHub
parent 6632c37223
commit a90e71fd83
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 2 additions and 0 deletions

View File

@ -376,6 +376,8 @@ Teacher.objects.filter(subject__name__contains='全栈')
def show_teachers(request):
try:
# 测试的时候要传参数snohttp://localhost:8000/teachers/?sno=1
try:
sno = int(request.GET.get('sno'))
teachers = []