r101081 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r101080‎ | r101081 | r101082 >
Date:23:08, 27 October 2011
Author:reedy
Status:resolved
Tags:
Comment:
*(bug 25983) Drop unused columns from CodeReview tables

Also added script to kill old test tables (was never added) if they happen to still exists
Modified paths:
  • /trunk/extensions/CodeReview/CodeReview.php (modified) (history)
  • /trunk/extensions/CodeReview/archives/code_drop_cc_review.sql (added) (history)
  • /trunk/extensions/CodeReview/archives/code_drop_test.sql (added) (history)
  • /trunk/extensions/CodeReview/ui/CodeRevisionListView.php (modified) (history)

Diff [purge]

Index: trunk/extensions/CodeReview/CodeReview.php
@@ -354,6 +354,11 @@
355355 "$base/archives/code_revs_status_author-index.sql" );
356356 $updater->addExtensionField( 'code_comment', 'cc_patch_line',
357357 "$base/archives/code_comment_patch_line.sql" );
 358+
 359+ $updater->addExtensionUpdate( array( 'dropField', 'code_comment', 'cc_review',
 360+ "$base/archives/code_drop_cc_review.sql", true ) );
 361+
 362+ $updater->addExtensionUpdate( array( 'dropTable', 'code_test_suite', "$base/archives/code_drop_test.sql", true ) );
358363 break;
359364 case 'sqlite':
360365 $updater->addExtensionTable( 'code_rev', "$base/codereview.sql" );
Index: trunk/extensions/CodeReview/archives/code_drop_cc_review.sql
@@ -0,0 +1 @@
 2+ALTER TABLE /*_*/code_comment DROP COLUMN cc_review;
Property changes on: trunk/extensions/CodeReview/archives/code_drop_cc_review.sql
___________________________________________________________________
Added: svn:eol-style
13 + native
Index: trunk/extensions/CodeReview/archives/code_drop_test.sql
@@ -0,0 +1,4 @@
 2+DROP TABLE IF EXISTS /*_*/code_test_suite;
 3+DROP TABLE IF EXISTS /*_*/code_test_case;
 4+DROP TABLE IF EXISTS /*_*/code_test_run;
 5+DROP TABLE IF EXISTS /*_*/code_test_result;
Property changes on: trunk/extensions/CodeReview/archives/code_drop_test.sql
___________________________________________________________________
Added: svn:eol-style
16 + native
Index: trunk/extensions/CodeReview/ui/CodeRevisionListView.php
@@ -232,13 +232,13 @@
233233
234234 foreach ( $states as $key => $state ) {
235235 $title = SpecialPage::getTitleFor( 'Code', $name . "/status/$state" );
236 - $options[] = Xml::option(
 236+ $options[] = Xml::option(
237237 wfMsgHtml( "code-status-$state" ),
238238 $title->getPrefixedText(),
239239 $this->mStatus == $state
240240 );
241241 }
242 -
 242+
243243 $ret = "<fieldset><legend>" . wfMsgHtml( 'code-pathsearch-legend' ) . "</legend>" .
244244 '<table width="100%"><tr><td>' .
245245 Xml::openElement( 'form', array( 'action' => $wgScript, 'method' => 'get' ) ) .
@@ -455,6 +455,9 @@
456456 }
457457 }
458458
 459+ /**
 460+ * @return Title
 461+ */
459462 function getTitle() {
460463 return SpecialPage::getTitleFor( 'Code', $this->mRepo->getName() );
461464 }

Sign-offs

UserFlagDate
Nikerabbitinspected07:37, 28 October 2011

Follow-up revisions

RevisionCommit summaryAuthorDate
r101082Followup r101081, don't add the cc_review column eitherreedy23:09, 27 October 2011

Status & tagging log