Index: branches/querypage-work2/extensions/MetavidWiki/includes/specials/MV_SpecialListStreams.php |
— | — | @@ -45,9 +45,9 @@ |
46 | 46 | function getPageHeader() { |
47 | 47 | return '<p>' . wfMsg( 'mv_list_streams_docu' ) . "</p><br />\n"; |
48 | 48 | } |
49 | | - function getSQL() { |
50 | | - $dbr = wfGetDB( DB_SLAVE ); |
51 | | - // $relations = $dbr->tableName( 'smw_relations' ); |
| 49 | + |
| 50 | + function getQueryInfo() { |
| 51 | + // $relations = $dbr->tableName( 'smw_relations' ); |
52 | 52 | // $NSrel = SMW_NS_RELATION; |
53 | 53 | # QueryPage uses the value from this SQL in an ORDER clause. |
54 | 54 | /*return "SELECT 'Relations' as type, |
— | — | @@ -63,13 +63,13 @@ |
64 | 64 | * stream length |
65 | 65 | * formats available |
66 | 66 | * number of associative metadata chunks */ |
67 | | - return "SELECT |
68 | | - `id` as `stream_id`, |
69 | | - `name` as title, |
70 | | - `name` as value " . |
71 | | - "FROM " . $dbr->tableName( 'mv_streams' ); |
72 | 67 | |
| 68 | + return array( |
| 69 | + 'tables' => array( 'mv_streams' ), |
| 70 | + 'fields' => array( 'id AS stream_id', 'name AS title', 'name AS value' ) |
| 71 | + ); |
73 | 72 | } |
| 73 | + |
74 | 74 | function getOrder() { |
75 | 75 | return ' ORDER BY `mv_streams`.`date_start_time` DESC '; |
76 | 76 | // ($this->sortDescending() ? 'DESC' : ''); |