From 32c893fdc347c2da771299661aae47a6111d9b48 Mon Sep 17 00:00:00 2001 From: fly-l <1420031550@qq.com> Date: Wed, 1 Nov 2023 23:12:52 +0800 Subject: [PATCH 1/6] 2023-11-01 --- .vs/SGGL_SeDin/v17/.wsuo | Bin 264192 -> 265216 bytes .../BillOfQuantities/PhtglQuantityService.cs | 29 ++++ .../PhtglContracttrackService .cs | 61 +++++++-- .../PhtglContracttrackprogressService.cs | 2 +- .../ContractTrackComparison.aspx | 100 +++++++------- .../ContractTrackComparison.aspx.cs | 23 ++-- .../ContractTrackComparison.aspx.designer.cs | 18 +++ .../ContractCompile/ContractTrackEdit.aspx | 31 +++-- .../ContractCompile/ContractTrackEdit.aspx.cs | 12 +- .../ContractTrackEdit.aspx.designer.cs | 6 +- .../ContractCompile/ContractTrackList.aspx | 4 +- .../ContractCompile/ContractTrackList.aspx.cs | 19 ++- .../ContractTrackList.aspx.designer.cs | 18 +++ .../ContractTrackProgressDetectionGrid.aspx | 26 +++- ...ContractTrackProgressDetectionGrid.aspx.cs | 66 +++++---- ...rackProgressDetectionGrid.aspx.designer.cs | 45 ++++++ .../PHTGL/ContractCompile/ContractWBS.aspx | 9 +- .../PHTGL/ContractCompile/ContractWBS.aspx.cs | 75 +++++++++- .../ContractWBS.aspx.designer.cs | 27 ++++ SGGL/Model/Model.cs | 128 +++++++++--------- 20 files changed, 496 insertions(+), 203 deletions(-) diff --git a/.vs/SGGL_SeDin/v17/.wsuo b/.vs/SGGL_SeDin/v17/.wsuo index 8deb1efc87ca3b79ce1806b8d50fcd1d1aea4464..801c4d5de45dc8e6dd94442ea011224700b588c2 100644 GIT binary patch delta 2303 zcmchYZA?>F7{~9q_mRS1+1bJqzR=hw5WJ_o46rp5NE=ODJ^1j4vG|c(e)~B zm}nN)XGyp0-F;iKEYd9Qo2W~cEGFC6?c+XdZ04V_Do_s0E3)L+8uVSj4LqP0 z)B!K32Rv>IY6afehPpwL=#OHXc?a5UU?+GMkbSMOpKW{*90f0dK`;c^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/PhtglQuantityService.cs +++ b/SGGL/BLL/PHTGL/BillOfQuantities/PhtglQuantityService.cs @@ -338,6 +338,35 @@ namespace BLL return list; } + public static ListItem[] GetMajorItems3() + { + var list = new ListItem[12]; + list[0] = new ListItem("土建工程", "土建工程"); + list[1] = new ListItem("钢结构预制工程", "钢结构预制工程"); + list[2] = new ListItem("工艺管道安装工程", "工艺管道安装工程"); + list[3] = new ListItem("工艺设备安装工程", "工艺设备安装工程"); + list[4] = new ListItem("非标设备现场制作安装工程", "非标设备现场制作安装工程"); + list[5] = new ListItem("电气工程", "电气工程"); + list[6] = new ListItem("仪表工程", "仪表工程"); + list[7] = new ListItem("电信工程", "电信工程"); + list[8] = new ListItem("水暖安装工程", "水暖安装工程"); + list[9] = new ListItem("防腐绝热工程", "防腐绝热工程"); + list[10] = new ListItem("无损检测工程", "无损检测工程"); + list[11] = new ListItem("消防工程", "消防工程"); + + return list; + } + public static void IniGetMajorItems3DownList(FineUIPro.DropDownList dropName, bool isShowPlease) + { + dropName.DataValueField = "Value"; + dropName.DataTextField = "Text"; + dropName.DataSource = GetMajorItems3(); + dropName.DataBind(); + if (isShowPlease) + { + Funs.FineUIPleaseSelect(dropName); + } + } #region 获取列表 diff --git a/SGGL/BLL/PHTGL/ContractCompile/PhtglContracttrackService .cs b/SGGL/BLL/PHTGL/ContractCompile/PhtglContracttrackService .cs index ec3bd6d2..adb12d71 100644 --- a/SGGL/BLL/PHTGL/ContractCompile/PhtglContracttrackService .cs +++ b/SGGL/BLL/PHTGL/ContractCompile/PhtglContracttrackService .cs @@ -42,11 +42,6 @@ namespace BLL (string.IsNullOrEmpty(table.UnitOfMeasurement) || x.UnitOfMeasurement.Contains(table.UnitOfMeasurement)) && (string.IsNullOrEmpty(table.Quantity) || x.Quantity.Contains(table.Quantity)) && - (string.IsNullOrEmpty(table.TotalCostFixedComprehensiveUnitPrice) || - x.TotalCostFixedComprehensiveUnitPrice.Contains(table.TotalCostFixedComprehensiveUnitPrice)) && - (string.IsNullOrEmpty(table.MainMaterialCost) || - x.MainMaterialCost.Contains(table.MainMaterialCost)) && - (string.IsNullOrEmpty(table.TotalPrice) || x.TotalPrice.Contains(table.TotalPrice)) && (string.IsNullOrEmpty(table.CalculationRule) || x.CalculationRule.Contains(table.CalculationRule)) && (string.IsNullOrEmpty(table.WorkContent) || x.WorkContent.Contains(table.WorkContent)) && @@ -72,6 +67,51 @@ namespace BLL return model; } + public static PHTGL_ContractTrack GetFirstPHTGL_ContractTrackByModle(PHTGL_ContractTrack table) + { + var q = (from x in Funs.DB.PHTGL_ContractTrack + where + (string.IsNullOrEmpty(table.Id) || x.Id.Contains(table.Id)) && + (string.IsNullOrEmpty(table.ContractNum) || x.ContractNum.Contains(table.ContractNum)) && + (string.IsNullOrEmpty(table.MainItemCode) || x.MainItemCode.Contains(table.MainItemCode)) && + (string.IsNullOrEmpty(table.MainItemName) || x.MainItemName.Contains(table.MainItemName)) && + (string.IsNullOrEmpty(table.MajorName) || x.MajorName.Contains(table.MajorName)) && + (string.IsNullOrEmpty(table.MajorCode) || x.MajorCode.Contains(table.MajorCode)) && + (string.IsNullOrEmpty(table.SubProject) || x.SubProject.Contains(table.SubProject)) && + (string.IsNullOrEmpty(table.SubItemProject) || + x.SubItemProject.Contains(table.SubItemProject)) && + (string.IsNullOrEmpty(table.ProjectCode) || x.ProjectCode.Contains(table.ProjectCode)) && + (string.IsNullOrEmpty(table.ProjectName) || x.ProjectName.Contains(table.ProjectName)) && + (string.IsNullOrEmpty(table.ProjectDescription) || + x.ProjectDescription.Contains(table.ProjectDescription)) && + (string.IsNullOrEmpty(table.UnitOfMeasurement) || + x.UnitOfMeasurement.Contains(table.UnitOfMeasurement)) && + (string.IsNullOrEmpty(table.Quantity) || x.Quantity.Contains(table.Quantity)) && + (string.IsNullOrEmpty(table.CalculationRule) || + x.CalculationRule.Contains(table.CalculationRule)) && + (string.IsNullOrEmpty(table.WorkContent) || x.WorkContent.Contains(table.WorkContent)) && + (string.IsNullOrEmpty(table.Remarks) || x.Remarks.Contains(table.Remarks)) && + (string.IsNullOrEmpty(table.ConstructionSubcontractor) || + x.ConstructionSubcontractor.Contains(table.ConstructionSubcontractor)) && + (string.IsNullOrEmpty(table.ContractWeight) || + x.ContractWeight.Contains(table.ContractWeight)) && + (string.IsNullOrEmpty(table.MaterialSupplier) || + x.MaterialSupplier.Contains(table.MaterialSupplier)) && + (string.IsNullOrEmpty(table.EstimatedQuantity) || + x.EstimatedQuantity.Contains(table.EstimatedQuantity)) && + (string.IsNullOrEmpty(table.SettledQuantity) || + x.SettledQuantity.Contains(table.SettledQuantity)) && + (string.IsNullOrEmpty(table.ContractId) || + table.ContractId.Split(',').Contains(x.ContractId)) && + (string.IsNullOrEmpty(table.ProjectId) || + x.ProjectId.Contains(table.ProjectId)) + + select x).FirstOrDefault() + ; + return q; + } + + /// /// 获取分页列表 /// @@ -115,7 +155,8 @@ namespace BLL x.EstimatedAmount, x.SettledQuantity, x.SettledAmount, - x.ContractId + x.ContractId, + x.SerialNumber }; } @@ -287,7 +328,7 @@ namespace BLL Funs.GetNewDecimalOrZero(model.SettledQuantity); } - return result; + return result; } /// @@ -1322,15 +1363,15 @@ namespace BLL /// /// 全费用固定综合单价 /// - [ExcelColumnIndex("M")] public string TotalCostFixedComprehensiveUnitPrice { get; set; } + [ExcelColumnIndex("M")] public decimal TotalCostFixedComprehensiveUnitPrice { get; set; } /// /// 其中:主材费 /// - [ExcelColumnIndex("N")] public string MainMaterialCost { get; set; } + [ExcelColumnIndex("N")] public decimal MainMaterialCost { get; set; } /// /// 合价/元 /// - [ExcelColumnIndex("O")] public string TotalPrice { get; set; } + [ExcelColumnIndex("O")] public decimal TotalPrice { get; set; } /// /// 计算规则 /// diff --git a/SGGL/BLL/PHTGL/ContractCompile/PhtglContracttrackprogressService.cs b/SGGL/BLL/PHTGL/ContractCompile/PhtglContracttrackprogressService.cs index c84d0cee..5fc442a7 100644 --- a/SGGL/BLL/PHTGL/ContractCompile/PhtglContracttrackprogressService.cs +++ b/SGGL/BLL/PHTGL/ContractCompile/PhtglContracttrackprogressService.cs @@ -172,7 +172,7 @@ namespace BLL var modeContractTrack = PhtglContractTrackService.GetPHTGL_ContractTrackById(contractTrackId); if (modeContractTrack!=null) { - var totalCostFixedComprehensiveUnitPrice = Funs.GetNewDecimalOrZero(modeContractTrack.TotalCostFixedComprehensiveUnitPrice); //全费用综合单价 + var totalCostFixedComprehensiveUnitPrice = modeContractTrack.TotalCostFixedComprehensiveUnitPrice; //全费用综合单价 var settledAmount = modeContractTrack.SettledAmount??0;//预算金额 var contractWeight= Funs.GetNewDecimalOrZero(modeContractTrack.ContractWeight)==0?0: Funs.GetNewDecimalOrZero(modeContractTrack.ContractWeight)/100;//合同权重 var quserytable = new Model.PHTGL_ContractTrackProgress(); diff --git a/SGGL/FineUIPro.Web/PHTGL/ContractCompile/ContractTrackComparison.aspx b/SGGL/FineUIPro.Web/PHTGL/ContractCompile/ContractTrackComparison.aspx index 287ff9e0..4cb71d60 100644 --- a/SGGL/FineUIPro.Web/PHTGL/ContractCompile/ContractTrackComparison.aspx +++ b/SGGL/FineUIPro.Web/PHTGL/ContractCompile/ContractTrackComparison.aspx @@ -21,7 +21,6 @@ .f-grid-row.red { background-color: Yellow; - } .color1 { @@ -38,12 +37,12 @@ - + SortDirection="DESC" OnSort="Grid1_Sort" EnableColumnLines="true" + AllowPaging="True" IsDatabasePaging="true" PageSize="500" OnPageIndexChange="Grid1_PageIndexChange" + EnableRowDoubleClickEvent="true" EnableRowClickEvent="True"> @@ -53,7 +52,7 @@ - + @@ -66,6 +65,8 @@ + + - - + FieldType="String" HeaderText="序号" TextAlign="Center" HeaderTextAlign="Center"> + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + @@ -168,7 +168,7 @@ - - @@ -230,14 +230,14 @@ - + - + - <%-- + <%-- --%> diff --git a/SGGL/FineUIPro.Web/PHTGL/ContractCompile/ContractTrackComparison.aspx.cs b/SGGL/FineUIPro.Web/PHTGL/ContractCompile/ContractTrackComparison.aspx.cs index 9f669dea..f4997206 100644 --- a/SGGL/FineUIPro.Web/PHTGL/ContractCompile/ContractTrackComparison.aspx.cs +++ b/SGGL/FineUIPro.Web/PHTGL/ContractCompile/ContractTrackComparison.aspx.cs @@ -30,6 +30,8 @@ namespace FineUIPro.Web.PHTGL.ContractCompile this.DropContractCode.DataSource = BLL.PHTGL_ContractReviewService.GetContractReview_CompleteData(this.CurrUser.LoginProjectId); this.DropContractCode.DataBind(); Funs.FineUIPleaseSelect(this.DropContractCode); + + PHTGL_QuantityService.IniGetMajorItems3DownList(drpMajorItems, true); DropMainContractCode_SelectedIndexChanged(null, null); this.ddlPageSize.SelectedValue = this.Grid1.PageSize.ToString(); // 绑定表格 @@ -49,12 +51,15 @@ namespace FineUIPro.Web.PHTGL.ContractCompile table.ContractId = this.ContractId; table.ProjectCode = this.txtProjectCode.Text.Trim(); table.ProjectName = this.txtProjectName.Text.Trim(); - var tb = BLL.PhtglContractTrackService.GetPHTGL_ContractTrackByModle(table); - Grid1.RecordCount = tb.Count; - //tb = GetFilteredTable(Grid1.FilteredData, tb); - Grid1.DataSource = tb; + table.MainItemName = this.txtMainItemName.Text.Trim(); + if (drpMajorItems.SelectedValue != Const._Null) + { + table.MajorName = drpMajorItems.SelectedValue; + } + Grid1.DataSource = PhtglContractTrackService.GetListData(table, Grid1); + Grid1.RecordCount = PhtglContractTrackService.Count; Grid1.DataBind(); - + } @@ -99,7 +104,7 @@ namespace FineUIPro.Web.PHTGL.ContractCompile { var model = (Model.PHTGL_ContractTrack)e.DataItem; // 工程量偏差 - decimal QuantityOffset = Funs.GetNewDecimalOrZero(model.EstimatedQuantity) - + decimal? QuantityOffset = Funs.GetNewDecimalOrZero(model.EstimatedQuantity) - Funs.GetNewDecimalOrZero(model.SettledQuantity); TemplateField bfQuantityOffset = Grid1.FindColumn("QuantityOffset") as TemplateField; if (QuantityOffset < 0) @@ -246,9 +251,9 @@ namespace FineUIPro.Web.PHTGL.ContractCompile model.ProjectDescription = ProjectDescription; model.UnitOfMeasurement = UnitOfMeasurement; model.Quantity = Quantity; - model.TotalCostFixedComprehensiveUnitPrice = TotalCostFixedComprehensiveUnitPrice; - model.MainMaterialCost = MainMaterialCost; - model.TotalPrice = TotalPrice; + model.TotalCostFixedComprehensiveUnitPrice = Funs.GetNewDecimalOrZero( TotalCostFixedComprehensiveUnitPrice); + model.MainMaterialCost = Funs.GetNewDecimalOrZero(MainMaterialCost); + model.TotalPrice = Funs.GetNewDecimalOrZero(TotalPrice); model.CalculationRule = CalculationRule; model.WorkContent = WorkContent; model.Remarks = Remarks; diff --git a/SGGL/FineUIPro.Web/PHTGL/ContractCompile/ContractTrackComparison.aspx.designer.cs b/SGGL/FineUIPro.Web/PHTGL/ContractCompile/ContractTrackComparison.aspx.designer.cs index e3f7fef8..f9a17adf 100644 --- a/SGGL/FineUIPro.Web/PHTGL/ContractCompile/ContractTrackComparison.aspx.designer.cs +++ b/SGGL/FineUIPro.Web/PHTGL/ContractCompile/ContractTrackComparison.aspx.designer.cs @@ -131,6 +131,24 @@ namespace FineUIPro.Web.PHTGL.ContractCompile /// protected global::FineUIPro.TextBox txtProjectName; + /// + /// txtMainItemName 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.TextBox txtMainItemName; + + /// + /// drpMajorItems 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.DropDownList drpMajorItems; + /// /// btnQuery 控件。 /// diff --git a/SGGL/FineUIPro.Web/PHTGL/ContractCompile/ContractTrackEdit.aspx b/SGGL/FineUIPro.Web/PHTGL/ContractCompile/ContractTrackEdit.aspx index 5cdf2e9c..3b1e3dc5 100644 --- a/SGGL/FineUIPro.Web/PHTGL/ContractCompile/ContractTrackEdit.aspx +++ b/SGGL/FineUIPro.Web/PHTGL/ContractCompile/ContractTrackEdit.aspx @@ -86,21 +86,24 @@ - - + + + + + + + + + + + + - - - - - - - - - - - - + + diff --git a/SGGL/FineUIPro.Web/PHTGL/ContractCompile/ContractTrackEdit.aspx.cs b/SGGL/FineUIPro.Web/PHTGL/ContractCompile/ContractTrackEdit.aspx.cs index 42ac786e..ae7a3f76 100644 --- a/SGGL/FineUIPro.Web/PHTGL/ContractCompile/ContractTrackEdit.aspx.cs +++ b/SGGL/FineUIPro.Web/PHTGL/ContractCompile/ContractTrackEdit.aspx.cs @@ -58,9 +58,9 @@ namespace FineUIPro.Web.PHTGL.ContractCompile txtProjectDescription.Text = model.ProjectDescription; txtUnitOfMeasurement.Text = model.UnitOfMeasurement; txtQuantity.Text = model.Quantity; - txtTotalCostFixedComprehensiveUnitPrice.Text = model.TotalCostFixedComprehensiveUnitPrice; - txtMainMaterialCost.Text = model.MainMaterialCost; - txtTotalPrice.Text = model.TotalPrice; + txtTotalCostFixedComprehensiveUnitPrice.Text = model.TotalCostFixedComprehensiveUnitPrice.HasValue?model.TotalCostFixedComprehensiveUnitPrice.ToString():""; + txtMainMaterialCost.Text = model.MainMaterialCost.HasValue ? model.MainMaterialCost.ToString() : ""; + txtTotalPrice.Text = model.TotalPrice.HasValue ? model.TotalPrice.ToString() : ""; txtCalculationRule.Text = model.CalculationRule; txtWorkContent.Text = model.WorkContent; txtRemarks.Text = model.Remarks; @@ -167,9 +167,9 @@ namespace FineUIPro.Web.PHTGL.ContractCompile table.ProjectDescription = txtProjectDescription.Text; table.UnitOfMeasurement = txtUnitOfMeasurement.Text; table.Quantity = txtQuantity.Text; - table.TotalCostFixedComprehensiveUnitPrice = txtTotalCostFixedComprehensiveUnitPrice.Text; - table.MainMaterialCost = txtMainMaterialCost.Text; - table.TotalPrice = txtTotalPrice.Text; + table.TotalCostFixedComprehensiveUnitPrice = Funs.GetNewDecimalOrZero(txtTotalCostFixedComprehensiveUnitPrice.Text); + table.MainMaterialCost = Funs.GetNewDecimalOrZero(txtMainMaterialCost.Text); + table.TotalPrice = Funs.GetNewDecimalOrZero(txtTotalPrice.Text); table.CalculationRule = txtCalculationRule.Text; table.WorkContent = txtWorkContent.Text; table.Remarks = txtRemarks.Text; diff --git a/SGGL/FineUIPro.Web/PHTGL/ContractCompile/ContractTrackEdit.aspx.designer.cs b/SGGL/FineUIPro.Web/PHTGL/ContractCompile/ContractTrackEdit.aspx.designer.cs index c5e3ea67..7b6d05d0 100644 --- a/SGGL/FineUIPro.Web/PHTGL/ContractCompile/ContractTrackEdit.aspx.designer.cs +++ b/SGGL/FineUIPro.Web/PHTGL/ContractCompile/ContractTrackEdit.aspx.designer.cs @@ -165,7 +165,7 @@ namespace FineUIPro.Web.PHTGL.ContractCompile /// 自动生成的字段。 /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 /// - protected global::FineUIPro.TextBox txtTotalCostFixedComprehensiveUnitPrice; + protected global::FineUIPro.NumberBox txtTotalCostFixedComprehensiveUnitPrice; /// /// txtMainMaterialCost 控件。 @@ -174,7 +174,7 @@ namespace FineUIPro.Web.PHTGL.ContractCompile /// 自动生成的字段。 /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 /// - protected global::FineUIPro.TextBox txtMainMaterialCost; + protected global::FineUIPro.NumberBox txtMainMaterialCost; /// /// txtTotalPrice 控件。 @@ -183,7 +183,7 @@ namespace FineUIPro.Web.PHTGL.ContractCompile /// 自动生成的字段。 /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 /// - protected global::FineUIPro.TextBox txtTotalPrice; + protected global::FineUIPro.NumberBox txtTotalPrice; /// /// txtCalculationRule 控件。 diff --git a/SGGL/FineUIPro.Web/PHTGL/ContractCompile/ContractTrackList.aspx b/SGGL/FineUIPro.Web/PHTGL/ContractCompile/ContractTrackList.aspx index ded7be69..2d56a098 100644 --- a/SGGL/FineUIPro.Web/PHTGL/ContractCompile/ContractTrackList.aspx +++ b/SGGL/FineUIPro.Web/PHTGL/ContractCompile/ContractTrackList.aspx @@ -40,7 +40,7 @@ runat="server" BoxFlex="1" DataKeyNames="Id" AllowCellEditing="true" ClicksToEdit="1" DataIDField="Id" AllowSorting="true" SortField="Id" SortDirection="DESC" OnSort="Grid1_Sort" EnableColumnLines="true" - AllowPaging="False" IsDatabasePaging="true" PageSize="10" OnPageIndexChange="Grid1_PageIndexChange" + AllowPaging="True" IsDatabasePaging="true" PageSize="500" OnPageIndexChange="Grid1_PageIndexChange" EnableRowDoubleClickEvent="true" OnRowDoubleClick="Grid1_RowDoubleClick" EnableRowClickEvent="True"> @@ -70,6 +70,8 @@ + + Funs.GetNewDecimalOrZero(x.TotalPrice) ).ToList().Sum(); + var sumTotalPricea = tb.Select(x => x.TotalPrice).ToList().Sum(); lbTotalPrice.Text = sumTotalPricea.ToString(); } @@ -468,9 +475,9 @@ namespace FineUIPro.Web.PHTGL.ContractCompile model.ProjectDescription = ProjectDescription; model.UnitOfMeasurement = UnitOfMeasurement; model.Quantity = Quantity; - model.TotalCostFixedComprehensiveUnitPrice = TotalCostFixedComprehensiveUnitPrice; - model.MainMaterialCost = MainMaterialCost; - model.TotalPrice = TotalPrice; + model.TotalCostFixedComprehensiveUnitPrice =Funs.GetNewDecimalOrZero( TotalCostFixedComprehensiveUnitPrice); + model.MainMaterialCost = Funs.GetNewDecimalOrZero(MainMaterialCost); + model.TotalPrice = Funs.GetNewDecimalOrZero(TotalPrice); model.CalculationRule = CalculationRule; model.WorkContent = WorkContent; model.Remarks = Remarks; diff --git a/SGGL/FineUIPro.Web/PHTGL/ContractCompile/ContractTrackList.aspx.designer.cs b/SGGL/FineUIPro.Web/PHTGL/ContractCompile/ContractTrackList.aspx.designer.cs index 87f8e89a..7917cb25 100644 --- a/SGGL/FineUIPro.Web/PHTGL/ContractCompile/ContractTrackList.aspx.designer.cs +++ b/SGGL/FineUIPro.Web/PHTGL/ContractCompile/ContractTrackList.aspx.designer.cs @@ -158,6 +158,24 @@ namespace FineUIPro.Web.PHTGL.ContractCompile /// protected global::FineUIPro.TextBox txtProjectName; + /// + /// txtMainItemName 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.TextBox txtMainItemName; + + /// + /// drpMajorItems 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.DropDownList drpMajorItems; + /// /// btnQuery 控件。 /// diff --git a/SGGL/FineUIPro.Web/PHTGL/ContractCompile/ContractTrackProgressDetectionGrid.aspx b/SGGL/FineUIPro.Web/PHTGL/ContractCompile/ContractTrackProgressDetectionGrid.aspx index f80e6384..e53281df 100644 --- a/SGGL/FineUIPro.Web/PHTGL/ContractCompile/ContractTrackProgressDetectionGrid.aspx +++ b/SGGL/FineUIPro.Web/PHTGL/ContractCompile/ContractTrackProgressDetectionGrid.aspx @@ -37,17 +37,19 @@ Title="中间面板" ShowBorder="True" ShowHeader="false" BodyPadding="10px" IconFont="_RoundPlus"> + runat="server" BoxFlex="1" DataKeyNames="Id" AllowCellEditing="true" + ClicksToEdit="1" DataIDField="Id" AllowSorting="true" SortField="Id" + SortDirection="DESC" OnSort="Grid1_Sort" EnableColumnLines="true" + AllowPaging="True" IsDatabasePaging="true" PageSize="300" OnPageIndexChange="Grid1_PageIndexChange" OnRowDataBound="Grid1_OnRowDataBound" + EnableRowDoubleClickEvent="true" OnRowDoubleClick="Grid1_RowDoubleClick" EnableRowClickEvent="True"> + + @@ -65,6 +67,20 @@ + + + + + + + + + + + + + diff --git a/SGGL/FineUIPro.Web/PHTGL/ContractCompile/ContractTrackProgressDetectionGrid.aspx.cs b/SGGL/FineUIPro.Web/PHTGL/ContractCompile/ContractTrackProgressDetectionGrid.aspx.cs index 2e1e7c58..d1a0de7d 100644 --- a/SGGL/FineUIPro.Web/PHTGL/ContractCompile/ContractTrackProgressDetectionGrid.aspx.cs +++ b/SGGL/FineUIPro.Web/PHTGL/ContractCompile/ContractTrackProgressDetectionGrid.aspx.cs @@ -266,10 +266,11 @@ namespace FineUIPro.Web.PHTGL.ContractCompile if (!IsPostBack) { this.GetButtonPower(); - + + PHTGL_QuantityService.IniGetMajorItems3DownList(drpMajorItems, true); // 绑定表格 - this.BindGrid(); + this.BindGrid(); } } @@ -286,7 +287,17 @@ namespace FineUIPro.Web.PHTGL.ContractCompile Model.PHTGL_ContractTrack queryContractTrack = new Model.PHTGL_ContractTrack(); queryContractTrack.ProjectId = this.CurrUser.LoginProjectId; queryContractTrack.ContractId = this.ContractId; - var modelContractTracks = BLL.PhtglContractTrackService.GetPHTGL_ContractTrackByModle(queryContractTrack); + queryContractTrack.MainItemName = this.txtMainItemName.Text.Trim(); + if (drpMajorItems.SelectedValue != Const._Null) + { + queryContractTrack.MajorName = drpMajorItems.SelectedValue; + } + + var modelContractTracks = + BLL.PhtglContractTrackService.GetPHTGL_ContractTrackByModle(queryContractTrack); + + var count = BLL.PhtglContractTrackService.GetPHTGL_ContractTrackByModle(queryContractTrack).Count(); + modelContractTracks= modelContractTracks.Skip(Grid1.PageSize * Grid1.PageIndex).Take(Grid1.PageSize).ToList(); foreach (var item in modelContractTracks) { row= GridTable.NewRow(); @@ -326,6 +337,7 @@ namespace FineUIPro.Web.PHTGL.ContractCompile GridTable.Rows.Add(row); } + Grid1.RecordCount = count; Grid1.DataSource = GridTable; Grid1.DataBind(); } @@ -339,36 +351,38 @@ namespace FineUIPro.Web.PHTGL.ContractCompile Model.PHTGL_ContractTrack queryContractTrack = new Model.PHTGL_ContractTrack(); queryContractTrack.ProjectId = this.CurrUser.LoginProjectId; queryContractTrack.ContractId = this.ContractId; - var modelContractTracks = BLL.PhtglContractTrackService.GetPHTGL_ContractTrackByModle(queryContractTrack); - foreach (var item in modelContractTracks) + var modelContractTracks = BLL.PhtglContractTrackService.GetFirstPHTGL_ContractTrackByModle(queryContractTrack); + if (modelContractTracks ==null) return; + Model.PHTGL_ContractTrackProgress qContractTrackProgress = new Model.PHTGL_ContractTrackProgress(); + qContractTrackProgress.ContractTrackId = modelContractTracks.Id; + var modelContractTrackProgresses = BLL.PhtglContracttrackprogressService.GetPHTGL_ContractTrackProgressByModle(qContractTrackProgress); + foreach (var detail in modelContractTrackProgresses) { + var date = detail.Date + "#"; + RenderField rfRenderField1 = Grid1.FindColumn(date + "BCWS_Quantity") as RenderField; + BoundField bf1 = Grid1.FindColumn(date + "BCWS_OutputValue") as BoundField; + BoundField bf2 = Grid1.FindColumn(date + "BCWS_Percentage") as BoundField; - Model.PHTGL_ContractTrackProgress qContractTrackProgress = new Model.PHTGL_ContractTrackProgress(); - qContractTrackProgress.ContractTrackId = item.Id; - var modelContractTrackProgresses = BLL.PhtglContracttrackprogressService.GetPHTGL_ContractTrackProgressByModle(qContractTrackProgress); - foreach (var detail in modelContractTrackProgresses) - { + e.CellAttributes[rfRenderField1.ColumnIndex]["data-color"] = "color1"; + e.CellAttributes[bf1.ColumnIndex]["data-color"] = "color1"; + e.CellAttributes[bf2.ColumnIndex]["data-color"] = "color1"; - var date = detail.Date + "#"; - RenderField rfRenderField1 = Grid1.FindColumn(date + "BCWS_Quantity") as RenderField; - BoundField bf1 = Grid1.FindColumn(date + "BCWS_OutputValue") as BoundField; - BoundField bf2 = Grid1.FindColumn(date + "BCWS_Percentage") as BoundField; + RenderField rfRenderField2 = Grid1.FindColumn(date + "SumBCWS_Quantity") as RenderField; + BoundField bf3 = Grid1.FindColumn(date + "SumBCWS_OutputValue") as BoundField; + BoundField bf4 = Grid1.FindColumn(date + "SumBCWS_Percentage") as BoundField; - e.CellAttributes[rfRenderField1.ColumnIndex]["data-color"] = "color1"; - e.CellAttributes[bf1.ColumnIndex]["data-color"] = "color1"; - e.CellAttributes[bf2.ColumnIndex]["data-color"] = "color1"; + e.CellAttributes[rfRenderField2.ColumnIndex]["data-color"] = "color1"; + e.CellAttributes[bf3.ColumnIndex]["data-color"] = "color1"; + e.CellAttributes[bf4.ColumnIndex]["data-color"] = "color1"; - RenderField rfRenderField2 = Grid1.FindColumn(date + "SumBCWS_Quantity") as RenderField; - BoundField bf3 = Grid1.FindColumn(date + "SumBCWS_OutputValue") as BoundField; - BoundField bf4 = Grid1.FindColumn(date + "SumBCWS_Percentage") as BoundField; - - e.CellAttributes[rfRenderField2.ColumnIndex]["data-color"] = "color1"; - e.CellAttributes[bf3.ColumnIndex]["data-color"] = "color1"; - e.CellAttributes[bf4.ColumnIndex]["data-color"] = "color1"; - - } } + //foreach (var item in modelContractTracks) + //{ + + + + //} } } diff --git a/SGGL/FineUIPro.Web/PHTGL/ContractCompile/ContractTrackProgressDetectionGrid.aspx.designer.cs b/SGGL/FineUIPro.Web/PHTGL/ContractCompile/ContractTrackProgressDetectionGrid.aspx.designer.cs index dc989cb2..0dafdcee 100644 --- a/SGGL/FineUIPro.Web/PHTGL/ContractCompile/ContractTrackProgressDetectionGrid.aspx.designer.cs +++ b/SGGL/FineUIPro.Web/PHTGL/ContractCompile/ContractTrackProgressDetectionGrid.aspx.designer.cs @@ -86,6 +86,24 @@ namespace FineUIPro.Web.PHTGL.ContractCompile /// protected global::FineUIPro.TextBox txtProjectName; + /// + /// txtMainItemName 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.TextBox txtMainItemName; + + /// + /// drpMajorItems 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.DropDownList drpMajorItems; + /// /// btnQuery 控件。 /// @@ -122,6 +140,33 @@ namespace FineUIPro.Web.PHTGL.ContractCompile /// protected global::FineUIPro.Button btnOut; + /// + /// ToolbarSeparator1 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.ToolbarSeparator ToolbarSeparator1; + + /// + /// ToolbarText1 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.ToolbarText ToolbarText1; + + /// + /// ddlPageSize 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.DropDownList ddlPageSize; + /// /// Window1 控件。 /// diff --git a/SGGL/FineUIPro.Web/PHTGL/ContractCompile/ContractWBS.aspx b/SGGL/FineUIPro.Web/PHTGL/ContractCompile/ContractWBS.aspx index c06358c3..045ba4f0 100644 --- a/SGGL/FineUIPro.Web/PHTGL/ContractCompile/ContractWBS.aspx +++ b/SGGL/FineUIPro.Web/PHTGL/ContractCompile/ContractWBS.aspx @@ -36,7 +36,7 @@ runat="server" BoxFlex="1" DataKeyNames="Id,MatchWbsId" AllowCellEditing="true" ClicksToEdit="1" AllowSorting="true" SortField="Id" SortDirection="DESC" OnSort="Grid1_Sort" EnableColumnLines="true" - AllowPaging="False" IsDatabasePaging="true" PageSize="10" OnPageIndexChange="Grid1_PageIndexChange" + AllowPaging="True" IsDatabasePaging="true" PageSize="500" OnPageIndexChange="Grid1_PageIndexChange" EnableRowDoubleClickEvent="true" OnRowDoubleClick="Grid1_RowDoubleClick" EnableRowClickEvent="True"> @@ -50,7 +50,10 @@ - + + + @@ -58,6 +61,8 @@ + + + x.MajorName.Contains(this.drpMajorItems.SelectedValue)); + } + Grid1.RecordCount = q.Count(); - Grid1.DataSource = q.ToList().OrderBy(x => x.SerialNumber, new CustomComparer()).ToList(); + Grid1.DataSource = q.ToList().OrderBy(x => x.SerialNumber, new CustomComparer()).ToList().Skip(Grid1.PageSize * Grid1.PageIndex).Take(Grid1.PageSize); Grid1.DataBind(); } @@ -262,10 +270,65 @@ namespace FineUIPro.Web.PHTGL.ContractCompile } } } - #endregion + #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("WBS工作包匹配表" + filename, System.Text.Encoding.UTF8) + ".xls"); + Response.ContentType = "application/excel"; + Response.ContentEncoding = System.Text.Encoding.UTF8; + this.Grid1.PageSize = 500; + this.BindGrid(); + Response.Write(GetGridTableHtml(Grid1)); + Response.End(); + } + + /// + /// 导出方法 + /// + /// + /// + private string GetGridTableHtml(Grid grid) + { + StringBuilder sb = new StringBuilder(); + sb.Append(""); + sb.Append(""); + sb.Append(""); + foreach (GridColumn column in grid.Columns) + { + sb.AppendFormat("", column.HeaderText); + } + sb.Append(""); + foreach (GridRow row in grid.Rows) + { + sb.Append(""); + foreach (GridColumn column in grid.Columns) + { + string html = row.Values[column.ColumnIndex].ToString(); + if (column.ColumnID == "tfNumber") + { + html = (row.FindControl("lblNumber") as System.Web.UI.WebControls.Label).Text; + } + sb.AppendFormat("", html); + } + + sb.Append(""); + } + + sb.Append("
{0}
{0}
"); + + return sb.ToString(); + } + #endregion - - } } \ No newline at end of file diff --git a/SGGL/FineUIPro.Web/PHTGL/ContractCompile/ContractWBS.aspx.designer.cs b/SGGL/FineUIPro.Web/PHTGL/ContractCompile/ContractWBS.aspx.designer.cs index 8f51d833..0f1fa36d 100644 --- a/SGGL/FineUIPro.Web/PHTGL/ContractCompile/ContractWBS.aspx.designer.cs +++ b/SGGL/FineUIPro.Web/PHTGL/ContractCompile/ContractWBS.aspx.designer.cs @@ -95,6 +95,15 @@ namespace FineUIPro.Web.PHTGL.ContractCompile /// protected global::FineUIPro.Button btnNew; + /// + /// btnOut 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.Button btnOut; + /// /// Toolbar4 控件。 /// @@ -122,6 +131,24 @@ namespace FineUIPro.Web.PHTGL.ContractCompile /// protected global::FineUIPro.TextBox txtProjectName; + /// + /// txtMainItemName 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.TextBox txtMainItemName; + + /// + /// drpMajorItems 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.DropDownList drpMajorItems; + /// /// btnQuery 控件。 /// diff --git a/SGGL/Model/Model.cs b/SGGL/Model/Model.cs index b1dc3361..3245a2b7 100644 --- a/SGGL/Model/Model.cs +++ b/SGGL/Model/Model.cs @@ -11763,7 +11763,7 @@ namespace Model } } - [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ApproveIdea", DbType="NVarChar(2000)")] + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ApproveIdea", DbType="NVarChar(200)")] public string ApproveIdea { get @@ -39519,10 +39519,10 @@ namespace Model private string _SaveHandleMan; - private string _WorkPackageName; - private string _WorkPackageId; + private string _WorkPackageName; + private EntityRef _Base_Project; private EntityRef _Person_Persons; @@ -39579,10 +39579,10 @@ namespace Model partial void OnProposeUnitIdChanged(); partial void OnSaveHandleManChanging(string value); partial void OnSaveHandleManChanged(); - partial void OnWorkPackageNameChanging(string value); - partial void OnWorkPackageNameChanged(); partial void OnWorkPackageIdChanging(string value); partial void OnWorkPackageIdChanged(); + partial void OnWorkPackageNameChanging(string value); + partial void OnWorkPackageNameChanged(); #endregion public Check_CheckControl() @@ -40061,26 +40061,6 @@ namespace Model } } - [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_WorkPackageName", DbType="NVarChar(2000)")] - public string WorkPackageName - { - get - { - return this._WorkPackageName; - } - set - { - if ((this._WorkPackageName != value)) - { - this.OnWorkPackageNameChanging(value); - this.SendPropertyChanging(); - this._WorkPackageName = value; - this.SendPropertyChanged("WorkPackageName"); - this.OnWorkPackageNameChanged(); - } - } - } - [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_WorkPackageId", DbType="NVarChar(2000)")] public string WorkPackageId { @@ -40101,6 +40081,26 @@ namespace Model } } + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_WorkPackageName", DbType="NVarChar(2000)")] + public string WorkPackageName + { + get + { + return this._WorkPackageName; + } + set + { + if ((this._WorkPackageName != value)) + { + this.OnWorkPackageNameChanging(value); + this.SendPropertyChanging(); + this._WorkPackageName = value; + this.SendPropertyChanged("WorkPackageName"); + this.OnWorkPackageNameChanged(); + } + } + } + [global::System.Data.Linq.Mapping.AssociationAttribute(Name="FK_Check_CheckControl_Base_Project", Storage="_Base_Project", ThisKey="ProjectId", OtherKey="ProjectId", IsForeignKey=true)] public Base_Project Base_Project { @@ -100727,10 +100727,10 @@ namespace Model private string _HazardValue; - private string _WorkPackageName; - private string _WorkPackageId; + private string _WorkPackageName; + private EntityRef _Base_Unit; private EntityRef _HSSE_Hazard_HazardRegisterTypes; @@ -100831,10 +100831,10 @@ namespace Model partial void OnRegisterTypes4IdChanged(); partial void OnHazardValueChanging(string value); partial void OnHazardValueChanged(); - partial void OnWorkPackageNameChanging(string value); - partial void OnWorkPackageNameChanged(); partial void OnWorkPackageIdChanging(string value); partial void OnWorkPackageIdChanged(); + partial void OnWorkPackageNameChanging(string value); + partial void OnWorkPackageNameChanged(); #endregion public HSSE_Hazard_HazardRegister() @@ -101772,26 +101772,6 @@ namespace Model } } - [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_WorkPackageName", DbType="NVarChar(2000)")] - public string WorkPackageName - { - get - { - return this._WorkPackageName; - } - set - { - if ((this._WorkPackageName != value)) - { - this.OnWorkPackageNameChanging(value); - this.SendPropertyChanging(); - this._WorkPackageName = value; - this.SendPropertyChanged("WorkPackageName"); - this.OnWorkPackageNameChanged(); - } - } - } - [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_WorkPackageId", DbType="NVarChar(2000)")] public string WorkPackageId { @@ -101812,6 +101792,26 @@ namespace Model } } + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_WorkPackageName", DbType="NVarChar(2000)")] + public string WorkPackageName + { + get + { + return this._WorkPackageName; + } + set + { + if ((this._WorkPackageName != value)) + { + this.OnWorkPackageNameChanging(value); + this.SendPropertyChanging(); + this._WorkPackageName = value; + this.SendPropertyChanged("WorkPackageName"); + this.OnWorkPackageNameChanged(); + } + } + } + [global::System.Data.Linq.Mapping.AssociationAttribute(Name="FK_HSSE_Hazard_HazardRegister_Base_Unit", Storage="_Base_Unit", ThisKey="ResponsibleUnit", OtherKey="UnitId", IsForeignKey=true)] public Base_Unit Base_Unit { @@ -151221,7 +151221,7 @@ namespace Model } } - [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_AttentPerson", DbType="NVarChar(3000)")] + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_AttentPerson", DbType="NVarChar(500)")] public string AttentPerson { get @@ -181869,11 +181869,11 @@ namespace Model private string _Quantity; - private string _TotalCostFixedComprehensiveUnitPrice; + private System.Nullable _TotalCostFixedComprehensiveUnitPrice; - private string _MainMaterialCost; + private System.Nullable _MainMaterialCost; - private string _TotalPrice; + private System.Nullable _TotalPrice; private string _CalculationRule; @@ -181937,11 +181937,11 @@ namespace Model partial void OnUnitOfMeasurementChanged(); partial void OnQuantityChanging(string value); partial void OnQuantityChanged(); - partial void OnTotalCostFixedComprehensiveUnitPriceChanging(string value); + partial void OnTotalCostFixedComprehensiveUnitPriceChanging(System.Nullable value); partial void OnTotalCostFixedComprehensiveUnitPriceChanged(); - partial void OnMainMaterialCostChanging(string value); + partial void OnMainMaterialCostChanging(System.Nullable value); partial void OnMainMaterialCostChanged(); - partial void OnTotalPriceChanging(string value); + partial void OnTotalPriceChanging(System.Nullable value); partial void OnTotalPriceChanged(); partial void OnCalculationRuleChanging(string value); partial void OnCalculationRuleChanged(); @@ -182240,8 +182240,8 @@ namespace Model } } - [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_TotalCostFixedComprehensiveUnitPrice", DbType="VarChar(50)")] - public string TotalCostFixedComprehensiveUnitPrice + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_TotalCostFixedComprehensiveUnitPrice", DbType="Decimal(18,2)")] + public System.Nullable TotalCostFixedComprehensiveUnitPrice { get { @@ -182260,8 +182260,8 @@ namespace Model } } - [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_MainMaterialCost", DbType="VarChar(50)")] - public string MainMaterialCost + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_MainMaterialCost", DbType="Decimal(18,2)")] + public System.Nullable MainMaterialCost { get { @@ -182280,8 +182280,8 @@ namespace Model } } - [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_TotalPrice", DbType="VarChar(50)")] - public string TotalPrice + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_TotalPrice", DbType="Decimal(18,2)")] + public System.Nullable TotalPrice { get { @@ -182744,7 +182744,7 @@ namespace Model } } - [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_WorkPackageEstimate", DbType="Decimal(18,3)")] + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_WorkPackageEstimate", DbType="Decimal(18,2)")] public System.Nullable WorkPackageEstimate { get @@ -292538,7 +292538,7 @@ namespace Model } } - [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Name", DbType="NVarChar(50)")] + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Name", DbType="NVarChar(81)")] public string Name { get From b88e20eafdb91909957f52b06d08e93079e05d7c Mon Sep 17 00:00:00 2001 From: fly-l <1420031550@qq.com> Date: Wed, 1 Nov 2023 23:14:16 +0800 Subject: [PATCH 2/6] 2023-11-01 --- DataBase/版本日志/SGGLDB_V2023-11-01.sql | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) create mode 100644 DataBase/版本日志/SGGLDB_V2023-11-01.sql diff --git a/DataBase/版本日志/SGGLDB_V2023-11-01.sql b/DataBase/版本日志/SGGLDB_V2023-11-01.sql new file mode 100644 index 00000000..41188e46 --- /dev/null +++ b/DataBase/版本日志/SGGLDB_V2023-11-01.sql @@ -0,0 +1,18 @@ +update PHTGL_ContractTrack set TotalCostFixedComprehensiveUnitPrice =ROUND(TotalCostFixedComprehensiveUnitPrice ,2) where TotalCostFixedComprehensiveUnitPrice is not null ; +go +update PHTGL_ContractTrack set MainMaterialCost =ROUND(MainMaterialCost ,2) where MainMaterialCost is not null ; +go +update PHTGL_ContractTrack set TotalPrice =TRY_CAST(TotalPrice AS decimal(18, 2)) where TotalPrice is not null ; + + +alter table dbo.PHTGL_ContractTrack + alter column TotalCostFixedComprehensiveUnitPrice decimal(18, 2) null +go + +alter table dbo.PHTGL_ContractTrack + alter column MainMaterialCost decimal(18, 2) null +go + +alter table dbo.PHTGL_ContractTrack + alter column TotalPrice decimal(18, 2) null +go From 6f9a9bab953d86b3e5ac862561a65e37450a671e Mon Sep 17 00:00:00 2001 From: fly-l <1420031550@qq.com> Date: Wed, 1 Nov 2023 23:30:44 +0800 Subject: [PATCH 3/6] 2023-11-01 --- DataBase/版本日志/SGGLDB_V2023-11-01.sql | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/DataBase/版本日志/SGGLDB_V2023-11-01.sql b/DataBase/版本日志/SGGLDB_V2023-11-01.sql index 41188e46..78bc33c3 100644 --- a/DataBase/版本日志/SGGLDB_V2023-11-01.sql +++ b/DataBase/版本日志/SGGLDB_V2023-11-01.sql @@ -2,7 +2,7 @@ update PHTGL_ContractTrack set TotalCostFixedComprehensiveUnitPrice =ROUND(Total go update PHTGL_ContractTrack set MainMaterialCost =ROUND(MainMaterialCost ,2) where MainMaterialCost is not null ; go -update PHTGL_ContractTrack set TotalPrice =TRY_CAST(TotalPrice AS decimal(18, 2)) where TotalPrice is not null ; +update PHTGL_ContractTrack set TotalPrice =ROUND(TotalPrice ,2) where TotalPrice is not null ; alter table dbo.PHTGL_ContractTrack From 8646714ce3c0eb4ee071168904fdf774cf2f6504 Mon Sep 17 00:00:00 2001 From: fly-l <1420031550@qq.com> Date: Thu, 2 Nov 2023 10:44:58 +0800 Subject: [PATCH 4/6] 2023-11-2 --- SGGL/BLL/PHTGL/ContractCompile/PhtglContracttrackService .cs | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/SGGL/BLL/PHTGL/ContractCompile/PhtglContracttrackService .cs b/SGGL/BLL/PHTGL/ContractCompile/PhtglContracttrackService .cs index adb12d71..b5bef723 100644 --- a/SGGL/BLL/PHTGL/ContractCompile/PhtglContracttrackService .cs +++ b/SGGL/BLL/PHTGL/ContractCompile/PhtglContracttrackService .cs @@ -8,6 +8,7 @@ using EmitMapper.MappingConfiguration; using FineUIPro; using MiniExcelLibs; using MiniExcelLibs.Attributes; +using MiniExcelLibs.OpenXml; using Model; using WIA; @@ -356,7 +357,8 @@ namespace BLL { try { - rows = MiniExcel.Query(path, sheetName: sheet).ToList(); + + rows = MiniExcel.Query(path, sheetName: sheet,startCell:"A2").ToList(); } catch (Exception ex) { From 2d50250b72fb70d13e9da3dbe9e5a6e1c16a5def Mon Sep 17 00:00:00 2001 From: fly-l <1420031550@qq.com> Date: Mon, 6 Nov 2023 10:20:36 +0800 Subject: [PATCH 5/6] 2023-11-06 --- .vs/SGGL_SeDin/v17/.wsuo | Bin 265216 -> 265216 bytes .../HJGL/WeldingManage/WeldJointList.aspx.cs | 6 +++--- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/.vs/SGGL_SeDin/v17/.wsuo b/.vs/SGGL_SeDin/v17/.wsuo index 801c4d5de45dc8e6dd94442ea011224700b588c2..12d33752132c24fc031836cc38cb65b44926d573 100644 GIT binary patch delta 2785 zcmeI!TWr%+90%~8^Y37c|F*8XP{v9gO}bQfS3a04bz(arA0WehrLyYAX@ z2|g^w(Vs~nDj`J|H6}(%Rv&zrJP}R62ct&fgC-g^KKQWdW?=PuYG;}S5_sUj#Q*Z? zIsN_5`S*9u|M&lA?n^57CDlw#&PIho!C@sB45CpmNQ7)i2DLw-;2QJrq1d9|liO9_ zvSI}13u%mxu?w`w+vIg(6yO3uN{G)Vo8*qQA}|Qzh#{ujRJ8#;F+?2c=*tiVu@Dd9 zG8s?`BANSPahRQW(JJp3!6ckS6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dG z09wp_EpXY={Qj9hNzAewpuMMWn}Ieb>%zQh+2?_EgU!IY?9*avF|PylpaE*eW1T)%2xv`rqUJM*zaigqX z!#$Q8X3QlbmYoJ_PugYrD9l=>%*+N4>9yj`Rn`g)mzD~vub1_UNO??z%Q0*0WlxDn zFbnEogwiTS*D9(2Vm|8~V| z9g;*9A1m9zOe8jKf*vZtNO&X5RMe4H)Nw*w41OXm?0#B&TG5vDZ@Mfes`)>Cyo=#F z(?K?-qY-(h3!du#*MCo^0N(Zj!pMciQVf*orW|0GK)l?r=% zMpkmDNjMTp@xOOjymXd@#9V2N4T#8wP7~eR+6gDY^>p>MCFdJEnfT1^7UAZTi6$N| zp4HPGS10D%53v0rQgR~EE~99P4mr`0m3YA*2A@BbJhf|(t**jLS9p^3E?E*memFWF zWjvAO;YBv$e>qFtKFPb!eav%(chacNn7JV}T+WZO(K61*EBIwbt*ZuhOReg!3#?f6 zej%AsPA9+0;!!`#6WgMXdg`z*T7Bi#-rCxL&$q|p?Fj}v^?_i$C+KUa_w>}&Z0V^B zdiOL0dXl%IpR?>ocJ6Absr3nSeS>wCw&@DB>bs_J$BH~>bG*SNCgkal(<1myuV(3b~Be#Ws}kmO#SgA-mZqOOa9ccZ=@mf=+_cg z+rHzWROp&?+9JOC@HsI(Rjh{okjheT-jkwCO?)dUDdjgwVd^sjtXmDe#oVethnrGo Lf0z2C4`kDy`yb(C diff --git a/SGGL/FineUIPro.Web/HJGL/WeldingManage/WeldJointList.aspx.cs b/SGGL/FineUIPro.Web/HJGL/WeldingManage/WeldJointList.aspx.cs index 10b5c993..7486a93c 100644 --- a/SGGL/FineUIPro.Web/HJGL/WeldingManage/WeldJointList.aspx.cs +++ b/SGGL/FineUIPro.Web/HJGL/WeldingManage/WeldJointList.aspx.cs @@ -426,20 +426,20 @@ namespace FineUIPro.Web.HJGL.WeldingManage select new { SizeSum = g.Sum(x => x.Size) - }).FirstOrDefault().SizeSum; + }).FirstOrDefault()?.SizeSum; var FieldSum = (from x in q where x.JointAttribute == "安装口" group x by x.UnitWorkId into g select new { SizeSum = g.Sum(x => x.Size) - }).FirstOrDefault().SizeSum; + }).FirstOrDefault()?.SizeSum; var AllSum = (from x in q group x by x.UnitWorkId into g select new { SizeSum = g.Sum(x => x.Size) - }).FirstOrDefault().SizeSum; + }).FirstOrDefault()?.SizeSum; proSum = (proSum != null) ? proSum : 0; FieldSum = (FieldSum != null) ? FieldSum : 0; ShopSumSize = proSum.ToString() ; From 1b7463957c47954d12941a955f3bc350f2034189 Mon Sep 17 00:00:00 2001 From: fly-l <1420031550@qq.com> Date: Mon, 6 Nov 2023 11:00:06 +0800 Subject: [PATCH 6/6] 2023-11-06 --- .../PHTGL/ContractCompile/ContractTrackComparison.aspx | 6 +++--- .../PHTGL/ContractCompile/ContractTrackComparison.aspx.cs | 7 +++++-- 2 files changed, 8 insertions(+), 5 deletions(-) diff --git a/SGGL/FineUIPro.Web/PHTGL/ContractCompile/ContractTrackComparison.aspx b/SGGL/FineUIPro.Web/PHTGL/ContractCompile/ContractTrackComparison.aspx index 4cb71d60..8d72ddc3 100644 --- a/SGGL/FineUIPro.Web/PHTGL/ContractCompile/ContractTrackComparison.aspx +++ b/SGGL/FineUIPro.Web/PHTGL/ContractCompile/ContractTrackComparison.aspx @@ -40,9 +40,9 @@ + SortDirection="DESC" OnSort="Grid1_Sort" EnableColumnLines="true" OnRowDataBound="Grid1_RowDataBound" IsFluid="True" + AllowPaging="true" IsDatabasePaging="true" PageSize="500" OnPageIndexChange="Grid1_PageIndexChange" + EnableRowDoubleClickEvent="true" > diff --git a/SGGL/FineUIPro.Web/PHTGL/ContractCompile/ContractTrackComparison.aspx.cs b/SGGL/FineUIPro.Web/PHTGL/ContractCompile/ContractTrackComparison.aspx.cs index f4997206..4539de66 100644 --- a/SGGL/FineUIPro.Web/PHTGL/ContractCompile/ContractTrackComparison.aspx.cs +++ b/SGGL/FineUIPro.Web/PHTGL/ContractCompile/ContractTrackComparison.aspx.cs @@ -101,8 +101,11 @@ namespace FineUIPro.Web.PHTGL.ContractCompile protected void Grid1_RowDataBound(object sender, GridRowEventArgs e) { try - { - var model = (Model.PHTGL_ContractTrack)e.DataItem; + { + + string Id =e.DataItem.GetType().GetProperty("Id").GetValue(e.DataItem).ToString(); + var model = PhtglContractTrackService.GetPHTGL_ContractTrackById(Id); + // 工程量偏差 decimal? QuantityOffset = Funs.GetNewDecimalOrZero(model.EstimatedQuantity) - Funs.GetNewDecimalOrZero(model.SettledQuantity);