parent
59c13bcbe4
commit
0d65f317e1
|
|
@ -0,0 +1,297 @@
|
||||||
|
@model NP.Model.VMLect
|
||||||
|
@{ Layout = "~/Views/Shared/_PopupLayout.cshtml";}
|
||||||
|
<ul class="pagination pagination-md">
|
||||||
|
<li class="active"><a href="#" onclick="gotab(0);" data-toggle="tab">출결이력</a></li>
|
||||||
|
<li><a href="#" onclick="gotab(1);" data-toggle="tab">로그인이력</a></li>
|
||||||
|
<li><a href="#" onclick="gotab(2);" data-toggle="tab">활동이력</a></li>
|
||||||
|
</ul>
|
||||||
|
<table class="regtable" style="margin-top: 0;">
|
||||||
|
<colgroup><col width="100" /><col width="300" /><col width="100" /><col /></colgroup>
|
||||||
|
<tr><th>신청자 정보</th><td>@string.Format("({0}) {1}", Model.Lect.asname, Model.Lect.usernameid)</td><th>신청구분</th><td>@Model.Lect.isrebatename</td></tr>
|
||||||
|
</table>
|
||||||
|
<br />
|
||||||
|
<div id="tab0">
|
||||||
|
<section class="panel panel-default">
|
||||||
|
<div class="table-responsive" id="excel1">
|
||||||
|
<table class="table table-striped b-t b-light no-odd">
|
||||||
|
<thead>
|
||||||
|
<tr>
|
||||||
|
<th width="20">회차</th>
|
||||||
|
<th>방식</th>
|
||||||
|
<th>강의주제</th>
|
||||||
|
<th>인정시간</th>
|
||||||
|
<th>학습시간(페이지)</th>
|
||||||
|
<th>최초학습시작일(IP)</th>
|
||||||
|
<th>최근학습종료일(IP)</th>
|
||||||
|
<th>상태</th>
|
||||||
|
</tr>
|
||||||
|
</thead>
|
||||||
|
<tbody class="data" id="tbody1">
|
||||||
|
@foreach (var iseq in Model.LectInningPages.Select(s => s.iseq).Distinct())
|
||||||
|
{
|
||||||
|
var inning = Model.LectInningPages.Where(w => w.iseq == iseq).First();
|
||||||
|
<tr data-cmino="@inning.cmino" data-cpno="@inning.cpno">
|
||||||
|
<td>@inning.iseq</td>
|
||||||
|
<td>@inning.isonlinename2</td>
|
||||||
|
<td>@inning.ititle</td>
|
||||||
|
<td>@inning.atimename</td>
|
||||||
|
<td class="@(inning.isonline==1 && inning.istatus != null ?"link":"") text-center">
|
||||||
|
@if (inning.isonline == 1 && inning.istatus != null@*&& inning.cpno > 0*@)
|
||||||
|
{
|
||||||
|
<a href="#" onclick="viewpage(@inning.cmino, this)">@inning.litotstudymin 분 <i class="fa fa-level-down"></i></a>
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
@:-
|
||||||
|
}
|
||||||
|
</td>
|
||||||
|
<td>@inning.listimeymdhms<br />@string.Format("({0}|{1})", inning.liispcsname, inning.lisips)</td>
|
||||||
|
<td>@inning.lietimeymdhms<br />@string.Format("({0})", inning.lieips)</td>
|
||||||
|
<td>
|
||||||
|
@if (inning.isonline == 1 && ((inning.istatus == 0 || inning.istatus == 1) || (inning.istatus == 2 && inning.statustime != null)))
|
||||||
|
{
|
||||||
|
<a href="#" class="link" style="color: #0094ff; text-decoration: underline;" onclick="viewabs(@inning.lectno, @inning.cmino, @inning.istatus, '@inning.statususername', '@inning.statususerid', '@inning.statustimename', '@((inning.statusreason??"").Replace("\n","newline"))')">@inning.istatusname</a>
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
@inning.istatusname
|
||||||
|
}
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
|
||||||
|
if (inning.isonline == 1 && inning.istatus != null/* && inning.cpno > 0*/)
|
||||||
|
{
|
||||||
|
var innings = Model.LectInningPages.Where(w => w.iseq == iseq);
|
||||||
|
<tr class="trpage hide trpage@(inning.cmino)">
|
||||||
|
<td colspan="4"> </td>
|
||||||
|
<td>
|
||||||
|
<ul>
|
||||||
|
@foreach (var d in innings)
|
||||||
|
{
|
||||||
|
<li>@string.Format("{0}분 ({1})", d.totstudymin, d.pseqname)</li>
|
||||||
|
}
|
||||||
|
</ul>
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
|
<ul>
|
||||||
|
@foreach (var d in innings)
|
||||||
|
{
|
||||||
|
<li>@d.stimeymdhms<br />@string.Format("({0}|{1})", d.ispcsname, d.sip)</li>
|
||||||
|
}
|
||||||
|
</ul>
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
|
<ul>
|
||||||
|
@foreach (var d in innings)
|
||||||
|
{
|
||||||
|
<li>@d.etimeymdhms<br />@string.Format("({0})", d.eip)</li>
|
||||||
|
}
|
||||||
|
</ul>
|
||||||
|
</td>
|
||||||
|
<td> </td>
|
||||||
|
</tr>
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</tbody>
|
||||||
|
</table>
|
||||||
|
</div>
|
||||||
|
<form id="mform" method="post">
|
||||||
|
@Html.Pager((int)Model.pagenum, 10, Model.pagerowcount, Model.pagetotalcount)
|
||||||
|
</form>
|
||||||
|
</section>
|
||||||
|
</div>
|
||||||
|
<div id="tab1" style="display: none;">
|
||||||
|
<div>
|
||||||
|
@Html.Partial("./Partial/Date", Model.Lect.sstime, new ViewDataDictionary { { "name", "start" } })
|
||||||
|
~
|
||||||
|
@Html.Partial("./Partial/Date", Model.Lect.setime, new ViewDataDictionary { { "name", "end" } })
|
||||||
|
<a href="#" class="btn btn-find btn-info btn-sm" onclick="findme()">검색</a>
|
||||||
|
</div>
|
||||||
|
<section class="panel panel-default">
|
||||||
|
<div class="table-responsive" id="excel1">
|
||||||
|
<table class="table table-striped b-t b-light no-odd">
|
||||||
|
<thead>
|
||||||
|
<tr>
|
||||||
|
<th>접속시간</th>
|
||||||
|
<th>접속IP</th>
|
||||||
|
<th>페이지</th>
|
||||||
|
</tr>
|
||||||
|
</thead>
|
||||||
|
<tbody id="tbody2">
|
||||||
|
@*@foreach(var d in Model.PageLogs)
|
||||||
|
{
|
||||||
|
<tr>
|
||||||
|
<td>@d.cdtymdhm</td>
|
||||||
|
<td>@d.uip</td>
|
||||||
|
<td class="text-left">@d.loginfo</td>
|
||||||
|
</tr>
|
||||||
|
}*@
|
||||||
|
</tbody>
|
||||||
|
</table>
|
||||||
|
</div>
|
||||||
|
</section>
|
||||||
|
</div>
|
||||||
|
<div id="tab2" style="display: none;">
|
||||||
|
<div>
|
||||||
|
@Html.Partial("./Partial/Date", Model.Lect.sstime, new ViewDataDictionary { { "name", "start2" } })
|
||||||
|
~
|
||||||
|
@Html.Partial("./Partial/Date", Model.Lect.setime, new ViewDataDictionary { { "name", "end2" } })
|
||||||
|
<a href="#" class="btn btn-find btn-info btn-sm" onclick="findme2()">검색</a>
|
||||||
|
</div>
|
||||||
|
<section class="panel panel-default">
|
||||||
|
<div class="table-responsive" id="excel1">
|
||||||
|
<table class="table table-striped b-t b-light no-odd">
|
||||||
|
<thead>
|
||||||
|
<tr>
|
||||||
|
<th>접속시간</th>
|
||||||
|
<th>접속IP</th>
|
||||||
|
<th>페이지</th>
|
||||||
|
</tr>
|
||||||
|
</thead>
|
||||||
|
<tbody id="tbody3">
|
||||||
|
@*@foreach(var d in Model.PageLogs)
|
||||||
|
{
|
||||||
|
<tr>
|
||||||
|
<td>@d.cdtymdhm</td>
|
||||||
|
<td>@d.uip</td>
|
||||||
|
<td class="text-left">@d.loginfo</td>
|
||||||
|
</tr>
|
||||||
|
}*@
|
||||||
|
</tbody>
|
||||||
|
</table>
|
||||||
|
</div>
|
||||||
|
</section>
|
||||||
|
</div>
|
||||||
|
<div class="botfixempty"> </div>
|
||||||
|
<div class="form-group botfix" style="margin-left: -20px;">
|
||||||
|
<a href="#" class="btn btn-danger" onclick="goparent(val('IsSavedForParent') == '1');">닫기</a>
|
||||||
|
</div>
|
||||||
|
<div id="thisbox" class="findbox draggable regbox" style="width: 500px; z-index: 1041; top: 60px; overflow: auto;">
|
||||||
|
<h4><i class="fa fa-bars"></i> <span id="pcap">출석인정</span><a href="#" class="btn btn-default btn-xs f-r closethisbox">닫기</a></h4>
|
||||||
|
<table class="regtable">
|
||||||
|
<colgroup><col style="width:150px;"><col></colgroup>
|
||||||
|
<tbody>
|
||||||
|
<tr>
|
||||||
|
<th>담당자</th>
|
||||||
|
<td><p id="statususer" class="form-static-control"></p></td>
|
||||||
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<th>정정일</th>
|
||||||
|
<td><p id="statustime" class="form-static-control"></p></td>
|
||||||
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<th>사유</th>
|
||||||
|
<td><textarea id="statusreason" class="form-control" style="resize: none;" maxlength="90"></textarea></td>
|
||||||
|
</tr>
|
||||||
|
</tbody>
|
||||||
|
</table>
|
||||||
|
<div class="findboxbtnbox">
|
||||||
|
<a href="#" class="btn btn-primary" id="btnsavereason" onclick="savereason();">저장</a>
|
||||||
|
</div>
|
||||||
|
<br><br>
|
||||||
|
</div>
|
||||||
|
<form id="mform" method="post">
|
||||||
|
@Html.HiddenFor(m => m.longval)
|
||||||
|
@Html.HiddenFor(m => m.IsSavedForParent)
|
||||||
|
</form>
|
||||||
|
@section styles{
|
||||||
|
<style type="text/css">
|
||||||
|
.panel .table-striped.no-odd > tbody > tr:nth-child(odd).trpage > td{background-color: #f7f7f7 !important}
|
||||||
|
tr.hide{display: none;}
|
||||||
|
</style>
|
||||||
|
}
|
||||||
|
@section scriptsHeader{
|
||||||
|
@Html.Partial("./Partial/ScriptDate")
|
||||||
|
}
|
||||||
|
@section scripts{
|
||||||
|
<script>
|
||||||
|
$(document).ready(function () {
|
||||||
|
|
||||||
|
});
|
||||||
|
var _ischanged = false;
|
||||||
|
function viewpage(cmino, a) {
|
||||||
|
if ($(a).find("i").hasClass("fa-level-down")) {
|
||||||
|
$("tr.trpage" + cmino).removeClass("hide");
|
||||||
|
$(a).find("i").removeClass("fa-level-down").addClass("fa-level-up");
|
||||||
|
} else {
|
||||||
|
$("tr.trpage" + cmino).addClass("hide");
|
||||||
|
$(a).find("i").removeClass("fa-level-up").addClass("fa-level-down");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
var _lectno = 0;
|
||||||
|
var _cmino = 0;
|
||||||
|
function viewabs(lectno, cmino, istatus, statususername, statususerid, statustimename, statusreason) {
|
||||||
|
$("#statusreason").removeAttr("readonly");
|
||||||
|
$("#btnsavereason").show();
|
||||||
|
_lectno = 0;
|
||||||
|
_cmino = 0;
|
||||||
|
$("#statustime,#statusreason,#statusreason").text("");
|
||||||
|
if (istatus == 2) {
|
||||||
|
$("#statususer").text(statususername + "(" + statususerid + ")");
|
||||||
|
$("#statustime").text(statustimename);
|
||||||
|
$("#statusreason").text(statusreason.replace(/newline/gi,'\n'));
|
||||||
|
$("#btnsavereason").hide();
|
||||||
|
$("#statusreason").attr("readonly", "readonly");
|
||||||
|
} else {
|
||||||
|
_lectno = lectno;
|
||||||
|
_cmino = cmino;
|
||||||
|
$("#statususer").text('@ViewBag.SSUserName');
|
||||||
|
}
|
||||||
|
bglayer(); $("#thisbox").slideDown("fast", function () {
|
||||||
|
$("#statusreason").focus();
|
||||||
|
});
|
||||||
|
}
|
||||||
|
function savereason() {
|
||||||
|
if (check("statusreason", null, "사유를 입력해주세요.", true)) { }
|
||||||
|
else if (confirm("출석처리하시겠습니까?")) {
|
||||||
|
capp("/acommon/attabs", { lectno: _lectno, cmino: _cmino, reason: val("statusreason") }, "cbsavereason", null, null, null, true);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
function cbsavereason() {
|
||||||
|
if (capResult.code == 1000) {
|
||||||
|
_ischanged = true;
|
||||||
|
parent.childsaved();
|
||||||
|
|
||||||
|
} else {
|
||||||
|
msgdev(true);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
function gotab(idx) {
|
||||||
|
$("#tab0,#tab1").hide();
|
||||||
|
$("#tab" + idx).show();
|
||||||
|
}
|
||||||
|
function findme() {
|
||||||
|
if (check("start", null, "접속시작일자를 입력해주세요.")) { }
|
||||||
|
else if (check("end", null, "접속종료일자를 입력해주세요.")) { }
|
||||||
|
else {
|
||||||
|
$("#tbody2 tr").remove();
|
||||||
|
capp("/acommon/getLoginLog", { userno: @Model.Lect.userno, stime: val("start"), etime: val("end") }, "cbpagelogs");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
function cbpagelogs() {
|
||||||
|
$.each(capResult.obj, function (i, d) {
|
||||||
|
$("#tbody2").append("<tr><td>" + d.cdtymdhm + "</td><td>" + getdb(d.uip) + "</td><td class=\"text-left\">" + getdb(d.loginfo) + "</td></tr>");
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
function findme2() {
|
||||||
|
if (check("start2", null, "접속시작일자를 입력해주세요.")) { }
|
||||||
|
else {
|
||||||
|
$("#tbody3 tr").remove();
|
||||||
|
capp("/acommon/PageLogs2", { userno: @Model.Lect.userno, start: val("start2"), end: val("end2"), logsite: 1 }, "cbpagelogs2");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
function cbpagelogs2() {
|
||||||
|
$.each(JSON.parse(capResult).Table, function (i, d) {
|
||||||
|
$("#tbody3").append("<tr><td>" + d.cdt.replace("T", " ") + "</td><td>" + getdb(d.uip) + "</td><td class=\"text-left\">" + getdb(d.loginfo) + "</td></tr>");
|
||||||
|
});
|
||||||
|
hidelayermsg2()
|
||||||
|
}
|
||||||
|
function cbpagelogs2_old() {
|
||||||
|
$.each(capResult.obj, function (i, d) {
|
||||||
|
$("#tbody3").append("<tr><td>" + d.cdt.replace("T", " ") + "</td><td>" + getdb(d.uip) + "</td><td class=\"text-left\">" + getdb(d.loginfo) + "</td></tr>");
|
||||||
|
});
|
||||||
|
hidelayermsg2()
|
||||||
|
}
|
||||||
|
</script>
|
||||||
|
}
|
||||||
File diff suppressed because it is too large
Load Diff
|
|
@ -803,6 +803,42 @@
|
||||||
</dynamic>
|
</dynamic>
|
||||||
order by cdt desc
|
order by cdt desc
|
||||||
</select>
|
</select>
|
||||||
|
<select id="lect.pagelogs_page_OLD" parameterClass="hashtable" resultClass="pagelog">
|
||||||
|
select a.cdt,a.uip,b.pagename,a.loginfo
|
||||||
|
from (
|
||||||
|
select cdt, uip, loginfo, pno
|
||||||
|
from pagelog a
|
||||||
|
where a.userno=#userno# and a.logsite=#logsite# and DATE_FORMAT(a.cdt, '%Y-%m-%d') = #start#
|
||||||
|
) a
|
||||||
|
left outer join menupage b on b.pno=a.pno
|
||||||
|
<dynamic prepend="where">
|
||||||
|
<isNotNull property="logsite" prepend="and"></isNotNull>
|
||||||
|
<isNotNull property="userno" prepend="and"></isNotNull>
|
||||||
|
<isNotNull property="from" prepend="and">a.cdt >= #from#</isNotNull>
|
||||||
|
<isNotNull property="to" prepend="and">a.cdt <= #to#</isNotNull>
|
||||||
|
</dynamic>
|
||||||
|
</select>
|
||||||
|
<select id="lect.pagelogs_page" parameterClass="hashtable" resultClass="pagelog">
|
||||||
|
select a.cdt,a.uip,b.pagename,a.loginfo
|
||||||
|
from menupage b
|
||||||
|
inner join (
|
||||||
|
select cdt, uip, loginfo, pno
|
||||||
|
from pagelog a
|
||||||
|
where a.userno=#userno# and a.logsite=#logsite# and a.cdt between #start# and #end#
|
||||||
|
) a on b.pno=a.pno
|
||||||
|
</select>
|
||||||
|
<select id="lect.pagelogs_login" parameterClass="hashtable" resultClass="pagelog">
|
||||||
|
select a.cdt,a.uip,'로그인' as pagename, '로그인' as loginfo
|
||||||
|
from loginlog a
|
||||||
|
<dynamic prepend="where">
|
||||||
|
<isNotNull property="logsite" prepend="and">a.logsite=#logsite#</isNotNull>
|
||||||
|
<isNotNull property="userno" prepend="and">a.userno=#userno# and a.loginstatus < 2</isNotNull>
|
||||||
|
<isNotNull property="start" prepend="and">a.cdt between #start# and #end#</isNotNull>
|
||||||
|
<isNotNull property="from" prepend="and">a.cdt >= #from#</isNotNull>
|
||||||
|
<isNotNull property="to" prepend="and">a.cdt <= #to#</isNotNull>
|
||||||
|
</dynamic>
|
||||||
|
<!--order by cdt desc-->
|
||||||
|
</select>
|
||||||
<select id="lect.lectexes" parameterClass="hashtable" resultClass="lectex">
|
<select id="lect.lectexes" parameterClass="hashtable" resultClass="lectex">
|
||||||
select a.*
|
select a.*
|
||||||
from (
|
from (
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue