Skip to content

Commit d709470

Browse files
TD-5487 Issue showing multiple comments when clicked the back link after submitted the review on Frameworks section
1 parent ff91492 commit d709470

File tree

1 file changed

+2
-0
lines changed
  • DigitalLearningSolutions.Web/Controllers/FrameworksController

1 file changed

+2
-0
lines changed

DigitalLearningSolutions.Web/Controllers/FrameworksController/Review.cs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -81,6 +81,8 @@ public IActionResult LoadReview(int frameworkId, int reviewId)
8181
public IActionResult SubmitFrameworkReview(int frameworkId, int reviewId, string? comment, bool signedOff)
8282
{
8383
var adminId = GetAdminId();
84+
var framework = frameworkService.GetBaseFrameworkByFrameworkId(frameworkId, adminId);
85+
if (framework.FrameworkReviewID == 0 || framework.FrameworkReviewID == null) return RedirectToAction("StatusCode", "LearningSolutions", new { code = 410 });
8486
int? commentId = null;
8587
if (!string.IsNullOrWhiteSpace(comment)) commentId = frameworkService.InsertComment(frameworkId, adminId, comment, null);
8688
frameworkService.SubmitFrameworkReview(frameworkId, reviewId, signedOff, commentId);

0 commit comments

Comments
 (0)