◆ filter()
| static filter |
( |
|
$data, |
|
|
|
$search |
|
) |
| |
|
staticabstract |
Returns an array of information for the found element. Following informations (key: description) are necessary
- name: The name of the object
- url: The url to send the user to when he clicks the link
Additional informations are:
- additional: Subtitle for the hit
- expand: Url if the user further expands the search
- img: Avatar for the
- Parameters
-
| $data | One row returned from getSQL SQL Query |
| $search | The searchstring (Use for markup e.g. self::mark) |
- Returns
- mixed Information Array
Reimplemented in GlobalSearchMyCourses, GlobalSearchCourses, GlobalSearchFiles, GlobalSearchForum, GlobalSearchUsers, GlobalSearchInstitutes, GlobalSearchMessages, GlobalSearchModules, GlobalSearchResources, GlobalSearchRoomBookings, and GlobalSearchCalendar.
◆ getActiveSearchModules()
| static getActiveSearchModules |
( |
| ) |
|
|
static |
Returns a list of all active search modules
- Returns
- array search_class => data
◆ getCurrentSemester()
| static getCurrentSemester |
( |
| ) |
|
|
static |
Get the current semester considering the given SEMESTER_TIME_SWITCH in the CONFIG (n weeks before the next semester)
- Returns
- int The start time of the current semester.
◆ getFilters()
◆ getInstituteIdsForSQL()
| static getInstituteIdsForSQL |
( |
|
$institute_id | ) |
|
|
static |
Get the selected institute with sub-institutes as an array of IDs or a single institute as a string to use in the SQL query.
- Parameters
-
| $institute_id | ID of the given institute or faculty |
- Returns
- mixed: a single institute as string if selected or an array of institute IDs if a faculty was selected
◆ getName()
Returns the displayname for this module
- Returns
- mixed
Reimplemented in GlobalSearchCalendar, GlobalSearchCourses, GlobalSearchFiles, GlobalSearchForum, GlobalSearchInstitutes, GlobalSearchMessages, GlobalSearchModules, GlobalSearchMyCourses, GlobalSearchResources, GlobalSearchRoomBookings, and GlobalSearchUsers.
◆ getSearchURL()
| static getSearchURL |
( |
|
$searchterm | ) |
|
|
static |
Returns the URL that can be called for a full search, containing the specified category and the searchterm.
Overwrite this method in your subclass to provide the category specific search.
- Parameters
-
| string | $searchterm | what to search for? |
- Returns
- URL to the full search, containing the searchterm and the category
Reimplemented in GlobalSearchCalendar, GlobalSearchCourses, GlobalSearchFiles, GlobalSearchForum, GlobalSearchInstitutes, GlobalSearchMessages, GlobalSearchModules, GlobalSearchMyCourses, GlobalSearchResources, GlobalSearchRoomBookings, and GlobalSearchUsers.
◆ getSeminarTypesForSQL()
| static getSeminarTypesForSQL |
( |
|
$sem_class | ) |
|
|
static |
Get the selected seminar class with sub-types as an array or a single seminar type as a string to use in an SQL query.
- Parameters
-
| $sem_class | a single sem_type ID or a sem_class containing multiple sem_types |
- Returns
- mixed: seminar class/types formatted for an SQL query
◆ getSQL()
| static getSQL |
( |
|
$search, |
|
|
|
$filter, |
|
|
|
$limit |
|
) |
| |
|
staticabstract |
Has to return a SQL Query that discovers all objects. All retrieved data is passed row by row to getGlobalSearchFilter.
- Parameters
-
| $search | the input query string |
| $filter | an array with search limiting filter information (e.g. 'category', 'semester', etc.) |
- Returns
- String SQL Query to discover elements for the search
Reimplemented in GlobalSearchCalendar, GlobalSearchCourses, GlobalSearchFiles, GlobalSearchForum, GlobalSearchInstitutes, GlobalSearchMessages, GlobalSearchModules, GlobalSearchMyCourses, GlobalSearchResources, GlobalSearchRoomBookings, and GlobalSearchUsers.
◆ mark()
| static mark |
( |
|
$string, |
|
|
|
$query, |
|
|
|
$longtext = false, |
|
|
|
$filename = true |
|
) |
| |
|
static |
Function to mark a querystring in a resultstring
- Parameters
-
| $string | |
| $query | |
| bool | true | $filename | |
- Returns
- mixed
The documentation for this class was generated from the following file: