Skip to content

Commit 8df5f2b

Browse files
committed
fix: sfdc billing account filed dev/prod config
ref issue #631
1 parent 9e57db3 commit 8df5f2b

File tree

4 files changed

+7
-4
lines changed

4 files changed

+7
-4
lines changed

config/default.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -82,5 +82,6 @@
8282
"CLIENT_AUDIENCE": "",
8383
"SUBJECT": "",
8484
"CLIENT_ID": ""
85-
}
85+
},
86+
"sfdcBillingAccountNameField": "Billing_Account_Name__c"
8687
}

config/development.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,5 +7,6 @@
77
"connectProjectsUrl": "https://connect.topcoder-dev.com/projects/",
88
"memberServiceEndpoint": "https://api.topcoder-dev.com/v3/members",
99
"identityServiceEndpoint": "https://api.topcoder-dev.com/v3/",
10-
"taasJobApiUrl": "https://api.topcoder-dev.com/v5/jobs"
10+
"taasJobApiUrl": "https://api.topcoder-dev.com/v5/jobs",
11+
"sfdcBillingAccountNameField": "Billing_Account_Name__c"
1112
}

config/production.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
{
22
"authDomain": "topcoder.com",
3-
"connectProjectsUrl": "https://connect.topcoder.com/projects/"
3+
"connectProjectsUrl": "https://connect.topcoder.com/projects/",
4+
"sfdcBillingAccountNameField": "Billing_Account_name__c"
45
}

src/services/salesforceService.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@ class SalesforceService {
7070
10,
7171
null, // fallback to null if cannot parse
7272
),
73-
name: _.get(o, 'Topcoder_Billing_Account__r.Billing_Account_name__c'),
73+
name: _.get(o, `Topcoder_Billing_Account__r.${config.get('sfdcBillingAccountNameField')}`),
7474
startDate: _.get(o, 'Topcoder_Billing_Account__r.Start_Date__c'),
7575
endDate: _.get(o, 'Topcoder_Billing_Account__r.End_Date__c'),
7676
}));

0 commit comments

Comments
 (0)