r74833 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r74832‎ | r74833 | r74834 >
Date:14:31, 16 October 2010
Author:hashar
Status:resolved (Comments)
Tags:
Comment:
Show a description for each status
Modified paths:
  • /trunk/extensions/CodeReview/CodeReview.i18n.php (modified) (history)
  • /trunk/extensions/CodeReview/ui/CodeStatusListView.php (modified) (history)

Diff [purge]

Index: trunk/extensions/CodeReview/CodeReview.i18n.php
@@ -84,13 +84,21 @@
8585 'code-rev-total' => 'Total number of results: $1',
8686 'code-rev-not-found' => "Revision '''$1''' does not exist!",
8787 'code-status-new' => 'new',
 88+ 'code-status-desc-new' => 'Revision is pending an action (default status).',
8889 'code-status-fixme' => 'fixme',
 90+ 'code-status-desc-fixme' => 'A reviewer marked this revision introduce a bug or is broken. It should be corrected.',
8991 'code-status-reverted' => 'reverted',
 92+ 'code-status-desc-reverted' => 'Revision was thrown away by a later revision.',
9093 'code-status-resolved' => 'resolved',
 94+ 'code-status-desc-resolved' => 'Revision had an issue which got adressed by a later revision.',
9195 'code-status-ok' => 'ok',
 96+ 'code-status-desc-ok' => 'Revision fully reviewed and reviewer is sure it is fine in every way.',
9297 'code-status-verified' => 'verified',
 98+ 'code-status-desc-verified' => 'Revision has been tested and is working as intended.',
9399 'code-status-deferred' => 'deferred',
 100+ 'code-status-desc-deferred' => 'Nobody care about this revision.',
94101 'code-status-old' => 'old',
 102+ 'code-status-desc-old' => 'Old revision with potential bugs but which are not worth the effort of reviewing them.',
95103 'code-pathsearch-legend' => 'Search revisions in this repo by path',
96104 'code-pathsearch-path' => 'Path:',
97105 'code-pathsearch-filter' => 'Filter applied:',
Index: trunk/extensions/CodeReview/ui/CodeStatusListView.php
@@ -11,10 +11,21 @@
1212 global $wgOut;
1313 $name = $this->mRepo->getName();
1414 $states = CodeRevision::getPossibleStates();
15 - $text = "== " . wfMsg ( "code-field-status" ) . " ==\n";
 15+ $wgOut->addWikiText( "== " . wfMsg ( "code-field-status" ) . " ==\n" );
 16+
 17+ $table_rows = '';
1618 foreach ( $states as $state ) {
17 - $text .= "* [[Special:Code/$name/status/$state|" . wfMsg ( "code-status-" . $state ) . "]]\n";
 19+ $link = $this->mSkin->link(
 20+ SpecialPage::getTitleFor( 'Code', $name . "/status/$state" ),
 21+ wfMsg( "code-status-".$state )
 22+ );
 23+ $table_rows .= "<tr><td>$link</td>"
 24+ . "<td>" . wfMsg( "code-status-desc-" . $state ) . "</td></tr>\n" ;
1825 }
19 - $wgOut->addWikiText( $text );
 26+ $wgOut->addHTML( '<table class="TablePager">'
 27+ . '<tr><th>toto</th><th>tata</th></tr>'
 28+ . $table_rows
 29+ . '</table>'
 30+ );
2031 }
2132 }

Follow-up revisions

RevisionCommit summaryAuthorDate
r76199Fix up status list table header (fu r74833)hashar16:57, 6 November 2010

Comments

#Comment by 😂 (talk | contribs)   16:36, 6 November 2010

Yay! I wanted to do this but never got around to it:

+	'code-status-desc-reverted' => 'Revision was thrown away by a later revision.',

Perhaps "...was undone by a later..." Just not a huge fan of "thrown away" for some reason.

In 'code-status-desc-resolved': turn 'got' to 'was' Also 'addressed' is misspelled.

Constructing new SpecialPage objects on each iteration feels icky, but shouldn't be a realistic problem since there's less than 10.

+			. '<tr><th>toto</th><th>tata</th></tr>'

Forgot some messages?

#Comment by Hashar (talk | contribs)   16:58, 6 November 2010

Some messages got fixed in a later revision.

Fixed with follow up r76199: - Replaced thrown away - wfMsg for table header

Marking 'new'

Status & tagging log