rename qcombine.FakeModel to qcombine.GenericModel
This commit is contained in:
parent
47991dfa3d
commit
bae670e883
|
@ -126,7 +126,7 @@ class Manager(type):
|
|||
return qs
|
||||
|
||||
|
||||
class FakeModel(Routable,metaclass=Manager):
|
||||
class GenericModel(Routable,metaclass=Manager):
|
||||
"""
|
||||
This class is used to register a route for multiple models to a website.
|
||||
A QCombine is created with qs for all given models when objects
|
||||
|
|
|
@ -189,7 +189,7 @@ class SearchRoute(Route):
|
|||
@classmethod
|
||||
def get_queryset(cl, model, request, **kwargs):
|
||||
q = request.GET.get('q') or ''
|
||||
if issubclass(model, qcombine.FakeModel):
|
||||
if issubclass(model, qcombine.GenericModel):
|
||||
models = model.models
|
||||
return qcombine.QCombine(
|
||||
*(cl.__search(model, q) for model in models)
|
||||
|
|
4
notes.md
4
notes.md
|
@ -33,7 +33,7 @@
|
|||
- calendar
|
||||
- article list with the focus
|
||||
-> set html attribute based on values that are public
|
||||
- tags: allow tags_url route QCombine
|
||||
- rename qcombine.FakeModel -> GenericModel?
|
||||
|
||||
- website:
|
||||
- diffusions:
|
||||
|
@ -47,7 +47,7 @@
|
|||
- load complete week for a schedule?
|
||||
- finish that fucking website
|
||||
- list of played diffusions and tracks when non-stop;
|
||||
- search field -- section
|
||||
- search input in a section
|
||||
|
||||
|
||||
|
||||
|
|
|
@ -129,7 +129,7 @@ class Sound (cms.RelatedPost):
|
|||
)
|
||||
|
||||
|
||||
class Publications (qcombine.FakeModel):
|
||||
class Publications (qcombine.GenericModel):
|
||||
"""
|
||||
Combine views
|
||||
"""
|
||||
|
|
Loading…
Reference in New Issue
Block a user