r73513 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r73512‎ | r73513 | r73514 >
Date:10:40, 22 September 2010
Author:nad
Status:deferred
Tags:
Comment:
add tabset code - requires tabset.js
Modified paths:
  • /trunk/extensions/RecordAdmin/RecordAdmin.i18n.php (modified) (history)
  • /trunk/extensions/RecordAdmin/RecordAdmin_body.php (modified) (history)

Diff [purge]

Index: trunk/extensions/RecordAdmin/RecordAdmin_body.php
@@ -76,19 +76,24 @@
7777 if( $count > 0 ) {
7878
7979 # Add the prefs JS for the tabset
80 - $wgOut->addScript( "<script src=\"$wgStylePath/common/prefs.js?269\"></script>" );
 80+ #$wgOut->addScript( "<script src=\"$wgStylePath/common/prefs.js\"></script>" );
8181
8282 $editPage->textbox1 = str_replace( "\x07", "", $content );
8383
8484 $jsFormsList = array();
85 - $tabset = "";
 85+ $tabset = "<div class=\"tabset\">";
 86+ $tabset .= "<fieldset><legend>" . wfMsg( 'recordadmin-properties' ) . "</legend>";
 87+ $tabset .= wfMsg( 'recordadmin-edit-info' ) . "</fieldset>";
8688 foreach( $records as $type => $record ) {
8789 $jsFormsList[] = "'$type'";
8890 $this->preProcessForm( $type );
8991 $this->examineForm();
9092 $this->populateForm( $this->valuesFromText( $record ) );
 93+ $tabset .= "<fieldset><legend>$type " . strtolower( wfMsg( 'recordadmin-properties' ) ) . "</legend>\n";
9194 $tabset .= "<form id=\"$type-form\" class=\"$type-record recordadmin\">$this->form</form>\n";
 95+ $tabset .= "</fieldset>";
9296 }
 97+ $tabset .= "</div>";
9398 $jsFormsList = join( ', ', $jsFormsList );
9499
95100 # Add the tabset before the normal edit form
Index: trunk/extensions/RecordAdmin/RecordAdmin.i18n.php
@@ -55,6 +55,7 @@
5656 'recordadmin-export-pdf' => 'PDF',
5757 'recordadmin-notset' => 'No "$1"',
5858 'recordadmin-edit-info' => 'This page contains templates which have their own forms which you can fill in from this tab-set',
 59+ 'recordadmin-properties' => 'Properties',
5960 );
6061
6162 /** Message documentation (Message documentation)

Status & tagging log