-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #719 from cabinetoffice/feature/dp-447-pdf-share-m…
…y-info BE - Exclusions - Share my information - PDF - Exclusions
- Loading branch information
Showing
9 changed files
with
146 additions
and
11 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,4 @@ | ||
using Amazon.CloudWatch; | ||
using CO.CDP.DataSharing.WebApi.Model; | ||
using CO.CDP.OrganisationInformation; | ||
using CO.CDP.OrganisationInformation.Persistence; | ||
|
@@ -25,13 +26,13 @@ public static CO.CDP.OrganisationInformation.Persistence.Forms.SharedConsent Cre | |
Organisation = theOrganisation, | ||
FormId = 1, | ||
Form = null!, | ||
AnswerSets = null!, | ||
AnswerSets = [], | ||
SubmissionState = default, | ||
SubmittedAt = null, | ||
FormVersionId = string.Empty, | ||
ShareCode = shareCode ?? "valid-sharecode", | ||
CreatedOn = DateTimeOffset.UtcNow, | ||
UpdatedOn = DateTimeOffset.UtcNow | ||
UpdatedOn = DateTimeOffset.UtcNow, | ||
}; | ||
} | ||
|
||
|
@@ -150,6 +151,22 @@ public static BasicInformation CreateMockBasicInformation() | |
} | ||
}; | ||
} | ||
|
||
public static List<FormAnswerSetForPdf> CreateMockFormAnswerSetForPdfs() | ||
{ | ||
return | ||
[ | ||
new FormAnswerSetForPdf() { | ||
QuestionAnswers = [ | ||
new Tuple<string, string>("Did this exclusion happen in the UK? ", "Yes"), | ||
new Tuple<string, string>("Enter an email address ", "[email protected]") | ||
], | ||
SectionName = "Exclusions", | ||
SectionType = OrganisationInformation.Persistence.Forms.FormSectionType.Exclusions | ||
} | ||
]; | ||
} | ||
|
||
public static List<ConnectedPersonInformation> CreateMockConnectedPersonInformation() | ||
{ | ||
return | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
10 changes: 10 additions & 0 deletions
10
Services/CO.CDP.DataSharing.WebApi/Model/FormAnswerSetForPdf.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
using CO.CDP.OrganisationInformation.Persistence.Forms; | ||
|
||
namespace CO.CDP.DataSharing.WebApi.Model; | ||
|
||
public record FormAnswerSetForPdf | ||
{ | ||
public required string SectionName { get; init; } | ||
public required FormSectionType SectionType { get; init; } | ||
public required List<Tuple<string, string>> QuestionAnswers { get; init; } | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters