One of your ideas has been delivered from your suggestion.Grid View for Top Answers Widget on CP page

This feature provides option to have the CP items (answers) in the Top Answers Widget to be displayed in the Grid layout rather than a list (default). For the same, an image must be attached to the answer that can be used as a thumbnail on the matrix layout as shown below. In absence of image, a default image is used. (more details under steps to enable).

Customer Portal Popular Answers Widget

Customer Portal Popular Answers Widget

Business Value:

This enhancement brings an enhanced look and feel to end user pages making them more friendly and improving interaction.

Steps to Enable

Configuration required on Customer Portal:

The following configuration is required to be done on the CP page by the customer if the widget output is to be displayed as grid.

  1. For TopAnswers widget, edit the widget code in the home page i.e. cp/customer/development/views/pages/home.php to add the relevant attributes
  2. There are new attributes that are introduced for this widget to support the display in the form of grid. These are:
    1. view_type - determines how the output of the TopAnswers are displayed. The default value is 'list'. It can be set to 'grid' to have the output display in the grid layout.

    2. grid_default_img_name - specifies the name of the default image that users should add to answer in order for it to be displayed as image in the grid view. The image should be stored in the value specified by the 'image_path' attribute. The default value is 'default.png'.

    3. grid_thumbnail_img_name - defines the naming pattern for thumbnail images. If an uploaded image's name ends with the specified value (e.g., 

      thumbnailicon), it will be displayed as a thumbnail in the grid view. If multiple images match this pattern, the most recent one will be used.

    4. image_path - determines the location where the default image is stored.

    5. grid_num_of_rows - indicates the number of rows configured for the grid layout.

    6. grid_num_of_columns - indicates the number of columns configured for the grid layout.

    7. grid_row_col_limit - indicates the max of number of rows and columns that can be displayed in the grid layout. Maximum value for this is 3.

  3. For e.g. the default widget code,
                     <rn:widget path="reports/TopAnswers" show_excerpt="true" limit="5"/>
    can be changed to
                      <rn:widget path="reports/TopAnswers" view_type="grid"  grid_num_of_rows="2" grid_thumbnail_img_name="thumbnail" grid_num_of_columns="3" grid_row_col_limit="3"/>
    to have the output of TopAnswers widget displayed as grid (2*3) in the app/home page .



Tips And Considerations

  • Please note that the enhancement is only available for HTML type answers.
  • This feature requires an upgrade to 25B.