提交代码
This commit is contained in:
parent
bfb7065085
commit
2f364f21b2
|
@ -0,0 +1,50 @@
|
|||
delete Sys_Menu where MenuId='2590BA0B-3B56-4F8A-8EB8-2D047EF90753'
|
||||
INSERT INTO dbo.Sys_Menu(MenuId,MenuName,Icon,Url,SortIndex,SuperMenu,MenuType,IsOffice,IsEnd,IsUsed)VALUES('2590BA0B-3B56-4F8A-8EB8-2D047EF90753','运行日志管理',null,'TestRun/ProduceTestRun/RunningLogManagementList.aspx',1,'110E8BDB-8121-4C5B-A3C3-AF2B34B1B29B','Menu_TestRun',0,1,1)
|
||||
|
||||
--==运行日志管理
|
||||
if object_id(N'Running_LogManagement',N'U') is not null
|
||||
drop table dbo.Running_LogManagement
|
||||
CREATE TABLE dbo.Running_LogManagement(
|
||||
RunningId varchar(50) NOT NULL,--主键
|
||||
ProjectId varchar(50) NULL,--项目主键
|
||||
InstallationId varchar(50) NULL,--装置主键
|
||||
ProcessesId varchar(50) NULL,--工序主键
|
||||
SystemId varchar(50) NULL,--系统主键
|
||||
JobNo varchar(50) NULL,--职工号
|
||||
ShiftType varchar(50) NULL,--轮班类型1:白班2:夜班
|
||||
ShiftUser varchar(50) NULL,--轮班职工
|
||||
SuccessionUser varchar(50) NULL,--继任职工
|
||||
StartData datetime NULL,--开始日期
|
||||
EndData datetime NULL,--结束日期
|
||||
IsDesalinated int NULL,--是否存在脱盐水
|
||||
DesalinatedSituation varchar(1000),--脱盐水运行情况
|
||||
DesalinatedRemarks varchar(1000),--脱盐水备注
|
||||
IsLoop int NULL,--是否存在循环水
|
||||
LoopSituation varchar(1000),--循环水运行情况
|
||||
LoopRemarks varchar(1000),--循环水备注
|
||||
IsSteam int NULL,--是否存在蒸汽
|
||||
SteamSituation varchar(1000),--蒸汽运行情况
|
||||
SteamRemarks varchar(1000),--蒸汽备注
|
||||
IsAirCompression int NULL,--是否存在空压站
|
||||
AirCompressionSituation varchar(1000),--空压站运行情况
|
||||
AirCompressionRemarks varchar(1000),--空压站备注
|
||||
IsCompoundAmmonia int NULL,--是否存在合成氨
|
||||
CompoundAmmoniaSituation varchar(1000),--合成氨运行情况
|
||||
CompoundAmmoniaRemarks varchar(1000),--合成氨备注
|
||||
IsUrea int NULL,--是否存在尿素
|
||||
UreaSituation varchar(1000),--尿素运行情况
|
||||
UreaRemarks varchar(1000),--尿素备注
|
||||
HandoverCare varchar(1000),--交班注意
|
||||
OperationReason varchar(1000),--操作问题原因
|
||||
OperationHandle varchar(1000),--操作问题处理
|
||||
MaintenanceReason varchar(1000),--维护问题原因
|
||||
MaintenanceHandle varchar(1000),--维护问题处理
|
||||
AddUser varchar(50) NULL,--添加人
|
||||
AddTime datetime NULL,--添加日期
|
||||
Sort int NULL,--排序
|
||||
CONSTRAINT PK_Running_LogManagement PRIMARY KEY CLUSTERED
|
||||
(
|
||||
RunningId ASC
|
||||
)WITH (PAD_INDEX = OFF, STATISTICS_NORECOMPUTE = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS = ON, ALLOW_PAGE_LOCKS = ON) ON [PRIMARY]
|
||||
) ON [PRIMARY]
|
||||
GO
|
|
@ -1855,6 +1855,8 @@
|
|||
<Content Include="TestRun\ProduceProperty\PropertyRunRecordEdit.aspx" />
|
||||
<Content Include="TestRun\ProduceProperty\PropertyRunReport.aspx" />
|
||||
<Content Include="TestRun\ProduceProperty\PropertyRunReportEdit.aspx" />
|
||||
<Content Include="TestRun\ProduceTestRun\RunningLogManagementEdit.aspx" />
|
||||
<Content Include="TestRun\ProduceTestRun\RunningLogManagementList.aspx" />
|
||||
<Content Include="TestRun\ProduceTestRun\TestRunOthersCheck.aspx" />
|
||||
<Content Include="TestRun\ProduceTestRun\TestRunOthersCheckEdit.aspx" />
|
||||
<Content Include="TestRun\ProduceTestRun\TestRunPumpCheck.aspx" />
|
||||
|
@ -16603,6 +16605,20 @@
|
|||
<Compile Include="TestRun\ProduceProperty\PropertyRunReportEdit.aspx.designer.cs">
|
||||
<DependentUpon>PropertyRunReportEdit.aspx</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="TestRun\ProduceTestRun\RunningLogManagementEdit.aspx.cs">
|
||||
<DependentUpon>RunningLogManagementEdit.aspx</DependentUpon>
|
||||
<SubType>ASPXCodeBehind</SubType>
|
||||
</Compile>
|
||||
<Compile Include="TestRun\ProduceTestRun\RunningLogManagementEdit.aspx.designer.cs">
|
||||
<DependentUpon>RunningLogManagementEdit.aspx</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="TestRun\ProduceTestRun\RunningLogManagementList.aspx.cs">
|
||||
<DependentUpon>RunningLogManagementList.aspx</DependentUpon>
|
||||
<SubType>ASPXCodeBehind</SubType>
|
||||
</Compile>
|
||||
<Compile Include="TestRun\ProduceTestRun\RunningLogManagementList.aspx.designer.cs">
|
||||
<DependentUpon>RunningLogManagementList.aspx</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="TestRun\ProduceTestRun\TestRunOthersCheck.aspx.cs">
|
||||
<DependentUpon>TestRunOthersCheck.aspx</DependentUpon>
|
||||
<SubType>ASPXCodeBehind</SubType>
|
||||
|
|
|
@ -0,0 +1,188 @@
|
|||
<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="RunningLogManagementEdit.aspx.cs" Inherits="FineUIPro.Web.TestRun.ProduceTestRun.RunningLogManagementEdit" %>
|
||||
|
||||
<!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="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="Toolbar1" Position="Bottom" ToolbarAlign="Right" runat="server">
|
||||
<Items>
|
||||
<f:ToolbarFill ID="ToolbarFill1" runat="server">
|
||||
</f:ToolbarFill>
|
||||
<f:Button ID="btnSave" OnClick="btnSave_Click" Icon="SystemSave" runat="server" ToolTip="保存" ValidateForms="SimpleForm1">
|
||||
</f:Button>
|
||||
</Items>
|
||||
</f:Toolbar>
|
||||
</Toolbars>
|
||||
<Rows>
|
||||
<f:FormRow>
|
||||
<Items>
|
||||
<f:ContentPanel ID="ContentPanel2" ShowBorder="true" Title="试运行日志"
|
||||
BodyPadding="10px" EnableCollapse="true" ShowHeader="true" AutoScroll="true"
|
||||
runat="server">
|
||||
<f:Form ID="Form2" ShowBorder="false" ShowHeader="false" AutoScroll="true"
|
||||
BodyPadding="10px" runat="server" RedStarPosition="BeforeText" LabelAlign="Right">
|
||||
<Rows>
|
||||
<f:FormRow>
|
||||
<Items>
|
||||
<f:TextBox ID="txtJobNo" runat="server" Label="职工号" LabelAlign="Right" LabelWidth="150px" MaxLength="50" Required="true" ShowRedStar="true">
|
||||
</f:TextBox>
|
||||
<f:DropDownList ID="ddlShiftType" runat="server" Label="轮班类型" LabelAlign="Right" EnableEdit="true" ShowRedStar="true">
|
||||
<f:ListItem Text="白班" Value="1" />
|
||||
<f:ListItem Text="夜班" Value="2" />
|
||||
</f:DropDownList>
|
||||
</Items>
|
||||
</f:FormRow>
|
||||
<f:FormRow>
|
||||
<Items>
|
||||
<f:DropDownList ID="ddlShiftUser" Required="true" Label="轮班职工" LabelAlign="Right" AutoSelectFirstItem="false" LabelWidth="120px" runat="server" ShowRedStar="true">
|
||||
</f:DropDownList>
|
||||
<f:DropDownList ID="ddlSuccessionUser" Required="true" Label="继任职工" LabelAlign="Right" AutoSelectFirstItem="false" LabelWidth="120px" runat="server" ShowRedStar="true">
|
||||
</f:DropDownList>
|
||||
</Items>
|
||||
</f:FormRow>
|
||||
<f:FormRow>
|
||||
<Items>
|
||||
<f:DatePicker runat="server" Required="true" DateFormatString="yyyy-MM-dd HH:mm:ss" Label="开始日期" EmptyText="请选择开始日期"
|
||||
ID="txtStartData" ShowRedStar="true" ShowTime="true">
|
||||
</f:DatePicker>
|
||||
<f:DatePicker ID="txtEndData" Required="true" Readonly="false" CompareControl="txtStartData" DateFormatString="yyyy-MM-dd HH:mm:ss"
|
||||
CompareOperator="GreaterThan" CompareMessage="结束日期应该大于开始日期" Label="结束日期"
|
||||
runat="server" ShowRedStar="true" ShowTime="true">
|
||||
</f:DatePicker>
|
||||
</Items>
|
||||
</f:FormRow>
|
||||
<f:FormRow>
|
||||
<Items>
|
||||
<f:CheckBoxList ID="rdbOperation" AutoPostBack="true" OnSelectedIndexChanged="rdbOperation_SelectedIndexChanged"
|
||||
Label="选项" ColumnNumber="3" runat="server" ShowRedStar="true" Required="true" DisplayType="Switch" SwitchTextVisible="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:CheckBoxList>
|
||||
</Items>
|
||||
</f:FormRow>
|
||||
<f:FormRow runat="server" ID="tys">
|
||||
<Items>
|
||||
<f:TextArea ID="txtDesalinatedSituation" runat="server" Label="脱盐水运行情况" LabelAlign="Right" LabelWidth="150px" MaxLength="500" Required="true" ShowRedStar="true">
|
||||
</f:TextArea>
|
||||
<f:TextArea ID="txtDesalinatedRemarks" runat="server" Label="脱盐水备注" LabelAlign="Right" LabelWidth="150px" MaxLength="500" Required="true" ShowRedStar="true">
|
||||
</f:TextArea>
|
||||
</Items>
|
||||
</f:FormRow>
|
||||
<f:FormRow runat="server" ID="xhs">
|
||||
<Items>
|
||||
|
||||
<f:TextArea ID="txtLoopSituation" runat="server" Label="循环水运行情况" LabelAlign="Right" LabelWidth="150px" MaxLength="500" Required="true" ShowRedStar="true">
|
||||
</f:TextArea>
|
||||
<f:TextArea ID="txtLoopRemarks" runat="server" Label="循环水备注" LabelAlign="Right" LabelWidth="150px" MaxLength="500" Required="true" ShowRedStar="true">
|
||||
</f:TextArea>
|
||||
</Items>
|
||||
</f:FormRow>
|
||||
<f:FormRow runat="server" ID="zq">
|
||||
<Items>
|
||||
<f:TextArea ID="txtSteamSituation" runat="server" Label="蒸汽运行情况" LabelAlign="Right" LabelWidth="150px" MaxLength="500" Required="true" ShowRedStar="true">
|
||||
</f:TextArea>
|
||||
<f:TextArea ID="txtSteamRemarks" runat="server" Label="蒸汽备注" LabelAlign="Right" LabelWidth="150px" MaxLength="500" Required="true" ShowRedStar="true">
|
||||
</f:TextArea>
|
||||
</Items>
|
||||
</f:FormRow>
|
||||
<f:FormRow runat="server" ID="kyz">
|
||||
<Items>
|
||||
<f:TextArea ID="txtAirCompressionSituation" runat="server" Label="空压站运行情况" LabelAlign="Right" LabelWidth="150px" MaxLength="500" Required="true" ShowRedStar="true">
|
||||
</f:TextArea>
|
||||
<f:TextArea ID="txtAirCompressionRemarks" runat="server" Label="空压站备注" LabelAlign="Right" LabelWidth="150px" MaxLength="500" Required="true" ShowRedStar="true">
|
||||
</f:TextArea>
|
||||
</Items>
|
||||
</f:FormRow>
|
||||
<f:FormRow runat="server" ID="hca">
|
||||
<Items>
|
||||
<f:TextArea ID="txtCompoundAmmoniaSituation" runat="server" Label="合成氨运行情况" LabelAlign="Right" LabelWidth="150px" MaxLength="500" Required="true" ShowRedStar="true">
|
||||
</f:TextArea>
|
||||
<f:TextArea ID="txtCompoundAmmoniaRemarks" runat="server" Label="合成氨备注" LabelAlign="Right" LabelWidth="150px" MaxLength="500" Required="true" ShowRedStar="true">
|
||||
</f:TextArea>
|
||||
</Items>
|
||||
</f:FormRow>
|
||||
<f:FormRow runat="server" ID="ns">
|
||||
<Items>
|
||||
<f:TextArea ID="txtUreaSituation" runat="server" Label="尿素运行情况" LabelAlign="Right" LabelWidth="150px" MaxLength="500" Required="true" ShowRedStar="true">
|
||||
</f:TextArea>
|
||||
<f:TextArea ID="txtUreaRemarks" runat="server" Label="尿素备注" LabelAlign="Right" LabelWidth="150px" MaxLength="500" Required="true" ShowRedStar="true">
|
||||
</f:TextArea>
|
||||
</Items>
|
||||
</f:FormRow>
|
||||
<f:FormRow>
|
||||
<Items>
|
||||
<f:TextArea ID="txtHandoverCare" runat="server" Label="交班注意" LabelAlign="Right" LabelWidth="150px" MaxLength="500" Required="true" ShowRedStar="true">
|
||||
</f:TextArea>
|
||||
</Items>
|
||||
</f:FormRow>
|
||||
<f:FormRow>
|
||||
<Items>
|
||||
<f:ContentPanel ID="ContentPanel1" Title="操作问题" ShowBorder="true" BodyPadding="10px" EnableCollapse="true" ShowHeader="true" AutoScroll="true"
|
||||
runat="server">
|
||||
<f:Form ID="Form3" ShowBorder="false" ShowHeader="false" AutoScroll="true"
|
||||
BodyPadding="10px" runat="server" RedStarPosition="BeforeText" LabelAlign="Right">
|
||||
<Rows>
|
||||
<f:FormRow>
|
||||
<Items>
|
||||
<f:TextArea ID="txtOperationReason" runat="server" Label="操作问题原因" LabelAlign="Right" LabelWidth="150px" MaxLength="500" Required="true" ShowRedStar="true">
|
||||
</f:TextArea>
|
||||
</Items>
|
||||
</f:FormRow>
|
||||
<f:FormRow>
|
||||
<Items>
|
||||
<f:TextArea ID="txtOperationHandle" runat="server" Label="操作问题处理" LabelAlign="Right" LabelWidth="150px" MaxLength="500" Required="true" ShowRedStar="true">
|
||||
</f:TextArea>
|
||||
</Items>
|
||||
</f:FormRow>
|
||||
</Rows>
|
||||
</f:Form>
|
||||
</f:ContentPanel>
|
||||
</Items>
|
||||
</f:FormRow>
|
||||
<f:FormRow>
|
||||
<Items>
|
||||
<f:ContentPanel ID="ContentPanel3" Title="维护问题" ShowBorder="true" BodyPadding="10px" EnableCollapse="true" ShowHeader="true" AutoScroll="true"
|
||||
runat="server">
|
||||
<f:Form ID="Form4" ShowBorder="false" ShowHeader="false" AutoScroll="true"
|
||||
BodyPadding="10px" runat="server" RedStarPosition="BeforeText" LabelAlign="Right">
|
||||
<Rows>
|
||||
<f:FormRow>
|
||||
<Items>
|
||||
<f:TextArea ID="txtMaintenanceReason" runat="server" Label="维护问题原因" LabelAlign="Right" LabelWidth="150px" MaxLength="500" Required="true" ShowRedStar="true">
|
||||
</f:TextArea>
|
||||
</Items>
|
||||
</f:FormRow>
|
||||
<f:FormRow>
|
||||
<Items>
|
||||
<f:TextArea ID="txtMaintenanceHandle" runat="server" Label="维护问题处理" LabelAlign="Right" LabelWidth="150px" MaxLength="500" Required="true" ShowRedStar="true">
|
||||
</f:TextArea>
|
||||
</Items>
|
||||
</f:FormRow>
|
||||
</Rows>
|
||||
</f:Form>
|
||||
</f:ContentPanel>
|
||||
</Items>
|
||||
</f:FormRow>
|
||||
</Rows>
|
||||
</f:Form>
|
||||
</f:ContentPanel>
|
||||
</Items>
|
||||
</f:FormRow>
|
||||
</Rows>
|
||||
</f:Form>
|
||||
</form>
|
||||
</body>
|
||||
</html>
|
|
@ -0,0 +1,258 @@
|
|||
using BLL;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Runtime.InteropServices.ComTypes;
|
||||
using System.Web;
|
||||
using System.Web.UI;
|
||||
using System.Web.UI.WebControls;
|
||||
|
||||
namespace FineUIPro.Web.TestRun.ProduceTestRun
|
||||
{
|
||||
public partial class RunningLogManagementEdit : PageBase
|
||||
{
|
||||
/// <summary>
|
||||
/// 日志
|
||||
/// </summary>
|
||||
public string RunningId { get { return (string)ViewState["RunningId"]; } set { ViewState["RunningId"] = value; } }
|
||||
/// <summary>
|
||||
/// 系统主键
|
||||
/// </summary>
|
||||
public string SystemId { get { return (string)ViewState["SystemId"]; } set { ViewState["SystemId"] = value; } }
|
||||
|
||||
protected void Page_Load(object sender, EventArgs e)
|
||||
{
|
||||
if (!IsPostBack)
|
||||
{
|
||||
this.RunningId = Request["RunningId"];
|
||||
this.SystemId = Request["SystemId"];
|
||||
PageBase();
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 页面控件处理
|
||||
/// </summary>
|
||||
public void PageBase()
|
||||
{
|
||||
//获取人员
|
||||
var userList = from user in Funs.DB.Sys_User
|
||||
join projectrole in Funs.DB.Project_ProjectUser on user.UserId equals projectrole.UserId
|
||||
where projectrole.ProjectId == this.CurrUser.LoginProjectId
|
||||
select user;
|
||||
var userids = new List<string>() { Const.sysglyId, Const.hfnbdId, Const.sedinId };
|
||||
var addUserList = Funs.DB.Sys_User.Where(x => userids.Contains(x.UserId));
|
||||
var users = userList.ToList();
|
||||
if (addUserList.Count() > 0)
|
||||
{
|
||||
users.AddRange(addUserList);
|
||||
}
|
||||
//轮班职工
|
||||
ddlShiftUser.DataTextField = "UserName";
|
||||
ddlShiftUser.DataValueField = "UserId";
|
||||
ddlShiftUser.DataSource = users;
|
||||
ddlShiftUser.DataBind();
|
||||
ddlShiftUser.SelectedValue = this.CurrUser.UserId;
|
||||
//继任职工
|
||||
ddlSuccessionUser.DataTextField = "UserName";
|
||||
ddlSuccessionUser.DataValueField = "UserId";
|
||||
ddlSuccessionUser.DataSource = users;
|
||||
ddlSuccessionUser.DataBind();
|
||||
ddlSuccessionUser.SelectedValue = this.CurrUser.UserId;
|
||||
List<string> options = new List<string>();
|
||||
var model = Funs.DB.Running_LogManagement.FirstOrDefault(x => x.RunningId == this.RunningId);
|
||||
if (model != null)
|
||||
{
|
||||
txtJobNo.Text = model.JobNo;
|
||||
ddlShiftUser.SelectedValue = model.ShiftUser;
|
||||
ddlSuccessionUser.SelectedValue = model.SuccessionUser;
|
||||
txtStartData.Text = model.StartData.Value.ToString("yyyy-MM-dd HH:mm:ss");
|
||||
txtEndData.Text = model.EndData.Value.ToString("yyyy-MM-dd HH:mm:ss");
|
||||
if (model.IsDesalinated == 1)
|
||||
{
|
||||
options.Add("1");
|
||||
tys.Hidden = false;
|
||||
txtDesalinatedSituation.Text = model.DesalinatedSituation;
|
||||
txtDesalinatedRemarks.Text = model.DesalinatedRemarks;
|
||||
}
|
||||
else
|
||||
{
|
||||
tys.Hidden = true;
|
||||
}
|
||||
if (model.IsLoop == 1)
|
||||
{
|
||||
options.Add("2");
|
||||
xhs.Hidden = false;
|
||||
txtLoopSituation.Text = model.LoopSituation;
|
||||
txtLoopRemarks.Text = model.LoopRemarks;
|
||||
}
|
||||
else
|
||||
{
|
||||
xhs.Hidden = true;
|
||||
}
|
||||
if (model.IsSteam == 1)
|
||||
{
|
||||
options.Add("3");
|
||||
zq.Hidden = false;
|
||||
txtSteamSituation.Text = model.SteamSituation;
|
||||
txtSteamRemarks.Text = model.SteamRemarks;
|
||||
}
|
||||
else
|
||||
{
|
||||
zq.Hidden = true;
|
||||
}
|
||||
if (model.IsAirCompression == 1)
|
||||
{
|
||||
options.Add("4");
|
||||
kyz.Hidden = false;
|
||||
txtAirCompressionSituation.Text = model.AirCompressionSituation;
|
||||
txtAirCompressionRemarks.Text = model.AirCompressionRemarks;
|
||||
}
|
||||
else
|
||||
{
|
||||
kyz.Hidden = true;
|
||||
}
|
||||
if (model.IsCompoundAmmonia == 1)
|
||||
{
|
||||
options.Add("5");
|
||||
hca.Hidden = false;
|
||||
txtCompoundAmmoniaSituation.Text = model.CompoundAmmoniaSituation;
|
||||
txtCompoundAmmoniaRemarks.Text = model.CompoundAmmoniaRemarks;
|
||||
}
|
||||
else
|
||||
{
|
||||
hca.Hidden = true;
|
||||
}
|
||||
if (model.IsUrea == 1)
|
||||
{
|
||||
options.Add("6");
|
||||
ns.Hidden = false;
|
||||
txtUreaSituation.Text = model.UreaSituation;
|
||||
txtUreaRemarks.Text = model.UreaRemarks;
|
||||
}
|
||||
else
|
||||
{
|
||||
ns.Hidden = true;
|
||||
}
|
||||
rdbOperation.SelectedValueArray = options.ToArray();
|
||||
txtHandoverCare.Text = model.HandoverCare;
|
||||
txtOperationReason.Text = model.OperationReason;
|
||||
txtOperationHandle.Text = model.OperationHandle;
|
||||
txtMaintenanceReason.Text = model.MaintenanceReason;
|
||||
txtMaintenanceHandle.Text = model.MaintenanceHandle;
|
||||
}
|
||||
else
|
||||
{
|
||||
txtJobNo.Text = SQLHelper.RunProcNewId("SpGetNewCode5", "dbo.Running_LogManagement", "JobNo", "13022-PS81-");
|
||||
tys.Hidden = true;
|
||||
xhs.Hidden = true;
|
||||
zq.Hidden = true;
|
||||
kyz.Hidden = true;
|
||||
hca.Hidden = true;
|
||||
ns.Hidden = true;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 选择项
|
||||
/// </summary>
|
||||
protected void rdbOperation_SelectedIndexChanged(object sender, EventArgs e)
|
||||
{
|
||||
var rdbArr = rdbOperation.SelectedValueArray;
|
||||
tys.Hidden = rdbArr.Contains("1") ? false : true;
|
||||
xhs.Hidden = rdbArr.Contains("2") ? false : true;
|
||||
zq.Hidden = rdbArr.Contains("3") ? false : true;
|
||||
kyz.Hidden = rdbArr.Contains("4") ? false : true;
|
||||
hca.Hidden = rdbArr.Contains("5") ? false : true;
|
||||
ns.Hidden = rdbArr.Contains("6") ? false : true;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 保存
|
||||
/// </summary>
|
||||
protected void btnSave_Click(object sender, EventArgs e)
|
||||
{
|
||||
if (string.IsNullOrWhiteSpace(ddlShiftUser.SelectedValue))
|
||||
{
|
||||
ShowNotify("请选择轮班职工!", MessageBoxIcon.Warning);
|
||||
return;
|
||||
}
|
||||
if (string.IsNullOrWhiteSpace(ddlSuccessionUser.SelectedValue))
|
||||
{
|
||||
ShowNotify("请选择继任职工!", MessageBoxIcon.Warning);
|
||||
return;
|
||||
}
|
||||
var sysmodel = Funs.DB.PreRun_SysDevice.FirstOrDefault(x => x.PreRunId == this.SystemId);
|
||||
if (sysmodel == null)
|
||||
{
|
||||
Alert.ShowInTop("系统参数错误!", MessageBoxIcon.Warning);
|
||||
return;
|
||||
}
|
||||
|
||||
var edata = DateTime.Parse(txtEndData.Text);
|
||||
if (!string.IsNullOrWhiteSpace(this.RunningId))
|
||||
{
|
||||
if (Funs.DB.Running_LogManagement.Count(x => x.ShiftType == ddlShiftType.SelectedValue && x.SystemId == this.SystemId && x.EndData.Value.Year == edata.Year && x.EndData.Value.Month == edata.Month && x.EndData.Value.Day == edata.Day && x.RunningId != this.RunningId) > 0)
|
||||
{
|
||||
Alert.ShowInTop($"{DateTime.Now.ToString("yyyy-MM-dd")}已添加{ddlShiftType.SelectedText}日志,无法继续添加!", MessageBoxIcon.Warning);
|
||||
return;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
if (Funs.DB.Running_LogManagement.Count(x => x.ShiftType == ddlShiftType.SelectedValue && x.SystemId == this.SystemId && x.EndData.Value.Year == edata.Year && x.EndData.Value.Month == edata.Month && x.EndData.Value.Day == edata.Day) > 0)
|
||||
{
|
||||
Alert.ShowInTop($"{DateTime.Now.ToString("yyyy-MM-dd")}已添加{ddlShiftType.SelectedText}日志,无法继续添加!", MessageBoxIcon.Warning);
|
||||
return;
|
||||
}
|
||||
}
|
||||
bool add = false;
|
||||
var model = Funs.DB.Running_LogManagement.FirstOrDefault(x => x.RunningId == this.RunningId);
|
||||
if (model == null)
|
||||
{
|
||||
add = true;
|
||||
model = new Model.Running_LogManagement();
|
||||
model.RunningId = Guid.NewGuid().ToString();
|
||||
model.ProjectId = this.CurrUser.LoginProjectId;
|
||||
model.InstallationId = sysmodel.InstallationId;
|
||||
model.ProcessesId = sysmodel.ProcessesId;
|
||||
model.SystemId = this.SystemId;
|
||||
model.AddUser = this.CurrUser.UserId;
|
||||
model.AddTime = DateTime.Now;
|
||||
}
|
||||
model.JobNo = txtJobNo.Text;
|
||||
model.ShiftType = ddlShiftType.SelectedValue;
|
||||
model.ShiftUser = ddlShiftUser.SelectedValue;
|
||||
model.SuccessionUser = ddlSuccessionUser.SelectedValue;
|
||||
model.StartData = DateTime.Parse(txtStartData.Text);
|
||||
model.EndData = DateTime.Parse(txtEndData.Text);
|
||||
model.IsDesalinated = rdbOperation.SelectedValueArray.Contains("1") ? 1 : 0;
|
||||
model.DesalinatedSituation = txtDesalinatedSituation.Text;
|
||||
model.DesalinatedRemarks = txtDesalinatedRemarks.Text;
|
||||
model.IsLoop = rdbOperation.SelectedValueArray.Contains("2") ? 1 : 0;
|
||||
model.LoopSituation = txtLoopSituation.Text;
|
||||
model.LoopRemarks = txtLoopRemarks.Text;
|
||||
model.IsSteam = rdbOperation.SelectedValueArray.Contains("3") ? 1 : 0;
|
||||
model.SteamSituation = txtSteamSituation.Text;
|
||||
model.SteamRemarks = txtSteamRemarks.Text;
|
||||
model.IsAirCompression = rdbOperation.SelectedValueArray.Contains("4") ? 1 : 0;
|
||||
model.AirCompressionSituation = txtAirCompressionSituation.Text;
|
||||
model.AirCompressionRemarks = txtAirCompressionRemarks.Text;
|
||||
model.IsCompoundAmmonia = rdbOperation.SelectedValueArray.Contains("5") ? 1 : 0;
|
||||
model.CompoundAmmoniaSituation = txtCompoundAmmoniaSituation.Text;
|
||||
model.CompoundAmmoniaRemarks = txtCompoundAmmoniaRemarks.Text;
|
||||
model.IsUrea = rdbOperation.SelectedValueArray.Contains("6") ? 1 : 0;
|
||||
model.UreaSituation = txtUreaSituation.Text;
|
||||
model.UreaRemarks = txtUreaRemarks.Text;
|
||||
model.HandoverCare = txtHandoverCare.Text;
|
||||
model.OperationReason = txtOperationReason.Text;
|
||||
model.OperationHandle = txtOperationHandle.Text;
|
||||
model.MaintenanceReason = txtMaintenanceReason.Text;
|
||||
model.MaintenanceHandle = txtMaintenanceHandle.Text;
|
||||
if (add) Funs.DB.Running_LogManagement.InsertOnSubmit(model);
|
||||
Funs.DB.SubmitChanges();
|
||||
ShowNotify("操作成功!", MessageBoxIcon.Success);
|
||||
PageContext.RegisterStartupScript(ActiveWindow.GetHidePostBackReference());
|
||||
}
|
||||
}
|
||||
}
|
395
SGGL/FineUIPro.Web/TestRun/ProduceTestRun/RunningLogManagementEdit.aspx.designer.cs
generated
Normal file
395
SGGL/FineUIPro.Web/TestRun/ProduceTestRun/RunningLogManagementEdit.aspx.designer.cs
generated
Normal file
|
@ -0,0 +1,395 @@
|
|||
//------------------------------------------------------------------------------
|
||||
// <自动生成>
|
||||
// 此代码由工具生成。
|
||||
//
|
||||
// 对此文件的更改可能导致不正确的行为,如果
|
||||
// 重新生成代码,则所做更改将丢失。
|
||||
// </自动生成>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace FineUIPro.Web.TestRun.ProduceTestRun
|
||||
{
|
||||
|
||||
|
||||
public partial class RunningLogManagementEdit
|
||||
{
|
||||
|
||||
/// <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>
|
||||
/// Toolbar1 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Toolbar Toolbar1;
|
||||
|
||||
/// <summary>
|
||||
/// ToolbarFill1 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.ToolbarFill ToolbarFill1;
|
||||
|
||||
/// <summary>
|
||||
/// btnSave 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Button btnSave;
|
||||
|
||||
/// <summary>
|
||||
/// ContentPanel2 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.ContentPanel ContentPanel2;
|
||||
|
||||
/// <summary>
|
||||
/// Form2 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Form Form2;
|
||||
|
||||
/// <summary>
|
||||
/// txtJobNo 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.TextBox txtJobNo;
|
||||
|
||||
/// <summary>
|
||||
/// ddlShiftType 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.DropDownList ddlShiftType;
|
||||
|
||||
/// <summary>
|
||||
/// ddlShiftUser 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.DropDownList ddlShiftUser;
|
||||
|
||||
/// <summary>
|
||||
/// ddlSuccessionUser 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.DropDownList ddlSuccessionUser;
|
||||
|
||||
/// <summary>
|
||||
/// txtStartData 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.DatePicker txtStartData;
|
||||
|
||||
/// <summary>
|
||||
/// txtEndData 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.DatePicker txtEndData;
|
||||
|
||||
/// <summary>
|
||||
/// rdbOperation 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.CheckBoxList rdbOperation;
|
||||
|
||||
/// <summary>
|
||||
/// tys 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.FormRow tys;
|
||||
|
||||
/// <summary>
|
||||
/// txtDesalinatedSituation 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.TextArea txtDesalinatedSituation;
|
||||
|
||||
/// <summary>
|
||||
/// txtDesalinatedRemarks 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.TextArea txtDesalinatedRemarks;
|
||||
|
||||
/// <summary>
|
||||
/// xhs 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.FormRow xhs;
|
||||
|
||||
/// <summary>
|
||||
/// txtLoopSituation 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.TextArea txtLoopSituation;
|
||||
|
||||
/// <summary>
|
||||
/// txtLoopRemarks 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.TextArea txtLoopRemarks;
|
||||
|
||||
/// <summary>
|
||||
/// zq 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.FormRow zq;
|
||||
|
||||
/// <summary>
|
||||
/// txtSteamSituation 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.TextArea txtSteamSituation;
|
||||
|
||||
/// <summary>
|
||||
/// txtSteamRemarks 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.TextArea txtSteamRemarks;
|
||||
|
||||
/// <summary>
|
||||
/// kyz 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.FormRow kyz;
|
||||
|
||||
/// <summary>
|
||||
/// txtAirCompressionSituation 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.TextArea txtAirCompressionSituation;
|
||||
|
||||
/// <summary>
|
||||
/// txtAirCompressionRemarks 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.TextArea txtAirCompressionRemarks;
|
||||
|
||||
/// <summary>
|
||||
/// hca 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.FormRow hca;
|
||||
|
||||
/// <summary>
|
||||
/// txtCompoundAmmoniaSituation 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.TextArea txtCompoundAmmoniaSituation;
|
||||
|
||||
/// <summary>
|
||||
/// txtCompoundAmmoniaRemarks 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.TextArea txtCompoundAmmoniaRemarks;
|
||||
|
||||
/// <summary>
|
||||
/// ns 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.FormRow ns;
|
||||
|
||||
/// <summary>
|
||||
/// txtUreaSituation 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.TextArea txtUreaSituation;
|
||||
|
||||
/// <summary>
|
||||
/// txtUreaRemarks 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.TextArea txtUreaRemarks;
|
||||
|
||||
/// <summary>
|
||||
/// txtHandoverCare 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.TextArea txtHandoverCare;
|
||||
|
||||
/// <summary>
|
||||
/// ContentPanel1 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.ContentPanel ContentPanel1;
|
||||
|
||||
/// <summary>
|
||||
/// Form3 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Form Form3;
|
||||
|
||||
/// <summary>
|
||||
/// txtOperationReason 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.TextArea txtOperationReason;
|
||||
|
||||
/// <summary>
|
||||
/// txtOperationHandle 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.TextArea txtOperationHandle;
|
||||
|
||||
/// <summary>
|
||||
/// ContentPanel3 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.ContentPanel ContentPanel3;
|
||||
|
||||
/// <summary>
|
||||
/// Form4 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Form Form4;
|
||||
|
||||
/// <summary>
|
||||
/// txtMaintenanceReason 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.TextArea txtMaintenanceReason;
|
||||
|
||||
/// <summary>
|
||||
/// txtMaintenanceHandle 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.TextArea txtMaintenanceHandle;
|
||||
}
|
||||
}
|
|
@ -0,0 +1,144 @@
|
|||
<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="RunningLogManagementList.aspx.cs" Inherits="FineUIPro.Web.TestRun.ProduceTestRun.RunningLogManagementList" %>
|
||||
|
||||
<!DOCTYPE html>
|
||||
|
||||
<html xmlns="http://www.w3.org/1999/xhtml">
|
||||
<head runat="server">
|
||||
<link href="../../res/css/common.css" rel="stylesheet" type="text/css" />
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
||||
<script src="../../Controls/My97DatePicker/WdatePicker.js" type="text/javascript"></script>
|
||||
<title>运行日志管理</title>
|
||||
<style type="text/css">
|
||||
.labcenter {
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
.f-grid-row .f-grid-cell-inner {
|
||||
white-space: normal;
|
||||
word-break: break-all;
|
||||
}
|
||||
|
||||
.LabelColor {
|
||||
color: Red;
|
||||
font-size: small;
|
||||
}
|
||||
|
||||
.Green {
|
||||
background-color: Green;
|
||||
color: white;
|
||||
}
|
||||
|
||||
.Yellow {
|
||||
background-color: #FFFF93;
|
||||
}
|
||||
|
||||
.Red {
|
||||
background-color: red;
|
||||
}
|
||||
|
||||
.LightGreen {
|
||||
background-color: LightGreen
|
||||
}
|
||||
|
||||
.f-grid-colheader-text {
|
||||
white-space: normal;
|
||||
word-break: break-all;
|
||||
}
|
||||
</style>
|
||||
</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="Region" BoxConfigAlign="Stretch">
|
||||
<Items>
|
||||
<f:Panel runat="server" ID="panelLeftRegion" RegionPosition="Left" RegionSplit="true"
|
||||
EnableCollapse="true" Width="300px" Title="巡检记录" ShowBorder="true" Layout="VBox"
|
||||
ShowHeader="false" AutoScroll="true" BodyPadding="5px" IconFont="ArrowCircleLeft">
|
||||
<Items>
|
||||
<f:Tree ID="tvControlItem" ShowHeader="false" Title="工作包" OnNodeCommand="tvControlItem_NodeCommand"
|
||||
runat="server" ShowBorder="false" EnableCollapse="true" EnableSingleClickExpand="true"
|
||||
AutoLeafIdentification="true" EnableSingleExpand="false">
|
||||
</f:Tree>
|
||||
</Items>
|
||||
</f:Panel>
|
||||
<f:Grid ID="Grid1" ShowBorder="true" EnableAjax="false" ShowHeader="false" Title="运行日志管理" EnableCollapse="true"
|
||||
runat="server" BoxFlex="1" DataKeyNames="RunningId" AllowCellEditing="true" ClicksToEdit="2" DataIDField="RunningId" AllowSorting="true" SortField="AddTime" SortDirection="DESC" OnSort="Grid1_Sort" EnableColumnLines="true" ForceFit="true" AllowPaging="true" IsDatabasePaging="true" PageSize="10" OnPageIndexChange="Grid1_PageIndexChange" EnableRowDoubleClickEvent="true" OnRowDoubleClick="Grid1_RowDoubleClick" AllowFilters="true" EnableTextSelection="True" EnableMultiSelect="false" EnableCheckBoxSelect="true">
|
||||
<Toolbars>
|
||||
<f:Toolbar ID="Toolbar1" Position="Top" runat="server" ToolbarAlign="Left">
|
||||
<Items>
|
||||
<f:DropDownList ID="ddlShiftType" runat="server" Label="轮班类型" LabelAlign="Right" EnableEdit="true">
|
||||
<f:ListItem Text="全部" Value="" />
|
||||
<f:ListItem Text="白班" Value="1" />
|
||||
<f:ListItem Text="夜班" Value="2" />
|
||||
</f:DropDownList>
|
||||
<f:ToolbarFill runat="server"></f:ToolbarFill>
|
||||
<f:Button ID="btnQuery" ToolTip="查询" Icon="SystemSearch" runat="server" OnClick="btnQuery_Click"></f:Button>
|
||||
<f:Button ID="btnAdd" Icon="Add" Text="添加" ToolTip="处理" runat="server" OnClick="btnAdd_Click"></f:Button>
|
||||
<f:Button ID="btnModify" Text="修改" ToolTip="修改" Icon="Pencil" runat="server" OnClick="btnModify_Click"></f:Button>
|
||||
<f:Button ID="btnDel" Text="删除" ToolTip="删除" Icon="Delete" runat="server" OnClick="btnDel_Click" ConfirmText="是否确认删除?"></f:Button>
|
||||
<f:Button ID="btnExport" runat="server" Icon="ApplicationGo" Text="导出" ToolTip="导出" EnableAjax="false" DisableControlBeforePostBack="false" OnClick="btnExport_Click"></f:Button>
|
||||
</Items>
|
||||
</f:Toolbar>
|
||||
</Toolbars>
|
||||
<Columns>
|
||||
<f:RowNumberField />
|
||||
<f:RenderField ColumnID="ProjectName" DataField="ProjectName" HeaderText="项目名称" HeaderTextAlign="Center">
|
||||
</f:RenderField>
|
||||
<f:RenderField ColumnID="JobNo" DataField="JobNo" HeaderText="工作编号" HeaderTextAlign="Center">
|
||||
</f:RenderField>
|
||||
<f:RenderField ColumnID="ShiftTypeName" DataField="ShiftTypeName" HeaderText="轮班类型" HeaderTextAlign="Center">
|
||||
</f:RenderField>
|
||||
<f:RenderField ColumnID="ShiftUserName" DataField="ShiftUserName" HeaderText="轮班职工" HeaderTextAlign="Center">
|
||||
</f:RenderField>
|
||||
<f:RenderField ColumnID="SuccessionUserName" DataField="SuccessionUserName" HeaderText="继任职工" HeaderTextAlign="Center">
|
||||
</f:RenderField>
|
||||
<f:BoundField DataField="StartData" DataFormatString="{0:yyyy-MM-dd hh:mm:ss}" HeaderText="开始时间" />
|
||||
<f:BoundField DataField="EndData" DataFormatString="{0:yyyy-MM-dd hh:mm:ss}" HeaderText="结束时间" />
|
||||
</Columns>
|
||||
<Listeners>
|
||||
<f:Listener Event="beforerowcontextmenu" Handler="onRowContextMenu" />
|
||||
</Listeners>
|
||||
<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="100000" />
|
||||
</f:DropDownList>
|
||||
<f:ToolbarFill runat="server">
|
||||
</f:ToolbarFill>
|
||||
|
||||
</PageItems>
|
||||
</f:Grid>
|
||||
</Items>
|
||||
</f:Panel>
|
||||
<f:Window ID="Window1" Title="检查项巡检确认" Hidden="true" EnableIFrame="true" EnableMaximize="true"
|
||||
Target="Parent" EnableResize="false" runat="server" IsModal="true" OnClose="Window1_Close"
|
||||
Width="1300px" Height="660px">
|
||||
</f:Window>
|
||||
<f:Menu ID="Menu1" runat="server">
|
||||
<Items>
|
||||
<f:MenuButton ID="btnMenuModify" EnablePostBack="true" runat="server" Text="处理" Icon="Pencil"
|
||||
OnClick="btnMenuModify_Click">
|
||||
</f:MenuButton>
|
||||
</Items>
|
||||
</f:Menu>
|
||||
</form>
|
||||
<script type="text/javascript">
|
||||
var menuID = '<%= Menu1.ClientID %>';
|
||||
|
||||
// 返回false,来阻止浏览器右键菜单
|
||||
function onRowContextMenu(event, rowId) {
|
||||
F(menuID).show(); //showAt(event.pageX, event.pageY);
|
||||
return false;
|
||||
}
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
|
@ -0,0 +1,666 @@
|
|||
using BLL;
|
||||
using NPOI.SS.UserModel;
|
||||
using NPOI.XSSF.UserModel;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Data;
|
||||
using System.Data.SqlClient;
|
||||
using System.IO;
|
||||
using System.Linq;
|
||||
using System.Web;
|
||||
using System.Web.UI;
|
||||
using NPOI.SS.UserModel;
|
||||
using NPOI.SS.Util;
|
||||
using NPOI.XSSF.UserModel;
|
||||
using Model;
|
||||
using NPOI.SS.Formula.Functions;
|
||||
|
||||
namespace FineUIPro.Web.TestRun.ProduceTestRun
|
||||
{
|
||||
public partial class RunningLogManagementList : PageBase
|
||||
{
|
||||
/// <summary>
|
||||
/// 系统主键
|
||||
/// </summary>
|
||||
public string SystemId { get { return (string)ViewState["SystemId"]; } set { ViewState["SystemId"] = value; } }
|
||||
|
||||
protected void Page_Load(object sender, EventArgs e)
|
||||
{
|
||||
if (!IsPostBack)
|
||||
{
|
||||
//绑定数据
|
||||
InitTreeMenu();
|
||||
}
|
||||
}
|
||||
|
||||
#region 树绑定
|
||||
|
||||
/// <summary>
|
||||
/// 加载树
|
||||
/// </summary>
|
||||
private void InitTreeMenu()
|
||||
{
|
||||
this.tvControlItem.Nodes.Clear();
|
||||
TreeNode rootNode = new TreeNode();
|
||||
rootNode.Text = "检查表";
|
||||
rootNode.NodeID = "0";
|
||||
rootNode.Expanded = true;
|
||||
rootNode.ToolTip = "";
|
||||
rootNode.EnableClickEvent = true;
|
||||
this.tvControlItem.Nodes.Add(rootNode);
|
||||
var alllist = Funs.DB.PreRun_SysDevice.Where(x => x.ProjectId == this.CurrUser.LoginProjectId && x.PreRunLevel != 4).ToList();
|
||||
if (alllist.Count() > 0)
|
||||
{
|
||||
var onelist = alllist.Where(x => x.PreRunLevel == 1).ToList();
|
||||
|
||||
foreach (var itemOne in onelist)
|
||||
{
|
||||
TreeNode rootOneNode = new TreeNode();
|
||||
rootOneNode.NodeID = itemOne.PreRunId;
|
||||
rootOneNode.Text = itemOne.PreRunName;
|
||||
rootOneNode.ToolTip = itemOne.PreRunName;
|
||||
rootOneNode.CommandName = "";
|
||||
rootOneNode.EnableClickEvent = true;
|
||||
rootOneNode.EnableExpandEvent = false;
|
||||
rootNode.Nodes.Add(rootOneNode);
|
||||
rootOneNode.Expanded = true;
|
||||
var twolist = alllist.Where(x => x.PreRunLevel == 2 && x.ParentId == itemOne.PreRunId).ToList();
|
||||
foreach (var itemTwo in twolist)
|
||||
{
|
||||
TreeNode rootTwoNode = new TreeNode();
|
||||
rootTwoNode.NodeID = itemOne.PreRunId + "|" + itemTwo.PreRunId;
|
||||
rootTwoNode.Text = itemTwo.PreRunName;
|
||||
rootTwoNode.ToolTip = itemTwo.PreRunName;
|
||||
rootTwoNode.CommandName = "";
|
||||
rootTwoNode.EnableClickEvent = true;
|
||||
rootTwoNode.EnableExpandEvent = false;
|
||||
rootOneNode.Nodes.Add(rootTwoNode);
|
||||
rootTwoNode.Expanded = true;
|
||||
var threelist = alllist.Where(x => x.PreRunLevel == 3 && x.ParentId == itemTwo.PreRunId).ToList();
|
||||
foreach (var itemThree in threelist)
|
||||
{
|
||||
TreeNode rootThreeNode = new TreeNode();
|
||||
rootThreeNode.NodeID = itemOne.PreRunId + "|" + itemTwo.PreRunId + "|" + itemThree.PreRunId;
|
||||
rootThreeNode.Text = itemThree.PreRunName;
|
||||
rootThreeNode.ToolTip = itemThree.PreRunName;
|
||||
rootThreeNode.CommandName = "";
|
||||
rootThreeNode.EnableClickEvent = true;
|
||||
rootThreeNode.EnableExpandEvent = false;
|
||||
rootTwoNode.Nodes.Add(rootThreeNode);
|
||||
rootThreeNode.Expanded = true;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 点击TreeView
|
||||
/// </summary>
|
||||
protected void tvControlItem_NodeCommand(object sender, TreeCommandEventArgs e)
|
||||
{
|
||||
if (this.tvControlItem.SelectedNodeID.Split('|').Length > 2)
|
||||
{
|
||||
this.SystemId = this.tvControlItem.SelectedNodeID.Split('|').Last();
|
||||
}
|
||||
this.BindGrid();
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
#region 绑定数据
|
||||
|
||||
/// <summary>
|
||||
/// 数据绑定
|
||||
/// </summary>
|
||||
public void BindGrid()
|
||||
{
|
||||
string strSql = @"select a.RunningId,a.ProjectId,project.ProjectName as ProjectName,a.InstallationId,a.ProcessesId,a.SystemId,a.JobNo,a.ShiftType,(case a.ShiftType when 1 then '白班' else '夜班' end) as ShiftTypeName,a.ShiftUser,shiftuser.UserName as ShiftUserName,a.SuccessionUser,successuser.UserName as SuccessionUserName,a.StartData,a.EndData,a.IsDesalinated,a.DesalinatedSituation,a.DesalinatedRemarks,a.IsLoop,a.LoopSituation,a.LoopRemarks,a.IsSteam,a.SteamSituation,a.SteamRemarks,a.IsAirCompression,a.AirCompressionSituation,a.AirCompressionRemarks,a.IsCompoundAmmonia,a.CompoundAmmoniaSituation,a.CompoundAmmoniaRemarks,a.IsUrea,a.UreaSituation,a.UreaRemarks,a.HandoverCare,a.OperationReason,a.OperationHandle,a.MaintenanceReason,a.MaintenanceHandle,a.AddUser,a.AddTime,a.Sort from Running_LogManagement as a inner join Sys_User as shiftuser on shiftuser.UserId=a.ShiftUser inner join Sys_User as successuser on successuser.UserId=a.SuccessionUser inner join Base_Project as project on project.ProjectId=a.ProjectId ";
|
||||
List<SqlParameter> listStr = new List<SqlParameter>();
|
||||
listStr.Add(new SqlParameter("@projectid", this.CurrUser.LoginProjectId));
|
||||
if (this.tvControlItem.SelectedNodeID.Split('|').Length > 0)
|
||||
{
|
||||
var installationId = this.tvControlItem.SelectedNodeID.Split('|').First();
|
||||
strSql += " and a.InstallationId=@InstallationId";
|
||||
listStr.Add(new SqlParameter("@InstallationId", installationId));
|
||||
}
|
||||
if (this.tvControlItem.SelectedNodeID.Split('|').Length > 1)
|
||||
{
|
||||
var processesId = this.tvControlItem.SelectedNodeID.Split('|')[1];
|
||||
strSql += " and a.ProcessesId=@ProcessesId";
|
||||
listStr.Add(new SqlParameter("@ProcessesId", processesId));
|
||||
}
|
||||
if (this.tvControlItem.SelectedNodeID.Split('|').Length > 2)
|
||||
{
|
||||
var systemId = this.tvControlItem.SelectedNodeID.Split('|').Last();
|
||||
strSql += " and a.SystemId=@SystemId";
|
||||
listStr.Add(new SqlParameter("@SystemId", systemId));
|
||||
}
|
||||
if (!string.IsNullOrWhiteSpace(ddlShiftType.SelectedValue))
|
||||
{
|
||||
strSql += " and a.ShiftType=@ShiftType";
|
||||
listStr.Add(new SqlParameter("@ShiftType", ddlShiftType.SelectedValue));
|
||||
}
|
||||
strSql += " order by a.AddTime asc";
|
||||
SqlParameter[] parameter = listStr.ToArray();
|
||||
DataTable tb = SQLHelper.GetDataTableRunText(strSql, parameter);
|
||||
Grid1.RecordCount = tb.Rows.Count;
|
||||
var table = this.GetPagedDataTable(Grid1, tb);
|
||||
Grid1.DataSource = table;
|
||||
Grid1.DataBind();
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 分页
|
||||
/// </summary>
|
||||
protected void Grid1_PageIndexChange(object sender, GridPageEventArgs e)
|
||||
{
|
||||
Grid1.PageIndex = e.NewPageIndex;
|
||||
BindGrid();
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 分页下拉框
|
||||
/// </summary>
|
||||
protected void ddlPageSize_SelectedIndexChanged(object sender, EventArgs e)
|
||||
{
|
||||
Grid1.PageSize = Convert.ToInt32(ddlPageSize.SelectedValue);
|
||||
BindGrid();
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 排序
|
||||
/// </summary>
|
||||
protected void Grid1_Sort(object sender, GridSortEventArgs e)
|
||||
{
|
||||
BindGrid();
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 双击修改
|
||||
/// </summary>
|
||||
protected void Grid1_RowDoubleClick(object sender, GridRowClickEventArgs e)
|
||||
{
|
||||
btnMenuModify_Click(null, null);
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
#region 按钮
|
||||
|
||||
/// <summary>
|
||||
/// 关闭弹框
|
||||
/// </summary>
|
||||
protected void Window1_Close(object sender, WindowCloseEventArgs e)
|
||||
{
|
||||
BindGrid();
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 搜索
|
||||
/// </summary>
|
||||
protected void btnQuery_Click(object sender, EventArgs e)
|
||||
{
|
||||
BindGrid();
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 添加
|
||||
/// </summary>
|
||||
protected void btnAdd_Click(object sender, EventArgs e)
|
||||
{
|
||||
if (string.IsNullOrWhiteSpace(this.SystemId))
|
||||
{
|
||||
Alert.ShowInTop("请选择系统!", MessageBoxIcon.Warning);
|
||||
return;
|
||||
}
|
||||
PageContext.RegisterStartupScript(Window1.GetShowReference(String.Format("RunningLogManagementEdit.aspx?RunningId=&SystemId=" + this.SystemId, "新增 - ")));
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 修改
|
||||
/// </summary>
|
||||
protected void btnModify_Click(object sender, EventArgs e)
|
||||
{
|
||||
if (Grid1.SelectedRowIndexArray.Length == 0)
|
||||
{
|
||||
Alert.ShowInTop("请至少选择一条记录!", MessageBoxIcon.Warning);
|
||||
return;
|
||||
}
|
||||
PageContext.RegisterStartupScript(Window1.GetShowReference(String.Format("RunningLogManagementEdit.aspx?RunningId={0}&SystemId={1}", Grid1.SelectedRowID, this.SystemId, "编辑 - ")));
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 删除
|
||||
/// </summary>
|
||||
protected void btnDel_Click(object sender, EventArgs e)
|
||||
{
|
||||
if (Grid1.SelectedRowIndexArray.Length == 0)
|
||||
{
|
||||
Alert.ShowInTop("请至少选择一条记录!", MessageBoxIcon.Warning);
|
||||
return;
|
||||
}
|
||||
var ids = Grid1.SelectedRowIDArray.ToList();
|
||||
var list = Funs.DB.Running_LogManagement.Where(x => ids.Contains(x.RunningId)).ToList();
|
||||
if (list.Count > 0)
|
||||
{
|
||||
Funs.DB.Running_LogManagement.DeleteAllOnSubmit(list);
|
||||
Funs.DB.SubmitChanges();
|
||||
BindGrid();
|
||||
Alert.ShowInTop("删除成功!", MessageBoxIcon.Success);
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 导出
|
||||
/// </summary>
|
||||
protected void btnExport_Click(object sender, EventArgs e)
|
||||
{
|
||||
if (Grid1.SelectedRowIndexArray.Length == 0 || Grid1.SelectedRowIndexArray.Length > 1)
|
||||
{
|
||||
Alert.ShowInTop("请至少选择记录,最大只可选择一条!", MessageBoxIcon.Warning);
|
||||
return;
|
||||
}
|
||||
var runningId = this.Grid1.Rows[Grid1.SelectedRowIndex].DataKeys[0].ToString();
|
||||
|
||||
string rootPath = Server.MapPath("~/") + Const.ExcelUrl;
|
||||
//导出文件
|
||||
string filePath = rootPath + DateTime.Now.ToString("yyyyMMddhhmmss") + "\\";
|
||||
if (!Directory.Exists(filePath))
|
||||
{
|
||||
Directory.CreateDirectory(filePath);
|
||||
}
|
||||
|
||||
var data = from a in Funs.DB.Running_LogManagement
|
||||
join b in Funs.DB.Base_Project on a.ProjectId equals b.ProjectId
|
||||
join c in Funs.DB.Sys_User on a.ShiftUser equals c.UserId
|
||||
join d in Funs.DB.Sys_User on a.SuccessionUser equals d.UserId
|
||||
where a.RunningId == runningId
|
||||
select new
|
||||
{
|
||||
a.RunningId,
|
||||
a.ProjectId,
|
||||
a.InstallationId,
|
||||
a.ProcessesId,
|
||||
a.SystemId,
|
||||
a.JobNo,
|
||||
a.ShiftType,
|
||||
ShiftTypeName = a.ShiftType == "1" ? "白班" : "夜班",
|
||||
a.ShiftUser,
|
||||
ShiftUserName = c.UserName,
|
||||
a.SuccessionUser,
|
||||
SuccessionUserName = d.UserName,
|
||||
a.StartData,
|
||||
a.EndData,
|
||||
a.IsDesalinated,
|
||||
a.DesalinatedSituation,
|
||||
a.DesalinatedRemarks,
|
||||
a.IsLoop,
|
||||
a.LoopSituation,
|
||||
a.LoopRemarks,
|
||||
a.IsSteam,
|
||||
a.SteamSituation,
|
||||
a.SteamRemarks,
|
||||
a.IsAirCompression,
|
||||
a.AirCompressionSituation,
|
||||
a.AirCompressionRemarks,
|
||||
a.IsCompoundAmmonia,
|
||||
a.CompoundAmmoniaSituation,
|
||||
a.CompoundAmmoniaRemarks,
|
||||
a.IsUrea,
|
||||
a.UreaSituation,
|
||||
a.UreaRemarks,
|
||||
a.HandoverCare,
|
||||
a.OperationReason,
|
||||
a.OperationHandle,
|
||||
a.MaintenanceReason,
|
||||
a.MaintenanceHandle,
|
||||
a.AddUser,
|
||||
a.AddTime,
|
||||
a.Sort
|
||||
};
|
||||
var model = data.FirstOrDefault();
|
||||
if (model != null)
|
||||
{
|
||||
string ReportFileName = $"{filePath}Production report({DateTime.Now.ToString("yyyy-MM-dd")} {model.ShiftUserName}).xlsx";
|
||||
int rowIndex = 0;
|
||||
XSSFWorkbook hssfworkbook = new XSSFWorkbook();
|
||||
XSSFSheet ws = (XSSFSheet)hssfworkbook.CreateSheet($"Production report({DateTime.Now.ToString("yyyy-MM-dd")} {model.ShiftUserName})");
|
||||
|
||||
#region 列宽
|
||||
|
||||
ws.SetColumnWidth(0, (9 * 256));
|
||||
ws.SetColumnWidth(1, (9 * 256));
|
||||
ws.SetColumnWidth(2, (43 * 256));
|
||||
ws.SetColumnWidth(3, (7 * 256));
|
||||
ws.SetColumnWidth(4, (8 * 256));
|
||||
ws.SetColumnWidth(5, (5 * 256));
|
||||
|
||||
#endregion
|
||||
|
||||
#region 样式
|
||||
//头部样式居中
|
||||
ICellStyle titleStyle = SetExcelStyle(hssfworkbook, BorderStyle.Thin, BorderStyle.Thin, BorderStyle.Thin, BorderStyle.Thin, VerticalAlignment.Center, HorizontalAlignment.Center, 14, true, true);
|
||||
//头部样式靠左
|
||||
ICellStyle leftTitleStyle = SetExcelStyle(hssfworkbook, BorderStyle.Thin, BorderStyle.Thin, BorderStyle.Thin, BorderStyle.Thin, VerticalAlignment.Center, HorizontalAlignment.Left, 14, true, true);
|
||||
//公共样式
|
||||
ICellStyle style = SetExcelStyle(hssfworkbook, BorderStyle.Thin, BorderStyle.Thin, BorderStyle.Thin, BorderStyle.Thin, VerticalAlignment.Center, HorizontalAlignment.Center, 10.5, true);
|
||||
//公共样式靠左
|
||||
ICellStyle leftStyle = SetExcelStyle(hssfworkbook, BorderStyle.Thin, BorderStyle.Thin, BorderStyle.Thin, BorderStyle.Thin, VerticalAlignment.Center, HorizontalAlignment.Left, 10.5, true);
|
||||
//公共样式靠左上对其
|
||||
ICellStyle leftTopStyle = SetExcelStyle(hssfworkbook, BorderStyle.Thin, BorderStyle.Thin, BorderStyle.Thin, BorderStyle.Thin, VerticalAlignment.Top, HorizontalAlignment.Left, 10.5, true);
|
||||
//公共样式加粗
|
||||
ICellStyle styleBold = SetExcelStyle(hssfworkbook, BorderStyle.Thin, BorderStyle.Thin, BorderStyle.Thin, BorderStyle.Thin, VerticalAlignment.Center, HorizontalAlignment.Center, 10.5, true, true);
|
||||
//公共样式靠左加粗
|
||||
ICellStyle styleLeftBold = SetExcelStyle(hssfworkbook, BorderStyle.Thin, BorderStyle.Thin, BorderStyle.Thin, BorderStyle.Thin, VerticalAlignment.Center, HorizontalAlignment.Left, 10.5, true, true);
|
||||
|
||||
#endregion
|
||||
|
||||
#region 头部
|
||||
|
||||
ws = ExcelCreateRowTitle(ws, hssfworkbook, style, rowIndex, rowIndex + 5, 0, 5);
|
||||
//行1
|
||||
var region = new CellRangeAddress(rowIndex, rowIndex + 3, 0, 1);
|
||||
ws.AddMergedRegion(region);
|
||||
ws.GetRow(rowIndex).GetCell(0).SetCellValue("WUHUAN ENGINEERING CO.,LTD");
|
||||
ws.GetRow(rowIndex).GetCell(0).CellStyle = titleStyle;
|
||||
ws.GetRow(rowIndex).GetCell(2).SetCellValue("PT PETROKIMIA GRESIK");
|
||||
ws.GetRow(rowIndex).GetCell(2).CellStyle = titleStyle;
|
||||
region = new CellRangeAddress(rowIndex, rowIndex, 3, 5);
|
||||
ws.AddMergedRegion(region);
|
||||
ws.GetRow(rowIndex).GetCell(3).SetCellValue("WUHUAN Job. No.");
|
||||
ws.GetRow(rowIndex).GetCell(3).CellStyle = styleBold;
|
||||
//行2
|
||||
ws.GetRow(rowIndex + 1).GetCell(2).SetCellValue("AMMONIA-Urea II PROJECT");
|
||||
ws.GetRow(rowIndex + 1).GetCell(2).CellStyle = titleStyle;
|
||||
region = new CellRangeAddress(rowIndex + 1, rowIndex + 1, 3, 5);
|
||||
ws.AddMergedRegion(region);
|
||||
//行3行4
|
||||
region = new CellRangeAddress(rowIndex + 2, rowIndex + 3, 2, 2);
|
||||
ws.AddMergedRegion(region);
|
||||
ws.GetRow(rowIndex + 2).GetCell(2).SetCellValue("Production report");
|
||||
ws.GetRow(rowIndex + 2).GetCell(2).CellStyle = titleStyle;
|
||||
region = new CellRangeAddress(rowIndex + 2, rowIndex + 3, 3, 5);
|
||||
ws.AddMergedRegion(region);
|
||||
ws.GetRow(rowIndex + 2).GetCell(3).SetCellValue("Page 1");
|
||||
ws.GetRow(rowIndex + 2).GetCell(3).CellStyle = titleStyle;
|
||||
//行5
|
||||
region = new CellRangeAddress(rowIndex + 4, rowIndex + 4, 0, 5);
|
||||
ws.AddMergedRegion(region);
|
||||
ws.GetRow(rowIndex + 4).GetCell(0).SetCellValue($"Shift:({model.ShiftUserName}) Succession:({model.SuccessionUserName}) {model.StartData.Value.ToString("yyyy-MM-dd")}— {model.EndData.Value.ToString("yyyy-MM-dd")}");
|
||||
ws.GetRow(rowIndex + 4).GetCell(0).CellStyle = styleBold;
|
||||
//行6
|
||||
region = new CellRangeAddress(rowIndex + 5, rowIndex + 5, 0, 3);
|
||||
ws.AddMergedRegion(region);
|
||||
ws.GetRow(rowIndex + 5).GetCell(0).SetCellValue("Operation situation");
|
||||
ws.GetRow(rowIndex + 5).GetCell(0).CellStyle = styleBold;
|
||||
region = new CellRangeAddress(rowIndex + 5, rowIndex + 5, 4, 5);
|
||||
ws.AddMergedRegion(region);
|
||||
ws.GetRow(rowIndex + 5).GetCell(4).SetCellValue("Remarks");
|
||||
ws.GetRow(rowIndex + 5).GetCell(4).CellStyle = styleBold;
|
||||
|
||||
#endregion
|
||||
|
||||
#region 数据
|
||||
|
||||
var dataIndex = 5;
|
||||
if (model.IsDesalinated == 1)
|
||||
{
|
||||
ws = ExcelCreateRowTitle(ws, hssfworkbook, style, dataIndex + 1, dataIndex + 1, 0, 5);
|
||||
region = new CellRangeAddress(dataIndex + 1, dataIndex + 1, 0, 3);
|
||||
ws.AddMergedRegion(region);
|
||||
ws.GetRow(dataIndex + 1).GetCell(0).SetCellValue("DW Station 脱盐水");
|
||||
ws.GetRow(dataIndex + 1).GetCell(0).CellStyle = styleLeftBold;
|
||||
region = new CellRangeAddress(dataIndex + 1, dataIndex + 1, 4, 5);
|
||||
ws.AddMergedRegion(region);
|
||||
ws.GetRow(dataIndex + 1).GetCell(4).SetCellValue("");
|
||||
ws.GetRow(dataIndex + 1).GetCell(4).CellStyle = leftStyle;
|
||||
ws = ExcelCreateRowTitle(ws, hssfworkbook, style, dataIndex + 2, dataIndex + 2, 0, 5, 90);
|
||||
region = new CellRangeAddress(dataIndex + 2, dataIndex + 2, 0, 3);
|
||||
ws.AddMergedRegion(region);
|
||||
ws.GetRow(dataIndex + 2).GetCell(0).SetCellValue(model.DesalinatedSituation);
|
||||
ws.GetRow(dataIndex + 2).GetCell(0).CellStyle = leftStyle;
|
||||
region = new CellRangeAddress(dataIndex + 2, dataIndex + 2, 4, 5);
|
||||
ws.AddMergedRegion(region);
|
||||
ws.GetRow(dataIndex + 2).GetCell(4).SetCellValue(model.DesalinatedRemarks);
|
||||
ws.GetRow(dataIndex + 2).GetCell(4).CellStyle = leftStyle;
|
||||
dataIndex += 2;
|
||||
}
|
||||
if (model.IsLoop == 1)
|
||||
{
|
||||
ws = ExcelCreateRowTitle(ws, hssfworkbook, style, dataIndex + 1, dataIndex + 1, 0, 5);
|
||||
region = new CellRangeAddress(dataIndex + 1, dataIndex + 1, 0, 3);
|
||||
ws.AddMergedRegion(region);
|
||||
ws.GetRow(dataIndex + 1).GetCell(0).SetCellValue("ACW/UCW/ECW Station 循环水");
|
||||
ws.GetRow(dataIndex + 1).GetCell(0).CellStyle = styleLeftBold;
|
||||
region = new CellRangeAddress(dataIndex + 1, dataIndex + 1, 4, 5);
|
||||
ws.AddMergedRegion(region);
|
||||
ws.GetRow(dataIndex + 1).GetCell(4).SetCellValue("");
|
||||
ws.GetRow(dataIndex + 1).GetCell(4).CellStyle = leftStyle;
|
||||
ws = ExcelCreateRowTitle(ws, hssfworkbook, style, dataIndex + 2, dataIndex + 2, 0, 5, 90);
|
||||
region = new CellRangeAddress(dataIndex + 2, dataIndex + 2, 0, 3);
|
||||
ws.AddMergedRegion(region);
|
||||
ws.GetRow(dataIndex + 2).GetCell(0).SetCellValue(model.LoopSituation);
|
||||
ws.GetRow(dataIndex + 2).GetCell(0).CellStyle = leftStyle;
|
||||
region = new CellRangeAddress(dataIndex + 2, dataIndex + 2, 4, 5);
|
||||
ws.AddMergedRegion(region);
|
||||
ws.GetRow(dataIndex + 2).GetCell(4).SetCellValue(model.LoopRemarks);
|
||||
ws.GetRow(dataIndex + 2).GetCell(4).CellStyle = leftStyle;
|
||||
dataIndex += 2;
|
||||
}
|
||||
if (model.IsSteam == 1)
|
||||
{
|
||||
ws = ExcelCreateRowTitle(ws, hssfworkbook, style, dataIndex + 1, dataIndex + 1, 0, 5);
|
||||
region = new CellRangeAddress(dataIndex + 1, dataIndex + 1, 0, 3);
|
||||
ws.AddMergedRegion(region);
|
||||
ws.GetRow(dataIndex + 1).GetCell(0).SetCellValue("Steam System蒸汽");
|
||||
ws.GetRow(dataIndex + 1).GetCell(0).CellStyle = styleLeftBold;
|
||||
region = new CellRangeAddress(dataIndex + 1, dataIndex + 1, 4, 5);
|
||||
ws.AddMergedRegion(region);
|
||||
ws.GetRow(dataIndex + 1).GetCell(4).SetCellValue("");
|
||||
ws.GetRow(dataIndex + 1).GetCell(4).CellStyle = leftStyle;
|
||||
ws = ExcelCreateRowTitle(ws, hssfworkbook, style, dataIndex + 2, dataIndex + 2, 0, 5, 90);
|
||||
region = new CellRangeAddress(dataIndex + 2, dataIndex + 2, 0, 3);
|
||||
ws.AddMergedRegion(region);
|
||||
ws.GetRow(dataIndex + 2).GetCell(0).SetCellValue(model.SteamSituation);
|
||||
ws.GetRow(dataIndex + 2).GetCell(0).CellStyle = leftStyle;
|
||||
region = new CellRangeAddress(dataIndex + 2, dataIndex + 2, 4, 5);
|
||||
ws.AddMergedRegion(region);
|
||||
ws.GetRow(dataIndex + 2).GetCell(4).SetCellValue(model.SteamRemarks);
|
||||
ws.GetRow(dataIndex + 2).GetCell(4).CellStyle = leftStyle;
|
||||
dataIndex += 2;
|
||||
}
|
||||
if (model.IsAirCompression == 1)
|
||||
{
|
||||
ws = ExcelCreateRowTitle(ws, hssfworkbook, style, dataIndex + 1, dataIndex + 1, 0, 5);
|
||||
region = new CellRangeAddress(dataIndex + 1, dataIndex + 1, 0, 3);
|
||||
ws.AddMergedRegion(region);
|
||||
ws.GetRow(dataIndex + 1).GetCell(0).SetCellValue("Air Station 空压站");
|
||||
ws.GetRow(dataIndex + 1).GetCell(0).CellStyle = styleLeftBold;
|
||||
region = new CellRangeAddress(dataIndex + 1, dataIndex + 1, 4, 5);
|
||||
ws.AddMergedRegion(region);
|
||||
ws.GetRow(dataIndex + 1).GetCell(4).SetCellValue("");
|
||||
ws.GetRow(dataIndex + 1).GetCell(4).CellStyle = leftStyle;
|
||||
ws = ExcelCreateRowTitle(ws, hssfworkbook, style, dataIndex + 2, dataIndex + 2, 0, 5, 90);
|
||||
region = new CellRangeAddress(dataIndex + 2, dataIndex + 2, 0, 3);
|
||||
ws.AddMergedRegion(region);
|
||||
ws.GetRow(dataIndex + 2).GetCell(0).SetCellValue(model.AirCompressionSituation);
|
||||
ws.GetRow(dataIndex + 2).GetCell(0).CellStyle = leftStyle;
|
||||
region = new CellRangeAddress(dataIndex + 2, dataIndex + 2, 4, 5);
|
||||
ws.AddMergedRegion(region);
|
||||
ws.GetRow(dataIndex + 2).GetCell(4).SetCellValue(model.AirCompressionRemarks);
|
||||
ws.GetRow(dataIndex + 2).GetCell(4).CellStyle = leftStyle;
|
||||
dataIndex += 2;
|
||||
}
|
||||
if (model.IsCompoundAmmonia == 1)
|
||||
{
|
||||
ws = ExcelCreateRowTitle(ws, hssfworkbook, style, dataIndex + 1, dataIndex + 1, 0, 5);
|
||||
region = new CellRangeAddress(dataIndex + 1, dataIndex + 1, 0, 3);
|
||||
ws.AddMergedRegion(region);
|
||||
ws.GetRow(dataIndex + 1).GetCell(0).SetCellValue("Ammonia Plant 合成氨");
|
||||
ws.GetRow(dataIndex + 1).GetCell(0).CellStyle = styleLeftBold;
|
||||
region = new CellRangeAddress(dataIndex + 1, dataIndex + 1, 4, 5);
|
||||
ws.AddMergedRegion(region);
|
||||
ws.GetRow(dataIndex + 1).GetCell(4).SetCellValue("");
|
||||
ws.GetRow(dataIndex + 1).GetCell(4).CellStyle = leftStyle;
|
||||
ws = ExcelCreateRowTitle(ws, hssfworkbook, style, dataIndex + 2, dataIndex + 2, 0, 5, 90);
|
||||
region = new CellRangeAddress(dataIndex + 2, dataIndex + 2, 0, 3);
|
||||
ws.AddMergedRegion(region);
|
||||
ws.GetRow(dataIndex + 2).GetCell(0).SetCellValue(model.CompoundAmmoniaSituation);
|
||||
ws.GetRow(dataIndex + 2).GetCell(0).CellStyle = leftStyle;
|
||||
region = new CellRangeAddress(dataIndex + 2, dataIndex + 2, 4, 5);
|
||||
ws.AddMergedRegion(region);
|
||||
ws.GetRow(dataIndex + 2).GetCell(4).SetCellValue(model.CompoundAmmoniaRemarks);
|
||||
ws.GetRow(dataIndex + 2).GetCell(4).CellStyle = leftStyle;
|
||||
dataIndex += 2;
|
||||
}
|
||||
if (model.IsUrea == 1)
|
||||
{
|
||||
ws = ExcelCreateRowTitle(ws, hssfworkbook, style, dataIndex + 1, dataIndex + 1, 0, 5);
|
||||
region = new CellRangeAddress(dataIndex + 1, dataIndex + 1, 0, 3);
|
||||
ws.AddMergedRegion(region);
|
||||
ws.GetRow(dataIndex + 1).GetCell(0).SetCellValue("Urea Plant 尿素");
|
||||
ws.GetRow(dataIndex + 1).GetCell(0).CellStyle = styleLeftBold;
|
||||
region = new CellRangeAddress(dataIndex + 1, dataIndex + 1, 4, 5);
|
||||
ws.AddMergedRegion(region);
|
||||
ws.GetRow(dataIndex + 1).GetCell(4).SetCellValue("");
|
||||
ws.GetRow(dataIndex + 1).GetCell(4).CellStyle = leftStyle;
|
||||
ws = ExcelCreateRowTitle(ws, hssfworkbook, style, dataIndex + 2, dataIndex + 2, 0, 5, 90);
|
||||
region = new CellRangeAddress(dataIndex + 2, dataIndex + 2, 0, 3);
|
||||
ws.AddMergedRegion(region);
|
||||
ws.GetRow(dataIndex + 2).GetCell(0).SetCellValue(model.UreaSituation);
|
||||
ws.GetRow(dataIndex + 2).GetCell(0).CellStyle = leftStyle;
|
||||
region = new CellRangeAddress(dataIndex + 2, dataIndex + 2, 4, 5);
|
||||
ws.AddMergedRegion(region);
|
||||
ws.GetRow(dataIndex + 2).GetCell(4).SetCellValue(model.UreaRemarks);
|
||||
ws.GetRow(dataIndex + 2).GetCell(4).CellStyle = leftStyle;
|
||||
dataIndex += 2;
|
||||
}
|
||||
ws = ExcelCreateRowTitle(ws, hssfworkbook, style, dataIndex + 1, dataIndex + 1, 0, 5);
|
||||
region = new CellRangeAddress(dataIndex + 1, dataIndex + 1, 0, 5);
|
||||
ws.AddMergedRegion(region);
|
||||
ws.GetRow(dataIndex + 1).GetCell(0).SetCellValue("Attention of next shift交班注意");
|
||||
ws.GetRow(dataIndex + 1).GetCell(0).CellStyle = styleLeftBold;
|
||||
ws = ExcelCreateRowTitle(ws, hssfworkbook, style, dataIndex + 2, dataIndex + 2, 0, 5, 30);
|
||||
region = new CellRangeAddress(dataIndex + 2, dataIndex + 2, 0, 5);
|
||||
ws.AddMergedRegion(region);
|
||||
ws.GetRow(dataIndex + 2).GetCell(0).SetCellValue(model.HandoverCare);
|
||||
ws.GetRow(dataIndex + 2).GetCell(0).CellStyle = leftStyle;
|
||||
dataIndex += 2;
|
||||
ws = ExcelCreateRowTitle(ws, hssfworkbook, style, dataIndex + 1, dataIndex + 1, 0, 5);
|
||||
region = new CellRangeAddress(dataIndex + 1, dataIndex + 1, 0, 5);
|
||||
ws.AddMergedRegion(region);
|
||||
ws.GetRow(dataIndex + 1).GetCell(0).SetCellValue("operation issue操作问题");
|
||||
ws.GetRow(dataIndex + 1).GetCell(0).CellStyle = styleLeftBold;
|
||||
ws = ExcelCreateRowTitle(ws, hssfworkbook, style, dataIndex + 2, dataIndex + 2, 0, 5, 30);
|
||||
region = new CellRangeAddress(dataIndex + 2, dataIndex + 2, 0, 5);
|
||||
ws.AddMergedRegion(region);
|
||||
ws.GetRow(dataIndex + 2).GetCell(0).SetCellValue($"reason原因:{model.OperationReason}");
|
||||
ws.GetRow(dataIndex + 2).GetCell(0).CellStyle = leftStyle;
|
||||
ws = ExcelCreateRowTitle(ws, hssfworkbook, style, dataIndex + 3, dataIndex + 3, 0, 5, 30);
|
||||
region = new CellRangeAddress(dataIndex + 3, dataIndex + 3, 0, 5);
|
||||
ws.AddMergedRegion(region);
|
||||
ws.GetRow(dataIndex + 3).GetCell(0).SetCellValue($"solution处理:{model.OperationHandle}");
|
||||
ws.GetRow(dataIndex + 3).GetCell(0).CellStyle = leftStyle;
|
||||
dataIndex += 3;
|
||||
ws = ExcelCreateRowTitle(ws, hssfworkbook, style, dataIndex + 1, dataIndex + 1, 0, 5);
|
||||
region = new CellRangeAddress(dataIndex + 1, dataIndex + 1, 0, 5);
|
||||
ws.AddMergedRegion(region);
|
||||
ws.GetRow(dataIndex + 1).GetCell(0).SetCellValue("maintenance issue维护问题");
|
||||
ws.GetRow(dataIndex + 1).GetCell(0).CellStyle = styleLeftBold;
|
||||
ws = ExcelCreateRowTitle(ws, hssfworkbook, style, dataIndex + 2, dataIndex + 2, 0, 5, 30);
|
||||
region = new CellRangeAddress(dataIndex + 2, dataIndex + 2, 0, 5);
|
||||
ws.AddMergedRegion(region);
|
||||
ws.GetRow(dataIndex + 2).GetCell(0).SetCellValue($"reason原因:{model.MaintenanceReason}");
|
||||
ws.GetRow(dataIndex + 2).GetCell(0).CellStyle = leftStyle;
|
||||
ws = ExcelCreateRowTitle(ws, hssfworkbook, style, dataIndex + 3, dataIndex + 3, 0, 5, 30);
|
||||
region = new CellRangeAddress(dataIndex + 3, dataIndex + 3, 0, 5);
|
||||
ws.AddMergedRegion(region);
|
||||
ws.GetRow(dataIndex + 3).GetCell(0).SetCellValue($"solution处理:{model.MaintenanceHandle}");
|
||||
ws.GetRow(dataIndex + 3).GetCell(0).CellStyle = leftStyle;
|
||||
dataIndex += 3;
|
||||
#endregion
|
||||
|
||||
ws.PrintSetup.Landscape = false;
|
||||
ws.PrintSetup.PaperSize = 9;
|
||||
ws.ForceFormulaRecalculation = true;
|
||||
using (FileStream filess = File.OpenWrite(ReportFileName))
|
||||
{
|
||||
hssfworkbook.Write(filess);
|
||||
}
|
||||
FileInfo filet = new FileInfo(ReportFileName);
|
||||
Response.Clear();
|
||||
Response.Charset = "GB2312";
|
||||
Response.ContentEncoding = System.Text.Encoding.UTF8;
|
||||
// 添加头信息,为"文件下载/另存为"对话框指定默认文件名
|
||||
Response.AddHeader("Content-Disposition", "attachment; filename=" + Server.UrlEncode($"Production report({DateTime.Now.ToString("yyyy-MM-dd")} {model.ShiftUserName}).xlsx"));
|
||||
// 添加头信息,指定文件大小,让浏览器能够显示下载进度
|
||||
Response.AddHeader("Content-Length", filet.Length.ToString());
|
||||
// 指定返回的是一个不能被客户端读取的流,必须被下载
|
||||
Response.ContentType = "application/ms-excel";
|
||||
// 把文件流发送到客户端
|
||||
Response.WriteFile(filet.FullName);
|
||||
// 停止页面的执行
|
||||
Response.End();
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
///右击修改
|
||||
/// </summary>
|
||||
protected void btnMenuModify_Click(object sender, EventArgs e)
|
||||
{
|
||||
btnModify_Click(null, null);
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
|
||||
#region 私有方法
|
||||
|
||||
/// <summary>
|
||||
/// 创建样式
|
||||
/// </summary>
|
||||
/// <returns></returns>
|
||||
public static ICellStyle SetExcelStyle(XSSFWorkbook wb, BorderStyle Bottom, BorderStyle Left, BorderStyle Right, BorderStyle Top, VerticalAlignment VerAig, HorizontalAlignment HorAig, double FontSize, bool WrapText = true, bool Bold = false, string FontName = "宋体")
|
||||
{
|
||||
ICellStyle style = wb.CreateCellStyle();
|
||||
style.BorderBottom = Bottom;
|
||||
style.BorderLeft = Left;
|
||||
style.BorderRight = Right;
|
||||
style.BorderTop = Top;
|
||||
style.VerticalAlignment = VerAig;
|
||||
style.Alignment = HorAig;
|
||||
IFont font = wb.CreateFont();
|
||||
font.FontHeightInPoints = FontSize;
|
||||
font.IsBold = Bold;
|
||||
font.FontName = FontName;
|
||||
style.SetFont(font);
|
||||
style.WrapText = WrapText;
|
||||
return style;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 创建头部
|
||||
/// </summary>
|
||||
/// <returns></returns>
|
||||
private XSSFSheet ExcelCreateRowTitle(XSSFSheet ws, XSSFWorkbook hssfworkbook, ICellStyle style, int sRows, int eRows, int cStart, int cEnd, float height = 21)
|
||||
{
|
||||
for (int i = sRows; i <= eRows; i++)
|
||||
{
|
||||
ws.CreateRow(i);
|
||||
ws.GetRow(i).HeightInPoints = height;
|
||||
for (int j = cStart; j <= cEnd; j++)
|
||||
{
|
||||
ws.GetRow(i).CreateCell(j);
|
||||
ws.GetRow(i).CreateCell(j).CellStyle = style;
|
||||
}
|
||||
}
|
||||
return ws;
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
}
|
||||
}
|
188
SGGL/FineUIPro.Web/TestRun/ProduceTestRun/RunningLogManagementList.aspx.designer.cs
generated
Normal file
188
SGGL/FineUIPro.Web/TestRun/ProduceTestRun/RunningLogManagementList.aspx.designer.cs
generated
Normal file
|
@ -0,0 +1,188 @@
|
|||
//------------------------------------------------------------------------------
|
||||
// <自动生成>
|
||||
// 此代码由工具生成。
|
||||
//
|
||||
// 对此文件的更改可能导致不正确的行为,如果
|
||||
// 重新生成代码,则所做更改将丢失。
|
||||
// </自动生成>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace FineUIPro.Web.TestRun.ProduceTestRun
|
||||
{
|
||||
|
||||
|
||||
public partial class RunningLogManagementList
|
||||
{
|
||||
|
||||
/// <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>
|
||||
/// panelLeftRegion 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Panel panelLeftRegion;
|
||||
|
||||
/// <summary>
|
||||
/// tvControlItem 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Tree tvControlItem;
|
||||
|
||||
/// <summary>
|
||||
/// Grid1 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Grid Grid1;
|
||||
|
||||
/// <summary>
|
||||
/// Toolbar1 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Toolbar Toolbar1;
|
||||
|
||||
/// <summary>
|
||||
/// ddlShiftType 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.DropDownList ddlShiftType;
|
||||
|
||||
/// <summary>
|
||||
/// btnQuery 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Button btnQuery;
|
||||
|
||||
/// <summary>
|
||||
/// btnAdd 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Button btnAdd;
|
||||
|
||||
/// <summary>
|
||||
/// btnModify 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Button btnModify;
|
||||
|
||||
/// <summary>
|
||||
/// btnDel 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Button btnDel;
|
||||
|
||||
/// <summary>
|
||||
/// btnExport 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Button btnExport;
|
||||
|
||||
/// <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;
|
||||
|
||||
/// <summary>
|
||||
/// Window1 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Window Window1;
|
||||
|
||||
/// <summary>
|
||||
/// Menu1 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Menu Menu1;
|
||||
|
||||
/// <summary>
|
||||
/// btnMenuModify 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.MenuButton btnMenuModify;
|
||||
}
|
||||
}
|
Loading…
Reference in New Issue