Christopher Glass
a5a517532f
Added Germán to AUTHORS.rst
...
Thanks a lot for your contribution
2011-12-20 19:01:13 +00:00
German M. Bravo
f987818fe4
PEP 8 cleaning
...
Conflicts:
polymorphic/__init__.py
polymorphic/polymorphic_model.py
2011-12-20 18:59:50 +00:00
German M. Bravo
c9922d8987
PEP 8 cleaning
2011-12-20 18:59:50 +00:00
German M. Bravo
bb06d6d12b
Some more PEP 8 cleaning
2011-12-20 18:59:25 +00:00
Christopher Glass
741abf4228
Cleanup AUTHORS.rst
2011-12-20 18:56:37 +00:00
Chris Glass
11daac4fef
Merge pull request #3 from mbrochh/dont_use_attrs
...
Not using attrs when getting the first user defined manager.
2011-12-20 10:53:00 -08:00
Christopher Glass
ce97087f78
Started cleaning up
...
Now that the line was drawn, it's time for cleanups and improvements.
2011-12-20 18:51:05 +00:00
Christopher Glass
60813621a1
Drew the line between legacy and new code.
...
Since the original author disappeared, this commit marks the line between what
he did and what enhancements we (the community of maintainers) bring to the
project.
2011-12-20 18:49:20 +00:00
Martin Brochhaus
dfc8eff1e1
Not using attrs when getting the first user defined manager.
2011-12-09 15:22:38 +08:00
Chris Glass
227810c49f
Removed homepage URL from python packaging (this broke pip, as usual)
2011-08-02 14:18:04 +02:00
Chris Glass
c7cbfc0e23
Removed dead imports.
2011-05-19 15:16:39 +02:00
Jonas Obrist
10b8901088
Edited polymorphic/showfields.py via GitHub
2011-05-19 06:08:39 -07:00
Jonas Obrist
30f11a35d7
Edited polymorphic/query_translate.py via GitHub
2011-05-19 06:07:25 -07:00
Jonas Obrist
6f8e31222d
PEP-8, it's a thing!
2011-05-19 06:05:49 -07:00
Jonas Obrist
ba2cb60c9d
Edited polymorphic/polymorphic_model.py via GitHub
2011-05-19 06:04:23 -07:00
Jonas Obrist
fabae70ed4
protip: after a colon in python, HIT THE ENTER KEY!
2011-05-19 06:02:53 -07:00
Jonas Obrist
f42c58c0d4
it's python, not javascript!
2011-05-19 06:01:07 -07:00
Chris Glass
7b49fd133f
Added packaging stuff to gitignore, created MANIFEST include (to ship the
...
license and docs etc...)
2011-04-27 11:20:34 +02:00
Chris Glass
000d480dfb
Fixed typo
2011-04-27 11:11:31 +02:00
Chris Glass
74a21efb17
Changed setup.py: Added maintainer field (me), and classifiers
2011-04-27 11:10:06 +02:00
Chris Glass
a0f1fe455a
Added stuff to gitignore
2011-04-27 11:09:54 +02:00
Bert Constantin
2c47db8fcc
Fixed github issue 15 (query result incomplete with inheritance). Thanks to John Debs.
2011-01-24 17:03:23 +01:00
Bert Constantin
3cc7d483c1
minor additions in base.py
2011-01-24 16:45:58 +01:00
Bert Constantin
4a4cfd82a2
translate_polymorphic_Q_object: fixed test case, and made the function a member of PolymorphicObject.
...
Minor test fixes: warnings fixed, test_tool.py renamed as it's no test
2010-11-12 07:19:23 +01:00
Bert Constantin
ca329ff9b4
docs
2010-11-11 17:11:01 +01:00
Bert Constantin
748d10d2d5
docs
2010-11-05 22:24:07 +01:00
Bert Constantin
f78b27dc1a
updated docs, tests, misc
2010-11-02 12:21:46 +01:00
Bert Constantin
52f32c1fc3
improved showfields.py for better and more precise output, updated tests
2010-11-02 12:21:46 +01:00
Bert Constantin
a4ac6cc91d
fix object retrieval problem occuring with some custom primary key fields
...
+ added UUIDField as test case
2010-11-02 12:21:22 +01:00
Bert Constantin
6befe6c733
added "queryset.get_real_instances()" usage, added testcase
2010-11-02 12:10:02 +01:00
Bert Constantin
8c3df56cb6
non_polymorphic() queryset member function added
2010-10-23 12:22:13 +02:00
Bert Constantin
19adbdaf2c
extra(): Re-implemented. Now is polymorphic (nearly) without restrictions.
...
Added test cases + docs.
2010-10-23 11:52:04 +02:00
Bert Constantin
6c8d28cbbc
extra(): throw error if unsupported argument is encountered, support 'params' argument, special case Django 1.1
2010-10-22 13:37:26 +02:00
Abel Daniel
486a579ac7
Make .extra() only disable polymorphic query if an arg that is currently
...
not handled is actually used. I.e. if all args are supported, then
do polymorphic query by default.
2010-10-22 13:35:50 +02:00
Bert Constantin
b2357592cb
make sure 'base_manager is not inherited (but managed by Django instead).
...
(This seems more correct but it doen't seem to make any difference.)
Also added related test cases.
2010-10-22 13:35:39 +02:00
Bert Constantin
6628145af7
removed __getattribute__ hack from PolymorphicModel.
...
A somewhat cleaner solution is now used (through __init__) which
also completely removes the performance impact of __getattribute__.
2010-10-20 09:31:42 +02:00
Bert Constantin
a87481b8b5
polymorphic_dumpdata management command functionality removed;
...
the regular Django dumpdata command now automatically works correctly
for polymorphic models and all Django versions
(this is handled by PolymorphicModelBase now).
Testing for dumpdata has been added.
2010-10-20 09:31:42 +02:00
Bert Constantin
f05b854a54
make PolymorphicQuerySet.get_real_instances() an official part of the API
2010-10-20 09:31:42 +02:00
Bert Constantin
b1905026bc
Documentation updated.
...
Test_all_versions script added.
Some minor misc changes.
Added polybench.
2010-10-20 09:31:36 +02:00
Bert Constantin
c10ff1650b
added translate_polymorphic_Q_object
2010-10-19 21:28:33 +02:00
Bert Constantin
01bdb2f9b0
- renamed ShowField* to ShowFieldType, ShowFieldContent, ShowFieldTypeAndContent, in order to reflect better what they do.
...
- by default, django_polymorphic's pretty printing of querysets/objects (via ShowField*) is not used anymore
- ShowField mixins now also show the annotations (after the regular fields, prepended by "Ann:")
- cleaned up implementation.
2010-10-19 21:28:33 +02:00
mathieusteele
50b54f5aca
removed requirement for primary key to be an IntegerField.
2010-10-14 19:14:58 -07:00
Bert Constantin
116e2af08b
IMPORTANT: import path changed, it's now: "from polymorphic import PolymorphicModel, ..."
...
- added python2.4 compatibility. Contributed by Charles Leifer. Thanks!
- general reorganization of the code - there is no single polymorphic.py module anymore,
so d-p now needs to be installed as a regular Django app
- polymorphic.VERSION/get_version added
- version numbering started: V0.5 beta
2010-02-22 16:16:00 +01:00
Bert Constantin
e6c1e7ec6e
fix "...has no attribute 'sub_and_superclass_dict'". Thanks to Mattias Brändström.
...
this occurred if a subclass defined __init__ and accessed class
members before calling the superclass __init__
(__getattribute__ had a problem, as "sub_and_superclass_dict" was set in __init__).
2010-02-18 20:18:49 +01:00
Bert Constantin
7e584632b8
fix unnecessary field-name/model-name conflicts (i.e. field_name == model_name.lower() )
...
=> __init__ + __getattribute__ now handle only the Django inheritance
references that are needed ('modela_ptr', 'modelc' etc.), avoiding
unnecessary conflicts with field names.
2010-02-18 20:05:17 +01:00
Bert Constantin
2795f7acd5
some doc + minor code updates (__repr__ + Show... mixins)
2010-02-18 20:04:38 +01:00
Bert Constantin
2fcb7fba1a
queryset order_by method added, testcase, docs
2010-02-04 16:38:58 +01:00
Bert Constantin
b4aeae417e
queryset values(), values_list(), distinct() documented; defer(), only() allowed (but not yet supported)
2010-02-04 16:14:10 +01:00
Bert Constantin
cf42a8111b
setup.py added. Thanks to Andrew Ingram.
2010-02-04 15:28:56 +01:00
Bert Constantin
c10577c32f
queryset aggregate() and extra() methods implemented, testcases, docs
2010-02-04 15:28:55 +01:00