Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Django-Rest_framework Example #67

Open
klahnen opened this issue Oct 14, 2015 · 3 comments
Open

Django-Rest_framework Example #67

klahnen opened this issue Oct 14, 2015 · 3 comments

Comments

@klahnen
Copy link

klahnen commented Oct 14, 2015

Hi,

I would like to know if its possible to add an example using one DRF.

Example ( http://www.django-rest-framework.org/api-guide/parsers/#fileuploadparser )

Basic usage example:

class FileUploadView(views.APIView):
    parser_classes = (FileUploadParser,)

    def put(self, request, filename, format=None):
        file_obj = request.data['file']
        # ...
        # do some stuff with data-importer
        # ...
        return Response(status=204) # If data-importer succeeds on save.
@valdergallo
Copy link
Owner

Hi, klahnen
Amazing, idea !!!

Could you send me one pull request with changes that you need ? If not I'll make some examples in my free time.

@klahnen
Copy link
Author

klahnen commented Oct 14, 2015

Hey valdergallo,

I will work on that and if you agree I will be posting questions if I get stuck. Thanks for your time.

@valdergallo
Copy link
Owner

OK, no problem

tnx :D

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants