예제 #1
0
파일: views.py 프로젝트: ogonbat/chano
 def post(self, request,id, *args, **kwargs):
     file_image = Images()
     file_image.image = request.FILES['image']
     file_image.gallery = Images_Galleries.objects.get(pk=id)
     file_image.save()
     messages.success(request,_("Gallery Image Added"))
     return redirect('/admin/galleries/edit/%s'%id)
예제 #2
0
파일: views.py 프로젝트: ogonbat/chano
 def post(self, request, *args, **kwargs):
     file_image = Images()
     file_image.image = request.FILES['image']
     file_image.save()
     messages.success(request,_("Image Added"))
     return redirect('/admin/galleries/images')