<%@ page contentType="text/html;charset=UTF-8"%>
|
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
|
<%@ taglib prefix="tags" tagdir="/WEB-INF/tags"%>
|
<c:set var="ctx" value="${pageContext.request.contextPath}" />
|
|
<html>
|
<head>
|
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
|
<link href="${ctx}/static/styles/default.css" type="text/css" rel="stylesheet" />
|
<script src="${ctx}/static/holder.js" type="text/javascript"></script>
|
<script language="javascript" type="text/javascript" src="${ctx}/static/util.js"></script>
|
<script type="text/javascript" src="${ctx}/static/jquery/jquery-3.1.0.min.js"></script>
|
<title>上片位</title>
|
<script type="text/javascript">
|
var interval = setInterval('refreshStatus()', 20000);
|
|
// 设备页面自动刷新
|
function refreshStatus() {
|
window.location.reload();
|
|
}
|
|
// 停止页面自动刷新
|
function disableAutoRefresh() {
|
clearInterval(interval);
|
}
|
|
function setRange() {
|
disableAutoRefresh();
|
$('#modifyRangeModal').modal('toggle');
|
}
|
|
function setdata() {
|
disableAutoRefresh();
|
$('#modifyRangeModal1').modal('toggle');
|
}
|
|
/**
|
* 添加固定料架信息
|
*/
|
function modifyraw(){
|
disableAutoRefresh()
|
$("#add-fix-info").modal('show');
|
}
|
|
|
function oncheck(){
|
var password1=document.getElementsByName('password1')[0].value;
|
var password2=document.getElementsByName('password2')[0].value;
|
$.ajax({
|
cache:false,
|
type:"POST",
|
dataType : "json",
|
url:"${ctx}/identifymachine/modifypassword",
|
data:{
|
"password1":password1,
|
"password2":password2,
|
},success:function(data){
|
if(data.result==1){
|
window.location.href="${ctx}/identifymachine/password";
|
alert("修改成功");
|
}else{
|
window.location.href="${ctx}/identifymachine/password";
|
alert("原密码错误");
|
}
|
|
|
}
|
|
});
|
}
|
|
/* var text = document.getElementById("floorInput");
|
text.onkeyup = function(){
|
this.value=this.value.replace(/\D/g,'');
|
if(text.value>2){
|
text.value = 2;
|
}
|
} */
|
</script>
|
</head>
|
<body>
|
<!-- Content Wrapper. Contains page content -->
|
<div class="content-wrapper">
|
<!-- Content Header (Page header) -->
|
<section class="content-header">
|
<h1>
|
修改密码
|
<!-- <small>测量</small> -->
|
</h1>
|
</section>
|
|
<!-- Main content -->
|
<section class="content container-fluid">
|
|
<!--------------------------
|
| Your Page Content Here |
|
-------------------------->
|
<fieldset>
|
<br>
|
<!-- class="modal hide fade" -->
|
<div id="modifyRangeModal" tabindex="-1" role="dialog"
|
aria-labelledby="myModalLabel" aria-hidden="true">
|
<form method="post" class="form-horizontal"
|
action="${ctx}/identifymachine/modifypassword">
|
<!-- <div class="modal-header">
|
<button type="button" class="close" data-dismiss="modal"
|
aria-hidden="true">×</button>
|
<h3 id="myModalLabel">修改误差范围</h3>
|
</div> -->
|
<div class="modal-body">
|
<!-- <div class="control-group">
|
<label class="control-label" for="floorInput">误差范围</label> -->
|
<div class="controls">
|
原密码 <input type="password" id="password1" name="password1"
|
class="input-mini required" value="">
|
<!-- <script type="text/javascript">
|
var text = document.getElementById("floorInput");
|
text.onkeyup = function(){
|
this.value=this.value.replace(/\D/g,'');
|
if(text.value>2.0){
|
text.value = 2.0;
|
}
|
}
|
</script> -->
|
<br><br>
|
新密码 <input type="password" id="password2" name="password2"
|
class="input-mini required" value=""> <span></span>
|
</div>
|
<br>
|
<button type="button" onclick="oncheck()" class="btn btn-primary">提交</button>
|
<!-- </div> -->
|
</div>
|
<div class="modal-footer"></div>
|
</form>
|
</div>
|
|
|
|
|
</section>
|
<!-- /.content -->
|
</div>
|
</body>
|
</html>
|