<%@ page language="java" contentType="text/html; charset=utf-8"
	pageEncoding="utf-8"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Insert title here</title>
<link
	href="${pageContext.request.contextPath }/common/admin/css/H-ui.min.css"
	rel="stylesheet" type="text/css" />
<link
	href="${pageContext.request.contextPath }/common/admin/css/H-ui.login.css"
	rel="stylesheet" type="text/css" />
<link
	href="${pageContext.request.contextPath }/common/admin/css/style.css"
	rel="stylesheet" type="text/css" />
<link
	href="${pageContext.request.contextPath }/common/admin/lib/Hui-iconfont/1.0.1/iconfont.css"
	rel="stylesheet" type="text/css" />
</head>
<body>
	<form action="" id="updateAgentMachine">
		<div id="" class="formControls col-2">
				<input type="hidden"  name="agentMachineId" value = "${agentMachineId}">
				<input type="hidden"  name="agentMachineStatus" value = "${agentMachineStatus}">
				<input name="agentMachinePostName" id="agentMachinePostName" value="" placeholder="快递名称" style="width: 300px" class="input-text" type="text">
				<input name="agentMachinePostNum" id="agentMachinePostNum" value="" placeholder="快递单号" style="width: 300px" class="input-text" type="text">
				<button name="" id="submitBtn"  class="btn btn-success" type="button" onclick="updateAgentMachineStatus();">
				<i class="Hui-iconfont"></i> 发货
			</button>
		</div>
	</form>
</body>
<script type="text/javascript"
		src="${pageContext.request.contextPath }/common/admin/lib/jquery/1.9.1/jquery.min.js"></script>
	<script type="text/javascript"
		src="${pageContext.request.contextPath }/common/admin/lib/layer/1.9.3/layer.js"></script>
	<script type="text/javascript"
		src="${pageContext.request.contextPath }/common/admin/js/H-ui.js"></script>
	<script type="text/javascript"
		src="${pageContext.request.contextPath }/common/admin/js/H-ui.admin.js"></script>
	<script type="text/javascript"
		src="${pageContext.request.contextPath }/common/admin/js/tips.js"></script> 
<script type="text/javascript">

  function updateAgentMachineStatus(){
	$.ajax({
        url: '${pageContext.request.contextPath }/admin/card/updateAgentMachineStatus',
        type: "POST",
        dataType: "json",
        data: $('#updateAgentMachine').serialize(),
        error:function(){
      	  layer.msg(data.status,{icon: 5,time:3000});
        },
	        success:  function(data){
	      	  layer.msg(data.status,{icon: 1,time:3000});
	      	  /* $("#Goodstatus").val(obj.val()); */
	      	   window.location.href = '${pageContext.request.contextPath }/admin/card/agentMachineList'; 
	     }
    });
} 
 
</script>
</html>