mirror of
https://github.com/ansible/awx.git
synced 2026-03-04 02:01:01 -03:30
change JSONField to be a DB text type
This commit is contained in:
@@ -32,6 +32,9 @@ __all__ = ['AutoOneToOneField', 'ImplicitRoleField', 'JSONField']
|
|||||||
|
|
||||||
class JSONField(upstream_JSONField):
|
class JSONField(upstream_JSONField):
|
||||||
|
|
||||||
|
def db_type(self, connection):
|
||||||
|
return 'text'
|
||||||
|
|
||||||
def from_db_value(self, value, expression, connection, context):
|
def from_db_value(self, value, expression, connection, context):
|
||||||
if value in {'', None} and not self.null:
|
if value in {'', None} and not self.null:
|
||||||
return {}
|
return {}
|
||||||
|
|||||||
Reference in New Issue
Block a user