first commit
This commit is contained in:
336
WebRoot/jsp/process/dataVisualLineChartSeriesEdit.jsp
Normal file
336
WebRoot/jsp/process/dataVisualLineChartSeriesEdit.jsp
Normal file
@ -0,0 +1,336 @@
|
||||
<%@ page language="java" pageEncoding="UTF-8" %>
|
||||
<%@page import="com.sipai.entity.process.DataVisualLineChartSeries" %>
|
||||
<%request.setAttribute("TimeRange_dateSelect", DataVisualLineChartSeries.TimeRange_dateSelect); %>
|
||||
<%request.setAttribute("TimeRange_hour", DataVisualLineChartSeries.TimeRange_hour); %>
|
||||
<%request.setAttribute("TimeRange_day", DataVisualLineChartSeries.TimeRange_day); %>
|
||||
<%request.setAttribute("TimeRange_week", DataVisualLineChartSeries.TimeRange_week); %>
|
||||
<%request.setAttribute("TimeRange_month", DataVisualLineChartSeries.TimeRange_month); %>
|
||||
<%request.setAttribute("TimeRange_year", DataVisualLineChartSeries.TimeRange_year); %>
|
||||
|
||||
<link rel="stylesheet"
|
||||
href="<%=request.getContextPath()%>/node_modules/bootstrap-switch/dist/css/bootstrap3/bootstrap-switch.min.css"/>
|
||||
<script type="text/javascript"
|
||||
src="<%=request.getContextPath()%>/node_modules/bootstrap-switch/dist/js/bootstrap-switch.min.js"
|
||||
charset="utf-8"></script>
|
||||
|
||||
<style type="text/css">
|
||||
|
||||
</style>
|
||||
<script type="text/javascript">
|
||||
$(function () {
|
||||
$("#timerange").select2({minimumResultsForSearch: -1}).val("${dataVisualLineChartSeries.timerange}").trigger("change");
|
||||
|
||||
$('#switchBtnIshistorydata').bootstrapSwitch({
|
||||
onText: '是',
|
||||
offText: '否',
|
||||
size: "small",
|
||||
});
|
||||
if ('${dataVisualLineChartSeries.ishistorydata}' == 'false') {
|
||||
$('#switchBtnIshistorydata').bootstrapSwitch('state', false, true);
|
||||
} else if ('${dataVisualLineChartSeries.ishistorydata}' == 'true') {
|
||||
$('#switchBtnIshistorydata').bootstrapSwitch('state', true, true);
|
||||
} else {
|
||||
$('#switchBtnIshistorydata').bootstrapSwitch('state', false, true);
|
||||
}
|
||||
|
||||
|
||||
$('#switchBtnMaxshow').bootstrapSwitch({
|
||||
onText: '显示',
|
||||
offText: '不显示',
|
||||
size: "small",
|
||||
});
|
||||
if ('${dataVisualLineChartSeries.maxshow}' == 'false') {
|
||||
$('#switchBtnMaxshow').bootstrapSwitch('state', false, true);
|
||||
} else if ('${dataVisualLineChartSeries.maxshow}' == 'true') {
|
||||
$('#switchBtnMaxshow').bootstrapSwitch('state', true, true);
|
||||
} else {
|
||||
$('#switchBtnMaxshow').bootstrapSwitch('state', false, true);
|
||||
}
|
||||
|
||||
$('#switchBtnMinshow').bootstrapSwitch({
|
||||
onText: '显示',
|
||||
offText: '不显示',
|
||||
size: "small",
|
||||
});
|
||||
if ('${dataVisualLineChartSeries.minshow}' == 'false') {
|
||||
$('#switchBtnMinshow').bootstrapSwitch('state', false, true);
|
||||
} else if ('${dataVisualLineChartSeries.minshow}' == 'true') {
|
||||
$('#switchBtnMinshow').bootstrapSwitch('state', true, true);
|
||||
} else {
|
||||
$('#switchBtnMinshow').bootstrapSwitch('state', false, true);
|
||||
}
|
||||
|
||||
$('#switchBtnAvgshow').bootstrapSwitch({
|
||||
onText: '显示',
|
||||
offText: '不显示',
|
||||
size: "small",
|
||||
});
|
||||
if ('${dataVisualLineChartSeries.avgshow}' == 'false') {
|
||||
$('#switchBtnAvgshow').bootstrapSwitch('state', false, true);
|
||||
} else if ('${dataVisualLineChartSeries.avgshow}' == 'true') {
|
||||
$('#switchBtnAvgshow').bootstrapSwitch('state', true, true);
|
||||
} else {
|
||||
$('#switchBtnAvgshow').bootstrapSwitch('state', false, true);
|
||||
}
|
||||
|
||||
$('#switchBtnAreastyle').bootstrapSwitch({
|
||||
onText: '显示',
|
||||
offText: '不显示',
|
||||
size: "small",
|
||||
});
|
||||
if ('${dataVisualLineChartSeries.areastyle}' == 'false') {
|
||||
$('#switchBtnAreastyle').bootstrapSwitch('state', false, true);
|
||||
} else if ('${dataVisualLineChartSeries.areastyle}' == 'true') {
|
||||
$('#switchBtnAreastyle').bootstrapSwitch('state', true, true);
|
||||
} else {
|
||||
$('#switchBtnAreastyle').bootstrapSwitch('state', false, true);
|
||||
}
|
||||
|
||||
$('#switchBtnSymbolst').bootstrapSwitch({
|
||||
onText: '显示',
|
||||
offText: '不显示',
|
||||
size: "small",
|
||||
});
|
||||
if ('${dataVisualLineChartSeries.symbolst}' == 'false') {
|
||||
$('#switchBtnSymbolst').bootstrapSwitch('state', false, true);
|
||||
} else if ('${dataVisualLineChartSeries.symbolst}' == 'true') {
|
||||
$('#switchBtnSymbolst').bootstrapSwitch('state', true, true);
|
||||
} else {
|
||||
$('#switchBtnSymbolst').bootstrapSwitch('state', false, true);
|
||||
}
|
||||
|
||||
$('#switchBtnSelectst').bootstrapSwitch({
|
||||
onText: '显示',
|
||||
offText: '不显示',
|
||||
size: "small",
|
||||
});
|
||||
if ('${dataVisualLineChartSeries.selectst}' == 'false') {
|
||||
$('#switchBtnSelectst').bootstrapSwitch('state', false, true);
|
||||
} else if ('${dataVisualLineChartSeries.selectst}' == 'true') {
|
||||
$('#switchBtnSelectst').bootstrapSwitch('state', true, true);
|
||||
} else {
|
||||
$('#switchBtnSelectst').bootstrapSwitch('state', false, true);
|
||||
}
|
||||
|
||||
});
|
||||
|
||||
function doLineChartSeriesSave() {
|
||||
let form = $("#lineChartSeriesForm").serialize();
|
||||
|
||||
const ishistorydata = $('#switchBtnIshistorydata').bootstrapSwitch('state');
|
||||
if (ishistorydata) {
|
||||
form = form + "&ishistorydata=true";
|
||||
} else {
|
||||
form = form + "&ishistorydata=false";
|
||||
}
|
||||
const switchBtnMaxshow = $('#switchBtnMaxshow').bootstrapSwitch('state');
|
||||
if (switchBtnMaxshow) {
|
||||
form = form + "&maxshow=true";
|
||||
} else {
|
||||
form = form + "&maxshow=false";
|
||||
}
|
||||
const switchBtnMinshow = $('#switchBtnMinshow').bootstrapSwitch('state');
|
||||
if (switchBtnMinshow) {
|
||||
form = form + "&minshow=true";
|
||||
} else {
|
||||
form = form + "&minshow=false";
|
||||
}
|
||||
const switchBtnAvgshow = $('#switchBtnAvgshow').bootstrapSwitch('state');
|
||||
if (switchBtnAvgshow) {
|
||||
form = form + "&avgshow=true";
|
||||
} else {
|
||||
form = form + "&avgshow=false";
|
||||
}
|
||||
const switchBtnAreastyle = $('#switchBtnAreastyle').bootstrapSwitch('state');
|
||||
if (switchBtnAreastyle) {
|
||||
form = form + "&areastyle=true";
|
||||
} else {
|
||||
form = form + "&areastyle=false";
|
||||
}
|
||||
const switchBtnSymbolst = $('#switchBtnSymbolst').bootstrapSwitch('state');
|
||||
if (switchBtnSymbolst) {
|
||||
form = form + "&symbolst=true";
|
||||
} else {
|
||||
form = form + "&symbolst=false";
|
||||
}
|
||||
const switchBtnSelectst = $('#switchBtnSelectst').bootstrapSwitch('state');
|
||||
if (switchBtnSelectst) {
|
||||
form = form + "&selectst=true";
|
||||
} else {
|
||||
form = form + "&selectst=false";
|
||||
}
|
||||
|
||||
$.post(ext.contextPath + "/process/dataVisualLineChartSeries/doupdate.do", form, function (data) {
|
||||
if (data.code == 1) {
|
||||
closeModal('lineChartSeriesSubModal');
|
||||
$("#seriesTable").bootstrapTable('refresh');
|
||||
} else if (data.code == 0) {
|
||||
showAlert('d', '保存失败');
|
||||
} else {
|
||||
showAlert('d', data.res);
|
||||
}
|
||||
}, 'json');
|
||||
}
|
||||
|
||||
function selectmpids() {
|
||||
$.post(ext.contextPath + '/work/mpoint/mpointList4LayerES.do', {
|
||||
// mpids: mpids,
|
||||
mpids: '',
|
||||
fucname: 'ckmpidDone'
|
||||
}, function (data) {
|
||||
$("#mpSelectDiv").html(data);
|
||||
openModal('subModalMpoint');
|
||||
});
|
||||
}
|
||||
|
||||
function ckmpidDone(data) {
|
||||
$('#lineChartSeriesForm #mpid').val(data);
|
||||
closeModal('subModalMpoint');
|
||||
}
|
||||
|
||||
</script>
|
||||
<div class="modal fade" id="lineChartSeriesSubModal">
|
||||
<div class="modal-dialog">
|
||||
<div class="modal-content">
|
||||
<div class="modal-header">
|
||||
<button type="button" class="close" data-dismiss="modal" aria-label="Close">
|
||||
<span aria-hidden="true">×</span></button>
|
||||
<h4 class="modal-title">编辑</h4>
|
||||
</div>
|
||||
|
||||
<div id="alertDiv"></div>
|
||||
|
||||
<div class="modal-body">
|
||||
<!-- 新增界面formid强制为subForm -->
|
||||
<form class="form-horizontal" id="lineChartSeriesForm" autocomplete="off">
|
||||
<!-- 界面提醒div强制id为alertDiv -->
|
||||
<input type="hidden" name="id" id="id" value="${dataVisualLineChartSeries.id}"/>
|
||||
|
||||
<div class="form-group">
|
||||
<label class="col-sm-2 control-label">名称</label>
|
||||
<div class="col-sm-4">
|
||||
<input type="text" class="form-control" id="name" name="name" placeholder="名称"
|
||||
value="${dataVisualLineChartSeries.name}">
|
||||
</div>
|
||||
<label class="col-sm-2 control-label">所属轴</label>
|
||||
<div class="col-sm-4">
|
||||
<input type="text" class="form-control" id="yaxisindex" name="yaxisindex" placeholder="所属轴"
|
||||
value="${dataVisualLineChartSeries.yaxisindex}">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-sm-2 control-label">历史值</label>
|
||||
<div class="col-sm-4">
|
||||
<div class="switch" data-on="primary" data-off="info">
|
||||
<input id="switchBtnIshistorydata" type="checkbox"/>
|
||||
</div>
|
||||
</div>
|
||||
<label class="col-sm-2 control-label">时间范围</label>
|
||||
<div class="col-sm-4">
|
||||
<select id="timerange" name="timerange" class="form-control select2" style="width: 170px;">
|
||||
<option value="${TimeRange_dateSelect}">日期控件</option>
|
||||
<option value="${TimeRange_hour}">小时</option>
|
||||
<option value="${TimeRange_day}">天</option>
|
||||
<option value="${TimeRange_week}">周</option>
|
||||
<option value="${TimeRange_month}">月</option>
|
||||
<option value="${TimeRange_year}">年</option>
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-sm-2 control-label">测量点</label>
|
||||
<div class="col-sm-10">
|
||||
<input type="text" class="form-control" id="mpid" name="mpid" placeholder="测量点"
|
||||
value="${dataVisualLineChartSeries.mpid}" onclick="selectmpids();">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-sm-2 control-label">接口数据</label>
|
||||
<div class="col-sm-10">
|
||||
<input type="text" class="form-control" id="urldata" name="urldata"
|
||||
placeholder="接口数据"
|
||||
value="${dataVisualLineChartSeries.urldata}">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-sm-2 control-label">固定值</label>
|
||||
<div class="col-sm-10">
|
||||
<input type="text" class="form-control" id="fixedvalue" name="fixedvalue" placeholder="固定值"
|
||||
value="${dataVisualLineChartSeries.fixedvalue}">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-sm-2 control-label">标记线</label>
|
||||
<div class="col-sm-4">
|
||||
<input type="text" class="form-control" id="markerline" name="markerline" placeholder="标记线"
|
||||
value="${dataVisualLineChartSeries.markerline}">
|
||||
</div>
|
||||
<label class="col-sm-2 control-label">堆叠名称</label>
|
||||
<div class="col-sm-4">
|
||||
<input type="text" class="form-control" id="stackst" name="stackst" placeholder="堆叠名称"
|
||||
value="${dataVisualLineChartSeries.stackst}">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-sm-2 control-label">最大值</label>
|
||||
<div class="col-sm-4">
|
||||
<div class="switch" data-on="primary" data-off="info">
|
||||
<input id="switchBtnMaxshow" type="checkbox"/>
|
||||
</div>
|
||||
</div>
|
||||
<label class="col-sm-2 control-label">最小值</label>
|
||||
<div class="col-sm-4">
|
||||
<div class="switch" data-on="primary" data-off="info">
|
||||
<input id="switchBtnMinshow" type="checkbox"/>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-sm-2 control-label">平均值</label>
|
||||
<div class="col-sm-4">
|
||||
<div class="switch" data-on="primary" data-off="info">
|
||||
<input id="switchBtnAvgshow" type="checkbox"/>
|
||||
</div>
|
||||
</div>
|
||||
<label class="col-sm-2 control-label">面积块</label>
|
||||
<div class="col-sm-4">
|
||||
<div class="switch" data-on="primary" data-off="info">
|
||||
<input id="switchBtnAreastyle" type="checkbox"/>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-sm-2 control-label">拐点图形</label>
|
||||
<div class="col-sm-4">
|
||||
<div class="switch" data-on="primary" data-off="info">
|
||||
<input id="switchBtnSymbolst" type="checkbox"/>
|
||||
</div>
|
||||
</div>
|
||||
<label class="col-sm-2 control-label">图例状态</label>
|
||||
<div class="col-sm-4">
|
||||
<div class="switch" data-on="primary" data-off="info">
|
||||
<input id="switchBtnSelectst" type="checkbox"/>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-sm-2 control-label">排序</label>
|
||||
<div class="col-sm-4">
|
||||
<input type="text" class="form-control" id="morder" name="morder" placeholder="排序"
|
||||
value="${dataVisualLineChartSeries.morder}">
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</form>
|
||||
</div>
|
||||
|
||||
<div class="modal-footer">
|
||||
<button type="button" class="btn btn-default pull-left" data-dismiss="modal">关闭</button>
|
||||
<button type="button" class="btn btn-primary" onclick="doLineChartSeriesSave()">保存</button>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
<!-- /.modal-content -->
|
||||
</div>
|
||||
<!-- /.modal-dialog -->
|
||||
</div>
|
||||
Reference in New Issue
Block a user