IO-3570 Fortellis Owner Phone Search
Signed-off-by: Allan Carr <allan@imexsystems.ca>
This commit is contained in:
@@ -425,7 +425,7 @@ async function QueryDmsCustomerByName({ socket, redisHelpers, JobData }) {
|
||||
const ownerName =
|
||||
JobData.ownr_co_nm && JobData.ownr_co_nm.trim() !== ""
|
||||
? //? [["firstName", JobData.ownr_co_nm.replace(replaceSpecialRegex, "").toUpperCase()]] // Commented out until we receive direction.
|
||||
[["phone", JobData.ownr_ph1?.replace(replaceSpecialRegex, "")]]
|
||||
[["phone", JobData.ownr_ph1?.replace(/[^0-9]/g, "")]]
|
||||
: [
|
||||
["firstName", JobData.ownr_fn?.replace(/[^a-zA-Z0-9-]/g, "").toUpperCase()],
|
||||
["lastName", JobData.ownr_ln?.replace(/[^a-zA-Z0-9-]/g, "").toUpperCase()]
|
||||
@@ -501,7 +501,7 @@ async function InsertDmsCustomer({ socket, redisHelpers, JobData }) {
|
||||
phones: [
|
||||
{
|
||||
//"uuid": "",
|
||||
number: JobData.ownr_ph1?.replace(replaceSpecialRegex, ""),
|
||||
number: JobData.ownr_ph1?.replace(/[^0-9]/g, ""),
|
||||
type: "HOME"
|
||||
// "doNotCallIndicator": true,
|
||||
// "doNotCallIndicatorDate": `null,
|
||||
|
||||
Reference in New Issue
Block a user