1
0
mirror of https://github.com/django/django.git synced 2025-10-31 09:41:08 +00:00

Stopped adapting DecimalField values to strings on PostgreSQL.

The psycopg2 backend uses the type information to provide type hints.
This commit is contained in:
Simon Charette
2019-10-08 09:23:07 -04:00
committed by Mariusz Felisiak
parent f783a99072
commit 9c5c9bd709
2 changed files with 7 additions and 4 deletions

View File

@@ -257,6 +257,9 @@ class DatabaseOperations(BaseDatabaseOperations):
def adapt_timefield_value(self, value):
return value
def adapt_decimalfield_value(self, value, max_digits=None, decimal_places=None):
return value
def adapt_ipaddressfield_value(self, value):
if value:
return Inet(value)