r109751 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r109750‎ | r109751 | r109752 >
Date:20:16, 22 January 2012
Author:jeroendedauw
Status:deferred
Tags:
Comment:
follow up to r109656 - renaming
Modified paths:
  • /trunk/extensions/EducationProgram/EducationProgram.i18n.php (modified) (history)
  • /trunk/extensions/EducationProgram/includes/EPCourse.php (modified) (history)
  • /trunk/extensions/EducationProgram/specials/SpecialMasterCourse.php (modified) (history)

Diff [purge]

Index: trunk/extensions/EducationProgram/specials/SpecialMasterCourse.php
@@ -65,12 +65,12 @@
6666
6767 $out->addHTML( Html::element( 'h2', array(), wfMsg( 'ep-mc-courses' ) ) );
6868
69 - EPMC::displayPager( $this->getContext(), array( 'id' => $masterCourse->getId() ) );
 69+ EPCourse::displayPager( $this->getContext(), array( 'mc_id' => $masterCourse->getId() ) );
7070
71 - if ( $this->getUser()->isAllowed( 'ep-mc' ) ) {
 71+ if ( $this->getUser()->isAllowed( 'ep-course' ) ) {
7272 $out->addHTML( Html::element( 'h2', array(), wfMsg( 'ep-mc-add-course' ) ) );
7373
74 - EPMC::displayAddNewControl( $this->getContext(), array( 'mc' => $masterCourse->getId() ) );
 74+ EPCourse::displayAddNewControl( $this->getContext(), array( 'mc' => $masterCourse->getId() ) );
7575 }
7676 }
7777 }
Index: trunk/extensions/EducationProgram/includes/EPCourse.php
@@ -353,7 +353,7 @@
354354 * @return boolean
355355 */
356356 public static function displayAddNewControl( IContextSource $context, array $args ) {
357 - if ( !$context->getUser()->isAllowed( 'ep-term' ) ) {
 357+ if ( !$context->getUser()->isAllowed( 'ep-course' ) ) {
358358 return false;
359359 }
360360
@@ -363,7 +363,7 @@
364364 'form',
365365 array(
366366 'method' => 'post',
367 - 'action' => SpecialPage::getTitleFor( 'EditTerm' )->getLocalURL(),
 367+ 'action' => SpecialPage::getTitleFor( 'EditCourse' )->getLocalURL(),
368368 )
369369 ) );
370370
@@ -381,14 +381,14 @@
382382 array_key_exists( 'mc', $args ) ? $args['mc'] : false
383383 );
384384
385 - $select->addOptions( EPCourse::getCourseOptions() );
 385+ $select->addOptions( EPMC::getMasterCourseOptions() );
386386 $out->addHTML( $select->getHTML() );
387387
388388 $out->addHTML( ' ' . Xml::inputLabel( wfMsg( 'ep-courses-newyear' ), 'newyear', 'newyear', 10 ) );
389389
390390 $out->addHTML( ' ' . Html::input(
391391 'addnewcourse',
392 - wfMsg( 'ep-terms-add' ),
 392+ wfMsg( 'ep-courses-add' ),
393393 'submit'
394394 ) );
395395
Index: trunk/extensions/EducationProgram/EducationProgram.i18n.php
@@ -183,7 +183,7 @@
184184 'ep-courses-addnew' => 'Add a new course',
185185 'ep-courses-namedoc' => 'Enter the master course the course belongs to and the year in which it is active.',
186186 'ep-courses-newyear' => 'Course year:',
187 - 'ep-courses-newcourse' => 'Course master course:',
 187+ 'ep-courses-newmastercourse' => 'Course master course:',
188188 'ep-courses-add' => 'Add course',
189189 'ep-courses-nocourses' => 'There are no master courses yet. You need to [[Special:MasterCourses|add a master course]] before you can create any courses.',
190190 'ep-courses-addcoursefirst' => 'The institutions you are a mentor for do not have any master courses associated with them. You need to [[Special:MasterCourses|add a master course]] before you can create any courses.',

Past revisions this follows-up on

RevisionCommit summaryAuthorDate
r109656schema changes currently completely breaking the extension and added hook to ...jeroendedauw22:24, 20 January 2012

Status & tagging log