r100911 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r100910‎ | r100911 | r100912 >
Date:00:14, 27 October 2011
Author:reedy
Status:ok
Tags:
Comment:
Bug 31964 - Allow filter by path on CodeRevisionTagView

Doesn't work through UI (ie selecting path, and pressing go), but will work as Special:CodeReview/MediaWiki/tag/foobar?path=/trunk

Didn't see much point (at the moment at least) feeding that in, but if needed, I can. Won't change the previous behaviour where if you had it filtered by tag, entering a path just ignores the tag anyway
Modified paths:
  • /trunk/extensions/CodeReview/ui/CodeRevisionTagView.php (modified) (history)

Diff [purge]

Index: trunk/extensions/CodeReview/ui/CodeRevisionTagView.php
@@ -27,6 +27,13 @@
2828
2929 function getQueryInfo() {
3030 $info = parent::getQueryInfo();
 31+
 32+ if ( $this->mView->mPath ) {
 33+ array_unshift( $info['tables'], 'code_paths' );
 34+ $info['conds'][] = 'cr_repo_id=cp_repo_id';
 35+ $info['conds'][] = 'cr_id=cp_rev_id';
 36+ $info['conds']['cp_path'] = $this->mView->mPath;
 37+ }
3138 //Don't change table order, see http://www.mediawiki.org/wiki/Special:Code/MediaWiki/77733
3239 //Bug in mysql 4 allowed incorrect table ordering joins to work
3340 array_unshift( $info['tables'], 'code_tags' );

Follow-up revisions

RevisionCommit summaryAuthorDate
r100913MFT r100911 for Chadreedy00:17, 27 October 2011

Status & tagging log