From 7ddba79090098f1c501c1f1900fd22433cedd769 Mon Sep 17 00:00:00 2001 From: Rebeka Dekany <50901361+rebekadekany@users.noreply.github.com> Date: Mon, 13 Nov 2023 18:01:08 +0100 Subject: [PATCH] Merge pull request #15740 from overleaf/dk-odc-newprops Store ODC form step 3 data in mongo GitOrigin-RevId: 91311efaddb5ccb9a456ea359140235235530536 --- .../OnboardingDataCollectionManager.js | 16 ++++++++++++++++ .../app/src/models/OnboardingDataCollection.js | 8 ++++++++ 2 files changed, 24 insertions(+) diff --git a/services/web/app/src/Features/OnboardingDataCollection/OnboardingDataCollectionManager.js b/services/web/app/src/Features/OnboardingDataCollection/OnboardingDataCollectionManager.js index 32e09b283b..c9bcb6d278 100644 --- a/services/web/app/src/Features/OnboardingDataCollection/OnboardingDataCollectionManager.js +++ b/services/web/app/src/Features/OnboardingDataCollection/OnboardingDataCollectionManager.js @@ -17,6 +17,14 @@ async function upsertOnboardingDataCollection({ lastName, usedLatex, primaryOccupation, + companyDivisionDepartment, + companyJobTitle, + governmentJobTitle, + otherJobTitle, + nonprofitDivisionDepartment, + nonprofitJobTitle, + role, + subjectArea, updatedAt, }) { const odc = await OnboardingDataCollection.findOneAndUpdate( @@ -26,6 +34,14 @@ async function upsertOnboardingDataCollection({ lastName, usedLatex, primaryOccupation, + companyDivisionDepartment, + companyJobTitle, + governmentJobTitle, + otherJobTitle, + nonprofitDivisionDepartment, + nonprofitJobTitle, + role, + subjectArea, updatedAt, }, { upsert: true } diff --git a/services/web/app/src/models/OnboardingDataCollection.js b/services/web/app/src/models/OnboardingDataCollection.js index e54b8254eb..3f9484b0e2 100644 --- a/services/web/app/src/models/OnboardingDataCollection.js +++ b/services/web/app/src/models/OnboardingDataCollection.js @@ -7,6 +7,14 @@ const OnboardingDataCollectionSchema = new Schema( lastName: { type: String, default: null }, primaryOccupation: { type: String, default: null }, usedLatex: { type: String, default: null }, + companyDivisionDepartment: { type: String, default: null }, + companyJobTitle: { type: String, default: null }, + governmentJobTitle: { type: String, default: null }, + otherJobTitle: { type: String, default: null }, + nonprofitDivisionDepartment: { type: String, default: null }, + nonprofitJobTitle: { type: String, default: null }, + role: { type: String, default: null }, + subjectArea: { type: String, default: null }, updatedAt: { type: Date, default: Date.now }, }, {