Class humhub\modules\stream\widgets\WallStreamFilterNavigation

Inheritancehumhub\modules\stream\widgets\WallStreamFilterNavigation » humhub\modules\ui\filter\widgets\FilterNavigation » humhub\widgets\JsWidget » humhub\components\Widget » yii\base\Widget
Available since version1.3

Predefines the default stream filters of a content stream.

The default stream filter navigation consists of three panels

and the following blocks and filters:

  • basic
    • filter_entry_userinvolved
    • filter_entry_mine
    • filter_entry_files
  • post
    • filter_model_posts
    • filter_posts_links
  • visibility
    • filter_visibility_public
    • filter_visibility_private
  • sorting
    • sorting_c
    • sorting_u
  • content type
    • filter_content_type
  • topics
    • filter_topic

which are holding the following

Public Methods

Hide inherited methods

MethodDescriptionDefined By
addFilter() Adds a Filter with given $filterId and filter definition to the filter block with the given $blockId. humhub\modules\ui\filter\widgets\FilterNavigation
addFilterBlock() Adds a new filter block to the given $panel. humhub\modules\ui\filter\widgets\FilterNavigation
filterOutEmptyPanels() humhub\modules\ui\filter\widgets\FilterNavigation
getAttributes() humhub\modules\stream\widgets\WallStreamFilterNavigation
getId() Returns the html id of this widget, if no id is set this function will generate an id if $autoGenerate is set to true (default). humhub\widgets\JsWidget
init() humhub\modules\ui\filter\widgets\FilterNavigation
initDefinitionFilters() Adds additional filters of the filter definition, which are not already part of the default filter setting. humhub\modules\ui\filter\widgets\FilterNavigation
isAllowedFilter() Checks if the given $filterId is allowed by the definition. humhub\modules\ui\filter\widgets\FilterNavigation
process() Process is a wrapper for the run method humhub\components\Widget
run() Default implementation of JsWidget. humhub\modules\ui\filter\widgets\FilterNavigation
setDefaultOptions() Sets some default data options required by all widgets as the widget implementation and the widget evetns and initialization trigger. humhub\widgets\JsWidget
widget() Creates a widget instance and runs it. humhub\components\Widget

Events

Hide inherited events

EventTypeDescriptionDefined By
EVENT_CREATE humhub\libs\WidgetCreateEvent An event raised before creating a widget. humhub\components\Widget

Constants

Hide inherited constants

ConstantValueDescriptionDefined By
FILTER_ARCHIVED 'entry_archived' humhub\modules\stream\widgets\WallStreamFilterNavigation
FILTER_BLOCK_BASIC 'basic' humhub\modules\stream\widgets\WallStreamFilterNavigation
FILTER_BLOCK_CONTENT_TYPE 'contentType' humhub\modules\stream\widgets\WallStreamFilterNavigation
FILTER_BLOCK_ORIGINATORS 'originators' humhub\modules\stream\widgets\WallStreamFilterNavigation
FILTER_BLOCK_SORTING 'sorting' humhub\modules\stream\widgets\WallStreamFilterNavigation
FILTER_BLOCK_TOPIC 'topics' humhub\modules\stream\widgets\WallStreamFilterNavigation
FILTER_BLOCK_VISIBILITY 'visibility' humhub\modules\stream\widgets\WallStreamFilterNavigation
FILTER_CONTENT_TYPE 'content_type' humhub\modules\stream\widgets\WallStreamFilterNavigation
FILTER_FILES 'entry_files' humhub\modules\stream\widgets\WallStreamFilterNavigation
FILTER_MINE 'entry_mine' humhub\modules\stream\widgets\WallStreamFilterNavigation
FILTER_ORIGINATORS 'originators' humhub\modules\stream\widgets\WallStreamFilterNavigation
FILTER_SORT_CREATION 'sort_creation' humhub\modules\stream\widgets\WallStreamFilterNavigation
FILTER_SORT_UPDATE 'sort_update' humhub\modules\stream\widgets\WallStreamFilterNavigation
FILTER_TOPICS 'topic' humhub\modules\stream\widgets\WallStreamFilterNavigation
FILTER_USER_INVOVLED 'entry_userinvolved' humhub\modules\stream\widgets\WallStreamFilterNavigation
FILTER_VISIBILITY_PRIVATE 'visibility_private' humhub\modules\stream\widgets\WallStreamFilterNavigation
FILTER_VISIBILITY_PUBLIC 'visibility_public' humhub\modules\stream\widgets\WallStreamFilterNavigation
PANEL_POSITION_CENTER 1 Left panel position humhub\modules\stream\widgets\WallStreamFilterNavigation
PANEL_POSITION_LEFT 0 Left panel position humhub\modules\stream\widgets\WallStreamFilterNavigation
PANEL_POSITION_RIGHT 2 humhub\modules\stream\widgets\WallStreamFilterNavigation

Property Details

$defaultBlock public property
public $defaultBlock self::FILTER_BLOCK_BASIC
$id public property
public string $id 'wall-stream-filter-nav'
$jsWidget public property
public $jsWidget 'stream.wall.WallStreamFilter'
$view public property

View

public string $view 'wallStreamFilterNavigation'

Method Details

getAttributes() public method

public void getAttributes ( )
initBasicFilters() protected method

protected void initBasicFilters ( )
initFilterBlocks() protected method

Initialization logic for default filter blocks.

This function can make use of the addFilterBlock() to add filter blocks to the previously initialized panels

protected void initFilterBlocks ( )
initFilterPanels() protected method

Initialization logic for default filter panels

protected void initFilterPanels ( )
initFilters() protected method

Initialization logic for default filter blocks.

This function can make use of the addFilter() to add filters the previously initialized blocks

protected void initFilters ( )
initSortFilters() protected method

protected void initSortFilters ( )
initVisibilityFilters() protected method

protected void initVisibilityFilters ( )