Uploaded image for project: 'Blog Application'
  1. Blog Application
  2. BLOG-9

Implement the BlogPostList Macro

    XMLWordPrintable

Details

    • Improvement
    • Resolution: Fixed
    • Major
    • 9.4-milestone-1
    • 9.3.1
    • None

    Description

      The BlogPostMacro will be used to search and display blog posts based on some parameters, the results can be displayed using customizable templates.

      The macro have the following parameters:
      blog: The  descriptor document of a given blog, it should contain a document with a Blog.BlogClass object (not mandatory, at least blog or category mandatory)
      category : either a given category or a category space (not mandatory, at least blog or category mandatory)
      year : limit post to a given year
      month : limit post to a given month
      published : (yes), no, all
      hidden : (no), yes, all
      limit : number of post to display
      paginated: yes, (no), if yes paginate the results of the blogpostlist macro. If the 'blog' parameter is set and the 'limit' parameter is not set the macro will get the number of posts per page from the blog descriptor object.

      layout: The name of the macro that will be used to display the results. The default layout is the 'link' macro that is used to display the posts as links.
      The layout macro have a parameter 'reference' that contains the document full name of the post to display.
      The naming convention for the layout macros is: "BlogPostLayout${macroName}"

      The other layout available is the 'full' layout (BlogPostLayoutFull macro), It is possible to specify additional parameters for the 'full' layout, using the layutParams parameter of the blogpostlist macro

      layoutParams: Additional parameters of the blog post layout.
      This parameters is used to specify additional parameters for the 'full' layout, the parameters are represented with a string, as follow: "layoutParamName1=layoutParamValue1|...|layoutParamNameN=layoutParamValueN|"
      The layout parameters supported by the full layout macro are:

      • DisplayTitle: if true display the title of the blog post
      • useSummary: if true the summary of the post is dislayed (if the summary is empty then the post content is displayed)
      • displayCalendar: if true display the blog post with the calendar as it is in the default version of the blog app
      • displayImage: if true an image is displayed with the blog post instead of the calendar
      • displayActions: if true the blog action buttons are dispayed

      Below an example on how to use the blogPostList macro

      {{blogpostlist blog="aBlogSpace.WebHome" published="yes" paginated="yes" layout="full" layoutParams="displayTitle=true|displayImage=true|displayActions=false"/}}
      

      Attachments

        Issue Links

          Activity

            People

              mouhb Mohamed Boussaa
              mouhb Mohamed Boussaa
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: