Пример #1
0
 def __init__(self):
     self.title = "Unglue.it Catalog:  Books under Active Campaign"
     self.feed_path = "active_campaigns"
     self.works = models.Work.objects.filter(campaigns__status='ACTIVE',
                                             is_free=True)
     self.description = "With your help we're raising money to make these books free to the world."
     self.facet_object = facets.get_facet_object(self.feed_path)
Пример #2
0
 def __init__(self):
     self.title = "Unglue.it Catalog:  Creative Commons Books"
     self.feed_path = "creative_commons"
     self.works = models.Work.objects.filter(
         editions__ebooks__isnull=False,
         editions__ebooks__rights__in=cc.LICENSE_LIST).distinct()
     self.description = "These Creative Commons licensed ebooks are free to read - the people who created them want you to read and share them."
     self.facet_object = facets.get_facet_object(self.feed_path)
Пример #3
0
 def __init__(self, facet_path=facet_path):
     self.feed_path = facet_path
     self.facet_object = facets.get_facet_object(facet_path)
     self.title = "Unglue.it"
     for facet in self.facet_object.facets():
         self.title = self.title + " " + facet.title
     self.works = self.facet_object.get_query_set().distinct()
     self.description = self.facet_object.description