r22445 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r22444‎ | r22445 | r22446 >
Date:00:35, 26 May 2007
Author:kim
Status:old
Tags:
Comment:
Slight updates
Modified paths:
  • /trunk/extensions/Wikidata/OmegaWiki/DefinedMeaning.php (modified) (history)
  • /trunk/extensions/Wikidata/OmegaWiki/WikiDataAPI.php (modified) (history)

Diff [purge]

Index: trunk/extensions/Wikidata/OmegaWiki/DefinedMeaning.php
@@ -16,6 +16,7 @@
1717
1818 $definedMeaningId = $this->getDefinedMeaningIdFromTitle($wgTitle->getText());
1919
 20+ $wgOut->addHTML($this->getConceptPanel());
2021 $wgOut->addHTML(
2122 getDefinedMeaningEditor(
2223 $this->filterLanguageId, $this->possiblySynonymousRelationTypeId, false, $this->shouldShowAuthorities)->view(
@@ -130,6 +131,8 @@
131132 }
132133
133134 public function getDefinedMeaningId() {
 135+ global
 136+ $wgTitle;
134137 return $this->getDefinedMeaningIdFromTitle($wgTitle->getText());
135138 }
136139 /** cut and paste getDataSetPanel with mods for Collection instead
@@ -137,6 +140,7 @@
138141 */
139142 protected function getConceptPanel() {
140143 global $wgTitle, $wgUser;
 144+ $active=True; # wrong place, but hey
141145 $dm=$this->getDefinedMeaningId();
142146 $dc=wdGetDataSetContext();
143147 $ow_conceptpanel="Concept Panel";
@@ -156,6 +160,7 @@
157161 }
158162 $html.="</table>";
159163 $html.="</div>";
 164+ #$html="bla\n";
160165 return $html;
161166 }
162167 }
Index: trunk/extensions/Wikidata/OmegaWiki/WikiDataAPI.php
@@ -1165,12 +1165,14 @@
11661166 if(is_null($dc)) {
11671167 $dc=wdGetDataSetContext();
11681168 }
 1169+ $collection_id=getCollectionIdForDC($dc);
11691170 $dbr = & wfGetDB(DB_SLAVE);
11701171 $dm=$dbr->addQuotes($dm);
11711172 $query = "
11721173 SELECT internal_member_id AS concept_id
11731174 FROM {$dc}_collection_contents
11741175 WHERE member_mid=$dm
 1176+ AND collection_id=$collection_id;
11751177 ";
11761178 wfDebug($query);
11771179 $queryResult = $dbr->query($query);