From 5066d10e1dd3d2d6a969833ea541ddcefa239210 Mon Sep 17 00:00:00 2001 From: kevwhitt-hee Date: Wed, 10 Jan 2024 08:43:57 +0000 Subject: [PATCH 01/22] Update continuous-integration-workflow.yml to run on PR rather than push --- .github/workflows/continuous-integration-workflow.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/continuous-integration-workflow.yml b/.github/workflows/continuous-integration-workflow.yml index c0e0da4..c59f759 100644 --- a/.github/workflows/continuous-integration-workflow.yml +++ b/.github/workflows/continuous-integration-workflow.yml @@ -1,5 +1,5 @@ name: Continuous Integration -on: [push] +on: [pull_request] env: BuildParameters.RestoreBuildProjects: '**/*.csproj' BuildParameters.TestProjects: '**/*[Tt]ests/*.csproj' From 87236b9eec9d2f00448e1d963810f0bea1834122 Mon Sep 17 00:00:00 2001 From: kevwhitt-hee Date: Wed, 10 Jan 2024 09:35:32 +0000 Subject: [PATCH 02/22] Update continuous-integration-workflow.yml to run on push --- .github/workflows/continuous-integration-workflow.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/continuous-integration-workflow.yml b/.github/workflows/continuous-integration-workflow.yml index c59f759..c0e0da4 100644 --- a/.github/workflows/continuous-integration-workflow.yml +++ b/.github/workflows/continuous-integration-workflow.yml @@ -1,5 +1,5 @@ name: Continuous Integration -on: [pull_request] +on: [push] env: BuildParameters.RestoreBuildProjects: '**/*.csproj' BuildParameters.TestProjects: '**/*[Tt]ests/*.csproj' From 37005de2086946b1344143ceaeb68f42ca206905 Mon Sep 17 00:00:00 2001 From: binon Date: Mon, 15 Jan 2024 16:46:52 +0000 Subject: [PATCH 03/22] Adding user GUID --- Auth/LearningHub.Nhs.Auth/Program.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Auth/LearningHub.Nhs.Auth/Program.cs b/Auth/LearningHub.Nhs.Auth/Program.cs index b9eef4a..585bfab 100644 --- a/Auth/LearningHub.Nhs.Auth/Program.cs +++ b/Auth/LearningHub.Nhs.Auth/Program.cs @@ -17,7 +17,7 @@ var builder = WebApplication.CreateBuilder(args); -builder.Configuration.AddUserSecrets(string.Empty); +builder.Configuration.AddUserSecrets("a2ecb5d2-cf13-4551-9cb6-3d86dfbcf8ef"); builder.Logging.ClearProviders(); From fc86b7ee31d6d9ef2a9878b9b9ed809f74d1d417 Mon Sep 17 00:00:00 2001 From: binon Date: Tue, 16 Jan 2024 12:08:56 +0000 Subject: [PATCH 04/22] Set up CI with Azure Pipelines [skip ci] --- azure-pipelines-ci.yml | 99 ++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 99 insertions(+) create mode 100644 azure-pipelines-ci.yml diff --git a/azure-pipelines-ci.yml b/azure-pipelines-ci.yml new file mode 100644 index 0000000..8a70bcd --- /dev/null +++ b/azure-pipelines-ci.yml @@ -0,0 +1,99 @@ +# Agent Queue 'Azure Pipelines' was used with unrecognized Agent Specification, vmImage property must be specified to determine image - https://docs.microsoft.com/en-us/azure/devops/pipelines/agents/hosted?view=azure-devops&tabs=yaml#software +variables: +- name: BuildParameters.RestoreBuildProjects + value: '**/*.csproj' +- name: BuildParameters.TestProjects + value: '**/*[Tt]ests/*.csproj' +trigger: + branches: + include: + - refs/heads/ci +name: $(date:yyyyMMdd)$(rev:.r) +resources: + repositories: + - repository: self + type: git + ref: refs/heads/CI +jobs: +- job: Job_1 + displayName: Agent job + pool: + name: Azure Pipelines + steps: + - checkout: self + clean: true + fetchTags: false + - task: NodeTool@0 + displayName: Use Node 12.19 + inputs: + versionSpec: 12.19 + - task: Npm@1 + displayName: npm custom + inputs: + command: custom + workingDir: Auth/LearningHub.Nhs.Auth + verbose: false + customCommand: install -f + - task: Npm@1 + displayName: run webpack build + inputs: + command: custom + workingDir: Auth/LearningHub.Nhs.Auth + verbose: false + customCommand: run build + - task: NuGetToolInstaller@1 + displayName: Use NuGet 5.8 + inputs: + versionSpec: 5.8 + - task: NuGetCommand@2 + displayName: NuGet restore + inputs: + feedRestore: d99eaf2c-ad74-4a35-876e-f7dc1e45a604 + - task: DotNetCoreCLI@2 + displayName: Restore + inputs: + command: restore + projects: $(BuildParameters.RestoreBuildProjects) + - task: DotNetCoreCLI@2 + displayName: Build + inputs: + projects: $(BuildParameters.RestoreBuildProjects) + arguments: --configuration $(BuildConfiguration) /p:Platform=x64 + - task: DotNetCoreCLI@2 + displayName: Test + enabled: False + inputs: + command: test + projects: $(BuildParameters.TestProjects) + arguments: --configuration $(BuildConfiguration) + - task: DotNetCoreCLI@2 + displayName: Publish Auth + inputs: + command: publish + publishWebProjects: false + projects: '**/*LearningHub.Nhs.Auth.csproj' + arguments: --configuration $(BuildConfiguration) --output $(build.artifactstagingdirectory)/Auth + zipAfterPublish: True + - task: PublishBuildArtifacts@1 + displayName: Publish Artifact Auth + condition: succeededOrFailed() + inputs: + PathtoPublish: $(build.artifactstagingdirectory)/Auth + ArtifactName: Auth + TargetPath: '\\my\share\$(Build.DefinitionName)\$(Build.BuildNumber)' + - task: DotNetCoreCLI@2 + displayName: Publish UserAPI + inputs: + command: publish + publishWebProjects: false + projects: '**/*LearningHub.Nhs.UserApi.csproj' + arguments: --configuration $(BuildConfiguration) --output $(build.artifactstagingdirectory)/UserAPI + zipAfterPublish: True + - task: PublishBuildArtifacts@1 + displayName: Publish Artifact UserAPI + condition: succeededOrFailed() + inputs: + PathtoPublish: $(build.artifactstagingdirectory)/UserAPI + ArtifactName: UserAPI + TargetPath: '\\my\share\$(Build.DefinitionName)\$(Build.BuildNumber)' +... From eaea20ed3f3ad0ba40667e9c5e597ae75306996c Mon Sep 17 00:00:00 2001 From: binon Date: Tue, 16 Jan 2024 12:22:20 +0000 Subject: [PATCH 05/22] Update README.md --- README.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 65ca487..0fec919 100644 --- a/README.md +++ b/README.md @@ -148,7 +148,7 @@ Go to: **Tools > NuGet Package Manager > Manage NuGet Packages for Solution > Co Click the **+** button to create a new package source with name `LHPackages` and source: https://pkgs.dev.azure.com/e-LfH/_packaging/LearningHubFeed/nuget/v3/index.json -## Rebuild and run +## Rebuild and run 1. Rebuild the solution 2. Set **LearningHub.Nhs.WebUI** as the startup Project @@ -156,4 +156,4 @@ Click the **+** button to create a new package source with name `LHPackages` and # Contribute -If you are interested in contributing to the Learning Hub, please contact [support@learninghub.nhs.uk](mailto:support@learninghub.nhs.uk) \ No newline at end of file +If you are interested in contributing to the Learning Hub, please contact [support@learninghub.nhs.uk](mailto:support@learninghub.nhs.uk) From 13fc9523340eec1a970c09f8990a1f219503588f Mon Sep 17 00:00:00 2001 From: binon Date: Tue, 16 Jan 2024 13:22:38 +0000 Subject: [PATCH 06/22] Update azure-pipelines-ci.yml for Azure Pipelines --- azure-pipelines-ci.yml | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/azure-pipelines-ci.yml b/azure-pipelines-ci.yml index 8a70bcd..1778f7c 100644 --- a/azure-pipelines-ci.yml +++ b/azure-pipelines-ci.yml @@ -48,7 +48,10 @@ jobs: - task: NuGetCommand@2 displayName: NuGet restore inputs: - feedRestore: d99eaf2c-ad74-4a35-876e-f7dc1e45a604 + command: 'restore' + restoreSolution: '**/*.sln' + feedsToUse: 'select' + vstsFeed: 'd99eaf2c-ad74-4a35-876e-f7dc1e45a604' - task: DotNetCoreCLI@2 displayName: Restore inputs: From 7c906c18af2947a480513343a1c851617ee880db Mon Sep 17 00:00:00 2001 From: binon Date: Tue, 16 Jan 2024 13:36:15 +0000 Subject: [PATCH 07/22] Update azure-pipelines-ci.yml for Azure Pipelines --- azure-pipelines-ci.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/azure-pipelines-ci.yml b/azure-pipelines-ci.yml index 1778f7c..c019981 100644 --- a/azure-pipelines-ci.yml +++ b/azure-pipelines-ci.yml @@ -9,6 +9,8 @@ trigger: include: - refs/heads/ci name: $(date:yyyyMMdd)$(rev:.r) +pool: + vmImage: windows-latest resources: repositories: - repository: self From f661efee177807338ad7e3041830de701d690083 Mon Sep 17 00:00:00 2001 From: binon Date: Tue, 16 Jan 2024 13:49:28 +0000 Subject: [PATCH 08/22] Update azure-pipelines-ci.yml for Azure Pipelines --- azure-pipelines-ci.yml | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/azure-pipelines-ci.yml b/azure-pipelines-ci.yml index c019981..04dc906 100644 --- a/azure-pipelines-ci.yml +++ b/azure-pipelines-ci.yml @@ -9,8 +9,6 @@ trigger: include: - refs/heads/ci name: $(date:yyyyMMdd)$(rev:.r) -pool: - vmImage: windows-latest resources: repositories: - repository: self @@ -20,7 +18,7 @@ jobs: - job: Job_1 displayName: Agent job pool: - name: Azure Pipelines + vmImage: windows-latest steps: - checkout: self clean: true From 8c995e29a2abce67c6727fd688b2565c989c8067 Mon Sep 17 00:00:00 2001 From: binon Date: Tue, 16 Jan 2024 13:55:33 +0000 Subject: [PATCH 09/22] Update azure-pipelines-ci.yml for Azure Pipelines --- azure-pipelines-ci.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/azure-pipelines-ci.yml b/azure-pipelines-ci.yml index 04dc906..a295151 100644 --- a/azure-pipelines-ci.yml +++ b/azure-pipelines-ci.yml @@ -9,6 +9,8 @@ trigger: include: - refs/heads/ci name: $(date:yyyyMMdd)$(rev:.r) +pool: + vmImage: windows-latest resources: repositories: - repository: self @@ -17,8 +19,6 @@ resources: jobs: - job: Job_1 displayName: Agent job - pool: - vmImage: windows-latest steps: - checkout: self clean: true From 69775b2c7aa4ab95d36e47ede85867f617a17049 Mon Sep 17 00:00:00 2001 From: binon Date: Tue, 16 Jan 2024 13:56:50 +0000 Subject: [PATCH 10/22] Update azure-pipelines-ci.yml for Azure Pipelines --- azure-pipelines-ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/azure-pipelines-ci.yml b/azure-pipelines-ci.yml index a295151..9f76a08 100644 --- a/azure-pipelines-ci.yml +++ b/azure-pipelines-ci.yml @@ -18,7 +18,7 @@ resources: ref: refs/heads/CI jobs: - job: Job_1 - displayName: Agent job + displayName: Agent job Binon steps: - checkout: self clean: true From f51d1989c8a62e7d2396edfff2b384f24ec6cc3b Mon Sep 17 00:00:00 2001 From: binon Date: Tue, 16 Jan 2024 14:13:20 +0000 Subject: [PATCH 11/22] Update azure-pipelines-ci.yml for Azure Pipelines --- azure-pipelines-ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/azure-pipelines-ci.yml b/azure-pipelines-ci.yml index 9f76a08..a295151 100644 --- a/azure-pipelines-ci.yml +++ b/azure-pipelines-ci.yml @@ -18,7 +18,7 @@ resources: ref: refs/heads/CI jobs: - job: Job_1 - displayName: Agent job Binon + displayName: Agent job steps: - checkout: self clean: true From 3e0644ad278a18c6988100313beaf73f18d8a16c Mon Sep 17 00:00:00 2001 From: binon Date: Tue, 16 Jan 2024 14:28:29 +0000 Subject: [PATCH 12/22] Update azure-pipelines-ci.yml for Azure Pipelines --- azure-pipelines-ci.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/azure-pipelines-ci.yml b/azure-pipelines-ci.yml index a295151..04dc906 100644 --- a/azure-pipelines-ci.yml +++ b/azure-pipelines-ci.yml @@ -9,8 +9,6 @@ trigger: include: - refs/heads/ci name: $(date:yyyyMMdd)$(rev:.r) -pool: - vmImage: windows-latest resources: repositories: - repository: self @@ -19,6 +17,8 @@ resources: jobs: - job: Job_1 displayName: Agent job + pool: + vmImage: windows-latest steps: - checkout: self clean: true From 05e37a074c62b39af537d5af5e992cf422bf4f5f Mon Sep 17 00:00:00 2001 From: binon Date: Tue, 16 Jan 2024 14:38:50 +0000 Subject: [PATCH 13/22] Delete azure-pipelines-ci.yml --- azure-pipelines-ci.yml | 102 ----------------------------------------- 1 file changed, 102 deletions(-) delete mode 100644 azure-pipelines-ci.yml diff --git a/azure-pipelines-ci.yml b/azure-pipelines-ci.yml deleted file mode 100644 index 04dc906..0000000 --- a/azure-pipelines-ci.yml +++ /dev/null @@ -1,102 +0,0 @@ -# Agent Queue 'Azure Pipelines' was used with unrecognized Agent Specification, vmImage property must be specified to determine image - https://docs.microsoft.com/en-us/azure/devops/pipelines/agents/hosted?view=azure-devops&tabs=yaml#software -variables: -- name: BuildParameters.RestoreBuildProjects - value: '**/*.csproj' -- name: BuildParameters.TestProjects - value: '**/*[Tt]ests/*.csproj' -trigger: - branches: - include: - - refs/heads/ci -name: $(date:yyyyMMdd)$(rev:.r) -resources: - repositories: - - repository: self - type: git - ref: refs/heads/CI -jobs: -- job: Job_1 - displayName: Agent job - pool: - vmImage: windows-latest - steps: - - checkout: self - clean: true - fetchTags: false - - task: NodeTool@0 - displayName: Use Node 12.19 - inputs: - versionSpec: 12.19 - - task: Npm@1 - displayName: npm custom - inputs: - command: custom - workingDir: Auth/LearningHub.Nhs.Auth - verbose: false - customCommand: install -f - - task: Npm@1 - displayName: run webpack build - inputs: - command: custom - workingDir: Auth/LearningHub.Nhs.Auth - verbose: false - customCommand: run build - - task: NuGetToolInstaller@1 - displayName: Use NuGet 5.8 - inputs: - versionSpec: 5.8 - - task: NuGetCommand@2 - displayName: NuGet restore - inputs: - command: 'restore' - restoreSolution: '**/*.sln' - feedsToUse: 'select' - vstsFeed: 'd99eaf2c-ad74-4a35-876e-f7dc1e45a604' - - task: DotNetCoreCLI@2 - displayName: Restore - inputs: - command: restore - projects: $(BuildParameters.RestoreBuildProjects) - - task: DotNetCoreCLI@2 - displayName: Build - inputs: - projects: $(BuildParameters.RestoreBuildProjects) - arguments: --configuration $(BuildConfiguration) /p:Platform=x64 - - task: DotNetCoreCLI@2 - displayName: Test - enabled: False - inputs: - command: test - projects: $(BuildParameters.TestProjects) - arguments: --configuration $(BuildConfiguration) - - task: DotNetCoreCLI@2 - displayName: Publish Auth - inputs: - command: publish - publishWebProjects: false - projects: '**/*LearningHub.Nhs.Auth.csproj' - arguments: --configuration $(BuildConfiguration) --output $(build.artifactstagingdirectory)/Auth - zipAfterPublish: True - - task: PublishBuildArtifacts@1 - displayName: Publish Artifact Auth - condition: succeededOrFailed() - inputs: - PathtoPublish: $(build.artifactstagingdirectory)/Auth - ArtifactName: Auth - TargetPath: '\\my\share\$(Build.DefinitionName)\$(Build.BuildNumber)' - - task: DotNetCoreCLI@2 - displayName: Publish UserAPI - inputs: - command: publish - publishWebProjects: false - projects: '**/*LearningHub.Nhs.UserApi.csproj' - arguments: --configuration $(BuildConfiguration) --output $(build.artifactstagingdirectory)/UserAPI - zipAfterPublish: True - - task: PublishBuildArtifacts@1 - displayName: Publish Artifact UserAPI - condition: succeededOrFailed() - inputs: - PathtoPublish: $(build.artifactstagingdirectory)/UserAPI - ArtifactName: UserAPI - TargetPath: '\\my\share\$(Build.DefinitionName)\$(Build.BuildNumber)' -... From e9476368de0a1744636daa0d993c283257888b0e Mon Sep 17 00:00:00 2001 From: binon Date: Tue, 16 Jan 2024 14:41:38 +0000 Subject: [PATCH 14/22] Set up CI with Azure Pipelines [skip ci] --- azure-pipelines-ci.yml | 102 +++++++++++++++++++++++++++++++++++++++++ 1 file changed, 102 insertions(+) create mode 100644 azure-pipelines-ci.yml diff --git a/azure-pipelines-ci.yml b/azure-pipelines-ci.yml new file mode 100644 index 0000000..04dc906 --- /dev/null +++ b/azure-pipelines-ci.yml @@ -0,0 +1,102 @@ +# Agent Queue 'Azure Pipelines' was used with unrecognized Agent Specification, vmImage property must be specified to determine image - https://docs.microsoft.com/en-us/azure/devops/pipelines/agents/hosted?view=azure-devops&tabs=yaml#software +variables: +- name: BuildParameters.RestoreBuildProjects + value: '**/*.csproj' +- name: BuildParameters.TestProjects + value: '**/*[Tt]ests/*.csproj' +trigger: + branches: + include: + - refs/heads/ci +name: $(date:yyyyMMdd)$(rev:.r) +resources: + repositories: + - repository: self + type: git + ref: refs/heads/CI +jobs: +- job: Job_1 + displayName: Agent job + pool: + vmImage: windows-latest + steps: + - checkout: self + clean: true + fetchTags: false + - task: NodeTool@0 + displayName: Use Node 12.19 + inputs: + versionSpec: 12.19 + - task: Npm@1 + displayName: npm custom + inputs: + command: custom + workingDir: Auth/LearningHub.Nhs.Auth + verbose: false + customCommand: install -f + - task: Npm@1 + displayName: run webpack build + inputs: + command: custom + workingDir: Auth/LearningHub.Nhs.Auth + verbose: false + customCommand: run build + - task: NuGetToolInstaller@1 + displayName: Use NuGet 5.8 + inputs: + versionSpec: 5.8 + - task: NuGetCommand@2 + displayName: NuGet restore + inputs: + command: 'restore' + restoreSolution: '**/*.sln' + feedsToUse: 'select' + vstsFeed: 'd99eaf2c-ad74-4a35-876e-f7dc1e45a604' + - task: DotNetCoreCLI@2 + displayName: Restore + inputs: + command: restore + projects: $(BuildParameters.RestoreBuildProjects) + - task: DotNetCoreCLI@2 + displayName: Build + inputs: + projects: $(BuildParameters.RestoreBuildProjects) + arguments: --configuration $(BuildConfiguration) /p:Platform=x64 + - task: DotNetCoreCLI@2 + displayName: Test + enabled: False + inputs: + command: test + projects: $(BuildParameters.TestProjects) + arguments: --configuration $(BuildConfiguration) + - task: DotNetCoreCLI@2 + displayName: Publish Auth + inputs: + command: publish + publishWebProjects: false + projects: '**/*LearningHub.Nhs.Auth.csproj' + arguments: --configuration $(BuildConfiguration) --output $(build.artifactstagingdirectory)/Auth + zipAfterPublish: True + - task: PublishBuildArtifacts@1 + displayName: Publish Artifact Auth + condition: succeededOrFailed() + inputs: + PathtoPublish: $(build.artifactstagingdirectory)/Auth + ArtifactName: Auth + TargetPath: '\\my\share\$(Build.DefinitionName)\$(Build.BuildNumber)' + - task: DotNetCoreCLI@2 + displayName: Publish UserAPI + inputs: + command: publish + publishWebProjects: false + projects: '**/*LearningHub.Nhs.UserApi.csproj' + arguments: --configuration $(BuildConfiguration) --output $(build.artifactstagingdirectory)/UserAPI + zipAfterPublish: True + - task: PublishBuildArtifacts@1 + displayName: Publish Artifact UserAPI + condition: succeededOrFailed() + inputs: + PathtoPublish: $(build.artifactstagingdirectory)/UserAPI + ArtifactName: UserAPI + TargetPath: '\\my\share\$(Build.DefinitionName)\$(Build.BuildNumber)' +... From eda50499ad0db34028295ebfd2212432d750936c Mon Sep 17 00:00:00 2001 From: binon Date: Tue, 16 Jan 2024 14:51:38 +0000 Subject: [PATCH 15/22] Update azure-pipelines-ci.yml for Azure Pipelines --- azure-pipelines-ci.yml | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/azure-pipelines-ci.yml b/azure-pipelines-ci.yml index 04dc906..889ad3c 100644 --- a/azure-pipelines-ci.yml +++ b/azure-pipelines-ci.yml @@ -7,7 +7,7 @@ variables: trigger: branches: include: - - refs/heads/ci + - refs/heads/CI name: $(date:yyyyMMdd)$(rev:.r) resources: repositories: @@ -18,7 +18,7 @@ jobs: - job: Job_1 displayName: Agent job pool: - vmImage: windows-latest + name: Azure Pipelines steps: - checkout: self clean: true @@ -48,10 +48,7 @@ jobs: - task: NuGetCommand@2 displayName: NuGet restore inputs: - command: 'restore' - restoreSolution: '**/*.sln' - feedsToUse: 'select' - vstsFeed: 'd99eaf2c-ad74-4a35-876e-f7dc1e45a604' + feedRestore: d99eaf2c-ad74-4a35-876e-f7dc1e45a604 - task: DotNetCoreCLI@2 displayName: Restore inputs: From 83c691299751d79d7d4487866d10c887e9d65f6b Mon Sep 17 00:00:00 2001 From: binon Date: Tue, 16 Jan 2024 15:03:04 +0000 Subject: [PATCH 16/22] Update azure-pipelines-ci.yml for Azure Pipelines --- azure-pipelines-ci.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/azure-pipelines-ci.yml b/azure-pipelines-ci.yml index 889ad3c..4d260f2 100644 --- a/azure-pipelines-ci.yml +++ b/azure-pipelines-ci.yml @@ -7,7 +7,7 @@ variables: trigger: branches: include: - - refs/heads/CI + - refs/heads/ci name: $(date:yyyyMMdd)$(rev:.r) resources: repositories: @@ -18,7 +18,7 @@ jobs: - job: Job_1 displayName: Agent job pool: - name: Azure Pipelines + vmImage: windows-latest steps: - checkout: self clean: true From 8c61f4c0a411794be5236480fa6fdf0d39dfdf8c Mon Sep 17 00:00:00 2001 From: binon Date: Tue, 16 Jan 2024 15:09:02 +0000 Subject: [PATCH 17/22] Update azure-pipelines-ci.yml for Azure Pipelines --- azure-pipelines-ci.yml | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/azure-pipelines-ci.yml b/azure-pipelines-ci.yml index 4d260f2..a9e0ac2 100644 --- a/azure-pipelines-ci.yml +++ b/azure-pipelines-ci.yml @@ -5,9 +5,7 @@ variables: - name: BuildParameters.TestProjects value: '**/*[Tt]ests/*.csproj' trigger: - branches: - include: - - refs/heads/ci + - ci name: $(date:yyyyMMdd)$(rev:.r) resources: repositories: From 16985f7dc482d643952dd56365ab3bc2aa21d8f1 Mon Sep 17 00:00:00 2001 From: binon Date: Tue, 16 Jan 2024 23:06:41 +0000 Subject: [PATCH 18/22] Delete azure-pipelines-ci.yml --- azure-pipelines-ci.yml | 97 ------------------------------------------ 1 file changed, 97 deletions(-) delete mode 100644 azure-pipelines-ci.yml diff --git a/azure-pipelines-ci.yml b/azure-pipelines-ci.yml deleted file mode 100644 index a9e0ac2..0000000 --- a/azure-pipelines-ci.yml +++ /dev/null @@ -1,97 +0,0 @@ -# Agent Queue 'Azure Pipelines' was used with unrecognized Agent Specification, vmImage property must be specified to determine image - https://docs.microsoft.com/en-us/azure/devops/pipelines/agents/hosted?view=azure-devops&tabs=yaml#software -variables: -- name: BuildParameters.RestoreBuildProjects - value: '**/*.csproj' -- name: BuildParameters.TestProjects - value: '**/*[Tt]ests/*.csproj' -trigger: - - ci -name: $(date:yyyyMMdd)$(rev:.r) -resources: - repositories: - - repository: self - type: git - ref: refs/heads/CI -jobs: -- job: Job_1 - displayName: Agent job - pool: - vmImage: windows-latest - steps: - - checkout: self - clean: true - fetchTags: false - - task: NodeTool@0 - displayName: Use Node 12.19 - inputs: - versionSpec: 12.19 - - task: Npm@1 - displayName: npm custom - inputs: - command: custom - workingDir: Auth/LearningHub.Nhs.Auth - verbose: false - customCommand: install -f - - task: Npm@1 - displayName: run webpack build - inputs: - command: custom - workingDir: Auth/LearningHub.Nhs.Auth - verbose: false - customCommand: run build - - task: NuGetToolInstaller@1 - displayName: Use NuGet 5.8 - inputs: - versionSpec: 5.8 - - task: NuGetCommand@2 - displayName: NuGet restore - inputs: - feedRestore: d99eaf2c-ad74-4a35-876e-f7dc1e45a604 - - task: DotNetCoreCLI@2 - displayName: Restore - inputs: - command: restore - projects: $(BuildParameters.RestoreBuildProjects) - - task: DotNetCoreCLI@2 - displayName: Build - inputs: - projects: $(BuildParameters.RestoreBuildProjects) - arguments: --configuration $(BuildConfiguration) /p:Platform=x64 - - task: DotNetCoreCLI@2 - displayName: Test - enabled: False - inputs: - command: test - projects: $(BuildParameters.TestProjects) - arguments: --configuration $(BuildConfiguration) - - task: DotNetCoreCLI@2 - displayName: Publish Auth - inputs: - command: publish - publishWebProjects: false - projects: '**/*LearningHub.Nhs.Auth.csproj' - arguments: --configuration $(BuildConfiguration) --output $(build.artifactstagingdirectory)/Auth - zipAfterPublish: True - - task: PublishBuildArtifacts@1 - displayName: Publish Artifact Auth - condition: succeededOrFailed() - inputs: - PathtoPublish: $(build.artifactstagingdirectory)/Auth - ArtifactName: Auth - TargetPath: '\\my\share\$(Build.DefinitionName)\$(Build.BuildNumber)' - - task: DotNetCoreCLI@2 - displayName: Publish UserAPI - inputs: - command: publish - publishWebProjects: false - projects: '**/*LearningHub.Nhs.UserApi.csproj' - arguments: --configuration $(BuildConfiguration) --output $(build.artifactstagingdirectory)/UserAPI - zipAfterPublish: True - - task: PublishBuildArtifacts@1 - displayName: Publish Artifact UserAPI - condition: succeededOrFailed() - inputs: - PathtoPublish: $(build.artifactstagingdirectory)/UserAPI - ArtifactName: UserAPI - TargetPath: '\\my\share\$(Build.DefinitionName)\$(Build.BuildNumber)' -... From 6aa886a7c13fcde63076d8d5421e91663efa1432 Mon Sep 17 00:00:00 2001 From: binon Date: Tue, 16 Jan 2024 23:08:42 +0000 Subject: [PATCH 19/22] Trigger master --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 0fec919..1bd22d5 100644 --- a/README.md +++ b/README.md @@ -1,4 +1,4 @@ -# Introduction +# Introduction This is the official open source repository for the [Learning Hub](https://learninghub.nhs.uk/) user profile and authentication service. This repository is used to provide user authentication for the main [Learning Hub repository](https://github.com/TechnologyEnhancedLearning/LearningHub.Nhs.WebUI). From ae81cdacdb18301aa08a62e42bde7a9de6ac7dd1 Mon Sep 17 00:00:00 2001 From: binon Date: Tue, 16 Jan 2024 23:33:01 +0000 Subject: [PATCH 20/22] Update Program.cs From f652850b732aea9ae9c11f97e087f69175abcc07 Mon Sep 17 00:00:00 2001 From: binon Date: Wed, 17 Jan 2024 14:51:26 +0000 Subject: [PATCH 21/22] Hotfix- auth project --- .../Configuration/WebSettings.cs | 7 +- .../Controllers/AccountController.cs | 2 +- .../Filters/SecurityHeadersAttribute.cs | 2 +- Auth/LearningHub.Nhs.Auth/Styles/sso.scss | 16 - .../Views/Shared/LearningHub/_Layout.cshtml | 4 + .../Shared/LearningHub/_NavPartial.cshtml | 40 +- .../Views/Shared/_Signout_Layout.cshtml | 86 ++-- .../Views/Shared/_SsoLayout.cshtml | 138 +++--- .../Views/Sso/Create.cshtml | 447 +++++++++--------- .../Views/Sso/NotAuthenticated.cshtml | 21 +- Auth/LearningHub.Nhs.Auth/wwwroot/css/sso.css | 2 +- .../wwwroot/css/sso.css.map | 2 +- 12 files changed, 374 insertions(+), 393 deletions(-) diff --git a/Auth/LearningHub.Nhs.Auth/Configuration/WebSettings.cs b/Auth/LearningHub.Nhs.Auth/Configuration/WebSettings.cs index 849253d..0839951 100644 --- a/Auth/LearningHub.Nhs.Auth/Configuration/WebSettings.cs +++ b/Auth/LearningHub.Nhs.Auth/Configuration/WebSettings.cs @@ -55,5 +55,10 @@ public class WebSettings /// Gets or sets the SupportForm. /// public string SupportForm { get; set; } - } + + /// + /// Gets or sets the SupportFeedbackForm. + /// + public string SupportFeedbackForm { get; set; } + } } diff --git a/Auth/LearningHub.Nhs.Auth/Controllers/AccountController.cs b/Auth/LearningHub.Nhs.Auth/Controllers/AccountController.cs index ac3fdc8..46d5cc2 100644 --- a/Auth/LearningHub.Nhs.Auth/Controllers/AccountController.cs +++ b/Auth/LearningHub.Nhs.Auth/Controllers/AccountController.cs @@ -334,6 +334,7 @@ private async Task BuildLoginViewModelAsync(string returnUrl) // Base _layout.cshtml template config this.ViewData["AuthMainTitle"] = loginClientTemplate.AuthMainTitle; + this.ViewData["ClientUrl"] = loginClientTemplate.ClientUrl; this.ViewData["ClientLogoUrl"] = loginClientTemplate.ClientLogoUrl; this.ViewData["ClientLogoSrc"] = loginClientTemplate.ClientLogoSrc; this.ViewData["ClientLogoAltText"] = loginClientTemplate.ClientLogoAltText; @@ -380,7 +381,6 @@ private async Task BuildLoginViewModelAsync(string returnUrl) if (client != null) { allowLocal = client.EnableLocalLogin; - if (client.IdentityProviderRestrictions != null && client.IdentityProviderRestrictions.Any()) { providers = providers.Where(provider => client.IdentityProviderRestrictions.Contains(provider.AuthenticationScheme)).ToList(); diff --git a/Auth/LearningHub.Nhs.Auth/Filters/SecurityHeadersAttribute.cs b/Auth/LearningHub.Nhs.Auth/Filters/SecurityHeadersAttribute.cs index 453a24c..51e693d 100644 --- a/Auth/LearningHub.Nhs.Auth/Filters/SecurityHeadersAttribute.cs +++ b/Auth/LearningHub.Nhs.Auth/Filters/SecurityHeadersAttribute.cs @@ -37,7 +37,7 @@ public override void OnResultExecuting(ResultExecutingContext context) // https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Content-Security-Policy ////var csp = "default-src 'self'; object-src 'none'; frame-ancestors 'none'; sandbox allow-forms allow-same-origin allow-scripts; base-uri 'self';"; - var csp = "object-src 'none'; frame-ancestors 'none'; sandbox allow-forms allow-same-origin allow-scripts; base-uri 'self';"; + var csp = "object-src 'none'; frame-ancestors 'none'; sandbox allow-forms allow-same-origin allow-scripts allow-popups; base-uri 'self';"; //// also consider adding upgrade-insecure-requests once you have HTTPS in place for production ////csp += "upgrade-insecure-requests;"; //// also an example if you need client images to be displayed from twitter diff --git a/Auth/LearningHub.Nhs.Auth/Styles/sso.scss b/Auth/LearningHub.Nhs.Auth/Styles/sso.scss index c1b6e5d..cc8225d 100644 --- a/Auth/LearningHub.Nhs.Auth/Styles/sso.scss +++ b/Auth/LearningHub.Nhs.Auth/Styles/sso.scss @@ -10,22 +10,6 @@ body { background-color: $nhsuk-grey-white; } -header { - background-color: $nhsuk-blue; - height: 112px; - padding: 0 15px; -} - -footer { - background-color: $nhsuk-blue; - height: 130px; - padding: 0 15px; - position: absolute; - left: 0; - bottom: 0; - width: 100%; -} - a { text-decoration: underline; } diff --git a/Auth/LearningHub.Nhs.Auth/Views/Shared/LearningHub/_Layout.cshtml b/Auth/LearningHub.Nhs.Auth/Views/Shared/LearningHub/_Layout.cshtml index 52a6a0e..6c57885 100644 --- a/Auth/LearningHub.Nhs.Auth/Views/Shared/LearningHub/_Layout.cshtml +++ b/Auth/LearningHub.Nhs.Auth/Views/Shared/LearningHub/_Layout.cshtml @@ -38,6 +38,10 @@ +
+ BETA + This is a new platform - your feedback will help us to improve it. +
@RenderBody() diff --git a/Auth/LearningHub.Nhs.Auth/Views/Shared/LearningHub/_NavPartial.cshtml b/Auth/LearningHub.Nhs.Auth/Views/Shared/LearningHub/_NavPartial.cshtml index f118fb9..6a5e554 100644 --- a/Auth/LearningHub.Nhs.Auth/Views/Shared/LearningHub/_NavPartial.cshtml +++ b/Auth/LearningHub.Nhs.Auth/Views/Shared/LearningHub/_NavPartial.cshtml @@ -1,24 +1,24 @@  @functions { - public string PreLoginClass() - { - if (!User.Identity.IsAuthenticated) return "nhsuk-header__pre-login"; - return ""; - } + public string PreLoginClass() + { + if (!User.Identity.IsAuthenticated) return "nhsuk-header__pre-login"; + return ""; + } } \ No newline at end of file diff --git a/Auth/LearningHub.Nhs.Auth/Views/Shared/_Signout_Layout.cshtml b/Auth/LearningHub.Nhs.Auth/Views/Shared/_Signout_Layout.cshtml index cd82c32..89d0f03 100644 --- a/Auth/LearningHub.Nhs.Auth/Views/Shared/_Signout_Layout.cshtml +++ b/Auth/LearningHub.Nhs.Auth/Views/Shared/_Signout_Layout.cshtml @@ -5,53 +5,49 @@ - - - @ViewData["Title"] - Learning Hub Authentication - - - - - - - - - - - - - - + + + @ViewData["Title"] - Learning Hub Authentication + + + + + + + + + + -
-
- @RenderBody() -
-
+
+
+ @RenderBody() +
+
- - - - - - - - - @RenderSection("Scripts", required: false) + + + + + + + + + @RenderSection("Scripts", required: false) diff --git a/Auth/LearningHub.Nhs.Auth/Views/Shared/_SsoLayout.cshtml b/Auth/LearningHub.Nhs.Auth/Views/Shared/_SsoLayout.cshtml index e3e19f3..513a6fd 100644 --- a/Auth/LearningHub.Nhs.Auth/Views/Shared/_SsoLayout.cshtml +++ b/Auth/LearningHub.Nhs.Auth/Views/Shared/_SsoLayout.cshtml @@ -1,89 +1,75 @@ @using IdentityServer4.Extensions +@inject Microsoft.Extensions.Options.IOptions settings @{ - string name = null; - if (!true.Equals(ViewData["signed-out"])) - { - name = Context.User?.GetDisplayName(); - } + string name = null; + if (!true.Equals(ViewData["signed-out"])) + { + name = Context.User?.GetDisplayName(); + } } - - - @ViewData["Title"] - Learning Hub Authentication - - - - - - - - - - - - - - + + + @ViewData["Title"] - Learning Hub Authentication + + + + + + + + + + + + + -
-
-
-
- NHS -
- -
-
-
- -
-
- @RenderBody() -
+ +
+ BETA + This is a new platform - your feedback will help us to improve it. +
+
+
+ @RenderBody() +
+
-
-
-
-
- NHS -
- -
-
-
- - - - - - - - - +
+ +
+ + + + + + + + - - @RenderSection("Scripts", required: false) + + @RenderSection("Scripts", required: false) diff --git a/Auth/LearningHub.Nhs.Auth/Views/Sso/Create.cshtml b/Auth/LearningHub.Nhs.Auth/Views/Sso/Create.cshtml index 4899e12..0c684ad 100644 --- a/Auth/LearningHub.Nhs.Auth/Views/Sso/Create.cshtml +++ b/Auth/LearningHub.Nhs.Auth/Views/Sso/Create.cshtml @@ -1,233 +1,236 @@ @model LearningHub.Nhs.Auth.ViewModels.Sso.CreateUserViewModel @{ - ViewBag.Title = "Registration"; - Layout = "~/Views/Shared/_SsoLayout.cshtml"; + ViewBag.Title = "Registration"; + Layout = "~/Views/Shared/_SsoLayout.cshtml"; } -
-
-
-

Link your Learning Hub account with your organisation

- -

The @Model.ClientName website has requested authorisation to access the Learning Hub.

- -

If you already have an account on the Learning Hub, you can link your existing Learning Hub account with your @Model.ClientName account by entering your username and password below.

- -

When you select ‘Link my account’, the details you have entered will be sent to @Model.ClientName for approval.

- -

If you don’t have an existing Learning Hub account you can create an account.

- -
- - @if (!string.IsNullOrWhiteSpace(Model.Error)) - { -

@Model.Error

- } - -
- -
- @Html.ValidationMessageFor(m => m.SsoLinkUserForm.Username) - -
-
- -
- -
- @Html.ValidationMessageFor(m => m.SsoLinkUserForm.Password) - -
-
- -
- @Html.ValidationMessageFor(m => m.SsoLinkUserForm.Consented) -
-
- @Html.CheckBoxFor(m => m.SsoLinkUserForm.Consented, new { @class = "sso-chk-tnc" }) -
-
- @Html.LabelFor(m => m.SsoLinkUserForm.Consented, @Model.TermsAndConditions) -
-
-
- - -
-
- -
-

Create an account

- -

Enter your details below to create a Learning Hub account and link it to your organisation.

- -

When you select ‘Create linked account’, the details you have entered will be sent to @Model.ClientName for approval.

- -
- - @if (!string.IsNullOrWhiteSpace(Model.Error)) - { -

@Model.Error

- } - -
- -
- @Html.ValidationMessageFor(m => m.SsoRegisterUserForm.FirstName) - -
-
- -
- -
- @Html.ValidationMessageFor(m => m.SsoRegisterUserForm.LastName) - -
-
- -
- -
- @Html.ValidationMessageFor(m => m.SsoRegisterUserForm.EmailAddress) - -
-
- - @if (Model.SsoRegisterUserForm.ShowStaffGroupOption) - { -
- -
- @Html.ValidationMessageFor(m => m.SsoRegisterUserForm.StaffGroupId) - @Html.DropDownListFor(m => m.SsoRegisterUserForm.StaffGroupId, - new SelectList(Model.SsoRegisterUserForm.StaffGroups, "Id", "Name", Model.SsoRegisterUserForm.StaffGroupId), - new { @class = "form-control mt-2" }) -
-
- } - else - { - @Html.HiddenFor(m => m.SsoRegisterUserForm.StaffGroupId) - } - - @if (Model.SsoRegisterUserForm.ShowJobRoleOption) - { -
- -
- @Html.ValidationMessageFor(m => m.SsoRegisterUserForm.JobRoleId) - @Html.DropDownListFor(m => m.SsoRegisterUserForm.JobRoleId, - new SelectList(Model.SsoRegisterUserForm.JobRoles, "Id", "Name", Model.SsoRegisterUserForm.JobRoleId), - new { @class = "form-control mt-2" }) -
-
- } - else - { - @Html.HiddenFor(m => m.SsoRegisterUserForm.JobRoleId) - } - - @if (Model.SsoRegisterUserForm.ShowGradingOption) - { -
- -
- @Html.ValidationMessageFor(m => m.SsoRegisterUserForm.GradeId) - @Html.DropDownListFor(m => m.SsoRegisterUserForm.GradeId, - new SelectList(Model.SsoRegisterUserForm.Grades, "Id", "Name", Model.SsoRegisterUserForm.GradeId), - new { @class = "form-control mt-2" }) -
-
- } - else - { - @Html.HiddenFor(m => m.SsoRegisterUserForm.GradeId) - } - -
- -
- @Html.ValidationMessageFor(m => m.SsoRegisterUserForm.MedicalCouncilNumber) - -
+
+
+
+ +
+

Link your Learning Hub account with your organisation

+ +

The @Model.ClientName website has requested authorisation to access the Learning Hub.

+ +

If you already have an account on the Learning Hub, you can link your existing Learning Hub account with your @Model.ClientName account by entering your username and password below.

+ +

When you select ‘Link my account’, the details you have entered will be sent to @Model.ClientName to link your accounts.

+ +

If you don’t have an existing Learning Hub account you can create an account.

+ + + + @if (!string.IsNullOrWhiteSpace(Model.Error)) + { +

@Model.Error

+ } + +
+ +
+ @Html.ValidationMessageFor(m => m.SsoLinkUserForm.Username) + +
+
+ +
+ +
+ @Html.ValidationMessageFor(m => m.SsoLinkUserForm.Password) + +
+
+ +
+ @Html.ValidationMessageFor(m => m.SsoLinkUserForm.Consented) +
+
+ @Html.CheckBoxFor(m => m.SsoLinkUserForm.Consented, new { @class = "sso-chk-tnc" }) +
+
+ @Html.LabelFor(m => m.SsoLinkUserForm.Consented, @Model.TermsAndConditions) +
+
+
+ + + +
+ +
+

Create an account

+ +

Enter your details below to create a Learning Hub account and link it to your organisation.

+ +

When you select ‘Create linked account’, the details you have entered will be sent to @Model.ClientName for approval.

+ +
+ + @if (!string.IsNullOrWhiteSpace(Model.Error)) + { +

@Model.Error

+ } + +
+ +
+ @Html.ValidationMessageFor(m => m.SsoRegisterUserForm.FirstName) + +
+
+ +
+ +
+ @Html.ValidationMessageFor(m => m.SsoRegisterUserForm.LastName) + +
+
+ +
+ +
+ @Html.ValidationMessageFor(m => m.SsoRegisterUserForm.EmailAddress) + +
+
+ + @if (Model.SsoRegisterUserForm.ShowStaffGroupOption) + { +
+ +
+ @Html.ValidationMessageFor(m => m.SsoRegisterUserForm.StaffGroupId) + @Html.DropDownListFor(m => m.SsoRegisterUserForm.StaffGroupId, + new SelectList(Model.SsoRegisterUserForm.StaffGroups, "Id", "Name", Model.SsoRegisterUserForm.StaffGroupId), + new { @class = "form-control mt-2" }) +
+
+ } + else + { + @Html.HiddenFor(m => m.SsoRegisterUserForm.StaffGroupId) + } + + @if (Model.SsoRegisterUserForm.ShowJobRoleOption) + { +
+ +
+ @Html.ValidationMessageFor(m => m.SsoRegisterUserForm.JobRoleId) + @Html.DropDownListFor(m => m.SsoRegisterUserForm.JobRoleId, + new SelectList(Model.SsoRegisterUserForm.JobRoles, "Id", "Name", Model.SsoRegisterUserForm.JobRoleId), + new { @class = "form-control mt-2" }) +
+
+ } + else + { + @Html.HiddenFor(m => m.SsoRegisterUserForm.JobRoleId) + } + + @if (Model.SsoRegisterUserForm.ShowGradingOption) + { +
+ +
+ @Html.ValidationMessageFor(m => m.SsoRegisterUserForm.GradeId) + @Html.DropDownListFor(m => m.SsoRegisterUserForm.GradeId, + new SelectList(Model.SsoRegisterUserForm.Grades, "Id", "Name", Model.SsoRegisterUserForm.GradeId), + new { @class = "form-control mt-2" }) +
+
+ } + else + { + @Html.HiddenFor(m => m.SsoRegisterUserForm.GradeId) + } + +
+ +
+ @Html.ValidationMessageFor(m => m.SsoRegisterUserForm.MedicalCouncilNumber) + +
+
+ + + @if (Model.SsoRegisterUserForm.ShowSpecialityOption) + { +
+ +
+ @Html.ValidationMessageFor(m => m.SsoRegisterUserForm.SpecialtyId) + @Html.DropDownListFor(m => m.SsoRegisterUserForm.SpecialtyId, + new SelectList(Model.SsoRegisterUserForm.Specialties, "Id", "Name", Model.SsoRegisterUserForm.SpecialtyId), + new { @class = "form-control mt-2" }) +
+
+ + } + else + { + @Html.HiddenFor(m => m.SsoRegisterUserForm.SpecialtyId) + } + + @if (Model.SsoRegisterUserForm.ShowLocation) + { +
+ +
+ @Html.ValidationMessageFor(m => m.SsoRegisterUserForm.LocationId) + + + Results may take a moment to load +
+
+ Information on your place of work will help us provide activity reports to evidence your learning.
+
+
+ } + else + { + @Html.HiddenFor(m => m.SsoRegisterUserForm.LocationId) + } + +
+ @Html.ValidationMessageFor(m => m.SsoRegisterUserForm.Consented) +
+
+ @Html.CheckBoxFor(m => m.SsoRegisterUserForm.Consented, new { @class = "sso-chk-tnc" }) +
+
+ @Html.LabelFor(m => m.SsoRegisterUserForm.Consented, @Model.TermsAndConditions) +
+
+
+ + +
+
- @if (Model.SsoRegisterUserForm.ShowSpecialityOption) - { -
- -
- @Html.ValidationMessageFor(m => m.SsoRegisterUserForm.SpecialtyId) - @Html.DropDownListFor(m => m.SsoRegisterUserForm.SpecialtyId, - new SelectList(Model.SsoRegisterUserForm.Specialties, "Id", "Name", Model.SsoRegisterUserForm.SpecialtyId), - new { @class = "form-control mt-2" }) -
-
- - } - else - { - @Html.HiddenFor(m => m.SsoRegisterUserForm.SpecialtyId) - } - - @if (Model.SsoRegisterUserForm.ShowLocation) - { -
- -
- @Html.ValidationMessageFor(m => m.SsoRegisterUserForm.LocationId) - - - Results may take a moment to load -
-
- Information on your place of work will help us provide activity reports to evidence your learning. -
- -
-
- } - else - { - @Html.HiddenFor(m => m.SsoRegisterUserForm.LocationId) - } - -
- @Html.ValidationMessageFor(m => m.SsoRegisterUserForm.Consented) -
-
- @Html.CheckBoxFor(m => m.SsoRegisterUserForm.Consented, new { @class = "sso-chk-tnc" }) -
-
- @Html.LabelFor(m => m.SsoRegisterUserForm.Consented, @Model.TermsAndConditions) -
-
-
- - - -
+
- @section Scripts -{ - - + { + + } \ No newline at end of file diff --git a/Auth/LearningHub.Nhs.Auth/Views/Sso/NotAuthenticated.cshtml b/Auth/LearningHub.Nhs.Auth/Views/Sso/NotAuthenticated.cshtml index e79dedd..1b60be5 100644 --- a/Auth/LearningHub.Nhs.Auth/Views/Sso/NotAuthenticated.cshtml +++ b/Auth/LearningHub.Nhs.Auth/Views/Sso/NotAuthenticated.cshtml @@ -1,18 +1,21 @@ @model string @{ - ViewBag.Title = "Not Authenticated"; - Layout = "~/Views/Shared/_SsoLayout.cshtml"; + ViewBag.Title = "Not Authenticated"; + Layout = "~/Views/Shared/_SsoLayout.cshtml"; } -
-

Your account cannot be validated

+
+
+
+

Your account cannot be validated

-

The Learning Hub could not validate your account. For help please contact support.

+

The Learning Hub could not validate your account. For help please contact support.

+
+
- \ No newline at end of file diff --git a/Auth/LearningHub.Nhs.Auth/wwwroot/css/sso.css b/Auth/LearningHub.Nhs.Auth/wwwroot/css/sso.css index 8e43f45..e0f249e 100644 --- a/Auth/LearningHub.Nhs.Auth/wwwroot/css/sso.css +++ b/Auth/LearningHub.Nhs.Auth/wwwroot/css/sso.css @@ -1 +1 @@ -html{position:relative;min-height:100%}body{margin:0 0 130px !important;background-color:#f0f4f5}header{background-color:#005eb8;height:112px;padding:0 15px}footer{background-color:#005eb8;height:130px;padding:0 15px;position:absolute;left:0;bottom:0;width:100%}a{text-decoration:underline}.container-fluid{background-color:#fff}.lh-container{max-width:1144px;margin:0 auto}.sso-frame{max-width:756px}.header-title-sso{cursor:pointer;font-family:FrutigerLTW01-65Bold,Arial,sans-serif;font-size:2.7rem;margin-top:5px;margin-bottom:0;clear:both;min-width:215px}.header-beta{color:#c8e4ff;font-family:FrutigerLTW01-55Roman,Arial,sans-serif;font-size:1.7rem;margin-left:2px;text-transform:uppercase}.form-group{max-width:500px}.form-control{margin-top:6px}.sso-btn{color:#fff;border:1px solid rgba(0,0,0,0);padding:10px 20px;background:#007f3b;border-radius:6px}.terms-conditions{background-color:#f0f4f5;font-size:16px}@media(max-width: 768px){.terms-conditions{font-size:14px}}.terms-conditions input{width:30px}.sso-chk-tnc{width:30px}.input-validation-error{border:4px solid #da291c !important}.grade-form-group{border-left:5px solid #c4c4c4;padding-left:14px}.form-group--error{border-left:8px solid #d5281b;padding-left:14px}input,select{height:45px !important;border:2px solid #425563 !important;border-radius:4px !important}.twitter-typeahead{width:100%}.twitter-typeahead .tt-menu{background-color:#fff;border:1px solid #000}.twitter-typeahead .tt-suggestion{padding:6px 8px;font-size:14px;margin:0}.twitter-typeahead .tt-suggestion:hover{cursor:pointer;background-color:#e8f0fe}.locationInfoSection{padding-left:23px;position:relative;margin-top:5px}#whyLocationInfo:before{content:url(/images/triangle-down.svg);position:absolute;top:5px;left:2px}#whyLocationInfo.collapsed:before{content:url(/images/triangle-right.svg)}/*# sourceMappingURL=sso.css.map */ +html{position:relative;min-height:100%}body{margin:0 0 130px !important;background-color:#f0f4f5}a{text-decoration:underline}.container-fluid{background-color:#fff}.lh-container{max-width:1144px;margin:0 auto}.sso-frame{max-width:756px}.header-title-sso{cursor:pointer;font-family:FrutigerLTW01-65Bold,Arial,sans-serif;font-size:2.7rem;margin-top:5px;margin-bottom:0;clear:both;min-width:215px}.header-beta{color:#c8e4ff;font-family:FrutigerLTW01-55Roman,Arial,sans-serif;font-size:1.7rem;margin-left:2px;text-transform:uppercase}.form-group{max-width:500px}.form-control{margin-top:6px}.sso-btn{color:#fff;border:1px solid rgba(0,0,0,0);padding:10px 20px;background:#007f3b;border-radius:6px}.terms-conditions{background-color:#f0f4f5;font-size:16px}@media(max-width: 768px){.terms-conditions{font-size:14px}}.terms-conditions input{width:30px}.sso-chk-tnc{width:30px}.input-validation-error{border:4px solid #da291c !important}.grade-form-group{border-left:5px solid #c4c4c4;padding-left:14px}.form-group--error{border-left:8px solid #d5281b;padding-left:14px}input,select{height:45px !important;border:2px solid #425563 !important;border-radius:4px !important}.twitter-typeahead{width:100%}.twitter-typeahead .tt-menu{background-color:#fff;border:1px solid #000}.twitter-typeahead .tt-suggestion{padding:6px 8px;font-size:14px;margin:0}.twitter-typeahead .tt-suggestion:hover{cursor:pointer;background-color:#e8f0fe}.locationInfoSection{padding-left:23px;position:relative;margin-top:5px}#whyLocationInfo:before{content:url(/images/triangle-down.svg);position:absolute;top:5px;left:2px}#whyLocationInfo.collapsed:before{content:url(/images/triangle-right.svg)}/*# sourceMappingURL=sso.css.map */ diff --git a/Auth/LearningHub.Nhs.Auth/wwwroot/css/sso.css.map b/Auth/LearningHub.Nhs.Auth/wwwroot/css/sso.css.map index 2fc948d..f6a4af3 100644 --- a/Auth/LearningHub.Nhs.Auth/wwwroot/css/sso.css.map +++ b/Auth/LearningHub.Nhs.Auth/wwwroot/css/sso.css.map @@ -1 +1 @@ -{"version":3,"sourceRoot":"","sources":["../../Styles/sso.scss","../../Styles/_variables.scss"],"names":[],"mappings":"AAEA,KACI,kBACA,gBAGJ,KACI,4BACA,iBCKe,QDFnB,OACI,iBCbU,QDcV,aACA,eAGJ,OACI,iBCnBU,QDoBV,aACA,eACA,kBACA,OACA,SACA,WAGJ,EACI,0BAGJ,iBACI,sBAGJ,cACI,iBACA,cAGJ,WACI,gBAGJ,kBACI,eACA,kDACA,iBACA,eACA,gBACA,WACA,gBAGJ,aACI,cACA,mDACA,iBACA,gBACA,yBAGJ,YACI,gBAGJ,cACI,eAGJ,SACI,WACA,+BACA,kBACA,WCzEU,QD0EV,kBAGJ,kBACI,iBClEe,QDmEf,eAEA,yBAJJ,kBAKQ,gBAIR,wBACI,WAGJ,aACI,WAGJ,wBACI,oCAGJ,kBACI,8BACA,kBAGJ,mBACI,8BACA,kBAGJ,aACI,uBACA,oCACA,6BAGJ,mBACI,WAEA,4BACI,sBACA,sBAGJ,kCACI,gBACA,eACA,SAEA,wCACI,eACA,yBAKZ,qBACI,kBACA,kBACA,eAIA,wBACI,uCACA,kBACA,QACA,SAKJ,kCACI","file":"sso.css"} \ No newline at end of file +{"version":3,"sourceRoot":"","sources":["../../Styles/sso.scss","../../Styles/_variables.scss"],"names":[],"mappings":"AAEA,KACI,kBACA,gBAGJ,KACI,4BACA,iBCKe,QDFnB,EACI,0BAGJ,iBACI,sBAGJ,cACI,iBACA,cAGJ,WACI,gBAGJ,kBACI,eACA,kDACA,iBACA,eACA,gBACA,WACA,gBAGJ,aACI,cACA,mDACA,iBACA,gBACA,yBAGJ,YACI,gBAGJ,cACI,eAGJ,SACI,WACA,+BACA,kBACA,WCzDU,QD0DV,kBAGJ,kBACI,iBClDe,QDmDf,eAEA,yBAJJ,kBAKQ,gBAIR,wBACI,WAGJ,aACI,WAGJ,wBACI,oCAGJ,kBACI,8BACA,kBAGJ,mBACI,8BACA,kBAGJ,aACI,uBACA,oCACA,6BAGJ,mBACI,WAEA,4BACI,sBACA,sBAGJ,kCACI,gBACA,eACA,SAEA,wCACI,eACA,yBAKZ,qBACI,kBACA,kBACA,eAIA,wBACI,uCACA,kBACA,QACA,SAKJ,kCACI","file":"sso.css"} \ No newline at end of file From c9f6f09f7edeb5d1cb1eca6f6eff1b0a508a7f5d Mon Sep 17 00:00:00 2001 From: binon Date: Wed, 17 Jan 2024 15:55:32 +0000 Subject: [PATCH 22/22] adding app settings --- Auth/LearningHub.Nhs.Auth/appsettings.json | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/Auth/LearningHub.Nhs.Auth/appsettings.json b/Auth/LearningHub.Nhs.Auth/appsettings.json index fb85fb9..fbd9f12 100644 --- a/Auth/LearningHub.Nhs.Auth/appsettings.json +++ b/Auth/LearningHub.Nhs.Auth/appsettings.json @@ -38,7 +38,10 @@ "AuthClientIdentityKey": "", "ElfhHub": "", "Rcr": "", - "SupportForm": "https://support.learninghub.nhs.uk/support/tickets/new" + "SupportForm": "https://support.learninghub.nhs.uk/support/tickets/new", + "SupportFeedbackForm": "https://forms.office.com/e/C8tteweEhG" + + }, "AllowOpenAthensDebug": false, "OaLhClients": {