Empty commit

This commit is contained in:
Git 2012-12-30 08:00:23 +00:00
parent 560f52b8ba
commit 23684501b2
4 changed files with 17 additions and 7 deletions

View File

@ -155,7 +155,7 @@
</li> </li>
<li>In this example, Rippy has snatched 90 torrents, and is currently seeding 45 torrents.</li> <li>In this example, Rippy has snatched 90 torrents, and is currently seeding 45 torrents.</li>
<li>To calculate Rippy&#39;s actual required ratio, we take his maximum required ratio (0% seeded), which is 0.30, and multiply it by [1 - seeding/snatched] (which is 0.50). Written out: <li>To calculate Rippy&#39;s actual required ratio, we take his maximum required ratio (0% seeded), which is 0.30, and multiply it by [1 - seeding/snatched] (which is 0.50). Written out:
0.05 * [1 - (45/90)] = 0.15. 0.3 * [1 - (45/90)] = 0.15.
</li> </li>
<li>The resulting required ratio is 0.15, which falls between the maximum required ratio of 0.30 and the minimum required ratio of 0.05 for his amount downloaded bracket.</li> <li>The resulting required ratio is 0.15, which falls between the maximum required ratio of 0.30 and the minimum required ratio of 0.05 for his amount downloaded bracket.</li>
<li>If Rippy&#39;s on-site required ratio was listed as a value greater than the calculated value, this would be because he hadn&#39;t seeded those 45 torrents for a 72 hour period in the <li>If Rippy&#39;s on-site required ratio was listed as a value greater than the calculated value, this would be because he hadn&#39;t seeded those 45 torrents for a 72 hour period in the

View File

@ -619,7 +619,7 @@ function next_hour() {
FROM forums_topics AS t FROM forums_topics AS t
JOIN forums AS f ON t.ForumID = f.ID JOIN forums AS f ON t.ForumID = f.ID
WHERE t.IsLocked='0' AND t.IsSticky='0' WHERE t.IsLocked='0' AND t.IsSticky='0'
AND t.LastPostTime<'".time_minus(3600*24*28)."' AND DATEDIFF(CURDATE(),DATE(t.LastPostTime))/7>f.AutoLockWeeks
AND f.AutoLock = '1'"); AND f.AutoLock = '1'");
$IDs = $DB->collect('ID'); $IDs = $DB->collect('ID');

View File

@ -42,12 +42,13 @@
MinClassRead='$P[minclassread]', MinClassRead='$P[minclassread]',
MinClassWrite='$P[minclasswrite]', MinClassWrite='$P[minclasswrite]',
MinClassCreate='$P[minclasscreate]', MinClassCreate='$P[minclasscreate]',
AutoLock='$P[autolock]' AutoLock='$P[autolock]',
AutoLockWeeks='$P[autolockweeks]'
WHERE ID='$P[id]'"); WHERE ID='$P[id]'");
} else { //Create } else { //Create
$DB->query("INSERT INTO forums $DB->query("INSERT INTO forums
(Sort, CategoryID, Name, Description, MinClassRead, MinClassWrite, MinClassCreate, AutoLock) VALUES (Sort, CategoryID, Name, Description, MinClassRead, MinClassWrite, MinClassCreate, AutoLock, AutoLockWeeks) VALUES
('$P[sort]', '$P[categoryid]', '$P[name]','$P[description]','$P[minclassread]','$P[minclasswrite]','$P[minclasscreate]','$P[autolock]')"); ('$P[sort]', '$P[categoryid]', '$P[name]','$P[description]','$P[minclassread]','$P[minclasswrite]','$P[minclasscreate]','$P[autolock]','$P[autolockweeks]')");
} }
} }

View File

@ -44,11 +44,13 @@ function class_list($Selected=0){
MinClassRead, MinClassRead,
MinClassWrite, MinClassWrite,
MinClassCreate, MinClassCreate,
AutoLock AutoLock,
AutoLockWeeks
FROM forums FROM forums
ORDER BY CategoryID, Sort ASC'); ORDER BY CategoryID, Sort ASC');
?> ?>
<div class="header"> <div class="header">
<script type="text/javacript">document.getElementByID('content').style.overflow='visible';</script>
<h2>Forum control panel</h2> <h2>Forum control panel</h2>
</div> </div>
<table width="100%"> <table width="100%">
@ -61,11 +63,12 @@ function class_list($Selected=0){
<td>Min class write</td> <td>Min class write</td>
<td>Min class create</td> <td>Min class create</td>
<td>Autolock</td> <td>Autolock</td>
<td>Autolock weeks</td>
<td>Submit</td> <td>Submit</td>
</tr> </tr>
<? <?
$Row = 'b'; $Row = 'b';
while(list($ID, $CategoryID, $Sort, $Name, $Description, $MinClassRead, $MinClassWrite, $MinClassCreate, $AutoLock) = $DB->next_record()){ while(list($ID, $CategoryID, $Sort, $Name, $Description, $MinClassRead, $MinClassWrite, $MinClassCreate, $AutoLock, $AutoLockWeeks) = $DB->next_record()){
$Row = ($Row === 'a' ? 'b' : 'a'); $Row = ($Row === 'a' ? 'b' : 'a');
?> ?>
<tr class="row<?=$Row?>"> <tr class="row<?=$Row?>">
@ -109,6 +112,9 @@ function class_list($Selected=0){
<td> <td>
<input type="checkbox" name="autolock" <?=($AutoLock == '1')?'checked ':''?>/> <input type="checkbox" name="autolock" <?=($AutoLock == '1')?'checked ':''?>/>
</td> </td>
<td>
<input type="text" name="autolockweeks" value="<?=$AutoLockWeeks?>" />
</td>
<td> <td>
<input type="submit" name="submit" value="Edit" /> <input type="submit" name="submit" value="Edit" />
<input type="submit" name="submit" value="Delete" /> <input type="submit" name="submit" value="Delete" />
@ -161,6 +167,9 @@ function class_list($Selected=0){
<td> <td>
<input type="checkbox" name="autolock" checked /> <input type="checkbox" name="autolock" checked />
</td> </td>
<td>
<input type="text" name="autolockweeks" value="4" />
</td>
<td> <td>
<input type="submit" value="Create" /> <input type="submit" value="Create" />
</td> </td>