charles-vdulac / django-roa

Fork of original Django ROA lib. Now ROA works directly with an API like Django Rest Framework
BSD 3-Clause "New" or "Revised" License
51 stars 25 forks source link

Include ROA headers on GET (.save_base) and DELETE (.delete) #17

Closed jathanism closed 10 years ago

jathanism commented 10 years ago

This replaces the hard-coded GET argument of format with the mapped argument name from settings.ROA_ARGS_NAMES_MAPPING, but still defaults to format if a mapping for that argument is not found. This is important if the remote service does not accept a ?format= argument and has a different one.

This also make all of the resource calls consistent when saving or deleting objects, to include the ROA headers on resource.get() calls made within django_roa.db.models.ROAModel.save_base(), and on resource.delete() calls made within django_roa.db.models.ROAModel.delete().

I took the liberty of versioning this commit as 1.7.2 inside of setup.py.

charles-vdulac commented 10 years ago

I've just merge your branch on develop, but I set the version number to 1.8 (in order to respect guidelines of CHANGELOG file).

I'm waiting for your second request before to push your commits to master.

Thanks !

jathanism commented 10 years ago

Awesome, I have great excitement! :) Thanks.