TML
4 years ago
12 changed files with 2954 additions and 1 deletions
@ -0,0 +1,163 @@ |
|||
<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="SCP_INVOICE.aspx.cs" Inherits="SCP.Views.PlanData.SCP_INVOICE" %> |
|||
|
|||
<!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" runat="server" AutoSizePanelID="Panel1"/> |
|||
<f:Panel ID="Panel1" runat="server" Title="" Layout="VBox" BoxConfigAlign="Stretch" BoxConfigPosition="Start"> |
|||
<Items> |
|||
<f:Form runat="server"> |
|||
<Toolbars> |
|||
<f:Toolbar ID="Toolbar1" runat="server"> |
|||
<Items> |
|||
|
|||
<f:Button ID="Button3" runat="server" EnablePostBack="True" Text="刷新" Icon="Reload" OnClientClick="location.reload();"> |
|||
</f:Button> |
|||
<f:Button ID="btnView" runat="server" EnablePostBack="True" Text="查看发票" Icon="Zoom" OnClick="btnView_OnClick"> |
|||
</f:Button> |
|||
<f:ToolbarSeparator runat="server" /> |
|||
<f:Button ID="btnOutput" runat="server" Text="导出" Icon="PageExcel" OnClick="btnOutput_OnClick"> |
|||
</f:Button> |
|||
<f:Button ID="btnShow" runat="server" Text="显示查询面板" Icon="Find" OnClick="btnShow_OnClick"> |
|||
</f:Button> |
|||
<f:DropDownList ID="DDL_VEND_LIST" DataValueField="VendId" DataTextField="VendName" runat="server" Label="供应商编码" EnableEdit="true" EnableMultiSelect="false" Hidden="true"/> |
|||
<f:Button ID="BTN_INV" runat="server" EnablePostBack="True" Text="确认供应商发票管理" OnClick="BTN_INV_Click" Hidden="true"></f:Button> |
|||
|
|||
</Items> |
|||
</f:Toolbar> |
|||
</Toolbars> |
|||
</f:Form> |
|||
<f:GroupPanel runat="server" ID="gp1" Hidden="True" Layout="HBox"> |
|||
<Items> |
|||
<f:Form runat="server"> |
|||
<Rows> |
|||
<f:FormRow runat="server" ID="FormRow_1"> |
|||
<Items> |
|||
<f:CheckBoxList runat="server" ID="ckb" Label="状态"> |
|||
<%--<f:CheckItem Text="新建" Value="0" Selected="True" /> |
|||
<f:CheckItem Text="供应商申请" Value="1" /> |
|||
<f:CheckItem Text="采购审核退回" Value="2" /> |
|||
<f:CheckItem Text="采购审核通过" Value="3" /> |
|||
<f:CheckItem Text="发票寄出" Value="4" /> |
|||
<f:CheckItem Text="财务退回" Value="5" /> |
|||
<f:CheckItem Text="财务收票" Value="6" /> |
|||
<f:CheckItem Text="发票作废" Value="-1" />--%> |
|||
|
|||
</f:CheckBoxList> |
|||
</Items> |
|||
</f:FormRow> |
|||
<f:FormRow runat="server" ID="FormRow_2"> |
|||
<Items> |
|||
|
|||
<f:TextBox ID="TXT_InvcBillNum" runat="server" Label="发票单号"/> |
|||
|
|||
<f:TextBox ID="TXT_VendName" runat="server" Label="供应商"/> |
|||
|
|||
<f:TextBox ID="TXT_InvoiceNum" runat="server" Label="金税票号" MaxLength="22"/> |
|||
|
|||
<f:TextBox ID="TXT_PO" runat="server" Label="订单编号"/> |
|||
</Items> |
|||
</f:FormRow> |
|||
<f:FormRow runat="server" ID="FormRow_3"> |
|||
<Items> |
|||
|
|||
<f:TextBox ID="TXT_Site" runat="server" Label="收货地点"/> |
|||
|
|||
<f:TextBox ID="TXT_ASN" runat="server" Label="发货单号"/> |
|||
|
|||
<f:DatePicker ID="DP_CreateTime1" runat="server" Required="true" Label="收货时间" /> |
|||
|
|||
<f:DatePicker ID="DP_CreateTime2" runat="server" Required="true" Label="至" /> |
|||
</Items> |
|||
</f:FormRow> |
|||
<f:FormRow runat="server" ID="FormRow_4"> |
|||
<Items> |
|||
<f:Button runat="server" Text="关闭" OnClick="OnClick"></f:Button> |
|||
<f:Button ID="BTN_SEARCH" runat="server" OnClick="BTN_SEARCH_Click" Text="快速查找"> |
|||
</f:Button> |
|||
</Items> |
|||
</f:FormRow> |
|||
</Rows> |
|||
</f:Form> |
|||
|
|||
</Items> |
|||
</f:GroupPanel> |
|||
|
|||
<f:Grid ID="Grid_V_TB_INVOICE" runat="server" EnableCheckBoxSelect="true" ShowHeader="False" |
|||
AllowPaging="True" PageSize="20" OnPageIndexChange="Grid_V_TB_INVOICE_PageIndexChange" |
|||
ShowBorder="False" OnRowDoubleClick="Grid_V_TB_INVOICE_RowDoubleClick" BoxFlex="1" |
|||
DataKeyNames="UID, InvcBillNum" AllowSorting="true" IsDatabasePaging="true" SortField="State" OnRowDataBound="Grid_V_TB_INVOICE_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="20" Value="20" /> |
|||
<f:ListItem Text="50" Value="50" /> |
|||
<f:ListItem Text="100" Value="100" /> |
|||
<f:ListItem Text="200" Value="200" /> |
|||
</f:DropDownList> |
|||
</PageItems> |
|||
<Columns> |
|||
<f:BoundField runat="server" HeaderText="状态" ColumnID="" DataField="State_DESC" /> |
|||
<f:BoundField runat="server" HeaderText="发票单号" ColumnID="" DataField="InvcBillNum" /> |
|||
<f:BoundField runat="server" HeaderText="金税票号" ColumnID="" DataField="InvoiceNum" /> |
|||
<f:BoundField runat="server" HeaderText="快递单号" ColumnID="" DataField="ExpressNum" /> |
|||
<f:BoundField runat="server" HeaderText="供应商" ColumnID="" DataField="VendName" /> |
|||
<f:BoundField runat="server" HeaderText="供应商编码" ColumnID="" DataField="VendId" /> |
|||
<f:BoundField runat="server" HeaderText="金额" ColumnID="" DataField="Amount" DataFormatString = "{0:F}"/> |
|||
<f:BoundField runat="server" HeaderText="采购金额" ColumnID="" DataField="PurCost" DataFormatString = "{0:F}" /> |
|||
<f:BoundField runat="server" HeaderText="成本金额" ColumnID="" DataField="StdCost" DataFormatString = "{0:F}"/> |
|||
<f:BoundField runat="server" HeaderText="税率" ColumnID="" DataField="Tax" DataFormatString = "{0:F}"/> |
|||
<f:BoundField runat="server" HeaderText="税额" ColumnID="" DataField="TaxAmount" DataFormatString = "{0:F}"/> |
|||
|
|||
|
|||
|
|||
<%-- <f:BoundField runat="server" HeaderText="开票金额" ColumnID="" DataField="Total" />--%> |
|||
<f:TemplateField HeaderText="税后金额" Width="70px" ColumnID="Total"> |
|||
<ItemTemplate> |
|||
<asp:label ID="Total1" runat="server" Width="60px" Text='<%# Eval("Total") %>' ></asp:label> |
|||
</ItemTemplate> |
|||
</f:TemplateField> |
|||
|
|||
<f:BoundField runat="server" HeaderText="折扣金额" ColumnID="" DataField="DiscountPrice" DataFormatString = "{0:F}"/> |
|||
<%-- <f:BoundField runat="server" HeaderText="折扣税额" ColumnID="" DataField="DiscountPriceTax" DataFormatString = "{0:F}"/> --%> |
|||
<f:BoundField runat="server" HeaderText="索赔金额" ColumnID="" DataField="ContractPrice" DataFormatString = "{0:F}"/> |
|||
<%-- <f:BoundField runat="server" HeaderText="索赔税额" ColumnID="" DataField="ContractPriceTax" DataFormatString = "{0:F}"/>--%> |
|||
<f:BoundField runat="server" HeaderText="调整税额" ColumnID="" DataField="BlancePrice" DataFormatString = "{0:F}"/> |
|||
<%-- <f:BoundField runat="server" HeaderText="开票金额" ColumnID="" DataField="RealTotal" DataFormatString = "{0:F}"/> --%> |
|||
|
|||
<%--<f:BoundField runat="server" HeaderText="创建时间" ColumnID="" DataField="CreateTime" />--%> |
|||
<f:BoundField runat="server" HeaderText="备注" ColumnID="" DataField="Remark" /> |
|||
</Columns> |
|||
</f:Grid> |
|||
</Items> |
|||
</f:Panel> |
|||
<f:Window ID="Window1" runat="server" Hidden="True" AutoScroll="True" |
|||
WindowPosition="Center" IsModal="true" Title="发票编辑" Target="Parent" EnableIFrame="true" OnClose="Window1_Close" |
|||
IFrameUrl="about:blank" Height="550px" Width="1024px"> |
|||
</f:Window> |
|||
<f:Window ID="Window2" runat="server" Hidden="True" AutoScroll="True" |
|||
WindowPosition="Center" IsModal="true" Title="Popup Window 1" Target="Parent" EnableIFrame="true" |
|||
IFrameUrl="about:blank" Height="300px" Width="400px"> |
|||
</f:Window> |
|||
<f:Window ID="WindowUpload" runat="server" Hidden="True" AutoScroll="True" |
|||
WindowPosition="Center" IsModal="true" Title="Popup Window 1" Target="Parent" EnableIFrame="true" |
|||
IFrameUrl="about:blank" Height="200px" Width="400px" OnClose="WindowUpload_Close" > |
|||
</f:Window> |
|||
<script type="text/javascript"> |
|||
|
|||
|
|||
</script> |
|||
|
|||
</form> |
|||
</body> |
|||
</html> |
@ -0,0 +1,206 @@ |
|||
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.Controller; |
|||
using FineUI; |
|||
using System.Data; |
|||
using System.Drawing; |
|||
namespace SCP.Views.PlanData |
|||
{ |
|||
public partial class SCP_INVOICE : PageBase |
|||
{ |
|||
protected void Page_Load(object sender, EventArgs e) |
|||
{ |
|||
IsRoleRight(); |
|||
|
|||
if (!IsPostBack) |
|||
{ |
|||
//TranslatorAgents(Toolbar1);
|
|||
//TranslatorAgent(Grid_V_TB_INVOICE);
|
|||
//TranslatorAgents(FormRow_1);
|
|||
//TranslatorAgents(FormRow_2);
|
|||
//TranslatorAgents(FormRow_3);
|
|||
//TranslatorAgents(FormRow_4);
|
|||
BindInvoice(); |
|||
BindVenderByUser(DDL_VEND_LIST); |
|||
} |
|||
} |
|||
|
|||
public void IsRoleRight() |
|||
{ |
|||
if (CurrentUser.RoleList.Contains("采购人员")) |
|||
{ |
|||
DDL_VEND_LIST.Hidden = false; |
|||
BTN_INV.Hidden = false; |
|||
} |
|||
} |
|||
|
|||
public void BindInvoice() |
|||
{ |
|||
SearchInvoice(ret => { |
|||
Grid_V_TB_INVOICE.RecordCount = ret.Count(); |
|||
ret = SortAndPage(ret, Grid_V_TB_INVOICE); |
|||
Grid_V_TB_INVOICE.DataSource = ret; |
|||
Grid_V_TB_INVOICE.DataBind(); |
|||
}); |
|||
} |
|||
public void SearchInvoice(Action<IQueryable<V_TB_INVOICE>> p_action) |
|||
{ |
|||
V_TB_INVOICE _entity = new V_TB_INVOICE(); |
|||
_entity.InvcBillNum = TXT_InvcBillNum.Text; |
|||
_entity.VendName = TXT_VendName.Text; |
|||
_entity.InvoiceNum = TXT_InvoiceNum.Text; |
|||
_entity.UserInVendIds = CurrentUser.VenderList; |
|||
|
|||
if (CurrentUser.RoleList.Contains("采购人员")) |
|||
{ |
|||
if (string.IsNullOrEmpty(DDL_VEND_LIST.SelectedValue)) |
|||
{ |
|||
Alert.Show("选择开票的供应商,并点击确认!"); |
|||
return; |
|||
} |
|||
var _venderId = DDL_VEND_LIST.SelectedValue; |
|||
_entity.VendId = _venderId; |
|||
} |
|||
else |
|||
{ |
|||
if (CurrentUser.VenderList != null && CurrentUser.VenderList.Count > 0) |
|||
{ |
|||
_entity.VendId = CurrentUser.VenderList[0]; |
|||
} |
|||
} |
|||
if (CurrentUser.FactoryList != null && CurrentUser.FactoryList.Count > 0) |
|||
{ |
|||
_entity.Site = CurrentUser.FactoryList[0]; |
|||
} |
|||
if (string.IsNullOrEmpty(_entity.VendId)) |
|||
{ |
|||
return; |
|||
} |
|||
if (DP_CreateTime1.SelectedDate != null || DP_CreateTime2.SelectedDate != null || !string.IsNullOrEmpty(TXT_PO.Text) || !string.IsNullOrEmpty(TXT_ASN.Text)) |
|||
{ |
|||
_entity.InvoiceList = SCP_INVOICE_CONTROLLER.Get_V_TB_INVOICE_BY_TIME(DP_CreateTime1.Text, DP_CreateTime2.Text, TXT_PO.Text, TXT_ASN.Text); |
|||
} |
|||
SCP_INVOICE_CONTROLLER.Get_V_TB_INVOICE_List(_entity, (ret) => |
|||
{ |
|||
if (ret.State == ReturnStatus.Succeed) |
|||
{ |
|||
//if (_entity.InvoiceList == null || _entity.InvoiceList.Count == 0)
|
|||
//{
|
|||
// Alert.Show("未查询到符合条件的发票!");
|
|||
//}
|
|||
p_action(ret.Result); |
|||
} |
|||
}); |
|||
} |
|||
protected void btnView_OnClick(object sender, EventArgs e) |
|||
{ |
|||
if (Grid_V_TB_INVOICE.SelectedRowIndexArray.Length != 1) |
|||
{ |
|||
Alert.Show("请选择一行要操作的记录!"); |
|||
return; |
|||
} |
|||
string roleID = GetSelectedDataKey(Grid_V_TB_INVOICE, 1); |
|||
string url = String.Format("../PlanData/SCP_INVOICE_EDIT.aspx?ID={0}", roleID); |
|||
PageContext.RegisterStartupScript(Window1.GetShowReference(url)); |
|||
} |
|||
|
|||
|
|||
//显示面板
|
|||
protected void btnShow_OnClick(object sender, EventArgs e) |
|||
{ |
|||
gp1.Hidden = false; |
|||
} |
|||
//关闭面板
|
|||
protected void OnClick(object sender, EventArgs e) |
|||
{ |
|||
gp1.Hidden = true; |
|||
} |
|||
|
|||
|
|||
protected void Grid_V_TB_INVOICE_PageIndexChange(object sender, FineUI.GridPageEventArgs e) |
|||
{ |
|||
BindInvoice(); |
|||
} |
|||
|
|||
protected void Grid_V_TB_INVOICE_RowDoubleClick(object sender, FineUI.GridRowClickEventArgs e) |
|||
{ |
|||
//string roleID = GetSelectedDataKey(Grid1, 1);
|
|||
//string url = String.Format("../SupplierData/InvoiceDetail.aspx?ID={0}", roleID);
|
|||
//PageContext.RegisterStartupScript(Window1.GetShowReference(url));
|
|||
} |
|||
|
|||
protected void ddlGridPageSize_SelectedIndexChanged(object sender, EventArgs e) |
|||
{ |
|||
Grid_V_TB_INVOICE.PageSize = Convert.ToInt32(ddlGridPageSize.SelectedValue); |
|||
BindInvoice(); |
|||
} |
|||
protected void BTN_SEARCH_Click(object sender, EventArgs e) |
|||
{ |
|||
BindInvoice(); |
|||
} |
|||
//导出
|
|||
protected void btnOutput_OnClick(object sender, EventArgs e) |
|||
{ |
|||
int[] _selections = Grid_V_TB_INVOICE.SelectedRowIndexArray; |
|||
if (_selections.Count() == 0) |
|||
{ |
|||
Alert.Show("请选择发票记录导出!"); |
|||
} |
|||
List<string> _ls = new List<string>(); |
|||
for (int i = 0, count = Grid_V_TB_INVOICE.Rows.Count; i < count; i++) |
|||
{ |
|||
if (_selections.Contains(i)) |
|||
{ |
|||
|
|||
object[] rowDataKeys = Grid_V_TB_INVOICE.DataKeys[i]; |
|||
_ls.Add(rowDataKeys[1] as string); |
|||
} |
|||
} |
|||
if (_ls.Count == 0) |
|||
{ |
|||
Alert.Show("请选择记录导出!"); |
|||
return; |
|||
} |
|||
DataSet ds = SCP_EXCEL_CONTROLLER.GET_INVOICE_EXECEL(_ls); |
|||
ds.Tables[1].Columns.Remove("成本价"); |
|||
PageBase.DataSetToExcel(ds, "导出发票"); |
|||
|
|||
|
|||
|
|||
} |
|||
|
|||
protected void Grid_V_TB_INVOICE_RowDataBound(object sender, GridRowEventArgs e) |
|||
{ |
|||
int i = 0; |
|||
System.Web.UI.WebControls.Label _label = (System.Web.UI.WebControls.Label)Grid_V_TB_INVOICE.Rows[e.RowIndex].FindControl("Total1"); |
|||
if (!string.IsNullOrEmpty(_label.Text)) |
|||
{ |
|||
try |
|||
{ |
|||
if (decimal.Parse(_label.Text) < 0) |
|||
{ |
|||
_label.ForeColor = Color.Red; |
|||
i++; |
|||
} |
|||
} |
|||
catch |
|||
{ } |
|||
} |
|||
} |
|||
|
|||
protected void BTN_INV_Click(object sender, EventArgs e) |
|||
{ |
|||
BindInvoice(); |
|||
} |
|||
|
|||
protected void Window1_Close(object sender, WindowCloseEventArgs e) |
|||
{ |
|||
|
|||
} |
|||
} |
|||
} |
@ -0,0 +1,314 @@ |
|||
//------------------------------------------------------------------------------
|
|||
// <自动生成>
|
|||
// 此代码由工具生成。
|
|||
//
|
|||
// 对此文件的更改可能导致不正确的行为,如果
|
|||
// 重新生成代码,则所做更改将丢失。
|
|||
// </自动生成>
|
|||
//------------------------------------------------------------------------------
|
|||
|
|||
namespace SCP.Views.PlanData |
|||
{ |
|||
|
|||
|
|||
public partial class SCP_INVOICE |
|||
{ |
|||
|
|||
/// <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>
|
|||
/// Toolbar1 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.Toolbar Toolbar1; |
|||
|
|||
/// <summary>
|
|||
/// Button3 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.Button Button3; |
|||
|
|||
/// <summary>
|
|||
/// btnView 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.Button btnView; |
|||
|
|||
/// <summary>
|
|||
/// btnOutput 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.Button btnOutput; |
|||
|
|||
/// <summary>
|
|||
/// btnShow 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.Button btnShow; |
|||
|
|||
/// <summary>
|
|||
/// DDL_VEND_LIST 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.DropDownList DDL_VEND_LIST; |
|||
|
|||
/// <summary>
|
|||
/// BTN_INV 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.Button BTN_INV; |
|||
|
|||
/// <summary>
|
|||
/// gp1 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.GroupPanel gp1; |
|||
|
|||
/// <summary>
|
|||
/// FormRow_1 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.FormRow FormRow_1; |
|||
|
|||
/// <summary>
|
|||
/// ckb 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.CheckBoxList ckb; |
|||
|
|||
/// <summary>
|
|||
/// FormRow_2 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.FormRow FormRow_2; |
|||
|
|||
/// <summary>
|
|||
/// TXT_InvcBillNum 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.TextBox TXT_InvcBillNum; |
|||
|
|||
/// <summary>
|
|||
/// TXT_VendName 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.TextBox TXT_VendName; |
|||
|
|||
/// <summary>
|
|||
/// TXT_InvoiceNum 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.TextBox TXT_InvoiceNum; |
|||
|
|||
/// <summary>
|
|||
/// TXT_PO 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.TextBox TXT_PO; |
|||
|
|||
/// <summary>
|
|||
/// FormRow_3 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.FormRow FormRow_3; |
|||
|
|||
/// <summary>
|
|||
/// TXT_Site 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.TextBox TXT_Site; |
|||
|
|||
/// <summary>
|
|||
/// TXT_ASN 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.TextBox TXT_ASN; |
|||
|
|||
/// <summary>
|
|||
/// DP_CreateTime1 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.DatePicker DP_CreateTime1; |
|||
|
|||
/// <summary>
|
|||
/// DP_CreateTime2 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.DatePicker DP_CreateTime2; |
|||
|
|||
/// <summary>
|
|||
/// FormRow_4 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.FormRow FormRow_4; |
|||
|
|||
/// <summary>
|
|||
/// BTN_SEARCH 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.Button BTN_SEARCH; |
|||
|
|||
/// <summary>
|
|||
/// Grid_V_TB_INVOICE 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.Grid Grid_V_TB_INVOICE; |
|||
|
|||
/// <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>
|
|||
/// Total1 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::System.Web.UI.WebControls.Label Total1; |
|||
|
|||
/// <summary>
|
|||
/// Window1 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.Window Window1; |
|||
|
|||
/// <summary>
|
|||
/// Window2 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.Window Window2; |
|||
|
|||
/// <summary>
|
|||
/// WindowUpload 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.Window WindowUpload; |
|||
} |
|||
} |
@ -0,0 +1,153 @@ |
|||
<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="SCP_INVOICE_EDIT.aspx.cs" Inherits="SCP.Views.PlanData.SCP_INVOICE_EDIT" %> |
|||
|
|||
<!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"> |
|||
<Items> |
|||
<f:Form runat="server" Title=""> |
|||
<Toolbars> |
|||
<f:Toolbar ID="Toolbar2" runat="server"> |
|||
<Items> |
|||
<f:ToolbarSeparator ID="ToolbarSeparator3" runat="server"> |
|||
</f:ToolbarSeparator> |
|||
|
|||
<f:Button ID="btnOK" runat="server" Text="修改数据" Hidden="true" OnClientClick="if(!confirm('是否要修改发票?'))return false;" Icon="ApplicationEdit" OnClick="btnOK_Click"> |
|||
</f:Button> |
|||
|
|||
<f:Button ID="btnApply" runat="server" Text="提交申请" Hidden="true" OnClientClick="if(!confirm('是否要提交申请?'))return false;" Icon="Accept" OnClick="btnApply_Click"> |
|||
</f:Button> |
|||
|
|||
<f:Button ID="btnMail" runat="server" Text="寄出发票" Hidden="true" OnClientClick="if(!confirm('是否寄出发票?寄出前请检查发票时间和纸质发票时间是否一致!'))return false;" Icon="Mail" OnClick="btnMail_Click" ValidateForms="extForm1"> |
|||
</f:Button> |
|||
|
|||
<f:Button ID="btnReject" runat="server" Text="发票作废" Hidden="true" OnClientClick="if(!confirm('是否要作废收票?'))return false;" Icon="Exclamation" OnClick="btnReject_Click"> |
|||
</f:Button> |
|||
<f:Button ID="btnRed" runat="server" Hidden="true" Text="添加红字发票" OnClientClick="if(!confirm('是否要添加红字发票?'))return false;" Icon="Exclamation" OnClick="btnRed_Click"> |
|||
</f:Button> |
|||
</Items> |
|||
</f:Toolbar> |
|||
</Toolbars> |
|||
</f:Form> |
|||
<f:GroupPanel runat="server" ID="gp1" Layout="HBox" > |
|||
<Items> |
|||
<f:Form runat="server"> |
|||
<Rows> |
|||
<f:FormRow runat="server" ColumnWidths="20% 20% 20% 20% 20%" ID="FormRow_1"> |
|||
<Items> |
|||
<f:TextBox ID="txtBillNo" runat="server" Label="发票单号" Text="" MaxLength="100" Readonly="true" Enabled="false"> |
|||
</f:TextBox> |
|||
<f:TextBox ID="txtState" runat="server" Label="状态" Text="" MaxLength="100" Readonly="true" Enabled="false"> |
|||
</f:TextBox> |
|||
<f:TextBox ID="txtBillTime" runat="server" Label="创建时间" Text="" MaxLength="100" Readonly="true" Enabled="false" /> |
|||
<f:TextBox ID="txtSupplierName" runat="server" Label="供应商" Text="" MaxLength="100" Readonly="true" Enabled="false" /> |
|||
<f:Label runat="server" ID="Label3" /> |
|||
</Items> |
|||
</f:FormRow> |
|||
<f:FormRow runat="server" ColumnWidths="20% 20% 20% 20% 20%" ID="FormRow_2"> |
|||
<Items> |
|||
<f:TextBox ID="txtAmount" runat="server" Label="金额" Text="" Readonly="true" Enabled="false" /> |
|||
<f:Label runat="server" ID="Label1" Text="税率" /><f:DropDownList runat="server" Label="税率" ID="txtTax" AutoPostBack="true" > |
|||
<f:ListItem Text="0.16" Value="0.16" /> |
|||
<f:ListItem Text="0.13" Value="0.13" /> |
|||
<f:ListItem Text="0" Value="0" /> |
|||
</f:DropDownList> |
|||
<f:TextBox ID="txtTaxAmount" runat="server" Label="税额" Text="" Readonly="true" Enabled="false"> |
|||
</f:TextBox> |
|||
<f:TextBox ID="txtTotal" runat="server" Label="税后金额" Text="" Readonly="true" Enabled="false" /> |
|||
|
|||
</Items> |
|||
</f:FormRow> |
|||
<f:FormRow runat="server" ColumnWidths="20% 20% 20% 20% 20%" ID="FormRow_3"> |
|||
<Items> |
|||
<f:NumberBox ID="txtContractPrice1" runat="server" Label="索赔金额" Readonly="true" /> |
|||
<f:NumberBox ID="txtDiscountPrice" runat="server" Label="折扣金额" /> |
|||
<f:NumberBox ID="txtBlancePrice1" runat="server" Label="调整税额" MaxValue="1" /> |
|||
|
|||
<f:TextBox ID="txtInvoiceNumber" runat="server" Label="金税票号" Text="" MaxLength="22"> |
|||
</f:TextBox> |
|||
|
|||
</Items> |
|||
</f:FormRow> |
|||
<f:FormRow runat="server" ColumnWidths="20% 20% 20% 20% 20%" ID="FormRow_4"> |
|||
<Items> |
|||
<f:TextBox ID="txtExpressNumber" runat="server" Label="快递单号" Text="" MaxLength="100"> |
|||
</f:TextBox> |
|||
<f:DatePicker runat="server" ID ="dpUpdateTime" Label="发票时间"></f:DatePicker> |
|||
<f:TextBox ID="txtMemo" runat="server" Label="备注" Text="" MaxLength="100"> |
|||
</f:TextBox> |
|||
<f:Label runat="server" ID="l1" /> |
|||
|
|||
</Items> |
|||
</f:FormRow> |
|||
</Rows> |
|||
</f:Form> |
|||
</Items> |
|||
</f:GroupPanel> |
|||
<f:Grid ID="Grid1" ShowBorder="true" ShowHeader="true" PageSize="500" BoxFlex="1" CssClass="maingrid" |
|||
runat="server" DataKeyNames="UID,InvcBillNum,Qty,CanQty,State" IsDatabasePaging="True" AllowPaging="True" |
|||
EnableRowSelectEvent="True" AutoScroll="True" SortField="PoBillNum" OnRowDataBound="Grid1_RowDataBound"> |
|||
<Columns> |
|||
|
|||
<f:BoundField DataField="ID" HeaderText="ID" ColumnID="ID" Hidden="true" /> |
|||
<f:BoundField SortField="ProjectId" DataField="ProjectId" HeaderText="项目编号" ColumnID="ProjectId" Width="100px" /> |
|||
<f:BoundField SortField="PoBillNum" DataField="PoBillNum" HeaderText="订单" ColumnID="Line" Width="100px" /> |
|||
<f:BoundField SortField="PoLineNum" DataField="PoLineNum" HeaderText="订单行" ColumnID="ProductCode" Width="80px" /> |
|||
<%--<f:BoundField SortField="ProductName" DataField="AsnBillNum" HeaderText="收货单" ColumnID="ProductName" Width="100px" />--%> |
|||
<f:BoundField SortField="AsnBillNum" DataField="AsnBillNum" HeaderText="发货单" ColumnID="UnitCode" Width="120px" /> |
|||
<f:BoundField SortField="PartCode" DataField="PartCode" HeaderText="零件号" ColumnID="PackageQty" Width="80px" /> |
|||
<f:BoundField SortField="PartDesc1" DataField="PartDesc1" HeaderText="零件名称" ColumnID="CurrencyCode" Width="300px" /> |
|||
<f:BoundField SortField="Currency" DataField="Currency" HeaderText="币种" ColumnID="Price" Width="80px" /> |
|||
<f:TemplateField Width="90px" HeaderText="单价"> |
|||
<ItemTemplate> |
|||
<asp:TextBox ID="txtPrice" runat="server" Width="80px" onkeyup="if(isNaN(value))execCommand('undo')" onafterpaste="if(isNaN(value))execCommand('undo')" |
|||
Text='<%# Eval("Price") %>' MaxLength="12" ></asp:TextBox> |
|||
</ItemTemplate> |
|||
</f:TemplateField> |
|||
|
|||
|
|||
<f:BoundField SortField="PurCost" runat="server" HeaderText="采购价格" ColumnID="" DataField="PurCost" /> |
|||
|
|||
|
|||
<f:BoundField SortField="UpdateTime" runat="server" HeaderText="收货日期" ColumnID="" DataField="UpdateTime" /> |
|||
<f:BoundField SortField="CanQty" DataField="CanQty" HeaderText="可开票数量" ColumnID="OpenQty" Width="80px" /> |
|||
|
|||
<f:TemplateField HeaderText="开票数量" Width="90px"> |
|||
<ItemTemplate> |
|||
<asp:TextBox ID="txtQty" runat="server" Width="80px" |
|||
Text='<%# Eval("Qty") %>' MaxLength="12"></asp:TextBox> |
|||
</ItemTemplate> |
|||
</f:TemplateField> |
|||
|
|||
<f:TemplateField HeaderText="备注" Width="100px"> |
|||
<ItemTemplate> |
|||
<asp:TextBox ID="txtLineMemo" runat="server" Width="300px" |
|||
Text='<%# Eval("Remark") %>' MaxLength="200" ></asp:TextBox> |
|||
</ItemTemplate> |
|||
</f:TemplateField> |
|||
|
|||
|
|||
|
|||
|
|||
</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="640px" Width="700px" OnClose="Window1_OnClose"/> |
|||
<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> |
|||
</form> |
|||
</body> |
|||
</html> |
|||
|
@ -0,0 +1,528 @@ |
|||
using System; |
|||
using System.Collections.Generic; |
|||
using System.Linq; |
|||
using System.Web; |
|||
using System.Web.UI; |
|||
using System.Web.UI.WebControls; |
|||
using CK.SCP.Common; |
|||
using CK.SCP.Controller; |
|||
using CK.SCP.Models.Enums; |
|||
using CK.SCP.Models.ScpEntity; |
|||
using CK.SCP.Utils; |
|||
using FineUI; |
|||
using System.Drawing; |
|||
|
|||
|
|||
namespace SCP.Views.PlanData |
|||
{ |
|||
public partial class SCP_INVOICE_EDIT : PageBase |
|||
{ |
|||
protected void Page_Load(object sender, EventArgs e) |
|||
{ |
|||
IsRoleRight(); |
|||
|
|||
if (!IsPostBack) |
|||
{ |
|||
TranslatorAgents(Toolbar2); |
|||
TranslatorAgent(Grid1); |
|||
TranslatorAgents(FormRow_1); |
|||
TranslatorAgents(FormRow_2); |
|||
TranslatorAgents(FormRow_3); |
|||
TranslatorAgents(FormRow_4); |
|||
BindData(); |
|||
GetInvoice(); |
|||
SetRoleRule(); |
|||
|
|||
} |
|||
} |
|||
|
|||
public void IsRoleRight() |
|||
{ |
|||
//if (!CurrentUser.RoleList.Contains("供应商"))
|
|||
//{
|
|||
// Alert.Show("当前用户角色不能操作该模块!");
|
|||
// return;
|
|||
//}
|
|||
//if (CurrentUser.VenderList == null || CurrentUser.VenderList.Count == 0)
|
|||
//{
|
|||
// Alert.Show("当前用户未选择地点!");
|
|||
// return;
|
|||
//}
|
|||
} |
|||
|
|||
private void SetRoleRule() |
|||
{ |
|||
//IsPriceVisible(Grid1, "合同价格");
|
|||
//IsPriceVisible(Grid1, "合同差额");
|
|||
IsPriceVisible(Grid1, "要货日期"); |
|||
} |
|||
|
|||
private void Search(Action<IQueryable<V_TB_INVOICE_DETAIL>> p_list) |
|||
{ |
|||
|
|||
string id = GetQueryValue("ID"); |
|||
V_TB_INVOICE_DETAIL _tb = new V_TB_INVOICE_DETAIL(); |
|||
_tb.InvcBillNum = id; |
|||
SCP_INVOICE_CONTROLLER.Get_V_TB_INVOICE_DETAIL_List(_tb, (ret) => { |
|||
|
|||
if (ret.State == ReturnStatus.Succeed) |
|||
{ |
|||
p_list(ret.Result); |
|||
} |
|||
|
|||
}); |
|||
} |
|||
|
|||
public void BindData() |
|||
{ |
|||
Search(ret => |
|||
{ |
|||
Grid1.RecordCount = ret.Count(); |
|||
var list = SortAndPage(ret, Grid1); |
|||
//Grid1.DataSource =SCP_RECIVECE_CONTROLLER.Get_V_TB_INVOICE_LIST(list.ToList());
|
|||
List<V_TB_INVOICE_DETAIL> temp = SCP_RECIVECE_CONTROLLER.Get_V_TB_INVOICE_LIST(list.ToList()); |
|||
temp = SCP_CONTRACT_CONTROLLER.GET_CONTRACT_PRICE_LIST(temp); |
|||
GetInvoice(); |
|||
Grid1.DataSource = temp; |
|||
Grid1.DataBind(); |
|||
}); |
|||
|
|||
|
|||
} |
|||
|
|||
private void GetInvoice() |
|||
{ |
|||
string id = GetQueryValue("ID"); |
|||
string vendid = ""; |
|||
if (CurrentUser.VenderList != null && CurrentUser.VenderList.Count > 0) |
|||
{ |
|||
vendid = CurrentUser.VenderList[0]; |
|||
} |
|||
|
|||
SCP_INVOICE_CONTROLLER.Get_V_TB_INVOICE_List(new V_TB_INVOICE { InvcBillNum = id, VendId = vendid }, (ret) => { |
|||
|
|||
if (ret.State == ReturnStatus.Succeed) |
|||
{ |
|||
var _ls = ret.Result.ToList(); |
|||
if (_ls != null && _ls.Count > 0) |
|||
{ |
|||
var _Model = _ls[0]; |
|||
Session["Invoice"] = _Model; |
|||
txtState.Text = _Model.State_DESC; |
|||
txtBillNo.Text = _Model.InvcBillNum; |
|||
txtBillTime.Text = Convert.ToDateTime(_Model.CreateTime).ToString("yyyy-MM-dd"); |
|||
txtSupplierName.Text = _Model.VendName; |
|||
txtInvoiceNumber.Text = _Model.InvoiceNum; |
|||
txtExpressNumber.Text = _Model.ExpressNum; |
|||
|
|||
dpUpdateTime.SelectedDate = _Model.UpdateTime; |
|||
txtTax.SelectedValue = _Model.Tax != null ? _Model.Tax.Value.ToString() : "0"; |
|||
txtTaxAmount.Text = _Model.TaxAmount != null ? _Model.TaxAmount.Value.ToString() : "0"; |
|||
txtDiscountPrice.Text = _Model.DiscountPrice != null ? _Model.DiscountPrice.Value.ToString() : "0"; |
|||
//if (_Model.State != (int)InvoiceState.New)
|
|||
//{
|
|||
txtContractPrice1.Text = _Model.ContractPrice != null ? _Model.ContractPrice.ToString() : string.Empty; |
|||
txtBlancePrice1.Text = _Model.BlancePrice != null ? _Model.BlancePrice.ToString() : string.Empty; |
|||
//}
|
|||
txtAmount.Text = _Model.Amount.ToString(); |
|||
txtTotal.Text = _Model.Total != null ? _Model.Total.ToString() : string.Empty; |
|||
txtMemo.Text = _Model.Remark; |
|||
if (_Model.State == (int)InvoiceState.New ) |
|||
{ |
|||
this.btnOK.Hidden = false; |
|||
this.btnApply.Hidden = false; |
|||
this.btnReject.Hidden = false; |
|||
} |
|||
|
|||
if (_Model.State == (int)InvoiceState.Reject) |
|||
{ |
|||
this.btnReject.Hidden = true; |
|||
this.btnOK.Hidden = false; |
|||
} |
|||
|
|||
//提交之后不能作废
|
|||
if (_Model.State == (int)InvoiceState.New) |
|||
{ |
|||
this.btnOK.Hidden = false; |
|||
this.btnReject.Hidden = false; |
|||
} |
|||
|
|||
if (_Model.State == (int)InvoiceState.Apply) |
|||
{ |
|||
this.btnOK.Hidden = false; |
|||
this.btnApply.Hidden = true;//提交申请
|
|||
this.btnReject.Hidden = true;//发票作废
|
|||
this.btnMail.Hidden = true;//寄出发票
|
|||
} |
|||
|
|||
if (_Model.State == (int)InvoiceState.Mail) |
|||
{ |
|||
this.btnOK.Hidden = true;//确定修改
|
|||
this.btnApply.Hidden = true;//提交申请
|
|||
this.btnReject.Hidden = true;//发票作废
|
|||
this.btnMail.Hidden = true;//寄出发票
|
|||
|
|||
txtInvoiceNumber.Readonly = true; |
|||
txtInvoiceNumber.Required = false; |
|||
|
|||
txtExpressNumber.Readonly = true; |
|||
txtExpressNumber.Required = false; |
|||
|
|||
txtContractPrice1.Readonly = true; |
|||
txtContractPrice1.Required = false; |
|||
|
|||
txtBlancePrice1.Readonly = true; |
|||
txtBlancePrice1.Required = false; |
|||
} |
|||
|
|||
if (_Model.State == (int)InvoiceState.FinanceFail || _Model.State == (int)InvoiceState.CheckSuccess) |
|||
{ |
|||
txtInvoiceNumber.Readonly = false; |
|||
txtInvoiceNumber.Required = true; |
|||
txtExpressNumber.Readonly = false; |
|||
txtContractPrice1.Readonly = false; |
|||
txtContractPrice1.Required = false; |
|||
txtBlancePrice1.Readonly = false; |
|||
txtBlancePrice1.Required = false; |
|||
this.btnMail.Hidden = false; |
|||
this.btnReject.Hidden = false; |
|||
this.btnOK.Hidden = false; |
|||
} |
|||
if (_Model.State == (int)InvoiceState.CheckSuccess) |
|||
{ |
|||
this.btnOK.Hidden = true; |
|||
txtMemo.Enabled = false; |
|||
|
|||
for (int i = 0, count = Grid1.Rows.Count; i < count; i++) |
|||
{ |
|||
object[] rowDataKeys = Grid1.DataKeys[i]; |
|||
GridRow row = Grid1.Rows[i]; |
|||
|
|||
var txtPrice = (System.Web.UI.WebControls.TextBox)row.FindControl("txtPrice"); |
|||
var txtQty = (System.Web.UI.WebControls.TextBox)row.FindControl("txtQty"); |
|||
var txtLineMemo = (System.Web.UI.WebControls.TextBox)row.FindControl("txtLineMemo"); |
|||
|
|||
|
|||
txtPrice.ReadOnly = true; |
|||
txtPrice.Enabled = false; |
|||
txtQty.ReadOnly = true; |
|||
txtQty.Enabled = false; |
|||
txtLineMemo.ReadOnly = true; |
|||
txtLineMemo.Enabled = false; |
|||
|
|||
} |
|||
} |
|||
} |
|||
} |
|||
}); |
|||
|
|||
|
|||
} |
|||
|
|||
|
|||
protected void btnOK_Click(object sender, EventArgs e) |
|||
{ |
|||
|
|||
var _invoice = Session["Invoice"] as V_TB_INVOICE; |
|||
|
|||
string InvoiceNumber = MyWebString.GetString(this.txtInvoiceNumber.Text.Trim()); |
|||
string Memo = MyWebString.GetString(this.txtMemo.Text.Trim()); |
|||
string ExpressNumber = MyWebString.GetString(this.txtExpressNumber.Text.Trim()); |
|||
string ContractPrice1 = MyWebString.GetString(this.txtContractPrice1.Text.Trim());//合同价格
|
|||
string BlancePrice1 = MyWebString.GetString(this.txtBlancePrice1.Text.Trim());//合同差额
|
|||
string DiscountPrice1 = MyWebString.GetString(this.txtDiscountPrice.Text.Trim()); |
|||
//if (_invoice.State != (int)InvoiceState.New &&
|
|||
// _invoice.State != (int)InvoiceState.CheckFail)
|
|||
//{
|
|||
// Alert.Show(_invoice.InvcBillNum + " 不允许修改,只有状态为 " + "新建" + " 或 " +
|
|||
// "采购退回" + " 才能修改");
|
|||
// return;
|
|||
//}
|
|||
if (!string.IsNullOrEmpty(txtTax.SelectedValue)) |
|||
{ |
|||
_invoice.Tax = decimal.Parse(txtTax.SelectedValue); |
|||
} |
|||
_invoice.InvoiceNum = InvoiceNumber; |
|||
_invoice.Remark = Memo; |
|||
_invoice.ExpressNum = ExpressNumber; |
|||
|
|||
//_invoice.UpdateTime = dpUpdateTime.SelectedDate.Value;
|
|||
//_invoice.State = (int)InvoiceState.Apply;
|
|||
|
|||
if (string.IsNullOrEmpty(ContractPrice1)) |
|||
{ |
|||
_invoice.ContractPrice = 0; |
|||
} |
|||
|
|||
if (string.IsNullOrEmpty(BlancePrice1)) |
|||
{ |
|||
_invoice.BlancePrice = 0; |
|||
} |
|||
if (string.IsNullOrEmpty(DiscountPrice1)) |
|||
{ |
|||
_invoice.DiscountPrice = 0; |
|||
} |
|||
if (_invoice.State == (int)InvoiceState.CheckSuccess) |
|||
{ |
|||
|
|||
if (dpUpdateTime.SelectedDate == null) |
|||
{ |
|||
Alert.Show("发票时间必须填写,时间为纸质发票开票时间"); |
|||
return; |
|||
} |
|||
else |
|||
{ |
|||
_invoice.UpdateTime = dpUpdateTime.SelectedDate.Value; |
|||
} |
|||
} |
|||
|
|||
decimal c1; |
|||
decimal b1; |
|||
decimal d1; |
|||
if (decimal.TryParse(ContractPrice1, out c1)) |
|||
{ |
|||
_invoice.ContractPrice = c1; |
|||
} |
|||
//else
|
|||
//{
|
|||
// Alert.Show("折扣金额请填写数字!");
|
|||
// return;
|
|||
//}
|
|||
|
|||
if (decimal.TryParse(BlancePrice1, out b1)) |
|||
{ |
|||
_invoice.BlancePrice = b1; |
|||
} |
|||
if (decimal.TryParse(DiscountPrice1, out d1)) |
|||
{ |
|||
_invoice.DiscountPrice = d1; |
|||
} |
|||
//else
|
|||
//{
|
|||
// Alert.Show("调整请填写数字!");
|
|||
// return;
|
|||
//}
|
|||
|
|||
|
|||
List<V_TB_INVOICE_DETAIL> _ls = new List<V_TB_INVOICE_DETAIL>(); |
|||
if (this.txtQty.ReadOnly == false) |
|||
{ |
|||
|
|||
for (int i = 0, count = Grid1.Rows.Count; i < count; i++) |
|||
{ |
|||
object[] rowDataKeys = Grid1.DataKeys[i]; |
|||
GridRow row = Grid1.Rows[i]; |
|||
|
|||
V_TB_INVOICE_DETAIL _entity = new V_TB_INVOICE_DETAIL(); |
|||
_entity.UID = ConvertHelper.To<Int32>(rowDataKeys[0]); |
|||
_entity.InvcBillNum = rowDataKeys[1] as string; |
|||
_entity.Qty = ConvertHelper.To<Decimal>(rowDataKeys[2]); |
|||
_entity.CanQty = ConvertHelper.To<Decimal>(rowDataKeys[3]); |
|||
_entity.State = ConvertHelper.To<Int32>(rowDataKeys[4]); |
|||
var txtQty = (System.Web.UI.WebControls.TextBox)row.FindControl("txtQty"); |
|||
var txtPrice = (System.Web.UI.WebControls.TextBox)row.FindControl("txtPrice"); |
|||
var txtLineMemo = (System.Web.UI.WebControls.TextBox)row.FindControl("txtLineMemo"); |
|||
//var txtContractPrice = (System.Web.UI.WebControls.TextBox)row.FindControl("txtContractPrice");
|
|||
//var txtBlancePrice = (System.Web.UI.WebControls.TextBox)row.FindControl("txtBlancePrice");
|
|||
|
|||
decimal QtyNew = 0; |
|||
try |
|||
{ |
|||
if (txtQty.Text.Trim() != "") |
|||
{ |
|||
QtyNew = Convert.ToDecimal(txtQty.Text.Trim()); |
|||
} |
|||
} |
|||
catch |
|||
{ |
|||
Alert.Show("开票数量输入不正确"); |
|||
return; |
|||
} |
|||
|
|||
if (QtyNew > _entity.CanQty + _entity.Qty) |
|||
{ |
|||
Alert.Show("开票数量不能大于可用开数票"); |
|||
return; |
|||
|
|||
} |
|||
|
|||
decimal PriceNew = 0; |
|||
try |
|||
{ |
|||
if (txtPrice.Text.Trim() != "") |
|||
{ |
|||
PriceNew = Convert.ToDecimal(txtPrice.Text.Trim()); |
|||
} |
|||
} |
|||
catch |
|||
{ |
|||
Alert.Show("单价输入不正确"); |
|||
return; |
|||
} |
|||
_entity.Remark = txtLineMemo.Text; |
|||
_entity.Price = PriceNew; |
|||
_entity.Qty = QtyNew; |
|||
_ls.Add(_entity); |
|||
|
|||
} |
|||
} |
|||
|
|||
// SCPDB.Database.SqlQuery<V_TB_INVOICE>("select * from V_TB_INVOICE WHERE STATE==0 AND ").ToArray
|
|||
|
|||
if (_ls.Count > 0) |
|||
{ |
|||
var ret = SCP_INVOICE_CONTROLLER.SAVE_TB_INVOICE_APPLY(_invoice, _ls); |
|||
if (ret.State == ReturnStatus.Succeed) |
|||
{ |
|||
|
|||
Alert.Show("发票明细修改成功!"); |
|||
|
|||
BindData(); |
|||
} |
|||
} |
|||
else |
|||
{ |
|||
Alert.Show("更改记录数为零"); |
|||
} |
|||
|
|||
} |
|||
private void SET_INVOICE_STATE(string p_msg, InvoiceState p_state) |
|||
{ |
|||
if (Session["Invoice"] != null) |
|||
{ |
|||
var _Invoice = Session["Invoice"] as V_TB_INVOICE; |
|||
|
|||
string InvoiceNumber = MyWebString.GetString(this.txtInvoiceNumber.Text.Trim());//金税票号
|
|||
string ExpressNumber = MyWebString.GetString(this.txtExpressNumber.Text.Trim());//快递单号
|
|||
|
|||
string ContractPrice1 = MyWebString.GetString(this.txtContractPrice1.Text.Trim());//合同价格
|
|||
string BlancePrice1 = MyWebString.GetString(this.txtBlancePrice1.Text.Trim());//合同差额
|
|||
string DiscountPrice1 = MyWebString.GetString(this.txtDiscountPrice.Text.Trim()); |
|||
_Invoice.InvoiceNum = InvoiceNumber; |
|||
_Invoice.ExpressNum = ExpressNumber; |
|||
_Invoice.UpdateTime = dpUpdateTime.SelectedDate; |
|||
if (string.IsNullOrEmpty(ContractPrice1)) |
|||
{ |
|||
_Invoice.ContractPrice = 0; |
|||
} |
|||
if (string.IsNullOrEmpty(BlancePrice1)) |
|||
{ |
|||
_Invoice.BlancePrice = 0; |
|||
} |
|||
|
|||
decimal c1; |
|||
decimal b1; |
|||
decimal d1; |
|||
if (decimal.TryParse(ContractPrice1, out c1)) |
|||
{ |
|||
_Invoice.ContractPrice = c1; |
|||
} |
|||
else |
|||
{ |
|||
_Invoice.ContractPrice = 0; |
|||
} |
|||
|
|||
if (decimal.TryParse(BlancePrice1, out b1)) |
|||
{ |
|||
_Invoice.BlancePrice = b1; |
|||
} |
|||
else |
|||
{ |
|||
_Invoice.BlancePrice = 0; |
|||
} |
|||
if (decimal.TryParse(DiscountPrice1, out d1)) |
|||
{ |
|||
_Invoice.DiscountPrice = d1; |
|||
} |
|||
else |
|||
{ |
|||
_Invoice.DiscountPrice = 0; |
|||
} |
|||
if (p_state == InvoiceState.Mail) |
|||
{ |
|||
if (string.IsNullOrEmpty(InvoiceNumber)) |
|||
{ |
|||
Alert.Show("请填写金税票号!"); |
|||
return; |
|||
} |
|||
|
|||
if (string.IsNullOrEmpty(ExpressNumber)) |
|||
{ |
|||
Alert.Show("请填写快递单号!"); |
|||
return; |
|||
} |
|||
if (dpUpdateTime.SelectedDate == null) |
|||
{ |
|||
Alert.Show("发票时间必须填写,时间为纸质发票开票时间"); |
|||
return; |
|||
} |
|||
} |
|||
|
|||
var ret = SCP_INVOICE_CONTROLLER.SAVE_TB_INVOICE_STATE(_Invoice, p_state, CurrentUser.ChineseName); |
|||
if (ret.State == ReturnStatus.Succeed) |
|||
{ |
|||
Alert.Show(p_msg); |
|||
|
|||
BindData(); |
|||
GetInvoice(); |
|||
} |
|||
else |
|||
{ |
|||
Alert.Show(ret.Message); |
|||
} |
|||
} |
|||
} |
|||
|
|||
protected void btnApply_Click(object sender, EventArgs e) |
|||
{ |
|||
|
|||
SET_INVOICE_STATE("发票申请成功!", InvoiceState.Mail); |
|||
|
|||
} |
|||
|
|||
protected void btnMail_Click(object sender, EventArgs e) |
|||
{ |
|||
SET_INVOICE_STATE("发票已经寄出!", InvoiceState.Mail); |
|||
} |
|||
|
|||
protected void btnReject_Click(object sender, EventArgs e) |
|||
{ |
|||
SET_INVOICE_STATE("发票已经作废!", InvoiceState.Reject); |
|||
} |
|||
|
|||
protected void Window1_OnClose(object sender, WindowCloseEventArgs e) |
|||
{ |
|||
//string id = GetQueryValue("ID");
|
|||
|
|||
//TB_INVOICE model = InvoiceController.GetDataByBillInvoiceBillNum(id);
|
|||
//InvoiceController.UpdateDataRemark(e.CloseArgument, model);
|
|||
|
|||
} |
|||
|
|||
protected void btnRed_Click(object sender, EventArgs e) |
|||
{ |
|||
string id = GetQueryValue("ID"); |
|||
V_TB_INVOICE _tb = new V_TB_INVOICE(); |
|||
_tb.InvcBillNum = id; |
|||
var ret = SCP_INVOICE_CONTROLLER.Add_New_Red_Invoice(_tb); |
|||
|
|||
if (ret.State == ReturnStatus.Succeed) |
|||
{ |
|||
BindData(); |
|||
GetInvoice(); |
|||
} |
|||
} |
|||
|
|||
protected void Grid1_RowDataBound(object sender, GridRowEventArgs e) |
|||
{ |
|||
System.Web.UI.WebControls.TextBox _label = (System.Web.UI.WebControls.TextBox)Grid1.Rows[e.RowIndex].FindControl("txtQty"); |
|||
if (!string.IsNullOrEmpty(_label.Text)) |
|||
{ |
|||
if (decimal.Parse(_label.Text) < 0) |
|||
{ |
|||
_label.ForeColor = Color.Red; |
|||
} |
|||
} |
|||
} |
|||
} |
|||
} |
@ -0,0 +1,359 @@ |
|||
//------------------------------------------------------------------------------
|
|||
// <自动生成>
|
|||
// 此代码由工具生成。
|
|||
//
|
|||
// 对此文件的更改可能导致不正确的行为,如果
|
|||
// 重新生成代码,则所做更改将丢失。
|
|||
// </自动生成>
|
|||
//------------------------------------------------------------------------------
|
|||
|
|||
namespace SCP.Views.PlanData |
|||
{ |
|||
|
|||
|
|||
public partial class SCP_INVOICE_EDIT |
|||
{ |
|||
|
|||
/// <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>
|
|||
/// ToolbarSeparator3 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.ToolbarSeparator ToolbarSeparator3; |
|||
|
|||
/// <summary>
|
|||
/// btnOK 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.Button btnOK; |
|||
|
|||
/// <summary>
|
|||
/// btnApply 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.Button btnApply; |
|||
|
|||
/// <summary>
|
|||
/// btnMail 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.Button btnMail; |
|||
|
|||
/// <summary>
|
|||
/// btnReject 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.Button btnReject; |
|||
|
|||
/// <summary>
|
|||
/// btnRed 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.Button btnRed; |
|||
|
|||
/// <summary>
|
|||
/// gp1 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.GroupPanel gp1; |
|||
|
|||
/// <summary>
|
|||
/// FormRow_1 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.FormRow FormRow_1; |
|||
|
|||
/// <summary>
|
|||
/// txtBillNo 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.TextBox txtBillNo; |
|||
|
|||
/// <summary>
|
|||
/// txtState 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.TextBox txtState; |
|||
|
|||
/// <summary>
|
|||
/// txtBillTime 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.TextBox txtBillTime; |
|||
|
|||
/// <summary>
|
|||
/// txtSupplierName 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.TextBox txtSupplierName; |
|||
|
|||
/// <summary>
|
|||
/// Label3 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.Label Label3; |
|||
|
|||
/// <summary>
|
|||
/// FormRow_2 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.FormRow FormRow_2; |
|||
|
|||
/// <summary>
|
|||
/// txtAmount 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.TextBox txtAmount; |
|||
|
|||
/// <summary>
|
|||
/// Label1 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.Label Label1; |
|||
|
|||
/// <summary>
|
|||
/// txtTax 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.DropDownList txtTax; |
|||
|
|||
/// <summary>
|
|||
/// txtTaxAmount 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.TextBox txtTaxAmount; |
|||
|
|||
/// <summary>
|
|||
/// txtTotal 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.TextBox txtTotal; |
|||
|
|||
/// <summary>
|
|||
/// FormRow_3 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.FormRow FormRow_3; |
|||
|
|||
/// <summary>
|
|||
/// txtContractPrice1 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.NumberBox txtContractPrice1; |
|||
|
|||
/// <summary>
|
|||
/// txtDiscountPrice 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.NumberBox txtDiscountPrice; |
|||
|
|||
/// <summary>
|
|||
/// txtBlancePrice1 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.NumberBox txtBlancePrice1; |
|||
|
|||
/// <summary>
|
|||
/// txtInvoiceNumber 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.TextBox txtInvoiceNumber; |
|||
|
|||
/// <summary>
|
|||
/// FormRow_4 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.FormRow FormRow_4; |
|||
|
|||
/// <summary>
|
|||
/// txtExpressNumber 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.TextBox txtExpressNumber; |
|||
|
|||
/// <summary>
|
|||
/// dpUpdateTime 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.DatePicker dpUpdateTime; |
|||
|
|||
/// <summary>
|
|||
/// txtMemo 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.TextBox txtMemo; |
|||
|
|||
/// <summary>
|
|||
/// l1 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.Label l1; |
|||
|
|||
/// <summary>
|
|||
/// Grid1 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.Grid Grid1; |
|||
|
|||
/// <summary>
|
|||
/// txtPrice 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::System.Web.UI.WebControls.TextBox txtPrice; |
|||
|
|||
/// <summary>
|
|||
/// txtQty 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::System.Web.UI.WebControls.TextBox txtQty; |
|||
|
|||
/// <summary>
|
|||
/// txtLineMemo 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::System.Web.UI.WebControls.TextBox txtLineMemo; |
|||
|
|||
/// <summary>
|
|||
/// Window1 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.Window Window1; |
|||
|
|||
/// <summary>
|
|||
/// WindowUpload 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.Window WindowUpload; |
|||
} |
|||
} |
@ -0,0 +1,246 @@ |
|||
<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="SCP_RECEIVE_LIST.aspx.cs" Inherits="SCP.Views.PlanData.SCP_RECEIVE_LIST" %><%@ Register Assembly="System.Web.DataVisualization, Version=4.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" Namespace="System.Web.UI.DataVisualization.Charting" TagPrefix="asp" %> |
|||
|
|||
<%@ Import Namespace="CK.SCP.Utils" %> |
|||
<%@ Import Namespace="CK.SCP.Models.Enums" %> |
|||
|
|||
<!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> |
|||
<style> |
|||
.totalpanel .x-panel-body { |
|||
border-top-width: 0 !important; |
|||
} |
|||
</style> |
|||
</head> |
|||
<body> |
|||
<form id="form1" runat="server"> |
|||
<f:PageManager runat="server" AutoSizePanelID="Panel1" /> |
|||
<f:Panel ID="Panel1" runat="server" Title="" Layout="VBox" BoxConfigAlign="Stretch" BoxConfigPosition="Start"> |
|||
<Items> |
|||
<f:Form runat="server"> |
|||
<Toolbars> |
|||
<f:Toolbar ID="Toolbar2" runat="server"> |
|||
<Items> |
|||
<f:Button ID="Button1" runat="server" EnablePostBack="True" Text="刷新" Icon="Reload" OnClientClick="location.reload();"> |
|||
</f:Button> |
|||
<f:Button ID="btnCreate" runat="server" EnablePostBack="True" Text="生成发票" OnClick="btnCreate_OnClick" Icon="Add" Hidden="true"> |
|||
</f:Button> |
|||
<f:Button ID="btnCreateAll" runat="server" EnablePostBack="True" Text="生成发票" Icon="Add" OnClick="btnCreateAll_Click" OnClientClick="if(!confirm('生成发票时请先处理退货数量,如发现收票时还有退货数量未处理,造成不能收票自行负责!'))return false;"> |
|||
</f:Button> |
|||
<f:Button ID="btn" runat="server" EnablePostBack="True" Text="补开发票" Icon="Add" Hidden="true"> |
|||
</f:Button> |
|||
<f:Button ID="Button2" runat="server" EnablePostBack="True" Text="导出" Icon="PageExcel" OnClick="btnOutput_OnClick"> |
|||
</f:Button> |
|||
<f:Button ID="btnCanIn" runat="server" EnablePostBack="True" Text="只看可开票零件" Icon="Zoom" OnClick="btnCanIn_Click" Hidden="true"> |
|||
</f:Button> |
|||
<f:Button ID="btnShow" runat="server" Text="查询面板" Icon="Zoom" OnClick="btnShow_Click"> |
|||
</f:Button> |
|||
<f:ToolbarFill runat="server" Hidden="true"/> |
|||
<f:TextBox ID="tb_RecvBillNum" runat="server" Label="单据号" Hidden="true"/> |
|||
<f:Button ID="btn_Search" runat="server" EnablePostBack="True" Text="快速查找" OnClick="btnSearch_Click" Hidden="true"></f:Button> |
|||
<f:DropDownList ID="DDL_VEND_LIST" DataValueField="VendId" DataTextField="VendName" runat="server" Label="供应商编码" EnableEdit="true" EnableMultiSelect="false" Hidden="true"/> |
|||
<f:Button ID="BTN_INV" runat="server" EnablePostBack="True" Text="确认" OnClick="BTN_INV_Click" Hidden="true" Icon="Accept" ></f:Button> |
|||
</Items> |
|||
</f:Toolbar> |
|||
</Toolbars> |
|||
</f:Form> |
|||
|
|||
|
|||
|
|||
<f:GroupPanel runat="server" ID="gp1" Hidden="true" Layout="HBox" > |
|||
<Items> |
|||
<f:Form runat="server" > |
|||
<Rows> |
|||
<f:FormRow runat="server" ID="FormRow_1"> |
|||
<Items> |
|||
|
|||
<f:TextBox runat = "server" Label = "订单编号" EmptyText = "" ID = "TXT_BillNo" /> |
|||
<f:TextBox runat = "server" Label = "发货单号" EmptyText = "" ID = "TXT_ASNBill" /> |
|||
<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" ID="FormRow_2"> |
|||
<Items> |
|||
<f:TextBox runat = "server" Label = "项目编号" EmptyText = "" ID = "TXT_ProjectId" /> |
|||
<f:TextBox runat = "server" Label = "零件编号" EmptyText = "" ID = "TXT_PartCode" /> |
|||
<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" EmptyText="请选择日期" Label="至" ID="Date_EndDate" /> |
|||
</Items> |
|||
</f:FormRow> |
|||
<f:FormRow runat="server" ID="FormRow_3"> |
|||
<Items> |
|||
<f:TextBox runat = "server" Label = "ERP收(退)货单号" EmptyText = "" ID = "TXT_ERPBillNo" /> |
|||
<f:TextBox runat = "server" Label = "WMS收(退)货单号" EmptyText = "" ID = "TXT_RECEIVE" /> |
|||
<f:DropDownList runat="server" ID="DDL_State" Label="单据类型" Text="单据类型"> |
|||
<f:ListItem Text="-" Value=""/> |
|||
<f:ListItem Text="退货单" Value="退货单" /> |
|||
<f:ListItem Text="收货单" Value="收货单" /> |
|||
</f:DropDownList> |
|||
<f:Button runat="server" Text="关闭" ID="BtnClose" OnClick="BtnClose_Click"></f:Button> |
|||
<f:Button ID="BtnSearch" runat="server" OnClick="BtnSearch_Click" Text="快速查找"> |
|||
</f:Button> |
|||
|
|||
</Items> |
|||
</f:FormRow> |
|||
</Rows> |
|||
</f:Form> |
|||
|
|||
</Items> |
|||
</f:GroupPanel> |
|||
<f:Form runat="server" Title=""> |
|||
<Items> |
|||
<f:FormRow runat="server" ColumnWidths="33% 33% 33%" ID="FormRow1"> |
|||
<Items> |
|||
<f:NumberBox ID="txtContractPrice1" runat="server" Label="折扣金额" Hidden="true" /> |
|||
<f:NumberBox ID="txtBlancePrice1" runat="server" Label="调整税额" MaxValue="1" Hidden="true" /> |
|||
<f:Label runat="server"></f:Label> |
|||
<f:Label runat="server"></f:Label> |
|||
</Items> |
|||
</f:FormRow> |
|||
<f:FormRow runat="server" ColumnWidths="33% 33% 33%" ID="FormRow2"> |
|||
<Items> |
|||
<f:DropDownList runat="server" Label="供应商税率" ID="lbTaxRate" AutoPostBack="true" > |
|||
<f:ListItem Text="0.16" Value="0.16" /> |
|||
<f:ListItem Text="0.13" Value="0.13" /> |
|||
<f:ListItem Text="0" Value="0" /> |
|||
</f:DropDownList> |
|||
<f:Button ID="btnTax" runat="server" Text="使用税率" OnClientClick="updateTotal();" Icon="Accept" ></f:Button> |
|||
<f:Label runat="server"></f:Label> |
|||
<f:Label runat="server"></f:Label> |
|||
</Items> |
|||
</f:FormRow> |
|||
</Items> |
|||
</f:Form> |
|||
<f:Grid id="Grid_V_TB_RECEIVE_LIST" ShowBorder="true" ShowHeader="true" PageSize="200" BoxFlex="1" CssClass="maingrid" |
|||
runat="server" DataKeyNames="UID,ProjectId,RecvBillNum,PartCode,PoLine,Qty,Price" IsDatabasePaging="true" AllowPaging="True" SortField="BillType;PartCode" OnSort="Grid1_Sort" AllowSorting="true" |
|||
AutoScroll="True" OnPageIndexChange="Grid_V_TB_RECEIVE_LIST_PageIndexChange" EnableCheckBoxSelect = "true" OnRowDataBound="Grid_V_TB_RECEIVE_LIST_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_OnSelectedIndexChanged" runat="server"> |
|||
<f:ListItem Text="200" Value="200" /> |
|||
<f:ListItem Text="500" Value="500" /> |
|||
<f:ListItem Text="1000" Value="1000" /> |
|||
<f:ListItem Text="5000" Value="5000" /> |
|||
</f:DropDownList> |
|||
</PageItems> |
|||
<Columns> |
|||
<%-- <f:RowNumberField runat="server" ID="chb" HeaderText="行号" />--%> |
|||
<%-- <f:TemplateField HeaderText="否可开票" Width="120px" ColumnID="IsCheck"> |
|||
<ItemTemplate> |
|||
<asp:Label runat="server" DataField="Qty" ID="Label1" Text='<%# Eval("IsCheck") %>'></asp:Label> |
|||
</ItemTemplate> |
|||
</f:TemplateField>--%> |
|||
|
|||
<f:BoundField runat="server" HeaderText="项目编码" SortField="ProjectId" DataField="ProjectId" width="80"/> |
|||
<f:BoundField runat="server" HeaderText="单据类型" SortField="BillType_DESC" ColumnID="BillType_DESC" DataField="BillType_DESC" width="80"/> |
|||
<f:BoundField runat="server" HeaderText="ERP单据号" SortField="ErpRecvBillNum" ColumnID="ErpRecvBillNum" DataField="ErpRecvBillNum" width="80" /> |
|||
<f:BoundField runat="server" HeaderText="WMS单据号" SortField="RecvBillNum" ColumnID="RecvBillNum" DataField="RecvBillNum" width="80" /> |
|||
<f:BoundField runat="server" HeaderText="发货单号" SortField="AsnBillNum" ColumnID="AsnBillNum" DataField="AsnBillNum" width="80"/> |
|||
<f:BoundField runat="server" HeaderText="供应商" SortField="VendName" ColumnID="VendName" DataField="VendName" /> |
|||
<f:BoundField runat="server" HeaderText="供应商编码" SortField="VendId" DataField="VendId" width="80"/> |
|||
<f:BoundField runat="server" HeaderText="订单号" SortField="PoBillNum" ColumnID="PoBillNum" DataField="PoBillNum" width="80"/> |
|||
<f:BoundField runat="server" HeaderText="订单行" SortField="PoLine" ColumnID="PoLine" DataField="PoLine" width="50" /> |
|||
<f:BoundField runat="server" HeaderText="单价" ColumnID="" DataField="Price" width="80"/> |
|||
|
|||
<f:BoundField runat="server" HeaderText="采购价格" ColumnID="" DataField="PurPrice" width="80"/> |
|||
|
|||
<f:TemplateField HeaderText="可开票数量" ColumnID="Qty" width="100"> |
|||
<ItemTemplate> |
|||
<input type="hidden" class="price" runat="server" value='<%# Eval("Price") %>' /> |
|||
<input type="hidden" class="number" runat="server" value='<%# Eval("CanQty") %>' /> |
|||
<asp:Label runat="server" DataField="Qty" ID="Qty1" Text='<%# Eval("CanQty") %>'></asp:Label> |
|||
</ItemTemplate> |
|||
</f:TemplateField> |
|||
<f:BoundField runat="server" HeaderText="零件号" SortField="PartCode" ColumnID="PartCode" DataField="PartCode" width="80"/> |
|||
<f:BoundField runat="server" HeaderText="零件名称" SortField="PartDesc1" ColumnID="PartDesc1" DataField="PartDesc1" /> |
|||
<f:BoundField runat="server" HeaderText="单位" SortField="LocUnit" ColumnID="LocUnit" DataField="LocUnit" width="50"/> |
|||
<f:BoundField runat="server" HeaderText="币种" SortField="Currency" ColumnID="Currency" DataField="Currency" width="50"/> |
|||
|
|||
<f:BoundField runat="server" HeaderText="Erp收货单税率" SortField="Tax" ColumnID="Tax" DataField="Tax" width="50" Hidden="true"/> |
|||
|
|||
<f:BoundField runat="server" HeaderText="要货日期" SortField="BeginTime" ColumnID="BeginTime" DataField="BeginTime" Hidden="true"/> |
|||
<f:BoundField runat="server" HeaderText="收货时间" SortField="ShipTime" ColumnID="ShipTime" DataField="ShipTime" DataFormatString="{0:yyyy-MM-dd}" /> |
|||
<f:BoundField runat="server" HeaderText="备注" ColumnID="Remark" DataField="Remark" /> |
|||
</Columns> |
|||
</f:Grid> |
|||
<f:ContentPanel runat="server" CssClass="totalpanel" ShowBorder="true" ShowHeader="false" ColumnWidth="50%"> |
|||
<div style="margin-bottom: 10px; "> |
|||
<input type="hidden" id="TOTAL_PRICE" name="TOTAL_PRICE" /> |
|||
总计:<span id="totalPrice" style="color: red; font-size: 1.5em; font-weight: bold;" ></span> |
|||
<input type="hidden" id="TOTAL_PRICE1" name="TOTAL_PRICE1" /> |
|||
<input type="hidden" id="TOTAL_PRICE_TAX" name="TOTAL_PRICE_TAX" /> |
|||
税额:<span id="totalPriceTax" style="color: red; font-size: 1.5em; font-weight: bold;" ></span> |
|||
税后金额:<span id="totalPrice1" style="color: red; font-size: 1.5em; font-weight: bold;" ></span> |
|||
</div> |
|||
<%--<div style="margin-bottom: 10px;"> |
|||
</div> |
|||
<div style="margin-bottom: 10px;"> |
|||
</div>--%> |
|||
|
|||
|
|||
</f:ContentPanel> |
|||
</Items> |
|||
</f:Panel> |
|||
<f:Window runat="server" ID="Window1" Hidden="True" Height="600px" Width="1024px" AutoScroll="True" OnClose="Window1_Close" |
|||
WindowPosition="Center" IsModal="true" Title="明细详情" Target="Parent" EnableIFrame="true" |
|||
IFrameUrl="about:blank" /> |
|||
</form> |
|||
<script src="../../res/js/jquery.min.js"></script> |
|||
<script type="text/javascript"> |
|||
var gridClientID = '<%= Grid_V_TB_RECEIVE_LIST.ClientID %>'; |
|||
var taxRateClientID = '<%= lbTaxRate.ClientID %>'; |
|||
var priceSelector = '.f-grid-tpl input.price'; |
|||
var numberSelector = '.f-grid-tpl input.number'; |
|||
function getRowPrice(row) { |
|||
return parseFloat(row.find(priceSelector).val()); |
|||
} |
|||
function getRowNumber(row) { |
|||
var num = parseFloat(row.find(numberSelector).val(), 10); |
|||
return num; |
|||
} |
|||
function updateTotal() { |
|||
var grid = F(gridClientID); |
|||
var tax = F(taxRateClientID); |
|||
var selection = grid.getSelectionModel().getSelection(); |
|||
var store = grid.getStore(); |
|||
var total = 0; |
|||
$.each(selection, function (index, item) { |
|||
var rowIndex = store.indexOf(item); |
|||
var row = $(grid.body.el.dom).find('.x-grid-item').eq(rowIndex); |
|||
total += getRowNumber(row) * getRowPrice(row); |
|||
}); |
|||
$('#totalPrice').text( total.toFixed(4)); |
|||
$('#TOTAL_PRICE').val(total.toFixed(4)); |
|||
var _tax = total.toFixed(4) * parseFloat(tax.value); |
|||
var _totalPrice1 =parseFloat(total) + parseFloat(_tax); |
|||
$('#totalPriceTax').text( _tax.toFixed(4)); |
|||
$('#TOTAL_PRICE_TAX').val(_tax.toFixed(4)); |
|||
$('#totalPrice1').text( _totalPrice1.toFixed(4)); |
|||
$('#TOTAL_PRICE1').val(_totalPrice1); |
|||
|
|||
} |
|||
function registerSelectionChangeEvents() { |
|||
var grid = F(gridClientID); |
|||
|
|||
grid.on('selectionchange', function (cmp, selected) { |
|||
updateTotal(); |
|||
}); |
|||
} |
|||
// 页面第一次加载完成后调用的函数 |
|||
F.ready(function () { |
|||
registerSelectionChangeEvents(); |
|||
updateTotal(); |
|||
}); |
|||
|
|||
</script> |
|||
</body> |
|||
</html> |
@ -0,0 +1,529 @@ |
|||
using System; |
|||
using System.Collections.Generic; |
|||
using System.Linq; |
|||
using System.Linq.Expressions; |
|||
using System.Web; |
|||
using System.Web.Security; |
|||
using System.Web.UI; |
|||
using System.Web.UI.WebControls; |
|||
using CK.SCP.Models.AppBoxEntity; |
|||
using CK.SCP.Models.ScpEntity; |
|||
using CK.SCP.Controller; |
|||
using FineUI; |
|||
using SCP.Code; |
|||
using System.Drawing; |
|||
using CK.SCP.Models.Enums; |
|||
using CK.SCP.Models; |
|||
|
|||
namespace SCP.Views.PlanData |
|||
{ |
|||
public partial class SCP_RECEIVE_LIST : PageBase |
|||
{ |
|||
protected void Page_Load(object sender, EventArgs e) |
|||
{ |
|||
IsRoleRight(); |
|||
|
|||
if (!IsPostBack) |
|||
{ |
|||
TranslatorAgents(Toolbar2); |
|||
TranslatorAgent(Grid_V_TB_RECEIVE_LIST); |
|||
TranslatorAgents(FormRow_1); |
|||
TranslatorAgents(FormRow_2); |
|||
TranslatorAgents(FormRow_3); |
|||
LoadData(); |
|||
SetRoleRule(); |
|||
BindVenderByUser(DDL_VEND_LIST); |
|||
} |
|||
} |
|||
public void IsRoleRight() |
|||
{ |
|||
|
|||
//if (!CurrentUser.RoleList.Contains("供应商"))
|
|||
//{
|
|||
// Alert.Show("当前用户角色不能操作该模块!");
|
|||
// return;
|
|||
//}
|
|||
//else
|
|||
//{
|
|||
|
|||
//}
|
|||
//if (CurrentUser.VenderList == null || CurrentUser.VenderList.Count == 0)
|
|||
//{
|
|||
// Alert.Show("当前用户未选择地点!");
|
|||
// return;
|
|||
//}
|
|||
} |
|||
private void SetRoleRule() |
|||
{ |
|||
if (CurrentUser.RoleList.Contains("采购人员")) |
|||
{ |
|||
DDL_VEND_LIST.Hidden = false; |
|||
BTN_INV.Hidden = false; |
|||
if (CurrentUser.FactoryList != null && CurrentUser.FactoryList.Count > 0) |
|||
{ |
|||
var _site = CurrentUser.FactoryList.FirstOrDefault(); |
|||
if (_site == "CNS") |
|||
{ |
|||
txtContractPrice1.Enabled = false; |
|||
} |
|||
} |
|||
} |
|||
} |
|||
|
|||
public void LoadData() |
|||
{ |
|||
// 每页记录数
|
|||
Grid_V_TB_RECEIVE_LIST.PageSize = ConfigHelper.PageSize; |
|||
ddlGridPageSize.SelectedValue = ConfigHelper.PageSize.ToString(); |
|||
BindData(); |
|||
} |
|||
private void SearchData(Action<IQueryable<V_TB_RECEIVE_LIST>> p_action) |
|||
{ |
|||
V_TB_RECEIVE_LIST _ls = new V_TB_RECEIVE_LIST(); |
|||
_ls.PoBillNum = TXT_BillNo.Text; |
|||
_ls.VendName = TXT_VendName.Text; |
|||
|
|||
_ls.AsnBillNum = TXT_ASNBill.Text; |
|||
_ls.PartCode = TXT_PartCode.Text; |
|||
_ls.VendId = TXT_VendId.Text; |
|||
_ls.ProjectId = TXT_ProjectId.Text; |
|||
_ls.ErpRecvBillNum = TXT_ERPBillNo.Text; |
|||
_ls.RecvBillNum = TXT_RECEIVE.Text; |
|||
if (DP_StartDate.SelectedDate != null) |
|||
{ |
|||
_ls.BeginTime = DP_StartDate.SelectedDate; |
|||
} |
|||
if (Date_EndDate.SelectedDate != null) |
|||
{ |
|||
_ls.ShipTime = Date_EndDate.SelectedDate; |
|||
} |
|||
if (!string.IsNullOrEmpty(DDL_State.SelectedValue)) |
|||
{ |
|||
_ls.BillType_DESC = DDL_State.SelectedValue; |
|||
} |
|||
if (CurrentUser.FactoryList != null && CurrentUser.FactoryList.Count > 0) |
|||
{ |
|||
_ls.Site = CurrentUser.FactoryList[0]; |
|||
} |
|||
_ls.State = 1; |
|||
|
|||
|
|||
|
|||
|
|||
if (CurrentUser.RoleList.Contains("采购人员")) |
|||
{ |
|||
if (string.IsNullOrEmpty(DDL_VEND_LIST.SelectedValue)) |
|||
{ |
|||
Alert.Show("请在工具栏里选择要开票的供应商,并点击确认!"); |
|||
return; |
|||
} |
|||
var _venderId = DDL_VEND_LIST.SelectedValue; |
|||
_ls.VendId = DDL_VEND_LIST.SelectedValue; |
|||
if (!string.IsNullOrEmpty(_ls.Site) && !string.IsNullOrEmpty(_venderId)) |
|||
{ |
|||
var _vender = SCP_TB_VENDER_CONTROLLER.GetVender(_venderId, _ls.Site); |
|||
if (_vender.Tax > 0 && _vender.Tax != null) |
|||
{ |
|||
lbTaxRate.SelectedValue = _vender.Tax.ToString(); |
|||
} |
|||
else |
|||
{ |
|||
lbTaxRate.SelectedValue = "0"; |
|||
} |
|||
} |
|||
} |
|||
else |
|||
{ |
|||
if (CurrentUser.VenderList != null && CurrentUser.VenderList.Count > 0) |
|||
{ |
|||
var _venderId = CurrentUser.VenderList.FirstOrDefault(); |
|||
_ls.VendId = _venderId; |
|||
if (!string.IsNullOrEmpty(_ls.Site) && !string.IsNullOrEmpty(_venderId)) |
|||
{ |
|||
var _vender = SCP_TB_VENDER_CONTROLLER.GetVender(_venderId, _ls.Site); |
|||
if (_vender.Tax > 0 && _vender.Tax != null) |
|||
{ |
|||
lbTaxRate.SelectedValue = _vender.Tax.ToString(); |
|||
} |
|||
else |
|||
{ |
|||
lbTaxRate.SelectedValue = "0"; |
|||
} |
|||
} |
|||
} |
|||
} |
|||
if (string.IsNullOrEmpty(_ls.VendId)) |
|||
{ |
|||
return; |
|||
} |
|||
SCP_RECIVECE_CONTROLLER.Get_V_TB_RECEIVE_LIST_List(_ls, (ret) => |
|||
{ |
|||
if (ret.State == ReturnStatus.Succeed) |
|||
{ |
|||
p_action(ret.Result); |
|||
} |
|||
}); |
|||
|
|||
} |
|||
public void BindData() |
|||
{ |
|||
SearchData(ret => |
|||
{ |
|||
if (CurrentUser.RoleList.Contains("采购人员")) |
|||
{ |
|||
Grid_V_TB_RECEIVE_LIST.RecordCount = ret.Count(); |
|||
ret = SortAndPage(ret, Grid_V_TB_RECEIVE_LIST, "DESC"); |
|||
|
|||
List<V_TB_RECEIVE_LIST> temp = ret.ToList(); |
|||
if (string.IsNullOrEmpty(DDL_VEND_LIST.SelectedValue)) |
|||
{ |
|||
Alert.Show("请在工具栏里选择要开票的供应商,并点击确认!"); |
|||
return; |
|||
} |
|||
|
|||
Grid_V_TB_RECEIVE_LIST.DataSource = temp; |
|||
Grid_V_TB_RECEIVE_LIST.DataBind(); |
|||
} |
|||
else |
|||
{ |
|||
|
|||
Grid_V_TB_RECEIVE_LIST.RecordCount = ret.Count(); |
|||
ret = SortAndPage(ret, Grid_V_TB_RECEIVE_LIST, "DESC"); |
|||
List<V_TB_RECEIVE_LIST> temp = ret.ToList(); |
|||
|
|||
Grid_V_TB_RECEIVE_LIST.DataSource = temp; |
|||
Grid_V_TB_RECEIVE_LIST.DataBind(); |
|||
} |
|||
}); |
|||
// 排列和数据库分页
|
|||
} |
|||
protected void Grid1_OnPageIndexChange(object sender, GridPageEventArgs e) |
|||
{ |
|||
Grid_V_TB_RECEIVE_LIST.PageIndex = e.NewPageIndex; |
|||
BindData(); |
|||
} |
|||
|
|||
protected void ddlGridPageSize_OnSelectedIndexChanged(object sender, EventArgs e) |
|||
{ |
|||
Grid_V_TB_RECEIVE_LIST.PageSize = Convert.ToInt32(ddlGridPageSize.SelectedValue); |
|||
BindData(); |
|||
} |
|||
//生成发票
|
|||
protected void btnCreate_OnClick(object sender, EventArgs e) |
|||
{ |
|||
CreateInvoice("0"); |
|||
} |
|||
private void CreateInvoice(string p_all) |
|||
{ |
|||
try |
|||
{ |
|||
|
|||
string vender = string.Empty; |
|||
if (CurrentUser.RoleList.Contains("采购人员")) |
|||
{ |
|||
if (string.IsNullOrEmpty(DDL_VEND_LIST.SelectedValue)) |
|||
{ |
|||
Alert.Show("请在工具栏里选择要开票的供应商,并点击确认!"); |
|||
return; |
|||
} |
|||
vender = DDL_VEND_LIST.SelectedValue; |
|||
} |
|||
else |
|||
{ |
|||
vender = CurrentUser.VenderList[0]; |
|||
} |
|||
|
|||
TM_HYANTOLIN_REVIEW _entity = new TM_HYANTOLIN_REVIEW(); |
|||
_entity.UltimateName = vender; |
|||
_entity.State = 0; |
|||
var _state = 0; |
|||
SCP_QUALITY_CONTROLLER.Get_TM_HYANTOLIN_REVIEW_List(_entity, (rs) => |
|||
{ |
|||
if (rs.State == ReturnStatus.Succeed) |
|||
{ |
|||
var _ls = rs.Result.ToList(); |
|||
if (_ls != null && _ls.Count > 0) |
|||
{ |
|||
var _sum = _ls.Sum(p => p.ClaimAmount); |
|||
var _ary = _ls.Select(p => p.ReviewBillNum).ToList(); |
|||
_state = 1; |
|||
if (_sum == 0) |
|||
{ |
|||
_state = 0; |
|||
} |
|||
if (_sum > 0) |
|||
{ |
|||
Alert.Show(string.Format("索赔金额合计{0}供应商存在未处理索赔单{1}!", _sum.ToString(), string.Join(",", _ary.ToArray())), "索赔管理查看"); |
|||
} |
|||
} |
|||
} |
|||
}); |
|||
if (_state == 1) |
|||
{ |
|||
return; |
|||
} |
|||
var _tax = lbTaxRate.SelectedValue; |
|||
var _cj = string.IsNullOrEmpty(txtContractPrice1.Text) ? "0" : txtContractPrice1.Text; |
|||
var _tz = string.IsNullOrEmpty(txtBlancePrice1.Text) ? "0" : txtBlancePrice1.Text; |
|||
|
|||
string IsCreate = "0"; |
|||
|
|||
if (Grid_V_TB_RECEIVE_LIST.SelectedRowIndexArray.Length == 0) |
|||
{ |
|||
Alert.Show("请选择要创建发票的记录!"); |
|||
return; |
|||
} |
|||
string IDS = ""; |
|||
List<string> _list = new List<string>(); |
|||
List<string> _projectList = new List<string>(); |
|||
List<string> _rejList = new List<string>(); |
|||
string _projectId = string.Empty; |
|||
List<string> _recList = new List<string>(); |
|||
List<int> IdList = new List<int>(); |
|||
decimal _total = 0; |
|||
|
|||
for (int i = 0; i < Grid_V_TB_RECEIVE_LIST.SelectedRowIndexArray.Length; i++) |
|||
{ |
|||
int rowIndex = Grid_V_TB_RECEIVE_LIST.SelectedRowIndexArray[i]; |
|||
int ID = Convert.ToInt32(Grid_V_TB_RECEIVE_LIST.DataKeys[rowIndex][0]); |
|||
|
|||
decimal _qty = decimal.Parse(Grid_V_TB_RECEIVE_LIST.DataKeys[rowIndex][5].ToString()); |
|||
|
|||
decimal _price = decimal.Parse(Grid_V_TB_RECEIVE_LIST.DataKeys[rowIndex][6].ToString()); |
|||
|
|||
_total += (_qty * _price); |
|||
IDS += ID + ","; |
|||
_projectId = Grid_V_TB_RECEIVE_LIST.DataKeys[rowIndex][1].ToString(); |
|||
_projectList.Add(_projectId); |
|||
var _recbill = Grid_V_TB_RECEIVE_LIST.DataKeys[rowIndex][2].ToString(); |
|||
if (!string.IsNullOrEmpty(_recbill) && _recbill.IndexOf("R.") > 0) |
|||
{ |
|||
_rejList.Add(_projectId); |
|||
} |
|||
IdList.Add(ID); |
|||
|
|||
|
|||
} |
|||
if (!ScpCache.Config.负数发票) |
|||
{ |
|||
if (_total < 0) |
|||
{ |
|||
Alert.Show("不允许开负数发票!退货、索赔零件数量有问题,请联系工厂库房和质量解决!"); |
|||
return; |
|||
} |
|||
} |
|||
|
|||
|
|||
|
|||
if (IdList.Count > 1000) |
|||
{ |
|||
Alert.Show("选择发票条数" + IdList.Count + "超过1000条,发票允许条数!"); |
|||
return; |
|||
} |
|||
|
|||
if (_list.Distinct().Count() > 1) |
|||
{ |
|||
Alert.Show("请选择的记录不是同一个供应商,请选择供应商!"); |
|||
return; |
|||
} |
|||
|
|||
|
|||
|
|||
if (IDS != "") IDS = IDS.Substring(0, IDS.Length - 1); |
|||
|
|||
if (CurrentUser.FactoryList.FirstOrDefault() != "BJCIAI" && CurrentUser.FactoryList.FirstOrDefault() != "JZ1") |
|||
{ |
|||
var _ls = GetIsAllChecked(vender, IDS); |
|||
if (_ls.Count > 0) |
|||
{ |
|||
Alert.Show(string.Format("退货或索赔单{0}未开票!", string.Join(",", _ls.ToArray()))); |
|||
return; |
|||
} |
|||
} |
|||
|
|||
|
|||
InvoiceCreateQueryParm parm = new InvoiceCreateQueryParm(); |
|||
parm.ReceiveID = IDS; |
|||
parm.VendId = vender; |
|||
parm.Modify = IsCreate; |
|||
parm.IsAll = p_all; |
|||
parm.Tax = _tax; |
|||
parm.CJ = _cj; |
|||
parm.TZ = _tz; |
|||
|
|||
Session["InvoiceCreateQueryParm"] = parm; |
|||
string ret = Window1.GetShowReference("../../Views/SupplierData/SCP_INVOICE_CREATE.aspx", "生成发票"); |
|||
PageContext.RegisterStartupScript(ret); |
|||
} |
|||
catch (Exception ex) |
|||
{ |
|||
Alert.Show(ex.Message); |
|||
} |
|||
} |
|||
private List<string> GetIsAllChecked(string p_VendId, string p_VendIds) |
|||
{ |
|||
|
|||
List<string> unSelected = new List<string>(); |
|||
|
|||
var _ls = SCPDB.V_TB_RECEIVE_LIST.Where(p => p.VendId == p_VendId && p.State == 1 && (p.BillType_DESC == "索赔单" || p.BillType_DESC == "退货单")).Select(p => new { p.UID, p.RecvBillNum }).ToList(); |
|||
|
|||
//SCP_RECIVECE_CONTROLLER.Get_V_TB_RECEIVE_LIST_List(_ent, (ret) =>
|
|||
//{
|
|||
// if (ret.State == ReturnStatus.Succeed)
|
|||
// {
|
|||
var _lsCompare = p_VendIds.Split(new char[] { ',' }); |
|||
// var _ls = ret.Result.Select(p => new { p.UID, p.RecvBillNum }).ToList();
|
|||
foreach (var itm in _ls) |
|||
{ |
|||
if (!_lsCompare.Contains(itm.UID.ToString())) |
|||
{ |
|||
unSelected.Add(itm.RecvBillNum); |
|||
} |
|||
} |
|||
// }
|
|||
//});
|
|||
return unSelected.Distinct().ToList(); |
|||
} |
|||
|
|||
|
|||
protected void Grid_V_TB_RECEIVE_LIST_PageIndexChange(object sender, GridPageEventArgs e) |
|||
{ |
|||
BindData(); |
|||
} |
|||
|
|||
//导出
|
|||
protected void btnOutput_OnClick(object sender, EventArgs e) |
|||
{ |
|||
V_TB_RECEIVE_LIST _ls = new V_TB_RECEIVE_LIST(); |
|||
_ls.PoBillNum = TXT_BillNo.Text; |
|||
_ls.VendName = TXT_VendName.Text; |
|||
_ls.UserInVendIds = CurrentUser.VenderList; |
|||
_ls.AsnBillNum = TXT_ASNBill.Text; |
|||
_ls.PartCode = TXT_PartCode.Text; |
|||
_ls.VendId = TXT_VendId.Text; |
|||
_ls.ProjectId = TXT_ProjectId.Text; |
|||
_ls.RecvBillNum = TXT_RECEIVE.Text; |
|||
_ls.ErpRecvBillNum = TXT_ERPBillNo.Text; |
|||
if (DP_StartDate.SelectedDate != null) |
|||
{ |
|||
_ls.BeginTime = DP_StartDate.SelectedDate; |
|||
} |
|||
if (Date_EndDate.SelectedDate != null) |
|||
{ |
|||
_ls.ShipTime = Date_EndDate.SelectedDate; |
|||
} |
|||
if (!string.IsNullOrEmpty(DDL_State.SelectedValue)) |
|||
{ |
|||
_ls.BillType_DESC = DDL_State.SelectedValue; |
|||
} |
|||
if (CurrentUser.FactoryList != null && CurrentUser.FactoryList.Count > 0) |
|||
{ |
|||
_ls.Site = CurrentUser.FactoryList[0]; |
|||
} |
|||
_ls.State = 1; |
|||
if (CurrentUser.VenderList != null && CurrentUser.VenderList.Count > 0) |
|||
{ |
|||
var _venderId = CurrentUser.VenderList.FirstOrDefault(); |
|||
if (!string.IsNullOrEmpty(_ls.Site) && !string.IsNullOrEmpty(_venderId)) |
|||
{ |
|||
var _vender = SCP_TB_VENDER_CONTROLLER.GetVender(_venderId, _ls.Site); |
|||
if (_vender.Tax > 0 && _vender.Tax != null) |
|||
{ |
|||
lbTaxRate.SelectedValue = _vender.Tax.ToString(); |
|||
} |
|||
else |
|||
{ |
|||
lbTaxRate.Text = "0"; |
|||
} |
|||
} |
|||
} |
|||
|
|||
SCP_RECIVECE_CONTROLLER.Get_V_TB_RECEIVE_LIST_List(_ls, (ret) => |
|||
{ |
|||
if (ret.State == ReturnStatus.Succeed) |
|||
{ |
|||
var _lst = ret.Result.ToList(); |
|||
|
|||
Dictionary<string, string> cellheader = new Dictionary<string, string> |
|||
{ |
|||
{ "ProjectId", "项目编号" }, |
|||
{ "BillType_DESC", "单据类型" }, |
|||
{ "ErpRecvBillNum", "ERP单据编号" }, |
|||
{ "RecvBillNum", "WMS单据编号" }, |
|||
{ "AsnBillNum", "发货单号" }, |
|||
{ "VendName", "供应商" }, |
|||
{ "VendId", "供应商编码" }, |
|||
{ "PoBillNum", "订单号" }, |
|||
{ "PoLine", "订单行" }, |
|||
{ "PartCode", "零件号" }, |
|||
{ "PartDesc1", "零件名称" }, |
|||
{ "LocUnit", "单位" }, |
|||
{ "Currency", "币种" }, |
|||
{ "CanQty", "可开票数量" }, |
|||
{ "Price", "单价" }, |
|||
{ "ShipTime", "收货时间" } |
|||
}; |
|||
string url = EntityListToExcel2003(cellheader, _lst, "审核明细"); |
|||
} |
|||
}); |
|||
} |
|||
//快速查找
|
|||
protected void btnSearch_Click(object sender, EventArgs e) |
|||
{ |
|||
|
|||
} |
|||
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) |
|||
{ |
|||
BindData(); |
|||
} |
|||
|
|||
protected void Grid_V_TB_RECEIVE_LIST_RowDataBound(object sender, GridRowEventArgs e) |
|||
{ |
|||
System.Web.UI.WebControls.Label _label = (System.Web.UI.WebControls.Label)Grid_V_TB_RECEIVE_LIST.Rows[e.RowIndex].FindControl("Qty1"); |
|||
if (!string.IsNullOrEmpty(_label.Text)) |
|||
{ |
|||
if (decimal.Parse(_label.Text) < 0) |
|||
{ |
|||
_label.ForeColor = Color.Red; |
|||
} |
|||
} |
|||
} |
|||
|
|||
protected void btnCanIn_Click(object sender, EventArgs e) |
|||
{ |
|||
|
|||
} |
|||
|
|||
|
|||
|
|||
protected void BTN_INV_Click(object sender, EventArgs e) |
|||
{ |
|||
BindData(); |
|||
} |
|||
|
|||
protected void Window1_Close(object sender, WindowCloseEventArgs e) |
|||
{ |
|||
Session["InvoiceCreateQueryParm"] = null; |
|||
BindData(); |
|||
} |
|||
protected void Grid1_Sort(object sender, GridSortEventArgs e) |
|||
{ |
|||
Grid_V_TB_RECEIVE_LIST.SortDirection = e.SortDirection; |
|||
Grid_V_TB_RECEIVE_LIST.SortField = e.SortField; |
|||
BindData(); |
|||
} |
|||
protected void btnCreateAll_Click(object sender, EventArgs e) |
|||
{ |
|||
CreateInvoice("1"); |
|||
} |
|||
|
|||
} |
|||
} |
@ -0,0 +1,404 @@ |
|||
//------------------------------------------------------------------------------
|
|||
// <自动生成>
|
|||
// 此代码由工具生成。
|
|||
//
|
|||
// 对此文件的更改可能导致不正确的行为,如果
|
|||
// 重新生成代码,则所做更改将丢失。
|
|||
// </自动生成>
|
|||
//------------------------------------------------------------------------------
|
|||
|
|||
namespace SCP.Views.PlanData |
|||
{ |
|||
|
|||
|
|||
public partial class SCP_RECEIVE_LIST |
|||
{ |
|||
|
|||
/// <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>
|
|||
/// Button1 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.Button Button1; |
|||
|
|||
/// <summary>
|
|||
/// btnCreate 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.Button btnCreate; |
|||
|
|||
/// <summary>
|
|||
/// btnCreateAll 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.Button btnCreateAll; |
|||
|
|||
/// <summary>
|
|||
/// btn 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.Button btn; |
|||
|
|||
/// <summary>
|
|||
/// Button2 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.Button Button2; |
|||
|
|||
/// <summary>
|
|||
/// btnCanIn 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.Button btnCanIn; |
|||
|
|||
/// <summary>
|
|||
/// btnShow 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.Button btnShow; |
|||
|
|||
/// <summary>
|
|||
/// tb_RecvBillNum 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.TextBox tb_RecvBillNum; |
|||
|
|||
/// <summary>
|
|||
/// btn_Search 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.Button btn_Search; |
|||
|
|||
/// <summary>
|
|||
/// DDL_VEND_LIST 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.DropDownList DDL_VEND_LIST; |
|||
|
|||
/// <summary>
|
|||
/// BTN_INV 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.Button BTN_INV; |
|||
|
|||
/// <summary>
|
|||
/// gp1 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.GroupPanel gp1; |
|||
|
|||
/// <summary>
|
|||
/// FormRow_1 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.FormRow FormRow_1; |
|||
|
|||
/// <summary>
|
|||
/// TXT_BillNo 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.TextBox TXT_BillNo; |
|||
|
|||
/// <summary>
|
|||
/// TXT_ASNBill 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.TextBox TXT_ASNBill; |
|||
|
|||
/// <summary>
|
|||
/// TXT_VendName 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.TextBox TXT_VendName; |
|||
|
|||
/// <summary>
|
|||
/// TXT_VendId 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.TextBox TXT_VendId; |
|||
|
|||
/// <summary>
|
|||
/// FormRow_2 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.FormRow FormRow_2; |
|||
|
|||
/// <summary>
|
|||
/// TXT_ProjectId 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.TextBox TXT_ProjectId; |
|||
|
|||
/// <summary>
|
|||
/// TXT_PartCode 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.TextBox TXT_PartCode; |
|||
|
|||
/// <summary>
|
|||
/// DP_StartDate 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.DatePicker DP_StartDate; |
|||
|
|||
/// <summary>
|
|||
/// Date_EndDate 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.DatePicker Date_EndDate; |
|||
|
|||
/// <summary>
|
|||
/// FormRow_3 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.FormRow FormRow_3; |
|||
|
|||
/// <summary>
|
|||
/// TXT_ERPBillNo 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.TextBox TXT_ERPBillNo; |
|||
|
|||
/// <summary>
|
|||
/// TXT_RECEIVE 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.TextBox TXT_RECEIVE; |
|||
|
|||
/// <summary>
|
|||
/// DDL_State 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.DropDownList DDL_State; |
|||
|
|||
/// <summary>
|
|||
/// BtnClose 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.Button BtnClose; |
|||
|
|||
/// <summary>
|
|||
/// BtnSearch 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.Button BtnSearch; |
|||
|
|||
/// <summary>
|
|||
/// FormRow1 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.FormRow FormRow1; |
|||
|
|||
/// <summary>
|
|||
/// txtContractPrice1 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.NumberBox txtContractPrice1; |
|||
|
|||
/// <summary>
|
|||
/// txtBlancePrice1 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.NumberBox txtBlancePrice1; |
|||
|
|||
/// <summary>
|
|||
/// FormRow2 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.FormRow FormRow2; |
|||
|
|||
/// <summary>
|
|||
/// lbTaxRate 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.DropDownList lbTaxRate; |
|||
|
|||
/// <summary>
|
|||
/// btnTax 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.Button btnTax; |
|||
|
|||
/// <summary>
|
|||
/// Grid_V_TB_RECEIVE_LIST 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.Grid Grid_V_TB_RECEIVE_LIST; |
|||
|
|||
/// <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>
|
|||
/// Qty1 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::System.Web.UI.WebControls.Label Qty1; |
|||
|
|||
/// <summary>
|
|||
/// Window1 控件。
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 自动生成的字段。
|
|||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
|||
/// </remarks>
|
|||
protected global::FineUI.Window Window1; |
|||
} |
|||
} |
Loading…
Reference in new issue