ruoxing.wang
5 months ago
13 changed files with 495 additions and 135 deletions
@ -0,0 +1,225 @@ |
|||||
|
<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="StockInTest.aspx.cs" Inherits="MESWebSite.Manage.StockInTest" %> |
||||
|
|
||||
|
|
||||
|
<!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: left; |
||||
|
width: 80px; |
||||
|
height: 40px; |
||||
|
padding: 0px; |
||||
|
} |
||||
|
|
||||
|
p { |
||||
|
padding: 0px 5px; |
||||
|
font-size: small; |
||||
|
font-family: 微软雅黑; |
||||
|
margin: 0px; |
||||
|
} |
||||
|
|
||||
|
.tree-folder-open, .tree-folder, .tree-file { |
||||
|
display: none; |
||||
|
} |
||||
|
|
||||
|
.datagrid { |
||||
|
text-align: center; |
||||
|
} |
||||
|
|
||||
|
.ttb { |
||||
|
width: 180px; |
||||
|
display: block; |
||||
|
}*/ |
||||
|
</style> |
||||
|
<title>喷涂入库记录</title> |
||||
|
<script> |
||||
|
|
||||
|
|
||||
|
</script> |
||||
|
</head> |
||||
|
<body> |
||||
|
<form id="form1" runat="server"> |
||||
|
<div class="top"> |
||||
|
<table cellpadding="0" cellspacing="0" style="width: 100%"> |
||||
|
<thead> |
||||
|
<tr> |
||||
|
<td><span class="title">喷涂入库记录</span></td> |
||||
|
</tr> |
||||
|
</thead> |
||||
|
|
||||
|
<tbody> |
||||
|
<tr> |
||||
|
|
||||
|
<td style="width: 415px;">班次: |
||||
|
<select name="workClass" id="fl_workClass_s" class="easyui-combobox"> |
||||
|
<option value=""></option> |
||||
|
<option value="A班">A班</option> |
||||
|
<option value="B班">B班</option> |
||||
|
</select> |
||||
|
|
||||
|
颜色: |
||||
|
<select id="fl_color_s" class="easyui-combobox" style="width: 80px; height: 30px;" |
||||
|
data-options="valueField: 'valueField',textField: 'textField'"> |
||||
|
</select> |
||||
|
产品: |
||||
|
<select id="fl_productInfo_s" class="easyui-combobox" style="width: 150px; height: 30px;" |
||||
|
data-options="valueField: 'ProductName',textField: 'ProductName'"> |
||||
|
</select> |
||||
|
时间: |
||||
|
<input id="start_time" class="easyui-datetimebox" data-options="onShowPanel:function(){ $(this).datetimebox('spinner').timespinner('setValue','00:00:00');}" /> 至 |
||||
|
<input id="end_time" class="easyui-datetimebox" data-options="onShowPanel:function(){ $(this).datetimebox('spinner').timespinner('setValue','23:59:59');}" /> |
||||
|
|
||||
|
<a class="topsearchBtn">查询</a> |
||||
|
|
||||
|
<a class="topexcelBtn" id="exportbtn">导出</a> |
||||
|
<%-- @for(int i=0;i<5;1++){ |
||||
|
<p>Line @i</p> |
||||
|
}--%> |
||||
|
</td> |
||||
|
</tr> |
||||
|
</tbody> |
||||
|
</table> |
||||
|
</div> |
||||
|
<table id="tb" title="喷涂入库记录" style="width: 99%;"> |
||||
|
</table> |
||||
|
|
||||
|
<input id="UserID" type="text" hidden="hidden" runat="server" /> |
||||
|
|
||||
|
<script> |
||||
|
var dg = $("#tb"); |
||||
|
|
||||
|
$(document).ready( |
||||
|
alert("23234"); |
||||
|
); |
||||
|
|
||||
|
$(function () { |
||||
|
reloadfl_color_s(); |
||||
|
reloadfl_productInfo_s(); |
||||
|
|
||||
|
$('.topsearchBtn').first().click(function () { |
||||
|
SearchInfo(); |
||||
|
}); |
||||
|
|
||||
|
//排序 |
||||
|
function sorts(obj, sortName, sortOrder) { |
||||
|
var queryParams = $('#' + obj).datagrid('options').queryParams; |
||||
|
queryParams.sortName = sortName; |
||||
|
queryParams.sortOrder = sortOrder; |
||||
|
console.log(queryParams.sortOrder) |
||||
|
$('#' + obj).datagrid('reload'); |
||||
|
} |
||||
|
|
||||
|
dg = $('#tb').datagrid({ |
||||
|
fitColumns: true, |
||||
|
nowrap: false, |
||||
|
striped: true, |
||||
|
collapsible: true, |
||||
|
url: "/HttpHandlers/StockInHandler.ashx?method=QueryList", |
||||
|
queryParams: { "sortName": "", "sortOrder": "desc" }, |
||||
|
remoteSort: false, |
||||
|
columns: [[ |
||||
|
{ field: 'ID', title: 'ID', hidden: true }, |
||||
|
{ field: 'barcode', title: '条码', sortable: 'true', width: 100 }, |
||||
|
{ field: 'workClass', title: '班次', sortable: 'true', width: 10 }, |
||||
|
{ field: 'productInfo', title: '产品', sortable: 'true', width: 100 }, |
||||
|
{ |
||||
|
field: 'pass', title: '状态', sortable: 'true', width: 20, |
||||
|
formatter: function (value, row) { |
||||
|
if (row.pass == 1) { |
||||
|
return '合格入库'; |
||||
|
} |
||||
|
else if (row.pass == 2) { |
||||
|
return '报废'; |
||||
|
} |
||||
|
else if (row.pass == 0) { |
||||
|
return '点修'; |
||||
|
} |
||||
|
} |
||||
|
}, |
||||
|
{ |
||||
|
field: 'createTime', title: '入库时间', sortable: 'true', width: 50, |
||||
|
formatter: function (date) { |
||||
|
var pa = /.*\((.*)\)/; |
||||
|
var unixtime = date.match(pa)[1].substring(0, 10); |
||||
|
return getTime(unixtime); |
||||
|
} |
||||
|
}, |
||||
|
]], |
||||
|
onSortColumn: function (sort, order) { |
||||
|
sorts('tb', sort, order);//调用排序方法。 |
||||
|
}, |
||||
|
pagination: true,//表示在datagrid设置分页 |
||||
|
rownumbers: true, |
||||
|
singleSelect: true |
||||
|
}); |
||||
|
|
||||
|
dg.datagrid('getPager').pagination({ |
||||
|
pageSize: 10, |
||||
|
pageNumber: 1, |
||||
|
pageList: [10, 20, 30, 40, 50, 100], |
||||
|
beforePageText: '第',//页数文本框前显示的汉字 |
||||
|
afterPageText: '页 共 {pages} 页', |
||||
|
displayMsg: '当前显示 {from} - {to} 条记录 共 {total} 条记录', |
||||
|
}); |
||||
|
}); |
||||
|
|
||||
|
function reloadfl_color_s() { |
||||
|
$('#fl_color_s').combobox("reload", '/HttpHandlers/ColorHandler.ashx?method=QueryForCombobox') |
||||
|
} |
||||
|
function reloadfl_productInfo_s() { |
||||
|
$('#fl_productInfo_s').combobox("reload",'/HttpHandlers/ProductHandler.ashx?method=GetComboboxProduct1&ProductTypeNo=2000'); |
||||
|
} |
||||
|
|
||||
|
|
||||
|
|
||||
|
|
||||
|
|
||||
|
function SearchInfo() { |
||||
|
var workClass = $('#fl_workClass_s').combobox('getValue'); |
||||
|
|
||||
|
var color = $('#fl_color_s').combobox('getValue'); |
||||
|
var productInfo = $('#fl_productInfo_s').combobox('getValue'); |
||||
|
alert('workClass=' + workClass + ' color=' + color + ' product=' + product); |
||||
|
var StartTime = $('#start_time').datetimebox('getValue'); |
||||
|
var EndTime = $('#end_time').datetimebox('getValue'); |
||||
|
|
||||
|
var queryParams = { |
||||
|
|
||||
|
workClass: workClass, |
||||
|
color: color, |
||||
|
productInfo: productInfo, |
||||
|
StartTime: StartTime, |
||||
|
EndTime: EndTime, |
||||
|
"sortName": "", |
||||
|
"sortOrder": "desc" |
||||
|
}; |
||||
|
dg.datagrid( |
||||
|
{ |
||||
|
queryParams: queryParams |
||||
|
} |
||||
|
); |
||||
|
|
||||
|
} |
||||
|
</script> |
||||
|
|
||||
|
</form> |
||||
|
</body> |
||||
|
</html> |
@ -0,0 +1,17 @@ |
|||||
|
using System; |
||||
|
using System.Collections.Generic; |
||||
|
using System.Linq; |
||||
|
using System.Web; |
||||
|
using System.Web.UI; |
||||
|
using System.Web.UI.WebControls; |
||||
|
|
||||
|
namespace MESWebSite.Manage |
||||
|
{ |
||||
|
public partial class StockInTest : System.Web.UI.Page |
||||
|
{ |
||||
|
protected void Page_Load(object sender, EventArgs e) |
||||
|
{ |
||||
|
|
||||
|
} |
||||
|
} |
||||
|
} |
@ -0,0 +1,35 @@ |
|||||
|
//------------------------------------------------------------------------------
|
||||
|
// <自动生成>
|
||||
|
// 此代码由工具生成。
|
||||
|
//
|
||||
|
// 对此文件的更改可能导致不正确的行为,如果
|
||||
|
// 重新生成代码,则所做更改将丢失。
|
||||
|
// </自动生成>
|
||||
|
//------------------------------------------------------------------------------
|
||||
|
|
||||
|
namespace MESWebSite.Manage |
||||
|
{ |
||||
|
|
||||
|
|
||||
|
public partial class StockInTest |
||||
|
{ |
||||
|
|
||||
|
/// <summary>
|
||||
|
/// form1 控件。
|
||||
|
/// </summary>
|
||||
|
/// <remarks>
|
||||
|
/// 自动生成的字段。
|
||||
|
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
|
/// </remarks>
|
||||
|
protected global::System.Web.UI.HtmlControls.HtmlForm form1; |
||||
|
|
||||
|
/// <summary>
|
||||
|
/// UserID 控件。
|
||||
|
/// </summary>
|
||||
|
/// <remarks>
|
||||
|
/// 自动生成的字段。
|
||||
|
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
|
/// </remarks>
|
||||
|
protected global::System.Web.UI.HtmlControls.HtmlInputText UserID; |
||||
|
} |
||||
|
} |
Loading…
Reference in new issue