mirror of
https://github.com/django/django.git
synced 2025-07-23 05:05:17 +00:00
Fixed #24938 -- Added PostgreSQL trigram support.
This commit is contained in:
parent
d7334b405f
commit
1962a96a30
11 changed files with 184 additions and 4 deletions
|
@ -5,12 +5,13 @@ from django.db import migrations
|
|||
|
||||
try:
|
||||
from django.contrib.postgres.operations import (
|
||||
CreateExtension, HStoreExtension, UnaccentExtension,
|
||||
CreateExtension, HStoreExtension, TrigramExtension, UnaccentExtension,
|
||||
)
|
||||
except ImportError:
|
||||
from django.test import mock
|
||||
CreateExtension = mock.Mock()
|
||||
HStoreExtension = mock.Mock()
|
||||
TrigramExtension = mock.Mock()
|
||||
UnaccentExtension = mock.Mock()
|
||||
|
||||
|
||||
|
@ -21,5 +22,6 @@ class Migration(migrations.Migration):
|
|||
# dash in its name.
|
||||
CreateExtension('uuid-ossp'),
|
||||
HStoreExtension(),
|
||||
TrigramExtension(),
|
||||
UnaccentExtension(),
|
||||
]
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue