NotificationManager::getIconClass PHP Method

getIconClass() public method

Return a CSS class containing the icon of this notification type
public getIconClass ( $notification ) : string
$notification Notification
return string
    function getIconClass($notification)
    {
        switch ($notification->getType()) {
            case NOTIFICATION_TYPE_PUBLISHED_ISSUE:
                return 'notifyIconPublished';
            case NOTIFICATION_TYPE_NEW_ANNOUNCEMENT:
                return 'notifyIconNewAnnouncement';
            case NOTIFICATION_TYPE_BOOK_REQUESTED:
            case NOTIFICATION_TYPE_BOOK_CREATED:
            case NOTIFICATION_TYPE_BOOK_UPDATED:
            case NOTIFICATION_TYPE_BOOK_DELETED:
            case NOTIFICATION_TYPE_BOOK_MAILED:
            case NOTIFICATION_TYPE_BOOK_SETTINGS_SAVED:
            case NOTIFICATION_TYPE_BOOK_SUBMISSION_ASSIGNED:
            case NOTIFICATION_TYPE_BOOK_AUTHOR_ASSIGNED:
            case NOTIFICATION_TYPE_BOOK_AUTHOR_DENIED:
            case NOTIFICATION_TYPE_BOOK_AUTHOR_REMOVED:
            case NOTIFICATION_TYPE_GIFT_REDEEM_STATUS_SUCCESS:
                return 'notifyIconSuccess';
            case NOTIFICATION_TYPE_GIFT_REDEEM_STATUS_ERROR_NO_GIFT_TO_REDEEM:
            case NOTIFICATION_TYPE_GIFT_REDEEM_STATUS_ERROR_GIFT_ALREADY_REDEEMED:
            case NOTIFICATION_TYPE_GIFT_REDEEM_STATUS_ERROR_GIFT_INVALID:
            case NOTIFICATION_TYPE_GIFT_REDEEM_STATUS_ERROR_SUBSCRIPTION_TYPE_INVALID:
            case NOTIFICATION_TYPE_GIFT_REDEEM_STATUS_ERROR_SUBSCRIPTION_NON_EXPIRING:
                return 'notifyIconError';
            default:
                return parent::getIconClass($notification);
        }
    }