Commit 38493dc3 authored by 杨成林's avatar 杨成林

Merge branch 'ycl/fix' into 'test'

fix

See merge request alpha/sun!271
parents 558fa4c1 64007da9
......@@ -50,7 +50,7 @@ class PictorialUpdateOrCreate(APIView):
star_ids = json.loads(request.POST.get('star', '[]'))
pictorial_user_ids = json.loads(request.POST.get('pictorial_user_ids', '[]'))
collection_tag_ids = json.loads(request.POST.get('collection_tag_ids', '[]'))
pictorial_activity_id = request.POST.get('pictorial_activity_id', 0)
pictorial_activity_id = request.POST.get('pictorial_activity_id')
data = {
'name': request.POST.get('name', ''),
'description': request.POST.get('description', ''),
......@@ -65,7 +65,7 @@ class PictorialUpdateOrCreate(APIView):
'add_score': int(request.POST.get('add_score', 0)),
'is_public': True if request.POST.get('is_public') == "true" else False,
'is_feed': int(request.POST.get('is_feed', 0)),
'pictorial_activity_ids': [int(pictorial_activity_id)],
'pictorial_activity_ids': [int(pictorial_activity_id)] if pictorial_activity_id else [],
'alias': request.POST.get('alias', ''),
}
......
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