Switches back to absolute wagtail_personalisation imports.
This commit is contained in:
@ -4,9 +4,9 @@ from django.conf import settings
|
|||||||
from django.db.models import F
|
from django.db.models import F
|
||||||
from django.utils.module_loading import import_string
|
from django.utils.module_loading import import_string
|
||||||
|
|
||||||
from .models import Segment
|
from wagtail_personalisation.models import Segment
|
||||||
from .rules import AbstractBaseRule
|
from wagtail_personalisation.rules import AbstractBaseRule
|
||||||
from .utils import create_segment_dictionary
|
from wagtail_personalisation.utils import create_segment_dictionary
|
||||||
|
|
||||||
|
|
||||||
class BaseSegmentsAdapter(object):
|
class BaseSegmentsAdapter(object):
|
||||||
|
@ -2,7 +2,7 @@ from __future__ import absolute_import, unicode_literals
|
|||||||
|
|
||||||
from django.contrib import admin
|
from django.contrib import admin
|
||||||
|
|
||||||
from . import models, rules
|
from wagtail_personalisation import models, rules
|
||||||
|
|
||||||
|
|
||||||
class UserIsLoggedInRuleAdminInline(admin.TabularInline):
|
class UserIsLoggedInRuleAdminInline(admin.TabularInline):
|
||||||
|
@ -2,7 +2,7 @@ from __future__ import absolute_import, unicode_literals
|
|||||||
|
|
||||||
from django.conf.urls import url
|
from django.conf.urls import url
|
||||||
|
|
||||||
from . import views
|
from wagtail_personalisation import views
|
||||||
|
|
||||||
app_name = 'segment'
|
app_name = 'segment'
|
||||||
|
|
||||||
|
@ -3,8 +3,8 @@ from __future__ import absolute_import, unicode_literals
|
|||||||
from django.utils.translation import ugettext_lazy as _
|
from django.utils.translation import ugettext_lazy as _
|
||||||
from wagtail.wagtailcore import blocks
|
from wagtail.wagtailcore import blocks
|
||||||
|
|
||||||
from .adapters import get_segment_adapter
|
from wagtail_personalisation.adapters import get_segment_adapter
|
||||||
from .models import Segment
|
from wagtail_personalisation.models import Segment
|
||||||
|
|
||||||
|
|
||||||
def list_segment_choices():
|
def list_segment_choices():
|
||||||
|
@ -11,9 +11,9 @@ from wagtail.wagtailadmin.edit_handlers import (
|
|||||||
FieldPanel, FieldRowPanel, InlinePanel, MultiFieldPanel, ObjectList,
|
FieldPanel, FieldRowPanel, InlinePanel, MultiFieldPanel, ObjectList,
|
||||||
PageChooserPanel, TabbedInterface)
|
PageChooserPanel, TabbedInterface)
|
||||||
|
|
||||||
from .forms import AdminPersonalisablePageForm
|
from wagtail_personalisation.forms import AdminPersonalisablePageForm
|
||||||
from .rules import AbstractBaseRule
|
from wagtail_personalisation.rules import AbstractBaseRule
|
||||||
from .utils import count_active_days
|
from wagtail_personalisation.utils import count_active_days
|
||||||
|
|
||||||
|
|
||||||
class SegmentQuerySet(models.QuerySet):
|
class SegmentQuerySet(models.QuerySet):
|
||||||
|
@ -10,10 +10,10 @@ from wagtail.wagtailadmin.site_summary import SummaryItem
|
|||||||
from wagtail.wagtailadmin.widgets import Button, ButtonWithDropdownFromHook
|
from wagtail.wagtailadmin.widgets import Button, ButtonWithDropdownFromHook
|
||||||
from wagtail.wagtailcore import hooks
|
from wagtail.wagtailcore import hooks
|
||||||
|
|
||||||
from . import admin_urls
|
from wagtail_personalisation import admin_urls
|
||||||
from .adapters import get_segment_adapter
|
from wagtail_personalisation.adapters import get_segment_adapter
|
||||||
from .models import PersonalisablePageMixin, Segment
|
from wagtail_personalisation.models import PersonalisablePageMixin, Segment
|
||||||
from .utils import impersonate_other_page
|
from wagtail_personalisation.utils import impersonate_other_page
|
||||||
|
|
||||||
logger = logging.getLogger(__name__)
|
logger = logging.getLogger(__name__)
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user