Hi!
I have an application (Django-Tastypie-mongoengine) in which I am uploading
images to GridFS. With the previous version of tastypie and mongoengine was
working properly. As I was doing the following to upload:
*def upload (request, id):*
* Movie.objects movie = (id = id)*
* *
* if request.method == 'POST':*
* my_painting = Movie (id = id)*
* *
* files = []*
* request.FILES.getlist for f in ('file'):*
* mf = mongoengine.fields.GridFSProxy ()*
* mf.put (f, filename = f.name, legend = 'Hi')*
* files.append (mf)*
* my_painting.MovieCover = files*
* my_painting.save ()*
*
*
* return render_to_response ('upload.html', {},*
* context_instance = RequestContext (request))
*
The problem is that now I updated to the latest versions, and when I upload
the images, it deletes all my data, leaving only the images.
Does anyone know why?
What I have to change to get working properly?
--
You received this message because you are subscribed to the Google Groups
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/django-users.
For more options, visit https://groups.google.com/groups/opt_out.