diff --git a/DataBase/版本日志/SGGLDB_WH_2024-01-26-gaofei.sql b/DataBase/版本日志/SGGLDB_WH_2024-01-26-gaofei.sql
index a884ec35..89ae6984 100644
--- a/DataBase/版本日志/SGGLDB_WH_2024-01-26-gaofei.sql
+++ b/DataBase/版本日志/SGGLDB_WH_2024-01-26-gaofei.sql
@@ -27,6 +27,31 @@ EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'ProjectSetup'
GO
+CREATE TABLE [dbo].[Transfer_Piping](
+ [Id] [nvarchar](50) NOT NULL,
+ [ProjectId] [nvarchar](50) NULL,
+ [PIPINGLINENUMBER] [nvarchar](50) NULL,
+ [SYSTEM] [nvarchar](50) NULL,
+ [Subsystem] [nvarchar](50) NULL,
+ [TestPackage] [nvarchar](50) NULL,
+ [TestPackageSTART] [datetime] NULL,
+ [TestPackageFINISH] [datetime] NULL,
+ [FINALStatus] [nvarchar](50) NULL,
+ [PreTestFINISHED] [nvarchar](50) NULL,
+ [FinalTestFINISHED] [nvarchar](50) NULL,
+ CONSTRAINT [PK_Transfer_Piping] PRIMARY KEY CLUSTERED
+(
+ [Id] 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
+
+EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Piping' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'Transfer_Piping'
+GO
+
+
+
diff --git a/SGGL/BLL/BLL.csproj b/SGGL/BLL/BLL.csproj
index e8e85809..541c99ef 100644
--- a/SGGL/BLL/BLL.csproj
+++ b/SGGL/BLL/BLL.csproj
@@ -767,6 +767,7 @@
+
diff --git a/SGGL/BLL/Common/Const.cs b/SGGL/BLL/Common/Const.cs
index cd88e993..daf4207e 100644
--- a/SGGL/BLL/Common/Const.cs
+++ b/SGGL/BLL/Common/Const.cs
@@ -3206,6 +3206,10 @@ namespace BLL
/// 开车方案编制计划模板文件原始虚拟路径
///
public const string SchemePlan2TemplateUrl = "File\\Excel\\TestRun\\开车方案编制计划2.xlsx";
+ ///
+ /// ProjectSetup导入模版文件原始的虚拟路径
+ ///
+ public const string ProjectSetupDataInUrl = "File\\Excel\\DataIn\\Project Set up导入模板.xls";
#endregion
#region 绩效考核模板文件路径
diff --git a/SGGL/BLL/Transfer/PipingService.cs b/SGGL/BLL/Transfer/PipingService.cs
new file mode 100644
index 00000000..18c4dde1
--- /dev/null
+++ b/SGGL/BLL/Transfer/PipingService.cs
@@ -0,0 +1,83 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+using System.Threading.Tasks;
+
+namespace BLL
+{
+ public class PipingService
+ {
+ ///
+ /// 根据主键获取设备材料报验信息
+ ///
+ ///
+ ///
+ public static Model.Transfer_Piping GetPipingById(string Id)
+ {
+ return Funs.DB.Transfer_Piping.FirstOrDefault(e => e.Id == Id);
+ }
+
+ ///
+ /// 添加设备材料报验
+ ///
+ ///
+ public static void AddPiping(Model.Transfer_Piping Piping)
+ {
+ Model.SGGLDB db = Funs.DB;
+ Model.Transfer_Piping newPiping = new Model.Transfer_Piping();
+ newPiping.Id = Piping.Id;
+ newPiping.ProjectId = Piping.ProjectId;
+ newPiping.PIPINGLINENUMBER = Piping.PIPINGLINENUMBER;
+ newPiping.SYSTEM = Piping.SYSTEM;
+ newPiping.Subsystem = Piping.Subsystem;
+ newPiping.TestPackage = Piping.TestPackage;
+ newPiping.TestPackageSTART = Piping.TestPackageSTART;
+ newPiping.TestPackageFINISH = Piping.TestPackageFINISH;
+ newPiping.FINALStatus = Piping.FINALStatus;
+ newPiping.PreTestFINISHED = Piping.PreTestFINISHED;
+ newPiping.FinalTestFINISHED = Piping.FinalTestFINISHED;
+ db.Transfer_Piping.InsertOnSubmit(newPiping);
+ db.SubmitChanges();
+ }
+
+ ///
+ /// 修改设备材料报验
+ ///
+ ///
+ public static void UpdatePiping(Model.Transfer_Piping Piping)
+ {
+ Model.SGGLDB db = Funs.DB;
+ Model.Transfer_Piping newPiping = db.Transfer_Piping.FirstOrDefault(e => e.Id == Piping.Id);
+ if (newPiping != null)
+ {
+ newPiping.ProjectId = Piping.ProjectId;
+ newPiping.PIPINGLINENUMBER = Piping.PIPINGLINENUMBER;
+ newPiping.SYSTEM = Piping.SYSTEM;
+ newPiping.Subsystem = Piping.Subsystem;
+ newPiping.TestPackage = Piping.TestPackage;
+ newPiping.TestPackageSTART = Piping.TestPackageSTART;
+ newPiping.TestPackageFINISH = Piping.TestPackageFINISH;
+ newPiping.FINALStatus = Piping.FINALStatus;
+ newPiping.PreTestFINISHED = Piping.PreTestFINISHED;
+ newPiping.FinalTestFINISHED = Piping.FinalTestFINISHED;
+ db.SubmitChanges();
+ }
+ }
+
+ ///
+ /// 根据主键删除设备材料报验
+ ///
+ ///
+ public static void DeletePiping(string Id)
+ {
+ Model.SGGLDB db = Funs.DB;
+ Model.Transfer_Piping Piping = db.Transfer_Piping.FirstOrDefault(e => e.Id == Id);
+ if (Piping != null)
+ {
+ db.Transfer_Piping.DeleteOnSubmit(Piping);
+ db.SubmitChanges();
+ }
+ }
+ }
+}
diff --git a/SGGL/FineUIPro.Web/ErrLog.txt b/SGGL/FineUIPro.Web/ErrLog.txt
index 9b1ca355..40871f48 100644
--- a/SGGL/FineUIPro.Web/ErrLog.txt
+++ b/SGGL/FineUIPro.Web/ErrLog.txt
@@ -355,3 +355,103 @@ IP地址:::1
出错时间:01/26/2024 09:47:58
+
+错误信息开始=====>
+错误类型:ArgumentException
+错误信息:提供的 URI 方案“http”无效,应为“https”。
+参数名: via
+错误堆栈:
+ 在 System.ServiceModel.Channels.TransportChannelFactory`1.ValidateScheme(Uri via)
+ 在 System.ServiceModel.Channels.HttpChannelFactory`1.ValidateCreateChannelParameters(EndpointAddress remoteAddress, Uri via)
+ 在 System.ServiceModel.Channels.HttpsChannelFactory`1.ValidateCreateChannelParameters(EndpointAddress remoteAddress, Uri via)
+ 在 System.ServiceModel.Channels.HttpsChannelFactory`1.OnCreateChannelCore(EndpointAddress address, Uri via)
+ 在 System.ServiceModel.Channels.HttpChannelFactory`1.OnCreateChannel(EndpointAddress remoteAddress, Uri via)
+ 在 System.ServiceModel.Channels.ChannelFactoryBase`1.InternalCreateChannel(EndpointAddress address, Uri via)
+ 在 System.ServiceModel.Channels.ChannelFactoryBase`1.CreateChannel(EndpointAddress address, Uri via)
+ 在 System.ServiceModel.Channels.ServiceChannelFactory.ServiceChannelFactoryOverRequest.CreateInnerChannelBinder(EndpointAddress to, Uri via)
+ 在 System.ServiceModel.Channels.ServiceChannelFactory.CreateServiceChannel(EndpointAddress address, Uri via)
+ 在 System.ServiceModel.Channels.ServiceChannelFactory.CreateChannel(Type channelType, EndpointAddress address, Uri via)
+ 在 System.ServiceModel.ChannelFactory`1.CreateChannel(EndpointAddress address, Uri via)
+ 在 System.ServiceModel.ChannelFactory`1.CreateChannel()
+ 在 System.ServiceModel.ClientBase`1.CreateChannel()
+ 在 System.ServiceModel.ClientBase`1.CreateChannelInternal()
+ 在 System.ServiceModel.ClientBase`1.get_Channel()
+ 在 BLL.CNCECHSSEWebService.getSupervise_SubUnitReport() 位置 E:\工作\五环施工平台\CNCEC_SUBQHSE_WUHUAN\SGGL\BLL\WebService\CNCECHSSEWebService.cs:行号 2180
+出错时间:01/26/2024 12:55:46
+出错时间:01/26/2024 12:55:46
+
+
+错误信息开始=====>
+错误类型:ArgumentException
+错误信息:提供的 URI 方案“http”无效,应为“https”。
+参数名: via
+错误堆栈:
+ 在 System.ServiceModel.Channels.TransportChannelFactory`1.ValidateScheme(Uri via)
+ 在 System.ServiceModel.Channels.HttpChannelFactory`1.ValidateCreateChannelParameters(EndpointAddress remoteAddress, Uri via)
+ 在 System.ServiceModel.Channels.HttpsChannelFactory`1.ValidateCreateChannelParameters(EndpointAddress remoteAddress, Uri via)
+ 在 System.ServiceModel.Channels.HttpsChannelFactory`1.OnCreateChannelCore(EndpointAddress address, Uri via)
+ 在 System.ServiceModel.Channels.HttpChannelFactory`1.OnCreateChannel(EndpointAddress remoteAddress, Uri via)
+ 在 System.ServiceModel.Channels.ChannelFactoryBase`1.InternalCreateChannel(EndpointAddress address, Uri via)
+ 在 System.ServiceModel.Channels.ChannelFactoryBase`1.CreateChannel(EndpointAddress address, Uri via)
+ 在 System.ServiceModel.Channels.ServiceChannelFactory.ServiceChannelFactoryOverRequest.CreateInnerChannelBinder(EndpointAddress to, Uri via)
+ 在 System.ServiceModel.Channels.ServiceChannelFactory.CreateServiceChannel(EndpointAddress address, Uri via)
+ 在 System.ServiceModel.Channels.ServiceChannelFactory.CreateChannel(Type channelType, EndpointAddress address, Uri via)
+ 在 System.ServiceModel.ChannelFactory`1.CreateChannel(EndpointAddress address, Uri via)
+ 在 System.ServiceModel.ChannelFactory`1.CreateChannel()
+ 在 System.ServiceModel.ClientBase`1.CreateChannel()
+ 在 System.ServiceModel.ClientBase`1.CreateChannelInternal()
+ 在 System.ServiceModel.ClientBase`1.get_Channel()
+ 在 BLL.CNCECHSSEWebService.getCheck_CheckInfo_Table8Item() 位置 E:\工作\五环施工平台\CNCEC_SUBQHSE_WUHUAN\SGGL\BLL\WebService\CNCECHSSEWebService.cs:行号 2045
+出错时间:01/26/2024 12:55:46
+出错时间:01/26/2024 12:55:46
+
+
+错误信息开始=====>
+错误类型:ArgumentException
+错误信息:提供的 URI 方案“http”无效,应为“https”。
+参数名: via
+错误堆栈:
+ 在 System.ServiceModel.Channels.TransportChannelFactory`1.ValidateScheme(Uri via)
+ 在 System.ServiceModel.Channels.HttpChannelFactory`1.ValidateCreateChannelParameters(EndpointAddress remoteAddress, Uri via)
+ 在 System.ServiceModel.Channels.HttpsChannelFactory`1.ValidateCreateChannelParameters(EndpointAddress remoteAddress, Uri via)
+ 在 System.ServiceModel.Channels.HttpsChannelFactory`1.OnCreateChannelCore(EndpointAddress address, Uri via)
+ 在 System.ServiceModel.Channels.HttpChannelFactory`1.OnCreateChannel(EndpointAddress remoteAddress, Uri via)
+ 在 System.ServiceModel.Channels.ChannelFactoryBase`1.InternalCreateChannel(EndpointAddress address, Uri via)
+ 在 System.ServiceModel.Channels.ChannelFactoryBase`1.CreateChannel(EndpointAddress address, Uri via)
+ 在 System.ServiceModel.Channels.ServiceChannelFactory.ServiceChannelFactoryOverRequest.CreateInnerChannelBinder(EndpointAddress to, Uri via)
+ 在 System.ServiceModel.Channels.ServiceChannelFactory.CreateServiceChannel(EndpointAddress address, Uri via)
+ 在 System.ServiceModel.Channels.ServiceChannelFactory.CreateChannel(Type channelType, EndpointAddress address, Uri via)
+ 在 System.ServiceModel.ChannelFactory`1.CreateChannel(EndpointAddress address, Uri via)
+ 在 System.ServiceModel.ChannelFactory`1.CreateChannel()
+ 在 System.ServiceModel.ClientBase`1.CreateChannel()
+ 在 System.ServiceModel.ClientBase`1.CreateChannelInternal()
+ 在 System.ServiceModel.ClientBase`1.get_Channel()
+ 在 BLL.CNCECHSSEWebService.getCheck_CheckRectify() 位置 E:\工作\五环施工平台\CNCEC_SUBQHSE_WUHUAN\SGGL\BLL\WebService\CNCECHSSEWebService.cs:行号 1941
+出错时间:01/26/2024 12:55:46
+出错时间:01/26/2024 12:55:46
+
+
+错误信息开始=====>
+错误类型:ArgumentException
+错误信息:提供的 URI 方案“http”无效,应为“https”。
+参数名: via
+错误堆栈:
+ 在 System.ServiceModel.Channels.TransportChannelFactory`1.ValidateScheme(Uri via)
+ 在 System.ServiceModel.Channels.HttpChannelFactory`1.ValidateCreateChannelParameters(EndpointAddress remoteAddress, Uri via)
+ 在 System.ServiceModel.Channels.HttpsChannelFactory`1.ValidateCreateChannelParameters(EndpointAddress remoteAddress, Uri via)
+ 在 System.ServiceModel.Channels.HttpsChannelFactory`1.OnCreateChannelCore(EndpointAddress address, Uri via)
+ 在 System.ServiceModel.Channels.HttpChannelFactory`1.OnCreateChannel(EndpointAddress remoteAddress, Uri via)
+ 在 System.ServiceModel.Channels.ChannelFactoryBase`1.InternalCreateChannel(EndpointAddress address, Uri via)
+ 在 System.ServiceModel.Channels.ChannelFactoryBase`1.CreateChannel(EndpointAddress address, Uri via)
+ 在 System.ServiceModel.Channels.ServiceChannelFactory.ServiceChannelFactoryOverRequest.CreateInnerChannelBinder(EndpointAddress to, Uri via)
+ 在 System.ServiceModel.Channels.ServiceChannelFactory.CreateServiceChannel(EndpointAddress address, Uri via)
+ 在 System.ServiceModel.Channels.ServiceChannelFactory.CreateChannel(Type channelType, EndpointAddress address, Uri via)
+ 在 System.ServiceModel.ChannelFactory`1.CreateChannel(EndpointAddress address, Uri via)
+ 在 System.ServiceModel.ChannelFactory`1.CreateChannel()
+ 在 System.ServiceModel.ClientBase`1.CreateChannel()
+ 在 System.ServiceModel.ClientBase`1.CreateChannelInternal()
+ 在 System.ServiceModel.ClientBase`1.get_Channel()
+ 在 BLL.CNCECHSSEWebService.getInformation_UrgeReport() 位置 E:\工作\五环施工平台\CNCEC_SUBQHSE_WUHUAN\SGGL\BLL\WebService\CNCECHSSEWebService.cs:行号 1883
+出错时间:01/26/2024 12:55:46
+出错时间:01/26/2024 12:55:46
+
diff --git a/SGGL/FineUIPro.Web/File/Excel/DataIn/Project Set up导入模板.xls b/SGGL/FineUIPro.Web/File/Excel/DataIn/Project Set up导入模板.xls
new file mode 100644
index 00000000..8f5c6e0d
Binary files /dev/null and b/SGGL/FineUIPro.Web/File/Excel/DataIn/Project Set up导入模板.xls differ
diff --git a/SGGL/FineUIPro.Web/FineUIPro.Web.csproj b/SGGL/FineUIPro.Web/FineUIPro.Web.csproj
index f4d327e2..eb338935 100644
--- a/SGGL/FineUIPro.Web/FineUIPro.Web.csproj
+++ b/SGGL/FineUIPro.Web/FineUIPro.Web.csproj
@@ -1826,7 +1826,9 @@
+
+
@@ -16298,6 +16300,13 @@
TestRunRecordUploadList.aspx
+
+ Piping.aspx
+ ASPXCodeBehind
+
+
+ Piping.aspx
+
ProjectSetup.aspx
ASPXCodeBehind
@@ -16305,6 +16314,13 @@
ProjectSetup.aspx
+
+ ProjectSetupDataIn.aspx
+ ASPXCodeBehind
+
+
+ ProjectSetupDataIn.aspx
+
Video.aspx
ASPXCodeBehind
diff --git a/SGGL/FineUIPro.Web/Transfer/Piping.aspx b/SGGL/FineUIPro.Web/Transfer/Piping.aspx
new file mode 100644
index 00000000..f80d2b82
--- /dev/null
+++ b/SGGL/FineUIPro.Web/Transfer/Piping.aspx
@@ -0,0 +1,129 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="Piping.aspx.cs" Inherits="FineUIPro.Web.Transfer.Piping" %>
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/SGGL/FineUIPro.Web/Transfer/Piping.aspx.cs b/SGGL/FineUIPro.Web/Transfer/Piping.aspx.cs
new file mode 100644
index 00000000..09da90ac
--- /dev/null
+++ b/SGGL/FineUIPro.Web/Transfer/Piping.aspx.cs
@@ -0,0 +1,208 @@
+using BLL;
+using BLL.CQMS.Comprehensive;
+using System;
+using System.Collections.Generic;
+using System.Data;
+using System.Data.SqlClient;
+using System.Linq;
+
+namespace FineUIPro.Web.Transfer
+{
+ public partial class Piping : PageBase
+ {
+ #region 加载
+ ///
+ /// 加载页面
+ ///
+ ///
+ ///
+ protected void Page_Load(object sender, EventArgs e)
+ {
+ if (!IsPostBack)
+ {
+ GetButtonPower();
+ BindGrid();
+ }
+ }
+
+ ///
+ /// 数据绑定
+ ///
+ public void BindGrid()
+ {
+ string strSql = @"select * from Transfer_ProjectSetup C
+ where C.ProjectId = @ProjectId";
+ List listStr = new List();
+ listStr.Add(new SqlParameter("@ProjectId", this.CurrUser.LoginProjectId));
+ 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();
+ }
+ #endregion
+
+ #region 分页、排序
+ ///
+ /// 分页下拉
+ ///
+ ///
+ ///
+ protected void ddlPageSize_SelectedIndexChanged(object sender, EventArgs e)
+ {
+ Grid1.PageSize = Convert.ToInt32(ddlPageSize.SelectedValue);
+ BindGrid();
+ }
+
+ ///
+ /// 分页索引事件
+ ///
+ ///
+ ///
+ protected void Grid1_PageIndexChange(object sender, GridPageEventArgs e)
+ {
+ BindGrid();
+ }
+
+ ///
+ /// 排序
+ ///
+ ///
+ ///
+ protected void Grid1_Sort(object sender, FineUIPro.GridSortEventArgs e)
+ {
+ Grid1.SortDirection = e.SortDirection;
+ Grid1.SortField = e.SortField;
+ BindGrid();
+ }
+ #endregion
+
+ #region 查询
+ ///
+ /// 查询
+ ///
+ ///
+ ///
+ protected void btnSearch_Click(object sender, EventArgs e)
+ {
+ BindGrid();
+ }
+ #endregion
+
+ #region 关闭弹出窗口
+ ///
+ /// 关闭弹出窗口
+ ///
+ ///
+ ///
+ protected void Window1_Close(object sender, WindowCloseEventArgs e)
+ {
+ BindGrid();
+ }
+ #endregion
+
+ #region 增加
+ ///
+ /// 新增按钮事件
+ ///
+ ///
+ ///
+ protected void btnNew_Click(object sender, EventArgs e)
+ {
+ PageContext.RegisterStartupScript(Window1.GetShowReference(String.Format("InspectionEquipmentEdit.aspx", "编辑 - ")));
+ }
+ #endregion
+
+ #region 编辑
+ ///
+ /// 右键编辑
+ ///
+ ///
+ ///
+ protected void btnMenuModify_Click(object sender, EventArgs e)
+ {
+ if (Grid1.SelectedRowIndexArray.Length == 0)
+ {
+ Alert.ShowInTop("请至少选择一条记录", MessageBoxIcon.Warning);
+ return;
+ }
+ PageContext.RegisterStartupScript(Window1.GetShowReference(String.Format("InspectionEquipmentEdit.aspx?InspectionEquipmentId={0}", Grid1.SelectedRowID, "编辑 - ")));
+ }
+
+ ///
+ /// Grid行双击事件
+ ///
+ ///
+ ///
+ protected void Grid1_RowDoubleClick(object sender, GridRowClickEventArgs e)
+ {
+ this.btnMenuModify_Click(sender, e);
+ }
+ #endregion
+
+ #region 删除
+ ///
+ /// 右键删除
+ ///
+ ///
+ ///
+ protected void btnMenuDel_Click(object sender, EventArgs e)
+ {
+ if (Grid1.SelectedRowIndexArray.Length > 0)
+ {
+ foreach (int rowIndex in Grid1.SelectedRowIndexArray)
+ {
+ string rowID = Grid1.DataKeys[rowIndex][0].ToString();
+ var data = BLL.ProjectSetupService.GetProjectSetupById(rowID);
+ if (data != null)
+ {
+ BLL.ProjectSetupService.DeleteProjectSetup(rowID);
+ }
+ }
+ BindGrid();
+ ShowNotify("删除数据成功!", MessageBoxIcon.Success);
+ }
+ }
+ #endregion
+
+ #region 导入
+ ///
+ /// 导入按钮
+ ///
+ ///
+ ///
+ protected void btnImport_Click(object sender, EventArgs e)
+ {
+ PageContext.RegisterStartupScript(Window2.GetShowReference(String.Format("ProjectSetupDataIn.aspx", "导入 - ")));
+ }
+ #endregion
+
+ #region 获取按钮权限
+ ///
+ /// 获取按钮权限
+ ///
+ ///
+ ///
+ private void GetButtonPower()
+ {
+ if (Request.Params["value"] == "0")
+ {
+ return;
+ }
+ var buttonList = BLL.CommonService.GetAllButtonList(this.CurrUser.LoginProjectId, this.CurrUser.UserId, BLL.Const.ProjectSetupMenuId);
+ if (buttonList.Count() > 0)
+ {
+ if (buttonList.Contains(BLL.Const.BtnDelete))
+ {
+ this.btnMenuDel.Hidden = false;
+ }
+ if (buttonList.Contains(BLL.Const.BtnSave))
+ {
+ this.btnImport.Hidden = false;
+ }
+ }
+ }
+ #endregion
+ }
+}
\ No newline at end of file
diff --git a/SGGL/FineUIPro.Web/Transfer/Piping.aspx.designer.cs b/SGGL/FineUIPro.Web/Transfer/Piping.aspx.designer.cs
new file mode 100644
index 00000000..d7ce9219
--- /dev/null
+++ b/SGGL/FineUIPro.Web/Transfer/Piping.aspx.designer.cs
@@ -0,0 +1,177 @@
+//------------------------------------------------------------------------------
+// <自动生成>
+// 此代码由工具生成。
+//
+// 对此文件的更改可能导致不正确的行为,如果
+// 重新生成代码,则所做更改将丢失。
+// 自动生成>
+//------------------------------------------------------------------------------
+
+namespace FineUIPro.Web.Transfer {
+
+
+ public partial class Piping {
+
+ ///
+ /// form1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.HtmlControls.HtmlForm form1;
+
+ ///
+ /// PageManager1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::FineUIPro.PageManager PageManager1;
+
+ ///
+ /// Panel1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::FineUIPro.Panel Panel1;
+
+ ///
+ /// Grid1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::FineUIPro.Grid Grid1;
+
+ ///
+ /// ToolSearch 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::FineUIPro.Toolbar ToolSearch;
+
+ ///
+ /// btnImport 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::FineUIPro.Button btnImport;
+
+ ///
+ /// lblPageIndex 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Label lblPageIndex;
+
+ ///
+ /// g1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::FineUIPro.GroupField g1;
+
+ ///
+ /// g2 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::FineUIPro.GroupField g2;
+
+ ///
+ /// g3 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::FineUIPro.GroupField g3;
+
+ ///
+ /// g4 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::FineUIPro.GroupField g4;
+
+ ///
+ /// ToolbarText1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::FineUIPro.ToolbarText ToolbarText1;
+
+ ///
+ /// ddlPageSize 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::FineUIPro.DropDownList ddlPageSize;
+
+ ///
+ /// Window1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::FineUIPro.Window Window1;
+
+ ///
+ /// Window2 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::FineUIPro.Window Window2;
+
+ ///
+ /// WindowAtt 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::FineUIPro.Window WindowAtt;
+
+ ///
+ /// Menu1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::FineUIPro.Menu Menu1;
+
+ ///
+ /// btnMenuDel 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::FineUIPro.MenuButton btnMenuDel;
+ }
+}
diff --git a/SGGL/FineUIPro.Web/Transfer/ProjectSetup.aspx b/SGGL/FineUIPro.Web/Transfer/ProjectSetup.aspx
index 5181a9b7..860fb31f 100644
--- a/SGGL/FineUIPro.Web/Transfer/ProjectSetup.aspx
+++ b/SGGL/FineUIPro.Web/Transfer/ProjectSetup.aspx
@@ -4,7 +4,7 @@
-
+
@@ -14,8 +14,8 @@
ShowHeader="false" Layout="VBox" BoxConfigAlign="Stretch">
@@ -35,54 +35,61 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/SGGL/FineUIPro.Web/Transfer/ProjectSetup.aspx.cs b/SGGL/FineUIPro.Web/Transfer/ProjectSetup.aspx.cs
index 74d176c9..61c8f241 100644
--- a/SGGL/FineUIPro.Web/Transfer/ProjectSetup.aspx.cs
+++ b/SGGL/FineUIPro.Web/Transfer/ProjectSetup.aspx.cs
@@ -30,11 +30,7 @@ namespace FineUIPro.Web.Transfer
///
public void BindGrid()
{
- string strSql = @"select InspectionEquipmentId,ProjectId,C.UnitId,Status, U.UnitName,InspectionCode,CN.ProfessionalName,InspectionName,Specifications,Unit,
- Supplier,Counts,SamplingCount,(CASE WHEN SamplingResult=1 THEN '合格' WHEN SamplingResult=0 THEN '不合格' ELSE '' END) AS SamplingResult,
- InspectionDate,AttachUrl,Attribute,RemarkCode,UsedPlace,EquipmentNO from Comprehensive_InspectionEquipment C
- left join Base_Unit U on C.UnitId=U.UnitId
- left join Base_CNProfessional CN on C.CNProfessionalId=CN.CNProfessionalId
+ string strSql = @"select * from Transfer_ProjectSetup C
where C.ProjectId = @ProjectId";
List listStr = new List();
listStr.Add(new SqlParameter("@ProjectId", this.CurrUser.LoginProjectId));
@@ -158,10 +154,10 @@ namespace FineUIPro.Web.Transfer
foreach (int rowIndex in Grid1.SelectedRowIndexArray)
{
string rowID = Grid1.DataKeys[rowIndex][0].ToString();
- var InspectionEquipment = BLL.InspectionEquipmentService.GetInspectionEquipmentById(rowID);
- if (InspectionEquipment != null)
+ var data = BLL.ProjectSetupService.GetProjectSetupById(rowID);
+ if (data != null)
{
- BLL.InspectionEquipmentService.DeleteInspectionEquipment(rowID);
+ BLL.ProjectSetupService.DeleteProjectSetup(rowID);
}
}
BindGrid();
@@ -178,7 +174,7 @@ namespace FineUIPro.Web.Transfer
///
protected void btnImport_Click(object sender, EventArgs e)
{
- PageContext.RegisterStartupScript(Window2.GetShowReference(String.Format("InspectionEquipmentDataIn.aspx", "导入 - ")));
+ PageContext.RegisterStartupScript(Window2.GetShowReference(String.Format("ProjectSetupDataIn.aspx", "导入 - ")));
}
#endregion
@@ -194,7 +190,7 @@ namespace FineUIPro.Web.Transfer
{
return;
}
- var buttonList = BLL.CommonService.GetAllButtonList(this.CurrUser.LoginProjectId, this.CurrUser.UserId, BLL.Const.InspectionEquipmentMenuId);
+ var buttonList = BLL.CommonService.GetAllButtonList(this.CurrUser.LoginProjectId, this.CurrUser.UserId, BLL.Const.ProjectSetupMenuId);
if (buttonList.Count() > 0)
{
if (buttonList.Contains(BLL.Const.BtnDelete))
@@ -208,33 +204,5 @@ namespace FineUIPro.Web.Transfer
}
}
#endregion
-
- public static string ConvertState(object Status)
- {
- if (Status != null)
- {
- if (Status.ToString().Trim() == BLL.Const.Comprehensive_ReCompile)
- {
- return "重报";
- }
- else if (Status.ToString().Trim() == BLL.Const.Comprehensive_ReJect)
- {
- return "驳回";
- }
- else if (Status.ToString().Trim() == BLL.Const.Comprehensive_Compile)
- {
- return "编制";
- }
- else if (Status.ToString().Trim() == BLL.Const.Comprehensive_Audit)
- {
- return "待审批";
- }
- else if (Status.ToString().Trim() == BLL.Const.Comprehensive_Complete)
- {
- return "审批完成";
- }
- }
- return "编制";
- }
}
}
\ No newline at end of file
diff --git a/SGGL/FineUIPro.Web/Transfer/ProjectSetup.aspx.designer.cs b/SGGL/FineUIPro.Web/Transfer/ProjectSetup.aspx.designer.cs
index 12cfd988..4a55604b 100644
--- a/SGGL/FineUIPro.Web/Transfer/ProjectSetup.aspx.designer.cs
+++ b/SGGL/FineUIPro.Web/Transfer/ProjectSetup.aspx.designer.cs
@@ -76,13 +76,40 @@ namespace FineUIPro.Web.Transfer {
protected global::System.Web.UI.WebControls.Label lblPageIndex;
///
- /// lbtnFileUrl 控件。
+ /// g1 控件。
///
///
/// 自动生成的字段。
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
///
- protected global::System.Web.UI.WebControls.LinkButton lbtnFileUrl;
+ protected global::FineUIPro.GroupField g1;
+
+ ///
+ /// g2 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::FineUIPro.GroupField g2;
+
+ ///
+ /// g3 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::FineUIPro.GroupField g3;
+
+ ///
+ /// g4 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::FineUIPro.GroupField g4;
///
/// ToolbarText1 控件。
diff --git a/SGGL/FineUIPro.Web/Transfer/ProjectSetupDataIn.aspx b/SGGL/FineUIPro.Web/Transfer/ProjectSetupDataIn.aspx
new file mode 100644
index 00000000..92bd444b
--- /dev/null
+++ b/SGGL/FineUIPro.Web/Transfer/ProjectSetupDataIn.aspx
@@ -0,0 +1,68 @@
+<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="ProjectSetupDataIn.aspx.cs" Inherits="FineUIPro.Web.Transfer.ProjectSetupDataIn" %>
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/SGGL/FineUIPro.Web/Transfer/ProjectSetupDataIn.aspx.cs b/SGGL/FineUIPro.Web/Transfer/ProjectSetupDataIn.aspx.cs
new file mode 100644
index 00000000..75349cd2
--- /dev/null
+++ b/SGGL/FineUIPro.Web/Transfer/ProjectSetupDataIn.aspx.cs
@@ -0,0 +1,427 @@
+using BLL;
+using System;
+using System.Collections.Generic;
+using System.Data;
+using System.Data.OleDb;
+using System.IO;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace FineUIPro.Web.Transfer
+{
+ public partial class ProjectSetupDataIn : PageBase
+ {
+ #region 定义变量
+ ///
+ /// 上传预设的虚拟路径
+ ///
+ private string initPath = Const.ExcelUrl;
+
+
+ ///
+ /// 错误集合
+ ///
+ public static List errorInfos = new List();
+ #endregion
+
+ #region 加载
+ ///
+ /// 加载页面
+ ///
+ ///
+ ///
+ protected void Page_Load(object sender, EventArgs e)
+ {
+ if (!IsPostBack)
+ {
+ this.hdCheckResult.Text = string.Empty;
+ this.hdFileName.Text = string.Empty;
+ if (errorInfos != null)
+ {
+ errorInfos.Clear();
+ }
+ }
+ }
+ #endregion
+
+ #region 审核
+ ///
+ /// 审核
+ ///
+ ///
+ ///
+ protected void btnAudit_Click(object sender, EventArgs e)
+ {
+ try
+ {
+ if (this.fuAttachUrl.HasFile == false)
+ {
+ ShowNotify("请您选择Excel文件!", MessageBoxIcon.Warning);
+ return;
+ }
+ string IsXls = Path.GetExtension(this.fuAttachUrl.FileName).ToString().Trim().ToLower();
+ if (IsXls != ".xls")
+ {
+ ShowNotify("只可以选择Excel文件!", MessageBoxIcon.Warning);
+ return;
+ }
+ if (errorInfos != null)
+ {
+ errorInfos.Clear();
+ }
+ string rootPath = Server.MapPath("~/");
+ string initFullPath = rootPath + initPath;
+ if (!Directory.Exists(initFullPath))
+ {
+ Directory.CreateDirectory(initFullPath);
+ }
+
+ this.hdFileName.Text = BLL.Funs.GetNewFileName() + IsXls;
+ string filePath = initFullPath + this.hdFileName.Text;
+ this.fuAttachUrl.PostedFile.SaveAs(filePath);
+ ImportXlsToData(rootPath + initPath + this.hdFileName.Text);
+ }
+ catch (Exception ex)
+ {
+ ShowNotify("'" + ex.Message + "'", MessageBoxIcon.Warning);
+ }
+ }
+
+ #region 读Excel提取数据
+ ///
+ /// 从Excel提取数据--》Dataset
+ ///
+ /// Excel文件路径名
+ private void ImportXlsToData(string fileName)
+ {
+ try
+ {
+ string oleDBConnString = String.Empty;
+ oleDBConnString = "Provider=Microsoft.Jet.OLEDB.4.0;";
+ oleDBConnString += "Data Source=";
+ oleDBConnString += fileName;
+ oleDBConnString += ";Extended Properties=Excel 8.0;";
+ OleDbConnection oleDBConn = null;
+ OleDbDataAdapter oleAdMaster = null;
+ DataTable m_tableName = new DataTable();
+ DataSet ds = new DataSet();
+
+ oleDBConn = new OleDbConnection(oleDBConnString);
+ oleDBConn.Open();
+ m_tableName = oleDBConn.GetOleDbSchemaTable(OleDbSchemaGuid.Tables, null);
+
+ if (m_tableName != null && m_tableName.Rows.Count > 0)
+ {
+
+ m_tableName.TableName = m_tableName.Rows[0]["TABLE_NAME"].ToString().Trim();
+
+ }
+ string sqlMaster;
+ sqlMaster = " SELECT * FROM [" + m_tableName.TableName + "]";
+ oleAdMaster = new OleDbDataAdapter(sqlMaster, oleDBConn);
+ oleAdMaster.Fill(ds, "m_tableName");
+ oleAdMaster.Dispose();
+ oleDBConn.Close();
+ oleDBConn.Dispose();
+
+ AddDatasetToSQL(ds.Tables[0], 13);
+ hdCheckResult.Text = "1";
+ }
+ catch (Exception exc)
+ {
+ Response.Write(exc);
+ //return null;
+ // return dt;
+ }
+ finally
+ {
+ }
+ }
+ #endregion
+
+ #region 将Dataset的数据导入数据库
+ ///
+ /// 将Dataset的数据导入数据库
+ ///
+ /// 数据集
+ /// 数据集行数
+ ///
+ private bool AddDatasetToSQL(DataTable pds, int Cols)
+ {
+ string result = string.Empty;
+ int ic, ir;
+ ic = pds.Columns.Count;
+ if (ic < Cols)
+ {
+ ShowNotify("导入Excel格式错误!Excel只有" + ic.ToString().Trim() + "列", MessageBoxIcon.Warning);
+ return false;
+ }
+
+ ir = pds.Rows.Count;
+ if (pds != null && ir > 0)
+ {
+ var oldViewInfos = from x in Funs.DB.Transfer_ProjectSetup
+ where x.ProjectId == this.CurrUser.LoginProjectId
+ select x;
+
+ var cns = from x in Funs.DB.Base_CNProfessional select x;
+
+ for (int i = 0; i < ir; i++)
+ {
+ Model.Transfer_ProjectSetup oldViewInfo = new Model.Transfer_ProjectSetup();
+ string row0 = pds.Rows[i][0].ToString().Trim();
+ string row1 = pds.Rows[i][1].ToString();
+ //if (string.IsNullOrEmpty(row1))
+ //{
+ // result += (i + 2).ToString() + "," + "报验编号" + "," + "此项为必填项!" + "|";
+ //}
+
+ //string row2 = pds.Rows[i][2].ToString();
+ //if (!string.IsNullOrEmpty(row2))
+ //{
+ // var cn = cns.Where(x => x.ProfessionalName == row2.Trim()).FirstOrDefault();
+ // if (cn == null)
+ // {
+ // result += (i + 2).ToString() + "," + "专业名称" + "," + "[" + row2 + "]不存在!" + "|";
+ // }
+ //}
+
+ //string row10 = pds.Rows[i][10].ToString().Trim();
+ //if (!string.IsNullOrEmpty(row10))
+ //{
+ // if (row10 != "合格" && row10 != "不合格")
+ // {
+ // result += (i + 2).ToString() + "," + "本次抽检结果" + "," + "[" + row10 + "]错误!" + "|";
+ // }
+ //}
+
+ //string row11 = pds.Rows[i][11].ToString();
+ //if (!string.IsNullOrEmpty(row11))
+ //{
+ // try
+ // {
+ // DateTime date = Convert.ToDateTime(row11.Trim());
+ // }
+ // catch (Exception)
+ // {
+ // result += (i + 2).ToString() + "," + "报验日期" + "," + "[" + row11 + "]错误!" + "|";
+ // }
+ //}
+
+ //string row12 = pds.Rows[i][12].ToString();
+ //if (string.IsNullOrEmpty(row12))
+ //{
+ // result += (i + 2).ToString() + "," + "标识编号" + "," + "此项为必填项!" + "|";
+ //}
+
+ }
+ if (!string.IsNullOrEmpty(result))
+ {
+ result = result.Substring(0, result.LastIndexOf("|"));
+ }
+ errorInfos.Clear();
+ if (!string.IsNullOrEmpty(result))
+ {
+ string results = result;
+ List errorInfoList = results.Split('|').ToList();
+ foreach (var item in errorInfoList)
+ {
+ string[] errors = item.Split(',');
+ Model.ErrorInfo errorInfo = new Model.ErrorInfo();
+ errorInfo.Row = errors[0];
+ errorInfo.Column = errors[1];
+ errorInfo.Reason = errors[2];
+ errorInfos.Add(errorInfo);
+ }
+ if (errorInfos.Count > 0)
+ {
+ this.gvErrorInfo.DataSource = errorInfos;
+ this.gvErrorInfo.DataBind();
+ }
+ }
+ else
+ {
+ ShowNotify("审核完成,请点击导入!", MessageBoxIcon.Success);
+ }
+ }
+
+ else
+ {
+ ShowNotify("导入数据为空!", MessageBoxIcon.Warning);
+ }
+ return true;
+ }
+ #endregion
+ #endregion
+
+ #region 导入
+ ///
+ /// 导入
+ ///
+ ///
+ ///
+ protected void btnImport_Click(object sender, EventArgs e)
+ {
+ if (!string.IsNullOrEmpty(hdCheckResult.Text))
+ {
+ if (errorInfos.Count <= 0)
+ {
+ string rootPath = Server.MapPath("~/");
+ ImportXlsToData2(rootPath + initPath + this.hdFileName.Text);
+ hdCheckResult.Text = string.Empty;
+ ShowNotify("导入成功!", MessageBoxIcon.Success);
+ PageContext.RegisterStartupScript(ActiveWindow.GetHidePostBackReference());
+ }
+ else
+ {
+ ShowNotify("请先将错误数据修正,再重新导入提交!", MessageBoxIcon.Warning);
+ }
+ }
+ else
+ {
+ ShowNotify("请先审核要导入的文件!", MessageBoxIcon.Warning);
+ }
+ }
+
+ #region Excel提取数据
+ ///
+ /// 从Excel提取数据--》Dataset
+ ///
+ /// Excel文件路径名
+ private void ImportXlsToData2(string fileName)
+ {
+ try
+ {
+ string oleDBConnString = String.Empty;
+ oleDBConnString = "Provider=Microsoft.Jet.OLEDB.4.0;";
+ oleDBConnString += "Data Source=";
+ oleDBConnString += fileName;
+ oleDBConnString += ";Extended Properties=Excel 8.0;";
+ OleDbConnection oleDBConn = null;
+ OleDbDataAdapter oleAdMaster = null;
+ DataTable m_tableName = new DataTable();
+ DataSet ds = new DataSet();
+
+ oleDBConn = new OleDbConnection(oleDBConnString);
+ oleDBConn.Open();
+ m_tableName = oleDBConn.GetOleDbSchemaTable(OleDbSchemaGuid.Tables, null);
+
+ if (m_tableName != null && m_tableName.Rows.Count > 0)
+ {
+
+ m_tableName.TableName = m_tableName.Rows[0]["TABLE_NAME"].ToString().Trim();
+
+ }
+ string sqlMaster;
+ sqlMaster = " SELECT * FROM [" + m_tableName.TableName + "]";
+ oleAdMaster = new OleDbDataAdapter(sqlMaster, oleDBConn);
+ oleAdMaster.Fill(ds, "m_tableName");
+ oleAdMaster.Dispose();
+ oleDBConn.Close();
+ oleDBConn.Dispose();
+
+ AddDatasetToSQL2(ds.Tables[0], 13);
+ }
+ catch (Exception ex)
+ {
+ throw ex;
+ }
+ }
+ #endregion
+
+ #region 将Dataset的数据导入数据库
+ ///
+ /// 将Dataset的数据导入数据库
+ ///
+ /// 数据集
+ /// 数据集列数
+ ///
+ private bool AddDatasetToSQL2(DataTable pds, int Cols)
+ {
+ int ic, ir;
+ ic = pds.Columns.Count;
+ if (ic < Cols)
+ {
+ ShowNotify("导入Excel格式错误!Excel只有" + ic.ToString().Trim() + "列", MessageBoxIcon.Warning);
+ }
+ string result = string.Empty;
+ ir = pds.Rows.Count;
+ if (pds != null && ir > 0)
+ {
+ var oldViewInfos = from x in Funs.DB.Comprehensive_InspectionEquipment
+ where x.ProjectId == this.CurrUser.LoginProjectId
+ select x;
+
+ var cns = from x in Funs.DB.Base_CNProfessional select x;
+
+ for (int i = 1; i < ir; i++)
+ {
+ Model.Transfer_ProjectSetup Ins = new Model.Transfer_ProjectSetup();
+ Ins.Id = SQLHelper.GetNewID();
+ Ins.ProjectId = this.CurrUser.LoginProjectId;
+ Ins.SN = pds.Rows[i][0].ToString().Trim();
+ Ins.PlantNo = pds.Rows[i][1].ToString().Trim();
+ Ins.PlantName = pds.Rows[i][2].ToString().Trim();
+ Ins.CommissioningSystem = pds.Rows[i][3].ToString().Trim();
+ Ins.CommissioningCodeDescription = pds.Rows[i][4].ToString().Trim();
+ Ins.SubCommissioningSystem = pds.Rows[i][5].ToString().Trim();
+ Ins.SubCommissioningCodeDescription = pds.Rows[i][6].ToString().Trim();
+ Ins.DescriptionArea = pds.Rows[i][7].ToString().Trim();
+ Ins.TurnoverSystemSequenceNumber = pds.Rows[i][8].ToString().Trim();
+ Ins.Description = pds.Rows[i][9].ToString().Trim();
+ Ins.TurnoverCode = pds.Rows[i][10].ToString().Trim();
+ Ins.TurnoverDescription = pds.Rows[i][11].ToString().Trim();
+ Ins.Remark = pds.Rows[i][12].ToString().Trim();
+ BLL.ProjectSetupService.AddProjectSetup(Ins);
+ }
+ }
+ else
+ {
+ ShowNotify("导入数据为空!", MessageBoxIcon.Warning);
+ }
+ return true;
+ }
+ #endregion
+ #endregion
+
+
+ #region 下载模板
+ ///
+ /// 下载模板按钮
+ ///
+ ///
+ ///
+ protected void btnDownLoad_Click(object sender, EventArgs e)
+ {
+ PageContext.RegisterStartupScript(Confirm.GetShowReference("确定下载导入模板吗?", String.Empty, MessageBoxIcon.Question, PageManager1.GetCustomEventReference(false, "Confirm_OK"), PageManager1.GetCustomEventReference("Confirm_Cancel")));
+ }
+
+ ///
+ /// 下载导入模板
+ ///
+ ///
+ ///
+ protected void PageManager1_CustomEvent(object sender, CustomEventArgs e)
+ {
+ if (e.EventArgument == "Confirm_OK")
+ {
+ string rootPath = Server.MapPath("~/");
+ string uploadfilepath = rootPath + Const.ProjectSetupDataInUrl;
+ string filePath = Const.ProjectSetupDataInUrl;
+ string fileName = Path.GetFileName(filePath);
+ FileInfo info = new FileInfo(uploadfilepath);
+ long fileSize = info.Length;
+ Response.ClearContent();
+ Response.AddHeader("Content-Disposition", "attachment;filename=" + System.Web.HttpUtility.UrlEncode(fileName, System.Text.Encoding.UTF8));
+ Response.ContentType = "excel/plain";
+ Response.ContentEncoding = System.Text.Encoding.UTF8;
+ Response.AddHeader("Content-Length", fileSize.ToString().Trim());
+ Response.TransmitFile(uploadfilepath, 0, fileSize);
+ Response.End();
+ }
+ }
+ #endregion
+ }
+}
\ No newline at end of file
diff --git a/SGGL/FineUIPro.Web/Transfer/ProjectSetupDataIn.aspx.designer.cs b/SGGL/FineUIPro.Web/Transfer/ProjectSetupDataIn.aspx.designer.cs
new file mode 100644
index 00000000..8e67ec09
--- /dev/null
+++ b/SGGL/FineUIPro.Web/Transfer/ProjectSetupDataIn.aspx.designer.cs
@@ -0,0 +1,123 @@
+//------------------------------------------------------------------------------
+// <自动生成>
+// 此代码由工具生成。
+//
+// 对此文件的更改可能导致不正确的行为,如果
+// 重新生成代码,则所做更改将丢失。
+// 自动生成>
+//------------------------------------------------------------------------------
+
+namespace FineUIPro.Web.Transfer {
+
+
+ public partial class ProjectSetupDataIn {
+
+ ///
+ /// form1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.HtmlControls.HtmlForm form1;
+
+ ///
+ /// PageManager1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::FineUIPro.PageManager PageManager1;
+
+ ///
+ /// SimpleForm1 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::FineUIPro.Form SimpleForm1;
+
+ ///
+ /// Toolbar2 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::FineUIPro.Toolbar Toolbar2;
+
+ ///
+ /// hdFileName 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::FineUIPro.HiddenField hdFileName;
+
+ ///
+ /// btnAudit 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::FineUIPro.Button btnAudit;
+
+ ///
+ /// btnImport 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::FineUIPro.Button btnImport;
+
+ ///
+ /// btnDownLoad 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::FineUIPro.Button btnDownLoad;
+
+ ///
+ /// hdCheckResult 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::FineUIPro.HiddenField hdCheckResult;
+
+ ///
+ /// fuAttachUrl 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::FineUIPro.FileUpload fuAttachUrl;
+
+ ///
+ /// gvErrorInfo 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::FineUIPro.Grid gvErrorInfo;
+
+ ///
+ /// lblPageIndex 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::System.Web.UI.WebControls.Label lblPageIndex;
+ }
+}
diff --git a/SGGL/Model/Model.cs b/SGGL/Model/Model.cs
index 4d71da9b..770cad83 100644
--- a/SGGL/Model/Model.cs
+++ b/SGGL/Model/Model.cs
@@ -2345,6 +2345,9 @@ namespace Model
partial void InsertTransfer_Instrumentation(Transfer_Instrumentation instance);
partial void UpdateTransfer_Instrumentation(Transfer_Instrumentation instance);
partial void DeleteTransfer_Instrumentation(Transfer_Instrumentation instance);
+ partial void InsertTransfer_Piping(Transfer_Piping instance);
+ partial void UpdateTransfer_Piping(Transfer_Piping instance);
+ partial void DeleteTransfer_Piping(Transfer_Piping instance);
partial void InsertTransfer_ProjectSetup(Transfer_ProjectSetup instance);
partial void UpdateTransfer_ProjectSetup(Transfer_ProjectSetup instance);
partial void DeleteTransfer_ProjectSetup(Transfer_ProjectSetup instance);
@@ -8719,6 +8722,14 @@ namespace Model
}
}
+ public System.Data.Linq.Table Transfer_Piping
+ {
+ get
+ {
+ return this.GetTable();
+ }
+ }
+
public System.Data.Linq.Table Transfer_ProjectSetup
{
get
@@ -368792,6 +368803,308 @@ namespace Model
}
}
+ [global::System.Data.Linq.Mapping.TableAttribute(Name="dbo.Transfer_Piping")]
+ public partial class Transfer_Piping : INotifyPropertyChanging, INotifyPropertyChanged
+ {
+
+ private static PropertyChangingEventArgs emptyChangingEventArgs = new PropertyChangingEventArgs(String.Empty);
+
+ private string _Id;
+
+ private string _ProjectId;
+
+ private string _PIPINGLINENUMBER;
+
+ private string _SYSTEM;
+
+ private string _Subsystem;
+
+ private string _TestPackage;
+
+ private System.Nullable _TestPackageSTART;
+
+ private System.Nullable _TestPackageFINISH;
+
+ private string _FINALStatus;
+
+ private string _PreTestFINISHED;
+
+ private string _FinalTestFINISHED;
+
+ #region 可扩展性方法定义
+ partial void OnLoaded();
+ partial void OnValidate(System.Data.Linq.ChangeAction action);
+ partial void OnCreated();
+ partial void OnIdChanging(string value);
+ partial void OnIdChanged();
+ partial void OnProjectIdChanging(string value);
+ partial void OnProjectIdChanged();
+ partial void OnPIPINGLINENUMBERChanging(string value);
+ partial void OnPIPINGLINENUMBERChanged();
+ partial void OnSYSTEMChanging(string value);
+ partial void OnSYSTEMChanged();
+ partial void OnSubsystemChanging(string value);
+ partial void OnSubsystemChanged();
+ partial void OnTestPackageChanging(string value);
+ partial void OnTestPackageChanged();
+ partial void OnTestPackageSTARTChanging(System.Nullable value);
+ partial void OnTestPackageSTARTChanged();
+ partial void OnTestPackageFINISHChanging(System.Nullable value);
+ partial void OnTestPackageFINISHChanged();
+ partial void OnFINALStatusChanging(string value);
+ partial void OnFINALStatusChanged();
+ partial void OnPreTestFINISHEDChanging(string value);
+ partial void OnPreTestFINISHEDChanged();
+ partial void OnFinalTestFINISHEDChanging(string value);
+ partial void OnFinalTestFINISHEDChanged();
+ #endregion
+
+ public Transfer_Piping()
+ {
+ OnCreated();
+ }
+
+ [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Id", DbType="NVarChar(50) NOT NULL", CanBeNull=false, IsPrimaryKey=true)]
+ public string Id
+ {
+ get
+ {
+ return this._Id;
+ }
+ set
+ {
+ if ((this._Id != value))
+ {
+ this.OnIdChanging(value);
+ this.SendPropertyChanging();
+ this._Id = value;
+ this.SendPropertyChanged("Id");
+ this.OnIdChanged();
+ }
+ }
+ }
+
+ [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ProjectId", DbType="NVarChar(50)")]
+ public string ProjectId
+ {
+ get
+ {
+ return this._ProjectId;
+ }
+ set
+ {
+ if ((this._ProjectId != value))
+ {
+ this.OnProjectIdChanging(value);
+ this.SendPropertyChanging();
+ this._ProjectId = value;
+ this.SendPropertyChanged("ProjectId");
+ this.OnProjectIdChanged();
+ }
+ }
+ }
+
+ [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_PIPINGLINENUMBER", DbType="NVarChar(50)")]
+ public string PIPINGLINENUMBER
+ {
+ get
+ {
+ return this._PIPINGLINENUMBER;
+ }
+ set
+ {
+ if ((this._PIPINGLINENUMBER != value))
+ {
+ this.OnPIPINGLINENUMBERChanging(value);
+ this.SendPropertyChanging();
+ this._PIPINGLINENUMBER = value;
+ this.SendPropertyChanged("PIPINGLINENUMBER");
+ this.OnPIPINGLINENUMBERChanged();
+ }
+ }
+ }
+
+ [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_SYSTEM", DbType="NVarChar(50)")]
+ public string SYSTEM
+ {
+ get
+ {
+ return this._SYSTEM;
+ }
+ set
+ {
+ if ((this._SYSTEM != value))
+ {
+ this.OnSYSTEMChanging(value);
+ this.SendPropertyChanging();
+ this._SYSTEM = value;
+ this.SendPropertyChanged("SYSTEM");
+ this.OnSYSTEMChanged();
+ }
+ }
+ }
+
+ [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Subsystem", DbType="NVarChar(50)")]
+ public string Subsystem
+ {
+ get
+ {
+ return this._Subsystem;
+ }
+ set
+ {
+ if ((this._Subsystem != value))
+ {
+ this.OnSubsystemChanging(value);
+ this.SendPropertyChanging();
+ this._Subsystem = value;
+ this.SendPropertyChanged("Subsystem");
+ this.OnSubsystemChanged();
+ }
+ }
+ }
+
+ [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_TestPackage", DbType="NVarChar(50)")]
+ public string TestPackage
+ {
+ get
+ {
+ return this._TestPackage;
+ }
+ set
+ {
+ if ((this._TestPackage != value))
+ {
+ this.OnTestPackageChanging(value);
+ this.SendPropertyChanging();
+ this._TestPackage = value;
+ this.SendPropertyChanged("TestPackage");
+ this.OnTestPackageChanged();
+ }
+ }
+ }
+
+ [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_TestPackageSTART", DbType="DateTime")]
+ public System.Nullable TestPackageSTART
+ {
+ get
+ {
+ return this._TestPackageSTART;
+ }
+ set
+ {
+ if ((this._TestPackageSTART != value))
+ {
+ this.OnTestPackageSTARTChanging(value);
+ this.SendPropertyChanging();
+ this._TestPackageSTART = value;
+ this.SendPropertyChanged("TestPackageSTART");
+ this.OnTestPackageSTARTChanged();
+ }
+ }
+ }
+
+ [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_TestPackageFINISH", DbType="DateTime")]
+ public System.Nullable TestPackageFINISH
+ {
+ get
+ {
+ return this._TestPackageFINISH;
+ }
+ set
+ {
+ if ((this._TestPackageFINISH != value))
+ {
+ this.OnTestPackageFINISHChanging(value);
+ this.SendPropertyChanging();
+ this._TestPackageFINISH = value;
+ this.SendPropertyChanged("TestPackageFINISH");
+ this.OnTestPackageFINISHChanged();
+ }
+ }
+ }
+
+ [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_FINALStatus", DbType="NVarChar(50)")]
+ public string FINALStatus
+ {
+ get
+ {
+ return this._FINALStatus;
+ }
+ set
+ {
+ if ((this._FINALStatus != value))
+ {
+ this.OnFINALStatusChanging(value);
+ this.SendPropertyChanging();
+ this._FINALStatus = value;
+ this.SendPropertyChanged("FINALStatus");
+ this.OnFINALStatusChanged();
+ }
+ }
+ }
+
+ [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_PreTestFINISHED", DbType="NVarChar(50)")]
+ public string PreTestFINISHED
+ {
+ get
+ {
+ return this._PreTestFINISHED;
+ }
+ set
+ {
+ if ((this._PreTestFINISHED != value))
+ {
+ this.OnPreTestFINISHEDChanging(value);
+ this.SendPropertyChanging();
+ this._PreTestFINISHED = value;
+ this.SendPropertyChanged("PreTestFINISHED");
+ this.OnPreTestFINISHEDChanged();
+ }
+ }
+ }
+
+ [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_FinalTestFINISHED", DbType="NVarChar(50)")]
+ public string FinalTestFINISHED
+ {
+ get
+ {
+ return this._FinalTestFINISHED;
+ }
+ set
+ {
+ if ((this._FinalTestFINISHED != value))
+ {
+ this.OnFinalTestFINISHEDChanging(value);
+ this.SendPropertyChanging();
+ this._FinalTestFINISHED = value;
+ this.SendPropertyChanged("FinalTestFINISHED");
+ this.OnFinalTestFINISHEDChanged();
+ }
+ }
+ }
+
+ public event PropertyChangingEventHandler PropertyChanging;
+
+ public event PropertyChangedEventHandler PropertyChanged;
+
+ protected virtual void SendPropertyChanging()
+ {
+ if ((this.PropertyChanging != null))
+ {
+ this.PropertyChanging(this, emptyChangingEventArgs);
+ }
+ }
+
+ protected virtual void SendPropertyChanged(String propertyName)
+ {
+ if ((this.PropertyChanged != null))
+ {
+ this.PropertyChanged(this, new PropertyChangedEventArgs(propertyName));
+ }
+ }
+ }
+
[global::System.Data.Linq.Mapping.TableAttribute(Name="dbo.Transfer_ProjectSetup")]
public partial class Transfer_ProjectSetup : INotifyPropertyChanging, INotifyPropertyChanged
{