7111. 회원탈퇴 관리 기능추가
This commit is contained in:
parent
4fb54561ba
commit
381f37eccd
|
|
@ -105,6 +105,7 @@ namespace NP.BO.Controllers
|
|||
public ActionResult adminreg(NP.Model.VMUser vm) { return ur(vm); }
|
||||
public ActionResult ur(VMUser vm)
|
||||
{
|
||||
var p = new Hashtable();
|
||||
|
||||
vm.User = new Users() { status = 1, usertype = vm.viewname == "user" ? 1 : vm.viewname == "professor" ? 11 : 0 };
|
||||
vm.Lects = new List<Lect>() { };
|
||||
|
|
@ -116,7 +117,10 @@ namespace NP.BO.Controllers
|
|||
|
||||
if (vm.intval > 0)
|
||||
{
|
||||
vm.User = Dao.Get<Users>("users.users", new System.Collections.Hashtable() { { "userno", vm.intval } , { "includesysadmin", 1 } }).First();
|
||||
p.Clear();
|
||||
p.Add("userno", vm.intval);
|
||||
p.Add("includesysadmin", 1);
|
||||
vm.User = Dao.Get<Users>("users.users", p).First();
|
||||
|
||||
vm.Councel = new Councel() { };
|
||||
vm.Councels = Dao.Get<Councel>("users.councels", new System.Collections.Hashtable() { { "userno", vm.intval } });
|
||||
|
|
|
|||
|
|
@ -25,7 +25,7 @@
|
|||
<a href="/aCommon/DownFile?fno=@f.fileno&loginfo=@(_loginfo)" title="다운로드"><i class="fa fa-paperclip"></i> <span class="fileitem">@f.orgname</span></a>
|
||||
@if (_readmode == 0)
|
||||
{
|
||||
<a href="#" class="btn_txt btn btn-xxs btn-danger" onclick="javascript:fnFileDeleteNew(@f.fileno, this, '@_loginfo');" title="삭제">삭제</a>
|
||||
<a href="javascript:;" class="btn_txt btn btn-xxs btn-danger" onclick="javascript:fnFileDeleteNew(@f.fileno, this, '@_loginfo');" title="삭제">삭제</a>
|
||||
}
|
||||
</div>
|
||||
}
|
||||
|
|
@ -33,7 +33,10 @@
|
|||
@if (_hidemode == 1 || _filecount == 0 || _filecount >= md.Count())
|
||||
{
|
||||
<div class="file_search_area" style="@_hidden">
|
||||
<a href="#" class="btn_file_search">첨부파일 찾기</a><input type="text" class="file_input_textbox clearfiletemp" readonly="" style="width: @_width;" /><input type="file" class="file_input_opacity clearfiletemp" name="@_fname" data-empty="1" /><a href="#" class="btn_file_clear" style="border: 1px solid #ddd; padding: 2px 10px; background-color: #999; color: #fff !important;">삭제</a>
|
||||
<a href="javascript:;" class="btn_file_search">첨부파일 찾기</a>
|
||||
<input type="text" class="file_input_textbox clearfiletemp" readonly="" style="width: @_width;" />
|
||||
<input type="file" class="file_input_opacity clearfiletemp" name="@_fname" data-empty="1" />
|
||||
<a href="javascript:;" class="btn_file_clear" style="border: 1px solid #ddd; padding: 2px 10px; background-color: #999; color: #fff !important;">삭제</a>
|
||||
</div>
|
||||
}
|
||||
</div>
|
||||
|
|
@ -12,8 +12,7 @@
|
|||
@Html.Partial("./Partial/Select", null, new ViewDataDictionary { { "valuetext", ":-모사;9950:100%" }, { "name", "addstringval4" }, { "selected", Model.addstringval4 }, { "onchange", "findme()" }, { "style", "vertical-align: middle;" } })
|
||||
|
||||
@Html.Partial("./Partial/pagerow", new ViewDataDictionary { { "tbodyid", "tbody1" }, { "searchmethod", "submit()" }, { "pagesize", Model.pagerowcount } })
|
||||
@*<a href="#" onclick="javascript:exceldown('mform', '/croom/gradeall', 'tbody1', '성적처리과제');" class="btn btn-s-xs btn-success" style="margin-left: 5px; float:right;">엑셀다운로드</a>*@
|
||||
<a href="#" onclick="javascript:callComment('mform', '/croom/gradeall', 'tbody1', '성적처리과제');" class="btn btn-s-xs btn-success" style="margin-left: 5px; float:right;">엑셀다운로드</a>
|
||||
<a href="javascript:;" onclick="javascript:callComment('mform', '/croom/gradeall', 'tbody1', '성적처리과제');" class="btn btn-s-xs btn-success" style="margin-left: 5px; float:right;">엑셀다운로드</a>
|
||||
@Html.Partial("./Partial/sembtns", "#tbody1;" + (Model.IsAdmin ? "1;11;" : "0;0;0") + ";1;right;평가안내")
|
||||
</div>
|
||||
<div class="table-responsive" id="excel1">
|
||||
|
|
@ -63,7 +62,7 @@
|
|||
{
|
||||
if (d.iscomplete != 1)
|
||||
{
|
||||
<td class="link text-center"><a href="#" onclick="javascript: openScd(@d.cmno,@d.lectno,@d.cmisno);">@d.leend.ToShortDateString()</a></td>
|
||||
<td class="link text-center"><a href="javascript:;" onclick="javascript: openScd(@d.cmno,@d.lectno,@d.cmisno);">@d.leend.ToShortDateString()</a></td>
|
||||
}
|
||||
else
|
||||
{
|
||||
|
|
@ -75,9 +74,13 @@
|
|||
<td>@d.edate.Value.ToShortDateString()</td>
|
||||
}
|
||||
<td class="estate@(d.sdstate)">@d.sdstatename</td>
|
||||
<td><a class="btn btn-xxs btn-select" onclick="viewsd(@d.sdno, @d.lectno,@d.tpoint, @(idx++))" href="#">@d.cpoint2</a></td>
|
||||
<td>
|
||||
<a class="btn btn-xxs btn-select" onclick="viewsd(@d.sdno, @d.lectno,@d.tpoint, @(idx++))" href="javascript:;">@d.cpoint2</a>
|
||||
</td>
|
||||
<td>@d.feedbox</td>
|
||||
<td><a class="btn btn-xxs btn-select iscopy@(d.iscopy)" onclick="viewcopy(@d.sdno, @d.lectno, @string.Format("{0:yyyyMMdd}", d.submittime))" href="#">@d.copyratename</a></td>
|
||||
<td>
|
||||
<a class="btn btn-xxs btn-select iscopy@(d.iscopy)" onclick="viewcopy(@d.sdno, @d.lectno, @string.Format("{0:yyyyMMdd}", d.submittime))" href="javascript:;">@d.copyratename</a>
|
||||
</td>
|
||||
<td>@Html.Raw(d.submittimeip)</td>
|
||||
<td>@Html.Raw(d.checktimeip)</td>
|
||||
@if (!ViewBag.IsSubAdmin96)
|
||||
|
|
@ -98,15 +101,17 @@
|
|||
</form>
|
||||
@Html.Partial("./Partial/ExcelCommentBox")
|
||||
<div id="scdbox" class="findbox draggable regbox" style="width: 400px; 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>
|
||||
<h4><i class="fa fa-bars"></i> <span id="pcap">교육일정변경</span><a href="javascript:;" class="btn btn-default btn-xs f-r closethisbox">닫기</a></h4>
|
||||
<ul id="ulScd"></ul>
|
||||
<div class="findboxbtnbox" id="btnsavelect">
|
||||
<a href="#" class="btn btn-primary" onclick="updateScd();">선택완료</a>
|
||||
<a href="javascript:;" class="btn btn-primary" onclick="updateScd();">선택완료</a>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- 과제제출 -->
|
||||
<div id="thisbox" class="findbox draggable regbox" style="height: 850px; width: 800px; z-index: 1041; top: 60px; overflow: auto;">
|
||||
<form id="mform2" enctype="multipart/form-data">
|
||||
<h4><i class="fa fa-bars"></i> <span id="pcap">개별 과제제출 내용</span><a href="#" class="btn btn-default btn-xs f-r closethisbox">닫기</a></h4>@*PMS 6987관련 페이지*@
|
||||
<h4><i class="fa fa-bars"></i> <span id="pcap">개별 과제제출 내용</span><a href="javascript:;" class="btn btn-default btn-xs f-r closethisbox">닫기</a></h4>
|
||||
<br />
|
||||
<table class="regtable" id="exsummary">
|
||||
<tr>
|
||||
|
|
@ -146,12 +151,13 @@
|
|||
</table>
|
||||
<br /><br /><br />
|
||||
<div class="text-center">
|
||||
<a href="#" id="btnpre" class="btn btn-info btn-xs" onclick="save(-1)">◀이전</a>
|
||||
<a href="#" class="btn btn-primary btn-xs" onclick="save(0)">저장</a>
|
||||
<a href="#" id="btnnext" class="btn btn-info btn-xs" onclick="save(1)">다음▶</a>
|
||||
<a href="#" class="btn btn-default btn-xs closethisbox">닫기</a>
|
||||
<a href="javascript:;" id="btnpre" class="btn btn-info btn-xs" onclick="save(-1)">◀이전</a>
|
||||
<a href="javascript:;" class="btn btn-primary btn-xs" onclick="save(0)">저장</a>
|
||||
<a href="javascript:;" id="btnnext" class="btn btn-info btn-xs" onclick="save(1)">다음▶</a>
|
||||
<a href="javascript:;" class="btn btn-default btn-xs closethisbox">닫기</a>
|
||||
</div>
|
||||
<br /><br />
|
||||
<div id="hdnmform2Area">
|
||||
<input type="hidden" id="sdno" name="sdno" value="">
|
||||
<input type="hidden" id="lectno" name="lectno" value="">
|
||||
<input type="hidden" id="tpoint" name="tpoint" value="">
|
||||
|
|
@ -159,8 +165,10 @@
|
|||
<input type="hidden" id="iscopyVal" name="iscopy" value="">
|
||||
<input type="hidden" id="cmno" name="cmno" value="">
|
||||
<input type="hidden" id="userno" name="userno" value="">
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
<!-- // 과제제출 -->
|
||||
<style type="text/css">
|
||||
td.estate0 {
|
||||
background-color: #ffd7bb !important;
|
||||
|
|
@ -214,7 +222,6 @@
|
|||
<script>
|
||||
var ischange = false;
|
||||
$(document).ready(function () {
|
||||
/* $("[name='pagerowcount']").css("vertical-align", "");*/
|
||||
$("body").on("click", "td.qi div.imgbox", function () {
|
||||
$(this).toggleClass("active");
|
||||
});
|
||||
|
|
@ -237,6 +244,7 @@
|
|||
capp("/acommon/lectallsds", { pagenum: @((int)Model.pagenum), pagerowcount:@(Model.pagerowcount), sdstate: valnull("addstringval2"), edate: valnull("stringval"), cshape: valnull("stringval2"), cname: valnull("stringval3"), cnamestr: valnull("stringval3"), iscomplete: valnull("stringval4"), studyplace: valnull("stringval5"), searchtype: valnull("stringval6"), searchtext: valnull("stringval7"), sdtype: 0, sdateall: valnull("stringval8"), edateall: valnull("stringval9"), asname: valnull("stringval10") }, "cblectsds");
|
||||
}
|
||||
}
|
||||
|
||||
function cblectsds() {
|
||||
var submittimeDateVal;
|
||||
var submittime = "";
|
||||
|
|
@ -248,6 +256,7 @@
|
|||
else {
|
||||
submittime = "";
|
||||
}
|
||||
|
||||
$("#tbody1").append(("<tr data-sdno=\"{8}\" data-lectno=\"{0}\" data-tpoint=\"{22}\">" +
|
||||
"<td><input type=\"checkbox\" class=\"autocheck\" value=\"{0}\" data-userno=\"{1}\" /></td>" +
|
||||
"<td>{2}</td>" +
|
||||
|
|
@ -279,7 +288,12 @@
|
|||
var _lectno = 0;
|
||||
var _tpoint = 0;
|
||||
var _ridx = 0;
|
||||
|
||||
// 과제제출 팝업
|
||||
function viewsd(sdno, lectno, tpoint, ridx) {
|
||||
// Hidden 영역 초기화
|
||||
$("#hdnmform2Area input[type='hidden']").val("");
|
||||
|
||||
ischange = false;
|
||||
_sdno = sdno;
|
||||
_lectno = lectno;
|
||||
|
|
@ -289,65 +303,153 @@
|
|||
$("#lectno").val(lectno);
|
||||
$("#tpoint").val(tpoint);
|
||||
$("#ridx").val(ridx);
|
||||
capp("/acommon/lectsd", { lectno: lectno, sdno: sdno }, "cblectsd");
|
||||
}
|
||||
function cblectsd() {
|
||||
var d = capResult.obj;
|
||||
$("#userinfo").text("[{0}]{1} | {2}".format(d.isrebatename, d.asname, d.usernameid));
|
||||
if (getdb(d.atext) == "") {
|
||||
$("#atext").html("- 미제출");
|
||||
} else {
|
||||
$("#atext").html(getdb(d.atext).replace(/\n/gi, "<br />"));
|
||||
}
|
||||
var _html = "- 제출파일 없음<br />";
|
||||
if (getdb(d.fileurl) != "") {
|
||||
_html = '<div id="file{0}div"><a href="/aCommon/DownFile?fno={0}&loginfo=&issubject=1" title="다운로드"><i class="fa fa-paperclip"></i> <span class="fileitem">{1}</span></a>'.format(d.fileno, d.orgname);
|
||||
_html += '<a href="#" style="color:red;margin-left:5px;cursor:point" onclick="fileDel(this)" data-fileno="{0}" data-filename="{1}">X</a>'.format(d.fileno, d.orgname);
|
||||
_html += '</div><br />'
|
||||
|
||||
$("#fileinfoDiv .fgno").val(d.fgno)
|
||||
$("#fileinfoDiv").css("display", "none")
|
||||
capp(
|
||||
"/acommon/lectsd",
|
||||
{
|
||||
lectno: lectno,
|
||||
sdno: sdno
|
||||
},
|
||||
"cblectsd");
|
||||
}
|
||||
else {
|
||||
$("#fileinfoDiv").css("display", "")
|
||||
|
||||
/** 과제제출 팝업 콜백 */
|
||||
function cblectsd() {
|
||||
const d = capResult.obj;
|
||||
|
||||
// 제출자 정보 설정
|
||||
$("#userinfo").text(`[${d.isrebatename}]${d.asname} | ${d.usernameid}`);
|
||||
|
||||
// 제출 내용 설정 (내용이 없으면 '미제출' 표시)
|
||||
const submissionText = getdb(d.atext);
|
||||
$("#atext").html(submissionText ? submissionText.replace(/\n/gi, "<br />") : "- 미제출");
|
||||
|
||||
// 첨부 파일 정보 및 모사율 설정
|
||||
let fileHtml;
|
||||
if (getdb(d.fileurl)) {
|
||||
// 파일이 있을 경우, 다운로드 링크 생성
|
||||
fileHtml = `
|
||||
<div id="file${d.fileno}div">
|
||||
<a href="/aCommon/DownFile?fno=${d.fileno}&loginfo=&issubject=1" title="다운로드">
|
||||
<i class="fa fa-paperclip"></i> <span class="fileitem">${d.orgname}</span>
|
||||
</a>
|
||||
<a href="javascript:;" style="color:red; margin-left:5px; cursor:point;" onclick="fileDel(this)" data-fileno="${d.fileno}" data-filename="${d.orgname}">X</a>
|
||||
</div>
|
||||
<br />`;
|
||||
|
||||
$("#fileinfoDiv .fgno").val(d.fgno);
|
||||
$("#fileinfoDiv").hide();
|
||||
} else {
|
||||
// 파일이 없을 경우
|
||||
fileHtml = "- 제출파일 없음<br />";
|
||||
$("#fileinfoDiv").show();
|
||||
}
|
||||
_html += "(모사율: {0}) ".format(d.copyratename);
|
||||
$("#fileinfo").html(_html + ("<label><input id=\"iscopy\" type=\"checkbox\" " + (d.iscopy == 1 ? "checked" : "") + " /> 모사답안신고</label>"));
|
||||
|
||||
// 모사율, 모사답안 신고 체크박스와 결합하여 최종 HTML 생성
|
||||
const isCopyChecked = d.iscopy === 1 ? "checked" : "";
|
||||
|
||||
const finalFileinfoHtml = `
|
||||
${fileHtml}
|
||||
(모사율: ${d.copyratename})
|
||||
<label>
|
||||
<input id="iscopy" type="checkbox" ${isCopyChecked} /> 모사답안신고
|
||||
</label>`;
|
||||
|
||||
$("#fileinfo").html(finalFileinfoHtml);
|
||||
|
||||
// 숨은 값 및 텍스트 입력 영역 설정
|
||||
setv("userno", d.userno);
|
||||
setv("cmno", d.cmno);
|
||||
setv("cpoint", d.cpoint);
|
||||
if (d.feedb != null) {
|
||||
$("#feedb").val(d.feedb);
|
||||
}
|
||||
else {
|
||||
$("#feedb").val("");
|
||||
}
|
||||
if (d.memo != null) {
|
||||
$("#memo").val(d.memo);
|
||||
}
|
||||
else {
|
||||
$("#memo").val("");
|
||||
}
|
||||
|
||||
// feedb, d.memo가 null이나 undefined이면 빈 문자열로 설정
|
||||
$("#feedb").val(d.feedb ?? "");
|
||||
$("#memo").val(d.memo ?? "");
|
||||
|
||||
$("#feedb").removeAttr("readonly");
|
||||
$("#tpoint").val(_tpoint);
|
||||
//if (getdb(d.feedb) != '') {
|
||||
// $("#feedb").attr("readonly", "readonly");
|
||||
//}
|
||||
|
||||
// 이전/다음 버튼 표시 로직
|
||||
$("#btnpre, #btnnext").show();
|
||||
if (_ridx == 1) {
|
||||
if (_ridx === 1) {
|
||||
$("#btnpre").hide();
|
||||
}
|
||||
if (_ridx == $("#tbody1 tr").length) {
|
||||
if (_ridx === $("#tbody1 tr").length) {
|
||||
$("#btnnext").hide();
|
||||
}
|
||||
|
||||
setTimeout(function () {
|
||||
bglayer(); $("#thisbox").slideDown("fast", function () { $("#thisbox").scrollTop(0); });
|
||||
// 레이어 표시
|
||||
setTimeout(() => {
|
||||
bglayer();
|
||||
$("#thisbox").slideDown("fast", function () {
|
||||
$(this).scrollTop(0);
|
||||
});
|
||||
bglayer2(false);
|
||||
$("#cpoint").focus();
|
||||
}, 10);
|
||||
}
|
||||
//function cblectsd() {
|
||||
|
||||
// var d = capResult.obj;
|
||||
// $("#userinfo").text("[{0}]{1} | {2}".format(d.isrebatename, d.asname, d.usernameid));
|
||||
// if (getdb(d.atext) == "") {
|
||||
// $("#atext").html("- 미제출");
|
||||
// } else {
|
||||
// $("#atext").html(getdb(d.atext).replace(/\n/gi, "<br />"));
|
||||
// }
|
||||
// var _html = "- 제출파일 없음<br />";
|
||||
// if (getdb(d.fileurl) != "") {
|
||||
// _html = '<div id="file{0}div"><a href="/aCommon/DownFile?fno={0}&loginfo=&issubject=1" title="다운로드"><i class="fa fa-paperclip"></i> <span class="fileitem">{1}</span></a>'.format(d.fileno, d.orgname);
|
||||
// _html += '<a href="javascript:;" style="color:red;margin-left:5px;cursor:point" onclick="fileDel(this)" data-fileno="{0}" data-filename="{1}">X</a>'.format(d.fileno, d.orgname);
|
||||
// _html += '</div><br />'
|
||||
|
||||
// $("#fileinfoDiv .fgno").val(d.fgno)
|
||||
// $("#fileinfoDiv").css("display", "none")
|
||||
// }
|
||||
// else {
|
||||
// $("#fileinfoDiv").css("display", "")
|
||||
// }
|
||||
// _html += "(모사율: {0}) ".format(d.copyratename);
|
||||
// $("#fileinfo").html(_html + ("<label><input id=\"iscopy\" type=\"checkbox\" " + (d.iscopy == 1 ? "checked" : "") + " /> 모사답안신고</label>"));
|
||||
// setv("userno", d.userno);
|
||||
// setv("cmno", d.cmno);
|
||||
// setv("cpoint", d.cpoint);
|
||||
|
||||
// if (d.feedb != null) {
|
||||
// $("#feedb").val(d.feedb);
|
||||
// }
|
||||
// else {
|
||||
// $("#feedb").val("");
|
||||
// }
|
||||
|
||||
// if (d.memo != null) {
|
||||
// $("#memo").val(d.memo);
|
||||
// }
|
||||
// else {
|
||||
// $("#memo").val("");
|
||||
// }
|
||||
|
||||
// $("#feedb").removeAttr("readonly");
|
||||
// $("#tpoint").val(_tpoint);
|
||||
|
||||
// $("#btnpre,#btnnext").show();
|
||||
// if (_ridx == 1) {
|
||||
// $("#btnpre").hide();
|
||||
// }
|
||||
// if (_ridx == $("#tbody1 tr").length) {
|
||||
// $("#btnnext").hide();
|
||||
// }
|
||||
|
||||
// setTimeout(function () {
|
||||
// bglayer();
|
||||
// $("#thisbox").slideDown("fast", function () { $("#thisbox").scrollTop(0); });
|
||||
// bglayer2(false);
|
||||
// $("#cpoint").focus();
|
||||
// }, 10);
|
||||
//}
|
||||
|
||||
|
||||
|
||||
var _saveidx = 0;
|
||||
function save(idx) {
|
||||
if (idx != 0 && ischange == false) {
|
||||
|
|
@ -363,27 +465,17 @@
|
|||
msg2(getint($("#tpoint").val()) + "점 이하으로 입력해주세요.");
|
||||
} else if (confirm("저장하시겠습니까?")) {
|
||||
_saveidx = idx;
|
||||
// capp("/acommon/lectsdsave", { lectno: _lectno, sdno: _sdno, iscopy: $("#iscopy").prop("checked") ? 1 : 0, cpoint: val("cpoint"), feedb: val("feedb"), memo: val("memo") }, "cbsave", null, null, null, true);
|
||||
$("#iscopyVal").val($("#iscopy").prop("checked") ? 1 : 0)
|
||||
capfileform("/acommon/LectSDSaveToAdmin", "mform2", "cbsave");
|
||||
capfileform(
|
||||
"/acommon/LectSDSaveToAdmin",
|
||||
"mform2",
|
||||
"cbsave");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
function cbsave() {
|
||||
if (capResult.code == 1000) {
|
||||
//if (_saveidx == 0) {
|
||||
// msg2("저장했습니다.");
|
||||
// viewsd(_sdno, _lectno, _tpoint, _ridx);
|
||||
// //submit("mform", 500);
|
||||
//} else {
|
||||
// //리스트 갱신 후 다음 또는 이전 수강생과제 표시
|
||||
// msg2("저장했습니다.", null, null, null, true);
|
||||
// setTimeout(function () {
|
||||
// hidelayermsg2(true);
|
||||
// getsds(true);
|
||||
// }, 300);
|
||||
//}
|
||||
msg2("저장했습니다.");
|
||||
$(".file_input_opacity").val("")
|
||||
$(".file_input_textbox").val("")
|
||||
|
|
@ -426,7 +518,6 @@
|
|||
}
|
||||
function cbauthkey() {
|
||||
if (capResult.code == 1000) {
|
||||
@*var pop = window.open('@ViewBag.fronturl/Open/CertPrint?userno=@ViewBag.SSUserNo&authtype=' + _authtype + '&randkey=' + capResult.obj, "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/certification.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("팝업이 차단되어 있습니다. 차단을 해제해 주세요.");
|
||||
|
|
|
|||
|
|
@ -30,11 +30,13 @@
|
|||
<col />
|
||||
<col />
|
||||
<col />
|
||||
<col />
|
||||
</colgroup>
|
||||
<thead>
|
||||
<tr>
|
||||
<th>선택</th>
|
||||
<th>아이디</th>
|
||||
<th>핸드폰번호</th>
|
||||
<th>요청일</th>
|
||||
<th>처리상태</th>
|
||||
</tr>
|
||||
|
|
@ -56,18 +58,8 @@
|
|||
}
|
||||
<input type="hidden" id="hdn_UserStatus" value="@item.userstatus" />
|
||||
</td>
|
||||
<td>
|
||||
@if (item.status != 1 && item.userstatus != 99)
|
||||
{
|
||||
<a href="javascript:;" onclick="reg(@item.userno);" style="text-decoration: underline; color: blue;">
|
||||
@item.userid @string.Format("({0})", item.username)
|
||||
</a>
|
||||
}
|
||||
else
|
||||
{
|
||||
<span>@item.userid</span>
|
||||
}
|
||||
</td>
|
||||
<td class="link"><span>@item.userid</span></td>
|
||||
<td>@item.Mobile</td>
|
||||
<td>@item.levdate.ToString("yy-MM-dd HH:mm")</td>
|
||||
<td>
|
||||
@if (item.status != 1 && item.userstatus == 99)
|
||||
|
|
@ -78,7 +70,6 @@
|
|||
{
|
||||
<span>@this.LeaveStatusToText(item.status)</span>
|
||||
}
|
||||
|
||||
</td>
|
||||
</tr>
|
||||
}
|
||||
|
|
|
|||
|
|
@ -39,10 +39,13 @@
|
|||
<label class="col-sm-4 col-md-2 control-label req">ID</label>
|
||||
<div class="col-sm-8 col-md-10">@Html.TextBoxFor(m => m.User.userid, new { @class = "form-control disp-init ff", @style = "width: 300px;", @maxlength = "50" })</div>
|
||||
</div>
|
||||
@if (Model.viewname != "leavehistory")
|
||||
{
|
||||
<div class="line line-dashed line-lg pull-in"></div><div class="form-group">
|
||||
<label class="col-sm-4 col-md-2 control-label">비밀번호</label>
|
||||
<div class="col-sm-8 col-md-10">@Html.PasswordFor(m => m.User.userpass, new { @class = "form-control disp-init", @style = "width: 300px;", @maxlength = "20" })</div>
|
||||
</div>
|
||||
}
|
||||
<div class="line line-dashed line-lg pull-in"></div><div class="form-group">
|
||||
<label class="col-sm-4 col-md-2 control-label req">이름</label>
|
||||
<div class="col-sm-8 col-md-10">@Html.TextBoxFor(m => m.User.username, new { @class = "form-control disp-init", @style = "width: 300px;", @maxlength = "50" })</div>
|
||||
|
|
|
|||
|
|
@ -1,18 +1,18 @@
|
|||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Web;
|
||||
using System.Web.Mvc;
|
||||
|
||||
using NP.Model;
|
||||
using System.Collections;
|
||||
using IBatisNet.DataMapper.Configuration.ResultMapping;
|
||||
using NP.Base.Auth;
|
||||
using NP.Base.ENUM;
|
||||
|
||||
using System.Net.Http;
|
||||
using XPayClientNet;
|
||||
using NP.Base.Popbill;
|
||||
using IBatisNet.DataMapper.Configuration.ResultMapping;
|
||||
using NP.Model;
|
||||
using System;
|
||||
using System.Collections;
|
||||
using System.Collections.Generic;
|
||||
using System.IO;
|
||||
using System.Linq;
|
||||
using System.Net.Http;
|
||||
using System.Threading.Tasks;
|
||||
using System.Web;
|
||||
using System.Web.Mvc;
|
||||
using XPayClientNet;
|
||||
|
||||
namespace NP.Base.Controllers
|
||||
{
|
||||
|
|
@ -940,14 +940,46 @@ namespace NP.Base.Controllers
|
|||
/// <param name="d"></param>
|
||||
/// <returns></returns>
|
||||
[HttpPost]
|
||||
public JsonResult LectSDSaveToAdmin(LectSD model)
|
||||
{
|
||||
model.uno = SUserInfo.UserNo;
|
||||
model.uip = GetUserIP();
|
||||
model.isproduct = GetConfig("isstaging") == "1" ? (int?)null : 1;
|
||||
|
||||
var uploadedFiles = Request.Files.GetMultiple("fgno")
|
||||
.Where(file => !string.IsNullOrEmpty(file.FileName))
|
||||
.ToList();
|
||||
|
||||
// 파일 존재 여부를 .Any()로 확인하여 의도를 명확히 합니다.
|
||||
if (uploadedFiles != null && uploadedFiles.Any())
|
||||
{
|
||||
model.fgno = SetFile(uploadedFiles, model.fgno ?? 0, "lectsd", "fgno", 1, "XX", false, true, model.cmno, model.userno);
|
||||
model.zstring0 = "T"; // 파일 존재 플래그
|
||||
}
|
||||
else
|
||||
{
|
||||
model.zstring0 = ""; // 파일 없음 플래그
|
||||
}
|
||||
|
||||
string ccountPart = model.ccount == 1 ? "2" : "";
|
||||
string batchPart = string.IsNullOrEmpty(model.lectnos) ? "" : "batch";
|
||||
string queryId = $"lect.lectsd{ccountPart}.save2{batchPart}";
|
||||
|
||||
int resultCode = Dao.Save(queryId, model);
|
||||
|
||||
return JsonOK(resultCode);
|
||||
}
|
||||
|
||||
/*
|
||||
[HttpPost]
|
||||
public JsonResult LectSDSaveToAdmin(LectSD d)
|
||||
{
|
||||
d.uno = SUserInfo.UserNo;
|
||||
d.uip = GetUserIP();
|
||||
d.isproduct = GetConfig("isstaging") == "1" ? (int?)null : 1;
|
||||
|
||||
if (Request.Files.GetMultiple("fgno").Where(w => !string.IsNullOrEmpty(w.FileName)).Count() > 0)
|
||||
{
|
||||
//d.fgno = SetFile(Request.Files.GetMultiple("fgno").Where(w => !string.IsNullOrEmpty(w.FileName)).ToList(), d.fgno ?? 0, "lectsd", "fgno");
|
||||
d.fgno = SetFile(Request.Files.GetMultiple("fgno").Where(w => !string.IsNullOrEmpty(w.FileName)).ToList(), d.fgno ?? 0, "lectsd", "fgno", 1, "XX", false, true, d.cmno, d.userno);
|
||||
d.zstring0 = "T";
|
||||
}
|
||||
|
|
@ -959,6 +991,7 @@ namespace NP.Base.Controllers
|
|||
|
||||
return JsonOK(Dao.Save("lect.lectsd" + (d.ccount == 1 ? "2" : "") + ".save2" + (string.IsNullOrEmpty(d.lectnos) ? "" : "batch"), d));
|
||||
}
|
||||
*/
|
||||
|
||||
/// <summary>
|
||||
/// 과제이력 일괄다운로드
|
||||
|
|
@ -994,10 +1027,10 @@ namespace NP.Base.Controllers
|
|||
}
|
||||
|
||||
//zip 생성
|
||||
List<File> newfile = new List<File>();
|
||||
var newfile = new List<Model.File>();
|
||||
foreach (var f in sds)
|
||||
{
|
||||
newfile.Add(new File() { orgname = string.Format("{0}_{1}.{2}", f.userid, f.username, f.fileurl.Split('.').Last()), fileurl = Server.MapPath(vm.Subjects + f.fileurl) });
|
||||
newfile.Add(new Model.File() { orgname = string.Format("{0}_{1}.{2}", f.userid, f.username, f.fileurl.Split('.').Last()), fileurl = Server.MapPath(vm.Subjects + f.fileurl) });
|
||||
}
|
||||
|
||||
if (!newfile.Count.Equals(0))
|
||||
|
|
|
|||
|
|
@ -492,6 +492,7 @@ namespace NP.Base
|
|||
}
|
||||
return SetFile(fs, fgno, tablename, columnname, fseq, FGKey, false, false, 0);
|
||||
}
|
||||
|
||||
protected long? SetFile(IList<System.Web.HttpPostedFileBase> upFiles, long fgno, String tablename, String columnname, int fseq = 1, String FGKey = "XX", bool iscontents = false, bool issubject = false, int cmno = 0, long userno = 0)
|
||||
{
|
||||
try
|
||||
|
|
@ -507,20 +508,23 @@ namespace NP.Base
|
|||
var fg = Dao.Get<NP.Model.File>("sys.file.getfgnobyfgkey", FGKey).FirstOrDefault();
|
||||
fgno = fg == null ? 0 : fg.fgno;
|
||||
}
|
||||
|
||||
var finfos = new NP.Model.File() { fgno = fgno, tablename = tablename, columnname = columnname, uno = userno > 0 ? userno : SUserInfo.UserNo, uip = GetUserIP() };
|
||||
finfos.Files = new List<NP.Model.File>();
|
||||
var _month = DateTime.Now.ToString("yyyyMM");
|
||||
|
||||
if (issubject)
|
||||
{
|
||||
if (!System.IO.Directory.Exists(Server.MapPath(string.Format(@"{0}\{1}", NP.Model.Base.Subjects, cmno))))
|
||||
if (!Directory.Exists(Server.MapPath(string.Format(@"{0}\{1}", Model.Base.Subjects, cmno))))
|
||||
{
|
||||
System.IO.Directory.CreateDirectory(Server.MapPath(string.Format(@"{0}\{1}", NP.Model.Base.Subjects, cmno)));
|
||||
Directory.CreateDirectory(Server.MapPath(string.Format(@"{0}\{1}", Model.Base.Subjects, cmno)));
|
||||
}
|
||||
}
|
||||
else if (!System.IO.Directory.Exists(Server.MapPath(string.Format(@"{0}\{1}\{2}", iscontents ? NP.Model.Base.Contents : NP.Model.Base.Files, _month, tablename))))
|
||||
else if (!Directory.Exists(Server.MapPath(string.Format(@"{0}\{1}\{2}", iscontents ? Model.Base.Contents : Model.Base.Files, _month, tablename))))
|
||||
{
|
||||
System.IO.Directory.CreateDirectory(Server.MapPath(string.Format(@"{0}\{1}\{2}", iscontents ? NP.Model.Base.Contents : NP.Model.Base.Files, _month, tablename)));
|
||||
Directory.CreateDirectory(Server.MapPath(string.Format(@"{0}\{1}\{2}", iscontents ? Model.Base.Contents : Model.Base.Files, _month, tablename)));
|
||||
}
|
||||
|
||||
int filelength = 0;
|
||||
for (int i = 0; i < fcnt; i++)
|
||||
{
|
||||
|
|
@ -530,6 +534,7 @@ namespace NP.Base
|
|||
string fileExt = System.IO.Path.GetExtension(upFiles[i].FileName.Split('\\').Last());
|
||||
string fileFullPath = issubject ? string.Format(@"\{0}\{1}_{2}_{3}{4}", cmno, SUserInfo.UserNo, DateTime.Now.ToString("yyyyMMddHHmmssfff"),i, fileExt) : string.Format(@"\{0}\{1}\{2}_{3}{4}", _month, tablename, DateTime.Now.ToString("yyyyMMddHHmmssfff") + "_" + SUserInfo.UserNo.ToString(),i, fileExt);
|
||||
upFiles[i].SaveAs(Server.MapPath((issubject ? NP.Model.Base.Subjects : iscontents ? NP.Model.Base.Contents : NP.Model.Base.Files) + fileFullPath));
|
||||
|
||||
finfos.Files.Add(new Model.File()
|
||||
{
|
||||
orgname = upFiles[i].FileName.Split('\\').Last(),
|
||||
|
|
@ -539,6 +544,7 @@ namespace NP.Base
|
|||
});
|
||||
}
|
||||
}
|
||||
|
||||
if (finfos.Files.Count() > 0)
|
||||
{
|
||||
if (finfos.fgno < 1)
|
||||
|
|
@ -557,11 +563,12 @@ namespace NP.Base
|
|||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
//Logger.TryError(ex.Message, ex);
|
||||
SetError(ex.Message);
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
protected long SetFileSingle(System.Web.HttpPostedFileBase upFile, long fgno, String tablename, int fseq, String FGKey)
|
||||
{
|
||||
try
|
||||
|
|
|
|||
|
|
@ -228,10 +228,11 @@
|
|||
order by a.rno
|
||||
</select>
|
||||
|
||||
<!-- 사용자 리스트 와 사용자 정보 공통 -->
|
||||
<select id="users.users" parameterClass="hashtable" resultClass="users">
|
||||
select a.*
|
||||
from (
|
||||
select a.userno,a.usertype,a.asno,a.pasname,a.userid,a.username,a.status,a.gender,a.jointype
|
||||
SELECT a.*
|
||||
FROM (
|
||||
SELECT a.userno,a.usertype,a.asno,a.pasname,a.userid,a.username,a.status,a.gender,a.jointype
|
||||
,b.asname,b.isjoin,b.ceoname,b.brno,b.post aspost,b.address1 asaddress1,b.address2 asaddress2,b.btype asbtype,b.bkind asbkind
|
||||
,CAST(AES_DECRYPT(UNHEX(a.email), <include refid="sql.digest"></include>) AS char) email
|
||||
,CAST(AES_DECRYPT(UNHEX(a.mobile), <include refid="sql.digest"></include>) AS char) mobile
|
||||
|
|
@ -247,19 +248,19 @@
|
|||
,case when a.usertype=1 then '교육생' when d.authname is null then '-' else d.authname end usertypestr
|
||||
,CAST(AES_DECRYPT(UNHEX(a.birthday), <include refid="sql.digest"></include>) 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 <isNotNull property="orderby">$orderby$</isNotNull><isNull property="orderby">a.username</isNull>) rno
|
||||
,count(a.cdt) over() pagetotalcount
|
||||
from users a
|
||||
left outer join assign b on b.asno=a.asno and b.isdel=0
|
||||
left outer join comcode c on c.ccode=a.ccposition
|
||||
left outer join (
|
||||
select distinct usertype,authname
|
||||
from menuauth
|
||||
) d on d.usertype = a.usertype
|
||||
left outer join userstatus us on a.userno = us.userno
|
||||
where a.status < 99
|
||||
,IFNULL(us.playbar, 0) as playbar
|
||||
,IFNULL(us.isplay, 0) as isplay
|
||||
,ROW_NUMBER() OVER(ORDER BY <isNotNull property="orderby">$orderby$</isNotNull><isNull property="orderby">a.username</isNull>) rno
|
||||
,COUNT(a.cdt) over() pagetotalcount
|
||||
FROM users a
|
||||
LEFT OUTER JOIN assign b on b.asno=a.asno and b.isdel=0
|
||||
LEFT OUTER JOIN comcode c on c.ccode=a.ccposition
|
||||
LEFT OUTER JOIN (
|
||||
SELECT DISTINCT usertype,authname
|
||||
FROM menuauth
|
||||
) d ON d.usertype = a.usertype
|
||||
LEFT OUTER JOIN userstatus us on a.userno = us.userno
|
||||
WHERE a.status < 98
|
||||
<isNull property="includesysadmin">and a.usertype <> 91</isNull>
|
||||
<isNotNull property="userno">and a.userno =#userno#</isNotNull>
|
||||
<isNotNull property="usernonot">
|
||||
|
|
@ -275,23 +276,17 @@
|
|||
<isNotNull property="profandmainadmin" prepend="and">(a.usertype=11 or (a.usertype > 80 and b.ismain=1))</isNotNull>
|
||||
<isNotNull property="asname" prepend="and">b.asname like concat('%',#asname#,'%')</isNotNull>
|
||||
<isNotEmpty property="brno" prepend="and">b.brno=#brno#</isNotEmpty>
|
||||
<isNotNull property="email" prepend="and">
|
||||
a.email=HEX(AES_ENCRYPT(#email#, <include refid="sql.digest"></include>))
|
||||
</isNotNull>
|
||||
<isNotEmpty property="mobile" prepend="and">
|
||||
a.mobile=HEX(AES_ENCRYPT(#mobile#, <include refid="sql.digest"></include>))
|
||||
</isNotEmpty>
|
||||
<isNotEmpty property="userpno" prepend="and">
|
||||
a.userpno=HEX(AES_ENCRYPT(#userpno#, <include refid="sql.digest"></include>))
|
||||
</isNotEmpty>
|
||||
<isNotNull property="email" prepend="and">a.email=HEX(AES_ENCRYPT(#email#, <include refid="sql.digest"></include>))</isNotNull>
|
||||
<isNotEmpty property="mobile" prepend="and">a.mobile=HEX(AES_ENCRYPT(#mobile#, <include refid="sql.digest"></include>))</isNotEmpty>
|
||||
<isNotEmpty property="userpno" prepend="and">a.userpno=HEX(AES_ENCRYPT(#userpno#, <include refid="sql.digest"></include>))</isNotEmpty>
|
||||
<isNotNull property="usertypeover" prepend="and">a.usertype > #usertypeover#</isNotNull>
|
||||
<isNotNull property="vssn" prepend="and">a.vssn = #vssn#</isNotNull>
|
||||
<isNotNull property="di" prepend="and">a.di = #di#</isNotNull>
|
||||
) a
|
||||
<include refid="sql.pagedynamic"></include>
|
||||
order by a.rno
|
||||
|
||||
ORDER BY a.rno
|
||||
</select>
|
||||
|
||||
<select id="users.usersbyuserids" parameterClass="hashtable" resultClass="users">
|
||||
select a.userno,a.userid,a.username,asno
|
||||
from users a
|
||||
|
|
@ -1072,11 +1067,12 @@
|
|||
, a.uno
|
||||
, a.uip
|
||||
, b.status as userstatus
|
||||
]]>
|
||||
, CAST(AES_DECRYPT(UNHEX(b.mobile), <include refid="sql.digest"></include>) AS char) Mobile
|
||||
, COUNT(*) OVER() AS pagetotalcount
|
||||
FROM userleave a
|
||||
INNER JOIN users b
|
||||
ON a.userno = b.userno
|
||||
]]>
|
||||
<dynamic prepend="where">
|
||||
<isNotNull property="searchtext">
|
||||
<isEqual property="searchtype" compareValue="username" prepend="and">b.username LIKE CONCAT('%', #searchtext#,'%')</isEqual>
|
||||
|
|
|
|||
|
|
@ -325,7 +325,7 @@
|
|||
|
||||
<div class="checkbox-container" style="display: flex; align-items: flex-start; margin-top: 1.5rem; padding: 1rem; border: 1px solid #e5e7eb; border-radius: 0.5rem; background-color: #f9fafb;">
|
||||
<input type="checkbox" id="agreeLeave" name="agreeLeave" style="margin-top: 0.25rem; margin-right: 0.75rem; min-width: 1.25rem; min-height: 1.25rem;">
|
||||
<label for="agreeWithdrawal" style="font-size: 0.95rem; color: #333; line-height: 1.5;">본인은 <strong style="color: #ef4444;">상기 주의사항을 확인 및 동의하며</strong> 회원탈퇴를 요청 합니다.</label>
|
||||
<label for="agreeWithdrawal" style="font-size: 0.95rem;color: #333;line-height: 1.5;cursor: default;">본인은 <strong style="color: #ef4444;">상기 주의사항을 확인 및 동의하며</strong> 회원탈퇴를 요청 합니다.</label>
|
||||
</div>
|
||||
|
||||
<div class="odrPopBtn" style="display: flex; justify-content: center; gap: 1rem; margin-top: 2rem;">
|
||||
|
|
|
|||
|
|
@ -738,6 +738,9 @@ namespace NP.Model
|
|||
/// <summary>탈퇴 처리 IP</summary>
|
||||
public string uip { get; set; }
|
||||
|
||||
/// <summary>휴대폰번호</summary>
|
||||
public string Mobile { get; set; }
|
||||
|
||||
/// <summary>페이지 총 카운트</summary>
|
||||
public int pagetotalcount { get; set; }
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue