From 9c804196e732cbddb15d82c5bcdd5cd870d789f9 Mon Sep 17 00:00:00 2001 From: yhw0507 Date: Mon, 29 May 2023 09:09:30 +0800 Subject: [PATCH] =?UTF-8?q?202305291=E3=80=81=E4=BF=AE=E6=94=B9=E5=A5=96?= =?UTF-8?q?=E5=8A=B1=E9=80=9A=E7=9F=A5=E5=8D=95=E3=80=81=E5=A5=96=E6=83=A9?= =?UTF-8?q?=E9=80=9A=E7=9F=A5=E5=8D=95=E3=80=82?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- DataBase/版本日志/SGGLDB_V2023-04-29-001.sql | 178 ++++ .../SGGLDB_V2023-04-29-001版本日志.txt | 4 + .../SGGLDB_V2023-04-26-001版本日志.txt | 0 SGGL/BLL/API/APICommonService.cs | 4 +- SGGL/BLL/API/APIPersonService.cs | 11 +- .../HSSE/CostGoods/ExpenseDetailService.cs | 132 +-- SGGL/BLL/HSSE/CostGoods/ExpenseService.cs | 91 +- SGGL/FineUIPro.Web/BaseInfo/CostType.aspx | 116 +-- SGGL/FineUIPro.Web/BaseInfo/CostType.aspx.cs | 241 +---- .../BaseInfo/CostType.aspx.designer.cs | 141 +-- SGGL/FineUIPro.Web/FineUIPro.Web.csproj | 21 +- .../HSSE/Check/IncentiveNotice.aspx | 4 +- .../HSSE/Check/IncentiveNoticeAdd.aspx | 2 +- .../HSSE/Check/PunishNotice.aspx | 2 +- .../HSSE/Check/PunishNoticeAdd.aspx | 2 +- .../HSSE/Check/PunishNoticeAdd.aspx.cs | 2 +- .../HSSE/Check/PunishNoticeEdit.aspx | 2 +- .../HSSE/Check/PunishNoticeEdit.aspx.cs | 2 +- .../HSSE/Check/PunishNoticeView.aspx | 2 +- .../HSSE/Check/PunishNoticeView.aspx.cs | 2 +- .../FineUIPro.Web/HSSE/CostGoods/Expense.aspx | 166 ++- .../HSSE/CostGoods/Expense.aspx.cs | 317 ++++-- .../HSSE/CostGoods/Expense.aspx.designer.cs | 84 +- .../HSSE/CostGoods/ExpenseEdit.aspx | 477 +++------ .../HSSE/CostGoods/ExpenseEdit.aspx.cs | 538 ++-------- .../CostGoods/ExpenseEdit.aspx.designer.cs | 690 +++--------- .../HSSE/CostGoods/ExpenseUnit.aspx | 87 ++ .../HSSE/CostGoods/ExpenseUnit.aspx.cs | 446 ++++++++ .../CostGoods/ExpenseUnit.aspx.designer.cs | 161 +++ .../HSSE/CostGoods/ExpenseView.aspx | 464 +++------ .../HSSE/CostGoods/ExpenseView.aspx.cs | 135 +-- .../CostGoods/ExpenseView.aspx.designer.cs | 562 +++------- .../ZHGL/DataSync/HSSEData_HSSEEdit.aspx | 980 +++++++++--------- SGGL/FineUIPro.Web/common/PageBase.cs | 1 - SGGL/FineUIPro.Web/libman.json | 5 + SGGL/Model/Model.cs | 430 +++++++- SGGL/WebAPI/Controllers/PersonController.cs | 33 + .../PublishProfiles/FolderProfile.pubxml | 22 - .../PublishProfiles/FolderProfile1.pubxml | 2 +- .../PublishProfiles/FolderProfile2.pubxml | 17 - .../PublishProfiles/FolderProfile3.pubxml | 16 - .../PublishProfiles/FolderProfile4.pubxml | 18 - SGGL/WebAPI/WebAPI.csproj | 4 +- 43 files changed, 3070 insertions(+), 3544 deletions(-) create mode 100644 DataBase/版本日志/SGGLDB_V2023-04-29-001.sql create mode 100644 DataBase/版本日志/SGGLDB_V2023-04-29-001版本日志.txt rename DataBase/版本日志/{ => 已更新脚本}/SGGLDB_V2023-04-26-001版本日志.txt (100%) create mode 100644 SGGL/FineUIPro.Web/HSSE/CostGoods/ExpenseUnit.aspx create mode 100644 SGGL/FineUIPro.Web/HSSE/CostGoods/ExpenseUnit.aspx.cs create mode 100644 SGGL/FineUIPro.Web/HSSE/CostGoods/ExpenseUnit.aspx.designer.cs create mode 100644 SGGL/FineUIPro.Web/libman.json delete mode 100644 SGGL/WebAPI/Properties/PublishProfiles/FolderProfile.pubxml delete mode 100644 SGGL/WebAPI/Properties/PublishProfiles/FolderProfile2.pubxml delete mode 100644 SGGL/WebAPI/Properties/PublishProfiles/FolderProfile3.pubxml delete mode 100644 SGGL/WebAPI/Properties/PublishProfiles/FolderProfile4.pubxml diff --git a/DataBase/版本日志/SGGLDB_V2023-04-29-001.sql b/DataBase/版本日志/SGGLDB_V2023-04-29-001.sql new file mode 100644 index 00000000..94b01842 --- /dev/null +++ b/DataBase/版本日志/SGGLDB_V2023-04-29-001.sql @@ -0,0 +1,178 @@ +ALTER TABLE [dbo].[CostGoods_Expense] ALTER COLUMN ExpenseCode nvarchar(50) NULL +GO +ALTER TABLE CostGoods_Expense ALTER COLUMN CompileMan NVARCHAR(50) NULL +GO +ALTER TABLE CostGoods_Expense ALTER COLUMN CheckMan NVARCHAR(50) NULL +GO +ALTER TABLE CostGoods_Expense ALTER COLUMN ApproveMan NVARCHAR(50) NULL +GO + +ALTER TABLE CostGoods_ExpenseDetail add CostTypeName NVARCHAR(50) NULL +GO +ALTER TABLE CostGoods_ExpenseDetail add SortIndex int NULL +GO +ALTER TABLE CostGoods_ExpenseDetail add SupCostTypeId NVARCHAR(50) NULL +GO +ALTER TABLE CostGoods_ExpenseDetail add SupCostTypeName NVARCHAR(50) NULL +GO +ALTER TABLE CostGoods_ExpenseDetail add SupSortIndex int NULL +GO + +ALTER TABLE CostGoods_ExpenseDetail alter column CostMoney decimal(18, 2) NULL +GO + +CREATE TABLE [dbo].[Base_CostTypeItem]( + [CostTypeItemId] [nvarchar](50) NOT NULL, + [CostTypeId] [nvarchar](50) NULL, + [SortIndex] [int] NULL, + [CostTypeItemName] [nvarchar](50) NULL, + [Remark] [nvarchar](500) NULL, + CONSTRAINT [PK_Base_CostTypeItem] PRIMARY KEY CLUSTERED +( + [CostTypeItemId] 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 + +ALTER TABLE [dbo].[Base_CostTypeItem] WITH CHECK ADD CONSTRAINT [FK_Base_CostTypeItem_Base_CostType] FOREIGN KEY([CostTypeId]) +REFERENCES [dbo].[Base_CostType] ([CostTypeId]) +GO + +ALTER TABLE [dbo].[Base_CostTypeItem] CHECK CONSTRAINT [FK_Base_CostTypeItem_Base_CostType] +GO + +EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'ID' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'Base_CostTypeItem', @level2type=N'COLUMN',@level2name=N'CostTypeItemId' +GO + +EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'id' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'Base_CostTypeItem', @level2type=N'COLUMN',@level2name=N'CostTypeId' +GO + +EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'Base_CostTypeItem', @level2type=N'COLUMN',@level2name=N'SortIndex' +GO + +EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'Base_CostTypeItem', @level2type=N'COLUMN',@level2name=N'CostTypeItemName' +GO + +EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'ϸ' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'Base_CostTypeItem' +GO + +DELETE FROM Base_CostType +GO +ALTER TABLE Base_CostType ALTER COLUMN CostTypeCode INT NULL +GO +-- +INSERT INTO [dbo].[Base_CostType]([CostTypeId],[CostTypeCode],[CostTypeName],[Remark]) +VALUES('ca2dacae-ca5f-4104-aca1-3bd185b737b2',1,'ȫʩ','ҵҵּܡѹ봵ɨ') +GO + INSERT INTO [dbo].[Base_CostTypeItem]([CostTypeItemId],[CostTypeId],[SortIndex],[CostTypeItemName]) + VALUES('A1','ca2dacae-ca5f-4104-aca1-3bd185b737b2',1,'칫Ʒ') + GO + INSERT INTO [dbo].[Base_CostTypeItem]([CostTypeItemId],[CostTypeId],[SortIndex],[CostTypeItemName]) + VALUES('A2','ca2dacae-ca5f-4104-aca1-3bd185b737b2',2,'HSEѵ') + GO + INSERT INTO [dbo].[Base_CostTypeItem]([CostTypeItemId],[CostTypeId],[SortIndex],[CostTypeItemName]) + VALUES('A3','ca2dacae-ca5f-4104-aca1-3bd185b737b2',3,'ʾʶ') + GO + INSERT INTO [dbo].[Base_CostTypeItem]([CostTypeItemId],[CostTypeId],[SortIndex],[CostTypeItemName]) + VALUES('A4','ca2dacae-ca5f-4104-aca1-3bd185b737b2',4,'') + GO + INSERT INTO [dbo].[Base_CostTypeItem]([CostTypeItemId],[CostTypeId],[SortIndex],[CostTypeItemName]) + VALUES('A5','ca2dacae-ca5f-4104-aca1-3bd185b737b2',5,'ȫ') + GO + INSERT INTO [dbo].[Base_CostTypeItem]([CostTypeItemId],[CostTypeId],[SortIndex],[CostTypeItemName]) + VALUES('A6','ca2dacae-ca5f-4104-aca1-3bd185b737b2',6,'ȫ') + GO + INSERT INTO [dbo].[Base_CostTypeItem]([CostTypeItemId],[CostTypeId],[SortIndex],[CostTypeItemName]) + VALUES('A7','ca2dacae-ca5f-4104-aca1-3bd185b737b2',7,'ȫõ') + GO + INSERT INTO [dbo].[Base_CostTypeItem]([CostTypeItemId],[CostTypeId],[SortIndex],[CostTypeItemName]) + VALUES('A8','ca2dacae-ca5f-4104-aca1-3bd185b737b2',8,'ߴҵٱ߿׶') + GO + INSERT INTO [dbo].[Base_CostTypeItem]([CostTypeItemId],[CostTypeId],[SortIndex],[CostTypeItemName]) + VALUES('A9','ca2dacae-ca5f-4104-aca1-3bd185b737b2',9,'ƿ') + GO + INSERT INTO [dbo].[Base_CostTypeItem]([CostTypeItemId],[CostTypeId],[SortIndex],[CostTypeItemName]) + VALUES('A10','ca2dacae-ca5f-4104-aca1-3bd185b737b2',10,'ּܣ') + GO + INSERT INTO [dbo].[Base_CostTypeItem]([CostTypeItemId],[CostTypeId],[SortIndex],[CostTypeItemName]) + VALUES('A11','ca2dacae-ca5f-4104-aca1-3bd185b737b2',11,'ľ') + GO + INSERT INTO [dbo].[Base_CostTypeItem]([CostTypeItemId],[CostTypeId],[SortIndex],[CostTypeItemName]) + VALUES('A12','ca2dacae-ca5f-4104-aca1-3bd185b737b2',12,'ֽӹ') + GO + INSERT INTO [dbo].[Base_CostTypeItem]([CostTypeItemId],[CostTypeId],[SortIndex],[CostTypeItemName]) + VALUES('A13','ca2dacae-ca5f-4104-aca1-3bd185b737b2',13,'޿ռ') + GO + INSERT INTO [dbo].[Base_CostTypeItem]([CostTypeItemId],[CostTypeId],[SortIndex],[CostTypeItemName]) + VALUES('A14','ca2dacae-ca5f-4104-aca1-3bd185b737b2',14,'е豸') + GO + INSERT INTO [dbo].[Base_CostTypeItem]([CostTypeItemId],[CostTypeId],[SortIndex],[CostTypeItemName]) + VALUES('A15','ca2dacae-ca5f-4104-aca1-3bd185b737b2',15,'ɰҵ') + GO + INSERT INTO [dbo].[Base_CostTypeItem]([CostTypeItemId],[CostTypeId],[SortIndex],[CostTypeItemName]) + VALUES('A16','ca2dacae-ca5f-4104-aca1-3bd185b737b2',16,'') + GO + INSERT INTO [dbo].[Base_CostTypeItem]([CostTypeItemId],[CostTypeId],[SortIndex],[CostTypeItemName]) + VALUES('A17','ca2dacae-ca5f-4104-aca1-3bd185b737b2',17,'Ӧ') + GO + INSERT INTO [dbo].[Base_CostTypeItem]([CostTypeItemId],[CostTypeId],[SortIndex],[CostTypeItemName]) + VALUES('A18','ca2dacae-ca5f-4104-aca1-3bd185b737b2',18,'Գ') + GO + +INSERT INTO [dbo].[Base_CostType]([CostTypeId],[CostTypeCode],[CostTypeName],[Remark]) +VALUES('fa9e4e0c-8f0d-46c4-a659-682d4de1ca0f',2,'ְҵ','') +GO + INSERT INTO [dbo].[Base_CostTypeItem]([CostTypeItemId],[CostTypeId],[SortIndex],[CostTypeItemName]) + VALUES('B1','fa9e4e0c-8f0d-46c4-a659-682d4de1ca0f',1,'ʱʩˮ䡢ҵȣ') + GO + INSERT INTO [dbo].[Base_CostTypeItem]([CostTypeItemId],[CostTypeId],[SortIndex],[CostTypeItemName]) + VALUES('B2','fa9e4e0c-8f0d-46c4-a659-682d4de1ca0f',2,'Ʒ') + GO + INSERT INTO [dbo].[Base_CostTypeItem]([CostTypeItemId],[CostTypeId],[SortIndex],[CostTypeItemName]) + VALUES('B3','fa9e4e0c-8f0d-46c4-a659-682d4de1ca0f',3,'') + GO +INSERT INTO [dbo].[Base_CostType]([CostTypeId],[CostTypeCode],[CostTypeName],[Remark]) +VALUES('2c5b070a-ef8c-44f8-b35a-00316aed7d3a',3,'','ˮˮŷšΣʿơ') +GO + INSERT INTO [dbo].[Base_CostTypeItem]([CostTypeItemId],[CostTypeId],[SortIndex],[CostTypeItemName]) + VALUES('C1','2c5b070a-ef8c-44f8-b35a-00316aed7d3a',1,'') + GO + INSERT INTO [dbo].[Base_CostTypeItem]([CostTypeItemId],[CostTypeId],[SortIndex],[CostTypeItemName]) + VALUES('C2','2c5b070a-ef8c-44f8-b35a-00316aed7d3a',2,'ﳾ') + GO + INSERT INTO [dbo].[Base_CostTypeItem]([CostTypeItemId],[CostTypeId],[SortIndex],[CostTypeItemName]) + VALUES('C3','2c5b070a-ef8c-44f8-b35a-00316aed7d3a',3,'') + GO + INSERT INTO [dbo].[Base_CostTypeItem]([CostTypeItemId],[CostTypeId],[SortIndex],[CostTypeItemName]) + VALUES('C4','2c5b070a-ef8c-44f8-b35a-00316aed7d3a',4,'ˮ') + GO + INSERT INTO [dbo].[Base_CostTypeItem]([CostTypeItemId],[CostTypeId],[SortIndex],[CostTypeItemName]) + VALUES('C5','2c5b070a-ef8c-44f8-b35a-00316aed7d3a',5,'Σʿ') + GO + INSERT INTO [dbo].[Base_CostTypeItem]([CostTypeItemId],[CostTypeId],[SortIndex],[CostTypeItemName]) + VALUES('C6','2c5b070a-ef8c-44f8-b35a-00316aed7d3a',6,'') + GO + +INSERT INTO [dbo].[Base_CostType]([CostTypeId],[CostTypeCode],[CostTypeName],[Remark]) +VALUES('278e29bc-fa92-463a-88de-f481d41a69e0',4,'ʩ','ֳΧһͼҵ־ݳòϴšʩƷƷ') +GO + INSERT INTO [dbo].[Base_CostTypeItem]([CostTypeItemId],[CostTypeId],[SortIndex],[CostTypeItemName]) + VALUES('D1','278e29bc-fa92-463a-88de-f481d41a69e0',1,'ݳò') + GO + INSERT INTO [dbo].[Base_CostTypeItem]([CostTypeItemId],[CostTypeId],[SortIndex],[CostTypeItemName]) + VALUES('D2','278e29bc-fa92-463a-88de-f481d41a69e0',2,'ʶ') + GO + INSERT INTO [dbo].[Base_CostTypeItem]([CostTypeItemId],[CostTypeId],[SortIndex],[CostTypeItemName]) + VALUES('D3','278e29bc-fa92-463a-88de-f481d41a69e0',3,'ǻۻ') + GO + + +ALTER TABLE [dbo].[CostGoods_Expense] ADD SortIndex int null +GO +EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'CostGoods_Expense', @level2type=N'COLUMN',@level2name=N'SortIndex' +GO + +ALTER TABLE [dbo].[CostGoods_Expense] ADD Year int null +GO +EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'CostGoods_Expense', @level2type=N'COLUMN',@level2name=N'Year' +GO diff --git a/DataBase/版本日志/SGGLDB_V2023-04-29-001版本日志.txt b/DataBase/版本日志/SGGLDB_V2023-04-29-001版本日志.txt new file mode 100644 index 00000000..002f863e --- /dev/null +++ b/DataBase/版本日志/SGGLDB_V2023-04-29-001版本日志.txt @@ -0,0 +1,4 @@ +--ADD BY YangHongwei 2023-05-29 +1、修改奖励通知单、奖惩通知单。 +2、费用计划页面开发。 +--END \ No newline at end of file diff --git a/DataBase/版本日志/SGGLDB_V2023-04-26-001版本日志.txt b/DataBase/版本日志/已更新脚本/SGGLDB_V2023-04-26-001版本日志.txt similarity index 100% rename from DataBase/版本日志/SGGLDB_V2023-04-26-001版本日志.txt rename to DataBase/版本日志/已更新脚本/SGGLDB_V2023-04-26-001版本日志.txt diff --git a/SGGL/BLL/API/APICommonService.cs b/SGGL/BLL/API/APICommonService.cs index 550fd22f..4b3ceec3 100644 --- a/SGGL/BLL/API/APICommonService.cs +++ b/SGGL/BLL/API/APICommonService.cs @@ -80,11 +80,11 @@ var getUser = db.Person_Persons.FirstOrDefault(x => x.PersonId == personId); if (getUser != null && !string.IsNullOrEmpty(getUser.OpenId)) { - if (thing2.Length > 20) + if (!string.IsNullOrEmpty(thing2) && thing2.Length > 20) { thing2 = thing2.Substring(0, 20); } - if (name1.Length > 10) + if (!string.IsNullOrEmpty(name1) && name1.Length > 10) { name1 = name1.Substring(0, 10); } diff --git a/SGGL/BLL/API/APIPersonService.cs b/SGGL/BLL/API/APIPersonService.cs index 67f27231..3251c7db 100644 --- a/SGGL/BLL/API/APIPersonService.cs +++ b/SGGL/BLL/API/APIPersonService.cs @@ -133,7 +133,7 @@ namespace BLL person.AttachUrl2 = APIUpLoadFileService.getFileUrl(getProjectPerson.PersonId + "#2", null); person.AttachUrl3 = APIUpLoadFileService.getFileUrl(getProjectPerson.PersonId + "#3", null); person.AttachUrl4 = getAttachUrl4(getProjectPerson.PersonId); - //person.AttachUrl5 = APIUpLoadFileService.getFileUrl(personId + "#5", null); + person.AttachUrl5 = APIUpLoadFileService.getFileUrl(getProjectPerson.PersonId + "#5", null); } var getPerson = db.Person_Persons.FirstOrDefault(x => x.IdentityCard == idcard); if (getPerson != null) @@ -742,6 +742,15 @@ namespace BLL using (Model.SGGLDB db = new Model.SGGLDB(Funs.ConnString)) { var getPerson = db.Person_Persons.FirstOrDefault(x => x.IdentityCard == person.IdentityCard || x.PersonId == person.PersonId); + if (getPerson == null) + { + var getSitePerson = db.SitePerson_Person.FirstOrDefault(x => x.SitePersonId ==person.PersonId); + if (getSitePerson != null) + { + getPerson = db.Person_Persons.FirstOrDefault(x => x.IdentityCard == getSitePerson.IdentityCard || x.PersonId == getSitePerson.PersonId); + } + } + if (getPerson != null) { if (!string.IsNullOrEmpty(person.PhotoUrl)) diff --git a/SGGL/BLL/HSSE/CostGoods/ExpenseDetailService.cs b/SGGL/BLL/HSSE/CostGoods/ExpenseDetailService.cs index 2652bef0..65643517 100644 --- a/SGGL/BLL/HSSE/CostGoods/ExpenseDetailService.cs +++ b/SGGL/BLL/HSSE/CostGoods/ExpenseDetailService.cs @@ -6,110 +6,53 @@ namespace BLL { public class ExpenseDetailService { - public static decimal? GetSumCostMoneyByExpenseId(string expenseId) - { - return (from x in Funs.DB.CostGoods_ExpenseDetail where x.ExpenseId == expenseId select x.CostMoney).Sum(); - } - + public static List GetExpenseDetailsByExpenseId(string expenseId) { return (from x in Funs.DB.CostGoods_ExpenseDetail where x.ExpenseId == expenseId select x).ToList(); } - public static decimal GetSumCostMoneyByExpenseIdAndType(string expenseId, string costType) - { - Model.CostGoods_ExpenseDetail detail = (from x in Funs.DB.CostGoods_ExpenseDetail where x.ExpenseId == expenseId && x.CostType == costType select x).FirstOrDefault(); - if (detail != null) - { - return detail.CostMoney ?? 0; - } - else - { - return 0; - } - } - - /// - /// 根据单位和时间获取费用明细集合 - /// - /// - /// - /// - /// - public static List GetCostDetailsByUnitId(string unitId, DateTime startTime, DateTime endTime) - { - using (Model.SGGLDB db = new Model.SGGLDB(Funs.ConnString)) - { - return (from x in db.CostGoods_ExpenseDetail - join y in db.CostGoods_Expense on x.ExpenseId equals y.ExpenseId - where y.UnitId == unitId && y.States == BLL.Const.State_2 && y.ApproveDate >= startTime && y.ApproveDate < endTime - select x).Distinct().ToList(); - } - } - - /// - /// 根据单位和时间及费用类型获取当期费用 - /// - /// - /// - /// - /// - /// - public static decimal GetCostDetailsByUnitIdAndCostType(string unitId, DateTime startTime, DateTime endTime, string costType) - { - using (Model.SGGLDB db = new Model.SGGLDB(Funs.ConnString)) - { - decimal cost = 0; - var q = from x in db.CostGoods_ExpenseDetail - join y in db.CostGoods_Expense on x.ExpenseId equals y.ExpenseId - join z in db.Sys_FlowOperate - on y.ExpenseId equals z.DataId - where y.UnitId == unitId && y.States == BLL.Const.State_2 && z.State == BLL.Const.State_2 && z.OperaterTime >= startTime && z.OperaterTime < endTime && x.CostType.Contains(costType) - select x.CostMoney; - foreach (var item in q) - { - if (item != null) - { - cost += Funs.GetNewDecimalOrZero(item.ToString()); - } - } - return cost; - //return (from x in Funs.DB.CostGoods_ExpenseDetail - // join y in Funs.DB.CostGoods_Expense on x.ExpenseId equals y.ExpenseId - // where y.UnitId == unitId && y.States == BLL.Const.State_2 && y.ApproveDate >= startTime && y.ApproveDate < endTime && x.CostType.Contains(costType) - // select x.CostMoney ?? 0).Sum(); - } - } /// /// 增加费用明细信息 /// /// 费用明细实体 - public static void AddCostDetail(string expenseId, string costType, decimal costMoney, string costDef) - { + public static void AddCostDetail(string expenseId ) + { + DeleteCostDetailByExpenseId(expenseId); Model.SGGLDB db = Funs.DB; - Model.CostGoods_ExpenseDetail newExpenseDetail = new Model.CostGoods_ExpenseDetail + var getItems = from x in db.Base_CostTypeItem + join y in db.Base_CostType on x.CostTypeId equals y.CostTypeId + select new + { + SupCostTypeId = y.CostTypeId, + SupCostTypeName = y.CostTypeName, + SupSortIndex = y.CostTypeCode, + CostType = x.CostTypeId, + CostTypeName=x.CostTypeItemName, + SortIndex=x.SortIndex, + CostMoney=0, + }; + foreach (var item in getItems) { - ExpenseDetailId = SQLHelper.GetNewID(typeof(Model.CostGoods_ExpenseDetail)), - ExpenseId = expenseId, - CostType = costType, - CostMoney = costMoney, - CostDef = costDef - }; - db.CostGoods_ExpenseDetail.InsertOnSubmit(newExpenseDetail); - db.SubmitChanges(); + Model.CostGoods_ExpenseDetail newExpenseDetail = new Model.CostGoods_ExpenseDetail + { + ExpenseDetailId = SQLHelper.GetNewID(), + ExpenseId = expenseId, + SupCostTypeId=item.SupCostTypeId, + SupCostTypeName=item.SupCostTypeName, + SupSortIndex=item.SupSortIndex, + + CostType = item.CostType, + CostTypeName = item.CostTypeName, + SortIndex=item.SortIndex, + CostMoney = item.CostMoney, + }; + db.CostGoods_ExpenseDetail.InsertOnSubmit(newExpenseDetail); + db.SubmitChanges(); + } } - /// - /// 根据费用编号和费用类型获取费用明细信息 - /// - /// - /// - /// - public static Model.CostGoods_ExpenseDetail GetCostDetailByExpenseIdAndCostType(string expenseId, string costType) - { - return Funs.DB.CostGoods_ExpenseDetail.FirstOrDefault(e => (e.ExpenseId == expenseId && e.CostType == costType)); - } /// /// 根据费用编号删除对应的费用明细信息 @@ -118,9 +61,12 @@ namespace BLL public static void DeleteCostDetailByExpenseId(string expenseId) { Model.SGGLDB db = Funs.DB; - var q = (from x in db.CostGoods_ExpenseDetail where x.ExpenseId == expenseId select x).ToList(); - db.CostGoods_ExpenseDetail.DeleteAllOnSubmit(q); - db.SubmitChanges(); + var q = from x in db.CostGoods_ExpenseDetail where x.ExpenseId == expenseId select x; + if (q.Count() > 0) + { + db.CostGoods_ExpenseDetail.DeleteAllOnSubmit(q); + db.SubmitChanges(); + } } } } diff --git a/SGGL/BLL/HSSE/CostGoods/ExpenseService.cs b/SGGL/BLL/HSSE/CostGoods/ExpenseService.cs index cc7371c8..08f22e67 100644 --- a/SGGL/BLL/HSSE/CostGoods/ExpenseService.cs +++ b/SGGL/BLL/HSSE/CostGoods/ExpenseService.cs @@ -21,6 +21,28 @@ namespace BLL return Funs.DB.CostGoods_Expense.FirstOrDefault(e => e.ExpenseId == expenseId); } + /// + /// 根据主键获取措施费用使用计划 + /// + /// + /// + public static List GetExpenseList(string projectId, string unitId, int? year) + { + var getData = from x in Funs.DB.CostGoods_Expense + where x.ProjectId == projectId + select x; + if (!string.IsNullOrEmpty(unitId) && unitId != Const._Null) + { + getData = getData.Where(x =>x.UnitId == unitId); + } + if (year.HasValue) + { + getData = getData.Where(x => x.Year == year); + } + + return getData.OrderBy(x => x.SortIndex).ToList(); + } + /// /// 根据时间获取当期单位Id集合 /// @@ -49,22 +71,17 @@ namespace BLL ProjectId = expense.ProjectId, ExpenseCode = expense.ExpenseCode, UnitId = expense.UnitId, - //newExpense.CompileMan = expense.CompileMan; + ReportDate=expense.ReportDate, CreateDate = expense.CreateDate, States = expense.States, - Months = expense.Months, - ReportDate = expense.ReportDate, - PlanCostA = expense.PlanCostA, - PlanCostB = expense.PlanCostB, + CompileMan = expense.CompileMan, CompileDate = expense.CompileDate, - // newExpense.CheckMan = expense.CheckMan; - CheckDate = expense.CheckDate, - // newExpense.ApproveMan = expense.ApproveMan; - ApproveDate = expense.ApproveDate + SortIndex = expense.SortIndex, + Year = expense.Year, }; db.CostGoods_Expense.InsertOnSubmit(newExpense); db.SubmitChanges(); - BLL.CodeRecordsService.InsertCodeRecordsByMenuIdProjectIdUnitId(Const.ProjectExpenseMenuId, expense.ProjectId, null, expense.ExpenseId, expense.CreateDate); + } /// @@ -79,20 +96,22 @@ namespace BLL { //newExpense.ProjectId = expense.ProjectId; newExpense.ExpenseCode = expense.ExpenseCode; - newExpense.UnitId = expense.UnitId; - // newExpense.CompileMan = expense.CompileMan; - newExpense.CreateDate = expense.CreateDate; + newExpense.UnitId = expense.UnitId; newExpense.States = expense.States; newExpense.Months = expense.Months; newExpense.ReportDate = expense.ReportDate; newExpense.PlanCostA = expense.PlanCostA; newExpense.PlanCostB = expense.PlanCostB; newExpense.CompileDate = expense.CompileDate; + newExpense.CompileMan = expense.CompileMan; //newExpense.CheckMan = expense.CheckMan; - newExpense.CheckDate = expense.CheckDate; + //newExpense.CheckDate = expense.CheckDate; //newExpense.ApproveMan = expense.ApproveMan; - newExpense.ApproveDate = expense.ApproveDate; + // newExpense.ApproveDate = expense.ApproveDate; + newExpense.SortIndex = expense.SortIndex; + newExpense.Year = expense.Year; db.SubmitChanges(); + } } @@ -112,6 +131,48 @@ namespace BLL BLL.CommonService.DeleteFlowOperateByID(expenseId); db.CostGoods_Expense.DeleteOnSubmit(expense); db.SubmitChanges(); + + if (expense.Year.HasValue) + { + SetSumYearExpense(expense.ProjectId, expense.Year.Value); + } + } + } + + /// + /// 当前合计数 + /// + /// + /// + public static void SetSumYearExpense(string projectId,int Year) + { + var getYearEx = Funs.DB. CostGoods_Expense.FirstOrDefault(x=>x.ProjectId == projectId && x.Year == Year && x.UnitId == null); + if (getYearEx != null) + { + Funs.DB.CostGoods_Expense.DeleteOnSubmit(getYearEx); + Funs.DB.SubmitChanges(); + } + + var getALLEx=from x in Funs.DB.CostGoods_Expense where x.ProjectId == projectId && x.Year == Year && x.UnitId != null select x; + if (getALLEx.Count() > 0) + { + Model.CostGoods_Expense newExpense = new Model.CostGoods_Expense + { + ExpenseId = SQLHelper.GetNewID(), + ProjectId = projectId, + UnitId = null, + CreateDate = DateTime.Now, + Months = DateTime.Now, + ReportDate = DateTime.Now, + CompileDate = DateTime.Now, + CheckDate = DateTime.Now, + ApproveDate = DateTime.Now, + SortIndex = 0, + Year = Year, + }; + + db.CostGoods_Expense.InsertOnSubmit(newExpense); + db.SubmitChanges(); } } } diff --git a/SGGL/FineUIPro.Web/BaseInfo/CostType.aspx b/SGGL/FineUIPro.Web/BaseInfo/CostType.aspx index ac4baeae..c911d38a 100644 --- a/SGGL/FineUIPro.Web/BaseInfo/CostType.aspx +++ b/SGGL/FineUIPro.Web/BaseInfo/CostType.aspx @@ -12,26 +12,20 @@ - + - - - - + + - - - - - + @@ -42,105 +36,13 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/SGGL/FineUIPro.Web/BaseInfo/CostType.aspx.cs b/SGGL/FineUIPro.Web/BaseInfo/CostType.aspx.cs index 7829228d..5b5362ac 100644 --- a/SGGL/FineUIPro.Web/BaseInfo/CostType.aspx.cs +++ b/SGGL/FineUIPro.Web/BaseInfo/CostType.aspx.cs @@ -1,6 +1,7 @@ using BLL; using System; using System.Collections.Generic; +using System.Data; using System.Linq; using System.Web.UI.WebControls; @@ -18,8 +19,6 @@ namespace FineUIPro.Web.BaseInfo { if (!IsPostBack) { - ////权限按钮方法 - this.GetButtonPower(); Funs.DropDownPageSize(this.ddlPageSize); ddlPageSize.SelectedValue = Grid1.PageSize.ToString(); // 绑定表格 @@ -33,47 +32,54 @@ namespace FineUIPro.Web.BaseInfo private void BindGrid() { var q = from x in Funs.DB.Base_CostType orderby x.CostTypeCode select x; - Grid1.RecordCount = q.Count(); - // 2.获取当前分页数据 - var table = GetPagedDataTable(Grid1.PageIndex, Grid1.PageSize); + DataTable tb = GetTreeDataTable(q.ToList()); //this.LINQToDataTable(getData.ToList()); + Grid1.RecordCount = tb.Rows.Count; + var table = this.GetPagedDataTable(Grid1, tb); Grid1.DataSource = table; Grid1.DataBind(); } /// - /// 分页 + /// 获取模拟树表格 /// /// - private List GetPagedDataTable(int pageIndex, int pageSize) + public DataTable GetTreeDataTable(List getData) { - List source = (from x in Funs.DB.Base_CostType orderby x.CostTypeCode select x).ToList(); - List paged = new List(); + DataTable table = new DataTable(); + table.Columns.Add(new DataColumn("ID", typeof(string))); + table.Columns.Add(new DataColumn("ParentId", typeof(string))); + table.Columns.Add(new DataColumn("Code", typeof(int))); + table.Columns.Add(new DataColumn("Name", typeof(String))); + table.Columns.Add(new DataColumn("Remark", typeof(String))); - int rowbegin = pageIndex * pageSize; - int rowend = (pageIndex + 1) * pageSize; - if (rowend > source.Count()) + foreach (var item in getData) { - rowend = source.Count(); + DataRow row = table.NewRow(); + row[0] = item.CostTypeId; + row[1] ="-1"; + row[2] = item.CostTypeCode; + row[3] = item.CostTypeCode+ item.CostTypeName; + row[4] = item.Remark; + table.Rows.Add(row); + var getU = Funs.DB.Base_CostTypeItem.Where(x => x.CostTypeId == item.CostTypeId).OrderBy(x=>x.SortIndex); + foreach (var itemU in getU) + { + DataRow rowC = table.NewRow(); + rowC[0] = itemU.CostTypeItemId; + rowC[1] = item.CostTypeId; + rowC[2] = itemU.SortIndex.ToString(); + rowC[3] = itemU.SortIndex.ToString() + itemU.CostTypeItemName; + rowC[4] = itemU.Remark; + table.Rows.Add(rowC); + } } - for (int i = rowbegin; i < rowend; i++) - { - paged.Add(source[i]); - } - - return paged; + return table; } - /// - /// 过滤表头 - /// - /// - /// - protected void Grid1_FilterChange(object sender, EventArgs e) - { - BindGrid(); - } + #endregion + #region 分页 排序 /// /// 改变索引事件 /// @@ -81,198 +87,31 @@ namespace FineUIPro.Web.BaseInfo /// protected void Grid1_PageIndexChange(object sender, GridPageEventArgs e) { - Grid1.PageIndex = e.NewPageIndex; BindGrid(); } - #endregion - #region 分页下拉选择 /// - /// 分页下拉选择 + /// 分页下拉选择事件 /// /// /// protected void ddlPageSize_SelectedIndexChanged(object sender, EventArgs e) { - Grid1.PageSize = Convert.ToInt32(ddlPageSize.SelectedValue); + this.Grid1.PageSize = Convert.ToInt32(this.ddlPageSize.SelectedValue); BindGrid(); } - #endregion - #region 删除 /// - /// 删除 + /// /// /// /// - protected void btnDelete_Click(object sender, EventArgs e) + protected void Grid1_Sort(object sender, GridSortEventArgs e) { - var getV = BLL.CostTypeService.GetCostTypeById(hfFormID.Text); - if (getV != null) - { - BLL.LogService.AddSys_Log(this.CurrUser, getV.CostTypeCode, getV.CostTypeId, BLL.Const.CostTypeMenuId, BLL.Const.BtnDelete); - BLL.CostTypeService.DeleteCostTypeById(hfFormID.Text); - // 重新绑定表格,并模拟点击[新增按钮] - BindGrid(); - PageContext.RegisterStartupScript("onNewButtonClick();"); - } - } - - /// - /// 右键删除事件 - /// - /// - /// - protected void btnMenuDelete_Click(object sender, EventArgs e) - { - this.DeleteData(); - } - - /// - /// 删除方法 - /// - private void DeleteData() - { - if (Grid1.SelectedRowIndexArray.Length > 0) - { - foreach (int rowIndex in Grid1.SelectedRowIndexArray) - { - string rowID = Grid1.DataKeys[rowIndex][0].ToString(); - var getV = BLL.CostTypeService.GetCostTypeById(rowID); - if (getV != null) - { - BLL.LogService.AddSys_Log(this.CurrUser, getV.CostTypeCode, getV.CostTypeId, BLL.Const.CostTypeMenuId, BLL.Const.BtnDelete); - BLL.CostTypeService.DeleteCostTypeById(rowID); - } - } - - BindGrid(); - PageContext.RegisterStartupScript("onNewButtonClick();"); - } - } - #endregion - - #region 编辑 - /// - /// 右键编辑事件 - /// - /// - /// - protected void btnMenuEdit_Click(object sender, EventArgs e) - { - this.EditData(); - } - - /// - /// 编辑数据方法 - /// - private void EditData() - { - if (Grid1.SelectedRowIndexArray.Length == 0) - { - Alert.ShowInTop("请至少选择一条记录!", MessageBoxIcon.Warning); - return; - } - string Id = Grid1.SelectedRowID; - var costType = BLL.CostTypeService.GetCostTypeById(Id); - if (costType != null) - { - this.txtCostTypeCode.Text = costType.CostTypeCode; - this.txtCostTypeName.Text = costType.CostTypeName; - this.txtRemark.Text = costType.Remark; - hfFormID.Text = Id; - this.btnDelete.Enabled = true; - } - } - #endregion - - #region 保存 - /// - /// 保存按钮 - /// - /// - /// - protected void btnSave_Click(object sender, EventArgs e) - { - string strRowID = hfFormID.Text; - Model.Base_CostType costType = new Model.Base_CostType - { - CostTypeCode = this.txtCostTypeCode.Text.Trim(), - CostTypeName = this.txtCostTypeName.Text.Trim(), - Remark = txtRemark.Text.Trim() - }; - if (string.IsNullOrEmpty(strRowID)) - { - costType.CostTypeId = SQLHelper.GetNewID(typeof(Model.Base_CostType)); - BLL.CostTypeService.AddCostType(costType); - BLL.LogService.AddSys_Log(this.CurrUser, costType.CostTypeCode, costType.CostTypeId, BLL.Const.CostTypeMenuId, BLL.Const.BtnAdd); - } - else - { - costType.CostTypeId = strRowID; - BLL.CostTypeService.UpdateCostType(costType); - BLL.LogService.AddSys_Log(this.CurrUser, costType.CostTypeCode, costType.CostTypeId, BLL.Const.CostTypeMenuId, BLL.Const.BtnModify); - } - - this.SimpleForm1.Reset(); - // 重新绑定表格,并点击当前编辑或者新增的行 BindGrid(); - PageContext.RegisterStartupScript(String.Format("F('{0}').selectRow('{1}');", Grid1.ClientID, costType.CostTypeId)); } + #endregion - - #region 验证费用类别名称、编号是否存在 - /// - /// 验证费用类别名称、编号是否存在 - /// - /// - /// - protected void TextBox_TextChanged(object sender, EventArgs e) - { - var q = Funs.DB.Base_CostType.FirstOrDefault(x => x.CostTypeCode == this.txtCostTypeCode.Text.Trim() && (x.CostTypeId != hfFormID.Text || (hfFormID.Text == null && x.CostTypeId != null))); - if (q != null) - { - ShowNotify("输入的类别编号已存在!", MessageBoxIcon.Warning); - } - - var q2 = Funs.DB.Base_CostType.FirstOrDefault(x => x.CostTypeName == this.txtCostTypeName.Text.Trim() && (x.CostTypeId != hfFormID.Text || (hfFormID.Text == null && x.CostTypeId != null))); - if (q2 != null) - { - ShowNotify("输入的类别名称已存在!", MessageBoxIcon.Warning); - } - } - #endregion - - #region 获取按钮权限 - /// - /// 获取按钮权限 - /// - /// - /// - private void GetButtonPower() - { - var buttonList = BLL.CommonService.GetAllButtonList(this.CurrUser.LoginProjectId, this.CurrUser.PersonId, BLL.Const.CostTypeMenuId); - if (buttonList.Count() > 0) - { - if (buttonList.Contains(BLL.Const.BtnAdd)) - { - this.btnNew.Hidden = false; - } - if (buttonList.Contains(BLL.Const.BtnModify)) - { - this.btnMenuEdit.Hidden = false; - } - if (buttonList.Contains(BLL.Const.BtnDelete)) - { - this.btnDelete.Hidden = false; - this.btnMenuDelete.Hidden = false; - } - if (buttonList.Contains(BLL.Const.BtnSave)) - { - this.btnSave.Hidden = false; - } - } - } - #endregion + } } \ No newline at end of file diff --git a/SGGL/FineUIPro.Web/BaseInfo/CostType.aspx.designer.cs b/SGGL/FineUIPro.Web/BaseInfo/CostType.aspx.designer.cs index 584e5a99..6a020fcf 100644 --- a/SGGL/FineUIPro.Web/BaseInfo/CostType.aspx.designer.cs +++ b/SGGL/FineUIPro.Web/BaseInfo/CostType.aspx.designer.cs @@ -7,11 +7,13 @@ // //------------------------------------------------------------------------------ -namespace FineUIPro.Web.BaseInfo { - - - public partial class CostType { - +namespace FineUIPro.Web.BaseInfo +{ + + + public partial class CostType + { + /// /// form1 控件。 /// @@ -20,7 +22,7 @@ namespace FineUIPro.Web.BaseInfo { /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 /// protected global::System.Web.UI.HtmlControls.HtmlForm form1; - + /// /// PageManager1 控件。 /// @@ -29,7 +31,7 @@ namespace FineUIPro.Web.BaseInfo { /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 /// protected global::FineUIPro.PageManager PageManager1; - + /// /// Panel1 控件。 /// @@ -38,7 +40,7 @@ namespace FineUIPro.Web.BaseInfo { /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 /// protected global::FineUIPro.Panel Panel1; - + /// /// Grid1 控件。 /// @@ -47,7 +49,7 @@ namespace FineUIPro.Web.BaseInfo { /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 /// protected global::FineUIPro.Grid Grid1; - + /// /// ToolbarSeparator1 控件。 /// @@ -56,7 +58,7 @@ namespace FineUIPro.Web.BaseInfo { /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 /// protected global::FineUIPro.ToolbarSeparator ToolbarSeparator1; - + /// /// ToolbarText1 控件。 /// @@ -65,7 +67,7 @@ namespace FineUIPro.Web.BaseInfo { /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 /// protected global::FineUIPro.ToolbarText ToolbarText1; - + /// /// ddlPageSize 控件。 /// @@ -74,122 +76,5 @@ namespace FineUIPro.Web.BaseInfo { /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 /// protected global::FineUIPro.DropDownList ddlPageSize; - - /// - /// SimpleForm1 控件。 - /// - /// - /// 自动生成的字段。 - /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 - /// - protected global::FineUIPro.SimpleForm SimpleForm1; - - /// - /// hfFormID 控件。 - /// - /// - /// 自动生成的字段。 - /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 - /// - protected global::FineUIPro.HiddenField hfFormID; - - /// - /// txtCostTypeCode 控件。 - /// - /// - /// 自动生成的字段。 - /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 - /// - protected global::FineUIPro.TextBox txtCostTypeCode; - - /// - /// txtCostTypeName 控件。 - /// - /// - /// 自动生成的字段。 - /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 - /// - protected global::FineUIPro.TextBox txtCostTypeName; - - /// - /// txtRemark 控件。 - /// - /// - /// 自动生成的字段。 - /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 - /// - protected global::FineUIPro.TextArea txtRemark; - - /// - /// Toolbar1 控件。 - /// - /// - /// 自动生成的字段。 - /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 - /// - protected global::FineUIPro.Toolbar Toolbar1; - - /// - /// btnNew 控件。 - /// - /// - /// 自动生成的字段。 - /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 - /// - protected global::FineUIPro.Button btnNew; - - /// - /// btnDelete 控件。 - /// - /// - /// 自动生成的字段。 - /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 - /// - protected global::FineUIPro.Button btnDelete; - - /// - /// ToolbarFill1 控件。 - /// - /// - /// 自动生成的字段。 - /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 - /// - protected global::FineUIPro.ToolbarFill ToolbarFill1; - - /// - /// btnSave 控件。 - /// - /// - /// 自动生成的字段。 - /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 - /// - protected global::FineUIPro.Button btnSave; - - /// - /// Menu1 控件。 - /// - /// - /// 自动生成的字段。 - /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 - /// - protected global::FineUIPro.Menu Menu1; - - /// - /// btnMenuEdit 控件。 - /// - /// - /// 自动生成的字段。 - /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 - /// - protected global::FineUIPro.MenuButton btnMenuEdit; - - /// - /// btnMenuDelete 控件。 - /// - /// - /// 自动生成的字段。 - /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 - /// - protected global::FineUIPro.MenuButton btnMenuDelete; } } diff --git a/SGGL/FineUIPro.Web/FineUIPro.Web.csproj b/SGGL/FineUIPro.Web/FineUIPro.Web.csproj index 84bb1c21..d4f868ec 100644 --- a/SGGL/FineUIPro.Web/FineUIPro.Web.csproj +++ b/SGGL/FineUIPro.Web/FineUIPro.Web.csproj @@ -752,9 +752,10 @@ - + + @@ -1654,6 +1655,7 @@ + @@ -9307,12 +9309,12 @@ CostSmallDetailView.aspx - - Expense.aspx + + ExpenseUnit.aspx ASPXCodeBehind - - Expense.aspx + + ExpenseUnit.aspx ExpenseEdit.aspx @@ -9328,6 +9330,13 @@ ExpenseView.aspx + + Expense.aspx + ASPXCodeBehind + + + Expense.aspx + AccidentCase.aspx ASPXCodeBehind @@ -13522,7 +13531,7 @@ True 0 / - http://localhost:3027/ + http://localhost:5403/ False False diff --git a/SGGL/FineUIPro.Web/HSSE/Check/IncentiveNotice.aspx b/SGGL/FineUIPro.Web/HSSE/Check/IncentiveNotice.aspx index f1b12f3d..e3aa4a78 100644 --- a/SGGL/FineUIPro.Web/HSSE/Check/IncentiveNotice.aspx +++ b/SGGL/FineUIPro.Web/HSSE/Check/IncentiveNotice.aspx @@ -105,8 +105,8 @@ +<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="IncentiveNoticeAdd.aspx.cs" Inherits="FineUIPro.Web.HSSE.Check.IncentiveNoticeAdd" ValidateRequest="false" %> diff --git a/SGGL/FineUIPro.Web/HSSE/Check/PunishNotice.aspx b/SGGL/FineUIPro.Web/HSSE/Check/PunishNotice.aspx index 055c57a1..da143068 100644 --- a/SGGL/FineUIPro.Web/HSSE/Check/PunishNotice.aspx +++ b/SGGL/FineUIPro.Web/HSSE/Check/PunishNotice.aspx @@ -113,7 +113,7 @@ + /// + /// + 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 = System.Text.Encoding.UTF8; + this.Grid1.PageSize = this.Grid1.RecordCount; + + Response.Write(GetTableHtml(GetDataTable())); + Response.End(); + } + #endregion + + #region 分页 排序 + /// + /// 改变索引事件 + /// + /// + /// + protected void Grid1_PageIndexChange(object sender, GridPageEventArgs e) + { + LoadData(); + } + + /// + /// 分页下拉选择事件 + /// + /// + /// + protected void ddlPageSize_SelectedIndexChanged(object sender, EventArgs e) + { + this.Grid1.PageSize = Convert.ToInt32(this.ddlPageSize.SelectedValue); + LoadData(); + } + + /// + /// + /// + /// + /// + protected void Grid1_Sort(object sender, GridSortEventArgs e) + { + LoadData(); + } + + #endregion + + /// + /// 查看 + /// + /// + /// + protected void btnView_Click(object sender, EventArgs e) + { + this.EditData("view"); + } + + /// + /// 双击事件 + /// + /// + /// + protected void Grid1_RowDoubleClick(object sender, GridRowClickEventArgs e) + { + this.EditData(); + } + + /// + /// 右键编辑事件 + /// + /// + /// + protected void btnMenuEdit_Click(object sender, EventArgs e) + { + this.EditData(); + } + + /// + /// 编辑数据 + /// + private void EditData(string type = null) + { + if (Grid1.SelectedRowIndexArray.Length == 0) + { + Alert.ShowInTop("请至少选择一条记录!", MessageBoxIcon.Warning); + return; + } + string id = Grid1.SelectedRow.Values[0].ToString(); + var getID = Funs.GetStrListByStr(id, '#'); + if (getID != null && getID.Count > 1) + { + var getEx = ExpenseService.GetExpenseById(getID[1]); + if (getEx != null && !string.IsNullOrEmpty(getEx.UnitId)) + { + if (this.btnMenuEdit.Hidden || type == "view") ////双击事件 编辑权限有:编辑页面,无:查看页面 或者状态是完成时查看页面 + { + PageContext.RegisterStartupScript(Window1.GetShowReference(String.Format("ExpenseView.aspx?ExpenseId={0}", id, "查看 - "))); + } + else + { + PageContext.RegisterStartupScript(Window1.GetShowReference(String.Format("ExpenseEdit.aspx?ExpenseId={0}", id, "编辑 - "))); + } + } + } + } + + #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 getEx = ExpenseService.GetExpenseById(rowID); + if (getEx != null && !string.IsNullOrEmpty(getEx.UnitId)) + { + BLL.LogService.AddSys_Log(this.CurrUser, getEx.ExpenseCode, getEx.ExpenseId, BLL.Const.ProjectExpenseMenuId, BLL.Const.BtnDelete); + BLL.ExpenseService.DeleteExpenseById(rowID); + } + } + + this.LoadData(); + ShowNotify("删除数据成功!", MessageBoxIcon.Success); + } + } + #endregion + + /// + /// 单位查询事件 + /// + /// + /// + protected void drpUnit_SelectedIndexChanged(object sender, EventArgs e) + { + this.LoadData(); + } + + #region 获取按钮权限 + /// + /// 获取按钮权限 + /// + /// + /// + private void GetButtonPower() + { + if (Request.Params["value"] == "0") + { + return; + } + var buttonList = BLL.CommonService.GetAllButtonList(this.CurrUser.LoginProjectId, this.CurrUser.PersonId, BLL.Const.ProjectExpenseMenuId); + if (buttonList.Count() > 0) + { + if (buttonList.Contains(BLL.Const.BtnAdd)) + { + this.btnNew.Hidden = false; + } + if (buttonList.Contains(BLL.Const.BtnModify)) + { + this.btnMenuEdit.Hidden = false; + } + if (buttonList.Contains(BLL.Const.BtnDelete)) + { + this.btnMenuDelete.Hidden = false; + } + } + } + #endregion + + protected void txtYear_ClearIconClick(object sender, EventArgs e) + { + this.txtYear.Text = string.Empty; + this.LoadData(); + } + } +} \ No newline at end of file diff --git a/SGGL/FineUIPro.Web/HSSE/CostGoods/ExpenseUnit.aspx.designer.cs b/SGGL/FineUIPro.Web/HSSE/CostGoods/ExpenseUnit.aspx.designer.cs new file mode 100644 index 00000000..f1686b0c --- /dev/null +++ b/SGGL/FineUIPro.Web/HSSE/CostGoods/ExpenseUnit.aspx.designer.cs @@ -0,0 +1,161 @@ +//------------------------------------------------------------------------------ +// <自动生成> +// 此代码由工具生成。 +// +// 对此文件的更改可能导致不正确的行为,如果 +// 重新生成代码,则所做更改将丢失。 +// +//------------------------------------------------------------------------------ + +namespace FineUIPro.Web.HSSE.CostGoods +{ + + + public partial class ExpenseUnit + { + + /// + /// 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; + + /// + /// txtYear 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.DatePicker txtYear; + + /// + /// btnNew 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.Button btnNew; + + /// + /// btnOut 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.Button btnOut; + + /// + /// 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; + + /// + /// btnView 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.MenuButton btnView; + + /// + /// btnMenuEdit 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.MenuButton btnMenuEdit; + + /// + /// btnMenuDelete 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.MenuButton btnMenuDelete; + } +} diff --git a/SGGL/FineUIPro.Web/HSSE/CostGoods/ExpenseView.aspx b/SGGL/FineUIPro.Web/HSSE/CostGoods/ExpenseView.aspx index 92443c33..81fac7a1 100644 --- a/SGGL/FineUIPro.Web/HSSE/CostGoods/ExpenseView.aspx +++ b/SGGL/FineUIPro.Web/HSSE/CostGoods/ExpenseView.aspx @@ -7,321 +7,163 @@ - 查看安全费用计划 + 费用计划
- - - - - - - - - - - - - - - - - - - - <%-- - - - - - - - --%> - <%-- - - - - - - - - - - - - - - - --%> - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/SGGL/FineUIPro.Web/HSSE/CostGoods/ExpenseView.aspx.cs b/SGGL/FineUIPro.Web/HSSE/CostGoods/ExpenseView.aspx.cs index b8284319..b3be480a 100644 --- a/SGGL/FineUIPro.Web/HSSE/CostGoods/ExpenseView.aspx.cs +++ b/SGGL/FineUIPro.Web/HSSE/CostGoods/ExpenseView.aspx.cs @@ -35,141 +35,22 @@ namespace FineUIPro.Web.HSSE.CostGoods if (!IsPostBack) { this.btnClose.OnClientClick = ActiveWindow.GetHideReference(); - this.ExpenseId = Request.Params["ExpenseId"]; if (!string.IsNullOrEmpty(this.ExpenseId)) { - Model.CostGoods_Expense expense = BLL.ExpenseService.GetExpenseById(this.ExpenseId); + var expense = BLL.ExpenseService.GetExpenseById(this.ExpenseId); if (expense != null) { - this.txtExpenseCode.Text = CodeRecordsService.ReturnCodeByDataId(this.ExpenseId); - if (expense.Months != null) + if (expense != null) { - this.txtMonths.Text = string.Format("{0:yyyy-MM}", expense.Months); + this.ExpenseId = expense.ExpenseId; + this.drpUnit.Text = UnitService.GetUnitNameByUnitId( expense.UnitId); + this.txtYear.Text = expense.Year.ToString(); + this.lbSortIndex.Text = expense.SortIndex.ToString(); + } - if (!string.IsNullOrEmpty(expense.UnitId)) - { - Model.Base_Unit unit = BLL.UnitService.GetUnitByUnitId(expense.UnitId); - if (unit != null) - { - this.drpUnitId.Text = unit.UnitName; - } - } - if (expense.ReportDate != null) - { - this.txtReportDate.Text = string.Format("{0:yyyy-MM-dd}", expense.ReportDate); - } - //this.txtCompileMan.Text = expense.CompileMan; - //if (expense.CompileDate != null) - //{ - // this.txtCompileDate.Text = string.Format("{0:yyyy-MM-dd}", expense.CompileDate); - //} - //this.txtCheckMan.Text = expense.CheckMan; - //if (expense.CheckDate != null) - //{ - // this.txtCheckDate.Text = string.Format("{0:yyyy-MM-dd}", expense.CheckDate); - //} - //this.txtApproveMan.Text = expense.ApproveMan; - //if (expense.ApproveDate != null) - //{ - // this.txtApproveDate.Text = string.Format("{0:yyyy-MM-dd}", expense.ApproveDate); - //} - decimal totalA = 0, totalB = 0, totalProjectA = 0, totalProjectB = 0; - Model.Base_Project project = BLL.ProjectService.GetProjectByProjectId(expense.ProjectId); - List projectDetails = BLL.ExpenseDetailService.GetCostDetailsByUnitId(expense.UnitId, project != null ? Convert.ToDateTime(project.StartDate) : Convert.ToDateTime("2000-01-01"), Convert.ToDateTime(expense.Months)); - List details = BLL.ExpenseDetailService.GetExpenseDetailsByExpenseId(this.ExpenseId); - Model.CostGoods_ExpenseDetail a1 = details.FirstOrDefault(x => x.CostType == "A1"); - if (a1 != null) - { - this.nbA1.Text = (a1.CostMoney ?? 0).ToString(); - totalA += Funs.GetNewDecimalOrZero(this.nbA1.Text); - this.nbProjectA1.Text = ((from x in projectDetails where x.CostType == "A1" select x.CostMoney ?? 0).Sum() + a1.CostMoney ?? 0).ToString(); - totalProjectA += Funs.GetNewDecimalOrZero(this.nbProjectA1.Text); - this.txtDefA1.Text = a1.CostDef; - } - Model.CostGoods_ExpenseDetail a2 = details.FirstOrDefault(x => x.CostType == "A2"); - if (a2 != null) - { - this.nbA2.Text = (a2.CostMoney ?? 0).ToString(); - totalA += Funs.GetNewDecimalOrZero(this.nbA2.Text); - this.nbProjectA2.Text = ((from x in projectDetails where x.CostType == "A2" select x.CostMoney ?? 0).Sum() + a2.CostMoney ?? 0).ToString(); - totalProjectA += Funs.GetNewDecimalOrZero(this.nbProjectA2.Text); - this.txtDefA2.Text = a2.CostDef; - } - Model.CostGoods_ExpenseDetail a3 = details.FirstOrDefault(x => x.CostType == "A3"); - if (a3 != null) - { - this.nbA3.Text = (a3.CostMoney ?? 0).ToString(); - totalA += Funs.GetNewDecimalOrZero(this.nbA3.Text); - this.nbProjectA3.Text = ((from x in projectDetails where x.CostType == "A3" select x.CostMoney ?? 0).Sum() + a3.CostMoney ?? 0).ToString(); - totalProjectA += Funs.GetNewDecimalOrZero(this.nbProjectA3.Text); - this.txtDefA3.Text = a3.CostDef; - } - Model.CostGoods_ExpenseDetail a4 = details.FirstOrDefault(x => x.CostType == "A4"); - if (a4 != null) - { - this.nbA4.Text = (a4.CostMoney ?? 0).ToString(); - totalA += Funs.GetNewDecimalOrZero(this.nbA4.Text); - this.nbProjectA4.Text = ((from x in projectDetails where x.CostType == "A4" select x.CostMoney ?? 0).Sum() + a4.CostMoney ?? 0).ToString(); - totalProjectA += Funs.GetNewDecimalOrZero(this.nbProjectA4.Text); - this.txtDefA4.Text = a4.CostDef; - } - Model.CostGoods_ExpenseDetail a5 = details.FirstOrDefault(x => x.CostType == "A5"); - if (a5 != null) - { - this.nbA5.Text = (a5.CostMoney ?? 0).ToString(); - totalA += Funs.GetNewDecimalOrZero(this.nbA5.Text); - this.nbProjectA5.Text = ((from x in projectDetails where x.CostType == "A5" select x.CostMoney ?? 0).Sum() + a5.CostMoney ?? 0).ToString(); - totalProjectA += Funs.GetNewDecimalOrZero(this.nbProjectA5.Text); - this.txtDefA5.Text = a5.CostDef; - } - Model.CostGoods_ExpenseDetail a6 = details.FirstOrDefault(x => x.CostType == "A6"); - if (a6 != null) - { - this.nbA6.Text = (a6.CostMoney ?? 0).ToString(); - totalA += Funs.GetNewDecimalOrZero(this.nbA6.Text); - this.nbProjectA6.Text = ((from x in projectDetails where x.CostType == "A6" select x.CostMoney ?? 0).Sum() + a6.CostMoney ?? 0).ToString(); - totalProjectA += Funs.GetNewDecimalOrZero(this.nbProjectA6.Text); - this.txtDefA6.Text = a6.CostDef; - } - this.nbA.Text = totalA.ToString(); - this.nbProjectA.Text = totalProjectA.ToString(); - Model.CostGoods_ExpenseDetail b1 = details.FirstOrDefault(x => x.CostType == "B1"); - if (b1 != null) - { - this.nbB1.Text = (b1.CostMoney ?? 0).ToString(); - totalB += Funs.GetNewDecimalOrZero(this.nbB1.Text); - this.nbProjectB1.Text = ((from x in projectDetails where x.CostType == "B1" select x.CostMoney ?? 0).Sum() + b1.CostMoney ?? 0).ToString(); - totalProjectB += Funs.GetNewDecimalOrZero(this.nbProjectB1.Text); - this.txtDefB1.Text = b1.CostDef; - } - Model.CostGoods_ExpenseDetail b2 = details.FirstOrDefault(x => x.CostType == "B2"); - if (b2 != null) - { - this.nbB2.Text = (b2.CostMoney ?? 0).ToString(); - totalB += Funs.GetNewDecimalOrZero(this.nbB2.Text); - this.nbProjectB2.Text = ((from x in projectDetails where x.CostType == "B2" select x.CostMoney ?? 0).Sum() + b2.CostMoney ?? 0).ToString(); - totalProjectB += Funs.GetNewDecimalOrZero(this.nbProjectB2.Text); - this.txtDefB2.Text = b2.CostDef; - } - Model.CostGoods_ExpenseDetail b3 = details.FirstOrDefault(x => x.CostType == "B3"); - if (b3 != null) - { - this.nbB3.Text = (b3.CostMoney ?? 0).ToString(); - totalB += Funs.GetNewDecimalOrZero(this.nbB3.Text); - this.nbProjectB3.Text = ((from x in projectDetails where x.CostType == "B3" select x.CostMoney ?? 0).Sum() + b3.CostMoney ?? 0).ToString(); - totalProjectB += Funs.GetNewDecimalOrZero(this.nbProjectB3.Text); - this.txtDefB3.Text = b3.CostDef; - } - this.nbB.Text = totalB.ToString(); - this.nbProjectB.Text = totalProjectB.ToString(); - this.nbAB.Text = (totalA + totalB).ToString(); - this.nbProjectAB.Text = (totalProjectA + totalProjectB).ToString(); } } - ///初始化审核菜单 - this.ctlAuditFlow.MenuId = BLL.Const.ProjectExpenseMenuId; - this.ctlAuditFlow.DataId = this.ExpenseId; } } #endregion @@ -184,7 +65,7 @@ namespace FineUIPro.Web.HSSE.CostGoods { if (!string.IsNullOrEmpty(this.ExpenseId)) { - PageContext.RegisterStartupScript(WindowAtt.GetShowReference(String.Format("~/AttachFile/webuploader.aspx?toKeyId={0}&path=FileUpload/ExpenseAttachUrl&menuId={1}", ExpenseId, BLL.Const.ProjectExpenseMenuId))); + PageContext.RegisterStartupScript(WindowAtt.GetShowReference(String.Format("../../AttachFile/webuploader.aspx?toKeyId={0}&menuId={1}&type=-1", ExpenseId, BLL.Const.ProjectExpenseMenuId))); } } #endregion diff --git a/SGGL/FineUIPro.Web/HSSE/CostGoods/ExpenseView.aspx.designer.cs b/SGGL/FineUIPro.Web/HSSE/CostGoods/ExpenseView.aspx.designer.cs index fb1e3425..98c7ca45 100644 --- a/SGGL/FineUIPro.Web/HSSE/CostGoods/ExpenseView.aspx.designer.cs +++ b/SGGL/FineUIPro.Web/HSSE/CostGoods/ExpenseView.aspx.designer.cs @@ -7,11 +7,13 @@ // //------------------------------------------------------------------------------ -namespace FineUIPro.Web.HSSE.CostGoods { - - - public partial class ExpenseView { - +namespace FineUIPro.Web.HSSE.CostGoods +{ + + + public partial class ExpenseView + { + /// /// form1 控件。 /// @@ -20,7 +22,7 @@ namespace FineUIPro.Web.HSSE.CostGoods { /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 /// protected global::System.Web.UI.HtmlControls.HtmlForm form1; - + /// /// PageManager1 控件。 /// @@ -29,7 +31,7 @@ namespace FineUIPro.Web.HSSE.CostGoods { /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 /// protected global::FineUIPro.PageManager PageManager1; - + /// /// SimpleForm1 控件。 /// @@ -38,34 +40,25 @@ namespace FineUIPro.Web.HSSE.CostGoods { /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 /// protected global::FineUIPro.Form SimpleForm1; - + /// - /// txtMonths 控件。 + /// drpUnit 控件。 /// /// /// 自动生成的字段。 /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 /// - protected global::FineUIPro.Label txtMonths; - + protected global::FineUIPro.TextBox drpUnit; + /// - /// txtExpenseCode 控件。 + /// txtYear 控件。 /// /// /// 自动生成的字段。 /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 /// - protected global::FineUIPro.TextBox txtExpenseCode; - - /// - /// drpUnitId 控件。 - /// - /// - /// 自动生成的字段。 - /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 - /// - protected global::FineUIPro.TextBox drpUnitId; - + protected global::FineUIPro.TextBox txtYear; + /// /// txtReportDate 控件。 /// @@ -74,16 +67,16 @@ namespace FineUIPro.Web.HSSE.CostGoods { /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 /// protected global::FineUIPro.TextBox txtReportDate; - + /// - /// Panel2 控件。 + /// lbSortIndex 控件。 /// /// /// 自动生成的字段。 /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 /// - protected global::FineUIPro.Panel Panel2; - + protected global::FineUIPro.Label lbSortIndex; + /// /// Panel1 控件。 /// @@ -92,619 +85,349 @@ namespace FineUIPro.Web.HSSE.CostGoods { /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 /// protected global::FineUIPro.Panel Panel1; - + /// - /// Label58 控件。 + /// GroupPanel1 控件。 /// /// /// 自动生成的字段。 /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 /// - protected global::FineUIPro.Label Label58; - + protected global::FineUIPro.GroupPanel GroupPanel1; + /// - /// Panel3 控件。 + /// SimpleForm2 控件。 /// /// /// 自动生成的字段。 /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 /// - protected global::FineUIPro.Panel Panel3; - + protected global::FineUIPro.Form SimpleForm2; + /// - /// lblAccidentType11 控件。 + /// txtA1 控件。 /// /// /// 自动生成的字段。 /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 /// - protected global::FineUIPro.Label lblAccidentType11; - + protected global::FineUIPro.TextBox txtA1; + /// - /// Panel5 控件。 + /// txtA2 控件。 /// /// /// 自动生成的字段。 /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 /// - protected global::FineUIPro.Panel Panel5; - + protected global::FineUIPro.TextBox txtA2; + /// - /// Label1 控件。 + /// txtA3 控件。 /// /// /// 自动生成的字段。 /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 /// - protected global::FineUIPro.Label Label1; - + protected global::FineUIPro.TextBox txtA3; + /// - /// Panel6 控件。 + /// txtA4 控件。 /// /// /// 自动生成的字段。 /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 /// - protected global::FineUIPro.Panel Panel6; - + protected global::FineUIPro.TextBox txtA4; + /// - /// Label3 控件。 + /// txtA5 控件。 /// /// /// 自动生成的字段。 /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 /// - protected global::FineUIPro.Label Label3; - + protected global::FineUIPro.TextBox txtA5; + /// - /// Panel4 控件。 + /// txtA6 控件。 /// /// /// 自动生成的字段。 /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 /// - protected global::FineUIPro.Panel Panel4; - + protected global::FineUIPro.TextBox txtA6; + /// - /// Label2 控件。 + /// txtA7 控件。 /// /// /// 自动生成的字段。 /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 /// - protected global::FineUIPro.Label Label2; - + protected global::FineUIPro.TextBox txtA7; + /// - /// Label5 控件。 + /// txtA8 控件。 /// /// /// 自动生成的字段。 /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 /// - protected global::FineUIPro.Label Label5; - + protected global::FineUIPro.TextBox txtA8; + /// - /// Label6 控件。 + /// txtA9 控件。 /// /// /// 自动生成的字段。 /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 /// - protected global::FineUIPro.Label Label6; - + protected global::FineUIPro.TextBox txtA9; + /// - /// nbA1 控件。 + /// txtA10 控件。 /// /// /// 自动生成的字段。 /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 /// - protected global::FineUIPro.NumberBox nbA1; - + protected global::FineUIPro.TextBox txtA10; + /// - /// nbProjectA1 控件。 + /// txtA11 控件。 /// /// /// 自动生成的字段。 /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 /// - protected global::FineUIPro.NumberBox nbProjectA1; - + protected global::FineUIPro.TextBox txtA11; + /// - /// txtDefA1 控件。 + /// txtA12 控件。 /// /// /// 自动生成的字段。 /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 /// - protected global::FineUIPro.TextBox txtDefA1; - + protected global::FineUIPro.TextBox txtA12; + /// - /// Label7 控件。 + /// txtA13 控件。 /// /// /// 自动生成的字段。 /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 /// - protected global::FineUIPro.Label Label7; - + protected global::FineUIPro.TextBox txtA13; + /// - /// Label8 控件。 + /// txtA14 控件。 /// /// /// 自动生成的字段。 /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 /// - protected global::FineUIPro.Label Label8; - + protected global::FineUIPro.TextBox txtA14; + /// - /// nbA2 控件。 + /// txtA15 控件。 /// /// /// 自动生成的字段。 /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 /// - protected global::FineUIPro.NumberBox nbA2; - + protected global::FineUIPro.TextBox txtA15; + /// - /// nbProjectA2 控件。 + /// txtA16 控件。 /// /// /// 自动生成的字段。 /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 /// - protected global::FineUIPro.NumberBox nbProjectA2; - + protected global::FineUIPro.TextBox txtA16; + /// - /// txtDefA2 控件。 + /// txtA17 控件。 /// /// /// 自动生成的字段。 /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 /// - protected global::FineUIPro.TextBox txtDefA2; - + protected global::FineUIPro.TextBox txtA17; + /// - /// Label9 控件。 + /// txtA18 控件。 /// /// /// 自动生成的字段。 /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 /// - protected global::FineUIPro.Label Label9; - + protected global::FineUIPro.TextBox txtA18; + /// - /// Label10 控件。 + /// GroupPanel2 控件。 /// /// /// 自动生成的字段。 /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 /// - protected global::FineUIPro.Label Label10; - + protected global::FineUIPro.GroupPanel GroupPanel2; + /// - /// nbA3 控件。 + /// Form2 控件。 /// /// /// 自动生成的字段。 /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 /// - protected global::FineUIPro.NumberBox nbA3; - + protected global::FineUIPro.Form Form2; + /// - /// nbProjectA3 控件。 + /// txtB1 控件。 /// /// /// 自动生成的字段。 /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 /// - protected global::FineUIPro.NumberBox nbProjectA3; - + protected global::FineUIPro.TextBox txtB1; + /// - /// txtDefA3 控件。 + /// txtB2 控件。 /// /// /// 自动生成的字段。 /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 /// - protected global::FineUIPro.TextBox txtDefA3; - + protected global::FineUIPro.TextBox txtB2; + /// - /// Label11 控件。 + /// txtB3 控件。 /// /// /// 自动生成的字段。 /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 /// - protected global::FineUIPro.Label Label11; - + protected global::FineUIPro.TextBox txtB3; + /// - /// Label12 控件。 + /// GroupPanel3 控件。 /// /// /// 自动生成的字段。 /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 /// - protected global::FineUIPro.Label Label12; - + protected global::FineUIPro.GroupPanel GroupPanel3; + /// - /// nbA4 控件。 + /// Form3 控件。 /// /// /// 自动生成的字段。 /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 /// - protected global::FineUIPro.NumberBox nbA4; - + protected global::FineUIPro.Form Form3; + /// - /// nbProjectA4 控件。 + /// txtC1 控件。 /// /// /// 自动生成的字段。 /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 /// - protected global::FineUIPro.NumberBox nbProjectA4; - + protected global::FineUIPro.TextBox txtC1; + /// - /// txtDefA4 控件。 + /// txtC2 控件。 /// /// /// 自动生成的字段。 /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 /// - protected global::FineUIPro.TextBox txtDefA4; - + protected global::FineUIPro.TextBox txtC2; + /// - /// Label13 控件。 + /// txtC3 控件。 /// /// /// 自动生成的字段。 /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 /// - protected global::FineUIPro.Label Label13; - + protected global::FineUIPro.TextBox txtC3; + /// - /// Label14 控件。 + /// txtC4 控件。 /// /// /// 自动生成的字段。 /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 /// - protected global::FineUIPro.Label Label14; - + protected global::FineUIPro.TextBox txtC4; + /// - /// nbA5 控件。 + /// txtC5 控件。 /// /// /// 自动生成的字段。 /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 /// - protected global::FineUIPro.NumberBox nbA5; - + protected global::FineUIPro.TextBox txtC5; + /// - /// nbProjectA5 控件。 + /// txtC6 控件。 /// /// /// 自动生成的字段。 /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 /// - protected global::FineUIPro.NumberBox nbProjectA5; - + protected global::FineUIPro.TextBox txtC6; + /// - /// txtDefA5 控件。 + /// GroupPanel4 控件。 /// /// /// 自动生成的字段。 /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 /// - protected global::FineUIPro.TextBox txtDefA5; - + protected global::FineUIPro.GroupPanel GroupPanel4; + /// - /// Label15 控件。 + /// Form4 控件。 /// /// /// 自动生成的字段。 /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 /// - protected global::FineUIPro.Label Label15; - + protected global::FineUIPro.Form Form4; + /// - /// Label16 控件。 + /// txtD1 控件。 /// /// /// 自动生成的字段。 /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 /// - protected global::FineUIPro.Label Label16; - + protected global::FineUIPro.TextBox txtD1; + /// - /// nbA6 控件。 + /// txtD2 控件。 /// /// /// 自动生成的字段。 /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 /// - protected global::FineUIPro.NumberBox nbA6; - + protected global::FineUIPro.TextBox txtD2; + /// - /// nbProjectA6 控件。 + /// txtD3 控件。 /// /// /// 自动生成的字段。 /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 /// - protected global::FineUIPro.NumberBox nbProjectA6; - - /// - /// txtDefA6 控件。 - /// - /// - /// 自动生成的字段。 - /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 - /// - protected global::FineUIPro.TextBox txtDefA6; - - /// - /// Label17 控件。 - /// - /// - /// 自动生成的字段。 - /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 - /// - protected global::FineUIPro.Label Label17; - - /// - /// nbA 控件。 - /// - /// - /// 自动生成的字段。 - /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 - /// - protected global::FineUIPro.NumberBox nbA; - - /// - /// nbProjectA 控件。 - /// - /// - /// 自动生成的字段。 - /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 - /// - protected global::FineUIPro.NumberBox nbProjectA; - - /// - /// Label18 控件。 - /// - /// - /// 自动生成的字段。 - /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 - /// - protected global::FineUIPro.Label Label18; - - /// - /// Label19 控件。 - /// - /// - /// 自动生成的字段。 - /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 - /// - protected global::FineUIPro.Label Label19; - - /// - /// Label20 控件。 - /// - /// - /// 自动生成的字段。 - /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 - /// - protected global::FineUIPro.Label Label20; - - /// - /// nbB1 控件。 - /// - /// - /// 自动生成的字段。 - /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 - /// - protected global::FineUIPro.NumberBox nbB1; - - /// - /// nbProjectB1 控件。 - /// - /// - /// 自动生成的字段。 - /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 - /// - protected global::FineUIPro.NumberBox nbProjectB1; - - /// - /// txtDefB1 控件。 - /// - /// - /// 自动生成的字段。 - /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 - /// - protected global::FineUIPro.TextBox txtDefB1; - - /// - /// Label21 控件。 - /// - /// - /// 自动生成的字段。 - /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 - /// - protected global::FineUIPro.Label Label21; - - /// - /// Label22 控件。 - /// - /// - /// 自动生成的字段。 - /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 - /// - protected global::FineUIPro.Label Label22; - - /// - /// nbB2 控件。 - /// - /// - /// 自动生成的字段。 - /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 - /// - protected global::FineUIPro.NumberBox nbB2; - - /// - /// nbProjectB2 控件。 - /// - /// - /// 自动生成的字段。 - /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 - /// - protected global::FineUIPro.NumberBox nbProjectB2; - - /// - /// txtDefB2 控件。 - /// - /// - /// 自动生成的字段。 - /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 - /// - protected global::FineUIPro.TextBox txtDefB2; - - /// - /// Label23 控件。 - /// - /// - /// 自动生成的字段。 - /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 - /// - protected global::FineUIPro.Label Label23; - - /// - /// Label24 控件。 - /// - /// - /// 自动生成的字段。 - /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 - /// - protected global::FineUIPro.Label Label24; - - /// - /// nbB3 控件。 - /// - /// - /// 自动生成的字段。 - /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 - /// - protected global::FineUIPro.NumberBox nbB3; - - /// - /// nbProjectB3 控件。 - /// - /// - /// 自动生成的字段。 - /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 - /// - protected global::FineUIPro.NumberBox nbProjectB3; - - /// - /// txtDefB3 控件。 - /// - /// - /// 自动生成的字段。 - /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 - /// - protected global::FineUIPro.TextBox txtDefB3; - - /// - /// Label25 控件。 - /// - /// - /// 自动生成的字段。 - /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 - /// - protected global::FineUIPro.Label Label25; - - /// - /// nbB 控件。 - /// - /// - /// 自动生成的字段。 - /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 - /// - protected global::FineUIPro.NumberBox nbB; - - /// - /// nbProjectB 控件。 - /// - /// - /// 自动生成的字段。 - /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 - /// - protected global::FineUIPro.NumberBox nbProjectB; - - /// - /// Label26 控件。 - /// - /// - /// 自动生成的字段。 - /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 - /// - protected global::FineUIPro.Label Label26; - - /// - /// Label27 控件。 - /// - /// - /// 自动生成的字段。 - /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 - /// - protected global::FineUIPro.Label Label27; - - /// - /// nbAB 控件。 - /// - /// - /// 自动生成的字段。 - /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 - /// - protected global::FineUIPro.NumberBox nbAB; - - /// - /// nbProjectAB 控件。 - /// - /// - /// 自动生成的字段。 - /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 - /// - protected global::FineUIPro.NumberBox nbProjectAB; - - /// - /// Label28 控件。 - /// - /// - /// 自动生成的字段。 - /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 - /// - protected global::FineUIPro.Label Label28; - - /// - /// ContentPanel1 控件。 - /// - /// - /// 自动生成的字段。 - /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 - /// - protected global::FineUIPro.ContentPanel ContentPanel1; - - /// - /// ctlAuditFlow 控件。 - /// - /// - /// 自动生成的字段。 - /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 - /// - protected global::FineUIPro.Web.Controls.FlowOperateControl ctlAuditFlow; - + protected global::FineUIPro.TextBox txtD3; + /// /// Toolbar1 控件。 /// @@ -713,7 +436,7 @@ namespace FineUIPro.Web.HSSE.CostGoods { /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 /// protected global::FineUIPro.Toolbar Toolbar1; - + /// /// btnAttachUrl 控件。 /// @@ -722,16 +445,7 @@ namespace FineUIPro.Web.HSSE.CostGoods { /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 /// protected global::FineUIPro.Button btnAttachUrl; - - /// - /// ToolbarFill1 控件。 - /// - /// - /// 自动生成的字段。 - /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 - /// - protected global::FineUIPro.ToolbarFill ToolbarFill1; - + /// /// btnClose 控件。 /// @@ -740,7 +454,7 @@ namespace FineUIPro.Web.HSSE.CostGoods { /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 /// protected global::FineUIPro.Button btnClose; - + /// /// WindowAtt 控件。 /// diff --git a/SGGL/FineUIPro.Web/ZHGL/DataSync/HSSEData_HSSEEdit.aspx b/SGGL/FineUIPro.Web/ZHGL/DataSync/HSSEData_HSSEEdit.aspx index 00b3e395..acea1b2b 100644 --- a/SGGL/FineUIPro.Web/ZHGL/DataSync/HSSEData_HSSEEdit.aspx +++ b/SGGL/FineUIPro.Web/ZHGL/DataSync/HSSEData_HSSEEdit.aspx @@ -11,511 +11,511 @@
- + - - - - - - - + + + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + - - - - + + + + - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - + - diff --git a/SGGL/FineUIPro.Web/common/PageBase.cs b/SGGL/FineUIPro.Web/common/PageBase.cs index ac41d93a..23211d18 100644 --- a/SGGL/FineUIPro.Web/common/PageBase.cs +++ b/SGGL/FineUIPro.Web/common/PageBase.cs @@ -1,5 +1,4 @@ using BLL; -using Model; using Newtonsoft.Json; using Newtonsoft.Json.Linq; using System; diff --git a/SGGL/FineUIPro.Web/libman.json b/SGGL/FineUIPro.Web/libman.json new file mode 100644 index 00000000..ceee2710 --- /dev/null +++ b/SGGL/FineUIPro.Web/libman.json @@ -0,0 +1,5 @@ +{ + "version": "1.0", + "defaultProvider": "cdnjs", + "libraries": [] +} \ No newline at end of file diff --git a/SGGL/Model/Model.cs b/SGGL/Model/Model.cs index 3019216a..f41a62c1 100644 --- a/SGGL/Model/Model.cs +++ b/SGGL/Model/Model.cs @@ -92,6 +92,9 @@ namespace Model partial void InsertBase_CostType(Base_CostType instance); partial void UpdateBase_CostType(Base_CostType instance); partial void DeleteBase_CostType(Base_CostType instance); + partial void InsertBase_CostTypeItem(Base_CostTypeItem instance); + partial void UpdateBase_CostTypeItem(Base_CostTypeItem instance); + partial void DeleteBase_CostTypeItem(Base_CostTypeItem instance); partial void InsertBase_CQMSTrainObject(Base_CQMSTrainObject instance); partial void UpdateBase_CQMSTrainObject(Base_CQMSTrainObject instance); partial void DeleteBase_CQMSTrainObject(Base_CQMSTrainObject instance); @@ -1840,6 +1843,14 @@ namespace Model } } + public System.Data.Linq.Table Base_CostTypeItem + { + get + { + return this.GetTable(); + } + } + public System.Data.Linq.Table Base_CQMSTrainObject { get @@ -14356,19 +14367,21 @@ namespace Model private string _CostTypeId; - private string _CostTypeCode; + private System.Nullable _CostTypeCode; private string _CostTypeName; private string _Remark; + private EntitySet _Base_CostTypeItem; + #region 可扩展性方法定义 partial void OnLoaded(); partial void OnValidate(System.Data.Linq.ChangeAction action); partial void OnCreated(); partial void OnCostTypeIdChanging(string value); partial void OnCostTypeIdChanged(); - partial void OnCostTypeCodeChanging(string value); + partial void OnCostTypeCodeChanging(System.Nullable value); partial void OnCostTypeCodeChanged(); partial void OnCostTypeNameChanging(string value); partial void OnCostTypeNameChanged(); @@ -14378,6 +14391,7 @@ namespace Model public Base_CostType() { + this._Base_CostTypeItem = new EntitySet(new Action(this.attach_Base_CostTypeItem), new Action(this.detach_Base_CostTypeItem)); OnCreated(); } @@ -14401,8 +14415,8 @@ namespace Model } } - [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_CostTypeCode", DbType="NVarChar(50)")] - public string CostTypeCode + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_CostTypeCode", DbType="Int")] + public System.Nullable CostTypeCode { get { @@ -14461,6 +14475,230 @@ namespace Model } } + [global::System.Data.Linq.Mapping.AssociationAttribute(Name="FK_Base_CostTypeItem_Base_CostType", Storage="_Base_CostTypeItem", ThisKey="CostTypeId", OtherKey="CostTypeId", DeleteRule="NO ACTION")] + public EntitySet Base_CostTypeItem + { + get + { + return this._Base_CostTypeItem; + } + set + { + this._Base_CostTypeItem.Assign(value); + } + } + + public event PropertyChangingEventHandler PropertyChanging; + + public event PropertyChangedEventHandler PropertyChanged; + + protected virtual void SendPropertyChanging() + { + if ((this.PropertyChanging != null)) + { + this.PropertyChanging(this, emptyChangingEventArgs); + } + } + + protected virtual void SendPropertyChanged(String propertyName) + { + if ((this.PropertyChanged != null)) + { + this.PropertyChanged(this, new PropertyChangedEventArgs(propertyName)); + } + } + + private void attach_Base_CostTypeItem(Base_CostTypeItem entity) + { + this.SendPropertyChanging(); + entity.Base_CostType = this; + } + + private void detach_Base_CostTypeItem(Base_CostTypeItem entity) + { + this.SendPropertyChanging(); + entity.Base_CostType = null; + } + } + + [global::System.Data.Linq.Mapping.TableAttribute(Name="dbo.Base_CostTypeItem")] + public partial class Base_CostTypeItem : INotifyPropertyChanging, INotifyPropertyChanged + { + + private static PropertyChangingEventArgs emptyChangingEventArgs = new PropertyChangingEventArgs(String.Empty); + + private string _CostTypeItemId; + + private string _CostTypeId; + + private System.Nullable _SortIndex; + + private string _CostTypeItemName; + + private string _Remark; + + private EntityRef _Base_CostType; + + #region 可扩展性方法定义 + partial void OnLoaded(); + partial void OnValidate(System.Data.Linq.ChangeAction action); + partial void OnCreated(); + partial void OnCostTypeItemIdChanging(string value); + partial void OnCostTypeItemIdChanged(); + partial void OnCostTypeIdChanging(string value); + partial void OnCostTypeIdChanged(); + partial void OnSortIndexChanging(System.Nullable value); + partial void OnSortIndexChanged(); + partial void OnCostTypeItemNameChanging(string value); + partial void OnCostTypeItemNameChanged(); + partial void OnRemarkChanging(string value); + partial void OnRemarkChanged(); + #endregion + + public Base_CostTypeItem() + { + this._Base_CostType = default(EntityRef); + OnCreated(); + } + + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_CostTypeItemId", DbType="NVarChar(50) NOT NULL", CanBeNull=false, IsPrimaryKey=true)] + public string CostTypeItemId + { + get + { + return this._CostTypeItemId; + } + set + { + if ((this._CostTypeItemId != value)) + { + this.OnCostTypeItemIdChanging(value); + this.SendPropertyChanging(); + this._CostTypeItemId = value; + this.SendPropertyChanged("CostTypeItemId"); + this.OnCostTypeItemIdChanged(); + } + } + } + + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_CostTypeId", DbType="NVarChar(50)")] + public string CostTypeId + { + get + { + return this._CostTypeId; + } + set + { + if ((this._CostTypeId != value)) + { + if (this._Base_CostType.HasLoadedOrAssignedValue) + { + throw new System.Data.Linq.ForeignKeyReferenceAlreadyHasValueException(); + } + this.OnCostTypeIdChanging(value); + this.SendPropertyChanging(); + this._CostTypeId = value; + this.SendPropertyChanged("CostTypeId"); + this.OnCostTypeIdChanged(); + } + } + } + + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_SortIndex", DbType="Int")] + public System.Nullable SortIndex + { + get + { + return this._SortIndex; + } + set + { + if ((this._SortIndex != value)) + { + this.OnSortIndexChanging(value); + this.SendPropertyChanging(); + this._SortIndex = value; + this.SendPropertyChanged("SortIndex"); + this.OnSortIndexChanged(); + } + } + } + + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_CostTypeItemName", DbType="NVarChar(50)")] + public string CostTypeItemName + { + get + { + return this._CostTypeItemName; + } + set + { + if ((this._CostTypeItemName != value)) + { + this.OnCostTypeItemNameChanging(value); + this.SendPropertyChanging(); + this._CostTypeItemName = value; + this.SendPropertyChanged("CostTypeItemName"); + this.OnCostTypeItemNameChanged(); + } + } + } + + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Remark", DbType="NVarChar(500)")] + public string Remark + { + get + { + return this._Remark; + } + set + { + if ((this._Remark != value)) + { + this.OnRemarkChanging(value); + this.SendPropertyChanging(); + this._Remark = value; + this.SendPropertyChanged("Remark"); + this.OnRemarkChanged(); + } + } + } + + [global::System.Data.Linq.Mapping.AssociationAttribute(Name="FK_Base_CostTypeItem_Base_CostType", Storage="_Base_CostType", ThisKey="CostTypeId", OtherKey="CostTypeId", IsForeignKey=true)] + public Base_CostType Base_CostType + { + get + { + return this._Base_CostType.Entity; + } + set + { + Base_CostType previousValue = this._Base_CostType.Entity; + if (((previousValue != value) + || (this._Base_CostType.HasLoadedOrAssignedValue == false))) + { + this.SendPropertyChanging(); + if ((previousValue != null)) + { + this._Base_CostType.Entity = null; + previousValue.Base_CostTypeItem.Remove(this); + } + this._Base_CostType.Entity = value; + if ((value != null)) + { + value.Base_CostTypeItem.Add(this); + this._CostTypeId = value.CostTypeId; + } + else + { + this._CostTypeId = default(string); + } + this.SendPropertyChanged("Base_CostType"); + } + } + } + public event PropertyChangingEventHandler PropertyChanging; public event PropertyChangedEventHandler PropertyChanged; @@ -57929,6 +58167,10 @@ namespace Model private System.Nullable _ApproveDate; + private System.Nullable _SortIndex; + + private System.Nullable _Year; + private EntityRef _Base_Project; private EntitySet _CostGoods_ExpenseDetail; @@ -57971,6 +58213,10 @@ namespace Model partial void OnApproveManChanged(); partial void OnApproveDateChanging(System.Nullable value); partial void OnApproveDateChanged(); + partial void OnSortIndexChanging(System.Nullable value); + partial void OnSortIndexChanged(); + partial void OnYearChanging(System.Nullable value); + partial void OnYearChanged(); #endregion public CostGoods_Expense() @@ -58025,7 +58271,7 @@ namespace Model } } - [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ExpenseCode", DbType="NVarChar(50) NOT NULL", CanBeNull=false)] + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ExpenseCode", DbType="NVarChar(50)")] public string ExpenseCode { get @@ -58189,7 +58435,7 @@ namespace Model } } - [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_CompileMan", DbType="NVarChar(20)")] + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_CompileMan", DbType="NVarChar(50)")] public string CompileMan { get @@ -58229,7 +58475,7 @@ namespace Model } } - [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_CheckMan", DbType="NVarChar(20)")] + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_CheckMan", DbType="NVarChar(50)")] public string CheckMan { get @@ -58269,7 +58515,7 @@ namespace Model } } - [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ApproveMan", DbType="NVarChar(20)")] + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ApproveMan", DbType="NVarChar(50)")] public string ApproveMan { get @@ -58309,6 +58555,46 @@ namespace Model } } + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_SortIndex", DbType="Int")] + public System.Nullable SortIndex + { + get + { + return this._SortIndex; + } + set + { + if ((this._SortIndex != value)) + { + this.OnSortIndexChanging(value); + this.SendPropertyChanging(); + this._SortIndex = value; + this.SendPropertyChanged("SortIndex"); + this.OnSortIndexChanged(); + } + } + } + + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Year", DbType="Int")] + public System.Nullable Year + { + get + { + return this._Year; + } + set + { + if ((this._Year != value)) + { + this.OnYearChanging(value); + this.SendPropertyChanging(); + this._Year = value; + this.SendPropertyChanged("Year"); + this.OnYearChanged(); + } + } + } + [global::System.Data.Linq.Mapping.AssociationAttribute(Name="FK_CostGoods_Expense_Base_Project", Storage="_Base_Project", ThisKey="ProjectId", OtherKey="ProjectId", IsForeignKey=true)] public Base_Project Base_Project { @@ -58439,6 +58725,16 @@ namespace Model private string _CostDef; + private string _CostTypeName; + + private string _SupCostTypeName; + + private string _SupCostTypeId; + + private System.Nullable _SortIndex; + + private System.Nullable _SupSortIndex; + private EntityRef _CostGoods_Expense; #region 可扩展性方法定义 @@ -58455,6 +58751,16 @@ namespace Model partial void OnCostMoneyChanged(); partial void OnCostDefChanging(string value); partial void OnCostDefChanged(); + partial void OnCostTypeNameChanging(string value); + partial void OnCostTypeNameChanged(); + partial void OnSupCostTypeNameChanging(string value); + partial void OnSupCostTypeNameChanged(); + partial void OnSupCostTypeIdChanging(string value); + partial void OnSupCostTypeIdChanged(); + partial void OnSortIndexChanging(System.Nullable value); + partial void OnSortIndexChanged(); + partial void OnSupSortIndexChanging(System.Nullable value); + partial void OnSupSortIndexChanged(); #endregion public CostGoods_ExpenseDetail() @@ -58527,7 +58833,7 @@ namespace Model } } - [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_CostMoney", DbType="Money")] + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_CostMoney", DbType="Decimal(18,2)")] public System.Nullable CostMoney { get @@ -58567,6 +58873,106 @@ namespace Model } } + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_CostTypeName", DbType="NVarChar(50)")] + public string CostTypeName + { + get + { + return this._CostTypeName; + } + set + { + if ((this._CostTypeName != value)) + { + this.OnCostTypeNameChanging(value); + this.SendPropertyChanging(); + this._CostTypeName = value; + this.SendPropertyChanged("CostTypeName"); + this.OnCostTypeNameChanged(); + } + } + } + + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_SupCostTypeName", DbType="NVarChar(50)")] + public string SupCostTypeName + { + get + { + return this._SupCostTypeName; + } + set + { + if ((this._SupCostTypeName != value)) + { + this.OnSupCostTypeNameChanging(value); + this.SendPropertyChanging(); + this._SupCostTypeName = value; + this.SendPropertyChanged("SupCostTypeName"); + this.OnSupCostTypeNameChanged(); + } + } + } + + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_SupCostTypeId", DbType="NVarChar(50)")] + public string SupCostTypeId + { + get + { + return this._SupCostTypeId; + } + set + { + if ((this._SupCostTypeId != value)) + { + this.OnSupCostTypeIdChanging(value); + this.SendPropertyChanging(); + this._SupCostTypeId = value; + this.SendPropertyChanged("SupCostTypeId"); + this.OnSupCostTypeIdChanged(); + } + } + } + + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_SortIndex", DbType="Int")] + public System.Nullable SortIndex + { + get + { + return this._SortIndex; + } + set + { + if ((this._SortIndex != value)) + { + this.OnSortIndexChanging(value); + this.SendPropertyChanging(); + this._SortIndex = value; + this.SendPropertyChanged("SortIndex"); + this.OnSortIndexChanged(); + } + } + } + + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_SupSortIndex", DbType="Int")] + public System.Nullable SupSortIndex + { + get + { + return this._SupSortIndex; + } + set + { + if ((this._SupSortIndex != value)) + { + this.OnSupSortIndexChanging(value); + this.SendPropertyChanging(); + this._SupSortIndex = value; + this.SendPropertyChanged("SupSortIndex"); + this.OnSupSortIndexChanged(); + } + } + } + [global::System.Data.Linq.Mapping.AssociationAttribute(Name="FK_CostGoods_ExpenseDetail_CostGoods_Expense", Storage="_CostGoods_Expense", ThisKey="ExpenseId", OtherKey="ExpenseId", IsForeignKey=true)] public CostGoods_Expense CostGoods_Expense { @@ -171589,7 +171995,7 @@ namespace Model } } - [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Remarks", DbType="NVarChar(2000)")] + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Remarks", DbType="NVarChar(MAX)", UpdateCheck=UpdateCheck.Never)] public string Remarks { get @@ -172209,7 +172615,7 @@ namespace Model } } - [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_PriceMethod", DbType="VarChar(50)")] + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_PriceMethod", DbType="NVarChar(500)")] public string PriceMethod { get @@ -172349,7 +172755,7 @@ namespace Model } } - [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Clause", DbType="NVarChar(2000)")] + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Clause", DbType="NVarChar(MAX)", UpdateCheck=UpdateCheck.Never)] public string Clause { get diff --git a/SGGL/WebAPI/Controllers/PersonController.cs b/SGGL/WebAPI/Controllers/PersonController.cs index ecb08e36..9e5d9f4d 100644 --- a/SGGL/WebAPI/Controllers/PersonController.cs +++ b/SGGL/WebAPI/Controllers/PersonController.cs @@ -701,6 +701,7 @@ namespace WebAPI.Controllers select new { x.PersonId, + x.SitePersonId, x.PersonName, x.CardNo, x.IdentityCard, @@ -785,6 +786,38 @@ namespace WebAPI.Controllers } return responeData; } + + /// + /// + /// + /// + /// + /// + /// + public Model.ResponeData getUpdatePersonExchangeTime(string projectId,string idCard, string type) + { + var responeData = new Model.ResponeData(); + try + { + var getsiteperson = Funs.DB.SitePerson_Person.FirstOrDefault(x => x.ProjectId == projectId && x.IdentityCard == idCard); + if (getsiteperson != null) + { + APIPersonService.getUpdatePersonExchangeTime(getsiteperson.SitePersonId, type); + } + else + { + responeData.code = 1; + responeData.message = "当前项目不存在身份证为:" + idCard.ToString() +"的人员!"; + } + + } + catch (Exception ex) + { + responeData.code = 0; + responeData.message = ex.Message; + } + return responeData; + } #endregion #region 获取人员信息出入场记录 diff --git a/SGGL/WebAPI/Properties/PublishProfiles/FolderProfile.pubxml b/SGGL/WebAPI/Properties/PublishProfiles/FolderProfile.pubxml deleted file mode 100644 index cd69b0ac..00000000 --- a/SGGL/WebAPI/Properties/PublishProfiles/FolderProfile.pubxml +++ /dev/null @@ -1,22 +0,0 @@ - - - - - FileSystem - FileSystem - Release - Any CPU - - True - False - E:\WebApi - True - True - True - False - DonotMerge - - \ No newline at end of file diff --git a/SGGL/WebAPI/Properties/PublishProfiles/FolderProfile1.pubxml b/SGGL/WebAPI/Properties/PublishProfiles/FolderProfile1.pubxml index 696472e5..99fa69e2 100644 --- a/SGGL/WebAPI/Properties/PublishProfiles/FolderProfile1.pubxml +++ b/SGGL/WebAPI/Properties/PublishProfiles/FolderProfile1.pubxml @@ -4,7 +4,7 @@ https://go.microsoft.com/fwlink/?LinkID=208121. --> - false + true false true Release diff --git a/SGGL/WebAPI/Properties/PublishProfiles/FolderProfile2.pubxml b/SGGL/WebAPI/Properties/PublishProfiles/FolderProfile2.pubxml deleted file mode 100644 index 99fa69e2..00000000 --- a/SGGL/WebAPI/Properties/PublishProfiles/FolderProfile2.pubxml +++ /dev/null @@ -1,17 +0,0 @@ - - - - - true - false - true - Release - Any CPU - FileSystem - E:\Package\赛鼎工程有限公司\SGGLAPI - FileSystem - - - \ No newline at end of file diff --git a/SGGL/WebAPI/Properties/PublishProfiles/FolderProfile3.pubxml b/SGGL/WebAPI/Properties/PublishProfiles/FolderProfile3.pubxml deleted file mode 100644 index cc554435..00000000 --- a/SGGL/WebAPI/Properties/PublishProfiles/FolderProfile3.pubxml +++ /dev/null @@ -1,16 +0,0 @@ - - - - - False - False - True - Release - Any CPU - FileSystem - bin\app.publish\ - FileSystem - - \ No newline at end of file diff --git a/SGGL/WebAPI/Properties/PublishProfiles/FolderProfile4.pubxml b/SGGL/WebAPI/Properties/PublishProfiles/FolderProfile4.pubxml deleted file mode 100644 index 7c5e7db1..00000000 --- a/SGGL/WebAPI/Properties/PublishProfiles/FolderProfile4.pubxml +++ /dev/null @@ -1,18 +0,0 @@ - - - - - true - false - true - Release - Any CPU - FileSystem - bin\app.publish\ - FileSystem - <_TargetId>Folder - - - \ No newline at end of file diff --git a/SGGL/WebAPI/WebAPI.csproj b/SGGL/WebAPI/WebAPI.csproj index febfec5d..19a32c6a 100644 --- a/SGGL/WebAPI/WebAPI.csproj +++ b/SGGL/WebAPI/WebAPI.csproj @@ -271,7 +271,6 @@ - @@ -299,6 +298,7 @@ + @@ -360,7 +360,7 @@ True 0 / - http://localhost:7655/ + http://localhost:3305/ False False