Page 1 of 1

Lead Recycling - Attempt Delay limitation

PostPosted: Sun Feb 26, 2023 9:00 pm
by gcd135
CAMPAIGN LEAD RECYCLE NOT ADDED - Please go back and look at the data you entered
status must be between 1 and 6 characters in length
attempt delay must be at least 120 seconds and less than 43200 seconds or 12 hours


Is there any reason why its less than 12 hours only?
can I edit the source and remove the limitation?

Re: Lead Recycling - Attempt Delay limitation

PostPosted: Sun Feb 26, 2023 9:22 pm
by gcd135
ok after some search , apologies for not searching before posting...
viewtopic.php?f=4&t=38660&p=135185&hilit=lead+recycle#p135185
and most of here saying 'refrain from using it'...

how can we automate to retry specific status after 27 hours(approx) with the maximum of 3 times?

Re: Lead Recycling - Attempt Delay limitation

PostPosted: Mon Feb 27, 2023 7:27 am
by mflorell
The Lead Recycling maximum delay is currently 43199(almost 12 hours) and Lead Recycling was specifically designed never to cross into a second day, hard-coded into the system. So changing this would also be a major project with a ton of testing needed to make sure it does not adversely affect other features.

As for alternatives, I would suggest looking into using a Settings Container with some custom SQL in it with the "AST_settings_container_SQL.pl" script in a crontab entry to reset specific lead statuses at specific times on a regularly scheduled basis. We have set up many clients with this kind of process for all kinds of automated processes, including for extended lead resetting like you have described. Here is some example SQL to put into a Settings Container for this script:

UPDATE vicidial_list SET called_since_last_reset='N' WHERE ( (list_id IN(select list_id from vicidial_lists where campaign_id='TESTCAMP')) and (status IN('NA','N','B')) and called_since_last_reset!='N' and (last_local_call_time < CONCAT(DATE_ADD(CURDATE(), INTERVAL -1 DAY),' ',DATE_ADD(CURTIME(), INTERVAL -3 HOUR));