diff --git a/DataBase/ConstInitData.sql b/DataBase/ConstInitData.sql index eb357dc8..9e03c871 100644 --- a/DataBase/ConstInitData.sql +++ b/DataBase/ConstInitData.sql @@ -572,6 +572,9 @@ GO INSERT INTO Sys_Const (ID,ConstValue,ConstText,SortIndex,GroupId) VALUES('85CF0BBF-A3F3-42DF-89DC-CE9A4886BCA1','Menu_Video','视频监控',11,'MenuType_P') GO +INSERT INTO Sys_Const (ID,ConstValue,ConstText,SortIndex,GroupId) +VALUES('4F835AC7-9FD8-443D-A5A6-F557AA5A2221','Menu_Transfer','移交管理',12,'MenuType_P') +GO --项目类型 INSERT INTO dbo.Sys_Const(ID, ConstValue, ConstText, SortIndex, GroupId) diff --git a/DataBase/鐗堟湰鏃ュ織/SGGLDB_WH_2024-01-26-gaofei.sql b/DataBase/鐗堟湰鏃ュ織/SGGLDB_WH_2024-01-26-gaofei.sql index 8bb9d8be..cadd0a7f 100644 --- a/DataBase/鐗堟湰鏃ュ織/SGGLDB_WH_2024-01-26-gaofei.sql +++ b/DataBase/鐗堟湰鏃ュ織/SGGLDB_WH_2024-01-26-gaofei.sql @@ -53,6 +53,52 @@ GO +CREATE TABLE [dbo].[Transfer_StaticEquipment]( + [Id] [nvarchar](50) NOT NULL, + [ProjectId] [nvarchar](50) NULL, + [StaticEquipment] [nvarchar](50) NULL, + [SYSTEM] [nvarchar](50) NULL, + [Subsystem] [nvarchar](50) NULL, + [TestPackage] [nvarchar](50) NULL, + [TestPackageSTART] [datetime] NULL, + [TestPackageFINISH] [datetime] NULL, + [MechanicalFINALStatus] [nvarchar](50) NULL, + CONSTRAINT [PK_Transfer_StaticEquipment] 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'StaticEquipment' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'Transfer_StaticEquipment' +GO + + + +CREATE TABLE [dbo].[Transfer_RotatingEquipment]( + [Id] [nvarchar](50) NOT NULL, + [ProjectId] [nvarchar](50) NULL, + [RotatingEquipment] [nvarchar](50) NULL, + [SYSTEM] [nvarchar](50) NULL, + [Subsystem] [nvarchar](50) NULL, + [TestPackage] [nvarchar](50) NULL, + [TestPackageSTART] [datetime] NULL, + [TestPackageFINISH] [datetime] NULL, + [MechanicalFINALStatus] [nvarchar](50) NULL, + CONSTRAINT [PK_Transfer_RotatingEquipment] 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'RotatingEquipment' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'Transfer_RotatingEquipment' +GO + + + CREATE TABLE [dbo].[Transfer_Instrumentation]( diff --git a/DataBase/鐗堟湰鏃ュ織/SGGLDB_WH_2024-01-26-lpf.sql b/DataBase/鐗堟湰鏃ュ織/SGGLDB_WH_2024-01-26-lpf.sql index 3c56725d..e2850604 100644 --- a/DataBase/鐗堟湰鏃ュ織/SGGLDB_WH_2024-01-26-lpf.sql +++ b/DataBase/鐗堟湰鏃ュ織/SGGLDB_WH_2024-01-26-lpf.sql @@ -1,11 +1,11 @@ -alter table DriverSub_DriverSubPlan add DriverSubNames varchar(100); -go; -alter table DriverSub_DriverSubContact add DriverSubPlanId varchar(100); -go; -alter table DriverSub_DriverSubContact add DriverSubContractorsId varchar(100); -go; -alter table DriverSub_DriverSubContact add SubcontractingType varchar(100); -go; +alter table DriverSub_DriverSubPlan add DriverSubNames varchar(100) +go +alter table DriverSub_DriverSubContact add DriverSubPlanId varchar(100) +go +alter table DriverSub_DriverSubContact add DriverSubContractorsId varchar(100) +go +alter table DriverSub_DriverSubContact add SubcontractingType varchar(100) +go create table DriverSub_DriverSubContractors ( DriverSubContractorsId varchar(100) primary key, @@ -20,8 +20,8 @@ create table DriverSub_DriverSubContractors Province varchar(100), City varchar(100), IsUse bit default 1, -); -go; +) +go exec sp_addextendedproperty 'MS_Description', N'浼佷笟鍚嶇О', 'SCHEMA', 'dbo', 'TABLE', 'DriverSub_DriverSubContractors', 'COLUMN', 'SubUnitName' go diff --git a/DataBase/鐗堟湰鏃ュ織/SGGLDB_WH_2024-01-26-phf.sql b/DataBase/鐗堟湰鏃ュ織/SGGLDB_WH_2024-01-26-phf.sql deleted file mode 100644 index ce48014a..00000000 --- a/DataBase/鐗堟湰鏃ュ織/SGGLDB_WH_2024-01-26-phf.sql +++ /dev/null @@ -1,79 +0,0 @@ -CREATE TABLE [dbo].[Transfer_PunchlistFrom]( - [Id] [nvarchar](50) NOT NULL, - [ProjectId] [nvarchar](50) NULL, - [Item_No] [nvarchar](50) NULL, - [Punch_No] [nvarchar](50) NULL, - [SystemName] [nvarchar](50) NULL, - [Subsystem] [nvarchar](50) NULL, - [Test_Package] [nvarchar](50) NULL, - [Discipline] [nvarchar](50) NULL, - [DESCRIPTION] [nvarchar](50) NULL, - [Identified] [nvarchar](50) NULL, - [Category] [nvarchar](50) NULL, - [PUNCH_ITEM_FINISH_DATE] [datetime] NULL, - [Action_By] [nvarchar](50) NULL, - [Required_By] [nvarchar](50) NULL, - [PUNCH_ITEM_STATUS] [nvarchar](50) NULL, - [Comments] [nvarchar](50) NULL, - CONSTRAINT [PK_Transfer_PunchlistFrom] 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 - - -CREATE TABLE [dbo].[Transfer_HVAC]( - [Id] [nvarchar](50) NOT NULL, - [ProjectId] [nvarchar](50) NULL, - [HVAC] [nvarchar](50) NULL, - [SystemName] [nvarchar](50) NULL, - [Subsystem] [nvarchar](50) NULL, - [Test_Package] [nvarchar](50) NULL, - [Test_Package_START] [datetime] NULL, - [Test_Package_FINISH] [datetime] NULL, - [FINAL_Status] [nvarchar](50) NULL, - CONSTRAINT [PK_Transfer_HVAC] 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 - -CREATE TABLE [dbo].[Transfer_Plumbing]( - [Id] [nvarchar](50) NOT NULL, - [ProjectId] [nvarchar](50) NULL, - [Plumbing] [nvarchar](50) NULL, - [SystemName] [nvarchar](50) NULL, - [Subsystem] [nvarchar](50) NULL, - [Test_Package] [nvarchar](50) NULL, - [Test_Package_START] [datetime] NULL, - [Test_Package_FINISH] [datetime] NULL, - [FINAL_Status] [nvarchar](50) NULL, - CONSTRAINT [PK_Transfer_Plumbing] 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 - -CREATE TABLE [dbo].[Transfer_Telecom]( - [Id] [nvarchar](50) NOT NULL, - [ProjectId] [nvarchar](50) NULL, - [Telecom] [nvarchar](50) NULL, - [SystemName] [nvarchar](50) NULL, - [Subsystem] [nvarchar](50) NULL, - [Test_Package] [nvarchar](50) NULL, - [Test_Package_START] [datetime] NULL, - [Test_Package_FINISH] [datetime] NULL, - [FINAL_Status] [nvarchar](50) NULL, - CONSTRAINT [PK_Transfer_Telecom] 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 \ No newline at end of file diff --git a/DataBase/鐗堟湰鏃ュ織/SGGLDB_WH_2024-01-29-gaofei.sql b/DataBase/鐗堟湰鏃ュ織/SGGLDB_WH_2024-01-29-gaofei.sql new file mode 100644 index 00000000..39437a4f --- /dev/null +++ b/DataBase/鐗堟湰鏃ュ織/SGGLDB_WH_2024-01-29-gaofei.sql @@ -0,0 +1,71 @@ +INSERT INTO Sys_Const (ID,ConstValue,ConstText,SortIndex,GroupId) +VALUES('4F835AC7-9FD8-443D-A5A6-F557AA5A2221','Menu_Transfer','移交管理',12,'MenuType_P') +GO + + insert into Sys_Menu( MenuId,MenuName,Url,SortIndex,SuperMenu,MenuType ,IsOffice,IsEnd,IsUsed ) + values('D0850615-BF32-4CFA-84CA-EEA261676EA8','移交专业设置','BaseInfo/TransferMajor.aspx',180,'5196A6FD-4BF1-46B3-8D24-9A3CE5BB4760','Menu_SysSet',1,1,1) + GO + insert into Sys_ButtonToMenu (ButtonToMenuId,MenuId,ButtonName,SortIndex) values('0465EA2B-2F37-4103-A717-4033894108E0','D0850615-BF32-4CFA-84CA-EEA261676EA8','增加',1) + insert into Sys_ButtonToMenu (ButtonToMenuId,MenuId,ButtonName,SortIndex) values('EF58BDF7-F303-4633-8B83-DB4B151F8EAF','D0850615-BF32-4CFA-84CA-EEA261676EA8','修改',2) + insert into Sys_ButtonToMenu (ButtonToMenuId,MenuId,ButtonName,SortIndex) values('FC1373E2-D942-4D0E-822F-CE2F16C5D42D','D0850615-BF32-4CFA-84CA-EEA261676EA8','删除',3) + insert into Sys_ButtonToMenu (ButtonToMenuId,MenuId,ButtonName,SortIndex) values('65427D56-5490-42D7-8F00-EB3A59FAA6B0','D0850615-BF32-4CFA-84CA-EEA261676EA8','保存',4) + GO + + +CREATE TABLE [dbo].[Base_TransferMajor]( + [TransferMajorId] [nvarchar](50) NOT NULL, + [Discipline] [nvarchar](50) NULL, + [Major] [nvarchar](50) NULL, + [DisciplineCode] [nvarchar](50) NULL, + [Remark] [nvarchar](200) NULL, + CONSTRAINT [PK_BaseInfo_TransferMajor] PRIMARY KEY CLUSTERED +( + [TransferMajorId] 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'移交专业表' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'Base_TransferMajor' +GO + + +INSERT INTO Base_TransferMajor +VALUES('7A0CD361-2BF9-466A-A586-3DBA49A7D4A1','Static Equipment','静设备','01',null) +GO +INSERT INTO Base_TransferMajor +VALUES('3D5FC248-8437-4062-A882-945C077B1910','Equipment','动设备','02',null) +GO +INSERT INTO Base_TransferMajor +VALUES('B55C034D-057E-4CD3-B09B-75DBDB7D2CDC','Piping','管道','03',null) +GO +INSERT INTO Base_TransferMajor +VALUES('2DA0AB18-78BD-43A5-BBB0-2BF96E25789E','Instrument','仪表','04','only refer to field instrument') +GO +INSERT INTO Base_TransferMajor +VALUES('A7C08424-D6B4-40AD-8563-DCD793290ADE','Eletrical','电气','05',null) +GO +INSERT INTO Base_TransferMajor +VALUES('0A4DE4BE-DE07-41F2-ABB1-FE8B8710BC2A','Structure','结构','06',null) +GO +INSERT INTO Base_TransferMajor +VALUES('2EE1D310-53DF-43E1-B7A0-F4C1389E4A52','Civil','土建','07',null) +GO +INSERT INTO Base_TransferMajor +VALUES('2CDA9F7D-2212-4D6F-9E62-14241BA57DF3','Architecture','建筑','08',null) +GO +INSERT INTO Base_TransferMajor +VALUES('53CB3BF5-517F-4E67-A218-E9A7E1E31A58','FF','消防','09',null) +GO +INSERT INTO Base_TransferMajor +VALUES('B87322EC-75DA-4BEB-9CED-31B7E89B4FA9','Plumbing','给排水','10',null) +GO +INSERT INTO Base_TransferMajor +VALUES('D109A3D9-E8CC-46B4-830A-AB2686E6321F','Plot Plan','总图','11',null) +GO +INSERT INTO Base_TransferMajor +VALUES('DE4904D2-1CD8-4248-8599-AC16995FBDDB','Telecom','电信','12',null) +GO +INSERT INTO Base_TransferMajor +VALUES('82B6666D-1866-4A38-927A-0B2DB60C4D64','HVAC','暖通','13',null) +GO \ No newline at end of file diff --git a/DataBase/鐗堟湰鏃ュ織/SGGLDB_WH_2024-01-30-phf.sql b/DataBase/鐗堟湰鏃ュ織/SGGLDB_WH_2024-01-30-phf.sql new file mode 100644 index 00000000..d10e30b0 --- /dev/null +++ b/DataBase/鐗堟湰鏃ュ織/SGGLDB_WH_2024-01-30-phf.sql @@ -0,0 +1,76 @@ +Create VIEW [dbo].[View_TransferDetail] AS +/*移交管理列表视图*/ + +select Projectid,SystemName,Subsystem,TestPackage,sDate,fDate,Status from ( + +SELECT Projectid, SYSTEM as SystemName, Subsystem ,TestPackage, +TestPackageSTART as sDate,TestPackageFINISH as fDate,FINALStatus as Status +FROM Transfer_Piping + +UNION ALL + +SELECT Projectid,SYSTEM as SystemName, Subsystem ,TestPackage,TestPackageSTART as sDate, +TestPackageFINISH as fDate, +MechanicalFINALStatus as Status +FROM Transfer_StaticEquipment + +UNION ALL + +SELECT Projectid,SYSTEM as SystemName, Subsystem ,TestPackage,TestPackageSTART as sDate, +TestPackageFINISH as fDate, +MechanicalFINALStatus as Status +FROM Transfer_RotatingEquipment + +UNION ALL + +SELECT Projectid,SystemName, Subsystem ,Test_Package as TestPackage, Test_Package_START as sDate, +Test_Package_FINISH as fDate, +FINAL_Status as Status +FROM Transfer_Instrumentation + +UNION ALL + +SELECT Projectid,SystemName, Subsystem ,Test_Package as TestPackage, Test_Package_START as sDate, +Test_Package_FINISH as fDate, +FINAL_Status as Status +FROM Transfer_Electrical + +UNION ALL + +SELECT Projectid,SystemName, Subsystem ,Test_Package as TestPackage, Test_Package_START as sDate, +Test_Package_FINISH as fDate, +FINAL_Status as Status +FROM Transfer_Civil_Structure + +UNION ALL + +SELECT Projectid,SystemName, Subsystem ,Test_Package as TestPackage, Test_Package_START as sDate, +Test_Package_FINISH as fDate, +FINAL_Status as Status +FROM Transfer_Firefighting + +UNION ALL + +SELECT Projectid,SystemName, Subsystem ,Test_Package as TestPackage, Test_Package_START as sDate, +Test_Package_FINISH as fDate, +FINAL_Status as Status +FROM Transfer_Telecom + +UNION ALL + +SELECT Projectid,SystemName, Subsystem ,Test_Package as TestPackage, Test_Package_START as sDate, +Test_Package_FINISH as fDate, +FINAL_Status as Status +FROM Transfer_Plumbing + +UNION ALL + +SELECT Projectid,SystemName, Subsystem ,Test_Package as TestPackage, Test_Package_START as sDate, +Test_Package_FINISH as fDate, +FINAL_Status as Status +FROM Transfer_HVAC + +)f + + +GO \ No newline at end of file diff --git a/DataBase/鐗堟湰鏃ュ織/SGGLDB_WH_2024-02-01-gaofei.sql b/DataBase/鐗堟湰鏃ュ織/SGGLDB_WH_2024-02-01-gaofei.sql new file mode 100644 index 00000000..793147ec --- /dev/null +++ b/DataBase/鐗堟湰鏃ュ織/SGGLDB_WH_2024-02-01-gaofei.sql @@ -0,0 +1,2 @@ +alter table Transfer_PunchlistFrom alter column DESCRIPTION nvarchar(500) null +GO \ No newline at end of file diff --git a/DataBase/鐗堟湰鏃ュ織/SGGLDB_WH_2024-02-02-01-phf.sql b/DataBase/鐗堟湰鏃ュ織/SGGLDB_WH_2024-02-02-01-phf.sql new file mode 100644 index 00000000..5ab3c142 --- /dev/null +++ b/DataBase/鐗堟湰鏃ュ織/SGGLDB_WH_2024-02-02-01-phf.sql @@ -0,0 +1,86 @@ +Alter VIEW [dbo].[View_TransferDetail] AS +/*移交管理列表视图*/ + +select Projectid,SystemName,Subsystem,TestPackage,sDate,fDate,Status,aDate from ( + +SELECT Projectid, SYSTEM as SystemName, Subsystem ,TestPackage, +TestPackageSTART as sDate,TestPackageFINISH as fDate,FINALStatus as Status, +CompleteTime as aDate +FROM Transfer_Piping + +UNION ALL + +SELECT Projectid,SYSTEM as SystemName, Subsystem ,TestPackage,TestPackageSTART as sDate, +TestPackageFINISH as fDate, +MechanicalFINALStatus as Status , +CompleteTime as aDate +FROM Transfer_StaticEquipment + +UNION ALL + +SELECT Projectid,SYSTEM as SystemName, Subsystem ,TestPackage,TestPackageSTART as sDate, +TestPackageFINISH as fDate, +MechanicalFINALStatus as Status, +CompleteTime as aDate +FROM Transfer_RotatingEquipment + +UNION ALL + +SELECT Projectid,SystemName, Subsystem ,Test_Package as TestPackage, Test_Package_START as sDate, +Test_Package_FINISH as fDate, +FINAL_Status as Status, +CompleteTime as aDate +FROM Transfer_Instrumentation + +UNION ALL + +SELECT Projectid,SystemName, Subsystem ,Test_Package as TestPackage, Test_Package_START as sDate, +Test_Package_FINISH as fDate, +FINAL_Status as Status, +CompleteTime as aDate +FROM Transfer_Electrical + +UNION ALL + +SELECT Projectid,SystemName, Subsystem ,Test_Package as TestPackage, Test_Package_START as sDate, +Test_Package_FINISH as fDate, +FINAL_Status as Status, +CompleteTime as aDate +FROM Transfer_Civil_Structure + +UNION ALL + +SELECT Projectid,SystemName, Subsystem ,Test_Package as TestPackage, Test_Package_START as sDate, +Test_Package_FINISH as fDate, +FINAL_Status as Status, +CompleteTime as aDate +FROM Transfer_Firefighting + +UNION ALL + +SELECT Projectid,SystemName, Subsystem ,Test_Package as TestPackage, Test_Package_START as sDate, +Test_Package_FINISH as fDate, +FINAL_Status as Status, +CompleteTime as aDate +FROM Transfer_Telecom + +UNION ALL + +SELECT Projectid,SystemName, Subsystem ,Test_Package as TestPackage, Test_Package_START as sDate, +Test_Package_FINISH as fDate, +FINAL_Status as Status, +CompleteTime as aDate +FROM Transfer_Plumbing + +UNION ALL + +SELECT Projectid,SystemName, Subsystem ,Test_Package as TestPackage, Test_Package_START as sDate, +Test_Package_FINISH as fDate, +FINAL_Status as Status, +CompleteTime as aDate +FROM Transfer_HVAC + +)f + + +GO \ No newline at end of file diff --git a/DataBase/鐗堟湰鏃ュ織/SGGLDB_WH_2024-02-02-phf.sql b/DataBase/鐗堟湰鏃ュ織/SGGLDB_WH_2024-02-02-phf.sql new file mode 100644 index 00000000..d2dbe410 --- /dev/null +++ b/DataBase/鐗堟湰鏃ュ織/SGGLDB_WH_2024-02-02-phf.sql @@ -0,0 +1,10 @@ +alter table Transfer_Piping add CompleteTime datetime null; +alter table Transfer_StaticEquipment add CompleteTime datetime null; +alter table Transfer_RotatingEquipment add CompleteTime datetime null; +alter table Transfer_Instrumentation add CompleteTime datetime null; +alter table Transfer_Electrical add CompleteTime datetime null; +alter table Transfer_Civil_Structure add CompleteTime datetime null; +alter table Transfer_Firefighting add CompleteTime datetime null; +alter table Transfer_Telecom add CompleteTime datetime null; +alter table Transfer_Plumbing add CompleteTime datetime null; +alter table Transfer_HVAC add CompleteTime datetime null; \ No newline at end of file diff --git a/DataBase/鐗堟湰鏃ュ織/SGGLDB_WH_2024-02-04-phf.sql b/DataBase/鐗堟湰鏃ュ織/SGGLDB_WH_2024-02-04-phf.sql new file mode 100644 index 00000000..61d069b0 --- /dev/null +++ b/DataBase/鐗堟湰鏃ュ織/SGGLDB_WH_2024-02-04-phf.sql @@ -0,0 +1,13 @@ +--重新导入 +delete from Transfer_Piping; +delete from Transfer_StaticEquipment; +delete from Transfer_RotatingEquipment; + +--修改时间完成时间 +update Transfer_Instrumentation set CompleteTime=getdate(); +update Transfer_Electrical set CompleteTime=getdate(); +update Transfer_Civil_Structure set CompleteTime=getdate(); +update Transfer_Firefighting set CompleteTime=getdate(); +update Transfer_Telecom set CompleteTime=getdate(); +update Transfer_Plumbing set CompleteTime=getdate(); +update Transfer_HVAC set CompleteTime=getdate(); \ No newline at end of file diff --git a/DataBase/鑿滃崟鍒濆鍖栬剼鏈/0-1绯荤粺璁剧疆锛圡enu_SysSet锛.sql b/DataBase/鑿滃崟鍒濆鍖栬剼鏈/0-1绯荤粺璁剧疆锛圡enu_SysSet锛.sql index 0459d502..e85a33ac 100644 --- a/DataBase/鑿滃崟鍒濆鍖栬剼鏈/0-1绯荤粺璁剧疆锛圡enu_SysSet锛.sql +++ b/DataBase/鑿滃崟鍒濆鍖栬剼鏈/0-1绯荤粺璁剧疆锛圡enu_SysSet锛.sql @@ -244,6 +244,15 @@ GO insert into Sys_ButtonToMenu (ButtonToMenuId,MenuId,ButtonName,SortIndex) values('124B7659-5F18-49F3-8D30-BF8680830827','F0DF2F2B-7C12-4A0F-B7D4-0B00BADE1D64','保存',4) GO + insert into Sys_Menu( MenuId,MenuName,Url,SortIndex,SuperMenu,MenuType ,IsOffice,IsEnd,IsUsed ) + values('D0850615-BF32-4CFA-84CA-EEA261676EA8','移交专业设置','BaseInfo/TransferMajor.aspx',180,'5196A6FD-4BF1-46B3-8D24-9A3CE5BB4760','Menu_SysSet',1,1,1) + GO + insert into Sys_ButtonToMenu (ButtonToMenuId,MenuId,ButtonName,SortIndex) values('0465EA2B-2F37-4103-A717-4033894108E0','D0850615-BF32-4CFA-84CA-EEA261676EA8','增加',1) + insert into Sys_ButtonToMenu (ButtonToMenuId,MenuId,ButtonName,SortIndex) values('EF58BDF7-F303-4633-8B83-DB4B151F8EAF','D0850615-BF32-4CFA-84CA-EEA261676EA8','修改',2) + insert into Sys_ButtonToMenu (ButtonToMenuId,MenuId,ButtonName,SortIndex) values('FC1373E2-D942-4D0E-822F-CE2F16C5D42D','D0850615-BF32-4CFA-84CA-EEA261676EA8','删除',3) + insert into Sys_ButtonToMenu (ButtonToMenuId,MenuId,ButtonName,SortIndex) values('65427D56-5490-42D7-8F00-EB3A59FAA6B0','D0850615-BF32-4CFA-84CA-EEA261676EA8','保存',4) + GO + /****质量基础设置******/ INSERT INTO dbo.Sys_Menu(MenuId,MenuName,Url,SortIndex,SuperMenu,MenuType,IsOffice,IsEnd,IsUsed) VALUES('A93BA810-3511-4BB2-9C10-9663351DF79F','质量设置','',20,'D363BD9D-4DEC-45D8-89C8-B0E49DEF61B4','Menu_SysSet',1,0,1) diff --git a/DataBase/鑿滃崟鍒濆鍖栬剼鏈/1-14绉讳氦绠$悊鍥捐〃锛圡enu_Transfer锛.sql b/DataBase/鑿滃崟鍒濆鍖栬剼鏈/1-14绉讳氦绠$悊鍥捐〃锛圡enu_Transfer锛.sql new file mode 100644 index 00000000..7f28b592 --- /dev/null +++ b/DataBase/鑿滃崟鍒濆鍖栬剼鏈/1-14绉讳氦绠$悊鍥捐〃锛圡enu_Transfer锛.sql @@ -0,0 +1,20 @@ +INSERT INTO dbo.Sys_Menu(MenuId,MenuName,Url,SortIndex,SuperMenu,MenuType,IsOffice,IsEnd,IsUsed) +VALUES('3517DBE2-9728-4BA0-9EA5-AE2147DB883B','移交图表','', +130,'0','Menu_Transfer',0,0,1) + + +INSERT INTO dbo.Sys_Menu(MenuId,MenuName,Url,SortIndex,SuperMenu,MenuType,IsOffice,IsEnd,IsUsed) +VALUES('E6F5125D-DD94-4978-B7EB-D9C26694D86D','全厂移交统计表', +'Transfer/Chart/Instrumentation.aspx',10,'3517DBE2-9728-4BA0-9EA5-AE2147DB883B','Menu_Transfer',0,1,1) + + +INSERT INTO dbo.Sys_Menu(MenuId,MenuName,Url,SortIndex,SuperMenu,MenuType,IsOffice,IsEnd,IsUsed) +VALUES('C2DD3E9E-DB18-466F-8FA0-19AD6E21EEF0','Punchlist from', +'Transfer/Chart/PunchlistFrom.aspx',20,'3517DBE2-9728-4BA0-9EA5-AE2147DB883B','Menu_Transfer',0,1,1) + +INSERT INTO dbo.Sys_Menu(MenuId,MenuName,Url,SortIndex,SuperMenu,MenuType,IsOffice,IsEnd,IsUsed) +VALUES('F97BCF55-E450-4007-AD84-AB64B3496204','全厂移交统计递增表', +'Transfer/Chart/TransferChart.aspx',15,'3517DBE2-9728-4BA0-9EA5-AE2147DB883B','Menu_Transfer',0,1,1) + + + diff --git a/SGGL/BLL/BLL.csproj b/SGGL/BLL/BLL.csproj index d482c2e6..372cebec 100644 --- a/SGGL/BLL/BLL.csproj +++ b/SGGL/BLL/BLL.csproj @@ -165,6 +165,7 @@ + @@ -770,6 +771,8 @@ + + diff --git a/SGGL/BLL/BaseInfo/TransferMajorService.cs b/SGGL/BLL/BaseInfo/TransferMajorService.cs new file mode 100644 index 00000000..2099310b --- /dev/null +++ b/SGGL/BLL/BaseInfo/TransferMajorService.cs @@ -0,0 +1,86 @@ +锘縰sing System; +using System.Collections.Generic; +using System.Linq; +using System.Text; + +namespace BLL +{ + /// + /// 绉讳氦涓撲笟 + /// + public static class TransferMajorService + { + public static Model.SGGLDB db = Funs.DB; + + /// + /// 鏍规嵁涓婚敭鑾峰彇绉讳氦涓撲笟 + /// + /// + /// + public static Model.Base_TransferMajor GetTransferMajorById(string TransferMajorId) + { + return Funs.DB.Base_TransferMajor.FirstOrDefault(e => e.TransferMajorId == TransferMajorId); + } + + /// + /// 娣诲姞绉讳氦涓撲笟 + /// + /// + public static void AddTransferMajor(Model.Base_TransferMajor TransferMajor) + { + Model.SGGLDB db = Funs.DB; + Model.Base_TransferMajor newTransferMajor = new Model.Base_TransferMajor + { + TransferMajorId = TransferMajor.TransferMajorId, + Discipline = TransferMajor.Discipline, + Major = TransferMajor.Major, + DisciplineCode = TransferMajor.DisciplineCode, + Remark = TransferMajor.Remark + }; + db.Base_TransferMajor.InsertOnSubmit(newTransferMajor); + db.SubmitChanges(); + } + + /// + /// 淇敼绉讳氦涓撲笟 + /// + /// + public static void UpdateTransferMajor(Model.Base_TransferMajor TransferMajor) + { + Model.SGGLDB db = Funs.DB; + Model.Base_TransferMajor newTransferMajor = db.Base_TransferMajor.FirstOrDefault(e => e.TransferMajorId == TransferMajor.TransferMajorId); + if (newTransferMajor != null) + { + newTransferMajor.Discipline = TransferMajor.Discipline; + newTransferMajor.Major = TransferMajor.Major; + newTransferMajor.DisciplineCode = TransferMajor.DisciplineCode; + newTransferMajor.Remark = TransferMajor.Remark; + db.SubmitChanges(); + } + } + + /// + /// 鏍规嵁涓婚敭鍒犻櫎绉讳氦涓撲笟 + /// + /// + public static void DeleteTransferMajorById(string TransferMajorId) + { + Model.SGGLDB db = Funs.DB; + Model.Base_TransferMajor TransferMajor = db.Base_TransferMajor.FirstOrDefault(e => e.TransferMajorId == TransferMajorId); + if (TransferMajor != null) + { + db.Base_TransferMajor.DeleteOnSubmit(TransferMajor); + db.SubmitChanges(); + } + } + + /// + /// 鑾峰彇绉讳氦涓撲笟涓嬫媺鍒楄〃椤 + /// + /// + public static List GetTransferMajorList() + { + return (from x in Funs.DB.Base_TransferMajor orderby x.DisciplineCode select x).ToList(); + } + } +} diff --git a/SGGL/BLL/Common/ChartControlService.cs b/SGGL/BLL/Common/ChartControlService.cs index 32096b9d..e022e9fc 100644 --- a/SGGL/BLL/Common/ChartControlService.cs +++ b/SGGL/BLL/Common/ChartControlService.cs @@ -109,5 +109,49 @@ return chart; } #endregion + + /// + /// 缁檆hart绫昏祴鍊 + /// + /// 鏁版嵁婧愯〃鍊 + /// 鍥炬爣棰 + /// 鍥剧被鍨 + /// 鍥炬樉绀哄搴 + /// 鍥炬樉绀洪珮搴 + /// 鏄惁鏄剧ず3D鏁堟灉 + /// 杩斿洖鍥 + public static Model.DataSourceChart GetDataSourceChartByYijiao(DataTable dt, string title, string type, int width, int height, bool isNotEnable3D) + { + Model.DataSourceChart dataSourceChart = new Model.DataSourceChart + { + Width = width, + Height = height, + Title = title, + IsNotEnable3D = isNotEnable3D, + ChartType = GetChartType(type) + }; + List dataSourceTeams = new List(); + for (int i = 1; i < dt.Columns.Count; i++) + { + Model.DataSourceTeam dataSourceTeam = new Model.DataSourceTeam + { + DataPointName = dt.Columns[i].ToString() + }; + List dataSourcePoints = new List(); + for (int j = 0; j < dt.Rows.Count; j++) + { + Model.DataSourcePoint dataSourcePoint = new Model.DataSourcePoint + { + PointText = dt.Rows[j][0].ToString(), + PointValue = dt.Rows[j][i].ToString() + }; + dataSourcePoints.Add(dataSourcePoint); + } + dataSourceTeam.DataSourcePoints = dataSourcePoints; + dataSourceTeams.Add(dataSourceTeam); + } + dataSourceChart.DataSourceTeams = dataSourceTeams; + return dataSourceChart; + } } } diff --git a/SGGL/BLL/Common/Const.cs b/SGGL/BLL/Common/Const.cs index 2b52aa32..a96ed1c0 100644 --- a/SGGL/BLL/Common/Const.cs +++ b/SGGL/BLL/Common/Const.cs @@ -1026,6 +1026,10 @@ namespace BLL /// 椋庨櫓绛夌骇 /// public const string RiskLevelMenuId = "E4B526CC-805E-4131-8E18-2FFA6871507E"; + /// + /// 绉讳氦涓撲笟 + /// + public const string TransferMajorMenuId = "D0850615-BF32-4CFA-84CA-EEA261676EA8"; #endregion #region 璐ㄩ噺鍩虹淇℃伅 diff --git a/SGGL/BLL/TestRun/DriverRun/DriverRunPlanService.cs b/SGGL/BLL/TestRun/DriverRun/DriverRunPlanService.cs index 3da39a96..ec51bda1 100644 --- a/SGGL/BLL/TestRun/DriverRun/DriverRunPlanService.cs +++ b/SGGL/BLL/TestRun/DriverRun/DriverRunPlanService.cs @@ -83,10 +83,9 @@ namespace BLL Model.DriverRun_DriverRunPlan newDriverRunPlan = Funs.DB.DriverRun_DriverRunPlan.FirstOrDefault(e => e.DriverRunPlanId == driverRunPlanId); if (newDriverRunPlan != null) { - if (!string.IsNullOrEmpty(newDriverRunPlan.AttachUrl)) - { - UploadAttachmentService.DeleteFile(Funs.RootPath, newDriverRunPlan.AttachUrl); - } + ////鍒犻櫎闄勪欢琛 + BLL.CommonService.DeleteAttachFileById(newDriverRunPlan.DriverRunPlanId); + BLL.CommonService.DeleteAttachFileById(newDriverRunPlan.DriverRunPlanId + "K"); Funs.DB.DriverRun_DriverRunPlan.DeleteOnSubmit(newDriverRunPlan); Funs.DB.SubmitChanges(); } diff --git a/SGGL/BLL/Transfer/RotatingEquipmentService.cs b/SGGL/BLL/Transfer/RotatingEquipmentService.cs new file mode 100644 index 00000000..b20f390b --- /dev/null +++ b/SGGL/BLL/Transfer/RotatingEquipmentService.cs @@ -0,0 +1,79 @@ +锘縰sing System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace BLL +{ + public class RotatingEquipmentService + { + /// + /// 鏍规嵁涓婚敭鑾峰彇璁惧鏉愭枡鎶ラ獙淇℃伅 + /// + /// + /// + public static Model.Transfer_RotatingEquipment GetRotatingEquipmentById(string Id) + { + return Funs.DB.Transfer_RotatingEquipment.FirstOrDefault(e => e.Id == Id); + } + + /// + /// 娣诲姞璁惧鏉愭枡鎶ラ獙 + /// + /// + public static void AddRotatingEquipment(Model.Transfer_RotatingEquipment RotatingEquipment) + { + Model.SGGLDB db = Funs.DB; + Model.Transfer_RotatingEquipment newRotatingEquipment = new Model.Transfer_RotatingEquipment(); + newRotatingEquipment.Id = RotatingEquipment.Id; + newRotatingEquipment.ProjectId = RotatingEquipment.ProjectId; + newRotatingEquipment.RotatingEquipment = RotatingEquipment.RotatingEquipment; + newRotatingEquipment.SYSTEM = RotatingEquipment.SYSTEM; + newRotatingEquipment.Subsystem = RotatingEquipment.Subsystem; + newRotatingEquipment.TestPackage = RotatingEquipment.TestPackage; + newRotatingEquipment.TestPackageSTART = RotatingEquipment.TestPackageSTART; + newRotatingEquipment.TestPackageFINISH = RotatingEquipment.TestPackageFINISH; + newRotatingEquipment.MechanicalFINALStatus = RotatingEquipment.MechanicalFINALStatus; + db.Transfer_RotatingEquipment.InsertOnSubmit(newRotatingEquipment); + db.SubmitChanges(); + } + + /// + /// 淇敼璁惧鏉愭枡鎶ラ獙 + /// + /// + public static void UpdateRotatingEquipment(Model.Transfer_RotatingEquipment RotatingEquipment) + { + Model.SGGLDB db = Funs.DB; + Model.Transfer_RotatingEquipment newRotatingEquipment = db.Transfer_RotatingEquipment.FirstOrDefault(e => e.Id == RotatingEquipment.Id); + if (newRotatingEquipment != null) + { + newRotatingEquipment.ProjectId = RotatingEquipment.ProjectId; + newRotatingEquipment.RotatingEquipment = RotatingEquipment.RotatingEquipment; + newRotatingEquipment.SYSTEM = RotatingEquipment.SYSTEM; + newRotatingEquipment.Subsystem = RotatingEquipment.Subsystem; + newRotatingEquipment.TestPackage = RotatingEquipment.TestPackage; + newRotatingEquipment.TestPackageSTART = RotatingEquipment.TestPackageSTART; + newRotatingEquipment.TestPackageFINISH = RotatingEquipment.TestPackageFINISH; + newRotatingEquipment.MechanicalFINALStatus = RotatingEquipment.MechanicalFINALStatus; + db.SubmitChanges(); + } + } + + /// + /// 鏍规嵁涓婚敭鍒犻櫎璁惧鏉愭枡鎶ラ獙 + /// + /// + public static void DeleteRotatingEquipment(string Id) + { + Model.SGGLDB db = Funs.DB; + Model.Transfer_RotatingEquipment RotatingEquipment = db.Transfer_RotatingEquipment.FirstOrDefault(e => e.Id == Id); + if (RotatingEquipment != null) + { + db.Transfer_RotatingEquipment.DeleteOnSubmit(RotatingEquipment); + db.SubmitChanges(); + } + } + } +} diff --git a/SGGL/BLL/Transfer/StaticEquipmentService.cs b/SGGL/BLL/Transfer/StaticEquipmentService.cs new file mode 100644 index 00000000..bdeed534 --- /dev/null +++ b/SGGL/BLL/Transfer/StaticEquipmentService.cs @@ -0,0 +1,79 @@ +锘縰sing System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace BLL +{ + public class StaticEquipmentService + { + /// + /// 鏍规嵁涓婚敭鑾峰彇璁惧鏉愭枡鎶ラ獙淇℃伅 + /// + /// + /// + public static Model.Transfer_StaticEquipment GetStaticEquipmentById(string Id) + { + return Funs.DB.Transfer_StaticEquipment.FirstOrDefault(e => e.Id == Id); + } + + /// + /// 娣诲姞璁惧鏉愭枡鎶ラ獙 + /// + /// + public static void AddStaticEquipment(Model.Transfer_StaticEquipment StaticEquipment) + { + Model.SGGLDB db = Funs.DB; + Model.Transfer_StaticEquipment newStaticEquipment = new Model.Transfer_StaticEquipment(); + newStaticEquipment.Id = StaticEquipment.Id; + newStaticEquipment.ProjectId = StaticEquipment.ProjectId; + newStaticEquipment.StaticEquipment = StaticEquipment.StaticEquipment; + newStaticEquipment.SYSTEM = StaticEquipment.SYSTEM; + newStaticEquipment.Subsystem = StaticEquipment.Subsystem; + newStaticEquipment.TestPackage = StaticEquipment.TestPackage; + newStaticEquipment.TestPackageSTART = StaticEquipment.TestPackageSTART; + newStaticEquipment.TestPackageFINISH = StaticEquipment.TestPackageFINISH; + newStaticEquipment.MechanicalFINALStatus = StaticEquipment.MechanicalFINALStatus; + db.Transfer_StaticEquipment.InsertOnSubmit(newStaticEquipment); + db.SubmitChanges(); + } + + /// + /// 淇敼璁惧鏉愭枡鎶ラ獙 + /// + /// + public static void UpdateStaticEquipment(Model.Transfer_StaticEquipment StaticEquipment) + { + Model.SGGLDB db = Funs.DB; + Model.Transfer_StaticEquipment newStaticEquipment = db.Transfer_StaticEquipment.FirstOrDefault(e => e.Id == StaticEquipment.Id); + if (newStaticEquipment != null) + { + newStaticEquipment.ProjectId = StaticEquipment.ProjectId; + newStaticEquipment.StaticEquipment = StaticEquipment.StaticEquipment; + newStaticEquipment.SYSTEM = StaticEquipment.SYSTEM; + newStaticEquipment.Subsystem = StaticEquipment.Subsystem; + newStaticEquipment.TestPackage = StaticEquipment.TestPackage; + newStaticEquipment.TestPackageSTART = StaticEquipment.TestPackageSTART; + newStaticEquipment.TestPackageFINISH = StaticEquipment.TestPackageFINISH; + newStaticEquipment.MechanicalFINALStatus = StaticEquipment.MechanicalFINALStatus; + db.SubmitChanges(); + } + } + + /// + /// 鏍规嵁涓婚敭鍒犻櫎璁惧鏉愭枡鎶ラ獙 + /// + /// + public static void DeleteStaticEquipment(string Id) + { + Model.SGGLDB db = Funs.DB; + Model.Transfer_StaticEquipment StaticEquipment = db.Transfer_StaticEquipment.FirstOrDefault(e => e.Id == Id); + if (StaticEquipment != null) + { + db.Transfer_StaticEquipment.DeleteOnSubmit(StaticEquipment); + db.SubmitChanges(); + } + } + } +} diff --git a/SGGL/FineUIPro.Web/BaseInfo/TransferMajor.aspx b/SGGL/FineUIPro.Web/BaseInfo/TransferMajor.aspx new file mode 100644 index 00000000..07c4b6a5 --- /dev/null +++ b/SGGL/FineUIPro.Web/BaseInfo/TransferMajor.aspx @@ -0,0 +1,152 @@ +锘<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="TransferMajor.aspx.cs" Inherits="FineUIPro.Web.BaseInfo.TransferMajor" %> + + + + + + 绉讳氦涓撲笟 + + + +
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/SGGL/FineUIPro.Web/BaseInfo/TransferMajor.aspx.cs b/SGGL/FineUIPro.Web/BaseInfo/TransferMajor.aspx.cs new file mode 100644 index 00000000..b0d6346e --- /dev/null +++ b/SGGL/FineUIPro.Web/BaseInfo/TransferMajor.aspx.cs @@ -0,0 +1,280 @@ +锘縰sing BLL; +using System; +using System.Collections.Generic; +using System.Linq; +using System.Web.UI.WebControls; + +namespace FineUIPro.Web.BaseInfo +{ + public partial class TransferMajor : PageBase + { + #region 鍔犺浇 + /// + /// 鍔犺浇椤甸潰 + /// + /// + /// + protected void Page_Load(object sender, EventArgs e) + { + if (!IsPostBack) + { + ////鏉冮檺鎸夐挳鏂规硶 + this.GetButtonPower(); + Funs.DropDownPageSize(this.ddlPageSize); + ddlPageSize.SelectedValue = Grid1.PageSize.ToString(); + // 缁戝畾琛ㄦ牸 + BindGrid(); + } + } + + /// + /// 缁戝畾鏁版嵁 + /// + private void BindGrid() + { + var q = from x in Funs.DB.Base_TransferMajor orderby x.DisciplineCode select x; + Grid1.RecordCount = q.Count(); + // 2.鑾峰彇褰撳墠鍒嗛〉鏁版嵁 + var table = GetPagedDataTable(Grid1.PageIndex, Grid1.PageSize); + Grid1.DataSource = table; + Grid1.DataBind(); + } + + /// + /// 鍒嗛〉 + /// + /// + private List GetPagedDataTable(int pageIndex, int pageSize) + { + List source = (from x in Funs.DB.Base_TransferMajor orderby x.DisciplineCode select x).ToList(); + List paged = new List(); + + int rowbegin = pageIndex * pageSize; + int rowend = (pageIndex + 1) * pageSize; + if (rowend > source.Count()) + { + rowend = source.Count(); + } + + for (int i = rowbegin; i < rowend; i++) + { + paged.Add(source[i]); + } + + return paged; + } + + /// + /// 杩囨护琛ㄥご + /// + /// + /// + protected void Grid1_FilterChange(object sender, EventArgs e) + { + BindGrid(); + } + + /// + /// 鏀瑰彉绱㈠紩浜嬩欢 + /// + /// + /// + protected void Grid1_PageIndexChange(object sender, GridPageEventArgs e) + { + Grid1.PageIndex = e.NewPageIndex; + BindGrid(); + } + #endregion + + #region 鍒嗛〉涓嬫媺閫夋嫨 + /// + /// 鍒嗛〉涓嬫媺閫夋嫨 + /// + /// + /// + protected void ddlPageSize_SelectedIndexChanged(object sender, EventArgs e) + { + Grid1.PageSize = Convert.ToInt32(ddlPageSize.SelectedValue); + BindGrid(); + } + #endregion + + #region 鍒犻櫎 + /// + /// 鍒犻櫎 + /// + /// + /// + protected void btnDelete_Click(object sender, EventArgs e) + { + var getV = BLL.TransferMajorService.GetTransferMajorById(hfFormID.Text); + if (getV != null) + { + BLL.LogService.AddSys_Log(this.CurrUser, getV.DisciplineCode, getV.TransferMajorId, BLL.Const.TransferMajorMenuId, BLL.Const.BtnDelete); + BLL.TransferMajorService.DeleteTransferMajorById(hfFormID.Text); + // 閲嶆柊缁戝畾琛ㄦ牸锛屽苟妯℃嫙鐐瑰嚮[鏂板鎸夐挳] + BindGrid(); + PageContext.RegisterStartupScript("onNewButtonClick();"); + } + } + + /// + /// 鍙抽敭鍒犻櫎浜嬩欢 + /// + /// + /// + protected void btnMenuDelete_Click(object sender, EventArgs e) + { + this.DeleteData(); + } + + /// + /// 鍒犻櫎鏂规硶 + /// + private void DeleteData() + { + if (Grid1.SelectedRowIndexArray.Length > 0) + { + foreach (int rowIndex in Grid1.SelectedRowIndexArray) + { + string rowID = Grid1.DataKeys[rowIndex][0].ToString(); + var getV = BLL.TransferMajorService.GetTransferMajorById(rowID); + if (getV != null) + { + BLL.LogService.AddSys_Log(this.CurrUser, getV.DisciplineCode, getV.TransferMajorId, BLL.Const.TransferMajorMenuId, BLL.Const.BtnDelete); + BLL.TransferMajorService.DeleteTransferMajorById(rowID); + } + } + + BindGrid(); + PageContext.RegisterStartupScript("onNewButtonClick();"); + } + } + #endregion + + #region 缂栬緫 + /// + /// 鍙抽敭缂栬緫浜嬩欢 + /// + /// + /// + protected void btnMenuEdit_Click(object sender, EventArgs e) + { + this.EditData(); + } + + /// + /// 缂栬緫鏁版嵁鏂规硶 + /// + private void EditData() + { + if (Grid1.SelectedRowIndexArray.Length == 0) + { + Alert.ShowInTop("璇疯嚦灏戦夋嫨涓鏉¤褰曪紒", MessageBoxIcon.Warning); + return; + } + string Id = Grid1.SelectedRowID; + var TransferMajor = BLL.TransferMajorService.GetTransferMajorById(Id); + if (TransferMajor != null) + { + this.txtDiscipline.Text = TransferMajor.Discipline; + this.txtMajor.Text = TransferMajor.Major; + this.txtDisciplineCode.Text = TransferMajor.DisciplineCode; + this.txtRemark.Text = TransferMajor.Remark; + hfFormID.Text = Id; + this.btnDelete.Enabled = true; + } + } + #endregion + + #region 淇濆瓨 + /// + /// 淇濆瓨鎸夐挳 + /// + /// + /// + protected void btnSave_Click(object sender, EventArgs e) + { + string strRowID = hfFormID.Text; + Model.Base_TransferMajor TransferMajor = new Model.Base_TransferMajor + { + Discipline = this.txtDiscipline.Text.Trim(), + Major = this.txtMajor.Text.Trim(), + DisciplineCode= this.txtDisciplineCode.Text.Trim(), + Remark = txtRemark.Text.Trim() + }; + if (string.IsNullOrEmpty(strRowID)) + { + TransferMajor.TransferMajorId = SQLHelper.GetNewID(typeof(Model.Base_TransferMajor)); + BLL.TransferMajorService.AddTransferMajor(TransferMajor); + BLL.LogService.AddSys_Log(this.CurrUser, TransferMajor.Discipline, TransferMajor.TransferMajorId, BLL.Const.TransferMajorMenuId, BLL.Const.BtnAdd); + } + else + { + TransferMajor.TransferMajorId = strRowID; + BLL.TransferMajorService.UpdateTransferMajor(TransferMajor); + BLL.LogService.AddSys_Log(this.CurrUser, TransferMajor.Discipline, TransferMajor.TransferMajorId, BLL.Const.TransferMajorMenuId, BLL.Const.BtnModify); + } + + this.SimpleForm1.Reset(); + // 閲嶆柊缁戝畾琛ㄦ牸锛屽苟鐐瑰嚮褰撳墠缂栬緫鎴栬呮柊澧炵殑琛 + BindGrid(); + PageContext.RegisterStartupScript(String.Format("F('{0}').selectRow('{1}');", Grid1.ClientID, TransferMajor.TransferMajorId)); + } + #endregion + + #region 楠岃瘉璐圭敤绫诲埆鍚嶇О銆佺紪鍙锋槸鍚﹀瓨鍦 + /// + /// 楠岃瘉璐圭敤绫诲埆鍚嶇О銆佺紪鍙锋槸鍚﹀瓨鍦 + /// + /// + /// + protected void TextBox_TextChanged(object sender, EventArgs e) + { + var q = Funs.DB.Base_TransferMajor.FirstOrDefault(x => x.Discipline == this.txtDiscipline.Text.Trim() && (x.TransferMajorId != hfFormID.Text || (hfFormID.Text == null && x.TransferMajorId != null))); + if (q != null) + { + ShowNotify("杈撳叆鐨凞iscipline宸插瓨鍦紒", MessageBoxIcon.Warning); + } + + var q2 = Funs.DB.Base_TransferMajor.FirstOrDefault(x => x.Major == this.txtMajor.Text.Trim() && (x.TransferMajorId != hfFormID.Text || (hfFormID.Text == null && x.TransferMajorId != null))); + if (q2 != null) + { + ShowNotify("杈撳叆鐨勪笓涓氬凡瀛樺湪锛", MessageBoxIcon.Warning); + } + } + #endregion + + #region 鑾峰彇鎸夐挳鏉冮檺 + /// + /// 鑾峰彇鎸夐挳鏉冮檺 + /// + /// + /// + private void GetButtonPower() + { + var buttonList = BLL.CommonService.GetAllButtonList(this.CurrUser.LoginProjectId, this.CurrUser.UserId, BLL.Const.TransferMajorMenuId); + if (buttonList.Count() > 0) + { + if (buttonList.Contains(BLL.Const.BtnAdd)) + { + this.btnNew.Hidden = false; + } + if (buttonList.Contains(BLL.Const.BtnModify)) + { + this.btnMenuEdit.Hidden = false; + } + if (buttonList.Contains(BLL.Const.BtnDelete)) + { + this.btnDelete.Hidden = false; + this.btnMenuDelete.Hidden = false; + } + if (buttonList.Contains(BLL.Const.BtnSave)) + { + this.btnSave.Hidden = false; + } + } + } + #endregion + } +} \ No newline at end of file diff --git a/SGGL/FineUIPro.Web/BaseInfo/TransferMajor.aspx.designer.cs b/SGGL/FineUIPro.Web/BaseInfo/TransferMajor.aspx.designer.cs new file mode 100644 index 00000000..51b35e66 --- /dev/null +++ b/SGGL/FineUIPro.Web/BaseInfo/TransferMajor.aspx.designer.cs @@ -0,0 +1,204 @@ +锘//------------------------------------------------------------------------------ +// <鑷姩鐢熸垚> +// 姝や唬鐮佺敱宸ュ叿鐢熸垚銆 +// +// 瀵规鏂囦欢鐨勬洿鏀瑰彲鑳藉鑷翠笉姝g‘鐨勮涓猴紝濡傛灉 +// 閲嶆柊鐢熸垚浠g爜锛屽垯鎵鍋氭洿鏀瑰皢涓㈠け銆 +// +//------------------------------------------------------------------------------ + +namespace FineUIPro.Web.BaseInfo { + + + public partial class TransferMajor { + + /// + /// form1 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::System.Web.UI.HtmlControls.HtmlForm form1; + + /// + /// PageManager1 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.PageManager PageManager1; + + /// + /// Panel1 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.Panel Panel1; + + /// + /// Grid1 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.Grid Grid1; + + /// + /// ToolbarSeparator1 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.ToolbarSeparator ToolbarSeparator1; + + /// + /// ToolbarText1 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.ToolbarText ToolbarText1; + + /// + /// ddlPageSize 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.DropDownList ddlPageSize; + + /// + /// SimpleForm1 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.SimpleForm SimpleForm1; + + /// + /// hfFormID 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.TextBox hfFormID; + + /// + /// txtDiscipline 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.TextBox txtDiscipline; + + /// + /// txtMajor 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.TextBox txtMajor; + + /// + /// txtDisciplineCode 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.TextBox txtDisciplineCode; + + /// + /// txtRemark 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.TextArea txtRemark; + + /// + /// Toolbar1 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.Toolbar Toolbar1; + + /// + /// btnNew 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.Button btnNew; + + /// + /// btnDelete 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.Button btnDelete; + + /// + /// ToolbarFill1 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.ToolbarFill ToolbarFill1; + + /// + /// btnSave 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.Button btnSave; + + /// + /// Menu1 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.Menu Menu1; + + /// + /// btnMenuEdit 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.MenuButton btnMenuEdit; + + /// + /// btnMenuDelete 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.MenuButton btnMenuDelete; + } +} diff --git a/SGGL/FineUIPro.Web/Controls/ChartControl.ascx.cs b/SGGL/FineUIPro.Web/Controls/ChartControl.ascx.cs index cb6c6d73..b7c547ac 100644 --- a/SGGL/FineUIPro.Web/Controls/ChartControl.ascx.cs +++ b/SGGL/FineUIPro.Web/Controls/ChartControl.ascx.cs @@ -282,5 +282,154 @@ namespace Web.Controls Controls.Add(chart1); } + + /// + /// 鍒涘缓Chart鍥惧舰鐧惧垎姣 + /// + /// Chart绫 + public void CreateChartBaifenbi(Model.DataSourceChart dataSourceChart) + { + Chart chart1 = new Chart + { + ID = "chart1", + BackColor = Color.WhiteSmoke, + ImageLocation = "~/Images/ChartPic_#SEQ(300,3)", + BorderlineDashStyle = ChartDashStyle.Solid, + Palette = ChartColorPalette.BrightPastel, + BackSecondaryColor = Color.White, + BackGradientStyle = GradientStyle.TopBottom, + BorderWidth = 2, + BorderColor = Color.FromArgb(26, 59, 105), + ImageType = ChartImageType.Png, + + Width = dataSourceChart.Width, + Height = dataSourceChart.Height + }; + + Title title = new Title + { + Text = dataSourceChart.Title, + ShadowColor = Color.FromArgb(32, 0, 0, 0), + Font = new Font("Trebuchet MS", 10F, FontStyle.Bold), + ShadowOffset = 3, + ForeColor = Color.FromArgb(26, 59, 105) + }; + chart1.Titles.Add(title); + + Legend legend = new Legend + { + Name = dataSourceChart.Title, + TextWrapThreshold = 1, + Docking = Docking.Top, + Alignment = StringAlignment.Center, + BackColor = Color.Transparent, + Font = new Font(new FontFamily("Trebuchet MS"), 8), + LegendStyle = LegendStyle.Row, + IsEquallySpacedItems = true, + IsTextAutoFit = false + }; + chart1.Legends.Add(legend); + + ChartArea chartArea = new ChartArea + { + Name = dataSourceChart.Title, + BackColor = Color.Transparent + }; + chartArea.AxisX.IsLabelAutoFit = false; + chartArea.AxisY.IsLabelAutoFit = false; + chartArea.AxisX.LabelStyle.Font = new Font("Verdana,Arial,Helvetica,sans-serif", 8F, FontStyle.Regular); + chartArea.AxisY.LabelStyle.Font = new Font("Verdana,Arial,Helvetica,sans-serif", 8F, FontStyle.Regular); + chartArea.AxisY.LineColor = Color.FromArgb(64, 64, 64, 64); + chartArea.AxisX.LineColor = Color.FromArgb(64, 64, 64, 64); + chartArea.AxisY.MajorGrid.LineColor = Color.FromArgb(64, 64, 64, 64); + chartArea.AxisX.MajorGrid.LineColor = Color.FromArgb(64, 64, 64, 64); + chartArea.AxisX.Interval = 1; + chartArea.Area3DStyle.Enable3D = dataSourceChart.IsNotEnable3D; + + chartArea.AxisY.LabelStyle.Format = " 0% "; // 鏍煎紡鍖栵紝涓轰簡鏄剧ず鐧惧垎鍙 + + + chart1.ChartAreas.Add(chartArea); + + if (dataSourceChart.ChartType == SeriesChartType.Pie) + { + foreach (Model.DataSourceTeam dataSourceTeam in dataSourceChart.DataSourceTeams) + { + this.lblTotal.Text = "绱鍊间负锛"; + if (dataSourceTeam.DataPointName == "绱") + { + foreach (Model.DataSourcePoint dataSourcePoint in dataSourceTeam.DataSourcePoints) + { + this.lblTotal.Text += (dataSourcePoint.PointText + "锛" + dataSourcePoint.PointValue + ","); + } + if (this.lblTotal.Text != "绱鍊间负锛") + { + this.lblTotal.Text = this.lblTotal.Text.Substring(0, this.lblTotal.Text.LastIndexOf(",")); + } + } + else + { + this.lblTotal.Visible = false; + chart1.Series.Add(dataSourceTeam.DataPointName); + chart1.Series[dataSourceTeam.DataPointName].ChartType = dataSourceChart.ChartType; + chart1.Series[dataSourceTeam.DataPointName].Name = dataSourceTeam.DataPointName; + chart1.Series[dataSourceTeam.DataPointName].IsValueShownAsLabel = true; + chart1.Series[dataSourceTeam.DataPointName].BorderWidth = 2; + chart1.Series[dataSourceTeam.DataPointName].Label = "#PERCENT{P1}"; + chart1.Series[dataSourceTeam.DataPointName]["DrawingStyle"] = "Cylinder"; + int m = 0; + foreach (Model.DataSourcePoint dataSourcePoint in dataSourceTeam.DataSourcePoints) + { + chart1.Series[dataSourceTeam.DataPointName].Points.AddXY(dataSourcePoint.PointText, dataSourcePoint.PointValue); + chart1.Series[dataSourceTeam.DataPointName].Points[m].LegendText = dataSourcePoint.PointText + "#PERCENT{P1}"; + m++; + } + } + } + } + else + { + foreach (Model.DataSourceTeam dataSourceTeam in dataSourceChart.DataSourceTeams) + { + this.lblTotal.Text = "绱鍊间负锛"; + if (dataSourceTeam.DataPointName == "绱") + { + foreach (Model.DataSourcePoint dataSourcePoint in dataSourceTeam.DataSourcePoints) + { + this.lblTotal.Text += (dataSourcePoint.PointText + "锛" + dataSourcePoint.PointValue + ","); + } + if (this.lblTotal.Text != "绱鍊间负锛") + { + this.lblTotal.Text = this.lblTotal.Text.Substring(0, this.lblTotal.Text.LastIndexOf(",")); + } + } + else + { + this.lblTotal.Visible = false; + chart1.Series.Add(dataSourceTeam.DataPointName); + chart1.Series[dataSourceTeam.DataPointName].ChartType = dataSourceChart.ChartType; + chart1.Series[dataSourceTeam.DataPointName].Name = dataSourceTeam.DataPointName; + chart1.Series[dataSourceTeam.DataPointName].IsValueShownAsLabel = true; + chart1.Series[dataSourceTeam.DataPointName].BorderWidth = 2; + chart1.Series[dataSourceTeam.DataPointName]["DrawingStyle"] = "Cylinder"; + + chart1.Series[dataSourceTeam.DataPointName].Label = "#VAL{P}";//璁剧疆鏍囩鏂囨湰 (鍦ㄨ璁℃湡閫氳繃灞炴х獥鍙g紪杈戞洿鐩磋) + chart1.Series[dataSourceTeam.DataPointName].IsValueShownAsLabel = true;//鏄剧ず鏍囩 + if (dataSourceTeam.DataPointName == "Actual Finished(%)") + { + chart1.Series[dataSourceTeam.DataPointName].Color = Color.Red; + } + else { + chart1.Series[dataSourceTeam.DataPointName].Color = Color.Blue; + } + foreach (Model.DataSourcePoint dataSourcePoint in dataSourceTeam.DataSourcePoints) + { + chart1.Series[dataSourceTeam.DataPointName].Points.AddXY(dataSourcePoint.PointText, dataSourcePoint.PointValue); + } + } + } + } + Controls.Add(chart1); + } } } \ No newline at end of file diff --git a/SGGL/FineUIPro.Web/ErrLog.txt b/SGGL/FineUIPro.Web/ErrLog.txt index 40871f48..479c4756 100644 --- a/SGGL/FineUIPro.Web/ErrLog.txt +++ b/SGGL/FineUIPro.Web/ErrLog.txt @@ -1,457 +1,77 @@ 閿欒淇℃伅寮濮=====> -閿欒绫诲瀷:ArgumentException -閿欒淇℃伅:鎻愪緵鐨 URI 鏂规鈥渉ttp鈥濇棤鏁堬紝搴斾负鈥渉ttps鈥濄 -鍙傛暟鍚: via +閿欒绫诲瀷:SqlException +閿欒淇℃伅:鎵ц瓒呮椂宸茶繃鏈熴傚畬鎴愭搷浣滀箣鍓嶅凡瓒呮椂鎴栨湇鍔″櫒鏈搷搴斻 閿欒鍫嗘爤: - 鍦 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.CNCECHSSEService.HSSEServiceClient.GetSupervise_SubUnitReportListToSUB() 浣嶇疆 E:\浜旂幆\SGGL_CWCEC\SGGL\BLL\Service References\CNCECHSSEService\Reference.cs:琛屽彿 14204 - 鍦 BLL.CNCECHSSEWebService.getSupervise_SubUnitReport() 浣嶇疆 E:\浜旂幆\SGGL_CWCEC\SGGL\BLL\WebService\CNCECHSSEWebService.cs:琛屽彿 2181 -鍑洪敊鏃堕棿:01/23/2024 12:21:40 -鍑洪敊鏃堕棿:01/23/2024 12:21:40 - - -閿欒淇℃伅寮濮=====> -閿欒绫诲瀷:ArgumentException -閿欒淇℃伅:鎻愪緵鐨 URI 鏂规鈥渉ttp鈥濇棤鏁堬紝搴斾负鈥渉ttps鈥濄 -鍙傛暟鍚: 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.CNCECHSSEService.HSSEServiceClient.GetCheck_CheckInfo_Table8ItemListToSUB(String unitId) 浣嶇疆 E:\浜旂幆\SGGL_CWCEC\SGGL\BLL\Service References\CNCECHSSEService\Reference.cs:琛屽彿 14228 - 鍦 BLL.CNCECHSSEWebService.getCheck_CheckInfo_Table8Item() 浣嶇疆 E:\浜旂幆\SGGL_CWCEC\SGGL\BLL\WebService\CNCECHSSEWebService.cs:琛屽彿 2046 -鍑洪敊鏃堕棿:01/23/2024 12:21:41 -鍑洪敊鏃堕棿:01/23/2024 12:21:41 - - -閿欒淇℃伅寮濮=====> -閿欒绫诲瀷:ArgumentException -閿欒淇℃伅:鎻愪緵鐨 URI 鏂规鈥渉ttp鈥濇棤鏁堬紝搴斾负鈥渉ttps鈥濄 -鍙傛暟鍚: 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.CNCECHSSEService.HSSEServiceClient.GetCheck_CheckRectifyListToSUB(String unitId) 浣嶇疆 E:\浜旂幆\SGGL_CWCEC\SGGL\BLL\Service References\CNCECHSSEService\Reference.cs:琛屽彿 14220 - 鍦 BLL.CNCECHSSEWebService.getCheck_CheckRectify() 浣嶇疆 E:\浜旂幆\SGGL_CWCEC\SGGL\BLL\WebService\CNCECHSSEWebService.cs:琛屽彿 1942 -鍑洪敊鏃堕棿:01/23/2024 12:21:41 -鍑洪敊鏃堕棿:01/23/2024 12:21:41 - - -閿欒淇℃伅寮濮=====> -閿欒绫诲瀷:ArgumentException -閿欒淇℃伅:鎻愪緵鐨 URI 鏂规鈥渉ttp鈥濇棤鏁堬紝搴斾负鈥渉ttps鈥濄 -鍙傛暟鍚: 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.CNCECHSSEService.HSSEServiceClient.GetInformation_UrgeReportToSUB(String unitId) 浣嶇疆 E:\浜旂幆\SGGL_CWCEC\SGGL\BLL\Service References\CNCECHSSEService\Reference.cs:琛屽彿 14020 - 鍦 BLL.CNCECHSSEWebService.getInformation_UrgeReport() 浣嶇疆 E:\浜旂幆\SGGL_CWCEC\SGGL\BLL\WebService\CNCECHSSEWebService.cs:琛屽彿 1884 -鍑洪敊鏃堕棿:01/23/2024 12:21:41 -鍑洪敊鏃堕棿:01/23/2024 12:21:41 - - -閿欒淇℃伅寮濮=====> -閿欒绫诲瀷:HttpParseException -閿欒淇℃伅:鍩虹被鍖呮嫭瀛楁鈥渢xtRemark鈥濓紝浣嗗叾绫诲瀷(FineUIPro.TextBox)涓庢帶浠(FineUIPro.TextArea)鐨勭被鍨嬩笉鍏煎銆 -閿欒鍫嗘爤: - 鍦 System.Web.Compilation.BaseTemplateCodeDomTreeGenerator.BuildFieldDeclaration(ControlBuilder builder) - 鍦 System.Web.Compilation.BaseTemplateCodeDomTreeGenerator.BuildSourceDataTreeFromBuilder(ControlBuilder builder, Boolean fInTemplate, Boolean topLevelControlInTemplate, PropertyEntry pse) - 鍦 System.Web.Compilation.BaseTemplateCodeDomTreeGenerator.BuildSourceDataTreeFromBuilder(ControlBuilder builder, Boolean fInTemplate, Boolean topLevelControlInTemplate, PropertyEntry pse) - 鍦 System.Web.Compilation.BaseTemplateCodeDomTreeGenerator.BuildSourceDataTreeFromBuilder(ControlBuilder builder, Boolean fInTemplate, Boolean topLevelControlInTemplate, PropertyEntry pse) - 鍦 System.Web.Compilation.BaseTemplateCodeDomTreeGenerator.BuildSourceDataTreeFromBuilder(ControlBuilder builder, Boolean fInTemplate, Boolean topLevelControlInTemplate, PropertyEntry pse) - 鍦 System.Web.Compilation.BaseTemplateCodeDomTreeGenerator.BuildSourceDataTreeFromBuilder(ControlBuilder builder, Boolean fInTemplate, Boolean topLevelControlInTemplate, PropertyEntry pse) - 鍦 System.Web.Compilation.BaseTemplateCodeDomTreeGenerator.BuildSourceDataTreeFromBuilder(ControlBuilder builder, Boolean fInTemplate, Boolean topLevelControlInTemplate, PropertyEntry pse) - 鍦 System.Web.Compilation.BaseTemplateCodeDomTreeGenerator.BuildSourceDataTreeFromBuilder(ControlBuilder builder, Boolean fInTemplate, Boolean topLevelControlInTemplate, PropertyEntry pse) - 鍦 System.Web.Compilation.BaseTemplateCodeDomTreeGenerator.BuildSourceDataTreeFromBuilder(ControlBuilder builder, Boolean fInTemplate, Boolean topLevelControlInTemplate, PropertyEntry pse) - 鍦 System.Web.Compilation.BaseTemplateCodeDomTreeGenerator.BuildSourceDataTreeFromBuilder(ControlBuilder builder, Boolean fInTemplate, Boolean topLevelControlInTemplate, PropertyEntry pse) - 鍦 System.Web.Compilation.BaseTemplateCodeDomTreeGenerator.BuildSourceDataTreeFromBuilder(ControlBuilder builder, Boolean fInTemplate, Boolean topLevelControlInTemplate, PropertyEntry pse) - 鍦 System.Web.Compilation.BaseTemplateCodeDomTreeGenerator.BuildSourceDataTreeFromBuilder(ControlBuilder builder, Boolean fInTemplate, Boolean topLevelControlInTemplate, PropertyEntry pse) - 鍦 System.Web.Compilation.BaseTemplateCodeDomTreeGenerator.BuildSourceDataTreeFromBuilder(ControlBuilder builder, Boolean fInTemplate, Boolean topLevelControlInTemplate, PropertyEntry pse) - 鍦 System.Web.Compilation.TemplateControlCodeDomTreeGenerator.BuildMiscClassMembers() - 鍦 System.Web.Compilation.PageCodeDomTreeGenerator.BuildMiscClassMembers() - 鍦 System.Web.Compilation.BaseCodeDomTreeGenerator.BuildSourceDataTree() - 鍦 System.Web.Compilation.BaseCodeDomTreeGenerator.GetCodeDomTree(CodeDomProvider codeDomProvider, StringResourceBuilder stringResourceBuilder, VirtualPath virtualPath) - 鍦 System.Web.Compilation.BaseTemplateBuildProvider.GenerateCode(AssemblyBuilder assemblyBuilder) - 鍦 System.Web.Compilation.AssemblyBuilder.AddBuildProvider(BuildProvider buildProvider) -鍑洪敊鏃堕棿:01/24/2024 19:37:42 -鍑洪敊鏂囦欢:http://localhost:8579/TestRun/PersonTrain/TrainContractEdit.aspx?id=684accf8-74c8-4ba7-817f-914011ab0a03 -IP鍦板潃:::1 - -鍑洪敊鏃堕棿:01/24/2024 19:37:42 - - -閿欒淇℃伅寮濮=====> -閿欒绫诲瀷:ArgumentException -閿欒淇℃伅:鎻愪緵鐨 URI 鏂规鈥渉ttp鈥濇棤鏁堬紝搴斾负鈥渉ttps鈥濄 -鍙傛暟鍚: 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.CNCECHSSEService.HSSEServiceClient.GetSupervise_SubUnitReportListToSUB() 浣嶇疆 E:\宸ヤ綔\浜旂幆鏂藉伐骞冲彴\SGGL_CWCEC\SGGL\BLL\Service References\CNCECHSSEService\Reference.cs:琛屽彿 14204 - 鍦 BLL.CNCECHSSEWebService.getSupervise_SubUnitReport() 浣嶇疆 E:\宸ヤ綔\浜旂幆鏂藉伐骞冲彴\SGGL_CWCEC\SGGL\BLL\WebService\CNCECHSSEWebService.cs:琛屽彿 2181 -鍑洪敊鏃堕棿:01/25/2024 12:39:51 -鍑洪敊鏃堕棿:01/25/2024 12:39:51 - - -閿欒淇℃伅寮濮=====> -閿欒绫诲瀷:ArgumentException -閿欒淇℃伅:鎻愪緵鐨 URI 鏂规鈥渉ttp鈥濇棤鏁堬紝搴斾负鈥渉ttps鈥濄 -鍙傛暟鍚: 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.CNCECHSSEService.HSSEServiceClient.GetCheck_CheckInfo_Table8ItemListToSUB(String unitId) 浣嶇疆 E:\宸ヤ綔\浜旂幆鏂藉伐骞冲彴\SGGL_CWCEC\SGGL\BLL\Service References\CNCECHSSEService\Reference.cs:琛屽彿 14228 - 鍦 BLL.CNCECHSSEWebService.getCheck_CheckInfo_Table8Item() 浣嶇疆 E:\宸ヤ綔\浜旂幆鏂藉伐骞冲彴\SGGL_CWCEC\SGGL\BLL\WebService\CNCECHSSEWebService.cs:琛屽彿 2046 -鍑洪敊鏃堕棿:01/25/2024 12:39:51 -鍑洪敊鏃堕棿:01/25/2024 12:39:51 - - -閿欒淇℃伅寮濮=====> -閿欒绫诲瀷:ArgumentException -閿欒淇℃伅:鎻愪緵鐨 URI 鏂规鈥渉ttp鈥濇棤鏁堬紝搴斾负鈥渉ttps鈥濄 -鍙傛暟鍚: 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.CNCECHSSEService.HSSEServiceClient.GetCheck_CheckRectifyListToSUB(String unitId) 浣嶇疆 E:\宸ヤ綔\浜旂幆鏂藉伐骞冲彴\SGGL_CWCEC\SGGL\BLL\Service References\CNCECHSSEService\Reference.cs:琛屽彿 14220 - 鍦 BLL.CNCECHSSEWebService.getCheck_CheckRectify() 浣嶇疆 E:\宸ヤ綔\浜旂幆鏂藉伐骞冲彴\SGGL_CWCEC\SGGL\BLL\WebService\CNCECHSSEWebService.cs:琛屽彿 1942 -鍑洪敊鏃堕棿:01/25/2024 12:39:51 -鍑洪敊鏃堕棿:01/25/2024 12:39:51 - - -閿欒淇℃伅寮濮=====> -閿欒绫诲瀷:ArgumentException -閿欒淇℃伅:鎻愪緵鐨 URI 鏂规鈥渉ttp鈥濇棤鏁堬紝搴斾负鈥渉ttps鈥濄 -鍙傛暟鍚: 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.CNCECHSSEService.HSSEServiceClient.GetInformation_UrgeReportToSUB(String unitId) 浣嶇疆 E:\宸ヤ綔\浜旂幆鏂藉伐骞冲彴\SGGL_CWCEC\SGGL\BLL\Service References\CNCECHSSEService\Reference.cs:琛屽彿 14020 - 鍦 BLL.CNCECHSSEWebService.getInformation_UrgeReport() 浣嶇疆 E:\宸ヤ綔\浜旂幆鏂藉伐骞冲彴\SGGL_CWCEC\SGGL\BLL\WebService\CNCECHSSEWebService.cs:琛屽彿 1884 -鍑洪敊鏃堕棿:01/25/2024 12:39:51 -鍑洪敊鏃堕棿:01/25/2024 12:39:51 - - -閿欒淇℃伅寮濮=====> -閿欒绫诲瀷:FileNotFoundException -閿欒淇℃伅:鏈兘鎵惧埌鏂囦欢鈥淓:\宸ヤ綔\浜旂幆鏂藉伐骞冲彴\CNCEC_SUBQHSE_WUHUAN\SGGL\FineUIPro.Web\common\Menu_Transfer.xml鈥濄 -閿欒鍫嗘爤: - 鍦 System.IO.__Error.WinIOError(Int32 errorCode, String maybeFullPath) - 鍦 System.IO.FileStream.Init(String path, FileMode mode, FileAccess access, Int32 rights, Boolean useRights, FileShare share, Int32 bufferSize, FileOptions options, SECURITY_ATTRIBUTES secAttrs, String msgPath, Boolean bFromProxy, Boolean useLongPath, Boolean checkHost) - 鍦 System.IO.FileStream..ctor(String path, FileMode mode, FileAccess access, FileShare share) - 鍦 System.Web.UI.Control.OpenFileAndGetDependency(VirtualPath virtualPath, String physicalPath, CacheDependency& dependency) - 鍦 System.Web.UI.WebControls.XmlDataSource.GetReader(String path, String content, CacheDependency& cacheDependency) - 鍦 System.Web.UI.WebControls.XmlDataSource.PopulateXmlDocument(XmlDocument document, CacheDependency& dataCacheDependency, CacheDependency& transformCacheDependency) - 鍦 System.Web.UI.WebControls.XmlDataSource.GetXmlDocument() - 鍦 FineUIPro.Web.indexProject.InitTreeMenu() 浣嶇疆 E:\宸ヤ綔\浜旂幆鏂藉伐骞冲彴\CNCEC_SUBQHSE_WUHUAN\SGGL\FineUIPro.Web\indexProject.aspx.cs:琛屽彿 102 - 鍦 FineUIPro.Web.indexProject.MenuSwitchMethod(String type) 浣嶇疆 E:\宸ヤ綔\浜旂幆鏂藉伐骞冲彴\CNCEC_SUBQHSE_WUHUAN\SGGL\FineUIPro.Web\indexProject.aspx.cs:琛屽彿 728 - 鍦 FineUIPro.Web.indexProject.btnTransfer_Click(Object sender, EventArgs e) 浣嶇疆 E:\宸ヤ綔\浜旂幆鏂藉伐骞冲彴\CNCEC_SUBQHSE_WUHUAN\SGGL\FineUIPro.Web\indexProject.aspx.cs:琛屽彿 786 - 鍦 FineUIPro.Button.OnClick(EventArgs e) - 鍦 (Button , EventArgs ) - 鍦 FineUIPro.Button.RaisePostBackEvent(String eventArgument) - 鍦 System.Web.UI.Page.RaisePostBackEvent(IPostBackEventHandler sourceControl, String eventArgument) - 鍦 System.Web.UI.Page.RaisePostBackEvent(NameValueCollection postData) + 鍦 System.Data.SqlClient.SqlConnection.OnError(SqlException exception, Boolean breakConnection, Action`1 wrapCloseInAction) + 鍦 System.Data.SqlClient.SqlInternalConnection.OnError(SqlException exception, Boolean breakConnection, Action`1 wrapCloseInAction) + 鍦 System.Data.SqlClient.TdsParser.ThrowExceptionAndWarning(TdsParserStateObject stateObj, Boolean callerHasConnectionLock, Boolean asyncClose) + 鍦 System.Data.SqlClient.TdsParser.TryRun(RunBehavior runBehavior, SqlCommand cmdHandler, SqlDataReader dataStream, BulkCopySimpleResultSet bulkCopyHandler, TdsParserStateObject stateObj, Boolean& dataReady) + 鍦 System.Data.SqlClient.SqlDataReader.TryConsumeMetaData() + 鍦 System.Data.SqlClient.SqlDataReader.get_MetaData() + 鍦 System.Data.SqlClient.SqlCommand.FinishExecuteReader(SqlDataReader ds, RunBehavior runBehavior, String resetOptionsString, Boolean isInternal, Boolean forDescribeParameterEncryption, Boolean shouldCacheForAlwaysEncrypted) + 鍦 System.Data.SqlClient.SqlCommand.RunExecuteReaderTds(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, Boolean async, Int32 timeout, Task& task, Boolean asyncWrite, Boolean inRetry, SqlDataReader ds, Boolean describeParameterEncryptionRequest) + 鍦 System.Data.SqlClient.SqlCommand.RunExecuteReader(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, String method, TaskCompletionSource`1 completion, Int32 timeout, Task& task, Boolean& usedCache, Boolean asyncWrite, Boolean inRetry) + 鍦 System.Data.SqlClient.SqlCommand.RunExecuteReader(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, String method) + 鍦 System.Data.SqlClient.SqlCommand.ExecuteReader(CommandBehavior behavior, String method) + 鍦 System.Data.SqlClient.SqlCommand.ExecuteDbDataReader(CommandBehavior behavior) + 鍦 System.Data.Common.DbCommand.ExecuteReader() + 鍦 System.Data.Linq.SqlClient.SqlProvider.Execute(Expression query, QueryInfo queryInfo, IObjectReaderFactory factory, Object[] parentArgs, Object[] userArgs, ICompiledSubQuery[] subQueries, Object lastResult) + 鍦 System.Data.Linq.SqlClient.SqlProvider.ExecuteAll(Expression query, QueryInfo[] queryInfos, IObjectReaderFactory factory, Object[] userArguments, ICompiledSubQuery[] subQueries) + 鍦 System.Data.Linq.SqlClient.SqlProvider.System.Data.Linq.Provider.IProvider.Execute(Expression query) + 鍦 System.Data.Linq.DataQuery`1.System.Linq.IQueryProvider.Execute[S](Expression expression) + 鍦 System.Linq.Queryable.Count[TSource](IQueryable`1 source) + 鍦 FineUIPro.Web.common.main_new.Page_Load(Object sender, EventArgs e) 浣嶇疆 E:\2023鍏徃椤圭洰\浜旂幆鏂癨CNCEC_SUBQHSE_WUHUAN\SGGL\FineUIPro.Web\common\main_new.aspx.cs:琛屽彿 67 + 鍦 System.Web.Util.CalliEventHandlerDelegateProxy.Callback(Object sender, EventArgs e) + 鍦 System.EventHandler.Invoke(Object sender, EventArgs e) + 鍦 System.Web.UI.Control.OnLoad(EventArgs e) + 鍦 System.Web.UI.Control.LoadRecursive() 鍦 System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) -鍑洪敊鏃堕棿:01/26/2024 09:14:17 -鍑洪敊鏂囦欢:http://localhost:8579/indexProject.aspx?projectId=05a4f675-0caa-4e9e-b171-fc2b7d7ba025 -IP鍦板潃:::1 -鎿嶄綔浜哄憳:JT - -鍑洪敊鏃堕棿:01/26/2024 09:14:17 - - -閿欒淇℃伅寮濮=====> -閿欒绫诲瀷:FileNotFoundException -閿欒淇℃伅:鏈兘鎵惧埌鏂囦欢鈥淓:\宸ヤ綔\浜旂幆鏂藉伐骞冲彴\CNCEC_SUBQHSE_WUHUAN\SGGL\FineUIPro.Web\common\Menu_Transfer.xml鈥濄 -閿欒鍫嗘爤: - 鍦 System.IO.__Error.WinIOError(Int32 errorCode, String maybeFullPath) - 鍦 System.IO.FileStream.Init(String path, FileMode mode, FileAccess access, Int32 rights, Boolean useRights, FileShare share, Int32 bufferSize, FileOptions options, SECURITY_ATTRIBUTES secAttrs, String msgPath, Boolean bFromProxy, Boolean useLongPath, Boolean checkHost) - 鍦 System.IO.FileStream..ctor(String path, FileMode mode, FileAccess access, FileShare share) - 鍦 System.Web.UI.Control.OpenFileAndGetDependency(VirtualPath virtualPath, String physicalPath, CacheDependency& dependency) - 鍦 System.Web.UI.WebControls.XmlDataSource.GetReader(String path, String content, CacheDependency& cacheDependency) - 鍦 System.Web.UI.WebControls.XmlDataSource.PopulateXmlDocument(XmlDocument document, CacheDependency& dataCacheDependency, CacheDependency& transformCacheDependency) - 鍦 System.Web.UI.WebControls.XmlDataSource.GetXmlDocument() - 鍦 FineUIPro.Web.indexProject.InitTreeMenu() 浣嶇疆 E:\宸ヤ綔\浜旂幆鏂藉伐骞冲彴\CNCEC_SUBQHSE_WUHUAN\SGGL\FineUIPro.Web\indexProject.aspx.cs:琛屽彿 102 - 鍦 FineUIPro.Web.indexProject.MenuSwitchMethod(String type) 浣嶇疆 E:\宸ヤ綔\浜旂幆鏂藉伐骞冲彴\CNCEC_SUBQHSE_WUHUAN\SGGL\FineUIPro.Web\indexProject.aspx.cs:琛屽彿 728 - 鍦 FineUIPro.Web.indexProject.btnTransfer_Click(Object sender, EventArgs e) 浣嶇疆 E:\宸ヤ綔\浜旂幆鏂藉伐骞冲彴\CNCEC_SUBQHSE_WUHUAN\SGGL\FineUIPro.Web\indexProject.aspx.cs:琛屽彿 786 - 鍦 FineUIPro.Button.OnClick(EventArgs e) - 鍦 (Button , EventArgs ) - 鍦 FineUIPro.Button.RaisePostBackEvent(String eventArgument) - 鍦 System.Web.UI.Page.RaisePostBackEvent(IPostBackEventHandler sourceControl, String eventArgument) - 鍦 System.Web.UI.Page.RaisePostBackEvent(NameValueCollection postData) - 鍦 System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) -鍑洪敊鏃堕棿:01/26/2024 09:14:20 -鍑洪敊鏂囦欢:http://localhost:8579/indexProject.aspx?projectId=05a4f675-0caa-4e9e-b171-fc2b7d7ba025 -IP鍦板潃:::1 -鎿嶄綔浜哄憳:JT - -鍑洪敊鏃堕棿:01/26/2024 09:14:20 - - -閿欒淇℃伅寮濮=====> -閿欒绫诲瀷:HttpException -閿欒淇℃伅:鏂囦欢鈥/common/mainMenu_Transfer.aspx鈥濅笉瀛樺湪銆 -閿欒鍫嗘爤: - 鍦 System.Web.UI.Util.CheckVirtualFileExists(VirtualPath virtualPath) - 鍦 System.Web.Compilation.BuildManager.GetVPathBuildResultInternal(VirtualPath virtualPath, Boolean noBuild, Boolean allowCrossApp, Boolean allowBuildInPrecompile, Boolean throwIfNotFound, Boolean ensureIsUpToDate) - 鍦 System.Web.Compilation.BuildManager.GetVPathBuildResultWithNoAssert(HttpContext context, VirtualPath virtualPath, Boolean noBuild, Boolean allowCrossApp, Boolean allowBuildInPrecompile, Boolean throwIfNotFound, Boolean ensureIsUpToDate) - 鍦 System.Web.Compilation.BuildManager.GetVirtualPathObjectFactory(VirtualPath virtualPath, HttpContext context, Boolean allowCrossApp, Boolean throwIfNotFound) - 鍦 System.Web.Compilation.BuildManager.CreateInstanceFromVirtualPath(VirtualPath virtualPath, Type requiredBaseType, HttpContext context, Boolean allowCrossApp) - 鍦 System.Web.UI.PageHandlerFactory.GetHandlerHelper(HttpContext context, String requestType, VirtualPath virtualPath, String physicalPath) - 鍦 System.Web.UI.PageHandlerFactory.GetHandler(HttpContext context, String requestType, String virtualPath, String path) - 鍦 System.Web.HttpApplication.MaterializeHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute() - 鍦 System.Web.HttpApplication.ExecuteStepImpl(IExecutionStep step) - 鍦 System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously) -鍑洪敊鏃堕棿:01/26/2024 09:42:36 -鍑洪敊鏂囦欢:http://localhost:8579/common/mainMenu_Transfer.aspx -IP鍦板潃:::1 - -鍑洪敊鏃堕棿:01/26/2024 09:42:36 - - -閿欒淇℃伅寮濮=====> -閿欒绫诲瀷:HttpException -閿欒淇℃伅:鏂囦欢鈥/common/mainMenu_Transfer.aspx鈥濅笉瀛樺湪銆 -閿欒鍫嗘爤: - 鍦 System.Web.UI.Util.CheckVirtualFileExists(VirtualPath virtualPath) - 鍦 System.Web.Compilation.BuildManager.GetVPathBuildResultInternal(VirtualPath virtualPath, Boolean noBuild, Boolean allowCrossApp, Boolean allowBuildInPrecompile, Boolean throwIfNotFound, Boolean ensureIsUpToDate) - 鍦 System.Web.Compilation.BuildManager.GetVPathBuildResultWithNoAssert(HttpContext context, VirtualPath virtualPath, Boolean noBuild, Boolean allowCrossApp, Boolean allowBuildInPrecompile, Boolean throwIfNotFound, Boolean ensureIsUpToDate) - 鍦 System.Web.Compilation.BuildManager.GetVirtualPathObjectFactory(VirtualPath virtualPath, HttpContext context, Boolean allowCrossApp, Boolean throwIfNotFound) - 鍦 System.Web.Compilation.BuildManager.CreateInstanceFromVirtualPath(VirtualPath virtualPath, Type requiredBaseType, HttpContext context, Boolean allowCrossApp) - 鍦 System.Web.UI.PageHandlerFactory.GetHandlerHelper(HttpContext context, String requestType, VirtualPath virtualPath, String physicalPath) - 鍦 System.Web.UI.PageHandlerFactory.GetHandler(HttpContext context, String requestType, String virtualPath, String path) - 鍦 System.Web.HttpApplication.MaterializeHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute() - 鍦 System.Web.HttpApplication.ExecuteStepImpl(IExecutionStep step) - 鍦 System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously) -鍑洪敊鏃堕棿:01/26/2024 09:47:07 -鍑洪敊鏂囦欢:http://localhost:8579/common/mainMenu_Transfer.aspx -IP鍦板潃:::1 - -鍑洪敊鏃堕棿:01/26/2024 09:47:07 - - -閿欒淇℃伅寮濮=====> -閿欒绫诲瀷:HttpParseException -閿欒淇℃伅:鏈兘鍔犺浇绫诲瀷鈥淔ineUIPro.Web.common.mainMenu_Transfer鈥濄 -閿欒鍫嗘爤: - 鍦 System.Web.UI.TemplateParser.ProcessException(Exception ex) - 鍦 System.Web.UI.TemplateParser.ParseStringInternal(String text, Encoding fileEncoding) - 鍦 System.Web.UI.TemplateParser.ParseString(String text, VirtualPath virtualPath, Encoding fileEncoding) -----閿欒绫诲瀷:HttpException +----閿欒绫诲瀷:Win32Exception ----閿欒淇℃伅: -----鏈兘鍔犺浇绫诲瀷鈥淔ineUIPro.Web.common.mainMenu_Transfer鈥濄 +----绛夊緟鐨勬搷浣滆繃鏃躲 ----閿欒鍫嗘爤: - 鍦 System.Web.UI.TemplateParser.GetType(String typeName, Boolean ignoreCase, Boolean throwOnError) - 鍦 System.Web.UI.TemplateParser.ProcessInheritsAttribute(String baseTypeName, String codeFileBaseTypeName, String src, Assembly assembly) - 鍦 System.Web.UI.TemplateParser.PostProcessMainDirectiveAttributes(IDictionary parseData) -鍑洪敊鏃堕棿:01/26/2024 09:47:58 -鍑洪敊鏂囦欢:http://localhost:8579/common/mainMenu_Transfer.aspx + 鍑洪敊鏃堕棿:02/02/2024 11:24:03 +鍑洪敊鏂囦欢:http://localhost:8579/common/main_new.aspx IP鍦板潃:::1 +鎿嶄綔浜哄憳:JT -鍑洪敊鏃堕棿:01/26/2024 09:47:58 +鍑洪敊鏃堕棿:02/02/2024 11:24:12 閿欒淇℃伅寮濮=====> -閿欒绫诲瀷:ArgumentException -閿欒淇℃伅:鎻愪緵鐨 URI 鏂规鈥渉ttp鈥濇棤鏁堬紝搴斾负鈥渉ttps鈥濄 -鍙傛暟鍚: via +閿欒绫诲瀷:SqlException +閿欒淇℃伅:鍙傛暟鍖栨煡璇 '(@ProjectId nvarchar(4000))select * from Transfer_Piping C + ' 闇瑕佸弬鏁 '@ProjectId'锛屼絾鏈彁渚涜鍙傛暟銆 閿欒鍫嗘爤: - 鍦 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 + 鍦 System.Data.SqlClient.SqlConnection.OnError(SqlException exception, Boolean breakConnection, Action`1 wrapCloseInAction) + 鍦 System.Data.SqlClient.SqlInternalConnection.OnError(SqlException exception, Boolean breakConnection, Action`1 wrapCloseInAction) + 鍦 System.Data.SqlClient.TdsParser.ThrowExceptionAndWarning(TdsParserStateObject stateObj, Boolean callerHasConnectionLock, Boolean asyncClose) + 鍦 System.Data.SqlClient.TdsParser.TryRun(RunBehavior runBehavior, SqlCommand cmdHandler, SqlDataReader dataStream, BulkCopySimpleResultSet bulkCopyHandler, TdsParserStateObject stateObj, Boolean& dataReady) + 鍦 System.Data.SqlClient.SqlDataReader.TryConsumeMetaData() + 鍦 System.Data.SqlClient.SqlDataReader.get_MetaData() + 鍦 System.Data.SqlClient.SqlCommand.FinishExecuteReader(SqlDataReader ds, RunBehavior runBehavior, String resetOptionsString, Boolean isInternal, Boolean forDescribeParameterEncryption, Boolean shouldCacheForAlwaysEncrypted) + 鍦 System.Data.SqlClient.SqlCommand.RunExecuteReaderTds(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, Boolean async, Int32 timeout, Task& task, Boolean asyncWrite, Boolean inRetry, SqlDataReader ds, Boolean describeParameterEncryptionRequest) + 鍦 System.Data.SqlClient.SqlCommand.RunExecuteReader(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, String method, TaskCompletionSource`1 completion, Int32 timeout, Task& task, Boolean& usedCache, Boolean asyncWrite, Boolean inRetry) + 鍦 System.Data.SqlClient.SqlCommand.RunExecuteReader(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, String method) + 鍦 System.Data.SqlClient.SqlCommand.ExecuteReader(CommandBehavior behavior, String method) + 鍦 System.Data.SqlClient.SqlCommand.ExecuteDbDataReader(CommandBehavior behavior) + 鍦 System.Data.Common.DbCommand.System.Data.IDbCommand.ExecuteReader(CommandBehavior behavior) + 鍦 System.Data.Common.DbDataAdapter.FillInternal(DataSet dataset, DataTable[] datatables, Int32 startRecord, Int32 maxRecords, String srcTable, IDbCommand command, CommandBehavior behavior) + 鍦 System.Data.Common.DbDataAdapter.Fill(DataTable[] dataTables, Int32 startRecord, Int32 maxRecords, IDbCommand command, CommandBehavior behavior) + 鍦 System.Data.Common.DbDataAdapter.Fill(DataTable dataTable) + 鍦 BLL.SQLHelper.GetDataTableRunText(String strSql, SqlParameter[] parameters) 浣嶇疆 E:\2023鍏徃椤圭洰\浜旂幆鏂癨CNCEC_SUBQHSE_WUHUAN\SGGL\BLL\SQLHelper.cs:琛屽彿 311 + 鍦 FineUIPro.Web.Transfer.Piping.BindGrid() 浣嶇疆 E:\2023鍏徃椤圭洰\浜旂幆鏂癨CNCEC_SUBQHSE_WUHUAN\SGGL\FineUIPro.Web\Transfer\Piping.aspx.cs:琛屽彿 58 + 鍦 FineUIPro.Web.Transfer.Piping.Page_Load(Object sender, EventArgs e) 浣嶇疆 E:\2023鍏徃椤圭洰\浜旂幆鏂癨CNCEC_SUBQHSE_WUHUAN\SGGL\FineUIPro.Web\Transfer\Piping.aspx.cs:琛屽彿 24 + 鍦 System.Web.Util.CalliEventHandlerDelegateProxy.Callback(Object sender, EventArgs e) + 鍦 System.EventHandler.Invoke(Object sender, EventArgs e) + 鍦 System.Web.UI.Control.OnLoad(EventArgs e) + 鍦 System.Web.UI.Control.LoadRecursive() + 鍦 System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +鍑洪敊鏃堕棿:02/04/2024 10:42:45 +鍑洪敊鏂囦欢:http://localhost:8579/Transfer/Piping.aspx +IP鍦板潃:::1 +鎿嶄綔浜哄憳:JT - -閿欒淇℃伅寮濮=====> -閿欒绫诲瀷:ArgumentException -閿欒淇℃伅:鎻愪緵鐨 URI 鏂规鈥渉ttp鈥濇棤鏁堬紝搴斾负鈥渉ttps鈥濄 -鍙傛暟鍚: 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 鏂规鈥渉ttp鈥濇棤鏁堬紝搴斾负鈥渉ttps鈥濄 -鍙傛暟鍚: 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 鏂规鈥渉ttp鈥濇棤鏁堬紝搴斾负鈥渉ttps鈥濄 -鍙傛暟鍚: 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 +鍑洪敊鏃堕棿:02/04/2024 10:42:45 diff --git a/SGGL/FineUIPro.Web/File/Excel/DataIn/Piping瀵煎叆妯℃澘.xls b/SGGL/FineUIPro.Web/File/Excel/DataIn/Piping瀵煎叆妯℃澘.xls new file mode 100644 index 00000000..26f8263c Binary files /dev/null and b/SGGL/FineUIPro.Web/File/Excel/DataIn/Piping瀵煎叆妯℃澘.xls differ diff --git a/SGGL/FineUIPro.Web/File/Excel/DataIn/RotatingEquipment瀵煎叆妯℃澘.xls b/SGGL/FineUIPro.Web/File/Excel/DataIn/RotatingEquipment瀵煎叆妯℃澘.xls new file mode 100644 index 00000000..25111830 Binary files /dev/null and b/SGGL/FineUIPro.Web/File/Excel/DataIn/RotatingEquipment瀵煎叆妯℃澘.xls differ diff --git a/SGGL/FineUIPro.Web/File/Excel/DataIn/StaticEquipment瀵煎叆妯℃澘.xls b/SGGL/FineUIPro.Web/File/Excel/DataIn/StaticEquipment瀵煎叆妯℃澘.xls new file mode 100644 index 00000000..640e8001 Binary files /dev/null and b/SGGL/FineUIPro.Web/File/Excel/DataIn/StaticEquipment瀵煎叆妯℃澘.xls differ diff --git a/SGGL/FineUIPro.Web/File/Excel/TestRun/淇濊繍鑰冨嫟琛ㄦā鏉.xls b/SGGL/FineUIPro.Web/File/Excel/TestRun/淇濊繍鑰冨嫟琛ㄦā鏉.xls new file mode 100644 index 00000000..0c996796 Binary files /dev/null and b/SGGL/FineUIPro.Web/File/Excel/TestRun/淇濊繍鑰冨嫟琛ㄦā鏉.xls differ diff --git a/SGGL/FineUIPro.Web/FineUIPro.Web.csproj b/SGGL/FineUIPro.Web/FineUIPro.Web.csproj index 1beee8df..cb5ae160 100644 --- a/SGGL/FineUIPro.Web/FineUIPro.Web.csproj +++ b/SGGL/FineUIPro.Web/FineUIPro.Web.csproj @@ -244,6 +244,7 @@ + @@ -368,6 +369,7 @@ + @@ -1829,6 +1831,9 @@ + + + @@ -1840,12 +1845,17 @@ + + + + + @@ -6468,6 +6478,13 @@ TrainTypeEdit.aspx + + TransferMajor.aspx + ASPXCodeBehind + + + TransferMajor.aspx + UnitType.aspx ASPXCodeBehind @@ -6846,6 +6863,13 @@ themes.aspx + + DataImportControl.ascx + ASPXCodeBehind + + + DataImportControl.ascx + FlowOperateControl.ascx ASPXCodeBehind @@ -16341,6 +16365,27 @@ TestRunRecordUploadList.aspx + + Instrumentation.aspx + ASPXCodeBehind + + + Instrumentation.aspx + + + PunchlistFrom.aspx + ASPXCodeBehind + + + PunchlistFrom.aspx + + + TransferChart.aspx + ASPXCodeBehind + + + TransferChart.aspx + CivilStructure.aspx ASPXCodeBehind @@ -16418,6 +16463,13 @@ Piping.aspx + + PipingDataIn.aspx + ASPXCodeBehind + + + PipingDataIn.aspx + Plumbing.aspx ASPXCodeBehind @@ -16460,6 +16512,34 @@ PunchlistFromDataIn.aspx + + RotatingEquipment.aspx + ASPXCodeBehind + + + RotatingEquipment.aspx + + + RotatingEquipmentDataIn.aspx + ASPXCodeBehind + + + RotatingEquipmentDataIn.aspx + + + StaticEquipment.aspx + ASPXCodeBehind + + + StaticEquipment.aspx + + + StaticEquipmentDataIn.aspx + ASPXCodeBehind + + + StaticEquipmentDataIn.aspx + Telecom.aspx ASPXCodeBehind diff --git a/SGGL/FineUIPro.Web/TestRun/DriverPrepare/SchemePlan.aspx b/SGGL/FineUIPro.Web/TestRun/DriverPrepare/SchemePlan.aspx index 05f4efc6..209da8ac 100644 --- a/SGGL/FineUIPro.Web/TestRun/DriverPrepare/SchemePlan.aspx +++ b/SGGL/FineUIPro.Web/TestRun/DriverPrepare/SchemePlan.aspx @@ -28,6 +28,8 @@ + diff --git a/SGGL/FineUIPro.Web/TestRun/DriverPrepare/SchemePlan.aspx.cs b/SGGL/FineUIPro.Web/TestRun/DriverPrepare/SchemePlan.aspx.cs index 419f1737..0300fd86 100644 --- a/SGGL/FineUIPro.Web/TestRun/DriverPrepare/SchemePlan.aspx.cs +++ b/SGGL/FineUIPro.Web/TestRun/DriverPrepare/SchemePlan.aspx.cs @@ -97,6 +97,20 @@ namespace FineUIPro.Web.TestRun.DriverPrepare ShowNotify("鍒犻櫎鏁版嵁鎴愬姛!", MessageBoxIcon.Success); } } + + protected void btnDel_Click(object sender, EventArgs e) + { + var plan = (from x in Funs.DB.DriverPrepare_SchemePlan where x.ProjectId == this.CurrUser.LoginProjectId select x).FirstOrDefault(); + if (plan == null) + { + Alert.ShowInTop("椤圭洰鏃犺褰曪紝鏃犻渶鍒犻櫎锛", MessageBoxIcon.Warning); + return; + } + BLL.DriverPrepareSchemePlanItemService.DeleteSchemePlanItemByschemePlanId(plan.SchemePlanId); + BLL.DriverPrepareSchemePlanService.DeleteDriverPlan(plan.SchemePlanId); + BindGrid(); + ShowNotify("鍒犻櫎鏁版嵁鎴愬姛!", MessageBoxIcon.Success); + } #endregion #region 鏉冮檺璁剧疆 @@ -119,6 +133,7 @@ namespace FineUIPro.Web.TestRun.DriverPrepare } if (buttonList.Contains(BLL.Const.BtnDelete)) { + this.btnDel.Hidden = false; this.btnMenuDel.Hidden = false; } } diff --git a/SGGL/FineUIPro.Web/TestRun/DriverPrepare/SchemePlan.aspx.designer.cs b/SGGL/FineUIPro.Web/TestRun/DriverPrepare/SchemePlan.aspx.designer.cs index 39adf730..47e4ff3c 100644 --- a/SGGL/FineUIPro.Web/TestRun/DriverPrepare/SchemePlan.aspx.designer.cs +++ b/SGGL/FineUIPro.Web/TestRun/DriverPrepare/SchemePlan.aspx.designer.cs @@ -93,6 +93,15 @@ namespace FineUIPro.Web.TestRun.DriverPrepare { /// protected global::FineUIPro.Button btnOut; + /// + /// btnDel 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.Button btnDel; + /// /// Window1 鎺т欢銆 /// diff --git a/SGGL/FineUIPro.Web/TestRun/DriverRun/DriverRunPlan.aspx.cs b/SGGL/FineUIPro.Web/TestRun/DriverRun/DriverRunPlan.aspx.cs index e4cd5075..a550a026 100644 --- a/SGGL/FineUIPro.Web/TestRun/DriverRun/DriverRunPlan.aspx.cs +++ b/SGGL/FineUIPro.Web/TestRun/DriverRun/DriverRunPlan.aspx.cs @@ -41,7 +41,7 @@ namespace FineUIPro.Web.TestRun.DriverRun (CASE WHEN driverRun.IsAcceptInvite=1 THEN '鏄' ELSE '鍚' END) AS IsAcceptInvite, driverRun.AttachUrl, driverRun.Remark, - Unit.UnitName AS SubUnitName" + Unit.UnitName AS UnitName" + @" FROM DriverRun_DriverRunPlan AS driverRun" + @" LEFT JOIN Base_Unit AS Unit ON Unit.UnitId = driverRun.UnitId WHERE driverRun.ProjectId=@projectId"; List listStr = new List(); diff --git a/SGGL/FineUIPro.Web/TestRun/DriverRun/DriverRunPlanEdit.aspx b/SGGL/FineUIPro.Web/TestRun/DriverRun/DriverRunPlanEdit.aspx index d7305912..d97d5e98 100644 --- a/SGGL/FineUIPro.Web/TestRun/DriverRun/DriverRunPlanEdit.aspx +++ b/SGGL/FineUIPro.Web/TestRun/DriverRun/DriverRunPlanEdit.aspx @@ -4,12 +4,12 @@ - + 缂栬緫寮杞︿繚杩愯鍒
- + @@ -47,7 +47,7 @@ - + @@ -78,7 +78,11 @@ - + + + + + @@ -97,4 +101,4 @@ - \ No newline at end of file + diff --git a/SGGL/FineUIPro.Web/TestRun/DriverRun/DriverRunPlanEdit.aspx.cs b/SGGL/FineUIPro.Web/TestRun/DriverRun/DriverRunPlanEdit.aspx.cs index 9658a7fe..9408a891 100644 --- a/SGGL/FineUIPro.Web/TestRun/DriverRun/DriverRunPlanEdit.aspx.cs +++ b/SGGL/FineUIPro.Web/TestRun/DriverRun/DriverRunPlanEdit.aspx.cs @@ -1,5 +1,6 @@ 锘縰sing BLL; using System; +using System.IO; namespace FineUIPro.Web.TestRun.DriverRun { @@ -63,6 +64,57 @@ namespace FineUIPro.Web.TestRun.DriverRun } PageContext.RegisterStartupScript(WindowAtt.GetShowReference(String.Format("../../AttachFile/webuploader.aspx?type=0&toKeyId={0}&path=FileUpload/TestRun/DriverRun/DriverRunPlan&menuId={1}", this.hdId.Text, BLL.Const.DriverRunPlanMenuId))); } + + /// + /// 闄勪欢涓婁紶 + /// + /// + /// + protected void btnAttachK_Click(object sender, EventArgs e) + { + if (string.IsNullOrEmpty(this.hdId.Text)) //鏂板璁板綍 + { + this.hdId.Text = SQLHelper.GetNewID(typeof(Model.DriverRun_DriverRunPlan)); + } + PageContext.RegisterStartupScript(WindowAtt.GetShowReference(String.Format("../../AttachFile/webuploader.aspx?type=0&toKeyId={0}&path=FileUpload/TestRun/DriverRun/DriverRunPlan&menuId={1}", this.hdId.Text+"K", BLL.Const.DriverRunPlanMenuId))); + } + #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 + "File\\Excel\\TestRun\\淇濊繍鑰冨嫟琛ㄦā鏉.xls"; + string filePath = "File\\Excel\\TestRun\\淇濊繍鑰冨嫟琛ㄦā鏉.xls"; + 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 #region 淇濆瓨 diff --git a/SGGL/FineUIPro.Web/TestRun/DriverRun/DriverRunPlanEdit.aspx.designer.cs b/SGGL/FineUIPro.Web/TestRun/DriverRun/DriverRunPlanEdit.aspx.designer.cs index 026c7e3b..adba39d4 100644 --- a/SGGL/FineUIPro.Web/TestRun/DriverRun/DriverRunPlanEdit.aspx.designer.cs +++ b/SGGL/FineUIPro.Web/TestRun/DriverRun/DriverRunPlanEdit.aspx.designer.cs @@ -192,6 +192,24 @@ namespace FineUIPro.Web.TestRun.DriverRun { /// protected global::FineUIPro.Button btnAttach; + /// + /// btnAttachK 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.Button btnAttachK; + + /// + /// btnDownLoad 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.Button btnDownLoad; + /// /// WindowAtt 鎺т欢銆 /// diff --git a/SGGL/FineUIPro.Web/Transfer/Chart/Instrumentation.aspx b/SGGL/FineUIPro.Web/Transfer/Chart/Instrumentation.aspx new file mode 100644 index 00000000..fed1ca4d --- /dev/null +++ b/SGGL/FineUIPro.Web/Transfer/Chart/Instrumentation.aspx @@ -0,0 +1,111 @@ +锘<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="Instrumentation.aspx.cs" Inherits="FineUIPro.Web.Transfer.Chart.Instrumentation" %> + +<%@ Register Src="~/Controls/ChartControl.ascx" TagName="ChartControl" TagPrefix="uc1" %> + + + + + + + + +
+ + + + + + + + + + + + + + + + + + + + + + + + + <%-- + + + --%> + + <%-- + + + + --%> + + + + + + + + + + + + + + + + + + + +
+ +
+
+
+ + + <%-- + --%> + <%-- + --%> + + + + +
+
+
+
+
+
+
+ + + + + diff --git a/SGGL/FineUIPro.Web/Transfer/Chart/Instrumentation.aspx.cs b/SGGL/FineUIPro.Web/Transfer/Chart/Instrumentation.aspx.cs new file mode 100644 index 00000000..52903623 --- /dev/null +++ b/SGGL/FineUIPro.Web/Transfer/Chart/Instrumentation.aspx.cs @@ -0,0 +1,508 @@ +锘縰sing System; +using System.Collections.Generic; +using System.Data; +using System.Linq; +using BLL; + +namespace FineUIPro.Web.Transfer.Chart +{ + public partial class Instrumentation : PageBase + { + #region 瀹氫箟椤 + /// + /// 椤圭洰涓婚敭 + /// + public string ProjectId + { + get + { + return (string)ViewState["ProjectId"]; + } + set + { + ViewState["ProjectId"] = value; + } + } + #endregion + + #region 鍔犺浇椤甸潰 + /// + /// 鍔犺浇椤甸潰 + /// + /// + /// + protected void Page_Load(object sender, EventArgs e) + { + if (!IsPostBack) + { + this.ProjectId = this.CurrUser.LoginProjectId; + if (!string.IsNullOrEmpty(Request.Params["projectId"])) + { + this.ProjectId = Request.Params["projectId"]; + } + + //this.AnalyseData(); + } + } + #endregion + + protected void drpdateType_SelectedIndexChanged(object sender, EventArgs e) { + if (drpdateType.SelectedValue == "0") + { + txtStarTime.Hidden = false; + txtEndTime.Hidden = false; + + txtStarTime1.Hidden = true; + txtEndTime1.Hidden = true; + } + else { + txtStarTime1.Hidden = false; + txtEndTime1.Hidden = false; + + txtStarTime.Hidden = true; + txtEndTime.Hidden = true; + } + } + + #region 缁熻 + /// + /// 缁熻鏂规硶 + /// + private void AnalyseData() + { + if (string.IsNullOrEmpty(ProjectId)) + { + Alert.ShowInTop("椤圭洰鏈幏鍙栧埌锛岃鍒锋柊椤甸潰銆", MessageBoxIcon.Warning); + return; + } + var sTime = DateTime.Now.AddDays(-7); + var eTime = DateTime.Now; ; + + if (drpdateType.SelectedValue == "0") + { + if (string.IsNullOrEmpty(txtStarTime.Text) || string.IsNullOrEmpty(txtEndTime.Text)) + { + Alert.ShowInTop("璇烽夋嫨鏃ユ湡銆", MessageBoxIcon.Warning); + return; + } + else { + sTime = Convert.ToDateTime(txtStarTime.Text); + + eTime = Convert.ToDateTime(txtEndTime.Text).AddMonths(1).AddDays(-1); + } + } + else { + if (string.IsNullOrEmpty(txtStarTime1.Text) || string.IsNullOrEmpty(txtEndTime1.Text)) + { + Alert.ShowInTop("璇烽夋嫨鏃ユ湡銆", MessageBoxIcon.Warning); + return; + } + else { + sTime = Convert.ToDateTime(txtStarTime1.Text); + eTime = Convert.ToDateTime(txtEndTime1.Text); + } + } + + + + ////濡傛灉娌℃湁濉啓鏃ユ湡锛屽垯鏄竷澶╁唴鐨 + //if (!string.IsNullOrEmpty(txtStarTime.Text) && !string.IsNullOrEmpty(txtEndTime.Text)) + // { + + + //} + + //鏌ヨ褰撳墠鏃ユ湡涓殑system鐨勫叿浣撴暟鐩紝鍘婚櫎閲嶅 + var list = Funs.DB.View_TransferDetail.Where(x => x.Projectid == ProjectId + && x.FDate >= sTime && x.FDate <= eTime).ToList(); + + var SystemList = (from x in list select x.SystemName).Distinct(); + + //鍏堝姞杞藉乏渚ystem 鏍戣彍鍗 + LoadData(SystemList); + + DataTable dtTime = new DataTable(); + dtTime.Columns.Add("鏃ユ湡", typeof(string)); + dtTime.Columns.Add("Finished", typeof(string)); + dtTime.Columns.Add("In Progress", typeof(string)); + dtTime.Columns.Add("Not Start", typeof(string)); + + var systemBol = false; + for (var i = sTime; i <= eTime; i=returnDay(i)) + { + var finishedCount = 0; + var inProgress = 0; + var notStart = 0; + DataRow rowTime = dtTime.NewRow(); + Model.SpTDesktopItem newspItem = new Model.SpTDesktopItem(); + + //鎸夊勾鏈 + if (drpdateType.SelectedValue == "0") + { + rowTime["鏃ユ湡"] = string.Format("{0:yyyy-MM}", i); + } + else { + rowTime["鏃ユ湡"] = string.Format("{0:yyyy-MM-dd}", i); + } + + + //鏍规嵁鏃ユ湡鏌ヨ褰撳墠system鐨勬暟閲 + var systemListbyDate = Funs.DB.View_TransferDetail.Where(x => x.Projectid == ProjectId + && x.FDate >= Convert.ToDateTime(rowTime["鏃ユ湡"]) + && x.FDate < Convert.ToDateTime(rowTime["鏃ユ湡"]).AddDays(1)).ToList(); + //濡傛灉鎸夊勾鏈 + if (drpdateType.SelectedValue == "0") + { + systemListbyDate = Funs.DB.View_TransferDetail.Where(x => x.Projectid == ProjectId + && x.FDate >= Convert.ToDateTime(rowTime["鏃ユ湡"]) + && x.FDate < Convert.ToDateTime(rowTime["鏃ユ湡"]).AddMonths(1)).ToList(); + } + + + //鏌ヨTestPackage 鍘婚噸 + var testpackageList = (from x in systemListbyDate select x.TestPackage).Distinct(); + + if (testpackageList.ToList().Count>0) + { + systemBol = true; + } + foreach (var item in testpackageList) + { + //鏌ヨ褰撳墠鏃ユ湡姣忎釜testpackage鐨勬暟閲 + var systemSumCount = systemListbyDate.Where(x => x.TestPackage == item).ToList().Count; + + //瀛愮郴缁熶腑瀹屾垚鐨勬暟閲 + var subSystemSumCount = systemListbyDate.Where(x => x.TestPackage == item && + x.Status.ToLower() == "finished").ToList().Count; + + //瀛愮郴缁熶腑娌″畬鎴愮殑鎯呭喌 + var subSystemSumNotStartCount = systemListbyDate.Where(x => x.TestPackage == item && + (x.Status.ToLower() == "not start"|| x.Status=="" || x.Status==null )).ToList().Count; + + //濡傛灉鎬绘暟閲忕瓑浜庡畬鎴愮殑鏁伴噺锛屽畬鎴愰噺+1 + if (systemSumCount == subSystemSumCount) + { + //濡傛灉閮芥槸瀹屾垚锛岄渶瑕佹渶鍚 12琛 test packge 蹇呴』鏄疐inished鎵嶈兘鏄畬鎴 + var punchlistFromList= Funs.DB.Transfer_PunchlistFrom.Where(x=>x.ProjectId==ProjectId + && x.Test_Package==item + ).ToList(); + + ////濡傛灉鎸夊勾鏈 + //if (drpdateType.SelectedValue == "0") { + // punchlistFromList = Funs.DB.Transfer_PunchlistFrom.Where(x => x.ProjectId == ProjectId + // && x.Test_Package == item + // && x.PUNCH_ITEM_FINISH_DATE >= Convert.ToDateTime(rowTime["鏃ユ湡"]) + // && x.PUNCH_ITEM_FINISH_DATE < Convert.ToDateTime(rowTime["鏃ユ湡"]).AddMonths(1)).ToList(); + //} + + //濡傛灉鏌ュ埌 + if (punchlistFromList.Count > 0) + { + //12琛ㄥ綋鍓嶆棩鏈熷畬鎴愮殑鏁伴噺 + var punchlistFromFinshCount = punchlistFromList.Where(x => x.PUNCH_ITEM_STATUS.ToLower() == "finished").ToList().Count(); + //濡傛灉瀹屾垚鐨勬暟閲忕瓑浜庢诲緱鏁伴噺锛屽垯鏄畬鎴 + if (punchlistFromFinshCount == punchlistFromList.Count) + { + finishedCount += 1; + } + else { + inProgress += 1; + } + } + else { + finishedCount += 1; + } + } + //濡傛灉鎬绘暟閲忕瓑浜巒ot start锛屾湭寮濮嬮噺+1 + else if (systemSumCount== subSystemSumNotStartCount) + { + notStart += 1; + } + else { + inProgress += 1; + } + } + rowTime["Finished"] = finishedCount; + rowTime["In Progress"] = inProgress; + rowTime["Not Start"] = notStart; + dtTime.Rows.Add(rowTime); + + } + if (systemBol) + { + this.ChartUc.CreateChart(BLL.ChartControlService.GetDataSourceChart(dtTime, "PROGRESS REPORT", "Column", 1100, 600, false)); + } + + + + } + + public DateTime returnDay(DateTime x) { + //鎸夊勾鏈 + if (drpdateType.SelectedValue == "0") + { + x = x.AddMonths(1); + return x; + } + else + { + x = x.AddDays(1); + return x; + } + } + + public class CheckAnalysisModel + { + public string itemType { get; set; } + public int count { get; set; } + } + #endregion + + /// + /// 缁熻鍒嗘瀽 + /// + /// + /// + protected void BtnAnalyse_Click(object sender, EventArgs e) + { + this.AnalyseData(); + } + + protected void drpChartType_SelectedIndexChanged(object sender, EventArgs e) + { + this.AnalyseData(); + } + + private void LoadData(IEnumerable list) + { + this.trRectify.Nodes.Clear(); + this.trRectify.ShowBorder = false; + this.trRectify.ShowHeader = false; + this.trRectify.EnableIcons = true; + this.trRectify.AutoScroll = true; + this.trRectify.EnableSingleClickExpand = true; + TreeNode rootNode = new TreeNode + { + Text = "鍏ㄩ儴", + NodeID = "ALL", + EnableClickEvent = true, + Expanded = true + }; + this.trRectify.Nodes.Add(rootNode); + BoundTree(rootNode.Nodes, list); + this.trRectify.AutoScroll = true; + } + + /// + /// 鍔犺浇鏍 + /// + /// + /// + private void BoundTree(TreeNodeCollection nodes, IEnumerable list) + { + TreeNode tn = null; + foreach (var item in list) + { + tn = new TreeNode + { + Text = item.ToString(), + NodeID = item.ToString(), + EnableClickEvent = true + }; + nodes.Add(tn); + } + } + + + + + + #region 鐐瑰嚮鏍戣妭鐐 + protected void trRectify_NodeCommand(object sender, TreeCommandEventArgs e) { + var SystemName = this.trRectify.SelectedNodeID; + if (SystemName == "ALL") + { + AnalyseData(); + } + else + { + var sTime = DateTime.Now.AddDays(-7); + var eTime = DateTime.Now; ; + + if (drpdateType.SelectedValue == "0") + { + if (string.IsNullOrEmpty(txtStarTime.Text) || string.IsNullOrEmpty(txtEndTime.Text)) + { + Alert.ShowInTop("璇烽夋嫨鏃ユ湡銆", MessageBoxIcon.Warning); + return; + } + else + { + sTime = Convert.ToDateTime(txtStarTime.Text); + + eTime = Convert.ToDateTime(txtEndTime.Text).AddMonths(1).AddDays(-1); + } + } + else + { + if (string.IsNullOrEmpty(txtStarTime1.Text) || string.IsNullOrEmpty(txtEndTime1.Text)) + { + Alert.ShowInTop("璇烽夋嫨鏃ユ湡銆", MessageBoxIcon.Warning); + return; + } + else + { + sTime = Convert.ToDateTime(txtStarTime1.Text); + eTime = Convert.ToDateTime(txtEndTime1.Text); + } + } + //var sTime = DateTime.Now.AddDays(-7); + //var eTime = DateTime.Now; ; + + ////濡傛灉娌℃湁濉啓鏃ユ湡锛屽垯鏄竷澶╁唴鐨 + //if (!string.IsNullOrEmpty(txtStarTime.Text) && !string.IsNullOrEmpty(txtEndTime.Text)) + //{ + // sTime = Convert.ToDateTime(txtStarTime.Text); + // eTime = Convert.ToDateTime(txtEndTime.Text); + + //} + + + DataTable dtTime = new DataTable(); + dtTime.Columns.Add("鏃ユ湡", typeof(string)); + dtTime.Columns.Add("Finished", typeof(string)); + dtTime.Columns.Add("In Progress", typeof(string)); + dtTime.Columns.Add("Not Start", typeof(string)); + + var systemBol = false; + for (var i = sTime; i <= eTime; i = returnDay(i)) + { + var finishedCount = 0; + var inProgress = 0; + var notStart = 0; + DataRow rowTime = dtTime.NewRow(); + Model.SpTDesktopItem newspItem = new Model.SpTDesktopItem(); + + //鎸夊勾鏈 + if (drpdateType.SelectedValue == "0") + { + rowTime["鏃ユ湡"] = string.Format("{0:yyyy-MM}", i); + } + else + { + rowTime["鏃ユ湡"] = string.Format("{0:yyyy-MM-dd}", i); + } + + //鏍规嵁鏃ユ湡鏌ヨ褰撳墠system鐨勬暟閲 + var systemListbyDate = Funs.DB.View_TransferDetail.Where(x => x.Projectid == ProjectId && x.SystemName == SystemName + && x.FDate >= Convert.ToDateTime(rowTime["鏃ユ湡"]) + && x.FDate < Convert.ToDateTime(rowTime["鏃ユ湡"]).AddDays(1)).ToList(); + + //濡傛灉鎸夊勾鏈 + if (drpdateType.SelectedValue == "0") + { + systemListbyDate = Funs.DB.View_TransferDetail.Where(x => x.Projectid == ProjectId && x.SystemName == SystemName + && x.FDate >= Convert.ToDateTime(rowTime["鏃ユ湡"]) + && x.FDate < Convert.ToDateTime(rowTime["鏃ユ湡"]).AddMonths(1)).ToList(); + } + + + //鏌ヨTestPackage 鍘婚噸 + var testpackageList = (from x in systemListbyDate select x.TestPackage).Distinct(); + + if (testpackageList.ToList().Count > 0) + { + systemBol = true; + } + foreach (var item in testpackageList) + { + //鏌ヨ褰撳墠鏃ユ湡姣忎釜testpackage鐨勬暟閲 + var systemSumCount = systemListbyDate.Where(x => x.TestPackage == item).ToList().Count; + + //瀛愮郴缁熶腑瀹屾垚鐨勬暟閲 + var subSystemSumCount = systemListbyDate.Where(x => x.TestPackage == item && + x.Status.ToLower() == "finished").ToList().Count; + + //瀛愮郴缁熶腑娌″畬鎴愮殑鎯呭喌 + var subSystemSumNotStartCount = systemListbyDate.Where(x => x.TestPackage == item && + (x.Status.ToLower() == "not start" || x.Status == "" || x.Status == null)).ToList().Count; + + //濡傛灉鎬绘暟閲忕瓑浜庡畬鎴愮殑鏁伴噺锛屽畬鎴愰噺+1 + if (systemSumCount == subSystemSumCount) + { + //濡傛灉閮芥槸瀹屾垚锛岄渶瑕佹渶鍚 12琛 test packge 蹇呴』鏄疐inished鎵嶈兘鏄畬鎴 + var punchlistFromList = Funs.DB.Transfer_PunchlistFrom.Where(x => x.ProjectId == ProjectId + && x.SystemName==SystemName + && x.Test_Package == item + ).ToList(); + + //&& x.PUNCH_ITEM_FINISH_DATE >= Convert.ToDateTime(rowTime["鏃ユ湡"]) + //&& x.PUNCH_ITEM_FINISH_DATE < Convert.ToDateTime(rowTime["鏃ユ湡"]).AddDays(1) + //濡傛灉鏌ュ埌 + if (punchlistFromList.Count > 0) + { + //12琛ㄥ綋鍓嶆棩鏈熷畬鎴愮殑鏁伴噺 + var punchlistFromFinshCount = punchlistFromList.Where(x => x.PUNCH_ITEM_STATUS.ToLower() == "finished").ToList().Count(); + //濡傛灉瀹屾垚鐨勬暟閲忕瓑浜庢诲緱鏁伴噺锛屽垯鏄畬鎴 + if (punchlistFromFinshCount == punchlistFromList.Count) + { + finishedCount += 1; + } + else + { + inProgress += 1; + } + } + else + { + finishedCount += 1; + } + } + //濡傛灉鎬绘暟閲忕瓑浜巒ot start锛屾湭寮濮嬮噺+1 + else if (systemSumCount == subSystemSumNotStartCount) + { + notStart += 1; + } + else + { + inProgress += 1; + } + } + rowTime["Finished"] = finishedCount; + rowTime["In Progress"] = inProgress; + rowTime["Not Start"] = notStart; + dtTime.Rows.Add(rowTime); + + } + if (systemBol) + { + this.ChartUc.CreateChart(BLL.ChartControlService.GetDataSourceChart(dtTime, "SYSTEM PROGRESS REPORT", "Column", 1100, 600, false)); + } + } + + } + #endregion + + #region 闄勪欢涓婁紶 + /// + /// 涓婁紶闄勪欢 + /// + /// + /// + protected void btnAttachUrl_Click(object sender, EventArgs e) + { + //蹇呴』鐐瑰嚮绯荤粺 + var SystemName = this.trRectify.SelectedNodeID; + if (SystemName=="ALL"|| SystemName=="") + { + Alert.ShowInTop("璇烽夋嫨绯荤粺銆", MessageBoxIcon.Warning); + return; + } + var toKeyId = "D142B96F-4D36-429D-AB08-FA0D7C30BB69" + SystemName; + PageContext.RegisterStartupScript(WindowAtt.GetShowReference + (String.Format("~/AttachFile/webuploader.aspx?type=0&toKeyId={0}&path=FileUpload/Trancfer&menuId={1}", + toKeyId, "E6F5125D-DD94-4978-B7EB-D9C26694D86D"))); + } + #endregion + } +} \ No newline at end of file diff --git a/SGGL/FineUIPro.Web/Transfer/Chart/Instrumentation.aspx.designer.cs b/SGGL/FineUIPro.Web/Transfer/Chart/Instrumentation.aspx.designer.cs new file mode 100644 index 00000000..d6ed0495 --- /dev/null +++ b/SGGL/FineUIPro.Web/Transfer/Chart/Instrumentation.aspx.designer.cs @@ -0,0 +1,188 @@ +锘//------------------------------------------------------------------------------ +// <鑷姩鐢熸垚> +// 姝や唬鐮佺敱宸ュ叿鐢熸垚銆 +// +// 瀵规鏂囦欢鐨勬洿鏀瑰彲鑳藉鑷翠笉姝g‘鐨勮涓猴紝濡傛灉 +// 閲嶆柊鐢熸垚浠g爜锛屽垯鎵鍋氭洿鏀瑰皢涓㈠け銆 +// +//------------------------------------------------------------------------------ + +namespace FineUIPro.Web.Transfer.Chart +{ + + + public partial class Instrumentation + { + + /// + /// form1 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::System.Web.UI.HtmlControls.HtmlForm form1; + + /// + /// PageManager1 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.PageManager PageManager1; + + /// + /// RegionPanel1 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.RegionPanel RegionPanel1; + + /// + /// Region1 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.Region Region1; + + /// + /// Form2 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.Form Form2; + + /// + /// drpdateType 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.DropDownList drpdateType; + + /// + /// txtStarTime 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.DatePicker txtStarTime; + + /// + /// txtEndTime 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.DatePicker txtEndTime; + + /// + /// txtStarTime1 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.DatePicker txtStarTime1; + + /// + /// txtEndTime1 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.DatePicker txtEndTime1; + + /// + /// BtnAnalyse 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.Button BtnAnalyse; + + /// + /// btnAttachUrl 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.Button btnAttachUrl; + + /// + /// Region2 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.Region Region2; + + /// + /// TabStrip1 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.TabStrip TabStrip1; + + /// + /// Tab2 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.Tab Tab2; + + /// + /// cpCostTime 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.ContentPanel cpCostTime; + + /// + /// ChartUc 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::Web.Controls.ChartControl ChartUc; + + /// + /// trRectify 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.Tree trRectify; + + /// + /// WindowAtt 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.Window WindowAtt; + } +} diff --git a/SGGL/FineUIPro.Web/Transfer/Chart/PunchlistFrom.aspx b/SGGL/FineUIPro.Web/Transfer/Chart/PunchlistFrom.aspx new file mode 100644 index 00000000..1839b0da --- /dev/null +++ b/SGGL/FineUIPro.Web/Transfer/Chart/PunchlistFrom.aspx @@ -0,0 +1,86 @@ +锘<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="PunchlistFrom.aspx.cs" Inherits="FineUIPro.Web.Transfer.Chart.PunchlistFrom" %> + +<%@ Register Src="~/Controls/ChartControl.ascx" TagName="ChartControl" TagPrefix="uc1" %> + + + + + + + + +
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + <%-- + --%> + + + + + + + + + + + + + + + +
+ +
+
+
+
+
+
+
+
+ + + diff --git a/SGGL/FineUIPro.Web/Transfer/Chart/PunchlistFrom.aspx.cs b/SGGL/FineUIPro.Web/Transfer/Chart/PunchlistFrom.aspx.cs new file mode 100644 index 00000000..4296ebdc --- /dev/null +++ b/SGGL/FineUIPro.Web/Transfer/Chart/PunchlistFrom.aspx.cs @@ -0,0 +1,177 @@ +锘縰sing System; +using System.Collections.Generic; +using System.Data; +using System.Linq; +using BLL; + +namespace FineUIPro.Web.Transfer.Chart +{ + public partial class PunchlistFrom : PageBase + { + #region 鍔犺浇椤甸潰 + /// + /// 鍔犺浇椤甸潰 + /// + /// + /// + protected void Page_Load(object sender, EventArgs e) + { + if (!IsPostBack) + { + } + } + #endregion + + #region 缁熻 + /// + /// 缁熻鍒嗘瀽 + /// + /// + /// + protected void BtnAnalyse_Click(object sender, EventArgs e) + { + this.AnalyseData(); + } + + /// + /// 缁熻鏂规硶 + /// + private void AnalyseData() + { + var forms = from x in Funs.DB.Transfer_PunchlistFrom + where x.ProjectId == this.CurrUser.LoginProjectId + select x; + if (!string.IsNullOrEmpty(this.txtStartTime.Text.Trim())) + { + forms = forms.Where(x => x.PUNCH_ITEM_FINISH_DATE >= Funs.GetNewDateTime(this.txtStartTime.Text.Trim())); + } + if (!string.IsNullOrEmpty(this.txtEndTime.Text.Trim())) + { + forms = forms.Where(x => x.PUNCH_ITEM_FINISH_DATE <= Funs.GetNewDateTime(this.txtEndTime.Text.Trim())); + } + var list = new List { "Testing", "Pre-Commissioning", "PSSR", "Commissioning" }; + if (this.rblState.SelectedValue == "0") + { + #region 鎸塈dentified during/by缁熻 + if (this.drpChartType.SelectedValue != "Pie") //闈為ゼ褰㈠浘 + { + ///鎸夊崟浣嶇粺璁 + DataTable dtTime = new DataTable(); + dtTime.Columns.Add("Identified during/by", typeof(string)); + dtTime.Columns.Add("鎬绘暟閲", typeof(string)); + dtTime.Columns.Add("A鏁伴噺", typeof(string)); + dtTime.Columns.Add("B鏁伴噺", typeof(string)); + dtTime.Columns.Add("C鏁伴噺", typeof(string)); + dtTime.Columns.Add("Finished", typeof(string)); + dtTime.Columns.Add("In Progress", typeof(string)); + dtTime.Columns.Add("Not Start", typeof(string)); + foreach (var item in list) + { + DataRow rowTime = dtTime.NewRow(); + Model.SpTDesktopItem newspItem = new Model.SpTDesktopItem(); + rowTime["Identified during/by"] = item; + var types = forms.Where(x => x.Identified == item); + rowTime["鎬绘暟閲"] = types.Count(); + rowTime["A鏁伴噺"] = types.Where(x => x.Category == "A").Count(); + rowTime["B鏁伴噺"] = types.Where(x => x.Category == "B").Count(); + rowTime["C鏁伴噺"] = types.Where(x => x.Category == "C").Count(); + rowTime["Finished"] = types.Where(x => x.PUNCH_ITEM_STATUS == "Finished").Count(); + rowTime["In Progress"] = types.Where(x => x.PUNCH_ITEM_STATUS == "In Progress").Count(); + rowTime["Not Start"] = types.Where(x => x.PUNCH_ITEM_STATUS == "Not Start").Count(); + dtTime.Rows.Add(rowTime); + } + this.ChartAccidentTime.CreateChart(BLL.ChartControlService.GetDataSourceChart(dtTime, "灏鹃」鍒嗘瀽", this.drpChartType.SelectedValue, 1300, 550, this.ckbShow.Checked)); + } + else //楗煎舰鍥 + { + DataTable dtTime = new DataTable(); + dtTime.Columns.Add("Identified during/by", typeof(string)); + dtTime.Columns.Add("鎬绘暟閲", typeof(string)); + foreach (var item in list) + { + DataRow rowTime = dtTime.NewRow(); + Model.SpTDesktopItem newspItem = new Model.SpTDesktopItem(); + rowTime["Identified during/by"] = item; + var types = forms.Where(x => x.Identified == item); + rowTime["鎬绘暟閲"] = types.Count(); + dtTime.Rows.Add(rowTime); + } + this.ChartAccidentTime.CreateChart(BLL.ChartControlService.GetDataSourceChart(dtTime, "灏鹃」鍒嗘瀽", this.drpChartType.SelectedValue, 1300, 550, this.ckbShow.Checked)); + } + #endregion + } + else + { + #region 鎸塂iscipline + var disciplines = from x in Funs.DB.Base_TransferMajor orderby x.DisciplineCode select x; + if (this.drpChartType.SelectedValue != "Pie") //闈為ゼ褰㈠浘 + { + ///鎸夋鏌ラ」 + DataTable dtTime = new DataTable(); + dtTime.Columns.Add("Discipline", typeof(string)); + dtTime.Columns.Add("鎬绘暟閲", typeof(string)); + dtTime.Columns.Add("A鏁伴噺", typeof(string)); + dtTime.Columns.Add("B鏁伴噺", typeof(string)); + dtTime.Columns.Add("C鏁伴噺", typeof(string)); + dtTime.Columns.Add("Finished", typeof(string)); + dtTime.Columns.Add("In Progress", typeof(string)); + dtTime.Columns.Add("Not Start", typeof(string)); + foreach (var item in disciplines) + { + DataRow rowTime = dtTime.NewRow(); + Model.SpTDesktopItem newspItem = new Model.SpTDesktopItem(); + rowTime["Discipline"] = item.Discipline; + var types = forms.Where(x => x.Discipline == item.Discipline || x.Discipline==item.DisciplineCode); + rowTime["鎬绘暟閲"] = types.Count(); + rowTime["A鏁伴噺"] = types.Where(x => x.Category == "A").Count(); + rowTime["B鏁伴噺"] = types.Where(x => x.Category == "B").Count(); + rowTime["C鏁伴噺"] = types.Where(x => x.Category == "C").Count(); + rowTime["Finished"] = types.Where(x => x.PUNCH_ITEM_STATUS == "Finished").Count(); + rowTime["In Progress"] = types.Where(x => x.PUNCH_ITEM_STATUS == "In Progress").Count(); + rowTime["Not Start"] = types.Where(x => x.PUNCH_ITEM_STATUS == "Not Start").Count(); + dtTime.Rows.Add(rowTime); + } + + this.ChartAccidentTime.CreateChart(BLL.ChartControlService.GetDataSourceChart(dtTime, "灏鹃」鍒嗘瀽", this.drpChartType.SelectedValue, 1300, 550, this.ckbShow.Checked)); + } + else //楗煎舰鍥 + { + ///鎸夐棶棰樼被鍨 + DataTable dtTime = new DataTable(); + dtTime.Columns.Add("Discipline", typeof(string)); + dtTime.Columns.Add("鎬绘暟閲", typeof(string)); + foreach (var item in disciplines) + { + DataRow rowTime = dtTime.NewRow(); + Model.SpTDesktopItem newspItem = new Model.SpTDesktopItem(); + rowTime["Discipline"] = item.Discipline; + var types = forms.Where(x => x.Discipline == item.Discipline || x.Discipline == item.DisciplineCode); + rowTime["鎬绘暟閲"] = types.Count(); + dtTime.Rows.Add(rowTime); + } + + this.ChartAccidentTime.CreateChart(BLL.ChartControlService.GetDataSourceChart(dtTime, "灏鹃」鍒嗘瀽", this.drpChartType.SelectedValue, 1300, 550, this.ckbShow.Checked)); + } + #endregion + } + } + #endregion + + #region 鍥惧舰 + /// + /// 鍥惧舰鍙樻崲 + /// + /// + /// + protected void drpChartType_SelectedIndexChanged(object sender, EventArgs e) + { + this.AnalyseData(); + } + + protected void ckbShow_CheckedChanged(object sender, CheckedEventArgs e) + { + this.AnalyseData(); + } + #endregion + } +} \ No newline at end of file diff --git a/SGGL/FineUIPro.Web/Transfer/Chart/PunchlistFrom.aspx.designer.cs b/SGGL/FineUIPro.Web/Transfer/Chart/PunchlistFrom.aspx.designer.cs new file mode 100644 index 00000000..ee441487 --- /dev/null +++ b/SGGL/FineUIPro.Web/Transfer/Chart/PunchlistFrom.aspx.designer.cs @@ -0,0 +1,168 @@ +锘//------------------------------------------------------------------------------ +// <鑷姩鐢熸垚> +// 姝や唬鐮佺敱宸ュ叿鐢熸垚銆 +// +// 瀵规鏂囦欢鐨勬洿鏀瑰彲鑳藉鑷翠笉姝g‘鐨勮涓猴紝濡傛灉 +// 閲嶆柊鐢熸垚浠g爜锛屽垯鎵鍋氭洿鏀瑰皢涓㈠け銆 +// +//------------------------------------------------------------------------------ + +namespace FineUIPro.Web.Transfer.Chart { + + + public partial class PunchlistFrom { + + /// + /// form1 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::System.Web.UI.HtmlControls.HtmlForm form1; + + /// + /// PageManager1 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.PageManager PageManager1; + + /// + /// Panel3 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.Panel Panel3; + + /// + /// Form2 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.Form Form2; + + /// + /// txtStartTime 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.DatePicker txtStartTime; + + /// + /// Label3 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.Label Label3; + + /// + /// txtEndTime 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.DatePicker txtEndTime; + + /// + /// drpChartType 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.DropDownList drpChartType; + + /// + /// ckbShow 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.CheckBox ckbShow; + + /// + /// BtnAnalyse 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.Button BtnAnalyse; + + /// + /// rblState 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.RadioButtonList rblState; + + /// + /// aa 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.Label aa; + + /// + /// Panel4 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.Panel Panel4; + + /// + /// TabStrip1 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.TabStrip TabStrip1; + + /// + /// Tab2 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.Tab Tab2; + + /// + /// cpAccidentTime 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.ContentPanel cpAccidentTime; + + /// + /// ChartAccidentTime 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::Web.Controls.ChartControl ChartAccidentTime; + } +} diff --git a/SGGL/FineUIPro.Web/Transfer/Chart/TransferChart.aspx b/SGGL/FineUIPro.Web/Transfer/Chart/TransferChart.aspx new file mode 100644 index 00000000..5933171b --- /dev/null +++ b/SGGL/FineUIPro.Web/Transfer/Chart/TransferChart.aspx @@ -0,0 +1,97 @@ +锘<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="TransferChart.aspx.cs" Inherits="FineUIPro.Web.Transfer.Chart.TransferChart" %> +<%@ Register Src="~/Controls/ChartControl.ascx" TagName="ChartControl" TagPrefix="uc1" %> + + + + + + 鍏ㄥ巶绉讳氦缁熻閫掑琛 + + +
+ + + + + + + + + + + + + + + + + + + + + + + + + + + <%-- + + + --%> + + + + + + + <%-- + + --%> + + <%-- + + + --%> + + + + + + + + + + + + + + + + + + +
+ +
+
+
+ + +
+
+
+
+
+
+
+ + + diff --git a/SGGL/FineUIPro.Web/Transfer/Chart/TransferChart.aspx.cs b/SGGL/FineUIPro.Web/Transfer/Chart/TransferChart.aspx.cs new file mode 100644 index 00000000..198d4252 --- /dev/null +++ b/SGGL/FineUIPro.Web/Transfer/Chart/TransferChart.aspx.cs @@ -0,0 +1,1791 @@ +锘縰sing System; +using System.Collections.Generic; +using System.Data; +using System.Linq; +using BLL; + +namespace FineUIPro.Web.Transfer.Chart +{ + public partial class TransferChart : PageBase + { + #region 瀹氫箟椤 + /// + /// 椤圭洰涓婚敭 + /// + public string ProjectId + { + get + { + return (string)ViewState["ProjectId"]; + } + set + { + ViewState["ProjectId"] = value; + } + } + #endregion + + #region 鍔犺浇椤甸潰 + /// + /// 鍔犺浇椤甸潰 + /// + /// + /// + protected void Page_Load(object sender, EventArgs e) + { + if (!IsPostBack) + { + this.ProjectId = this.CurrUser.LoginProjectId; + if (!string.IsNullOrEmpty(Request.Params["projectId"])) + { + this.ProjectId = Request.Params["projectId"]; + } + + //this.AnalyseData(); + } + } + #endregion + + /// + /// 缁熻鍒嗘瀽 + /// + /// + /// + protected void BtnAnalyse_Click(object sender, EventArgs e) + { + this.AnalyseData(); + } + + #region 缁熻 + private void AnalyseData() { + if (string.IsNullOrEmpty(ProjectId)) + { + Alert.ShowInTop("椤圭洰鏈幏鍙栧埌锛岃鍒锋柊椤甸潰銆", MessageBoxIcon.Warning); + return; + } + var sTime = DateTime.Now.AddDays(-7); + var eTime = DateTime.Now; + if (string.IsNullOrEmpty(txtStarTime.Text) || string.IsNullOrEmpty(txtEndTime.Text)) + { + Alert.ShowInTop("璇烽夋嫨鏃ユ湡銆", MessageBoxIcon.Warning); + return; + } + else + { + sTime = Convert.ToDateTime(txtStarTime.Text); + + eTime = Convert.ToDateTime(txtEndTime.Text).AddMonths(1).AddDays(-1); + } + var AfinishedCountSum = 0;//鎬荤殑瀹為檯瀹屾垚鏁伴噺 + var PfinishedCountSum = 0;//鎬荤殑璁″垝瀹屾垚鏁伴噺 + //鑾峰彇鎬荤殑瀹為檯瀹屾垚鏁伴噺鍜屾荤殑璁″垝瀹屾垚鏁伴噺 + switch (drpType.SelectedValue) + { + #region 鍏ㄩ儴 + case "": + //鏍规嵁褰撳墠璁″垝瀹屾垚鏃ユ湡 鏌ヨ鎬荤殑璁″垝瀹屾垚鐨勬暟閲 + var systemListbyDate = Funs.DB.View_TransferDetail.Where(x => x.Projectid == ProjectId + && x.FDate >= sTime + && x.FDate <= eTime + && x.Status.ToLower() == "finished").ToList(); + //鏌ヨTestPackage 鍘婚噸 + var testpackageList = (from x in systemListbyDate select x.TestPackage).Distinct(); + + foreach (var item in testpackageList) { + //鏌ヨ绗12涓〃鐨勬暟閲 + var punchlistFromList = Funs.DB.Transfer_PunchlistFrom.Where(x => x.ProjectId == ProjectId + && x.Test_Package == item + ).ToList(); + //濡傛灉鏌ュ埌 + if (punchlistFromList.Count > 0) + { + //12琛ㄥ綋鍓嶆棩鏈熷畬鎴愮殑鏁伴噺 + var punchlistFromFinshCount = punchlistFromList.Where(x => x.PUNCH_ITEM_STATUS.ToLower() == "finished").ToList().Count(); + //濡傛灉瀹屾垚鐨勬暟閲忕瓑浜庢诲緱鏁伴噺锛屽垯鏄畬鎴 + if (punchlistFromFinshCount == punchlistFromList.Count) + { + PfinishedCountSum += 1; + } + } + else { + PfinishedCountSum += 1; + } + + } + + //鑾峰彇褰撳墠鏃ユ湡鍐呭疄闄呭畬鎴愮殑鏁伴噺 + systemListbyDate = Funs.DB.View_TransferDetail.Where(x => x.Projectid == ProjectId + && x.ADate >= sTime + && x.ADate <= eTime + && x.Status.ToLower() == "finished").ToList(); + testpackageList = (from x in systemListbyDate select x.TestPackage).Distinct(); + + foreach (var item in testpackageList) + { + //鏌ヨ绗12涓〃鐨勬暟閲 + var punchlistFromList = Funs.DB.Transfer_PunchlistFrom.Where(x => x.ProjectId == ProjectId + && x.Test_Package == item + ).ToList(); + //濡傛灉鏌ュ埌 + if (punchlistFromList.Count > 0) + { + //12琛ㄥ綋鍓嶆棩鏈熷畬鎴愮殑鏁伴噺 + var punchlistFromFinshCount = punchlistFromList.Where(x => x.PUNCH_ITEM_STATUS.ToLower() == "finished").ToList().Count(); + //濡傛灉瀹屾垚鐨勬暟閲忕瓑浜庢诲緱鏁伴噺锛屽垯鏄畬鎴 + if (punchlistFromFinshCount == punchlistFromList.Count) + { + AfinishedCountSum += 1; + } + } + else + { + AfinishedCountSum += 1; + } + + } + break; + #endregion + + #region Piping + + + case "Piping": + //鏍规嵁褰撳墠璁″垝瀹屾垚鏃ユ湡 鏌ヨ鎬荤殑璁″垝瀹屾垚鐨勬暟閲 + var systemListbyDate1 = Funs.DB.Transfer_Piping.Where(x => x.ProjectId == ProjectId + && x.TestPackageFINISH >= sTime + && x.TestPackageFINISH <= eTime + && x.FINALStatus.ToLower() == "finished").ToList(); + //鏌ヨTestPackage 鍘婚噸 + testpackageList = (from x in systemListbyDate1 select x.TestPackage).Distinct(); + + foreach (var item in testpackageList) + { + //鏌ヨ绗12涓〃鐨勬暟閲 + var punchlistFromList = Funs.DB.Transfer_PunchlistFrom.Where(x => x.ProjectId == ProjectId + && x.Test_Package == item + ).ToList(); + //濡傛灉鏌ュ埌 + if (punchlistFromList.Count > 0) + { + //12琛ㄥ綋鍓嶆棩鏈熷畬鎴愮殑鏁伴噺 + var punchlistFromFinshCount = punchlistFromList.Where(x => x.PUNCH_ITEM_STATUS.ToLower() == "finished").ToList().Count(); + //濡傛灉瀹屾垚鐨勬暟閲忕瓑浜庢诲緱鏁伴噺锛屽垯鏄畬鎴 + if (punchlistFromFinshCount == punchlistFromList.Count) + { + PfinishedCountSum += 1; + } + } + else + { + PfinishedCountSum += 1; + } + + } + + //鑾峰彇褰撳墠鏃ユ湡鍐呭疄闄呭畬鎴愮殑鏁伴噺 + systemListbyDate1 = Funs.DB.Transfer_Piping.Where(x => x.ProjectId == ProjectId + && x.CompleteTime >= sTime + && x.CompleteTime <= eTime + && x.FINALStatus.ToLower() == "finished").ToList(); + testpackageList = (from x in systemListbyDate1 select x.TestPackage).Distinct(); + + foreach (var item in testpackageList) + { + //鏌ヨ绗12涓〃鐨勬暟閲 + var punchlistFromList = Funs.DB.Transfer_PunchlistFrom.Where(x => x.ProjectId == ProjectId + && x.Test_Package == item + ).ToList(); + //濡傛灉鏌ュ埌 + if (punchlistFromList.Count > 0) + { + //12琛ㄥ綋鍓嶆棩鏈熷畬鎴愮殑鏁伴噺 + var punchlistFromFinshCount = punchlistFromList.Where(x => x.PUNCH_ITEM_STATUS.ToLower() == "finished").ToList().Count(); + //濡傛灉瀹屾垚鐨勬暟閲忕瓑浜庢诲緱鏁伴噺锛屽垯鏄畬鎴 + if (punchlistFromFinshCount == punchlistFromList.Count) + { + AfinishedCountSum += 1; + } + } + else + { + AfinishedCountSum += 1; + } + + } + break; + #endregion + #region Static Equipment + + + case "Static Equipment": + //鏍规嵁褰撳墠璁″垝瀹屾垚鏃ユ湡 鏌ヨ鎬荤殑璁″垝瀹屾垚鐨勬暟閲 + var systemListbyDate2 = Funs.DB.Transfer_StaticEquipment.Where(x => x.ProjectId == ProjectId + && x.TestPackageFINISH >= sTime + && x.TestPackageFINISH <= eTime + && x.MechanicalFINALStatus.ToLower() == "finished").ToList(); + //鏌ヨTestPackage 鍘婚噸 + testpackageList = (from x in systemListbyDate2 select x.TestPackage).Distinct(); + + foreach (var item in testpackageList) + { + //鏌ヨ绗12涓〃鐨勬暟閲 + var punchlistFromList = Funs.DB.Transfer_PunchlistFrom.Where(x => x.ProjectId == ProjectId + && x.Test_Package == item + ).ToList(); + //濡傛灉鏌ュ埌 + if (punchlistFromList.Count > 0) + { + //12琛ㄥ綋鍓嶆棩鏈熷畬鎴愮殑鏁伴噺 + var punchlistFromFinshCount = punchlistFromList.Where(x => x.PUNCH_ITEM_STATUS.ToLower() == "finished").ToList().Count(); + //濡傛灉瀹屾垚鐨勬暟閲忕瓑浜庢诲緱鏁伴噺锛屽垯鏄畬鎴 + if (punchlistFromFinshCount == punchlistFromList.Count) + { + PfinishedCountSum += 1; + } + } + else + { + PfinishedCountSum += 1; + } + + } + + //鑾峰彇褰撳墠鏃ユ湡鍐呭疄闄呭畬鎴愮殑鏁伴噺 + systemListbyDate2=Funs.DB.Transfer_StaticEquipment.Where(x => x.ProjectId == ProjectId + && x.CompleteTime >= sTime + && x.CompleteTime <= eTime + && x.MechanicalFINALStatus.ToLower() == "finished").ToList(); + testpackageList = (from x in systemListbyDate2 select x.TestPackage).Distinct(); + foreach (var item in testpackageList) + { + //鏌ヨ绗12涓〃鐨勬暟閲 + var punchlistFromList = Funs.DB.Transfer_PunchlistFrom.Where(x => x.ProjectId == ProjectId + && x.Test_Package == item + ).ToList(); + //濡傛灉鏌ュ埌 + if (punchlistFromList.Count > 0) + { + //12琛ㄥ綋鍓嶆棩鏈熷畬鎴愮殑鏁伴噺 + var punchlistFromFinshCount = punchlistFromList.Where(x => x.PUNCH_ITEM_STATUS.ToLower() == "finished").ToList().Count(); + //濡傛灉瀹屾垚鐨勬暟閲忕瓑浜庢诲緱鏁伴噺锛屽垯鏄畬鎴 + if (punchlistFromFinshCount == punchlistFromList.Count) + { + AfinishedCountSum += 1; + } + } + else + { + AfinishedCountSum += 1; + } + + } + break; + #endregion + #region Rotating Equipment + + + case "Rotating Equipment": + //鏍规嵁褰撳墠璁″垝瀹屾垚鏃ユ湡 鏌ヨ鎬荤殑璁″垝瀹屾垚鐨勬暟閲 + var systemListbyDate3 = Funs.DB.Transfer_RotatingEquipment.Where(x => x.ProjectId == ProjectId + && x.TestPackageFINISH >= sTime + && x.TestPackageFINISH <= eTime + && x.MechanicalFINALStatus.ToLower() == "finished").ToList(); + //鏌ヨTestPackage 鍘婚噸 + testpackageList = (from x in systemListbyDate3 select x.TestPackage).Distinct(); + + foreach (var item in testpackageList) + { + //鏌ヨ绗12涓〃鐨勬暟閲 + var punchlistFromList = Funs.DB.Transfer_PunchlistFrom.Where(x => x.ProjectId == ProjectId + && x.Test_Package == item + ).ToList(); + //濡傛灉鏌ュ埌 + if (punchlistFromList.Count > 0) + { + //12琛ㄥ綋鍓嶆棩鏈熷畬鎴愮殑鏁伴噺 + var punchlistFromFinshCount = punchlistFromList.Where(x => x.PUNCH_ITEM_STATUS.ToLower() == "finished").ToList().Count(); + //濡傛灉瀹屾垚鐨勬暟閲忕瓑浜庢诲緱鏁伴噺锛屽垯鏄畬鎴 + if (punchlistFromFinshCount == punchlistFromList.Count) + { + PfinishedCountSum += 1; + } + } + else + { + PfinishedCountSum += 1; + } + + } + + //鑾峰彇褰撳墠鏃ユ湡鍐呭疄闄呭畬鎴愮殑鏁伴噺 + systemListbyDate3 = Funs.DB.Transfer_RotatingEquipment.Where(x => x.ProjectId == ProjectId + && x.CompleteTime >= sTime + && x.CompleteTime <= eTime + && x.MechanicalFINALStatus.ToLower() == "finished").ToList(); + + testpackageList = (from x in systemListbyDate3 select x.TestPackage).Distinct(); + foreach (var item in testpackageList) + { + //鏌ヨ绗12涓〃鐨勬暟閲 + var punchlistFromList = Funs.DB.Transfer_PunchlistFrom.Where(x => x.ProjectId == ProjectId + && x.Test_Package == item + ).ToList(); + //濡傛灉鏌ュ埌 + if (punchlistFromList.Count > 0) + { + //12琛ㄥ綋鍓嶆棩鏈熷畬鎴愮殑鏁伴噺 + var punchlistFromFinshCount = punchlistFromList.Where(x => x.PUNCH_ITEM_STATUS.ToLower() == "finished").ToList().Count(); + //濡傛灉瀹屾垚鐨勬暟閲忕瓑浜庢诲緱鏁伴噺锛屽垯鏄畬鎴 + if (punchlistFromFinshCount == punchlistFromList.Count) + { + AfinishedCountSum += 1; + } + } + else + { + AfinishedCountSum += 1; + } + + } + break; + #endregion + #region Instrumentation + + + case "Instrumentation": + //鏍规嵁褰撳墠璁″垝瀹屾垚鏃ユ湡 鏌ヨ鎬荤殑璁″垝瀹屾垚鐨勬暟閲 + var systemListbyDate4 = Funs.DB.Transfer_Instrumentation.Where(x => x.ProjectId == ProjectId + && x.Test_Package_FINISH >= sTime + && x.Test_Package_FINISH <= eTime + && x.FINAL_Status.ToLower() == "finished").ToList(); + //鏌ヨTestPackage 鍘婚噸 + testpackageList = (from x in systemListbyDate4 select x.Test_Package).Distinct(); + + foreach (var item in testpackageList) + { + //鏌ヨ绗12涓〃鐨勬暟閲 + var punchlistFromList = Funs.DB.Transfer_PunchlistFrom.Where(x => x.ProjectId == ProjectId + && x.Test_Package == item + ).ToList(); + //濡傛灉鏌ュ埌 + if (punchlistFromList.Count > 0) + { + //12琛ㄥ綋鍓嶆棩鏈熷畬鎴愮殑鏁伴噺 + var punchlistFromFinshCount = punchlistFromList.Where(x => x.PUNCH_ITEM_STATUS.ToLower() == "finished").ToList().Count(); + //濡傛灉瀹屾垚鐨勬暟閲忕瓑浜庢诲緱鏁伴噺锛屽垯鏄畬鎴 + if (punchlistFromFinshCount == punchlistFromList.Count) + { + PfinishedCountSum += 1; + } + } + else + { + PfinishedCountSum += 1; + } + + } + + //鑾峰彇褰撳墠鏃ユ湡鍐呭疄闄呭畬鎴愮殑鏁伴噺 + systemListbyDate4 = Funs.DB.Transfer_Instrumentation.Where(x => x.ProjectId == ProjectId + && x.CompleteTime >= sTime + && x.CompleteTime <= eTime + && x.FINAL_Status.ToLower() == "finished").ToList(); + + testpackageList = (from x in systemListbyDate4 select x.Test_Package).Distinct(); + foreach (var item in testpackageList) + { + //鏌ヨ绗12涓〃鐨勬暟閲 + var punchlistFromList = Funs.DB.Transfer_PunchlistFrom.Where(x => x.ProjectId == ProjectId + && x.Test_Package == item + ).ToList(); + //濡傛灉鏌ュ埌 + if (punchlistFromList.Count > 0) + { + //12琛ㄥ綋鍓嶆棩鏈熷畬鎴愮殑鏁伴噺 + var punchlistFromFinshCount = punchlistFromList.Where(x => x.PUNCH_ITEM_STATUS.ToLower() == "finished").ToList().Count(); + //濡傛灉瀹屾垚鐨勬暟閲忕瓑浜庢诲緱鏁伴噺锛屽垯鏄畬鎴 + if (punchlistFromFinshCount == punchlistFromList.Count) + { + AfinishedCountSum += 1; + } + } + else + { + AfinishedCountSum += 1; + } + + } + break; + #endregion + #region Electrical + + + case "Electrical": + //鏍规嵁褰撳墠璁″垝瀹屾垚鏃ユ湡 鏌ヨ鎬荤殑璁″垝瀹屾垚鐨勬暟閲 + var systemListbyDate5 = Funs.DB.Transfer_Electrical.Where(x => x.ProjectId == ProjectId + && x.Test_Package_FINISH >= sTime + && x.Test_Package_FINISH <= eTime + && x.FINAL_Status.ToLower() == "finished").ToList(); + //鏌ヨTestPackage 鍘婚噸 + testpackageList = (from x in systemListbyDate5 select x.Test_Package).Distinct(); + + foreach (var item in testpackageList) + { + //鏌ヨ绗12涓〃鐨勬暟閲 + var punchlistFromList = Funs.DB.Transfer_PunchlistFrom.Where(x => x.ProjectId == ProjectId + && x.Test_Package == item + ).ToList(); + //濡傛灉鏌ュ埌 + if (punchlistFromList.Count > 0) + { + //12琛ㄥ綋鍓嶆棩鏈熷畬鎴愮殑鏁伴噺 + var punchlistFromFinshCount = punchlistFromList.Where(x => x.PUNCH_ITEM_STATUS.ToLower() == "finished").ToList().Count(); + //濡傛灉瀹屾垚鐨勬暟閲忕瓑浜庢诲緱鏁伴噺锛屽垯鏄畬鎴 + if (punchlistFromFinshCount == punchlistFromList.Count) + { + PfinishedCountSum += 1; + } + } + else + { + PfinishedCountSum += 1; + } + + } + + //鑾峰彇褰撳墠鏃ユ湡鍐呭疄闄呭畬鎴愮殑鏁伴噺 + systemListbyDate5 = Funs.DB.Transfer_Electrical.Where(x => x.ProjectId == ProjectId + && x.CompleteTime >= sTime + && x.CompleteTime <= eTime + && x.FINAL_Status.ToLower() == "finished").ToList(); + + testpackageList = (from x in systemListbyDate5 select x.Test_Package).Distinct(); + foreach (var item in testpackageList) + { + //鏌ヨ绗12涓〃鐨勬暟閲 + var punchlistFromList = Funs.DB.Transfer_PunchlistFrom.Where(x => x.ProjectId == ProjectId + && x.Test_Package == item + ).ToList(); + //濡傛灉鏌ュ埌 + if (punchlistFromList.Count > 0) + { + //12琛ㄥ綋鍓嶆棩鏈熷畬鎴愮殑鏁伴噺 + var punchlistFromFinshCount = punchlistFromList.Where(x => x.PUNCH_ITEM_STATUS.ToLower() == "finished").ToList().Count(); + //濡傛灉瀹屾垚鐨勬暟閲忕瓑浜庢诲緱鏁伴噺锛屽垯鏄畬鎴 + if (punchlistFromFinshCount == punchlistFromList.Count) + { + AfinishedCountSum += 1; + } + } + else + { + AfinishedCountSum += 1; + } + + } + break; + #endregion + #region Civil Structure + + + case "Civil Structure": + //鏍规嵁褰撳墠璁″垝瀹屾垚鏃ユ湡 鏌ヨ鎬荤殑璁″垝瀹屾垚鐨勬暟閲 + var systemListbyDate6 = Funs.DB.Transfer_Civil_Structure.Where(x => x.ProjectId == ProjectId + && x.Test_Package_FINISH >= sTime + && x.Test_Package_FINISH <= eTime + && x.FINAL_Status.ToLower() == "finished").ToList(); + //鏌ヨTestPackage 鍘婚噸 + testpackageList = (from x in systemListbyDate6 select x.Test_Package).Distinct(); + + foreach (var item in testpackageList) + { + //鏌ヨ绗12涓〃鐨勬暟閲 + var punchlistFromList = Funs.DB.Transfer_PunchlistFrom.Where(x => x.ProjectId == ProjectId + && x.Test_Package == item + ).ToList(); + //濡傛灉鏌ュ埌 + if (punchlistFromList.Count > 0) + { + //12琛ㄥ綋鍓嶆棩鏈熷畬鎴愮殑鏁伴噺 + var punchlistFromFinshCount = punchlistFromList.Where(x => x.PUNCH_ITEM_STATUS.ToLower() == "finished").ToList().Count(); + //濡傛灉瀹屾垚鐨勬暟閲忕瓑浜庢诲緱鏁伴噺锛屽垯鏄畬鎴 + if (punchlistFromFinshCount == punchlistFromList.Count) + { + PfinishedCountSum += 1; + } + } + else + { + PfinishedCountSum += 1; + } + + } + + //鑾峰彇褰撳墠鏃ユ湡鍐呭疄闄呭畬鎴愮殑鏁伴噺 + systemListbyDate6 = Funs.DB.Transfer_Civil_Structure.Where(x => x.ProjectId == ProjectId + && x.CompleteTime >= sTime + && x.CompleteTime <= eTime + && x.FINAL_Status.ToLower() == "finished").ToList(); + + testpackageList = (from x in systemListbyDate6 select x.Test_Package).Distinct(); + foreach (var item in testpackageList) + { + //鏌ヨ绗12涓〃鐨勬暟閲 + var punchlistFromList = Funs.DB.Transfer_PunchlistFrom.Where(x => x.ProjectId == ProjectId + && x.Test_Package == item + ).ToList(); + //濡傛灉鏌ュ埌 + if (punchlistFromList.Count > 0) + { + //12琛ㄥ綋鍓嶆棩鏈熷畬鎴愮殑鏁伴噺 + var punchlistFromFinshCount = punchlistFromList.Where(x => x.PUNCH_ITEM_STATUS.ToLower() == "finished").ToList().Count(); + //濡傛灉瀹屾垚鐨勬暟閲忕瓑浜庢诲緱鏁伴噺锛屽垯鏄畬鎴 + if (punchlistFromFinshCount == punchlistFromList.Count) + { + AfinishedCountSum += 1; + } + } + else + { + AfinishedCountSum += 1; + } + + } + break; + #endregion + #region Firefighting + + + case "Firefighting": + //鏍规嵁褰撳墠璁″垝瀹屾垚鏃ユ湡 鏌ヨ鎬荤殑璁″垝瀹屾垚鐨勬暟閲 + var systemListbyDate7 = Funs.DB.Transfer_Firefighting.Where(x => x.ProjectId == ProjectId + && x.Test_Package_FINISH >= sTime + && x.Test_Package_FINISH <= eTime + && x.FINAL_Status.ToLower() == "finished").ToList(); + //鏌ヨTestPackage 鍘婚噸 + testpackageList = (from x in systemListbyDate7 select x.Test_Package).Distinct(); + + foreach (var item in testpackageList) + { + //鏌ヨ绗12涓〃鐨勬暟閲 + var punchlistFromList = Funs.DB.Transfer_PunchlistFrom.Where(x => x.ProjectId == ProjectId + && x.Test_Package == item + ).ToList(); + //濡傛灉鏌ュ埌 + if (punchlistFromList.Count > 0) + { + //12琛ㄥ綋鍓嶆棩鏈熷畬鎴愮殑鏁伴噺 + var punchlistFromFinshCount = punchlistFromList.Where(x => x.PUNCH_ITEM_STATUS.ToLower() == "finished").ToList().Count(); + //濡傛灉瀹屾垚鐨勬暟閲忕瓑浜庢诲緱鏁伴噺锛屽垯鏄畬鎴 + if (punchlistFromFinshCount == punchlistFromList.Count) + { + PfinishedCountSum += 1; + } + } + else + { + PfinishedCountSum += 1; + } + + } + + //鑾峰彇褰撳墠鏃ユ湡鍐呭疄闄呭畬鎴愮殑鏁伴噺 + systemListbyDate7 = Funs.DB.Transfer_Firefighting.Where(x => x.ProjectId == ProjectId + && x.CompleteTime >= sTime + && x.CompleteTime <= eTime + && x.FINAL_Status.ToLower() == "finished").ToList(); + + testpackageList = (from x in systemListbyDate7 select x.Test_Package).Distinct(); + foreach (var item in testpackageList) + { + //鏌ヨ绗12涓〃鐨勬暟閲 + var punchlistFromList = Funs.DB.Transfer_PunchlistFrom.Where(x => x.ProjectId == ProjectId + && x.Test_Package == item + ).ToList(); + //濡傛灉鏌ュ埌 + if (punchlistFromList.Count > 0) + { + //12琛ㄥ綋鍓嶆棩鏈熷畬鎴愮殑鏁伴噺 + var punchlistFromFinshCount = punchlistFromList.Where(x => x.PUNCH_ITEM_STATUS.ToLower() == "finished").ToList().Count(); + //濡傛灉瀹屾垚鐨勬暟閲忕瓑浜庢诲緱鏁伴噺锛屽垯鏄畬鎴 + if (punchlistFromFinshCount == punchlistFromList.Count) + { + AfinishedCountSum += 1; + } + } + else + { + AfinishedCountSum += 1; + } + + } + break; + #endregion + #region Telecom + + + case "Telecom": + //鏍规嵁褰撳墠璁″垝瀹屾垚鏃ユ湡 鏌ヨ鎬荤殑璁″垝瀹屾垚鐨勬暟閲 + var systemListbyDate8 = Funs.DB.Transfer_Telecom.Where(x => x.ProjectId == ProjectId + && x.Test_Package_FINISH >= sTime + && x.Test_Package_FINISH <= eTime + && x.FINAL_Status.ToLower() == "finished").ToList(); + //鏌ヨTestPackage 鍘婚噸 + testpackageList = (from x in systemListbyDate8 select x.Test_Package).Distinct(); + + foreach (var item in testpackageList) + { + //鏌ヨ绗12涓〃鐨勬暟閲 + var punchlistFromList = Funs.DB.Transfer_PunchlistFrom.Where(x => x.ProjectId == ProjectId + && x.Test_Package == item + ).ToList(); + //濡傛灉鏌ュ埌 + if (punchlistFromList.Count > 0) + { + //12琛ㄥ綋鍓嶆棩鏈熷畬鎴愮殑鏁伴噺 + var punchlistFromFinshCount = punchlistFromList.Where(x => x.PUNCH_ITEM_STATUS.ToLower() == "finished").ToList().Count(); + //濡傛灉瀹屾垚鐨勬暟閲忕瓑浜庢诲緱鏁伴噺锛屽垯鏄畬鎴 + if (punchlistFromFinshCount == punchlistFromList.Count) + { + PfinishedCountSum += 1; + } + } + else + { + PfinishedCountSum += 1; + } + + } + + //鑾峰彇褰撳墠鏃ユ湡鍐呭疄闄呭畬鎴愮殑鏁伴噺 + systemListbyDate8 = Funs.DB.Transfer_Telecom.Where(x => x.ProjectId == ProjectId + && x.CompleteTime >= sTime + && x.CompleteTime <= eTime + && x.FINAL_Status.ToLower() == "finished").ToList(); + + testpackageList = (from x in systemListbyDate8 select x.Test_Package).Distinct(); + foreach (var item in testpackageList) + { + //鏌ヨ绗12涓〃鐨勬暟閲 + var punchlistFromList = Funs.DB.Transfer_PunchlistFrom.Where(x => x.ProjectId == ProjectId + && x.Test_Package == item + ).ToList(); + //濡傛灉鏌ュ埌 + if (punchlistFromList.Count > 0) + { + //12琛ㄥ綋鍓嶆棩鏈熷畬鎴愮殑鏁伴噺 + var punchlistFromFinshCount = punchlistFromList.Where(x => x.PUNCH_ITEM_STATUS.ToLower() == "finished").ToList().Count(); + //濡傛灉瀹屾垚鐨勬暟閲忕瓑浜庢诲緱鏁伴噺锛屽垯鏄畬鎴 + if (punchlistFromFinshCount == punchlistFromList.Count) + { + AfinishedCountSum += 1; + } + } + else + { + AfinishedCountSum += 1; + } + + } + break; + #endregion + #region Plumbing + + + case "Plumbing": + //鏍规嵁褰撳墠璁″垝瀹屾垚鏃ユ湡 鏌ヨ鎬荤殑璁″垝瀹屾垚鐨勬暟閲 + var systemListbyDate9 = Funs.DB.Transfer_Plumbing.Where(x => x.ProjectId == ProjectId + && x.Test_Package_FINISH >= sTime + && x.Test_Package_FINISH <= eTime + && x.FINAL_Status.ToLower() == "finished").ToList(); + //鏌ヨTestPackage 鍘婚噸 + testpackageList = (from x in systemListbyDate9 select x.Test_Package).Distinct(); + + foreach (var item in testpackageList) + { + //鏌ヨ绗12涓〃鐨勬暟閲 + var punchlistFromList = Funs.DB.Transfer_PunchlistFrom.Where(x => x.ProjectId == ProjectId + && x.Test_Package == item + ).ToList(); + //濡傛灉鏌ュ埌 + if (punchlistFromList.Count > 0) + { + //12琛ㄥ綋鍓嶆棩鏈熷畬鎴愮殑鏁伴噺 + var punchlistFromFinshCount = punchlistFromList.Where(x => x.PUNCH_ITEM_STATUS.ToLower() == "finished").ToList().Count(); + //濡傛灉瀹屾垚鐨勬暟閲忕瓑浜庢诲緱鏁伴噺锛屽垯鏄畬鎴 + if (punchlistFromFinshCount == punchlistFromList.Count) + { + PfinishedCountSum += 1; + } + } + else + { + PfinishedCountSum += 1; + } + + } + + //鑾峰彇褰撳墠鏃ユ湡鍐呭疄闄呭畬鎴愮殑鏁伴噺 + systemListbyDate9 = Funs.DB.Transfer_Plumbing.Where(x => x.ProjectId == ProjectId + && x.CompleteTime >= sTime + && x.CompleteTime <= eTime + && x.FINAL_Status.ToLower() == "finished").ToList(); + + testpackageList = (from x in systemListbyDate9 select x.Test_Package).Distinct(); + foreach (var item in testpackageList) + { + //鏌ヨ绗12涓〃鐨勬暟閲 + var punchlistFromList = Funs.DB.Transfer_PunchlistFrom.Where(x => x.ProjectId == ProjectId + && x.Test_Package == item + ).ToList(); + //濡傛灉鏌ュ埌 + if (punchlistFromList.Count > 0) + { + //12琛ㄥ綋鍓嶆棩鏈熷畬鎴愮殑鏁伴噺 + var punchlistFromFinshCount = punchlistFromList.Where(x => x.PUNCH_ITEM_STATUS.ToLower() == "finished").ToList().Count(); + //濡傛灉瀹屾垚鐨勬暟閲忕瓑浜庢诲緱鏁伴噺锛屽垯鏄畬鎴 + if (punchlistFromFinshCount == punchlistFromList.Count) + { + AfinishedCountSum += 1; + } + } + else + { + AfinishedCountSum += 1; + } + + } + break; + #endregion + #region HVAC + + + case "HVAC": + //鏍规嵁褰撳墠璁″垝瀹屾垚鏃ユ湡 鏌ヨ鎬荤殑璁″垝瀹屾垚鐨勬暟閲 + var systemListbyDate10 = Funs.DB.Transfer_HVAC.Where(x => x.ProjectId == ProjectId + && x.Test_Package_FINISH >= sTime + && x.Test_Package_FINISH <= eTime + && x.FINAL_Status.ToLower() == "finished").ToList(); + //鏌ヨTestPackage 鍘婚噸 + testpackageList = (from x in systemListbyDate10 select x.Test_Package).Distinct(); + + foreach (var item in testpackageList) + { + //鏌ヨ绗12涓〃鐨勬暟閲 + var punchlistFromList = Funs.DB.Transfer_PunchlistFrom.Where(x => x.ProjectId == ProjectId + && x.Test_Package == item + ).ToList(); + //濡傛灉鏌ュ埌 + if (punchlistFromList.Count > 0) + { + //12琛ㄥ綋鍓嶆棩鏈熷畬鎴愮殑鏁伴噺 + var punchlistFromFinshCount = punchlistFromList.Where(x => x.PUNCH_ITEM_STATUS.ToLower() == "finished").ToList().Count(); + //濡傛灉瀹屾垚鐨勬暟閲忕瓑浜庢诲緱鏁伴噺锛屽垯鏄畬鎴 + if (punchlistFromFinshCount == punchlistFromList.Count) + { + PfinishedCountSum += 1; + } + } + else + { + PfinishedCountSum += 1; + } + + } + + //鑾峰彇褰撳墠鏃ユ湡鍐呭疄闄呭畬鎴愮殑鏁伴噺 + systemListbyDate10 = Funs.DB.Transfer_HVAC.Where(x => x.ProjectId == ProjectId + && x.CompleteTime >= sTime + && x.CompleteTime <= eTime + && x.FINAL_Status.ToLower() == "finished").ToList(); + + testpackageList = (from x in systemListbyDate10 select x.Test_Package).Distinct(); + foreach (var item in testpackageList) + { + //鏌ヨ绗12涓〃鐨勬暟閲 + var punchlistFromList = Funs.DB.Transfer_PunchlistFrom.Where(x => x.ProjectId == ProjectId + && x.Test_Package == item + ).ToList(); + //濡傛灉鏌ュ埌 + if (punchlistFromList.Count > 0) + { + //12琛ㄥ綋鍓嶆棩鏈熷畬鎴愮殑鏁伴噺 + var punchlistFromFinshCount = punchlistFromList.Where(x => x.PUNCH_ITEM_STATUS.ToLower() == "finished").ToList().Count(); + //濡傛灉瀹屾垚鐨勬暟閲忕瓑浜庢诲緱鏁伴噺锛屽垯鏄畬鎴 + if (punchlistFromFinshCount == punchlistFromList.Count) + { + AfinishedCountSum += 1; + } + } + else + { + AfinishedCountSum += 1; + } + + } + break; + #endregion + } + + + DataTable dtTime = new DataTable(); + dtTime.Columns.Add("鏃ユ湡", typeof(string)); + dtTime.Columns.Add("Actual Finished(%)", typeof(string)); + dtTime.Columns.Add("Plan Finished(%)", typeof(string)); + + for (var i = sTime; i <= eTime; i = i.AddMonths(1)) { + var AfinishedCount = 0;//瀹為檯瀹屾垚鏁伴噺 + var PfinishedCount = 0;//璁″垝瀹屾垚鏁伴噺 + DataRow rowTime = dtTime.NewRow(); + rowTime["鏃ユ湡"] = string.Format("{0:yyyy-MM}", i); + switch (drpType.SelectedValue) + { + #region 鍏ㄩ儴 + case "": + //閫掑褰㈠紡锛屽紑濮嬫棩鏈熷氨鏄変腑鐨勫紑濮嬫棩鏈 + //鏍规嵁褰撳墠璁″垝瀹屾垚鏃ユ湡 鏌ヨ瀹屾垚鐨勬暟閲 + var systemListbyDate = Funs.DB.View_TransferDetail.Where(x => x.Projectid == ProjectId + && x.FDate >= sTime + && x.FDate < Convert.ToDateTime(rowTime["鏃ユ湡"]).AddMonths(1) + && x.Status.ToLower()== "finished").ToList(); + //鏌ヨTestPackage鐨勬绘暟閲忥紝鐘舵佹槸瀹屾垚鐨勩 + var testpackageList = (from x in systemListbyDate select x.TestPackage).Distinct(); + foreach (var item in testpackageList) { + //鏌ヨ绗12涓〃鐨勬暟閲 + var punchlistFromList = Funs.DB.Transfer_PunchlistFrom.Where(x => x.ProjectId == ProjectId + && x.Test_Package == item + ).ToList(); + //濡傛灉鏌ュ埌 + if (punchlistFromList.Count > 0) + { + //12琛ㄥ綋鍓嶆棩鏈熷畬鎴愮殑鏁伴噺 + var punchlistFromFinshCount = punchlistFromList.Where(x => x.PUNCH_ITEM_STATUS.ToLower() == "finished").ToList().Count(); + //濡傛灉瀹屾垚鐨勬暟閲忕瓑浜庢诲緱鏁伴噺锛屽垯鏄畬鎴 + if (punchlistFromFinshCount == punchlistFromList.Count) + { + PfinishedCount += 1; + } + } + else + { + PfinishedCount += 1; + } + } + //瀹屾垚鐨勬暟閲忥細xx瀹屾垚/鎬荤殑瀹屾垚 *100 + var Pcount = ((Convert.ToDouble(PfinishedCount) / Convert.ToDouble(PfinishedCountSum))); + if (PfinishedCount==0) + { + Pcount = 0; + } + rowTime["Plan Finished(%)"] = Pcount; + + + //瀹為檯鐨勫畬鎴愭暟閲 + systemListbyDate = Funs.DB.View_TransferDetail.Where(x => x.Projectid == ProjectId + && x.ADate >= sTime + && x.ADate < Convert.ToDateTime(rowTime["鏃ユ湡"]).AddMonths(1) + && x.Status.ToLower() == "finished").ToList(); + //鏌ヨTestPackage鐨勬绘暟閲忥紝鐘舵佹槸瀹屾垚鐨勩 + testpackageList = (from x in systemListbyDate select x.TestPackage).Distinct(); + foreach (var item in testpackageList) + { + //鏌ヨ绗12涓〃鐨勬暟閲 + var punchlistFromList = Funs.DB.Transfer_PunchlistFrom.Where(x => x.ProjectId == ProjectId + && x.Test_Package == item + ).ToList(); + //濡傛灉鏌ュ埌 + if (punchlistFromList.Count > 0) + { + //12琛ㄥ綋鍓嶆棩鏈熷畬鎴愮殑鏁伴噺 + var punchlistFromFinshCount = punchlistFromList.Where(x => x.PUNCH_ITEM_STATUS.ToLower() == "finished").ToList().Count(); + //濡傛灉瀹屾垚鐨勬暟閲忕瓑浜庢诲緱鏁伴噺锛屽垯鏄畬鎴 + if (punchlistFromFinshCount == punchlistFromList.Count) + { + AfinishedCount += 1; + } + } + else + { + AfinishedCount += 1; + } + } + //瀹屾垚鐨勬暟閲忥細xx瀹屾垚/鎬荤殑瀹屾垚 *100 + var Acount = ((Convert.ToDouble(AfinishedCount) / Convert.ToDouble(AfinishedCountSum))); + if (AfinishedCount==0) + { + Acount = 0; + } + rowTime["Actual Finished(%)"] = Acount; + dtTime.Rows.Add(rowTime); + continue; + #endregion + + #region Piping + case "Piping": + //閫掑褰㈠紡锛屽紑濮嬫棩鏈熷氨鏄変腑鐨勫紑濮嬫棩鏈 + //鏍规嵁褰撳墠璁″垝瀹屾垚鏃ユ湡 鏌ヨ瀹屾垚鐨勬暟閲 + var systemListbyDate1 = Funs.DB.Transfer_Piping.Where(x => x.ProjectId == ProjectId + && x.TestPackageFINISH >= sTime + && x.TestPackageFINISH < Convert.ToDateTime(rowTime["鏃ユ湡"]).AddMonths(1) + && x.FINALStatus.ToLower() == "finished").ToList(); + //鏌ヨTestPackage鐨勬绘暟閲忥紝鐘舵佹槸瀹屾垚鐨勩 + testpackageList = (from x in systemListbyDate1 select x.TestPackage).Distinct(); + foreach (var item in testpackageList) + { + //鏌ヨ绗12涓〃鐨勬暟閲 + var punchlistFromList = Funs.DB.Transfer_PunchlistFrom.Where(x => x.ProjectId == ProjectId + && x.Test_Package == item + ).ToList(); + //濡傛灉鏌ュ埌 + if (punchlistFromList.Count > 0) + { + //12琛ㄥ綋鍓嶆棩鏈熷畬鎴愮殑鏁伴噺 + var punchlistFromFinshCount = punchlistFromList.Where(x => x.PUNCH_ITEM_STATUS.ToLower() == "finished").ToList().Count(); + //濡傛灉瀹屾垚鐨勬暟閲忕瓑浜庢诲緱鏁伴噺锛屽垯鏄畬鎴 + if (punchlistFromFinshCount == punchlistFromList.Count) + { + PfinishedCount += 1; + } + } + else + { + PfinishedCount += 1; + } + } + //瀹屾垚鐨勬暟閲忥細xx瀹屾垚/鎬荤殑瀹屾垚 *100 + Pcount = ((Convert.ToDouble(PfinishedCount) / Convert.ToDouble(PfinishedCountSum))); + if (PfinishedCount == 0) + { + Pcount = 0; + } + rowTime["Plan Finished(%)"] = Pcount; + + + //瀹為檯鐨勫畬鎴愭暟閲 + systemListbyDate1 = Funs.DB.Transfer_Piping.Where(x => x.ProjectId == ProjectId + && x.CompleteTime >= sTime + && x.CompleteTime < Convert.ToDateTime(rowTime["鏃ユ湡"]).AddMonths(1) + && x.FINALStatus.ToLower() == "finished").ToList(); + //鏌ヨTestPackage鐨勬绘暟閲忥紝鐘舵佹槸瀹屾垚鐨勩 + testpackageList = (from x in systemListbyDate1 select x.TestPackage).Distinct(); + foreach (var item in testpackageList) + { + //鏌ヨ绗12涓〃鐨勬暟閲 + var punchlistFromList = Funs.DB.Transfer_PunchlistFrom.Where(x => x.ProjectId == ProjectId + && x.Test_Package == item + ).ToList(); + //濡傛灉鏌ュ埌 + if (punchlistFromList.Count > 0) + { + //12琛ㄥ綋鍓嶆棩鏈熷畬鎴愮殑鏁伴噺 + var punchlistFromFinshCount = punchlistFromList.Where(x => x.PUNCH_ITEM_STATUS.ToLower() == "finished").ToList().Count(); + //濡傛灉瀹屾垚鐨勬暟閲忕瓑浜庢诲緱鏁伴噺锛屽垯鏄畬鎴 + if (punchlistFromFinshCount == punchlistFromList.Count) + { + AfinishedCount += 1; + } + } + else + { + AfinishedCount += 1; + } + } + //瀹屾垚鐨勬暟閲忥細xx瀹屾垚/鎬荤殑瀹屾垚 *100 + if (AfinishedCount == 0) + { + Acount = 0; + rowTime["Actual Finished(%)"] = Acount; + dtTime.Rows.Add(rowTime); + } + else { + Acount = ((Convert.ToDouble(AfinishedCount) / Convert.ToDouble(AfinishedCountSum))); + rowTime["Actual Finished(%)"] = Acount; + dtTime.Rows.Add(rowTime); + } + + continue; + #endregion + + #region Static Equipment + case "Static Equipment": + //閫掑褰㈠紡锛屽紑濮嬫棩鏈熷氨鏄変腑鐨勫紑濮嬫棩鏈 + //鏍规嵁褰撳墠璁″垝瀹屾垚鏃ユ湡 鏌ヨ瀹屾垚鐨勬暟閲 + var systemListbyDate2 = Funs.DB.Transfer_StaticEquipment.Where(x => x.ProjectId == ProjectId + && x.TestPackageFINISH >= sTime + && x.TestPackageFINISH < Convert.ToDateTime(rowTime["鏃ユ湡"]).AddMonths(1) + && x.MechanicalFINALStatus.ToLower() == "finished").ToList(); + //鏌ヨTestPackage鐨勬绘暟閲忥紝鐘舵佹槸瀹屾垚鐨勩 + testpackageList = (from x in systemListbyDate2 select x.TestPackage).Distinct(); + foreach (var item in testpackageList) + { + //鏌ヨ绗12涓〃鐨勬暟閲 + var punchlistFromList = Funs.DB.Transfer_PunchlistFrom.Where(x => x.ProjectId == ProjectId + && x.Test_Package == item + ).ToList(); + //濡傛灉鏌ュ埌 + if (punchlistFromList.Count > 0) + { + //12琛ㄥ綋鍓嶆棩鏈熷畬鎴愮殑鏁伴噺 + var punchlistFromFinshCount = punchlistFromList.Where(x => x.PUNCH_ITEM_STATUS.ToLower() == "finished").ToList().Count(); + //濡傛灉瀹屾垚鐨勬暟閲忕瓑浜庢诲緱鏁伴噺锛屽垯鏄畬鎴 + if (punchlistFromFinshCount == punchlistFromList.Count) + { + PfinishedCount += 1; + } + } + else + { + PfinishedCount += 1; + } + } + //瀹屾垚鐨勬暟閲忥細xx瀹屾垚/鎬荤殑瀹屾垚 *100 + Pcount = ((Convert.ToDouble(PfinishedCount) / Convert.ToDouble(PfinishedCountSum))); + if (PfinishedCount == 0) + { + Pcount = 0; + } + rowTime["Plan Finished(%)"] = Pcount; + + + //瀹為檯鐨勫畬鎴愭暟閲 + systemListbyDate2 = Funs.DB.Transfer_StaticEquipment.Where(x => x.ProjectId == ProjectId + && x.CompleteTime >= sTime + && x.CompleteTime < Convert.ToDateTime(rowTime["鏃ユ湡"]).AddMonths(1) + && x.MechanicalFINALStatus.ToLower() == "finished").ToList(); + //鏌ヨTestPackage鐨勬绘暟閲忥紝鐘舵佹槸瀹屾垚鐨勩 + testpackageList = (from x in systemListbyDate2 select x.TestPackage).Distinct(); + foreach (var item in testpackageList) + { + //鏌ヨ绗12涓〃鐨勬暟閲 + var punchlistFromList = Funs.DB.Transfer_PunchlistFrom.Where(x => x.ProjectId == ProjectId + && x.Test_Package == item + ).ToList(); + //濡傛灉鏌ュ埌 + if (punchlistFromList.Count > 0) + { + //12琛ㄥ綋鍓嶆棩鏈熷畬鎴愮殑鏁伴噺 + var punchlistFromFinshCount = punchlistFromList.Where(x => x.PUNCH_ITEM_STATUS.ToLower() == "finished").ToList().Count(); + //濡傛灉瀹屾垚鐨勬暟閲忕瓑浜庢诲緱鏁伴噺锛屽垯鏄畬鎴 + if (punchlistFromFinshCount == punchlistFromList.Count) + { + AfinishedCount += 1; + } + } + else + { + AfinishedCount += 1; + } + } + //瀹屾垚鐨勬暟閲忥細xx瀹屾垚/鎬荤殑瀹屾垚 *100 + if (AfinishedCount == 0) + { + Acount = 0; + rowTime["Actual Finished(%)"] = Acount; + dtTime.Rows.Add(rowTime); + } + else + { + Acount = ((Convert.ToDouble(AfinishedCount) / Convert.ToDouble(AfinishedCountSum))); + rowTime["Actual Finished(%)"] = Acount; + dtTime.Rows.Add(rowTime); + } + continue; + #endregion + + #region Rotating Equipment + case "Rotating Equipment": + //閫掑褰㈠紡锛屽紑濮嬫棩鏈熷氨鏄変腑鐨勫紑濮嬫棩鏈 + //鏍规嵁褰撳墠璁″垝瀹屾垚鏃ユ湡 鏌ヨ瀹屾垚鐨勬暟閲 + var systemListbyDate3 = Funs.DB.Transfer_RotatingEquipment.Where(x => x.ProjectId == ProjectId + && x.TestPackageFINISH >= sTime + && x.TestPackageFINISH < Convert.ToDateTime(rowTime["鏃ユ湡"]).AddMonths(1) + && x.MechanicalFINALStatus.ToLower() == "finished").ToList(); + //鏌ヨTestPackage鐨勬绘暟閲忥紝鐘舵佹槸瀹屾垚鐨勩 + testpackageList = (from x in systemListbyDate3 select x.TestPackage).Distinct(); + foreach (var item in testpackageList) + { + //鏌ヨ绗12涓〃鐨勬暟閲 + var punchlistFromList = Funs.DB.Transfer_PunchlistFrom.Where(x => x.ProjectId == ProjectId + && x.Test_Package == item + ).ToList(); + //濡傛灉鏌ュ埌 + if (punchlistFromList.Count > 0) + { + //12琛ㄥ綋鍓嶆棩鏈熷畬鎴愮殑鏁伴噺 + var punchlistFromFinshCount = punchlistFromList.Where(x => x.PUNCH_ITEM_STATUS.ToLower() == "finished").ToList().Count(); + //濡傛灉瀹屾垚鐨勬暟閲忕瓑浜庢诲緱鏁伴噺锛屽垯鏄畬鎴 + if (punchlistFromFinshCount == punchlistFromList.Count) + { + PfinishedCount += 1; + } + } + else + { + PfinishedCount += 1; + } + } + //瀹屾垚鐨勬暟閲忥細xx瀹屾垚/鎬荤殑瀹屾垚 *100 + Pcount = ((Convert.ToDouble(PfinishedCount) / Convert.ToDouble(PfinishedCountSum))); + if (PfinishedCount == 0) + { + Pcount = 0; + } + rowTime["Plan Finished(%)"] = Pcount; + + + //瀹為檯鐨勫畬鎴愭暟閲 + systemListbyDate3 = Funs.DB.Transfer_RotatingEquipment.Where(x => x.ProjectId == ProjectId + && x.CompleteTime >= sTime + && x.CompleteTime < Convert.ToDateTime(rowTime["鏃ユ湡"]).AddMonths(1) + && x.MechanicalFINALStatus.ToLower() == "finished").ToList(); + //鏌ヨTestPackage鐨勬绘暟閲忥紝鐘舵佹槸瀹屾垚鐨勩 + testpackageList = (from x in systemListbyDate3 select x.TestPackage).Distinct(); + foreach (var item in testpackageList) + { + //鏌ヨ绗12涓〃鐨勬暟閲 + var punchlistFromList = Funs.DB.Transfer_PunchlistFrom.Where(x => x.ProjectId == ProjectId + && x.Test_Package == item + ).ToList(); + //濡傛灉鏌ュ埌 + if (punchlistFromList.Count > 0) + { + //12琛ㄥ綋鍓嶆棩鏈熷畬鎴愮殑鏁伴噺 + var punchlistFromFinshCount = punchlistFromList.Where(x => x.PUNCH_ITEM_STATUS.ToLower() == "finished").ToList().Count(); + //濡傛灉瀹屾垚鐨勬暟閲忕瓑浜庢诲緱鏁伴噺锛屽垯鏄畬鎴 + if (punchlistFromFinshCount == punchlistFromList.Count) + { + AfinishedCount += 1; + } + } + else + { + AfinishedCount += 1; + } + } + //瀹屾垚鐨勬暟閲忥細xx瀹屾垚/鎬荤殑瀹屾垚 *100 + if (AfinishedCount == 0) + { + Acount = 0; + rowTime["Actual Finished(%)"] = Acount; + dtTime.Rows.Add(rowTime); + } + else + { + Acount = ((Convert.ToDouble(AfinishedCount) / Convert.ToDouble(AfinishedCountSum))); + rowTime["Actual Finished(%)"] = Acount; + dtTime.Rows.Add(rowTime); + } + continue; + #endregion + + #region Instrumentation + case "Transfer_Instrumentation": + //閫掑褰㈠紡锛屽紑濮嬫棩鏈熷氨鏄変腑鐨勫紑濮嬫棩鏈 + //鏍规嵁褰撳墠璁″垝瀹屾垚鏃ユ湡 鏌ヨ瀹屾垚鐨勬暟閲 + var systemListbyDate4 = Funs.DB.Transfer_Instrumentation.Where(x => x.ProjectId == ProjectId + && x.Test_Package_FINISH >= sTime + && x.Test_Package_FINISH < Convert.ToDateTime(rowTime["鏃ユ湡"]).AddMonths(1) + && x.FINAL_Status.ToLower() == "finished").ToList(); + //鏌ヨTestPackage鐨勬绘暟閲忥紝鐘舵佹槸瀹屾垚鐨勩 + testpackageList = (from x in systemListbyDate4 select x.Test_Package).Distinct(); + foreach (var item in testpackageList) + { + //鏌ヨ绗12涓〃鐨勬暟閲 + var punchlistFromList = Funs.DB.Transfer_PunchlistFrom.Where(x => x.ProjectId == ProjectId + && x.Test_Package == item + ).ToList(); + //濡傛灉鏌ュ埌 + if (punchlistFromList.Count > 0) + { + //12琛ㄥ綋鍓嶆棩鏈熷畬鎴愮殑鏁伴噺 + var punchlistFromFinshCount = punchlistFromList.Where(x => x.PUNCH_ITEM_STATUS.ToLower() == "finished").ToList().Count(); + //濡傛灉瀹屾垚鐨勬暟閲忕瓑浜庢诲緱鏁伴噺锛屽垯鏄畬鎴 + if (punchlistFromFinshCount == punchlistFromList.Count) + { + PfinishedCount += 1; + } + } + else + { + PfinishedCount += 1; + } + } + //瀹屾垚鐨勬暟閲忥細xx瀹屾垚/鎬荤殑瀹屾垚 *100 + Pcount = ((Convert.ToDouble(PfinishedCount) / Convert.ToDouble(PfinishedCountSum))); + if (PfinishedCount == 0) + { + Pcount = 0; + } + rowTime["Plan Finished(%)"] = Pcount; + + + //瀹為檯鐨勫畬鎴愭暟閲 + systemListbyDate4 = Funs.DB.Transfer_Instrumentation.Where(x => x.ProjectId == ProjectId + && x.CompleteTime >= sTime + && x.CompleteTime < Convert.ToDateTime(rowTime["鏃ユ湡"]).AddMonths(1) + && x.FINAL_Status.ToLower() == "finished").ToList(); + //鏌ヨTestPackage鐨勬绘暟閲忥紝鐘舵佹槸瀹屾垚鐨勩 + testpackageList = (from x in systemListbyDate4 select x.Test_Package).Distinct(); + foreach (var item in testpackageList) + { + //鏌ヨ绗12涓〃鐨勬暟閲 + var punchlistFromList = Funs.DB.Transfer_PunchlistFrom.Where(x => x.ProjectId == ProjectId + && x.Test_Package == item + ).ToList(); + //濡傛灉鏌ュ埌 + if (punchlistFromList.Count > 0) + { + //12琛ㄥ綋鍓嶆棩鏈熷畬鎴愮殑鏁伴噺 + var punchlistFromFinshCount = punchlistFromList.Where(x => x.PUNCH_ITEM_STATUS.ToLower() == "finished").ToList().Count(); + //濡傛灉瀹屾垚鐨勬暟閲忕瓑浜庢诲緱鏁伴噺锛屽垯鏄畬鎴 + if (punchlistFromFinshCount == punchlistFromList.Count) + { + AfinishedCount += 1; + } + } + else + { + AfinishedCount += 1; + } + } + //瀹屾垚鐨勬暟閲忥細xx瀹屾垚/鎬荤殑瀹屾垚 *100 + if (AfinishedCount == 0) + { + Acount = 0; + rowTime["Actual Finished(%)"] = Acount; + dtTime.Rows.Add(rowTime); + } + else + { + Acount = ((Convert.ToDouble(AfinishedCount) / Convert.ToDouble(AfinishedCountSum))); + rowTime["Actual Finished(%)"] = Acount; + dtTime.Rows.Add(rowTime); + } + continue; + #endregion + + #region Electrical + case "Electrical": + //閫掑褰㈠紡锛屽紑濮嬫棩鏈熷氨鏄変腑鐨勫紑濮嬫棩鏈 + //鏍规嵁褰撳墠璁″垝瀹屾垚鏃ユ湡 鏌ヨ瀹屾垚鐨勬暟閲 + var systemListbyDate5 = Funs.DB.Transfer_Electrical.Where(x => x.ProjectId == ProjectId + && x.Test_Package_FINISH >= sTime + && x.Test_Package_FINISH < Convert.ToDateTime(rowTime["鏃ユ湡"]).AddMonths(1) + && x.FINAL_Status.ToLower() == "finished").ToList(); + //鏌ヨTestPackage鐨勬绘暟閲忥紝鐘舵佹槸瀹屾垚鐨勩 + testpackageList = (from x in systemListbyDate5 select x.Test_Package).Distinct(); + foreach (var item in testpackageList) + { + //鏌ヨ绗12涓〃鐨勬暟閲 + var punchlistFromList = Funs.DB.Transfer_PunchlistFrom.Where(x => x.ProjectId == ProjectId + && x.Test_Package == item + ).ToList(); + //濡傛灉鏌ュ埌 + if (punchlistFromList.Count > 0) + { + //12琛ㄥ綋鍓嶆棩鏈熷畬鎴愮殑鏁伴噺 + var punchlistFromFinshCount = punchlistFromList.Where(x => x.PUNCH_ITEM_STATUS.ToLower() == "finished").ToList().Count(); + //濡傛灉瀹屾垚鐨勬暟閲忕瓑浜庢诲緱鏁伴噺锛屽垯鏄畬鎴 + if (punchlistFromFinshCount == punchlistFromList.Count) + { + PfinishedCount += 1; + } + } + else + { + PfinishedCount += 1; + } + } + //瀹屾垚鐨勬暟閲忥細xx瀹屾垚/鎬荤殑瀹屾垚 *100 + Pcount = ((Convert.ToDouble(PfinishedCount) / Convert.ToDouble(PfinishedCountSum))); + if (PfinishedCount == 0) + { + Pcount = 0; + } + rowTime["Plan Finished(%)"] = Pcount; + + + //瀹為檯鐨勫畬鎴愭暟閲 + systemListbyDate5 = Funs.DB.Transfer_Electrical.Where(x => x.ProjectId == ProjectId + && x.CompleteTime >= sTime + && x.CompleteTime < Convert.ToDateTime(rowTime["鏃ユ湡"]).AddMonths(1) + && x.FINAL_Status.ToLower() == "finished").ToList(); + //鏌ヨTestPackage鐨勬绘暟閲忥紝鐘舵佹槸瀹屾垚鐨勩 + testpackageList = (from x in systemListbyDate5 select x.Test_Package).Distinct(); + foreach (var item in testpackageList) + { + //鏌ヨ绗12涓〃鐨勬暟閲 + var punchlistFromList = Funs.DB.Transfer_PunchlistFrom.Where(x => x.ProjectId == ProjectId + && x.Test_Package == item + ).ToList(); + //濡傛灉鏌ュ埌 + if (punchlistFromList.Count > 0) + { + //12琛ㄥ綋鍓嶆棩鏈熷畬鎴愮殑鏁伴噺 + var punchlistFromFinshCount = punchlistFromList.Where(x => x.PUNCH_ITEM_STATUS.ToLower() == "finished").ToList().Count(); + //濡傛灉瀹屾垚鐨勬暟閲忕瓑浜庢诲緱鏁伴噺锛屽垯鏄畬鎴 + if (punchlistFromFinshCount == punchlistFromList.Count) + { + AfinishedCount += 1; + } + } + else + { + AfinishedCount += 1; + } + } + //瀹屾垚鐨勬暟閲忥細xx瀹屾垚/鎬荤殑瀹屾垚 *100 + if (AfinishedCount == 0) + { + Acount = 0; + rowTime["Actual Finished(%)"] = Acount; + dtTime.Rows.Add(rowTime); + } + else + { + Acount = ((Convert.ToDouble(AfinishedCount) / Convert.ToDouble(AfinishedCountSum))); + rowTime["Actual Finished(%)"] = Acount; + dtTime.Rows.Add(rowTime); + } + continue; + #endregion + + #region Civil Structure + case "Civil Structure": + //閫掑褰㈠紡锛屽紑濮嬫棩鏈熷氨鏄変腑鐨勫紑濮嬫棩鏈 + //鏍规嵁褰撳墠璁″垝瀹屾垚鏃ユ湡 鏌ヨ瀹屾垚鐨勬暟閲 + var systemListbyDate6 = Funs.DB.Transfer_Civil_Structure.Where(x => x.ProjectId == ProjectId + && x.Test_Package_FINISH >= sTime + && x.Test_Package_FINISH < Convert.ToDateTime(rowTime["鏃ユ湡"]).AddMonths(1) + && x.FINAL_Status.ToLower() == "finished").ToList(); + //鏌ヨTestPackage鐨勬绘暟閲忥紝鐘舵佹槸瀹屾垚鐨勩 + testpackageList = (from x in systemListbyDate6 select x.Test_Package).Distinct(); + foreach (var item in testpackageList) + { + //鏌ヨ绗12涓〃鐨勬暟閲 + var punchlistFromList = Funs.DB.Transfer_PunchlistFrom.Where(x => x.ProjectId == ProjectId + && x.Test_Package == item + ).ToList(); + //濡傛灉鏌ュ埌 + if (punchlistFromList.Count > 0) + { + //12琛ㄥ綋鍓嶆棩鏈熷畬鎴愮殑鏁伴噺 + var punchlistFromFinshCount = punchlistFromList.Where(x => x.PUNCH_ITEM_STATUS.ToLower() == "finished").ToList().Count(); + //濡傛灉瀹屾垚鐨勬暟閲忕瓑浜庢诲緱鏁伴噺锛屽垯鏄畬鎴 + if (punchlistFromFinshCount == punchlistFromList.Count) + { + PfinishedCount += 1; + } + } + else + { + PfinishedCount += 1; + } + } + //瀹屾垚鐨勬暟閲忥細xx瀹屾垚/鎬荤殑瀹屾垚 *100 + Pcount = ((Convert.ToDouble(PfinishedCount) / Convert.ToDouble(PfinishedCountSum))); + if (PfinishedCount == 0) + { + Pcount = 0; + } + rowTime["Plan Finished(%)"] = Pcount; + + + //瀹為檯鐨勫畬鎴愭暟閲 + systemListbyDate6 = Funs.DB.Transfer_Civil_Structure.Where(x => x.ProjectId == ProjectId + && x.CompleteTime >= sTime + && x.CompleteTime < Convert.ToDateTime(rowTime["鏃ユ湡"]).AddMonths(1) + && x.FINAL_Status.ToLower() == "finished").ToList(); + //鏌ヨTestPackage鐨勬绘暟閲忥紝鐘舵佹槸瀹屾垚鐨勩 + testpackageList = (from x in systemListbyDate6 select x.Test_Package).Distinct(); + foreach (var item in testpackageList) + { + //鏌ヨ绗12涓〃鐨勬暟閲 + var punchlistFromList = Funs.DB.Transfer_PunchlistFrom.Where(x => x.ProjectId == ProjectId + && x.Test_Package == item + ).ToList(); + //濡傛灉鏌ュ埌 + if (punchlistFromList.Count > 0) + { + //12琛ㄥ綋鍓嶆棩鏈熷畬鎴愮殑鏁伴噺 + var punchlistFromFinshCount = punchlistFromList.Where(x => x.PUNCH_ITEM_STATUS.ToLower() == "finished").ToList().Count(); + //濡傛灉瀹屾垚鐨勬暟閲忕瓑浜庢诲緱鏁伴噺锛屽垯鏄畬鎴 + if (punchlistFromFinshCount == punchlistFromList.Count) + { + AfinishedCount += 1; + } + } + else + { + AfinishedCount += 1; + } + } + //瀹屾垚鐨勬暟閲忥細xx瀹屾垚/鎬荤殑瀹屾垚 *100 + if (AfinishedCount == 0) + { + Acount = 0; + rowTime["Actual Finished(%)"] = Acount; + dtTime.Rows.Add(rowTime); + } + else + { + Acount = ((Convert.ToDouble(AfinishedCount) / Convert.ToDouble(AfinishedCountSum))); + rowTime["Actual Finished(%)"] = Acount; + dtTime.Rows.Add(rowTime); + } + continue; + #endregion + + #region Firefighting + case "Firefighting": + //閫掑褰㈠紡锛屽紑濮嬫棩鏈熷氨鏄変腑鐨勫紑濮嬫棩鏈 + //鏍规嵁褰撳墠璁″垝瀹屾垚鏃ユ湡 鏌ヨ瀹屾垚鐨勬暟閲 + var systemListbyDate8 = Funs.DB.Transfer_Firefighting.Where(x => x.ProjectId == ProjectId + && x.Test_Package_FINISH >= sTime + && x.Test_Package_FINISH < Convert.ToDateTime(rowTime["鏃ユ湡"]).AddMonths(1) + && x.FINAL_Status.ToLower() == "finished").ToList(); + //鏌ヨTestPackage鐨勬绘暟閲忥紝鐘舵佹槸瀹屾垚鐨勩 + testpackageList = (from x in systemListbyDate8 select x.Test_Package).Distinct(); + foreach (var item in testpackageList) + { + //鏌ヨ绗12涓〃鐨勬暟閲 + var punchlistFromList = Funs.DB.Transfer_PunchlistFrom.Where(x => x.ProjectId == ProjectId + && x.Test_Package == item + ).ToList(); + //濡傛灉鏌ュ埌 + if (punchlistFromList.Count > 0) + { + //12琛ㄥ綋鍓嶆棩鏈熷畬鎴愮殑鏁伴噺 + var punchlistFromFinshCount = punchlistFromList.Where(x => x.PUNCH_ITEM_STATUS.ToLower() == "finished").ToList().Count(); + //濡傛灉瀹屾垚鐨勬暟閲忕瓑浜庢诲緱鏁伴噺锛屽垯鏄畬鎴 + if (punchlistFromFinshCount == punchlistFromList.Count) + { + PfinishedCount += 1; + } + } + else + { + PfinishedCount += 1; + } + } + //瀹屾垚鐨勬暟閲忥細xx瀹屾垚/鎬荤殑瀹屾垚 *100 + Pcount = ((Convert.ToDouble(PfinishedCount) / Convert.ToDouble(PfinishedCountSum))); + if (PfinishedCount == 0) + { + Pcount = 0; + } + rowTime["Plan Finished(%)"] = Pcount; + + + //瀹為檯鐨勫畬鎴愭暟閲 + systemListbyDate8 = Funs.DB.Transfer_Firefighting.Where(x => x.ProjectId == ProjectId + && x.CompleteTime >= sTime + && x.CompleteTime < Convert.ToDateTime(rowTime["鏃ユ湡"]).AddMonths(1) + && x.FINAL_Status.ToLower() == "finished").ToList(); + //鏌ヨTestPackage鐨勬绘暟閲忥紝鐘舵佹槸瀹屾垚鐨勩 + testpackageList = (from x in systemListbyDate8 select x.Test_Package).Distinct(); + foreach (var item in testpackageList) + { + //鏌ヨ绗12涓〃鐨勬暟閲 + var punchlistFromList = Funs.DB.Transfer_PunchlistFrom.Where(x => x.ProjectId == ProjectId + && x.Test_Package == item + ).ToList(); + //濡傛灉鏌ュ埌 + if (punchlistFromList.Count > 0) + { + //12琛ㄥ綋鍓嶆棩鏈熷畬鎴愮殑鏁伴噺 + var punchlistFromFinshCount = punchlistFromList.Where(x => x.PUNCH_ITEM_STATUS.ToLower() == "finished").ToList().Count(); + //濡傛灉瀹屾垚鐨勬暟閲忕瓑浜庢诲緱鏁伴噺锛屽垯鏄畬鎴 + if (punchlistFromFinshCount == punchlistFromList.Count) + { + AfinishedCount += 1; + } + } + else + { + AfinishedCount += 1; + } + } + //瀹屾垚鐨勬暟閲忥細xx瀹屾垚/鎬荤殑瀹屾垚 *100 + if (AfinishedCount == 0) + { + Acount = 0; + rowTime["Actual Finished(%)"] = Acount; + dtTime.Rows.Add(rowTime); + } + else + { + Acount = ((Convert.ToDouble(AfinishedCount) / Convert.ToDouble(AfinishedCountSum))); + rowTime["Actual Finished(%)"] = Acount; + dtTime.Rows.Add(rowTime); + } + continue; + #endregion + + #region Telecom + case "Telecom": + //閫掑褰㈠紡锛屽紑濮嬫棩鏈熷氨鏄変腑鐨勫紑濮嬫棩鏈 + //鏍规嵁褰撳墠璁″垝瀹屾垚鏃ユ湡 鏌ヨ瀹屾垚鐨勬暟閲 + var systemListbyDate9 = Funs.DB.Transfer_Telecom.Where(x => x.ProjectId == ProjectId + && x.Test_Package_FINISH >= sTime + && x.Test_Package_FINISH < Convert.ToDateTime(rowTime["鏃ユ湡"]).AddMonths(1) + && x.FINAL_Status.ToLower() == "finished").ToList(); + //鏌ヨTestPackage鐨勬绘暟閲忥紝鐘舵佹槸瀹屾垚鐨勩 + testpackageList = (from x in systemListbyDate9 select x.Test_Package).Distinct(); + foreach (var item in testpackageList) + { + //鏌ヨ绗12涓〃鐨勬暟閲 + var punchlistFromList = Funs.DB.Transfer_PunchlistFrom.Where(x => x.ProjectId == ProjectId + && x.Test_Package == item + ).ToList(); + //濡傛灉鏌ュ埌 + if (punchlistFromList.Count > 0) + { + //12琛ㄥ綋鍓嶆棩鏈熷畬鎴愮殑鏁伴噺 + var punchlistFromFinshCount = punchlistFromList.Where(x => x.PUNCH_ITEM_STATUS.ToLower() == "finished").ToList().Count(); + //濡傛灉瀹屾垚鐨勬暟閲忕瓑浜庢诲緱鏁伴噺锛屽垯鏄畬鎴 + if (punchlistFromFinshCount == punchlistFromList.Count) + { + PfinishedCount += 1; + } + } + else + { + PfinishedCount += 1; + } + } + //瀹屾垚鐨勬暟閲忥細xx瀹屾垚/鎬荤殑瀹屾垚 *100 + Pcount = ((Convert.ToDouble(PfinishedCount) / Convert.ToDouble(PfinishedCountSum))); + if (PfinishedCount == 0) + { + Pcount = 0; + } + rowTime["Plan Finished(%)"] = Pcount; + + + //瀹為檯鐨勫畬鎴愭暟閲 + systemListbyDate9 = Funs.DB.Transfer_Telecom.Where(x => x.ProjectId == ProjectId + && x.CompleteTime >= sTime + && x.CompleteTime < Convert.ToDateTime(rowTime["鏃ユ湡"]).AddMonths(1) + && x.FINAL_Status.ToLower() == "finished").ToList(); + //鏌ヨTestPackage鐨勬绘暟閲忥紝鐘舵佹槸瀹屾垚鐨勩 + testpackageList = (from x in systemListbyDate9 select x.Test_Package).Distinct(); + foreach (var item in testpackageList) + { + //鏌ヨ绗12涓〃鐨勬暟閲 + var punchlistFromList = Funs.DB.Transfer_PunchlistFrom.Where(x => x.ProjectId == ProjectId + && x.Test_Package == item + ).ToList(); + //濡傛灉鏌ュ埌 + if (punchlistFromList.Count > 0) + { + //12琛ㄥ綋鍓嶆棩鏈熷畬鎴愮殑鏁伴噺 + var punchlistFromFinshCount = punchlistFromList.Where(x => x.PUNCH_ITEM_STATUS.ToLower() == "finished").ToList().Count(); + //濡傛灉瀹屾垚鐨勬暟閲忕瓑浜庢诲緱鏁伴噺锛屽垯鏄畬鎴 + if (punchlistFromFinshCount == punchlistFromList.Count) + { + AfinishedCount += 1; + } + } + else + { + AfinishedCount += 1; + } + } + //瀹屾垚鐨勬暟閲忥細xx瀹屾垚/鎬荤殑瀹屾垚 *100 + if (AfinishedCount == 0) + { + Acount = 0; + rowTime["Actual Finished(%)"] = Acount; + dtTime.Rows.Add(rowTime); + } + else + { + Acount = ((Convert.ToDouble(AfinishedCount) / Convert.ToDouble(AfinishedCountSum))); + rowTime["Actual Finished(%)"] = Acount; + dtTime.Rows.Add(rowTime); + } + continue; + #endregion + + #region Plumbing + case "Plumbing": + //閫掑褰㈠紡锛屽紑濮嬫棩鏈熷氨鏄変腑鐨勫紑濮嬫棩鏈 + //鏍规嵁褰撳墠璁″垝瀹屾垚鏃ユ湡 鏌ヨ瀹屾垚鐨勬暟閲 + var systemListbyDate10 = Funs.DB.Transfer_Plumbing.Where(x => x.ProjectId == ProjectId + && x.Test_Package_FINISH >= sTime + && x.Test_Package_FINISH < Convert.ToDateTime(rowTime["鏃ユ湡"]).AddMonths(1) + && x.FINAL_Status.ToLower() == "finished").ToList(); + //鏌ヨTestPackage鐨勬绘暟閲忥紝鐘舵佹槸瀹屾垚鐨勩 + testpackageList = (from x in systemListbyDate10 select x.Test_Package).Distinct(); + foreach (var item in testpackageList) + { + //鏌ヨ绗12涓〃鐨勬暟閲 + var punchlistFromList = Funs.DB.Transfer_PunchlistFrom.Where(x => x.ProjectId == ProjectId + && x.Test_Package == item + ).ToList(); + //濡傛灉鏌ュ埌 + if (punchlistFromList.Count > 0) + { + //12琛ㄥ綋鍓嶆棩鏈熷畬鎴愮殑鏁伴噺 + var punchlistFromFinshCount = punchlistFromList.Where(x => x.PUNCH_ITEM_STATUS.ToLower() == "finished").ToList().Count(); + //濡傛灉瀹屾垚鐨勬暟閲忕瓑浜庢诲緱鏁伴噺锛屽垯鏄畬鎴 + if (punchlistFromFinshCount == punchlistFromList.Count) + { + PfinishedCount += 1; + } + } + else + { + PfinishedCount += 1; + } + } + //瀹屾垚鐨勬暟閲忥細xx瀹屾垚/鎬荤殑瀹屾垚 *100 + Pcount = ((Convert.ToDouble(PfinishedCount) / Convert.ToDouble(PfinishedCountSum))); + if (PfinishedCount == 0) + { + Pcount = 0; + } + rowTime["Plan Finished(%)"] = Pcount; + + + //瀹為檯鐨勫畬鎴愭暟閲 + systemListbyDate10 = Funs.DB.Transfer_Plumbing.Where(x => x.ProjectId == ProjectId + && x.CompleteTime >= sTime + && x.CompleteTime < Convert.ToDateTime(rowTime["鏃ユ湡"]).AddMonths(1) + && x.FINAL_Status.ToLower() == "finished").ToList(); + //鏌ヨTestPackage鐨勬绘暟閲忥紝鐘舵佹槸瀹屾垚鐨勩 + testpackageList = (from x in systemListbyDate10 select x.Test_Package).Distinct(); + foreach (var item in testpackageList) + { + //鏌ヨ绗12涓〃鐨勬暟閲 + var punchlistFromList = Funs.DB.Transfer_PunchlistFrom.Where(x => x.ProjectId == ProjectId + && x.Test_Package == item + ).ToList(); + //濡傛灉鏌ュ埌 + if (punchlistFromList.Count > 0) + { + //12琛ㄥ綋鍓嶆棩鏈熷畬鎴愮殑鏁伴噺 + var punchlistFromFinshCount = punchlistFromList.Where(x => x.PUNCH_ITEM_STATUS.ToLower() == "finished").ToList().Count(); + //濡傛灉瀹屾垚鐨勬暟閲忕瓑浜庢诲緱鏁伴噺锛屽垯鏄畬鎴 + if (punchlistFromFinshCount == punchlistFromList.Count) + { + AfinishedCount += 1; + } + } + else + { + AfinishedCount += 1; + } + } + //瀹屾垚鐨勬暟閲忥細xx瀹屾垚/鎬荤殑瀹屾垚 *100 + if (AfinishedCount == 0) + { + Acount = 0; + rowTime["Actual Finished(%)"] = Acount; + dtTime.Rows.Add(rowTime); + } + else + { + Acount = ((Convert.ToDouble(AfinishedCount) / Convert.ToDouble(AfinishedCountSum))); + rowTime["Actual Finished(%)"] = Acount; + dtTime.Rows.Add(rowTime); + } + continue; + #endregion + + #region HVAC + case "HVAC": + //閫掑褰㈠紡锛屽紑濮嬫棩鏈熷氨鏄変腑鐨勫紑濮嬫棩鏈 + //鏍规嵁褰撳墠璁″垝瀹屾垚鏃ユ湡 鏌ヨ瀹屾垚鐨勬暟閲 + var systemListbyDate11 = Funs.DB.Transfer_HVAC.Where(x => x.ProjectId == ProjectId + && x.Test_Package_FINISH >= sTime + && x.Test_Package_FINISH < Convert.ToDateTime(rowTime["鏃ユ湡"]).AddMonths(1) + && x.FINAL_Status.ToLower() == "finished").ToList(); + //鏌ヨTestPackage鐨勬绘暟閲忥紝鐘舵佹槸瀹屾垚鐨勩 + testpackageList = (from x in systemListbyDate11 select x.Test_Package).Distinct(); + foreach (var item in testpackageList) + { + //鏌ヨ绗12涓〃鐨勬暟閲 + var punchlistFromList = Funs.DB.Transfer_PunchlistFrom.Where(x => x.ProjectId == ProjectId + && x.Test_Package == item + ).ToList(); + //濡傛灉鏌ュ埌 + if (punchlistFromList.Count > 0) + { + //12琛ㄥ綋鍓嶆棩鏈熷畬鎴愮殑鏁伴噺 + var punchlistFromFinshCount = punchlistFromList.Where(x => x.PUNCH_ITEM_STATUS.ToLower() == "finished").ToList().Count(); + //濡傛灉瀹屾垚鐨勬暟閲忕瓑浜庢诲緱鏁伴噺锛屽垯鏄畬鎴 + if (punchlistFromFinshCount == punchlistFromList.Count) + { + PfinishedCount += 1; + } + } + else + { + PfinishedCount += 1; + } + } + //瀹屾垚鐨勬暟閲忥細xx瀹屾垚/鎬荤殑瀹屾垚 *100 + Pcount = ((Convert.ToDouble(PfinishedCount) / Convert.ToDouble(PfinishedCountSum))); + if (PfinishedCount == 0) + { + Pcount = 0; + } + rowTime["Plan Finished(%)"] = Pcount; + + + //瀹為檯鐨勫畬鎴愭暟閲 + systemListbyDate11 = Funs.DB.Transfer_HVAC.Where(x => x.ProjectId == ProjectId + && x.CompleteTime >= sTime + && x.CompleteTime < Convert.ToDateTime(rowTime["鏃ユ湡"]).AddMonths(1) + && x.FINAL_Status.ToLower() == "finished").ToList(); + //鏌ヨTestPackage鐨勬绘暟閲忥紝鐘舵佹槸瀹屾垚鐨勩 + testpackageList = (from x in systemListbyDate11 select x.Test_Package).Distinct(); + foreach (var item in testpackageList) + { + //鏌ヨ绗12涓〃鐨勬暟閲 + var punchlistFromList = Funs.DB.Transfer_PunchlistFrom.Where(x => x.ProjectId == ProjectId + && x.Test_Package == item + ).ToList(); + //濡傛灉鏌ュ埌 + if (punchlistFromList.Count > 0) + { + //12琛ㄥ綋鍓嶆棩鏈熷畬鎴愮殑鏁伴噺 + var punchlistFromFinshCount = punchlistFromList.Where(x => x.PUNCH_ITEM_STATUS.ToLower() == "finished").ToList().Count(); + //濡傛灉瀹屾垚鐨勬暟閲忕瓑浜庢诲緱鏁伴噺锛屽垯鏄畬鎴 + if (punchlistFromFinshCount == punchlistFromList.Count) + { + AfinishedCount += 1; + } + } + else + { + AfinishedCount += 1; + } + } + //瀹屾垚鐨勬暟閲忥細xx瀹屾垚/鎬荤殑瀹屾垚 *100 + if (AfinishedCount == 0) + { + Acount = 0; + rowTime["Actual Finished(%)"] = Acount; + dtTime.Rows.Add(rowTime); + } + else + { + Acount = ((Convert.ToDouble(AfinishedCount) / Convert.ToDouble(AfinishedCountSum))); + rowTime["Actual Finished(%)"] = Acount; + dtTime.Rows.Add(rowTime); + } + continue; + #endregion + + } + + + } + this.ChartUc.CreateChartBaifenbi(BLL.ChartControlService.GetDataSourceChartByYijiao(dtTime, "PROGRESS REPORT", "Line", 1300, 600, false)); + } + #endregion + } +} \ No newline at end of file diff --git a/SGGL/FineUIPro.Web/Transfer/Chart/TransferChart.aspx.designer.cs b/SGGL/FineUIPro.Web/Transfer/Chart/TransferChart.aspx.designer.cs new file mode 100644 index 00000000..fe4095aa --- /dev/null +++ b/SGGL/FineUIPro.Web/Transfer/Chart/TransferChart.aspx.designer.cs @@ -0,0 +1,152 @@ +锘//------------------------------------------------------------------------------ +// <鑷姩鐢熸垚> +// 姝や唬鐮佺敱宸ュ叿鐢熸垚銆 +// +// 瀵规鏂囦欢鐨勬洿鏀瑰彲鑳藉鑷翠笉姝g‘鐨勮涓猴紝濡傛灉 +// 閲嶆柊鐢熸垚浠g爜锛屽垯鎵鍋氭洿鏀瑰皢涓㈠け銆 +// +//------------------------------------------------------------------------------ + +namespace FineUIPro.Web.Transfer.Chart +{ + + + public partial class TransferChart + { + + /// + /// form1 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::System.Web.UI.HtmlControls.HtmlForm form1; + + /// + /// PageManager1 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.PageManager PageManager1; + + /// + /// RegionPanel1 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.RegionPanel RegionPanel1; + + /// + /// Region1 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.Region Region1; + + /// + /// Form2 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.Form Form2; + + /// + /// drpType 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.DropDownList drpType; + + /// + /// txtStarTime 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.DatePicker txtStarTime; + + /// + /// Label3 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.Label Label3; + + /// + /// txtEndTime 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.DatePicker txtEndTime; + + /// + /// BtnAnalyse 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.Button BtnAnalyse; + + /// + /// Region2 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.Region Region2; + + /// + /// TabStrip1 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.TabStrip TabStrip1; + + /// + /// Tab2 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.Tab Tab2; + + /// + /// cpCostTime 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.ContentPanel cpCostTime; + + /// + /// ChartUc 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::Web.Controls.ChartControl ChartUc; + } +} diff --git a/SGGL/FineUIPro.Web/Transfer/CivilStructure.aspx b/SGGL/FineUIPro.Web/Transfer/CivilStructure.aspx index e31a2e4d..eae82268 100644 --- a/SGGL/FineUIPro.Web/Transfer/CivilStructure.aspx +++ b/SGGL/FineUIPro.Web/Transfer/CivilStructure.aspx @@ -24,6 +24,8 @@ + + diff --git a/SGGL/FineUIPro.Web/Transfer/CivilStructure.aspx.cs b/SGGL/FineUIPro.Web/Transfer/CivilStructure.aspx.cs index b9844950..24c855b6 100644 --- a/SGGL/FineUIPro.Web/Transfer/CivilStructure.aspx.cs +++ b/SGGL/FineUIPro.Web/Transfer/CivilStructure.aspx.cs @@ -50,6 +50,12 @@ namespace FineUIPro.Web.Transfer strSql += " AND Test_Package_START <= @InspectionDateZ"; listStr.Add(new SqlParameter("@InspectionDateZ", Funs.GetNewDateTime(txtEndTime.Text.Trim()))); } + if (!string.IsNullOrEmpty(this.txtSystem.Text.Trim())) + { + strSql += " AND SystemName like @SystemName"; + listStr.Add(new SqlParameter("@SystemName", "%" + this.txtSystem.Text.Trim() + "%")); + } + strSql += " order by Civil_Structure "; SqlParameter[] parameter = listStr.ToArray(); DataTable tb = SQLHelper.GetDataTableRunText(strSql, parameter); diff --git a/SGGL/FineUIPro.Web/Transfer/CivilStructure.aspx.designer.cs b/SGGL/FineUIPro.Web/Transfer/CivilStructure.aspx.designer.cs index 783a843e..4fbe8adf 100644 --- a/SGGL/FineUIPro.Web/Transfer/CivilStructure.aspx.designer.cs +++ b/SGGL/FineUIPro.Web/Transfer/CivilStructure.aspx.designer.cs @@ -68,6 +68,15 @@ namespace FineUIPro.Web.Transfer /// protected global::FineUIPro.TextBox txtCivil_Structure; + /// + /// txtSystem 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.TextBox txtSystem; + /// /// txtStarTime 鎺т欢銆 /// diff --git a/SGGL/FineUIPro.Web/Transfer/CivilStructureDataIn.aspx.cs b/SGGL/FineUIPro.Web/Transfer/CivilStructureDataIn.aspx.cs index d7472dc3..27aa40b4 100644 --- a/SGGL/FineUIPro.Web/Transfer/CivilStructureDataIn.aspx.cs +++ b/SGGL/FineUIPro.Web/Transfer/CivilStructureDataIn.aspx.cs @@ -181,7 +181,7 @@ namespace FineUIPro.Web.Transfer } } string row5 = pds.Rows[i][5].ToString(); - if (!string.IsNullOrEmpty(row4)) + if (!string.IsNullOrEmpty(row5)) { try { @@ -329,41 +329,52 @@ namespace FineUIPro.Web.Transfer List list = new List(); for (int i = 1; i < ir; i++) { - //鏌ヨ绗竴鍒楋紝娌℃煡鍒扮殑鎯呭喌涓嬩綔瀵煎叆澶勭悊 - var modelOnly = Funs.DB.Transfer_Civil_Structure.FirstOrDefault(x => x.Civil_Structure == pds.Rows[i][0].ToString().Trim() + if (!string.IsNullOrEmpty(pds.Rows[i][0].ToString().Trim())) + { + //鏌ヨ绗竴鍒楋紝娌℃煡鍒扮殑鎯呭喌涓嬩綔瀵煎叆澶勭悊 + var modelOnly = Funs.DB.Transfer_Civil_Structure.FirstOrDefault(x => x.Civil_Structure == pds.Rows[i][0].ToString().Trim() && x.ProjectId == CurrUser.LoginProjectId); - if (modelOnly==null) - { - Model.Transfer_Civil_Structure model = new Model.Transfer_Civil_Structure(); - model.Id = Guid.NewGuid().ToString(); - model.ProjectId = CurrUser.LoginProjectId; - model.Civil_Structure = pds.Rows[i][0].ToString().Trim(); - model.SystemName = pds.Rows[i][1].ToString().Trim(); - model.Subsystem = pds.Rows[i][2].ToString().Trim(); - model.Test_Package = pds.Rows[i][3].ToString().Trim(); - DateTime t1, t2; - if (DateTime.TryParse(pds.Rows[i][4].ToString(), out t1) && !string.IsNullOrEmpty(pds.Rows[i][4].ToString())) - model.Test_Package_START = t1; - if (DateTime.TryParse(pds.Rows[i][5].ToString(), out t2) && !string.IsNullOrEmpty(pds.Rows[i][5].ToString())) - model.Test_Package_FINISH = t2; + if (modelOnly == null) + { + Model.Transfer_Civil_Structure model = new Model.Transfer_Civil_Structure(); + model.Id = Guid.NewGuid().ToString(); + model.ProjectId = CurrUser.LoginProjectId; + model.Civil_Structure = pds.Rows[i][0].ToString().Trim(); + model.SystemName = pds.Rows[i][1].ToString().Trim(); + model.Subsystem = pds.Rows[i][2].ToString().Trim(); + model.Test_Package = pds.Rows[i][3].ToString().Trim(); + DateTime t1, t2; + if (DateTime.TryParse(pds.Rows[i][4].ToString(), out t1) && !string.IsNullOrEmpty(pds.Rows[i][4].ToString())) + model.Test_Package_START = t1; + if (DateTime.TryParse(pds.Rows[i][5].ToString(), out t2) && !string.IsNullOrEmpty(pds.Rows[i][5].ToString())) + model.Test_Package_FINISH = t2; - model.FINAL_Status = pds.Rows[i][6].ToString().Trim(); - list.Add(model); - } - else - { - //淇敼 - modelOnly.Civil_Structure = pds.Rows[i][0].ToString().Trim(); - modelOnly.SystemName = pds.Rows[i][1].ToString().Trim(); - modelOnly.Subsystem = pds.Rows[i][2].ToString().Trim(); - modelOnly.Test_Package = pds.Rows[i][3].ToString().Trim(); - DateTime t1, t2; - if (DateTime.TryParse(pds.Rows[i][4].ToString(), out t1) && !string.IsNullOrEmpty(pds.Rows[i][4].ToString())) - modelOnly.Test_Package_START = t1; - if (DateTime.TryParse(pds.Rows[i][5].ToString(), out t2) && !string.IsNullOrEmpty(pds.Rows[i][5].ToString())) - modelOnly.Test_Package_FINISH = t2; - modelOnly.FINAL_Status = pds.Rows[i][6].ToString().Trim(); - Funs.DB.SubmitChanges(); + model.FINAL_Status = pds.Rows[i][6].ToString().Trim(); + if (model.FINAL_Status.ToLower() == "finished") + { + model.CompleteTime = DateTime.Now; + } + list.Add(model); + } + else + { + //淇敼 + modelOnly.Civil_Structure = pds.Rows[i][0].ToString().Trim(); + modelOnly.SystemName = pds.Rows[i][1].ToString().Trim(); + modelOnly.Subsystem = pds.Rows[i][2].ToString().Trim(); + modelOnly.Test_Package = pds.Rows[i][3].ToString().Trim(); + DateTime t1, t2; + if (DateTime.TryParse(pds.Rows[i][4].ToString(), out t1) && !string.IsNullOrEmpty(pds.Rows[i][4].ToString())) + modelOnly.Test_Package_START = t1; + if (DateTime.TryParse(pds.Rows[i][5].ToString(), out t2) && !string.IsNullOrEmpty(pds.Rows[i][5].ToString())) + modelOnly.Test_Package_FINISH = t2; + modelOnly.FINAL_Status = pds.Rows[i][6].ToString().Trim(); + if (modelOnly.FINAL_Status.ToLower() == "finished") + { + modelOnly.CompleteTime = DateTime.Now; + } + Funs.DB.SubmitChanges(); + } } } if (list.Count > 0) diff --git a/SGGL/FineUIPro.Web/Transfer/Electrical.aspx b/SGGL/FineUIPro.Web/Transfer/Electrical.aspx index 66d65ca6..22689192 100644 --- a/SGGL/FineUIPro.Web/Transfer/Electrical.aspx +++ b/SGGL/FineUIPro.Web/Transfer/Electrical.aspx @@ -24,6 +24,8 @@ + + diff --git a/SGGL/FineUIPro.Web/Transfer/Electrical.aspx.cs b/SGGL/FineUIPro.Web/Transfer/Electrical.aspx.cs index 0c674ca9..12d64925 100644 --- a/SGGL/FineUIPro.Web/Transfer/Electrical.aspx.cs +++ b/SGGL/FineUIPro.Web/Transfer/Electrical.aspx.cs @@ -51,6 +51,12 @@ namespace FineUIPro.Web.Transfer listStr.Add(new SqlParameter("@InspectionDateZ", Funs.GetNewDateTime(txtEndTime.Text.Trim()))); } + if (!string.IsNullOrEmpty(this.txtSystem.Text.Trim())) + { + strSql += " AND SystemName like @SystemName"; + listStr.Add(new SqlParameter("@SystemName", "%" + this.txtSystem.Text.Trim() + "%")); + } + strSql += " order by ELECTRICAL "; SqlParameter[] parameter = listStr.ToArray(); diff --git a/SGGL/FineUIPro.Web/Transfer/Electrical.aspx.designer.cs b/SGGL/FineUIPro.Web/Transfer/Electrical.aspx.designer.cs index 07ce47f3..da5c48b7 100644 --- a/SGGL/FineUIPro.Web/Transfer/Electrical.aspx.designer.cs +++ b/SGGL/FineUIPro.Web/Transfer/Electrical.aspx.designer.cs @@ -68,6 +68,15 @@ namespace FineUIPro.Web.Transfer /// protected global::FineUIPro.TextBox txtELECTRICAL; + /// + /// txtSystem 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.TextBox txtSystem; + /// /// txtStarTime 鎺т欢銆 /// diff --git a/SGGL/FineUIPro.Web/Transfer/ElectricalDataIn.aspx.cs b/SGGL/FineUIPro.Web/Transfer/ElectricalDataIn.aspx.cs index add980dc..210b4df8 100644 --- a/SGGL/FineUIPro.Web/Transfer/ElectricalDataIn.aspx.cs +++ b/SGGL/FineUIPro.Web/Transfer/ElectricalDataIn.aspx.cs @@ -180,7 +180,7 @@ namespace FineUIPro.Web.Transfer } } string row5 = pds.Rows[i][5].ToString(); - if (!string.IsNullOrEmpty(row4)) + if (!string.IsNullOrEmpty(row5)) { try { @@ -328,41 +328,53 @@ namespace FineUIPro.Web.Transfer List list = new List(); for (int i = 1; i < ir; i++) { - //鏌ヨ绗竴鍒楋紝娌℃煡鍒扮殑鎯呭喌涓嬩綔瀵煎叆澶勭悊 - var modelOnly = Funs.DB.Transfer_Electrical.FirstOrDefault(x => x.ELECTRICAL == pds.Rows[i][0].ToString().Trim() + if (!string.IsNullOrEmpty(pds.Rows[i][0].ToString().Trim())) + { + //鏌ヨ绗竴鍒楋紝娌℃煡鍒扮殑鎯呭喌涓嬩綔瀵煎叆澶勭悊 + var modelOnly = Funs.DB.Transfer_Electrical.FirstOrDefault(x => x.ELECTRICAL == pds.Rows[i][0].ToString().Trim() && x.ProjectId == CurrUser.LoginProjectId); - if (modelOnly == null) - { - Model.Transfer_Electrical model = new Model.Transfer_Electrical(); - model.Id = Guid.NewGuid().ToString(); - model.ProjectId = CurrUser.LoginProjectId; - model.ELECTRICAL = pds.Rows[i][0].ToString().Trim(); - model.SystemName = pds.Rows[i][1].ToString().Trim(); - model.Subsystem = pds.Rows[i][2].ToString().Trim(); - model.Test_Package = pds.Rows[i][3].ToString().Trim(); - DateTime t1, t2; - if (DateTime.TryParse(pds.Rows[i][4].ToString(), out t1) && !string.IsNullOrEmpty(pds.Rows[i][4].ToString())) - model.Test_Package_START = t1; - if (DateTime.TryParse(pds.Rows[i][5].ToString(), out t2) && !string.IsNullOrEmpty(pds.Rows[i][5].ToString())) - model.Test_Package_FINISH = t2; + if (modelOnly == null) + { + Model.Transfer_Electrical model = new Model.Transfer_Electrical(); + model.Id = Guid.NewGuid().ToString(); + model.ProjectId = CurrUser.LoginProjectId; + model.ELECTRICAL = pds.Rows[i][0].ToString().Trim(); + model.SystemName = pds.Rows[i][1].ToString().Trim(); + model.Subsystem = pds.Rows[i][2].ToString().Trim(); + model.Test_Package = pds.Rows[i][3].ToString().Trim(); + DateTime t1, t2; + if (DateTime.TryParse(pds.Rows[i][4].ToString(), out t1) && !string.IsNullOrEmpty(pds.Rows[i][4].ToString())) + model.Test_Package_START = t1; + if (DateTime.TryParse(pds.Rows[i][5].ToString(), out t2) && !string.IsNullOrEmpty(pds.Rows[i][5].ToString())) + model.Test_Package_FINISH = t2; - model.FINAL_Status = pds.Rows[i][6].ToString().Trim(); - list.Add(model); - } - else - { - //淇敼 - modelOnly.ELECTRICAL = pds.Rows[i][0].ToString().Trim(); - modelOnly.SystemName = pds.Rows[i][1].ToString().Trim(); - modelOnly.Subsystem = pds.Rows[i][2].ToString().Trim(); - modelOnly.Test_Package = pds.Rows[i][3].ToString().Trim(); - DateTime t1, t2; - if (DateTime.TryParse(pds.Rows[i][4].ToString(), out t1) && !string.IsNullOrEmpty(pds.Rows[i][4].ToString())) - modelOnly.Test_Package_START = t1; - if (DateTime.TryParse(pds.Rows[i][5].ToString(), out t2) && !string.IsNullOrEmpty(pds.Rows[i][5].ToString())) - modelOnly.Test_Package_FINISH = t2; - modelOnly.FINAL_Status = pds.Rows[i][6].ToString().Trim(); - Funs.DB.SubmitChanges(); + model.FINAL_Status = pds.Rows[i][6].ToString().Trim(); + if (model.FINAL_Status.ToLower() == "finished") + { + model.CompleteTime = DateTime.Now; + } + + list.Add(model); + } + else + { + //淇敼 + modelOnly.ELECTRICAL = pds.Rows[i][0].ToString().Trim(); + modelOnly.SystemName = pds.Rows[i][1].ToString().Trim(); + modelOnly.Subsystem = pds.Rows[i][2].ToString().Trim(); + modelOnly.Test_Package = pds.Rows[i][3].ToString().Trim(); + DateTime t1, t2; + if (DateTime.TryParse(pds.Rows[i][4].ToString(), out t1) && !string.IsNullOrEmpty(pds.Rows[i][4].ToString())) + modelOnly.Test_Package_START = t1; + if (DateTime.TryParse(pds.Rows[i][5].ToString(), out t2) && !string.IsNullOrEmpty(pds.Rows[i][5].ToString())) + modelOnly.Test_Package_FINISH = t2; + modelOnly.FINAL_Status = pds.Rows[i][6].ToString().Trim(); + if (modelOnly.FINAL_Status.ToLower() == "finished") + { + modelOnly.CompleteTime = DateTime.Now; + } + Funs.DB.SubmitChanges(); + } } } if (list.Count > 0) diff --git a/SGGL/FineUIPro.Web/Transfer/Firefighting.aspx b/SGGL/FineUIPro.Web/Transfer/Firefighting.aspx index c342ea2e..110128f9 100644 --- a/SGGL/FineUIPro.Web/Transfer/Firefighting.aspx +++ b/SGGL/FineUIPro.Web/Transfer/Firefighting.aspx @@ -24,6 +24,8 @@ + + diff --git a/SGGL/FineUIPro.Web/Transfer/Firefighting.aspx.cs b/SGGL/FineUIPro.Web/Transfer/Firefighting.aspx.cs index e31ff404..c18a64d4 100644 --- a/SGGL/FineUIPro.Web/Transfer/Firefighting.aspx.cs +++ b/SGGL/FineUIPro.Web/Transfer/Firefighting.aspx.cs @@ -50,6 +50,11 @@ namespace FineUIPro.Web.Transfer strSql += " AND Test_Package_START <= @InspectionDateZ"; listStr.Add(new SqlParameter("@InspectionDateZ", Funs.GetNewDateTime(txtEndTime.Text.Trim()))); } + if (!string.IsNullOrEmpty(this.txtSystem.Text.Trim())) + { + strSql += " AND SystemName like @SystemName"; + listStr.Add(new SqlParameter("@SystemName", "%" + this.txtSystem.Text.Trim() + "%")); + } strSql += " order by Firefighting "; diff --git a/SGGL/FineUIPro.Web/Transfer/Firefighting.aspx.designer.cs b/SGGL/FineUIPro.Web/Transfer/Firefighting.aspx.designer.cs index f8080d74..fe469cc9 100644 --- a/SGGL/FineUIPro.Web/Transfer/Firefighting.aspx.designer.cs +++ b/SGGL/FineUIPro.Web/Transfer/Firefighting.aspx.designer.cs @@ -68,6 +68,15 @@ namespace FineUIPro.Web.Transfer /// protected global::FineUIPro.TextBox txtFirefighting; + /// + /// txtSystem 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.TextBox txtSystem; + /// /// txtStarTime 鎺т欢銆 /// diff --git a/SGGL/FineUIPro.Web/Transfer/FirefightingDataIn.aspx.cs b/SGGL/FineUIPro.Web/Transfer/FirefightingDataIn.aspx.cs index 25961140..537d4feb 100644 --- a/SGGL/FineUIPro.Web/Transfer/FirefightingDataIn.aspx.cs +++ b/SGGL/FineUIPro.Web/Transfer/FirefightingDataIn.aspx.cs @@ -181,7 +181,7 @@ namespace FineUIPro.Web.Transfer } } string row5 = pds.Rows[i][5].ToString(); - if (!string.IsNullOrEmpty(row4)) + if (!string.IsNullOrEmpty(row5)) { try { @@ -329,40 +329,51 @@ namespace FineUIPro.Web.Transfer List list = new List(); for (int i = 1; i < ir; i++) { - //鏌ヨ绗竴鍒楋紝娌℃煡鍒扮殑鎯呭喌涓嬩綔瀵煎叆澶勭悊 - var modelOnly = Funs.DB.Transfer_Firefighting.FirstOrDefault(x => x.Firefighting == pds.Rows[i][0].ToString().Trim() && x.ProjectId == CurrUser.LoginProjectId); - if (modelOnly == null) + if (!string.IsNullOrEmpty(pds.Rows[i][0].ToString().Trim())) { - Model.Transfer_Firefighting model = new Model.Transfer_Firefighting(); - model.Id = Guid.NewGuid().ToString(); - model.ProjectId = CurrUser.LoginProjectId; - model.Firefighting = pds.Rows[i][0].ToString().Trim(); - model.SystemName = pds.Rows[i][1].ToString().Trim(); - model.Subsystem = pds.Rows[i][2].ToString().Trim(); - model.Test_Package = pds.Rows[i][3].ToString().Trim(); - DateTime t1, t2; - if (DateTime.TryParse(pds.Rows[i][4].ToString(), out t1) && !string.IsNullOrEmpty(pds.Rows[i][4].ToString())) - model.Test_Package_START = t1; - if (DateTime.TryParse(pds.Rows[i][5].ToString(), out t2) && !string.IsNullOrEmpty(pds.Rows[i][5].ToString())) - model.Test_Package_FINISH = t2; + //鏌ヨ绗竴鍒楋紝娌℃煡鍒扮殑鎯呭喌涓嬩綔瀵煎叆澶勭悊 + var modelOnly = Funs.DB.Transfer_Firefighting.FirstOrDefault(x => x.Firefighting == pds.Rows[i][0].ToString().Trim() && x.ProjectId == CurrUser.LoginProjectId); + if (modelOnly == null) + { + Model.Transfer_Firefighting model = new Model.Transfer_Firefighting(); + model.Id = Guid.NewGuid().ToString(); + model.ProjectId = CurrUser.LoginProjectId; + model.Firefighting = pds.Rows[i][0].ToString().Trim(); + model.SystemName = pds.Rows[i][1].ToString().Trim(); + model.Subsystem = pds.Rows[i][2].ToString().Trim(); + model.Test_Package = pds.Rows[i][3].ToString().Trim(); + DateTime t1, t2; + if (DateTime.TryParse(pds.Rows[i][4].ToString(), out t1) && !string.IsNullOrEmpty(pds.Rows[i][4].ToString())) + model.Test_Package_START = t1; + if (DateTime.TryParse(pds.Rows[i][5].ToString(), out t2) && !string.IsNullOrEmpty(pds.Rows[i][5].ToString())) + model.Test_Package_FINISH = t2; - model.FINAL_Status = pds.Rows[i][6].ToString().Trim(); - list.Add(model); - } - else - { - //淇敼 - modelOnly.Firefighting = pds.Rows[i][0].ToString().Trim(); - modelOnly.SystemName = pds.Rows[i][1].ToString().Trim(); - modelOnly.Subsystem = pds.Rows[i][2].ToString().Trim(); - modelOnly.Test_Package = pds.Rows[i][3].ToString().Trim(); - DateTime t1, t2; - if (DateTime.TryParse(pds.Rows[i][4].ToString(), out t1) && !string.IsNullOrEmpty(pds.Rows[i][4].ToString())) - modelOnly.Test_Package_START = t1; - if (DateTime.TryParse(pds.Rows[i][5].ToString(), out t2) && !string.IsNullOrEmpty(pds.Rows[i][5].ToString())) - modelOnly.Test_Package_FINISH = t2; - modelOnly.FINAL_Status = pds.Rows[i][6].ToString().Trim(); - Funs.DB.SubmitChanges(); + model.FINAL_Status = pds.Rows[i][6].ToString().Trim(); + if (model.FINAL_Status.ToLower() == "finished") + { + model.CompleteTime = DateTime.Now; + } + list.Add(model); + } + else + { + //淇敼 + modelOnly.Firefighting = pds.Rows[i][0].ToString().Trim(); + modelOnly.SystemName = pds.Rows[i][1].ToString().Trim(); + modelOnly.Subsystem = pds.Rows[i][2].ToString().Trim(); + modelOnly.Test_Package = pds.Rows[i][3].ToString().Trim(); + DateTime t1, t2; + if (DateTime.TryParse(pds.Rows[i][4].ToString(), out t1) && !string.IsNullOrEmpty(pds.Rows[i][4].ToString())) + modelOnly.Test_Package_START = t1; + if (DateTime.TryParse(pds.Rows[i][5].ToString(), out t2) && !string.IsNullOrEmpty(pds.Rows[i][5].ToString())) + modelOnly.Test_Package_FINISH = t2; + modelOnly.FINAL_Status = pds.Rows[i][6].ToString().Trim(); + if (modelOnly.FINAL_Status.ToLower() == "finished") + { + modelOnly.CompleteTime = DateTime.Now; + } + Funs.DB.SubmitChanges(); + } } } if (list.Count > 0) diff --git a/SGGL/FineUIPro.Web/Transfer/HVAC.aspx b/SGGL/FineUIPro.Web/Transfer/HVAC.aspx index 0705d0af..752f6115 100644 --- a/SGGL/FineUIPro.Web/Transfer/HVAC.aspx +++ b/SGGL/FineUIPro.Web/Transfer/HVAC.aspx @@ -25,6 +25,8 @@ + + diff --git a/SGGL/FineUIPro.Web/Transfer/HVAC.aspx.cs b/SGGL/FineUIPro.Web/Transfer/HVAC.aspx.cs index 2c981fe7..eb9cc132 100644 --- a/SGGL/FineUIPro.Web/Transfer/HVAC.aspx.cs +++ b/SGGL/FineUIPro.Web/Transfer/HVAC.aspx.cs @@ -50,6 +50,12 @@ namespace FineUIPro.Web.Transfer strSql += " AND Test_Package_START <= @InspectionDateZ"; listStr.Add(new SqlParameter("@InspectionDateZ", Funs.GetNewDateTime(txtEndTime.Text.Trim()))); } + if (!string.IsNullOrEmpty(this.txtSystem.Text.Trim())) + { + strSql += " AND SystemName like @SystemName"; + listStr.Add(new SqlParameter("@SystemName", "%" + this.txtSystem.Text.Trim() + "%")); + } + strSql += " order by HVAC "; SqlParameter[] parameter = listStr.ToArray(); diff --git a/SGGL/FineUIPro.Web/Transfer/HVAC.aspx.designer.cs b/SGGL/FineUIPro.Web/Transfer/HVAC.aspx.designer.cs index b796f0e3..95a07ad2 100644 --- a/SGGL/FineUIPro.Web/Transfer/HVAC.aspx.designer.cs +++ b/SGGL/FineUIPro.Web/Transfer/HVAC.aspx.designer.cs @@ -68,6 +68,15 @@ namespace FineUIPro.Web.Transfer /// protected global::FineUIPro.TextBox txtHVAC; + /// + /// txtSystem 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.TextBox txtSystem; + /// /// txtStarTime 鎺т欢銆 /// diff --git a/SGGL/FineUIPro.Web/Transfer/HVACDataIn.aspx.cs b/SGGL/FineUIPro.Web/Transfer/HVACDataIn.aspx.cs index 3b779322..9f190958 100644 --- a/SGGL/FineUIPro.Web/Transfer/HVACDataIn.aspx.cs +++ b/SGGL/FineUIPro.Web/Transfer/HVACDataIn.aspx.cs @@ -180,7 +180,7 @@ namespace FineUIPro.Web.Transfer } } string row5 = pds.Rows[i][5].ToString(); - if (!string.IsNullOrEmpty(row4)) + if (!string.IsNullOrEmpty(row5)) { try { @@ -328,41 +328,53 @@ namespace FineUIPro.Web.Transfer List list = new List(); for (int i = 1; i < ir; i++) { - //鏌ヨ绗竴鍒楋紝娌℃煡鍒扮殑鎯呭喌涓嬩綔瀵煎叆澶勭悊 - var modelOnly = Funs.DB.Transfer_HVAC.FirstOrDefault(x => x.HVAC == pds.Rows[i][0].ToString().Trim() + if (!string.IsNullOrEmpty(pds.Rows[i][0].ToString().Trim())) + { + //鏌ヨ绗竴鍒楋紝娌℃煡鍒扮殑鎯呭喌涓嬩綔瀵煎叆澶勭悊 + var modelOnly = Funs.DB.Transfer_HVAC.FirstOrDefault(x => x.HVAC == pds.Rows[i][0].ToString().Trim() && x.ProjectId == CurrUser.LoginProjectId); - if (modelOnly == null) - { - Model.Transfer_HVAC model = new Model.Transfer_HVAC(); - model.Id = Guid.NewGuid().ToString(); - model.ProjectId = CurrUser.LoginProjectId; - model.HVAC = pds.Rows[i][0].ToString().Trim(); - model.SystemName = pds.Rows[i][1].ToString().Trim(); - model.Subsystem = pds.Rows[i][2].ToString().Trim(); - model.Test_Package = pds.Rows[i][3].ToString().Trim(); - DateTime t1, t2; - if (DateTime.TryParse(pds.Rows[i][4].ToString(), out t1) && !string.IsNullOrEmpty(pds.Rows[i][4].ToString())) - model.Test_Package_START = t1; - if (DateTime.TryParse(pds.Rows[i][5].ToString(), out t2) && !string.IsNullOrEmpty(pds.Rows[i][5].ToString())) - model.Test_Package_FINISH = t2; + if (modelOnly == null) + { + Model.Transfer_HVAC model = new Model.Transfer_HVAC(); + model.Id = Guid.NewGuid().ToString(); + model.ProjectId = CurrUser.LoginProjectId; + model.HVAC = pds.Rows[i][0].ToString().Trim(); + model.SystemName = pds.Rows[i][1].ToString().Trim(); + model.Subsystem = pds.Rows[i][2].ToString().Trim(); + model.Test_Package = pds.Rows[i][3].ToString().Trim(); + DateTime t1, t2; + if (DateTime.TryParse(pds.Rows[i][4].ToString(), out t1) && !string.IsNullOrEmpty(pds.Rows[i][4].ToString())) + model.Test_Package_START = t1; + if (DateTime.TryParse(pds.Rows[i][5].ToString(), out t2) && !string.IsNullOrEmpty(pds.Rows[i][5].ToString())) + model.Test_Package_FINISH = t2; - model.FINAL_Status = pds.Rows[i][6].ToString().Trim(); - list.Add(model); - } - else - { - //淇敼 - modelOnly.HVAC = pds.Rows[i][0].ToString().Trim(); - modelOnly.SystemName = pds.Rows[i][1].ToString().Trim(); - modelOnly.Subsystem = pds.Rows[i][2].ToString().Trim(); - modelOnly.Test_Package = pds.Rows[i][3].ToString().Trim(); - DateTime t1, t2; - if (DateTime.TryParse(pds.Rows[i][4].ToString(), out t1) && !string.IsNullOrEmpty(pds.Rows[i][4].ToString())) - modelOnly.Test_Package_START = t1; - if (DateTime.TryParse(pds.Rows[i][5].ToString(), out t2) && !string.IsNullOrEmpty(pds.Rows[i][5].ToString())) - modelOnly.Test_Package_FINISH = t2; - modelOnly.FINAL_Status = pds.Rows[i][6].ToString().Trim(); - Funs.DB.SubmitChanges(); + model.FINAL_Status = pds.Rows[i][6].ToString().Trim(); + if (model.FINAL_Status.ToLower() == "finished") + { + model.CompleteTime = DateTime.Now; + } + + list.Add(model); + } + else + { + //淇敼 + modelOnly.HVAC = pds.Rows[i][0].ToString().Trim(); + modelOnly.SystemName = pds.Rows[i][1].ToString().Trim(); + modelOnly.Subsystem = pds.Rows[i][2].ToString().Trim(); + modelOnly.Test_Package = pds.Rows[i][3].ToString().Trim(); + DateTime t1, t2; + if (DateTime.TryParse(pds.Rows[i][4].ToString(), out t1) && !string.IsNullOrEmpty(pds.Rows[i][4].ToString())) + modelOnly.Test_Package_START = t1; + if (DateTime.TryParse(pds.Rows[i][5].ToString(), out t2) && !string.IsNullOrEmpty(pds.Rows[i][5].ToString())) + modelOnly.Test_Package_FINISH = t2; + modelOnly.FINAL_Status = pds.Rows[i][6].ToString().Trim(); + if (modelOnly.FINAL_Status.ToLower() == "finished") + { + modelOnly.CompleteTime = DateTime.Now; + } + Funs.DB.SubmitChanges(); + } } } if (list.Count > 0) diff --git a/SGGL/FineUIPro.Web/Transfer/Instrumentation.aspx b/SGGL/FineUIPro.Web/Transfer/Instrumentation.aspx index ca15bdec..6ce2465d 100644 --- a/SGGL/FineUIPro.Web/Transfer/Instrumentation.aspx +++ b/SGGL/FineUIPro.Web/Transfer/Instrumentation.aspx @@ -24,6 +24,8 @@ + + diff --git a/SGGL/FineUIPro.Web/Transfer/Instrumentation.aspx.cs b/SGGL/FineUIPro.Web/Transfer/Instrumentation.aspx.cs index 00eb6ea4..2d7a5239 100644 --- a/SGGL/FineUIPro.Web/Transfer/Instrumentation.aspx.cs +++ b/SGGL/FineUIPro.Web/Transfer/Instrumentation.aspx.cs @@ -51,6 +51,12 @@ namespace FineUIPro.Web.Transfer listStr.Add(new SqlParameter("@InspectionDateZ", Funs.GetNewDateTime(txtEndTime.Text.Trim()))); } + if (!string.IsNullOrEmpty(this.txtSystem.Text.Trim())) + { + strSql += " AND SystemName like @SystemName"; + listStr.Add(new SqlParameter("@SystemName", "%" + this.txtSystem.Text.Trim() + "%")); + } + strSql += " order by INSTRUMENTATION "; SqlParameter[] parameter = listStr.ToArray(); diff --git a/SGGL/FineUIPro.Web/Transfer/Instrumentation.aspx.designer.cs b/SGGL/FineUIPro.Web/Transfer/Instrumentation.aspx.designer.cs index e7fd10a4..5272a8ec 100644 --- a/SGGL/FineUIPro.Web/Transfer/Instrumentation.aspx.designer.cs +++ b/SGGL/FineUIPro.Web/Transfer/Instrumentation.aspx.designer.cs @@ -68,6 +68,15 @@ namespace FineUIPro.Web.Transfer /// protected global::FineUIPro.TextBox txtINSTRUMENTATION; + /// + /// txtSystem 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.TextBox txtSystem; + /// /// txtStarTime 鎺т欢銆 /// diff --git a/SGGL/FineUIPro.Web/Transfer/InstrumentationDataIn.aspx.cs b/SGGL/FineUIPro.Web/Transfer/InstrumentationDataIn.aspx.cs index afe7ca2f..04a129a9 100644 --- a/SGGL/FineUIPro.Web/Transfer/InstrumentationDataIn.aspx.cs +++ b/SGGL/FineUIPro.Web/Transfer/InstrumentationDataIn.aspx.cs @@ -106,7 +106,7 @@ namespace FineUIPro.Web.Transfer oleDBConnString = "Provider=Microsoft.Jet.OLEDB.4.0;"; oleDBConnString += "Data Source="; oleDBConnString += fileName; - oleDBConnString += ";Extended Properties=Excel 8.0;"; + oleDBConnString += ";Extended Properties='Excel 8.0';"; OleDbConnection oleDBConn = null; OleDbDataAdapter oleAdMaster = null; DataTable m_tableName = new DataTable(); @@ -181,7 +181,7 @@ namespace FineUIPro.Web.Transfer } } string row5 = pds.Rows[i][5].ToString(); - if (!string.IsNullOrEmpty(row4)) + if (!string.IsNullOrEmpty(row5)) { try { @@ -329,40 +329,55 @@ namespace FineUIPro.Web.Transfer List list = new List(); for (int i = 1; i < ir; i++) { - //鏌ヨ绗竴鍒楋紝娌℃煡鍒扮殑鎯呭喌涓嬩綔瀵煎叆澶勭悊 - var modelOnly = Funs.DB.Transfer_Instrumentation.FirstOrDefault(x => x.INSTRUMENTATION == pds.Rows[i][0].ToString().Trim() - && x.ProjectId==CurrUser.LoginProjectId); - if (modelOnly == null) + if (!string.IsNullOrEmpty(pds.Rows[i][0].ToString().Trim())) { - Model.Transfer_Instrumentation model = new Model.Transfer_Instrumentation(); - model.Id = Guid.NewGuid().ToString(); - model.ProjectId = CurrUser.LoginProjectId; - model.INSTRUMENTATION = pds.Rows[i][0].ToString().Trim(); - model.SystemName = pds.Rows[i][1].ToString().Trim(); - model.Subsystem = pds.Rows[i][2].ToString().Trim(); - model.Test_Package = pds.Rows[i][3].ToString().Trim(); - DateTime t1, t2; - if (DateTime.TryParse(pds.Rows[i][4].ToString(), out t1) && !string.IsNullOrEmpty(pds.Rows[i][4].ToString())) - model.Test_Package_START = t1; - if (DateTime.TryParse(pds.Rows[i][5].ToString(), out t2) && !string.IsNullOrEmpty(pds.Rows[i][5].ToString())) - model.Test_Package_FINISH = t2; + //鏌ヨ绗竴鍒楋紝娌℃煡鍒扮殑鎯呭喌涓嬩綔瀵煎叆澶勭悊 + var modelOnly = Funs.DB.Transfer_Instrumentation.FirstOrDefault(x => x.INSTRUMENTATION == pds.Rows[i][0].ToString().Trim() + && x.ProjectId == CurrUser.LoginProjectId); + if (modelOnly == null) + { + Model.Transfer_Instrumentation model = new Model.Transfer_Instrumentation(); + model.Id = Guid.NewGuid().ToString(); + model.ProjectId = CurrUser.LoginProjectId; + model.INSTRUMENTATION = pds.Rows[i][0].ToString().Trim(); + model.SystemName = pds.Rows[i][1].ToString().Trim(); + model.Subsystem = pds.Rows[i][2].ToString().Trim(); + model.Test_Package = pds.Rows[i][3].ToString().Trim(); + DateTime t1, t2; + if (DateTime.TryParse(pds.Rows[i][4].ToString(), out t1) && !string.IsNullOrEmpty(pds.Rows[i][4].ToString())) + model.Test_Package_START = t1; + if (DateTime.TryParse(pds.Rows[i][5].ToString(), out t2) && !string.IsNullOrEmpty(pds.Rows[i][5].ToString())) + model.Test_Package_FINISH = t2; + + model.FINAL_Status = pds.Rows[i][6].ToString().Trim(); + if (model.FINAL_Status.ToLower() == "finished") + { + model.CompleteTime = DateTime.Now; + } + + list.Add(model); + } + else + { + //淇敼 + modelOnly.INSTRUMENTATION = pds.Rows[i][0].ToString().Trim(); + modelOnly.SystemName = pds.Rows[i][1].ToString().Trim(); + modelOnly.Subsystem = pds.Rows[i][2].ToString().Trim(); + modelOnly.Test_Package = pds.Rows[i][3].ToString().Trim(); + DateTime t1, t2; + if (DateTime.TryParse(pds.Rows[i][4].ToString(), out t1) && !string.IsNullOrEmpty(pds.Rows[i][4].ToString())) + modelOnly.Test_Package_START = t1; + if (DateTime.TryParse(pds.Rows[i][5].ToString(), out t2) && !string.IsNullOrEmpty(pds.Rows[i][5].ToString())) + modelOnly.Test_Package_FINISH = t2; + modelOnly.FINAL_Status = pds.Rows[i][6].ToString().Trim(); + if (modelOnly.FINAL_Status.ToLower() == "finished") + { + modelOnly.CompleteTime = DateTime.Now; + } + Funs.DB.SubmitChanges(); + } + - model.FINAL_Status = pds.Rows[i][6].ToString().Trim(); - list.Add(model); - } - else { - //淇敼 - modelOnly.INSTRUMENTATION = pds.Rows[i][0].ToString().Trim(); - modelOnly.SystemName = pds.Rows[i][1].ToString().Trim(); - modelOnly.Subsystem = pds.Rows[i][2].ToString().Trim(); - modelOnly.Test_Package = pds.Rows[i][3].ToString().Trim(); - DateTime t1, t2; - if (DateTime.TryParse(pds.Rows[i][4].ToString(), out t1) && !string.IsNullOrEmpty(pds.Rows[i][4].ToString())) - modelOnly.Test_Package_START = t1; - if (DateTime.TryParse(pds.Rows[i][5].ToString(), out t2) && !string.IsNullOrEmpty(pds.Rows[i][5].ToString())) - modelOnly.Test_Package_FINISH = t2; - modelOnly.FINAL_Status = pds.Rows[i][6].ToString().Trim(); - Funs.DB.SubmitChanges(); } } if (list.Count > 0) diff --git a/SGGL/FineUIPro.Web/Transfer/Piping.aspx b/SGGL/FineUIPro.Web/Transfer/Piping.aspx index f80d2b82..09bf59a1 100644 --- a/SGGL/FineUIPro.Web/Transfer/Piping.aspx +++ b/SGGL/FineUIPro.Web/Transfer/Piping.aspx @@ -16,12 +16,26 @@ + + + + + + + + + + + + + @@ -38,43 +52,47 @@ + HeaderTextAlign="Center" Width="170px"> + HeaderTextAlign="Center" Width="120px"> + HeaderTextAlign="Center" Width="120px"> + HeaderTextAlign="Center" Width="200px"> - + - - - + + HeaderTextAlign="Center" Width="130px"> + HeaderTextAlign="Center" Width="170px"> + + + + + + diff --git a/SGGL/FineUIPro.Web/Transfer/Piping.aspx.cs b/SGGL/FineUIPro.Web/Transfer/Piping.aspx.cs index 09da90ac..f1f900ba 100644 --- a/SGGL/FineUIPro.Web/Transfer/Piping.aspx.cs +++ b/SGGL/FineUIPro.Web/Transfer/Piping.aspx.cs @@ -30,10 +30,30 @@ namespace FineUIPro.Web.Transfer /// public void BindGrid() { - string strSql = @"select * from Transfer_ProjectSetup C + string strSql = @"select * from Transfer_Piping C where C.ProjectId = @ProjectId"; List listStr = new List(); listStr.Add(new SqlParameter("@ProjectId", this.CurrUser.LoginProjectId)); + if (!string.IsNullOrEmpty(this.txtPIPINGLINENUMBER.Text.Trim())) + { + strSql += " AND PIPINGLINENUMBER like @PIPINGLINENUMBER"; + listStr.Add(new SqlParameter("@PIPINGLINENUMBER", "%" + this.txtPIPINGLINENUMBER.Text.Trim() + "%")); + } + if (!string.IsNullOrEmpty(txtStarTime.Text.Trim())) + { + strSql += " AND TestPackageSTART >= @InspectionDateA"; + listStr.Add(new SqlParameter("@InspectionDateA", Funs.GetNewDateTime(txtStarTime.Text.Trim()))); + } + if (!string.IsNullOrEmpty(txtEndTime.Text.Trim())) + { + strSql += " AND TestPackageSTART <= @InspectionDateZ"; + listStr.Add(new SqlParameter("@InspectionDateZ", Funs.GetNewDateTime(txtEndTime.Text.Trim()))); + } + if (!string.IsNullOrEmpty(this.txtSystem.Text.Trim())) + { + strSql += " AND SYSTEM like @SYSTEM"; + listStr.Add(new SqlParameter("@SYSTEM", "%" + this.txtSystem.Text.Trim() + "%")); + } SqlParameter[] parameter = listStr.ToArray(); DataTable tb = SQLHelper.GetDataTableRunText(strSql, parameter); Grid1.RecordCount = tb.Rows.Count; @@ -154,10 +174,10 @@ namespace FineUIPro.Web.Transfer foreach (int rowIndex in Grid1.SelectedRowIndexArray) { string rowID = Grid1.DataKeys[rowIndex][0].ToString(); - var data = BLL.ProjectSetupService.GetProjectSetupById(rowID); + var data = BLL.PipingService.GetPipingById(rowID); if (data != null) { - BLL.ProjectSetupService.DeleteProjectSetup(rowID); + BLL.PipingService.DeletePiping(rowID); } } BindGrid(); @@ -174,7 +194,7 @@ namespace FineUIPro.Web.Transfer /// protected void btnImport_Click(object sender, EventArgs e) { - PageContext.RegisterStartupScript(Window2.GetShowReference(String.Format("ProjectSetupDataIn.aspx", "瀵煎叆 - "))); + PageContext.RegisterStartupScript(Window2.GetShowReference(String.Format("PipingDataIn.aspx", "瀵煎叆 - "))); } #endregion @@ -190,7 +210,7 @@ namespace FineUIPro.Web.Transfer { return; } - var buttonList = BLL.CommonService.GetAllButtonList(this.CurrUser.LoginProjectId, this.CurrUser.UserId, BLL.Const.ProjectSetupMenuId); + var buttonList = BLL.CommonService.GetAllButtonList(this.CurrUser.LoginProjectId, this.CurrUser.UserId, BLL.Const.PipingMenuId); if (buttonList.Count() > 0) { if (buttonList.Contains(BLL.Const.BtnDelete)) diff --git a/SGGL/FineUIPro.Web/Transfer/Piping.aspx.designer.cs b/SGGL/FineUIPro.Web/Transfer/Piping.aspx.designer.cs index d7ce9219..282fb9a7 100644 --- a/SGGL/FineUIPro.Web/Transfer/Piping.aspx.designer.cs +++ b/SGGL/FineUIPro.Web/Transfer/Piping.aspx.designer.cs @@ -7,11 +7,13 @@ // //------------------------------------------------------------------------------ -namespace FineUIPro.Web.Transfer { - - - public partial class Piping { - +namespace FineUIPro.Web.Transfer +{ + + + public partial class Piping + { + /// /// form1 鎺т欢銆 /// @@ -20,7 +22,7 @@ namespace FineUIPro.Web.Transfer { /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 /// protected global::System.Web.UI.HtmlControls.HtmlForm form1; - + /// /// PageManager1 鎺т欢銆 /// @@ -29,7 +31,7 @@ namespace FineUIPro.Web.Transfer { /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 /// protected global::FineUIPro.PageManager PageManager1; - + /// /// Panel1 鎺т欢銆 /// @@ -38,7 +40,7 @@ namespace FineUIPro.Web.Transfer { /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 /// protected global::FineUIPro.Panel Panel1; - + /// /// Grid1 鎺т欢銆 /// @@ -47,7 +49,7 @@ namespace FineUIPro.Web.Transfer { /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 /// protected global::FineUIPro.Grid Grid1; - + /// /// ToolSearch 鎺т欢銆 /// @@ -56,7 +58,61 @@ namespace FineUIPro.Web.Transfer { /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 /// protected global::FineUIPro.Toolbar ToolSearch; - + + /// + /// txtPIPINGLINENUMBER 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.TextBox txtPIPINGLINENUMBER; + + /// + /// txtSystem 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.TextBox txtSystem; + + /// + /// txtStarTime 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.DatePicker txtStarTime; + + /// + /// Label1 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.Label Label1; + + /// + /// txtEndTime 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.DatePicker txtEndTime; + + /// + /// btnSearch 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.Button btnSearch; + /// /// btnImport 鎺т欢銆 /// @@ -65,7 +121,7 @@ namespace FineUIPro.Web.Transfer { /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 /// protected global::FineUIPro.Button btnImport; - + /// /// lblPageIndex 鎺т欢銆 /// @@ -74,7 +130,7 @@ namespace FineUIPro.Web.Transfer { /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 /// protected global::System.Web.UI.WebControls.Label lblPageIndex; - + /// /// g1 鎺т欢銆 /// @@ -83,7 +139,7 @@ namespace FineUIPro.Web.Transfer { /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 /// protected global::FineUIPro.GroupField g1; - + /// /// g2 鎺т欢銆 /// @@ -92,7 +148,7 @@ namespace FineUIPro.Web.Transfer { /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 /// protected global::FineUIPro.GroupField g2; - + /// /// g3 鎺т欢銆 /// @@ -101,7 +157,7 @@ namespace FineUIPro.Web.Transfer { /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 /// protected global::FineUIPro.GroupField g3; - + /// /// g4 鎺т欢銆 /// @@ -110,7 +166,16 @@ namespace FineUIPro.Web.Transfer { /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 /// protected global::FineUIPro.GroupField g4; - + + /// + /// g5 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.GroupField g5; + /// /// ToolbarText1 鎺т欢銆 /// @@ -119,7 +184,7 @@ namespace FineUIPro.Web.Transfer { /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 /// protected global::FineUIPro.ToolbarText ToolbarText1; - + /// /// ddlPageSize 鎺т欢銆 /// @@ -128,7 +193,7 @@ namespace FineUIPro.Web.Transfer { /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 /// protected global::FineUIPro.DropDownList ddlPageSize; - + /// /// Window1 鎺т欢銆 /// @@ -137,7 +202,7 @@ namespace FineUIPro.Web.Transfer { /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 /// protected global::FineUIPro.Window Window1; - + /// /// Window2 鎺т欢銆 /// @@ -146,7 +211,7 @@ namespace FineUIPro.Web.Transfer { /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 /// protected global::FineUIPro.Window Window2; - + /// /// WindowAtt 鎺т欢銆 /// @@ -155,7 +220,7 @@ namespace FineUIPro.Web.Transfer { /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 /// protected global::FineUIPro.Window WindowAtt; - + /// /// Menu1 鎺т欢銆 /// @@ -164,7 +229,7 @@ namespace FineUIPro.Web.Transfer { /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 /// protected global::FineUIPro.Menu Menu1; - + /// /// btnMenuDel 鎺т欢銆 /// diff --git a/SGGL/FineUIPro.Web/Transfer/PipingDataIn.aspx b/SGGL/FineUIPro.Web/Transfer/PipingDataIn.aspx new file mode 100644 index 00000000..0fb8ea7f --- /dev/null +++ b/SGGL/FineUIPro.Web/Transfer/PipingDataIn.aspx @@ -0,0 +1,68 @@ +锘<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="PipingDataIn.aspx.cs" Inherits="FineUIPro.Web.Transfer.PipingDataIn" %> + + + + + + + + + +
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/SGGL/FineUIPro.Web/Transfer/PipingDataIn.aspx.cs b/SGGL/FineUIPro.Web/Transfer/PipingDataIn.aspx.cs new file mode 100644 index 00000000..e6b99b72 --- /dev/null +++ b/SGGL/FineUIPro.Web/Transfer/PipingDataIn.aspx.cs @@ -0,0 +1,430 @@ +锘縰sing 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 PipingDataIn : 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 璇籈xcel鎻愬彇鏁版嵁 + /// + /// 浠嶦xcel鎻愬彇鏁版嵁--銆婦ataset + /// + /// 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], 9); + hdCheckResult.Text = "1"; + } + catch (Exception exc) + { + Response.Write(exc); + //return null; + // return dt; + } + finally + { + } + } + #endregion + + #region 灏咲ataset鐨勬暟鎹鍏ユ暟鎹簱 + /// + /// 灏咲ataset鐨勬暟鎹鍏ユ暟鎹簱 + /// + /// 鏁版嵁闆 + /// 鏁版嵁闆嗚鏁 + /// + private bool AddDatasetToSQL(DataTable pds, int Cols) + { + string result = string.Empty; + int ic, ir; + ic = pds.Columns.Count; + if (ic < Cols) + { + ShowNotify("瀵煎叆Excel鏍煎紡閿欒锛丒xcel鍙湁" + ic.ToString().Trim() + "鍒", MessageBoxIcon.Warning); + return false; + } + + ir = pds.Rows.Count; + if (pds != null && ir > 0) + { + for (int i = 1; i < ir; i++) + { + string row4 = pds.Rows[i][4].ToString(); + if (!string.IsNullOrEmpty(row4)) + { + try + { + DateTime date = Convert.ToDateTime(row4.Trim()); + } + catch (Exception) + { + result += (i + 3).ToString() + "," + "Test Package START" + "," + "[" + row4 + "]閿欒锛佷笉鏄棩鏈熸牸寮忥紒" + "|"; + } + } + string row5 = pds.Rows[i][5].ToString(); + if (!string.IsNullOrEmpty(row4)) + { + try + { + DateTime date = Convert.ToDateTime(row5.Trim()); + } + catch (Exception) + { + result += (i + 3).ToString() + "," + "Test Package FINISH" + "," + "[" + row5 + "]閿欒锛佷笉鏄棩鏈熸牸寮忥紒" + "|"; + } + } + } + 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("璇峰厛灏嗛敊璇暟鎹慨姝o紝鍐嶉噸鏂板鍏ユ彁浜わ紒", MessageBoxIcon.Warning); + } + } + else + { + ShowNotify("璇峰厛瀹℃牳瑕佸鍏ョ殑鏂囦欢锛", MessageBoxIcon.Warning); + } + } + + #region Excel鎻愬彇鏁版嵁 + /// + /// 浠嶦xcel鎻愬彇鏁版嵁--銆婦ataset + /// + /// 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], 9); + } + catch (Exception ex) + { + throw ex; + } + } + #endregion + + #region 灏咲ataset鐨勬暟鎹鍏ユ暟鎹簱 + /// + /// 灏咲ataset鐨勬暟鎹鍏ユ暟鎹簱 + /// + /// 鏁版嵁闆 + /// 鏁版嵁闆嗗垪鏁 + /// + private bool AddDatasetToSQL2(DataTable pds, int Cols) + { + int ic, ir; + ic = pds.Columns.Count; + if (ic < Cols) + { + ShowNotify("瀵煎叆Excel鏍煎紡閿欒锛丒xcel鍙湁" + ic.ToString().Trim() + "鍒", MessageBoxIcon.Warning); + } + string result = string.Empty; + ir = pds.Rows.Count; + if (pds != null && ir > 0) + { + List list = new List(); + for (int i = 1; i < ir; i++) + { + //鏌ヨ绗竴鍒楋紝娌℃煡鍒扮殑鎯呭喌涓嬩綔瀵煎叆澶勭悊 + var modelOnly = Funs.DB.Transfer_Piping.FirstOrDefault(x => x.PIPINGLINENUMBER == pds.Rows[i][0].ToString().Trim() + && x.ProjectId == CurrUser.LoginProjectId); + if (modelOnly == null) + { + Model.Transfer_Piping model = new Model.Transfer_Piping(); + model.Id = Guid.NewGuid().ToString(); + model.ProjectId = CurrUser.LoginProjectId; + model.PIPINGLINENUMBER = pds.Rows[i][0].ToString().Trim(); + model.SYSTEM = pds.Rows[i][1].ToString().Trim(); + model.Subsystem = pds.Rows[i][2].ToString().Trim(); + model.TestPackage = pds.Rows[i][3].ToString().Trim(); + DateTime t1, t2; + if (DateTime.TryParse(pds.Rows[i][4].ToString(), out t1) && !string.IsNullOrEmpty(pds.Rows[i][4].ToString())) + model.TestPackageSTART = t1; + if (DateTime.TryParse(pds.Rows[i][5].ToString(), out t2) && !string.IsNullOrEmpty(pds.Rows[i][5].ToString())) + model.TestPackageFINISH = t2; + + model.FINALStatus = pds.Rows[i][6].ToString().Trim(); + if (model.FINALStatus.ToLower()== "finished") + { + model.CompleteTime = DateTime.Now; + } + + model.PreTestFINISHED = pds.Rows[i][7].ToString().Trim(); + model.FinalTestFINISHED = pds.Rows[i][8].ToString().Trim(); + list.Add(model); + } + else + { + //淇敼 + modelOnly.PIPINGLINENUMBER = pds.Rows[i][0].ToString().Trim(); + modelOnly.SYSTEM = pds.Rows[i][1].ToString().Trim(); + modelOnly.Subsystem = pds.Rows[i][2].ToString().Trim(); + modelOnly.TestPackage = pds.Rows[i][3].ToString().Trim(); + DateTime t1, t2; + if (DateTime.TryParse(pds.Rows[i][4].ToString(), out t1) && !string.IsNullOrEmpty(pds.Rows[i][4].ToString())) + modelOnly.TestPackageSTART = t1; + if (DateTime.TryParse(pds.Rows[i][5].ToString(), out t2) && !string.IsNullOrEmpty(pds.Rows[i][5].ToString())) + modelOnly.TestPackageFINISH = t2; + modelOnly.FINALStatus = pds.Rows[i][6].ToString().Trim(); + if (modelOnly.FINALStatus.ToLower() == "finished") + { + modelOnly.CompleteTime = DateTime.Now; + } + modelOnly.PreTestFINISHED = pds.Rows[i][7].ToString().Trim(); + modelOnly.FinalTestFINISHED = pds.Rows[i][8].ToString().Trim(); + Funs.DB.SubmitChanges(); + } + } + if (list.Count > 0) + { + Funs.DB.Transfer_Piping.InsertAllOnSubmit(list); + Funs.DB.SubmitChanges(); + } + } + 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 + "File\\Excel\\DataIn\\Piping瀵煎叆妯℃澘.xls"; + string filePath = "File\\Excel\\DataIn\\Piping瀵煎叆妯℃澘.xls"; + 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/PipingDataIn.aspx.designer.cs b/SGGL/FineUIPro.Web/Transfer/PipingDataIn.aspx.designer.cs new file mode 100644 index 00000000..fdc5b39c --- /dev/null +++ b/SGGL/FineUIPro.Web/Transfer/PipingDataIn.aspx.designer.cs @@ -0,0 +1,123 @@ +锘//------------------------------------------------------------------------------ +// <鑷姩鐢熸垚> +// 姝や唬鐮佺敱宸ュ叿鐢熸垚銆 +// +// 瀵规鏂囦欢鐨勬洿鏀瑰彲鑳藉鑷翠笉姝g‘鐨勮涓猴紝濡傛灉 +// 閲嶆柊鐢熸垚浠g爜锛屽垯鎵鍋氭洿鏀瑰皢涓㈠け銆 +// +//------------------------------------------------------------------------------ + +namespace FineUIPro.Web.Transfer { + + + public partial class PipingDataIn { + + /// + /// form1 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::System.Web.UI.HtmlControls.HtmlForm form1; + + /// + /// PageManager1 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.PageManager PageManager1; + + /// + /// SimpleForm1 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.Form SimpleForm1; + + /// + /// Toolbar2 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.Toolbar Toolbar2; + + /// + /// hdFileName 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.HiddenField hdFileName; + + /// + /// btnAudit 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.Button btnAudit; + + /// + /// btnImport 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.Button btnImport; + + /// + /// btnDownLoad 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.Button btnDownLoad; + + /// + /// hdCheckResult 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.HiddenField hdCheckResult; + + /// + /// fuAttachUrl 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.FileUpload fuAttachUrl; + + /// + /// gvErrorInfo 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.Grid gvErrorInfo; + + /// + /// lblPageIndex 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::System.Web.UI.WebControls.Label lblPageIndex; + } +} diff --git a/SGGL/FineUIPro.Web/Transfer/Plumbing.aspx b/SGGL/FineUIPro.Web/Transfer/Plumbing.aspx index 5a7dcf8c..08a9ed31 100644 --- a/SGGL/FineUIPro.Web/Transfer/Plumbing.aspx +++ b/SGGL/FineUIPro.Web/Transfer/Plumbing.aspx @@ -24,6 +24,8 @@ + + diff --git a/SGGL/FineUIPro.Web/Transfer/Plumbing.aspx.cs b/SGGL/FineUIPro.Web/Transfer/Plumbing.aspx.cs index f1873d04..cd19d616 100644 --- a/SGGL/FineUIPro.Web/Transfer/Plumbing.aspx.cs +++ b/SGGL/FineUIPro.Web/Transfer/Plumbing.aspx.cs @@ -51,6 +51,11 @@ namespace FineUIPro.Web.Transfer strSql += " AND Test_Package_START <= @InspectionDateZ"; listStr.Add(new SqlParameter("@InspectionDateZ", Funs.GetNewDateTime(txtEndTime.Text.Trim()))); } + if (!string.IsNullOrEmpty(this.txtSystem.Text.Trim())) + { + strSql += " AND SystemName like @SystemName"; + listStr.Add(new SqlParameter("@SystemName", "%" + this.txtSystem.Text.Trim() + "%")); + } strSql += " order by Plumbing "; SqlParameter[] parameter = listStr.ToArray(); diff --git a/SGGL/FineUIPro.Web/Transfer/Plumbing.aspx.designer.cs b/SGGL/FineUIPro.Web/Transfer/Plumbing.aspx.designer.cs index d79c6e0c..ae747e36 100644 --- a/SGGL/FineUIPro.Web/Transfer/Plumbing.aspx.designer.cs +++ b/SGGL/FineUIPro.Web/Transfer/Plumbing.aspx.designer.cs @@ -68,6 +68,15 @@ namespace FineUIPro.Web.Transfer /// protected global::FineUIPro.TextBox txtPlumbing; + /// + /// txtSystem 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.TextBox txtSystem; + /// /// txtStarTime 鎺т欢銆 /// diff --git a/SGGL/FineUIPro.Web/Transfer/PlumbingDataIn.aspx.cs b/SGGL/FineUIPro.Web/Transfer/PlumbingDataIn.aspx.cs index 1a358706..eac8c964 100644 --- a/SGGL/FineUIPro.Web/Transfer/PlumbingDataIn.aspx.cs +++ b/SGGL/FineUIPro.Web/Transfer/PlumbingDataIn.aspx.cs @@ -181,7 +181,7 @@ namespace FineUIPro.Web.Transfer } } string row5 = pds.Rows[i][5].ToString(); - if (!string.IsNullOrEmpty(row4)) + if (!string.IsNullOrEmpty(row5)) { try { @@ -329,41 +329,52 @@ namespace FineUIPro.Web.Transfer List list = new List(); for (int i = 1; i < ir; i++) { - //鏌ヨ绗竴鍒楋紝娌℃煡鍒扮殑鎯呭喌涓嬩綔瀵煎叆澶勭悊 - var modelOnly = Funs.DB.Transfer_Plumbing.FirstOrDefault(x => x.Plumbing == pds.Rows[i][0].ToString().Trim() + if (!string.IsNullOrEmpty(pds.Rows[i][0].ToString().Trim())) + { + //鏌ヨ绗竴鍒楋紝娌℃煡鍒扮殑鎯呭喌涓嬩綔瀵煎叆澶勭悊 + var modelOnly = Funs.DB.Transfer_Plumbing.FirstOrDefault(x => x.Plumbing == pds.Rows[i][0].ToString().Trim() && x.ProjectId == CurrUser.LoginProjectId); - if (modelOnly == null) - { - Model.Transfer_Plumbing model = new Model.Transfer_Plumbing(); - model.Id = Guid.NewGuid().ToString(); - model.ProjectId = CurrUser.LoginProjectId; - model.Plumbing = pds.Rows[i][0].ToString().Trim(); - model.SystemName = pds.Rows[i][1].ToString().Trim(); - model.Subsystem = pds.Rows[i][2].ToString().Trim(); - model.Test_Package = pds.Rows[i][3].ToString().Trim(); - DateTime t1, t2; - if (DateTime.TryParse(pds.Rows[i][4].ToString(), out t1) && !string.IsNullOrEmpty(pds.Rows[i][4].ToString())) - model.Test_Package_START = t1; - if (DateTime.TryParse(pds.Rows[i][5].ToString(), out t2) && !string.IsNullOrEmpty(pds.Rows[i][5].ToString())) - model.Test_Package_FINISH = t2; + if (modelOnly == null) + { + Model.Transfer_Plumbing model = new Model.Transfer_Plumbing(); + model.Id = Guid.NewGuid().ToString(); + model.ProjectId = CurrUser.LoginProjectId; + model.Plumbing = pds.Rows[i][0].ToString().Trim(); + model.SystemName = pds.Rows[i][1].ToString().Trim(); + model.Subsystem = pds.Rows[i][2].ToString().Trim(); + model.Test_Package = pds.Rows[i][3].ToString().Trim(); + DateTime t1, t2; + if (DateTime.TryParse(pds.Rows[i][4].ToString(), out t1) && !string.IsNullOrEmpty(pds.Rows[i][4].ToString())) + model.Test_Package_START = t1; + if (DateTime.TryParse(pds.Rows[i][5].ToString(), out t2) && !string.IsNullOrEmpty(pds.Rows[i][5].ToString())) + model.Test_Package_FINISH = t2; - model.FINAL_Status = pds.Rows[i][6].ToString().Trim(); - list.Add(model); - } - else - { - //淇敼 - modelOnly.Plumbing = pds.Rows[i][0].ToString().Trim(); - modelOnly.SystemName = pds.Rows[i][1].ToString().Trim(); - modelOnly.Subsystem = pds.Rows[i][2].ToString().Trim(); - modelOnly.Test_Package = pds.Rows[i][3].ToString().Trim(); - DateTime t1, t2; - if (DateTime.TryParse(pds.Rows[i][4].ToString(), out t1) && !string.IsNullOrEmpty(pds.Rows[i][4].ToString())) - modelOnly.Test_Package_START = t1; - if (DateTime.TryParse(pds.Rows[i][5].ToString(), out t2) && !string.IsNullOrEmpty(pds.Rows[i][5].ToString())) - modelOnly.Test_Package_FINISH = t2; - modelOnly.FINAL_Status = pds.Rows[i][6].ToString().Trim(); - Funs.DB.SubmitChanges(); + model.FINAL_Status = pds.Rows[i][6].ToString().Trim(); + if (model.FINAL_Status.ToLower() == "finished") + { + model.CompleteTime = DateTime.Now; + } + list.Add(model); + } + else + { + //淇敼 + modelOnly.Plumbing = pds.Rows[i][0].ToString().Trim(); + modelOnly.SystemName = pds.Rows[i][1].ToString().Trim(); + modelOnly.Subsystem = pds.Rows[i][2].ToString().Trim(); + modelOnly.Test_Package = pds.Rows[i][3].ToString().Trim(); + DateTime t1, t2; + if (DateTime.TryParse(pds.Rows[i][4].ToString(), out t1) && !string.IsNullOrEmpty(pds.Rows[i][4].ToString())) + modelOnly.Test_Package_START = t1; + if (DateTime.TryParse(pds.Rows[i][5].ToString(), out t2) && !string.IsNullOrEmpty(pds.Rows[i][5].ToString())) + modelOnly.Test_Package_FINISH = t2; + modelOnly.FINAL_Status = pds.Rows[i][6].ToString().Trim(); + if (modelOnly.FINAL_Status.ToLower() == "finished") + { + modelOnly.CompleteTime = DateTime.Now; + } + Funs.DB.SubmitChanges(); + } } } if (list.Count > 0) diff --git a/SGGL/FineUIPro.Web/Transfer/ProjectSetup.aspx b/SGGL/FineUIPro.Web/Transfer/ProjectSetup.aspx index 860fb31f..90c631d0 100644 --- a/SGGL/FineUIPro.Web/Transfer/ProjectSetup.aspx +++ b/SGGL/FineUIPro.Web/Transfer/ProjectSetup.aspx @@ -15,8 +15,8 @@ diff --git a/SGGL/FineUIPro.Web/Transfer/ProjectSetup.aspx.cs b/SGGL/FineUIPro.Web/Transfer/ProjectSetup.aspx.cs index 61c8f241..8cb60289 100644 --- a/SGGL/FineUIPro.Web/Transfer/ProjectSetup.aspx.cs +++ b/SGGL/FineUIPro.Web/Transfer/ProjectSetup.aspx.cs @@ -30,7 +30,7 @@ namespace FineUIPro.Web.Transfer /// public void BindGrid() { - string strSql = @"select * from Transfer_ProjectSetup C + string strSql = @"select *,isnull(CAST(SN as int),0) as SortIndex from Transfer_ProjectSetup C where C.ProjectId = @ProjectId"; List listStr = new List(); listStr.Add(new SqlParameter("@ProjectId", this.CurrUser.LoginProjectId)); diff --git a/SGGL/FineUIPro.Web/Transfer/PunchlistFrom.aspx b/SGGL/FineUIPro.Web/Transfer/PunchlistFrom.aspx index 551cf92d..43d86694 100644 --- a/SGGL/FineUIPro.Web/Transfer/PunchlistFrom.aspx +++ b/SGGL/FineUIPro.Web/Transfer/PunchlistFrom.aspx @@ -22,10 +22,11 @@ - - - + + + + @@ -43,6 +44,14 @@
+ + + + + + + +
@@ -50,33 +59,33 @@ - + - + - + - + - + - + - + - - + - + - + - + diff --git a/SGGL/FineUIPro.Web/Transfer/PunchlistFrom.aspx.cs b/SGGL/FineUIPro.Web/Transfer/PunchlistFrom.aspx.cs index 81f69bd4..111e8a0c 100644 --- a/SGGL/FineUIPro.Web/Transfer/PunchlistFrom.aspx.cs +++ b/SGGL/FineUIPro.Web/Transfer/PunchlistFrom.aspx.cs @@ -40,6 +40,16 @@ namespace FineUIPro.Web.Transfer strSql += " AND Punch_No like @Punch_No"; listStr.Add(new SqlParameter("@Punch_No", "%" + this.txtPunch_No.Text.Trim() + "%")); } + if (!string.IsNullOrEmpty(this.txtSYSTEM.Text.Trim())) + { + strSql += " AND SystemName like @SystemName"; + listStr.Add(new SqlParameter("@SystemName", "%" + this.txtSYSTEM.Text.Trim() + "%")); + } + if (!string.IsNullOrEmpty(this.txtSUBSYSTEM.Text.Trim())) + { + strSql += " AND Subsystem like @Subsystem"; + listStr.Add(new SqlParameter("@Subsystem", "%" + this.txtSUBSYSTEM.Text.Trim() + "%")); + } if (!string.IsNullOrEmpty(txtStarTime.Text.Trim())) { strSql += " AND PUNCH_ITEM_FINISH_DATE >= @InspectionDateA"; @@ -50,6 +60,26 @@ namespace FineUIPro.Web.Transfer strSql += " AND PUNCH_ITEM_FINISH_DATE <= @InspectionDateZ"; listStr.Add(new SqlParameter("@InspectionDateZ", Funs.GetNewDateTime(txtEndTime.Text.Trim()))); } + if (!string.IsNullOrEmpty(this.txtTestPackage.Text.Trim())) + { + strSql += " AND Test_Package like @Test_Package"; + listStr.Add(new SqlParameter("@Test_Package", "%" + this.txtTestPackage.Text.Trim() + "%")); + } + if (!string.IsNullOrEmpty(this.txtDiscipline.Text.Trim())) + { + strSql += " AND Discipline like @Discipline"; + listStr.Add(new SqlParameter("@Discipline", "%" + this.txtDiscipline.Text.Trim() + "%")); + } + if (!string.IsNullOrEmpty(this.txtIdentified.Text.Trim())) + { + strSql += " AND Identified like @Identified"; + listStr.Add(new SqlParameter("@Identified", "%" + this.txtIdentified.Text.Trim() + "%")); + } + if (!string.IsNullOrEmpty(this.txtCategory.Text.Trim())) + { + strSql += " AND Category like @Category"; + listStr.Add(new SqlParameter("@Category", "%" + this.txtCategory.Text.Trim() + "%")); + } strSql += " order by Punch_No "; SqlParameter[] parameter = listStr.ToArray(); DataTable tb = SQLHelper.GetDataTableRunText(strSql, parameter); diff --git a/SGGL/FineUIPro.Web/Transfer/PunchlistFrom.aspx.designer.cs b/SGGL/FineUIPro.Web/Transfer/PunchlistFrom.aspx.designer.cs index ac2dc2ef..80f55cb7 100644 --- a/SGGL/FineUIPro.Web/Transfer/PunchlistFrom.aspx.designer.cs +++ b/SGGL/FineUIPro.Web/Transfer/PunchlistFrom.aspx.designer.cs @@ -7,13 +7,11 @@ // //------------------------------------------------------------------------------ -namespace FineUIPro.Web.Transfer -{ - - - public partial class PunchlistFrom - { - +namespace FineUIPro.Web.Transfer { + + + public partial class PunchlistFrom { + /// /// form1 鎺т欢銆 /// @@ -22,7 +20,7 @@ namespace FineUIPro.Web.Transfer /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 /// protected global::System.Web.UI.HtmlControls.HtmlForm form1; - + /// /// PageManager1 鎺т欢銆 /// @@ -31,7 +29,7 @@ namespace FineUIPro.Web.Transfer /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 /// protected global::FineUIPro.PageManager PageManager1; - + /// /// Panel1 鎺т欢銆 /// @@ -40,7 +38,7 @@ namespace FineUIPro.Web.Transfer /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 /// protected global::FineUIPro.Panel Panel1; - + /// /// Grid1 鎺т欢銆 /// @@ -49,7 +47,7 @@ namespace FineUIPro.Web.Transfer /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 /// protected global::FineUIPro.Grid Grid1; - + /// /// ToolSearch 鎺т欢銆 /// @@ -58,7 +56,7 @@ namespace FineUIPro.Web.Transfer /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 /// protected global::FineUIPro.Toolbar ToolSearch; - + /// /// txtPunch_No 鎺т欢銆 /// @@ -67,7 +65,25 @@ namespace FineUIPro.Web.Transfer /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 /// protected global::FineUIPro.TextBox txtPunch_No; - + + /// + /// txtSYSTEM 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.TextBox txtSYSTEM; + + /// + /// txtSUBSYSTEM 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.TextBox txtSUBSYSTEM; + /// /// txtStarTime 鎺т欢銆 /// @@ -76,7 +92,7 @@ namespace FineUIPro.Web.Transfer /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 /// protected global::FineUIPro.DatePicker txtStarTime; - + /// /// Label1 鎺т欢銆 /// @@ -85,7 +101,7 @@ namespace FineUIPro.Web.Transfer /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 /// protected global::FineUIPro.Label Label1; - + /// /// txtEndTime 鎺т欢銆 /// @@ -94,7 +110,7 @@ namespace FineUIPro.Web.Transfer /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 /// protected global::FineUIPro.DatePicker txtEndTime; - + /// /// btnSearch 鎺т欢銆 /// @@ -103,7 +119,7 @@ namespace FineUIPro.Web.Transfer /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 /// protected global::FineUIPro.Button btnSearch; - + /// /// btnImport 鎺т欢銆 /// @@ -112,7 +128,52 @@ namespace FineUIPro.Web.Transfer /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 /// protected global::FineUIPro.Button btnImport; - + + /// + /// Toolbar1 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.Toolbar Toolbar1; + + /// + /// txtTest Package 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.TextBox txtTestPackage; + + /// + /// txtDiscipline 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.TextBox txtDiscipline; + + /// + /// txtIdentified 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.TextBox txtIdentified; + + /// + /// txtCategory 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.TextBox txtCategory; + /// /// ToolbarText1 鎺т欢銆 /// @@ -121,7 +182,7 @@ namespace FineUIPro.Web.Transfer /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 /// protected global::FineUIPro.ToolbarText ToolbarText1; - + /// /// ddlPageSize 鎺т欢銆 /// @@ -130,7 +191,7 @@ namespace FineUIPro.Web.Transfer /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 /// protected global::FineUIPro.DropDownList ddlPageSize; - + /// /// Window2 鎺т欢銆 /// @@ -139,7 +200,7 @@ namespace FineUIPro.Web.Transfer /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 /// protected global::FineUIPro.Window Window2; - + /// /// Menu1 鎺т欢銆 /// @@ -148,7 +209,7 @@ namespace FineUIPro.Web.Transfer /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 /// protected global::FineUIPro.Menu Menu1; - + /// /// btnMenuDel 鎺т欢銆 /// diff --git a/SGGL/FineUIPro.Web/Transfer/PunchlistFromDataIn.aspx.cs b/SGGL/FineUIPro.Web/Transfer/PunchlistFromDataIn.aspx.cs index 6922c30a..39924624 100644 --- a/SGGL/FineUIPro.Web/Transfer/PunchlistFromDataIn.aspx.cs +++ b/SGGL/FineUIPro.Web/Transfer/PunchlistFromDataIn.aspx.cs @@ -317,57 +317,60 @@ namespace FineUIPro.Web.Transfer List list = new List(); for (int i = 1; i < ir; i++) { - //鏌ヨ绗竴鍒楋紝娌℃煡鍒扮殑鎯呭喌涓嬩綔瀵煎叆澶勭悊 - var modelOnly = Funs.DB.Transfer_PunchlistFrom.FirstOrDefault(x => x.Punch_No == pds.Rows[i][0].ToString().Trim() + if (!string.IsNullOrEmpty(pds.Rows[i][1].ToString().Trim())) + { + //鏌ヨ绗竴鍒楋紝娌℃煡鍒扮殑鎯呭喌涓嬩綔瀵煎叆澶勭悊 + var modelOnly = Funs.DB.Transfer_PunchlistFrom.FirstOrDefault(x => x.Punch_No == pds.Rows[i][1].ToString().Trim() && x.ProjectId == CurrUser.LoginProjectId); - if (modelOnly == null) - { - Model.Transfer_PunchlistFrom model = new Model.Transfer_PunchlistFrom(); + if (modelOnly == null) + { + Model.Transfer_PunchlistFrom model = new Model.Transfer_PunchlistFrom(); - model.Id = Guid.NewGuid().ToString(); - model.ProjectId = CurrUser.LoginProjectId; + model.Id = Guid.NewGuid().ToString(); + model.ProjectId = CurrUser.LoginProjectId; - model.Item_No = pds.Rows[i][0].ToString().Trim(); - model.Punch_No = pds.Rows[i][1].ToString().Trim(); - model.SystemName = pds.Rows[i][2].ToString().Trim(); - model.Subsystem = pds.Rows[i][3].ToString().Trim(); + model.Item_No = pds.Rows[i][0].ToString().Trim(); + model.Punch_No = pds.Rows[i][1].ToString().Trim(); + model.SystemName = pds.Rows[i][2].ToString().Trim(); + model.Subsystem = pds.Rows[i][3].ToString().Trim(); - model.Test_Package = pds.Rows[i][4].ToString().Trim(); - model.Discipline = pds.Rows[i][5].ToString().Trim(); - model.DESCRIPTION = pds.Rows[i][6].ToString().Trim(); - model.Identified = pds.Rows[i][7].ToString().Trim(); - model.Category = pds.Rows[i][8].ToString().Trim(); - DateTime t1; - if (DateTime.TryParse(pds.Rows[i][9].ToString(), out t1) && !string.IsNullOrEmpty(pds.Rows[i][9].ToString())) - model.PUNCH_ITEM_FINISH_DATE = t1; - + model.Test_Package = pds.Rows[i][4].ToString().Trim(); + model.Discipline = pds.Rows[i][5].ToString().Trim(); + model.DESCRIPTION = pds.Rows[i][6].ToString().Trim(); + model.Identified = pds.Rows[i][7].ToString().Trim(); + model.Category = pds.Rows[i][8].ToString().Trim(); + DateTime t1; + if (DateTime.TryParse(pds.Rows[i][9].ToString(), out t1) && !string.IsNullOrEmpty(pds.Rows[i][9].ToString())) + model.PUNCH_ITEM_FINISH_DATE = t1; - model.Action_By = pds.Rows[i][10].ToString().Trim(); - model.Required_By = pds.Rows[i][11].ToString().Trim(); - model.PUNCH_ITEM_STATUS = pds.Rows[i][12].ToString().Trim(); - model.Comments = pds.Rows[i][13].ToString().Trim(); - list.Add(model); - } - else - { - //淇敼 - modelOnly.Item_No = pds.Rows[i][0].ToString().Trim(); - modelOnly.Punch_No = pds.Rows[i][1].ToString().Trim(); - modelOnly.SystemName = pds.Rows[i][2].ToString().Trim(); - modelOnly.Subsystem = pds.Rows[i][3].ToString().Trim(); - modelOnly.Test_Package = pds.Rows[i][4].ToString().Trim(); - modelOnly.Discipline = pds.Rows[i][5].ToString().Trim(); - modelOnly.DESCRIPTION = pds.Rows[i][6].ToString().Trim(); - modelOnly.Identified = pds.Rows[i][7].ToString().Trim(); - modelOnly.Category = pds.Rows[i][8].ToString().Trim(); - DateTime t1; - if (DateTime.TryParse(pds.Rows[i][9].ToString(), out t1) && !string.IsNullOrEmpty(pds.Rows[i][9].ToString())) - modelOnly.PUNCH_ITEM_FINISH_DATE = t1; - modelOnly.Action_By = pds.Rows[i][10].ToString().Trim(); - modelOnly.Required_By = pds.Rows[i][11].ToString().Trim(); - modelOnly.PUNCH_ITEM_STATUS = pds.Rows[i][12].ToString().Trim(); - modelOnly.Comments = pds.Rows[i][13].ToString().Trim(); - Funs.DB.SubmitChanges(); + + model.Action_By = pds.Rows[i][10].ToString().Trim(); + model.Required_By = pds.Rows[i][11].ToString().Trim(); + model.PUNCH_ITEM_STATUS = pds.Rows[i][12].ToString().Trim(); + model.Comments = pds.Rows[i][13].ToString().Trim(); + list.Add(model); + } + else + { + //淇敼 + modelOnly.Item_No = pds.Rows[i][0].ToString().Trim(); + modelOnly.Punch_No = pds.Rows[i][1].ToString().Trim(); + modelOnly.SystemName = pds.Rows[i][2].ToString().Trim(); + modelOnly.Subsystem = pds.Rows[i][3].ToString().Trim(); + modelOnly.Test_Package = pds.Rows[i][4].ToString().Trim(); + modelOnly.Discipline = pds.Rows[i][5].ToString().Trim(); + modelOnly.DESCRIPTION = pds.Rows[i][6].ToString().Trim(); + modelOnly.Identified = pds.Rows[i][7].ToString().Trim(); + modelOnly.Category = pds.Rows[i][8].ToString().Trim(); + DateTime t1; + if (DateTime.TryParse(pds.Rows[i][9].ToString(), out t1) && !string.IsNullOrEmpty(pds.Rows[i][9].ToString())) + modelOnly.PUNCH_ITEM_FINISH_DATE = t1; + modelOnly.Action_By = pds.Rows[i][10].ToString().Trim(); + modelOnly.Required_By = pds.Rows[i][11].ToString().Trim(); + modelOnly.PUNCH_ITEM_STATUS = pds.Rows[i][12].ToString().Trim(); + modelOnly.Comments = pds.Rows[i][13].ToString().Trim(); + Funs.DB.SubmitChanges(); + } } } if (list.Count > 0) diff --git a/SGGL/FineUIPro.Web/Transfer/RotatingEquipment.aspx b/SGGL/FineUIPro.Web/Transfer/RotatingEquipment.aspx new file mode 100644 index 00000000..661b0b79 --- /dev/null +++ b/SGGL/FineUIPro.Web/Transfer/RotatingEquipment.aspx @@ -0,0 +1,137 @@ +锘<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="RotatingEquipment.aspx.cs" Inherits="FineUIPro.Web.Transfer.RotatingEquipment" %> + + + + + + + + + +
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/SGGL/FineUIPro.Web/Transfer/RotatingEquipment.aspx.cs b/SGGL/FineUIPro.Web/Transfer/RotatingEquipment.aspx.cs new file mode 100644 index 00000000..62633b6e --- /dev/null +++ b/SGGL/FineUIPro.Web/Transfer/RotatingEquipment.aspx.cs @@ -0,0 +1,228 @@ +锘縰sing 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 RotatingEquipment : PageBase + { + #region 鍔犺浇 + /// + /// 鍔犺浇椤甸潰 + /// + /// + /// + protected void Page_Load(object sender, EventArgs e) + { + if (!IsPostBack) + { + GetButtonPower(); + BindGrid(); + } + } + + /// + /// 鏁版嵁缁戝畾 + /// + public void BindGrid() + { + string strSql = @"select * from Transfer_RotatingEquipment C + where C.ProjectId = @ProjectId"; + List listStr = new List(); + listStr.Add(new SqlParameter("@ProjectId", this.CurrUser.LoginProjectId)); + if (!string.IsNullOrEmpty(this.txtRotatingEquipment.Text.Trim())) + { + strSql += " AND RotatingEquipment like @RotatingEquipment"; + listStr.Add(new SqlParameter("@RotatingEquipment", "%" + this.txtRotatingEquipment.Text.Trim() + "%")); + } + if (!string.IsNullOrEmpty(txtStarTime.Text.Trim())) + { + strSql += " AND TestPackageSTART >= @InspectionDateA"; + listStr.Add(new SqlParameter("@InspectionDateA", Funs.GetNewDateTime(txtStarTime.Text.Trim()))); + } + if (!string.IsNullOrEmpty(txtEndTime.Text.Trim())) + { + strSql += " AND TestPackageSTART <= @InspectionDateZ"; + listStr.Add(new SqlParameter("@InspectionDateZ", Funs.GetNewDateTime(txtEndTime.Text.Trim()))); + } + if (!string.IsNullOrEmpty(this.txtSystem.Text.Trim())) + { + strSql += " AND SYSTEM like @SYSTEM"; + listStr.Add(new SqlParameter("@SYSTEM", "%" + this.txtSystem.Text.Trim() + "%")); + } + 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.RotatingEquipmentService.GetRotatingEquipmentById(rowID); + if (data != null) + { + BLL.RotatingEquipmentService.DeleteRotatingEquipment(rowID); + } + } + BindGrid(); + ShowNotify("鍒犻櫎鏁版嵁鎴愬姛!", MessageBoxIcon.Success); + } + } + #endregion + + #region 瀵煎叆 + /// + /// 瀵煎叆鎸夐挳 + /// + /// + /// + protected void btnImport_Click(object sender, EventArgs e) + { + PageContext.RegisterStartupScript(Window2.GetShowReference(String.Format("RotatingEquipmentDataIn.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.RotatingEquipmentMenuId); + 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/RotatingEquipment.aspx.designer.cs b/SGGL/FineUIPro.Web/Transfer/RotatingEquipment.aspx.designer.cs new file mode 100644 index 00000000..a623f720 --- /dev/null +++ b/SGGL/FineUIPro.Web/Transfer/RotatingEquipment.aspx.designer.cs @@ -0,0 +1,233 @@ +锘//------------------------------------------------------------------------------ +// <鑷姩鐢熸垚> +// 姝や唬鐮佺敱宸ュ叿鐢熸垚銆 +// +// 瀵规鏂囦欢鐨勬洿鏀瑰彲鑳藉鑷翠笉姝g‘鐨勮涓猴紝濡傛灉 +// 閲嶆柊鐢熸垚浠g爜锛屽垯鎵鍋氭洿鏀瑰皢涓㈠け銆 +// +//------------------------------------------------------------------------------ + +namespace FineUIPro.Web.Transfer +{ + + + public partial class RotatingEquipment + { + + /// + /// form1 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::System.Web.UI.HtmlControls.HtmlForm form1; + + /// + /// PageManager1 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.PageManager PageManager1; + + /// + /// Panel1 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.Panel Panel1; + + /// + /// Grid1 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.Grid Grid1; + + /// + /// ToolSearch 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.Toolbar ToolSearch; + + /// + /// txtRotatingEquipment 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.TextBox txtRotatingEquipment; + + /// + /// txtSystem 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.TextBox txtSystem; + + /// + /// txtStarTime 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.DatePicker txtStarTime; + + /// + /// Label1 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.Label Label1; + + /// + /// txtEndTime 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.DatePicker txtEndTime; + + /// + /// btnSearch 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.Button btnSearch; + + /// + /// btnImport 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.Button btnImport; + + /// + /// lblPageIndex 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::System.Web.UI.WebControls.Label lblPageIndex; + + /// + /// g1 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.GroupField g1; + + /// + /// g2 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.GroupField g2; + + /// + /// g3 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.GroupField g3; + + /// + /// g5 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.GroupField g5; + + /// + /// ToolbarText1 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.ToolbarText ToolbarText1; + + /// + /// ddlPageSize 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.DropDownList ddlPageSize; + + /// + /// Window1 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.Window Window1; + + /// + /// Window2 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.Window Window2; + + /// + /// WindowAtt 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.Window WindowAtt; + + /// + /// Menu1 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.Menu Menu1; + + /// + /// btnMenuDel 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.MenuButton btnMenuDel; + } +} diff --git a/SGGL/FineUIPro.Web/Transfer/RotatingEquipmentDataIn.aspx b/SGGL/FineUIPro.Web/Transfer/RotatingEquipmentDataIn.aspx new file mode 100644 index 00000000..ccec8b03 --- /dev/null +++ b/SGGL/FineUIPro.Web/Transfer/RotatingEquipmentDataIn.aspx @@ -0,0 +1,68 @@ +锘<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="RotatingEquipmentDataIn.aspx.cs" Inherits="FineUIPro.Web.Transfer.RotatingEquipmentDataIn" %> + + + + + + + + + +
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/SGGL/FineUIPro.Web/Transfer/RotatingEquipmentDataIn.aspx.cs b/SGGL/FineUIPro.Web/Transfer/RotatingEquipmentDataIn.aspx.cs new file mode 100644 index 00000000..46d84158 --- /dev/null +++ b/SGGL/FineUIPro.Web/Transfer/RotatingEquipmentDataIn.aspx.cs @@ -0,0 +1,427 @@ +锘縰sing 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 RotatingEquipmentDataIn : 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 璇籈xcel鎻愬彇鏁版嵁 + /// + /// 浠嶦xcel鎻愬彇鏁版嵁--銆婦ataset + /// + /// 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], 7); + hdCheckResult.Text = "1"; + } + catch (Exception exc) + { + Response.Write(exc); + //return null; + // return dt; + } + finally + { + } + } + #endregion + + #region 灏咲ataset鐨勬暟鎹鍏ユ暟鎹簱 + /// + /// 灏咲ataset鐨勬暟鎹鍏ユ暟鎹簱 + /// + /// 鏁版嵁闆 + /// 鏁版嵁闆嗚鏁 + /// + private bool AddDatasetToSQL(DataTable pds, int Cols) + { + string result = string.Empty; + int ic, ir; + ic = pds.Columns.Count; + if (ic < Cols) + { + ShowNotify("瀵煎叆Excel鏍煎紡閿欒锛丒xcel鍙湁" + ic.ToString().Trim() + "鍒", MessageBoxIcon.Warning); + return false; + } + + ir = pds.Rows.Count; + if (pds != null && ir > 0) + { + for (int i = 1; i < ir; i++) + { + string row4 = pds.Rows[i][4].ToString(); + if (!string.IsNullOrEmpty(row4)) + { + try + { + DateTime date = Convert.ToDateTime(row4.Trim()); + } + catch (Exception) + { + result += (i + 3).ToString() + "," + "Test Package START" + "," + "[" + row4 + "]閿欒锛佷笉鏄棩鏈熸牸寮忥紒" + "|"; + } + } + string row5 = pds.Rows[i][5].ToString(); + if (!string.IsNullOrEmpty(row4)) + { + try + { + DateTime date = Convert.ToDateTime(row5.Trim()); + } + catch (Exception) + { + result += (i + 3).ToString() + "," + "Test Package FINISH" + "," + "[" + row5 + "]閿欒锛佷笉鏄棩鏈熸牸寮忥紒" + "|"; + } + } + } + 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("璇峰厛灏嗛敊璇暟鎹慨姝o紝鍐嶉噸鏂板鍏ユ彁浜わ紒", MessageBoxIcon.Warning); + } + } + else + { + ShowNotify("璇峰厛瀹℃牳瑕佸鍏ョ殑鏂囦欢锛", MessageBoxIcon.Warning); + } + } + + #region Excel鎻愬彇鏁版嵁 + /// + /// 浠嶦xcel鎻愬彇鏁版嵁--銆婦ataset + /// + /// 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], 7); + } + catch (Exception ex) + { + throw ex; + } + } + #endregion + + #region 灏咲ataset鐨勬暟鎹鍏ユ暟鎹簱 + /// + /// 灏咲ataset鐨勬暟鎹鍏ユ暟鎹簱 + /// + /// 鏁版嵁闆 + /// 鏁版嵁闆嗗垪鏁 + /// + private bool AddDatasetToSQL2(DataTable pds, int Cols) + { + int ic, ir; + ic = pds.Columns.Count; + if (ic < Cols) + { + ShowNotify("瀵煎叆Excel鏍煎紡閿欒锛丒xcel鍙湁" + ic.ToString().Trim() + "鍒", MessageBoxIcon.Warning); + } + string result = string.Empty; + ir = pds.Rows.Count; + if (pds != null && ir > 0) + { + List list = new List(); + for (int i = 1; i < ir; i++) + { + //鏌ヨ绗竴鍒楋紝娌℃煡鍒扮殑鎯呭喌涓嬩綔瀵煎叆澶勭悊 + var modelOnly = Funs.DB.Transfer_RotatingEquipment.FirstOrDefault(x => x.RotatingEquipment == pds.Rows[i][0].ToString().Trim() + && x.ProjectId == CurrUser.LoginProjectId); + if (modelOnly == null) + { + Model.Transfer_RotatingEquipment model = new Model.Transfer_RotatingEquipment(); + model.Id = Guid.NewGuid().ToString(); + model.ProjectId = CurrUser.LoginProjectId; + model.RotatingEquipment = pds.Rows[i][0].ToString().Trim(); + model.SYSTEM = pds.Rows[i][1].ToString().Trim(); + model.Subsystem = pds.Rows[i][2].ToString().Trim(); + model.TestPackage = pds.Rows[i][3].ToString().Trim(); + DateTime t1, t2; + if (DateTime.TryParse(pds.Rows[i][4].ToString(), out t1) && !string.IsNullOrEmpty(pds.Rows[i][4].ToString())) + model.TestPackageSTART = t1; + if (DateTime.TryParse(pds.Rows[i][5].ToString(), out t2) && !string.IsNullOrEmpty(pds.Rows[i][5].ToString())) + model.TestPackageFINISH = t2; + + model.MechanicalFINALStatus = pds.Rows[i][6].ToString().Trim(); + if (model.MechanicalFINALStatus.ToLower() == "finished") + { + model.CompleteTime = DateTime.Now; + } + list.Add(model); + } + else + { + //淇敼 + modelOnly.RotatingEquipment = pds.Rows[i][0].ToString().Trim(); + modelOnly.SYSTEM = pds.Rows[i][1].ToString().Trim(); + modelOnly.Subsystem = pds.Rows[i][2].ToString().Trim(); + modelOnly.TestPackage = pds.Rows[i][3].ToString().Trim(); + DateTime t1, t2; + if (DateTime.TryParse(pds.Rows[i][4].ToString(), out t1) && !string.IsNullOrEmpty(pds.Rows[i][4].ToString())) + modelOnly.TestPackageSTART = t1; + if (DateTime.TryParse(pds.Rows[i][5].ToString(), out t2) && !string.IsNullOrEmpty(pds.Rows[i][5].ToString())) + modelOnly.TestPackageFINISH = t2; + modelOnly.MechanicalFINALStatus = pds.Rows[i][6].ToString().Trim(); + + if (modelOnly.MechanicalFINALStatus.ToLower() == "finished") + { + modelOnly.CompleteTime = DateTime.Now; + } + + Funs.DB.SubmitChanges(); + } + } + if (list.Count > 0) + { + Funs.DB.Transfer_RotatingEquipment.InsertAllOnSubmit(list); + Funs.DB.SubmitChanges(); + } + } + 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 + "File\\Excel\\DataIn\\RotatingEquipment瀵煎叆妯℃澘.xls"; + string filePath = "File\\Excel\\DataIn\\RotatingEquipment瀵煎叆妯℃澘.xls"; + 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/RotatingEquipmentDataIn.aspx.designer.cs b/SGGL/FineUIPro.Web/Transfer/RotatingEquipmentDataIn.aspx.designer.cs new file mode 100644 index 00000000..bb3f6d2f --- /dev/null +++ b/SGGL/FineUIPro.Web/Transfer/RotatingEquipmentDataIn.aspx.designer.cs @@ -0,0 +1,123 @@ +锘//------------------------------------------------------------------------------ +// <鑷姩鐢熸垚> +// 姝や唬鐮佺敱宸ュ叿鐢熸垚銆 +// +// 瀵规鏂囦欢鐨勬洿鏀瑰彲鑳藉鑷翠笉姝g‘鐨勮涓猴紝濡傛灉 +// 閲嶆柊鐢熸垚浠g爜锛屽垯鎵鍋氭洿鏀瑰皢涓㈠け銆 +// +//------------------------------------------------------------------------------ + +namespace FineUIPro.Web.Transfer { + + + public partial class RotatingEquipmentDataIn { + + /// + /// form1 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::System.Web.UI.HtmlControls.HtmlForm form1; + + /// + /// PageManager1 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.PageManager PageManager1; + + /// + /// SimpleForm1 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.Form SimpleForm1; + + /// + /// Toolbar2 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.Toolbar Toolbar2; + + /// + /// hdFileName 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.HiddenField hdFileName; + + /// + /// btnAudit 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.Button btnAudit; + + /// + /// btnImport 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.Button btnImport; + + /// + /// btnDownLoad 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.Button btnDownLoad; + + /// + /// hdCheckResult 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.HiddenField hdCheckResult; + + /// + /// fuAttachUrl 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.FileUpload fuAttachUrl; + + /// + /// gvErrorInfo 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.Grid gvErrorInfo; + + /// + /// lblPageIndex 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::System.Web.UI.WebControls.Label lblPageIndex; + } +} diff --git a/SGGL/FineUIPro.Web/Transfer/StaticEquipment.aspx b/SGGL/FineUIPro.Web/Transfer/StaticEquipment.aspx new file mode 100644 index 00000000..df506ba3 --- /dev/null +++ b/SGGL/FineUIPro.Web/Transfer/StaticEquipment.aspx @@ -0,0 +1,137 @@ +锘<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="StaticEquipment.aspx.cs" Inherits="FineUIPro.Web.Transfer.StaticEquipment" %> + + + + + + + + + +
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/SGGL/FineUIPro.Web/Transfer/StaticEquipment.aspx.cs b/SGGL/FineUIPro.Web/Transfer/StaticEquipment.aspx.cs new file mode 100644 index 00000000..107c96d2 --- /dev/null +++ b/SGGL/FineUIPro.Web/Transfer/StaticEquipment.aspx.cs @@ -0,0 +1,229 @@ +锘縰sing 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 StaticEquipment : PageBase + { + #region 鍔犺浇 + /// + /// 鍔犺浇椤甸潰 + /// + /// + /// + protected void Page_Load(object sender, EventArgs e) + { + if (!IsPostBack) + { + GetButtonPower(); + BindGrid(); + } + } + + /// + /// 鏁版嵁缁戝畾 + /// + public void BindGrid() + { + string strSql = @"select * from Transfer_StaticEquipment C + where C.ProjectId = @ProjectId"; + List listStr = new List(); + listStr.Add(new SqlParameter("@ProjectId", this.CurrUser.LoginProjectId)); + if (!string.IsNullOrEmpty(this.txtStaticEquipment.Text.Trim())) + { + strSql += " AND StaticEquipment like @StaticEquipment"; + listStr.Add(new SqlParameter("@StaticEquipment", "%" + this.txtStaticEquipment.Text.Trim() + "%")); + } + if (!string.IsNullOrEmpty(txtStarTime.Text.Trim())) + { + strSql += " AND TestPackageSTART >= @InspectionDateA"; + listStr.Add(new SqlParameter("@InspectionDateA", Funs.GetNewDateTime(txtStarTime.Text.Trim()))); + } + if (!string.IsNullOrEmpty(txtEndTime.Text.Trim())) + { + strSql += " AND TestPackageSTART <= @InspectionDateZ"; + listStr.Add(new SqlParameter("@InspectionDateZ", Funs.GetNewDateTime(txtEndTime.Text.Trim()))); + } + if (!string.IsNullOrEmpty(this.txtSystem.Text.Trim())) + { + strSql += " AND SYSTEM like @SYSTEM"; + listStr.Add(new SqlParameter("@SYSTEM", "%" + this.txtSystem.Text.Trim() + "%")); + } + + 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.StaticEquipmentService.GetStaticEquipmentById(rowID); + if (data != null) + { + BLL.StaticEquipmentService.DeleteStaticEquipment(rowID); + } + } + BindGrid(); + ShowNotify("鍒犻櫎鏁版嵁鎴愬姛!", MessageBoxIcon.Success); + } + } + #endregion + + #region 瀵煎叆 + /// + /// 瀵煎叆鎸夐挳 + /// + /// + /// + protected void btnImport_Click(object sender, EventArgs e) + { + PageContext.RegisterStartupScript(Window2.GetShowReference(String.Format("StaticEquipmentDataIn.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.StaticEquipmentMenuId); + 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/StaticEquipment.aspx.designer.cs b/SGGL/FineUIPro.Web/Transfer/StaticEquipment.aspx.designer.cs new file mode 100644 index 00000000..5c8b69a6 --- /dev/null +++ b/SGGL/FineUIPro.Web/Transfer/StaticEquipment.aspx.designer.cs @@ -0,0 +1,233 @@ +锘//------------------------------------------------------------------------------ +// <鑷姩鐢熸垚> +// 姝や唬鐮佺敱宸ュ叿鐢熸垚銆 +// +// 瀵规鏂囦欢鐨勬洿鏀瑰彲鑳藉鑷翠笉姝g‘鐨勮涓猴紝濡傛灉 +// 閲嶆柊鐢熸垚浠g爜锛屽垯鎵鍋氭洿鏀瑰皢涓㈠け銆 +// +//------------------------------------------------------------------------------ + +namespace FineUIPro.Web.Transfer +{ + + + public partial class StaticEquipment + { + + /// + /// form1 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::System.Web.UI.HtmlControls.HtmlForm form1; + + /// + /// PageManager1 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.PageManager PageManager1; + + /// + /// Panel1 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.Panel Panel1; + + /// + /// Grid1 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.Grid Grid1; + + /// + /// ToolSearch 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.Toolbar ToolSearch; + + /// + /// txtStaticEquipment 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.TextBox txtStaticEquipment; + + /// + /// txtSystem 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.TextBox txtSystem; + + /// + /// txtStarTime 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.DatePicker txtStarTime; + + /// + /// Label1 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.Label Label1; + + /// + /// txtEndTime 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.DatePicker txtEndTime; + + /// + /// btnSearch 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.Button btnSearch; + + /// + /// btnImport 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.Button btnImport; + + /// + /// lblPageIndex 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::System.Web.UI.WebControls.Label lblPageIndex; + + /// + /// g1 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.GroupField g1; + + /// + /// g2 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.GroupField g2; + + /// + /// g3 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.GroupField g3; + + /// + /// g5 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.GroupField g5; + + /// + /// ToolbarText1 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.ToolbarText ToolbarText1; + + /// + /// ddlPageSize 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.DropDownList ddlPageSize; + + /// + /// Window1 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.Window Window1; + + /// + /// Window2 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.Window Window2; + + /// + /// WindowAtt 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.Window WindowAtt; + + /// + /// Menu1 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.Menu Menu1; + + /// + /// btnMenuDel 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.MenuButton btnMenuDel; + } +} diff --git a/SGGL/FineUIPro.Web/Transfer/StaticEquipmentDataIn.aspx b/SGGL/FineUIPro.Web/Transfer/StaticEquipmentDataIn.aspx new file mode 100644 index 00000000..22fc0d7a --- /dev/null +++ b/SGGL/FineUIPro.Web/Transfer/StaticEquipmentDataIn.aspx @@ -0,0 +1,68 @@ +锘<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="StaticEquipmentDataIn.aspx.cs" Inherits="FineUIPro.Web.Transfer.StaticEquipmentDataIn" %> + + + + + + + + + +
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/SGGL/FineUIPro.Web/Transfer/StaticEquipmentDataIn.aspx.cs b/SGGL/FineUIPro.Web/Transfer/StaticEquipmentDataIn.aspx.cs new file mode 100644 index 00000000..2746a5c5 --- /dev/null +++ b/SGGL/FineUIPro.Web/Transfer/StaticEquipmentDataIn.aspx.cs @@ -0,0 +1,426 @@ +锘縰sing 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 StaticEquipmentDataIn : 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 璇籈xcel鎻愬彇鏁版嵁 + /// + /// 浠嶦xcel鎻愬彇鏁版嵁--銆婦ataset + /// + /// 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], 7); + hdCheckResult.Text = "1"; + } + catch (Exception exc) + { + Response.Write(exc); + //return null; + // return dt; + } + finally + { + } + } + #endregion + + #region 灏咲ataset鐨勬暟鎹鍏ユ暟鎹簱 + /// + /// 灏咲ataset鐨勬暟鎹鍏ユ暟鎹簱 + /// + /// 鏁版嵁闆 + /// 鏁版嵁闆嗚鏁 + /// + private bool AddDatasetToSQL(DataTable pds, int Cols) + { + string result = string.Empty; + int ic, ir; + ic = pds.Columns.Count; + if (ic < Cols) + { + ShowNotify("瀵煎叆Excel鏍煎紡閿欒锛丒xcel鍙湁" + ic.ToString().Trim() + "鍒", MessageBoxIcon.Warning); + return false; + } + + ir = pds.Rows.Count; + if (pds != null && ir > 0) + { + for (int i = 1; i < ir; i++) + { + string row4 = pds.Rows[i][4].ToString(); + if (!string.IsNullOrEmpty(row4)) + { + try + { + DateTime date = Convert.ToDateTime(row4.Trim()); + } + catch (Exception) + { + result += (i + 3).ToString() + "," + "Test Package START" + "," + "[" + row4 + "]閿欒锛佷笉鏄棩鏈熸牸寮忥紒" + "|"; + } + } + string row5 = pds.Rows[i][5].ToString(); + if (!string.IsNullOrEmpty(row4)) + { + try + { + DateTime date = Convert.ToDateTime(row5.Trim()); + } + catch (Exception) + { + result += (i + 3).ToString() + "," + "Test Package FINISH" + "," + "[" + row5 + "]閿欒锛佷笉鏄棩鏈熸牸寮忥紒" + "|"; + } + } + } + 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("璇峰厛灏嗛敊璇暟鎹慨姝o紝鍐嶉噸鏂板鍏ユ彁浜わ紒", MessageBoxIcon.Warning); + } + } + else + { + ShowNotify("璇峰厛瀹℃牳瑕佸鍏ョ殑鏂囦欢锛", MessageBoxIcon.Warning); + } + } + + #region Excel鎻愬彇鏁版嵁 + /// + /// 浠嶦xcel鎻愬彇鏁版嵁--銆婦ataset + /// + /// 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], 7); + } + catch (Exception ex) + { + throw ex; + } + } + #endregion + + #region 灏咲ataset鐨勬暟鎹鍏ユ暟鎹簱 + /// + /// 灏咲ataset鐨勬暟鎹鍏ユ暟鎹簱 + /// + /// 鏁版嵁闆 + /// 鏁版嵁闆嗗垪鏁 + /// + private bool AddDatasetToSQL2(DataTable pds, int Cols) + { + int ic, ir; + ic = pds.Columns.Count; + if (ic < Cols) + { + ShowNotify("瀵煎叆Excel鏍煎紡閿欒锛丒xcel鍙湁" + ic.ToString().Trim() + "鍒", MessageBoxIcon.Warning); + } + string result = string.Empty; + ir = pds.Rows.Count; + if (pds != null && ir > 0) + { + List list = new List(); + for (int i = 1; i < ir; i++) + { + //鏌ヨ绗竴鍒楋紝娌℃煡鍒扮殑鎯呭喌涓嬩綔瀵煎叆澶勭悊 + var modelOnly = Funs.DB.Transfer_StaticEquipment.FirstOrDefault(x => x.StaticEquipment == pds.Rows[i][0].ToString().Trim() + && x.ProjectId == CurrUser.LoginProjectId); + if (modelOnly == null) + { + Model.Transfer_StaticEquipment model = new Model.Transfer_StaticEquipment(); + model.Id = Guid.NewGuid().ToString(); + model.ProjectId = CurrUser.LoginProjectId; + model.StaticEquipment = pds.Rows[i][0].ToString().Trim(); + model.SYSTEM = pds.Rows[i][1].ToString().Trim(); + model.Subsystem = pds.Rows[i][2].ToString().Trim(); + model.TestPackage = pds.Rows[i][3].ToString().Trim(); + DateTime t1, t2; + if (DateTime.TryParse(pds.Rows[i][4].ToString(), out t1) && !string.IsNullOrEmpty(pds.Rows[i][4].ToString())) + model.TestPackageSTART = t1; + if (DateTime.TryParse(pds.Rows[i][5].ToString(), out t2) && !string.IsNullOrEmpty(pds.Rows[i][5].ToString())) + model.TestPackageFINISH = t2; + + model.MechanicalFINALStatus = pds.Rows[i][6].ToString().Trim(); + if (model.MechanicalFINALStatus.ToLower() == "finished") + { + model.CompleteTime = DateTime.Now; + } + + list.Add(model); + } + else + { + //淇敼 + modelOnly.StaticEquipment = pds.Rows[i][0].ToString().Trim(); + modelOnly.SYSTEM = pds.Rows[i][1].ToString().Trim(); + modelOnly.Subsystem = pds.Rows[i][2].ToString().Trim(); + modelOnly.TestPackage = pds.Rows[i][3].ToString().Trim(); + DateTime t1, t2; + if (DateTime.TryParse(pds.Rows[i][4].ToString(), out t1) && !string.IsNullOrEmpty(pds.Rows[i][4].ToString())) + modelOnly.TestPackageSTART = t1; + if (DateTime.TryParse(pds.Rows[i][5].ToString(), out t2) && !string.IsNullOrEmpty(pds.Rows[i][5].ToString())) + modelOnly.TestPackageFINISH = t2; + modelOnly.MechanicalFINALStatus = pds.Rows[i][6].ToString().Trim(); + if (modelOnly.MechanicalFINALStatus.ToLower() == "finished") + { + modelOnly.CompleteTime = DateTime.Now; + } + Funs.DB.SubmitChanges(); + } + } + if (list.Count > 0) + { + Funs.DB.Transfer_StaticEquipment.InsertAllOnSubmit(list); + Funs.DB.SubmitChanges(); + } + } + 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 + "File\\Excel\\DataIn\\StaticEquipment瀵煎叆妯℃澘.xls"; + string filePath = "File\\Excel\\DataIn\\StaticEquipment瀵煎叆妯℃澘.xls"; + 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/StaticEquipmentDataIn.aspx.designer.cs b/SGGL/FineUIPro.Web/Transfer/StaticEquipmentDataIn.aspx.designer.cs new file mode 100644 index 00000000..30d4244f --- /dev/null +++ b/SGGL/FineUIPro.Web/Transfer/StaticEquipmentDataIn.aspx.designer.cs @@ -0,0 +1,123 @@ +锘//------------------------------------------------------------------------------ +// <鑷姩鐢熸垚> +// 姝や唬鐮佺敱宸ュ叿鐢熸垚銆 +// +// 瀵规鏂囦欢鐨勬洿鏀瑰彲鑳藉鑷翠笉姝g‘鐨勮涓猴紝濡傛灉 +// 閲嶆柊鐢熸垚浠g爜锛屽垯鎵鍋氭洿鏀瑰皢涓㈠け銆 +// +//------------------------------------------------------------------------------ + +namespace FineUIPro.Web.Transfer { + + + public partial class StaticEquipmentDataIn { + + /// + /// form1 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::System.Web.UI.HtmlControls.HtmlForm form1; + + /// + /// PageManager1 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.PageManager PageManager1; + + /// + /// SimpleForm1 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.Form SimpleForm1; + + /// + /// Toolbar2 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.Toolbar Toolbar2; + + /// + /// hdFileName 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.HiddenField hdFileName; + + /// + /// btnAudit 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.Button btnAudit; + + /// + /// btnImport 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.Button btnImport; + + /// + /// btnDownLoad 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.Button btnDownLoad; + + /// + /// hdCheckResult 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.HiddenField hdCheckResult; + + /// + /// fuAttachUrl 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.FileUpload fuAttachUrl; + + /// + /// gvErrorInfo 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.Grid gvErrorInfo; + + /// + /// lblPageIndex 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::System.Web.UI.WebControls.Label lblPageIndex; + } +} diff --git a/SGGL/FineUIPro.Web/Transfer/Telecom.aspx b/SGGL/FineUIPro.Web/Transfer/Telecom.aspx index 91edfec2..4868ebb4 100644 --- a/SGGL/FineUIPro.Web/Transfer/Telecom.aspx +++ b/SGGL/FineUIPro.Web/Transfer/Telecom.aspx @@ -24,6 +24,8 @@ + + diff --git a/SGGL/FineUIPro.Web/Transfer/Telecom.aspx.cs b/SGGL/FineUIPro.Web/Transfer/Telecom.aspx.cs index 767658f8..2043236e 100644 --- a/SGGL/FineUIPro.Web/Transfer/Telecom.aspx.cs +++ b/SGGL/FineUIPro.Web/Transfer/Telecom.aspx.cs @@ -51,6 +51,11 @@ namespace FineUIPro.Web.Transfer strSql += " AND Test_Package_START <= @InspectionDateZ"; listStr.Add(new SqlParameter("@InspectionDateZ", Funs.GetNewDateTime(txtEndTime.Text.Trim()))); } + if (!string.IsNullOrEmpty(this.txtSystem.Text.Trim())) + { + strSql += " AND SystemName like @SystemName"; + listStr.Add(new SqlParameter("@SystemName", "%" + this.txtSystem.Text.Trim() + "%")); + } strSql += " order by Telecom "; diff --git a/SGGL/FineUIPro.Web/Transfer/Telecom.aspx.designer.cs b/SGGL/FineUIPro.Web/Transfer/Telecom.aspx.designer.cs index 815afe32..4518bcf3 100644 --- a/SGGL/FineUIPro.Web/Transfer/Telecom.aspx.designer.cs +++ b/SGGL/FineUIPro.Web/Transfer/Telecom.aspx.designer.cs @@ -68,6 +68,15 @@ namespace FineUIPro.Web.Transfer /// protected global::FineUIPro.TextBox txtTelecom; + /// + /// txtSystem 鎺т欢銆 + /// + /// + /// 鑷姩鐢熸垚鐨勫瓧娈点 + /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲 + /// + protected global::FineUIPro.TextBox txtSystem; + /// /// txtStarTime 鎺т欢銆 /// diff --git a/SGGL/FineUIPro.Web/Transfer/TelecomDataIn.aspx.cs b/SGGL/FineUIPro.Web/Transfer/TelecomDataIn.aspx.cs index bc640cba..a67ffc19 100644 --- a/SGGL/FineUIPro.Web/Transfer/TelecomDataIn.aspx.cs +++ b/SGGL/FineUIPro.Web/Transfer/TelecomDataIn.aspx.cs @@ -181,7 +181,7 @@ namespace FineUIPro.Web.Transfer } } string row5 = pds.Rows[i][5].ToString(); - if (!string.IsNullOrEmpty(row4)) + if (!string.IsNullOrEmpty(row5)) { try { @@ -329,41 +329,52 @@ namespace FineUIPro.Web.Transfer List list = new List(); for (int i = 1; i < ir; i++) { - //鏌ヨ绗竴鍒楋紝娌℃煡鍒扮殑鎯呭喌涓嬩綔瀵煎叆澶勭悊 - var modelOnly = Funs.DB.Transfer_Telecom.FirstOrDefault(x => x.Telecom == pds.Rows[i][0].ToString().Trim() + if (!string.IsNullOrEmpty(pds.Rows[i][0].ToString().Trim())) + { + //鏌ヨ绗竴鍒楋紝娌℃煡鍒扮殑鎯呭喌涓嬩綔瀵煎叆澶勭悊 + var modelOnly = Funs.DB.Transfer_Telecom.FirstOrDefault(x => x.Telecom == pds.Rows[i][0].ToString().Trim() && x.ProjectId == CurrUser.LoginProjectId); - if (modelOnly == null) - { - Model.Transfer_Telecom model = new Model.Transfer_Telecom(); - model.Id = Guid.NewGuid().ToString(); - model.ProjectId = CurrUser.LoginProjectId; - model.Telecom = pds.Rows[i][0].ToString().Trim(); - model.SystemName = pds.Rows[i][1].ToString().Trim(); - model.Subsystem = pds.Rows[i][2].ToString().Trim(); - model.Test_Package = pds.Rows[i][3].ToString().Trim(); - DateTime t1, t2; - if (DateTime.TryParse(pds.Rows[i][4].ToString(), out t1) && !string.IsNullOrEmpty(pds.Rows[i][4].ToString())) - model.Test_Package_START = t1; - if (DateTime.TryParse(pds.Rows[i][5].ToString(), out t2) && !string.IsNullOrEmpty(pds.Rows[i][5].ToString())) - model.Test_Package_FINISH = t2; + if (modelOnly == null) + { + Model.Transfer_Telecom model = new Model.Transfer_Telecom(); + model.Id = Guid.NewGuid().ToString(); + model.ProjectId = CurrUser.LoginProjectId; + model.Telecom = pds.Rows[i][0].ToString().Trim(); + model.SystemName = pds.Rows[i][1].ToString().Trim(); + model.Subsystem = pds.Rows[i][2].ToString().Trim(); + model.Test_Package = pds.Rows[i][3].ToString().Trim(); + DateTime t1, t2; + if (DateTime.TryParse(pds.Rows[i][4].ToString(), out t1) && !string.IsNullOrEmpty(pds.Rows[i][4].ToString())) + model.Test_Package_START = t1; + if (DateTime.TryParse(pds.Rows[i][5].ToString(), out t2) && !string.IsNullOrEmpty(pds.Rows[i][5].ToString())) + model.Test_Package_FINISH = t2; - model.FINAL_Status = pds.Rows[i][6].ToString().Trim(); - list.Add(model); - } - else - { - //淇敼 - modelOnly.Telecom = pds.Rows[i][0].ToString().Trim(); - modelOnly.SystemName = pds.Rows[i][1].ToString().Trim(); - modelOnly.Subsystem = pds.Rows[i][2].ToString().Trim(); - modelOnly.Test_Package = pds.Rows[i][3].ToString().Trim(); - DateTime t1, t2; - if (DateTime.TryParse(pds.Rows[i][4].ToString(), out t1) && !string.IsNullOrEmpty(pds.Rows[i][4].ToString())) - modelOnly.Test_Package_START = t1; - if (DateTime.TryParse(pds.Rows[i][5].ToString(), out t2) && !string.IsNullOrEmpty(pds.Rows[i][5].ToString())) - modelOnly.Test_Package_FINISH = t2; - modelOnly.FINAL_Status = pds.Rows[i][6].ToString().Trim(); - Funs.DB.SubmitChanges(); + model.FINAL_Status = pds.Rows[i][6].ToString().Trim(); + if (model.FINAL_Status.ToLower() == "finished") + { + model.CompleteTime = DateTime.Now; + } + list.Add(model); + } + else + { + //淇敼 + modelOnly.Telecom = pds.Rows[i][0].ToString().Trim(); + modelOnly.SystemName = pds.Rows[i][1].ToString().Trim(); + modelOnly.Subsystem = pds.Rows[i][2].ToString().Trim(); + modelOnly.Test_Package = pds.Rows[i][3].ToString().Trim(); + DateTime t1, t2; + if (DateTime.TryParse(pds.Rows[i][4].ToString(), out t1) && !string.IsNullOrEmpty(pds.Rows[i][4].ToString())) + modelOnly.Test_Package_START = t1; + if (DateTime.TryParse(pds.Rows[i][5].ToString(), out t2) && !string.IsNullOrEmpty(pds.Rows[i][5].ToString())) + modelOnly.Test_Package_FINISH = t2; + modelOnly.FINAL_Status = pds.Rows[i][6].ToString().Trim(); + if (modelOnly.FINAL_Status.ToLower() == "finished") + { + modelOnly.CompleteTime = DateTime.Now; + } + Funs.DB.SubmitChanges(); + } } } if (list.Count > 0) diff --git a/SGGL/FineUIPro.Web/Web.config b/SGGL/FineUIPro.Web/Web.config index 37de607d..6f9fe9f9 100644 --- a/SGGL/FineUIPro.Web/Web.config +++ b/SGGL/FineUIPro.Web/Web.config @@ -11,7 +11,8 @@ - + + diff --git a/SGGL/FineUIPro.Web/common/Menu_Transfer.xml b/SGGL/FineUIPro.Web/common/Menu_Transfer.xml index c006fd7f..5180b459 100644 --- a/SGGL/FineUIPro.Web/common/Menu_Transfer.xml +++ b/SGGL/FineUIPro.Web/common/Menu_Transfer.xml @@ -13,4 +13,8 @@ + + + + \ No newline at end of file diff --git a/SGGL/FineUIPro.Web/common/mainProject2.aspx.cs b/SGGL/FineUIPro.Web/common/mainProject2.aspx.cs index 878e59cc..111078dd 100644 --- a/SGGL/FineUIPro.Web/common/mainProject2.aspx.cs +++ b/SGGL/FineUIPro.Web/common/mainProject2.aspx.cs @@ -100,7 +100,7 @@ namespace FineUIPro.Web.common //璐ㄩ噺鍩硅浜哄憳 DateTime date = DateTime.Now.AddDays(-1); int CqmsPxNum = (from x in Funs.DB.Comprehensive_InspectionPerson - where x.IsTrain == true && x.CompileDate.Value.Year == date.Year && x.CompileDate.Value.Month == date.Month && x.CompileDate.Value.Day == date.Day + where x.IsTrain == true && x.ProjectId == ProjectId select x).Count(); divCqmsPxNum.InnerHtml = CqmsPxNum.ToString(); diff --git a/SGGL/Model/Model.cs b/SGGL/Model/Model.cs index 3f5147c5..28352979 100644 --- a/SGGL/Model/Model.cs +++ b/SGGL/Model/Model.cs @@ -227,6 +227,9 @@ namespace Model partial void InsertBase_TrainTypeItem(Base_TrainTypeItem instance); partial void UpdateBase_TrainTypeItem(Base_TrainTypeItem instance); partial void DeleteBase_TrainTypeItem(Base_TrainTypeItem instance); + partial void InsertBase_TransferMajor(Base_TransferMajor instance); + partial void UpdateBase_TransferMajor(Base_TransferMajor instance); + partial void DeleteBase_TransferMajor(Base_TransferMajor instance); partial void InsertBase_Unit(Base_Unit instance); partial void UpdateBase_Unit(Base_Unit instance); partial void DeleteBase_Unit(Base_Unit instance); @@ -2363,6 +2366,12 @@ namespace Model partial void InsertTransfer_PunchlistFrom(Transfer_PunchlistFrom instance); partial void UpdateTransfer_PunchlistFrom(Transfer_PunchlistFrom instance); partial void DeleteTransfer_PunchlistFrom(Transfer_PunchlistFrom instance); + partial void InsertTransfer_RotatingEquipment(Transfer_RotatingEquipment instance); + partial void UpdateTransfer_RotatingEquipment(Transfer_RotatingEquipment instance); + partial void DeleteTransfer_RotatingEquipment(Transfer_RotatingEquipment instance); + partial void InsertTransfer_StaticEquipment(Transfer_StaticEquipment instance); + partial void UpdateTransfer_StaticEquipment(Transfer_StaticEquipment instance); + partial void DeleteTransfer_StaticEquipment(Transfer_StaticEquipment instance); partial void InsertTransfer_Telecom(Transfer_Telecom instance); partial void UpdateTransfer_Telecom(Transfer_Telecom instance); partial void DeleteTransfer_Telecom(Transfer_Telecom instance); @@ -3073,6 +3082,14 @@ namespace Model } } + public System.Data.Linq.Table Base_TransferMajor + { + get + { + return this.GetTable(); + } + } + public System.Data.Linq.Table Base_Unit { get @@ -8785,6 +8802,22 @@ namespace Model } } + public System.Data.Linq.Table Transfer_RotatingEquipment + { + get + { + return this.GetTable(); + } + } + + public System.Data.Linq.Table Transfer_StaticEquipment + { + get + { + return this.GetTable(); + } + } + public System.Data.Linq.Table Transfer_Telecom { get @@ -9729,6 +9762,14 @@ namespace Model } } + public System.Data.Linq.Table View_TransferDetail + { + get + { + return this.GetTable(); + } + } + public System.Data.Linq.Table View_WBS { get @@ -25615,6 +25656,8 @@ namespace Model private EntitySet _DriverSub_DriverSubContact; + private EntitySet _DriverSub_DriverSubPlan; + private EntitySet _EduTrain_TrainRecord; private EntitySet _EduTrain_TrainPersonRecord; @@ -26185,6 +26228,7 @@ namespace Model this._DriverRun_DriverRunPlan = new EntitySet(new Action(this.attach_DriverRun_DriverRunPlan), new Action(this.detach_DriverRun_DriverRunPlan)); this._DriverSub_DriverSub = new EntitySet(new Action(this.attach_DriverSub_DriverSub), new Action(this.detach_DriverSub_DriverSub)); this._DriverSub_DriverSubContact = new EntitySet(new Action(this.attach_DriverSub_DriverSubContact), new Action(this.detach_DriverSub_DriverSubContact)); + this._DriverSub_DriverSubPlan = new EntitySet(new Action(this.attach_DriverSub_DriverSubPlan), new Action(this.detach_DriverSub_DriverSubPlan)); this._EduTrain_TrainRecord = new EntitySet(new Action(this.attach_EduTrain_TrainRecord), new Action(this.detach_EduTrain_TrainRecord)); this._EduTrain_TrainPersonRecord = new EntitySet(new Action(this.attach_EduTrain_TrainPersonRecord), new Action(this.detach_EduTrain_TrainPersonRecord)); this._Emergency_DrillRecordList = new EntitySet(new Action(this.attach_Emergency_DrillRecordList), new Action(this.detach_Emergency_DrillRecordList)); @@ -28554,6 +28598,19 @@ namespace Model } } + [global::System.Data.Linq.Mapping.AssociationAttribute(Name="FK_DriverSub_DriverSubPlan_Base_Project", Storage="_DriverSub_DriverSubPlan", ThisKey="ProjectId", OtherKey="ProjectId", DeleteRule="NO ACTION")] + public EntitySet DriverSub_DriverSubPlan + { + get + { + return this._DriverSub_DriverSubPlan; + } + set + { + this._DriverSub_DriverSubPlan.Assign(value); + } + } + [global::System.Data.Linq.Mapping.AssociationAttribute(Name="FK_EduTrain_Training_Base_Project", Storage="_EduTrain_TrainRecord", ThisKey="ProjectId", OtherKey="ProjectId", DeleteRule="NO ACTION")] public EntitySet EduTrain_TrainRecord { @@ -32244,6 +32301,18 @@ namespace Model entity.Base_Project = null; } + private void attach_DriverSub_DriverSubPlan(DriverSub_DriverSubPlan entity) + { + this.SendPropertyChanging(); + entity.Base_Project = this; + } + + private void detach_DriverSub_DriverSubPlan(DriverSub_DriverSubPlan entity) + { + this.SendPropertyChanging(); + entity.Base_Project = null; + } + private void attach_EduTrain_TrainRecord(EduTrain_TrainRecord entity) { this.SendPropertyChanging(); @@ -37805,6 +37874,164 @@ namespace Model } } + [global::System.Data.Linq.Mapping.TableAttribute(Name="dbo.Base_TransferMajor")] + public partial class Base_TransferMajor : INotifyPropertyChanging, INotifyPropertyChanged + { + + private static PropertyChangingEventArgs emptyChangingEventArgs = new PropertyChangingEventArgs(String.Empty); + + private string _TransferMajorId; + + private string _Discipline; + + private string _Major; + + private string _DisciplineCode; + + private string _Remark; + + #region 鍙墿灞曟ф柟娉曞畾涔 + partial void OnLoaded(); + partial void OnValidate(System.Data.Linq.ChangeAction action); + partial void OnCreated(); + partial void OnTransferMajorIdChanging(string value); + partial void OnTransferMajorIdChanged(); + partial void OnDisciplineChanging(string value); + partial void OnDisciplineChanged(); + partial void OnMajorChanging(string value); + partial void OnMajorChanged(); + partial void OnDisciplineCodeChanging(string value); + partial void OnDisciplineCodeChanged(); + partial void OnRemarkChanging(string value); + partial void OnRemarkChanged(); + #endregion + + public Base_TransferMajor() + { + OnCreated(); + } + + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_TransferMajorId", DbType="NVarChar(50) NOT NULL", CanBeNull=false, IsPrimaryKey=true)] + public string TransferMajorId + { + get + { + return this._TransferMajorId; + } + set + { + if ((this._TransferMajorId != value)) + { + this.OnTransferMajorIdChanging(value); + this.SendPropertyChanging(); + this._TransferMajorId = value; + this.SendPropertyChanged("TransferMajorId"); + this.OnTransferMajorIdChanged(); + } + } + } + + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Discipline", DbType="NVarChar(50)")] + public string Discipline + { + get + { + return this._Discipline; + } + set + { + if ((this._Discipline != value)) + { + this.OnDisciplineChanging(value); + this.SendPropertyChanging(); + this._Discipline = value; + this.SendPropertyChanged("Discipline"); + this.OnDisciplineChanged(); + } + } + } + + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Major", DbType="NVarChar(50)")] + public string Major + { + get + { + return this._Major; + } + set + { + if ((this._Major != value)) + { + this.OnMajorChanging(value); + this.SendPropertyChanging(); + this._Major = value; + this.SendPropertyChanged("Major"); + this.OnMajorChanged(); + } + } + } + + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_DisciplineCode", DbType="NVarChar(50)")] + public string DisciplineCode + { + get + { + return this._DisciplineCode; + } + set + { + if ((this._DisciplineCode != value)) + { + this.OnDisciplineCodeChanging(value); + this.SendPropertyChanging(); + this._DisciplineCode = value; + this.SendPropertyChanged("DisciplineCode"); + this.OnDisciplineCodeChanged(); + } + } + } + + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Remark", DbType="NVarChar(200)")] + public string Remark + { + get + { + return this._Remark; + } + set + { + if ((this._Remark != value)) + { + this.OnRemarkChanging(value); + this.SendPropertyChanging(); + this._Remark = value; + this.SendPropertyChanged("Remark"); + this.OnRemarkChanged(); + } + } + } + + 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.Base_Unit")] public partial class Base_Unit : INotifyPropertyChanging, INotifyPropertyChanged { @@ -37977,6 +38204,8 @@ namespace Model private EntitySet _DriverSub_DriverSubContact; + private EntitySet _DriverSub_DriverSubPlan; + private EntitySet _Emergency_EmergencyList; private EntitySet _Emergency_EmergencySupply; @@ -38327,6 +38556,7 @@ namespace Model this._DriverRun_DriverRunPlan = new EntitySet(new Action(this.attach_DriverRun_DriverRunPlan), new Action(this.detach_DriverRun_DriverRunPlan)); this._DriverSub_DriverSub = new EntitySet(new Action(this.attach_DriverSub_DriverSub), new Action(this.detach_DriverSub_DriverSub)); this._DriverSub_DriverSubContact = new EntitySet(new Action(this.attach_DriverSub_DriverSubContact), new Action(this.detach_DriverSub_DriverSubContact)); + this._DriverSub_DriverSubPlan = new EntitySet(new Action(this.attach_DriverSub_DriverSubPlan), new Action(this.detach_DriverSub_DriverSubPlan)); this._Emergency_EmergencyList = new EntitySet(new Action(this.attach_Emergency_EmergencyList), new Action(this.detach_Emergency_EmergencyList)); this._Emergency_EmergencySupply = new EntitySet(new Action(this.attach_Emergency_EmergencySupply), new Action(this.detach_Emergency_EmergencySupply)); this._Emergency_EmergencyTeamAndTrain = new EntitySet(new Action(this.attach_Emergency_EmergencyTeamAndTrain), new Action(this.detach_Emergency_EmergencyTeamAndTrain)); @@ -39701,6 +39931,19 @@ namespace Model } } + [global::System.Data.Linq.Mapping.AssociationAttribute(Name="FK_DriverSub_DriverSubPlan_Base_Unit", Storage="_DriverSub_DriverSubPlan", ThisKey="UnitId", OtherKey="SubUnitId", DeleteRule="NO ACTION")] + public EntitySet DriverSub_DriverSubPlan + { + get + { + return this._DriverSub_DriverSubPlan; + } + set + { + this._DriverSub_DriverSubPlan.Assign(value); + } + } + [global::System.Data.Linq.Mapping.AssociationAttribute(Name="FK_Emergency_EmergencyList_Base_Unit", Storage="_Emergency_EmergencyList", ThisKey="UnitId", OtherKey="UnitId", DeleteRule="NO ACTION")] public EntitySet Emergency_EmergencyList { @@ -41938,6 +42181,18 @@ namespace Model entity.Base_Unit = null; } + private void attach_DriverSub_DriverSubPlan(DriverSub_DriverSubPlan entity) + { + this.SendPropertyChanging(); + entity.Base_Unit = this; + } + + private void detach_DriverSub_DriverSubPlan(DriverSub_DriverSubPlan entity) + { + this.SendPropertyChanging(); + entity.Base_Unit = null; + } + private void attach_Emergency_EmergencyList(Emergency_EmergencyList entity) { this.SendPropertyChanging(); @@ -60117,8 +60372,6 @@ namespace Model private string _CheckItemSetId; - private string _ReceiveMan; - private string _ResponsibleUnit; private string _WorkAreaId; @@ -60127,6 +60380,8 @@ namespace Model private string _ResponsibleMan; + private string _ReceiveMan; + private EntityRef _Base_Project; private EntityRef _Technique_CheckItemSet; @@ -60167,8 +60422,6 @@ namespace Model partial void OnPartInPersonNamesChanged(); partial void OnCheckItemSetIdChanging(string value); partial void OnCheckItemSetIdChanged(); - partial void OnReceiveManChanging(string value); - partial void OnReceiveManChanged(); partial void OnResponsibleUnitChanging(string value); partial void OnResponsibleUnitChanged(); partial void OnWorkAreaIdChanging(string value); @@ -60177,6 +60430,8 @@ namespace Model partial void OnQuestionTypeChanged(); partial void OnResponsibleManChanging(string value); partial void OnResponsibleManChanged(); + partial void OnReceiveManChanging(string value); + partial void OnReceiveManChanged(); #endregion public Check_CheckSpecial() @@ -60514,26 +60769,6 @@ namespace Model } } - [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ReceiveMan", DbType="NVarChar(2000)")] - public string ReceiveMan - { - get - { - return this._ReceiveMan; - } - set - { - if ((this._ReceiveMan != value)) - { - this.OnReceiveManChanging(value); - this.SendPropertyChanging(); - this._ReceiveMan = value; - this.SendPropertyChanged("ReceiveMan"); - this.OnReceiveManChanged(); - } - } - } - [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ResponsibleUnit", DbType="NVarChar(50)")] public string ResponsibleUnit { @@ -60614,6 +60849,26 @@ namespace Model } } + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ReceiveMan", DbType="NVarChar(2000)")] + public string ReceiveMan + { + get + { + return this._ReceiveMan; + } + set + { + if ((this._ReceiveMan != value)) + { + this.OnReceiveManChanging(value); + this.SendPropertyChanging(); + this._ReceiveMan = value; + this.SendPropertyChanged("ReceiveMan"); + this.OnReceiveManChanged(); + } + } + } + [global::System.Data.Linq.Mapping.AssociationAttribute(Name="FK_Check_CheckSpecial_Base_Project", Storage="_Base_Project", ThisKey="ProjectId", OtherKey="ProjectId", IsForeignKey=true)] public Base_Project Base_Project { @@ -111341,8 +111596,6 @@ namespace Model private string _States; - private System.Nullable _SgCount; - private System.Nullable _OutDay; private System.Nullable _Workloads; @@ -111351,6 +111604,8 @@ namespace Model private string _ScorMan; + private System.Nullable _SgCount; + #region 鍙墿灞曟ф柟娉曞畾涔 partial void OnLoaded(); partial void OnValidate(System.Data.Linq.ChangeAction action); @@ -111377,8 +111632,6 @@ namespace Model partial void OnCreateDateMonthChanged(); partial void OnStatesChanging(string value); partial void OnStatesChanged(); - partial void OnSgCountChanging(System.Nullable value); - partial void OnSgCountChanged(); partial void OnOutDayChanging(System.Nullable value); partial void OnOutDayChanged(); partial void OnWorkloadsChanging(System.Nullable value); @@ -111387,6 +111640,8 @@ namespace Model partial void OnWorkRangeChanged(); partial void OnScorManChanging(string value); partial void OnScorManChanged(); + partial void OnSgCountChanging(System.Nullable value); + partial void OnSgCountChanged(); #endregion public CQMS_Performance() @@ -111614,26 +111869,6 @@ namespace Model } } - [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_SgCount", DbType="Int")] - public System.Nullable SgCount - { - get - { - return this._SgCount; - } - set - { - if ((this._SgCount != value)) - { - this.OnSgCountChanging(value); - this.SendPropertyChanging(); - this._SgCount = value; - this.SendPropertyChanged("SgCount"); - this.OnSgCountChanged(); - } - } - } - [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_OutDay", DbType="Int")] public System.Nullable OutDay { @@ -111714,6 +111949,26 @@ namespace Model } } + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_SgCount", DbType="Int")] + public System.Nullable SgCount + { + get + { + return this._SgCount; + } + set + { + if ((this._SgCount != value)) + { + this.OnSgCountChanging(value); + this.SendPropertyChanging(); + this._SgCount = value; + this.SendPropertyChanged("SgCount"); + this.OnSgCountChanged(); + } + } + } + public event PropertyChangingEventHandler PropertyChanging; public event PropertyChangedEventHandler PropertyChanged; @@ -129485,6 +129740,10 @@ namespace Model private string _DriverSubNames; + private EntityRef _Base_Project; + + private EntityRef _Base_Unit; + #region 鍙墿灞曟ф柟娉曞畾涔 partial void OnLoaded(); partial void OnValidate(System.Data.Linq.ChangeAction action); @@ -129519,10 +129778,12 @@ namespace Model public DriverSub_DriverSubPlan() { + this._Base_Project = default(EntityRef); + this._Base_Unit = default(EntityRef); OnCreated(); } - [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_DriverSubPlanId", DbType="NVarChar(36) NOT NULL", CanBeNull=false, IsPrimaryKey=true)] + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_DriverSubPlanId", DbType="NVarChar(50) NOT NULL", CanBeNull=false, IsPrimaryKey=true)] public string DriverSubPlanId { get @@ -129542,7 +129803,7 @@ namespace Model } } - [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ProjectId", DbType="NVarChar(36)")] + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ProjectId", DbType="NVarChar(50)")] public string ProjectId { get @@ -129553,6 +129814,10 @@ namespace Model { if ((this._ProjectId != value)) { + if (this._Base_Project.HasLoadedOrAssignedValue) + { + throw new System.Data.Linq.ForeignKeyReferenceAlreadyHasValueException(); + } this.OnProjectIdChanging(value); this.SendPropertyChanging(); this._ProjectId = value; @@ -129562,7 +129827,7 @@ namespace Model } } - [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Code", DbType="NVarChar(36)")] + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Code", DbType="NVarChar(50)")] public string Code { get @@ -129582,7 +129847,7 @@ namespace Model } } - [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_SubUnitId", DbType="NVarChar(36)")] + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_SubUnitId", DbType="NVarChar(50)")] public string SubUnitId { get @@ -129593,6 +129858,10 @@ namespace Model { if ((this._SubUnitId != value)) { + if (this._Base_Unit.HasLoadedOrAssignedValue) + { + throw new System.Data.Linq.ForeignKeyReferenceAlreadyHasValueException(); + } this.OnSubUnitIdChanging(value); this.SendPropertyChanging(); this._SubUnitId = value; @@ -129602,7 +129871,7 @@ namespace Model } } - [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Introductions", DbType="NVarChar(2000)")] + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Introductions", DbType="NVarChar(1000)")] public string Introductions { get @@ -129622,7 +129891,7 @@ namespace Model } } - [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Achievement", DbType="NVarChar(2000)")] + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Achievement", DbType="NVarChar(1000)")] public string Achievement { get @@ -129642,7 +129911,7 @@ namespace Model } } - [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Cooperation", DbType="NVarChar(2000)")] + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Cooperation", DbType="NVarChar(1000)")] public string Cooperation { get @@ -129782,6 +130051,74 @@ namespace Model } } + [global::System.Data.Linq.Mapping.AssociationAttribute(Name="FK_DriverSub_DriverSubPlan_Base_Project", Storage="_Base_Project", ThisKey="ProjectId", OtherKey="ProjectId", IsForeignKey=true)] + public Base_Project Base_Project + { + get + { + return this._Base_Project.Entity; + } + set + { + Base_Project previousValue = this._Base_Project.Entity; + if (((previousValue != value) + || (this._Base_Project.HasLoadedOrAssignedValue == false))) + { + this.SendPropertyChanging(); + if ((previousValue != null)) + { + this._Base_Project.Entity = null; + previousValue.DriverSub_DriverSubPlan.Remove(this); + } + this._Base_Project.Entity = value; + if ((value != null)) + { + value.DriverSub_DriverSubPlan.Add(this); + this._ProjectId = value.ProjectId; + } + else + { + this._ProjectId = default(string); + } + this.SendPropertyChanged("Base_Project"); + } + } + } + + [global::System.Data.Linq.Mapping.AssociationAttribute(Name="FK_DriverSub_DriverSubPlan_Base_Unit", Storage="_Base_Unit", ThisKey="SubUnitId", OtherKey="UnitId", IsForeignKey=true)] + public Base_Unit Base_Unit + { + get + { + return this._Base_Unit.Entity; + } + set + { + Base_Unit previousValue = this._Base_Unit.Entity; + if (((previousValue != value) + || (this._Base_Unit.HasLoadedOrAssignedValue == false))) + { + this.SendPropertyChanging(); + if ((previousValue != null)) + { + this._Base_Unit.Entity = null; + previousValue.DriverSub_DriverSubPlan.Remove(this); + } + this._Base_Unit.Entity = value; + if ((value != null)) + { + value.DriverSub_DriverSubPlan.Add(this); + this._SubUnitId = value.UnitId; + } + else + { + this._SubUnitId = default(string); + } + this.SendPropertyChanged("Base_Unit"); + } + } + } + public event PropertyChangingEventHandler PropertyChanging; public event PropertyChangedEventHandler PropertyChanged; @@ -264679,6 +265016,8 @@ namespace Model private System.Nullable _ProblemType; + private string _SubInspectId; + private string _TermItemId; private string _WorkPackId; @@ -264691,20 +265030,18 @@ namespace Model private string _InspectUser; + private string _HandleUser; + private string _ApproveUser; + private System.Nullable _AdjustCompleteTime; + private System.Nullable _ApproveState; private string _AddUser; private System.Nullable _AddTime; - private string _SubInspectId; - - private string _HandleUser; - - private System.Nullable _AdjustCompleteTime; - #region 鍙墿灞曟ф柟娉曞畾涔 partial void OnLoaded(); partial void OnValidate(System.Data.Linq.ChangeAction action); @@ -264721,6 +265058,8 @@ namespace Model partial void OnConstructionUnitChanged(); partial void OnProblemTypeChanging(System.Nullable value); partial void OnProblemTypeChanged(); + partial void OnSubInspectIdChanging(string value); + partial void OnSubInspectIdChanged(); partial void OnTermItemIdChanging(string value); partial void OnTermItemIdChanged(); partial void OnWorkPackIdChanging(string value); @@ -264733,20 +265072,18 @@ namespace Model partial void OnRectifyTimeChanged(); partial void OnInspectUserChanging(string value); partial void OnInspectUserChanged(); + partial void OnHandleUserChanging(string value); + partial void OnHandleUserChanged(); partial void OnApproveUserChanging(string value); partial void OnApproveUserChanged(); + partial void OnAdjustCompleteTimeChanging(System.Nullable value); + partial void OnAdjustCompleteTimeChanged(); partial void OnApproveStateChanging(System.Nullable value); partial void OnApproveStateChanged(); partial void OnAddUserChanging(string value); partial void OnAddUserChanged(); partial void OnAddTimeChanging(System.Nullable value); partial void OnAddTimeChanged(); - partial void OnSubInspectIdChanging(string value); - partial void OnSubInspectIdChanged(); - partial void OnHandleUserChanging(string value); - partial void OnHandleUserChanged(); - partial void OnAdjustCompleteTimeChanging(System.Nullable value); - partial void OnAdjustCompleteTimeChanged(); #endregion public PreRun_InspectTailTerm() @@ -264874,6 +265211,26 @@ namespace Model } } + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_SubInspectId", DbType="VarChar(50)")] + public string SubInspectId + { + get + { + return this._SubInspectId; + } + set + { + if ((this._SubInspectId != value)) + { + this.OnSubInspectIdChanging(value); + this.SendPropertyChanging(); + this._SubInspectId = value; + this.SendPropertyChanged("SubInspectId"); + this.OnSubInspectIdChanged(); + } + } + } + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_TermItemId", DbType="VarChar(50)")] public string TermItemId { @@ -264994,6 +265351,26 @@ namespace Model } } + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_HandleUser", DbType="VarChar(50)")] + public string HandleUser + { + get + { + return this._HandleUser; + } + set + { + if ((this._HandleUser != value)) + { + this.OnHandleUserChanging(value); + this.SendPropertyChanging(); + this._HandleUser = value; + this.SendPropertyChanged("HandleUser"); + this.OnHandleUserChanged(); + } + } + } + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ApproveUser", DbType="VarChar(50)")] public string ApproveUser { @@ -265014,6 +265391,26 @@ namespace Model } } + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_AdjustCompleteTime", DbType="DateTime")] + public System.Nullable AdjustCompleteTime + { + get + { + return this._AdjustCompleteTime; + } + set + { + if ((this._AdjustCompleteTime != value)) + { + this.OnAdjustCompleteTimeChanging(value); + this.SendPropertyChanging(); + this._AdjustCompleteTime = value; + this.SendPropertyChanged("AdjustCompleteTime"); + this.OnAdjustCompleteTimeChanged(); + } + } + } + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ApproveState", DbType="Int")] public System.Nullable ApproveState { @@ -265074,66 +265471,6 @@ namespace Model } } - [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_SubInspectId", DbType="VarChar(50)")] - public string SubInspectId - { - get - { - return this._SubInspectId; - } - set - { - if ((this._SubInspectId != value)) - { - this.OnSubInspectIdChanging(value); - this.SendPropertyChanging(); - this._SubInspectId = value; - this.SendPropertyChanged("SubInspectId"); - this.OnSubInspectIdChanged(); - } - } - } - - [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_HandleUser", DbType="VarChar(50)")] - public string HandleUser - { - get - { - return this._HandleUser; - } - set - { - if ((this._HandleUser != value)) - { - this.OnHandleUserChanging(value); - this.SendPropertyChanging(); - this._HandleUser = value; - this.SendPropertyChanged("HandleUser"); - this.OnHandleUserChanged(); - } - } - } - - [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_AdjustCompleteTime", DbType="DateTime")] - public System.Nullable AdjustCompleteTime - { - get - { - return this._AdjustCompleteTime; - } - set - { - if ((this._AdjustCompleteTime != value)) - { - this.OnAdjustCompleteTimeChanging(value); - this.SendPropertyChanging(); - this._AdjustCompleteTime = value; - this.SendPropertyChanged("AdjustCompleteTime"); - this.OnAdjustCompleteTimeChanged(); - } - } - } - public event PropertyChangingEventHandler PropertyChanging; public event PropertyChangedEventHandler PropertyChanged; @@ -265175,14 +265512,14 @@ namespace Model private string _ApproveUser; + private System.Nullable _ApproveType; + private System.Nullable _ApproveState; private string _AddUser; private System.Nullable _AddTime; - private System.Nullable _ApproveType; - #region 鍙墿灞曟ф柟娉曞畾涔 partial void OnLoaded(); partial void OnValidate(System.Data.Linq.ChangeAction action); @@ -265201,14 +265538,14 @@ namespace Model partial void OnApproveTimeChanged(); partial void OnApproveUserChanging(string value); partial void OnApproveUserChanged(); + partial void OnApproveTypeChanging(System.Nullable value); + partial void OnApproveTypeChanged(); partial void OnApproveStateChanging(System.Nullable value); partial void OnApproveStateChanged(); partial void OnAddUserChanging(string value); partial void OnAddUserChanged(); partial void OnAddTimeChanging(System.Nullable value); partial void OnAddTimeChanged(); - partial void OnApproveTypeChanging(System.Nullable value); - partial void OnApproveTypeChanged(); #endregion public PreRun_InspectTermApproveRecords() @@ -265356,6 +265693,26 @@ namespace Model } } + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ApproveType", DbType="Int")] + public System.Nullable ApproveType + { + get + { + return this._ApproveType; + } + set + { + if ((this._ApproveType != value)) + { + this.OnApproveTypeChanging(value); + this.SendPropertyChanging(); + this._ApproveType = value; + this.SendPropertyChanged("ApproveType"); + this.OnApproveTypeChanged(); + } + } + } + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ApproveState", DbType="Int")] public System.Nullable ApproveState { @@ -265416,26 +265773,6 @@ namespace Model } } - [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ApproveType", DbType="Int")] - public System.Nullable ApproveType - { - get - { - return this._ApproveType; - } - set - { - if ((this._ApproveType != value)) - { - this.OnApproveTypeChanging(value); - this.SendPropertyChanging(); - this._ApproveType = value; - this.SendPropertyChanged("ApproveType"); - this.OnApproveTypeChanged(); - } - } - } - public event PropertyChangingEventHandler PropertyChanging; public event PropertyChangedEventHandler PropertyChanged; @@ -266368,7 +266705,7 @@ namespace Model } } - [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Remark", DbType="VarChar(MAX)", UpdateCheck=UpdateCheck.Never)] + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Remark", DbType="NVarChar(MAX)", UpdateCheck=UpdateCheck.Never)] public string Remark { get @@ -266491,12 +266828,6 @@ namespace Model private string _InspectResult; - private System.Nullable _InspectTime; - - private string _AddUser; - - private System.Nullable _AddTime; - private string _Subcontractor; private string _Contractor; @@ -266505,10 +266836,6 @@ namespace Model private string _Owner; - private System.Nullable _WorkPackType; - - private string _PropertyTechnologyId; - private System.Nullable _InspectionIsAllPass; private System.Nullable _SubcontractorIsAllPass; @@ -266519,6 +266846,10 @@ namespace Model private System.Nullable _OwnerIsAllPass; + private System.Nullable _WorkPackType; + + private string _PropertyTechnologyId; + private System.Nullable _SubcontractorAllPassData; private System.Nullable _ContractorAllPassData; @@ -266551,6 +266882,12 @@ namespace Model private string _UnifyWanderAboutOpinion; + private System.Nullable _InspectTime; + + private string _AddUser; + + private System.Nullable _AddTime; + #region 鍙墿灞曟ф柟娉曞畾涔 partial void OnLoaded(); partial void OnValidate(System.Data.Linq.ChangeAction action); @@ -266571,12 +266908,6 @@ namespace Model partial void OnWorkPackIdChanged(); partial void OnInspectResultChanging(string value); partial void OnInspectResultChanged(); - partial void OnInspectTimeChanging(System.Nullable value); - partial void OnInspectTimeChanged(); - partial void OnAddUserChanging(string value); - partial void OnAddUserChanged(); - partial void OnAddTimeChanging(System.Nullable value); - partial void OnAddTimeChanged(); partial void OnSubcontractorChanging(string value); partial void OnSubcontractorChanged(); partial void OnContractorChanging(string value); @@ -266585,10 +266916,6 @@ namespace Model partial void OnSupervisionChanged(); partial void OnOwnerChanging(string value); partial void OnOwnerChanged(); - partial void OnWorkPackTypeChanging(System.Nullable value); - partial void OnWorkPackTypeChanged(); - partial void OnPropertyTechnologyIdChanging(string value); - partial void OnPropertyTechnologyIdChanged(); partial void OnInspectionIsAllPassChanging(System.Nullable value); partial void OnInspectionIsAllPassChanged(); partial void OnSubcontractorIsAllPassChanging(System.Nullable value); @@ -266599,6 +266926,10 @@ namespace Model partial void OnSupervisionIsAllPassChanged(); partial void OnOwnerIsAllPassChanging(System.Nullable value); partial void OnOwnerIsAllPassChanged(); + partial void OnWorkPackTypeChanging(System.Nullable value); + partial void OnWorkPackTypeChanged(); + partial void OnPropertyTechnologyIdChanging(string value); + partial void OnPropertyTechnologyIdChanged(); partial void OnSubcontractorAllPassDataChanging(System.Nullable value); partial void OnSubcontractorAllPassDataChanged(); partial void OnContractorAllPassDataChanging(System.Nullable value); @@ -266631,6 +266962,12 @@ namespace Model partial void OnUnifyWanderAboutDataChanged(); partial void OnUnifyWanderAboutOpinionChanging(string value); partial void OnUnifyWanderAboutOpinionChanged(); + partial void OnInspectTimeChanging(System.Nullable value); + partial void OnInspectTimeChanged(); + partial void OnAddUserChanging(string value); + partial void OnAddUserChanged(); + partial void OnAddTimeChanging(System.Nullable value); + partial void OnAddTimeChanged(); #endregion public PreRun_SubInspectTerm() @@ -266798,66 +267135,6 @@ namespace Model } } - [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_InspectTime", DbType="DateTime")] - public System.Nullable InspectTime - { - get - { - return this._InspectTime; - } - set - { - if ((this._InspectTime != value)) - { - this.OnInspectTimeChanging(value); - this.SendPropertyChanging(); - this._InspectTime = value; - this.SendPropertyChanged("InspectTime"); - this.OnInspectTimeChanged(); - } - } - } - - [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_AddUser", DbType="VarChar(50)")] - public string AddUser - { - get - { - return this._AddUser; - } - set - { - if ((this._AddUser != value)) - { - this.OnAddUserChanging(value); - this.SendPropertyChanging(); - this._AddUser = value; - this.SendPropertyChanged("AddUser"); - this.OnAddUserChanged(); - } - } - } - - [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_AddTime", DbType="DateTime")] - public System.Nullable AddTime - { - get - { - return this._AddTime; - } - set - { - if ((this._AddTime != value)) - { - this.OnAddTimeChanging(value); - this.SendPropertyChanging(); - this._AddTime = value; - this.SendPropertyChanged("AddTime"); - this.OnAddTimeChanged(); - } - } - } - [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Subcontractor", DbType="VarChar(50)")] public string Subcontractor { @@ -266938,46 +267215,6 @@ namespace Model } } - [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_WorkPackType", DbType="Int")] - public System.Nullable WorkPackType - { - get - { - return this._WorkPackType; - } - set - { - if ((this._WorkPackType != value)) - { - this.OnWorkPackTypeChanging(value); - this.SendPropertyChanging(); - this._WorkPackType = value; - this.SendPropertyChanged("WorkPackType"); - this.OnWorkPackTypeChanged(); - } - } - } - - [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_PropertyTechnologyId", DbType="VarChar(MAX)", UpdateCheck=UpdateCheck.Never)] - public string PropertyTechnologyId - { - get - { - return this._PropertyTechnologyId; - } - set - { - if ((this._PropertyTechnologyId != value)) - { - this.OnPropertyTechnologyIdChanging(value); - this.SendPropertyChanging(); - this._PropertyTechnologyId = value; - this.SendPropertyChanged("PropertyTechnologyId"); - this.OnPropertyTechnologyIdChanged(); - } - } - } - [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_InspectionIsAllPass", DbType="Int")] public System.Nullable InspectionIsAllPass { @@ -267078,6 +267315,46 @@ namespace Model } } + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_WorkPackType", DbType="Int")] + public System.Nullable WorkPackType + { + get + { + return this._WorkPackType; + } + set + { + if ((this._WorkPackType != value)) + { + this.OnWorkPackTypeChanging(value); + this.SendPropertyChanging(); + this._WorkPackType = value; + this.SendPropertyChanged("WorkPackType"); + this.OnWorkPackTypeChanged(); + } + } + } + + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_PropertyTechnologyId", DbType="VarChar(MAX)", UpdateCheck=UpdateCheck.Never)] + public string PropertyTechnologyId + { + get + { + return this._PropertyTechnologyId; + } + set + { + if ((this._PropertyTechnologyId != value)) + { + this.OnPropertyTechnologyIdChanging(value); + this.SendPropertyChanging(); + this._PropertyTechnologyId = value; + this.SendPropertyChanged("PropertyTechnologyId"); + this.OnPropertyTechnologyIdChanged(); + } + } + } + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_SubcontractorAllPassData", DbType="DateTime")] public System.Nullable SubcontractorAllPassData { @@ -267398,6 +267675,66 @@ namespace Model } } + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_InspectTime", DbType="DateTime")] + public System.Nullable InspectTime + { + get + { + return this._InspectTime; + } + set + { + if ((this._InspectTime != value)) + { + this.OnInspectTimeChanging(value); + this.SendPropertyChanging(); + this._InspectTime = value; + this.SendPropertyChanged("InspectTime"); + this.OnInspectTimeChanged(); + } + } + } + + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_AddUser", DbType="VarChar(50)")] + public string AddUser + { + get + { + return this._AddUser; + } + set + { + if ((this._AddUser != value)) + { + this.OnAddUserChanging(value); + this.SendPropertyChanging(); + this._AddUser = value; + this.SendPropertyChanged("AddUser"); + this.OnAddUserChanged(); + } + } + } + + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_AddTime", DbType="DateTime")] + public System.Nullable AddTime + { + get + { + return this._AddTime; + } + set + { + if ((this._AddTime != value)) + { + this.OnAddTimeChanging(value); + this.SendPropertyChanging(); + this._AddTime = value; + this.SendPropertyChanged("AddTime"); + this.OnAddTimeChanged(); + } + } + } + public event PropertyChangingEventHandler PropertyChanging; public event PropertyChangedEventHandler PropertyChanged; @@ -267461,18 +267798,6 @@ namespace Model private string _Owner; - private System.Nullable _WorkPackType; - - private string _PropertyTechnologyId; - - private string _Remark; - - private string _AddUser; - - private System.Nullable _AddTime; - - private System.Nullable _Sort; - private System.Nullable _SubcontractorIsPass; private System.Nullable _ContractorIsPass; @@ -267489,6 +267814,18 @@ namespace Model private string _OwnerRemark; + private System.Nullable _WorkPackType; + + private string _PropertyTechnologyId; + + private string _Remark; + + private string _AddUser; + + private System.Nullable _AddTime; + + private System.Nullable _Sort; + #region 鍙墿灞曟ф柟娉曞畾涔 partial void OnLoaded(); partial void OnValidate(System.Data.Linq.ChangeAction action); @@ -267529,18 +267866,6 @@ namespace Model partial void OnSupervisionChanged(); partial void OnOwnerChanging(string value); partial void OnOwnerChanged(); - partial void OnWorkPackTypeChanging(System.Nullable value); - partial void OnWorkPackTypeChanged(); - partial void OnPropertyTechnologyIdChanging(string value); - partial void OnPropertyTechnologyIdChanged(); - partial void OnRemarkChanging(string value); - partial void OnRemarkChanged(); - partial void OnAddUserChanging(string value); - partial void OnAddUserChanged(); - partial void OnAddTimeChanging(System.Nullable value); - partial void OnAddTimeChanged(); - partial void OnSortChanging(System.Nullable value); - partial void OnSortChanged(); partial void OnSubcontractorIsPassChanging(System.Nullable value); partial void OnSubcontractorIsPassChanged(); partial void OnContractorIsPassChanging(System.Nullable value); @@ -267557,6 +267882,18 @@ namespace Model partial void OnSupervisionRemarkChanged(); partial void OnOwnerRemarkChanging(string value); partial void OnOwnerRemarkChanged(); + partial void OnWorkPackTypeChanging(System.Nullable value); + partial void OnWorkPackTypeChanged(); + partial void OnPropertyTechnologyIdChanging(string value); + partial void OnPropertyTechnologyIdChanged(); + partial void OnRemarkChanging(string value); + partial void OnRemarkChanged(); + partial void OnAddUserChanging(string value); + partial void OnAddUserChanged(); + partial void OnAddTimeChanging(System.Nullable value); + partial void OnAddTimeChanged(); + partial void OnSortChanging(System.Nullable value); + partial void OnSortChanged(); #endregion public PreRun_SubInspectTermItem() @@ -267924,126 +268261,6 @@ namespace Model } } - [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_WorkPackType", DbType="Int")] - public System.Nullable WorkPackType - { - get - { - return this._WorkPackType; - } - set - { - if ((this._WorkPackType != value)) - { - this.OnWorkPackTypeChanging(value); - this.SendPropertyChanging(); - this._WorkPackType = value; - this.SendPropertyChanged("WorkPackType"); - this.OnWorkPackTypeChanged(); - } - } - } - - [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_PropertyTechnologyId", DbType="VarChar(MAX)", UpdateCheck=UpdateCheck.Never)] - public string PropertyTechnologyId - { - get - { - return this._PropertyTechnologyId; - } - set - { - if ((this._PropertyTechnologyId != value)) - { - this.OnPropertyTechnologyIdChanging(value); - this.SendPropertyChanging(); - this._PropertyTechnologyId = value; - this.SendPropertyChanged("PropertyTechnologyId"); - this.OnPropertyTechnologyIdChanged(); - } - } - } - - [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Remark", DbType="VarChar(200)")] - public string Remark - { - get - { - return this._Remark; - } - set - { - if ((this._Remark != value)) - { - this.OnRemarkChanging(value); - this.SendPropertyChanging(); - this._Remark = value; - this.SendPropertyChanged("Remark"); - this.OnRemarkChanged(); - } - } - } - - [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_AddUser", DbType="VarChar(50)")] - public string AddUser - { - get - { - return this._AddUser; - } - set - { - if ((this._AddUser != value)) - { - this.OnAddUserChanging(value); - this.SendPropertyChanging(); - this._AddUser = value; - this.SendPropertyChanged("AddUser"); - this.OnAddUserChanged(); - } - } - } - - [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_AddTime", DbType="DateTime")] - public System.Nullable AddTime - { - get - { - return this._AddTime; - } - set - { - if ((this._AddTime != value)) - { - this.OnAddTimeChanging(value); - this.SendPropertyChanging(); - this._AddTime = value; - this.SendPropertyChanged("AddTime"); - this.OnAddTimeChanged(); - } - } - } - - [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Sort", DbType="Int")] - public System.Nullable Sort - { - get - { - return this._Sort; - } - set - { - if ((this._Sort != value)) - { - this.OnSortChanging(value); - this.SendPropertyChanging(); - this._Sort = value; - this.SendPropertyChanged("Sort"); - this.OnSortChanged(); - } - } - } - [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_SubcontractorIsPass", DbType="Int")] public System.Nullable SubcontractorIsPass { @@ -268204,6 +268421,126 @@ namespace Model } } + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_WorkPackType", DbType="Int")] + public System.Nullable WorkPackType + { + get + { + return this._WorkPackType; + } + set + { + if ((this._WorkPackType != value)) + { + this.OnWorkPackTypeChanging(value); + this.SendPropertyChanging(); + this._WorkPackType = value; + this.SendPropertyChanged("WorkPackType"); + this.OnWorkPackTypeChanged(); + } + } + } + + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_PropertyTechnologyId", DbType="VarChar(MAX)", UpdateCheck=UpdateCheck.Never)] + public string PropertyTechnologyId + { + get + { + return this._PropertyTechnologyId; + } + set + { + if ((this._PropertyTechnologyId != value)) + { + this.OnPropertyTechnologyIdChanging(value); + this.SendPropertyChanging(); + this._PropertyTechnologyId = value; + this.SendPropertyChanged("PropertyTechnologyId"); + this.OnPropertyTechnologyIdChanged(); + } + } + } + + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Remark", DbType="VarChar(200)")] + public string Remark + { + get + { + return this._Remark; + } + set + { + if ((this._Remark != value)) + { + this.OnRemarkChanging(value); + this.SendPropertyChanging(); + this._Remark = value; + this.SendPropertyChanged("Remark"); + this.OnRemarkChanged(); + } + } + } + + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_AddUser", DbType="VarChar(50)")] + public string AddUser + { + get + { + return this._AddUser; + } + set + { + if ((this._AddUser != value)) + { + this.OnAddUserChanging(value); + this.SendPropertyChanging(); + this._AddUser = value; + this.SendPropertyChanged("AddUser"); + this.OnAddUserChanged(); + } + } + } + + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_AddTime", DbType="DateTime")] + public System.Nullable AddTime + { + get + { + return this._AddTime; + } + set + { + if ((this._AddTime != value)) + { + this.OnAddTimeChanging(value); + this.SendPropertyChanging(); + this._AddTime = value; + this.SendPropertyChanged("AddTime"); + this.OnAddTimeChanged(); + } + } + } + + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Sort", DbType="Int")] + public System.Nullable Sort + { + get + { + return this._Sort; + } + set + { + if ((this._Sort != value)) + { + this.OnSortChanging(value); + this.SendPropertyChanging(); + this._Sort = value; + this.SendPropertyChanged("Sort"); + this.OnSortChanged(); + } + } + } + public event PropertyChangingEventHandler PropertyChanging; public event PropertyChangedEventHandler PropertyChanged; @@ -269205,6 +269542,8 @@ namespace Model private string _RestrictCondition; + private System.Nullable _ResponsibilityProposeSatate; + private System.Nullable _ResponsibilityConfirm; private System.Nullable _ProposeConfirm; @@ -269215,9 +269554,11 @@ namespace Model private System.Nullable _OwnerConfirm; + private System.Nullable _ProposeConfirmData; + private System.Nullable _ResponsibilityConfirmData; - private System.Nullable _ProposeConfirmData; + private System.Nullable _ProposeHandleData; private System.Nullable _GeneraConfirmData; @@ -269233,10 +269574,6 @@ namespace Model private System.Nullable _Sort; - private System.Nullable _ResponsibilityProposeSatate; - - private System.Nullable _ProposeHandleData; - private string _FourDecisionCode; #region 鍙墿灞曟ф柟娉曞畾涔 @@ -269273,6 +269610,8 @@ namespace Model partial void OnRealityDestructionTimeChanged(); partial void OnRestrictConditionChanging(string value); partial void OnRestrictConditionChanged(); + partial void OnResponsibilityProposeSatateChanging(System.Nullable value); + partial void OnResponsibilityProposeSatateChanged(); partial void OnResponsibilityConfirmChanging(System.Nullable value); partial void OnResponsibilityConfirmChanged(); partial void OnProposeConfirmChanging(System.Nullable value); @@ -269283,10 +269622,12 @@ namespace Model partial void OnSupervisionConfirmChanged(); partial void OnOwnerConfirmChanging(System.Nullable value); partial void OnOwnerConfirmChanged(); - partial void OnResponsibilityConfirmDataChanging(System.Nullable value); - partial void OnResponsibilityConfirmDataChanged(); partial void OnProposeConfirmDataChanging(System.Nullable value); partial void OnProposeConfirmDataChanged(); + partial void OnResponsibilityConfirmDataChanging(System.Nullable value); + partial void OnResponsibilityConfirmDataChanged(); + partial void OnProposeHandleDataChanging(System.Nullable value); + partial void OnProposeHandleDataChanged(); partial void OnGeneraConfirmDataChanging(System.Nullable value); partial void OnGeneraConfirmDataChanged(); partial void OnSupervisionConfirmDataChanging(System.Nullable value); @@ -269301,10 +269642,6 @@ namespace Model partial void OnAddTimeChanged(); partial void OnSortChanging(System.Nullable value); partial void OnSortChanged(); - partial void OnResponsibilityProposeSatateChanging(System.Nullable value); - partial void OnResponsibilityProposeSatateChanged(); - partial void OnProposeHandleDataChanging(System.Nullable value); - partial void OnProposeHandleDataChanged(); partial void OnFourDecisionCodeChanging(string value); partial void OnFourDecisionCodeChanged(); #endregion @@ -269614,6 +269951,26 @@ namespace Model } } + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ResponsibilityProposeSatate", DbType="Int")] + public System.Nullable ResponsibilityProposeSatate + { + get + { + return this._ResponsibilityProposeSatate; + } + set + { + if ((this._ResponsibilityProposeSatate != value)) + { + this.OnResponsibilityProposeSatateChanging(value); + this.SendPropertyChanging(); + this._ResponsibilityProposeSatate = value; + this.SendPropertyChanged("ResponsibilityProposeSatate"); + this.OnResponsibilityProposeSatateChanged(); + } + } + } + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ResponsibilityConfirm", DbType="Int")] public System.Nullable ResponsibilityConfirm { @@ -269714,6 +270071,26 @@ namespace Model } } + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ProposeConfirmData", DbType="DateTime")] + public System.Nullable ProposeConfirmData + { + get + { + return this._ProposeConfirmData; + } + set + { + if ((this._ProposeConfirmData != value)) + { + this.OnProposeConfirmDataChanging(value); + this.SendPropertyChanging(); + this._ProposeConfirmData = value; + this.SendPropertyChanged("ProposeConfirmData"); + this.OnProposeConfirmDataChanged(); + } + } + } + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ResponsibilityConfirmData", DbType="DateTime")] public System.Nullable ResponsibilityConfirmData { @@ -269734,22 +270111,22 @@ namespace Model } } - [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ProposeConfirmData", DbType="DateTime")] - public System.Nullable ProposeConfirmData + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ProposeHandleData", DbType="DateTime")] + public System.Nullable ProposeHandleData { get { - return this._ProposeConfirmData; + return this._ProposeHandleData; } set { - if ((this._ProposeConfirmData != value)) + if ((this._ProposeHandleData != value)) { - this.OnProposeConfirmDataChanging(value); + this.OnProposeHandleDataChanging(value); this.SendPropertyChanging(); - this._ProposeConfirmData = value; - this.SendPropertyChanged("ProposeConfirmData"); - this.OnProposeConfirmDataChanged(); + this._ProposeHandleData = value; + this.SendPropertyChanged("ProposeHandleData"); + this.OnProposeHandleDataChanged(); } } } @@ -269894,46 +270271,6 @@ namespace Model } } - [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ResponsibilityProposeSatate", DbType="Int")] - public System.Nullable ResponsibilityProposeSatate - { - get - { - return this._ResponsibilityProposeSatate; - } - set - { - if ((this._ResponsibilityProposeSatate != value)) - { - this.OnResponsibilityProposeSatateChanging(value); - this.SendPropertyChanging(); - this._ResponsibilityProposeSatate = value; - this.SendPropertyChanged("ResponsibilityProposeSatate"); - this.OnResponsibilityProposeSatateChanged(); - } - } - } - - [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ProposeHandleData", DbType="DateTime")] - public System.Nullable ProposeHandleData - { - get - { - return this._ProposeHandleData; - } - set - { - if ((this._ProposeHandleData != value)) - { - this.OnProposeHandleDataChanging(value); - this.SendPropertyChanging(); - this._ProposeHandleData = value; - this.SendPropertyChanged("ProposeHandleData"); - this.OnProposeHandleDataChanged(); - } - } - } - [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_FourDecisionCode", DbType="VarChar(20)")] public string FourDecisionCode { @@ -270646,7 +270983,7 @@ namespace Model } } - [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Remark", DbType="VarChar(MAX)", UpdateCheck=UpdateCheck.Never)] + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Remark", DbType="NVarChar(MAX)", UpdateCheck=UpdateCheck.Never)] public string Remark { get @@ -368222,6 +368559,8 @@ namespace Model private string _FINAL_Status; + private System.Nullable _CompleteTime; + #region 鍙墿灞曟ф柟娉曞畾涔 partial void OnLoaded(); partial void OnValidate(System.Data.Linq.ChangeAction action); @@ -368244,6 +368583,8 @@ namespace Model partial void OnTest_Package_FINISHChanged(); partial void OnFINAL_StatusChanging(string value); partial void OnFINAL_StatusChanged(); + partial void OnCompleteTimeChanging(System.Nullable value); + partial void OnCompleteTimeChanged(); #endregion public Transfer_Civil_Structure() @@ -368431,6 +368772,26 @@ namespace Model } } + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_CompleteTime", DbType="DateTime")] + public System.Nullable CompleteTime + { + get + { + return this._CompleteTime; + } + set + { + if ((this._CompleteTime != value)) + { + this.OnCompleteTimeChanging(value); + this.SendPropertyChanging(); + this._CompleteTime = value; + this.SendPropertyChanged("CompleteTime"); + this.OnCompleteTimeChanged(); + } + } + } + public event PropertyChangingEventHandler PropertyChanging; public event PropertyChangedEventHandler PropertyChanged; @@ -368476,6 +368837,8 @@ namespace Model private string _FINAL_Status; + private System.Nullable _CompleteTime; + #region 鍙墿灞曟ф柟娉曞畾涔 partial void OnLoaded(); partial void OnValidate(System.Data.Linq.ChangeAction action); @@ -368498,6 +368861,8 @@ namespace Model partial void OnTest_Package_FINISHChanged(); partial void OnFINAL_StatusChanging(string value); partial void OnFINAL_StatusChanged(); + partial void OnCompleteTimeChanging(System.Nullable value); + partial void OnCompleteTimeChanged(); #endregion public Transfer_Electrical() @@ -368685,6 +369050,26 @@ namespace Model } } + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_CompleteTime", DbType="DateTime")] + public System.Nullable CompleteTime + { + get + { + return this._CompleteTime; + } + set + { + if ((this._CompleteTime != value)) + { + this.OnCompleteTimeChanging(value); + this.SendPropertyChanging(); + this._CompleteTime = value; + this.SendPropertyChanged("CompleteTime"); + this.OnCompleteTimeChanged(); + } + } + } + public event PropertyChangingEventHandler PropertyChanging; public event PropertyChangedEventHandler PropertyChanged; @@ -368730,6 +369115,8 @@ namespace Model private string _FINAL_Status; + private System.Nullable _CompleteTime; + #region 鍙墿灞曟ф柟娉曞畾涔 partial void OnLoaded(); partial void OnValidate(System.Data.Linq.ChangeAction action); @@ -368752,6 +369139,8 @@ namespace Model partial void OnTest_Package_FINISHChanged(); partial void OnFINAL_StatusChanging(string value); partial void OnFINAL_StatusChanged(); + partial void OnCompleteTimeChanging(System.Nullable value); + partial void OnCompleteTimeChanged(); #endregion public Transfer_Firefighting() @@ -368939,6 +369328,26 @@ namespace Model } } + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_CompleteTime", DbType="DateTime")] + public System.Nullable CompleteTime + { + get + { + return this._CompleteTime; + } + set + { + if ((this._CompleteTime != value)) + { + this.OnCompleteTimeChanging(value); + this.SendPropertyChanging(); + this._CompleteTime = value; + this.SendPropertyChanged("CompleteTime"); + this.OnCompleteTimeChanged(); + } + } + } + public event PropertyChangingEventHandler PropertyChanging; public event PropertyChangedEventHandler PropertyChanged; @@ -368984,6 +369393,8 @@ namespace Model private string _FINAL_Status; + private System.Nullable _CompleteTime; + #region 鍙墿灞曟ф柟娉曞畾涔 partial void OnLoaded(); partial void OnValidate(System.Data.Linq.ChangeAction action); @@ -369006,6 +369417,8 @@ namespace Model partial void OnTest_Package_FINISHChanged(); partial void OnFINAL_StatusChanging(string value); partial void OnFINAL_StatusChanged(); + partial void OnCompleteTimeChanging(System.Nullable value); + partial void OnCompleteTimeChanged(); #endregion public Transfer_HVAC() @@ -369193,6 +369606,26 @@ namespace Model } } + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_CompleteTime", DbType="DateTime")] + public System.Nullable CompleteTime + { + get + { + return this._CompleteTime; + } + set + { + if ((this._CompleteTime != value)) + { + this.OnCompleteTimeChanging(value); + this.SendPropertyChanging(); + this._CompleteTime = value; + this.SendPropertyChanged("CompleteTime"); + this.OnCompleteTimeChanged(); + } + } + } + public event PropertyChangingEventHandler PropertyChanging; public event PropertyChangedEventHandler PropertyChanged; @@ -369238,6 +369671,8 @@ namespace Model private string _FINAL_Status; + private System.Nullable _CompleteTime; + #region 鍙墿灞曟ф柟娉曞畾涔 partial void OnLoaded(); partial void OnValidate(System.Data.Linq.ChangeAction action); @@ -369260,6 +369695,8 @@ namespace Model partial void OnTest_Package_FINISHChanged(); partial void OnFINAL_StatusChanging(string value); partial void OnFINAL_StatusChanged(); + partial void OnCompleteTimeChanging(System.Nullable value); + partial void OnCompleteTimeChanged(); #endregion public Transfer_Instrumentation() @@ -369447,6 +369884,26 @@ namespace Model } } + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_CompleteTime", DbType="DateTime")] + public System.Nullable CompleteTime + { + get + { + return this._CompleteTime; + } + set + { + if ((this._CompleteTime != value)) + { + this.OnCompleteTimeChanging(value); + this.SendPropertyChanging(); + this._CompleteTime = value; + this.SendPropertyChanged("CompleteTime"); + this.OnCompleteTimeChanged(); + } + } + } + public event PropertyChangingEventHandler PropertyChanging; public event PropertyChangedEventHandler PropertyChanged; @@ -369496,6 +369953,8 @@ namespace Model private string _FinalTestFINISHED; + private System.Nullable _CompleteTime; + #region 鍙墿灞曟ф柟娉曞畾涔 partial void OnLoaded(); partial void OnValidate(System.Data.Linq.ChangeAction action); @@ -369522,6 +369981,8 @@ namespace Model partial void OnPreTestFINISHEDChanged(); partial void OnFinalTestFINISHEDChanging(string value); partial void OnFinalTestFINISHEDChanged(); + partial void OnCompleteTimeChanging(System.Nullable value); + partial void OnCompleteTimeChanged(); #endregion public Transfer_Piping() @@ -369749,6 +370210,26 @@ namespace Model } } + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_CompleteTime", DbType="DateTime")] + public System.Nullable CompleteTime + { + get + { + return this._CompleteTime; + } + set + { + if ((this._CompleteTime != value)) + { + this.OnCompleteTimeChanging(value); + this.SendPropertyChanging(); + this._CompleteTime = value; + this.SendPropertyChanged("CompleteTime"); + this.OnCompleteTimeChanged(); + } + } + } + public event PropertyChangingEventHandler PropertyChanging; public event PropertyChangedEventHandler PropertyChanged; @@ -369794,6 +370275,8 @@ namespace Model private string _FINAL_Status; + private System.Nullable _CompleteTime; + #region 鍙墿灞曟ф柟娉曞畾涔 partial void OnLoaded(); partial void OnValidate(System.Data.Linq.ChangeAction action); @@ -369816,6 +370299,8 @@ namespace Model partial void OnTest_Package_FINISHChanged(); partial void OnFINAL_StatusChanging(string value); partial void OnFINAL_StatusChanged(); + partial void OnCompleteTimeChanging(System.Nullable value); + partial void OnCompleteTimeChanged(); #endregion public Transfer_Plumbing() @@ -370003,6 +370488,26 @@ namespace Model } } + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_CompleteTime", DbType="DateTime")] + public System.Nullable CompleteTime + { + get + { + return this._CompleteTime; + } + set + { + if ((this._CompleteTime != value)) + { + this.OnCompleteTimeChanging(value); + this.SendPropertyChanging(); + this._CompleteTime = value; + this.SendPropertyChanged("CompleteTime"); + this.OnCompleteTimeChanged(); + } + } + } + public event PropertyChangingEventHandler PropertyChanging; public event PropertyChangedEventHandler PropertyChanged; @@ -370663,7 +371168,7 @@ namespace Model } } - [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_DESCRIPTION", DbType="NVarChar(50)")] + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_DESCRIPTION", DbType="NVarChar(500)")] public string DESCRIPTION { get @@ -370844,6 +371349,562 @@ namespace Model } } + [global::System.Data.Linq.Mapping.TableAttribute(Name="dbo.Transfer_RotatingEquipment")] + public partial class Transfer_RotatingEquipment : INotifyPropertyChanging, INotifyPropertyChanged + { + + private static PropertyChangingEventArgs emptyChangingEventArgs = new PropertyChangingEventArgs(String.Empty); + + private string _Id; + + private string _ProjectId; + + private string _RotatingEquipment; + + private string _SYSTEM; + + private string _Subsystem; + + private string _TestPackage; + + private System.Nullable _TestPackageSTART; + + private System.Nullable _TestPackageFINISH; + + private string _MechanicalFINALStatus; + + private System.Nullable _CompleteTime; + + #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 OnRotatingEquipmentChanging(string value); + partial void OnRotatingEquipmentChanged(); + 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 OnMechanicalFINALStatusChanging(string value); + partial void OnMechanicalFINALStatusChanged(); + partial void OnCompleteTimeChanging(System.Nullable value); + partial void OnCompleteTimeChanged(); + #endregion + + public Transfer_RotatingEquipment() + { + 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="_RotatingEquipment", DbType="NVarChar(50)")] + public string RotatingEquipment + { + get + { + return this._RotatingEquipment; + } + set + { + if ((this._RotatingEquipment != value)) + { + this.OnRotatingEquipmentChanging(value); + this.SendPropertyChanging(); + this._RotatingEquipment = value; + this.SendPropertyChanged("RotatingEquipment"); + this.OnRotatingEquipmentChanged(); + } + } + } + + [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="_MechanicalFINALStatus", DbType="NVarChar(50)")] + public string MechanicalFINALStatus + { + get + { + return this._MechanicalFINALStatus; + } + set + { + if ((this._MechanicalFINALStatus != value)) + { + this.OnMechanicalFINALStatusChanging(value); + this.SendPropertyChanging(); + this._MechanicalFINALStatus = value; + this.SendPropertyChanged("MechanicalFINALStatus"); + this.OnMechanicalFINALStatusChanged(); + } + } + } + + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_CompleteTime", DbType="DateTime")] + public System.Nullable CompleteTime + { + get + { + return this._CompleteTime; + } + set + { + if ((this._CompleteTime != value)) + { + this.OnCompleteTimeChanging(value); + this.SendPropertyChanging(); + this._CompleteTime = value; + this.SendPropertyChanged("CompleteTime"); + this.OnCompleteTimeChanged(); + } + } + } + + 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_StaticEquipment")] + public partial class Transfer_StaticEquipment : INotifyPropertyChanging, INotifyPropertyChanged + { + + private static PropertyChangingEventArgs emptyChangingEventArgs = new PropertyChangingEventArgs(String.Empty); + + private string _Id; + + private string _ProjectId; + + private string _StaticEquipment; + + private string _SYSTEM; + + private string _Subsystem; + + private string _TestPackage; + + private System.Nullable _TestPackageSTART; + + private System.Nullable _TestPackageFINISH; + + private string _MechanicalFINALStatus; + + private System.Nullable _CompleteTime; + + #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 OnStaticEquipmentChanging(string value); + partial void OnStaticEquipmentChanged(); + 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 OnMechanicalFINALStatusChanging(string value); + partial void OnMechanicalFINALStatusChanged(); + partial void OnCompleteTimeChanging(System.Nullable value); + partial void OnCompleteTimeChanged(); + #endregion + + public Transfer_StaticEquipment() + { + 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="_StaticEquipment", DbType="NVarChar(50)")] + public string StaticEquipment + { + get + { + return this._StaticEquipment; + } + set + { + if ((this._StaticEquipment != value)) + { + this.OnStaticEquipmentChanging(value); + this.SendPropertyChanging(); + this._StaticEquipment = value; + this.SendPropertyChanged("StaticEquipment"); + this.OnStaticEquipmentChanged(); + } + } + } + + [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="_MechanicalFINALStatus", DbType="NVarChar(50)")] + public string MechanicalFINALStatus + { + get + { + return this._MechanicalFINALStatus; + } + set + { + if ((this._MechanicalFINALStatus != value)) + { + this.OnMechanicalFINALStatusChanging(value); + this.SendPropertyChanging(); + this._MechanicalFINALStatus = value; + this.SendPropertyChanged("MechanicalFINALStatus"); + this.OnMechanicalFINALStatusChanged(); + } + } + } + + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_CompleteTime", DbType="DateTime")] + public System.Nullable CompleteTime + { + get + { + return this._CompleteTime; + } + set + { + if ((this._CompleteTime != value)) + { + this.OnCompleteTimeChanging(value); + this.SendPropertyChanging(); + this._CompleteTime = value; + this.SendPropertyChanged("CompleteTime"); + this.OnCompleteTimeChanged(); + } + } + } + + 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_Telecom")] public partial class Transfer_Telecom : INotifyPropertyChanging, INotifyPropertyChanged { @@ -370868,6 +371929,8 @@ namespace Model private string _FINAL_Status; + private System.Nullable _CompleteTime; + #region 鍙墿灞曟ф柟娉曞畾涔 partial void OnLoaded(); partial void OnValidate(System.Data.Linq.ChangeAction action); @@ -370890,6 +371953,8 @@ namespace Model partial void OnTest_Package_FINISHChanged(); partial void OnFINAL_StatusChanging(string value); partial void OnFINAL_StatusChanged(); + partial void OnCompleteTimeChanging(System.Nullable value); + partial void OnCompleteTimeChanged(); #endregion public Transfer_Telecom() @@ -371077,6 +372142,26 @@ namespace Model } } + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_CompleteTime", DbType="DateTime")] + public System.Nullable CompleteTime + { + get + { + return this._CompleteTime; + } + set + { + if ((this._CompleteTime != value)) + { + this.OnCompleteTimeChanging(value); + this.SendPropertyChanging(); + this._CompleteTime = value; + this.SendPropertyChanged("CompleteTime"); + this.OnCompleteTimeChanged(); + } + } + } + public event PropertyChangingEventHandler PropertyChanging; public event PropertyChangedEventHandler PropertyChanged; @@ -413951,6 +415036,159 @@ namespace Model } } + [global::System.Data.Linq.Mapping.TableAttribute(Name="dbo.View_TransferDetail")] + public partial class View_TransferDetail + { + + private string _Projectid; + + private string _SystemName; + + private string _Subsystem; + + private string _TestPackage; + + private System.Nullable _SDate; + + private System.Nullable _FDate; + + private string _Status; + + private System.Nullable _ADate; + + public View_TransferDetail() + { + } + + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Projectid", DbType="NVarChar(50)")] + public string Projectid + { + get + { + return this._Projectid; + } + set + { + if ((this._Projectid != value)) + { + this._Projectid = value; + } + } + } + + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_SystemName", DbType="NVarChar(50)")] + public string SystemName + { + get + { + return this._SystemName; + } + set + { + if ((this._SystemName != value)) + { + this._SystemName = value; + } + } + } + + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Subsystem", DbType="NVarChar(50)")] + public string Subsystem + { + get + { + return this._Subsystem; + } + set + { + if ((this._Subsystem != value)) + { + this._Subsystem = value; + } + } + } + + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_TestPackage", DbType="NVarChar(50)")] + public string TestPackage + { + get + { + return this._TestPackage; + } + set + { + if ((this._TestPackage != value)) + { + this._TestPackage = value; + } + } + } + + [global::System.Data.Linq.Mapping.ColumnAttribute(Name="sDate", Storage="_SDate", DbType="DateTime")] + public System.Nullable SDate + { + get + { + return this._SDate; + } + set + { + if ((this._SDate != value)) + { + this._SDate = value; + } + } + } + + [global::System.Data.Linq.Mapping.ColumnAttribute(Name="fDate", Storage="_FDate", DbType="DateTime")] + public System.Nullable FDate + { + get + { + return this._FDate; + } + set + { + if ((this._FDate != value)) + { + this._FDate = value; + } + } + } + + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Status", DbType="NVarChar(50)")] + public string Status + { + get + { + return this._Status; + } + set + { + if ((this._Status != value)) + { + this._Status = value; + } + } + } + + [global::System.Data.Linq.Mapping.ColumnAttribute(Name="aDate", Storage="_ADate", DbType="DateTime")] + public System.Nullable ADate + { + get + { + return this._ADate; + } + set + { + if ((this._ADate != value)) + { + this._ADate = value; + } + } + } + } + [global::System.Data.Linq.Mapping.TableAttribute(Name="dbo.View_WBS")] public partial class View_WBS {