def qidian(request):
user = request['session'].get('user', None)
novels_type = request.args.get('type', '????').strip()
first_type_title = "????"
first_type = [
'??',
'??',
'??',
'??',
'??',
'??',
'??',
'??',
'??',
'??',
'??',
'??',
'???',
]
if novels_type in first_type:
novels_head = [novels_type]
elif novels_type == first_type_title:
novels_head = ['#']
else:
return redirect('qidian')
search_ranking = await cache_others_search_ranking(spider='qidian', novel_type=novels_type)
title = "owllook - ??????"
if user:
return template('index.html',
title=title,
is_login=1,
is_qidian=1,
user=user,
search_ranking=search_ranking,
first_type=first_type,
first_type_title=first_type_title,
novels_head=novels_head)
else:
return template('index.html',
title=title,
is_login=0,
is_qidian=1,
search_ranking=search_ranking,
first_type=first_type,
first_type_title=first_type_title,
novels_head=novels_head)
评论列表
文章目录