Compare commits
No commits in common. "2873707e5023e4fe92573688d46bc591acb3810d" and "721bc1827af6bc53ffb29f1d5fa276dd1f166877" have entirely different histories.
2873707e50
...
721bc1827a
4 changed files with 3 additions and 6 deletions
|
|
@ -1,7 +1,6 @@
|
|||
import json
|
||||
import xml.etree.ElementTree as ET
|
||||
|
||||
import ox
|
||||
import json
|
||||
|
||||
from django.utils import timezone
|
||||
from django.utils.timezone import datetime, timedelta
|
||||
|
|
@ -159,7 +158,7 @@ def comment(request):
|
|||
comment.name = data['name']
|
||||
comment.email = data['email']
|
||||
comment.session_key = request.session.session_key
|
||||
comment.text = ox.add_links(data['text'])
|
||||
comment.text = data['text']
|
||||
comment.save()
|
||||
link = request.build_absolute_uri(comment.item.get_absolute_url())
|
||||
tasks.notify_moderators.delay(comment.id, link)
|
||||
|
|
|
|||
|
|
@ -161,7 +161,7 @@ document.querySelector('button#add-comment').addEventListener('click', event =>
|
|||
`
|
||||
comment.querySelector('.name').innerText = response.name
|
||||
comment.querySelector('.date').innerText = response.date
|
||||
comment.querySelector('.text').innerHTML = response.text
|
||||
comment.querySelector('.text').innerText = response.text
|
||||
document.querySelector('.comments .comments-content').append(comment)
|
||||
document.querySelector('.add-comment textarea').value = ''
|
||||
if (!user.username) {
|
||||
|
|
|
|||
|
|
@ -1,6 +1,5 @@
|
|||
{% if week_title %}
|
||||
<h1>{{ week_title }}</h1>
|
||||
<br>
|
||||
{% endif %}
|
||||
{% for item in items %}
|
||||
<div class="item">
|
||||
|
|
|
|||
|
|
@ -14,4 +14,3 @@ django-celery-beat
|
|||
redis
|
||||
django-brake
|
||||
python-telegram-bot
|
||||
ox
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue