Hi everyone,
I setup a Customer Self-Service demo portal in order to enhance the knowledge on CRM Portal customization. Running over all the site functionalities I encountered some undocumented behaviours of the portal. If you have the possibility to access the demo I am talking about the Home of the WebSite (for those who cannot access the demo code I will cut and paste some WebTemplate LIQUID code). There are 3 sections on the Home WebPage which are related to the CRM KnowledgeArticle standard entity:
1. Most Popular Articles
2. Most Recent Articles
3. Top Rated Articles
these 3 sections are rendered each through a specific LIQUID WebTemplate, for each section this is the piece of code I would like to focus:
1. Most Popular Articles --> {% assign popular_articles = knowledge.articles | popular: count,languagecode %}
2. Most Recent Articles --> {% assign recent_articles = knowledge.articles | recent: count,languagecode %}
3. Top Rated Articles --> {% assign top_articles = knowledge.articles | top: count,languagecode %}
The undefined behavior are:
- Where is the knowledge class defined? I mean, on CRM there is an entity "knowledgearticles" but I didn't find a place for an association with the class "knowledge". LIQUID does not specify an object "knowledge" and the liquid reference (https://www.microsoft.com/en-us/dynamics/crm-setup-and-administration/entities.aspx) define a standard way to access an entity content i.e. "entities.account"
- Assuming knowledge.articles is the list of knowledgearticles stored on the CRM, its content is filtered through a specific function respectively : popular, recent, top. Neither of this function is defined in LIQUID, furthermore it seems there is no way to define custom functions. So my second question is, where are this functions defined? Is it possible to define custom functions for a generic entity?
Hope to finde some answer.
Thanks in Advance,
Paolo