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.
65 lines
2.1 KiB
65 lines
2.1 KiB
<#import "../master.ftl" as master>
|
|
<@master.layout>
|
|
<style>
|
|
#fm label {
|
|
width: 150px;
|
|
}
|
|
</style>
|
|
|
|
<div class="page-header">
|
|
<h3>Automatically count by SO quantity</h3>
|
|
</div>
|
|
<div id="tb" style="padding:10px 5px;">
|
|
<div>
|
|
So Order No: <input class="easyui-textbox" id="orderNo" style="width:260px">
|
|
<input type="hidden" id="orderNoSearch" value="">
|
|
<a id="queryLink" class="easyui-linkbutton" iconCls="icon-search">Search</a>
|
|
|
|
<a href="javascript:void(0)" id="downExcel" class="easyui-linkbutton" iconCls="icon-add" onclick="downExcel()">Export to Excel</a>
|
|
</div>
|
|
</div>
|
|
<table id="dg" class="easyui-datagrid" style="width:100%;height:460px;"
|
|
data-options="singleSelect:true,collapsible:false,toolbar:'#tb'">
|
|
<thead>
|
|
<tr>
|
|
<th data-options="field:'orderNo',width:175,editor:'textbox'">Order No</th>
|
|
<th data-options="field:'operationDesc',width:320,editor:'textbox'">Operation Desc</th>
|
|
<th data-options="field:'qtyInput',width:180,editor:'textbox'">Input</th>
|
|
<th data-options="field:'qtyOutput',width:180,editor:'textbox'">Output</th>
|
|
</tr>
|
|
</thead>
|
|
</table>
|
|
<script>
|
|
//设置宽度
|
|
$(window).resize(function () {
|
|
$("#dg").datagrid({"height": $(window).height() - $(".datagrid").offset().top - 20});
|
|
});
|
|
|
|
$(function () {
|
|
$(window).resize();
|
|
});
|
|
|
|
$("#queryLink").click(function(){
|
|
var dg = $('#dg').datagrid({
|
|
url: '/prepress/soOrderInfo',
|
|
queryParams: {orderNo: $("#orderNo").val()},
|
|
pagination: false
|
|
});
|
|
$('dg').datagrid('load');
|
|
$("#orderNoSearch").val($("#orderNo").val());
|
|
});
|
|
//导出
|
|
function downExcel(){
|
|
var orderNoSearch = $("#orderNoSearch").val();
|
|
if(orderNoSearch!=null && orderNoSearch!=""){
|
|
//拼接url
|
|
var url = "/prepress/downSoOrderInfo?orderNoSearch="+encodeURIComponent(orderNoSearch);
|
|
//设置href
|
|
$("#downExcel").attr("href", url);
|
|
} else {
|
|
$.messager.alert('Error','No query results yet!', 'error');
|
|
}
|
|
}
|
|
</script>
|
|
</@master.layout>
|
|
|