'search', 'Clones' => Array( 'c-search' => Array('ParentPrefix' => 'c'), ), 'ItemClass' => Array('class'=>'kDBItem','file'=>'','build_event'=>'OnItemBuild'), 'ListClass' => Array('class'=>'kDBList','file'=>'','build_event'=>'OnListBuild'), 'EventHandlerClass' => Array('class'=>'RelatedSearchEventHandler','file'=>'related_searches_event_handler.php','build_event'=>'OnBuild'), 'TagProcessorClass' => Array('class'=>'RelatedSearchTagProcessor','file'=>'related_searches_tag_processor.php','build_event'=>'OnBuild'), 'AutoLoad' => true, 'QueryString' => Array( 1 => 'id', 2 => 'Page', 3 => 'PerPage', 4 => 'event', ), 'IDField' => 'RelatedSearchId', 'StatusField' => Array('Enabled'), 'TableName' => TABLE_PREFIX.'CategoryRelatedSearches', 'ParentTableKey' => 'ResourceId', 'ForeignKey' => 'ResourceId', 'ParentPrefix' => 'c', 'AutoDelete' => true, 'AutoClone' => true, 'ListSQLs' => Array( ''=> 'SELECT %1$s.* %2$s FROM %1$s', ), // key - special, value - list select sql 'ListSortings' => Array( '' => Array( 'ForcedSorting' => Array('Priority' => 'desc'), 'Sorting' => Array('Keyword' => 'asc'), ) ), 'ItemSQLs' => Array( '' => 'SELECT %1$s.* %2$s FROM %1$s',), 'Fields' => Array( 'RelatedSearchId' => Array('type' => 'int', 'not_null' => 1, 'default' => 0), 'ResourceId' => Array('type'=>'int', 'not_null' => 1, 'required' => 1, 'default' => 0), 'Keyword' => Array('type'=>'string', 'required' => 1, 'not_null' => 1, 'default' => ''), 'ItemType' => Array('type'=>'int', 'not_null' => 1, 'required' => 1, 'default' => 0), 'Enabled' => Array( 'type' => 'int', 'formatter' => 'kOptionsFormatter', 'options' => Array (0 => 'la_Disabled', 1 => 'la_Enabled'), 'use_phrases' => 1, 'not_null' => 1, 'default' => 1, ), 'Priority' => Array('type'=>'int','not_null'=>1,'default'=>0), ), 'VirtualFields' => Array( ), 'Grids' => Array( 'Default' => Array( 'Icons' => Array( 'default' => 'icon16_item.png', 0 => 'icon16_disabled.png', 1 => 'icon16_item.png' ), 'Fields' => Array( 'RelatedSearchId' => Array( 'title'=>'column:la_fld_Id', 'data_block' => 'grid_checkbox_td', 'filter_block' => 'grid_range_filter'), 'Keyword' => Array( 'title'=>'la_col_Keyword', 'data_block' => 'grid_keyword_td', 'filter_block' => 'grid_like_filter'), 'Enabled' => Array( 'title'=>'column:la_fld_Status', 'filter_block' => 'grid_options_filter'), ), ), ), );