Forum Discussion

fuenteso's avatar
fuenteso
Leader
10 years ago

Is there a way to use forums.widget.message-list-panel with API v2.0?

Hi!   I want to build a component to display topics from a user posted to some specific boards (each on different categories) and I would like to use "forums.widget.message-list-panel" to display t...
  • VarunGrazitti's avatar
    10 years ago

    fuenteso - There is no way to access the code of the OOB lithium components. One way is to override them but that wouldn't provide you with the code access either. So the only option is to build a custom component. An easier way would be to put these boards in one category and make a call at that category level :)

     

    I hope it helps.

  • DougS's avatar
    DougS
    9 years ago

    I wish I'd see this post sooner (a year too late it appears). You can use V2 calls that return a list of messages to the forums.widget.message-list-panel component -- just use the prefix rest_2.0: (instead of rest_v1:). For example:

     

    <#assign results_list_size = 5 />
    <#assign rest_query = "SELECT * FROM messages WHERE replies.count(*) = 0 AND depth = 0" />
    <@component id="forums.widget.message-list-panel" messages="rest_2.0:/search?q="+rest_query?url style="wide" numMessages="conv:"+results_list_size />

    -Doug