diff --git a/CSETWebApi/CSETWeb_Api/CSETWebCore.Business/Maturity/CmmcBusiness.cs b/CSETWebApi/CSETWeb_Api/CSETWebCore.Business/Maturity/CmmcBusiness.cs index 53233ef7de..9beed8339c 100644 --- a/CSETWebApi/CSETWeb_Api/CSETWebCore.Business/Maturity/CmmcBusiness.cs +++ b/CSETWebApi/CSETWeb_Api/CSETWebCore.Business/Maturity/CmmcBusiness.cs @@ -1,4 +1,4 @@ -//////////////////////////////// +//////////////////////////////// // // Copyright 2024 Battelle Energy Alliance, LLC // @@ -88,7 +88,7 @@ public CmmcScores GetCmmcScores(int assessmentId) // Level 3 response.Level3Score = GetScoreForLevel(assessmentId, 3); response.Level3MaxScore = _level3Max; - response.Level3Active = (response.Level2Score == _level2Max); + response.Level3Active = response.Level2Active && (response.Level2Score == _level2Max); return response; @@ -208,7 +208,7 @@ private CmmcScoreModel FilterByLevel(XDocument x, int level) /// - /// Calculates a SPRS score based on the question scoring values in MATURITY_EXTRA. + /// Calculates a SPRS score based on the level 2 question scoring values in MATURITY_EXTRA. /// public CmmcScoreModel GetSPRSScore(int assessmentId) { @@ -227,7 +227,7 @@ public CmmcScoreModel GetSPRSScore(int assessmentId) d.DomainName = goal.Attribute("title").Value; response.Domains.Add(d); - foreach (var question in goal.Descendants("Question")) + foreach (var question in goal.Descendants("Question").Where(x => x.Attribute("level").Value == "2")) { var q = new CmmcQuestion(); q.QuestionId = int.Parse(question.Attribute("questionid").Value); diff --git a/CSETWebApi/CSETWeb_Api/CSETWebCore.Business/Maturity/MaturityBusiness.cs b/CSETWebApi/CSETWeb_Api/CSETWebCore.Business/Maturity/MaturityBusiness.cs index c9a82f1481..4a9749bff5 100644 --- a/CSETWebApi/CSETWeb_Api/CSETWebCore.Business/Maturity/MaturityBusiness.cs +++ b/CSETWebApi/CSETWeb_Api/CSETWebCore.Business/Maturity/MaturityBusiness.cs @@ -825,6 +825,7 @@ public MaturityResponse GetMaturityQuestions(int assessmentId, bool fill, int gr var questionQuery = _context.MATURITY_QUESTIONS .Include(x => x.Maturity_Level) .Include(x => x.MATURITY_QUESTION_PROPS) + .Include(x => x.MATURITY_EXTRA) .Where(q => targetModelId == q.Maturity_Model_Id); diff --git a/CSETWebApi/CSETWeb_Api/CSETWebCore.DataLayer/Model/ANALYTICS_MATURITY_GROUPINGS.cs b/CSETWebApi/CSETWeb_Api/CSETWebCore.DataLayer/Model/ANALYTICS_MATURITY_GROUPINGS.cs index b04422ff2a..15348184d6 100644 --- a/CSETWebApi/CSETWeb_Api/CSETWebCore.DataLayer/Model/ANALYTICS_MATURITY_GROUPINGS.cs +++ b/CSETWebApi/CSETWeb_Api/CSETWebCore.DataLayer/Model/ANALYTICS_MATURITY_GROUPINGS.cs @@ -21,6 +21,12 @@ public partial class ANALYTICS_MATURITY_GROUPINGS [StringLength(200)] public string Question_Group { get; set; } + public int? Group_Sequence { get; set; } + + public int? Global_Sequence { get; set; } + + public int? Group_id { get; set; } + [ForeignKey("Maturity_Model_Id")] [InverseProperty("ANALYTICS_MATURITY_GROUPINGS")] public virtual MATURITY_MODELS Maturity_Model { get; set; } diff --git a/CSETWebApi/CSETWeb_Api/CSETWebCore.DataLayer/Model/Analytics_Answers.cs b/CSETWebApi/CSETWeb_Api/CSETWebCore.DataLayer/Model/Analytics_Answers.cs index 7c4c82491e..19d256f87a 100644 --- a/CSETWebApi/CSETWeb_Api/CSETWebCore.DataLayer/Model/Analytics_Answers.cs +++ b/CSETWebApi/CSETWeb_Api/CSETWebCore.DataLayer/Model/Analytics_Answers.cs @@ -19,6 +19,7 @@ public partial class Analytics_Answers [StringLength(20)] public string Question_Type { get; set; } + [Required] [StringLength(1)] public string Answer_Text { get; set; } } \ No newline at end of file diff --git a/CSETWebApi/CSETWeb_Api/CSETWebCore.DataLayer/Model/Answer_Components_Default.cs b/CSETWebApi/CSETWeb_Api/CSETWebCore.DataLayer/Model/Answer_Components_Default.cs index a01412e7e7..baae5e7c5d 100644 --- a/CSETWebApi/CSETWeb_Api/CSETWebCore.DataLayer/Model/Answer_Components_Default.cs +++ b/CSETWebApi/CSETWeb_Api/CSETWebCore.DataLayer/Model/Answer_Components_Default.cs @@ -40,7 +40,7 @@ public partial class Answer_Components_Default public int GroupHeadingId { get; set; } [Required] - [StringLength(150)] + [StringLength(100)] public string Universal_Sub_Category { get; set; } public int SubCategoryId { get; set; } diff --git a/CSETWebApi/CSETWeb_Api/CSETWebCore.DataLayer/Model/Answer_Components_Exploded.cs b/CSETWebApi/CSETWeb_Api/CSETWebCore.DataLayer/Model/Answer_Components_Exploded.cs index 00c9083314..ed5bff4079 100644 --- a/CSETWebApi/CSETWeb_Api/CSETWebCore.DataLayer/Model/Answer_Components_Exploded.cs +++ b/CSETWebApi/CSETWeb_Api/CSETWebCore.DataLayer/Model/Answer_Components_Exploded.cs @@ -48,7 +48,7 @@ public partial class Answer_Components_Exploded public int? GroupHeadingId { get; set; } - [StringLength(150)] + [StringLength(100)] public string Universal_Sub_Category { get; set; } public int? SubCategoryId { get; set; } diff --git a/CSETWebApi/CSETWeb_Api/CSETWebCore.DataLayer/Model/Answer_Components_Overrides.cs b/CSETWebApi/CSETWeb_Api/CSETWebCore.DataLayer/Model/Answer_Components_Overrides.cs index 8961c95bb0..a9c960e810 100644 --- a/CSETWebApi/CSETWeb_Api/CSETWebCore.DataLayer/Model/Answer_Components_Overrides.cs +++ b/CSETWebApi/CSETWeb_Api/CSETWebCore.DataLayer/Model/Answer_Components_Overrides.cs @@ -45,7 +45,7 @@ public partial class Answer_Components_Overrides public int? GroupHeadingId { get; set; } - [StringLength(150)] + [StringLength(100)] public string Universal_Sub_Category { get; set; } public int? SubCategoryId { get; set; } diff --git a/CSETWebApi/CSETWeb_Api/CSETWebCore.DataLayer/Model/CsetwebContext.cs b/CSETWebApi/CSETWeb_Api/CSETWebCore.DataLayer/Model/CsetwebContext.cs index 1fee6a7a79..1d24391705 100644 --- a/CSETWebApi/CSETWeb_Api/CSETWebCore.DataLayer/Model/CsetwebContext.cs +++ b/CSETWebApi/CSETWeb_Api/CSETWebCore.DataLayer/Model/CsetwebContext.cs @@ -569,10 +569,10 @@ protected override void OnModelCreating(ModelBuilder modelBuilder) .HasComment("The Answer Text is used to"); entity.Property(e => e.Comment).HasComment("The Comment is used to"); entity.Property(e => e.Component_Guid).HasComment("The Component Guid is used to"); - entity.Property(e => e.Is_Component).HasComputedColumnSql("(CONVERT([bit],case [Question_Type] when 'Component' then (1) else (0) end,(0)))", false); - entity.Property(e => e.Is_Framework).HasComputedColumnSql("(CONVERT([bit],case [Question_Type] when 'Framework' then (1) else (0) end,(0)))", false); - entity.Property(e => e.Is_Maturity).HasComputedColumnSql("(CONVERT([bit],case [Question_Type] when 'Maturity' then (1) else (0) end,(0)))", false); - entity.Property(e => e.Is_Requirement).HasComputedColumnSql("(CONVERT([bit],case [Question_Type] when 'Requirement' then (1) else (0) end,(0)))", false); + entity.Property(e => e.Is_Component).HasComputedColumnSql("(CONVERT([bit],case [Question_Type] when 'Component' then (1) else (0) end))", false); + entity.Property(e => e.Is_Framework).HasComputedColumnSql("(CONVERT([bit],case [Question_Type] when 'Framework' then (1) else (0) end))", false); + entity.Property(e => e.Is_Maturity).HasComputedColumnSql("(CONVERT([bit],case [Question_Type] when 'Maturity' then (1) else (0) end))", false); + entity.Property(e => e.Is_Requirement).HasComputedColumnSql("(CONVERT([bit],case [Question_Type] when 'Requirement' then (1) else (0) end))", false); entity.Property(e => e.Mark_For_Review).HasComment("The Mark For Review is used to"); entity.Property(e => e.Question_Number).HasComment("The Question Number is used to"); entity.Property(e => e.Question_Or_Requirement_Id).HasComment("The Question Or Requirement Id is used to"); @@ -1800,6 +1800,10 @@ protected override void OnModelCreating(ModelBuilder modelBuilder) modelBuilder.Entity(entity => { entity.Property(e => e.Maturity_Question_Id).ValueGeneratedNever(); + + entity.HasOne(d => d.Maturity_Question).WithOne(p => p.MATURITY_EXTRA) + .OnDelete(DeleteBehavior.ClientSetNull) + .HasConstraintName("fk_mat_questions"); }); modelBuilder.Entity(entity => diff --git a/CSETWebApi/CSETWeb_Api/CSETWebCore.DataLayer/Model/CsetwebContextProcedures.cs b/CSETWebApi/CSETWeb_Api/CSETWebCore.DataLayer/Model/CsetwebContextProcedures.cs index ce88038136..40ad6416b3 100644 --- a/CSETWebApi/CSETWeb_Api/CSETWebCore.DataLayer/Model/CsetwebContextProcedures.cs +++ b/CSETWebApi/CSETWeb_Api/CSETWebCore.DataLayer/Model/CsetwebContextProcedures.cs @@ -1,4 +1,4 @@ -// This file has been auto generated by EF Core Power Tools. +// This file has been auto generated by EF Core Power Tools. #nullable disable using CSETWebCore.DataLayer.Model; using Microsoft.Data.SqlClient; @@ -1915,6 +1915,31 @@ public virtual async Task> usp_financial_at return _; } + public virtual async Task> usp_GenerateSPRSScoreAsync(int? assessment_id, OutputParameter returnValue = null, CancellationToken cancellationToken = default) + { + var parameterreturnValue = new SqlParameter + { + ParameterName = "returnValue", + Direction = System.Data.ParameterDirection.Output, + SqlDbType = System.Data.SqlDbType.Int, + }; + + var sqlParameters = new [] + { + new SqlParameter + { + ParameterName = "assessment_id", + Value = assessment_id ?? Convert.DBNull, + SqlDbType = System.Data.SqlDbType.Int, + }, + parameterreturnValue, + }; + var _ = await _context.SqlQueryAsync("EXEC @returnValue = [dbo].[usp_GenerateSPRSScore] @assessment_id = @assessment_id", sqlParameters, cancellationToken); + + returnValue?.SetValue(parameterreturnValue.Value); + + return _; + } public virtual async Task> usp_getAnswerComponentOverridesAsync(int? assessment_id, OutputParameter returnValue = null, CancellationToken cancellationToken = default) { diff --git a/CSETWebApi/CSETWeb_Api/CSETWebCore.DataLayer/Model/ICsetwebContextProcedures.cs b/CSETWebApi/CSETWeb_Api/CSETWebCore.DataLayer/Model/ICsetwebContextProcedures.cs index 33c97711e0..379df300e8 100644 --- a/CSETWebApi/CSETWeb_Api/CSETWebCore.DataLayer/Model/ICsetwebContextProcedures.cs +++ b/CSETWebApi/CSETWeb_Api/CSETWebCore.DataLayer/Model/ICsetwebContextProcedures.cs @@ -73,6 +73,7 @@ public partial interface ICsetwebContextProcedures Task usp_CopyIntoSet_DeleteAsync(string DestinationSetName, OutputParameter returnValue = null, CancellationToken cancellationToken = default); Task> usp_countsForLevelsByGroupMaturityModelAsync(int? assessment_id, int? mat_model_id, OutputParameter returnValue = null, CancellationToken cancellationToken = default); Task> usp_financial_attributesAsync(int? Assessment_Id, OutputParameter returnValue = null, CancellationToken cancellationToken = default); + Task> usp_GenerateSPRSScoreAsync(int? assessment_id, OutputParameter returnValue = null, CancellationToken cancellationToken = default); Task> usp_getAnswerComponentOverridesAsync(int? assessment_id, OutputParameter returnValue = null, CancellationToken cancellationToken = default); Task> usp_GetAssessmentPieAsync(int? Assessment_Id, OutputParameter returnValue = null, CancellationToken cancellationToken = default); Task> usp_getComponentsRankedCategoriesAsync(int? assessment_id, OutputParameter returnValue = null, CancellationToken cancellationToken = default); diff --git a/CSETWebApi/CSETWeb_Api/CSETWebCore.DataLayer/Model/MATURITY_EXTRA.cs b/CSETWebApi/CSETWeb_Api/CSETWebCore.DataLayer/Model/MATURITY_EXTRA.cs index 5013c0ffcd..36b356612a 100644 --- a/CSETWebApi/CSETWeb_Api/CSETWebCore.DataLayer/Model/MATURITY_EXTRA.cs +++ b/CSETWebApi/CSETWeb_Api/CSETWebCore.DataLayer/Model/MATURITY_EXTRA.cs @@ -30,4 +30,11 @@ public partial class MATURITY_EXTRA [StringLength(100)] public string CMMC2_Title { get; set; } + + [StringLength(50)] + public string Answer_Options { get; set; } + + [ForeignKey("Maturity_Question_Id")] + [InverseProperty("MATURITY_EXTRA")] + public virtual MATURITY_QUESTIONS Maturity_Question { get; set; } } \ No newline at end of file diff --git a/CSETWebApi/CSETWeb_Api/CSETWebCore.DataLayer/Model/MATURITY_QUESTIONS.cs b/CSETWebApi/CSETWeb_Api/CSETWebCore.DataLayer/Model/MATURITY_QUESTIONS.cs index f2a886d5a8..6711878cd1 100644 --- a/CSETWebApi/CSETWeb_Api/CSETWebCore.DataLayer/Model/MATURITY_QUESTIONS.cs +++ b/CSETWebApi/CSETWeb_Api/CSETWebCore.DataLayer/Model/MATURITY_QUESTIONS.cs @@ -89,6 +89,9 @@ public partial class MATURITY_QUESTIONS [InverseProperty("Mat_Question")] public virtual ICollection MATURITY_ANSWER_OPTIONS { get; set; } = new List(); + [InverseProperty("Maturity_Question")] + public virtual MATURITY_EXTRA MATURITY_EXTRA { get; set; } + [InverseProperty("Mat_Question")] public virtual ICollection MATURITY_QUESTION_PROPS { get; set; } = new List(); diff --git a/CSETWebApi/CSETWeb_Api/CSETWebCore.DataLayer/Model/Nlogs.cs b/CSETWebApi/CSETWeb_Api/CSETWebCore.DataLayer/Model/Nlogs.cs index 7c015298dd..1b9eef3d9a 100644 --- a/CSETWebApi/CSETWeb_Api/CSETWebCore.DataLayer/Model/Nlogs.cs +++ b/CSETWebApi/CSETWeb_Api/CSETWebCore.DataLayer/Model/Nlogs.cs @@ -25,4 +25,7 @@ public partial class Nlogs [StringLength(4000)] public string Message { get; set; } + + [StringLength(100)] + public string User { get; set; } } \ No newline at end of file diff --git a/CSETWebApi/CSETWeb_Api/CSETWebCore.DataLayer/Model/usp_GenerateSPRSScoreResult.cs b/CSETWebApi/CSETWeb_Api/CSETWebCore.DataLayer/Model/usp_GenerateSPRSScoreResult.cs new file mode 100644 index 0000000000..e35ed4fb3c --- /dev/null +++ b/CSETWebApi/CSETWeb_Api/CSETWebCore.DataLayer/Model/usp_GenerateSPRSScoreResult.cs @@ -0,0 +1,12 @@ +// This file has been auto generated by EF Core Power Tools. +using System; +using System.Collections.Generic; +using System.ComponentModel.DataAnnotations.Schema; + +namespace CSETWebCore.DataLayer.Model +{ + public partial class usp_GenerateSPRSScoreResult + { + public int? SPRS_SCORE { get; set; } + } +} diff --git a/CSETWebApi/CSETWeb_Api/CSETWebCore.DataLayer/Model/usp_GetQuestionsResult.cs b/CSETWebApi/CSETWeb_Api/CSETWebCore.DataLayer/Model/usp_GetQuestionsResult.cs new file mode 100644 index 0000000000..4597eefeb4 --- /dev/null +++ b/CSETWebApi/CSETWeb_Api/CSETWebCore.DataLayer/Model/usp_GetQuestionsResult.cs @@ -0,0 +1,11 @@ +// This file has been auto generated by EF Core Power Tools. +using System; +using System.Collections.Generic; +using System.ComponentModel.DataAnnotations.Schema; + +namespace CSETWebCore.DataLayer.Model +{ + public partial class usp_GetQuestionsResult + { + } +} diff --git a/CSETWebApi/CSETWeb_Api/CSETWebCore.DataLayer/Model/vQUESTION_HEADINGS.cs b/CSETWebApi/CSETWeb_Api/CSETWebCore.DataLayer/Model/vQUESTION_HEADINGS.cs index 280fff258b..b9b0784aaa 100644 --- a/CSETWebApi/CSETWeb_Api/CSETWebCore.DataLayer/Model/vQUESTION_HEADINGS.cs +++ b/CSETWebApi/CSETWeb_Api/CSETWebCore.DataLayer/Model/vQUESTION_HEADINGS.cs @@ -20,7 +20,7 @@ public partial class vQUESTION_HEADINGS public int Question_Group_Heading_Id { get; set; } [Required] - [StringLength(150)] + [StringLength(100)] public string Universal_Sub_Category { get; set; } [StringLength(1000)] diff --git a/CSETWebApi/CSETWeb_Api/CSETWebCore.Helpers/QuestionAnswerBuilder.cs b/CSETWebApi/CSETWeb_Api/CSETWebCore.Helpers/QuestionAnswerBuilder.cs index 38aff30e2c..c2ac3f3ec6 100644 --- a/CSETWebApi/CSETWeb_Api/CSETWebCore.Helpers/QuestionAnswerBuilder.cs +++ b/CSETWebApi/CSETWeb_Api/CSETWebCore.Helpers/QuestionAnswerBuilder.cs @@ -1,10 +1,6 @@ using CSETWebCore.DataLayer.Model; using CSETWebCore.Model.Question; -using System; -using System.Collections.Generic; using System.Linq; -using System.Text; -using System.Threading.Tasks; namespace CSETWebCore.Helpers { @@ -49,6 +45,11 @@ public static QuestionAnswer BuildQuestionAnswer(MATURITY_QUESTIONS myQ, FullAns SetName = string.Empty }; + if (myQ.MATURITY_EXTRA?.Answer_Options != null) + { + qa.AnswerOptions = myQ.MATURITY_EXTRA?.Answer_Options.Split(',').ToList(); + } + return qa; } diff --git a/CSETWebApi/CSETWeb_Api/CSETWebCore.Model/Question/QuestionAnswer.cs b/CSETWebApi/CSETWeb_Api/CSETWebCore.Model/Question/QuestionAnswer.cs index 63cc680426..741877a897 100644 --- a/CSETWebApi/CSETWeb_Api/CSETWebCore.Model/Question/QuestionAnswer.cs +++ b/CSETWebApi/CSETWeb_Api/CSETWebCore.Model/Question/QuestionAnswer.cs @@ -35,6 +35,13 @@ public class QuestionAnswer public List ParmSubs { get; set; } public string StdRefId { get; set; } public string Answer { get; set; } + + /// + /// If a question's potential answer set deviates from the one + /// defined at the MaturityModel level. + /// + public List AnswerOptions { get; set; } + public string AltAnswerText { get; set; } public string FreeResponseAnswer { get; set; } public string Comment { get; set; } diff --git a/CSETWebApi/CSETWeb_Api/CSETWeb_ApiCore/Controllers/MaturityController.cs b/CSETWebApi/CSETWeb_Api/CSETWeb_ApiCore/Controllers/MaturityController.cs index ef3d7a14e0..6ff5240325 100644 --- a/CSETWebApi/CSETWeb_Api/CSETWeb_ApiCore/Controllers/MaturityController.cs +++ b/CSETWebApi/CSETWeb_Api/CSETWeb_ApiCore/Controllers/MaturityController.cs @@ -171,6 +171,11 @@ public IActionResult GetTargetLevel() } + /// + /// TODO: Cannot find this endpoint name in the UI codebase + /// + /// + /// [HttpGet] [Route("api/MaturityModel/GetLevelScoresByGroup")] public IActionResult GetLevelScoresByGroup(int mat_model_id) diff --git a/CSETWebNg/src/app/assessment/questions/maturity-questions/maturity-questions-acet.component.ts b/CSETWebNg/src/app/assessment/questions/maturity-questions/maturity-questions-acet.component.ts index 47ee54bf6a..ec6321786d 100644 --- a/CSETWebNg/src/app/assessment/questions/maturity-questions/maturity-questions-acet.component.ts +++ b/CSETWebNg/src/app/assessment/questions/maturity-questions/maturity-questions-acet.component.ts @@ -121,7 +121,7 @@ export class MaturityQuestionsAcetComponent implements OnInit, AfterViewInit { this.groupings = response.groupings; this.assessSvc.assessment.maturityModel.maturityTargetLevel = response.maturityTargetLevel; this.assessSvc.assessment.maturityModel.answerOptions = response.answerOptions; - this.filterSvc.answerOptions = response.answerOptions; + this.filterSvc.answerOptions = response.answerOptions.slice(); this.filterSvc.maturityModelId = response.modelId; this.filterSvc.maturityModelName = response.modelName; diff --git a/CSETWebNg/src/app/assessment/questions/maturity-questions/maturity-questions-cie/maturity-questions-cie.component.ts b/CSETWebNg/src/app/assessment/questions/maturity-questions/maturity-questions-cie/maturity-questions-cie.component.ts index c542ecf832..d52c71f7fa 100644 --- a/CSETWebNg/src/app/assessment/questions/maturity-questions/maturity-questions-cie/maturity-questions-cie.component.ts +++ b/CSETWebNg/src/app/assessment/questions/maturity-questions/maturity-questions-cie/maturity-questions-cie.component.ts @@ -182,7 +182,7 @@ export class MaturityQuestionsCieComponent implements OnInit, AfterViewInit { } this.assessSvc.assessment.maturityModel.maturityTargetLevel = response.maturityTargetLevel; this.assessSvc.assessment.maturityModel.answerOptions = response.answerOptions; - this.filterSvc.answerOptions = response.answerOptions; + this.filterSvc.answerOptions = response.answerOptions.slice(); this.filterSvc.maturityModelId = response.modelId; diff --git a/CSETWebNg/src/app/assessment/questions/maturity-questions/maturity-questions-ise.component.ts b/CSETWebNg/src/app/assessment/questions/maturity-questions/maturity-questions-ise.component.ts index 11921fb3cd..74d6ef52cc 100644 --- a/CSETWebNg/src/app/assessment/questions/maturity-questions/maturity-questions-ise.component.ts +++ b/CSETWebNg/src/app/assessment/questions/maturity-questions/maturity-questions-ise.component.ts @@ -126,7 +126,7 @@ export class MaturityQuestionsIseComponent implements OnInit, AfterViewInit { this.assessSvc.assessment.maturityModel.maturityTargetLevel = response.maturityTargetLevel; this.assessSvc.assessment.maturityModel.answerOptions = response.answerOptions; - this.filterSvc.answerOptions = response.answerOptions; + this.filterSvc.answerOptions = response.answerOptions.slice(); this.filterSvc.maturityModelId = response.modelId; // get the selected maturity filters diff --git a/CSETWebNg/src/app/assessment/questions/maturity-questions/maturity-questions.component.ts b/CSETWebNg/src/app/assessment/questions/maturity-questions/maturity-questions.component.ts index 10f90fd82d..a17294d11d 100644 --- a/CSETWebNg/src/app/assessment/questions/maturity-questions/maturity-questions.component.ts +++ b/CSETWebNg/src/app/assessment/questions/maturity-questions/maturity-questions.component.ts @@ -197,7 +197,7 @@ export class MaturityQuestionsComponent implements OnInit, AfterViewInit { this.assessSvc.assessment.maturityModel.maturityTargetLevel = response.maturityTargetLevel; this.assessSvc.assessment.maturityModel.answerOptions = response.answerOptions; - this.filterSvc.answerOptions = response.answerOptions; + this.filterSvc.answerOptions = response.answerOptions.slice(); this.filterSvc.maturityModelId = response.modelId; this.filterSvc.maturityModelName = response.modelName; @@ -247,7 +247,7 @@ export class MaturityQuestionsComponent implements OnInit, AfterViewInit { this.assessSvc.assessment.maturityModel.maturityTargetLevel = response.maturityTargetLevel; this.assessSvc.assessment.maturityModel.answerOptions = response.answerOptions; - this.filterSvc.answerOptions = response.answerOptions; + this.filterSvc.answerOptions = response.answerOptions.slice(); this.filterSvc.maturityModelId = response.modelId; this.pageTitle = this.questionsAlias + ' - ' + this.modelName; diff --git a/CSETWebNg/src/app/assessment/questions/question-block-ise/question-block-ise.component.html b/CSETWebNg/src/app/assessment/questions/question-block-ise/question-block-ise.component.html index 7373c93c0b..ca2db4f6d6 100644 --- a/CSETWebNg/src/app/assessment/questions/question-block-ise/question-block-ise.component.html +++ b/CSETWebNg/src/app/assessment/questions/question-block-ise/question-block-ise.component.html @@ -142,7 +142,7 @@