Commit Graph

6399 Commits

Author SHA1 Message Date
Prayag Verma
b24fb53d98 Update license year range to 2016 2016-01-18 12:28:24 +05:30
Xavier Ordoquy
db73833d13 Merge pull request #3835 from vyscond/patch-1
Update permissions.md
2016-01-15 15:48:24 +01:00
Ramon Moraes
a37a8748cc Update permissions.md
Adding additional note about the behavior of set permission classes per view as suggest on #3834
2016-01-15 11:44:25 -03:00
Xavier Ordoquy
30ef38c861 Merge pull request #3833 from bradmontgomery/patch-1
QueryParameterVersioning does not use default version
2016-01-14 20:33:05 +01:00
Brad Montgomery
40b5774a33 QueryParameterVersioning does not use default version
QueryParameterVersioning does not fall back to the value used in the `DEFAULT_VERSION` setting, while other versioning schemes do. This looks like a minor change, and incorporates the `self.default_version` set in the superclass.

I'll sheepishly admit that I edited this inline without running any tests or anything, so please let me know if this needs more work.
2016-01-14 12:00:30 -06:00
Tom Christie
2ce3ab59a6 Merge pull request #3746 from linovia/feature/display_internal_pytest_warnings
Display py.test internal warnings
2016-01-14 15:25:41 +00:00
Xavier Ordoquy
b76bf3d6d2 Merge pull request #3832 from atombrella/warnings_20_fkeys
Regarding #3729
2016-01-14 15:31:31 +01:00
Tom Christie
29f84aa4a3 Merge pull request #3831 from ticosax/doc-tweak-admin-authtoken
Document how to tweak authtoken.admin.TokenAdmin
2016-01-14 14:16:41 +00:00
Mads Jensen
215e1b6c6b Regarding #3729
python -Werror generates warnings informing that on_delete is a required keyword in Django 2.0
2016-01-14 15:14:33 +01:00
Nicolas Delaby
717e27c866 Document how to tweak authtoken.admin.TokenAdmin
With focus on large user base, but can be extended.
2016-01-14 14:59:31 +01:00
Tom Christie
01b1d100c5 Merge pull request #3826 from atombrella/copyright_update
2015 update in __init__.py file
2016-01-13 12:15:37 +00:00
Mads Jensen
a9c394f5b7 2015 update in __init__.py file 2016-01-13 12:54:56 +01:00
Tom Christie
1c5dfc9c8d Merge pull request #3821 from zwernberg/master
update copyright 2016
2016-01-11 16:25:11 +00:00
Zach Wernberg
04b2f021a6 update copyright 2016 2016-01-11 08:13:07 -06:00
Xavier Ordoquy
efe2c3739d Merge pull request #3809 from areski/fix-timefield
Fixed TimeField not handling empty values
2016-01-11 12:28:28 +01:00
areski
4e01796303 Test for TimeField not handling empty values 2016-01-11 12:16:26 +01:00
areski
a76c3ed051 Fixed TimeField not handling empty values 2016-01-11 12:14:40 +01:00
Xavier Ordoquy
edd9c7de02 Merge pull request #3819 from m1kola/bug/DateField-to_representation-unicode-compatibility
PY2: DateField.to_representation can't work with unicode value
2016-01-11 11:29:50 +01:00
Mikalai Radchuk
6b207d93d6 DateField.to_representation unicode compatibility 2016-01-11 13:11:01 +03:00
José Padilla
057cf13578 Merge pull request #3815 from atombrella/keys_dict_3786
Fixes #3786
2016-01-09 22:47:53 -04:00
Xavier Ordoquy
69fb34b0db Merge pull request #3810 from jerel/patch-1
Added documentation for the third party jsonapi.org package
2016-01-07 21:11:59 +01:00
Jerel Unruh
f71d8afdb0 Added documentation for the Third Party jsonapi.org package 2016-01-07 13:42:02 -06:00
Tom Christie
f01a3d9c36 Merge pull request #3801 from koordinates/fix-nested-validation-error
Fix nested validation error being rendered incorrectly.
2016-01-07 09:22:23 +00:00
Mads Jensen
d4cdb21de9 Fixes #3786
Minor fix for dictionary key lookup in settings file
2016-01-06 22:51:11 +01:00
Tom Christie
f7025cf5e5 Merge pull request #3805 from kewama/issue-3804
Fixes #3804, avoiding update of Meta.extra_kwargs
2016-01-06 20:25:00 +00:00
Kevin Massey
7cd3933144 Fixes #3804, avoiding update of Meta.extra_kwargs
Added unit test to cover.
2016-01-06 15:04:51 -05:00
Xavier Ordoquy
c46ed66d0a Merge pull request #3803 from m1kola/patch-1
Typo fix in docs/api-guide/relations.md
2016-01-06 16:02:16 +01:00
m1kola
5fa8a31855 Typo fix in docs/api-guide/relations.md
`slug field` in code snippet was replaced to `slug_field`
2016-01-06 17:58:45 +03:00
Craig de Stigter
651319e2da Fix nested validation error being rendered incorrectly.
Previously an extra list wrapped nested validation errors raised from serializer's validate() methods.
That was inconsistent with the format of validation errors raised by validate_<fieldname> methods.
i.e. these two resulted in *different* behaviour:

    def validate_foo(self):
        raise ValidationError(['bar'])

    def validate(self):
        raise ValidationError({'foo': ['bar']})
2016-01-06 16:05:43 +13:00
Tom Christie
37f7b76f72 Merge pull request #3785 from sheppard/authtoken-import
don't import authtoken model until needed
2016-01-05 17:28:48 +00:00
S. Andrew Sheppard
4f40714169 fix import order 2016-01-05 10:20:22 -06:00
S. Andrew Sheppard
2b8c036b48 test custom token model 2016-01-05 09:58:16 -06:00
S. Andrew Sheppard
1712c00001 update invalid token case 2016-01-05 09:42:22 -06:00
Xavier Ordoquy
dceb686700 Merge pull request #3774 from tomchristie/decimalfield_validators
Min/MaxValueValidator is no longer transferred from a model's DecimalField
2016-01-04 16:36:44 +01:00
Kevin Brown
a772326112 Merged two DecimalValidator tests together
These two tests were previously added in
7d79cf35b7
but we have now discovered that there are not actually two separate
cases, there was just a  bug in the code that made it look that way.

This also removes a redundant check to see if `DecimalValidator` was
defined.
2016-01-04 10:22:17 -05:00
Xavier Ordoquy
060444d89f Merge pull request #3791 from craigglennie/patch-1
Make code block consistent in serialization tutorial
2016-01-04 08:00:13 +01:00
craigglennie
2d7d3b79a0 Make code block consistent in serialization tutorial
All the other code blocks in the Serialization tutorial can be copied and pasted, but there is one that includes the >>> shell prompt characters. This commit removes those characters, and also makes the output consistent with other code blocks by making it a comment.
2016-01-02 13:15:25 -08:00
Xavier Ordoquy
dafbe65ff6 Merge pull request #3787 from Cheglader/issue_3636
Initial fixes #3636 and fixes #3637
2016-01-01 11:11:42 +01:00
Luis San Pablo
183f8fad44 Class formatting 2015-12-31 21:18:41 -06:00
Luis San Pablo
ef491685a0 Initial fixes #3636 and fixes #3637 2015-12-31 21:14:57 -06:00
S. Andrew Sheppard
ff29fdd875 don't import authtoken model until needed 2015-12-30 15:44:19 -06:00
Tom Christie
af0ea8ef51 Merge pull request #3771 from robromano/master
Add HTTP status code 451 to status.py
2015-12-29 09:59:48 +00:00
Kevin Brown
d797389cf7 Fixed broken test for Django < 1.9
This test was incorrectly checking that there were no validators set in
older versions of Django, even though it should have been checking for
the two validators that were set up on the model field level.

The originally regression test that this fixes was added in
7d79cf35b7
when fixing an issue with the `DecimalValidator`.
2015-12-24 18:17:58 -05:00
Kevin Brown
87605e1e39 Don't filter out the DecimalValidator if it is not supported
Previously, all validators set on a DecimalField in Django would be
stripped when converted to a Django REST framework field. This was
because any validator that was an instance of `DecimalValidator` would
be removed, and when `DecimalValidator` wasn't supported (so it was
`None`), all validators would be removed.

This fixes the issue by only removing the `DecimalValidator` instances
if the `DecimalValidator` is supported.
2015-12-24 14:10:48 -05:00
Kevin Brown
9bab640b0a Added tests for min_value and max_value on a DecimalField
This adds tests for a regression where the `min_value` and `max_value`
arguments are not being set for a DRF `DecimalField` even though the
corresponding `MinValueValidator` and `MaxValueValidator` is being set
on the model fields.

Note that this only appears to be a regression for Django < 1.9, as
these regression tests pass on newer versions of Django.
2015-12-24 14:00:49 -05:00
Robert Romano
c8915c0716 Change tab to spaces 2015-12-23 12:58:14 -08:00
Robert Romano
5fc938cbd1 The Internet Engineering Task Force approved the new HTTP status code 451. Adding to status.py and docs appropriately. 2015-12-23 12:54:17 -08:00
Tom Christie
2d27d9a10a Merge pull request #3769 from mlissner/master
Fixes #3756, adding the name to the HTML title, if it exists.
2015-12-23 16:58:29 +00:00
Michael Lissner
f15026be10 Fixes #3756, adding the name to the HTML title, if it exists. 2015-12-22 10:31:18 -08:00
José Padilla
503687d868 Merge pull request #3765 from linovia/feature/fix_guardian_for_dj_19
Update the Django-guardian version for Django 1.9
2015-12-21 16:59:03 -04:00