This commit is contained in:
kdh0120 2021-01-04 06:38:45 +00:00
parent 324f794267
commit 7784da586d
8 changed files with 173 additions and 101 deletions

View File

@ -371,13 +371,14 @@
}); });
function save() { function save() {
setv("User_userpno", val("userpno1") + val("userpno2")); setv("User_userpno", val("userpno1")+"-"+ val("userpno2"));
setv("User_mobile", formatmobile(val("User_mobile"))); setv("User_mobile", formatmobile(val("User_mobile")));
setv("User_telno", formatphone(val("User_telno"))); setv("User_telno", formatphone(val("User_telno")));
if (val("User_usertype") == "0" || val("User_usertype") == "") { focus("User_usertype");msg("권한을 선택해주세요."); } if (val("User_usertype") == "0" || val("User_usertype") == "") { focus("User_usertype");msg("권한을 선택해주세요."); }
else if (check("User_userid", null, "ID를 입력해주세요.")) { } else if (check("User_userid", null, "ID를 입력해주세요.")) { }
else if (val("User_userid").length < 6) {focus("User_userid"); msg("ID를 6글자 이상으로 입력해주세요.");} else if (val("User_userid").length < 6) {focus("User_userid"); msg("ID를 6글자 이상으로 입력해주세요.");}
else if (val("User_userno") == '0' && !ispassword(val("User_userpass"))) { focus("User_userpass"); msg("6글자이상의 비밀번호를 입력해주세요."); } else if (val("User_userno") == '0' && !ispassword(val("User_userpass"))) { focus("User_userpass"); msg("6글자이상의 비밀번호를 입력해주세요."); }
else if (val("userpno1") != null && val("userpno2") == null) {focus("userpno2");msg("주민등록번호를 제대로 입력해주세요.");}
else if (check("User_username", null, "이름을 입력해주세요.")) { } else if (check("User_username", null, "이름을 입력해주세요.")) { }
else if (('@Model.viewname' == 'professor' || '@Model.viewname' == 'user') && check("User_email",null,"이메일을 입력해주세요")) { } else if (('@Model.viewname' == 'professor' || '@Model.viewname' == 'user') && check("User_email",null,"이메일을 입력해주세요")) { }
else if (('@Model.viewname' == 'professor' || '@Model.viewname' == 'user') && check("User_mobile", null, "핸드폰 번호를 입력해주세요")) { } else if (('@Model.viewname' == 'professor' || '@Model.viewname' == 'user') && check("User_mobile", null, "핸드폰 번호를 입력해주세요")) { }

View File

@ -1428,6 +1428,13 @@
) a ) a
<include refid="sql.pagedynamic"></include> <include refid="sql.pagedynamic"></include>
</select> </select>
<select id="lect.lecture.document.past" parameterClass="hashtable" resultClass="lect">
select no lectno,substr(a.cshape,1,3) cshapename2,a.cgname cname,a.ssdate sstime,a.sedate setime
,case when a.rprice> 0 then 1 else 0 end isrebate
from docprintpast a
inner join users b on CAST(AES_DECRYPT(UNHEX(b.userpno), <include refid="sql.digest"></include>) AS char) = a.userpno
where userno = #userno#
</select>
<update id="lect.drop2day" parameterClass="hashtable"> <update id="lect.drop2day" parameterClass="hashtable">
update pay a update pay a
inner join lect b on b.payno = a.payno and b.cmno = #cmno# and b.ischanged=0 and ifnull(b.isready,0) = 1 and b.status = 4 and DATE_ADD(b.oktime, INTERVAL 2 DAY) &lt; <include refid="sql.now"></include> inner join lect b on b.payno = a.payno and b.cmno = #cmno# and b.ischanged=0 and ifnull(b.isready,0) = 1 and b.status = 4 and DATE_ADD(b.oktime, INTERVAL 2 DAY) &lt; <include refid="sql.now"></include>

View File

@ -442,6 +442,11 @@ namespace NP.FO.Controllers
else else
{ {
//여기는 2021년 이전과정 근데 아직 뭔가 안나옴.. //여기는 2021년 이전과정 근데 아직 뭔가 안나옴..
vm.pagerowcount = vm.pagerowcount < 1 ? 10 : vm.pagerowcount;
var ht = SetHash(vm);
ht.Add("userno", SUserInfo.UserNo);
vm.Lects = Dao.Get<Lect>("lect.lecture.document.past", ht);
} }
return View(vm); return View(vm);
} }

View File

@ -19,128 +19,174 @@
<li>환급금 지급내역서는 환급을 신청한 강좌만 출력하실 수 있습니다.</li> <li>환급금 지급내역서는 환급을 신청한 강좌만 출력하실 수 있습니다.</li>
</ul> </ul>
</div> </div>
<form id="dform" method="post" action="/My/Document">
@Html.HiddenFor(w=>w.tabidx)
</form>
<div class="lctQr"> <div class="lctQr">
<span class="@(Model.tabidx == 0 ? "current" : "" )" id="lblAll">신규과정</span>&nbsp;|&nbsp; <span class="@(Model.tabidx == 0 ? "current" : "" )" onclick="gopage(0);" id="lblAll">신규과정</span>&nbsp;|&nbsp;
<span class="@(Model.tabidx == 1 ? "current" : "" )" id="lblOff">2021년 이전과정</span>&nbsp; <span class="@(Model.tabidx == 1 ? "current" : "" )" onclick="gopage(1);" id="lblOff">2021년 이전과정</span>&nbsp;
</div> </div>
<table class="lctAply"> @if (Model.tabidx == 0)
<colgroup> {
<col width="*" /> <table class="lctAply">
<col width="10%" /> <colgroup>
<col width="10%" /> <col width="*" />
<col width="10%" /> <col width="10%" />
<col width="10%" /> <col width="10%" />
</colgroup> <col width="10%" />
<thead> <col width="10%" />
<tr> </colgroup>
<th>강좌명</th> <thead>
<th>위탁계약서</th>
<th>입교통지서</th>
<th>수료증</th>
<th>계산서/영수증</th>
</tr>
</thead>
<tbody>
@foreach (var item in Model.Lects)
{
<tr> <tr>
<th> <th>강좌명</th>
<div class="ltaList"> <th>위탁계약서</th>
<a href="#" style="cursor:default"> <th>입교통지서</th>
<h5> <th>수료증</th>
<em>@(item.tseq)기</em> <th>계산서/영수증</th>
<span class="nav">@item.cshapename</span> </tr>
@Html.Raw(item.isrebate == 1 ? "<span class=\"grn\">환급</span>" : "") </thead>
<b>@item.cname</b> <tbody>
</h5> @foreach (var item in Model.Lects)
<dl class="ltaDl"> {
@if (item.cshape == 1) <tr>
{ <th>
<dd>교육기간 : @item.sstime.Value.ToString("yy-MM-dd") ~ @(item.setime.Value.ToString("yy-MM-dd"))</dd> <div class="ltaList">
} <a href="#" style="cursor:default">
else <h5>
{ <em>@(item.tseq)기</em>
<dd> <span class="nav">@item.cshapename</span>
수강기간 : @item.sstime.Value.ToString("yy-MM-dd") ~ @(item.setime.Value.ToString("yy-MM-dd")) @Html.Raw(item.isrebate == 1 ? "<span class=\"grn\">환급</span>" : "")
@if (item.cshape == 2 && item.estart > Convert.ToDateTime("1900-01-01") && item.eend > Convert.ToDateTime("1900-01-01")) <b>@item.cname</b>
</h5>
<dl class="ltaDl">
@if (item.cshape == 1)
{ {
@:| 집체교육기간 : @("[" + item.studyplacename + "] " + string.Format("{0}", item.estart.ToString("yy-MM-dd"))) <dd>교육기간 : @item.sstime.Value.ToString("yy-MM-dd") ~ @(item.setime.Value.ToString("yy-MM-dd"))</dd>
} }
</dd> else
} {
<dd>결제금액 : @(item.payamt)원</dd> <dd>
</dl> 수강기간 : @item.sstime.Value.ToString("yy-MM-dd") ~ @(item.setime.Value.ToString("yy-MM-dd"))
</a> @if (item.cshape == 2 && item.estart > Convert.ToDateTime("1900-01-01") && item.eend > Convert.ToDateTime("1900-01-01"))
</div> {
</th> @:| 집체교육기간 : @("[" + item.studyplacename + "] " + string.Format("{0}", item.estart.ToString("yy-MM-dd")))
<td class="ltaBtn" data-th="위탁계약서 : "> }
@if (item.pstatus == 1) </dd>
{
<a href="#" onclick="javascript: educontract(@(item.lectno));"><img src="~/img/mypage/print.png"><br />인쇄</a> }
} <dd>결제금액 : @(item.payamt)원</dd>
else </dl>
{ </a>
@Html.Raw("-") </div>
} </th>
</td> <td class="ltaBtn" data-th="위탁계약서 : ">
<td class="ltaBtn" data-th="입교통지서 : "> @if (item.pstatus == 1)
<a href="#" onclick="javascript: eduannotation(@(item.lectno));"><img src="~/img/mypage/print.png"><br />[인쇄]</a> {
</td> <a href="#" onclick="javascript: educontract(@(item.lectno));"><img src="~/img/mypage/print.png"><br />인쇄</a>
<td class="ltaBtn" data-th="수료증 : "> }
@if (item.iscomplete == 1) else
{
<a href="#" onclick="javascript: certification(@(item.lectno));"><img src="~/img/mypage/print.png"><br />[인쇄]</a>
}
else
{
@Html.Raw("-")
}
</td>
<td class="ltaBtn" data-th="계산서/영수증 : ">
@if (item.pstatus == 1 && item.rstatus == 0)
{
if (item.ptype == 6)
{ {
@Html.Raw("-") @Html.Raw("-")
} }
else if (item.ptype == 1 && item.ispg == 1) </td>
<td class="ltaBtn" data-th="입교통지서 : ">
<a href="#" onclick="javascript: eduannotation(@(item.lectno));"><img src="~/img/mypage/print.png"><br />[인쇄]</a>
</td>
<td class="ltaBtn" data-th="수료증 : ">
@if (item.iscomplete == 1)
{ {
<a href="#" onclick="javascript:viewtax(@(item.pgkey))">[영수증]</a> <a href="#" onclick="javascript: certification(@(item.lectno));"><img src="~/img/mypage/print.png"><br />[인쇄]</a>
} }
//현금영수증안붙었음
@*else if (item.ptype == 3 && item.ispg == 1)
{
//일단대체?
<a href="#" onclick="javascript:viewtax(@(item.pgkey))">[영수증]</a>
}*@
else else
{ {
if (item.taxno > 0) @Html.Raw("-")
}
</td>
<td class="ltaBtn" data-th="계산서/영수증 : ">
@if (item.pstatus == 1 && item.rstatus == 0)
{
if (item.ptype == 6)
{ {
<a href="#" onclick="showtax(@(item.payno))">[@(item.taxdate2 == null ? "신청중" : "발행")]</a> @Html.Raw("-")
} }
else if (item.ptype == 1 && item.ispg == 1)
{
<a href="#" onclick="javascript:viewtax(@(item.pgkey))">[영수증]</a>
}
//현금영수증안붙었음
@*else if (item.ptype == 3 && item.ispg == 1)
{
//일단대체?
<a href="#" onclick="javascript:viewtax(@(item.pgkey))">[영수증]</a>
}*@
else else
{ {
if (Convert.ToDateTime(Convert.ToDateTime(item.payoktime).ToString("yyyy-MM-dd")) <= Convert.ToDateTime(DateTime.Now.AddMonths(1).ToString("yyyy-MM-dd"))) if (item.taxno > 0)
{ {
<a href="#" onclick="calltax(@(item.payno),'@(string.Format("{0}:{1}:{2}:{3}:{4}:{5}:{6}",item.payamt.ToString("#,0")+"원",item.payoktime.ToString("yy-MM-dd"),item.ptypename2,item.ispg == 1 ? "PG" : "현장결제",item.itemname,item.pipayamt.ToString("#,0")+"원",item.pino))')">[요청]</a> <a href="#" onclick="showtax(@(item.payno))">[@(item.taxdate2 == null ? "신청중" : "발행")]</a>
} }
else else
{ {
<a href="#" onclick="msg('계산서 요청 기한이 지나 신청이 불가능합니다.'); return;">[요청]</a> if (Convert.ToDateTime(Convert.ToDateTime(item.payoktime).ToString("yyyy-MM-dd")) <= Convert.ToDateTime(DateTime.Now.AddMonths(1).ToString("yyyy-MM-dd")))
{
<a href="#" onclick="calltax(@(item.payno),'@(string.Format("{0}:{1}:{2}:{3}:{4}:{5}:{6}",item.payamt.ToString("#,0")+"원",item.payoktime.ToString("yy-MM-dd"),item.ptypename2,item.ispg == 1 ? "PG" : "현장결제",item.itemname,item.pipayamt.ToString("#,0")+"원",item.pino))')">[요청]</a>
}
else
{
<a href="#" onclick="msg('계산서 요청 기한이 지나 신청이 불가능합니다.'); return;">[요청]</a>
}
} }
} }
} }
} else
else {
{ @Html.Raw("-")
@Html.Raw("-") }
} </td>
</td> </tr>
}
</tbody>
</table>
}
else
{
<table class="lctAply">
<colgroup>
<col width="*" />
<col width="10%" />
</colgroup>
<thead>
<tr>
<th>강좌명</th>
<th>수료증</th>
</tr> </tr>
} </thead>
</tbody> <tbody>
</table> @foreach (var item in Model.Lects)
{
<tr>
<th>
<div class="ltaList">
<a href="#" style="cursor:default">
<h5>
<span class="nav">@item.cshapename2</span>
@Html.Raw(item.isrebate == 1 ? "<span class=\"grn\">환급</span>" : "")
<b>@item.cname</b>
</h5>
<dl class="ltaDl">
<dd>교육기간 : @item.sstime.Value.ToString("yy-MM-dd") ~ @(item.setime.Value.ToString("yy-MM-dd"))</dd>
</dl>
</a>
</div>
</th>
<td class="ltaBtn" data-th="수료증 : ">
<a href="#" onclick="javascript: certificationpast(@(item.lectno));"><img src="~/img/mypage/print.png"><br />[인쇄]</a>
</td>
</tr>
}
</tbody>
</table>
}
<div class="mpgPop mpgPopFull" style="display:none;" id="pop1"> <div class="mpgPop mpgPopFull" style="display:none;" id="pop1">
<div> <div>
<div> <div>
@ -172,7 +218,7 @@
</tr> </tr>
</table> </table>
<form id="mform" method="post" enctype="multipart/form-data"> <form id="mform" method="post" enctype="multipart/form-data">
<input type="hidden" id="pinos" name="pinos" value=""/> <input type="hidden" id="pinos" name="pinos" value="" />
<input type="hidden" id="mptpayno" name="payno" value="" /> <input type="hidden" id="mptpayno" name="payno" value="" />
<h4 class="bskTitle">발행업체 정보</h4> <h4 class="bskTitle">발행업체 정보</h4>
<table class="odrTable th150"> <table class="odrTable th150">
@ -294,6 +340,12 @@
msg("팝업이 차단되어 있습니다. 차단을 해제해 주세요."); msg("팝업이 차단되어 있습니다. 차단을 해제해 주세요.");
} }
} }
function certificationpast(lectno) {
var pop = window.open('@ViewBag.reporturl/certificationpast.aspx?lectno='+lectno, "certprint", "width=" + (screen.availWidth) + ", height=" + (screen.availHeight) + ", scrollbars=yes, resizable=yes, status=no, location=no, left=0, top=0");
if (pop == null) {
msg("팝업이 차단되어 있습니다. 차단을 해제해 주세요.");
}
}
function educontract(lectno) { function educontract(lectno) {
var pop = window.open('@ViewBag.reporturl/educontract.aspx?lectno='+lectno, "certprint", "width=" + (screen.availWidth) + ", height=" + (screen.availHeight) + ", scrollbars=yes, resizable=yes, status=no, location=no, left=0, top=0"); var pop = window.open('@ViewBag.reporturl/educontract.aspx?lectno='+lectno, "certprint", "width=" + (screen.availWidth) + ", height=" + (screen.availHeight) + ", scrollbars=yes, resizable=yes, status=no, location=no, left=0, top=0");
if (pop == null) { if (pop == null) {
@ -425,7 +477,13 @@
} }
} else { } else {
msg("신청된 계산서가 없습니다."); msg("신청된 계산서가 없습니다.");
} }
}
function gopage(tabidx) {
if (tabidx != @(Model.tabidx)) {
$("#tabidx").val(tabidx);
$("#dform").submit();
}
} }
</script> </script>
@if (ViewBag.isPayTest == "1") @if (ViewBag.isPayTest == "1")

View File

@ -1076,6 +1076,7 @@ namespace NP.Model
return cshape == 0 ? "온라인" : cshape == 1 ? "교육장" : cshape == 2 ? "온라인" : "-"; return cshape == 0 ? "온라인" : cshape == 1 ? "교육장" : cshape == 2 ? "온라인" : "-";
} }
} }
public String cshapename2 { get; set; }
public String certgradeccname { get; set; } public String certgradeccname { get; set; }
public String rsrename public String rsrename
{ {