diff --git a/www/vicidial/admin.php b/www/vicidial/admin.php
index a36e7c37..d3e1b4c0 100644
--- a/www/vicidial/admin.php
+++ b/www/vicidial/admin.php
@@ -501,12 +501,13 @@ $lead_filter_sql = ereg_replace(";","",$lead_filter_sql);
# 60623-1159 - Fixed Scheduled Callbacks over-filtering bug and filter_sql bug
# 60808-1147 - changed filtering for and added instructions for consutative transfers
# 60816-1552 - added allcalls_delay start delay for recordings in vicidial.php
+# 60817-2226 - fixed bug that would not allow lead recycling of non-selectable statuses
#
# make sure you have added a user to the vicidial_users MySQL table with at least user_level 8 to access this page the first time
-$version = '2.0.57';
-$build = '60816-1552';
+$version = '2.0.58';
+$build = '60817-2226';
$STARTtime = date("U");
@@ -4250,28 +4251,32 @@ echo "
Dial status 1:
$o) {
+ while ($statuses_to_print > $o)
+ {
$rowx=mysql_fetch_row($rslt);
$statuses_list .= "\n";
$statname_list["$rowx[0]"] = "$rowx[1]";
+ $LRstatuses_list .= "\n";
if (eregi("Y",$rowx[2]))
{$HKstatuses_list .= "\n";}
$o++;
- }
+ }
- $stmt="SELECT * from vicidial_campaign_statuses where campaign_id='$campaign_id' and selectable='Y' order by status";
+ $stmt="SELECT * from vicidial_campaign_statuses where campaign_id='$campaign_id' order by status";
$rslt=mysql_query($stmt, $link);
$Cstatuses_to_print = mysql_num_rows($rslt);
$o=0;
- while ($Cstatuses_to_print > $o) {
+ while ($Cstatuses_to_print > $o)
+ {
$rowx=mysql_fetch_row($rslt);
$statuses_list .= "\n";
$statname_list["$rowx[0]"] = "$rowx[1]";
+ $LRstatuses_list .= "\n";
if (eregi("Y",$rowx[2]))
{$HKstatuses_list .= "\n";}
$o++;
- }
+ }
echo "$statuses_list";
echo "\n";
echo "$NWB#vicidial_campaigns-dial_status$NWE