Per-state dispo hack
Posted: Fri Mar 27, 2015 9:21 am
We are running into a constant problem where agents are dispo'ing calls wrong simply out of muscle memory. We have two states that use a slightly different dispo code (K1-G4 for CA and CO and then G1-G4 for other 48). When the call is coded incorrectly it caused a cascade of problems that mess with our QC dept among other things.
My intentions are to hide a list of dipos if the customer state matches one list and then hide that list and display another if customer state not in list. All other dispositions should be displayed as usual. I've tested on a dev server but on a fronter campaign. When it is in production it will be used for a closer campaign, does this matter?
Here is what I dropped in our 'vicidial.php' on our test dev server, modification starts at line 10709 inside the JS function "DispoSelectContent_create"
What will this break? I plan on testing it in production this Saturday when our agent staff is reduced and the atmosphere is a little more conducive to in-production testing.
My intentions are to hide a list of dipos if the customer state matches one list and then hide that list and display another if customer state not in list. All other dispositions should be displayed as usual. I've tested on a dev server but on a fronter campaign. When it is in production it will be used for a closer campaign, does this matter?
Here is what I dropped in our 'vicidial.php' on our test dev server, modification starts at line 10709 inside the JS function "DispoSelectContent_create"
- Code: Select all
var statesNoDispoCACO = ['CA','CO'];
var noDisplayDisposCACO = ['G1','G2','G3','G4'];
var noDisplayDisposNonCACO = ['K1','K2','K3','K4'];
else{ //State per-state dispo modification
if ( (statesNoDispoCACO.indexOf(document.vicidial_form.state.value) >= 0) ) //If state in CA or CO
{
if (noDisplayDisposCACO.indexOf(VARstatuses[loop_ct]) >= 0) //If dispo is in G1, G2, G3, G4
{
//do not display dispo
}else{
dispo_HTML = dispo_HTML + "<a href=\"#\" onclick=\"DispoSelectContent_create('" + VARstatuses[loop_ct] + "','ADD');return false;\">" + VARstatuses[loop_ct] + " - " + VARstatusnames[loop_ct] + "</a> " + CBflag + "<br /><br />";
}
}
if ( (statesNoDispoCACO.indexOf(document.vicidial_form.state.value) < 0) ) //If state NOT in CA or CO
{
if (noDisplayDisposNonCACO.indexOf(VARstatuses[loop_ct]) >= 0) //If dispo is in K1, K2, K3, K4
{
//do not display dispo
}else{
dispo_HTML = dispo_HTML + "<a href=\"#\" onclick=\"DispoSelectContent_create('" + VARstatuses[loop_ct] + "','ADD');return false;\">" + VARstatuses[loop_ct] + " - " + VARstatusnames[loop_ct] + "</a> " + CBflag + "<br /><br />";
}
}
}
What will this break? I plan on testing it in production this Saturday when our agent staff is reduced and the atmosphere is a little more conducive to in-production testing.