Skip to content
This repository has been archived by the owner on Jan 18, 2020. It is now read-only.

Commit

Permalink
Merge pull request #22 from lucaswiman/django-1.8-support
Browse files Browse the repository at this point in the history
Django 1.8+ support
  • Loading branch information
bruth committed Dec 22, 2015
2 parents b6454a0 + 96b062e commit ba282f5
Show file tree
Hide file tree
Showing 18 changed files with 210 additions and 376 deletions.
12 changes: 2 additions & 10 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,21 +1,13 @@
language: python

python:
- 2.6
- 2.7

sudo: false

env:
- DJANGO=1.4.16
- DJANGO=1.5.11
- DJANGO=1.6.8
- DJANGO=1.7.1

matrix:
exclude:
- python: 2.6
env: DJANGO=1.7.1
- DJANGO=1.8.7
- DJANGO=1.9

before_install:
- bash bin/check_signoff.sh
Expand Down
6 changes: 3 additions & 3 deletions modeltree/__init__.py
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
__version_info__ = {
'major': 1,
'minor': 2,
'major': 2,
'minor': 0,
'micro': 0,
'releaselevel': 'beta',
'releaselevel': 'alpha',
'serial': 1
}

Expand Down
6 changes: 0 additions & 6 deletions modeltree/compat.py

This file was deleted.

6 changes: 1 addition & 5 deletions modeltree/managers.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
import django
from django.db import models
from modeltree.query import ModelTreeQuerySet

Expand All @@ -8,11 +7,8 @@ def __init__(self, tree=None, *args, **kwargs):
super(ModelTreeManager, self).__init__(*args, **kwargs)
self.tree = tree or self.model

def get_query_set(self):
def get_queryset(self):
return ModelTreeQuerySet(model=self.tree, using=self.db)

def select(self, *args, **kwargs):
if django.VERSION < (1, 6):
return self.get_query_set().select(*args, **kwargs)

return self.get_queryset().select(*args, **kwargs)
Loading

0 comments on commit ba282f5

Please sign in to comment.