Fix for field chooser issue and more code updates for PHP8 compatibility in web lead loaders
Added summarized error output, fuzzy field auto-detection for custom layout, Issue #1561 from Acidshock in 5th gen lead loader git-svn-id: svn://192.168.202.10@3977 3d104415-ff17-0410-8863-d5cf3c621b8a
This commit is contained in:
@@ -899,6 +899,9 @@ OTHER CHANGES:
|
|||||||
256. Added In-Group "Transfer Talk Minimum" features, allowing for restruction
|
256. Added In-Group "Transfer Talk Minimum" features, allowing for restruction
|
||||||
on agent screen transfers before talk time threshold.
|
on agent screen transfers before talk time threshold.
|
||||||
|
|
||||||
|
257. Added Web Lead Loader feature to auto-detect custom column layouts in lead
|
||||||
|
files, as well as new load loading process rejection summaries
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -5890,6 +5890,7 @@ INSERT INTO vicidial_settings_containers(container_id,container_notes,container_
|
|||||||
INSERT INTO vicidial_settings_containers(container_id,container_notes,container_type,user_group,container_entry) VALUES ('VERM_STATUS_NAMES_OVERRIDE','Override dialer status names in enhanced reporting','OTHER','---ALL---','; For each status name you want overridden, type the status followed by\r\n; a pipe, then the new status name\r\n; Ex:\r\n; NZ|Taumatawhakatangihangakoauauotamateaturipukakapikimaungahoronukupoka\r\n201214|Request To Cancel\r\n210200|No Answer-Incomplete Call\r\n210201|Contact Established\r\n210202|Provider Review - HB\r\n210203|Promise to Pay\r\n210204|Setup Payment Plan\r\n210205|Research-Inquiry\r\n210206|Voice Mail Left - HB\r\n210207|Do Not Call\r\n210208|Appeal Verification\r\n210209|Bad Phone\r\n210210|Bad Address\r\n210211|Direct Pay Verification\r\n210213|Provider Approved\r\n210215|Update Notes Only\r\n210216|Voicemail-No Status Change\r\n210217|Sent Letter Request - HB\r\n210218|Auto VoiceMail Left - HB\r\n210219|Auto VoiceMail-No Status Change\r\n210302|Provider Review - LB\r\n210306|Voice Mail Left - LB\r\n210317|Sent Letter Request - LB\r\n210318|Auto VoiceMail Left - LB\r\n211503|Provider - COVID-19\r\n211603|Transferred Call to MLA\r\n'), ('VERM_REPORT_OPTIONS','Container for customizing VERM report output','OTHER','---ALL---','; This is the report queue used if none is chosen by the user\r\n; It\'s preloaded in some forms as well\r\nVERM_default_report_queue => ALL\r\n\r\n; If there are statuses to exclude from reports, list them here\r\n; Separate with commas. Default is AFTHRS\r\nexc_addtl_statuses => AFTHRS\r\n\r\n; Set the below value to 1 (or anything non-blank/non-zero) in order to \r\n; show the agents ID in addition to their full name in the report results\r\nshow_full_agent_info => 1\r\n\r\n; Some reports count \"lost\" calls - which are defined by the below variable\r\n; listing what you define as \"lost\" dispos. Separate with commas.\r\nlost_statuses => LOST,210208,DISPO\r\n\r\n; You can create a detailed IVR survey report for ingroups by defining\r\n; \"ivr_survey_ingroups_detail\" and \"ivr_survey_ingroups_voicemails.\"\r\n; For \"details\", supply an ingroup used as a tracking group on call menus.\r\n; Then, add a pipe and after that list all call menus that use the ingroup\r\n; as the tracking group, separating each with a comma\r\n; To track whether the calls went to voicemail, list every call menu/option\r\n; combination that goes to voicemail, separating the call menu from the \r\n; option with a pipe. One callmenu/option combo per line.\r\nivr_survey_ingroups_detail => 521205|561401,561402,561403,561404,561505\r\nivr_survey_ingroups_voicemails => 561505|t\r\n\r\n; #####################################################\r\n; # ALL of the below are used in the wallboard report #\r\n; #####################################################\r\nVERM_default_outb_widget_queue => ALL_OUT\r\nVERM_default_inb_widget_queue1 => 514915v_USA_Shared\r\nVERM_default_inb_widget_queue2 => 515915v_MLA_Shared\r\n\r\n; Used specifically for the SLA widget\r\n; Uses ingroups - separate multiple ingroups by commas\r\n; Comment out or leave blank to count all ingroups\r\nSLA_LEVEL_PCT_ingroups => 514915v,515915v\r\n\r\n; This removes remote agents from the wallboard reports\r\n; Comment out to include remote agents (or set to zero)\r\nomit_remote_agents => 1\r\n\r\n\r\n; #### AUTO DOWNLOAD ####\r\n; If the "total calls" value on any report requested exceeds the below \r\n; limit, automatically download the three "DETAILS" reports instead\r\n; of attempting to display that many records on-screen\r\nauto_download_limit => 50000\r\n\r\n; #### OUTCOMES report overrides ####\r\n; Use "outcome_lagged_status_overrides" for conditions where the call \r\n; record in the vicidial_log or vicidial_closer_log table has no uniqueid\r\n; value despite having a status/outcome, which can indicate a call \r\n; affected by network lag for certain statuses. This will change the call \r\n; status to "LAGGED". Separate statuses with commas. Default is the \r\n; automatic "PU" status.\r\noutcome_lagged_status_overrides => PU\r\n\r\n; Use "unknown_network_statuses" to change call statuses to read "Network/\r\n; LAGGED" on the OUTCOMES report. Separate statuses with commas.\r\n; IMPORTANT: if you are using the outcome_lagged_status_overrides option \r\n; above, make sure "LAGGED" is one of the unknown_network_statuses here\r\n; unknown_network_statuses => LAGGED\r\n\r\n; Use "outcome_status_overrides" to change one status to another on the \r\n; OUTCOMES report. Overrides are comma-separated pairs of dispositions \r\n; where the first disposition is the disposition to change, and the second\r\n; is the disposition to change to. Separate pairs with a pipe character as\r\n; in the below example. Off by default.\r\n; outcome_status_overrides => CBHOLD,DISPO|XFER,AL');
|
INSERT INTO vicidial_settings_containers(container_id,container_notes,container_type,user_group,container_entry) VALUES ('VERM_STATUS_NAMES_OVERRIDE','Override dialer status names in enhanced reporting','OTHER','---ALL---','; For each status name you want overridden, type the status followed by\r\n; a pipe, then the new status name\r\n; Ex:\r\n; NZ|Taumatawhakatangihangakoauauotamateaturipukakapikimaungahoronukupoka\r\n201214|Request To Cancel\r\n210200|No Answer-Incomplete Call\r\n210201|Contact Established\r\n210202|Provider Review - HB\r\n210203|Promise to Pay\r\n210204|Setup Payment Plan\r\n210205|Research-Inquiry\r\n210206|Voice Mail Left - HB\r\n210207|Do Not Call\r\n210208|Appeal Verification\r\n210209|Bad Phone\r\n210210|Bad Address\r\n210211|Direct Pay Verification\r\n210213|Provider Approved\r\n210215|Update Notes Only\r\n210216|Voicemail-No Status Change\r\n210217|Sent Letter Request - HB\r\n210218|Auto VoiceMail Left - HB\r\n210219|Auto VoiceMail-No Status Change\r\n210302|Provider Review - LB\r\n210306|Voice Mail Left - LB\r\n210317|Sent Letter Request - LB\r\n210318|Auto VoiceMail Left - LB\r\n211503|Provider - COVID-19\r\n211603|Transferred Call to MLA\r\n'), ('VERM_REPORT_OPTIONS','Container for customizing VERM report output','OTHER','---ALL---','; This is the report queue used if none is chosen by the user\r\n; It\'s preloaded in some forms as well\r\nVERM_default_report_queue => ALL\r\n\r\n; If there are statuses to exclude from reports, list them here\r\n; Separate with commas. Default is AFTHRS\r\nexc_addtl_statuses => AFTHRS\r\n\r\n; Set the below value to 1 (or anything non-blank/non-zero) in order to \r\n; show the agents ID in addition to their full name in the report results\r\nshow_full_agent_info => 1\r\n\r\n; Some reports count \"lost\" calls - which are defined by the below variable\r\n; listing what you define as \"lost\" dispos. Separate with commas.\r\nlost_statuses => LOST,210208,DISPO\r\n\r\n; You can create a detailed IVR survey report for ingroups by defining\r\n; \"ivr_survey_ingroups_detail\" and \"ivr_survey_ingroups_voicemails.\"\r\n; For \"details\", supply an ingroup used as a tracking group on call menus.\r\n; Then, add a pipe and after that list all call menus that use the ingroup\r\n; as the tracking group, separating each with a comma\r\n; To track whether the calls went to voicemail, list every call menu/option\r\n; combination that goes to voicemail, separating the call menu from the \r\n; option with a pipe. One callmenu/option combo per line.\r\nivr_survey_ingroups_detail => 521205|561401,561402,561403,561404,561505\r\nivr_survey_ingroups_voicemails => 561505|t\r\n\r\n; #####################################################\r\n; # ALL of the below are used in the wallboard report #\r\n; #####################################################\r\nVERM_default_outb_widget_queue => ALL_OUT\r\nVERM_default_inb_widget_queue1 => 514915v_USA_Shared\r\nVERM_default_inb_widget_queue2 => 515915v_MLA_Shared\r\n\r\n; Used specifically for the SLA widget\r\n; Uses ingroups - separate multiple ingroups by commas\r\n; Comment out or leave blank to count all ingroups\r\nSLA_LEVEL_PCT_ingroups => 514915v,515915v\r\n\r\n; This removes remote agents from the wallboard reports\r\n; Comment out to include remote agents (or set to zero)\r\nomit_remote_agents => 1\r\n\r\n\r\n; #### AUTO DOWNLOAD ####\r\n; If the "total calls" value on any report requested exceeds the below \r\n; limit, automatically download the three "DETAILS" reports instead\r\n; of attempting to display that many records on-screen\r\nauto_download_limit => 50000\r\n\r\n; #### OUTCOMES report overrides ####\r\n; Use "outcome_lagged_status_overrides" for conditions where the call \r\n; record in the vicidial_log or vicidial_closer_log table has no uniqueid\r\n; value despite having a status/outcome, which can indicate a call \r\n; affected by network lag for certain statuses. This will change the call \r\n; status to "LAGGED". Separate statuses with commas. Default is the \r\n; automatic "PU" status.\r\noutcome_lagged_status_overrides => PU\r\n\r\n; Use "unknown_network_statuses" to change call statuses to read "Network/\r\n; LAGGED" on the OUTCOMES report. Separate statuses with commas.\r\n; IMPORTANT: if you are using the outcome_lagged_status_overrides option \r\n; above, make sure "LAGGED" is one of the unknown_network_statuses here\r\n; unknown_network_statuses => LAGGED\r\n\r\n; Use "outcome_status_overrides" to change one status to another on the \r\n; OUTCOMES report. Overrides are comma-separated pairs of dispositions \r\n; where the first disposition is the disposition to change, and the second\r\n; is the disposition to change to. Separate pairs with a pipe character as\r\n; in the below example. Off by default.\r\n; outcome_status_overrides => CBHOLD,DISPO|XFER,AL');
|
||||||
INSERT INTO vicidial_settings_containers(container_id,container_notes,container_type,user_group,container_entry) VALUES ('VICIDIAL_TIMEOFF_SETTINGS','Settings for time-off admin utility','OTHER','---ALL---','; Comma-delimited time-off codes - MANDATORY, must have at least one defined. \r\n; Default is \'VAC\' for vacation\r\ntimeoff_types => VAC\r\n\r\n; optional, if set to \'1\' will show all viewable agents, even ones with no \r\n; time off for month. Default is 0\r\ndisplay_all_agents => 0\r\n\r\n; optional, used to filter users displayed, in addition to user_group \r\n; permissions\r\nuser_filter_SQL => \r\n\r\n; optional, uses columns from vicidial_users table. Defaults to \r\n; full_name asc, user asc if commented out or non-existent\r\n; sort_SQL => full_name asc, user asc\r\n\r\n; include custom coding for misc download coding where \"custom_download\" \r\n; marked in agent_timeoff_script.php - DO NOT USE WITHOUT CODING KNOWLEDGE\r\n; set to \'1\' to activate\r\ncustom_download => 0');
|
INSERT INTO vicidial_settings_containers(container_id,container_notes,container_type,user_group,container_entry) VALUES ('VICIDIAL_TIMEOFF_SETTINGS','Settings for time-off admin utility','OTHER','---ALL---','; Comma-delimited time-off codes - MANDATORY, must have at least one defined. \r\n; Default is \'VAC\' for vacation\r\ntimeoff_types => VAC\r\n\r\n; optional, if set to \'1\' will show all viewable agents, even ones with no \r\n; time off for month. Default is 0\r\ndisplay_all_agents => 0\r\n\r\n; optional, used to filter users displayed, in addition to user_group \r\n; permissions\r\nuser_filter_SQL => \r\n\r\n; optional, uses columns from vicidial_users table. Defaults to \r\n; full_name asc, user asc if commented out or non-existent\r\n; sort_SQL => full_name asc, user asc\r\n\r\n; include custom coding for misc download coding where \"custom_download\" \r\n; marked in agent_timeoff_script.php - DO NOT USE WITHOUT CODING KNOWLEDGE\r\n; set to \'1\' to activate\r\ncustom_download => 0');
|
||||||
INSERT INTO vicidial_settings_containers(container_id,container_notes,container_type,user_group,container_entry) VALUES ('FAILED_DIAL_MESSAGE_OVERRIDE','Failed Dial Message Override','OTHER','---ALL---',"Unable to complete the call at this time.\nPlease try again later.");
|
INSERT INTO vicidial_settings_containers(container_id,container_notes,container_type,user_group,container_entry) VALUES ('FAILED_DIAL_MESSAGE_OVERRIDE','Failed Dial Message Override','OTHER','---ALL---',"Unable to complete the call at this time.\nPlease try again later.");
|
||||||
|
INSERT INTO vicidial_settings_containers(container_id,container_notes,container_type,user_group,container_entry) VALUES ('LISTLOADER_AUTO_MAPPING', 'Contains aliases for auto-mapping fields in listloader', 'OTHER', '---ALL---', '; Use this to auto-map fields in the listloader when you attempt to load\r\n; a file. This will populate the \'File data\' dropdown menus \r\n; You may define additional aliases by adding them to the below list.\r\n; They must be of the form \"alias => vicidial_field\". One per line.\r\n; The \"vicidial_field\" value must match the name of a column in the\r\n; vicidial_list table\r\n\r\n\'phone\' => \'phonenumber\'\r\n\'phoneno\' => \'phonenumber\'\r\n\'phone1\' => \'phonenumber\'\r\n\'primaryphone\' => \'phonenumber\'\r\n\'mainphone\' => \'phonenumber\'\r\n\'telephone\' => \'phonenumber\'\r\n\'tel\' => \'phonenumber\'\r\n\'cell\' => \'phonenumber\'\r\n\'cellphone\' => \'phonenumber\'\r\n\'mobile\' => \'phonenumber\'\r\n\'mobilephone\' => \'phonenumber\'\r\n\'workphone\' => \'phonenumber\'\r\n\'homephone\' => \'phonenumber\'\r\n\'fname\' => \'firstname\'\r\n\'first\' => \'firstname\'\r\n\'givenname\' => \'firstname\'\r\n\'lname\' => \'lastname\'\r\n\'last\' => \'lastname\'\r\n\'surname\' => \'lastname\'\r\n\'familyname\' => \'lastname\'\r\n\'mi\' => \'middleinitial\'\r\n\'middle\' => \'middleinitial\'\r\n\'middlename\' => \'middleinitial\'\r\n\'minit\' => \'middleinitial\'\r\n\'addr\' => \'address1\'\r\n\'addr1\' => \'address1\'\r\n\'street\' => \'address1\'\r\n\'streetaddress\' => \'address1\'\r\n\'address\' => \'address1\'\r\n\'addr2\' => \'address2\'\r\n\'street2\' => \'address2\'\r\n\'suite\' => \'address2\'\r\n\'apt\' => \'address2\'\r\n\'apartment\' => \'address2\'\r\n\'unit\' => \'address2\'\r\n\'addr3\' => \'address3\'\r\n\'zip\' => \'postalcode\'\r\n\'zipcode\' => \'postalcode\'\r\n\'postcode\' => \'postalcode\'\r\n\'postalzip\' => \'postalcode\'\r\n\'st\' => \'state\'\r\n\'stateprovince\' => \'state\'\r\n\'region\' => \'state\'\r\n\'prov\' => \'province\'\r\n\'country\' => \'countrycode\'\r\n\'countrycd\' => \'countrycode\'\r\n\'cc\' => \'countrycode\'\r\n\'sex\' => \'gender\'\r\n\'dob\' => \'dateofbirth\'\r\n\'birthday\' => \'dateofbirth\'\r\n\'birthdate\' => \'dateofbirth\'\r\n\'birth\' => \'dateofbirth\'\r\n\'altphone\' => \'altphone\'\r\n\'phone2\' => \'altphone\'\r\n\'secondaryphone\' => \'altphone\'\r\n\'otherphone\' => \'altphone\'\r\n\'alternatephone\' => \'altphone\'\r\n\'emailaddress\' => \'email\'\r\n\'emailaddr\' => \'email\'\r\n\'mail\' => \'email\'\r\n\'note\' => \'comments\'\r\n\'notes\' => \'comments\'\r\n\'comment\' => \'comments\'\r\n\'remark\' => \'comments\'\r\n\'remarks\' => \'comments\'\r\n\'description\' => \'comments\'\r\n\'vendorcode\' => \'vendorleadcode\'\r\n\'vendorid\' => \'vendorleadcode\'\r\n\'vendorleadid\' => \'vendorleadcode\'\r\n\'leadcode\' => \'vendorleadcode\'\r\n\'externalid\' => \'vendorleadcode\'\r\n\'sourcecode\' => \'sourceid\'\r\n\'source\' => \'sourceid\'\r\n\'leadsource\' => \'sourceid\'\r\n\'listid\' => \'listid\'\r\n\'list\' => \'listid\'\r\n\'phonecode\' => \'phonecode\'\r\n\'dialcode\' => \'phonecode\'\r\n\'countrydialing\' => \'phonecode\'\r\n\'prefix\' => \'title\'\r\n\'salutation\' => \'title\'\r\n\'mr\' => \'title\'\r\n\'securityphrase\' => \'securityphrase\'\r\n\'security\' => \'securityphrase\'\r\n\'pin\' => \'securityphrase\'\r\n\'password\' => \'securityphrase\'\r\n\'priority\' => \'rank\'\r\n\'score\' => \'rank\'\r\n\'weight\' => \'rank\'\r\n\'agent\' => \'owner\'\r\n\'assignedto\' => \'owner\'\r\n\'rep\' => \'owner\'\r\n\'town\' => \'city\'\r\n\r\n\r\n; This is the minimum required score that the header field must return\r\n; when processed with the Levenshtein distance algorithm. Default is 70.\r\n; If you wish to raise or lower it, uncomment the below line and change the \r\n; score value to whatever you wish\r\n; minimum_required_score => 70\r\n');
|
||||||
|
|
||||||
INSERT INTO `wallboard_widgets` VALUES ('queues_widget_1','AGENTS_AND_QUEUES','queues','','TEXT',5,'N',1,'Queue Information','','',NULL,'','',NULL,2),('queues_widget_0','AGENTS_AND_QUEUES','queues','','LOGO',2,'N',1,NULL,'','',NULL,'','',NULL,1),('queues_widget_2','AGENTS_AND_QUEUES','queues','SLA Level %','SLA_LEVEL_PCT',1,'N',1,NULL,'','>60',NULL,'','',NULL,3),('queues_widget_3','AGENTS_AND_QUEUES','queues','Outbound calls','LIVE_QUEUE_INFO',1,'N',1,'','201201','','','','','yellow_alarm,|red_alarm,',4),('queues_widget_4','AGENTS_AND_QUEUES','queues','USA Ded Inbound','LIVE_QUEUE_INFO',1,'N',1,'','ALL_IN','','','','','yellow_alarm,|red_alarm,',5),('queues_widget_5','AGENTS_AND_QUEUES','queues','MLA Ded Inbound','LIVE_QUEUE_INFO',1,'N',1,'','514911','','','','','yellow_alarm,|red_alarm,',6),('queues_widget_6','AGENTS_AND_QUEUES','queues','N Waiting Calls','N_WAITING_CALLS',1,'N',1,NULL,'','',NULL,'','',NULL,7),('queues_widget_7','AGENTS_AND_QUEUES','queues','Offered Calls','OFFERED_CALLS',1,'N',1,NULL,'','',NULL,'','',NULL,8),('queues_widget_8','AGENTS_AND_QUEUES','queues','Answered Calls','ANSWERED_CALLS',1,'N',1,NULL,'','',NULL,'','',NULL,9),('queues_widget_9','AGENTS_AND_QUEUES','queues','Lost Calls','LOST_CALLS',1,'N',1,NULL,'','',NULL,'','',NULL,10),('queues_widget_10','AGENTS_AND_QUEUES','queues','Longest Wait','LONGEST_WAIT',1,'N',1,NULL,'','',NULL,'','',NULL,11),('queues_widget_11','AGENTS_AND_QUEUES','queues','Live Queues','LIVE_QUEUES',1,'Y',1,NULL,'','',NULL,'','',NULL,12),('queues_widget_12','AGENTS_AND_QUEUES','queues','Live Calls','LIVE_CALLS',1,'Y',2,NULL,'','',NULL,'','',NULL,13),('agent_widget_0','AGENTS_AND_QUEUES','agents','','LOGO',2,'N',1,NULL,'','',NULL,'','',NULL,1),('agent_widget_1','AGENTS_AND_QUEUES','agents','N Waiting Calls','N_WAITING_CALLS',1,'N',1,NULL,'','',NULL,'','',NULL,2),('agent_widget_2','AGENTS_AND_QUEUES','agents','Agents Ready','AGENTS_READY',1,'N',1,NULL,'','',NULL,'','',NULL,3),('agent_widget_3','AGENTS_AND_QUEUES','agents','Agents On Call','N_AGENTS_ON_CALL',1,'N',1,NULL,'','',NULL,'','',NULL,4),('agent_widget_4','AGENTS_AND_QUEUES','agents','N Answered Calls','N_ANSWERED_CALLS',1,'N',1,NULL,'','',NULL,'','',NULL,5),('agent_widget_5','AGENTS_AND_QUEUES','agents','Clock','CLOCK',1,'N',1,NULL,'','',NULL,'','',NULL,6),('agent_widget_6','AGENTS_AND_QUEUES','agents','Live Agents','LIVE_AGENTS',1,'Y',3,NULL,'','',NULL,'','',NULL,7);
|
INSERT INTO `wallboard_widgets` VALUES ('queues_widget_1','AGENTS_AND_QUEUES','queues','','TEXT',5,'N',1,'Queue Information','','',NULL,'','',NULL,2),('queues_widget_0','AGENTS_AND_QUEUES','queues','','LOGO',2,'N',1,NULL,'','',NULL,'','',NULL,1),('queues_widget_2','AGENTS_AND_QUEUES','queues','SLA Level %','SLA_LEVEL_PCT',1,'N',1,NULL,'','>60',NULL,'','',NULL,3),('queues_widget_3','AGENTS_AND_QUEUES','queues','Outbound calls','LIVE_QUEUE_INFO',1,'N',1,'','201201','','','','','yellow_alarm,|red_alarm,',4),('queues_widget_4','AGENTS_AND_QUEUES','queues','USA Ded Inbound','LIVE_QUEUE_INFO',1,'N',1,'','ALL_IN','','','','','yellow_alarm,|red_alarm,',5),('queues_widget_5','AGENTS_AND_QUEUES','queues','MLA Ded Inbound','LIVE_QUEUE_INFO',1,'N',1,'','514911','','','','','yellow_alarm,|red_alarm,',6),('queues_widget_6','AGENTS_AND_QUEUES','queues','N Waiting Calls','N_WAITING_CALLS',1,'N',1,NULL,'','',NULL,'','',NULL,7),('queues_widget_7','AGENTS_AND_QUEUES','queues','Offered Calls','OFFERED_CALLS',1,'N',1,NULL,'','',NULL,'','',NULL,8),('queues_widget_8','AGENTS_AND_QUEUES','queues','Answered Calls','ANSWERED_CALLS',1,'N',1,NULL,'','',NULL,'','',NULL,9),('queues_widget_9','AGENTS_AND_QUEUES','queues','Lost Calls','LOST_CALLS',1,'N',1,NULL,'','',NULL,'','',NULL,10),('queues_widget_10','AGENTS_AND_QUEUES','queues','Longest Wait','LONGEST_WAIT',1,'N',1,NULL,'','',NULL,'','',NULL,11),('queues_widget_11','AGENTS_AND_QUEUES','queues','Live Queues','LIVE_QUEUES',1,'Y',1,NULL,'','',NULL,'','',NULL,12),('queues_widget_12','AGENTS_AND_QUEUES','queues','Live Calls','LIVE_CALLS',1,'Y',2,NULL,'','',NULL,'','',NULL,13),('agent_widget_0','AGENTS_AND_QUEUES','agents','','LOGO',2,'N',1,NULL,'','',NULL,'','',NULL,1),('agent_widget_1','AGENTS_AND_QUEUES','agents','N Waiting Calls','N_WAITING_CALLS',1,'N',1,NULL,'','',NULL,'','',NULL,2),('agent_widget_2','AGENTS_AND_QUEUES','agents','Agents Ready','AGENTS_READY',1,'N',1,NULL,'','',NULL,'','',NULL,3),('agent_widget_3','AGENTS_AND_QUEUES','agents','Agents On Call','N_AGENTS_ON_CALL',1,'N',1,NULL,'','',NULL,'','',NULL,4),('agent_widget_4','AGENTS_AND_QUEUES','agents','N Answered Calls','N_ANSWERED_CALLS',1,'N',1,NULL,'','',NULL,'','',NULL,5),('agent_widget_5','AGENTS_AND_QUEUES','agents','Clock','CLOCK',1,'N',1,NULL,'','',NULL,'','',NULL,6),('agent_widget_6','AGENTS_AND_QUEUES','agents','Live Agents','LIVE_AGENTS',1,'Y',3,NULL,'','',NULL,'','',NULL,7);
|
||||||
|
|
||||||
@@ -5897,4 +5898,4 @@ INSERT INTO `wallboard_reports` VALUES ('AGENTS_AND_QUEUES','Agents and Queues',
|
|||||||
|
|
||||||
UPDATE system_settings set vdc_agent_api_active='1';
|
UPDATE system_settings set vdc_agent_api_active='1';
|
||||||
|
|
||||||
UPDATE system_settings SET db_schema_version='1739',db_schema_update_date=NOW(),reload_timestamp=NOW();
|
UPDATE system_settings SET db_schema_version='1740',db_schema_update_date=NOW(),reload_timestamp=NOW();
|
||||||
|
|||||||
@@ -3084,3 +3084,7 @@ index (status)
|
|||||||
ALTER TABLE system_settings ADD max_inbound_auto_reenable ENUM('0','1','2','3','4','5','6') default '1';
|
ALTER TABLE system_settings ADD max_inbound_auto_reenable ENUM('0','1','2','3','4','5','6') default '1';
|
||||||
|
|
||||||
UPDATE system_settings SET db_schema_version='1739',db_schema_update_date=NOW() where db_schema_version < 1739;
|
UPDATE system_settings SET db_schema_version='1739',db_schema_update_date=NOW() where db_schema_version < 1739;
|
||||||
|
|
||||||
|
INSERT INTO vicidial_settings_containers(container_id,container_notes,container_type,user_group,container_entry) VALUES ('LISTLOADER_AUTO_MAPPING', 'Contains aliases for auto-mapping fields in listloader', 'OTHER', '---ALL---', '; Use this to auto-map fields in the listloader when you attempt to load\r\n; a file. This will populate the \'File data\' dropdown menus \r\n; You may define additional aliases by adding them to the below list.\r\n; They must be of the form \"alias => vicidial_field\". One per line.\r\n; The \"vicidial_field\" value must match the name of a column in the\r\n; vicidial_list table\r\n\r\n\'phone\' => \'phonenumber\'\r\n\'phoneno\' => \'phonenumber\'\r\n\'phone1\' => \'phonenumber\'\r\n\'primaryphone\' => \'phonenumber\'\r\n\'mainphone\' => \'phonenumber\'\r\n\'telephone\' => \'phonenumber\'\r\n\'tel\' => \'phonenumber\'\r\n\'cell\' => \'phonenumber\'\r\n\'cellphone\' => \'phonenumber\'\r\n\'mobile\' => \'phonenumber\'\r\n\'mobilephone\' => \'phonenumber\'\r\n\'workphone\' => \'phonenumber\'\r\n\'homephone\' => \'phonenumber\'\r\n\'fname\' => \'firstname\'\r\n\'first\' => \'firstname\'\r\n\'givenname\' => \'firstname\'\r\n\'lname\' => \'lastname\'\r\n\'last\' => \'lastname\'\r\n\'surname\' => \'lastname\'\r\n\'familyname\' => \'lastname\'\r\n\'mi\' => \'middleinitial\'\r\n\'middle\' => \'middleinitial\'\r\n\'middlename\' => \'middleinitial\'\r\n\'minit\' => \'middleinitial\'\r\n\'addr\' => \'address1\'\r\n\'addr1\' => \'address1\'\r\n\'street\' => \'address1\'\r\n\'streetaddress\' => \'address1\'\r\n\'address\' => \'address1\'\r\n\'addr2\' => \'address2\'\r\n\'street2\' => \'address2\'\r\n\'suite\' => \'address2\'\r\n\'apt\' => \'address2\'\r\n\'apartment\' => \'address2\'\r\n\'unit\' => \'address2\'\r\n\'addr3\' => \'address3\'\r\n\'zip\' => \'postalcode\'\r\n\'zipcode\' => \'postalcode\'\r\n\'postcode\' => \'postalcode\'\r\n\'postalzip\' => \'postalcode\'\r\n\'st\' => \'state\'\r\n\'stateprovince\' => \'state\'\r\n\'region\' => \'state\'\r\n\'prov\' => \'province\'\r\n\'country\' => \'countrycode\'\r\n\'countrycd\' => \'countrycode\'\r\n\'cc\' => \'countrycode\'\r\n\'sex\' => \'gender\'\r\n\'dob\' => \'dateofbirth\'\r\n\'birthday\' => \'dateofbirth\'\r\n\'birthdate\' => \'dateofbirth\'\r\n\'birth\' => \'dateofbirth\'\r\n\'altphone\' => \'altphone\'\r\n\'phone2\' => \'altphone\'\r\n\'secondaryphone\' => \'altphone\'\r\n\'otherphone\' => \'altphone\'\r\n\'alternatephone\' => \'altphone\'\r\n\'emailaddress\' => \'email\'\r\n\'emailaddr\' => \'email\'\r\n\'mail\' => \'email\'\r\n\'note\' => \'comments\'\r\n\'notes\' => \'comments\'\r\n\'comment\' => \'comments\'\r\n\'remark\' => \'comments\'\r\n\'remarks\' => \'comments\'\r\n\'description\' => \'comments\'\r\n\'vendorcode\' => \'vendorleadcode\'\r\n\'vendorid\' => \'vendorleadcode\'\r\n\'vendorleadid\' => \'vendorleadcode\'\r\n\'leadcode\' => \'vendorleadcode\'\r\n\'externalid\' => \'vendorleadcode\'\r\n\'sourcecode\' => \'sourceid\'\r\n\'source\' => \'sourceid\'\r\n\'leadsource\' => \'sourceid\'\r\n\'listid\' => \'listid\'\r\n\'list\' => \'listid\'\r\n\'phonecode\' => \'phonecode\'\r\n\'dialcode\' => \'phonecode\'\r\n\'countrydialing\' => \'phonecode\'\r\n\'prefix\' => \'title\'\r\n\'salutation\' => \'title\'\r\n\'mr\' => \'title\'\r\n\'securityphrase\' => \'securityphrase\'\r\n\'security\' => \'securityphrase\'\r\n\'pin\' => \'securityphrase\'\r\n\'password\' => \'securityphrase\'\r\n\'priority\' => \'rank\'\r\n\'score\' => \'rank\'\r\n\'weight\' => \'rank\'\r\n\'agent\' => \'owner\'\r\n\'assignedto\' => \'owner\'\r\n\'rep\' => \'owner\'\r\n\'town\' => \'city\'\r\n\r\n\r\n; This is the minimum required score that the header field must return\r\n; when processed with the Levenshtein distance algorithm. Default is 70.\r\n; If you wish to raise or lower it, uncomment the below line and change the \r\n; score value to whatever you wish\r\n; minimum_required_score => 70\r\n');
|
||||||
|
|
||||||
|
UPDATE system_settings SET db_schema_version='1740',db_schema_update_date=NOW() where db_schema_version < 1740;
|
||||||
|
|||||||
File diff suppressed because it is too large
Load Diff
@@ -2,7 +2,7 @@
|
|||||||
# admin_listloader_fourth_gen.php - version 2.14
|
# admin_listloader_fourth_gen.php - version 2.14
|
||||||
# (based upon - new_listloader_superL.php script)
|
# (based upon - new_listloader_superL.php script)
|
||||||
#
|
#
|
||||||
# Copyright (C) 2024 Matt Florell,Joe Johnson <vicidial@gmail.com> LICENSE: AGPLv2
|
# Copyright (C) 2026 Matt Florell,Joe Johnson <vicidial@gmail.com> LICENSE: AGPLv2
|
||||||
#
|
#
|
||||||
# ViciDial web-based lead loader from formatted file
|
# ViciDial web-based lead loader from formatted file
|
||||||
#
|
#
|
||||||
@@ -83,10 +83,11 @@
|
|||||||
# 231207-1445 - Fix for web_loader_phone_strip duplicate check, issue #1498
|
# 231207-1445 - Fix for web_loader_phone_strip duplicate check, issue #1498
|
||||||
# 240320-1033 - Added misssing input variable filtering
|
# 240320-1033 - Added misssing input variable filtering
|
||||||
# 240801-1131 - Code updates for PHP8 compatibility
|
# 240801-1131 - Code updates for PHP8 compatibility
|
||||||
|
# 260415-1707 - Small field chooser fix and more code updates for PHP8 compatibility
|
||||||
#
|
#
|
||||||
|
|
||||||
$version = '2.14-81';
|
$version = '2.14-82';
|
||||||
$build = '240801-1131';
|
$build = '260415-1707';
|
||||||
|
|
||||||
require("dbconnect_mysqli.php");
|
require("dbconnect_mysqli.php");
|
||||||
require("functions.php");
|
require("functions.php");
|
||||||
@@ -101,110 +102,168 @@ if (file_exists('options.php'))
|
|||||||
$US='_';
|
$US='_';
|
||||||
$MT[0]='';
|
$MT[0]='';
|
||||||
|
|
||||||
$PHP_AUTH_USER=$_SERVER['PHP_AUTH_USER'];
|
$PHP_AUTH_USER=(array_key_exists('PHP_AUTH_USER', $_SERVER) ? $_SERVER['PHP_AUTH_USER'] : "");
|
||||||
$PHP_AUTH_PW=$_SERVER['PHP_AUTH_PW'];
|
$PHP_AUTH_PW=(array_key_exists('PHP_AUTH_PW', $_SERVER) ? $_SERVER['PHP_AUTH_PW'] : "");
|
||||||
$PHP_SELF=$_SERVER['PHP_SELF'];
|
$PHP_SELF=$_SERVER['PHP_SELF'];
|
||||||
$PHP_SELF = preg_replace('/\.php.*/i','.php',$PHP_SELF);
|
$PHP_SELF = preg_replace('/\.php.*/i','.php',$PHP_SELF);
|
||||||
$leadfile=$_FILES["leadfile"];
|
if (array_key_exists('leadfile', $_FILES))
|
||||||
|
{
|
||||||
|
$leadfile=$_FILES["leadfile"];
|
||||||
$LF_orig = $_FILES['leadfile']['name'];
|
$LF_orig = $_FILES['leadfile']['name'];
|
||||||
$LF_path = $_FILES['leadfile']['tmp_name'];
|
$LF_path = $_FILES['leadfile']['tmp_name'];
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
$leadfile="";
|
||||||
|
$LF_orig = "";
|
||||||
|
$LF_path = "";
|
||||||
|
}
|
||||||
if (isset($_GET["submit_file"])) {$submit_file=$_GET["submit_file"];}
|
if (isset($_GET["submit_file"])) {$submit_file=$_GET["submit_file"];}
|
||||||
elseif (isset($_POST["submit_file"])) {$submit_file=$_POST["submit_file"];}
|
elseif (isset($_POST["submit_file"])) {$submit_file=$_POST["submit_file"];}
|
||||||
if (isset($_GET["submit"])) {$submit=$_GET["submit"];}
|
else {$submit_file="";}
|
||||||
elseif (isset($_POST["submit"])) {$submit=$_POST["submit"];}
|
# if (isset($_GET["submit"])) {$submit=$_GET["submit"];}
|
||||||
if (isset($_GET["SUBMIT"])) {$SUBMIT=$_GET["SUBMIT"];}
|
# elseif (isset($_POST["submit"])) {$submit=$_POST["submit"];}
|
||||||
elseif (isset($_POST["SUBMIT"])) {$SUBMIT=$_POST["SUBMIT"];}
|
# if (isset($_GET["SUBMIT"])) {$SUBMIT=$_GET["SUBMIT"];}
|
||||||
|
# elseif (isset($_POST["SUBMIT"])) {$SUBMIT=$_POST["SUBMIT"];}
|
||||||
if (isset($_GET["leadfile_name"])) {$leadfile_name=$_GET["leadfile_name"];}
|
if (isset($_GET["leadfile_name"])) {$leadfile_name=$_GET["leadfile_name"];}
|
||||||
elseif (isset($_POST["leadfile_name"])) {$leadfile_name=$_POST["leadfile_name"];}
|
elseif (isset($_POST["leadfile_name"])) {$leadfile_name=$_POST["leadfile_name"];}
|
||||||
|
else {$leadfile_name="";}
|
||||||
if (isset($_FILES["leadfile"])) {$leadfile_name=$_FILES["leadfile"]['name'];}
|
if (isset($_FILES["leadfile"])) {$leadfile_name=$_FILES["leadfile"]['name'];}
|
||||||
if (isset($_GET["file_layout"])) {$file_layout=$_GET["file_layout"];}
|
if (isset($_GET["file_layout"])) {$file_layout=$_GET["file_layout"];}
|
||||||
elseif (isset($_POST["file_layout"])) {$file_layout=$_POST["file_layout"];}
|
elseif (isset($_POST["file_layout"])) {$file_layout=$_POST["file_layout"];}
|
||||||
|
else {$file_layout="";}
|
||||||
if (isset($_GET["OK_to_process"])) {$OK_to_process=$_GET["OK_to_process"];}
|
if (isset($_GET["OK_to_process"])) {$OK_to_process=$_GET["OK_to_process"];}
|
||||||
elseif (isset($_POST["OK_to_process"])) {$OK_to_process=$_POST["OK_to_process"];}
|
elseif (isset($_POST["OK_to_process"])) {$OK_to_process=$_POST["OK_to_process"];}
|
||||||
|
else {$OK_to_process="";}
|
||||||
if (isset($_GET["vendor_lead_code_field"])) {$vendor_lead_code_field=$_GET["vendor_lead_code_field"];}
|
if (isset($_GET["vendor_lead_code_field"])) {$vendor_lead_code_field=$_GET["vendor_lead_code_field"];}
|
||||||
elseif (isset($_POST["vendor_lead_code_field"])) {$vendor_lead_code_field=$_POST["vendor_lead_code_field"];}
|
elseif (isset($_POST["vendor_lead_code_field"])) {$vendor_lead_code_field=$_POST["vendor_lead_code_field"];}
|
||||||
|
else {$vendor_lead_code_field="-1";}
|
||||||
if (isset($_GET["source_id_field"])) {$source_id_field=$_GET["source_id_field"];}
|
if (isset($_GET["source_id_field"])) {$source_id_field=$_GET["source_id_field"];}
|
||||||
elseif (isset($_POST["source_id_field"])) {$source_id_field=$_POST["source_id_field"];}
|
elseif (isset($_POST["source_id_field"])) {$source_id_field=$_POST["source_id_field"];}
|
||||||
|
else {$source_id_field="-1";}
|
||||||
if (isset($_GET["list_id_field"])) {$list_id_field=$_GET["list_id_field"];}
|
if (isset($_GET["list_id_field"])) {$list_id_field=$_GET["list_id_field"];}
|
||||||
elseif (isset($_POST["list_id_field"])) {$list_id_field=$_POST["list_id_field"];}
|
elseif (isset($_POST["list_id_field"])) {$list_id_field=$_POST["list_id_field"];}
|
||||||
|
else {$list_id_field="-1";}
|
||||||
if (isset($_GET["phone_code_field"])) {$phone_code_field=$_GET["phone_code_field"];}
|
if (isset($_GET["phone_code_field"])) {$phone_code_field=$_GET["phone_code_field"];}
|
||||||
elseif (isset($_POST["phone_code_field"])) {$phone_code_field=$_POST["phone_code_field"];}
|
elseif (isset($_POST["phone_code_field"])) {$phone_code_field=$_POST["phone_code_field"];}
|
||||||
|
else {$phone_code_field="-1";}
|
||||||
if (isset($_GET["phone_number_field"])) {$phone_number_field=$_GET["phone_number_field"];}
|
if (isset($_GET["phone_number_field"])) {$phone_number_field=$_GET["phone_number_field"];}
|
||||||
elseif (isset($_POST["phone_number_field"])) {$phone_number_field=$_POST["phone_number_field"];}
|
elseif (isset($_POST["phone_number_field"])) {$phone_number_field=$_POST["phone_number_field"];}
|
||||||
|
else {$phone_number_field="-1";}
|
||||||
if (isset($_GET["title_field"])) {$title_field=$_GET["title_field"];}
|
if (isset($_GET["title_field"])) {$title_field=$_GET["title_field"];}
|
||||||
elseif (isset($_POST["title_field"])) {$title_field=$_POST["title_field"];}
|
elseif (isset($_POST["title_field"])) {$title_field=$_POST["title_field"];}
|
||||||
|
else {$title_field="-1";}
|
||||||
if (isset($_GET["first_name_field"])) {$first_name_field=$_GET["first_name_field"];}
|
if (isset($_GET["first_name_field"])) {$first_name_field=$_GET["first_name_field"];}
|
||||||
elseif (isset($_POST["first_name_field"])) {$first_name_field=$_POST["first_name_field"];}
|
elseif (isset($_POST["first_name_field"])) {$first_name_field=$_POST["first_name_field"];}
|
||||||
|
else {$first_name_field="-1";}
|
||||||
if (isset($_GET["middle_initial_field"])) {$middle_initial_field=$_GET["middle_initial_field"];}
|
if (isset($_GET["middle_initial_field"])) {$middle_initial_field=$_GET["middle_initial_field"];}
|
||||||
elseif (isset($_POST["middle_initial_field"])) {$middle_initial_field=$_POST["middle_initial_field"];}
|
elseif (isset($_POST["middle_initial_field"])) {$middle_initial_field=$_POST["middle_initial_field"];}
|
||||||
|
else {$middle_initial_field="-1";}
|
||||||
if (isset($_GET["last_name_field"])) {$last_name_field=$_GET["last_name_field"];}
|
if (isset($_GET["last_name_field"])) {$last_name_field=$_GET["last_name_field"];}
|
||||||
elseif (isset($_POST["last_name_field"])) {$last_name_field=$_POST["last_name_field"];}
|
elseif (isset($_POST["last_name_field"])) {$last_name_field=$_POST["last_name_field"];}
|
||||||
|
else {$last_name_field="-1";}
|
||||||
if (isset($_GET["address1_field"])) {$address1_field=$_GET["address1_field"];}
|
if (isset($_GET["address1_field"])) {$address1_field=$_GET["address1_field"];}
|
||||||
elseif (isset($_POST["address1_field"])) {$address1_field=$_POST["address1_field"];}
|
elseif (isset($_POST["address1_field"])) {$address1_field=$_POST["address1_field"];}
|
||||||
|
else {$address1_field="-1";}
|
||||||
if (isset($_GET["address2_field"])) {$address2_field=$_GET["address2_field"];}
|
if (isset($_GET["address2_field"])) {$address2_field=$_GET["address2_field"];}
|
||||||
elseif (isset($_POST["address2_field"])) {$address2_field=$_POST["address2_field"];}
|
elseif (isset($_POST["address2_field"])) {$address2_field=$_POST["address2_field"];}
|
||||||
|
else {$address2_field="-1";}
|
||||||
if (isset($_GET["address3_field"])) {$address3_field=$_GET["address3_field"];}
|
if (isset($_GET["address3_field"])) {$address3_field=$_GET["address3_field"];}
|
||||||
elseif (isset($_POST["address3_field"])) {$address3_field=$_POST["address3_field"];}
|
elseif (isset($_POST["address3_field"])) {$address3_field=$_POST["address3_field"];}
|
||||||
|
else {$address3_field="-1";}
|
||||||
if (isset($_GET["city_field"])) {$city_field=$_GET["city_field"];}
|
if (isset($_GET["city_field"])) {$city_field=$_GET["city_field"];}
|
||||||
elseif (isset($_POST["city_field"])) {$city_field=$_POST["city_field"];}
|
elseif (isset($_POST["city_field"])) {$city_field=$_POST["city_field"];}
|
||||||
|
else {$city_field="-1";}
|
||||||
if (isset($_GET["state_field"])) {$state_field=$_GET["state_field"];}
|
if (isset($_GET["state_field"])) {$state_field=$_GET["state_field"];}
|
||||||
elseif (isset($_POST["state_field"])) {$state_field=$_POST["state_field"];}
|
elseif (isset($_POST["state_field"])) {$state_field=$_POST["state_field"];}
|
||||||
|
else {$state_field="-1";}
|
||||||
if (isset($_GET["province_field"])) {$province_field=$_GET["province_field"];}
|
if (isset($_GET["province_field"])) {$province_field=$_GET["province_field"];}
|
||||||
elseif (isset($_POST["province_field"])) {$province_field=$_POST["province_field"];}
|
elseif (isset($_POST["province_field"])) {$province_field=$_POST["province_field"];}
|
||||||
|
else {$province_field="-1";}
|
||||||
if (isset($_GET["postal_code_field"])) {$postal_code_field=$_GET["postal_code_field"];}
|
if (isset($_GET["postal_code_field"])) {$postal_code_field=$_GET["postal_code_field"];}
|
||||||
elseif (isset($_POST["postal_code_field"])) {$postal_code_field=$_POST["postal_code_field"];}
|
elseif (isset($_POST["postal_code_field"])) {$postal_code_field=$_POST["postal_code_field"];}
|
||||||
|
else {$postal_code_field="-1";}
|
||||||
if (isset($_GET["country_code_field"])) {$country_code_field=$_GET["country_code_field"];}
|
if (isset($_GET["country_code_field"])) {$country_code_field=$_GET["country_code_field"];}
|
||||||
elseif (isset($_POST["country_code_field"])) {$country_code_field=$_POST["country_code_field"];}
|
elseif (isset($_POST["country_code_field"])) {$country_code_field=$_POST["country_code_field"];}
|
||||||
|
else {$country_code_field="-1";}
|
||||||
if (isset($_GET["gender_field"])) {$gender_field=$_GET["gender_field"];}
|
if (isset($_GET["gender_field"])) {$gender_field=$_GET["gender_field"];}
|
||||||
elseif (isset($_POST["gender_field"])) {$gender_field=$_POST["gender_field"];}
|
elseif (isset($_POST["gender_field"])) {$gender_field=$_POST["gender_field"];}
|
||||||
|
else {$gender_field="-1";}
|
||||||
if (isset($_GET["date_of_birth_field"])) {$date_of_birth_field=$_GET["date_of_birth_field"];}
|
if (isset($_GET["date_of_birth_field"])) {$date_of_birth_field=$_GET["date_of_birth_field"];}
|
||||||
elseif (isset($_POST["date_of_birth_field"])) {$date_of_birth_field=$_POST["date_of_birth_field"];}
|
elseif (isset($_POST["date_of_birth_field"])) {$date_of_birth_field=$_POST["date_of_birth_field"];}
|
||||||
|
else {$date_of_birth_field="-1";}
|
||||||
if (isset($_GET["alt_phone_field"])) {$alt_phone_field=$_GET["alt_phone_field"];}
|
if (isset($_GET["alt_phone_field"])) {$alt_phone_field=$_GET["alt_phone_field"];}
|
||||||
elseif (isset($_POST["alt_phone_field"])) {$alt_phone_field=$_POST["alt_phone_field"];}
|
elseif (isset($_POST["alt_phone_field"])) {$alt_phone_field=$_POST["alt_phone_field"];}
|
||||||
|
else {$alt_phone_field="-1";}
|
||||||
if (isset($_GET["email_field"])) {$email_field=$_GET["email_field"];}
|
if (isset($_GET["email_field"])) {$email_field=$_GET["email_field"];}
|
||||||
elseif (isset($_POST["email_field"])) {$email_field=$_POST["email_field"];}
|
elseif (isset($_POST["email_field"])) {$email_field=$_POST["email_field"];}
|
||||||
|
else {$email_field="-1";}
|
||||||
if (isset($_GET["security_phrase_field"])) {$security_phrase_field=$_GET["security_phrase_field"];}
|
if (isset($_GET["security_phrase_field"])) {$security_phrase_field=$_GET["security_phrase_field"];}
|
||||||
elseif (isset($_POST["security_phrase_field"])) {$security_phrase_field=$_POST["security_phrase_field"];}
|
elseif (isset($_POST["security_phrase_field"])) {$security_phrase_field=$_POST["security_phrase_field"];}
|
||||||
|
else {$security_phrase_field="-1";}
|
||||||
if (isset($_GET["comments_field"])) {$comments_field=$_GET["comments_field"];}
|
if (isset($_GET["comments_field"])) {$comments_field=$_GET["comments_field"];}
|
||||||
elseif (isset($_POST["comments_field"])) {$comments_field=$_POST["comments_field"];}
|
elseif (isset($_POST["comments_field"])) {$comments_field=$_POST["comments_field"];}
|
||||||
|
else {$comments_field="-1";}
|
||||||
if (isset($_GET["rank_field"])) {$rank_field=$_GET["rank_field"];}
|
if (isset($_GET["rank_field"])) {$rank_field=$_GET["rank_field"];}
|
||||||
elseif (isset($_POST["rank_field"])) {$rank_field=$_POST["rank_field"];}
|
elseif (isset($_POST["rank_field"])) {$rank_field=$_POST["rank_field"];}
|
||||||
|
else {$rank_field="-1";}
|
||||||
if (isset($_GET["owner_field"])) {$owner_field=$_GET["owner_field"];}
|
if (isset($_GET["owner_field"])) {$owner_field=$_GET["owner_field"];}
|
||||||
elseif (isset($_POST["owner_field"])) {$owner_field=$_POST["owner_field"];}
|
elseif (isset($_POST["owner_field"])) {$owner_field=$_POST["owner_field"];}
|
||||||
|
else {$owner_field="-1";}
|
||||||
if (isset($_GET["list_id_override"])) {$list_id_override=$_GET["list_id_override"];}
|
if (isset($_GET["list_id_override"])) {$list_id_override=$_GET["list_id_override"];}
|
||||||
elseif (isset($_POST["list_id_override"])) {$list_id_override=$_POST["list_id_override"];}
|
elseif (isset($_POST["list_id_override"])) {$list_id_override=$_POST["list_id_override"];}
|
||||||
|
else {$list_id_override="";}
|
||||||
$list_id_override = (preg_replace("/\D/","",$list_id_override));
|
$list_id_override = (preg_replace("/\D/","",$list_id_override));
|
||||||
if (isset($_GET["master_list_override"])) {$master_list_override=$_GET["master_list_override"];}
|
if (isset($_GET["master_list_override"])) {$master_list_override=$_GET["master_list_override"];}
|
||||||
elseif (isset($_POST["master_list_override"])) {$master_list_override=$_POST["master_list_override"];}
|
elseif (isset($_POST["master_list_override"])) {$master_list_override=$_POST["master_list_override"];}
|
||||||
|
else {$master_list_override="";}
|
||||||
if (isset($_GET["lead_file"])) {$lead_file=$_GET["lead_file"];}
|
if (isset($_GET["lead_file"])) {$lead_file=$_GET["lead_file"];}
|
||||||
elseif (isset($_POST["lead_file"])) {$lead_file=$_POST["lead_file"];}
|
elseif (isset($_POST["lead_file"])) {$lead_file=$_POST["lead_file"];}
|
||||||
|
else {$lead_file="";}
|
||||||
if (isset($_GET["dupcheck"])) {$dupcheck=$_GET["dupcheck"];}
|
if (isset($_GET["dupcheck"])) {$dupcheck=$_GET["dupcheck"];}
|
||||||
elseif (isset($_POST["dupcheck"])) {$dupcheck=$_POST["dupcheck"];}
|
elseif (isset($_POST["dupcheck"])) {$dupcheck=$_POST["dupcheck"];}
|
||||||
|
else {$dupcheck="";}
|
||||||
if (isset($_GET["dedupe_statuses"])) {$dedupe_statuses=$_GET["dedupe_statuses"];}
|
if (isset($_GET["dedupe_statuses"])) {$dedupe_statuses=$_GET["dedupe_statuses"];}
|
||||||
elseif (isset($_POST["dedupe_statuses"])) {$dedupe_statuses=$_POST["dedupe_statuses"];}
|
elseif (isset($_POST["dedupe_statuses"])) {$dedupe_statuses=$_POST["dedupe_statuses"];}
|
||||||
|
else {$dedupe_statuses="";}
|
||||||
if (isset($_GET["dedupe_statuses_override"])) {$dedupe_statuses_override=$_GET["dedupe_statuses_override"];}
|
if (isset($_GET["dedupe_statuses_override"])) {$dedupe_statuses_override=$_GET["dedupe_statuses_override"];}
|
||||||
elseif (isset($_POST["dedupe_statuses_override"])) {$dedupe_statuses_override=$_POST["dedupe_statuses_override"];}
|
elseif (isset($_POST["dedupe_statuses_override"])) {$dedupe_statuses_override=$_POST["dedupe_statuses_override"];}
|
||||||
|
else {$dedupe_statuses_override="";}
|
||||||
if (isset($_GET["status_mismatch_action"])) {$status_mismatch_action=$_GET["status_mismatch_action"];}
|
if (isset($_GET["status_mismatch_action"])) {$status_mismatch_action=$_GET["status_mismatch_action"];}
|
||||||
elseif (isset($_POST["status_mismatch_action"])) {$status_mismatch_action=$_POST["status_mismatch_action"];}
|
elseif (isset($_POST["status_mismatch_action"])) {$status_mismatch_action=$_POST["status_mismatch_action"];}
|
||||||
|
else {$status_mismatch_action="";}
|
||||||
if (isset($_GET["postalgmt"])) {$postalgmt=$_GET["postalgmt"];}
|
if (isset($_GET["postalgmt"])) {$postalgmt=$_GET["postalgmt"];}
|
||||||
elseif (isset($_POST["postalgmt"])) {$postalgmt=$_POST["postalgmt"];}
|
elseif (isset($_POST["postalgmt"])) {$postalgmt=$_POST["postalgmt"];}
|
||||||
|
else {$postalgmt="";}
|
||||||
if (isset($_GET["phone_code_override"])) {$phone_code_override=$_GET["phone_code_override"];}
|
if (isset($_GET["phone_code_override"])) {$phone_code_override=$_GET["phone_code_override"];}
|
||||||
elseif (isset($_POST["phone_code_override"])) {$phone_code_override=$_POST["phone_code_override"];}
|
elseif (isset($_POST["phone_code_override"])) {$phone_code_override=$_POST["phone_code_override"];}
|
||||||
|
else {$phone_code_override="";}
|
||||||
$phone_code_override = (preg_replace("/\D/","",$phone_code_override));
|
$phone_code_override = (preg_replace("/\D/","",$phone_code_override));
|
||||||
if (isset($_GET["DB"])) {$DB=$_GET["DB"];}
|
if (isset($_GET["DB"])) {$DB=$_GET["DB"];}
|
||||||
elseif (isset($_POST["DB"])) {$DB=$_POST["DB"];}
|
elseif (isset($_POST["DB"])) {$DB=$_POST["DB"];}
|
||||||
|
if (isset($_GET["DBX"])) {$DBX=$_GET["DBX"];}
|
||||||
|
elseif (isset($_POST["DBX"])) {$DBX=$_POST["DBX"];}
|
||||||
if (isset($_GET["template_id"])) {$template_id=$_GET["template_id"];}
|
if (isset($_GET["template_id"])) {$template_id=$_GET["template_id"];}
|
||||||
elseif (isset($_POST["template_id"])) {$template_id=$_POST["template_id"];}
|
elseif (isset($_POST["template_id"])) {$template_id=$_POST["template_id"];}
|
||||||
|
else {$template_id="";}
|
||||||
if (isset($_GET["usacan_check"])) {$usacan_check=$_GET["usacan_check"];}
|
if (isset($_GET["usacan_check"])) {$usacan_check=$_GET["usacan_check"];}
|
||||||
elseif (isset($_POST["usacan_check"])) {$usacan_check=$_POST["usacan_check"];}
|
elseif (isset($_POST["usacan_check"])) {$usacan_check=$_POST["usacan_check"];}
|
||||||
|
else {$usacan_check="";}
|
||||||
if (isset($_GET["state_conversion"])) {$state_conversion=$_GET["state_conversion"];}
|
if (isset($_GET["state_conversion"])) {$state_conversion=$_GET["state_conversion"];}
|
||||||
elseif (isset($_POST["state_conversion"])) {$state_conversion=$_POST["state_conversion"];}
|
elseif (isset($_POST["state_conversion"])) {$state_conversion=$_POST["state_conversion"];}
|
||||||
|
else {$state_conversion="";}
|
||||||
if (isset($_GET["web_loader_phone_length"])) {$web_loader_phone_length=$_GET["web_loader_phone_length"];}
|
if (isset($_GET["web_loader_phone_length"])) {$web_loader_phone_length=$_GET["web_loader_phone_length"];}
|
||||||
elseif (isset($_POST["web_loader_phone_length"])) {$web_loader_phone_length=$_POST["web_loader_phone_length"];}
|
elseif (isset($_POST["web_loader_phone_length"])) {$web_loader_phone_length=$_POST["web_loader_phone_length"];}
|
||||||
|
else {$web_loader_phone_length=0;}
|
||||||
if (isset($_GET["international_dnc_scrub"])) {$international_dnc_scrub=$_GET["international_dnc_scrub"];}
|
if (isset($_GET["international_dnc_scrub"])) {$international_dnc_scrub=$_GET["international_dnc_scrub"];}
|
||||||
elseif (isset($_POST["international_dnc_scrub"])) {$international_dnc_scrub=$_POST["international_dnc_scrub"];}
|
elseif (isset($_POST["international_dnc_scrub"])) {$international_dnc_scrub=$_POST["international_dnc_scrub"];}
|
||||||
|
else {$international_dnc_scrub="";}
|
||||||
$DB=preg_replace("/[^0-9a-zA-Z]/","",$DB);
|
if (isset($_GET["tz_method"])) {$tz_method=$_GET["tz_method"];}
|
||||||
|
elseif (isset($_POST["tz_method"])) {$tz_method=$_POST["tz_method"];}
|
||||||
|
else {$tz_method="";}
|
||||||
|
if (isset($_GET["server_ip"])) {$server_ip=$_GET["server_ip"];}
|
||||||
|
elseif (isset($_POST["server_ip"])) {$server_ip=$_POST["server_ip"];}
|
||||||
|
else {$server_ip="";}
|
||||||
|
|
||||||
# if the didnt select an over ride wipe out in_file
|
# if the didnt select an over ride wipe out in_file
|
||||||
if ( $list_id_override == "in_file" ) { $list_id_override = ""; }
|
if ( $list_id_override == "in_file" ) { $list_id_override = ""; }
|
||||||
@@ -221,7 +280,6 @@ $vicidial_list_fields = '|lead_id|vendor_lead_code|source_id|list_id|gmt_offset_
|
|||||||
##### START SYSTEM_SETTINGS LOOKUP #####
|
##### START SYSTEM_SETTINGS LOOKUP #####
|
||||||
$stmt = "SELECT use_non_latin,admin_web_directory,custom_fields_enabled,webroot_writable,enable_languages,language_method,active_modules,admin_screen_colors,web_loader_phone_length,enable_international_dncs,web_loader_phone_strip,allow_web_debug FROM system_settings;";
|
$stmt = "SELECT use_non_latin,admin_web_directory,custom_fields_enabled,webroot_writable,enable_languages,language_method,active_modules,admin_screen_colors,web_loader_phone_length,enable_international_dncs,web_loader_phone_strip,allow_web_debug FROM system_settings;";
|
||||||
$rslt=mysql_to_mysqli($stmt, $link);
|
$rslt=mysql_to_mysqli($stmt, $link);
|
||||||
if ($DB) {echo "$stmt\n";}
|
|
||||||
$qm_conf_ct = mysqli_num_rows($rslt);
|
$qm_conf_ct = mysqli_num_rows($rslt);
|
||||||
#if ($qm_conf_ct > 0)
|
#if ($qm_conf_ct > 0)
|
||||||
{
|
{
|
||||||
@@ -239,7 +297,9 @@ $qm_conf_ct = mysqli_num_rows($rslt);
|
|||||||
$SSweb_loader_phone_strip = $row[10];
|
$SSweb_loader_phone_strip = $row[10];
|
||||||
$SSallow_web_debug = $row[11];
|
$SSallow_web_debug = $row[11];
|
||||||
}
|
}
|
||||||
if ($SSallow_web_debug < 1) {$DB=0;}
|
if ($SSallow_web_debug < 1 || !isset($DB)) {$DB=0;}
|
||||||
|
$DB=preg_replace("/[^0-9a-zA-Z]/","",$DB);
|
||||||
|
$DBX=0; # Always set - used in lookup_gmt, where you will have to override via hard-coding
|
||||||
##### END SETTINGS LOOKUP #####
|
##### END SETTINGS LOOKUP #####
|
||||||
###########################################
|
###########################################
|
||||||
|
|
||||||
@@ -254,36 +314,38 @@ $status_mismatch_action = preg_replace('/[^- \_0-9a-zA-Z]/', '', $status_mismatc
|
|||||||
$postalgmt = preg_replace('/[^- \_0-9a-zA-Z]/', '', $postalgmt);
|
$postalgmt = preg_replace('/[^- \_0-9a-zA-Z]/', '', $postalgmt);
|
||||||
$dupcheck = preg_replace('/[^- \_0-9a-zA-Z]/', '', $dupcheck);
|
$dupcheck = preg_replace('/[^- \_0-9a-zA-Z]/', '', $dupcheck);
|
||||||
$lead_file = preg_replace("/\<|\>|\'|\"|\\\\|;/","",$lead_file);
|
$lead_file = preg_replace("/\<|\>|\'|\"|\\\\|;/","",$lead_file);
|
||||||
$vendor_lead_code_field = preg_replace("/\<|\>|\'|\"|\\\\|;/",'',$vendor_lead_code_field);
|
$vendor_lead_code_field = preg_replace("/[^-0-9]/",'',$vendor_lead_code_field);
|
||||||
$source_id_field = preg_replace("/\<|\>|\'|\"|\\\\|;/",'',$source_id_field);
|
$source_id_field = preg_replace("/[^-0-9]/",'',$source_id_field);
|
||||||
$list_id_field = preg_replace("/\<|\>|\'|\"|\\\\|;/",'',$list_id_field);
|
$list_id_field = preg_replace("/[^-0-9]/",'',$list_id_field);
|
||||||
$phone_code_field = preg_replace("/\<|\>|\'|\"|\\\\|;/",'',$phone_code_field);
|
$phone_code_field = preg_replace("/[^-0-9]/",'',$phone_code_field);
|
||||||
$phone_number_field = preg_replace("/\<|\>|\'|\"|\\\\|;/",'',$phone_number_field);
|
$phone_number_field = preg_replace("/[^-0-9]/",'',$phone_number_field);
|
||||||
$title_field = preg_replace("/\<|\>|\'|\"|\\\\|;/",'',$title_field);
|
$title_field = preg_replace("/[^-0-9]/",'',$title_field);
|
||||||
$first_name_field = preg_replace("/\<|\>|\'|\"|\\\\|;/",'',$first_name_field);
|
$first_name_field = preg_replace("/[^-0-9]/",'',$first_name_field);
|
||||||
$middle_initial_field = preg_replace("/\<|\>|\'|\"|\\\\|;/",'',$middle_initial_field);
|
$middle_initial_field = preg_replace("/[^-0-9]/",'',$middle_initial_field);
|
||||||
$last_name_field = preg_replace("/\<|\>|\'|\"|\\\\|;/",'',$last_name_field);
|
$last_name_field = preg_replace("/[^-0-9]/",'',$last_name_field);
|
||||||
$address1_field = preg_replace("/\<|\>|\'|\"|\\\\|;/",'',$address1_field);
|
$address1_field = preg_replace("/[^-0-9]/",'',$address1_field);
|
||||||
$address2_field = preg_replace("/\<|\>|\'|\"|\\\\|;/",'',$address2_field);
|
$address2_field = preg_replace("/[^-0-9]/",'',$address2_field);
|
||||||
$address3_field = preg_replace("/\<|\>|\'|\"|\\\\|;/",'',$address3_field);
|
$address3_field = preg_replace("/[^-0-9]/",'',$address3_field);
|
||||||
$city_field = preg_replace("/\<|\>|\'|\"|\\\\|;/",'',$city_field);
|
$city_field = preg_replace("/[^-0-9]/",'',$city_field);
|
||||||
$state_field = preg_replace("/\<|\>|\'|\"|\\\\|;/",'',$state_field);
|
$state_field = preg_replace("/[^-0-9]/",'',$state_field);
|
||||||
$province_field = preg_replace("/\<|\>|\'|\"|\\\\|;/",'',$province_field);
|
$province_field = preg_replace("/[^-0-9]/",'',$province_field);
|
||||||
$postal_code_field = preg_replace("/\<|\>|\'|\"|\\\\|;/",'',$postal_code_field);
|
$postal_code_field = preg_replace("/[^-0-9]/",'',$postal_code_field);
|
||||||
$country_code_field = preg_replace("/\<|\>|\'|\"|\\\\|;/",'',$country_code_field);
|
$country_code_field = preg_replace("/[^-0-9]/",'',$country_code_field);
|
||||||
$gender_field = preg_replace("/\<|\>|\'|\"|\\\\|;/",'',$gender_field);
|
$gender_field = preg_replace("/[^-0-9]/",'',$gender_field);
|
||||||
$date_of_birth_field = preg_replace("/\<|\>|\'|\"|\\\\|;/",'',$date_of_birth_field);
|
$date_of_birth_field = preg_replace("/[^-0-9]/",'',$date_of_birth_field);
|
||||||
$alt_phone_field = preg_replace("/\<|\>|\'|\"|\\\\|;/",'',$alt_phone_field);
|
$alt_phone_field = preg_replace("/[^-0-9]/",'',$alt_phone_field);
|
||||||
$email_field = preg_replace("/\<|\>|\'|\"|\\\\|;/",'',$email_field);
|
$email_field = preg_replace("/[^-0-9]/",'',$email_field);
|
||||||
$security_phrase_field = preg_replace("/\<|\>|\'|\"|\\\\|;/",'',$security_phrase_field);
|
$security_phrase_field = preg_replace("/[^-0-9]/",'',$security_phrase_field);
|
||||||
$comments_field = preg_replace("/\<|\>|\'|\"|\\\\|;/",'',$comments_field);
|
$comments_field = preg_replace("/[^-0-9]/",'',$comments_field);
|
||||||
$rank_field = preg_replace("/\<|\>|\'|\"|\\\\|;/",'',$rank_field);
|
$rank_field = preg_replace("/[^-0-9]/",'',$rank_field);
|
||||||
$owner_field = preg_replace("/\<|\>|\'|\"|\\\\|;/",'',$owner_field);
|
$owner_field = preg_replace("/[^-0-9]/",'',$owner_field);
|
||||||
$submit_file = preg_replace('/[^-_0-9a-zA-Z]/', '', $submit_file);
|
$submit_file = preg_replace('/[^-_0-9a-zA-Z]/', '', $submit_file);
|
||||||
$submit = preg_replace('/[^-_0-9a-zA-Z]/', '', $submit);
|
# $submit = preg_replace('/[^-_0-9a-zA-Z]/', '', $submit);
|
||||||
$SUBMIT = preg_replace('/[^-_0-9a-zA-Z]/', '', $SUBMIT);
|
# $SUBMIT = preg_replace('/[^-_0-9a-zA-Z]/', '', $SUBMIT);
|
||||||
$file_layout = preg_replace('/[^-_0-9a-zA-Z]/', '', $file_layout);
|
$file_layout = preg_replace('/[^-_0-9a-zA-Z]/', '', $file_layout);
|
||||||
$OK_to_process = preg_replace('/[^- \_0-9a-zA-Z]/', '', $OK_to_process);
|
$OK_to_process = preg_replace('/[^- \_0-9a-zA-Z]/', '', $OK_to_process);
|
||||||
|
$tz_method = preg_replace('/[^-\_0-9a-zA-Z]/', '',$tz_method);
|
||||||
|
$server_ip = preg_replace('/[^-\.\:\_0-9a-zA-Z]/', '', $server_ip);
|
||||||
|
|
||||||
# Variables filter further down in the code
|
# Variables filter further down in the code
|
||||||
# $dedupe_statuses
|
# $dedupe_statuses
|
||||||
@@ -397,8 +459,8 @@ if (preg_match("/;|:|\/|\^|\[|\]|\"|\'|\*/",$LF_orig))
|
|||||||
exit;
|
exit;
|
||||||
}
|
}
|
||||||
|
|
||||||
$upload_error = $_FILES['leadfile']['error'];
|
if (isset($_FILES['leadfile']['error'])) {$upload_error = $_FILES['leadfile']['error'];}
|
||||||
if ($upload_error != UPLOAD_ERR_OK)
|
if (isset($upload_error) && $upload_error != UPLOAD_ERR_OK)
|
||||||
{
|
{
|
||||||
if ($upload_error == UPLOAD_ERR_INI_SIZE)
|
if ($upload_error == UPLOAD_ERR_INI_SIZE)
|
||||||
{
|
{
|
||||||
@@ -734,7 +796,7 @@ if ( (!$OK_to_process) or ( ($leadfile) and ($file_layout!="standard" && $file_l
|
|||||||
<table align=center width="880" border=0 cellpadding=5 cellspacing=0 bgcolor=#<?php echo $SSframe_background; ?>>
|
<table align=center width="880" border=0 cellpadding=5 cellspacing=0 bgcolor=#<?php echo $SSframe_background; ?>>
|
||||||
<tr>
|
<tr>
|
||||||
<td align=right width="20%"><B><font face="arial, helvetica" size=2><?php echo _QXZ("Load leads from this file"); ?>:</font></B></td>
|
<td align=right width="20%"><B><font face="arial, helvetica" size=2><?php echo _QXZ("Load leads from this file"); ?>:</font></B></td>
|
||||||
<td align=left width="80%"><input type=file name="leadfile" value="<?php echo $leadfile ?>"> <?php echo "$NWB#list_loader$NWE"; ?></td>
|
<td align=left width="80%"><input type=file name="leadfile" value=""> <?php echo "$NWB#list_loader$NWE"; ?></td> <!-- can't echo $leadfile, it's an array at this point //-->
|
||||||
</tr>
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
<td align=right width="20%"><font face="arial, helvetica" size=2><?php echo _QXZ("List ID Override"); ?>: </font></td>
|
<td align=right width="20%"><font face="arial, helvetica" size=2><?php echo _QXZ("List ID Override"); ?>: </font></td>
|
||||||
@@ -783,7 +845,7 @@ if ( (!$OK_to_process) or ( ($leadfile) and ($file_layout!="standard" && $file_l
|
|||||||
<td align=left><font face="arial, helvetica" size=2><input type=radio name="file_layout" value="standard" checked><?php echo _QXZ("Standard Format"); ?> <input type=radio name="file_layout" value="custom"><?php echo _QXZ("Custom layout"); ?> <input type=radio name="file_layout" value="template"><?php echo _QXZ("Custom Template"); ?> <?php echo "$NWB#list_loader-file_layout$NWE"; ?></td>
|
<td align=left><font face="arial, helvetica" size=2><input type=radio name="file_layout" value="standard" checked><?php echo _QXZ("Standard Format"); ?> <input type=radio name="file_layout" value="custom"><?php echo _QXZ("Custom layout"); ?> <input type=radio name="file_layout" value="template"><?php echo _QXZ("Custom Template"); ?> <?php echo "$NWB#list_loader-file_layout$NWE"; ?></td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
<td align=right width="20%"><font face="arial, helvetica" size=2><?php echo _QXZ("Custom Layout to Use"); ?>: </font></td>
|
<td align=right width="20%"><font face="arial, helvetica" size=2><?php echo _QXZ("Custom Template to Use"); ?>: </font></td>
|
||||||
<td align=left><select name="template_id" id="template_id">
|
<td align=left><select name="template_id" id="template_id">
|
||||||
<?php
|
<?php
|
||||||
$template_stmt="SELECT template_id, template_name FROM vicidial_custom_leadloader_templates WHERE list_id IN (SELECT list_id FROM vicidial_lists $whereLOGallowed_campaignsSQL) ORDER BY template_id asc;";
|
$template_stmt="SELECT template_id, template_name FROM vicidial_custom_leadloader_templates WHERE list_id IN (SELECT list_id FROM vicidial_lists $whereLOGallowed_campaignsSQL) ORDER BY template_id asc;";
|
||||||
@@ -847,12 +909,12 @@ if ($SSenable_international_dncs)
|
|||||||
echo "\t\t\t<td align=left width='80%' nowrap><font face='arial, helvetica' size=1><select size='1' name='international_dnc_scrub'>\n";
|
echo "\t\t\t<td align=left width='80%' nowrap><font face='arial, helvetica' size=1><select size='1' name='international_dnc_scrub'>\n";
|
||||||
if ($available_countries>0)
|
if ($available_countries>0)
|
||||||
{
|
{
|
||||||
echo "\t\t\t\t<option>-- SELECT COUNTRY DNC LIST--</option>\n";
|
echo "\t\t\t\t<option value=''>-- SELECT COUNTRY DNC LIST--</option>\n";
|
||||||
echo $drop_down_dnc_options;
|
echo $drop_down_dnc_options;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
echo "\t\t\t\t<option>-- NO COUNTRY DNC TABLES EXIST --</option>\n";
|
echo "\t\t\t\t<option value=''>-- NO COUNTRY DNC TABLES EXIST --</option>\n";
|
||||||
}
|
}
|
||||||
echo "\t\t</tr>\n";
|
echo "\t\t</tr>\n";
|
||||||
echo "\t\t<tr>\n";
|
echo "\t\t<tr>\n";
|
||||||
@@ -1025,10 +1087,10 @@ if ($OK_to_process)
|
|||||||
$file=fopen("$lead_file", "r");
|
$file=fopen("$lead_file", "r");
|
||||||
print "<center><font face='arial, helvetica' size=3 color='#009900'><B>"._QXZ("Processing file")."...\n";
|
print "<center><font face='arial, helvetica' size=3 color='#009900'><B>"._QXZ("Processing file")."...\n";
|
||||||
|
|
||||||
|
$status_dedupe_str=""; $statuses_clause="";
|
||||||
if (is_array($dedupe_statuses) && count($dedupe_statuses)>0)
|
if (is_array($dedupe_statuses) && count($dedupe_statuses)>0)
|
||||||
{
|
{
|
||||||
$statuses_clause=" and status in (";
|
$statuses_clause=" and status in (";
|
||||||
$status_dedupe_str="";
|
|
||||||
for($ds=0; $ds<count($dedupe_statuses); $ds++)
|
for($ds=0; $ds<count($dedupe_statuses); $ds++)
|
||||||
{
|
{
|
||||||
$dedupe_statuses[$ds] = preg_replace('/[^-_0-9\p{L}]/u', '', $dedupe_statuses[$ds]);
|
$dedupe_statuses[$ds] = preg_replace('/[^-_0-9\p{L}]/u', '', $dedupe_statuses[$ds]);
|
||||||
@@ -1155,6 +1217,7 @@ if ($OK_to_process)
|
|||||||
$delete_hopper_rslt=mysql_to_mysqli($delete_hopper_stmt, $link);
|
$delete_hopper_rslt=mysql_to_mysqli($delete_hopper_stmt, $link);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
$record=0;
|
||||||
while (!feof($file))
|
while (!feof($file))
|
||||||
{
|
{
|
||||||
$record++;
|
$record++;
|
||||||
@@ -1170,34 +1233,34 @@ if ($OK_to_process)
|
|||||||
$modify_date = "";
|
$modify_date = "";
|
||||||
$status = "NEW";
|
$status = "NEW";
|
||||||
$user ="";
|
$user ="";
|
||||||
$vendor_lead_code = $row[$vendor_lead_code_field];
|
$vendor_lead_code = ($vendor_lead_code_field>=0 && isset($row[$vendor_lead_code_field]) ? $row[$vendor_lead_code_field] : "");
|
||||||
$source_code = $row[$source_id_field];
|
$source_code = ($source_id_field>=0 && isset($row[$source_id_field]) ? $row[$source_id_field] : "");
|
||||||
$source_id=$source_code;
|
$source_id=$source_code;
|
||||||
$list_id = $row[$list_id_field];
|
$list_id = ($list_id_field>=0 && isset($row[$list_id_field]) ? $row[$list_id_field] : "");
|
||||||
$gmt_offset = '0';
|
$gmt_offset = '0';
|
||||||
$called_since_last_reset='N';
|
$called_since_last_reset='N';
|
||||||
$phone_code = preg_replace('/[^0-9]/i', '', $row[$phone_code_field]);
|
$phone_code = ($phone_code_field>=0 && isset($row[$phone_code_field]) ? preg_replace('/[^0-9]/i', '', $row[$phone_code_field]) : "");
|
||||||
$phone_number = preg_replace('/[^0-9]/i', '', $row[$phone_number_field]);
|
$phone_number = ($phone_number_field>=0 && isset($row[$phone_number_field]) ? preg_replace('/[^0-9]/i', '', $row[$phone_number_field]) : "");
|
||||||
$title = $row[$title_field];
|
$title = ($title_field>=0 && isset($row[$title_field]) ? $row[$title_field] : "");
|
||||||
$first_name = $row[$first_name_field];
|
$first_name = ($first_name_field>=0 && isset($row[$first_name_field]) ? $row[$first_name_field] : "");
|
||||||
$middle_initial = $row[$middle_initial_field];
|
$middle_initial = ($middle_initial_field>=0 && isset($row[$middle_initial_field]) ? $row[$middle_initial_field] : "");
|
||||||
$last_name = $row[$last_name_field];
|
$last_name = ($last_name_field>=0 && isset($row[$last_name_field]) ? $row[$last_name_field] : "");
|
||||||
$address1 = $row[$address1_field];
|
$address1 = ($address1_field>=0 && isset($row[$address1_field]) ? $row[$address1_field] : "");
|
||||||
$address2 = $row[$address2_field];
|
$address2 = ($address2_field>=0 && isset($row[$address2_field]) ? $row[$address2_field] : "");
|
||||||
$address3 = $row[$address3_field];
|
$address3 = ($address3_field>=0 && isset($row[$address3_field]) ? $row[$address3_field] : "");
|
||||||
$city =$row[$city_field];
|
$city = ($city_field>=0 && isset($row[$city_field]) ? $row[$city_field] : "");
|
||||||
$state = $row[$state_field];
|
$state = ($state_field>=0 && isset($row[$state_field]) ? $row[$state_field] : "");
|
||||||
$province = $row[$province_field];
|
$province = ($province_field>=0 && isset($row[$province_field]) ? $row[$province_field] : "");
|
||||||
$postal_code = $row[$postal_code_field];
|
$postal_code = ($postal_code_field>=0 && isset($row[$postal_code_field]) ? $row[$postal_code_field] : "");
|
||||||
$country_code = $row[$country_code_field];
|
$country_code = ($country_code_field>=0 && isset($row[$country_code_field]) ? $row[$country_code_field] : "");
|
||||||
$gender = $row[$gender_field];
|
$gender = ($gender_field>=0 && isset($row[$gender_field]) ? $row[$gender_field] : "");
|
||||||
$date_of_birth = $row[$date_of_birth_field];
|
$date_of_birth = ($date_of_birth_field>=0 && isset($row[$date_of_birth_field]) ? $row[$date_of_birth_field] : "");
|
||||||
$alt_phone = preg_replace('/[^0-9]/i', '', $row[$alt_phone_field]);
|
$alt_phone = ($alt_phone_field>=0 && isset($row[$alt_phone_field]) ? preg_replace('/[^0-9]/i', '', $row[$alt_phone_field]) : "");
|
||||||
$email = $row[$email_field];
|
$email = ($email_field>=0 && isset($row[$email_field]) ? $row[$email_field] : "");
|
||||||
$security_phrase = $row[$security_phrase_field];
|
$security_phrase = ($security_phrase_field>=0 && isset($row[$security_phrase_field]) ? $row[$security_phrase_field] : "");
|
||||||
$comments = trim($row[$comments_field]);
|
$comments = ($comments_field>=0 && isset($row[$comments_field]) ? trim($row[$comments_field]) : "");
|
||||||
$rank = $row[$rank_field];
|
$rank = ($rank_field>=0 && isset($row[$rank_field]) ? $row[$rank_field] : "");
|
||||||
$owner = $row[$owner_field];
|
$owner = ($owner_field>=0 && isset($row[$owner_field]) ? $row[$owner_field] : "");
|
||||||
|
|
||||||
# replace ' " ` \ ; with nothing
|
# replace ' " ` \ ; with nothing
|
||||||
$vendor_lead_code = preg_replace("/$field_regx/i", "", $vendor_lead_code);
|
$vendor_lead_code = preg_replace("/$field_regx/i", "", $vendor_lead_code);
|
||||||
@@ -1323,10 +1386,10 @@ if ($OK_to_process)
|
|||||||
$phone_number = preg_replace("/^$SSweb_loader_phone_strip/",'',$phone_number);
|
$phone_number = preg_replace("/^$SSweb_loader_phone_strip/",'',$phone_number);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
$dup_lead=0; $moved_lead=0;
|
||||||
##### Check for duplicate phone numbers in vicidial_list table for all lists in a campaign #####
|
##### Check for duplicate phone numbers in vicidial_list table for all lists in a campaign #####
|
||||||
if (preg_match("/DUPCAMP/i",$dupcheck))
|
if (preg_match("/DUPCAMP/i",$dupcheck))
|
||||||
{
|
{
|
||||||
$dup_lead=0; $moved_lead=0;
|
|
||||||
$dup_lists='';
|
$dup_lists='';
|
||||||
$stmt="SELECT campaign_id from vicidial_lists where list_id='$list_id';";
|
$stmt="SELECT campaign_id from vicidial_lists where list_id='$list_id';";
|
||||||
$rslt=mysql_to_mysqli($stmt, $link);
|
$rslt=mysql_to_mysqli($stmt, $link);
|
||||||
@@ -1399,8 +1462,6 @@ if ($OK_to_process)
|
|||||||
##### Check for duplicate phone numbers in vicidial_list table entire database #####
|
##### Check for duplicate phone numbers in vicidial_list table entire database #####
|
||||||
if (preg_match("/DUPSYS/i",$dupcheck))
|
if (preg_match("/DUPSYS/i",$dupcheck))
|
||||||
{
|
{
|
||||||
$dup_lead=0; $moved_lead=0;
|
|
||||||
|
|
||||||
if ($status_mismatch_action)
|
if ($status_mismatch_action)
|
||||||
{
|
{
|
||||||
if (preg_match('/USING CHECK/', $status_mismatch_action))
|
if (preg_match('/USING CHECK/', $status_mismatch_action))
|
||||||
@@ -1450,8 +1511,6 @@ if ($OK_to_process)
|
|||||||
##### Check for duplicate phone numbers in vicidial_list table for one list_id #####
|
##### Check for duplicate phone numbers in vicidial_list table for one list_id #####
|
||||||
if (preg_match("/DUPLIST/i",$dupcheck))
|
if (preg_match("/DUPLIST/i",$dupcheck))
|
||||||
{
|
{
|
||||||
$dup_lead=0; $moved_lead=0;
|
|
||||||
|
|
||||||
if ($status_mismatch_action)
|
if ($status_mismatch_action)
|
||||||
{
|
{
|
||||||
if (preg_match('/USING CHECK/', $status_mismatch_action))
|
if (preg_match('/USING CHECK/', $status_mismatch_action))
|
||||||
@@ -1499,8 +1558,6 @@ if ($OK_to_process)
|
|||||||
##### Check for duplicate title and alt-phone in vicidial_list table for one list_id #####
|
##### Check for duplicate title and alt-phone in vicidial_list table for one list_id #####
|
||||||
if (preg_match("/DUPTITLEALTPHONELIST/i",$dupcheck))
|
if (preg_match("/DUPTITLEALTPHONELIST/i",$dupcheck))
|
||||||
{
|
{
|
||||||
$dup_lead=0; $moved_lead=0;
|
|
||||||
|
|
||||||
if ($status_mismatch_action)
|
if ($status_mismatch_action)
|
||||||
{
|
{
|
||||||
if (preg_match('/USING CHECK/', $status_mismatch_action))
|
if (preg_match('/USING CHECK/', $status_mismatch_action))
|
||||||
@@ -1548,7 +1605,6 @@ if ($OK_to_process)
|
|||||||
##### Check for duplicate phone numbers in vicidial_list table entire database #####
|
##### Check for duplicate phone numbers in vicidial_list table entire database #####
|
||||||
if (preg_match("/DUPTITLEALTPHONESYS/i",$dupcheck))
|
if (preg_match("/DUPTITLEALTPHONESYS/i",$dupcheck))
|
||||||
{
|
{
|
||||||
$dup_lead=0; $moved_lead=0;
|
|
||||||
|
|
||||||
if ($status_mismatch_action)
|
if ($status_mismatch_action)
|
||||||
{
|
{
|
||||||
@@ -1643,6 +1699,7 @@ if ($OK_to_process)
|
|||||||
$invalid_reason = _QXZ("INVALID PHONE NUMBER NANPA AREACODE PREFIX");
|
$invalid_reason = _QXZ("INVALID PHONE NUMBER NANPA AREACODE PREFIX");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
$dnc_matches=0;
|
||||||
if ($international_dnc_scrub and $valid_number > 0)
|
if ($international_dnc_scrub and $valid_number > 0)
|
||||||
{
|
{
|
||||||
$dnc_table_name="vicidial_dnc_".$international_dnc_scrub;
|
$dnc_table_name="vicidial_dnc_".$international_dnc_scrub;
|
||||||
@@ -1684,8 +1741,9 @@ if ($OK_to_process)
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
if ($multi_insert_counter > 8)
|
if (!isset($multi_insert_counter) || $multi_insert_counter > 8) # will not be set on the first record
|
||||||
{
|
{
|
||||||
|
if (!isset($multistmt)) {$multistmt='';} # Will happen on the first record
|
||||||
### insert good record into vicidial_list table ###
|
### insert good record into vicidial_list table ###
|
||||||
$stmtZ = "INSERT INTO vicidial_list (lead_id,entry_date,modify_date,status,user,vendor_lead_code,source_id,list_id,gmt_offset_now,called_since_last_reset,phone_code,phone_number,title,first_name,middle_initial,last_name,address1,address2,address3,city,state,province,postal_code,country_code,gender,date_of_birth,alt_phone,email,security_phrase,comments,called_count,last_local_call_time,rank,owner,entry_list_id) values$multistmt('',\"$entry_date\",\"$modify_date\",\"$status\",\"$user\",\"$vendor_lead_code\",\"$source_id\",\"$list_id\",\"$gmt_offset\",\"$called_since_last_reset\",\"$phone_code\",\"$phone_number\",\"$title\",\"$first_name\",\"$middle_initial\",\"$last_name\",\"$address1\",\"$address2\",\"$address3\",\"$city\",\"$state\",\"$province\",\"$postal_code\",\"$country_code\",\"$gender\",\"$date_of_birth\",\"$alt_phone\",\"$email\",\"$security_phrase\",\"$comments\",0,\"2008-01-01 00:00:00\",\"$rank\",\"$owner\",'0');";
|
$stmtZ = "INSERT INTO vicidial_list (lead_id,entry_date,modify_date,status,user,vendor_lead_code,source_id,list_id,gmt_offset_now,called_since_last_reset,phone_code,phone_number,title,first_name,middle_initial,last_name,address1,address2,address3,city,state,province,postal_code,country_code,gender,date_of_birth,alt_phone,email,security_phrase,comments,called_count,last_local_call_time,rank,owner,entry_list_id) values$multistmt('',\"$entry_date\",\"$modify_date\",\"$status\",\"$user\",\"$vendor_lead_code\",\"$source_id\",\"$list_id\",\"$gmt_offset\",\"$called_since_last_reset\",\"$phone_code\",\"$phone_number\",\"$title\",\"$first_name\",\"$middle_initial\",\"$last_name\",\"$address1\",\"$address2\",\"$address3\",\"$city\",\"$state\",\"$province\",\"$postal_code\",\"$country_code\",\"$gender\",\"$date_of_birth\",\"$alt_phone\",\"$email\",\"$security_phrase\",\"$comments\",0,\"2008-01-01 00:00:00\",\"$rank\",\"$owner\",'0');";
|
||||||
$rslt=mysql_to_mysqli($stmtZ, $link);
|
$rslt=mysql_to_mysqli($stmtZ, $link);
|
||||||
@@ -1738,7 +1796,7 @@ if ($OK_to_process)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if ($multi_insert_counter!=0)
|
if (isset($multi_insert_counter) && $multi_insert_counter!=0)
|
||||||
{
|
{
|
||||||
$stmtZ = "INSERT INTO vicidial_list (lead_id,entry_date,modify_date,status,user,vendor_lead_code,source_id,list_id,gmt_offset_now,called_since_last_reset,phone_code,phone_number,title,first_name,middle_initial,last_name,address1,address2,address3,city,state,province,postal_code,country_code,gender,date_of_birth,alt_phone,email,security_phrase,comments,called_count,last_local_call_time,rank,owner,entry_list_id) values".substr($multistmt, 0, -1).";";
|
$stmtZ = "INSERT INTO vicidial_list (lead_id,entry_date,modify_date,status,user,vendor_lead_code,source_id,list_id,gmt_offset_now,called_since_last_reset,phone_code,phone_number,title,first_name,middle_initial,last_name,address1,address2,address3,city,state,province,postal_code,country_code,gender,date_of_birth,alt_phone,email,security_phrase,comments,called_count,last_local_call_time,rank,owner,entry_list_id) values".substr($multistmt, 0, -1).";";
|
||||||
mysql_to_mysqli($stmtZ, $link);
|
mysql_to_mysqli($stmtZ, $link);
|
||||||
@@ -1747,7 +1805,7 @@ if ($OK_to_process)
|
|||||||
}
|
}
|
||||||
|
|
||||||
### LOG INSERTION Admin Log Table ###
|
### LOG INSERTION Admin Log Table ###
|
||||||
$stmt="INSERT INTO vicidial_admin_log set event_date='$NOW_TIME', user='$PHP_AUTH_USER', ip_address='$ip', event_section='LISTS', event_type='LOAD', record_id='$list_id_override', event_code='ADMIN LOAD LIST CUSTOM', event_sql='', event_notes='File Name: $leadfile_name, GOOD: $good, BAD: $bad, MOVED: $moved, TOTAL: $total, DEBUG: dedupe_statuses:$dedupe_statuses[0]| dedupe_statuses_override:$dedupe_statuses_override| dupcheck:$dupcheck| status mismatch action: $status_mismatch_action| lead_file:$lead_file| list_id_override:$list_id_override| phone_code_override:$phone_code_override| postalgmt:$postalgmt| template_id:$template_id| usacan_check:$usacan_check| dnc_country_scrub:$international_dnc_scrub| state_conversion:$state_conversion| web_loader_phone_length:$web_loader_phone_length| web_loader_phone_strip:$SSweb_loader_phone_strip|';";
|
$stmt="INSERT INTO vicidial_admin_log set event_date='$NOW_TIME', user='$PHP_AUTH_USER', ip_address='$ip', event_section='LISTS', event_type='LOAD', record_id='$list_id_override', event_code='ADMIN LOAD LIST CUSTOM', event_sql='', event_notes='File Name: $leadfile_name, GOOD: $good, BAD: $bad, MOVED: $moved, TOTAL: $total, DEBUG: dedupe_statuses:".(isset($dedupe_statuses[0]) ? $dedupe_statuses[0] : " NONE")."| dedupe_statuses_override:$dedupe_statuses_override| dupcheck:$dupcheck| status mismatch action: $status_mismatch_action| lead_file:$lead_file| list_id_override:$list_id_override| phone_code_override:$phone_code_override| postalgmt:$postalgmt| template_id:$template_id| usacan_check:$usacan_check| dnc_country_scrub:$international_dnc_scrub| state_conversion:$state_conversion| web_loader_phone_length:$web_loader_phone_length| web_loader_phone_strip:$SSweb_loader_phone_strip|';";
|
||||||
if ($DB) {echo "|$stmt|\n";}
|
if ($DB) {echo "|$stmt|\n";}
|
||||||
$rslt=mysql_to_mysqli($stmt, $link);
|
$rslt=mysql_to_mysqli($stmt, $link);
|
||||||
|
|
||||||
@@ -1767,7 +1825,7 @@ if (($leadfile) && ($LF_path))
|
|||||||
$total=0; $good=0; $bad=0; $dup=0; $inv=0; $post=0; $moved=0; $phone_list='';
|
$total=0; $good=0; $bad=0; $dup=0; $inv=0; $post=0; $moved=0; $phone_list='';
|
||||||
|
|
||||||
### LOG INSERTION Admin Log Table ###
|
### LOG INSERTION Admin Log Table ###
|
||||||
$stmt="INSERT INTO vicidial_admin_log set event_date='$NOW_TIME', user='$PHP_AUTH_USER', ip_address='$ip', event_section='LISTS', event_type='LOAD', record_id='$list_id_override', event_code='ADMIN LOAD LIST', event_sql='', event_notes='File Name: $leadfile_name, DEBUG: dedupe_statuses:$dedupe_statuses[0]| dedupe_statuses_override:$dedupe_statuses_override| dupcheck:$dupcheck | status mismatch action: $status_mismatch_action| lead_file:$lead_file| list_id_override:$list_id_override| phone_code_override:$phone_code_override| postalgmt:$postalgmt| template_id:$template_id| usacan_check:$usacan_check| dnc_country_scrub:$international_dnc_scrub| state_conversion:$state_conversion| web_loader_phone_length:$web_loader_phone_length| web_loader_phone_strip:$SSweb_loader_phone_strip|';";
|
$stmt="INSERT INTO vicidial_admin_log set event_date='$NOW_TIME', user='$PHP_AUTH_USER', ip_address='$ip', event_section='LISTS', event_type='LOAD', record_id='$list_id_override', event_code='ADMIN LOAD LIST', event_sql='', event_notes='File Name: $leadfile_name, DEBUG: dedupe_statuses:".(isset($dedupe_statuses[0]) ? $dedupe_statuses[0] : " NONE")."| dedupe_statuses_override:$dedupe_statuses_override| dupcheck:$dupcheck | status mismatch action: $status_mismatch_action| lead_file:$lead_file| list_id_override:$list_id_override| phone_code_override:$phone_code_override| postalgmt:$postalgmt| template_id:$template_id| usacan_check:$usacan_check| dnc_country_scrub:$international_dnc_scrub| state_conversion:$state_conversion| web_loader_phone_length:$web_loader_phone_length| web_loader_phone_strip:$SSweb_loader_phone_strip|';";
|
||||||
if ($DB) {echo "|$stmt|\n";}
|
if ($DB) {echo "|$stmt|\n";}
|
||||||
$rslt=mysql_to_mysqli($stmt, $link);
|
$rslt=mysql_to_mysqli($stmt, $link);
|
||||||
|
|
||||||
@@ -1972,38 +2030,38 @@ if (($leadfile) && ($LF_path))
|
|||||||
$modify_date = "";
|
$modify_date = "";
|
||||||
$status = "NEW";
|
$status = "NEW";
|
||||||
$user ="";
|
$user ="";
|
||||||
$vendor_lead_code = $row[$vendor_lead_code_field];
|
$vendor_lead_code = ($vendor_lead_code_field>=0 && isset($row[$vendor_lead_code_field]) ? $row[$vendor_lead_code_field] : "");
|
||||||
$source_code = $row[$source_id_field];
|
$source_code = ($source_id_field>=0 && isset($row[$source_id_field]) ? $row[$source_id_field] : "");
|
||||||
$source_id=$source_code;
|
$source_id=$source_code;
|
||||||
$list_id = $row[$list_id_field];
|
$list_id = ($list_id_field>=0 && isset($row[$list_id_field]) ? $row[$list_id_field] : "");
|
||||||
# Added 2/9/2015 to allow dropdown to override template
|
# Added 2/9/2015 to allow dropdown to override template
|
||||||
if ($master_list_override) {
|
if ($master_list_override) {
|
||||||
$list_id=$list_id_override;
|
$list_id=$list_id_override;
|
||||||
}
|
}
|
||||||
$gmt_offset = '0';
|
$gmt_offset = '0';
|
||||||
$called_since_last_reset='N';
|
$called_since_last_reset='N';
|
||||||
$phone_code = preg_replace('/[^0-9]/i', '', $row[$phone_code_field]);
|
$phone_code = ($phone_code_field>=0 && isset($row[$phone_code_field]) ? preg_replace('/[^0-9]/i', '', $row[$phone_code_field]) : "");
|
||||||
$phone_number = preg_replace('/[^0-9]/i', '', $row[$phone_number_field]);
|
$phone_number = ($phone_number_field>=0 && isset($row[$phone_number_field]) ? preg_replace('/[^0-9]/i', '', $row[$phone_number_field]) : "");
|
||||||
$title = $row[$title_field];
|
$title = ($title_field>=0 && isset($row[$title_field]) ? $row[$title_field] : "");
|
||||||
$first_name = $row[$first_name_field];
|
$first_name = ($first_name_field>=0 && isset($row[$first_name_field]) ? $row[$first_name_field] : "");
|
||||||
$middle_initial = $row[$middle_initial_field];
|
$middle_initial = ($middle_initial_field>=0 && isset($row[$middle_initial_field]) ? $row[$middle_initial_field] : "");
|
||||||
$last_name = $row[$last_name_field];
|
$last_name = ($last_name_field>=0 && isset($row[$last_name_field]) ? $row[$last_name_field] : "");
|
||||||
$address1 = $row[$address1_field];
|
$address1 = ($address1_field>=0 && isset($row[$address1_field]) ? $row[$address1_field] : "");
|
||||||
$address2 = $row[$address2_field];
|
$address2 = ($address2_field>=0 && isset($row[$address2_field]) ? $row[$address2_field] : "");
|
||||||
$address3 = $row[$address3_field];
|
$address3 = ($address3_field>=0 && isset($row[$address3_field]) ? $row[$address3_field] : "");
|
||||||
$city =$row[$city_field];
|
$city = ($city_field>=0 && isset($row[$city_field]) ? $row[$city_field] : "");
|
||||||
$state = $row[$state_field];
|
$state = ($state_field>=0 && isset($row[$state_field]) ? $row[$state_field] : "");
|
||||||
$province = $row[$province_field];
|
$province = ($province_field>=0 && isset($row[$province_field]) ? $row[$province_field] : "");
|
||||||
$postal_code = $row[$postal_code_field];
|
$postal_code = ($postal_code_field>=0 && isset($row[$postal_code_field]) ? $row[$postal_code_field] : "");
|
||||||
$country_code = $row[$country_code_field];
|
$country_code = ($country_code_field>=0 && isset($row[$country_code_field]) ? $row[$country_code_field] : "");
|
||||||
$gender = $row[$gender_field];
|
$gender = ($gender_field>=0 && isset($row[$gender_field]) ? $row[$gender_field] : "");
|
||||||
$date_of_birth = $row[$date_of_birth_field];
|
$date_of_birth = ($date_of_birth_field>=0 && isset($row[$date_of_birth_field]) ? $row[$date_of_birth_field] : "");
|
||||||
$alt_phone = preg_replace('/[^0-9]/i', '', $row[$alt_phone_field]);
|
$alt_phone = ($alt_phone_field>=0 && isset($row[$alt_phone_field]) ? preg_replace('/[^0-9]/i', '', $row[$alt_phone_field]) : "");
|
||||||
$email = $row[$email_field];
|
$email = ($email_field>=0 && isset($row[$email_field]) ? $row[$email_field] : "");
|
||||||
$security_phrase = $row[$security_phrase_field];
|
$security_phrase = ($security_phrase_field>=0 && isset($row[$security_phrase_field]) ? $row[$security_phrase_field] : "");
|
||||||
$comments = trim($row[$comments_field]);
|
$comments = ($comments_field>=0 && isset($row[$comments_field]) ? trim($row[$comments_field]) : "");
|
||||||
$rank = $row[$rank_field];
|
$rank = ($rank_field>=0 && isset($row[$rank_field]) ? $row[$rank_field] : "");
|
||||||
$owner = $row[$owner_field];
|
$owner = ($owner_field>=0 && isset($row[$owner_field]) ? $row[$owner_field] : "");
|
||||||
|
|
||||||
# replace ' " ` \ ; with nothing
|
# replace ' " ` \ ; with nothing
|
||||||
$vendor_lead_code = preg_replace("/$field_regx/i", "", $vendor_lead_code);
|
$vendor_lead_code = preg_replace("/$field_regx/i", "", $vendor_lead_code);
|
||||||
@@ -2069,11 +2127,11 @@ if (($leadfile) && ($LF_path))
|
|||||||
$phone_number = preg_replace("/^$SSweb_loader_phone_strip/",'',$phone_number);
|
$phone_number = preg_replace("/^$SSweb_loader_phone_strip/",'',$phone_number);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
$dup_lead=0; $moved_lead=0;
|
||||||
##### Check for duplicate phone numbers in vicidial_list table for all lists in a campaign #####
|
##### Check for duplicate phone numbers in vicidial_list table for all lists in a campaign #####
|
||||||
if (preg_match("/DUPCAMP/i",$dupcheck))
|
if (preg_match("/DUPCAMP/i",$dupcheck))
|
||||||
{
|
{
|
||||||
$dup_lead=0; $moved_lead=0;
|
$dup_lists='';
|
||||||
$dup_lists='';
|
|
||||||
$stmt="SELECT campaign_id from vicidial_lists where list_id='$list_id';";
|
$stmt="SELECT campaign_id from vicidial_lists where list_id='$list_id';";
|
||||||
$rslt=mysql_to_mysqli($stmt, $link);
|
$rslt=mysql_to_mysqli($stmt, $link);
|
||||||
$ci_recs = mysqli_num_rows($rslt);
|
$ci_recs = mysqli_num_rows($rslt);
|
||||||
@@ -2145,8 +2203,6 @@ if (($leadfile) && ($LF_path))
|
|||||||
##### Check for duplicate phone numbers in vicidial_list table entire database #####
|
##### Check for duplicate phone numbers in vicidial_list table entire database #####
|
||||||
if (preg_match("/DUPSYS/i",$dupcheck))
|
if (preg_match("/DUPSYS/i",$dupcheck))
|
||||||
{
|
{
|
||||||
$dup_lead=0; $moved_lead=0;
|
|
||||||
|
|
||||||
if ($status_mismatch_action)
|
if ($status_mismatch_action)
|
||||||
{
|
{
|
||||||
if (preg_match('/USING CHECK/', $status_mismatch_action))
|
if (preg_match('/USING CHECK/', $status_mismatch_action))
|
||||||
@@ -2194,8 +2250,6 @@ if (($leadfile) && ($LF_path))
|
|||||||
##### Check for duplicate phone numbers in vicidial_list table for one list_id #####
|
##### Check for duplicate phone numbers in vicidial_list table for one list_id #####
|
||||||
if (preg_match("/DUPLIST/i",$dupcheck))
|
if (preg_match("/DUPLIST/i",$dupcheck))
|
||||||
{
|
{
|
||||||
$dup_lead=0; $moved_lead=0;
|
|
||||||
|
|
||||||
if ($status_mismatch_action)
|
if ($status_mismatch_action)
|
||||||
{
|
{
|
||||||
if (preg_match('/USING CHECK/', $status_mismatch_action))
|
if (preg_match('/USING CHECK/', $status_mismatch_action))
|
||||||
@@ -2242,8 +2296,6 @@ if (($leadfile) && ($LF_path))
|
|||||||
##### Check for duplicate title and alt-phone in vicidial_list table for one list_id #####
|
##### Check for duplicate title and alt-phone in vicidial_list table for one list_id #####
|
||||||
if (preg_match("/DUPTITLEALTPHONELIST/i",$dupcheck))
|
if (preg_match("/DUPTITLEALTPHONELIST/i",$dupcheck))
|
||||||
{
|
{
|
||||||
$dup_lead=0; $moved_lead=0;
|
|
||||||
|
|
||||||
if ($status_mismatch_action)
|
if ($status_mismatch_action)
|
||||||
{
|
{
|
||||||
if (preg_match('/USING CHECK/', $status_mismatch_action))
|
if (preg_match('/USING CHECK/', $status_mismatch_action))
|
||||||
@@ -2291,8 +2343,6 @@ if (($leadfile) && ($LF_path))
|
|||||||
##### Check for duplicate phone numbers in vicidial_list table entire database #####
|
##### Check for duplicate phone numbers in vicidial_list table entire database #####
|
||||||
if (preg_match("/DUPTITLEALTPHONESYS/i",$dupcheck))
|
if (preg_match("/DUPTITLEALTPHONESYS/i",$dupcheck))
|
||||||
{
|
{
|
||||||
$dup_lead=0; $moved_lead=0;
|
|
||||||
|
|
||||||
if ($status_mismatch_action)
|
if ($status_mismatch_action)
|
||||||
{
|
{
|
||||||
if (preg_match('/USING CHECK/', $status_mismatch_action))
|
if (preg_match('/USING CHECK/', $status_mismatch_action))
|
||||||
@@ -2386,6 +2436,7 @@ if (($leadfile) && ($LF_path))
|
|||||||
$invalid_reason = _QXZ("INVALID PHONE NUMBER NANPA AREACODE PREFIX");
|
$invalid_reason = _QXZ("INVALID PHONE NUMBER NANPA AREACODE PREFIX");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
$dnc_matches=0;
|
||||||
if ($international_dnc_scrub and $valid_number > 0)
|
if ($international_dnc_scrub and $valid_number > 0)
|
||||||
{
|
{
|
||||||
$dnc_table_name="vicidial_dnc_".$international_dnc_scrub;
|
$dnc_table_name="vicidial_dnc_".$international_dnc_scrub;
|
||||||
@@ -2544,7 +2595,7 @@ if (($leadfile) && ($LF_path))
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if ($multi_insert_counter!=0)
|
if (isset($multi_insert_counter) && $multi_insert_counter!=0)
|
||||||
{
|
{
|
||||||
$stmtZ = "INSERT INTO vicidial_list (lead_id,entry_date,modify_date,status,user,vendor_lead_code,source_id,list_id,gmt_offset_now,called_since_last_reset,phone_code,phone_number,title,first_name,middle_initial,last_name,address1,address2,address3,city,state,province,postal_code,country_code,gender,date_of_birth,alt_phone,email,security_phrase,comments,called_count,last_local_call_time,rank,owner,entry_list_id) values".substr($multistmt, 0, -1).";";
|
$stmtZ = "INSERT INTO vicidial_list (lead_id,entry_date,modify_date,status,user,vendor_lead_code,source_id,list_id,gmt_offset_now,called_since_last_reset,phone_code,phone_number,title,first_name,middle_initial,last_name,address1,address2,address3,city,state,province,postal_code,country_code,gender,date_of_birth,alt_phone,email,security_phrase,comments,called_count,last_local_call_time,rank,owner,entry_list_id) values".substr($multistmt, 0, -1).";";
|
||||||
mysql_to_mysqli($stmtZ, $link);
|
mysql_to_mysqli($stmtZ, $link);
|
||||||
@@ -2568,7 +2619,7 @@ if (($leadfile) && ($LF_path))
|
|||||||
{fwrite($stmt_file, $custom_ins_stmt."\r\n");}
|
{fwrite($stmt_file, $custom_ins_stmt."\r\n");}
|
||||||
}
|
}
|
||||||
### LOG INSERTION Admin Log Table ###
|
### LOG INSERTION Admin Log Table ###
|
||||||
$stmt="INSERT INTO vicidial_admin_log set event_date='$NOW_TIME', user='$PHP_AUTH_USER', ip_address='$ip', event_section='LISTS', event_type='LOAD', record_id='$list_id_override', event_code='ADMIN LOAD LIST STANDARD', event_sql='', event_notes='File Name: $leadfile_name, GOOD: $good, BAD: $bad, MOVED: $moved, TOTAL: $total, DEBUG: dedupe_statuses:$dedupe_statuses[0]| dedupe_statuses_override:$dedupe_statuses_override| dupcheck:$dupcheck| status mismatch action: $status_mismatch_action| lead_file:$lead_file| list_id_override:$list_id_override| phone_code_override:$phone_code_override| postalgmt:$postalgmt| template_id:$template_id| usacan_check:$usacan_check| dnc_country_scrub:$international_dnc_scrub| state_conversion:$state_conversion| web_loader_phone_length:$web_loader_phone_length| web_loader_phone_strip:$SSweb_loader_phone_strip|';";
|
$stmt="INSERT INTO vicidial_admin_log set event_date='$NOW_TIME', user='$PHP_AUTH_USER', ip_address='$ip', event_section='LISTS', event_type='LOAD', record_id='$list_id_override', event_code='ADMIN LOAD LIST STANDARD', event_sql='', event_notes='File Name: $leadfile_name, GOOD: $good, BAD: $bad, MOVED: $moved, TOTAL: $total, DEBUG: dedupe_statuses:".(isset($dedupe_statuses[0]) ? $dedupe_statuses[0] : " NONE")."| dedupe_statuses_override:$dedupe_statuses_override| dupcheck:$dupcheck| status mismatch action: $status_mismatch_action| lead_file:$lead_file| list_id_override:$list_id_override| phone_code_override:$phone_code_override| postalgmt:$postalgmt| template_id:$template_id| usacan_check:$usacan_check| dnc_country_scrub:$international_dnc_scrub| state_conversion:$state_conversion| web_loader_phone_length:$web_loader_phone_length| web_loader_phone_strip:$SSweb_loader_phone_strip|';";
|
||||||
if ($DB) {echo "|$stmt|\n";}
|
if ($DB) {echo "|$stmt|\n";}
|
||||||
$rslt=mysql_to_mysqli($stmt, $link);
|
$rslt=mysql_to_mysqli($stmt, $link);
|
||||||
|
|
||||||
@@ -2643,9 +2694,9 @@ if (($leadfile) && ($LF_path))
|
|||||||
$total=0; $good=0; $bad=0; $dup=0; $inv=0; $post=0; $moved=0; $phone_list='';
|
$total=0; $good=0; $bad=0; $dup=0; $inv=0; $post=0; $moved=0; $phone_list='';
|
||||||
print "<center><font face='arial, helvetica' size=3 color='#009900'><B>"._QXZ("Processing")." $delim_name "._QXZ("file")."... ($tab_count|$pipe_count)\n";
|
print "<center><font face='arial, helvetica' size=3 color='#009900'><B>"._QXZ("Processing")." $delim_name "._QXZ("file")."... ($tab_count|$pipe_count)\n";
|
||||||
|
|
||||||
|
$status_dedupe_str=""; $statuses_clause="";
|
||||||
if (count($dedupe_statuses)>0) {
|
if (count($dedupe_statuses)>0) {
|
||||||
$statuses_clause=" and status in (";
|
$statuses_clause=" and status in (";
|
||||||
$status_dedupe_str="";
|
|
||||||
for($ds=0; $ds<count($dedupe_statuses); $ds++) {
|
for($ds=0; $ds<count($dedupe_statuses); $ds++) {
|
||||||
$dedupe_statuses[$ds] = preg_replace('/[^-_0-9\p{L}]/u', '', $dedupe_statuses[$ds]);
|
$dedupe_statuses[$ds] = preg_replace('/[^-_0-9\p{L}]/u', '', $dedupe_statuses[$ds]);
|
||||||
$statuses_clause.="'$dedupe_statuses[$ds]',";
|
$statuses_clause.="'$dedupe_statuses[$ds]',";
|
||||||
@@ -2729,6 +2780,7 @@ if (($leadfile) && ($LF_path))
|
|||||||
$delete_hopper_rslt=mysql_to_mysqli($delete_hopper_stmt, $link);
|
$delete_hopper_rslt=mysql_to_mysqli($delete_hopper_stmt, $link);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
$record=0;
|
||||||
while (!feof($file))
|
while (!feof($file))
|
||||||
{
|
{
|
||||||
$record++;
|
$record++;
|
||||||
@@ -2744,34 +2796,34 @@ if (($leadfile) && ($LF_path))
|
|||||||
$modify_date = "";
|
$modify_date = "";
|
||||||
$status = "NEW";
|
$status = "NEW";
|
||||||
$user ="";
|
$user ="";
|
||||||
$vendor_lead_code = $row[0];
|
$vendor_lead_code = (isset($row[0]) ? $row[0] : "");
|
||||||
$source_code = $row[1];
|
$source_code = (isset($row[1]) ? $row[1] : "");
|
||||||
$source_id=$source_code;
|
$source_id=$source_code;
|
||||||
$list_id = $row[2];
|
$list_id = (isset($row[2]) ? $row[2] : "");
|
||||||
$gmt_offset = '0';
|
$gmt_offset = '0';
|
||||||
$called_since_last_reset='N';
|
$called_since_last_reset='N';
|
||||||
$phone_code = preg_replace('/[^0-9]/i', '', $row[3]);
|
$phone_code = (isset($row[3]) ? preg_replace('/[^0-9]/i', '', $row[3]) : "");
|
||||||
$phone_number = preg_replace('/[^0-9]/i', '', $row[4]);
|
$phone_number = (isset($row[4]) ? preg_replace('/[^0-9]/i', '', $row[4]) : "");
|
||||||
$title = $row[5];
|
$title = (isset($row[5]) ? $row[5] : "");
|
||||||
$first_name = $row[6];
|
$first_name = (isset($row[6]) ? $row[6] : "");
|
||||||
$middle_initial = $row[7];
|
$middle_initial = (isset($row[7]) ? $row[7] : "");
|
||||||
$last_name = $row[8];
|
$last_name = (isset($row[8]) ? $row[8] : "");
|
||||||
$address1 = $row[9];
|
$address1 = (isset($row[9]) ? $row[9] : "");
|
||||||
$address2 = $row[10];
|
$address2 = (isset($row[10]) ? $row[10] : "");
|
||||||
$address3 = $row[11];
|
$address3 = (isset($row[11]) ? $row[11] : "");
|
||||||
$city =$row[12];
|
$city = (isset($row[12]) ? $row[12] : "");
|
||||||
$state = $row[13];
|
$state = (isset($row[13]) ? $row[13] : "");
|
||||||
$province = $row[14];
|
$province = (isset($row[14]) ? $row[14] : "");
|
||||||
$postal_code = $row[15];
|
$postal_code = (isset($row[15]) ? $row[15] : "");
|
||||||
$country_code = $row[16];
|
$country_code = (isset($row[16]) ? $row[16] : "");
|
||||||
$gender = $row[17];
|
$gender = (isset($row[17]) ? $row[17] : "");
|
||||||
$date_of_birth = $row[18];
|
$date_of_birth = (isset($row[18]) ? $row[18] : "");
|
||||||
$alt_phone = preg_replace('/[^0-9]/i', '', $row[19]);
|
$alt_phone = (isset($row[19]) ? preg_replace('/[^0-9]/i', '', $row[19]) : "");
|
||||||
$email = $row[20];
|
$email = (isset($row[20]) ? $row[20] : "");
|
||||||
$security_phrase = $row[21];
|
$security_phrase = (isset($row[21]) ? $row[21] : "");
|
||||||
$comments = trim($row[22]);
|
$comments = (isset($row[22]) ? trim($row[22]) : "");
|
||||||
$rank = $row[23];
|
$rank = (isset($row[23]) ? $row[23] : "");
|
||||||
$owner = $row[24];
|
$owner = (isset($row[24]) ? $row[24] : "");
|
||||||
|
|
||||||
# replace ' " ` \ ; with nothing
|
# replace ' " ` \ ; with nothing
|
||||||
$vendor_lead_code = preg_replace("/$field_regx/i", "", $vendor_lead_code);
|
$vendor_lead_code = preg_replace("/$field_regx/i", "", $vendor_lead_code);
|
||||||
@@ -2837,11 +2889,11 @@ if (($leadfile) && ($LF_path))
|
|||||||
$phone_number = preg_replace("/^$SSweb_loader_phone_strip/",'',$phone_number);
|
$phone_number = preg_replace("/^$SSweb_loader_phone_strip/",'',$phone_number);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
$dup_lead=0; $moved_lead=0;
|
||||||
##### Check for duplicate phone numbers in vicidial_list table for all lists in a campaign #####
|
##### Check for duplicate phone numbers in vicidial_list table for all lists in a campaign #####
|
||||||
if (preg_match("/DUPCAMP/i",$dupcheck))
|
if (preg_match("/DUPCAMP/i",$dupcheck))
|
||||||
{
|
{
|
||||||
$dup_lead=0; $moved_lead=0;
|
$dup_lists='';
|
||||||
$dup_lists='';
|
|
||||||
$stmt="SELECT campaign_id from vicidial_lists where list_id='$list_id';";
|
$stmt="SELECT campaign_id from vicidial_lists where list_id='$list_id';";
|
||||||
$rslt=mysql_to_mysqli($stmt, $link);
|
$rslt=mysql_to_mysqli($stmt, $link);
|
||||||
$ci_recs = mysqli_num_rows($rslt);
|
$ci_recs = mysqli_num_rows($rslt);
|
||||||
@@ -2913,8 +2965,6 @@ if (($leadfile) && ($LF_path))
|
|||||||
##### Check for duplicate phone numbers in vicidial_list table entire database #####
|
##### Check for duplicate phone numbers in vicidial_list table entire database #####
|
||||||
if (preg_match("/DUPSYS/i",$dupcheck))
|
if (preg_match("/DUPSYS/i",$dupcheck))
|
||||||
{
|
{
|
||||||
$dup_lead=0; $moved_lead=0;
|
|
||||||
|
|
||||||
if ($status_mismatch_action)
|
if ($status_mismatch_action)
|
||||||
{
|
{
|
||||||
if (preg_match('/USING CHECK/', $status_mismatch_action))
|
if (preg_match('/USING CHECK/', $status_mismatch_action))
|
||||||
@@ -2962,8 +3012,6 @@ if (($leadfile) && ($LF_path))
|
|||||||
##### Check for duplicate phone numbers in vicidial_list table for one list_id #####
|
##### Check for duplicate phone numbers in vicidial_list table for one list_id #####
|
||||||
if (preg_match("/DUPLIST/i",$dupcheck))
|
if (preg_match("/DUPLIST/i",$dupcheck))
|
||||||
{
|
{
|
||||||
$dup_lead=0; $moved_lead=0;
|
|
||||||
|
|
||||||
if ($status_mismatch_action)
|
if ($status_mismatch_action)
|
||||||
{
|
{
|
||||||
if (preg_match('/USING CHECK/', $status_mismatch_action))
|
if (preg_match('/USING CHECK/', $status_mismatch_action))
|
||||||
@@ -3010,8 +3058,6 @@ if (($leadfile) && ($LF_path))
|
|||||||
##### Check for duplicate title and alt-phone in vicidial_list table for one list_id #####
|
##### Check for duplicate title and alt-phone in vicidial_list table for one list_id #####
|
||||||
if (preg_match("/DUPTITLEALTPHONELIST/i",$dupcheck))
|
if (preg_match("/DUPTITLEALTPHONELIST/i",$dupcheck))
|
||||||
{
|
{
|
||||||
$dup_lead=0; $moved_lead=0;
|
|
||||||
|
|
||||||
if ($status_mismatch_action)
|
if ($status_mismatch_action)
|
||||||
{
|
{
|
||||||
if (preg_match('/USING CHECK/', $status_mismatch_action))
|
if (preg_match('/USING CHECK/', $status_mismatch_action))
|
||||||
@@ -3059,8 +3105,6 @@ if (($leadfile) && ($LF_path))
|
|||||||
##### Check for duplicate phone numbers in vicidial_list table entire database #####
|
##### Check for duplicate phone numbers in vicidial_list table entire database #####
|
||||||
if (preg_match("/DUPTITLEALTPHONESYS/i",$dupcheck))
|
if (preg_match("/DUPTITLEALTPHONESYS/i",$dupcheck))
|
||||||
{
|
{
|
||||||
$dup_lead=0; $moved_lead=0;
|
|
||||||
|
|
||||||
if ($status_mismatch_action)
|
if ($status_mismatch_action)
|
||||||
{
|
{
|
||||||
if (preg_match('/USING CHECK/', $status_mismatch_action))
|
if (preg_match('/USING CHECK/', $status_mismatch_action))
|
||||||
@@ -3178,7 +3222,7 @@ if (($leadfile) && ($LF_path))
|
|||||||
|
|
||||||
$gmt_offset = lookup_gmt($phone_code,$USarea,$state,$LOCAL_GMT_OFF_STD,$Shour,$Smin,$Ssec,$Smon,$Smday,$Syear,$postalgmt,$postal_code,$owner,$USprefix);
|
$gmt_offset = lookup_gmt($phone_code,$USarea,$state,$LOCAL_GMT_OFF_STD,$Shour,$Smin,$Ssec,$Smon,$Smday,$Syear,$postalgmt,$postal_code,$owner,$USprefix);
|
||||||
|
|
||||||
if ($multi_insert_counter > 8)
|
if (!isset($multi_insert_counter) || $multi_insert_counter > 8)
|
||||||
{
|
{
|
||||||
### insert good deal into pending_transactions table ###
|
### insert good deal into pending_transactions table ###
|
||||||
$stmtZ = "INSERT INTO vicidial_list (lead_id,entry_date,modify_date,status,user,vendor_lead_code,source_id,list_id,gmt_offset_now,called_since_last_reset,phone_code,phone_number,title,first_name,middle_initial,last_name,address1,address2,address3,city,state,province,postal_code,country_code,gender,date_of_birth,alt_phone,email,security_phrase,comments,called_count,last_local_call_time,rank,owner,entry_list_id) values$multistmt('',\"$entry_date\",\"$modify_date\",\"$status\",\"$user\",\"$vendor_lead_code\",\"$source_id\",\"$list_id\",\"$gmt_offset\",\"$called_since_last_reset\",\"$phone_code\",\"$phone_number\",\"$title\",\"$first_name\",\"$middle_initial\",\"$last_name\",\"$address1\",\"$address2\",\"$address3\",\"$city\",\"$state\",\"$province\",\"$postal_code\",\"$country_code\",\"$gender\",\"$date_of_birth\",\"$alt_phone\",\"$email\",\"$security_phrase\",\"$comments\",0,\"2008-01-01 00:00:00\",\"$rank\",\"$owner\",'0');";
|
$stmtZ = "INSERT INTO vicidial_list (lead_id,entry_date,modify_date,status,user,vendor_lead_code,source_id,list_id,gmt_offset_now,called_since_last_reset,phone_code,phone_number,title,first_name,middle_initial,last_name,address1,address2,address3,city,state,province,postal_code,country_code,gender,date_of_birth,alt_phone,email,security_phrase,comments,called_count,last_local_call_time,rank,owner,entry_list_id) values$multistmt('',\"$entry_date\",\"$modify_date\",\"$status\",\"$user\",\"$vendor_lead_code\",\"$source_id\",\"$list_id\",\"$gmt_offset\",\"$called_since_last_reset\",\"$phone_code\",\"$phone_number\",\"$title\",\"$first_name\",\"$middle_initial\",\"$last_name\",\"$address1\",\"$address2\",\"$address3\",\"$city\",\"$state\",\"$province\",\"$postal_code\",\"$country_code\",\"$gender\",\"$date_of_birth\",\"$alt_phone\",\"$email\",\"$security_phrase\",\"$comments\",0,\"2008-01-01 00:00:00\",\"$rank\",\"$owner\",'0');";
|
||||||
@@ -3231,7 +3275,7 @@ if (($leadfile) && ($LF_path))
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if ($multi_insert_counter!=0)
|
if (isset($multi_insert_counter) && $multi_insert_counter!=0)
|
||||||
{
|
{
|
||||||
$stmtZ = "INSERT INTO vicidial_list (lead_id,entry_date,modify_date,status,user,vendor_lead_code,source_id,list_id,gmt_offset_now,called_since_last_reset,phone_code,phone_number,title,first_name,middle_initial,last_name,address1,address2,address3,city,state,province,postal_code,country_code,gender,date_of_birth,alt_phone,email,security_phrase,comments,called_count,last_local_call_time,rank,owner,entry_list_id) values".substr($multistmt, 0, -1).";";
|
$stmtZ = "INSERT INTO vicidial_list (lead_id,entry_date,modify_date,status,user,vendor_lead_code,source_id,list_id,gmt_offset_now,called_since_last_reset,phone_code,phone_number,title,first_name,middle_initial,last_name,address1,address2,address3,city,state,province,postal_code,country_code,gender,date_of_birth,alt_phone,email,security_phrase,comments,called_count,last_local_call_time,rank,owner,entry_list_id) values".substr($multistmt, 0, -1).";";
|
||||||
mysql_to_mysqli($stmtZ, $link);
|
mysql_to_mysqli($stmtZ, $link);
|
||||||
@@ -3239,7 +3283,7 @@ if (($leadfile) && ($LF_path))
|
|||||||
{fwrite($stmt_file, $stmtZ."\r\n");}
|
{fwrite($stmt_file, $stmtZ."\r\n");}
|
||||||
}
|
}
|
||||||
### LOG INSERTION Admin Log Table ###
|
### LOG INSERTION Admin Log Table ###
|
||||||
$stmt="INSERT INTO vicidial_admin_log set event_date='$NOW_TIME', user='$PHP_AUTH_USER', ip_address='$ip', event_section='LISTS', event_type='LOAD', record_id='$list_id_override', event_code='ADMIN LOAD LIST STANDARD', event_sql='', event_notes='File Name: $leadfile_name, GOOD: $good, BAD: $bad, MOVED: $moved, TOTAL: $total, DEBUG: dedupe_statuses:$dedupe_statuses[0]| dedupe_statuses_override:$dedupe_statuses_override| dupcheck:$dupcheck| status mismatch action: $status_mismatch_action| lead_file:$lead_file| list_id_override:$list_id_override| phone_code_override:$phone_code_override| postalgmt:$postalgmt| template_id:$template_id| usacan_check:$usacan_check| dnc_country_scrub:$international_dnc_scrub| state_conversion:$state_conversion| web_loader_phone_length:$web_loader_phone_length| web_loader_phone_strip:$SSweb_loader_phone_strip|';";
|
$stmt="INSERT INTO vicidial_admin_log set event_date='$NOW_TIME', user='$PHP_AUTH_USER', ip_address='$ip', event_section='LISTS', event_type='LOAD', record_id='$list_id_override', event_code='ADMIN LOAD LIST STANDARD', event_sql='', event_notes='File Name: $leadfile_name, GOOD: $good, BAD: $bad, MOVED: $moved, TOTAL: $total, DEBUG: dedupe_statuses:".(isset($dedupe_statuses[0]) ? $dedupe_statuses[0] : " NONE")."| dedupe_statuses_override:$dedupe_statuses_override| dupcheck:$dupcheck| status mismatch action: $status_mismatch_action| lead_file:$lead_file| list_id_override:$list_id_override| phone_code_override:$phone_code_override| postalgmt:$postalgmt| template_id:$template_id| usacan_check:$usacan_check| dnc_country_scrub:$international_dnc_scrub| state_conversion:$state_conversion| web_loader_phone_length:$web_loader_phone_length| web_loader_phone_strip:$SSweb_loader_phone_strip|';";
|
||||||
if ($DB) {echo "|$stmt|\n";}
|
if ($DB) {echo "|$stmt|\n";}
|
||||||
$rslt=mysql_to_mysqli($stmt, $link);
|
$rslt=mysql_to_mysqli($stmt, $link);
|
||||||
|
|
||||||
|
|||||||
File diff suppressed because one or more lines are too long
@@ -1,7 +1,7 @@
|
|||||||
<?php
|
<?php
|
||||||
# list_merge.php - merge smaller lists into a larger one. Part of Admin Utilities.
|
# list_merge.php - merge smaller lists into a larger one. Part of Admin Utilities.
|
||||||
#
|
#
|
||||||
# Copyright (C) 2024 Matt Florell,Joseph Johnson <vicidial@gmail.com> LICENSE: AGPLv2
|
# Copyright (C) 2026 Matt Florell,Joseph Johnson <vicidial@gmail.com> LICENSE: AGPLv2
|
||||||
#
|
#
|
||||||
# CHANGES
|
# CHANGES
|
||||||
# 161004-2240 - Initial Build
|
# 161004-2240 - Initial Build
|
||||||
@@ -12,16 +12,17 @@
|
|||||||
# 201117-1350 - Translation bug fixed, Issue #1236
|
# 201117-1350 - Translation bug fixed, Issue #1236
|
||||||
# 220227-2210 - Added allow_web_debug system setting
|
# 220227-2210 - Added allow_web_debug system setting
|
||||||
# 240801-1133 - Code updates for PHP8 compatibility
|
# 240801-1133 - Code updates for PHP8 compatibility
|
||||||
|
# 260415-1738 - More code updates for PHP8 compatibility
|
||||||
#
|
#
|
||||||
|
|
||||||
$version = '2.14-5';
|
$version = '2.14-6';
|
||||||
$build = '240801-1133';
|
$build = '260415-1738';
|
||||||
|
|
||||||
require("dbconnect_mysqli.php");
|
require("dbconnect_mysqli.php");
|
||||||
require("functions.php");
|
require("functions.php");
|
||||||
|
|
||||||
$PHP_AUTH_USER=$_SERVER['PHP_AUTH_USER'];
|
$PHP_AUTH_USER=(array_key_exists('PHP_AUTH_USER', $_SERVER) ? $_SERVER['PHP_AUTH_USER'] : "");
|
||||||
$PHP_AUTH_PW=$_SERVER['PHP_AUTH_PW'];
|
$PHP_AUTH_PW=(array_key_exists('PHP_AUTH_PW', $_SERVER) ? $_SERVER['PHP_AUTH_PW'] : "");
|
||||||
$PHP_SELF=$_SERVER['PHP_SELF'];
|
$PHP_SELF=$_SERVER['PHP_SELF'];
|
||||||
$PHP_SELF = preg_replace('/\.php.*/i','.php',$PHP_SELF);
|
$PHP_SELF = preg_replace('/\.php.*/i','.php',$PHP_SELF);
|
||||||
$ip = getenv("REMOTE_ADDR");
|
$ip = getenv("REMOTE_ADDR");
|
||||||
@@ -48,22 +49,28 @@ if (isset($_GET["num_leads"])) {$num_leads=$_GET["num_leads"];}
|
|||||||
elseif (isset($_POST["num_leads"])) {$num_leads=$_POST["num_leads"];}
|
elseif (isset($_POST["num_leads"])) {$num_leads=$_POST["num_leads"];}
|
||||||
if (isset($_GET["destination_list_id"])) {$destination_list_id=$_GET["destination_list_id"];}
|
if (isset($_GET["destination_list_id"])) {$destination_list_id=$_GET["destination_list_id"];}
|
||||||
elseif (isset($_POST["destination_list_id"])) {$destination_list_id=$_POST["destination_list_id"];}
|
elseif (isset($_POST["destination_list_id"])) {$destination_list_id=$_POST["destination_list_id"];}
|
||||||
|
else {$destination_list_id="";}
|
||||||
if (isset($_GET["new_list_id"])) {$new_list_id=$_GET["new_list_id"];}
|
if (isset($_GET["new_list_id"])) {$new_list_id=$_GET["new_list_id"];}
|
||||||
elseif (isset($_POST["new_list_id"])) {$new_list_id=$_POST["new_list_id"];}
|
elseif (isset($_POST["new_list_id"])) {$new_list_id=$_POST["new_list_id"];}
|
||||||
|
else {$new_list_id="";}
|
||||||
if (isset($_GET["new_list_name"])) {$new_list_name=$_GET["new_list_name"];}
|
if (isset($_GET["new_list_name"])) {$new_list_name=$_GET["new_list_name"];}
|
||||||
elseif (isset($_POST["new_list_name"])) {$new_list_name=$_POST["new_list_name"];}
|
elseif (isset($_POST["new_list_name"])) {$new_list_name=$_POST["new_list_name"];}
|
||||||
|
else {$new_list_name="";}
|
||||||
if (isset($_GET["new_list_description"])) {$new_list_description=$_GET["new_list_description"];}
|
if (isset($_GET["new_list_description"])) {$new_list_description=$_GET["new_list_description"];}
|
||||||
elseif (isset($_POST["new_list_description"])) {$new_list_description=$_POST["new_list_description"];}
|
elseif (isset($_POST["new_list_description"])) {$new_list_description=$_POST["new_list_description"];}
|
||||||
|
else {$new_list_description="";}
|
||||||
if (isset($_GET["active"])) {$active=$_GET["active"];}
|
if (isset($_GET["active"])) {$active=$_GET["active"];}
|
||||||
elseif (isset($_POST["active"])) {$active=$_POST["active"];}
|
elseif (isset($_POST["active"])) {$active=$_POST["active"];}
|
||||||
|
else {$active="";}
|
||||||
if (isset($_GET["campaign_id"])) {$campaign_id=$_GET["campaign_id"];}
|
if (isset($_GET["campaign_id"])) {$campaign_id=$_GET["campaign_id"];}
|
||||||
elseif (isset($_POST["campaign_id"])) {$campaign_id=$_POST["campaign_id"];}
|
elseif (isset($_POST["campaign_id"])) {$campaign_id=$_POST["campaign_id"];}
|
||||||
|
else {$campaign_id="";}
|
||||||
if (isset($_GET["retain_original_list"])) {$retain_original_list=$_GET["retain_original_list"];}
|
if (isset($_GET["retain_original_list"])) {$retain_original_list=$_GET["retain_original_list"];}
|
||||||
elseif (isset($_POST["retain_original_list"])) {$retain_original_list=$_POST["retain_original_list"];}
|
elseif (isset($_POST["retain_original_list"])) {$retain_original_list=$_POST["retain_original_list"];}
|
||||||
|
else {$retain_original_list="";}
|
||||||
if (isset($_GET["create_new_list"])) {$create_new_list=$_GET["create_new_list"];}
|
if (isset($_GET["create_new_list"])) {$create_new_list=$_GET["create_new_list"];}
|
||||||
elseif (isset($_POST["create_new_list"])) {$create_new_list=$_POST["create_new_list"];}
|
elseif (isset($_POST["create_new_list"])) {$create_new_list=$_POST["create_new_list"];}
|
||||||
|
else {$create_new_list="";}
|
||||||
$DB = preg_replace('/[^0-9]/','',$DB);
|
|
||||||
|
|
||||||
#############################################
|
#############################################
|
||||||
##### START SYSTEM_SETTINGS LOOKUP #####
|
##### START SYSTEM_SETTINGS LOOKUP #####
|
||||||
@@ -89,7 +96,8 @@ else
|
|||||||
# there is something really weird if there are no system settings
|
# there is something really weird if there are no system settings
|
||||||
exit;
|
exit;
|
||||||
}
|
}
|
||||||
if ($SSallow_web_debug < 1) {$DB=0;}
|
if ($SSallow_web_debug < 1 || !isset($DB)) {$DB=0;}
|
||||||
|
$DB=preg_replace("/[^0-9a-zA-Z]/","",$DB);
|
||||||
##### END SETTINGS LOOKUP #####
|
##### END SETTINGS LOOKUP #####
|
||||||
###########################################
|
###########################################
|
||||||
|
|
||||||
@@ -615,7 +623,7 @@ if (($submit != "submit" ) && ($confirm != "CONFIRM"))
|
|||||||
echo "<tr bgcolor=#$SSstd_row1_background><td align=right>"._QXZ("List Description").": </td><td align=left><input type=text name='new_list_description' size=30 maxlength=255 value='".$new_list_description."'>$NWB#lists-list_description$NWE</td></tr>\n";
|
echo "<tr bgcolor=#$SSstd_row1_background><td align=right>"._QXZ("List Description").": </td><td align=left><input type=text name='new_list_description' size=30 maxlength=255 value='".$new_list_description."'>$NWB#lists-list_description$NWE</td></tr>\n";
|
||||||
echo "<tr bgcolor=#$SSstd_row1_background><td align=right>"._QXZ("Campaign").": </td><td align=left><select size=1 name='campaign_id'>\n";
|
echo "<tr bgcolor=#$SSstd_row1_background><td align=right>"._QXZ("Campaign").": </td><td align=left><select size=1 name='campaign_id'>\n";
|
||||||
|
|
||||||
$stmt="SELECT campaign_id,campaign_name from vicidial_campaigns $whereLOGallowed_campaignsSQL order by campaign_id;";
|
$stmt="SELECT campaign_id,campaign_name from vicidial_campaigns WHERE campaign_id IN ($allowed_campaigns_sql) order by campaign_id;"; # $whereLOGallowed_campaignsSQL - undefined
|
||||||
$rslt=mysql_to_mysqli($stmt, $link);
|
$rslt=mysql_to_mysqli($stmt, $link);
|
||||||
$campaigns_to_print = mysqli_num_rows($rslt);
|
$campaigns_to_print = mysqli_num_rows($rslt);
|
||||||
$campaigns_list='';
|
$campaigns_list='';
|
||||||
|
|||||||
Reference in New Issue
Block a user