354 lines
16 KiB
Plaintext
354 lines
16 KiB
Plaintext
<%@ page contentType="text/html;charset=UTF-8" %>
|
||
<%@ include file="/webpage/include/taglib.jsp" %>
|
||
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>
|
||
<%@ taglib uri="http://java.sun.com/jsp/jstl/functions" prefix="fn" %>
|
||
<html>
|
||
<head>
|
||
<title>问卷页面</title>
|
||
<meta name="decorator" content="default"/>
|
||
<script type="text/javascript" src="${ctxStatic}/jquery/jquery-1.8.3.min.js"></script>
|
||
<script language="javascript" type="text/javascript" src="${ctxStatic}/call/qnviccub.js"></script>
|
||
<script language="javascript" type="text/javascript" src="${ctxStatic}/call/qnvfunc.js"></script>
|
||
<script language="javascript" type="text/javascript" src="${ctxStatic}/call/json2.js"></script>
|
||
<script language="javascript" type="text/javascript" src="${ctxStatic}/call/deviceapi.js"></script>
|
||
<script language="javascript" type="text/javascript" src="${ctxStatic}/call/phone.js"></script>
|
||
<style type="text/css">
|
||
.bg{
|
||
box-shadow:0px 0px 4px #fd5252 inset;
|
||
}
|
||
.tijiaole{
|
||
background-color:#d7f5c7 !important;
|
||
}
|
||
* {
|
||
padding: 0;
|
||
margin: 0;
|
||
}
|
||
|
||
#top {
|
||
width: 100%;
|
||
}
|
||
|
||
.one {
|
||
height: 700px;
|
||
}
|
||
|
||
.three {
|
||
width: 19%;
|
||
height: 900px;
|
||
}
|
||
</style>
|
||
<script language="JavaScript">
|
||
// 电话调用方法
|
||
function doCall(phone){
|
||
if(phone==null||phone==''){
|
||
return;
|
||
}
|
||
//参数传个电话号 phone
|
||
// TV_StartDial(0,phone);
|
||
// openDialogView('电话随访', '${ctx}/assessment/execution/call?id=${spotCheckerOne.id}','600px', '300px')
|
||
}
|
||
function importUser(){
|
||
top.layer.open({
|
||
type : 1,
|
||
area : ['400px', '400px'],
|
||
title : "导入数据",
|
||
content : $("#importBox").html(),
|
||
btn : ['关闭' ],
|
||
/* btn1 : function(index, layero) {
|
||
|
||
top.layer.close(index);
|
||
location.reload();
|
||
}, */
|
||
|
||
btn1 : function(index) {
|
||
top.layer.close(index);
|
||
location.reload();
|
||
}
|
||
});
|
||
}
|
||
function trClick(spotCheckerId,subtaskId){
|
||
location.replace("${ctx}/assessment/task/questionnaireHomeLook?subtaskId="+subtaskId+"&userId="+spotCheckerId+"&pageNo=${page.pageNo}&pageSize=${page.pageSize}");
|
||
//$("#"+spotCheckerId+"").addClass("bg");
|
||
this.addClass("bg");
|
||
}
|
||
function searchByWJ(obj){
|
||
// document.getElementById('officeContent').contentWindow.location.reload(true);
|
||
var val=obj.options[obj.options.selectedIndex].value;
|
||
var identityNumber=obj.options[obj.options.selectedIndex].id;
|
||
location.replace("${ctx}/assessment/task/questionnaireHomeLook?subtaskId=${subtask.id}&userId="+val+"&pageNo=${page.pageNo}&pageSize=${page.pageSize}");
|
||
$("#"+identityNumber).addClass("bg");
|
||
//定位
|
||
var $objTr = $("#"+identityNumber); //找到要定位的地方 tr
|
||
var objTr = $objTr[0]; //转化为dom对象
|
||
$("#dataDiv").animate({scrollTop:objTr.offsetTop},"slow"); //定位tr
|
||
//定位
|
||
}
|
||
|
||
</script>
|
||
<script type="text/javascript">
|
||
function initLayDate() {
|
||
laydate.render({
|
||
elem: '#startTime',
|
||
type: 'date',
|
||
format: 'yyyy-MM-dd',
|
||
value: new Date(),
|
||
btns: ['now', 'confirm']
|
||
});
|
||
}
|
||
$(document).ready(function () {
|
||
var f=document.getElementById("officeContent");
|
||
f.onload = function() {
|
||
var value="${value}";
|
||
f.contentWindow.postMessage(value, "${surveyServer}");// "http://192.168.18.130:8081"
|
||
}
|
||
initLayDate();
|
||
var lost ='${spotCheckerOne.lost}' ;
|
||
if(lost==null||lost==''||lost=='0'){
|
||
//$("input:radio[value=2]").attr('checked','true');
|
||
}else{
|
||
$("input:radio[value='${spotCheckerOne.lost}']").attr('checked','true');
|
||
}
|
||
var id= "${spotCheckerOne.identityNumber}";
|
||
$("#"+id).addClass("bg");
|
||
//定位
|
||
var $objTr = $("#"+id); //找到要定位的地方 tr
|
||
var objTr = $objTr[0]; //转化为dom对象
|
||
$("#dataDiv").animate({scrollTop:objTr.offsetTop},"slow"); //定位tr
|
||
//定位
|
||
var selectedVal ="${userId}";
|
||
$("#wenjuanId option[value='"+selectedVal+"']").attr("selected","selected");
|
||
});
|
||
|
||
function ajaxRefresh(id,lost,subtaskId){
|
||
if(id==null||id==''){
|
||
return;
|
||
}
|
||
$.ajax({
|
||
async: false,
|
||
url: "${ctx}/assessment/task/updateStatusByUserId",
|
||
data:{"id":id,"lost":lost},
|
||
dataType: "json",
|
||
success: function (data) {
|
||
if(data.success){
|
||
top.layer.alert(data.msg);
|
||
location.replace("${ctx}/assessment/task/questionnaireHomeLook?subtaskId="+subtaskId+"&userId="+id+"&pageNo=${page.pageNo}&pageSize=${page.pageSize}");
|
||
}else{
|
||
top.layer.alert(data.msg);
|
||
}
|
||
}
|
||
});
|
||
}
|
||
//发布任务!
|
||
function releaseTask(subtaskId,questionId){
|
||
if(null==questionId){
|
||
return top.layer.alert("数据不全!");
|
||
}
|
||
// console.log(questionId);
|
||
if(questionId!='402892fc6c406f66016c4214edef0519'&&questionId!='402892fc6c406f66016c415116a102a7'){
|
||
return top.layer.alert("该问卷暂无此操作!");
|
||
}
|
||
openQuestionnaireFileDialog("${ctx}/assessment/questionnaireFile/chooseTime?subtaskId="+subtaskId+"&questionId="+questionId,"选择截止时间",'500','500');
|
||
}
|
||
|
||
/**
|
||
* 对话框
|
||
* @param url 地址
|
||
* @param title 标题
|
||
* @param width 宽
|
||
* @param height 高
|
||
*/
|
||
function openQuestionnaireFileDialog(url, title, width, height) {
|
||
top.layer.open({
|
||
type: 2,
|
||
area: [width + 'px', height + 'px'],
|
||
title: title,
|
||
maxmin: true,
|
||
content: url,
|
||
btn: ['确定', '关闭'],
|
||
yes: function (index, layero) {
|
||
var body = top.layer.getChildFrame('body', index);
|
||
// 得到iframe页的窗口对象,执行iframe页的方法:iframeWin.method();
|
||
var iframeWin = layero.find('iframe')[0];
|
||
var inputForm = body.find('#inputForm');
|
||
// 获取当前active的tab的iframe
|
||
var top_iframe = top.getActiveTab().attr("name");
|
||
// 表单提交成功后,从服务器返回的url在当前tab中展示
|
||
inputForm.attr("target", top_iframe);
|
||
if (iframeWin.contentWindow.doSubmit()) {
|
||
setTimeout(function () {
|
||
top.layer.close(index);
|
||
location.reload()
|
||
}, 1000);
|
||
}
|
||
},
|
||
cancel: function (index) {
|
||
}
|
||
});
|
||
}
|
||
function fileDown(url,questionId){
|
||
if(questionId!='402892fc6c406f66016c4214edef0519'&&questionId!='402892fc6c406f66016c415116a102a7'){
|
||
return top.layer.alert("该问卷暂无此操作!");
|
||
}
|
||
window.location =url;
|
||
}
|
||
</script>
|
||
</head>
|
||
|
||
<body style="font-size: large">
|
||
<div style="width: 100%;margin: auto auto">
|
||
<form:form id="searchForm" modelAttribute="spotCheckerOne" action="${ctx}/assessment/task/questionnaireHomeLook?subtaskId=${subtask.id}&userId=" method="post" class="form-inline">
|
||
<input id="pageNo" name="pageNo" type="hidden" vaspotCheckerlue="${page.pageNo}"/>
|
||
<input id="pageSize" name="pageSize" type="hidden" value="${page.pageSize}"/>
|
||
</form:form>
|
||
<div id="top" style="width:75%">
|
||
|
||
<table class="table table-striped table-bordered table-hover table-condensed dataTables-example dataTable">
|
||
<tr>
|
||
<td align="left">问卷名称:</td>
|
||
<td><input type="text" name="" value="${surveyDirectory.surveyName}" readonly class="layui-input"/></td>
|
||
|
||
<%--
|
||
<td align="right">该问卷文件上传任务:</td>
|
||
<td align="center" valign="middle">
|
||
<button class="layui-btn" onclick="releaseTask('${subtask.id}','${spotCheckerOne.questionId}')">任务发布</button>
|
||
</td>--%>
|
||
|
||
|
||
<td align="right">考核人:</td>
|
||
<td>${examiner.name}</td>
|
||
</tr>
|
||
</table>
|
||
</div>
|
||
<div class="one">
|
||
<div id="dataDiv" style="width: 25%;float: left;height:127%;overflow-y: auto;overflow-x: auto;">
|
||
<!-- 表格 -->
|
||
<table id="contentTable" style="height:100%;"
|
||
class="table table-striped table-bordered table-hover table-condensed dataTables-example dataTable" >
|
||
<thead>
|
||
<tr>
|
||
<td class="sort-column issuer" colspan="5" align="center">抽选人列表</td>
|
||
</tr>
|
||
<tr>
|
||
<th class="sort-column issuer">基本信息</th>
|
||
<th class="sort-column publishState">本人电话</th>
|
||
<th class="sort-column publishState">人群</th>
|
||
<th class="sort-column publishState">是否失访</th>
|
||
<th class="sort-column publishState">是否提交</th>
|
||
</tr>
|
||
</thead>
|
||
<tbody>
|
||
<c:forEach items="${spotCheckers}" var="spotChecker" varStatus="status" >
|
||
<tr onclick="trClick('${spotChecker.id}','${subtask.id}')" id="${spotChecker.identityNumber}" <c:if test="${spotChecker.status eq '1'}">class="tijiaole"</c:if>>
|
||
|
||
<td>${spotChecker.name} / ${spotChecker.gender}</td>
|
||
<td>${spotChecker.phone}</td>
|
||
<td>${spotChecker.type}</td>
|
||
<c:choose>
|
||
<c:when test="${empty spotChecker.lost}">
|
||
<td></td>
|
||
</c:when>
|
||
<c:otherwise>
|
||
<c:if test="${spotChecker.lost eq '1'}">
|
||
<td>失访</td>
|
||
</c:if>
|
||
<c:if test="${spotChecker.lost eq '2'}">
|
||
<td>未失访</td>
|
||
</c:if>
|
||
<c:if test="${spotChecker.lost eq '0'}">
|
||
<td></td>
|
||
</c:if>
|
||
</c:otherwise>
|
||
</c:choose>
|
||
<td >${spotChecker.status eq '1'?'已提交':'未提交'}</td>
|
||
|
||
</tr>
|
||
</c:forEach>
|
||
<%--<tr>
|
||
<td colspan="5" align="center" valign="middle">
|
||
<button class="layui-btn" onclick="importUser()">导入用户</button>
|
||
</td>
|
||
</tr>--%>
|
||
</tbody>
|
||
</table>
|
||
<div class="fixed-table-pagination">${page}</div>
|
||
|
||
</div>
|
||
<div style="width:50%;float: left ;height:120%;">
|
||
<table class="table table-bordered table-condensed dataTables-example dataTable no-footer">
|
||
<tbody>
|
||
<tr>
|
||
|
||
<td class="width-10 active"><label class="pull-right">姓名</label></td>
|
||
<td class="width-23">
|
||
${spotCheckerOne.name}
|
||
</td>
|
||
<td class="width-10 active"><label class="pull-right">性别</label></td>
|
||
<td class="width-23">
|
||
<%-- ${spotCheckerOne.gender eq '1'?'男':'女'}--%>
|
||
${spotCheckerOne.gender}
|
||
</td>
|
||
<td class="width-10 active"><label class="pull-right">身份证号</label></td>
|
||
<td class="width-23">
|
||
${spotCheckerOne.identityNumber}
|
||
</td>
|
||
</tr>
|
||
<tr>
|
||
<td class="width-10 active"><label class="pull-right">居住地址</label></td>
|
||
<td class="width-23">
|
||
${spotCheckerOne.nirthplace}
|
||
</td>
|
||
<td class="width-10 active"><label class="pull-right">本人电话</label></td>
|
||
<td class="width-23">
|
||
${spotCheckerOne.phone}
|
||
<a href="#" onclick="doCall('${spotCheckerOne.phone}')">
|
||
<img alt="电话" width="30px" height="30px" src="${ctxStatic}/images/zhsf/huchu.png">
|
||
</a>
|
||
<input type="button" value="挂机" name="B8" onClick="TV_HangUpCtrl(0)" class="layui-btn layui-btn-sm layui-btn-danger">
|
||
</td>
|
||
<td class="width-10 active"><label class="pull-right">联系人电话</label></td>
|
||
<td class="width-23">
|
||
${spotCheckerOne.sparePhone}
|
||
<a href="#" onclick="doCall('${spotCheckerOne.sparePhone}')">
|
||
<img alt="电话" width="30px" height="30px" src="${ctxStatic}/images/zhsf/huchu.png">
|
||
</a>
|
||
<input type="button" value="挂机" name="B8" onClick="TV_HangUpCtrl(0)" class="layui-btn layui-btn-sm layui-btn-danger">
|
||
</td>
|
||
|
||
</tr>
|
||
<tr>
|
||
<td class="width-10 active"><label class="pull-right">既往史疾病</label></td>
|
||
<td class="width-23">
|
||
${spotCheckerOne.historyDisease}
|
||
</td>
|
||
<td class="width-10 active"><label class="pull-right">是否失访</label></td>
|
||
<td class="width-23">
|
||
<input type="radio" value="1" name="options" >是</input>
|
||
<input type="radio" value="2" name="options">否</input>
|
||
</td>
|
||
<td class="width-15 active"><label class="pull-right">选择问卷:</label></td>
|
||
<td class="width-35" >
|
||
<select id="wenjuanId" onchange="searchByWJ(this)" class="form-control required">
|
||
<c:forEach items="${spotCheckerWJList}" var="spotCheckerWJ">
|
||
<option id="${spotCheckerWJ.identityNumber}" value="${spotCheckerWJ.id}">${spotCheckerWJ.survey.surveyName}</option>
|
||
</c:forEach>
|
||
</select></td>
|
||
</tr>
|
||
<%--<tr>
|
||
<td class="width-10 active"><label class="pull-right">文件查看</label></td>
|
||
<td class="width-23" align="center">
|
||
<button class="layui-btn" onclick="fileDown('${ctx}/assessment/questionnaireFile/downloadFileSelf?spotId=${spotCheckerOne.id}&subtaskId=${spotCheckerOne.subtaskId}','${spotCheckerOne.questionId}')" style="margin-left: 20%">检查文件</button>
|
||
</td>
|
||
</tr>--%>
|
||
</tbody>
|
||
</table>
|
||
<%--问卷--%>
|
||
<iframe style="border:1px solid #ddd;" id="officeContent" name="officeContent" src="${surveyUrl}" width="100%" height="82%" frameborder="0"></iframe>
|
||
</div>
|
||
<div style="width:25%;height:144%;float: left;margin-top: -160px;" class="three">
|
||
<%-- http://20.1.1.77:9081/sdcsm --%>
|
||
<a href="http://20.1.1.77:9081/sdcsm" style="width:100%;height:55px;line-height:55px;margin-top: 100px;font-size: larger;" class="layui-btn" target="_blank"><i class="layui-icon" style="font-size: 30px;"></i><i class="layui-icon" style="font-size: 30px;"></i> 山东省卫生机构机构管理信息系统</a>
|
||
</div>
|
||
</div>
|
||
</div>
|
||
</body>
|
||
</html> |