一厂MES,含注塑,喷涂,冲孔
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

200 lines
7.8 KiB

3 months ago
<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="Record_247.aspx.cs" Inherits="MESWebSite.Manage.Record_247" %>
<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<link href="/CSS/Basics.css" rel="stylesheet" />
<link href="/Scripts/jquery-easyui-1.4.3/themes/metro/easyui.css" rel="stylesheet" type="text/css" />
<link href="/Scripts/jquery-easyui-1.4.3/themes/icon.css" rel="stylesheet" type="text/css" />
<link href="/Scripts/jquery-easyui-1.4.3/themes/color.css" rel="stylesheet" type="text/css" />
<script src="/Scripts/jquery-easyui-1.4.3/jquery.min.js" type="text/javascript"></script>
<script src="/Scripts/jquery-easyui-1.4.3/jquery.easyui.min.js" type="text/javascript"></script>
<script src="/Scripts/jquery-easyui-1.4.3/locale/easyui-lang-zh_CN.js" type="text/javascript"></script>
<script src="/Scripts/MyJs.js" type="text/javascript"></script>
<style>
#w td {
padding: 5px 5px;
text-align: left;
vertical-align: middle;
}
#w .title {
vertical-align: middle;
text-align: right;
width: 80px;
height: 40px;
}
p {
padding: 5px;
font-size: small;
font-family: 微软雅黑;
}
.datagrid {
text-align: center;
}
</style>
<title>x247小件装配记录</title>
</head>
<body>
<form id="form1" runat="server">
<div class="top">
<table cellpadding="0" cellspacing="0" style="width: 100%">
<tr>
<td><span class="title">x247小件装配记录</span>
</td>
<td style="float:left">生产时间:
<input id="StartTime_s" class="easyui-datebox" style="width: 130px;" />&nbsp;至&nbsp;
<input id="EndTime_s" class="easyui-datebox" style="width: 130px;" />
&nbsp;&nbsp;装箱单:
<input type="text" id="BoxNo_s" style="width: 140px;" />
&nbsp;&nbsp;总成:
<input type="text" id="PartNo2_s" style="width: 140px;" />
&nbsp;&nbsp;半成品:
<input type="text" id="PartNo1_s" style="width: 140px;" />
&nbsp;&nbsp;订单号:
<input type="text" id="OrderNo_s" style="width: 140px;" />
&nbsp;&nbsp;<a class="topsearchBtn">查询</a></td>
<td style="width: 500px">
</td>
</tr>
</table>
</div>
<table id="tb" title="x247小件装配记录" style="width: 99%;">
</table>
<div hidden="hidden">
<asp:Label ID="lblMessage" runat="server" Text=""></asp:Label>
</div>
<input id="UserID" type="text" hidden="hidden" runat="server" />
<script>
/**************** 全局变量 ***************/
var PrimaryID; //要编辑的id
var dg = $('#tb'); //表格
var isEdit = false; //是否为编辑状态
/**************** DOM加载 ***************/
$(function () {
$.ajaxSetup({
cache: false //关闭AJAX缓存
});
var curr_time = new Date();
var str = curr_time.getFullYear() + "-";
str += curr_time.getMonth() + 1 + "-";
str += curr_time.getDate()
$('#StartTime_s').datebox('setValue', str + " 00:00:00");
$('#EndTime_s').datebox('setValue', str + " 23:59:59");
//搜索按钮
$('.topsearchBtn').first().click(function () {
SearchInfo();
});
dg = $('#tb').datagrid({
fitColumns: true,
nowrap: false,
striped: true,
collapsible: false,
url: "/HttpHandlers/Record_247Handler.ashx?method=QueryList",
//sortName: 'sortNumber',
//sortOrder: 'asc',
remoteSort: false,
columns: [[
{ field: 'ID', title: 'ID', hidden: true },
{ field: 'PartNo1', title: '半成品零件号', sortable: 'true', width: 10 },
{ field: 'PartNo2', title: '总成零件号', sortable: 'true', width: 5 },
{ field: 'BoxNo', title: '箱单', sortable: 'true', width: 10 },
{ field: 'OrderNo', title: '订单号', sortable: 'true', width: 10 },
{
field: 'CreateTime1', title: '总成打印时间', sortable: 'true', width: 10,
formatter: function (date) {
var pa = /.*\((.*)\)/;
var unixtime = date.match(pa)[1].substring(0, 10);
return getTime(unixtime);
}
},
{
field: 'CreateTime2', title: '装箱时间', sortable: 'true', width: 10,
formatter: function (date) {
var pa = /.*\((.*)\)/;
var unixtime = date.match(pa)[1].substring(0, 10);
return getTime(unixtime);
}
}
]],
pagination: true,//表示在datagrid设置分页
rownumbers: true,
singleSelect: true
});
dg.datagrid('getPager').pagination({
pageSize: 10,
pageNumber: 1,
pageList: [10, 20, 30, 40, 50],
beforePageText: '第',//页数文本框前显示的汉字
afterPageText: '页 共 {pages} 页',
displayMsg: '当前显示 {from} - {to} 条记录 共 {total} 条记录',
});
});
/**************** 主要业务程序 ***************/
//查询方法
function SearchInfo() {
var StartTime = $('#StartTime_s').datetimebox('getValue');
var EndTime = $('#EndTime_s').datetimebox('getValue');
var BoxNo = $('#BoxNo_s').val();
var PartNo2 = $('#PartNo2_s').val();
var PartNo1 = $('#PartNo1_s').val();
var OrderNo = $('#OrderNo_s').val();
var queryParams = {
StartTime: StartTime,
EndTime: EndTime,
BoxNo: BoxNo,
PartNo2: PartNo2,
PartNo1: PartNo1,
OrderNo: OrderNo
};
dg.datagrid({
queryParams: queryParams
});
dg.datagrid('reload');
}
/**************** 辅助业务程序 ***************/
/**********************************************/
/***************** 窗体程序 *******************/
/**********************************************/
function ww4(date) {
var y = date.getFullYear();
var m = date.getMonth() + 1;
var d = date.getDate();
return y + '-' + (m < 10 ? ('0' + m) : m) + '-' + (d < 10 ? ('0' + d) : d);
}
</script>
</form>
</body>
</html>