Skip to content

Commit

Permalink
add support for psychologicalStageChangeReason
Browse files Browse the repository at this point in the history
  • Loading branch information
eashaw committed Aug 27, 2024
1 parent ee66a81 commit f672af5
Showing 1 changed file with 8 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,10 @@ module.exports = {
'6 - Has team buy-in'
]
},
psychologicalStageChangeReason: {
type: 'string',
example: 'Website - Organic start flow'
},
leadSource: {
type: 'string',
isIn: [
Expand All @@ -54,7 +58,7 @@ module.exports = {
},


fn: async function ({emailAddress, linkedinUrl, firstName, lastName, organization, primaryBuyingSituation, psychologicalStage, leadSource}) {
fn: async function ({emailAddress, linkedinUrl, firstName, lastName, organization, primaryBuyingSituation, psychologicalStage, psychologicalStageChangeReason, leadSource}) {

require('assert')(sails.config.custom.salesforceIntegrationUsername);
require('assert')(sails.config.custom.salesforceIntegrationPasskey);
Expand Down Expand Up @@ -90,6 +94,9 @@ module.exports = {
if(psychologicalStage) {
valuesToSet.Stage__c = psychologicalStage;// eslint-disable-line camelcase
}
if(psychologicalStageChangeReason) {
valuesToSet.Psystage_change_reason__c = psychologicalStageChangeReason;// eslint-disable-line camelcase
}

let existingContactRecord;
// Search for an existing Contact record using the provided email address or linkedIn profile URL.
Expand Down

0 comments on commit f672af5

Please sign in to comment.