refactor: 清理旧模块资源并整理人员服务目录
为收敛当前分支代码范围并统一人员服务目录,移除历史模块与静态资源,减少无效代码和目录分散带来的维护成本。
This commit is contained in:
@@ -1,95 +0,0 @@
|
||||
<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="MaterialStock.aspx.cs" Inherits="FineUIPro.Web.HJGL.DataImport.MaterialStock" %>
|
||||
|
||||
<!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" runat="server" Margin="5px" BodyPadding="5px" ShowBorder="false"
|
||||
ShowHeader="false" Layout="VBox" BoxConfigAlign="Stretch">
|
||||
<Items>
|
||||
<f:Grid ID="Grid1" ShowBorder="true" ShowHeader="false" Title="材料编码库"
|
||||
EnableCollapse="true" runat="server" BoxFlex="1" EnableColumnLines="true" DataKeyNames="MaterialCode"
|
||||
AllowCellEditing="true" ClicksToEdit="2" DataIDField="MaterialCode" AllowSorting="true"
|
||||
SortField="MaterialCode" OnSort="Grid1_Sort" AllowPaging="true"
|
||||
IsDatabasePaging="true" PageSize="15" OnPageIndexChange="Grid1_PageIndexChange"
|
||||
EnableRowDoubleClickEvent="true" EnableTextSelection="True">
|
||||
<Toolbars>
|
||||
<f:Toolbar ID="Toolbar2" Position="Top" runat="server" ToolbarAlign="Left">
|
||||
<Items>
|
||||
<f:DropDownList ID="drpPipeArea" Label="管线划分" AutoPostBack="true"
|
||||
runat="server" ShowRedStar="true" Required="true" LabelWidth="100px"
|
||||
Width="250px" LabelAlign="Right">
|
||||
</f:DropDownList>
|
||||
<f:Button ID="btnQuery" Text="刷新" Icon="TableRefresh"
|
||||
EnablePostBack="true" OnClick="btnQuery_Click" runat="server">
|
||||
</f:Button>
|
||||
</Items>
|
||||
</f:Toolbar>
|
||||
</Toolbars>
|
||||
<Columns>
|
||||
<f:RenderField Width="200px" ColumnID="MaterialCode" DataField="MaterialCode"
|
||||
FieldType="String" HeaderText="材料主编码" HeaderTextAlign="Center"
|
||||
TextAlign="Left" SortField="MaterialCode">
|
||||
</f:RenderField>
|
||||
<f:RenderField Width="150px" ColumnID="Code" DataField="Code"
|
||||
FieldType="String" HeaderText="材料编码" HeaderTextAlign="Center"
|
||||
TextAlign="Left" SortField="Code">
|
||||
</f:RenderField>
|
||||
<f:RenderField Width="120px" ColumnID="HeatNo" DataField="HeatNo"
|
||||
FieldType="String" HeaderText="炉号" HeaderTextAlign="Center"
|
||||
TextAlign="Left" SortField="HeatNo">
|
||||
</f:RenderField>
|
||||
<f:RenderField Width="120px" ColumnID="BatchNo" DataField="BatchNo"
|
||||
FieldType="String" HeaderText="批号" HeaderTextAlign="Center"
|
||||
TextAlign="Left" SortField="BatchNo">
|
||||
</f:RenderField>
|
||||
<f:RenderField Width="200px" ColumnID="MaterialNum" DataField="MaterialNum"
|
||||
FieldType="String" HeaderText="数量" HeaderTextAlign="Center"
|
||||
TextAlign="Left" SortField="MaterialNum">
|
||||
</f:RenderField>
|
||||
<f:RenderField Width="200px" ColumnID="MaterialName" DataField="MaterialName"
|
||||
FieldType="String" HeaderText="元件类型" HeaderTextAlign="Center"
|
||||
TextAlign="Left" SortField="MaterialName">
|
||||
</f:RenderField>
|
||||
<f:RenderField Width="120px" ColumnID="" DataField="MaterialSpec"
|
||||
FieldType="String" HeaderText="规格" HeaderTextAlign="Center"
|
||||
TextAlign="Left" SortField="MaterialSpec">
|
||||
</f:RenderField>
|
||||
<f:RenderField Width="180px" ColumnID="MaterialMade" DataField="MaterialMade" FieldType="String" HeaderText="材质"
|
||||
HeaderTextAlign="Center" TextAlign="Left" SortField="MaterialMade" >
|
||||
</f:RenderField>
|
||||
<f:RenderField Width="90px" ColumnID="MaterialUnit" DataField="MaterialUnit" FieldType="String" HeaderText="单位"
|
||||
HeaderTextAlign="Center" TextAlign="Left" SortField="MaterialUnit" >
|
||||
</f:RenderField>
|
||||
<f:RenderField Width="260px" ColumnID="MaterialDef" DataField="MaterialDef" FieldType="String"
|
||||
HeaderText="材料描述" HeaderTextAlign="Center" TextAlign="Left"
|
||||
ExpandUnusedSpace="true">
|
||||
</f:RenderField>
|
||||
|
||||
</Columns>
|
||||
<PageItems>
|
||||
<f:ToolbarSeparator ID="ToolbarSeparator1" runat="server">
|
||||
</f:ToolbarSeparator>
|
||||
<f:ToolbarText ID="ToolbarText1" runat="server" Text="每页记录数:">
|
||||
</f:ToolbarText>
|
||||
<f:DropDownList runat="server" ID="ddlPageSize" Width="80px" AutoPostBack="true"
|
||||
OnSelectedIndexChanged="ddlPageSize_SelectedIndexChanged">
|
||||
<f:ListItem Text="10" Value="10" />
|
||||
<f:ListItem Text="15" Value="15" />
|
||||
<f:ListItem Text="20" Value="20" />
|
||||
<f:ListItem Text="25" Value="25" />
|
||||
</f:DropDownList>
|
||||
</PageItems>
|
||||
</f:Grid>
|
||||
</Items>
|
||||
</f:Panel>
|
||||
</form>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
@@ -1,100 +0,0 @@
|
||||
using BLL;
|
||||
using System;
|
||||
using System.Data;
|
||||
|
||||
namespace FineUIPro.Web.HJGL.DataImport
|
||||
{
|
||||
public partial class MaterialStock : PageBase
|
||||
{
|
||||
protected void Page_Load(object sender, EventArgs e)
|
||||
{
|
||||
if (!IsPostBack)
|
||||
{
|
||||
this.drpPipeArea.DataTextField = "Text";
|
||||
this.drpPipeArea.DataValueField = "Value";
|
||||
this.drpPipeArea.DataSource = BLL.PipelineService.GetPipeArea();
|
||||
this.drpPipeArea.DataBind();
|
||||
this.ddlPageSize.SelectedValue = Grid1.PageSize.ToString();
|
||||
// 绑定表格
|
||||
this.BindGrid();
|
||||
}
|
||||
}
|
||||
#region 绑定数据
|
||||
/// <summary>
|
||||
/// 绑定数据
|
||||
/// </summary>
|
||||
private void BindGrid()
|
||||
{
|
||||
DataTable tb = new DataTable();
|
||||
switch (drpPipeArea.SelectedValue)
|
||||
{
|
||||
case PipelineService.PipeArea_SHOP:
|
||||
tb = HJGL_MaterialService.GetSHOPStockDt(this.CurrUser.LoginProjectId);
|
||||
break;
|
||||
case PipelineService.PipeArea_FIELD:
|
||||
tb = HJGL_MaterialService.GetFIELDStockDt(this.CurrUser.LoginProjectId);
|
||||
break;
|
||||
}
|
||||
Grid1.RecordCount = tb.Rows.Count;
|
||||
//tb = GetFilteredTable(Grid1.FilteredData, tb);
|
||||
var table = this.GetPagedDataTable(Grid1, tb);
|
||||
Grid1.DataSource = table;
|
||||
Grid1.DataBind();
|
||||
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 改变索引事件
|
||||
/// </summary>
|
||||
/// <param name="sender"></param>
|
||||
/// <param name="e"></param>
|
||||
protected void Grid1_PageIndexChange(object sender, GridPageEventArgs e)
|
||||
{
|
||||
BindGrid();
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 分页下拉选择事件
|
||||
/// </summary>
|
||||
/// <param name="sender"></param>
|
||||
/// <param name="e"></param>
|
||||
protected void ddlPageSize_SelectedIndexChanged(object sender, EventArgs e)
|
||||
{
|
||||
Grid1.PageSize = Convert.ToInt32(ddlPageSize.SelectedValue);
|
||||
BindGrid();
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 排序
|
||||
/// </summary>
|
||||
/// <param name="sender"></param>
|
||||
/// <param name="e"></param>
|
||||
protected void Grid1_Sort(object sender, FineUIPro.GridSortEventArgs e)
|
||||
{
|
||||
BindGrid();
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 关闭弹出窗口
|
||||
/// </summary>
|
||||
/// <param name="sender"></param>
|
||||
/// <param name="e"></param>
|
||||
protected void Window1_Close(object sender, EventArgs e)
|
||||
{
|
||||
BindGrid();
|
||||
}
|
||||
#endregion
|
||||
|
||||
#region 查询
|
||||
/// <summary>
|
||||
/// 查询
|
||||
/// </summary>
|
||||
/// <param name="sender"></param>
|
||||
/// <param name="e"></param>
|
||||
protected void btnQuery_Click(object sender, EventArgs e)
|
||||
{
|
||||
this.BindGrid();
|
||||
}
|
||||
#endregion
|
||||
}
|
||||
}
|
||||
@@ -1,107 +0,0 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <自动生成>
|
||||
// 此代码由工具生成。
|
||||
//
|
||||
// 对此文件的更改可能导致不正确的行为,如果
|
||||
// 重新生成代码,则所做更改将丢失。
|
||||
// </自动生成>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace FineUIPro.Web.HJGL.DataImport
|
||||
{
|
||||
|
||||
|
||||
public partial class MaterialStock
|
||||
{
|
||||
|
||||
/// <summary>
|
||||
/// form1 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.HtmlControls.HtmlForm form1;
|
||||
|
||||
/// <summary>
|
||||
/// PageManager1 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.PageManager PageManager1;
|
||||
|
||||
/// <summary>
|
||||
/// Panel1 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Panel Panel1;
|
||||
|
||||
/// <summary>
|
||||
/// Grid1 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Grid Grid1;
|
||||
|
||||
/// <summary>
|
||||
/// Toolbar2 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Toolbar Toolbar2;
|
||||
|
||||
/// <summary>
|
||||
/// drpPipeArea 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.DropDownList drpPipeArea;
|
||||
|
||||
/// <summary>
|
||||
/// btnQuery 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Button btnQuery;
|
||||
|
||||
/// <summary>
|
||||
/// ToolbarSeparator1 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.ToolbarSeparator ToolbarSeparator1;
|
||||
|
||||
/// <summary>
|
||||
/// ToolbarText1 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.ToolbarText ToolbarText1;
|
||||
|
||||
/// <summary>
|
||||
/// ddlPageSize 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.DropDownList ddlPageSize;
|
||||
}
|
||||
}
|
||||
@@ -107,9 +107,6 @@ namespace FineUIPro.Web.HJGL.WeldingManage
|
||||
{
|
||||
if (!IsPostBack)
|
||||
{
|
||||
HJGL_MaterialService.materialStockItems_FIELD = new List<Model.MaterialStockItem>();
|
||||
HJGL_MaterialService.materialStockItems_SHOP = new List<Model.MaterialStockItem>();
|
||||
|
||||
Tree_hJGL_Pipelines = new List<HJGL_Pipeline>();
|
||||
this.txtTaskDate.Text = string.Format("{0:yyyy-MM-dd}", DateTime.Now.AddDays(1));
|
||||
BLL.Base_WeldingLocationServie.InitWeldingLocationDropDownList(drpWeldingLocation, true);
|
||||
@@ -263,7 +260,6 @@ namespace FineUIPro.Web.HJGL.WeldingManage
|
||||
TreeNode newNode = new TreeNode();
|
||||
int totalJointNum = joints.Count(x => x.PipelineId == item.PipelineId);
|
||||
int weldJointNum = joints.Count(x => x.PipelineId == item.PipelineId && x.WeldingDailyId != null);
|
||||
//bool istrue = BLL.HJGL_MaterialService.isInStockByPipeline(item.PipelineId, this.CurrUser.LoginProjectId);
|
||||
//if (istrue)
|
||||
//{
|
||||
// newNode.CssClass = "tn-color-green";
|
||||
|
||||
@@ -88,8 +88,6 @@
|
||||
<f:Button ID="btnTreeFind" ToolTip="查询" Icon="SystemSearch"
|
||||
EnablePostBack="true" OnClick="btnTreeFind_Click" runat="server">
|
||||
</f:Button>
|
||||
<f:Button ID="btnStatisticsMat" ToolTip="匹配材料" Icon="TabGo" runat="server" OnClick="btnStatisticsMat_Click" Hidden="true">
|
||||
</f:Button>
|
||||
<f:Button ID="btnExportPartialComponents" Text="导出全部组件" ToolTip="按当前区域导出所选单位工程的全部组件"
|
||||
Icon="TableGo" runat="server" OnClick="btnExportPartialComponents_Click" EnableAjax="false"
|
||||
DisableControlBeforePostBack="true" EnablePostBack="true">
|
||||
@@ -250,12 +248,6 @@
|
||||
</f:Panel>
|
||||
</Items>
|
||||
</f:Panel>
|
||||
<f:Window ID="Window2" Title="匹配100%材料" Hidden="true" EnableIFrame="true"
|
||||
EnableMaximize="true" Target="Top" runat="server"
|
||||
Width="650px" Height="300px" Icon="TagBlue"
|
||||
EnableCollapse="true" EnableResize="true"
|
||||
IsModal="false" AutoScroll="true" BodyPadding="10px">
|
||||
</f:Window>
|
||||
</form>
|
||||
<script type="text/javascript">
|
||||
function reloadGrid() {
|
||||
|
||||
@@ -1,5 +1,4 @@
|
||||
using BLL;
|
||||
using FineUIPro.Web.DataShow;
|
||||
using MiniExcelLibs;
|
||||
using Model;
|
||||
using Newtonsoft.Json;
|
||||
@@ -116,7 +115,6 @@ namespace FineUIPro.Web.HJGL.WeldingManage
|
||||
tw_PipeMatMatchOutputs = new List<Model.Tw_PipeMatMatchOutput>();
|
||||
PipeArea = Request.Params["PipeArea"];
|
||||
BindWarehouseOptions();
|
||||
ResetMaterialStockCache();
|
||||
dicSeclectPipeLine = new Dictionary<string, string>();
|
||||
priorityWeldJoints = new Dictionary<string, HashSet<string>>();
|
||||
BindFlowingSectionOptions();
|
||||
@@ -138,12 +136,6 @@ namespace FineUIPro.Web.HJGL.WeldingManage
|
||||
/// <summary>
|
||||
/// 清空材料库存缓存,避免首次加载沿用其他入口的区域缓存。
|
||||
/// </summary>
|
||||
private void ResetMaterialStockCache()
|
||||
{
|
||||
HJGL_MaterialService.materialStockItems_FIELD = new List<Model.MaterialStockItem>();
|
||||
HJGL_MaterialService.materialStockItems_SHOP = new List<Model.MaterialStockItem>();
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 绑定当前项目的流水段筛选项。
|
||||
/// </summary>
|
||||
@@ -706,24 +698,6 @@ namespace FineUIPro.Web.HJGL.WeldingManage
|
||||
this.InitTreeMenu();//加载树
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 打开单位工程材料匹配统计窗口。
|
||||
/// </summary>
|
||||
/// <param name="sender">事件源。</param>
|
||||
/// <param name="e">事件参数。</param>
|
||||
protected void btnStatisticsMat_Click(object sender, EventArgs e)
|
||||
{
|
||||
Model.WBS_UnitWork unitWork = BLL.UnitWorkService.GetUnitWorkByUnitWorkId(this.tvControlItem.SelectedNodeID);
|
||||
if (unitWork != null)
|
||||
{
|
||||
PageContext.RegisterStartupScript(Window2.GetShowReference(String.Format("WeldMatMatchGet.aspx?UnitWorkId={0}&&PipeArea={1}", this.tvControlItem.SelectedNodeID, PipeArea, "匹配 - ")));
|
||||
}
|
||||
else
|
||||
{
|
||||
ShowNotify("请先选择单位工程!", MessageBoxIcon.Warning);
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 按当前材料区域导出所选单位工程下全部组件。
|
||||
/// </summary>
|
||||
|
||||
@@ -131,15 +131,6 @@ namespace FineUIPro.Web.HJGL.WeldingManage
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Button btnTreeFind;
|
||||
|
||||
/// <summary>
|
||||
/// btnStatisticsMat 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Button btnStatisticsMat;
|
||||
|
||||
/// <summary>
|
||||
/// btnExportPartialComponents 控件。
|
||||
/// </summary>
|
||||
@@ -329,13 +320,5 @@ namespace FineUIPro.Web.HJGL.WeldingManage
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Grid Grid1;
|
||||
|
||||
/// <summary>
|
||||
/// Window2 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Window Window2;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,73 +0,0 @@
|
||||
<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WeldMatMatchGet.aspx.cs" Inherits="FineUIPro.Web.HJGL.WeldingManage.WeldMatMatchGet" %>
|
||||
|
||||
<!DOCTYPE html>
|
||||
|
||||
<html xmlns="http://www.w3.org/1999/xhtml">
|
||||
<head runat="server">
|
||||
<title></title>
|
||||
</head>
|
||||
<body class="f-bgcolor">
|
||||
<form id="form1" runat="server">
|
||||
<f:PageManager ID="PageManager1" AutoSizePanelID="SimpleForm1" runat="server" />
|
||||
<f:Form ID="SimpleForm1" ShowBorder="false" ShowHeader="false" AutoScroll="true"
|
||||
BodyPadding="10px" runat="server" RedStarPosition="BeforeText" LabelAlign="Right">
|
||||
<Toolbars>
|
||||
<f:Toolbar ID="Toolbar3" runat="server">
|
||||
<Items>
|
||||
<f:ToolbarFill runat="server"></f:ToolbarFill>
|
||||
<f:Button ID="btnOut" OnClick="btnOut_Click" runat="server" Text="导出"
|
||||
Icon="TableGo" EnableAjax="false" DisableControlBeforePostBack="true" EnablePostBack="true">
|
||||
</f:Button>
|
||||
|
||||
</Items>
|
||||
</f:Toolbar>
|
||||
</Toolbars>
|
||||
<Rows>
|
||||
<f:FormRow>
|
||||
<Items>
|
||||
<f:Grid ID="Grid1" ShowBorder="true" ShowHeader="false" Title="管线信息" Height="350px"
|
||||
EnableCollapse="true" runat="server" BoxFlex="1" DataKeyNames="PipelineCode" AllowCellEditing="true"
|
||||
AllowColumnLocking="true" EnableColumnLines="true" ClicksToEdit="2" DataIDField="PipelineCode" EnableBigData="true"
|
||||
AllowSorting="true" SortField="PipelineCode" SortDirection="ASC"
|
||||
AllowPaging="true" IsDatabasePaging="false" PageSize="300" EnableBigDataRowTip="false" ForceFit="true"
|
||||
EnableTextSelection="True">
|
||||
<Columns>
|
||||
<f:RenderField Width="130px" ColumnID="PipelineCode" DataField="PipelineCode" SortField="PipelineCode"
|
||||
FieldType="String" HeaderText="管线号" HeaderTextAlign="Center"
|
||||
TextAlign="Left">
|
||||
</f:RenderField>
|
||||
<f:RenderField Width="130px" ColumnID="FlowingSection" DataField="FlowingSection" SortField="FlowingSection"
|
||||
FieldType="String" HeaderText="流水段" HeaderTextAlign="Center"
|
||||
TextAlign="Left">
|
||||
</f:RenderField>
|
||||
<f:RenderField Width="130px" ColumnID="MatchingRate" DataField="MatchingRate" SortField="MatchingRate"
|
||||
FieldType="String" HeaderText="匹配率" HeaderTextAlign="Center"
|
||||
TextAlign="Left">
|
||||
</f:RenderField>
|
||||
<f:RenderField Width="130px" ColumnID="PlanStarDate" DataField="PlanStarDate" SortField="PlanStarDate"
|
||||
FieldType="String" HeaderText="安装日期" HeaderTextAlign="Center"
|
||||
TextAlign="Left">
|
||||
</f:RenderField>
|
||||
</Columns>
|
||||
<PageItems>
|
||||
<f:ToolbarSeparator ID="ToolbarSeparator1" runat="server">
|
||||
</f:ToolbarSeparator>
|
||||
<f:ToolbarText ID="ToolbarText1" runat="server" Text="每页记录数:">
|
||||
</f:ToolbarText>
|
||||
<f:DropDownList runat="server" ID="ddlPageSize" Width="80px" AutoPostBack="true"
|
||||
OnSelectedIndexChanged="ddlPageSize_SelectedIndexChanged">
|
||||
<f:ListItem Text="10" Value="10" />
|
||||
<f:ListItem Text="15" Value="15" />
|
||||
<f:ListItem Text="20" Value="20" />
|
||||
<f:ListItem Text="25" Value="25" />
|
||||
<f:ListItem Text="所有行" Value="10000" />
|
||||
</f:DropDownList>
|
||||
</PageItems>
|
||||
</f:Grid>
|
||||
</Items>
|
||||
</f:FormRow>
|
||||
</Rows>
|
||||
</f:Form>
|
||||
</form>
|
||||
</body>
|
||||
</html>
|
||||
@@ -1,84 +0,0 @@
|
||||
using BLL;
|
||||
using MiniExcelLibs;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.IO;
|
||||
using System.Linq;
|
||||
using System.Web.UI.WebControls;
|
||||
|
||||
namespace FineUIPro.Web.HJGL.WeldingManage
|
||||
{
|
||||
|
||||
public partial class WeldMatMatchGet : PageBase
|
||||
{
|
||||
public static List<string> pipelinecode = new List<string>();
|
||||
|
||||
protected void Page_Load(object sender, EventArgs e)
|
||||
{
|
||||
if (!IsPostBack)
|
||||
{
|
||||
var UnitWorkId = Request.Params["UnitWorkId"];
|
||||
var PipeArea = Request.Params["PipeArea"];
|
||||
// txtProgressBar.Text = "20";
|
||||
GetStockNum(UnitWorkId, PipeArea);
|
||||
}
|
||||
}
|
||||
public void GetStockNum(string UnitWorkId, string PipeArea)
|
||||
{
|
||||
var pipeline = (from x in Funs.DB.HJGL_Pipeline
|
||||
where x.ProjectId == this.CurrUser.LoginProjectId && x.UnitWorkId == UnitWorkId && x.PipeArea == PipeArea
|
||||
orderby x.PipelineCode
|
||||
select x).ToList();
|
||||
List<string> pipelineList = new List<string>();
|
||||
foreach (var item in pipeline)
|
||||
{
|
||||
bool istrue = BLL.HJGL_MaterialService.isInStockByPipeline(item.PipelineId, this.CurrUser.LoginProjectId);
|
||||
if (istrue)
|
||||
{
|
||||
pipelineList.Add(item.PipelineCode);
|
||||
}
|
||||
|
||||
}
|
||||
pipelinecode = pipelineList;
|
||||
BindGrid();
|
||||
}
|
||||
|
||||
protected void btnOut_Click(object sender, EventArgs e)
|
||||
{
|
||||
string path = Funs.RootPath + @"File\Excel\Temp\weldMatchGet.xlsx";
|
||||
path = path.Replace(".xlsx", string.Format("{0:yyyy-MM-dd-HH-mm}", DateTime.Now) + ".xlsx");
|
||||
var a = (from x in pipelinecode select new { PipelineCode = x }).ToList();
|
||||
var b = (from x in Funs.DB.HJGL_Pipeline
|
||||
where pipelinecode.Contains(x.PipelineCode)
|
||||
select new { 管线号 = x.PipelineCode, 流水段 = x.FlowingSection, 匹配率 = "100%", 计划安装日期 = x.PlanStartDate }).ToList();
|
||||
MiniExcel.SaveAs(path, b);
|
||||
|
||||
string fileName = "材料匹配100%管线.xlsx";
|
||||
FileInfo info = new FileInfo(path);
|
||||
long fileSize = info.Length;
|
||||
System.Web.HttpContext.Current.Response.Clear();
|
||||
System.Web.HttpContext.Current.Response.ContentType = "application/x-zip-compressed";
|
||||
System.Web.HttpContext.Current.Response.AddHeader("Content-Disposition", "attachment;filename=" + System.Web.HttpUtility.UrlEncode(fileName, System.Text.Encoding.UTF8));
|
||||
System.Web.HttpContext.Current.Response.AddHeader("Content-Length", fileSize.ToString());
|
||||
System.Web.HttpContext.Current.Response.TransmitFile(path, 0, fileSize);
|
||||
System.Web.HttpContext.Current.Response.Flush();
|
||||
System.Web.HttpContext.Current.Response.Close();
|
||||
File.Delete(path);
|
||||
}
|
||||
void BindGrid()
|
||||
{
|
||||
var a = (from x in pipelinecode select new { PipelineCode = x }).ToList();
|
||||
var b = (from x in Funs.DB.HJGL_Pipeline
|
||||
where pipelinecode.Contains(x.PipelineCode)
|
||||
select new { PipelineCode = x.PipelineCode, FlowingSection = x.FlowingSection, MatchingRate = "100%", PlanStarDate = x.PlanStartDate }).ToList();
|
||||
Grid1.PageSize = Convert.ToInt32(ddlPageSize.SelectedValue);
|
||||
this.Grid1.DataSource = b;
|
||||
this.Grid1.DataBind();
|
||||
Grid1.RecordCount = a.Count();
|
||||
}
|
||||
protected void ddlPageSize_SelectedIndexChanged(object sender, EventArgs e)
|
||||
{
|
||||
BindGrid();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,98 +0,0 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <自动生成>
|
||||
// 此代码由工具生成。
|
||||
//
|
||||
// 对此文件的更改可能导致不正确的行为,如果
|
||||
// 重新生成代码,则所做更改将丢失。
|
||||
// </自动生成>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace FineUIPro.Web.HJGL.WeldingManage
|
||||
{
|
||||
|
||||
|
||||
public partial class WeldMatMatchGet
|
||||
{
|
||||
|
||||
/// <summary>
|
||||
/// form1 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.HtmlControls.HtmlForm form1;
|
||||
|
||||
/// <summary>
|
||||
/// PageManager1 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.PageManager PageManager1;
|
||||
|
||||
/// <summary>
|
||||
/// SimpleForm1 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Form SimpleForm1;
|
||||
|
||||
/// <summary>
|
||||
/// Toolbar3 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Toolbar Toolbar3;
|
||||
|
||||
/// <summary>
|
||||
/// btnOut 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Button btnOut;
|
||||
|
||||
/// <summary>
|
||||
/// Grid1 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Grid Grid1;
|
||||
|
||||
/// <summary>
|
||||
/// ToolbarSeparator1 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.ToolbarSeparator ToolbarSeparator1;
|
||||
|
||||
/// <summary>
|
||||
/// ToolbarText1 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.ToolbarText ToolbarText1;
|
||||
|
||||
/// <summary>
|
||||
/// ddlPageSize 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.DropDownList ddlPageSize;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user