исправление Undefined index: gold_silver_enabled git-svn-id: https://torrentpier2.googlecode.com/svn/trunk@361 a8ac35ab-4ca4-ca47-4c2d-a49a94f06293
This commit is contained in:
nanosimbiot 2012-02-08 12:58:33 +00:00
commit 0cd162611a
11 changed files with 19 additions and 18 deletions

View file

@ -75,7 +75,6 @@ switch($mode)
'CONFIG_MODS' => true,
'REPORTS_ENABLED' => $new['reports_enabled'],
'GOLD_SILVER_ENABLED' => $new['gold_silver_enabled'],
'GALLERY_ENABLED' => $new['gallery_enabled'],
'PIC_DIR' => $new['pic_dir'],
'PIC_MAX_SIZE' => $new['pic_max_size'],

View file

@ -57,6 +57,7 @@ $template->assign_vars(array(
'IGNORE_REPORTED_IP' => $bb_cfg['ignore_reported_ip'],
'ANNOUNCE_INTERVAL' => $bb_cfg['announce_interval'],
'PASSKEY_KEY' => $bb_cfg['passkey_key'],
'GOLD_SILVER_ENABLED' => $tr_cfg['gold_silver_enabled'],
'DISABLE_SUBMIT' => true,
'S_HIDDEN_FIELDS' => '',

View file

@ -189,7 +189,7 @@ if ($tor_reged && $tor_info)
{
$template->assign_vars(array(
'SHOW_RATIO_WARN' => true,
'RATIO_WARN_MSG' => sprintf($lang['BT_RATIO_WARNING_MSG'], $min_ratio_warn, $bb_cfg['ratio_url_help']),
'RATIO_WARN_MSG' => sprintf($lang['BT_RATIO_WARNING_MSG'], $min_ratio_dl, $bb_cfg['ratio_url_help']),
));
}
}

View file

@ -357,7 +357,7 @@ $up_add = ($lp_info && $uploaded > $lp_info['uploaded']) ? $uploaded - $lp_info[
$down_add = ($lp_info && $downloaded > $lp_info['downloaded']) ? $downloaded - $lp_info['downloaded'] : 0;
// Gold/Silver releases
if ($bb_cfg['gold_silver_enabled'] && $down_add)
if ($tr_cfg['gold_silver_enabled'] && $down_add)
{
if ($tor_type == TOR_TYPE_GOLD)
{

View file

@ -53,7 +53,7 @@ $bb_cfg = $tr_cfg = $page_cfg = array();
// Increase number of revision after update
$bb_cfg['tp_version'] = '2.4 (beta)';
$bb_cfg['tp_release_state'] = 'R360';
$bb_cfg['tp_release_state'] = 'R361';
$bb_cfg['tp_release_date'] = '08-02-2012';
// Database
@ -163,6 +163,7 @@ $tr_cfg = array(
'limit_seed_ips' => 0,
'limit_leech_ips' => 0,
'tor_topic_up' => true,
'gold_silver_enabled' => true,
);
$bb_cfg['show_dl_status_in_search'] = true;

View file

@ -290,13 +290,6 @@
<label><input type="radio" name="reports_enabled" value="0" <!-- IF not REPORTS_ENABLED -->checked="checked"<!-- ENDIF --> />{L_DISABLED}</label>
</td>
</tr>
<tr>
<td><h4>{L_GOLD} / {L_SILVER}</h4></td>
<td>
<label><input type="radio" name="gold_silver_enabled" value="1" <!-- IF GOLD_SILVER_ENABLED -->checked="checked"<!-- ENDIF --> />{L_ENABLED}</label>&nbsp;&nbsp;
<label><input type="radio" name="gold_silver_enabled" value="0" <!-- IF not GOLD_SILVER_ENABLED -->checked="checked"<!-- ENDIF --> />{L_DISABLED}</label>
</td>
</tr>
<tr>
<td><h4>{L_MAGNET}</h4></td>
<td>

View file

@ -106,6 +106,13 @@
<td><h4>{L_UPDATE_DLSTAT}</h4><h6>Used in cron <b>Tracker cleanup and dlstat</b></h6></td>
<td><label for="update_dlstat1"><input type="radio" name="update_dlstat" id="update_dlstat1" value="1" {UPDATE_DLSTAT_YES} /> {L_UPDATE_DLSTAT_YES}&nbsp;</label><label for="update_dlstat2">&nbsp;<input type="radio" name="update_dlstat" id="update_dlstat2" value="0" {UPDATE_DLSTAT_NO} /> {L_UPDATE_DLSTAT_NO} &nbsp;</label></td>
</tr>
<tr>
<td><h4>{L_GOLD} / {L_SILVER}</h4></td>
<td>
<label><input type="radio" name="gold_silver_enabled" value="1" <!-- IF GOLD_SILVER_ENABLED -->checked="checked"<!-- ENDIF --> />{L_ENABLED}</label>&nbsp;&nbsp;
<label><input type="radio" name="gold_silver_enabled" value="0" <!-- IF not GOLD_SILVER_ENABLED -->checked="checked"<!-- ENDIF --> />{L_DISABLED}</label>
</td>
</tr>
<tr>
<td><h4>{L_IGNORE_GIVEN_IP}</h4><h5>$bb_cfg['ignore_reported_ip']</h5><h6><!-- IF L_IGNOR_GIVEN_IP_EXPL -->{L_IGNOR_GIVEN_IP_EXPL}<!-- ENDIF --></h6></td>
<td>&nbsp; <!-- IF IGNORE_REPORTED_IP -->{L_YES}<!-- ELSE -->{L_NO}<!-- ENDIF --></td>

View file

@ -149,7 +149,7 @@ ajax.callback.view_post = function(data) {
<p class="chbox">{ONLY_ACTIVE_CHBOX}</p>
<p class="chbox">{SEED_EXIST_CHBOX}</p>
<p class="chbox">{ONLY_NEW_CHBOX}[{MINIPOST_IMG_NEW}]&nbsp;</p>
<!-- IF $bb_cfg['gold_silver_enabled'] --><p class="chbox">{TOR_TYPE_CHBOX}</p><!-- ENDIF -->
<!-- IF $tr_cfg['gold_silver_enabled'] --><p class="chbox">{TOR_TYPE_CHBOX}</p><!-- ENDIF -->
</div>
</fieldset>
<fieldset>

View file

@ -232,11 +232,11 @@
<tr class="row3">
<th colspan="3" class="{postrow.attach.tor_reged.DL_LINK_CLASS}">{postrow.attach.tor_reged.DOWNLOAD_NAME}<!-- IF postrow.attach.tor_reged.TOR_FROZEN == 0 --><!-- IF MAGNET_LINKS -->&nbsp;{postrow.attach.tor_reged.MAGNET}<!-- ENDIF --><!-- ENDIF --></th>
</tr>
<!-- IF postrow.attach.tor_reged.TOR_SILVER_GOLD == 2 && $bb_cfg['gold_silver_enabled'] -->
<!-- IF postrow.attach.tor_reged.TOR_SILVER_GOLD == 2 && $tr_cfg['gold_silver_enabled'] -->
<tr class="row4">
<th colspan="3" class="row7"><img src="images/tor_silver.gif" width="16" height="15" title="{L_SILVER}" />&nbsp;{L_SILVER_STATUS}&nbsp;<img src="images/tor_silver.gif" width="16" height="15" title="{L_SILVER}" /></th>
</tr>
<!-- ELSEIF postrow.attach.tor_reged.TOR_SILVER_GOLD == 1 && $bb_cfg['gold_silver_enabled'] -->
<!-- ELSEIF postrow.attach.tor_reged.TOR_SILVER_GOLD == 1 && $tr_cfg['gold_silver_enabled'] -->
<tr class="row4">
<th colspan="3" class="row7"><img src="images/tor_gold.gif" width="16" height="15" title="{L_GOLD}" />&nbsp;{L_GOLD_STATUS}&nbsp;<img src="images/tor_gold.gif" width="16" height="15" title="{L_GOLD}" /></th>
</tr>
@ -321,7 +321,7 @@
<option value="del_torrent">{L_DELETE_TORRENT}</option>
<option value="del_torrent_move_topic">{L_DEL_MOVE_TORRENT}</option>
<!-- IF AUTH_MOD -->
<!-- IF $bb_cfg['gold_silver_enabled'] -->
<!-- IF $tr_cfg['gold_silver_enabled'] -->
<!-- IF postrow.attach.tor_reged.TOR_SILVER_GOLD == 1 -->
<option value="unset_silver_gold">{L_UNSET_GOLD_TORRENT} / {L_UNSET_SILVER_TORRENT}</option>
<option value="set_silver">{L_SET_SILVER_TORRENT}</option>

View file

@ -734,7 +734,7 @@ if ($allowed_forums)
// Gold/Silver releases mod
$is_gold = '';
if ($bb_cfg['gold_silver_enabled'])
if ($tr_cfg['gold_silver_enabled'])
{
if ($tor['tor_type'] == TOR_TYPE_GOLD)
{

View file

@ -480,7 +480,7 @@ foreach ($topic_rowset as $topic)
// Gold/Silver releases mod
$is_gold = '';
if ($bb_cfg['gold_silver_enabled'] && isset($topic['tor_type']))
if ($tr_cfg['gold_silver_enabled'] && isset($topic['tor_type']))
{
if ($topic['tor_type'] == TOR_TYPE_GOLD)
{