diff --git a/FO/Views/My/Index.cshtml b/FO/Views/My/Index.cshtml index 76bafd9..1a1cf92 100644 --- a/FO/Views/My/Index.cshtml +++ b/FO/Views/My/Index.cshtml @@ -209,7 +209,6 @@ { string croomLink = string.Format("/CRoom/Index?croomlectno={0}", d.longval); - // 6709. 과제(intval 4)일 경우 링크가 달라야 한다 switch (d.intval) { case 1: @@ -249,6 +248,21 @@ } break; case 4: + // 6709. 과제(intval 4)일 경우 링크가 달라야 한다 + // 기존 쿼리에서는 sdno를 가져올 수 없어서 vm.CRoomLectSdInfo 를 추가함 + // => 쿼리조건 기준은 사용자번호를 기준으로 현재 수강중인 강좌기간내의 과제들을 모두 가져와서 들고 있음 + var lectsdInfo = new NP.Model.CRoomLectSdInfo(); + if (Model.CRoomLectSdInfo != null) + { + lectsdInfo = Model.CRoomLectSdInfo + .Where(x => x.lectno == d.longval) + .SingleOrDefault(); + } + + if (lectsdInfo != null && lectsdInfo.lectno > 0) + { + croomLink = string.Format("/CRoom/EstimationSubject?croomlectno={0}&croomcmno={1}&estno={2}&tabidx=0", d.longval, d.intval7, lectsdInfo.sdno); + }