Plugin Directory

Changeset 683488


Ignore:
Timestamp:
03/18/2013 04:21:34 AM (13 years ago)
Author:
ntemple
Message:

Update for 2013 region changes

Location:
bracketpress/trunk
Files:
6 edited

Legend:

Unmodified
Added
Removed
  • bracketpress/trunk/bracketpress.php

    r677166 r683488  
    55Author: Scott Hack and Nick Temple
    66Author URI: http://www.bracketpress.com
    7 Version: 1.2.1
     7Version: 1.4.0
    88*/
    99
  • bracketpress/trunk/includes/models/match.php

    r677166 r683488  
    175175        // Final Four
    176176        switch ($id) {
    177             case 15: $next_game = array(61, 0); break;
     177            case 15: $next_game = array(62, 0); break;
    178178            case 30: $next_game = array(61, 1); break;
    179             case 45: $next_game = array(62, 0); break;
    180             case 60: $next_game = array(62, 1); break;
     179            case 45: $next_game = array(62, 1); break;
     180            case 60: $next_game = array(61, 0); break;
    181181
    182182            case 61: $next_game = array(63, 0); break;
     
    252252        // Special case tournament bracket
    253253        if ($id > 60)  {
    254             if ($id == 61) $previous = array(15, 30);
    255             if ($id == 62) $previous = array(45, 60);
     254            if ($id == 61) $previous = array(60, 30);
     255            if ($id == 62) $previous = array(15, 45);
    256256            if ($id == 63) $previous = array(61, 62);
    257257        }
  • bracketpress/trunk/readme.txt

    r677166 r683488  
    5252== Changelog ==
    5353
     54= 1.4.0 =
     55* Updated for 2013 region display order and final 4 matching.
     56
    5457= 1.2.1 =
    5558* Fixed problem where randomization led to a unchangeable bracket due to user_id not being stored.
     
    102105== Upgrade Notice ==
    103106
     107= 1.4.0 =
     108* Critical update for 2013: the region order and final 4 matchup has been changed from 2012. Please update now!
     109
    104110= 1.2.1 =
    105111* Out if beta! Please upgrade.
  • bracketpress/trunk/templates/bracket_display.php

    r677166 r683488  
    9999            <span class="seed <?php echo $class1 ?>">
    100100                <?php if ($winner1) { ?>
    101                 <span class="org_win1"><?php echo $winner1 ?></span>
     101                    <span class="org_win1"><?php echo $winner1 ?></span>
    102102                <?php } ?>
    103 
    104103                <?php if ($team1) { ?>
    105                 <span class="team_ids"> <?php if ($show_seed) echo $team1->seed; ?></span> <?php print bracketpress_display_name($team1->name) ?></span>
    106             <?php } ?>
    107                 <em class="score"><?php  ?></em>
     104                    <span class="team_ids"> <?php if ($show_seed) echo $team1->seed; ?></span> <?php print bracketpress_display_name($team1->name) ?>
     105                <?php } ?>
     106                <em class="score"><?php // echo $this_match_id ?></em>
     107            </span>
     108
    108109    </p>
    109110    <p class="slot slot2 team_<?php echo $team2->ID ?>" <?php echo $id2 ?>>
    110111            <span class="seed <?php echo $class2 ?>">
    111112                <?php if ($winner2) { ?>
    112                 <span class="org_win2"><?php echo $winner2 ?></span>
     113                    <span class="org_win2"><?php echo $winner2 ?></span>
    113114                <?php } ?>
    114115                <?php if ($team2) { ?>
    115                 <span class="team_ids"> <?php if ($show_seed) echo $team2->seed; ?></span> <?php print bracketpress_display_name($team2->name) ?>
     116                    <span class="team_ids"> <?php if ($show_seed) echo $team2->seed; ?></span> <?php print bracketpress_display_name($team2->name) ?>
     117                <?php } ?>
     118                <em class="score"><?php  ?></em>
    116119            </span>
    117             <?php } ?>
    118                 <em class="score"><?php  ?></em>
    119120    </p>
    120121</div>
     
    199200<div id="round<?php print $num ?>" class="round">
    200201    <h3>Round <?php print $name ?> (2013 NCAA Men's Basketball Tournament)</h3>
    201 
    202202    <div class="region region1">
    203         <h4 class="region1">SOUTH</h4>
    204         <?php bracketpress_partial_display_round($num, BRACKETPRESS_REGION_SOUTH); ?>
     203        <h4 class="region1">MIDWEST</h4>
     204        <?php bracketpress_partial_display_round($num, BRACKETPRESS_REGION_MIDWEST); ?>
    205205    </div>
    206206    <div class="region region2">
     
    209209    </div>
    210210    <div class="region region3">
    211         <h4 class="region3"> EAST </h4>
     211        <h4 class="region3"> SOUTH </h4>
     212        <?php bracketpress_partial_display_round($num, BRACKETPRESS_REGION_SOUTH); ?>
     213    </div>
     214    <div class="region region4">
     215        <h4 class="region4">EAST</h4>
    212216        <?php bracketpress_partial_display_round($num, BRACKETPRESS_REGION_EAST); ?>
    213     </div>
    214     <div class="region region4">
    215         <h4 class="region4">MIDWEST</h4>
    216         <?php bracketpress_partial_display_round($num, BRACKETPRESS_REGION_MIDWEST); ?>
    217217    </div>
    218218</div>
     
    263263            Round One (2013 NCAA Men's Basketball Tournament)
    264264        </h3>
     265
    265266        <div class="region region1">
    266             <h4 class="region1 first_region">SOUTH</h4>
    267             <?php bracketpress_partial_display_seed(BRACKETPRESS_REGION_SOUTH) ?>
     267            <h4 class="region1 first_region">MIDWEST</h4>
     268            <?php bracketpress_partial_display_seed(BRACKETPRESS_REGION_MIDWEST) ?>
    268269        </div>
    269270        <div class="region region2">
     
    272273        </div>
    273274        <div class="region region3">
    274             <h4 class="region3 first_region">EAST</h4>
     275            <h4 class="region3 first_region">SOUTH</h4>
     276            <?php bracketpress_partial_display_seed(BRACKETPRESS_REGION_SOUTH) ?>
     277        </div>
     278        <div class="region region4">
     279            <h4 class="region4 first_region">EAST</h4>
    275280            <?php bracketpress_partial_display_seed(BRACKETPRESS_REGION_EAST) ?>
    276281        </div>
    277         <div class="region region4">
    278             <h4 class="region4 first_region">MIDWEST</h4>
    279             <?php bracketpress_partial_display_seed(BRACKETPRESS_REGION_MIDWEST) ?>
    280         </div>
     282
     283
    281284    </div>
    282285
     
    294297        <div class="region">
    295298        <?php
     299
     300            /**
     301             * This is the final four, and unforunately, the game order depends on the ordering
     302             * of the matches.
     303             */
    296304
    297305            $matchlist = bracketpress()->matchlist;
  • bracketpress/trunk/templates/bracket_edit.js

    r666871 r683488  
    110110
    111111    sel_match = get_sel_match(15);
    112     if (sel_match['winner_id']) set_team(61, 1, sel_match.winner_id);
     112    if (sel_match['winner_id']) set_team(62, 1, sel_match.winner_id);
    113113
    114114    sel_match = get_sel_match(30);
     
    116116
    117117    sel_match = get_sel_match(45);
    118     if (sel_match['winner_id']) set_team(62, 1, sel_match.winner_id);
     118    if (sel_match['winner_id']) set_team(62, 2, sel_match.winner_id);
    119119
    120120    sel_match = get_sel_match(60);
    121     if (sel_match['winner_id']) set_team(62, 2, sel_match.winner_id);
     121    if (sel_match['winner_id']) set_team(61, 1, sel_match.winner_id);
    122122
    123123    sel_match = get_sel_match(61);
     
    491491
    492492        // Add the items
    493         set_team(61, 1, $('#get_team_selector_south_match15').val(), winner );
     493        set_team(61, 1, $('#get_team_selector_midwest_match60').val(), winner );
    494494        set_team(61, 2, $('#get_team_selector_west_match30').val(), winner );
    495495
     
    499499
    500500        // Add the items
    501         set_team(62, 1, $('#get_team_selector_east_match45').val(), winner );
    502         set_team(62, 2, $('#get_team_selector_midwest_match60').val(), winner );
     501        set_team(62, 1, $('#get_team_selector_south_match15').val(), winner );
     502        set_team(62, 2, $('#get_team_selector_east_match45').val(), winner );
    503503
    504504        // Clear and create the final round
  • bracketpress/trunk/templates/bracket_edit.php

    r673588 r683488  
    289289    </div>
    290290</div>
    291     <!-- Bracket -->
     291
    292292
    293293</div>
Note: See TracChangeset for help on using the changeset viewer.