562 lines
30 KiB
Plaintext
562 lines
30 KiB
Plaintext
@model NP.Model.VMPay
|
|
@{
|
|
|
|
}
|
|
<h4 class="bskTitle">주문상품 정보</h4>
|
|
<p class="odrNum">결제번호 : @(Model.Pay.payno < 1000000 ? Model.Pay.payno.ToString("000000") : Model.Pay.payno.ToString())</p>
|
|
<table class="bskList">
|
|
<tbody>
|
|
@foreach (var d in Model.PayItems.Where(w => w.ptype == 0 || w.ptype == 1 || w.ptype == 4))
|
|
{
|
|
<tr>
|
|
<td>
|
|
<h5>
|
|
<span class="blu">강좌</span>
|
|
<span class="ppl">@d.cshapename</span>
|
|
@Html.Raw(d.isrebate == 1 ? "<span class=\"grn\">환급</span>" : "")
|
|
<b style="color:@(d.pstatus==22?"red":"")">@d.itemname</b>
|
|
@if (d.rsno > 0 && d.userno == ViewBag.SSUserNo && Model.Pay.pstatus == 1 && d.rstatus == 0 && Model.Pay.rstatus < 2)
|
|
{
|
|
<a href="/CRoom/Research?croomlectno=@d.lectno">사전설문참여</a>
|
|
}
|
|
</h5>
|
|
<dl>
|
|
<dd>가격 : <span class="bk">@(d.days)일</span></dd>
|
|
@if (Model.Pay.isgroup == 1)
|
|
{
|
|
<dd><span class="org">@(Model.PayItems.Where(w => w.ptype == 0).Count())명</span></dd>
|
|
}
|
|
<dd><span class="red">@d.payamt.ToString("#,0")</span>원</dd>
|
|
</dl>
|
|
</td>
|
|
</tr>
|
|
if (Model.Pay.isgroup == 1)
|
|
{
|
|
break;
|
|
}
|
|
}
|
|
@foreach (var d in Model.PayItems.Where(w => w.ptype == 3))
|
|
{
|
|
<tr>
|
|
<td>
|
|
<h5>
|
|
<span class="org">시험</span>
|
|
<b>@d.itemname</b>
|
|
</h5>
|
|
<dl>
|
|
<dd>가격</dd>
|
|
<dd><span class="red">@d.payamt.ToString("#,0")</span>원</dd>
|
|
</dl>
|
|
</td>
|
|
</tr>
|
|
}
|
|
@foreach (var d in Model.PayItems.Where(w => w.ptype == 2))
|
|
{
|
|
<tr>
|
|
<td>
|
|
<h5>
|
|
<span class="org">교재</span>
|
|
<b>@d.itemname</b>
|
|
</h5>
|
|
<dl>
|
|
<dd>가격</dd>
|
|
<dd><span class="org">@(d.pcnt)개</span></dd>
|
|
<dd><span class="red">@d.payamt.ToString("#,0")</span>원</dd>
|
|
</dl>
|
|
</td>
|
|
</tr>
|
|
}
|
|
</tbody>
|
|
</table>
|
|
<table class="bskCost">
|
|
<thead>
|
|
<tr>
|
|
<th>주문금액</th>
|
|
<th>배송비</th>
|
|
<th>최종 결제금액</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody>
|
|
<tr>
|
|
<td>@((Model.Pay.payamt - Model.Pay.deliamt).ToString("#,0"))원</td>
|
|
<td><div>@(Model.Pay.deliamt.ToString("#,0"))원</div></td>
|
|
<td><b>@Model.Pay.payamt.ToString("#,0")</b><span>원</span></td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
@if (Model.Pay.isgroup == 1)
|
|
{
|
|
<h4 class="bskTitle">교육생 정보</h4>
|
|
foreach (var d in Model.PayItems.Where(w => w.ptype == 0))
|
|
{
|
|
<div class="odrInfo">
|
|
<h5>@d.username @d.ccpositionname (@(d.isassignuser == 1 ? "자사근로자" : "타사근로자"))</h5>
|
|
<ul>
|
|
<li>@d.emailhide @(d.telno ?? d.mobile)</li>
|
|
<li>@(string.IsNullOrEmpty(d.depart) ? "" : string.Format("{0} | ", d.depart)) 공정거래업무경력 : @(d.kfcfyear)년</li>
|
|
<li>교육이력 : @d.edusname</li>
|
|
</ul>
|
|
</div>
|
|
}
|
|
}
|
|
else
|
|
{
|
|
<h4 class="bskTitle">교육생 정보</h4>
|
|
var u = Model.PayItems.Where(w => w.ptype == 0 || w.ptype == 1 || w.ptype == 4).First();
|
|
<div class="odrInfo">
|
|
<h5>@u.username @u.ccpositionname (@(u.isassignuser == 1 ? "자사근로자" : "타사근로자"))</h5>
|
|
<ul>
|
|
<li>@u.emailhide @(u.telno ?? u.mobile)</li>
|
|
<li>@(string.IsNullOrEmpty(u.depart) ? "" : string.Format("{0} | ", u.depart))공정거래업무경력 : @(u.kfcfyear)년</li>
|
|
<li>교육이력 : @u.edusname</li>
|
|
</ul>
|
|
</div>
|
|
}
|
|
@if (Model.Pay.isdvr == 1)
|
|
{
|
|
<h4 class="bskTitle">배송지 정보</h4>
|
|
<table class="odrTable">
|
|
@if (Model.Pay.isdvr2 == 1)
|
|
{
|
|
<tr><th>이름</th><td>@Model.Pay.rcvname</td></tr>
|
|
<tr><th>연락처</th><td>@Model.Pay.mobile</td></tr>
|
|
<tr><th>이메일</th><td>@Model.Pay.email</td></tr>
|
|
}
|
|
<tr><th>배송방식</th><td><a href="#" onclick="viewdvr(@(Model.Pay.isdvr2), '@(Model.Pay.dvrcode??"")')">@(Model.Pay.isdvr2 == 1 ? "택배" : "방문수령") <span>(@(string.IsNullOrEmpty(Model.Pay.dvrcode) ? Model.Pay.isdvr2==1 ? "배송대기중" : "미수령" : Model.Pay.isdvr2 == 1 ? "배송완료" : "수령완료"))</span></a></td></tr>
|
|
@if (Model.Pay.isdvr2 == 1)
|
|
{
|
|
<tr><th>주소</th><td>@Model.Pay.post @Model.Pay.address1 @Model.Pay.address2</td></tr>
|
|
}
|
|
</table>
|
|
}
|
|
<h4 class="bskTitle">결제 정보</h4>
|
|
<table class="odrTable">
|
|
<tr><th>구매금액</th><td>@Model.Pay.payamt.ToString("#,0")원</td></tr>
|
|
<tr><th>지불방법</th><td>@Model.Pay.ptypename</td></tr>
|
|
@if (Model.Pay.ptype == 3)
|
|
{
|
|
<tr><th>입금계좌</th><td><span>@Model.Pay.vactbankname | @Model.Pay.vactnum | @Model.Pay.vactname</span></td></tr>
|
|
}
|
|
<tr>
|
|
<th>주문접수일</th>
|
|
<td>@Model.Pay.cdt.ToString("yyyy-MM-dd HH:mm") @(Model.Pay.ptype == 3 ? string.Format("(만료일 : {0})", (Model.Pay.ispg == 0 ? "-" : Model.Pay.paylimit.Value.ToString("yyyy-MM-dd HH:mm"))) : "")</td>
|
|
</tr>
|
|
<tr>
|
|
<th>주문상태</th>
|
|
<td><b>@Model.Pay.pstatusname</b> @Html.Raw(Model.Pay.ispg == 1 && Model.Pay.rstatus == 0 && Model.Pay.pstatus == 1 && Model.Pay.ptype == 1 ? "<a href=\"#\" onclick=\"viewtax()\" class=\"odrRcpt\">영수증 출력</a>" : "")</td>
|
|
</tr>
|
|
@if (Model.intval3 > 0)
|
|
{
|
|
<tr>
|
|
<th>환불상태</th>
|
|
<td><b>환불요청 중</b></td>
|
|
</tr>
|
|
}
|
|
</table>
|
|
|
|
<ul class="bskBtn col1">
|
|
<li><a href="/My/Paies" class="bk">결제현황 이동</a></li>
|
|
@if (Model.Pay.ispg == 1 && Model.Pay.rstatus == 0 && Model.Pay.pstatus == 1 && Model.Pay.ptype == 1)
|
|
{
|
|
<li><a href="#" onclick="calltax()" class="bk">계산서요청</a></li>
|
|
}
|
|
else
|
|
{
|
|
<li><a href="#" onclick="calltax()" class="bk">계산서요청</a></li>
|
|
}
|
|
@if (Model.Pay.pstatus == 1 && Model.Pay.rstatus != 2 && Model.PayItems.Where(w => w.rstatus == 0).Count() > 0 )
|
|
{
|
|
<li><a href="#" onclick="refund()" class="bk">환불요청</a></li>
|
|
}
|
|
@if (Model.Pay.rstatus < 2 && Model.Pay.pstatus == 22)
|
|
{
|
|
<li><a href="#" onclick="cancelpay()" class="bk">결제취소</a></li>
|
|
}
|
|
</ul>
|
|
|
|
<div class="mpgPop mpgPopFull" style="display:none;" id="pop1">
|
|
<div>
|
|
<div>
|
|
<div class="mpgPopWrap wdth650">
|
|
<div class="mpgPopTitle"><h5>계산서발행요청</h5><a href="#" onclick="javascript:mpgPopClose();"></a></div>
|
|
<div class="mpgPopScroll">
|
|
<div class="odrPop pop1box">
|
|
<h4 class="bskTitle">상품선택</h4>
|
|
<table class="odrTable th150">
|
|
<tr><th>총결제액/입금일</th><td>@(Model.Pay.payamt.ToString("#,0"))원 (@(Model.Pay.payoktime == null ? "" : Model.Pay.payoktime.Value.ToString("yy-MM-dd HH:mm")))</td></tr>
|
|
<tr id="trcall"><th>기존요청금액</th><td id="precalltaxamt">0원</td></tr>
|
|
<tr><th>기존발행금액</th><td id="pretaxamt">0원</td></tr>
|
|
<tr><th>결제방법</th><td>@Model.Pay.ptypename (@(Model.Pay.ispg == 1 ? "PG" : "현장결제"))</td></tr>
|
|
<tr>
|
|
<th>상품선택</th>
|
|
<td>
|
|
<ul class="odrChk" id="pibox"></ul>
|
|
</td>
|
|
</tr>
|
|
<tr>
|
|
<th>발행요청금액</th>
|
|
<td id="taxamt">0원</td>
|
|
</tr>
|
|
</table>
|
|
<form id="mform" method="post" enctype="multipart/form-data">
|
|
<input type="hidden" name="pinos" id="pinos" />
|
|
<input type="hidden" name="payno" value="@Model.Pay.payno" />
|
|
<h4 class="bskTitle">발행업체 정보</h4>
|
|
<table class="odrTable th150">
|
|
<tr class="pd5"><th>회사명</th><td><input type="text" name="asname" id="asname" value="" /></td></tr>
|
|
<tr class="pd5">
|
|
<th>대표자</th>
|
|
<td><input type="text" name="ceoname" id="ceoname" value="" /></td>
|
|
</tr>
|
|
<tr class="pd5">
|
|
<th>사업자등록번호</th>
|
|
<td><input type="text" name="brno" id="brno" value="" maxlength="12" /></td>
|
|
</tr>
|
|
<tr class="pd5">
|
|
<th>법인등록번호</th>
|
|
<td><input type="text" name="grno" id="grno" value="" maxlength="14" /></td>
|
|
</tr>
|
|
<tr class="pd5">
|
|
<th>업태</th>
|
|
<td><input type="text" name="btype" id="btype" value="" /></td>
|
|
</tr>
|
|
<tr class="pd5">
|
|
<th>종목</th>
|
|
<td><input type="text" name="bkind" id="bkind" value="" /></td>
|
|
</tr>
|
|
<tr class="pd5">
|
|
<th>담당자</th>
|
|
<td><input type="text" name="manname" id="manname" value="" /></td>
|
|
</tr>
|
|
<tr class="pd5">
|
|
<th>연락처</th>
|
|
<td><input type="text" name="telno" id="telno" value="" /></td>
|
|
</tr>
|
|
<tr class="pd5">
|
|
<th>이메일주소</th>
|
|
<td><input type="text" name="email" id="email" value="" /></td>
|
|
</tr>
|
|
<tr class="pd5">
|
|
<th>사업장주소</th>
|
|
<td><input type="text" name="asaddr" id="" value="" /></td>
|
|
</tr>
|
|
<tr class="pd5">
|
|
<th>사업자등록증첨부</th>
|
|
<td><input type="file" name="file1" id="file1" value="" /></td>
|
|
</tr>
|
|
<tr>
|
|
<th>영수구분</th>
|
|
<td>
|
|
<input type="hidden" name="isreceipt" id="isreceipt" />
|
|
<ul class="rcptRadio">
|
|
<li><input type="radio" name="isreceipts" id="isreceipt1" checked="checked" /><label for="isreceipt1">영수</label></li>
|
|
<li><input type="radio" name="isreceipts" id="isreceipt0" /><label for="isreceipts0">청구</label></li>
|
|
</ul>
|
|
</td>
|
|
</tr>
|
|
<tr class="pd5">
|
|
<th>기재사항</th>
|
|
<td><input type="text" name="taxinfo" id="taxinfo" value="" /></td>
|
|
</tr>
|
|
</table>
|
|
</form>
|
|
<ul class="odrPopBtn col1">
|
|
<li><a href="#" onclick="save()" class="bk">계산서 발행요청</a></li>
|
|
</ul>
|
|
</div><!-- clsPopCont -->
|
|
</div>
|
|
</div><!-- clsPopWrap -->
|
|
</div>
|
|
</div>
|
|
</div>
|
|
<div class="mpgPop mpgPopFull" style="display:none;" id="pop2">
|
|
<div>
|
|
<div>
|
|
<div class="mpgPopWrap wdth750">
|
|
<div class="mpgPopTitle">
|
|
<h5>취소/환불요청</h5>
|
|
<a href="javascript:mpgPopClose();"></a>
|
|
</div>
|
|
<div class="mpgPopScroll">
|
|
<div class="odrPop pop1box">
|
|
<h4 class="bskTitle">상품선택</h4>
|
|
<table class="odrTable th150">
|
|
<tr><th>총결제액/입금일</th><td>@(Model.Pay.payamt.ToString("#,0"))원 (@(Model.Pay.payoktime == null ? "" : Model.Pay.payoktime.Value.ToString("yy-MM-dd HH:mm")))</td></tr>
|
|
<tr><th>기존환불금액</th><td id="prerefundamt">0원</td></tr>
|
|
<tr><th>결제방법</th><td>@Model.Pay.ptypename (@(Model.Pay.ispg == 1 ? "PG" : "현장결제"))</td></tr>
|
|
<tr><th>상품선택</th><td><ul class="odrChk" id="pibox2"></ul></td></tr>
|
|
<tr><th>환불요청금액</th><td id="refundamt">0원</td></tr>
|
|
</table>
|
|
<form id="mform2" method="post">
|
|
<input type="hidden" name="pinos" id="pinos2" />
|
|
<input type="hidden" name="payno" id="payno"value="@Model.Pay.payno" />
|
|
<input type="hidden" name="ptype" id="ptype" value="@Model.Pay.ptype" />
|
|
<h4 class="bskTitle">환불정보</h4>
|
|
<table class="odrTable th150">
|
|
<tr class="pd5" style="@(Model.Pay.ptype == 1 ? "display:none;":"")">
|
|
<th>환불은행</th>
|
|
<td><input type="text" name="bankname" id="bankname" maxlength="30" value="" /></td>
|
|
</tr>
|
|
<tr class="pd5" style="@(Model.Pay.ptype == 1 ? "display:none;":"")">
|
|
<th>예금주</th>
|
|
<td><input type="text" name="bankowner" id="bankowner" maxlength="30" /></td>
|
|
</tr>
|
|
<tr class="pd5" style="@(Model.Pay.ptype == 1 ? "display:none;":"")">
|
|
<th>환불계좌</th>
|
|
<td><input type="text" name="bankno" id="bankno" maxlength="30" value="" /></td>
|
|
</tr>
|
|
<tr style="@(Model.Pay.ptype == 1 ? "display:none;":"")">
|
|
<th>개인계좌여부</th>
|
|
<td>
|
|
<input type="hidden" name="isowner" id="isowner" />
|
|
<ul class="bakRadio">
|
|
<li><input type="radio" name="isowners" id="isowner1" /><label for="isowner1">예</label></li>
|
|
<li><input type="radio" name="isowners" id="isowner0" /><label for="isowner0">아니오</label></li>
|
|
</ul>
|
|
</td>
|
|
</tr>
|
|
<tr class="pd5">
|
|
<th>환불요청사유</th>
|
|
<td><input type="text" name="rtext" id="rtext" value="" /></td>
|
|
</tr>
|
|
<tr>
|
|
<th>환불규정</th>
|
|
<td>
|
|
<div class="odrRfnd">
|
|
<span>펼치기</span>
|
|
<div>평생교육법 제28조 제4항에 따른 학습비의 반환사유가 발생할 때에는 평생교육시행령 23조의 별표 3의 반환기준에 따라 학습 비 등을 반환사유가 발생한 날부터 5일 이내에 반환하여야 한다.</div>
|
|
</div>
|
|
</td>
|
|
</tr>
|
|
</table>
|
|
</form>
|
|
<p class="odrpDesc">※ 단체신청한 강좌일 경우, 신청을 취소하려는 교육생을 추가로 명시해주셔야 합니다.</p>
|
|
<ul class="odrChk"><li><input type="checkbox" id="chkrefund" /><label for="chkrefund">영남건설기술교육원 환불규정에 동의하고 수강취소 및 환불을 요청합니다.</label></li></ul>
|
|
<ul class="odrPopBtn col2">
|
|
<li><a href="#" class="bk" onclick="save2()">환불요청</a></li>
|
|
<li><a href="#" onclick="mpgPopClose()">취소</a></li>
|
|
</ul>
|
|
</div><!-- clsPopCont -->
|
|
</div>
|
|
</div><!-- clsPopWrap -->
|
|
</div>
|
|
</div>
|
|
</div>
|
|
@section scriptsHeader{
|
|
|
|
}
|
|
@section scripts{
|
|
<script>
|
|
$(document).ready(function () {
|
|
$("#pibox").on("change", "input.pi", function () {
|
|
var tamt = 0;
|
|
$.each($("#pibox input.pi:checked"), function (i, c) {
|
|
tamt += getint($(c).val());
|
|
});
|
|
sett("taxamt", commaset(tamt) + "원");
|
|
});
|
|
$("#pibox2").on("change", "input.pi", function () {
|
|
var tamt = 0;
|
|
$.each($("#pibox2 input.pi:checked"), function (i, c) {
|
|
tamt += getint($(c).val());
|
|
});
|
|
sett("refundamt", commaset(tamt) + "원");
|
|
});
|
|
$('.odrRfnd > span').click(function () {
|
|
if ($(this).is('.on')) {
|
|
$(this).removeClass('on');
|
|
$(this).text('펼치기');
|
|
$(this).next().slideUp();
|
|
} else {
|
|
$(this).addClass('on');
|
|
$(this).text('접기');
|
|
$(this).next().slideDown();
|
|
}
|
|
});
|
|
});
|
|
function viewdvr(isdvr, dvrcode) {
|
|
if (isdvr == 1 && dvrcode != '') {
|
|
window.open("https://www.ilogen.com/web/personal/trace/" + dvrcode);
|
|
}
|
|
else if (isdvr == 0 && dvrcode == '') {
|
|
msg("수령위치: 경북 영천시 고경면 호국로 791 영남건설기술교육원");
|
|
}
|
|
}
|
|
function viewtax() {
|
|
window.open("https://iniweb.inicis.com/DefaultWebApp/mall/cr/cm/mCmReceipt_head.jsp?noTid=@(Model.Pay.pgkey)&noMethod=1", "pgreceipt", "width=500, height=600, scrollbars=yes, resizable=yes, status=no, location=no, left=0, top=0");
|
|
}
|
|
function calltax() {
|
|
if ('@(Model.Pay.rstatus < 2 && Model.Pay.pstatus == 1 || Model.Pay.pstatus == 22?1:0)' == '1') {
|
|
$("#pibox").html("");
|
|
sett("taxamt", "0원");
|
|
capp("/fcommon/paytaxget", { payno: @Model.Pay.payno}, "cbpaytaxget");
|
|
} else {
|
|
msg("결제완료내역만 계산서요청하실 수 있습니다.");
|
|
}
|
|
}
|
|
function cbpaytaxget() {
|
|
var h = capResult.obj.h;
|
|
var d = capResult.obj.d;
|
|
if (h != null && d.length > 0) {
|
|
setv("asname", h.asname);
|
|
setv("ceoname", h.ceoname);
|
|
setv("brno", h.brno);
|
|
setv("grno", h.grno);
|
|
setv("btype", h.btype);
|
|
setv("bkind", h.bkind);
|
|
setv("manname", h.manname);
|
|
setv("telno", h.telno);
|
|
setv("email", h.email);
|
|
$("#trcall").hide();
|
|
if (h.taxamt != h.taxamtsum) {
|
|
$("#trcall").show();
|
|
}
|
|
sett("precalltaxamt", commaset(h.taxamt) + "원");
|
|
sett("pretaxamt", commaset(h.taxamtsum) + "원");
|
|
if (h.isgroup == 1) {
|
|
var itemname = "";
|
|
var isget = false;
|
|
var pcnt = 0;
|
|
var pamt = 0;
|
|
var pinos = "";
|
|
$.each(d, function (i, pi) {
|
|
if (pi.taxno < 1 && pi.ptype == 0 && pi.rstatus == 0) {
|
|
//단체결제는 결제완료강좌 하나로 묶어서 하나로 출력
|
|
pcnt++;
|
|
pamt += getint(pi.payamt);
|
|
pinos += "," + pi.pino;
|
|
if (!isget) {
|
|
itemname = pi.itemname
|
|
}
|
|
}
|
|
});
|
|
if (pcnt > 0) {
|
|
$("#pibox").append("<li><input type=\"checkbox\" class=\"pi\" id=\"pi0\" value=\"" + pamt + "\" data-pino=\"" + pinos.substr(1)+"\" /><label for=\"pi0\">[강좌]" + itemname + "(" + pcnt + "명, " + commaset(pamt) + "원)</label></li>");
|
|
}
|
|
//교재 또는 기발행요청 건
|
|
$.each(d, function (i, pi) {
|
|
if (pi.ptype != 0) {
|
|
$("#pibox").append("<li><input type=\"checkbox\" " + (pi.taxno < 1 && pi.rstatus == 0 ? "" : "disabled") + " class=\"pi\" id=\"pi" + pi.pino + "\" value=\"" + pi.payamt + "\" data-pino=\"" + pi.pino +"\" /><label for=\"pi" + pi.pino + "\">" + (pi.ptype == 2 ? "[교재]" : pi.ptype == 3 ? "[시험]" : "[강좌]") +pi.itemname + "(" + pi.pcnt + (pi.ptype == 2 ? "개" : "명") + ", " + commaset(pi.payamt) + "원)</label></li>");
|
|
}
|
|
});
|
|
} else {
|
|
$.each(d, function (i, pi) {
|
|
$("#pibox").append("<li><input type=\"checkbox\" " + (pi.taxno < 1 && pi.rstatus == 0 ? "" : "disabled") + " class=\"pi\" id=\"pi" + pi.pino + "\" value=\"" + pi.payamt + "\" data-pino=\"" + pi.pino +"\" /><label for=\"pi" + pi.pino + "\">" + (pi.ptype == 2 ? "[교재]" : pi.ptype == 3 ? "[시험]" : "[강좌]") + pi.itemname + "(" + pi.pcnt + (pi.ptype == 2 ? "개" : "명") + ", " + commaset(pi.payamt) + "원)</label></li>");
|
|
});
|
|
}
|
|
$('html, body').addClass('lock');
|
|
$("#pop1").fadeIn("fast", function () {
|
|
$(".pop1box").scrollTop(0);
|
|
});
|
|
} else {
|
|
msg("이미 계산서를 접수중이거나 환불된 결제건입니다.");
|
|
}
|
|
}
|
|
function save() {
|
|
if ($("#pibox input.pi:checked").length < 1) { msg("요청할 결제상품을 선택해주세요."); }
|
|
else if (check("asname", null, "회사명을 입력해주세요.")) { }
|
|
else if (check("ceoname", null, "대표자명을 입력해주세요.")) { }
|
|
else if (check("brno", null, "사업자등록번호를 입력해주세요.")) { }
|
|
else if (check("grno", null, "법인등록번호를 입력해주세요.")) { }
|
|
else if (check("btype", null, "업태를 입력해주세요.")) { }
|
|
else if (check("bkind", null, "종목을 입력해주세요.")) { }
|
|
else if (check("manname", null, "담당자를 입력해주세요.")) { }
|
|
else if (check("telno", null, "연락처를 입력해주세요.")) { }
|
|
else if (check("email", null, "이메일주소를 입력해주세요.")) { }
|
|
else if (!isemail(val("email"))) { msg("이메일 형식이 올바르지 않습니다. 다시 입력해주세요."); }
|
|
else {
|
|
setv("isreceipt", $("#isreceipt1").prop("checked") ? 1 : 0);
|
|
confirmtoggle(true, "계산서발행요청 이후, 수정 및 철회는 고객문의 게시판을 이용해주십시오. 계산서 발행 요청을 완료하시겠습니까?", "gogo()");
|
|
}
|
|
}
|
|
function gogo() {
|
|
var pinos = "";
|
|
$.each($("#pibox input.pi:checked"), function (i, c) {
|
|
pinos += "," + $(c).attr("data-pino");
|
|
});
|
|
setv("pinos", pinos.substr(1));
|
|
capfileform('/fcommon/paytaxsave','mform', 'cbgogo');
|
|
}
|
|
//function cbgogo() {
|
|
// if (capResult.code == 1000) {
|
|
// msg("접수되었습니다.", null, null, null, "mpgPopClose()");
|
|
// } else {
|
|
// msgadmin();
|
|
// }
|
|
//}
|
|
function cbgogo() {
|
|
if (capResult.code == 1000) {
|
|
msg("접수되었습니다.");
|
|
setTimeout(function () {
|
|
$("#mform").attr("action", "/My/Paies").submit()
|
|
}, 1000);
|
|
} else if(capResult.code == -1) {
|
|
msg("이미 신청된 계산서가 존재합니다.");
|
|
}
|
|
}
|
|
function refund() {
|
|
if (@Model.intval3 > 0) {
|
|
msg("접수중입니다.");
|
|
} else if ('@(Model.Pay.rstatus < 2 && Model.Pay.pstatus == 1?1:0)' == '1') {
|
|
$("#pibox2").html("");
|
|
sett("prerefundamt", "0원");
|
|
capp("/fcommon/payrefundget", { payno: @Model.Pay.payno}, "cbpayrefundget");
|
|
} else {
|
|
msg("결제완료내역만 계산서요청하실 수 있습니다.");
|
|
}
|
|
}
|
|
function cbpayrefundget() {
|
|
var h = capResult.obj.h;
|
|
var d = capResult.obj.d;
|
|
if (h != null && h.pstatus == 1 && d.length > 0) {
|
|
sett("prerefundamt", commaset(h.refundamt) + "원");
|
|
$.each(d, function (i, pi) {
|
|
$("#pibox2").append("<li><input type=\"checkbox\" " + ((pi.rfdno < 1 || pi.rfdrstatus < 0) && pi.ispast < 1 && pi.rstatus < 1 && pi.pstatus == 1 ? "" : "disabled") +
|
|
" class=\"pi\" id=\"pi" + pi.pino + "\" value=\"" + pi.payamt + "\" data-pino=\"" + pi.pino + "\" /><label for=\"pi" + pi.pino + "\">" +
|
|
(pi.rstatus > 0 ? "[완료]" : pi.rfdrstatus == 0 ? "[요청]" : pi.rfdrstatus == -1 ? "[반려]" : pi.rfdrstatus == 2 ? "[환불]" : pi.ispast > 0 ? "[종료]" :"[정상]")+(pi.ptype == 2 ? "[교재]" : pi.ptype == 3 ? "[시험]" : "[강좌]") + pi.itemname + "(" + (pi.ptype == 2 || h.isgroup == 0 ? (pi.pcnt + "개") : pi.username) + ", " +
|
|
commaset(pi.payamt) + "원)</label></li>");
|
|
});
|
|
$('html, body').addClass('lock');
|
|
$("#pop2").fadeIn("fast", function () {
|
|
$(".pop1box").scrollTop(0);
|
|
});
|
|
} else {
|
|
msg("이미 전액환불된 결제내역입니다. 운영자에게 문의해주세요.");
|
|
}
|
|
}
|
|
function save2() {
|
|
if ($("#pibox2 input.pi:checked").length < 1) { msg("환불요청할 결제상품을 선택해주세요."); }
|
|
else if ('@(Model.Pay.ptype)' != '1' && check("bankname", null, "환불은행명을 입력해주세요.")) { }
|
|
else if ('@(Model.Pay.ptype)' != '1' && check("bankowner", null, "예금주를 입력해주세요.")) { }
|
|
else if ('@(Model.Pay.ptype)' != '1' && check("bankno", null, "환불계좌번호를 입력해주세요.")) { }
|
|
else if ('@(Model.Pay.ptype)' != '1' && $("input[name='isowners']:checked").length < 1) { msg("개인계좌여부를 선택해주세요."); }
|
|
else if (check("rtext", null, "환불요청사유를 입력해주세요.")) { }
|
|
else if ($("#chkrefund:checked").length < 1) { msg("환불규정에 동의 후 요청해주세요."); }
|
|
else {
|
|
setv("isowner", $("#isowner1").prop("checked") ? 1 : 0);
|
|
confirmtoggle(true, "환불요청하시겠습니까?", "gogo2()");
|
|
}
|
|
}
|
|
function gogo2() {
|
|
var pinos = "";
|
|
$.each($("#pibox2 input.pi:checked"), function (i, c) {
|
|
pinos += "," + $(c).attr("data-pino");
|
|
});
|
|
setv("pinos2", pinos.substr(1));
|
|
capfileform('/fcommon/payrfdsave', 'mform2', 'cbgogo2');
|
|
}
|
|
function cbgogo2() {
|
|
if (capResult.code == 1000) {
|
|
msg("환불요청이 성공적으로 접수되었습니다.<br />내부 담당자가 검토 후 연락드릴 예정입니다.", null, null, null, "mpgPopClose();refresh();");
|
|
} else {
|
|
msg("환불신청이 불가한 결제상품입니다. 운영자에게 문의해주세요.");
|
|
}
|
|
}
|
|
function cancelpay() {
|
|
confirmtoggle(true, "결제취소는 동일결제 건 모두 취소됩니다.<br />수강신청을 취소하시겠습니까?", "gocancel()");
|
|
}
|
|
function gocancel() {
|
|
capp("/fcommon/paycancel", { payno: @Model.Pay.payno}, "cbgogo");
|
|
}
|
|
</script>
|
|
} |