diff --git a/BO/Views/user/ur.cshtml b/BO/Views/user/ur.cshtml index a1e3371..60eea1d 100644 --- a/BO/Views/user/ur.cshtml +++ b/BO/Views/user/ur.cshtml @@ -66,6 +66,10 @@
@Html.Partial("./Partial/Radio", null, new ViewDataDictionary() { { "valuetext", "1:예;0:아니오" }, { "checked", Model.User.playbar }, { "name", "User.playbar" } })
+
+ +
@Html.Partial("./Partial/Radio", null, new ViewDataDictionary() { { "valuetext", "1:예;0:아니오" }, { "checked", Model.User.isplay }, { "name", "User.isplay" } })
+
}
diff --git a/BO/Web.config b/BO/Web.config index 7d4c0ec..27cf48b 100644 --- a/BO/Web.config +++ b/BO/Web.config @@ -56,9 +56,9 @@ - + - + diff --git a/Base/Controller/ACommonUser.cs b/Base/Controller/ACommonUser.cs index 42e2596..947c207 100644 --- a/Base/Controller/ACommonUser.cs +++ b/Base/Controller/ACommonUser.cs @@ -81,6 +81,7 @@ namespace NP.Base.Controllers { AuthSet(new AuthLog() { uno = SUserInfo.UserNo, uip = GetUserIP(), logtype = 1, usertypenew = vm.User.usertype, userno = vm.User.userno }); } + var result = Dao.Save("users.up", vm.User); // 상태값 휴면 선택시 diff --git a/Dao/MyBatis/Maps/CRoom.xml b/Dao/MyBatis/Maps/CRoom.xml index b90020e..98d31cf 100644 --- a/Dao/MyBatis/Maps/CRoom.xml +++ b/Dao/MyBatis/Maps/CRoom.xml @@ -178,23 +178,24 @@ ,case when b.isonline=1 then df.fileurl else df3.fileurl end fileurl ,case when b.isonline=1 then df.fileno else df3.fileno end fileno - ,df2.fileurl tasteurl - from lect a - inner join pay p on p.payno = a.payno - inner join cm a2 on a2.cmno=a.cmno - inner join cminning b on b.cmno=a2.cmno - left outer join lectinning c on c.lectno=a.lectno and c.cmino=b.cmino - left outer join cminning bp on bp.cmno=b.cmno and bp.iseq=b.iseq-1 - left outer join lectinning cp on cp.lectno=a.lectno and cp.cmino=bp.cmino - left outer join ct d on b.isonline = 1 and d.ctno=b.ctno - left outer join fileinfo df2 on b.isonline=1 and df2.fgno=d.fgnothumb and df2.isdel=0 - left outer join fileinfo df on b.isonline=1 and df.fgno=d.fgnotf and df.isdel=0 - left outer join fileinfo df3 on b.isonline=0 and df3.fgno=b.fgnotf and df3.isdel=0 - left outer join ctpage e on e.ctno=d.ctno and e.pseq=1 - left outer join cminningscd scd on a.cmisno = scd.cmisno - left outer join comcode com on scd.studyplace = com.ccode - where a.lectno=#lectno# and a.userno=#userno# and ifnull(b.isscd,0) = 0 - and ifnull(c.istatus,0) < 2 and a.sdate < now() and a.edate > now() + ,df2.fileurl tasteurl, ifnull(isplay,0) as isplay + from lect a + inner join pay p on p.payno = a.payno + inner join cm a2 on a2.cmno=a.cmno + inner join cminning b on b.cmno=a2.cmno + left outer join lectinning c on c.lectno=a.lectno and c.cmino=b.cmino + left outer join cminning bp on bp.cmno=b.cmno and bp.iseq=b.iseq-1 + left outer join lectinning cp on cp.lectno=a.lectno and cp.cmino=bp.cmino + left outer join ct d on b.isonline = 1 and d.ctno=b.ctno + left outer join fileinfo df2 on b.isonline=1 and df2.fgno=d.fgnothumb and df2.isdel=0 + left outer join fileinfo df on b.isonline=1 and df.fgno=d.fgnotf and df.isdel=0 + left outer join fileinfo df3 on b.isonline=0 and df3.fgno=b.fgnotf and df3.isdel=0 + left outer join ctpage e on e.ctno=d.ctno and e.pseq=1 + left outer join cminningscd scd on a.cmisno = scd.cmisno + left outer join comcode com on scd.studyplace = com.ccode + left outer join userstatus us on a.userno = us.userno + where a.lectno=#lectno# and a.userno=#userno# and ifnull(b.isscd,0) = 0 + and ifnull(c.istatus,0) < 2 and a.sdate < now() and a.edate > now() order by b.iseq limit $limit$ diff --git a/Dao/MyBatis/Maps/User.xml b/Dao/MyBatis/Maps/User.xml index 4717b15..2a6dbdf 100644 --- a/Dao/MyBatis/Maps/User.xml +++ b/Dao/MyBatis/Maps/User.xml @@ -248,6 +248,7 @@ ,CAST(AES_DECRYPT(UNHEX(a.birthday), ) AS char) birthday ,a.uduty,a.slevel,a.isacceptmobile,a.vssn,a.di,a.ci,a.ischkatt,a.authplatform , ifnull(us.playbar, 0) as playbar + , ifnull(us.isplay, 0) as isplay ,row_number() over(order by $orderby$a.username) rno ,count(a.cdt) over() pagetotalcount from users a @@ -406,6 +407,7 @@ update userstatus set playbar = #playbar# + ,isplay = #isplay# where userno = #userno#; insert into userstatus(userno, playbar) diff --git a/FO/Controllers/CRoomController.cs b/FO/Controllers/CRoomController.cs index d5045c2..abe4a4f 100644 --- a/FO/Controllers/CRoomController.cs +++ b/FO/Controllers/CRoomController.cs @@ -20,6 +20,7 @@ namespace NP.FO.Controllers public ActionResult Index() { vm.Lect = Dao.Get("cr.main.mygrade", new System.Collections.Hashtable() { { "lectno", vm.croomlectno }, { "cmno", vm.croomcmno},{ "userno", SUserInfo.UserNo} }).FirstOrDefault(); + ViewBag.fronturl = "https://" + Request.Url.Host; //ViewBag.fronturl = GetConfig("fronturl"); ViewBag.Mobile = Dao.Get("users.users", new System.Collections.Hashtable() { { "userno", SUserInfo.UserNo } }).FirstOrDefault().mobile; diff --git a/FO/Views/CRoom/Index.cshtml b/FO/Views/CRoom/Index.cshtml index 8a89ba7..ffb8eb5 100644 --- a/FO/Views/CRoom/Index.cshtml +++ b/FO/Views/CRoom/Index.cshtml @@ -1,5 +1,12 @@ @model NP.Model.VMCRoom @{ + // 임의학습과 같이 영상플레이 제한 해제 + int preflag = 0; + bool isplay = false; + if (Model.LectInnings.Count > 0) + { + isplay = Model.LectInnings.First().isplay > 0 ? true : false; + } }
@@ -249,8 +256,24 @@
  • @if (d.isonline == 1) { + if(!isplay) + { + + if (d.isseq == 1 && d.iseq != 1 && d.preistatus < 2) + { + preflag = 0; + } + else + { + preflag = 1; + } + } + else + { + preflag = 1; + } //학습기간 종료후에도 시청은 가능하고, 출석인정은 되지않도록 변경 2021-01-25 - 학습하기 + 학습하기 }
  • diff --git a/FO/Views/CRoom/Innings.cshtml b/FO/Views/CRoom/Innings.cshtml index f7c3a48..3eb1c96 100644 --- a/FO/Views/CRoom/Innings.cshtml +++ b/FO/Views/CRoom/Innings.cshtml @@ -1,6 +1,12 @@ @model NP.Model.VMCRoom @{ - + // 임의학습과 같이 영상플레이 제한 해제 + int preflag = 0; + bool isplay = false; + if (Model.LectInnings.Count > 0) + { + isplay = Model.LectInnings.First().isplay > 0 ? true : false; + } } @*
    출결이력조회 @@ -64,8 +70,23 @@
  • @if (d.isonline == 1) { + if (!isplay) + { + if (d.isseq == 1 && d.iseq != 1 && d.preistatus < 2) + { + preflag = 0; + } + else + { + preflag = 1; + } + } + else + { + preflag = 1; + } //학습기간 종료후에도 시청은 가능하고, 출석인정은 되지않도록 변경 2021-01-25 - 학습하기 + 학습하기 }
  • diff --git a/FO/Web.config b/FO/Web.config index dbfa277..901845f 100644 --- a/FO/Web.config +++ b/FO/Web.config @@ -40,9 +40,9 @@ - + - + diff --git a/Model/CM.cs b/Model/CM.cs index 0c03fc1..015acee 100644 --- a/Model/CM.cs +++ b/Model/CM.cs @@ -3274,6 +3274,12 @@ namespace NP.Model /// 일일 학습 회차 제한(0:무제한) /// public int daylectinninglimit { get; set; } + + + /// + /// 영상 임의학습과 같이 영상 플레이 (0:불가, 1:가능) + /// + public short isplay { get; set; } } [Serializable] diff --git a/Model/Users.cs b/Model/Users.cs index ce2f074..43d28b7 100644 --- a/Model/Users.cs +++ b/Model/Users.cs @@ -255,6 +255,7 @@ namespace NP.Model public int ischkatt { get; set; } public short lectcomp { get; set; } public short playbar { get; set; } + public short isplay { get; set; } public AuthPlatform authplatform { get; set; } }