def screening(id): l.l('screening_view', uid=request.user.id, id=id) proposal = l.get_proposal(id) if not proposal or proposal.withdrawn: abort(404) if request.user.email in (x.email.lower() for x in proposal.authors): abort(404) unread = l.is_unread(request.user.id, id) discussion = l.get_discussion(id) standards = l.get_standards() existing_vote = l.get_user_vote(request.user.id, id) votes = l.get_votes(id) my_votes = l.get_my_votes(request.user.id) percent = l.get_vote_percentage(request.user.email, request.user.id) return render_template('screening_proposal.html', proposal=proposal, votes=votes, discussion=discussion, standards=standards, existing_vote=existing_vote, unread=unread, percent=percent)
def comment(id): comment = request.values.get('comment').strip() if comment: l.add_to_discussion(request.user.id, id, comment, feedback=False) return render_template('discussion_snippet.html', unread=l.is_unread(request.user.id, id), discussion=l.get_discussion(id))
def comment(id): comment = request.values.get('comment').strip() if comment: l.add_to_discussion(request.user.id, id, comment, feedback=False) return render_template('discussion_snippet.html', unread = l.is_unread(request.user.id, id), discussion = l.get_discussion(id))
def screening(id): l.l('screening_view', uid=request.user.id, id=id) proposal = l.get_proposal(id) if not proposal or proposal.withdrawn: abort(404) if request.user.email in (x.email.lower() for x in proposal.authors): abort(404) unread = l.is_unread(request.user.id, id) discussion = l.get_discussion(id) standards = l.get_standards() bookmarked = l.has_bookmark(request.user.id, id) existing_vote = l.get_user_vote(request.user.id, id) votes = l.get_votes(id) my_votes = l.get_my_votes(request.user.id) percent = l.get_vote_percentage(request.user.email, request.user.id) return render_template('screening_proposal.html', proposal=proposal, votes=votes, discussion=discussion, standards=standards, bookmarked=bookmarked, existing_vote=existing_vote, unread=unread, percent=percent)
def screening(id): proposal = l.get_proposal(id) if not proposal or proposal.withdrawn: abort(404) if request.user.email in (x.email.lower() for x in proposal.authors): abort(404) unread = l.is_unread(request.user.id, id) discussion = l.get_discussion(id) standards = l.get_standards() progress = l.screening_progress() bookmarked = l.has_bookmark(request.user.id, id) existing_vote = l.get_user_vote(request.user.id, id) votes = l.get_votes(id) return render_template( "screening_proposal.html", proposal=proposal, votes=votes, discussion=discussion, standards=standards, progress=progress, bookmarked=bookmarked, existing_vote=existing_vote, unread=unread, )
def feedback(id): if CUTOFF_FEEDBACK: abort(404) comment = request.values.get('feedback').strip() if comment: l.add_to_discussion(request.user.id, id, comment, feedback=True) return render_template('discussion_snippet.html', unread=l.is_unread(request.user.id, id), discussion=l.get_discussion(id))
def feedback(id): if CUTOFF_FEEDBACK: abort(404) comment = request.values.get('feedback').strip() if comment: l.add_to_discussion(request.user.id, id, comment, feedback=True) return render_template('discussion_snippet.html', unread = l.is_unread(request.user.id, id), discussion = l.get_discussion(id))
def mark_read(id): l.mark_read(request.user.id, id) return render_template('discussion_snippet.html', unread=l.is_unread(request.user.id, id), discussion=l.get_discussion(id))
def mark_read(id): l.mark_read(request.user.id, id) return render_template('discussion_snippet.html', unread = l.is_unread(request.user.id, id), discussion = l.get_discussion(id))