Files
KON/user/test.asp
2026-08-07 12:53:18 +09:00

168 lines
5.1 KiB
Plaintext

<!-- #include File="../include/Header.asp"-->
<style>
.qprogress-view-type,
.qprogress-item {
cursor: pointer;
}
.qprogress-item:hover,
.qprogress-view-type:hover,
.selecteditem {
background-color: #639bf1;
color: white
}
.qadmin-selected-item:hover,
.preved-variable-box {
border-color: red !important;
}
.select_qlist:hover {
border-color: #28a745 !important;
}
.qlist_selection,
.selected-variable-box {
border-color: #28a745 !important;
}
#question_list {
overflow-y: scroll;
max-height: 1200px;
}
#dialog {
padding: 5px !important;
}
.usercheck_value {
background-color: yellowgreen;
}
</style>
<%
Dim Code : Code = request("code")
%>
<body>
<div class="container-fluid mt-1" id="mframe">
<div class="row justify-content-center">
<div class="col-10">
<div id="mcontent">
</div>
</div>
</div>
</div>
</body>
<!-- css -->
<link rel="stylesheet" href="../js/jquery-ui/jquery-ui.min.css">
<link rel="stylesheet" href="../js/codemirror-5.54.0/lib/codemirror.css">
<link rel="stylesheet" href="../js/codemirror-5.54.0/theme/hopscotch.css">
<!-- js -->
<script src="../js/jquery-ui/jquery-ui.min.js"></script>
<script src="../js/jquery.dialogextend.min.js"></script>
<script src="../js/codemirror-5.54.0/lib/codemirror.js"></script>
<script src="../js/codemirror-5.54.0/mode/javascript/javascript.js"></script>
<script src="../js/xlsx.min.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/FileSaver.js/1.3.8/FileSaver.min.js"></script>
<script src="../store/store_.js"></script>
<script src="../eachPageModule/Question_.js"></script>
<script src="../eachPageModule/logic.js"></script>
<script src="../eachPageModule/qprogress.js"></script>
<script>
var ajaxUrl = "./ajax_user.asp"
var code = "<%=Code%>"
$(document).ready(function(){
kon.qprogress.progress_type = "user"
kon.qprogress.fn_make_qprogress_frame();
/* 설문 진행에서 설문 크기 변경하기 */
$("body").on("click", ".qprogress-view-type", function () {
$target = $(event.target);
var type = $target.attr("data-type");
var sizing = {
"height": "",
"width": "",
"margin": ""
}
switch (type) {
case "desktop":
sizing.height = "900px"
sizing.width = "100%"
sizing.margin = "0px"
break;
case "mobile-width":
sizing.height = "360px"
sizing.width = "640px"
sizing.margin = "100px"
break;
case "mobile-height":
sizing.height = "640px"
sizing.width = "360px"
sizing.margin = "100px"
break;
}
$("#iframe_question").animate({
width: sizing.width,
height: sizing.height,
marginTop: sizing.margin
})
})
/* 설문 진행에서 문항 이동하기 */
$("body").on("click", ".qprogress-item", function (e) {
var $target = $(e.target);
var nextpage = $target.attr("data-qid")
var iframe = document.getElementById("iframe_question");
var $content = $(iframe.contentDocument);
$content.find("input[name=NEXTPAGE]").val(nextpage);
$content.find("form[name=survey]").attr("onsubmit", "").submit();
})
$("body").on("click", ".iframe-btn", function (e) {
var dtype = e.target.getAttribute("data-type");
var iframe = document.getElementById("iframe_question");
var $content = $(iframe.contentDocument);
var userid = ""
if (dtype === "question") {
if ($("#question_dialog").dialog("isOpen")) {
$("#question_dialog").dialog("close")
} else {
$("#question_dialog").dialog("open")
}
} else if (dtype === "data") {
if ($("#data_dialog").dialog("isOpen")) {
$("#data_dialog").dialog("close")
} else {
$("#data_dialog").dialog("open")
}
} else {
userid = ID()
$content.find("input[name=IDKEY]").val(userid);
kon.qprogress.userid = userid
$("#qprocess-id").text(kon.qprogress.userid)
}
})
/* 설문 진행 검색 가능하게 */
$("body").on("keyup", "#qprogress_list", function (e) {
if (e.keyCode === 13) {
var item = $(".qprogress-item[data-qid='" + e.target.value + "']");
if (item.length > 0) {
item.trigger("click");
}
}
})
})
</script>