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
11 KiB

<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="SCP_PO_CREATE_ASK.aspx.cs" Inherits="SCP.长春安通林.SCP_PO_CREATE_ASK" %>
<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
<title></title>
</head>
<body>
<form id="form1" runat="server">
<f:PageManager runat="server" AutoSizePanelID="Panel1" />
<f:Panel ID="Panel1" runat="server" Title="" AutoScroll="True">
<Toolbars>
<f:Toolbar ID="Toolbar2" runat="server">
<Items>
<f:Button ID="BTN_REFRESH" runat="server" EnablePostBack="True" Text="刷新" Icon="box">
</f:Button>
<f:Button ID="btnRelease" runat="server" EnablePostBack="True" OnClick="btnRelease_Click" Text="生成要货看板" Icon="CssAdd" OnClientClick="if(!confirm('是否要发布?'))return false;">
</f:Button>
<%-- <f:Button ID="btnCancel" runat="server" EnablePostBack="True" OnClick="btnCancel_Click" Text="取消发布" Icon="CssAdd" OnClientClick="if(!confirm('是否要发布?'))return false;">
</f:Button>--%>
<%-- <f:Button ID="btnReject" runat="server" EnablePostBack="True" OnClick="btnReject_Click" Text="作废" Icon="CssAdd" OnClientClick="if(!confirm('是否作废该订单?'))return false;">
</f:Button>--%>
<%-- <f:Button ID="btnContract" runat="server" EnablePostBack="True" OnClick="btnContract_Click" Text="合同校验" Icon="CssAdd" OnClientClick="if(!confirm('是否作废该订单?'))return false;">
</f:Button> --%>
</Items>
</f:Toolbar>
</Toolbars>
<Items>
<f:Form runat="server" Title="" Margin="5">
<Items>
<f:FormRow runat="server" ColumnWidths="25% 25% 25% 25%">
<Items>
<f:TextBox runat = "server" Label = "订单状态" EmptyText = "" ID = "TXT_State_DESC" />
<f:TextBox runat = "server" Label = "订单编号" EmptyText = "" ID = "TXT_PoBillNum" />
<f:TextBox runat = "server" Label = "供应商" EmptyText = "" ID = "TXT_VendName" />
<f:TextBox runat = "server" Label = "供应商编号" EmptyText = "" ID = "TXT_VendId" />
</Items>
</f:FormRow>
<f:FormRow runat="server" ColumnWidths="33% 33% 33%">
<Items>
<f:DatePicker runat="server" Required ="true" DateFormatString="yyyy-MM-dd" Label="要货日期" EmptyText="请选择日期" ID="DP_BeginTime" />
<f:TextBox runat = "server" Label = "发往地点" EmptyText = "" ID = "TXT_Site" />
<%-- <f:DropDownList ID="DDL_PORT" DataTextField="PORT_DESCRIPTION" DataValueField="PORT_NO" Required="true" runat="server" Label="收货口">
</f:DropDownList>--%>
<f:TextBox ID="txtRemark" runat="server" Label="备注" Text="">
</f:TextBox>
</Items>
</f:FormRow>
</Items>
</f:Form>
<f:HiddenField ID="HF_GRID_INDEX" runat="server"></f:HiddenField>
<f:Grid ID = "Grid_V_TB_PO_DETAIL" EnableCollapse = "true" ShowBorder = "true" EnableMultiSelect="true" ShowHeader = "true" runat ="server" EnableCheckBoxSelect = "true"
DataKeyNames = "UID,PoBillNum,PoLine,PartCode,PlanQty,ShippedQty,ReceivedQty,RejectQty,BeginTime,EndTime,PoUnit,LocUnit,Price,Currency,PackQty,UnConv,DockCode,State,Remark,CreateTime,CreateUser,UpdateTime,UpdateUser,UpdateInfo,IsDeleted,PartDesc1,CurrencyDesc,ErpBillNum,ModType,Contacter,Site,Buyer,BuyerPhone,VendName,PartDesc2,TempQty,PublishQty,ReceivedPort"
SortField="PoLine"
AllowPaging="True"
AllowCellEditing="true" ClicksToEdit="2"
IsDatabasePaging="true" PageSize="100" OnPageIndexChange="Grid_V_TB_PO_DETAIL_PageIndexChange"
OnRowDataBound="Grid_V_TB_PO_DETAIL_RowDataBound"
>
<PageItems>
<f:ToolbarSeparator ID="ToolbarSeparator1" runat="server">
</f:ToolbarSeparator>
<f:ToolbarText ID="ToolbarText1" runat="server" Text="每页记录数:">
</f:ToolbarText>
<f:DropDownList ID="ddlGridPageSize" Width="80px" AutoPostBack="true" OnSelectedIndexChanged="ddlGridPageSize_SelectedIndexChanged"
runat="server">
<f:ListItem Text="100" Value="100" />
<f:ListItem Text="500" Value="500" />
</f:DropDownList>
</PageItems>
<Columns>
<%--<f:BoundField Width = "100px" DataField = "PoBillNum" DataFormatString = "{0}" HeaderText = "订单号" />--%>
<f:BoundField Width="50px" DataField="State_DESC" HeaderText="状态"></f:BoundField>
<f:BoundField Width="80px" DataField="ProjectId" HeaderText="项目编号"></f:BoundField>
<f:BoundField Width = "50px" DataField = "PoLine" DataFormatString = "{0}" HeaderText = "行号" />
<f:BoundField Width = "100px" DataField = "PartDesc1" DataFormatString = "{0}" HeaderText = "零件名称" />
<f:BoundField Width = "80px" DataField = "PartCode" DataFormatString = "{0}" HeaderText = "零件编码" />
<%--<f:TemplateField HeaderText="要货数量" Width="70px">
<ItemTemplate>
<asp:TextBox ID="NB_PublishNum" runat="server" Width="60px" Text="0"></asp:TextBox>
</ItemTemplate>
</f:TemplateField>--%>
<f:RenderField Width="100px" ColumnID="PublishQty" DataField="PublishQty" FieldType="Float"
HeaderText="要货数量">
<Editor>
<f:NumberBox ID="NB_PublishNum" runat="server" MinValue="0"
MaxValue="99999999" DecimalPrecision="3" >
</f:NumberBox>
</Editor>
</f:RenderField>
<f:BoundField Width = "80px" DataField = "PlanQty" DataFormatString = "{0:F}" HeaderText = "订单数量" />
<f:BoundField Width = "100px" DataField = "TempQty" DataFormatString = "{0:F}" HeaderText = "已要数量" />
<f:RenderField Width="100px" ColumnID="ReceivedPort" DataField="ReceivedPort_Desc" FieldType="String"
RendererFunction="renderPort" HeaderText="收货口">
<Editor>
<f:DropDownList ID="DDL_ReceivedPort" DataTextField="PORT_DESCRIPTION" DataValueField="PORT_NO" Required="true" runat="server">
</f:DropDownList>
</Editor>
</f:RenderField>
<f:RenderField Width="120px" ColumnID="EndTime" DataField="EndTime" FieldType="Date"
Renderer="Date" RendererArgument="yyyy-MM-dd" HeaderText="到货日期">
<Editor>
<f:DatePicker ID="DatePicker1" Required="true" runat="server">
</f:DatePicker>
</Editor>
</f:RenderField>
<f:BoundField Width = "50px" DataField = "PoUnit" DataFormatString = "{0}" Hidden="true" HeaderText = "单位" />
<%-- <f:BoundField Width = "80px" DataField = "Price" DataFormatString = "{0}" HeaderText = "价格" Hidden="true"/> --%>
<f:RenderField Width="100px" ColumnID="Price" DataField = "Price" FieldType="Float" Hidden="true"
HeaderText="价格">
<Editor>
<f:NumberBox ID="NumberBox1" runat="server" MinValue="0"
MaxValue="99999999" DecimalPrecision="3" >
</f:NumberBox>
</Editor>
</f:RenderField>
<f:BoundField Width = "50px" DataField = "CurrencyDesc" DataFormatString = "{0}" HeaderText = "币种" Hidden="true" />
</Columns>
</f:Grid>
</Items>
</f:Panel>
<f:Window runat="server" ID="Window1" Hidden="True"
WindowPosition="Center" IsModal="true" Title="Popup Window 1" Target="Parent" EnableIFrame="true"
IFrameUrl="about:blank" Height="840px" Width="900px" OnClose="Window1_Close" />
<f:Window ID="WindowUpload" runat="server" Hidden="True"
WindowPosition="Center" IsModal="true" Title="Popup Window 1" Target="Parent" EnableIFrame="true"
IFrameUrl="about:blank" Height="200px" Width="400px">
</f:Window>
<f:HiddenField ID="highlightRows" runat="server">
</f:HiddenField>
</form>
<script>
var ddlPortID = '<%= DDL_ReceivedPort.ClientID %>';
function renderPort(value) {
return F(ddlPortID).f_getTextByValue(value);
}
var highlightRowsClientID = '<%= highlightRows.ClientID %>';
var gridClientID = '<%= Grid_V_TB_PO_DETAIL.ClientID %>';
function highlightRows() {
// 增加延迟,等待HiddenField更新完毕
window.setTimeout(function () {
var highlightRows = F(highlightRowsClientID);
var grid = F(gridClientID);
$(grid.el.dom).find('.x-grid-item.highlight').removeClass('highlight');
$.each(highlightRows.getValue().split(','), function (index, item) {
if (item !== '') {
var row = grid.getView().getNode(parseInt(item, 10));
$(row).addClass('highlight');
}
});
}, 100);
}
// 页面第一个加载完毕后执行的函数
F.ready(function () {
var grid = F(gridClientID);
grid.on('columnhide', function () {
highlightRows();
});
grid.on('columnshow', function () {
highlightRows();
});
grid.getStore().on('refresh', function () {
highlightRows();
});
highlightRows();
});
</script>
</body>
</html>