diff --git a/DataBase/版本日志/SGGLDB_WH_2023-09-07.sql b/DataBase/版本日志/SGGLDB_WH_2023-09-07.sql new file mode 100644 index 00000000..25c4a9e7 --- /dev/null +++ b/DataBase/版本日志/SGGLDB_WH_2023-09-07.sql @@ -0,0 +1,393 @@ +INSERT INTO dbo.Sys_Menu(MenuId,MenuName,Url,SortIndex,SuperMenu,MenuType,IsOffice,IsEnd,IsUsed) + VALUES('2E58D4F1-2FF1-450E-8A00-1CE3BBCF8D4B','ҵƱ','HSSE/License/FireWork.aspx',10,'473A87D2-1365-4A68-BD38-06F312F81BC2','Menu_HSSE',0,1,1) + GO + INSERT INTO dbo.Sys_ButtonToMenu(ButtonToMenuId,MenuId,ButtonName,SortIndex) + VALUES('8DB0EAED-B67D-423A-BA13-E7872A11727A','2E58D4F1-2FF1-450E-8A00-1CE3BBCF8D4B','',1) + INSERT INTO dbo.Sys_ButtonToMenu(ButtonToMenuId,MenuId,ButtonName,SortIndex) + VALUES('F0283058-2CCF-4195-AEBC-878A2AE5067F','2E58D4F1-2FF1-450E-8A00-1CE3BBCF8D4B','޸',2) + INSERT INTO dbo.Sys_ButtonToMenu(ButtonToMenuId,MenuId,ButtonName,SortIndex) + VALUES('2C3CD3AA-C07D-439F-97BE-FEA20CE512CB','2E58D4F1-2FF1-450E-8A00-1CE3BBCF8D4B','ɾ',3) + INSERT INTO dbo.Sys_ButtonToMenu(ButtonToMenuId,MenuId,ButtonName,SortIndex) + VALUES('BBB22814-70D3-4188-A7F8-8C0FD4557A27','2E58D4F1-2FF1-450E-8A00-1CE3BBCF8D4B','',4) + GO + INSERT INTO dbo.Sys_Menu(MenuId,MenuName,Url,SortIndex,SuperMenu,MenuType,IsOffice,IsEnd,IsUsed) + VALUES('DA1CAE8E-B5BF-4AC0-9996-AF6CAA412CA9','ߴҵƱ','HSSE/License/HeightWork.aspx',20,'473A87D2-1365-4A68-BD38-06F312F81BC2','Menu_HSSE',0,1,1) + GO + INSERT INTO dbo.Sys_ButtonToMenu(ButtonToMenuId,MenuId,ButtonName,SortIndex) + VALUES('B3CD11DC-D359-4D60-8DB4-BD095CE52C17','DA1CAE8E-B5BF-4AC0-9996-AF6CAA412CA9','',1) + INSERT INTO dbo.Sys_ButtonToMenu(ButtonToMenuId,MenuId,ButtonName,SortIndex) + VALUES('6D9B6919-0677-4892-9C73-CDD6C124B855','DA1CAE8E-B5BF-4AC0-9996-AF6CAA412CA9','޸',2) + INSERT INTO dbo.Sys_ButtonToMenu(ButtonToMenuId,MenuId,ButtonName,SortIndex) + VALUES('044C6FF2-2A30-4E08-88A6-9D85722AD89C','DA1CAE8E-B5BF-4AC0-9996-AF6CAA412CA9','ɾ',3) + INSERT INTO dbo.Sys_ButtonToMenu(ButtonToMenuId,MenuId,ButtonName,SortIndex) + VALUES('7C06CD77-402A-4F8C-A41B-1C69301707E5','DA1CAE8E-B5BF-4AC0-9996-AF6CAA412CA9','',4) + GO + INSERT INTO dbo.Sys_Menu(MenuId,MenuName,Url,SortIndex,SuperMenu,MenuType,IsOffice,IsEnd,IsUsed) + VALUES('AEC9166D-1C91-45F0-8BFE-D3D0479A28C7','޿ռҵƱ','HSSE/License/LimitedSpace.aspx',30,'473A87D2-1365-4A68-BD38-06F312F81BC2','Menu_HSSE',0,1,1) + GO + INSERT INTO dbo.Sys_ButtonToMenu(ButtonToMenuId,MenuId,ButtonName,SortIndex) + VALUES('904FD3D2-1520-48FB-BD8F-6BAA000653B7','AEC9166D-1C91-45F0-8BFE-D3D0479A28C7','',1) + INSERT INTO dbo.Sys_ButtonToMenu(ButtonToMenuId,MenuId,ButtonName,SortIndex) + VALUES('7F372BE4-E264-48FB-ACA6-8E7EE41393EC','AEC9166D-1C91-45F0-8BFE-D3D0479A28C7','޸',2) + INSERT INTO dbo.Sys_ButtonToMenu(ButtonToMenuId,MenuId,ButtonName,SortIndex) + VALUES('BE6D9AE8-069A-421A-8E3D-F3DDC18FCDB4','AEC9166D-1C91-45F0-8BFE-D3D0479A28C7','ɾ',3) + INSERT INTO dbo.Sys_ButtonToMenu(ButtonToMenuId,MenuId,ButtonName,SortIndex) + VALUES('8CC252A0-F098-4FE3-AF21-4A7A7030DC5E','AEC9166D-1C91-45F0-8BFE-D3D0479A28C7','',4) + GO + INSERT INTO dbo.Sys_Menu(MenuId,MenuName,Url,SortIndex,SuperMenu,MenuType,IsOffice,IsEnd,IsUsed) + VALUES('F72FF20B-D3EB-46A5-97F7-C99B2473A140','ҵƱ','HSSE/License/RadialWork.aspx',40,'473A87D2-1365-4A68-BD38-06F312F81BC2','Menu_HSSE',0,1,1) + GO + INSERT INTO dbo.Sys_ButtonToMenu(ButtonToMenuId,MenuId,ButtonName,SortIndex) + VALUES('107EA8EA-4D8D-410B-B3DE-F0C29E9C3EDC','F72FF20B-D3EB-46A5-97F7-C99B2473A140','',1) + INSERT INTO dbo.Sys_ButtonToMenu(ButtonToMenuId,MenuId,ButtonName,SortIndex) + VALUES('89010EF9-9E77-49EB-A00D-3142B9FBC29E','F72FF20B-D3EB-46A5-97F7-C99B2473A140','޸',2) + INSERT INTO dbo.Sys_ButtonToMenu(ButtonToMenuId,MenuId,ButtonName,SortIndex) + VALUES('F5EFEB84-7CCC-406D-ACFA-CA36CB6A8A1D','F72FF20B-D3EB-46A5-97F7-C99B2473A140','ɾ',3) + INSERT INTO dbo.Sys_ButtonToMenu(ButtonToMenuId,MenuId,ButtonName,SortIndex) + VALUES('982333DA-42A2-40A3-8F3D-52BA7DE4E19D','F72FF20B-D3EB-46A5-97F7-C99B2473A140','',4) + GO + INSERT INTO dbo.Sys_Menu(MenuId,MenuName,Url,SortIndex,SuperMenu,MenuType,IsOffice,IsEnd,IsUsed) + VALUES('4E607E83-41FC-4F49-B26F-A21CFE38328F','·(ռ)ҵƱ','HSSE/License/OpenCircuit.aspx',60,'473A87D2-1365-4A68-BD38-06F312F81BC2','Menu_HSSE',0,1,1) + GO + INSERT INTO dbo.Sys_ButtonToMenu(ButtonToMenuId,MenuId,ButtonName,SortIndex) + VALUES('6D90E4CD-D932-454A-8A8B-54FA3CC22FD4','4E607E83-41FC-4F49-B26F-A21CFE38328F','',1) + INSERT INTO dbo.Sys_ButtonToMenu(ButtonToMenuId,MenuId,ButtonName,SortIndex) + VALUES('53BF21A8-38DA-4853-A527-8D392B901554','4E607E83-41FC-4F49-B26F-A21CFE38328F','޸',2) + INSERT INTO dbo.Sys_ButtonToMenu(ButtonToMenuId,MenuId,ButtonName,SortIndex) + VALUES('06F8CEAB-7AF8-40C5-B6D0-6A91AE562AD7','4E607E83-41FC-4F49-B26F-A21CFE38328F','ɾ',3) + INSERT INTO dbo.Sys_ButtonToMenu(ButtonToMenuId,MenuId,ButtonName,SortIndex) + VALUES('C8BE46DF-2553-4A64-BE79-B69712C297A5','4E607E83-41FC-4F49-B26F-A21CFE38328F','',4) + GO + INSERT INTO dbo.Sys_Menu(MenuId,MenuName,Url,SortIndex,SuperMenu,MenuType,IsOffice,IsEnd,IsUsed) + VALUES('755C6AC9-2E38-4D4F-AF33-33CB1744A907','ҵƱ','HSSE/License/BreakGround.aspx',70,'473A87D2-1365-4A68-BD38-06F312F81BC2','Menu_HSSE',0,1,1) + GO + INSERT INTO dbo.Sys_ButtonToMenu(ButtonToMenuId,MenuId,ButtonName,SortIndex) + VALUES('F3D52EF3-104F-42CF-B48A-443FCE5C800D','755C6AC9-2E38-4D4F-AF33-33CB1744A907','',1) + INSERT INTO dbo.Sys_ButtonToMenu(ButtonToMenuId,MenuId,ButtonName,SortIndex) + VALUES('7DFD6886-0F8B-4DA1-9C4B-1847A8B286AF','755C6AC9-2E38-4D4F-AF33-33CB1744A907','޸',2) + INSERT INTO dbo.Sys_ButtonToMenu(ButtonToMenuId,MenuId,ButtonName,SortIndex) + VALUES('F5F93A18-438F-4A19-982B-7E9E38EB6AE2','755C6AC9-2E38-4D4F-AF33-33CB1744A907','ɾ',3) + INSERT INTO dbo.Sys_ButtonToMenu(ButtonToMenuId,MenuId,ButtonName,SortIndex) + VALUES('32937824-9F35-4C4E-8E13-984E784F8E9C','755C6AC9-2E38-4D4F-AF33-33CB1744A907','',4) + GO + INSERT INTO dbo.Sys_Menu(MenuId,MenuName,Url,SortIndex,SuperMenu,MenuType,IsOffice,IsEnd,IsUsed) + VALUES('7BBAE649-7B00-4475-A911-BFE3A37AC55B','ҹʩҵƱ','HSSE/License/NightWork.aspx',80,'473A87D2-1365-4A68-BD38-06F312F81BC2','Menu_HSSE',0,1,1) + GO + INSERT INTO dbo.Sys_ButtonToMenu(ButtonToMenuId,MenuId,ButtonName,SortIndex) + VALUES('B040C80B-4216-4AF8-B9C9-A1303E31CFAC','7BBAE649-7B00-4475-A911-BFE3A37AC55B','',1) + INSERT INTO dbo.Sys_ButtonToMenu(ButtonToMenuId,MenuId,ButtonName,SortIndex) + VALUES('60241503-BF4B-4159-AFA2-41186CD9329B','7BBAE649-7B00-4475-A911-BFE3A37AC55B','޸',2) + INSERT INTO dbo.Sys_ButtonToMenu(ButtonToMenuId,MenuId,ButtonName,SortIndex) + VALUES('3A192DC6-2338-4038-ADAD-46FA7364E20F','7BBAE649-7B00-4475-A911-BFE3A37AC55B','ɾ',3) + INSERT INTO dbo.Sys_ButtonToMenu(ButtonToMenuId,MenuId,ButtonName,SortIndex) + VALUES('6239BB95-33AF-4B36-97CB-787EF553D35A','7BBAE649-7B00-4475-A911-BFE3A37AC55B','',4) + GO + INSERT INTO dbo.Sys_Menu(MenuId,MenuName,Url,SortIndex,SuperMenu,MenuType,IsOffice,IsEnd,IsUsed) + VALUES('A1BE3AB6-9D4A-41E7-8870-E73423165451','װҵƱ','HSSE/License/LiftingWork.aspx',80,'473A87D2-1365-4A68-BD38-06F312F81BC2','Menu_HSSE',0,1,1) + GO + INSERT INTO dbo.Sys_ButtonToMenu(ButtonToMenuId,MenuId,ButtonName,SortIndex) + VALUES('BDC9E201-0C51-4C02-9151-B6DF86CE4C27','A1BE3AB6-9D4A-41E7-8870-E73423165451','',1) + INSERT INTO dbo.Sys_ButtonToMenu(ButtonToMenuId,MenuId,ButtonName,SortIndex) + VALUES('36EBA247-3051-4213-BD95-89DC948006E1','A1BE3AB6-9D4A-41E7-8870-E73423165451','޸',2) + INSERT INTO dbo.Sys_ButtonToMenu(ButtonToMenuId,MenuId,ButtonName,SortIndex) + VALUES('46A93981-2D60-49C3-877A-7B66EBCBC927','A1BE3AB6-9D4A-41E7-8870-E73423165451','ɾ',3) + INSERT INTO dbo.Sys_ButtonToMenu(ButtonToMenuId,MenuId,ButtonName,SortIndex) + VALUES('3C5F18F7-459A-4666-B497-9400E637C975','A1BE3AB6-9D4A-41E7-8870-E73423165451','',4) + GO + +update sys_menu set menuname='HSSE¹ʴ' where menuname ='HSSE¹(δ)' + +--Ӷҵֶ +-- +ALTER TABLE License_FireWork +ADD WorkAreaId nvarchar(500) null; +--ԭ +ALTER TABLE License_FireWork +ADD Reason nvarchar(500) null; +--ҵ +ALTER TABLE License_FireWork +ADD FireLevel nvarchar(20) null; + + +--޿ռ +-- +ALTER TABLE License_LimitedSpace +ADD WorkAreaId nvarchar(500) null; +--ռڽ +ALTER TABLE License_LimitedSpace +ADD LimitedDescribe nvarchar(500) null; +--Ƿ +ALTER TABLE License_LimitedSpace +ADD IsBoolOther bit null; +--ҵǷжк +ALTER TABLE License_LimitedSpace +ADD IsBoolHarmfulGas bit null; +--Խ +ALTER TABLE License_LimitedSpace +ADD TestResult nvarchar(500) null; +--ʱ +ALTER TABLE License_LimitedSpace +ADD TestDate datetime null; +-- +ALTER TABLE License_LimitedSpace +ADD TestPerson nvarchar(100) null; +--ͨʩ +ALTER TABLE License_LimitedSpace +ADD VenStep nvarchar(20) null; + + +--ҵƱ +-- +ALTER TABLE License_BreakGround +ADD WorkAreaId nvarchar(500) null; +--ԭ +ALTER TABLE License_BreakGround +ADD Reason nvarchar(500) null; +--໤ +ALTER TABLE License_BreakGround +ADD FireWatchManName nvarchar(500) null; + + +--ߴҵƱ +-- +ALTER TABLE License_HeightWork +ADD WorkAreaId nvarchar(500) null; +--ҵ߶ +ALTER TABLE License_HeightWork +ADD WorkHeight nvarchar(20) null; +--ߴҵ +ALTER TABLE License_HeightWork +ADD HeightLevel nvarchar(20) null; +--໤ +ALTER TABLE License_HeightWork +ADD FireWatchManName nvarchar(500) null; + +-- +ALTER TABLE License_HeightWork +ADD WorkLeaderName nvarchar(200) null; +--˵绰 +ALTER TABLE License_HeightWork +ADD WorkLeaderTel nvarchar(200) null; + +--װ +-- +ALTER TABLE License_LiftingWork +ADD WorkAreaId nvarchar(500) null; +--װ߶ +ALTER TABLE License_LiftingWork +ADD LiftingHeight nvarchar(20) null; + +--໤ +ALTER TABLE License_LiftingWork +ADD FireWatchManName nvarchar(500) null; + +-- +ALTER TABLE License_LiftingWork +ADD WorkLeaderName nvarchar(200) null; +--˵绰 +ALTER TABLE License_LiftingWork +ADD WorkLeaderTel nvarchar(200) null; + +--ع +ALTER TABLE License_LiftingWork +ADD QzgName nvarchar(200) null; +--ع绰 +ALTER TABLE License_LiftingWork +ADD QzgPhone nvarchar(200) null; + +--·ҵ +-- +ALTER TABLE License_OpenCircuit +ADD WorkAreaId nvarchar(500) null; +--·ҵԭ +ALTER TABLE License_OpenCircuit +ADD Reason nvarchar(500) null; +--໤ +ALTER TABLE License_OpenCircuit +ADD FireWatchManName nvarchar(500) null; + + +--ҵ +-- +ALTER TABLE License_RadialWork +ADD WorkAreaId nvarchar(500) null; + +--ʱõ˵ +INSERT INTO dbo.Sys_Menu(MenuId,MenuName,Url,SortIndex,SuperMenu,MenuType,IsOffice,IsEnd,IsUsed) +VALUES('48F64E0F-38B2-4BDC-9B61-6200BD02CBF5','ʱõҵƱ','HSSE/License/Electricity.aspx',50,'473A87D2-1365-4A68-BD38-06F312F81BC2','Menu_HSSE',0,1,1) +GO +INSERT INTO dbo.Sys_ButtonToMenu(ButtonToMenuId,MenuId,ButtonName,SortIndex) +VALUES('4D6FE464-B5D7-48BE-B68D-C55C9E8E6202','48F64E0F-38B2-4BDC-9B61-6200BD02CBF5','',1) +INSERT INTO dbo.Sys_ButtonToMenu(ButtonToMenuId,MenuId,ButtonName,SortIndex) +VALUES('0086D338-3864-4C90-BEDB-7E752622837D','48F64E0F-38B2-4BDC-9B61-6200BD02CBF5','޸',2) +INSERT INTO dbo.Sys_ButtonToMenu(ButtonToMenuId,MenuId,ButtonName,SortIndex) +VALUES('184C6276-C8B6-421B-B0F9-A74CDCBA53E9','48F64E0F-38B2-4BDC-9B61-6200BD02CBF5','ɾ',3) +INSERT INTO dbo.Sys_ButtonToMenu(ButtonToMenuId,MenuId,ButtonName,SortIndex) +VALUES('065EC96A-1AF4-457F-AA13-CEEAB5A0BD7C','48F64E0F-38B2-4BDC-9B61-6200BD02CBF5','',4) +GO +CREATE TABLE [dbo].[License_Electricity]( + [ElectricityId] [nvarchar](50) NOT NULL, + [ProjectId] [nvarchar](50) NULL, + [LicenseCode] [nvarchar](50) NULL, + [ApplyUnitId] [nvarchar](50) NULL, + [ApplyManId] [nvarchar](50) NULL, + [ApplyDate] [datetime] NULL, + [WorkPalce] [nvarchar](300) NULL, + [WorkDepth] [nvarchar](50) NULL, + [ValidityStartTime] [datetime] NULL, + [ValidityEndTime] [datetime] NULL, + [WorkMeasures] [nvarchar](500) NULL, + [CancelManId] [nvarchar](50) NULL, + [CancelReasons] [nvarchar](200) NULL, + [CancelTime] [datetime] NULL, + [CloseManId] [nvarchar](50) NULL, + [CloseReasons] [nvarchar](200) NULL, + [CloseTime] [datetime] NULL, + [States] [varchar](2) NULL, + [NextManId] [nvarchar](500) NULL, + [OldLicenseId] [nvarchar](50) NULL, + [WorkAreaId] [nvarchar](500) NULL, + [Reason] [nvarchar](500) NULL, + [FireWatchManName] [nvarchar](500) NULL, + CONSTRAINT [PK_License_Electricity] PRIMARY KEY CLUSTERED +( + [ElectricityId] 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 + +SET ANSI_PADDING OFF +GO + +ALTER TABLE [dbo].[License_Electricity] WITH CHECK ADD CONSTRAINT [FK_License_Electricity_Base_Project] FOREIGN KEY([ProjectId]) +REFERENCES [dbo].[Base_Project] ([ProjectId]) +GO + +ALTER TABLE [dbo].[License_Electricity] CHECK CONSTRAINT [FK_License_Electricity_Base_Project] +GO + +ALTER TABLE [dbo].[License_Electricity] WITH CHECK ADD CONSTRAINT [FK_License_Electricity_Base_Unit] FOREIGN KEY([ApplyUnitId]) +REFERENCES [dbo].[Base_Unit] ([UnitId]) +GO + +ALTER TABLE [dbo].[License_Electricity] CHECK CONSTRAINT [FK_License_Electricity_Base_Unit] +GO + +ALTER TABLE [dbo].[License_Electricity] WITH CHECK ADD CONSTRAINT [FK_License_Electricity_Sys_User] FOREIGN KEY([ApplyManId]) +REFERENCES [dbo].[Sys_User] ([UserId]) +GO + +ALTER TABLE [dbo].[License_Electricity] CHECK CONSTRAINT [FK_License_Electricity_Sys_User] +GO + +ALTER TABLE [dbo].[License_Electricity] WITH CHECK ADD CONSTRAINT [FK_License_Electricity_Sys_User2] FOREIGN KEY([CancelManId]) +REFERENCES [dbo].[Sys_User] ([UserId]) +GO + +ALTER TABLE [dbo].[License_Electricity] CHECK CONSTRAINT [FK_License_Electricity_Sys_User2] +GO + +ALTER TABLE [dbo].[License_Electricity] WITH CHECK ADD CONSTRAINT [FK_License_Electricity_Sys_User3] FOREIGN KEY([CloseManId]) +REFERENCES [dbo].[Sys_User] ([UserId]) +GO + +ALTER TABLE [dbo].[License_Electricity] CHECK CONSTRAINT [FK_License_Electricity_Sys_User3] +GO + +EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'ID' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'License_Electricity', @level2type=N'COLUMN',@level2name=N'ElectricityId' +GO + +EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'ĿID' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'License_Electricity', @level2type=N'COLUMN',@level2name=N'ProjectId' +GO + +EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'License_Electricity', @level2type=N'COLUMN',@level2name=N'LicenseCode' +GO + +EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'뵥ID' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'License_Electricity', @level2type=N'COLUMN',@level2name=N'ApplyUnitId' +GO + +EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'ID' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'License_Electricity', @level2type=N'COLUMN',@level2name=N'ApplyManId' +GO + +EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'ʱ' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'License_Electricity', @level2type=N'COLUMN',@level2name=N'ApplyDate' +GO + +EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'ҵص' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'License_Electricity', @level2type=N'COLUMN',@level2name=N'WorkPalce' +GO + +EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'License_Electricity', @level2type=N'COLUMN',@level2name=N'WorkDepth' +GO + +EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Чڿʼʱ' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'License_Electricity', @level2type=N'COLUMN',@level2name=N'ValidityStartTime' +GO + +EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Чڽʱ' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'License_Electricity', @level2type=N'COLUMN',@level2name=N'ValidityEndTime' +GO + +EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'ҵݡ߼ȫʩ' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'License_Electricity', @level2type=N'COLUMN',@level2name=N'WorkMeasures' +GO + +EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'ȡID' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'License_Electricity', @level2type=N'COLUMN',@level2name=N'CancelManId' +GO + +EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'ȡԭ' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'License_Electricity', @level2type=N'COLUMN',@level2name=N'CancelReasons' +GO + +EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'ȡʱ' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'License_Electricity', @level2type=N'COLUMN',@level2name=N'CancelTime' +GO + +EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'رID' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'License_Electricity', @level2type=N'COLUMN',@level2name=N'CloseManId' +GO + +EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'رԭ' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'License_Electricity', @level2type=N'COLUMN',@level2name=N'CloseReasons' +GO + +EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'رʱ' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'License_Electricity', @level2type=N'COLUMN',@level2name=N'CloseTime' +GO + +EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'״̬(0-ύ1-У2-ɣ3-رգ-1ȡ)' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'License_Electricity', @level2type=N'COLUMN',@level2name=N'States' +GO + +EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'²ID' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'License_Electricity', @level2type=N'COLUMN',@level2name=N'NextManId' +GO + +EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'ԭ֤ID' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'License_Electricity', @level2type=N'COLUMN',@level2name=N'OldLicenseId' +GO + +EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'ҵƱ' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'License_Electricity' +GO + +--ʱõ簲װ +ALTER TABLE License_Electricity +ADD WorkLeaderName nvarchar(200) null; +--ʱõ簲װ˵绰 +ALTER TABLE License_Electricity +ADD WorkLeaderTel nvarchar(200) null; + +--ʱҵƱ +INSERT Sys_MenuFlowOperate(FlowOperateId,MenuId,FlowStep,GroupNum,OrderNum,AuditFlowName,IsFlowEnd) +VALUES('48F64E0F-38B2-4BDC-9B61-6200BD02CBF51','48F64E0F-38B2-4BDC-9B61-6200BD02CBF5',1,1,1,'ʩλȫԱ',0) +INSERT Sys_MenuFlowOperate(FlowOperateId,MenuId,FlowStep,GroupNum,OrderNum,AuditFlowName,IsFlowEnd) +VALUES('48F64E0F-38B2-4BDC-9B61-6200BD02CBF52','48F64E0F-38B2-4BDC-9B61-6200BD02CBF5',2,1,1,'ܰλȫԱ',0) +INSERT Sys_MenuFlowOperate(FlowOperateId,MenuId,FlowStep,GroupNum,OrderNum,AuditFlowName,IsFlowEnd) +VALUES('48F64E0F-38B2-4BDC-9B61-6200BD02CBF53','48F64E0F-38B2-4BDC-9B61-6200BD02CBF5',3,1,1,'ܰλרҵʦ',0) +INSERT Sys_MenuFlowOperate(FlowOperateId,MenuId,FlowStep,GroupNum,OrderNum,AuditFlowName,IsFlowEnd) +VALUES('48F64E0F-38B2-4BDC-9B61-6200BD02CBF54','48F64E0F-38B2-4BDC-9B61-6200BD02CBF5',3,1,2,'ܰλʩ',0) +INSERT Sys_MenuFlowOperate(FlowOperateId,MenuId,FlowStep,GroupNum,OrderNum,AuditFlowName,IsFlowEnd) +VALUES('48F64E0F-38B2-4BDC-9B61-6200BD02CBF55','48F64E0F-38B2-4BDC-9B61-6200BD02CBF5',3,2,1,'λ',0) +INSERT Sys_MenuFlowOperate(FlowOperateId,MenuId,FlowStep,GroupNum,OrderNum,AuditFlowName,IsFlowEnd) +VALUES('48F64E0F-38B2-4BDC-9B61-6200BD02CBF56','48F64E0F-38B2-4BDC-9B61-6200BD02CBF5',3,2,2,'ҵλ',0) +INSERT Sys_MenuFlowOperate(FlowOperateId,MenuId,FlowStep,GroupNum,OrderNum,AuditFlowName,IsFlowEnd) +VALUES('48F64E0F-38B2-4BDC-9B61-6200BD02CBF57','48F64E0F-38B2-4BDC-9B61-6200BD02CBF5',4,1,1,'',1) + +--ҵ +insert into Sys_Const(id,ConstValue,ConstText,SortIndex,GroupId) +values('8A1DF18E-4CE6-4AA1-AD2C-625823BC4D8E','48F64E0F-38B2-4BDC-9B61-6200BD02CBF5','ʱõҵƱ',9,'LicenseType') + +--ҵһ +delete from Sys_MenuFlowOperate where flowStep!=1 +update Sys_MenuFlowOperate set auditflowname='' + + + diff --git a/SGGL/BLL/API/HSSE/APICheckSpecialService.cs b/SGGL/BLL/API/HSSE/APICheckSpecialService.cs index 7a6318bf..03c4a833 100644 --- a/SGGL/BLL/API/HSSE/APICheckSpecialService.cs +++ b/SGGL/BLL/API/HSSE/APICheckSpecialService.cs @@ -237,7 +237,7 @@ namespace BLL CheckItemDetailSetId = x.CheckItemSetId, CheckItemDetailContent = x.CheckItemSetContent, - Rectification_Date = x.Rectification_Date + Rectification_Date = string.Format("{0:yyyy-MM-dd}", x.Rectification_Date), }; return getInfo.ToList(); } @@ -289,7 +289,7 @@ namespace BLL CheckItemDetailSetId=x.CheckItemSetId, CheckItemDetailContent=x.CheckItemSetContent, - Rectification_Date=x.Rectification_Date + Rectification_Date= string.Format("{0:yyyy-MM-dd}", x.Rectification_Date), }; return getInfo.First(); } @@ -328,7 +328,7 @@ namespace BLL //整改日期、检查内容、检查内容id CheckItemSetId= newDetail.CheckItemDetailSetId, CheckItemSetContent= newDetail.CheckItemDetailContent, - Rectification_Date=newDetail.Rectification_Date + Rectification_Date = Funs.GetNewDateTime(newDetail.Rectification_Date) }; if (newCheckSpecialDetail.CompleteStatus == false && newCheckSpecialDetail.HandleStep.Contains("1") && string.IsNullOrEmpty(newCheckSpecialDetail.HiddenHazardType)) { @@ -374,7 +374,7 @@ namespace BLL //整改日期、检查内容、检查内容id updateDetail.CheckItemSetId = newDetail.CheckItemDetailSetId; updateDetail.CheckItemSetContent = newDetail.CheckItemDetailContent; - updateDetail.Rectification_Date = newDetail.Rectification_Date; + updateDetail.Rectification_Date = Funs.GetNewDateTime(newDetail.Rectification_Date); db.SubmitChanges(); } ////保存附件 diff --git a/SGGL/BLL/API/HSSE/APILicenseDataService.cs b/SGGL/BLL/API/HSSE/APILicenseDataService.cs index 7fcf5dd7..7294d538 100644 --- a/SGGL/BLL/API/HSSE/APILicenseDataService.cs +++ b/SGGL/BLL/API/HSSE/APILicenseDataService.cs @@ -58,6 +58,11 @@ namespace BLL AttachUrl = db.AttachFile.First(z => z.ToKeyId == x.FireWorkId).AttachUrl.Replace('\\', '/'), States = x.States, OldLicenseId = x.OldLicenseId, + + WorkAreaId = x.WorkAreaId, + WorkAreaName = UnitWorkService.GetUnitWorkName(x.WorkAreaId), + Reason = x.Reason, + FireLevel = x.FireLevel }).FirstOrDefault(); } #endregion @@ -96,6 +101,14 @@ namespace BLL AttachUrl = db.AttachFile.First(z => z.ToKeyId == x.HeightWorkId).AttachUrl.Replace('\\', '/'), States = x.States, OldLicenseId = x.OldLicenseId, + + WorkAreaId = x.WorkAreaId, + WorkAreaName = UnitWorkService.GetUnitWorkName(x.WorkAreaId), + WorkHeight = x.WorkHeight, + HeightLevel = x.HeightLevel, + FireWatchManName = x.FireWatchManName, + WorkLeaderName = x.WorkLeaderName, + WorkLeaderTel = x.WorkLeaderTel, }).FirstOrDefault(); } #endregion @@ -134,6 +147,16 @@ namespace BLL AttachUrl = db.AttachFile.First(z => z.ToKeyId == x.LimitedSpaceId).AttachUrl.Replace('\\', '/'), States = x.States, OldLicenseId = x.OldLicenseId, + + WorkAreaId = x.WorkAreaId, + WorkAreaName = UnitWorkService.GetUnitWorkName(x.WorkAreaId), + LimitedDescribe = x.LimitedDescribe, + IsBoolOther = x.IsBoolOther, + IsBoolHarmfulGas = x.IsBoolHarmfulGas, + TestResult = x.TestResult, + TestDate = string.Format("{0:yyyy-MM-dd HH:mm}", x.TestDate), + TestPerson = x.TestPerson, + VenStep = x.VenStep, }).FirstOrDefault(); } #endregion @@ -177,6 +200,9 @@ namespace BLL AttachUrl = db.AttachFile.First(z => z.ToKeyId == x.RadialWorkId).AttachUrl.Replace('\\', '/'), States = x.States, OldLicenseId = x.OldLicenseId, + + WorkAreaId = x.WorkAreaId, + WorkAreaName = UnitWorkService.GetUnitWorkName(x.WorkAreaId), }).FirstOrDefault(); } #endregion @@ -215,6 +241,11 @@ namespace BLL AttachUrl = db.AttachFile.First(z => z.ToKeyId == x.OpenCircuitId).AttachUrl.Replace('\\', '/'), States = x.States, OldLicenseId = x.OldLicenseId, + + WorkAreaId = x.WorkAreaId, + WorkAreaName = UnitWorkService.GetUnitWorkName(x.WorkAreaId), + Reason = x.Reason, + FireWatchManName = x.FireWatchManName, }).FirstOrDefault(); } #endregion @@ -252,6 +283,11 @@ namespace BLL AttachUrl = db.AttachFile.First(z => z.ToKeyId == x.BreakGroundId).AttachUrl.Replace('\\', '/'), States = x.States, OldLicenseId = x.OldLicenseId, + + WorkAreaId = x.WorkAreaId, + WorkAreaName = UnitWorkService.GetUnitWorkName(x.WorkAreaId), + Reason = x.Reason, + FireWatchManName = x.FireWatchManName, }).FirstOrDefault(); } #endregion @@ -332,6 +368,60 @@ namespace BLL AttachUrl = db.AttachFile.First(z => z.ToKeyId == x.LiftingWorkId).AttachUrl.Replace('\\', '/'), States = x.States, OldLicenseId = x.OldLicenseId, + + WorkAreaId = x.WorkAreaId, + WorkAreaName = UnitWorkService.GetUnitWorkName(x.WorkAreaId), + LiftingHeight = x.LiftingHeight, + FireWatchManName = x.FireWatchManName, + WorkLeaderName = x.WorkLeaderName, + WorkLeaderTel = x.WorkLeaderTel, + QzgName = x.QzgName, + QzgPhone = x.QzgPhone, + }).FirstOrDefault(); + } + #endregion + + #region 临时用电作业票 + if (strMenuId == Const.ProjectElectricityMenuId) + { + getInfo = (from x in db.License_Electricity + where x.ElectricityId == id + select new Model.LicenseDataItem + { + LicenseId = x.ElectricityId, + MenuId = strMenuId, + ProjectId = x.ProjectId, + LicenseCode = x.LicenseCode, + ApplyUnitId = x.ApplyUnitId, + ApplyUnitName = db.Base_Unit.First(u => u.UnitId == x.ApplyUnitId).UnitName, + ApplyManId = x.ApplyManId, + ApplyManName = db.Sys_User.First(u => u.UserId == x.ApplyManId).UserName, + ApplyDate = string.Format("{0:yyyy-MM-dd HH:mm}", x.ApplyDate), + WorkPalce = x.WorkPalce, + WorkDepth = x.WorkDepth, + ValidityStartTime = string.Format("{0:yyyy-MM-dd HH:mm}", x.ValidityStartTime), + ValidityEndTime = string.Format("{0:yyyy-MM-dd HH:mm}", x.ValidityEndTime), + WorkMeasures = x.WorkMeasures, + CancelManId = x.CancelManId, + CancelManName = db.Sys_User.First(u => u.UserId == x.CancelManId).UserName, + CancelReasons = x.CancelReasons, + CancelTime = string.Format("{0:yyyy-MM-dd HH:mm}", x.CancelTime), + CloseManId = x.CloseManId, + CloseManName = db.Sys_User.First(u => u.UserId == x.CloseManId).UserName, + CloseReasons = x.CloseReasons, + CloseTime = string.Format("{0:yyyy-MM-dd HH:mm}", x.CloseTime), + NextManId = x.NextManId, + NextManName = db.Sys_User.First(u => u.UserId == x.NextManId).UserName, + AttachUrl = db.AttachFile.First(z => z.ToKeyId == x.ElectricityId).AttachUrl.Replace('\\', '/'), + States = x.States, + OldLicenseId = x.OldLicenseId, + + WorkAreaId = x.WorkAreaId, + WorkAreaName = UnitWorkService.GetUnitWorkName(x.WorkAreaId), + Reason = x.Reason, + FireWatchManName = x.FireWatchManName, + WorkLeaderName=x.WorkLeaderName, + WorkLeaderTel=x.WorkLeaderTel }).FirstOrDefault(); } #endregion @@ -419,6 +509,11 @@ namespace BLL CloseReasons = x.CloseReasons, CloseTime = string.Format("{0:yyyy-MM-dd HH:mm}", x.CloseTime), States = x.States, + + WorkAreaId = x.WorkAreaId, + WorkAreaName = UnitWorkService.GetUnitWorkName(x.WorkAreaId), + Reason=x.Reason, + FireLevel=x.FireLevel }).ToList(); } #endregion @@ -455,6 +550,15 @@ namespace BLL CloseReasons = x.CloseReasons, CloseTime = string.Format("{0:yyyy-MM-dd HH:mm}", x.CloseTime), States = x.States, + + WorkAreaId = x.WorkAreaId, + WorkAreaName = UnitWorkService.GetUnitWorkName(x.WorkAreaId), + WorkHeight=x.WorkHeight, + HeightLevel=x.HeightLevel, + FireWatchManName=x.FireWatchManName, + WorkLeaderName=x.WorkLeaderName, + WorkLeaderTel=x.WorkLeaderTel, + }).ToList(); } #endregion @@ -491,6 +595,20 @@ namespace BLL CloseReasons = x.CloseReasons, CloseTime = string.Format("{0:yyyy-MM-dd HH:mm}", x.CloseTime), States = x.States, + + WorkAreaId = x.WorkAreaId, + WorkAreaName = UnitWorkService.GetUnitWorkName(x.WorkAreaId), + LimitedDescribe=x.LimitedDescribe, + IsBoolOther=x.IsBoolOther, + IsBoolHarmfulGas=x.IsBoolHarmfulGas, + TestResult=x.TestResult, + TestDate= string.Format("{0:yyyy-MM-dd HH:mm}", x.TestDate), + TestPerson=x.TestPerson, + VenStep=x.VenStep, + + + + }).ToList(); } #endregion @@ -534,6 +652,10 @@ namespace BLL NextManId = x.NextManId, NextManName = db.Sys_User.First(u => u.UserId == x.NextManId).UserName, States = x.States, + + WorkAreaId = x.WorkAreaId, + WorkAreaName = UnitWorkService.GetUnitWorkName(x.WorkAreaId), + }).ToList(); } #endregion @@ -570,6 +692,12 @@ namespace BLL CloseReasons = x.CloseReasons, CloseTime = string.Format("{0:yyyy-MM-dd HH:mm}", x.CloseTime), States = x.States, + + WorkAreaId = x.WorkAreaId, + WorkAreaName = UnitWorkService.GetUnitWorkName(x.WorkAreaId), + Reason=x.Reason, + FireWatchManName=x.FireWatchManName, + }).ToList(); } #endregion @@ -605,6 +733,12 @@ namespace BLL CloseReasons = x.CloseReasons, CloseTime = string.Format("{0:yyyy-MM-dd HH:mm}", x.CloseTime), States = x.States, + + WorkAreaId = x.WorkAreaId, + WorkAreaName = UnitWorkService.GetUnitWorkName(x.WorkAreaId), + Reason=x.Reason, + FireWatchManName=x.FireWatchManName, + }).ToList(); } #endregion @@ -685,6 +819,60 @@ namespace BLL NextManId = x.NextManId, NextManName = db.Sys_User.First(u => u.UserId == x.NextManId).UserName, States = x.States, + + WorkAreaId = x.WorkAreaId, + WorkAreaName = UnitWorkService.GetUnitWorkName(x.WorkAreaId), + LiftingHeight=x.LiftingHeight, + FireWatchManName=x.FireWatchManName, + WorkLeaderName=x.WorkLeaderName, + WorkLeaderTel=x.WorkLeaderTel, + QzgName=x.QzgName, + QzgPhone=x.QzgPhone, + + }).ToList(); + } + #endregion + + #region 临时用电作业票 + if (strMenuId == Const.ProjectElectricityMenuId) + { + getInfoList = (from x in db.License_Electricity + where x.ProjectId == projectId && (x.ApplyUnitId == unitId || unitId == null) + && (states == null || x.States == states) + orderby x.LicenseCode descending + select new Model.LicenseDataItem + { + LicenseId = x.ElectricityId, + MenuId = strMenuId, + ProjectId = x.ProjectId, + LicenseCode = x.LicenseCode, + ApplyUnitId = x.ApplyUnitId, + ApplyUnitName = db.Base_Unit.First(u => u.UnitId == x.ApplyUnitId).UnitName, + ApplyManId = x.ApplyManId, + ApplyManName = db.Sys_User.First(u => u.UserId == x.ApplyManId).UserName, + ApplyDate = string.Format("{0:yyyy-MM-dd HH:mm}", x.ApplyDate), + WorkPalce = x.WorkPalce, + WorkDepth = x.WorkDepth, + ValidityStartTime = string.Format("{0:yyyy-MM-dd HH:mm}", x.ValidityStartTime), + ValidityEndTime = string.Format("{0:yyyy-MM-dd HH:mm}", x.ValidityEndTime), + WorkMeasures = x.WorkMeasures, + CancelManId = x.CancelManId, + CancelManName = db.Sys_User.First(u => u.UserId == x.CancelManId).UserName, + CancelReasons = x.CancelReasons, + CancelTime = string.Format("{0:yyyy-MM-dd HH:mm}", x.CancelTime), + CloseManId = x.CloseManId, + CloseManName = db.Sys_User.First(u => u.UserId == x.CloseManId).UserName, + CloseReasons = x.CloseReasons, + CloseTime = string.Format("{0:yyyy-MM-dd HH:mm}", x.CloseTime), + States = x.States, + + WorkAreaId = x.WorkAreaId, + WorkAreaName = UnitWorkService.GetUnitWorkName(x.WorkAreaId), + Reason = x.Reason, + FireWatchManName = x.FireWatchManName, + WorkLeaderName=x.WorkLeaderName, + WorkLeaderTel=x.WorkLeaderTel, + }).ToList(); } #endregion @@ -760,6 +948,11 @@ namespace BLL ValidityStartTime = string.Format("{0:yyyy-MM-dd HH:mm}", x.ValidityStartTime), ValidityEndTime = string.Format("{0:yyyy-MM-dd HH:mm}", x.ValidityEndTime), States = x.States, + + WorkAreaId = x.WorkAreaId, + WorkAreaName = UnitWorkService.GetUnitWorkName(x.WorkAreaId), + Reason = x.Reason, + FireLevel = x.FireLevel }).ToList(); if (getFireWork.Count() > 0) { @@ -788,6 +981,14 @@ namespace BLL ValidityStartTime = string.Format("{0:yyyy-MM-dd HH:mm}", x.ValidityStartTime), ValidityEndTime = string.Format("{0:yyyy-MM-dd HH:mm}", x.ValidityEndTime), States = x.States, + + WorkAreaId = x.WorkAreaId, + WorkAreaName = UnitWorkService.GetUnitWorkName(x.WorkAreaId), + WorkHeight = x.WorkHeight, + HeightLevel = x.HeightLevel, + FireWatchManName = x.FireWatchManName, + WorkLeaderName = x.WorkLeaderName, + WorkLeaderTel = x.WorkLeaderTel, }).ToList(); if (getHeightWork.Count() > 0) { @@ -815,6 +1016,17 @@ namespace BLL ValidityStartTime = string.Format("{0:yyyy-MM-dd HH:mm}", x.ValidityStartTime), ValidityEndTime = string.Format("{0:yyyy-MM-dd HH:mm}", x.ValidityEndTime), States = x.States, + + WorkAreaId = x.WorkAreaId, + WorkAreaName = UnitWorkService.GetUnitWorkName(x.WorkAreaId), + LimitedDescribe = x.LimitedDescribe, + IsBoolOther = x.IsBoolOther, + IsBoolHarmfulGas = x.IsBoolHarmfulGas, + TestResult = x.TestResult, + TestDate = string.Format("{0:yyyy-MM-dd HH:mm}", x.TestDate), + TestPerson = x.TestPerson, + VenStep = x.VenStep, + }).ToList(); if (getLimitedSpace.Count() > 0) { @@ -843,6 +1055,9 @@ namespace BLL ValidityEndTime = string.Format("{0:yyyy-MM-dd HH:mm}", x.ValidityEndTime), WorkPalce = x.WorkPalce, States = x.States, + + WorkAreaId = x.WorkAreaId, + WorkAreaName = UnitWorkService.GetUnitWorkName(x.WorkAreaId), }).ToList(); if (getRadialWork.Count() > 0) { @@ -871,6 +1086,11 @@ namespace BLL ValidityEndTime = string.Format("{0:yyyy-MM-dd HH:mm}", x.ValidityEndTime), RoadName = x.RoadName, States = x.States, + + WorkAreaId = x.WorkAreaId, + WorkAreaName = UnitWorkService.GetUnitWorkName(x.WorkAreaId), + Reason = x.Reason, + FireWatchManName = x.FireWatchManName, }).ToList(); if (getOpenCircuit.Count() > 0) { @@ -899,6 +1119,11 @@ namespace BLL ValidityStartTime = string.Format("{0:yyyy-MM-dd HH:mm}", x.ValidityStartTime), ValidityEndTime = string.Format("{0:yyyy-MM-dd HH:mm}", x.ValidityEndTime), States = x.States, + + WorkAreaId = x.WorkAreaId, + WorkAreaName = UnitWorkService.GetUnitWorkName(x.WorkAreaId), + Reason = x.Reason, + FireWatchManName = x.FireWatchManName, }).ToList(); if (getBreakGround.Count() > 0) { @@ -954,6 +1179,15 @@ namespace BLL ValidityStartTime = string.Format("{0:yyyy-MM-dd HH:mm}", x.ValidityStartTime), ValidityEndTime = string.Format("{0:yyyy-MM-dd HH:mm}", x.ValidityEndTime), States = x.States, + + WorkAreaId = x.WorkAreaId, + WorkAreaName = UnitWorkService.GetUnitWorkName(x.WorkAreaId), + LiftingHeight = x.LiftingHeight, + FireWatchManName = x.FireWatchManName, + WorkLeaderName = x.WorkLeaderName, + WorkLeaderTel = x.WorkLeaderTel, + QzgName = x.QzgName, + QzgPhone = x.QzgPhone, }).ToList(); if (getLiftingWork.Count() > 0) { @@ -961,6 +1195,41 @@ namespace BLL } #endregion + #region 临时用电作业票 + var getElectricity = (from x in db.License_Electricity + where x.ProjectId == projectId && (x.ApplyUnitId == unitId || unitId == null) + && (states == null || x.States == states) + select new Model.LicenseDataItem + { + LicenseId = x.ElectricityId, + MenuId = Const.ProjectElectricityMenuId, + MenuName = "临时用电", + ProjectId = x.ProjectId, + LicenseCode = x.LicenseCode, + ApplyUnitId = x.ApplyUnitId, + ApplyUnitName = db.Base_Unit.First(u => u.UnitId == x.ApplyUnitId).UnitName, + ApplyManId = x.ApplyManId, + ApplyManName = db.Sys_User.First(u => u.UserId == x.ApplyManId).UserName, + ApplyDate = string.Format("{0:yyyy-MM-dd HH:mm}", x.ApplyDate), + WorkPalce = x.WorkPalce, + WorkDepth = x.WorkDepth, + ValidityStartTime = string.Format("{0:yyyy-MM-dd HH:mm}", x.ValidityStartTime), + ValidityEndTime = string.Format("{0:yyyy-MM-dd HH:mm}", x.ValidityEndTime), + States = x.States, + + WorkAreaId = x.WorkAreaId, + WorkAreaName = UnitWorkService.GetUnitWorkName(x.WorkAreaId), + Reason = x.Reason, + FireWatchManName = x.FireWatchManName, + WorkLeaderName=x.WorkLeaderName, + WorkLeaderTel=x.WorkLeaderTel, + }).ToList(); + if (getElectricity.Count() > 0) + { + getInfoList.AddRange(getElectricity); + } + #endregion + #region 作业票【定稿 】"待开工"="1";"作业中"="2";"已关闭"="3";"已取消"="-1" var getLicenseManager = (from x in db.License_LicenseManager where x.ProjectId == projectId && (x.UnitId == unitId || unitId == null) @@ -1106,6 +1375,10 @@ namespace BLL CloseTime = Funs.GetNewDateTime(newItem.CloseTime), NextManId = newItem.NextManId, States = newItem.States, + + WorkAreaId=newItem.WorkAreaId, + Reason=newItem.Reason, + FireLevel=newItem.FireLevel }; if (newItem.States == Const.State_0) @@ -1156,6 +1429,10 @@ namespace BLL updateFireWork.WorkMeasures = newFireWork.WorkMeasures; updateFireWork.NextManId = newFireWork.NextManId; updateFireWork.States = newFireWork.States; + + updateFireWork.WorkAreaId = newItem.WorkAreaId; + updateFireWork.Reason = newItem.Reason; + updateFireWork.FireLevel = newItem.FireLevel; } updateFireWork.States = newFireWork.States; } @@ -1186,6 +1463,15 @@ namespace BLL CloseTime = Funs.GetNewDateTime(newItem.CloseTime), NextManId = newItem.NextManId, States = newItem.States, + + WorkAreaId=newItem.WorkAreaId, + WorkHeight=newItem.WorkHeight, + HeightLevel=newItem.HeightLevel, + FireWatchManName=newItem.FireWatchManName, + WorkLeaderName=newItem.WorkLeaderName, + WorkLeaderTel=newItem.WorkLeaderTel, + + }; if (newItem.States == Const.State_0) { @@ -1236,6 +1522,12 @@ namespace BLL updateHeightWork.EquipmentTools = newHeightWork.EquipmentTools; updateHeightWork.NextManId = newHeightWork.NextManId; updateHeightWork.States = newHeightWork.States; + updateHeightWork.WorkAreaId = newItem.WorkAreaId; + updateHeightWork.WorkHeight = newItem.WorkHeight; + updateHeightWork.HeightLevel = newItem.HeightLevel; + updateHeightWork.FireWatchManName = newItem.FireWatchManName; + updateHeightWork.WorkLeaderName = newItem.WorkLeaderName; + updateHeightWork.WorkLeaderTel = newItem.WorkLeaderTel; } updateHeightWork.States = newHeightWork.States; } @@ -1266,6 +1558,14 @@ namespace BLL CloseTime = Funs.GetNewDateTime(newItem.CloseTime), NextManId = newItem.NextManId, States = newItem.States, + + LimitedDescribe=newItem.LimitedDescribe, + IsBoolOther=newItem.IsBoolOther, + IsBoolHarmfulGas=newItem.IsBoolHarmfulGas, + TestResult=newItem.TestResult, + TestDate= Funs.GetNewDateTime(newItem.TestDate), + TestPerson=newItem.TestPerson, + VenStep=newItem.VenStep }; if (newItem.States == Const.State_0) { @@ -1315,6 +1615,14 @@ namespace BLL updateLimitedSpace.WorkMeasures = newLimitedSpace.WorkMeasures; updateLimitedSpace.NextManId = newLimitedSpace.NextManId; updateLimitedSpace.States = newLimitedSpace.States; + + updateLimitedSpace.LimitedDescribe = newItem.LimitedDescribe; + updateLimitedSpace.IsBoolOther = newItem.IsBoolOther; + updateLimitedSpace.IsBoolHarmfulGas = newItem.IsBoolHarmfulGas; + updateLimitedSpace.TestResult = newItem.TestResult; + updateLimitedSpace.TestDate = Funs.GetNewDateTime(newItem.TestDate); + updateLimitedSpace.TestPerson = newItem.TestPerson; + updateLimitedSpace.VenStep = newItem.VenStep; } updateLimitedSpace.States = newLimitedSpace.States; } @@ -1348,6 +1656,8 @@ namespace BLL CloseTime = Funs.GetNewDateTime(newItem.CloseTime), NextManId = newItem.NextManId, States = newItem.States, + + WorkAreaId=newItem.WorkAreaId }; if (newItem.States == Const.State_0) { @@ -1400,6 +1710,7 @@ namespace BLL updateRadialWork.WatchManContact = newRadialWork.WatchManContact; updateRadialWork.NextManId = newRadialWork.NextManId; updateRadialWork.States = newRadialWork.States; + updateRadialWork.WorkAreaId = newItem.WorkAreaId; } updateRadialWork.States = newRadialWork.States; } @@ -1430,6 +1741,11 @@ namespace BLL CloseTime = Funs.GetNewDateTime(newItem.CloseTime), NextManId = newItem.NextManId, States = newItem.States, + + WorkAreaId=newItem.WorkAreaId, + Reason=newItem.Reason, + FireWatchManName=newItem.FireWatchManName, + }; if (newItem.States == Const.State_0) { @@ -1479,6 +1795,10 @@ namespace BLL updateOpenCircuit.SafeMeasures = newOpenCircuit.SafeMeasures; updateOpenCircuit.NextManId = newOpenCircuit.NextManId; updateOpenCircuit.States = newOpenCircuit.States; + + updateOpenCircuit.WorkAreaId = newItem.WorkAreaId; + updateOpenCircuit.Reason = newItem.Reason; + updateOpenCircuit.FireWatchManName = newItem.FireWatchManName; } updateOpenCircuit.States = newOpenCircuit.States; } @@ -1508,6 +1828,10 @@ namespace BLL CloseTime = Funs.GetNewDateTime(newItem.CloseTime), NextManId = newItem.NextManId, States = newItem.States, + + WorkAreaId=newItem.WorkAreaId, + Reason=newItem.Reason, + FireWatchManName=newItem.FireWatchManName }; if (newItem.States == Const.State_0) { @@ -1556,6 +1880,10 @@ namespace BLL updateBreakGround.WorkMeasures = newBreakGround.WorkMeasures; updateBreakGround.NextManId = newBreakGround.NextManId; updateBreakGround.States = newBreakGround.States; + + updateBreakGround.WorkAreaId = newItem.WorkAreaId; + updateBreakGround.Reason = newItem.Reason; + updateBreakGround.FireWatchManName = newItem.FireWatchManName; } updateBreakGround.States = newBreakGround.States; } @@ -1669,6 +1997,15 @@ namespace BLL CloseTime = Funs.GetNewDateTime(newItem.CloseTime), NextManId = newItem.NextManId, States = newItem.States, + + WorkAreaId=newItem.WorkAreaId, + LiftingHeight=newItem.LiftingHeight, + FireWatchManName=newItem.FireWatchManName, + WorkLeaderName=newItem.WorkLeaderName, + WorkLeaderTel=newItem.WorkLeaderTel, + QzgName=newItem.QzgName, + QzgPhone=newItem.QzgPhone, + }; if (newItem.States == Const.State_0) { @@ -1718,12 +2055,112 @@ namespace BLL updateLiftingWork.CraneCapacity = newLiftingWork.CraneCapacity; updateLiftingWork.NextManId = newLiftingWork.NextManId; updateLiftingWork.States = newLiftingWork.States; + + updateLiftingWork.WorkAreaId = newItem.WorkAreaId; + updateLiftingWork.LiftingHeight = newItem.LiftingHeight; + updateLiftingWork.FireWatchManName = newItem.FireWatchManName; + updateLiftingWork.WorkLeaderName = newItem.WorkLeaderName; + updateLiftingWork.WorkLeaderTel = newItem.WorkLeaderTel; + updateLiftingWork.QzgName = newItem.QzgName; + updateLiftingWork.QzgPhone = newItem.QzgPhone; } updateLiftingWork.States = newLiftingWork.States; } } #endregion + #region 临时用电作业票 + if (newItem.MenuId == Const.ProjectElectricityMenuId) + { + Model.License_Electricity newElectricity = new Model.License_Electricity + { + ElectricityId = strLicenseId, + ProjectId = projectId, + LicenseCode = newItem.LicenseCode, + ApplyUnitId = newItem.ApplyUnitId, + ApplyManId = newItem.ApplyManId, + ApplyDate = Funs.GetNewDateTime(newItem.ApplyDate), + WorkPalce = newItem.WorkPalce, + WorkDepth = newItem.WorkDepth, + ValidityStartTime = Funs.GetNewDateTime(newItem.ValidityStartTime), + ValidityEndTime = Funs.GetNewDateTime(newItem.ValidityEndTime), + WorkMeasures = newItem.WorkMeasures, + CancelManId = newItem.CancelManId, + CancelReasons = newItem.CancelReasons, + CancelTime = Funs.GetNewDateTime(newItem.CancelTime), + CloseManId = newItem.CloseManId, + CloseReasons = newItem.CloseReasons, + CloseTime = Funs.GetNewDateTime(newItem.CloseTime), + NextManId = newItem.NextManId, + States = newItem.States, + + WorkAreaId = newItem.WorkAreaId, + Reason = newItem.Reason, + FireWatchManName = newItem.FireWatchManName, + WorkLeaderName= newItem.WorkLeaderName, + WorkLeaderTel = newItem.WorkLeaderTel + }; + if (newItem.States == Const.State_0) + { + newElectricity.NextManId = newItem.ApplyManId; + } + ////保存 + var updateElectricity = db.License_Electricity.FirstOrDefault(x => x.ElectricityId == strLicenseId); + if (updateElectricity == null) + { + newElectricity.ApplyDate = DateTime.Now; + strLicenseId = newElectricity.ElectricityId = SQLHelper.GetNewID(); + newElectricity.OldLicenseId = newItem.OldLicenseId; + newItem.LicenseCode = newElectricity.LicenseCode = CodeRecordsService.ReturnCodeByMenuIdProjectId(Const.ProjectElectricityMenuId, newElectricity.ProjectId, newElectricity.ApplyUnitId); + db.License_Electricity.InsertOnSubmit(newElectricity); + ////增加一条编码记录 + CodeRecordsService.InsertCodeRecordsByMenuIdProjectIdUnitId(Const.ProjectElectricityMenuId, newElectricity.ProjectId, newElectricity.ApplyUnitId, newElectricity.ElectricityId, newElectricity.ApplyDate); + } + else + { + if (newItem.States == Const.State_3) + { + updateElectricity.CloseManId = newElectricity.CloseManId; + updateElectricity.CloseReasons = newElectricity.CloseReasons; + updateElectricity.CloseTime = DateTime.Now; + if (newElectricity.ValidityEndTime.HasValue && newElectricity.ValidityEndTime < DateTime.Now) + { + updateElectricity.CloseTime = newElectricity.ValidityEndTime; + } + } + else if (newItem.States == Const.State_R) + { + updateElectricity.CancelManId = newElectricity.CancelManId; + updateElectricity.CancelReasons = newElectricity.CancelReasons; + updateElectricity.CancelTime = DateTime.Now; + if (newElectricity.ValidityEndTime.HasValue && newElectricity.ValidityEndTime < DateTime.Now) + { + updateElectricity.CancelTime = newElectricity.ValidityEndTime; + } + } + else + { + updateElectricity.WorkPalce = newElectricity.WorkPalce; + updateElectricity.WorkDepth = newElectricity.WorkDepth; + updateElectricity.ValidityStartTime = newElectricity.ValidityStartTime; + updateElectricity.ValidityEndTime = newElectricity.ValidityEndTime; + updateElectricity.WorkMeasures = newElectricity.WorkMeasures; + updateElectricity.NextManId = newElectricity.NextManId; + updateElectricity.States = newElectricity.States; + + updateElectricity.WorkAreaId = newItem.WorkAreaId; + updateElectricity.Reason = newItem.Reason; + updateElectricity.FireWatchManName = newItem.FireWatchManName; + updateElectricity.WorkLeaderName = newItem.WorkLeaderName; + updateElectricity.WorkLeaderTel = newItem.WorkLeaderTel; + + + } + updateElectricity.States = newElectricity.States; + } + } + #endregion + #region 作业票【定稿】 if (newItem.MenuId == Const.ProjectLicenseManagerMenuId) { @@ -1880,23 +2317,26 @@ namespace BLL #region 新增下一步审核记录 if (newItem.IsAgree == true) { - var getCloseAllOperate = db.License_FlowOperate.FirstOrDefault(x => x.DataId == updateFlowOperate.DataId && (!x.IsClosed.HasValue || x.IsClosed == false) && (!x.IsFlowEnd.HasValue || x.IsFlowEnd == false)); - if (getCloseAllOperate == null) - { - var getNextFlowOperate = db.License_FlowOperate.FirstOrDefault(x => x.DataId == updateFlowOperate.DataId && x.IsFlowEnd == true); - ////判断审核步骤是否结束 - if (getNextFlowOperate != null) - { - /////最后一步是关闭所有 步骤 - getNextFlowOperate.IsClosed = true; + //修改只需要一个人审批直接通过 + + //var getCloseAllOperate = db.License_FlowOperate.FirstOrDefault(x => x.DataId == updateFlowOperate.DataId && (!x.IsClosed.HasValue || x.IsClosed == false) && (!x.IsFlowEnd.HasValue || x.IsFlowEnd == false)); + //if (getCloseAllOperate == null) + //{ + //var getNextFlowOperate = db.License_FlowOperate.FirstOrDefault(x => x.DataId == updateFlowOperate.DataId && x.IsFlowEnd == true); + var getNextFlowOperate = db.License_FlowOperate.FirstOrDefault(x => x.DataId == updateFlowOperate.DataId); + // ////判断审核步骤是否结束 + // if (getNextFlowOperate != null) + // { + /////最后一步是关闭所有 步骤 + getNextFlowOperate.IsClosed = true; getNextFlowOperate.OperaterTime = DateTime.Now; getNextFlowOperate.IsAgree = true; getNextFlowOperate.OperaterId = newItem.OperaterId; getNextFlowOperate.Opinion = "审核完成!"; boolIsFlowEnd = true; db.SubmitChanges(); - } - } + // } + //} #region 动火作业票 if (strMenuId == Const.ProjectFireWorkMenuId) @@ -2163,6 +2603,39 @@ namespace BLL } #endregion + #region 临时用电作业票 + if (strMenuId == Const.ProjectElectricityMenuId) + { + var getElectricity = db.License_Electricity.FirstOrDefault(x => x.ElectricityId == updateFlowOperate.DataId); + if (getElectricity != null) + { + getElectricity.NextManId = newItem.NextOperaterId; + if (newItem.IsAgree == true) + { + if (boolIsFlowEnd == true) + { + getElectricity.NextManId = null; + getElectricity.States = Const.State_2; + if (getElectricity.ValidityStartTime.HasValue && getElectricity.ValidityStartTime < DateTime.Now) + { + int days = 7; + if (getElectricity.ValidityEndTime.HasValue) + { + days = Convert.ToInt32((getElectricity.ValidityEndTime - getElectricity.ValidityStartTime).Value.TotalDays); + } + getElectricity.ValidityStartTime = DateTime.Now; + getElectricity.ValidityEndTime = DateTime.Now.AddDays(days); + } + } + } + else + { + getElectricity.States = Const.State_0; + } + db.SubmitChanges(); + } + } + #endregion if (!boolIsFlowEnd && !string.IsNullOrEmpty(newItem.NextOperaterId)) { List getUserIds = Funs.GetStrListByStr(newItem.NextOperaterId, ','); @@ -2291,6 +2764,7 @@ namespace BLL var getAllFlows = from x in db.License_FlowOperate where x.DataId == licenseInfo.LicenseId && (!x.IsFlowEnd.HasValue || x.IsFlowEnd == false) select x; + if (licenseInfo == null || string.IsNullOrEmpty(licenseInfo.LicenseId) || getAllFlows.Count() == 0) { getFlowOperate = (from x in db.Sys_MenuFlowOperate @@ -2617,6 +3091,17 @@ namespace BLL } #endregion + #region 临时用电作业票 + else if (newItem.MenuId == Const.ProjectElectricityMenuId) + { + var updateElectricity = db.License_Electricity.FirstOrDefault(x => x.ElectricityId == strLicenseId); + if (updateElectricity == null) + { + updateElectricity.NextManId = null; + updateElectricity.States = Const.State_C; + } + } + #endregion db.SubmitChanges(); } diff --git a/SGGL/BLL/Common/Const.cs b/SGGL/BLL/Common/Const.cs index 91bcdee0..699a4762 100644 --- a/SGGL/BLL/Common/Const.cs +++ b/SGGL/BLL/Common/Const.cs @@ -291,6 +291,11 @@ namespace BLL /// public static string WorkPost_SafetyManager = "e426e560-9906-4aba-843e-2daef9ebeb05"; + /// + /// HSE副经理岗位Id + /// + public static string WorkPost_SafetyManagerFu = "46AA7960-1D35-4D5B-8C8F-AA4C874D63C8"; + /// /// 无损检测工岗位Id /// @@ -1946,6 +1951,10 @@ namespace BLL /// 吊装作业票 /// public const string ProjectLiftingWorkMenuId = "A1BE3AB6-9D4A-41E7-8870-E73423165451"; + /// + /// 临时用电作业票 + /// + public const string ProjectElectricityMenuId = "48F64E0F-38B2-4BDC-9B61-6200BD02CBF5"; #endregion #region HSSE检查管理 diff --git a/SGGL/BLL/HSSE/License/LicensePublicService.cs b/SGGL/BLL/HSSE/License/LicensePublicService.cs index cc73baf2..658271d8 100644 --- a/SGGL/BLL/HSSE/License/LicensePublicService.cs +++ b/SGGL/BLL/HSSE/License/LicensePublicService.cs @@ -76,6 +76,11 @@ namespace BLL CloseTime = fireWork.CloseTime, NextManId=fireWork.NextManId, States = fireWork.States, + + WorkAreaId=fireWork.WorkAreaId, + Reason=fireWork.Reason, + FireLevel=fireWork.FireLevel, + }; db.License_FireWork.InsertOnSubmit(newFireWork); db.SubmitChanges(); @@ -105,7 +110,11 @@ namespace BLL newFireWork.CloseReasons = fireWork.CloseReasons; newFireWork.CloseTime = fireWork.CloseTime; newFireWork.NextManId = fireWork.NextManId; - newFireWork.States = fireWork.States; + newFireWork.States = fireWork.States; + + newFireWork.WorkAreaId = fireWork.WorkAreaId; + newFireWork.Reason = fireWork.Reason; + newFireWork.FireLevel = fireWork.FireLevel; db.SubmitChanges(); } } @@ -172,6 +181,14 @@ namespace BLL CloseTime = heightWork.CloseTime, NextManId = heightWork.NextManId, States = heightWork.States, + + WorkAreaId=heightWork.WorkAreaId, + WorkHeight=heightWork.WorkHeight, + HeightLevel=heightWork.HeightLevel, + FireWatchManName=heightWork.FireWatchManName, + WorkLeaderName=heightWork.WorkLeaderName, + WorkLeaderTel= heightWork.WorkLeaderTel, + }; db.License_HeightWork.InsertOnSubmit(newHeightWork); db.SubmitChanges(); @@ -203,6 +220,13 @@ namespace BLL newHeightWork.CloseTime = heightWork.CloseTime; newHeightWork.NextManId = heightWork.NextManId; newHeightWork.States = heightWork.States; + + newHeightWork.WorkAreaId = heightWork.WorkAreaId; + newHeightWork.WorkHeight = heightWork.WorkHeight; + newHeightWork.HeightLevel = heightWork.HeightLevel; + newHeightWork.FireWatchManName = heightWork.FireWatchManName; + newHeightWork.WorkLeaderName = heightWork.WorkLeaderName; + newHeightWork.WorkLeaderTel = heightWork.WorkLeaderTel; db.SubmitChanges(); } } @@ -269,6 +293,16 @@ namespace BLL CloseTime = limitedSpace.CloseTime, NextManId = limitedSpace.NextManId, States = limitedSpace.States, + + WorkAreaId=limitedSpace.WorkAreaId, + LimitedDescribe=limitedSpace.LimitedDescribe, + IsBoolOther=limitedSpace.IsBoolOther, + IsBoolHarmfulGas=limitedSpace.IsBoolHarmfulGas, + TestResult=limitedSpace.TestResult, + TestDate=limitedSpace.TestDate, + TestPerson=limitedSpace.TestPerson, + VenStep=limitedSpace.VenStep, + }; db.License_LimitedSpace.InsertOnSubmit(newLimitedSpace); db.SubmitChanges(); @@ -299,6 +333,15 @@ namespace BLL newLimitedSpace.CloseTime = limitedSpace.CloseTime; newLimitedSpace.NextManId = limitedSpace.NextManId; newLimitedSpace.States = limitedSpace.States; + + newLimitedSpace.WorkAreaId = limitedSpace.WorkAreaId; + newLimitedSpace.LimitedDescribe = limitedSpace.LimitedDescribe; + newLimitedSpace.IsBoolOther = limitedSpace.IsBoolOther; + newLimitedSpace.IsBoolHarmfulGas = limitedSpace.IsBoolHarmfulGas; + newLimitedSpace.TestResult = limitedSpace.TestResult; + newLimitedSpace.TestDate = limitedSpace.TestDate; + newLimitedSpace.TestPerson = limitedSpace.TestPerson; + newLimitedSpace.VenStep = limitedSpace.VenStep; db.SubmitChanges(); } } @@ -368,6 +411,9 @@ namespace BLL CloseTime = radialWork.CloseTime, NextManId = radialWork.NextManId, States = radialWork.States, + + WorkAreaId=radialWork.WorkAreaId, + }; db.License_RadialWork.InsertOnSubmit(newRadialWork); db.SubmitChanges(); @@ -408,6 +454,8 @@ namespace BLL newRadialWork.CloseTime = radialWork.CloseTime; newRadialWork.NextManId = radialWork.NextManId; newRadialWork.States = radialWork.States; + + newRadialWork.WorkAreaId = radialWork.WorkAreaId; db.SubmitChanges(); } } @@ -476,6 +524,11 @@ namespace BLL CloseTime = openCircuit.CloseTime, NextManId = openCircuit.NextManId, States = openCircuit.States, + + WorkAreaId=openCircuit.WorkAreaId, + Reason=openCircuit.Reason, + FireWatchManName=openCircuit.FireWatchManName, + }; db.License_OpenCircuit.InsertOnSubmit(newOpenCircuit); db.SubmitChanges(); @@ -507,6 +560,10 @@ namespace BLL newOpenCircuit.CloseTime = openCircuit.CloseTime; newOpenCircuit.NextManId = openCircuit.NextManId; newOpenCircuit.States = openCircuit.States; + + newOpenCircuit.WorkAreaId = openCircuit.WorkAreaId; + newOpenCircuit.Reason = openCircuit.Reason; + newOpenCircuit.FireWatchManName = openCircuit.FireWatchManName; db.SubmitChanges(); } } @@ -572,6 +629,11 @@ namespace BLL CloseTime = breakGround.CloseTime, NextManId = breakGround.NextManId, States = breakGround.States, + + WorkAreaId=breakGround.WorkAreaId, + Reason=breakGround.Reason, + FireWatchManName=breakGround.FireWatchManName, + }; db.License_BreakGround.InsertOnSubmit(newBreakGround); db.SubmitChanges(); @@ -602,6 +664,10 @@ namespace BLL newBreakGround.CloseTime = breakGround.CloseTime; newBreakGround.NextManId = breakGround.NextManId; newBreakGround.States = breakGround.States; + + newBreakGround.WorkAreaId = breakGround.WorkAreaId; + newBreakGround.Reason = breakGround.Reason; + newBreakGround.FireWatchManName = breakGround.FireWatchManName; db.SubmitChanges(); } } @@ -771,6 +837,15 @@ namespace BLL CloseTime = liftingWork.CloseTime, NextManId = liftingWork.NextManId, States = liftingWork.States, + + WorkAreaId=liftingWork.WorkAreaId, + LiftingHeight=liftingWork.LiftingHeight, + FireWatchManName=liftingWork.FireWatchManName, + WorkLeaderName=liftingWork.WorkLeaderName, + WorkLeaderTel=liftingWork.WorkLeaderTel, + QzgName=liftingWork.QzgName, + QzgPhone=liftingWork.QzgPhone, + }; db.License_LiftingWork.InsertOnSubmit(newLiftingWork); db.SubmitChanges(); @@ -802,6 +877,14 @@ namespace BLL newLiftingWork.CloseTime = liftingWork.CloseTime; newLiftingWork.NextManId = liftingWork.NextManId; newLiftingWork.States = liftingWork.States; + + newLiftingWork.WorkAreaId = liftingWork.WorkAreaId; + newLiftingWork.LiftingHeight = liftingWork.LiftingHeight; + newLiftingWork.FireWatchManName = liftingWork.FireWatchManName; + newLiftingWork.WorkLeaderName = liftingWork.WorkLeaderName; + newLiftingWork.WorkLeaderTel = liftingWork.WorkLeaderTel; + newLiftingWork.QzgName = liftingWork.QzgName; + newLiftingWork.QzgPhone = liftingWork.QzgPhone; db.SubmitChanges(); } } @@ -828,6 +911,117 @@ namespace BLL } #endregion + #region 临时用电作业票 + /// + /// 根据主键获取临时用电作业票 + /// + /// + /// + public static Model.License_Electricity GetElectricityById(string ElectricityId) + { + return Funs.DB.License_Electricity.FirstOrDefault(e => e.ElectricityId == ElectricityId); + } + + /// + /// 添加临时用电作业票 + /// + /// + public static void AddElectricity(Model.License_Electricity Electricity) + { + Model.SGGLDB db = Funs.DB; + Model.License_Electricity newElectricity = new Model.License_Electricity + { + ElectricityId = Electricity.ElectricityId, + ProjectId = Electricity.ProjectId, + LicenseCode = Electricity.LicenseCode, + ApplyUnitId = Electricity.ApplyUnitId, + ApplyManId = Electricity.ApplyManId, + ApplyDate = Electricity.ApplyDate, + WorkPalce = Electricity.WorkPalce, + WorkDepth = Electricity.WorkDepth, + ValidityStartTime = Electricity.ValidityStartTime, + ValidityEndTime = Electricity.ValidityEndTime, + WorkMeasures = Electricity.WorkMeasures, + CancelManId = Electricity.CancelManId, + CancelReasons = Electricity.CancelReasons, + CancelTime = Electricity.CancelTime, + CloseManId = Electricity.CloseManId, + CloseReasons = Electricity.CloseReasons, + CloseTime = Electricity.CloseTime, + NextManId = Electricity.NextManId, + States = Electricity.States, + + WorkAreaId= Electricity.WorkAreaId, + Reason = Electricity.Reason, + FireWatchManName = Electricity.FireWatchManName, + WorkLeaderName = Electricity.WorkLeaderName, + WorkLeaderTel = Electricity.WorkLeaderTel, + + + }; + db.License_Electricity.InsertOnSubmit(newElectricity); + db.SubmitChanges(); + ////增加一条编码记录 + CodeRecordsService.InsertCodeRecordsByMenuIdProjectIdUnitId(Const.ProjectElectricityMenuId, Electricity.ProjectId, Electricity.ApplyUnitId, Electricity.ElectricityId, Electricity.ApplyDate); + } + + /// + /// 修改临时用电作业票 + /// + /// + public static void UpdateElectricity(Model.License_Electricity Electricity) + { + Model.SGGLDB db = Funs.DB; + Model.License_Electricity newElectricity = db.License_Electricity.FirstOrDefault(e => e.ElectricityId == Electricity.ElectricityId); + if (newElectricity != null) + { + newElectricity.WorkPalce = Electricity.WorkPalce; + newElectricity.WorkDepth = Electricity.WorkDepth; + newElectricity.ValidityStartTime = Electricity.ValidityStartTime; + newElectricity.ValidityEndTime = Electricity.ValidityEndTime; + newElectricity.WorkMeasures = Electricity.WorkMeasures; + newElectricity.CancelManId = Electricity.CancelManId; + newElectricity.CancelReasons = Electricity.CancelReasons; + newElectricity.CancelTime = Electricity.CancelTime; + newElectricity.CloseManId = Electricity.CloseManId; + newElectricity.CloseReasons = Electricity.CloseReasons; + newElectricity.CloseTime = Electricity.CloseTime; + newElectricity.NextManId = Electricity.NextManId; + newElectricity.States = Electricity.States; + + newElectricity.WorkAreaId = Electricity.WorkAreaId; + newElectricity.Reason = Electricity.Reason; + newElectricity.FireWatchManName = Electricity.FireWatchManName; + newElectricity.WorkLeaderName = Electricity.WorkLeaderName; + newElectricity.WorkLeaderTel = Electricity.WorkLeaderTel; + db.SubmitChanges(); + } + } + + /// + /// 根据主键删除临时用电作业票 + /// + /// + public static void DeleteElectricityById(string ElectricityId) + { + Model.SGGLDB db = Funs.DB; + Model.License_Electricity Electricity = db.License_Electricity.FirstOrDefault(e => e.ElectricityId == ElectricityId); + if (Electricity != null) + { + ///删除编码表记录 + CodeRecordsService.DeleteCodeRecordsByDataId(ElectricityId); + ////删除附件 + CommonService.DeleteAttachFileById(ElectricityId); + ///删除-安全措施 + DeleteLicenseItemByDataId(ElectricityId); + ///删除作业票审核信息 + DeleteFlowOperateByDataId(ElectricityId); + db.License_Electricity.DeleteOnSubmit(Electricity); + db.SubmitChanges(); + } + } + #endregion + #endregion #region 作业票-安全措施 diff --git a/SGGL/BLL/HSSE/SitePerson/PersonService.cs b/SGGL/BLL/HSSE/SitePerson/PersonService.cs index 157e8e6e..0abd26a6 100644 --- a/SGGL/BLL/HSSE/SitePerson/PersonService.cs +++ b/SGGL/BLL/HSSE/SitePerson/PersonService.cs @@ -397,7 +397,10 @@ namespace BLL /// HSE人员的数量 public static int GetHSEPersonCountByUnitId(string unitId, string projectId) { - var q = (from x in Funs.DB.SitePerson_Person where x.UnitId == unitId && x.ProjectId == projectId && (x.WorkPostId == BLL.Const.WorkPost_HSSEEngineer || x.WorkPostId == BLL.Const.WorkPost_SafetyManager) && x.IsUsed == true select x).ToList(); + var q = (from x in Funs.DB.SitePerson_Person + join y in Funs.DB.Base_WorkPost on x.WorkPostId equals y.WorkPostId + where x.UnitId == unitId && x.ProjectId == projectId && y.IsHsse==true && x.IsUsed == true select x).ToList(); + //var q = (from x in Funs.DB.SitePerson_Person where x.UnitId == unitId && x.ProjectId == projectId && (x.WorkPostId == BLL.Const.WorkPost_HSSEEngineer || x.WorkPostId == BLL.Const.WorkPost_SafetyManager) && x.IsUsed == true select x).ToList(); return q.Count(); } diff --git a/SGGL/FineUIPro.Web/FineUIPro.Web.csproj b/SGGL/FineUIPro.Web/FineUIPro.Web.csproj index 4e4b636f..60ca25c6 100644 --- a/SGGL/FineUIPro.Web/FineUIPro.Web.csproj +++ b/SGGL/FineUIPro.Web/FineUIPro.Web.csproj @@ -1062,6 +1062,8 @@ + + @@ -11599,6 +11601,20 @@ BreakGroundView.aspx + + Electricity.aspx + ASPXCodeBehind + + + Electricity.aspx + + + ElectricityView.aspx + ASPXCodeBehind + + + ElectricityView.aspx + EquipmentSafetyList.aspx ASPXCodeBehind diff --git a/SGGL/FineUIPro.Web/HSSE/License/Electricity.aspx b/SGGL/FineUIPro.Web/HSSE/License/Electricity.aspx new file mode 100644 index 00000000..11b0ccba --- /dev/null +++ b/SGGL/FineUIPro.Web/HSSE/License/Electricity.aspx @@ -0,0 +1,122 @@ +<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="Electricity.aspx.cs" Inherits="FineUIPro.Web.HSSE.License.Electricity" %> + + + + + + + 临时用电作业票 + + + +
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/SGGL/FineUIPro.Web/HSSE/License/Electricity.aspx.cs b/SGGL/FineUIPro.Web/HSSE/License/Electricity.aspx.cs new file mode 100644 index 00000000..0d69be05 --- /dev/null +++ b/SGGL/FineUIPro.Web/HSSE/License/Electricity.aspx.cs @@ -0,0 +1,1077 @@ +using Aspose.Words; +using BLL; +using System; +using System.Collections.Generic; +using System.Data; +using System.Data.SqlClient; +using System.IO; +using System.Linq; +using System.Text; + +namespace FineUIPro.Web.HSSE.License +{ + public partial class Electricity : 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) + { + Funs.DropDownPageSize(this.ddlPageSize); + ////权限按钮方法 + this.GetButtonPower(); + this.ProjectId = this.CurrUser.LoginProjectId; + if (!string.IsNullOrEmpty(Request.Params["projectId"]) && Request.Params["projectId"] != this.CurrUser.LoginProjectId) + { + this.ProjectId = Request.Params["projectId"]; + } + + UnitService.InitUnitDropDownList(this.drpUnit, this.ProjectId, true); + if (BLL.ProjectUnitService.GetProjectUnitTypeByProjectIdUnitId(this.ProjectId, this.CurrUser.UnitId)) + { + this.drpUnit.SelectedValue = this.CurrUser.UnitId; + this.drpUnit.Enabled = false; + } + + this.drpStates.DataValueField = "Value"; + this.drpStates.DataTextField = "Text"; + this.drpStates.DataSource = LicensePublicService.drpStatesItem(); + this.drpStates.DataBind(); + this.drpStates.SelectedValue = Const._Null; + if (this.CurrUser != null && this.CurrUser.PageSize.HasValue) + { + Grid1.PageSize = this.CurrUser.PageSize.Value; + } + this.ddlPageSize.SelectedValue = Grid1.PageSize.ToString(); + // 绑定表格 + this.BindGrid(); + } + } + /// + /// 绑定数据 + /// + private void BindGrid() + { + string strSql = "SELECT license.ElectricityId,license.ProjectId,license.LicenseCode,license.ApplyUnitId,ApplyUnit.UnitName AS ApplyUnitName,license.ApplyManId,license.ApplyDate,license.WorkPalce,license.ValidityStartTime,license.ValidityEndTime,license.WorkMeasures,license.WorkDepth,license.States,license.WorkLeaderTel,license.WorkLeaderName" + + @" ,(CASE WHEN license.States=0 THEN '待提交' WHEN license.States=1 THEN '审核中' WHEN license.States=2 THEN '作业中' WHEN license.States=3 THEN '已关闭' WHEN license.States=-1 THEN '已取消' ELSE '未知' END) AS StatesName " + + @" FROM dbo.License_Electricity AS license " + + @" LEFT JOIN Base_Unit AS ApplyUnit ON license.ApplyUnitId =ApplyUnit.UnitId" + + @" WHERE license.ProjectId= '" + this.ProjectId + "'"; + List listStr = new List(); + + if (ProjectUnitService.GetProjectUnitTypeByProjectIdUnitId(this.ProjectId, this.CurrUser.UnitId)) + { + strSql += " AND license.ApplyUnitId = @UnitId"; ///状态为已完成 + listStr.Add(new SqlParameter("@UnitId", this.CurrUser.UnitId)); + } + if (this.drpUnit.SelectedValue != Const._Null) + { + strSql += " AND license.ApplyUnitId = @UnitId2"; + listStr.Add(new SqlParameter("@UnitId2", this.drpUnit.SelectedValue)); + } + if (!string.IsNullOrEmpty(this.drpStates.SelectedValue) && this.drpStates.SelectedValue != Const._Null) + { + strSql += " AND license.States = @States"; + listStr.Add(new SqlParameter("@States", this.drpStates.SelectedValue)); + } + 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(); + } + + /// + /// 改变索引事件 + /// + /// + /// + protected void Grid1_PageIndexChange(object sender, GridPageEventArgs e) + { + Grid1.PageIndex = e.NewPageIndex; + BindGrid(); + } + + /// + /// 分页下拉选择事件 + /// + /// + /// + protected void ddlPageSize_SelectedIndexChanged(object sender, EventArgs e) + { + Grid1.PageSize = Convert.ToInt32(ddlPageSize.SelectedValue); + BindGrid(); + } + + /// + /// 排序 + /// + /// + /// + protected void Grid1_Sort(object sender, FineUIPro.GridSortEventArgs e) + { + BindGrid(); + } + + /// + /// 关闭弹出窗口 + /// + /// + /// + protected void Window1_Close(object sender, EventArgs e) + { + BindGrid(); + } + #endregion + + #region 查询 + /// + /// 查询 + /// + /// + /// + protected void TextBox_TextChanged(object sender, EventArgs e) + { + this.BindGrid(); + } + #endregion + + #region 编辑 + /// + /// 双击事件 + /// + /// + /// + protected void Grid1_RowDoubleClick(object sender, GridRowClickEventArgs e) + { + this.EditData(); + } + + /// + /// 右键编辑事件 + /// + /// + /// + protected void btnMenuView_Click(object sender, EventArgs e) + { + this.EditData(); + } + + /// + /// 编辑数据方法 + /// + private void EditData() + { + if (Grid1.SelectedRowIndexArray.Length == 0) + { + Alert.ShowInTop("请至少选择一条记录!", MessageBoxIcon.Warning); + return; + } + string id = Grid1.SelectedRowID; + PageContext.RegisterStartupScript(Window1.GetShowReference(String.Format("ElectricityView.aspx?ElectricityId={0}", id, "查看 - "))); + } + #endregion + + #region 删除 + /// + /// 右键删除事件 + /// + /// + /// + protected void btnMenuDelete_Click(object sender, EventArgs e) + { + if (Grid1.SelectedRowIndexArray.Length > 0) + { + foreach (int rowIndex in Grid1.SelectedRowIndexArray) + { + string rowID = Grid1.DataKeys[rowIndex][0].ToString(); + var Electricity = LicensePublicService.GetElectricityById(rowID); + if (Electricity != null) + { + LogService.AddSys_Log(this.CurrUser, Electricity.LicenseCode, Electricity.ElectricityId, Const.ProjectElectricityMenuId, Const.BtnDelete); + LicensePublicService.DeleteElectricityById(rowID); + } + } + + this.BindGrid(); + ShowNotify("删除数据成功!", MessageBoxIcon.Success); + } + } + #endregion + + #region 获取按钮权限 + /// + /// 获取按钮权限 + /// + /// + /// + private void GetButtonPower() + { + if (Request.Params["value"] == "0") + { + return; + } + var buttonList = BLL.CommonService.GetAllButtonList(this.CurrUser.LoginProjectId, this.CurrUser.UserId, BLL.Const.ProjectElectricityMenuId); + if (buttonList.Count() > 0) + { + //if (buttonList.Contains(BLL.Const.BtnAdd)) + //{ + // this.btnNew.Hidden = false; + //} + if (buttonList.Contains(BLL.Const.BtnModify)) + { + this.btnMenuView.Hidden = false; + } + if (buttonList.Contains(BLL.Const.BtnDelete)) + { + this.btnMenuDelete.Hidden = false; + } + } + } + #endregion + + #region 导出按钮 + /// 导出按钮 + /// + /// + /// + protected void btnOut_Click(object sender, EventArgs e) + { + Response.ClearContent(); + string filename = Funs.GetNewFileName(); + Response.AddHeader("content-disposition", "attachment; filename=" + System.Web.HttpUtility.UrlEncode("动土作业票" + filename, System.Text.Encoding.UTF8) + ".xls"); + Response.ContentType = "application/excel"; + Response.ContentEncoding = Encoding.UTF8; + this.Grid1.PageSize = this.Grid1.RecordCount; + this.BindGrid(); + Response.Write(GetGridTableHtml(Grid1)); + Response.End(); + } + #endregion + + #region 打印 + protected void btnPrinter_Click(object sender, EventArgs e) + { + if (Grid1.SelectedRowIndexArray.Length == 0) + { + Alert.ShowInTop("请至少选择一条记录!", MessageBoxIcon.Warning); + return; + } + string Id = Grid1.SelectedRowID; + + string rootPath = Server.MapPath("~/"); + string initTemplatePath = string.Empty; + string uploadfilepath = string.Empty; + string newUrl = string.Empty; + string filePath = string.Empty; + initTemplatePath = "File\\Word\\HSSE\\动土作业票.doc"; + uploadfilepath = rootPath + initTemplatePath; + newUrl = uploadfilepath.Replace(".doc", string.Format("{0:yyyy-MM}", DateTime.Now) + ".doc"); + filePath = initTemplatePath.Replace(".doc", string.Format("{0:yyyy-MM}", DateTime.Now) + ".pdf"); + File.Copy(uploadfilepath, newUrl); + ///更新书签 + var getElectricity = LicensePublicService.GetElectricityById(Id); + Document doc = new Aspose.Words.Document(newUrl); + Bookmark bookmarkLicenseCode = doc.Range.Bookmarks["LicenseCode"];//编号 + if (bookmarkLicenseCode != null) + { + if (getElectricity != null) + { + bookmarkLicenseCode.Text = getElectricity.LicenseCode; + } + } + Bookmark bookmarkApplyManName = doc.Range.Bookmarks["ApplyManName"];//申请人 + if (bookmarkApplyManName != null) + { + if (getElectricity != null) + { + var getUser = UserService.GetUserByUserId(getElectricity.ApplyManId); + if (getUser != null) + { + bookmarkApplyManName.Text = getUser.UserName; + } + + + } + } + Bookmark bookmarkUnitName = doc.Range.Bookmarks["UnitName"];//申请单位 + if (bookmarkUnitName != null) + { + if (getElectricity != null) + { + if (!string.IsNullOrEmpty(getElectricity.ApplyUnitId)) + { + bookmarkUnitName.Text = BLL.UnitService.GetUnitNameByUnitId(getElectricity.ApplyUnitId); + } + + } + } + Bookmark bookmarkWorkPalce = doc.Range.Bookmarks["WorkPalce"];//作业地点 + if (bookmarkWorkPalce != null) + { + if (getElectricity != null) + { + bookmarkWorkPalce.Text = getElectricity.WorkPalce; + + } + } + Bookmark bookmarkWorkDepth = doc.Range.Bookmarks["WorkDepth"];//开挖深度 + if (bookmarkWorkDepth != null) + { + if (getElectricity != null) + { + bookmarkWorkDepth.Text = getElectricity.WorkDepth; + + } + } + Bookmark bookmarkValidityDate = doc.Range.Bookmarks["ValidityDate"];//有效期限 + if (bookmarkValidityDate != null) + { + if (getElectricity != null) + { + if (getElectricity.ValidityStartTime.HasValue) + { + + bookmarkValidityDate.Text = getElectricity.ValidityStartTime.Value.Year + "年" + getElectricity.ValidityStartTime.Value.Month + "月" + getElectricity.ValidityStartTime.Value.Day + "日" + getElectricity.ValidityStartTime.Value.Hour + "时至"; + if (getElectricity.ValidityEndTime.HasValue) + { + bookmarkValidityDate.Text += getElectricity.ValidityEndTime.Value.Year + "年" + getElectricity.ValidityEndTime.Value.Month + "月" + getElectricity.ValidityEndTime.Value.Day + "日" + getElectricity.ValidityEndTime.Value.Hour + "时"; + } + } + } + } + Bookmark bookmarkWorkMeasures = doc.Range.Bookmarks["WorkMeasures"];//作业内容 + if (bookmarkWorkMeasures != null) + { + if (getElectricity != null) + { + bookmarkWorkMeasures.Text = getElectricity.WorkMeasures; + + } + } + + + + + var GetLicenseItemList = LicensePublicService.GetLicenseItemListByDataId(Id); + if (GetLicenseItemList.Count > 0) + { + var item1 = GetLicenseItemList.FirstOrDefault(x => x.SortIndex == 1); + if (item1 != null) + { + if (item1.IsUsed == true) + { + Bookmark bookmarkUser1 = doc.Range.Bookmarks["User1"];//确认执行 + if (bookmarkUser1 != null) + { + bookmarkUser1.Text = "√"; + } + } + else + { + Bookmark bookmarkIsFit1 = doc.Range.Bookmarks["IsFit1"]; + if (bookmarkIsFit1 != null) + { + if (item1 != null) + { + bookmarkIsFit1.Text = "×"; + } + } + } + } + + + + var item2 = GetLicenseItemList.FirstOrDefault(x => x.SortIndex == 2); + if (item2 != null) + { + if (item2.IsUsed == true) + { + Bookmark bookmarkUser2 = doc.Range.Bookmarks["User2"];//确认执行 + if (bookmarkUser2 != null) + { + bookmarkUser2.Text = "√"; + } + } + else + { + Bookmark bookmarkIsFit2 = doc.Range.Bookmarks["IsFit2"]; + if (bookmarkIsFit2 != null) + { + if (item2 != null) + { + bookmarkIsFit2.Text = "×"; + } + } + } + } + var item3 = GetLicenseItemList.FirstOrDefault(x => x.SortIndex == 3); + if (item3 != null) + { + if (item3.IsUsed == true) + { + Bookmark bookmarkUser3 = doc.Range.Bookmarks["User3"];//确认执行 + if (bookmarkUser3 != null) + { + bookmarkUser3.Text = "√"; + } + } + else + { + Bookmark bookmarkIsFit3 = doc.Range.Bookmarks["IsFit3"]; + if (bookmarkIsFit3 != null) + { + if (item3 != null) + { + bookmarkIsFit3.Text = "×"; + } + } + } + } + + var item4 = GetLicenseItemList.FirstOrDefault(x => x.SortIndex == 4); + if (item4 != null) + { + if (item4.IsUsed == true) + { + Bookmark bookmarkUser4 = doc.Range.Bookmarks["User4"];//确认执行 + if (bookmarkUser4 != null) + { + bookmarkUser4.Text = "√"; + } + } + else + { + Bookmark bookmarkIsFit4 = doc.Range.Bookmarks["IsFit4"]; + if (bookmarkIsFit4 != null) + { + if (item4 != null) + { + bookmarkIsFit4.Text = "×"; + } + } + } + } + var item5 = GetLicenseItemList.FirstOrDefault(x => x.SortIndex == 5); + if (item5 != null) + { + if (item5.IsUsed == true) + { + Bookmark bookmarkUser5 = doc.Range.Bookmarks["User5"];//确认执行 + if (bookmarkUser5 != null) + { + bookmarkUser5.Text = "√"; + } + } + else + { + Bookmark bookmarkIsFit5 = doc.Range.Bookmarks["IsFit5"]; + if (bookmarkIsFit5 != null) + { + if (item5 != null) + { + bookmarkIsFit5.Text = "×"; + } + } + } + } + + var item6 = GetLicenseItemList.FirstOrDefault(x => x.SortIndex == 6); + if (item6 != null) + { + if (item6.IsUsed == true) + { + Bookmark bookmarkUser6 = doc.Range.Bookmarks["User6"];//确认执行 + if (bookmarkUser6 != null) + { + bookmarkUser6.Text = "√"; + } + } + else + { + Bookmark bookmarkIsFit6 = doc.Range.Bookmarks["IsFit6"]; + if (bookmarkIsFit6 != null) + { + if (item6 != null) + { + bookmarkIsFit6.Text = "×"; + } + } + } + } + var item7 = GetLicenseItemList.FirstOrDefault(x => x.SortIndex == 7); + if (item7 != null) + { + if (item7.IsUsed == true) + { + Bookmark bookmarkUser7 = doc.Range.Bookmarks["User7"];//确认执行 + if (bookmarkUser7 != null) + { + bookmarkUser7.Text = "√"; + } + } + else + { + Bookmark bookmarkIsFit7 = doc.Range.Bookmarks["IsFit7"]; + if (bookmarkIsFit7 != null) + { + if (item7 != null) + { + bookmarkIsFit7.Text = "×"; + } + } + } + } + + var item8 = GetLicenseItemList.FirstOrDefault(x => x.SortIndex == 8); + if (item8 != null) + { + if (item8.IsUsed == true) + { + Bookmark bookmarkUser8 = doc.Range.Bookmarks["User8"];//确认执行 + if (bookmarkUser8 != null) + { + bookmarkUser8.Text = "√"; + } + } + else + { + Bookmark bookmarkIsFit8 = doc.Range.Bookmarks["IsFit8"]; + if (bookmarkIsFit8 != null) + { + if (item8 != null) + { + bookmarkIsFit8.Text = "×"; + } + } + } + } + + var item9 = GetLicenseItemList.FirstOrDefault(x => x.SortIndex == 9); + if (item9 != null) + { + if (item9.IsUsed == true) + { + Bookmark bookmarkUser9 = doc.Range.Bookmarks["User9"];//确认执行 + if (bookmarkUser9 != null) + { + bookmarkUser9.Text = "√"; + } + } + else + { + Bookmark bookmarkIsFit9 = doc.Range.Bookmarks["IsFit9"]; + if (bookmarkIsFit9 != null) + { + if (item9 != null) + { + bookmarkIsFit9.Text = "×"; + } + } + } + } + + var item10 = GetLicenseItemList.FirstOrDefault(x => x.SortIndex == 10); + if (item10 != null) + { + if (item10.IsUsed == true) + { + Bookmark bookmarkUser10 = doc.Range.Bookmarks["User10"];//确认执行 + if (bookmarkUser10 != null) + { + bookmarkUser10.Text = "√"; + } + } + else + { + Bookmark bookmarkIsFit10 = doc.Range.Bookmarks["IsFit10"]; + if (bookmarkIsFit10 != null) + { + if (item10 != null) + { + bookmarkIsFit10.Text = "×"; + } + } + } + } + var item11 = GetLicenseItemList.FirstOrDefault(x => x.SortIndex == 11); + if (item11 != null) + { + if (item11.IsUsed == true) + { + Bookmark bookmarkUser11 = doc.Range.Bookmarks["User11"];//确认执行 + if (bookmarkUser11 != null) + { + bookmarkUser11.Text = "√"; + } + } + else + { + Bookmark bookmarkIsFit11 = doc.Range.Bookmarks["IsFit11"]; + if (bookmarkIsFit11 != null) + { + if (item11 != null) + { + bookmarkIsFit11.Text = "×"; + } + } + } + } + + var item12 = GetLicenseItemList.FirstOrDefault(x => x.SortIndex == 12); + if (item12 != null) + { + if (item12.IsUsed == true) + { + Bookmark bookmarkUser12 = doc.Range.Bookmarks["User12"];//确认执行 + if (bookmarkUser12 != null) + { + bookmarkUser12.Text = "√"; + } + } + else + { + Bookmark bookmarkIsFit12 = doc.Range.Bookmarks["IsFit12"]; + if (bookmarkIsFit12 != null) + { + if (item12 != null) + { + bookmarkIsFit12.Text = "×"; + } + } + } + } + + + } + //审核记录 + var getFlows = LicensePublicService.GetFlowOperateListByDataId(Id); + if (getFlows.Count() > 0) + { + var getF1 = getFlows.FirstOrDefault(x => x.SortIndex == 1); + if (getF1 != null) + { + var getUser = UserService.GetUserByUserId(getF1.OperaterId); + Bookmark bookmarkOpinion1 = doc.Range.Bookmarks["Opinion1"]; + if (bookmarkOpinion1 != null) + { + + + if (getUser != null) + { + if (getF1.IsAgree == true) + { + bookmarkOpinion1.Text = getF1.Opinion; + } + else + { + bookmarkOpinion1.Text = "不同意: " + getF1.Opinion; + } + } + + + } + Bookmark bookmarkOperaterMan1 = doc.Range.Bookmarks["OperaterMan1"]; + if (bookmarkOperaterMan1 != null) + { + if (getF1.OperaterTime.HasValue) + { + if (getUser != null) + { + DocumentBuilder builders = new DocumentBuilder(doc); + if (!string.IsNullOrEmpty(getUser.SignatureUrl) && File.Exists(rootPath + getUser.SignatureUrl)) + { + var file = rootPath + getUser.SignatureUrl; + builders.MoveToBookmark("OperaterMan1"); + builders.InsertImage(file, 80, 20); + } + else + { + bookmarkOperaterMan1.Text = getUser.UserName; + } + } + } + } + Bookmark bookmarkOperaterTime1 = doc.Range.Bookmarks["OperaterTime1"]; + if (bookmarkOperaterTime1 != null) + { + if (getF1.OperaterTime.HasValue) + { + bookmarkOperaterTime1.Text = string.Format("{0:yyyy-MM-dd HH:mm}", getF1.OperaterTime); + } + } + } + var getF2 = getFlows.FirstOrDefault(x => x.SortIndex == 2); + if (getF2 != null) + { + var getUser = UserService.GetUserByUserId(getF2.OperaterId); + Bookmark bookmarkOpinion2 = doc.Range.Bookmarks["Opinion2"]; + if (bookmarkOpinion2 != null) + { + + + if (getUser != null) + { + if (getF2.IsAgree == true) + { + bookmarkOpinion2.Text = getF2.Opinion; + } + else + { + bookmarkOpinion2.Text = "不同意: " + getF2.Opinion; + } + } + + + } + Bookmark bookmarkOperaterMan2 = doc.Range.Bookmarks["OperaterMan2"]; + if (bookmarkOperaterMan2 != null) + { + if (getF2.OperaterTime.HasValue) + { + if (getUser != null) + { + DocumentBuilder builders = new DocumentBuilder(doc); + if (!string.IsNullOrEmpty(getUser.SignatureUrl) && File.Exists(rootPath + getUser.SignatureUrl)) + { + var file = rootPath + getUser.SignatureUrl; + builders.MoveToBookmark("OperaterMan2"); + builders.InsertImage(file, 80, 20); + } + else + { + bookmarkOperaterMan2.Text = getUser.UserName; + } + } + } + } + Bookmark bookmarkOperaterTime2 = doc.Range.Bookmarks["OperaterTime2"]; + if (bookmarkOperaterTime2 != null) + { + if (getF2.OperaterTime.HasValue) + { + bookmarkOperaterTime2.Text = string.Format("{0:yyyy-MM-dd HH:mm}", getF2.OperaterTime); + } + } + } + var getF3 = getFlows.FirstOrDefault(x => x.SortIndex == 3); + if (getF3 != null) + { + var getUser = UserService.GetUserByUserId(getF3.OperaterId); + Bookmark bookmarkOpinion3 = doc.Range.Bookmarks["Opinion3"]; + if (bookmarkOpinion3 != null) + { + + + if (getUser != null) + { + if (getF3.IsAgree == true) + { + bookmarkOpinion3.Text = getF3.Opinion; + } + else + { + bookmarkOpinion3.Text = "不同意: " + getF3.Opinion; + } + } + + + } + Bookmark bookmarkOperaterMan3 = doc.Range.Bookmarks["OperaterMan3"]; + if (bookmarkOperaterMan3 != null) + { + if (getF3.OperaterTime.HasValue) + { + if (getUser != null) + { + DocumentBuilder builders = new DocumentBuilder(doc); + if (!string.IsNullOrEmpty(getUser.SignatureUrl) && File.Exists(rootPath + getUser.SignatureUrl)) + { + var file = rootPath + getUser.SignatureUrl; + builders.MoveToBookmark("OperaterMan3"); + builders.InsertImage(file, 80, 20); + } + else + { + bookmarkOperaterMan3.Text = getUser.UserName; + } + } + } + } + Bookmark bookmarkOperaterTime3 = doc.Range.Bookmarks["OperaterTime3"]; + if (bookmarkOperaterTime3 != null) + { + if (getF3.OperaterTime.HasValue) + { + bookmarkOperaterTime3.Text = string.Format("{0:yyyy-MM-dd HH:mm}", getF3.OperaterTime); + } + } + } + var getF4 = getFlows.FirstOrDefault(x => x.SortIndex == 4); + if (getF4 != null) + { + var getUser = UserService.GetUserByUserId(getF4.OperaterId); + Bookmark bookmarkOpinion4 = doc.Range.Bookmarks["Opinion4"]; + if (bookmarkOpinion4 != null) + { + + + if (getUser != null) + { + if (getF4.IsAgree == true) + { + bookmarkOpinion4.Text = getF4.Opinion; + } + else + { + bookmarkOpinion4.Text = "不同意: " + getF4.Opinion; + } + } + + + } + Bookmark bookmarkOperaterMan4 = doc.Range.Bookmarks["OperaterMan4"]; + if (bookmarkOperaterMan4 != null) + { + if (getF4.OperaterTime.HasValue) + { + if (getUser != null) + { + DocumentBuilder builders = new DocumentBuilder(doc); + if (!string.IsNullOrEmpty(getUser.SignatureUrl) && File.Exists(rootPath + getUser.SignatureUrl)) + { + var file = rootPath + getUser.SignatureUrl; + builders.MoveToBookmark("OperaterMan4"); + builders.InsertImage(file, 80, 20); + } + else + { + bookmarkOperaterMan4.Text = getUser.UserName; + } + } + } + } + Bookmark bookmarkOperaterTime4 = doc.Range.Bookmarks["OperaterTime4"]; + if (bookmarkOperaterTime4 != null) + { + if (getF4.OperaterTime.HasValue) + { + bookmarkOperaterTime4.Text = string.Format("{0:yyyy-MM-dd HH:mm}", getF4.OperaterTime); + } + } + } + var getF5 = getFlows.FirstOrDefault(x => x.SortIndex == 5); + if (getF5 != null) + { + var getUser = UserService.GetUserByUserId(getF5.OperaterId); + Bookmark bookmarkOpinion5 = doc.Range.Bookmarks["Opinion5"]; + if (bookmarkOpinion5 != null) + { + + + if (getUser != null) + { + if (getF5.IsAgree == true) + { + bookmarkOpinion5.Text = getF5.Opinion; + } + else + { + bookmarkOpinion5.Text = "不同意: " + getF5.Opinion; + } + } + + + } + Bookmark bookmarkOperaterMan5 = doc.Range.Bookmarks["OperaterMan5"]; + if (bookmarkOperaterMan5 != null) + { + if (getF5.OperaterTime.HasValue) + { + if (getUser != null) + { + DocumentBuilder builders = new DocumentBuilder(doc); + if (!string.IsNullOrEmpty(getUser.SignatureUrl) && File.Exists(rootPath + getUser.SignatureUrl)) + { + var file = rootPath + getUser.SignatureUrl; + builders.MoveToBookmark("OperaterMan5"); + builders.InsertImage(file, 80, 20); + } + else + { + bookmarkOperaterMan5.Text = getUser.UserName; + } + } + } + } + Bookmark bookmarkOperaterTime5 = doc.Range.Bookmarks["OperaterTime5"]; + if (bookmarkOperaterTime5 != null) + { + if (getF5.OperaterTime.HasValue) + { + bookmarkOperaterTime5.Text = string.Format("{0:yyyy-MM-dd HH:mm}", getF5.OperaterTime); + } + } + } + var getF6 = getFlows.FirstOrDefault(x => x.SortIndex == 6); + if (getF6 != null) + { + var getUser = UserService.GetUserByUserId(getF6.OperaterId); + Bookmark bookmarkOpinion6 = doc.Range.Bookmarks["Opinion6"]; + if (bookmarkOpinion6 != null) + { + + + if (getUser != null) + { + if (getF6.IsAgree == true) + { + bookmarkOpinion6.Text = getF6.Opinion; + } + else + { + bookmarkOpinion6.Text = "不同意: " + getF6.Opinion; + } + } + + + } + Bookmark bookmarkOperaterMan6 = doc.Range.Bookmarks["OperaterMan6"]; + if (bookmarkOperaterMan6 != null) + { + if (getF6.OperaterTime.HasValue) + { + if (getUser != null) + { + DocumentBuilder builders = new DocumentBuilder(doc); + if (!string.IsNullOrEmpty(getUser.SignatureUrl) && File.Exists(rootPath + getUser.SignatureUrl)) + { + var file = rootPath + getUser.SignatureUrl; + builders.MoveToBookmark("OperaterMan6"); + builders.InsertImage(file, 80, 20); + } + else + { + bookmarkOperaterMan6.Text = getUser.UserName; + } + } + } + } + Bookmark bookmarkOperaterTime6 = doc.Range.Bookmarks["OperaterTime6"]; + if (bookmarkOperaterTime6 != null) + { + if (getF6.OperaterTime.HasValue) + { + bookmarkOperaterTime6.Text = string.Format("{0:yyyy-MM-dd HH:mm}", getF6.OperaterTime); + } + } + } + } + + Bookmark bookmarkCance = doc.Range.Bookmarks["Cancel"];//取消 + if (bookmarkCance != null) + { + if (getElectricity != null) + { + if (!string.IsNullOrEmpty(getElectricity.CancelManId)) + { + var getUser = UserService.GetUserByUserId(getElectricity.CancelManId); + if (getUser != null) + { + if (!string.IsNullOrEmpty(getUser.SignatureUrl) && File.Exists(rootPath + getUser.SignatureUrl)) + { + var file = rootPath + getUser.SignatureUrl; + DocumentBuilder builders = new DocumentBuilder(doc); + builders.MoveToBookmark("Cancel"); + builders.InsertImage(file, 80, 20); + builders.Write("取消原因:" + getElectricity.CancelReasons + " 取消时间:" + string.Format("{0:yyyy-MM-dd HH:mm}", getElectricity.CancelTime)); + } + else + { + bookmarkCance.Text = getUser.UserName + " 取消原因:" + getElectricity.CancelReasons + " 取消时间:" + string.Format("{0:yyyy-MM-dd HH:mm}", getElectricity.CancelTime); + } + } + } + } + } + + Bookmark bookmarkClose = doc.Range.Bookmarks["Close"];//关闭 + if (bookmarkClose != null) + { + if (getElectricity != null) + { + if (!string.IsNullOrEmpty(getElectricity.CloseManId)) + { + var getUser = UserService.GetUserByUserId(getElectricity.CloseManId); + if (getUser != null) + { + if (!string.IsNullOrEmpty(getElectricity.CloseReasons)) + { + bookmarkClose.Text = getElectricity.CloseReasons + " 关闭时间:" + + string.Format("{0:yyyy-MM-dd HH:mm}", getElectricity.CloseTime) + "。"; + } + else if (!string.IsNullOrEmpty(getUser.SignatureUrl) && File.Exists(rootPath + getUser.SignatureUrl)) + { + var file = rootPath + getUser.SignatureUrl; + DocumentBuilder builders = new DocumentBuilder(doc); + builders.MoveToBookmark("Close"); + builders.InsertImage(file, 80, 20); + builders.Write("关闭时间:" + string.Format("{0:yyyy-MM-dd HH:mm}", getElectricity.CloseTime)); + } + else + { + bookmarkClose.Text = getUser.UserName + " 关闭时间:" + string.Format("{0:yyyy-MM-dd HH:mm}", getElectricity.CloseTime); + } + } + } + } + } + + doc.Save(newUrl); + //生成PDF文件 + string pdfUrl = newUrl.Replace(".doc", ".pdf"); + Document doc1 = new Aspose.Words.Document(newUrl); + //验证参数 + if (doc1 == null) { throw new Exception("Word文件无效"); } + doc1.Save(pdfUrl, Aspose.Words.SaveFormat.Pdf);//还可以改成其它格式 + string fileName = Path.GetFileName(filePath); + FileInfo info = new FileInfo(pdfUrl); + long fileSize = info.Length; + Response.Clear(); + Response.ContentType = "application/x-zip-compressed"; + Response.AddHeader("Content-Disposition", "attachment;filename=" + System.Web.HttpUtility.UrlEncode(fileName, System.Text.Encoding.UTF8)); + Response.AddHeader("Content-Length", fileSize.ToString()); + Response.TransmitFile(pdfUrl, 0, fileSize); + Response.Flush(); + Response.Close(); + File.Delete(newUrl); + File.Delete(pdfUrl); + } + #endregion + } +} \ No newline at end of file diff --git a/SGGL/FineUIPro.Web/HSSE/License/Electricity.aspx.designer.cs b/SGGL/FineUIPro.Web/HSSE/License/Electricity.aspx.designer.cs new file mode 100644 index 00000000..eb4c8753 --- /dev/null +++ b/SGGL/FineUIPro.Web/HSSE/License/Electricity.aspx.designer.cs @@ -0,0 +1,179 @@ +//------------------------------------------------------------------------------ +// <自动生成> +// 此代码由工具生成。 +// +// 对此文件的更改可能导致不正确的行为,如果 +// 重新生成代码,则所做更改将丢失。 +// +//------------------------------------------------------------------------------ + +namespace FineUIPro.Web.HSSE.License +{ + + + public partial class Electricity + { + + /// + /// form1 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::System.Web.UI.HtmlControls.HtmlForm form1; + + /// + /// PageManager1 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.PageManager PageManager1; + + /// + /// Panel1 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.Panel Panel1; + + /// + /// Grid1 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.Grid Grid1; + + /// + /// Toolbar2 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.Toolbar Toolbar2; + + /// + /// drpUnit 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.DropDownList drpUnit; + + /// + /// drpStates 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.RadioButtonList drpStates; + + /// + /// ToolbarFill1 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.ToolbarFill ToolbarFill1; + + /// + /// btnOut 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.Button btnOut; + + /// + /// lblNumber 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::System.Web.UI.WebControls.Label lblNumber; + + /// + /// ToolbarSeparator1 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.ToolbarSeparator ToolbarSeparator1; + + /// + /// ToolbarText1 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.ToolbarText ToolbarText1; + + /// + /// ddlPageSize 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.DropDownList ddlPageSize; + + /// + /// Window1 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.Window Window1; + + /// + /// Menu1 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.Menu Menu1; + + /// + /// btnMenuView 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.MenuButton btnMenuView; + + /// + /// btnPrinter 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.MenuButton btnPrinter; + + /// + /// btnMenuDelete 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.MenuButton btnMenuDelete; + } +} diff --git a/SGGL/FineUIPro.Web/HSSE/License/ElectricityView.aspx b/SGGL/FineUIPro.Web/HSSE/License/ElectricityView.aspx new file mode 100644 index 00000000..26a48405 --- /dev/null +++ b/SGGL/FineUIPro.Web/HSSE/License/ElectricityView.aspx @@ -0,0 +1,259 @@ +<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="ElectricityView.aspx.cs" Inherits="FineUIPro.Web.HSSE.License.ElectricityView" %> + + + + + + + 临时用电作业票 + + + + +
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/SGGL/FineUIPro.Web/HSSE/License/ElectricityView.aspx.cs b/SGGL/FineUIPro.Web/HSSE/License/ElectricityView.aspx.cs new file mode 100644 index 00000000..557d14e9 --- /dev/null +++ b/SGGL/FineUIPro.Web/HSSE/License/ElectricityView.aspx.cs @@ -0,0 +1,242 @@ +using BLL; +using System; +using System.Collections.Generic; +using System.Data; +using System.Data.SqlClient; +using System.Linq; + +namespace FineUIPro.Web.HSSE.License +{ + public partial class ElectricityView : PageBase + { + #region 定义项 + /// + /// 主键 + /// + private string ElectricityId + { + get + { + return (string)ViewState["ElectricityId"]; + } + set + { + ViewState["ElectricityId"] = value; + } + } + #endregion + + #region 加载 + /// + /// 加载页面 + /// + /// + /// + protected void Page_Load(object sender, EventArgs e) + { + if (!IsPostBack) + { + this.SimpleForm1.Title = UnitService.GetUnitNameByUnitId(Const.UnitId_CWCEC) + this.Title; + this.btnClose.OnClientClick = ActiveWindow.GetHideReference(); + this.ElectricityId = Request.Params["ElectricityId"]; + if (!string.IsNullOrEmpty(this.ElectricityId)) + { + var getElectricity = LicensePublicService.GetElectricityById(this.ElectricityId); + if (getElectricity != null) + { + this.lbLicenseCode.Text = getElectricity.LicenseCode; + this.txtApplyUnit.Text = UnitService.GetUnitNameByUnitId(getElectricity.ApplyUnitId); + this.txtApplyManName.Text = UserService.GetUserNameByUserId(getElectricity.ApplyManId); + this.txtWorkPalce.Text = getElectricity.WorkPalce; + this.txtReason.Text = getElectricity.Reason; + if (getElectricity.ValidityStartTime.HasValue) + { + this.txtWorkDate.Text = getElectricity.ValidityStartTime.Value.ToString("f") + " 至 "; + if (getElectricity.ValidityEndTime.HasValue) + { + this.txtWorkDate.Text += getElectricity.ValidityEndTime.Value.ToString("f"); + } + } + this.txtWorkMeasures.Text = getElectricity.WorkMeasures; + if (!string.IsNullOrEmpty(getElectricity.CancelManId)) + { + this.txtCance.Text = UserService.GetUserNameByUserId(getElectricity.CancelManId) + ";取消时间:" + + string.Format("{0:yyyy-MM-dd HH:mm}", getElectricity.CancelTime) + ";原因:" + getElectricity.CancelReasons + "。"; + } + if (!string.IsNullOrEmpty(getElectricity.CloseManId)) + { + if (!string.IsNullOrEmpty(getElectricity.CloseReasons)) + { + this.txtClose.Text = getElectricity.CloseReasons + " 关闭时间:" + + string.Format("{0:yyyy-MM-dd HH:mm}", getElectricity.CloseTime) + "。"; + } + else + { + this.txtClose.Text = UserService.GetUserNameByUserId(getElectricity.CloseManId) + ";关闭时间:" + + string.Format("{0:yyyy-MM-dd HH:mm}", getElectricity.CloseTime) + "。"; + } + } + } + } + // 绑定表格 + this.BindGrid(); + this.SetFlow(); + } + } + #endregion + + #region 获取审核记录信息 + /// + /// + /// + private void SetFlow() + { + var getFlows = LicensePublicService.GetFlowOperateListByDataId(this.ElectricityId); + if (getFlows.Count() > 0) + { + var getF1 = getFlows.FirstOrDefault(x => x.SortIndex == 1); + if (getF1 != null) + { + this.txtForm1.Title = getF1.AuditFlowName + ":"; + if (getF1.OperaterTime.HasValue) + { + if (getF1.IsAgree == true) + { + this.txtOpinion1.Text = "同意。"; + } + else + { + this.txtOpinion1.Text = getF1.Opinion; + } + this.txtName1.Text = UserService.GetUserNameByUserId(getF1.OperaterId); + this.txtTime1.Text = string.Format("{0:yyyy-MM-dd HH:mm}", getF1.OperaterTime); + } + } + var getF2 = getFlows.FirstOrDefault(x => x.SortIndex == 2); + if (getF2 != null) + { + this.txtForm2.Title = getF2.AuditFlowName + ":"; + if (getF2.OperaterTime.HasValue) + { + if (getF2.IsAgree == true) + { + this.txtOpinion2.Text = "同意。"; + } + else + { + this.txtOpinion2.Text = getF2.Opinion; + } + this.txtName2.Text = UserService.GetUserNameByUserId(getF2.OperaterId); + this.txtTime2.Text = string.Format("{0:yyyy-MM-dd HH:mm}", getF2.OperaterTime); + } + } + var getF3 = getFlows.FirstOrDefault(x => x.SortIndex == 3); + if (getF3 != null) + { + this.txtForm3.Title = getF3.AuditFlowName + ":"; + if (getF3.OperaterTime.HasValue) + { + if (getF3.IsAgree == true) + { + this.txtOpinion3.Text = "同意。"; + } + else + { + this.txtOpinion3.Text = getF3.Opinion; + } + this.txtName3.Text = UserService.GetUserNameByUserId(getF3.OperaterId); + this.txtTime3.Text = string.Format("{0:yyyy-MM-dd HH:mm}", getF3.OperaterTime); + } + } + var getF4 = getFlows.FirstOrDefault(x => x.SortIndex == 4); + if (getF4 != null) + { + this.txtForm4.Title = getF4.AuditFlowName + ":"; + if (getF4.OperaterTime.HasValue) + { + if (getF4.IsAgree == true) + { + this.txtOpinion4.Text = "同意。"; + } + else + { + this.txtOpinion4.Text = getF4.Opinion; + } + this.txtName4.Text = UserService.GetUserNameByUserId(getF4.OperaterId); + this.txtTime4.Text = string.Format("{0:yyyy-MM-dd HH:mm}", getF4.OperaterTime); + } + } + var getF5 = getFlows.FirstOrDefault(x => x.SortIndex == 5); + if (getF5 != null) + { + this.txtForm5.Title = getF5.AuditFlowName + ":"; + if (getF5.OperaterTime.HasValue) + { + if (getF5.IsAgree == true) + { + this.txtOpinion5.Text = "同意。"; + } + else + { + this.txtOpinion5.Text = getF5.Opinion; + } + this.txtName5.Text = UserService.GetUserNameByUserId(getF5.OperaterId); + this.txtTime5.Text = string.Format("{0:yyyy-MM-dd HH:mm}", getF5.OperaterTime); + } + } + var getF6 = getFlows.FirstOrDefault(x => x.SortIndex == 6); + if (getF6 != null) + { + this.txtForm6.Title = getF6.AuditFlowName + ":"; + if (getF6.OperaterTime.HasValue) + { + if (getF6.IsAgree == true) + { + this.txtOpinion6.Text = "同意。"; + } + else + { + this.txtOpinion6.Text = getF6.Opinion; + } + this.txtName6.Text = UserService.GetUserNameByUserId(getF6.OperaterId); + this.txtTime6.Text = string.Format("{0:yyyy-MM-dd HH:mm}", getF6.OperaterTime); + } + } + } + } + #endregion + + /// + /// 绑定数据 + /// + private void BindGrid() + { + string strSql = @"SELECT LicenseItemId,DataId,SortIndex,SafetyMeasures,(CASE WHEN IsUsed = 1 THEN '适用' ELSE '不适用' END) AS NoUsedName,ConfirmManId,U.UserName AS ConfirmManName" + + @" FROM License_LicenseItem AS L " + + @" LEFT JOIN Sys_User AS U ON L.ConfirmManId =U.UserId" + + @" WHERE L.DataId ='" + this.ElectricityId + "'"; + List listStr = new List(); + 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(); + } + + #region 附件查看 + /// + /// 附件查看 + /// + /// + /// + protected void btnAttachUrl_Click(object sender, EventArgs e) + { + if (!string.IsNullOrEmpty(this.ElectricityId)) + { + PageContext.RegisterStartupScript(WindowAtt.GetShowReference(String.Format("~/AttachFile/webuploader.aspx?toKeyId={0}&menuId={1}&type=-1", this.ElectricityId, Const.ProjectElectricityMenuId))); + } + } + #endregion + } +} \ No newline at end of file diff --git a/SGGL/FineUIPro.Web/HSSE/License/ElectricityView.aspx.designer.cs b/SGGL/FineUIPro.Web/HSSE/License/ElectricityView.aspx.designer.cs new file mode 100644 index 00000000..586573d5 --- /dev/null +++ b/SGGL/FineUIPro.Web/HSSE/License/ElectricityView.aspx.designer.cs @@ -0,0 +1,467 @@ +//------------------------------------------------------------------------------ +// <自动生成> +// 此代码由工具生成。 +// +// 对此文件的更改可能导致不正确的行为,如果 +// 重新生成代码,则所做更改将丢失。 +// +//------------------------------------------------------------------------------ + +namespace FineUIPro.Web.HSSE.License +{ + + + public partial class ElectricityView + { + + /// + /// form1 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::System.Web.UI.HtmlControls.HtmlForm form1; + + /// + /// PageManager1 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.PageManager PageManager1; + + /// + /// SimpleForm1 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.Form SimpleForm1; + + /// + /// lbLicenseCode 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.Label lbLicenseCode; + + /// + /// lbImageUrl 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.Label lbImageUrl; + + /// + /// txtApplyUnit 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.TextBox txtApplyUnit; + + /// + /// txtApplyManName 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.TextBox txtApplyManName; + + /// + /// txtWorkPalce 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.TextBox txtWorkPalce; + + /// + /// txtReason 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.TextBox txtReason; + + /// + /// txtWorkDate 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.TextBox txtWorkDate; + + /// + /// txtWorkMeasures 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.TextBox txtWorkMeasures; + + /// + /// Grid1 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.Grid Grid1; + + /// + /// txtForm1 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.Form txtForm1; + + /// + /// txtOpinion1 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.TextArea txtOpinion1; + + /// + /// Label6 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.Label Label6; + + /// + /// txtName1 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.Label txtName1; + + /// + /// txtTime1 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.Label txtTime1; + + /// + /// txtForm2 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.Form txtForm2; + + /// + /// txtOpinion2 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.TextArea txtOpinion2; + + /// + /// Label1 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.Label Label1; + + /// + /// txtName2 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.Label txtName2; + + /// + /// txtTime2 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.Label txtTime2; + + /// + /// txtForm3 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.Form txtForm3; + + /// + /// txtOpinion3 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.TextArea txtOpinion3; + + /// + /// Label2 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.Label Label2; + + /// + /// txtName3 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.Label txtName3; + + /// + /// txtTime3 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.Label txtTime3; + + /// + /// txtForm4 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.Form txtForm4; + + /// + /// txtOpinion4 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.TextArea txtOpinion4; + + /// + /// Label5 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.Label Label5; + + /// + /// txtName4 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.Label txtName4; + + /// + /// txtTime4 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.Label txtTime4; + + /// + /// txtForm5 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.Form txtForm5; + + /// + /// txtOpinion5 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.TextArea txtOpinion5; + + /// + /// Label9 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.Label Label9; + + /// + /// txtName5 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.Label txtName5; + + /// + /// txtTime5 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.Label txtTime5; + + /// + /// txtForm6 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.Form txtForm6; + + /// + /// txtOpinion6 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.TextArea txtOpinion6; + + /// + /// Label12 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.Label Label12; + + /// + /// txtName6 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.Label txtName6; + + /// + /// txtTime6 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.Label txtTime6; + + /// + /// txtCance 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.TextBox txtCance; + + /// + /// txtClose 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.TextBox txtClose; + + /// + /// Toolbar1 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.Toolbar Toolbar1; + + /// + /// lbTemp 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.Label lbTemp; + + /// + /// btnAttachUrl 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.Button btnAttachUrl; + + /// + /// ToolbarFill1 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.ToolbarFill ToolbarFill1; + + /// + /// btnClose 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.Button btnClose; + + /// + /// WindowAtt 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.Window WindowAtt; + } +} diff --git a/SGGL/FineUIPro.Web/common/mainProject2.aspx b/SGGL/FineUIPro.Web/common/mainProject2.aspx index 9043f130..66316df1 100644 --- a/SGGL/FineUIPro.Web/common/mainProject2.aspx +++ b/SGGL/FineUIPro.Web/common/mainProject2.aspx @@ -1,1297 +1,1012 @@ -<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="mainProject2.aspx.cs" Inherits="FineUIPro.Web.common.mainProject2" %> +using BLL; +using Newtonsoft.Json; +using System; +using System.Collections.Generic; +using System.Data; +using System.Data.SqlClient; +using System.IO; +using System.Linq; +using System.Web; +using System.Web.UI; +using System.Web.UI.WebControls; - - - - - 项目级首页(新) - - - - - - - - -
- -
-
-
-
-
安全统计
-
-
-
-

0000000000

-
累计安全人工时 -
-
-
-

0000000000

-
本月安全人工时 -
-
-
-

0

-
安全培训累计人员 -
-
-
-
-
-
安全管理人员
-
0
-
-
-
未遂事件
-
0
-
-
-
-
整改数据
-
-
-
0 -
-
总数
-
-
-
0 -
-
已完成
-
-
-
0 -
-
未完成
-
-
-
0% -
-
完成率
-
-
-
-
-
-
-
风险预警
-
-
-
-
-
-
资质预警
-
<%=getEarlyWarningCounts() %>
-
-
-
机械预警
-
<%=GetJxyjNum() %>
-
-
-
-
危大工程
-
-
-
<%=GetCompletedNum() %>
-
审批完成
-
-
-
<%=GetTrainPersonNum() %>
-
培训人次数
-
-
-
<%=GetConstructionNum() %>
-
施工个数
-
-
-
<%=GetFinishedNum() %>
-
完工个数
-
-
-
-
-
超危大工程
-
-
-
<%=GetSuperCompletedNum() %>
-
审批完成
-
-
-
<%=GetSuperTrainPersonNum() %>
-
培训人次数
-
-
-
<%=GetSuperConstructionNum() %>
-
施工个数
-
-
-
<%=GetSuperFinishedNum() %>
-
完工个数
-
-
-
-
-
-
-
-
作业许可
-
-
-
-
动火
-
<%=getWrokCount0() %>
-
-
-
高处
-
<%=getWrokCount1() %>
-
-
-
吊装
-
<%=getWrokCount2() %>
-
-
-
其他
-
<%=getWrokCount3() %>
-
-
-
- <%=getLicenseManager() %> - <%--
003-十一化建-合成氨区域-非高风险-T0001设备吊装
--%> - -
-
+ #endregion -
-
-
-
-
工程概括
-
-
-
工程名称:<%=spanProjectName %>
-
建设单位: <%=spanOwnUnit %>
-
施工单位: <%=spanSGUnit %>
-
监理单位:<%=spanJLUnit %>
-
工程概况:
-
-
-
-
-
-
-
-
-
- -
- - -
-
-
-
-
-
-
合同工期
-
0
-
-
-
合同到期时间
-
-
-
-
合同剩余
-
0
-
-
-
- -
-
-
赢得值曲线 - <%--
关键事项准点率90%
--%> -
-
- <%--
- -
--%> - -
-
-
质量概况
-
-
-
-
质量培训累计人员
-
0
-
-
-
施工方案审批量
-
0
-
-
-
-
-
-
-
-
-
-
-
-
-
工作台面
-
-
-
-
关键事项
-
0
-
-
-
待办事项
-
0
-
-
-
个人流程
-
0
-
-
-
已办任务
-
0
-
-
- - -
- -
-
- -
-
-
人员信息
-
-
-
-
当前现场人数
-
0
-
-
-
作业人员总数
-
0
-
-
-
管理人员总数
-
0
-
-
- -
- <%--
- -
--%> -
- -
-
-
- 材料到货 -
管道材料 - 设备材料
-
-
-
-
-
-
-

材料类别

-
-
-

设计量

-
-
-

采购量

-

采购量百分比

-
-
-

到货量

-

已到货百分比

-
-
-

领料量

-

已领料百分比

-
-
-
-
- <%=gdclHtml %> -
-
-
-
-
-
-
- - - - - - - - - - - - - - - - - - +} \ No newline at end of file diff --git a/SGGL/Model/APIItem/HSSE/CheckSpecialDetailItem.cs b/SGGL/Model/APIItem/HSSE/CheckSpecialDetailItem.cs index 707b91df..b5539e84 100644 --- a/SGGL/Model/APIItem/HSSE/CheckSpecialDetailItem.cs +++ b/SGGL/Model/APIItem/HSSE/CheckSpecialDetailItem.cs @@ -201,7 +201,7 @@ namespace Model /// /// 整改期限 /// - public DateTime? Rectification_Date { get; set; } + public string Rectification_Date { get; set; } } } diff --git a/SGGL/Model/APIItem/HSSE/LicenseDataItem.cs b/SGGL/Model/APIItem/HSSE/LicenseDataItem.cs index 7b395285..f6253ecf 100644 --- a/SGGL/Model/APIItem/HSSE/LicenseDataItem.cs +++ b/SGGL/Model/APIItem/HSSE/LicenseDataItem.cs @@ -277,7 +277,7 @@ namespace Model set; } /// - /// 作业负责人名字(射线、夜间) + /// 作业负责人名字(射线、夜间、高处) /// public string WorkLeaderName { @@ -285,7 +285,7 @@ namespace Model set; } /// - /// 作业负责人电话(射线、夜间) + /// 作业负责人电话(射线、夜间、高处) /// public string WorkLeaderTel { @@ -389,5 +389,114 @@ namespace Model get; set; } + + //新增 + public string WorkAreaName + { + get; + set; + } + /// + /// 区域 + /// + public string WorkAreaId + { + get; + set; + } + + /// + /// 原因 + /// + public string Reason + { + get; + set; + } + + /// + /// 动火作业级别 + /// + public string FireLevel + { + get; + set; + } + + /// + /// 空间内介质描述 + /// + public string LimitedDescribe + { + get; + set; + } + + /// + /// 是否存在其它介质 + /// + public bool? IsBoolOther + { + get; + set; + } + + /// + /// 作业是否耗氧或产生其它有毒有害气体 + /// + public bool? IsBoolHarmfulGas + { + get; + set; + } + + /// + /// 氧含量测试结果 + /// + public string TestResult + { + get; + set; + } + + /// + /// 测试时间 + /// + public string TestDate { get; set; } + + /// + /// 测试人 + /// + public string TestPerson { get; set; } + + /// + /// 通风措施 + /// + public string VenStep { get; set; } + + /// + /// 作业点高度 + /// + public string WorkHeight { get; set; } + + /// + /// 高处作业级别 + /// + public string HeightLevel { get; set; } + + /// + /// 吊装高度 + /// + public string LiftingHeight { get; set; } + + /// + /// 起重工姓名 + /// + public string QzgName { get; set; } + + /// + /// 起重工电话 + /// + public string QzgPhone { get; set; } } }