Commit 13a16f48 authored by 王浩's avatar 王浩

Merge branch 'haow/dev' into 'master'

Haow/dev

See merge request alpha/saturn!43
parents 19c4a177 2cac4681
......@@ -4,6 +4,8 @@ from django.conf.urls import url
from .views import user
from .views import topic
from .views import tag
from .views import reply
urlpatterns = [
# grasp
......@@ -22,4 +24,7 @@ urlpatterns = [
url(r'^v1/validate_3party_account$', user.Validate3PartyAccount.as_view(), name='validate_3party_account$'),
url(r'^v1/user/batch_create_shadow_user$', user.BatchCreateShadowUser.as_view(), name='batch_create_shadow_user$'),
url(r'^v1/user/batch_update_user_level_fans$', user.BatchUpdateUserLevelFansNum.as_view(), name='batch_update_user_level_fans$'),
# reply
url(r'^v1/reply/create_for_inner$', reply.CreateReplyForInner.as_view(), name='create_reply_for_inner'),
]
import json
from api.views.base_view import BaseView
class CreateReplyForInner(BaseView):
"""
内部使用,创建评论回复
"""
def post(self, request):
user_id = request.POST.get('user_id')
topic_id = request.POST.get('topic_id')
content = request.POST.get('content', '')
replied_id = request.POST.get('replied_id')
error, data = self.call_rpc('venus/community/reply/for_inner_create', user_id=user_id, topic_id=topic_id, content=content, replied_id=replied_id)
if error:
return self.error(error)
return self.ok(data=data)
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment