Compare commits
12 Commits
Author | SHA1 | Date | |
---|---|---|---|
414afa5269 | |||
b3f0ac2d58 | |||
4f9c18d2cf | |||
a4a283e4f3 | |||
30318549e2 | |||
f19de241b0 | |||
95ecd8d200 | |||
6436b85b1d | |||
06471248d3 | |||
e3df03f559 | |||
0a42ce3eeb | |||
e5068894c3 |
@ -4,9 +4,8 @@ language: python
|
||||
|
||||
matrix:
|
||||
include:
|
||||
# Django 1.9, Wagtail 1.9
|
||||
- python: 2.7
|
||||
env: TOXENV=py27-django19-wagtail19
|
||||
env: TOXENV=py27-django111-wagtail113
|
||||
|
||||
install:
|
||||
- pip install tox codecov
|
||||
|
@ -55,10 +55,10 @@ author = 'Lab Digital BV'
|
||||
# built documents.
|
||||
#
|
||||
# The short X.Y version.
|
||||
version = '0.10.1'
|
||||
version = '0.10.3'
|
||||
|
||||
# The full version, including alpha/beta/rc tags.
|
||||
release = '0.10.1'
|
||||
release = '0.10.3'
|
||||
|
||||
# The language for content autogenerated by Sphinx. Refer to documentation
|
||||
# for a list of supported languages.
|
||||
|
@ -1,5 +1,5 @@
|
||||
[bumpversion]
|
||||
current_version = 0.10.1
|
||||
current_version = 0.10.3
|
||||
commit = true
|
||||
tag = true
|
||||
tag_name = {new_version}
|
||||
|
4
setup.py
4
setup.py
@ -2,7 +2,7 @@ import re
|
||||
from setuptools import find_packages, setup
|
||||
|
||||
install_requires = [
|
||||
'wagtail>=1.9,<1.11',
|
||||
'wagtail>=1.10,<1.14',
|
||||
'user-agents>=1.0.1',
|
||||
'wagtailfontawesome>=1.0.6',
|
||||
]
|
||||
@ -32,7 +32,7 @@ with open('README.rst') as fh:
|
||||
|
||||
setup(
|
||||
name='wagtail-personalisation-molo',
|
||||
version='0.10.1',
|
||||
version='0.10.3',
|
||||
description='A forked version of Wagtail add-on for showing personalized content',
|
||||
author='Praekelt.org',
|
||||
author_email='dev@praekeltfoundation.org',
|
||||
|
@ -133,12 +133,13 @@ class SessionSegmentsAdapter(BaseSegmentsAdapter):
|
||||
if page_visits:
|
||||
for page_visit in page_visits:
|
||||
page_visit['count'] += 1
|
||||
page_visit['path'] = page.url_path if page else self.request.path
|
||||
self.request.session.modified = True
|
||||
else:
|
||||
visit_count.append({
|
||||
'slug': page.slug,
|
||||
'id': page.pk,
|
||||
'path': self.request.path,
|
||||
'path': page.url_path if page else self.request.path,
|
||||
'count': 1,
|
||||
})
|
||||
|
||||
|
@ -22,7 +22,7 @@
|
||||
<div class="nice-padding block_container">
|
||||
{% if all_count %}
|
||||
{% for segment in object_list %}
|
||||
<div class="block block--{{ segment.status }}" onclick="location.href = 'edit/{{ segment.pk }}'">
|
||||
<div class="block block--{{ segment.status }}" onclick="location.href = '{% url 'wagtail_personalisation_segment_modeladmin_edit' segment.pk %}'">
|
||||
<h2>{{ segment }}</h2>
|
||||
<div class="inspect_container">
|
||||
<ul class="inspect segment_stats">
|
||||
@ -90,7 +90,7 @@
|
||||
{% elif segment.status == segment.STATUS_ENABLED %}
|
||||
<li><a href="{% url 'segment:toggle' segment.pk %}" title="{% trans "Disable this segment" %}">disable</a></li>
|
||||
{% endif %}
|
||||
<li><a href="edit/{{ segment.pk }}" title="{% trans "Configure this segment" %}">configure this</a></li>
|
||||
<li><a href="{% url 'wagtail_personalisation_segment_modeladmin_edit' segment.pk %}" title="{% trans "Configure this segment" %}">configure this</a></li>
|
||||
</ul>
|
||||
{% endif %}
|
||||
</div>
|
||||
|
7
tox.ini
7
tox.ini
@ -1,13 +1,12 @@
|
||||
[tox]
|
||||
envlist = py{27}-django{19}-wagtail{19},lint
|
||||
envlist = py{27}-django{111}-wagtail{113},lint
|
||||
|
||||
[testenv]
|
||||
commands = coverage run --parallel -m pytest {posargs}
|
||||
extras = test
|
||||
deps =
|
||||
django19: django>=1.9,<1.10
|
||||
wagtail19: wagtail>=1.9,<1.10
|
||||
wagtail110: wagtail>=1.10,<1.11
|
||||
django111: django>=1.11,<1.12
|
||||
wagtail19: wagtail>=1.13,<1.14
|
||||
|
||||
[testenv:coverage-report]
|
||||
basepython = python2.7
|
||||
|
Reference in New Issue
Block a user