Changeset 2656 in products


Ignore:
Timestamp:
Jul 9, 2010 2:45:51 PM (14 years ago)
Author:
chervol
Message:

#27: Force blog_view accept additional query parameters

Location:
quintagroup.blog.star/trunk/quintagroup/blog/star
Files:
1 added
3 edited

Legend:

Unmodified
Added
Removed
  • quintagroup.blog.star/trunk/quintagroup/blog/star/browser/blog.py

    r2652 r2656  
    22from Products.CMFCore.utils import getToolByName 
    33from Products.CMFPlone.PloneBatch import Batch 
    4 from collective.blog.view.interfaces import IBlogEntryRetriever 
     4from quintagroup.blog.star.interfaces import IQGBlogEntryRetriever 
    55try: 
    66    from plone.app.discussion.interfaces import IConversation 
     
    2424        year = int(self.request.form.get('year',0)) 
    2525        month = int(self.request.form.get('month',0)) 
    26         return IBlogEntryRetriever(self.context).get_entries(year=year, month=month) 
     26        subject = list(self.request.form.get('Subject','')) 
     27        return IQGBlogEntryRetriever(self.context).get_entries( 
     28            year=year, month=month, Subject=subject) 
    2729 
    2830    def batch(self): 
  • quintagroup.blog.star/trunk/quintagroup/blog/star/configure.zcml

    r2639 r2656  
    1111  <include package=".browser" /> 
    1212 
    13   <genericsetup:registerProfile 
    14      name="default" 
    15      title="Quintagroup blog.star customization" 
    16      directory="profiles/default" 
    17      description="Generic setup for Quintagroup blogging" 
    18      provides="Products.GenericSetup.interfaces.EXTENSION" 
    19      /> 
     13  <adapter 
     14    factory=".adapters.FolderEntryGetter" 
     15    /> 
     16 
     17  <adapter 
     18    factory=".adapters.TopicEntryGetter" 
     19    /> 
     20 
    2021 
    2122  <genericsetup:registerProfile 
    22      name="uninstall" 
    23      title="Uninstall Quintagroup blog.star customization" 
    24      directory="profiles/uninstall" 
    25      description="Uninstall Quintagroup blogging" 
    26      provides="Products.GenericSetup.interfaces.EXTENSION" 
    27      /> 
     23    name="default" 
     24    title="Quintagroup blog.star customization" 
     25    directory="profiles/default" 
     26    description="Generic setup for Quintagroup blogging" 
     27    provides="Products.GenericSetup.interfaces.EXTENSION" 
     28    /> 
     29 
     30  <genericsetup:registerProfile 
     31    name="uninstall" 
     32    title="Uninstall Quintagroup blog.star customization" 
     33    directory="profiles/uninstall" 
     34    description="Uninstall Quintagroup blogging" 
     35    provides="Products.GenericSetup.interfaces.EXTENSION" 
     36    /> 
    2837 
    2938</configure> 
  • quintagroup.blog.star/trunk/quintagroup/blog/star/interfaces.py

    r2655 r2656  
    55    """Marker interface that defines a Zope 3 browser layer. 
    66    """ 
     7 
     8class IQGBlogEntryRetriever(interface.Interface): 
     9 
     10    def get_entries(year, month, **kw): 
     11        """Retrieves all blog entries as catalog brains. 
     12           with filtering by year, month and additional 
     13           catalog indexes. 
     14        """ 
Note: See TracChangeset for help on using the changeset viewer.