refactor to abstract models #58

Closed
django-mptt opened this Issue Dec 19, 2010 · 8 comments

Comments

Projects
None yet
1 participant
@ghost
Collaborator

ghost commented Dec 19, 2010

Originally GC 34

refactor django-mptt to be a set of abstract models that can be extended.
I think this would be a more elegant solution thant the current monkey
patching.

@ghost

This comment has been minimized.

Show comment Hide comment
@ghost

ghost Dec 19, 2010

Collaborator

insin (12 Oct 08):

I've not looked into abstract models at all yet, but they're definitely the approach
I'd rather take if possible.

Collaborator

ghost commented Dec 19, 2010

insin (12 Oct 08):

I've not looked into abstract models at all yet, but they're definitely the approach
I'd rather take if possible.

@ghost

This comment has been minimized.

Show comment Hide comment
@ghost

ghost Dec 19, 2010

Collaborator

mocksoul (06 Dec 08):

Yep, this is good idea. Also I want mptt to attach methods on model instances like
Model.mptt.is_root(), not Model.is_root(). For clearer code and stability (avoid
name collisions in large projects).

Collaborator

ghost commented Dec 19, 2010

mocksoul (06 Dec 08):

Yep, this is good idea. Also I want mptt to attach methods on model instances like
Model.mptt.is_root(), not Model.is_root(). For clearer code and stability (avoid
name collisions in large projects).

@ghost

This comment has been minimized.

Show comment Hide comment
@ghost

ghost Dec 19, 2010

Collaborator

craigds (02 Sep 10):

I'm definitely +1 for this. Will either be 0.4 or 0.5

Collaborator

ghost commented Dec 19, 2010

craigds (02 Sep 10):

I'm definitely +1 for this. Will either be 0.4 or 0.5

@ghost

This comment has been minimized.

Show comment Hide comment
@ghost

ghost Dec 19, 2010

Collaborator

craigds (12 Sep 10):

Created a branch for this: http://github.com/django-mptt/django-mptt/tree/abstract-models-refactor

This is a major refactor, may not be sane anytime soon.

Collaborator

ghost commented Dec 19, 2010

craigds (12 Sep 10):

Created a branch for this: http://github.com/django-mptt/django-mptt/tree/abstract-models-refactor

This is a major refactor, may not be sane anytime soon.

@ghost

This comment has been minimized.

Show comment Hide comment
@ghost

ghost Dec 19, 2010

Collaborator

craigds (18 Sep 10):

All the tests now pass on the new branch. Backwards incompatible changes:

  • mptt.register() has been removed
  • Field names and order_insertion_by are now specified via a MPTTMeta inner class
Collaborator

ghost commented Dec 19, 2010

craigds (18 Sep 10):

All the tests now pass on the new branch. Backwards incompatible changes:

  • mptt.register() has been removed
  • Field names and order_insertion_by are now specified via a MPTTMeta inner class
@ghost

This comment has been minimized.

Show comment Hide comment
@ghost

ghost Dec 19, 2010

Collaborator

craigds (20 Sep 10):

Issue 52 has been merged into this issue.

Collaborator

ghost commented Dec 19, 2010

craigds (20 Sep 10):

Issue 52 has been merged into this issue.

@ghost

This comment has been minimized.

Show comment Hide comment
@ghost

ghost Dec 19, 2010

Collaborator

craigds (23 Sep 10):

Merged to master in [http://github.com/django-mptt/django-mptt/commit/a7876509f4cbc35b25a76abd860e10eb6ac7ed11 a787650]

Collaborator

ghost commented Dec 19, 2010

craigds (23 Sep 10):

Merged to master in [http://github.com/django-mptt/django-mptt/commit/a7876509f4cbc35b25a76abd860e10eb6ac7ed11 a787650]

@ghost

This comment has been minimized.

Show comment Hide comment
@ghost

ghost Dec 19, 2010

Collaborator

craigds (27 Sep 10):

Some discussion in FeinCMS project, around using multiple inheritance for MPTTModel subclasses:

http://github.com/matthiask/feincms/issues/#issue/105

Collaborator

ghost commented Dec 19, 2010

craigds (27 Sep 10):

Some discussion in FeinCMS project, around using multiple inheritance for MPTTModel subclasses:

http://github.com/matthiask/feincms/issues/#issue/105

This issue was closed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment