123 lines
3.3 KiB
Plaintext
123 lines
3.3 KiB
Plaintext
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
|
<%@ page language="java" import="java.util.*" pageEncoding="utf-8"%>
|
|
<%@ taglib uri="http://java.sun.com/jstl/core_rt" prefix="c"%>
|
|
<%@ taglib uri="http://java.sun.com/jsp/jstl/functions" prefix="fn"%>
|
|
<html>
|
|
<head>
|
|
<title></title>
|
|
<jsp:include page="../../inc.jsp"></jsp:include>
|
|
<script type="text/javascript">
|
|
var grid;
|
|
var MpPics;
|
|
$(function() {
|
|
$('#expressionflag').switchbutton({
|
|
onChange: function(checked){
|
|
if(checked==true){
|
|
$('#tool').panel('open');
|
|
$('#expressionflag').switchbutton("setValue",1);//选中是value为1
|
|
showExpression()
|
|
}else{
|
|
$('#tool').panel('close');
|
|
}
|
|
}
|
|
});
|
|
$('#tool').panel('close');
|
|
MpPics =JSON.parse(getMpPic());
|
|
$('#tool').panel({
|
|
width:"100%",
|
|
height:"250",
|
|
title: '表达式',
|
|
|
|
});
|
|
var mpid ="${scadaPic_MPoint.mpid}";
|
|
grid = $('#grid').datagrid({
|
|
title : '',
|
|
url : ext.contextPath + '/work/scadaPic/getMPoint_ExpressionList.do?mpid='+mpid,
|
|
striped : true,
|
|
rownumbers : true,
|
|
singleSelect: false,
|
|
ctrlSelect:true,
|
|
selectOnCheck: false,
|
|
checkOnSelect: false,
|
|
idField : 'id',
|
|
columns : [ [
|
|
{width : '160', title : '表达式', field : 'expression', sortable : true, halign:'center'},
|
|
{width : '100', title : '显示图标', field : 'expressionway', sortable : true, align:'center',formatter : function(value,row){
|
|
|
|
//console.log(MpPics[value].path)
|
|
var pic='<img src=../../'+MpPics[value].path+' style="width:20px;height:20px;" ></img>';
|
|
return pic;
|
|
}}
|
|
] ],
|
|
onLoadSuccess : function(data) {
|
|
$('.iconImg').attr('src', ext.pixel_0);
|
|
}
|
|
});
|
|
if("${scadaPic_MPoint.expressionflag}"=='1'){
|
|
$('#expressionflag').switchbutton("check");
|
|
}
|
|
|
|
});
|
|
function showExpression(){
|
|
|
|
var mpid ="${scadaPic_MPoint.mpid}";
|
|
$('#grid').datagrid({url:ext.contextPath + '/work/scadaPic/getMPoint_ExpressionList.do?mpid='+mpid});
|
|
|
|
}
|
|
</script>
|
|
</head>
|
|
<body>
|
|
<form method="post" class="form">
|
|
<input name="mpid" type="hidden" value="${scadaPic_MPoint.mpid}"/>
|
|
<table class="table">
|
|
<tr>
|
|
<th>测量点编号</th>
|
|
<td>${scadaPic_MPoint.mpid}
|
|
</td>
|
|
</tr>
|
|
<tr>
|
|
<th>文本内容</th>
|
|
<td>${scadaPic_MPoint.txt}
|
|
</td>
|
|
</tr>
|
|
<tr>
|
|
<th>字体大小</th>
|
|
<td>
|
|
${scadaPic_MPoint.fsize}
|
|
</td>
|
|
</tr>
|
|
<tr>
|
|
<th>posx</th>
|
|
<td>
|
|
${scadaPic_MPoint.posx}
|
|
</td>
|
|
</tr>
|
|
<tr>
|
|
<th>posy</th>
|
|
<td>
|
|
${scadaPic_MPoint.posy}
|
|
</td>
|
|
</tr>
|
|
<tr>
|
|
<th>精确位数</th>
|
|
<td>
|
|
${scadaPic_MPoint.accuracy}
|
|
</td>
|
|
</tr>
|
|
<tr>
|
|
<th>启用表达式</th>
|
|
<td>
|
|
<input id="expressionflag" name ="expressionflag"
|
|
class="easyui-switchbutton" style="height:22px;width:50px;"
|
|
data-options="onText:'是',offText:'否'" unchecked disabled/>
|
|
</td>
|
|
</tr>
|
|
</table>
|
|
<br/>
|
|
<div id="tool" class="easyui-panel" style="height:200px;width:100%;" data-options="border:true" >
|
|
<table id="grid" data-options="border:false,fit:true" ></table>
|
|
</div>
|
|
</form>
|
|
</body>
|
|
</html>
|