eventChannel

The ZohoSalesIQ.knowledgeBase.eventChannel holds events related to the resource operations.

Event keys:

PropertyDatatypeDescription
actionResourceActionAction performed on the resource. Events are listed below.
typeResourceTypeType of the resource
resourceResourceDetails of the resource that action 

RecourceAction Events:

EventsInvoked when
openedThe visitor opens a resource
closedThe visitor closes a resource
likedThe visitor likes a resource
dislikedThe visitor dislikes a resource

Syntax

CopiedZohoSalesIQ.knowledgeBase.eventChannel.listen((KnowledgeBaseEvent event) {

});

Example

CopiedZohoSalesIQ.knowledgeBase.eventChannel.listen((event) {
          switch (event.action) {
             case ResourceAction.opened:
                // your code to handle the event
                break;
             case ResourceAction.closed:
                // your code to handle the event
                break;
            case ResourceAction.liked:
                // your code to handle the event
                break;
            case ResourceAction.disliked:
                // your code to handle the event
                break;
          }
});