采集器运行状态

master
ALW 3 years ago
parent b804835ef6
commit 2350a95c90

@ -68,12 +68,21 @@ public class StatisticsController {
return "statistics/printCount";
}
//采集器状态
@RequestMapping("collectorStatus")
public String collectorStatus(){
return "statistics/collectorStatus";
}
//复印记录明细
@RequestMapping("printInfo")
public String printInfo(){
return "statistics/printInfo";
}
//扫描上传记录报表
@RequestMapping("scanCount")
public String scanCount(Model model,String startDateTo,String endDateTo){

@ -24,6 +24,8 @@ public class Archive_Master_Vo extends Archive_Master{
private Float days;
private Integer statusFlag;
private String checkName;
private String checkedName;

@ -574,6 +574,15 @@
<if test="jzh != null and jzh != ''">
and archive_other_ext.jzh = #{jzh,jdbcType=NVARCHAR}
</if>
<if test="c2 != null and c2 != ''">
and archive_other_ext.c2 = #{c2,jdbcType=NVARCHAR}
</if>
<if test="statusflag != null">
and archive_other_ext.statusFlag = #{statusflag,jdbcType=INTEGER}
</if>
<if test="sysflag != null">
and archive_other_ext.sysflag = #{sysflag,jdbcType=INTEGER}
</if>
</where>
order by statusFlagSort
</select>

@ -805,7 +805,7 @@
<div class="form-inline">
<div class="form-group divCss8">
<label for="name">标题:</label>
<input type="text" class="input-sm form-control" id="c1" maxlength="25"
<input type="text" class="input-sm form-control" id="c2" maxlength="25"
placeholder="请输入标题">
</div>
<div class="form-group divCss8">

@ -0,0 +1,129 @@
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<%@taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>
<c:set value="${pageContext.request.contextPath}" var="path" scope="page"/>
<html>
<head>
<title>扫描上传记录报表</title>
<meta charset="utf-8">
<!-- 解决部分兼容性问题如果安装了GCF则使用GCF来渲染页面如果未安装GCF则使用最高版本的IE内核进行渲染。 -->
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
<!-- 页面按原比例显示 -->
<meta name="viewport" content="width=device-width, initial-scale=1">
<%@include file="../../jspf/comm.jspf" %>
<style>
.divCss {
margin-top: 5px;
}
.divCss8 {
margin-top: 5px;
margin-right: 20px;
}
/* dataTables表头居中 */
.table > thead:first-child > tr:first-child > th {
text-align: center !important;
}
</style>
<script>
var path = "${path}";
</script>
</head>
<body>
<!--隐藏是否是初始化-->
<input type="hidden" id="isSearch" value="1">
<div class="mainBody">
<div class="main">
<div class="headDiv">
<div class="headSpanDiv">
<span class="headspan">
扫描上传记录报表
</span>
</div>
</div>
<div class="mainDiv">
<!--搜索-->
<form>
<div class="form-inline" style="margin-left:5px;margin-top:5px;margin-bottom: 0!important;">
<div class="form-group divCss8">
<div class="input-group">
<select class="form-control" id="dateFlag">
<option value="1">按日查询</option>
<option value="2">按月查询</option>
<option value="3">按年查询</option>
</select>
</div>
</div>
<div class="form-group divCss8" id="day">
<label>出院日查询:</label>
<div class="input-group">
<input type="text" class="input-sm form-control" id="startTime1" style="text-align: center"
maxlength="10" autocomplete="off" value="${startDate}"/>
<span class="input-group-addon">-</span>
<input type="text" class="input-sm form-control" id="endTime1" style="text-align: center"
maxlength="10" autocomplete="off" value="${endDate}"/>
</div>
</div>
<div class="form-group divCss8" id="month" style="display: none">
<label>出院月查询:</label>
<div class="input-group">
<input type="text" class="input-sm form-control" id="startTime3" style="text-align: center"
maxlength="10" autocomplete="off"/>
<span class="input-group-addon">-</span>
<input type="text" class="input-sm form-control" id="endTime3" style="text-align: center"
maxlength="10" autocomplete="off"/>
</div>
</div>
<div class="form-group divCss8" id="year" style="display: none">
<label>出院年查询:</label>
<div class="input-group">
<input type="text" class="input-sm form-control" id="startTime4" style="text-align: center"
maxlength="10" autocomplete="off"/>
<span class="input-group-addon">-</span>
<input type="text" class="input-sm form-control" id="endTime4" style="text-align: center"
maxlength="10" autocomplete="off"/>
</div>
</div>
<div class="form-group divCss" id="dateRange">
<label>扫描时段:</label>
<select class="form-control input-sm" id="timeInterval"
onchange="loadTableByTime(this.options[this.options.selectedIndex].value,'startTime1','endTime1','table')">
</select>
</div>
<div class="form-group divCss8">
<label>扫描人:</label>
<input type="text" class="form-control input-sm" id="name" maxlength="8">
</div>
<button type="button" class="btn btn-primary btn-sm divCss" id="searchBtn">查询</button>
<button type="button" class="btn btn-info btn-sm divCss" id="excelBtn">条件导出</button>
</div>
</form>
<!--数据表格-->
<table id="table" class="table table-striped"></table>
<div id="toolbar" class="btn-group pull-right" style="margin-right: 20px;">
<div class="columns columns-right btn-group pull-right">
<div class="btn-group btn-info">
<select id="sel_exportoption" class="form-control">                
<option value="">导出当前页面数据</option>
               
<option value="all">导出全部数据</option>
             
<option value="selected">导出选中数据</option>
</select>
</div>
<button class=" btn btn-success" style="height: 34px" type="button" id="refreshBtn" name="refresh"
aria-label="Refresh"
title="Refresh">
<i class="glyphicon glyphicon-refresh icon-refresh"></i>
</button>
</div>
</div>
</div>
</div>
</div>
<script src="${path}/static/js/statistics/collectorStatus.js?time=2021-07-30"></script>
<script src="${path}/static/js/statistics/statisticsCommom.js?time=2020-07-24"></script>
<script src="${path}/static/js/record/getStartDateAndEndDateGroupbyDayMonthYear.js"></script>
</body>
</html>

@ -1176,10 +1176,10 @@ function initTable5(data,sidePagination) {
limit: limit, //页面大小
offset: offset, //页码
jzh: $("#patientId").val(),
c1: $("#c1").val(),
c2: $("#c2").val(),
statusflag:$("#statusflag").val(),
sysflag:$("#sysflag").val(),
assortId:$("#assortIdSearch").val()
assortId:$("#assortIdSearch").val(),
};
return temp;
},
@ -1251,13 +1251,22 @@ function initTable5(data,sidePagination) {
},
{
title: '状态',
field: 'statusFlagStr',
field: 'statusflag',
align: 'center',
valign: 'middle',
formatter: function (value, row, index) {
if(value != null){
if (row.statusflag == 3) {
value='完成';
return value;
}
if (row.statusflag == 2) {
value='正采';
return value;
}
var color = '';
if(row.statusflag == 0){
value='未开始';
color = selectTimeColor(row.tempTime,row.etimeStr);
}
return '<span style="color:'+color+'">'+value+'</span>';

@ -0,0 +1,170 @@
var tipLoad = 1;
//定义表格内容最大高度
var maxHeight = 0;
//按日期查询变更事件
$("#dateFlag").change(function(){
var value = $(this).val();
if(value == 1){
$("#day").show();
$("#month").hide();
$("#year").hide();
}else if(value == 2){
$("#day").hide();
$("#month").show();
$("#year").hide();
}else if(value == 3){
$("#day").hide();
$("#month").hide();
$("#year").show();
}
$("#table").bootstrapTable("refresh");
})
function initTable() {
if(tipLoad == 1){
$("#table").bootstrapTable({ // 对应table标签的id
url: path+"/statistics/getScanCount", // 获取表格数据的url
contentType: "application/x-www-form-urlencoded",//一种编码。好像在post请求的时候需要用到。这里用的get请求注释掉这句话也能拿到数据
cache: false, // 设置为 false 禁用 AJAX 数据缓存, 默认为true
striped: true, //表格显示条纹默认为false
pagination: true, // 在表格底部显示分页组件默认false
paginationShowPageGo: true,
pageList: [5,10, 20, 50, 100], // 如果设置了分页设置可供选择的页面数据条数。设置为All 则显示所有记录。
sidePagination: 'server', // 设置为服务器端分页 客户端client
search: false,
showColumns: true,
toolbar: '#toolbar',//指定工具栏
searchOnEnterKey: true, //设置为 true时按回车触发搜索方法否则自动触发搜索方法
undefinedText: '--', //当数据为 undefined 时显示的字符
singleSelect: false,//设置True 将禁止多选
clickToSelect: true,//设置true 将在点击行时自动选择rediobox 和 checkbox
//height: getStaticTableHeight(), //定义表格的高度。
searchTimeOut: 500,// 默认500 设置搜索超时时间。
toolbarAlign: 'right',// 指定 toolbar 水平方向的位置。'left' 或 'right'
paginationDetailHAlign: 'left',//指定 分页详细信息 在水平方向的位置。'left' 或 'right'。
showHeader: true,//是否显示列头。
trimOnSearch: true,//设置为 true 将自动去掉搜索字符的前后空格。
//是否显示导出按钮
showExport: true,
//导出表格方式默认basic只导出当前页的表格数据all导出所有数据selected导出选中的数据
exportDataType: "basic",
//导出文件类型
exportTypes: ['json', 'xml', 'csv', 'txt', 'sql', 'excel'],
exportOptions: {
fileName: document.title
},
queryParams: function (params) {
var currPageSize = this.pageSize;
if (currPageSize == 2) {
currPageSize = 10;
}
var limit = null;
var offset = params.offset;
//判断是否导出全部all
if ($("#sel_exportoption").val() == "all") {
offset = 0;
limit = this.totalRows;
this.pageSize = limit;
} else {
limit = currPageSize;
this.pageSize = currPageSize;
}
var dateFlag = $("#dateFlag").val();
var startDate = getStartOrEndDate(dateFlag,"startTime");
var endDate = getStartOrEndDate(dateFlag,"endTime");
var temp = {
limit: limit, //页面大小
offset: offset, //页码
startDate: startDate,
endDate: endDate,
name:$("#name").val(),
isSearch:$("#isSearch").val(),
dateFlag:$("#dateFlag").val()
};
return temp;
},
columns: [{
title: '全选',
field: 'select', //复选框
checkbox: true,
width: 25,
align: 'center',
valign: 'middle'
},
{
title: '扫描人',
field: 'uuname',
align: 'center',
valign: 'middle'
},
{
title: '扫描日期',
field: 'uploaddatetime',
align: 'center',
valign: 'middle'
},
{
title: '扫描次数',
field: 'scanCount',
align: 'center',
valign: 'middle'
},
{
title: '扫描份数',
field: 'scanNums',
align: 'center',
valign: 'middle'
},
],
onLoadSuccess: function (result) { //加载成功时执行
$(".page-list").show();
tipLoad =0;
//reloadTableHeight("table");
},
onLoadError: function () { //加载失败时执行
tipLoad = 0;
}
});
}
}
//导出excel功能
$("#excelBtn").click(function () {
//获取选中数据记录
var idlist = $('#table').bootstrapTable('getAllSelections');
var dateFlag = $("#dateFlag").val();
var sql = '';//AND ((uuName = '何素芳' and convert(date, UpLoadDateTime, 8) = '2019-12-26') or (uuName = '何素芳' and convert(date, UpLoadDateTime, 8) = '2019-12-26'))
if(idlist.length > 0){
var dateWhereSql = '';
if(dateFlag == 1){
dateWhereSql = 'CONVERT (VARCHAR(10), t1.UpLoadDateTime, 120)';
}else if(dateFlag == 2){
dateWhereSql = 'CONVERT (VARCHAR(7), t1.UpLoadDateTime, 120)';
}else if(dateFlag == 3){
dateWhereSql = 'CONVERT (VARCHAR(4), t1.UpLoadDateTime, 120)';
}
for (var i = 0; i < idlist.length; i++) {
if(idlist.length == 1){
sql += "AND (powerusers.name = '"+idlist[i].uuname+"' and "+dateWhereSql+" = '"+idlist[i].uploaddatetime+"')";
}else{
if(i == 0){
sql += "AND ((powerusers.name = '"+idlist[i].uuname+"' and "+dateWhereSql+" = '"+idlist[i].uploaddatetime+"') or ";
}else if(i != idlist.length - 1){
sql += "(powerusers.name = '"+idlist[i].uuname+"' and "+dateWhereSql+" = '"+idlist[i].uploaddatetime+"') or ";
}else if(i == idlist.length - 1){
sql += "(powerusers.name = '"+idlist[i].uuname+"' and "+dateWhereSql+" = '"+idlist[i].uploaddatetime+"'))";
}
}
}
}
var url = path+"/statistics/exportExcelScanCount";
var startDate = getStartOrEndDate(dateFlag,"startTime");
var endDate = getStartOrEndDate(dateFlag,"endTime");
post(url, {
"startDate": startDate,
"endDate": endDate,
"name":$("#name").val(),
"isSearch":$("#isSearch").val(),
"sql":sql,
"dateFlag":dateFlag
});
});
Loading…
Cancel
Save