Class NewsletterBlogService
java.lang.Object
fr.paris.lutece.plugins.newsletter.modules.blog.service.NewsletterBlogService
Newsletter blog service.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionfillTemplateWithDocumentInfos(Integer strTemplateFilekey, Collection<fr.paris.lutece.plugins.blog.business.Blog> listBlogs, Locale locale, String strBaseUrl, fr.paris.lutece.portal.business.user.AdminUser user) Fills a given document template (from an uploaded file) with the document data.fillTemplateWithDocumentInfos(String strTemplatePath, Collection<fr.paris.lutece.plugins.blog.business.Blog> listBlogs, Locale locale, String strBaseUrl, fr.paris.lutece.portal.business.user.AdminUser user) Fills a given document template with the document data.generateDocumentsList(NewsletterBlog newsletterDocument, int nTemplateId, Timestamp datePublishing, String strBaseUrl, fr.paris.lutece.portal.business.user.AdminUser user, Locale locale) Generate the html code for documents corresponding to the documents associated with the topic and to a given publishing datefr.paris.lutece.util.ReferenceListLoad the portlet of type BLOG_LIST.
-
Constructor Details
-
NewsletterBlogService
public NewsletterBlogService()
-
-
Method Details
-
generateDocumentsList
public String generateDocumentsList(NewsletterBlog newsletterDocument, int nTemplateId, Timestamp datePublishing, String strBaseUrl, fr.paris.lutece.portal.business.user.AdminUser user, Locale locale) Generate the html code for documents corresponding to the documents associated with the topic and to a given publishing date- Parameters:
newsletterDocument- the topic to generatenTemplateId- the document id to usedatePublishing- minimum date of publishing of documents. Documents published before this date will not be consideredstrBaseUrl- the url of the portaluser- The current admin userlocale- The locale- Returns:
- the html code for the document list of null if no document template available
-
fillTemplateWithDocumentInfos
public String fillTemplateWithDocumentInfos(String strTemplatePath, Collection<fr.paris.lutece.plugins.blog.business.Blog> listBlogs, Locale locale, String strBaseUrl, fr.paris.lutece.portal.business.user.AdminUser user) Fills a given document template with the document data.- Parameters:
strTemplatePath- The path of the template filelistBlogs- the object gathering the document datalocale- the locale used to build the templatestrBaseUrl- The base url of the portaluser- The current user- Returns:
- the html code corresponding to the document data
-
fillTemplateWithDocumentInfos
public String fillTemplateWithDocumentInfos(Integer strTemplateFilekey, Collection<fr.paris.lutece.plugins.blog.business.Blog> listBlogs, Locale locale, String strBaseUrl, fr.paris.lutece.portal.business.user.AdminUser user) Fills a given document template (from an uploaded file) with the document data.- Parameters:
strTemplateFilekey- The id of the template filelistBlogs- the object gathering the document datalocale- the locale used to build the templatestrBaseUrl- The base url of the portaluser- The current user- Returns:
- the html code corresponding to the document data
-
getPortletBlogList
public fr.paris.lutece.util.ReferenceList getPortletBlogList()Load the portlet of type BLOG_LIST.- Returns:
- the reference list of portlets of type BLOG_LIST
-