TML
4 years ago
8 changed files with 1345 additions and 11 deletions
@ -0,0 +1,206 @@ |
|||||
|
<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="SCP_PO_EXTEND.aspx.cs" Inherits="SCP.Views.富维冲插件.SCP_PO_EXTEND" %> |
||||
|
|
||||
|
<!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> |
||||
|
<%--<script src="../../Scripts/ajaxfileupload.js"></script> |
||||
|
<script> |
||||
|
function ajaxFileUpLoad() { |
||||
|
$.ajaxFileUpload( |
||||
|
{ |
||||
|
url: '../../Handlers/FileUpload.ashx?method=ajaxFileUpload', |
||||
|
secureuri: false, |
||||
|
fileElementId: 'fileToUpload', |
||||
|
dataType: 'json', |
||||
|
success: function (data, status) { |
||||
|
$('#img1').attr("src", data.imgurl); |
||||
|
if (typeof (data.error) != 'undefined') { |
||||
|
if (data.error != '') { |
||||
|
alert(data.error); |
||||
|
} else { |
||||
|
alert(data.msg); |
||||
|
} |
||||
|
} |
||||
|
}, |
||||
|
error: function (data, status, e) { |
||||
|
alert(e); |
||||
|
} |
||||
|
} |
||||
|
) |
||||
|
return false; |
||||
|
} |
||||
|
</script>--%> |
||||
|
</head> |
||||
|
<body> |
||||
|
<form id="form1" runat="server"> |
||||
|
<f:PageManager runat="server" AutoSizePanelID="Panel1" /> |
||||
|
<f:Panel ID="Panel1" runat="server" Title="" AutoScroll="True" Layout="VBox" > |
||||
|
<Toolbars> |
||||
|
<f:Toolbar ID="Toolbar2" runat="server"> |
||||
|
<Items> |
||||
|
<f:ToolbarSeparator runat="server" /> |
||||
|
<f:Button ID="Button3" runat="server" EnablePostBack="false" Text="刷新" Icon="Reload" OnClientClick="location.reload();"> |
||||
|
</f:Button> |
||||
|
|
||||
|
<f:ToolbarSeparator runat="server" /> |
||||
|
<f:Button ID="btnOutput" runat="server" Text="导出" Icon="PageExcel" OnClick="btnOutput_Click" > |
||||
|
</f:Button> |
||||
|
<f:Button ID="btnDetail" runat="server" Text="明细" Icon="Zoom" OnClick="btnDetail_Click"> |
||||
|
</f:Button> |
||||
|
<f:ToolbarSeparator runat="server" /> |
||||
|
<f:Button ID="BTN_CREATE" runat="server" EnablePostBack="True" Text="创建看板" Icon="Add" OnClick="BTN_CREATE_Click" > |
||||
|
</f:Button> |
||||
|
<f:Button ID="Button1" runat="server" EnablePostBack="True" Text="创建订单" Icon="Add" OnClick="BTN_CREATE_Click1" > |
||||
|
</f:Button> |
||||
|
<f:Button ID="btnShow" runat="server" Text="显示查询面板" Icon="Find" OnClick="btnShow_Click"> |
||||
|
</f:Button> |
||||
|
<f:Button ID="btnModeType1" runat="server" Text="日程单" Icon="Reload" OnClick="btnModeType1_Click" > |
||||
|
</f:Button> |
||||
|
<f:Button ID="btnModeType2" runat="server" Text="离散单" Icon="Reload" OnClick="btnModeType2_Click" > |
||||
|
</f:Button> |
||||
|
<f:RadioButtonList runat="server" Label="订单类型" ID="rblist" Hidden="true" > |
||||
|
<f:RadioItem Text="日程单" Value="1" /> |
||||
|
<f:RadioItem Text="离散单" Value="2"/> |
||||
|
</f:RadioButtonList> |
||||
|
<f:ToolbarSeparator runat="server" /> |
||||
|
<f:FileUpload runat="server" ID="FileUp" EmptyText="请选择要货单据" Required="true" Width="200" ButtonIcon="Add" ShowRedStar="true"> </f:FileUpload> |
||||
|
<f:Button ID="btnInput_Contract" runat="server" Text="日程单导入" Icon="PageExcel" OnClick="btnInput_Click_Contract" > |
||||
|
</f:Button> |
||||
|
<f:Button ID="btnInput_Non_Contract" runat="server" Text="离散单导入" Icon="PageExcel" OnClick="btnInput_Click_Non_Contract" > |
||||
|
</f:Button> |
||||
|
</Items> |
||||
|
</f:Toolbar> |
||||
|
</Toolbars> |
||||
|
<Items> |
||||
|
<f:Form runat="server" Margin="5" ID="gp1" Hidden="true" BodyPadding ="5"> |
||||
|
<Rows> |
||||
|
<f:FormRow runat="server" ColumnWidths="33% 33% 33%"> |
||||
|
<Items> |
||||
|
<f:TextBox runat = "server" Label = "订单编号" EmptyText = "" ID = "TXT_BillNo" /> |
||||
|
<f:DropDownList runat="server" ID="DropDownList1" Label="地点" DataTextField="FactoryName" DataValueField=" ErpDomain"> |
||||
|
</f:DropDownList> |
||||
|
<f:TextBox runat = "server" Label = "供应商编码" EmptyText = "" ID = "TXT_Vendid" /> |
||||
|
</Items> |
||||
|
</f:FormRow> |
||||
|
<f:FormRow runat="server" ColumnWidths="33% 33% 33%"> |
||||
|
<Items> |
||||
|
<f:TextBox runat = "server" Label = "供应商名称" EmptyText = "" ID = "TXT_VendName" /> |
||||
|
<f:TextBox runat = "server" Label = "项目编码" EmptyText = "" ID = "TXT_ProjectId" /> |
||||
|
<f:DropDownList runat="server" ID="DDL_State" Label="状态"> |
||||
|
<f:ListItem Text="-" Value=""/> |
||||
|
<f:ListItem Text="关闭" Value="0" /> |
||||
|
<f:ListItem Text="开放" Value="1" /> |
||||
|
</f:DropDownList> |
||||
|
</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_StartDate" /> |
||||
|
<f:DatePicker runat="server" Required ="true" DateFormatString="yyyy-MM-dd" Label="至" EmptyText="请选择日期" ID="DP_EndDate" /> |
||||
|
<f:TextBox runat="server" Required ="true" Label="零件编号" EmptyText="查询请填写零件编号" ID="TXT_PartCode" /> |
||||
|
|
||||
|
</Items> |
||||
|
</f:FormRow> |
||||
|
<f:FormRow runat="server" > |
||||
|
<Items> |
||||
|
<f:Panel ID="Panel5" runat="server" ShowBorder="false" CssClass="mypanel" ShowHeader="false"> |
||||
|
<Items> |
||||
|
<f:Button runat="server" Text="关闭" ID="BtnClose" OnClick="BtnClose_Click" Margin="5" ></f:Button> |
||||
|
<f:Button ID="BtnSearch" runat="server" OnClick="BtnSearch_Click" Text="快速查找订单" Margin="5" > |
||||
|
</f:Button> |
||||
|
<f:Button ID="BtnSearchDetail" runat="server" OnClick="BtnSearchDetail_Click" Text="快速查找订单明细" Margin="5" > |
||||
|
</f:Button> |
||||
|
</Items> |
||||
|
</f:Panel> |
||||
|
|
||||
|
</Items> |
||||
|
</f:FormRow> |
||||
|
</Rows> |
||||
|
</f:Form> |
||||
|
<f:Panel ID="Panel2" |
||||
|
runat="server" BodyPadding="0px" ShowBorder="true" BoxFlex="1" ShowHeader="false" Layout="HBox" AutoScroll="True"> |
||||
|
<Items> |
||||
|
<f:Panel ID="Panel3" |
||||
|
runat="server" BodyPadding="0px" ShowBorder="true" ShowHeader="false" BoxFlex="1" Layout="VBox" AutoScroll="True" > |
||||
|
<Items> |
||||
|
<f:Grid ID = "Grid_V_TB_PO" ColumnWidth="45%" PageSize="50" ShowBorder = "true" ShowHeader = "true" runat ="server" EnableCheckBoxSelect = "true" DataKeyNames = "UID,PoBillNum,ErpBillNum,VendId,ModType,Contacter,Site,Buyer,BuyerPhone,State,Remark,CreateTime,CreateUser,UpdateTime,UpdateUser,UpdateInfo,IsDeleted,VendName,State_DESC,ModType_DESC" |
||||
|
CssClass="maingrid" EnableRowDoubleClickEvent="True" OnSort="Grid_V_TB_PO_Sort" SortField="BeginTime" |
||||
|
IsDatabasePaging="True" AllowPaging="True" OnRowSelect="Grid_V_TB_PO_RowSelect" EnableRowSelectEvent="true" |
||||
|
AutoScroll="True" SortDirection="DESC" OnPageIndexChange="Grid_V_TB_PO_PageIndexChange" BoxFlex="1" > |
||||
|
<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="50" Value="50" /> |
||||
|
<f:ListItem Text="100" Value="100" /> |
||||
|
<f:ListItem Text="200" Value="200" /> |
||||
|
</f:DropDownList> |
||||
|
</PageItems> |
||||
|
<Columns> |
||||
|
<f:BoundField Width = "60px" DataField = "State" DataFormatString = "{0}" HeaderText = "状态" Hidden="true" /> |
||||
|
<f:BoundField Width = "60px" DataField = "State_DESC" DataFormatString = "{0}" HeaderText = "状态" /> |
||||
|
<f:BoundField Width = "80px" DataField = "ModType_DESC" DataFormatString = "{0}" HeaderText = "单据类型" /> |
||||
|
<f:BoundField Width = "100px" DataField = "PoBillNum" DataFormatString = "{0}" HeaderText = "订单号" /> |
||||
|
<f:BoundField Width = "100px" DataField = "ErpBillNum" DataFormatString = "{0}" HeaderText ="项目编号" /> |
||||
|
<f:BoundField Width = "100px" DataField = "VendName" DataFormatString = "{0}" HeaderText = "供应商" /> |
||||
|
<f:BoundField Width = "100px" DataField = "VendId" DataFormatString = "{0}" HeaderText = "供应商编码" /> |
||||
|
<%--<f:BoundField Width = "100px" DataField = "Contacter" DataFormatString = "{0}" HeaderText = "发布人" />--%> |
||||
|
<f:BoundField Width = "100px" DataField = "BeginTime" DataFormatString = "{0:yyyy-MM-dd}" HeaderText = "订货日期" /> |
||||
|
<%--<f:BoundField Width = "100px" DataField = "Site_Desc" DataFormatString = "{0}" HeaderText = "地点" />--%> |
||||
|
<f:BoundField Width = "100px" DataField = "Buyer" DataFormatString = "{0}" HeaderText = "收货人" /> |
||||
|
<%--<f:BoundField Width = "100px" DataField = "BuyerPhone" DataFormatString = "{0}" HeaderText = "收货电话" />--%> |
||||
|
</Columns> |
||||
|
</f:Grid> |
||||
|
</Items> |
||||
|
</f:Panel> |
||||
|
<f:Panel ID="Panel4" |
||||
|
runat="server" BodyPadding="0px" ShowBorder="true" ShowHeader="false" Layout="VBox" BoxFlex="1" > |
||||
|
<Items> |
||||
|
<f:Grid ID = "Grid_V_TB_PO_DETAIL" ShowBorder = "true" EnableMultiSelect="true" ShowHeader = "true" runat ="server" |
||||
|
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" |
||||
|
SortField="PoLine" |
||||
|
AllowPaging="True" |
||||
|
ColumnWidth="55%" SortDirection="DESC" |
||||
|
PageSize="500" BoxFlex="1" > |
||||
|
<Columns> |
||||
|
<f:BoundField Width = "80px" DataField="ProjectId" HeaderText="项目编号"></f:BoundField> |
||||
|
<f:BoundField Width = "40px" DataField = "PoLine" DataFormatString = "{0}" HeaderText = "行号" /> |
||||
|
<f:BoundField Width = "150px" DataField = "PartDesc1" DataFormatString = "{0}" HeaderText = "零件名称" /> |
||||
|
<f:BoundField Width = "100px" DataField = "PartCode" DataFormatString = "{0}" HeaderText = "零件编码" /> |
||||
|
<f:BoundField Width = "80px" DataField = "PlanQty" DataFormatString = "{0:F}" HeaderText = "订单数量" /> |
||||
|
<f:BoundField Width = "80px" DataField = "TempQty" DataFormatString = "{0:F}" HeaderText = "已要数量" /> |
||||
|
<f:BoundField Width = "80px" DataField = "ShippedQty" DataFormatString = "{0:F}" HeaderText = "发货数量" /> |
||||
|
<f:BoundField Width = "80px" DataField = "ReceivedQty" DataFormatString = "{0:F}" HeaderText = "收货数量" /> |
||||
|
<f:BoundField Width = "80px" DataField = "RejectQty" DataFormatString = "{0:F}" HeaderText = "退货数量" /> |
||||
|
<f:BoundField Width = "100px" DataField = "EndTime" DataFormatString = "{0:yyyy-MM-dd}" HeaderText = "到货日期" /> |
||||
|
<f:BoundField Width = "50px" DataField = "PoUnit" DataFormatString = "{0}" Hidden="true" HeaderText = "单位" /> |
||||
|
</Columns> |
||||
|
</f:Grid> |
||||
|
</Items> |
||||
|
</f:Panel> |
||||
|
|
||||
|
</Items> |
||||
|
</f:Panel> |
||||
|
|
||||
|
</Items> |
||||
|
</f:Panel> |
||||
|
<f:Window runat="server" ID="Window1" Hidden="True" Height="600px" Width="950px" AutoScroll="True" OnClose="Window1_Close" |
||||
|
WindowPosition="Center" IsModal="true" Title="明细详情" Target="Parent" EnableIFrame="true" |
||||
|
IFrameUrl="about:blank" /> |
||||
|
<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:Window runat="server" ID="Window2" Hidden="True" AutoScroll="false" Width="800px" Height="350px" CloseAction="HidePostBack" |
||||
|
WindowPosition="Center" IsModal="true" Title="增加离散订单" Target="Parent" EnableIFrame="true" |
||||
|
IFrameUrl="about:blank" /> |
||||
|
</form> |
||||
|
</body> |
||||
|
</html> |
@ -0,0 +1,310 @@ |
|||||
|
using System; |
||||
|
using System.Collections.Generic; |
||||
|
using System.Linq; |
||||
|
using System.Web; |
||||
|
using System.Web.UI; |
||||
|
using System.Web.UI.WebControls; |
||||
|
using CK.SCP.Models.ScpEntity; |
||||
|
using CK.SCP.Utils; |
||||
|
using CK.SCP.Controller; |
||||
|
using FineUI; |
||||
|
using System.IO; |
||||
|
using System.Data; |
||||
|
using CK.SCP.Models.ScpEntity.ExcelImportEntity; |
||||
|
using CK.SCP.Models.Enums; |
||||
|
using CK.SCP.Common; |
||||
|
using CK.SCP.Models; |
||||
|
using System.Text; |
||||
|
using CK.SCP.Models.ScpEntity.ExcelExportEnttity; |
||||
|
|
||||
|
namespace SCP.Views.富维冲插件 |
||||
|
{ |
||||
|
public partial class SCP_PO_EXTEND : PageBase |
||||
|
{ |
||||
|
protected void Page_Load(object sender, EventArgs e) |
||||
|
{ |
||||
|
if (!IsPostBack) |
||||
|
{ |
||||
|
LoadData(); |
||||
|
} |
||||
|
} |
||||
|
public void LoadData() |
||||
|
{ |
||||
|
|
||||
|
if (CurrentUser.FactoryList |
||||
|
== null || CurrentUser.FactoryList.Count == 0) |
||||
|
{ |
||||
|
Alert.Show("当前用户未选择地点"); |
||||
|
return; |
||||
|
} |
||||
|
BindOrder(); |
||||
|
|
||||
|
} |
||||
|
public void BindOrder() |
||||
|
{ |
||||
|
SearchV_TB_PO((result) => { |
||||
|
Grid_V_TB_PO.RecordCount = result.Count(); |
||||
|
var list = SortAndPage<V_TB_PO>(result, Grid_V_TB_PO); |
||||
|
Grid_V_TB_PO.DataSource = list; |
||||
|
Grid_V_TB_PO.DataBind(); |
||||
|
}); |
||||
|
|
||||
|
} |
||||
|
public void SearchV_TB_PO(Action<IQueryable<V_TB_PO>> p_action) |
||||
|
{ |
||||
|
var ls = SCPDB.TB_FACTORY.Where(p => p.ErpDomain == CurrentUser.UsedDomain).ToList(); |
||||
|
DropDownList1.DataSource = ls; |
||||
|
DropDownList1.DataBind(); |
||||
|
V_TB_PO _entity = new V_TB_PO(); |
||||
|
_entity.IsDeleted = false; |
||||
|
if (this.DP_StartDate.SelectedDate != null) |
||||
|
{ |
||||
|
_entity.BeginTime = DP_StartDate.SelectedDate; |
||||
|
} |
||||
|
if (DP_EndDate.SelectedDate != null) |
||||
|
{ |
||||
|
_entity.BeginTime = DP_EndDate.SelectedDate; |
||||
|
} |
||||
|
if (!string.IsNullOrEmpty(DDL_State.SelectedValue)) |
||||
|
{ |
||||
|
_entity.State = int.Parse(DDL_State.SelectedValue); |
||||
|
} |
||||
|
_entity.VendId = TXT_Vendid.Text; |
||||
|
_entity.PoBillNum = TXT_BillNo.Text; |
||||
|
_entity.VendName = TXT_VendName.Text; |
||||
|
if (!string.IsNullOrEmpty(rblist.SelectedValue)) |
||||
|
{ |
||||
|
_entity.ModType = ConvertHelper.To<int>(rblist.SelectedValue); |
||||
|
} |
||||
|
_entity.ErpBillNum = TXT_ProjectId.Text; |
||||
|
_entity.SubSite = DropDownList1.SelectedValue; |
||||
|
_entity.IsDeleted = false; |
||||
|
_entity.UserInAddress = CurrentUser.FactoryList; |
||||
|
_entity.UserInVendIds = CurrentUser.VenderList; |
||||
|
SCP_PO_CONTROLLER.Get_V_TB_PO_List(_entity, (_ret) => { |
||||
|
if (_ret.State == ReturnStatus.Succeed) |
||||
|
{ |
||||
|
p_action(_ret.Result); |
||||
|
} |
||||
|
}); |
||||
|
} |
||||
|
|
||||
|
protected void Grid_V_TB_PO_RowDoubleClick(object sender, FineUI.GridRowClickEventArgs e) |
||||
|
{ |
||||
|
//object[] rowDataKeys = Grid_V_TB_PO.DataKeys[e.RowIndex];
|
||||
|
|
||||
|
//string PoBillNum = rowDataKeys[1] as string;
|
||||
|
//string VendID = rowDataKeys[3] as string;
|
||||
|
//PageContext.RegisterStartupScript(Window1.GetShowReference(string.Format("../PlanData/SCP_PO_DETAIL.aspx?PoBillNum={0}", PoBillNum)));
|
||||
|
} |
||||
|
|
||||
|
protected void Grid_V_TB_PO_PageIndexChange(object sender, FineUI.GridPageEventArgs e) |
||||
|
{ |
||||
|
BindOrder(); |
||||
|
} |
||||
|
|
||||
|
protected void Grid_V_TB_PO_Sort(object sender, FineUI.GridSortEventArgs e) |
||||
|
{ |
||||
|
|
||||
|
} |
||||
|
|
||||
|
protected void btnOutput_Click(object sender, EventArgs e) |
||||
|
{ |
||||
|
int[] _selections = Grid_V_TB_PO.SelectedRowIndexArray; |
||||
|
if (_selections.Count() == 0) |
||||
|
{ |
||||
|
Alert.Show("请选择订单记录导出!"); |
||||
|
} |
||||
|
List<string> _ls = new List<string>(); |
||||
|
for (int i = 0, count = Grid_V_TB_PO.Rows.Count; i < count; i++) |
||||
|
{ |
||||
|
if (_selections.Contains(i)) |
||||
|
{ |
||||
|
|
||||
|
object[] rowDataKeys = Grid_V_TB_PO.DataKeys[i]; |
||||
|
_ls.Add(rowDataKeys[1] as string); |
||||
|
} |
||||
|
} |
||||
|
if (_ls.Count == 0) |
||||
|
{ |
||||
|
Alert.Show("请选择记录导出!"); |
||||
|
return; |
||||
|
} |
||||
|
//List<string> _ls = new List<string>();
|
||||
|
//for (int i = 0, count = Grid_V_TB_PO.Rows.Count; i < count; i++)
|
||||
|
//{
|
||||
|
// object[] rowDataKeys = Grid_V_TB_PO.DataKeys[i];
|
||||
|
// _ls.Add(rowDataKeys[1] as string);
|
||||
|
//}
|
||||
|
DataSet ds = SCP_EXCEL_CONTROLLER.GET_PO_EXECEL(_ls); |
||||
|
PageBase.DataSetToExcel(ds, "采购订单"); |
||||
|
|
||||
|
} |
||||
|
|
||||
|
protected void btnDetail_Click(object sender, EventArgs e) |
||||
|
{ |
||||
|
if (Grid_V_TB_PO.SelectedRowIndexArray.Count() == 0) |
||||
|
{ |
||||
|
PageContext.RegisterStartupScript(Alert.GetShowInTopReference("没有选择数据!")); |
||||
|
return; |
||||
|
} |
||||
|
object[] rowDataKeys = Grid_V_TB_PO.DataKeys[Grid_V_TB_PO.SelectedRowIndex]; |
||||
|
if (rowDataKeys != null) |
||||
|
{ |
||||
|
string PoBillNum = rowDataKeys[1] as string; |
||||
|
string VendID = rowDataKeys[3] as string; |
||||
|
PageContext.RegisterStartupScript(Window1.GetShowReference(string.Format("../PlanData/SCP_PO_DETAIL.aspx?PoBillNum={0}", PoBillNum))); |
||||
|
} |
||||
|
} |
||||
|
|
||||
|
protected void btnShow_Click(object sender, EventArgs e) |
||||
|
{ |
||||
|
gp1.Hidden = false; |
||||
|
} |
||||
|
|
||||
|
protected void BtnClose_Click(object sender, EventArgs e) |
||||
|
{ |
||||
|
gp1.Hidden = true; |
||||
|
} |
||||
|
|
||||
|
protected void BtnSearch_Click(object sender, EventArgs e) |
||||
|
{ |
||||
|
BindOrder(); |
||||
|
} |
||||
|
|
||||
|
|
||||
|
protected void ddlGridPageSize_SelectedIndexChanged(object sender, EventArgs e) |
||||
|
{ |
||||
|
Grid_V_TB_PO.PageSize = Convert.ToInt32(ddlGridPageSize.SelectedValue); |
||||
|
BindOrder(); |
||||
|
} |
||||
|
|
||||
|
protected void Window1_Close(object sender, WindowCloseEventArgs e) |
||||
|
{ |
||||
|
BindOrder(); |
||||
|
} |
||||
|
|
||||
|
protected void BTN_CREATE_Click(object sender, EventArgs e) |
||||
|
{ |
||||
|
if (Grid_V_TB_PO.SelectedRowIndexArray.Count() == 0) |
||||
|
{ |
||||
|
PageContext.RegisterStartupScript(Alert.GetShowInTopReference("没有选择数据!")); |
||||
|
return; |
||||
|
} |
||||
|
|
||||
|
object[] rowDataKeys = Grid_V_TB_PO.DataKeys[Grid_V_TB_PO.SelectedRowIndex]; |
||||
|
if (ConvertHelper.To<int>(rowDataKeys[9]) == 0) |
||||
|
{ |
||||
|
PageContext.RegisterStartupScript(Alert.GetShowInTopReference("当前订单处于关闭状态,不能创建要货看板!")); |
||||
|
return; |
||||
|
} |
||||
|
|
||||
|
if (rowDataKeys != null) |
||||
|
{ |
||||
|
string PoBillNum = rowDataKeys[1] as string; |
||||
|
string VendID = rowDataKeys[3] as string; |
||||
|
PageContext.RegisterStartupScript(Window1.GetShowReference(string.Format("../PlanData/SCP_PO_CREATE_ASK.aspx?PoBillNum={0}", PoBillNum))); |
||||
|
} |
||||
|
} |
||||
|
protected void BTN_CREATE_Click1(object sender, EventArgs e) |
||||
|
{ |
||||
|
PageContext.RegisterStartupScript(Window2.GetShowReference(string.Format("../PlanData/富维冲插件/SCP_PO_EXTEND_DETAIL.aspx?"))); |
||||
|
} |
||||
|
protected void BtnSearchDetail_Click(object sender, EventArgs e) |
||||
|
{ |
||||
|
string PoBillNum = TXT_BillNo.Text; |
||||
|
string VendName = TXT_VendName.Text; |
||||
|
string State = DDL_State.SelectedValue; |
||||
|
string PartCode = TXT_PartCode.Text; |
||||
|
PageContext.RegisterStartupScript(Window1.GetShowReference(string.Format("../PlanData/SCP_PO_DETAIL.aspx?PoBillNum={0}&&VendName={1}&&State={2}&&PartCode={3}", PoBillNum, VendName, State, PartCode))); |
||||
|
} |
||||
|
protected void btnModeType1_Click(object sender, EventArgs e) |
||||
|
{ |
||||
|
rblist.SelectedValue = "1"; |
||||
|
BindOrder(); |
||||
|
} |
||||
|
|
||||
|
protected void btnModeType2_Click(object sender, EventArgs e) |
||||
|
{ |
||||
|
rblist.SelectedValue = "2"; |
||||
|
BindOrder(); |
||||
|
} |
||||
|
|
||||
|
protected void Grid_V_TB_PO_RowSelect(object sender, GridRowSelectEventArgs e) |
||||
|
{ |
||||
|
object[] rowDataKeys = Grid_V_TB_PO.DataKeys[e.RowIndex]; |
||||
|
string PoBillNum = rowDataKeys[1] as string; |
||||
|
|
||||
|
V_TB_PO_DETAIL _detail = new V_TB_PO_DETAIL(); |
||||
|
_detail.PoBillNum = PoBillNum; |
||||
|
|
||||
|
SCP_PO_CONTROLLER.Get_V_TB_PO_DETAIL_List(_detail, (_ret) => |
||||
|
{ |
||||
|
if (_ret.State == ReturnStatus.Succeed) |
||||
|
{ |
||||
|
Grid_V_TB_PO_DETAIL.DataSource = SCP_CONTRACT_CONTROLLER.GET_CONTRACT_PRICE_LIST(SCP_PO_CONTROLLER.LOAD_PO_DETAIL_SUM(_ret.Result.ToList())); |
||||
|
Grid_V_TB_PO_DETAIL.DataBind(); |
||||
|
} |
||||
|
}); |
||||
|
} |
||||
|
|
||||
|
protected void btnInput_Click_Contract(object sender, EventArgs e) |
||||
|
{ |
||||
|
Excel_Input(BillModType.Contract); |
||||
|
} |
||||
|
protected void btnInput_Click_Non_Contract(object sender, EventArgs e) |
||||
|
{ |
||||
|
Excel_Input(BillModType.Non_Contract); |
||||
|
} |
||||
|
protected void Excel_Input(BillModType p_modtype) |
||||
|
{ |
||||
|
ResultObject<bool> saveret = new ResultObject<bool>(); |
||||
|
string _fileName = FileUp.FileName; |
||||
|
if (string.IsNullOrEmpty(_fileName)) |
||||
|
{ |
||||
|
Alert.Show("选择文件为空!"); |
||||
|
return; |
||||
|
} |
||||
|
string _lx = _fileName.Split('.')[1]; |
||||
|
Stream _stream = FileUp.PostedFile.InputStream; |
||||
|
DataTable _dt = new DataTable(); |
||||
|
if (_lx == "xls") |
||||
|
{ |
||||
|
_dt = ExcelHelper.GetDataTable(_stream); |
||||
|
} |
||||
|
else |
||||
|
{ |
||||
|
_dt = ExcelHelper.GetDataTableOfXlsx(_stream); |
||||
|
} |
||||
|
|
||||
|
var list = ConvertHelper.ToList<SCP_PO_EXPORT_IMPORT_MODEL>(ExcelHelper.RemoveEmpty(_dt)).ToList(); |
||||
|
var checkret = SCP_PO_CONTROLLER.Check_EXCEL_PO_MOD(list, p_modtype, CurrentUser.FactoryList[0], CurrentUser.SubSiteList[0]); |
||||
|
if (checkret.State == ReturnStatus.Failed && checkret.Result == false) |
||||
|
{ |
||||
|
Alert.Show(string.Join("<br>", checkret.MessageList)); |
||||
|
return; |
||||
|
} |
||||
|
if (ScpCache.Config.数据中心接口) |
||||
|
{ |
||||
|
saveret = SCP_DC_UNI_CONTROLLER.WritePo(list, CurrentUser.FactoryList[0], CurrentUser.Name, DateTime.Now, p_modtype, CurrentUser.SubSiteList[0], CurrentUser.ChineseName, CurrentUser.CellPhone); |
||||
|
} |
||||
|
else |
||||
|
{ |
||||
|
saveret = SCP_PO_CONTROLLER.Save_EXCEL_PO_MOD(list, CurrentUser.FactoryList[0], CurrentUser.Name, DateTime.Now, p_modtype, CurrentUser.SubSiteList[0], CurrentUser.ChineseName, CurrentUser.CellPhone); |
||||
|
} |
||||
|
if (saveret.State == ReturnStatus.Succeed && saveret.Result == true) |
||||
|
{ |
||||
|
BindOrder(); |
||||
|
Alert.Show("订单编号" + saveret.Message + "导入成功!"); |
||||
|
return; |
||||
|
} |
||||
|
else |
||||
|
{ |
||||
|
//Alert.Show(string.Join("<br>", saveret.MessageList));
|
||||
|
Alert.Show(saveret.Message); |
||||
|
return; |
||||
|
} |
||||
|
} |
||||
|
|
||||
|
} |
||||
|
} |
@ -0,0 +1,377 @@ |
|||||
|
//------------------------------------------------------------------------------
|
||||
|
// <自动生成>
|
||||
|
// 此代码由工具生成。
|
||||
|
//
|
||||
|
// 对此文件的更改可能导致不正确的行为,如果
|
||||
|
// 重新生成代码,则所做更改将丢失。
|
||||
|
// </自动生成>
|
||||
|
//------------------------------------------------------------------------------
|
||||
|
|
||||
|
namespace SCP.Views.富维冲插件 |
||||
|
{ |
||||
|
|
||||
|
|
||||
|
public partial class SCP_PO_EXTEND |
||||
|
{ |
||||
|
|
||||
|
/// <summary>
|
||||
|
/// form1 控件。
|
||||
|
/// </summary>
|
||||
|
/// <remarks>
|
||||
|
/// 自动生成的字段。
|
||||
|
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
|
/// </remarks>
|
||||
|
protected global::System.Web.UI.HtmlControls.HtmlForm form1; |
||||
|
|
||||
|
/// <summary>
|
||||
|
/// Panel1 控件。
|
||||
|
/// </summary>
|
||||
|
/// <remarks>
|
||||
|
/// 自动生成的字段。
|
||||
|
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
|
/// </remarks>
|
||||
|
protected global::FineUI.Panel Panel1; |
||||
|
|
||||
|
/// <summary>
|
||||
|
/// Toolbar2 控件。
|
||||
|
/// </summary>
|
||||
|
/// <remarks>
|
||||
|
/// 自动生成的字段。
|
||||
|
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
|
/// </remarks>
|
||||
|
protected global::FineUI.Toolbar Toolbar2; |
||||
|
|
||||
|
/// <summary>
|
||||
|
/// Button3 控件。
|
||||
|
/// </summary>
|
||||
|
/// <remarks>
|
||||
|
/// 自动生成的字段。
|
||||
|
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
|
/// </remarks>
|
||||
|
protected global::FineUI.Button Button3; |
||||
|
|
||||
|
/// <summary>
|
||||
|
/// btnOutput 控件。
|
||||
|
/// </summary>
|
||||
|
/// <remarks>
|
||||
|
/// 自动生成的字段。
|
||||
|
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
|
/// </remarks>
|
||||
|
protected global::FineUI.Button btnOutput; |
||||
|
|
||||
|
/// <summary>
|
||||
|
/// btnDetail 控件。
|
||||
|
/// </summary>
|
||||
|
/// <remarks>
|
||||
|
/// 自动生成的字段。
|
||||
|
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
|
/// </remarks>
|
||||
|
protected global::FineUI.Button btnDetail; |
||||
|
|
||||
|
/// <summary>
|
||||
|
/// BTN_CREATE 控件。
|
||||
|
/// </summary>
|
||||
|
/// <remarks>
|
||||
|
/// 自动生成的字段。
|
||||
|
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
|
/// </remarks>
|
||||
|
protected global::FineUI.Button BTN_CREATE; |
||||
|
|
||||
|
/// <summary>
|
||||
|
/// Button1 控件。
|
||||
|
/// </summary>
|
||||
|
/// <remarks>
|
||||
|
/// 自动生成的字段。
|
||||
|
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
|
/// </remarks>
|
||||
|
protected global::FineUI.Button Button1; |
||||
|
|
||||
|
/// <summary>
|
||||
|
/// btnShow 控件。
|
||||
|
/// </summary>
|
||||
|
/// <remarks>
|
||||
|
/// 自动生成的字段。
|
||||
|
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
|
/// </remarks>
|
||||
|
protected global::FineUI.Button btnShow; |
||||
|
|
||||
|
/// <summary>
|
||||
|
/// btnModeType1 控件。
|
||||
|
/// </summary>
|
||||
|
/// <remarks>
|
||||
|
/// 自动生成的字段。
|
||||
|
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
|
/// </remarks>
|
||||
|
protected global::FineUI.Button btnModeType1; |
||||
|
|
||||
|
/// <summary>
|
||||
|
/// btnModeType2 控件。
|
||||
|
/// </summary>
|
||||
|
/// <remarks>
|
||||
|
/// 自动生成的字段。
|
||||
|
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
|
/// </remarks>
|
||||
|
protected global::FineUI.Button btnModeType2; |
||||
|
|
||||
|
/// <summary>
|
||||
|
/// rblist 控件。
|
||||
|
/// </summary>
|
||||
|
/// <remarks>
|
||||
|
/// 自动生成的字段。
|
||||
|
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
|
/// </remarks>
|
||||
|
protected global::FineUI.RadioButtonList rblist; |
||||
|
|
||||
|
/// <summary>
|
||||
|
/// FileUp 控件。
|
||||
|
/// </summary>
|
||||
|
/// <remarks>
|
||||
|
/// 自动生成的字段。
|
||||
|
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
|
/// </remarks>
|
||||
|
protected global::FineUI.FileUpload FileUp; |
||||
|
|
||||
|
/// <summary>
|
||||
|
/// btnInput_Contract 控件。
|
||||
|
/// </summary>
|
||||
|
/// <remarks>
|
||||
|
/// 自动生成的字段。
|
||||
|
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
|
/// </remarks>
|
||||
|
protected global::FineUI.Button btnInput_Contract; |
||||
|
|
||||
|
/// <summary>
|
||||
|
/// btnInput_Non_Contract 控件。
|
||||
|
/// </summary>
|
||||
|
/// <remarks>
|
||||
|
/// 自动生成的字段。
|
||||
|
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
|
/// </remarks>
|
||||
|
protected global::FineUI.Button btnInput_Non_Contract; |
||||
|
|
||||
|
/// <summary>
|
||||
|
/// gp1 控件。
|
||||
|
/// </summary>
|
||||
|
/// <remarks>
|
||||
|
/// 自动生成的字段。
|
||||
|
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
|
/// </remarks>
|
||||
|
protected global::FineUI.Form gp1; |
||||
|
|
||||
|
/// <summary>
|
||||
|
/// TXT_BillNo 控件。
|
||||
|
/// </summary>
|
||||
|
/// <remarks>
|
||||
|
/// 自动生成的字段。
|
||||
|
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
|
/// </remarks>
|
||||
|
protected global::FineUI.TextBox TXT_BillNo; |
||||
|
|
||||
|
/// <summary>
|
||||
|
/// DropDownList1 控件。
|
||||
|
/// </summary>
|
||||
|
/// <remarks>
|
||||
|
/// 自动生成的字段。
|
||||
|
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
|
/// </remarks>
|
||||
|
protected global::FineUI.DropDownList DropDownList1; |
||||
|
|
||||
|
/// <summary>
|
||||
|
/// TXT_Vendid 控件。
|
||||
|
/// </summary>
|
||||
|
/// <remarks>
|
||||
|
/// 自动生成的字段。
|
||||
|
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
|
/// </remarks>
|
||||
|
protected global::FineUI.TextBox TXT_Vendid; |
||||
|
|
||||
|
/// <summary>
|
||||
|
/// TXT_VendName 控件。
|
||||
|
/// </summary>
|
||||
|
/// <remarks>
|
||||
|
/// 自动生成的字段。
|
||||
|
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
|
/// </remarks>
|
||||
|
protected global::FineUI.TextBox TXT_VendName; |
||||
|
|
||||
|
/// <summary>
|
||||
|
/// TXT_ProjectId 控件。
|
||||
|
/// </summary>
|
||||
|
/// <remarks>
|
||||
|
/// 自动生成的字段。
|
||||
|
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
|
/// </remarks>
|
||||
|
protected global::FineUI.TextBox TXT_ProjectId; |
||||
|
|
||||
|
/// <summary>
|
||||
|
/// DDL_State 控件。
|
||||
|
/// </summary>
|
||||
|
/// <remarks>
|
||||
|
/// 自动生成的字段。
|
||||
|
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
|
/// </remarks>
|
||||
|
protected global::FineUI.DropDownList DDL_State; |
||||
|
|
||||
|
/// <summary>
|
||||
|
/// DP_StartDate 控件。
|
||||
|
/// </summary>
|
||||
|
/// <remarks>
|
||||
|
/// 自动生成的字段。
|
||||
|
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
|
/// </remarks>
|
||||
|
protected global::FineUI.DatePicker DP_StartDate; |
||||
|
|
||||
|
/// <summary>
|
||||
|
/// DP_EndDate 控件。
|
||||
|
/// </summary>
|
||||
|
/// <remarks>
|
||||
|
/// 自动生成的字段。
|
||||
|
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
|
/// </remarks>
|
||||
|
protected global::FineUI.DatePicker DP_EndDate; |
||||
|
|
||||
|
/// <summary>
|
||||
|
/// TXT_PartCode 控件。
|
||||
|
/// </summary>
|
||||
|
/// <remarks>
|
||||
|
/// 自动生成的字段。
|
||||
|
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
|
/// </remarks>
|
||||
|
protected global::FineUI.TextBox TXT_PartCode; |
||||
|
|
||||
|
/// <summary>
|
||||
|
/// Panel5 控件。
|
||||
|
/// </summary>
|
||||
|
/// <remarks>
|
||||
|
/// 自动生成的字段。
|
||||
|
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
|
/// </remarks>
|
||||
|
protected global::FineUI.Panel Panel5; |
||||
|
|
||||
|
/// <summary>
|
||||
|
/// BtnClose 控件。
|
||||
|
/// </summary>
|
||||
|
/// <remarks>
|
||||
|
/// 自动生成的字段。
|
||||
|
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
|
/// </remarks>
|
||||
|
protected global::FineUI.Button BtnClose; |
||||
|
|
||||
|
/// <summary>
|
||||
|
/// BtnSearch 控件。
|
||||
|
/// </summary>
|
||||
|
/// <remarks>
|
||||
|
/// 自动生成的字段。
|
||||
|
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
|
/// </remarks>
|
||||
|
protected global::FineUI.Button BtnSearch; |
||||
|
|
||||
|
/// <summary>
|
||||
|
/// BtnSearchDetail 控件。
|
||||
|
/// </summary>
|
||||
|
/// <remarks>
|
||||
|
/// 自动生成的字段。
|
||||
|
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
|
/// </remarks>
|
||||
|
protected global::FineUI.Button BtnSearchDetail; |
||||
|
|
||||
|
/// <summary>
|
||||
|
/// Panel2 控件。
|
||||
|
/// </summary>
|
||||
|
/// <remarks>
|
||||
|
/// 自动生成的字段。
|
||||
|
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
|
/// </remarks>
|
||||
|
protected global::FineUI.Panel Panel2; |
||||
|
|
||||
|
/// <summary>
|
||||
|
/// Panel3 控件。
|
||||
|
/// </summary>
|
||||
|
/// <remarks>
|
||||
|
/// 自动生成的字段。
|
||||
|
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
|
/// </remarks>
|
||||
|
protected global::FineUI.Panel Panel3; |
||||
|
|
||||
|
/// <summary>
|
||||
|
/// Grid_V_TB_PO 控件。
|
||||
|
/// </summary>
|
||||
|
/// <remarks>
|
||||
|
/// 自动生成的字段。
|
||||
|
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
|
/// </remarks>
|
||||
|
protected global::FineUI.Grid Grid_V_TB_PO; |
||||
|
|
||||
|
/// <summary>
|
||||
|
/// ToolbarSeparator1 控件。
|
||||
|
/// </summary>
|
||||
|
/// <remarks>
|
||||
|
/// 自动生成的字段。
|
||||
|
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
|
/// </remarks>
|
||||
|
protected global::FineUI.ToolbarSeparator ToolbarSeparator1; |
||||
|
|
||||
|
/// <summary>
|
||||
|
/// ToolbarText1 控件。
|
||||
|
/// </summary>
|
||||
|
/// <remarks>
|
||||
|
/// 自动生成的字段。
|
||||
|
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
|
/// </remarks>
|
||||
|
protected global::FineUI.ToolbarText ToolbarText1; |
||||
|
|
||||
|
/// <summary>
|
||||
|
/// ddlGridPageSize 控件。
|
||||
|
/// </summary>
|
||||
|
/// <remarks>
|
||||
|
/// 自动生成的字段。
|
||||
|
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
|
/// </remarks>
|
||||
|
protected global::FineUI.DropDownList ddlGridPageSize; |
||||
|
|
||||
|
/// <summary>
|
||||
|
/// Panel4 控件。
|
||||
|
/// </summary>
|
||||
|
/// <remarks>
|
||||
|
/// 自动生成的字段。
|
||||
|
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
|
/// </remarks>
|
||||
|
protected global::FineUI.Panel Panel4; |
||||
|
|
||||
|
/// <summary>
|
||||
|
/// Grid_V_TB_PO_DETAIL 控件。
|
||||
|
/// </summary>
|
||||
|
/// <remarks>
|
||||
|
/// 自动生成的字段。
|
||||
|
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
|
/// </remarks>
|
||||
|
protected global::FineUI.Grid Grid_V_TB_PO_DETAIL; |
||||
|
|
||||
|
/// <summary>
|
||||
|
/// Window1 控件。
|
||||
|
/// </summary>
|
||||
|
/// <remarks>
|
||||
|
/// 自动生成的字段。
|
||||
|
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
|
/// </remarks>
|
||||
|
protected global::FineUI.Window Window1; |
||||
|
|
||||
|
/// <summary>
|
||||
|
/// WindowUpload 控件。
|
||||
|
/// </summary>
|
||||
|
/// <remarks>
|
||||
|
/// 自动生成的字段。
|
||||
|
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
|
/// </remarks>
|
||||
|
protected global::FineUI.Window WindowUpload; |
||||
|
|
||||
|
/// <summary>
|
||||
|
/// Window2 控件。
|
||||
|
/// </summary>
|
||||
|
/// <remarks>
|
||||
|
/// 自动生成的字段。
|
||||
|
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
|
/// </remarks>
|
||||
|
protected global::FineUI.Window Window2; |
||||
|
} |
||||
|
} |
@ -0,0 +1,43 @@ |
|||||
|
<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="SCP_PO_EXTEND_DETAIL.aspx.cs" Inherits="SCP.Views.富维冲插件.SCP_PO_EXTEND_DETAIL" %> |
||||
|
|
||||
|
<!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 ID="PageManager1" AutoSizePanelID="Panel1" runat="server"/> |
||||
|
<f:Panel ID="Panel1" CssClass="blockpanel" runat="server" ShowBorder="true" ShowHeader="true" Layout="Region"> |
||||
|
|
||||
|
<Toolbars> |
||||
|
<f:Toolbar ID="Toolbar2" runat="server"> |
||||
|
<Items> |
||||
|
<f:Button ID="Btn_Save" runat="server" EnablePostBack="True" Text="保存" Icon="SystemSave" OnClick="Btn_Save_Click"> |
||||
|
</f:Button> |
||||
|
|
||||
|
</Items> |
||||
|
</f:Toolbar> |
||||
|
</Toolbars> |
||||
|
<Items> |
||||
|
<f:Form runat="server" Width="550px" BodyPadding="25 25 30 25"> |
||||
|
<Items> |
||||
|
<f:TextBox runat = "server" Label = "订单编号" EmptyText = "" ID = "TXT_PoBillNum" Hidden="true"/> |
||||
|
<f:TextBox runat = "server" Label = "零件号" EmptyText = "" ID = "TXT_PartCode" /> |
||||
|
<f:TextBox runat = "server" Label = "数量" EmptyText = "" ID = "TXT_EN" /> |
||||
|
<f:TextBox runat = "server" Label = "供应商编码" EmptyText = "" ID = "TXT_VendId" /> |
||||
|
<f:TextBox runat = "server" Label = "订单创建时间" EmptyText = "" ID = "TXT_CreateTime" /> |
||||
|
<f:TextBox runat = "server" Label = "要求到货日期" EmptyText = "" ID = "TXT_EndTime" /> |
||||
|
<f:TextBox runat = "server" Label = "订单截止日期" EmptyText = "" ID = "TXT_Time" /> |
||||
|
<f:TextBox runat = "server" Label = "单位" EmptyText = "" ID = "TXT_PoUnit" /> |
||||
|
<f:TextBox runat = "server" Label = "备注" EmptyText = "" ID = "TXT_Remark" /> |
||||
|
|
||||
|
</Items> |
||||
|
</f:Form> |
||||
|
</Items> |
||||
|
</f:Panel> |
||||
|
</form> |
||||
|
</body> |
||||
|
</html> |
@ -0,0 +1,35 @@ |
|||||
|
using System; |
||||
|
using System.Collections.Generic; |
||||
|
using System.Linq; |
||||
|
using System.Web; |
||||
|
using System.Web.UI; |
||||
|
using System.Web.UI.WebControls; |
||||
|
using CK.SCP.Models.ScpEntity; |
||||
|
using CK.SCP.Utils; |
||||
|
using CK.SCP.Common; |
||||
|
using CK.SCP.Controller; |
||||
|
using CK.SCP.Models.ScpEntity.ExcelExportEnttity; |
||||
|
using System.Data; |
||||
|
using FineUI; |
||||
|
|
||||
|
namespace SCP.Views.富维冲插件 |
||||
|
{ |
||||
|
public partial class SCP_PO_EXTEND_DETAIL : PageBase |
||||
|
{ |
||||
|
protected void Page_Load(object sender, EventArgs e) |
||||
|
{ |
||||
|
TXT_PoBillNum.Text = "1"; |
||||
|
} |
||||
|
protected void Btn_Save_Click(object sender, EventArgs e) |
||||
|
{ |
||||
|
ResultObject<bool> saveret = new ResultObject<bool>(); |
||||
|
DataTable _dt = new DataTable(); |
||||
|
var list = ConvertHelper.ToList<SCP_PO_EXPORT_IMPORT_MODEL>(ExcelHelper.RemoveEmpty(_dt)).ToList(); |
||||
|
var ls = SCP_PO_CONTROLLER.Save_EXCEL_PO_MOD1(list, CurrentUser.FactoryList[0], CurrentUser.Name, DateTime.Now, CurrentUser.SubSiteList[0], CurrentUser.ChineseName, CurrentUser.CellPhone, TXT_CreateTime.Text, TXT_EN.Text, TXT_EndTime.Text, TXT_PartCode.Text, |
||||
|
TXT_PoBillNum.Text, TXT_Remark.Text, TXT_Time.Text, TXT_VendId.Text, TXT_PoUnit.Text); |
||||
|
|
||||
|
|
||||
|
} |
||||
|
} |
||||
|
|
||||
|
} |
@ -0,0 +1,143 @@ |
|||||
|
//------------------------------------------------------------------------------
|
||||
|
// <自动生成>
|
||||
|
// 此代码由工具生成。
|
||||
|
//
|
||||
|
// 对此文件的更改可能导致不正确的行为,如果
|
||||
|
// 重新生成代码,则所做更改将丢失。
|
||||
|
// </自动生成>
|
||||
|
//------------------------------------------------------------------------------
|
||||
|
|
||||
|
namespace SCP.Views.富维冲插件 |
||||
|
{ |
||||
|
|
||||
|
|
||||
|
public partial class SCP_PO_EXTEND_DETAIL |
||||
|
{ |
||||
|
|
||||
|
/// <summary>
|
||||
|
/// form1 控件。
|
||||
|
/// </summary>
|
||||
|
/// <remarks>
|
||||
|
/// 自动生成的字段。
|
||||
|
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
|
/// </remarks>
|
||||
|
protected global::System.Web.UI.HtmlControls.HtmlForm form1; |
||||
|
|
||||
|
/// <summary>
|
||||
|
/// PageManager1 控件。
|
||||
|
/// </summary>
|
||||
|
/// <remarks>
|
||||
|
/// 自动生成的字段。
|
||||
|
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
|
/// </remarks>
|
||||
|
protected global::FineUI.PageManager PageManager1; |
||||
|
|
||||
|
/// <summary>
|
||||
|
/// Panel1 控件。
|
||||
|
/// </summary>
|
||||
|
/// <remarks>
|
||||
|
/// 自动生成的字段。
|
||||
|
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
|
/// </remarks>
|
||||
|
protected global::FineUI.Panel Panel1; |
||||
|
|
||||
|
/// <summary>
|
||||
|
/// Toolbar2 控件。
|
||||
|
/// </summary>
|
||||
|
/// <remarks>
|
||||
|
/// 自动生成的字段。
|
||||
|
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
|
/// </remarks>
|
||||
|
protected global::FineUI.Toolbar Toolbar2; |
||||
|
|
||||
|
/// <summary>
|
||||
|
/// Btn_Save 控件。
|
||||
|
/// </summary>
|
||||
|
/// <remarks>
|
||||
|
/// 自动生成的字段。
|
||||
|
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
|
/// </remarks>
|
||||
|
protected global::FineUI.Button Btn_Save; |
||||
|
|
||||
|
/// <summary>
|
||||
|
/// TXT_PoBillNum 控件。
|
||||
|
/// </summary>
|
||||
|
/// <remarks>
|
||||
|
/// 自动生成的字段。
|
||||
|
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
|
/// </remarks>
|
||||
|
protected global::FineUI.TextBox TXT_PoBillNum; |
||||
|
|
||||
|
/// <summary>
|
||||
|
/// TXT_PartCode 控件。
|
||||
|
/// </summary>
|
||||
|
/// <remarks>
|
||||
|
/// 自动生成的字段。
|
||||
|
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
|
/// </remarks>
|
||||
|
protected global::FineUI.TextBox TXT_PartCode; |
||||
|
|
||||
|
/// <summary>
|
||||
|
/// TXT_EN 控件。
|
||||
|
/// </summary>
|
||||
|
/// <remarks>
|
||||
|
/// 自动生成的字段。
|
||||
|
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
|
/// </remarks>
|
||||
|
protected global::FineUI.TextBox TXT_EN; |
||||
|
|
||||
|
/// <summary>
|
||||
|
/// TXT_VendId 控件。
|
||||
|
/// </summary>
|
||||
|
/// <remarks>
|
||||
|
/// 自动生成的字段。
|
||||
|
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
|
/// </remarks>
|
||||
|
protected global::FineUI.TextBox TXT_VendId; |
||||
|
|
||||
|
/// <summary>
|
||||
|
/// TXT_CreateTime 控件。
|
||||
|
/// </summary>
|
||||
|
/// <remarks>
|
||||
|
/// 自动生成的字段。
|
||||
|
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
|
/// </remarks>
|
||||
|
protected global::FineUI.TextBox TXT_CreateTime; |
||||
|
|
||||
|
/// <summary>
|
||||
|
/// TXT_EndTime 控件。
|
||||
|
/// </summary>
|
||||
|
/// <remarks>
|
||||
|
/// 自动生成的字段。
|
||||
|
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
|
/// </remarks>
|
||||
|
protected global::FineUI.TextBox TXT_EndTime; |
||||
|
|
||||
|
/// <summary>
|
||||
|
/// TXT_Time 控件。
|
||||
|
/// </summary>
|
||||
|
/// <remarks>
|
||||
|
/// 自动生成的字段。
|
||||
|
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
|
/// </remarks>
|
||||
|
protected global::FineUI.TextBox TXT_Time; |
||||
|
|
||||
|
/// <summary>
|
||||
|
/// TXT_PoUnit 控件。
|
||||
|
/// </summary>
|
||||
|
/// <remarks>
|
||||
|
/// 自动生成的字段。
|
||||
|
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
|
/// </remarks>
|
||||
|
protected global::FineUI.TextBox TXT_PoUnit; |
||||
|
|
||||
|
/// <summary>
|
||||
|
/// TXT_Remark 控件。
|
||||
|
/// </summary>
|
||||
|
/// <remarks>
|
||||
|
/// 自动生成的字段。
|
||||
|
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
|
/// </remarks>
|
||||
|
protected global::FineUI.TextBox TXT_Remark; |
||||
|
} |
||||
|
} |
Loading…
Reference in new issue