This commit is contained in:
jackchenyang 2024-06-20 17:16:27 +08:00
commit afb8da22dc
30 changed files with 1030 additions and 840 deletions

Binary file not shown.

Binary file not shown.

View File

@ -162,7 +162,7 @@
</site>
<site name="WebApi" id="2">
<application path="/" applicationPool="Clr4IntegratedAppPool">
<virtualDirectory path="/" physicalPath="E:\湛江巴斯夫\Basf_TCC7\HJGL\WebApi" />
<virtualDirectory path="/" physicalPath="E:\MyProject\ZJ_BSF\Basf_TCC7\HJGL\WebApi" />
</application>
<bindings>
<binding protocol="http" bindingInformation="*:3862:localhost" />
@ -250,7 +250,7 @@
</site>
<site name="FineUIPro.Web(10)" id="13">
<application path="/" applicationPool="Clr4IntegratedAppPool">
<virtualDirectory path="/" physicalPath="E:\湛江巴斯夫\Basf_TCC7\HJGL\FineUIPro.Web" />
<virtualDirectory path="/" physicalPath="E:\MyProject\ZJ_BSF\Basf_TCC7\HJGL\FineUIPro.Web" />
</application>
<bindings>
<binding protocol="http" bindingInformation="*:13960:localhost" />

View File

@ -112,6 +112,11 @@ namespace BLL
/// </summary>
public const string BtnCancelAuditing = "取消审核";
/// <summary>
/// 发送邮件
/// </summary>
public const string BtnSendEmail = "发送邮件";
/// <summary>
/// 焊口取消
/// </summary>
@ -655,6 +660,11 @@ namespace BLL
#endregion
/// <summary>
/// 焊接日报导出
/// </summary>
public const string WeldDailyExportMenuId = "CE3B4B0E-C751-4BA6-A7AF-A46D434AD6DD";
#endregion
#endregion

View File

@ -2,6 +2,8 @@ using System;
using System.Data;
using System.Data.SqlClient;
using System.Collections;
using NPOI.SS.Formula.Functions;
using System.Text;
namespace BLL
{
@ -995,7 +997,5 @@ namespace BLL
}
return i;
}
}
}
}

View File

@ -76,7 +76,8 @@ namespace BLL
AcceptLevel = pointBatchItem.AcceptLevel,
RepairRecordId = pointBatchItem.RepairRecordId,
BatchOrder = pointBatchItem.BatchOrder,
IsCompletedPoint=pointBatchItem.IsCompletedPoint
IsCompletedPoint=pointBatchItem.IsCompletedPoint,
EnterDate = pointBatchItem.EnterDate
};
db.Batch_PointBatchItem.InsertOnSubmit(newPointBatchItem);
db.SubmitChanges();
@ -204,7 +205,13 @@ namespace BLL
db.SubmitChanges();
}
public static void UpdatePointBatchOrder(string pointBatchItemId, int batchOrder)
/// <summary>
/// 批次段完成
/// </summary>
/// <param name="pointBatchItemId"></param>
/// <param name="batchOrder"></param>
public static void UpdatePointBatchOrder(string pointBatchItemId, bool batchOrder)
{
Model.HJGLDB db = Funs.DB;
Model.Batch_PointBatchItem newPointBatchItem = db.Batch_PointBatchItem.FirstOrDefault(e => e.PointBatchItemId == pointBatchItemId);
@ -305,6 +312,7 @@ namespace BLL
newPointBatchItem.AcceptLevel = "";
}
newPointBatchItem.IsCompletedPoint = false;
newPointBatchItem.EnterDate = DateTime.Now;
BLL.Batch_PointBatchItemService.AddPointBatchItem(newPointBatchItem); // 插入明细表
@ -322,23 +330,14 @@ namespace BLL
&& (j.CoverWelderId == coverWelderId || j.BackingWelderId==backingWelderId)
&& x.PointDate.HasValue
select x;
if (Funs.UsingUnit == "TCC11")
if (threeJot.Count() <= 2)
{
if (threeJot.Count() <= 1)
{
UpdatePointBatchItem(pointBatchItemId, "1", System.DateTime.Now, null);
UpdateWelderFirst(pointBatchItemId, true);
}
UpdatePointBatchItem(pointBatchItemId, "1", System.DateTime.Now, null);
UpdateWelderFirst(pointBatchItemId, true);
UpdatePointBatchOrder(pointBatchItemId, true);
}
else
{
if (threeJot.Count() <= 2)
{
UpdatePointBatchItem(pointBatchItemId, "1", System.DateTime.Now, null);
UpdateWelderFirst(pointBatchItemId, true);
}
}
//// 焊工在这个批首道口RT要覆盖 不要了
#region RT要覆盖
//var joints = from x in Funs.DB.Batch_PointBatchItem
// join y in Funs.DB.Batch_PointBatch on x.PointBatchId equals y.PointBatchId
// join z in Funs.DB.Base_DetectionType on y.DetectionTypeId equals z.DetectionTypeId
@ -351,81 +350,87 @@ namespace BLL
// UpdatePointBatchItem(pointBatchItemId, "1", System.DateTime.Now, null);
// UpdatePipelineFirst(pointBatchItemId, true);
//}
#endregion
// 管径大于等于500必点
if (jot.Dia >= 500)
{
UpdatePointBatchItem(pointBatchItemId, "1", System.DateTime.Now, null);
UpdatePointBatchOrder(pointBatchItemId, true);
}
if (jot.IsGoldJoint == true)
{
UpdatePointBatchItem(pointBatchItemId, "1", System.DateTime.Now, null);
UpdatePointBatchOrder(pointBatchItemId, true);
}
}
// 一个段位的数量
int dnum = Convert.ToInt32((double)100 / (double)rate.DetectionRateValue);
// 批里未完成点口的焊口
var totalJot = from x in Funs.DB.Batch_PointBatchItem
join y in Funs.DB.Pipeline_WeldJoint on x.WeldJointId equals y.WeldJointId
where x.PointBatchId == pointBatchId && x.IsCompletedPoint == false
&& (y.CoverWelderId==coverWelderId || y.BackingWelderId==backingWelderId)
&& y.WeldingDate.HasValue
&& (y.IsCancel == false || y.IsCancel == null)
select x;
int totalnum = totalJot.Count();
// 时间>15处理放globle
//DateTime lastWeldingDate = totalJot.Select(x => x.WeldingDate.Value).Min();
//if((DateTime.Now.Date- lastWeldingDate).Days>=15)
#region
//// 一个段位的数量
//int dnum = Convert.ToInt32((double)100 / (double)rate.DetectionRateValue);
// 该段达到检测比例的数量
if (dnum == totalnum)
{
var GJot = from x in Funs.DB.Batch_PointBatchItem
join y in Funs.DB.Pipeline_WeldJoint on x.WeldJointId equals y.WeldJointId
where x.PointBatchId == pointBatchId && x.IsCompletedPoint == false
&& (y.IsCancel == false || y.IsCancel == null) && y.JointAttribute== "固定F"
select x;
//// 批里未完成点口的焊口
//var totalJot = from x in Funs.DB.Batch_PointBatchItem
// join y in Funs.DB.Pipeline_WeldJoint on x.WeldJointId equals y.WeldJointId
// where x.PointBatchId == pointBatchId && x.IsCompletedPoint == false
// && (y.CoverWelderId==coverWelderId || y.BackingWelderId==backingWelderId)
// && y.WeldingDate.HasValue
// && (y.IsCancel == false || y.IsCancel == null)
// select x;
//int totalnum = totalJot.Count();
//// 时间>15处理放globle
////DateTime lastWeldingDate = totalJot.Select(x => x.WeldingDate.Value).Min();
////if((DateTime.Now.Date- lastWeldingDate).Days>=15)
// 先查找固定口数量,如有固定口,则优先点
if (GJot.Count() > 0)
{
int Gnum = GJot.Count();
int rnum = Funs.GetRandomNum(1, Gnum);
int j = 1;
foreach (var g in GJot)
{
if (rnum == j)
{
UpdatePointBatchItem(g.PointBatchItemId, "1", System.DateTime.Now, null);
}
j++;
}
}
else
{
int rnum = Funs.GetRandomNum(1, totalnum);
int j = 1;
foreach (var g in totalJot)
{
if (rnum == j)
{
UpdatePointBatchItem(g.PointBatchItemId, "1", System.DateTime.Now, null);
}
j++;
}
}
//// 该段达到检测比例的数量
//if (dnum == totalnum)
//{
// var GJot = from x in Funs.DB.Batch_PointBatchItem
// join y in Funs.DB.Pipeline_WeldJoint on x.WeldJointId equals y.WeldJointId
// where x.PointBatchId == pointBatchId && x.IsCompletedPoint == false
// && (y.IsCancel == false || y.IsCancel == null) && y.JointAttribute== "固定F"
// select x;
int batchOrder= GetMaxBatchOrder(pointBatchId);
// 点口后,更新该段批里的所有口为完成点口,并更新分段的顺序
foreach (var g in totalJot)
{
UpdateIsCompletedPoint(g.PointBatchItemId, true);
UpdatePointBatchOrder(g.PointBatchItemId, batchOrder);
}
}
// // 先查找固定口数量,如有固定口,则优先点
// if (GJot.Count() > 0)
// {
// int Gnum = GJot.Count();
// int rnum = Funs.GetRandomNum(1, Gnum);
// int j = 1;
// foreach (var g in GJot)
// {
// if (rnum == j)
// {
// UpdatePointBatchItem(g.PointBatchItemId, "1", System.DateTime.Now, null);
// }
// j++;
// }
// }
// else
// {
// int rnum = Funs.GetRandomNum(1, totalnum);
// int j = 1;
// foreach (var g in totalJot)
// {
// if (rnum == j)
// {
// UpdatePointBatchItem(g.PointBatchItemId, "1", System.DateTime.Now, null);
// }
// j++;
// }
// }
// //int batchOrder= GetMaxBatchOrder(pointBatchId);
// // 点口后,更新该段批里的所有口为完成点口,并更新分段的顺序
// foreach (var g in totalJot)
// {
// UpdateIsCompletedPoint(g.PointBatchItemId, true);
// //UpdatePointBatchOrder(g.PointBatchItemId, batchOrder);
// }
//}
#endregion
}
}
@ -822,17 +827,17 @@ namespace BLL
#endregion
// 返回进批的顺序
public static int GetMaxBatchOrder(string pointBatchId)
{
int orderNum = 1;
Model.HJGLDB db = Funs.DB;
var batchItem = db.Batch_PointBatchItem.Where(x => x.PointBatchId == pointBatchId && x.IsCompletedPoint==true);
if (batchItem.Count() > 0)
{
orderNum = (batchItem.Max(x => x.BatchOrder) != null ? batchItem.Max(x => x.BatchOrder).Value : 0) + 1;
}
return orderNum;
}
//public static int GetMaxBatchOrder(string pointBatchId)
//{
// int orderNum = 1;
// Model.HJGLDB db = Funs.DB;
// var batchItem = db.Batch_PointBatchItem.Where(x => x.PointBatchId == pointBatchId && x.IsCompletedPoint==true);
// if (batchItem.Count() > 0)
// {
// orderNum = (batchItem.Max(x => x.BatchOrder) != null ? batchItem.Max(x => x.BatchOrder).Value : 0) + 1;
// }
// return orderNum;
//}
/// <summary>

View File

@ -2,7 +2,7 @@
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<PropertyGroup>
<ProjectView>ProjectFiles</ProjectView>
<LastActiveSolutionConfig>Debug|Any CPU</LastActiveSolutionConfig>
<LastActiveSolutionConfig>Release|Any CPU</LastActiveSolutionConfig>
<UseIISExpress>true</UseIISExpress>
<Use64BitIISExpress />
<IISExpressSSLPort />

View File

@ -47,8 +47,8 @@
}
// 开启线程
System.Threading.Thread LoadServiceData = new System.Threading.Thread(new System.Threading.ThreadStart(ExpirePoint));
LoadServiceData.Start();
//System.Threading.Thread LoadServiceData = new System.Threading.Thread(new System.Threading.ThreadStart(ExpirePoint));
//LoadServiceData.Start();
// 开启超焊信息提取
System.Threading.Thread LoadServiceSuperQue = new System.Threading.Thread(new System.Threading.ThreadStart(SuperQueWelding));
@ -137,12 +137,12 @@
}
}
int batchOrder = BLL.Batch_PointBatchItemService.GetMaxBatchOrder(r["PointBatchId"].ToString());
//int batchOrder = BLL.Batch_PointBatchItemService.GetMaxBatchOrder(r["PointBatchId"].ToString());
// 点口后,更新该段批里的所有口为完成点口,并更新分段的顺序
foreach (var g in jotList)
{
BLL.Batch_PointBatchItemService.UpdateIsCompletedPoint(g.PointBatchItemId, true);
BLL.Batch_PointBatchItemService.UpdatePointBatchOrder(g.PointBatchItemId, batchOrder);
//BLL.Batch_PointBatchItemService.UpdatePointBatchOrder(g.PointBatchItemId, batchOrder);
}
}
}
@ -162,13 +162,14 @@
void SuperQueWelding_Elapsed(object sender, System.Timers.ElapsedEventArgs e)
{
bool canWPS = true;
var jotList = (from x in Funs.DB.Pipeline_WeldJoint where x.WeldingDailyId != null && x.WeldingMethodId != null select x).ToList();
foreach (var jot in jotList)
{
var wps = BLL.WPQListServiceService.GetWPQById(jot.WPQId);
string floorWelder = jot.BackingWelderId;
string cellWelder = jot.CoverWelderId;
bool canWPS = true;
if (wps != null)
{
// 验证焊工WPS资质
@ -203,7 +204,11 @@
decimal? sch = jot.Thickness;
string[] wmeCodes = mat.WeldingMethodCode.Split('+');
string location = loc.WeldingLocationCode;
string location = string.Empty;
if (loc != null)
{
location = loc.WeldingLocationCode;
}
string ste = jot.Material1Id;
List<Model.Welder_WelderQualify> floorWelderQualifys = (from x in Funs.DB.Welder_WelderQualify
@ -261,13 +266,16 @@
}
}
if (canWPS == false || canSave == false)
{
jot.IsSuperQueWelding = true;
Funs.DB.SubmitChanges();
}
}
else
{
jot.IsSuperQueWelding = null;
}
}
Funs.DB.SubmitChanges();
}
protected void Session_Start(object sender, EventArgs e)

View File

@ -51,7 +51,7 @@
<add path="ChartImg.axd" verb="GET,POST,HEAD" type="System.Web.UI.DataVisualization.Charting.ChartHttpHandler, System.Web.DataVisualization, Version=4.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" validate="false"/>
<add path="Reserved.ReportViewerWebControl.axd" verb="*" type="Microsoft.Reporting.WebForms.HttpHandler, Microsoft.ReportViewer.WebForms, Version=15.0.0.0, Culture=neutral, PublicKeyToken=89845DCD8080CC91" validate="false"/>
</httpHandlers>
<compilation debug="true" targetFramework="4.8">
<compilation debug="false" targetFramework="4.8">
<assemblies>
<!--<add assembly="Microsoft.Build.Framework, Version=4.0.0.0, Culture=neutral, PublicKeyToken=B03F5F7F11D50A3A" />-->
<add assembly="System.Management, Version=4.0.0.0, Culture=neutral, PublicKeyToken=B03F5F7F11D50A3A"/>

View File

@ -88,13 +88,13 @@
</f:RenderField>
<f:RenderField Width="100px" ColumnID="CheckDate" DataField="CheckDate" SortField="CheckDate"
FieldType="Date" Renderer="Date" RendererArgument="yyyy-MM-dd" HeaderText="考试日期"
HeaderTextAlign="Center" TextAlign="Center" Locked="true">
HeaderTextAlign="Center" TextAlign="Center" Locked="true" Hidden="true">
</f:RenderField>
<f:RenderField Width="110px" ColumnID="ExamProject" DataField="ExamProject" SortField="ExamProject"
FieldType="String" HeaderTextAlign="Center" TextAlign="Left" HeaderText="考试项目" Locked="true">
FieldType="String" HeaderTextAlign="Center" TextAlign="Left" HeaderText="考试项目" Locked="true" Hidden="true">
</f:RenderField>
<f:RenderField Width="110px" ColumnID="IsPass" DataField="IsPass" SortField="IsPass"
FieldType="String" HeaderTextAlign="Center" TextAlign="Left" HeaderText="是否合格" Locked="true">
FieldType="String" HeaderTextAlign="Center" TextAlign="Left" HeaderText="是否合格" Locked="true" Hidden="true">
</f:RenderField>
<f:RenderField Width="90px" ColumnID="WeldingMethodId" DataField="WeldingMethodId" SortField="WeldingMethodId"
FieldType="String" HeaderTextAlign="Center" TextAlign="Left" HeaderText="焊接类型">

View File

@ -41,19 +41,19 @@
</f:FormRow>
<f:FormRow>
<Items>
<f:DatePicker runat="server" DateFormatString="yyyy-MM-dd" Label="考试日期" ID="txtCheckDate" LabelWidth="120px" EnableEdit="false">
<f:DatePicker runat="server" DateFormatString="yyyy-MM-dd" Label="考试日期" ID="txtCheckDate" LabelWidth="120px" EnableEdit="false" Hidden="true">
</f:DatePicker>
</Items>
</f:FormRow>
<f:FormRow>
<Items>
<f:TextBox ID="txtExamProject" runat="server" Label="考试项目" MaxLength="50" LabelWidth="120px">
<f:TextBox ID="txtExamProject" runat="server" Label="考试项目" MaxLength="50" LabelWidth="120px" Hidden="true">
</f:TextBox>
</Items>
</f:FormRow>
<f:FormRow>
<Items>
<f:DropDownList ID="drpIsPass" runat="server" Label="是否合格" LabelWidth="120px">
<f:DropDownList ID="drpIsPass" runat="server" Label="是否合格" LabelWidth="120px" Hidden="true">
<f:ListItem Value="是" Text="是" Selected="true" />
<f:ListItem Value="否" Text="否" />
</f:DropDownList>

View File

@ -120,6 +120,9 @@
</f:TextBox>
<f:ToolbarFill ID="ToolbarFill2" runat="server">
</f:ToolbarFill>
<f:Button ID="btnExport" Text="打印" ToolTip="导出" EnableAjax="false" DisableControlBeforePostBack="false" Icon="ApplicationGet" runat="server"
OnClick="btnExport_Click">
</f:Button>
</Items>
</f:Toolbar>
</Toolbars>
@ -147,11 +150,10 @@
HeaderTextAlign="Center" TextAlign="Left" Width="120px">
</f:RenderField>
<f:RenderField HeaderText="<%$ Resources:Lan,QualityNo %>" ColumnID="QualityNo" DataField="QualityNo"
FieldType="String" TextAlign="Left" Width="150px">
FieldType="String" TextAlign="Left" Width="150px" Hidden="true">
</f:RenderField>
<f:RenderField HeaderText="<%$ Resources:Lan,Acceptance %>" ColumnID="Acceptance"
DataField="Acceptance" FieldType="String" TextAlign="Left" Width="150px">
DataField="Acceptance" FieldType="String" TextAlign="Left" Width="150px" Hidden="true">
</f:RenderField>
</Columns>

View File

@ -1,17 +1,13 @@
using System;
using BLL;
using System;
using System.Collections.Generic;
using System.Data;
using System.Data.SqlClient;
using System.IO;
using System.Data;
using System.Linq;
using System.Web;
using BLL;
using Model;
using NPOI.HSSF.Util;
using NPOI.SS.UserModel;
using NPOI.SS.Util;
using NPOI.XSSF.UserModel;
namespace FineUIPro.Web.WeldingProcess.PMI
{
public partial class PMIDelegation : PageBase
@ -69,7 +65,7 @@ namespace FineUIPro.Web.WeldingProcess.PMI
this.tvControlItem.Nodes.Add(rootNode);
List<Model.PMI_Delegation> trustLists = new List<Model.PMI_Delegation>(); ///PMI委托单
if (!string.IsNullOrEmpty(this.txtSearchNo.Text.Trim()))
{
trustLists = (from x in Funs.DB.PMI_Delegation where x.ProjectId == CurrUser.LoginProjectId && x.DelegationNo.Contains(this.txtSearchNo.Text.Trim()) orderby x.DelegationNo select x).ToList();
@ -144,7 +140,7 @@ namespace FineUIPro.Web.WeldingProcess.PMI
if (!string.IsNullOrEmpty(this.tvControlItem.SelectedNodeID))
{
var result = Funs.DB.PMI_Delegation.FirstOrDefault(t => t.Id == this.tvControlItem.SelectedNodeID);
var result = Funs.DB.PMI_Delegation.FirstOrDefault(t=>t.Id==this.tvControlItem.SelectedNodeID);
if (result != null)
{
this.PMIDelegationId = result.Id;
@ -188,7 +184,7 @@ namespace FineUIPro.Web.WeldingProcess.PMI
/// </summary>
private void PageInfoLoad()
{
var trust = Funs.DB.PMI_Delegation.FirstOrDefault(t => t.Id == this.PMIDelegationId);
var trust =Funs.DB.PMI_Delegation.FirstOrDefault(t=>t.Id==this.PMIDelegationId);
if (trust != null)
{
this.txtDelegationNo.Text = trust.DelegationNo;
@ -283,7 +279,7 @@ namespace FineUIPro.Web.WeldingProcess.PMI
if (CommonService.GetAllButtonPowerList(this.CurrUser.LoginProjectId, this.CurrUser.UserId, Const.PMIDelegationMenuId, Const.BtnAdd))
{
this.SetTextTemp();
string window = String.Format("PMIDelegationEdit.aspx?PMIDelegationId={0}", string.Empty, "新增 - ");
string window = String.Format("PMIDelegationEdit.aspx?PMIDelegationId={0}", string.Empty, "新增 - ") ;
PageContext.RegisterStartupScript(Window2.GetSaveStateReference(this.hdPMIDelegationId.ClientID)
+ Window2.GetShowReference(window));
}
@ -303,7 +299,7 @@ namespace FineUIPro.Web.WeldingProcess.PMI
{
if (CommonService.GetAllButtonPowerList(this.CurrUser.LoginProjectId, this.CurrUser.UserId, Const.HotProessTrustMenuId, Const.BtnSave))
{
var trustManage = Funs.DB.PMI_Delegation.FirstOrDefault(t => t.Id == this.PMIDelegationId);
var trustManage = Funs.DB.PMI_Delegation.FirstOrDefault (t=>t.Id==this.PMIDelegationId);
if (trustManage != null)
{
string openUrl = String.Format("PMIDelegationEdit.aspx?PMIDelegationId={0}", this.PMIDelegationId, "编辑 - ");
@ -332,9 +328,9 @@ namespace FineUIPro.Web.WeldingProcess.PMI
{
if (CommonService.GetAllButtonPowerList(this.CurrUser.LoginProjectId, this.CurrUser.UserId, Const.PMIDelegationMenuId, Const.BtnDelete))
{
var trustManage = Funs.DB.PMI_Delegation.FirstOrDefault(t => t.Id == this.PMIDelegationId);
var trustManage =Funs.DB.PMI_Delegation.FirstOrDefault (t=>t.Id==this.PMIDelegationId);
if (trustManage != null)
{
{
//删除主表数据
Funs.DB.PMI_Delegation.DeleteOnSubmit(trustManage);
//删除 明细表
@ -371,7 +367,7 @@ namespace FineUIPro.Web.WeldingProcess.PMI
{
this.InitTreeMenu();
this.BindGrid();
}
#region
@ -387,435 +383,51 @@ namespace FineUIPro.Web.WeldingProcess.PMI
#endregion
#endregion
#region
/// <summary>
/// 获取按钮权限
/// </summary>
/// <param name="button"></param>
/// <returns></returns>
private bool GetButtonPower(string button)
{
return BLL.CommonService.GetAllButtonPowerList(this.CurrUser.LoginProjectId, this.CurrUser.UserId, BLL.Const.DailyReportCompleteMenuId, button);
}
#endregion
/// <summary>
/// 打印
/// </summary>
protected void btnExport_Click(object sender, EventArgs e)
{
if (string.IsNullOrWhiteSpace(this.tvControlItem.SelectedNodeID))
{
Alert.ShowInTop("请选择委托单!", MessageBoxIcon.Warning);
return;
}
string rootPath = Server.MapPath("~/") + Const.ExcelUrl;
//导出文件
string filePath = rootPath + DateTime.Now.ToString("yyyyMMddhhmmss") + "\\";
if (!Directory.Exists(filePath))
{
Directory.CreateDirectory(filePath);
}
string ReportFileName = filePath + "out.xlsx";
int rowIndex = 0;
XSSFWorkbook hssfworkbook = new XSSFWorkbook();
XSSFSheet ws = (XSSFSheet)hssfworkbook.CreateSheet("无损检测委托单(PMI)");
Alert.ShowInTop("待开发!", MessageBoxIcon.Warning);
return;
//if (CommonService.GetAllButtonPowerList(this.CurrUser.LoginProjectId, this.CurrUser.UserId, Const.HJGL_BatchTrustMenuId, Const.BtnOut))
//{
#region
ws.SetColumnWidth(0, 6 * 256);
ws.SetColumnWidth(1, 4 * 256);
ws.SetColumnWidth(2, 6 * 256);
ws.SetColumnWidth(3, 6 * 256);
ws.SetColumnWidth(4, 6 * 256);
ws.SetColumnWidth(5, 6 * 256);
ws.SetColumnWidth(6, 9 * 256);
ws.SetColumnWidth(7, 9 * 256);
ws.SetColumnWidth(8, 5 * 256);
ws.SetColumnWidth(9, 5 * 256);
ws.SetColumnWidth(10, 5 * 256);
ws.SetColumnWidth(11, 8 * 256);
ws.SetColumnWidth(12, 9 * 256);
ws.SetColumnWidth(13, 11 * 256);
#endregion
string pmiId = this.tvControlItem.SelectedNodeID;
//头部
var pmititle = Funs.DB.PMI_Delegation.FirstOrDefault(x => x.Id == pmiId);
//列表
List<SqlParameter> listStr = new List<SqlParameter>();
listStr.Add(new SqlParameter("@ProjectId", pmititle != null ? pmititle.ProjectId : this.CurrUser.LoginProjectId));
listStr.Add(new SqlParameter("@PMIID", this.PMIDelegationId));
SqlParameter[] parameter = listStr.ToArray();
var tb = SQLHelper.GetDataTableRunText("SELECT * FROM View_PMI_DelegationDetails WHERE ProjectId=@ProjectId AND PMIID=@PMIID", parameter);
//模拟多页数据sql
//var tb = SQLHelper.GetDataTableRunText("SELECT * FROM View_PMI_DelegationDetails WHERE ProjectId=@ProjectId AND PMIID=@PMIID union all SELECT * FROM View_PMI_DelegationDetails WHERE ProjectId=@ProjectId AND PMIID=@PMIID union all SELECT * FROM View_PMI_DelegationDetails WHERE ProjectId=@ProjectId AND PMIID=@PMIID union all SELECT * FROM View_PMI_DelegationDetails WHERE ProjectId=@ProjectId AND PMIID=@PMIID union all SELECT * FROM View_PMI_DelegationDetails WHERE ProjectId=@ProjectId AND PMIID=@PMIID union all SELECT * FROM View_PMI_DelegationDetails WHERE ProjectId=@ProjectId AND PMIID=@PMIID union all SELECT * FROM View_PMI_DelegationDetails WHERE ProjectId=@ProjectId AND PMIID=@PMIID union all SELECT * FROM View_PMI_DelegationDetails WHERE ProjectId=@ProjectId AND PMIID=@PMIID union all SELECT * FROM View_PMI_DelegationDetails WHERE ProjectId=@ProjectId AND PMIID=@PMIID union all SELECT * FROM View_PMI_DelegationDetails WHERE ProjectId=@ProjectId AND PMIID=@PMIID union all SELECT * FROM View_PMI_DelegationDetails WHERE ProjectId=@ProjectId AND PMIID=@PMIID union all SELECT * FROM View_PMI_DelegationDetails WHERE ProjectId=@ProjectId AND PMIID=@PMIID union all SELECT * FROM View_PMI_DelegationDetails WHERE ProjectId=@ProjectId AND PMIID=@PMIID union all SELECT * FROM View_PMI_DelegationDetails WHERE ProjectId=@ProjectId AND PMIID=@PMIID union all SELECT * FROM View_PMI_DelegationDetails WHERE ProjectId=@ProjectId AND PMIID=@PMIID union all SELECT * FROM View_PMI_DelegationDetails WHERE ProjectId=@ProjectId AND PMIID=@PMIID union all SELECT * FROM View_PMI_DelegationDetails WHERE ProjectId=@ProjectId AND PMIID=@PMIID union all SELECT * FROM View_PMI_DelegationDetails WHERE ProjectId=@ProjectId AND PMIID=@PMIID union all SELECT * FROM View_PMI_DelegationDetails WHERE ProjectId=@ProjectId AND PMIID=@PMIID union all SELECT * FROM View_PMI_DelegationDetails WHERE ProjectId=@ProjectId AND PMIID=@PMIID union all SELECT * FROM View_PMI_DelegationDetails WHERE ProjectId=@ProjectId AND PMIID=@PMIID union all SELECT * FROM View_PMI_DelegationDetails WHERE ProjectId=@ProjectId AND PMIID=@PMIID union all SELECT * FROM View_PMI_DelegationDetails WHERE ProjectId=@ProjectId AND PMIID=@PMIID union all SELECT * FROM View_PMI_DelegationDetails WHERE ProjectId=@ProjectId AND PMIID=@PMIID union all SELECT * FROM View_PMI_DelegationDetails WHERE ProjectId=@ProjectId AND PMIID=@PMIID", parameter);
var style = CommonPrint.SetExcelStyle(hssfworkbook, BorderStyle.Thin, BorderStyle.Thin, BorderStyle.Thin, BorderStyle.Thin, VerticalAlignment.Center, HorizontalAlignment.Center, 10, true, false);
var styleButton = CommonPrint.SetExcelStyle(hssfworkbook, BorderStyle.None, BorderStyle.Thin, BorderStyle.Thin, BorderStyle.Thin, VerticalAlignment.Center, HorizontalAlignment.Center, 10, true, false);
var styleTop = CommonPrint.SetExcelStyle(hssfworkbook, BorderStyle.Thin, BorderStyle.Thin, BorderStyle.Thin, BorderStyle.None, VerticalAlignment.Center, HorizontalAlignment.Center, 10, true, false);
var styleNone = CommonPrint.SetExcelStyle(hssfworkbook, BorderStyle.None, BorderStyle.Thin, BorderStyle.Thin, BorderStyle.None, VerticalAlignment.Center, HorizontalAlignment.Center, 10, true, false);
if (tb.Rows.Count > 0 && pmititle != null)
{
var tbNum = tb.Rows.Count;
var pageNum =
tbNum < 15 ? 1
: Math.Ceiling((float)(tbNum - 14) / 14) + 1;
//循环页
for (int i = 1; i <= pageNum; i++)
{
#region
ws = WsExcelCreateRow(ws, hssfworkbook, rowIndex, rowIndex + 12, style, 0, 13, 1);
//行0
CellRangeAddress region = new CellRangeAddress(rowIndex, rowIndex + 3, 0, 3);
ws.AddMergedRegion(region);
ws.GetRow(rowIndex).GetCell(0).SetCellValue("NDE-002");
ws.GetRow(rowIndex).GetCell(0).CellStyle = style;
ws.GetRow(rowIndex).GetCell(1).CellStyle = style;
ws.GetRow(rowIndex).GetCell(2).CellStyle = style;
ws.GetRow(rowIndex).GetCell(3).CellStyle = style;
region = new CellRangeAddress(rowIndex, rowIndex + 3, 4, 10);
ws.AddMergedRegion(region);
ws.GetRow(rowIndex).GetCell(4).SetCellValue("无损检测委托单\r\nPMI");
ws.GetRow(rowIndex).GetCell(4).CellStyle = CommonPrint.SetExcelStyle(hssfworkbook, BorderStyle.Thin, BorderStyle.Thin, BorderStyle.Thin, BorderStyle.Thin, VerticalAlignment.Center, HorizontalAlignment.Center, 16, true, true);
ws.GetRow(rowIndex).GetCell(5).CellStyle = style;
ws.GetRow(rowIndex).GetCell(6).CellStyle = style;
ws.GetRow(rowIndex).GetCell(7).CellStyle = style;
ws.GetRow(rowIndex).GetCell(8).CellStyle = style;
ws.GetRow(rowIndex).GetCell(9).CellStyle = style;
ws.GetRow(rowIndex).GetCell(10).CellStyle = style;
region = new CellRangeAddress(rowIndex, rowIndex, 11, 13);
ws.AddMergedRegion(region);
ws.GetRow(rowIndex).GetCell(11).SetCellValue("工程名称:巴斯夫(广东)一体化项目专用化学品二区");
ws.GetRow(rowIndex).GetCell(11).CellStyle = CommonPrint.SetExcelStyle(hssfworkbook, BorderStyle.None, BorderStyle.Thin, BorderStyle.Thin, BorderStyle.Thin, VerticalAlignment.Center, HorizontalAlignment.Justify, 10.5, true, false);
ws.GetRow(rowIndex).GetCell(12).CellStyle = styleButton;
ws.GetRow(rowIndex).GetCell(13).CellStyle = styleButton;
//行1
region = new CellRangeAddress(rowIndex + 1, rowIndex + 1, 11, 13);
ws.AddMergedRegion(region);
ws.GetRow(rowIndex + 1).GetCell(11).SetCellValue("BASF (Guangdong) Integrated Project Citral Cluster");
ws.GetRow(rowIndex + 1).GetCell(11).CellStyle = CommonPrint.SetExcelStyle(hssfworkbook, BorderStyle.None, BorderStyle.Thin, BorderStyle.Thin, BorderStyle.None, VerticalAlignment.Center, HorizontalAlignment.Justify, 10.5, true, false);
ws.GetRow(rowIndex + 1).GetCell(12).CellStyle = styleNone;
ws.GetRow(rowIndex + 1).GetCell(13).CellStyle = styleNone;
//行2
region = new CellRangeAddress(rowIndex + 2, rowIndex + 2, 11, 13);
ws.AddMergedRegion(region);
ws.GetRow(rowIndex + 2).GetCell(11).SetCellValue("单元名称:");
ws.GetRow(rowIndex + 2).GetCell(11).CellStyle = CommonPrint.SetExcelStyle(hssfworkbook, BorderStyle.None, BorderStyle.Thin, BorderStyle.Thin, BorderStyle.None, VerticalAlignment.Center, HorizontalAlignment.Justify, 10.5, true, false);
ws.GetRow(rowIndex + 2).GetCell(12).CellStyle = styleNone;
ws.GetRow(rowIndex + 2).GetCell(13).CellStyle = styleNone;
//行3
region = new CellRangeAddress(rowIndex + 3, rowIndex + 3, 11, 13);
ws.AddMergedRegion(region);
ws.GetRow(rowIndex + 3).GetCell(11).SetCellValue("Unit Name:");
ws.GetRow(rowIndex + 3).GetCell(11).CellStyle = CommonPrint.SetExcelStyle(hssfworkbook, BorderStyle.Thin, BorderStyle.Thin, BorderStyle.Thin, BorderStyle.None, VerticalAlignment.Center, HorizontalAlignment.Justify, 10.5, true, false);
ws.GetRow(rowIndex + 3).GetCell(12).CellStyle = styleTop;
ws.GetRow(rowIndex + 3).GetCell(13).CellStyle = styleTop;
//行4
region = new CellRangeAddress(rowIndex + 4, rowIndex + 4, 0, 1);
ws.AddMergedRegion(region);
ws.GetRow(rowIndex + 4).GetCell(0).SetCellValue("委托单位");
region = new CellRangeAddress(rowIndex + 4, rowIndex + 4, 2, 6);
ws.AddMergedRegion(region);
ws.GetRow(rowIndex + 4).GetCell(2).SetCellValue("");
region = new CellRangeAddress(rowIndex + 4, rowIndex + 4, 7, 8);
ws.AddMergedRegion(region);
ws.GetRow(rowIndex + 4).GetCell(7).SetCellValue("委托编号");
region = new CellRangeAddress(rowIndex + 4, rowIndex + 4, 9, 13);
ws.AddMergedRegion(region);
ws.GetRow(rowIndex + 4).GetCell(9).SetCellValue("");
//行5
region = new CellRangeAddress(rowIndex + 5, rowIndex + 5, 0, 1);
ws.AddMergedRegion(region);
ws.GetRow(rowIndex + 5).GetCell(0).SetCellValue("检测单位");
region = new CellRangeAddress(rowIndex + 5, rowIndex + 5, 2, 6);
ws.AddMergedRegion(region);
ws.GetRow(rowIndex + 5).GetCell(2).SetCellValue("");
region = new CellRangeAddress(rowIndex + 5, rowIndex + 5, 7, 8);
ws.AddMergedRegion(region);
ws.GetRow(rowIndex + 5).GetCell(7).SetCellValue("检测方法");
region = new CellRangeAddress(rowIndex + 5, rowIndex + 5, 9, 13);
ws.AddMergedRegion(region);
ws.GetRow(rowIndex + 5).GetCell(9).SetCellValue("");
//行6
region = new CellRangeAddress(rowIndex + 6, rowIndex + 6, 0, 1);
ws.AddMergedRegion(region);
ws.GetRow(rowIndex + 6).GetCell(0).SetCellValue("检件名称");
region = new CellRangeAddress(rowIndex + 6, rowIndex + 6, 2, 6);
ws.AddMergedRegion(region);
ws.GetRow(rowIndex + 6).GetCell(2).SetCellValue("");
region = new CellRangeAddress(rowIndex + 6, rowIndex + 6, 7, 8);
ws.AddMergedRegion(region);
ws.GetRow(rowIndex + 6).GetCell(7).SetCellValue("表面状态");
region = new CellRangeAddress(rowIndex + 6, rowIndex + 6, 9, 13);
ws.AddMergedRegion(region);
ws.GetRow(rowIndex + 6).GetCell(9).SetCellValue("");
//行7
region = new CellRangeAddress(rowIndex + 7, rowIndex + 7, 0, 1);
ws.AddMergedRegion(region);
ws.GetRow(rowIndex + 7).GetCell(0).SetCellValue("检测标准");
region = new CellRangeAddress(rowIndex + 7, rowIndex + 7, 2, 6);
ws.AddMergedRegion(region);
ws.GetRow(rowIndex + 7).GetCell(2).SetCellValue("");
region = new CellRangeAddress(rowIndex + 7, rowIndex + 7, 7, 8);
ws.AddMergedRegion(region);
ws.GetRow(rowIndex + 7).GetCell(7).SetCellValue("检测比例");
region = new CellRangeAddress(rowIndex + 7, rowIndex + 7, 9, 13);
ws.AddMergedRegion(region);
ws.GetRow(rowIndex + 7).GetCell(9).SetCellValue("");
//行8
region = new CellRangeAddress(rowIndex + 8, rowIndex + 8, 0, 1);
ws.AddMergedRegion(region);
ws.GetRow(rowIndex + 8).GetCell(0).SetCellValue("转动口/固定口");
region = new CellRangeAddress(rowIndex + 8, rowIndex + 8, 2, 6);
ws.AddMergedRegion(region);
ws.GetRow(rowIndex + 8).GetCell(2).SetCellValue("");
region = new CellRangeAddress(rowIndex + 8, rowIndex + 8, 7, 8);
ws.AddMergedRegion(region);
ws.GetRow(rowIndex + 8).GetCell(7).SetCellValue("委托日期");
region = new CellRangeAddress(rowIndex + 8, rowIndex + 8, 9, 13);
ws.AddMergedRegion(region);
ws.GetRow(rowIndex + 8).GetCell(9).SetCellValue("");
//行9
region = new CellRangeAddress(rowIndex + 9, rowIndex + 9, 0, 1);
ws.AddMergedRegion(region);
ws.GetRow(rowIndex + 9).GetCell(0).SetCellValue("焊接方法");
region = new CellRangeAddress(rowIndex + 9, rowIndex + 9, 2, 6);
ws.AddMergedRegion(region);
ws.GetRow(rowIndex + 9).GetCell(2).SetCellValue("");
region = new CellRangeAddress(rowIndex + 9, rowIndex + 9, 7, 8);
ws.AddMergedRegion(region);
ws.GetRow(rowIndex + 9).GetCell(7).SetCellValue("压力管道分级");
region = new CellRangeAddress(rowIndex + 9, rowIndex + 9, 9, 13);
ws.AddMergedRegion(region);
ws.GetRow(rowIndex + 9).GetCell(9).SetCellValue("");
//行10
region = new CellRangeAddress(rowIndex + 10, rowIndex + 10, 0, 1);
ws.AddMergedRegion(region);
ws.GetRow(rowIndex + 10).GetCell(0).SetCellValue("检测时机");
region = new CellRangeAddress(rowIndex + 10, rowIndex + 10, 2, 6);
ws.AddMergedRegion(region);
ws.GetRow(rowIndex + 10).GetCell(2).SetCellValue("");
region = new CellRangeAddress(rowIndex + 10, rowIndex + 10, 7, 8);
ws.AddMergedRegion(region);
ws.GetRow(rowIndex + 10).GetCell(7).SetCellValue("被检产品标准");
region = new CellRangeAddress(rowIndex + 10, rowIndex + 10, 9, 13);
ws.AddMergedRegion(region);
ws.GetRow(rowIndex + 10).GetCell(9).SetCellValue("");
//行12
region = new CellRangeAddress(rowIndex + 11, rowIndex + 11, 0, 2);
ws.AddMergedRegion(region);
ws.GetRow(rowIndex + 11).GetCell(0).SetCellValue("检件编号/管线号");
region = new CellRangeAddress(rowIndex + 11, rowIndex + 11, 3, 4);
ws.AddMergedRegion(region);
ws.GetRow(rowIndex + 11).GetCell(3).SetCellValue("");
region = new CellRangeAddress(rowIndex + 11, rowIndex + 11, 5, 6);
ws.AddMergedRegion(region);
ws.GetRow(rowIndex + 11).GetCell(5).SetCellValue("焊口总数");
region = new CellRangeAddress(rowIndex + 11, rowIndex + 11, 7, 9);
ws.AddMergedRegion(region);
ws.GetRow(rowIndex + 11).GetCell(7).SetCellValue("");
region = new CellRangeAddress(rowIndex + 11, rowIndex + 11, 10, 11);
ws.AddMergedRegion(region);
ws.GetRow(rowIndex + 11).GetCell(10).SetCellValue("抽检数量");
region = new CellRangeAddress(rowIndex + 11, rowIndex + 11, 12, 13);
ws.AddMergedRegion(region);
ws.GetRow(rowIndex + 11).GetCell(12).SetCellValue("");
//行13
ws.GetRow(rowIndex + 12).GetCell(0).SetCellValue("检测\r\n部位");
region = new CellRangeAddress(rowIndex + 12, rowIndex + 12, 1, 3);
ws.AddMergedRegion(region);
ws.GetRow(rowIndex + 12).GetCell(1).SetCellValue("检件编号/管线号");
ws.GetRow(rowIndex + 12).GetCell(4).SetCellValue("焊口号");
region = new CellRangeAddress(rowIndex + 12, rowIndex + 12, 5, 6);
ws.AddMergedRegion(region);
ws.GetRow(rowIndex + 12).GetCell(5).SetCellValue("焊工代号");
region = new CellRangeAddress(rowIndex + 12, rowIndex + 12, 7, 10);
ws.AddMergedRegion(region);
ws.GetRow(rowIndex + 12).GetCell(7).SetCellValue("检件材质");
region = new CellRangeAddress(rowIndex + 12, rowIndex + 12, 11, 12);
ws.AddMergedRegion(region);
ws.GetRow(rowIndex + 12).GetCell(11).SetCellValue("检件规格(mm)");
ws.GetRow(rowIndex + 12).GetCell(13).SetCellValue("备注");
#endregion
#region
ws = WsExcelCreateRow(ws, hssfworkbook, rowIndex + 13, rowIndex + 26, style, 0, 13, 2);
var dataTit = rowIndex + 13;
var tIndex = 12 + 14;
var dStart = 0;
var dEnd = 0;
if (i == 1)
{
dStart = 0;
dEnd = 14;
}
else
{
dStart = i == 2 ? 14 : ((i - 2) * 14) + 14;
dEnd = ((i - 1) * 14) + 14;
}
//合并单元格
for (int hb = dataTit; hb <= rowIndex + tIndex; hb++)
{
region = new CellRangeAddress(hb, hb, 1, 3);
ws.AddMergedRegion(region);
region = new CellRangeAddress(hb, hb, 5, 6);
ws.AddMergedRegion(region);
region = new CellRangeAddress(hb, hb, 7, 10);
ws.AddMergedRegion(region);
region = new CellRangeAddress(hb, hb, 11, 12);
ws.AddMergedRegion(region);
}
//获取当前页数据
var pageTb = GetPageToTable(tb, dStart, dEnd);
for (int j = 0; j < pageTb.Rows.Count; j++)
{
int dataIndex = dataTit + j;
//检测部位
ws.GetRow(dataIndex).GetCell(0).SetCellValue("");
//检件编号/管线号
ws.GetRow(dataIndex).GetCell(1).SetCellValue("数据待绑定");
//焊口号
ws.GetRow(dataIndex).GetCell(4).SetCellValue("");
//焊工代号
ws.GetRow(dataIndex).GetCell(5).SetCellValue("");
//检件材质
ws.GetRow(dataIndex).GetCell(7).SetCellValue("");
//检件规格(mm)
ws.GetRow(dataIndex).GetCell(11).SetCellValue("");
//备注
ws.GetRow(dataIndex).GetCell(13).SetCellValue("");
}
if (dataTit + pageTb.Rows.Count < 26)
{
ws.GetRow(dataTit + pageTb.Rows.Count).GetCell(0).SetCellValue("以下空白");
}
rowIndex += tIndex;
#endregion
#region
ws = WsExcelCreateRow(ws, hssfworkbook, rowIndex + 1, rowIndex + 9, style, 0, 13, 3);
//合并单元格
for (int hb = rowIndex + 1; hb <= rowIndex + 9; hb++)
{
for (int c = 0; c <= 13; c++)
{
if (hb >= rowIndex + 2 && hb <= rowIndex + 3)
{
ws.GetRow(hb).GetCell(c).CellStyle = CommonPrint.SetExcelStyle(hssfworkbook, BorderStyle.None, BorderStyle.Thin, BorderStyle.Thin, BorderStyle.None, VerticalAlignment.Center, HorizontalAlignment.Left, 10.5, true, false);
}
if (hb >= rowIndex + 4 && hb <= rowIndex + 8)
{
ws.GetRow(hb).GetCell(c).CellStyle = CommonPrint.SetExcelStyle(hssfworkbook, BorderStyle.None, BorderStyle.Thin, BorderStyle.Thin, BorderStyle.None, VerticalAlignment.Center, HorizontalAlignment.Right, 10.5, true, false);
}
if (hb == rowIndex + 9)
{
ws.GetRow(hb).GetCell(c).CellStyle = CommonPrint.SetExcelStyle(hssfworkbook, BorderStyle.Thin, BorderStyle.Thin, BorderStyle.Thin, BorderStyle.None, VerticalAlignment.Center, HorizontalAlignment.Center, 10.5, true, false);
}
}
region = new CellRangeAddress(hb, hb, 0, 2);
ws.AddMergedRegion(region);
region = new CellRangeAddress(hb, hb, 3, 5);
ws.AddMergedRegion(region);
region = new CellRangeAddress(hb, hb, 6, 7);
ws.AddMergedRegion(region);
region = new CellRangeAddress(hb, hb, 8, 11);
ws.AddMergedRegion(region);
region = new CellRangeAddress(hb, hb, 12, 13);
ws.AddMergedRegion(region);
}
//尾部行1
ws.GetRow(rowIndex + 1).GetCell(0).SetCellValue("施工单位");
ws.GetRow(rowIndex + 1).GetCell(3).SetCellValue("监理单位");
ws.GetRow(rowIndex + 1).GetCell(6).SetCellValue("管理公司");
ws.GetRow(rowIndex + 1).GetCell(8).SetCellValue("建设单位");
ws.GetRow(rowIndex + 1).GetCell(12).SetCellValue("检测单位");
//尾部行2
ws.GetRow(rowIndex + 2).GetCell(0).SetCellValue("");
ws.GetRow(rowIndex + 2).GetCell(3).SetCellValue("");
ws.GetRow(rowIndex + 2).GetCell(6).SetCellValue("");
ws.GetRow(rowIndex + 2).GetCell(8).SetCellValue("");
ws.GetRow(rowIndex + 2).GetCell(12).SetCellValue("");
//尾部行3
ws.GetRow(rowIndex + 3).GetCell(0).SetCellValue("质量检测员:");
ws.GetRow(rowIndex + 3).GetCell(3).SetCellValue("专业工程师:");
ws.GetRow(rowIndex + 3).GetCell(6).SetCellValue("专业/质量工程师:");
ws.GetRow(rowIndex + 3).GetCell(8).SetCellValue("业主代表:");
ws.GetRow(rowIndex + 3).GetCell(12).SetCellValue("接收人:");
//尾部行6
ws.GetRow(rowIndex + 6).GetCell(0).SetCellValue("专业工程师:");
//尾部行8
ws.GetRow(rowIndex + 8).GetCell(0).SetCellValue(" 年 月 日");
ws.GetRow(rowIndex + 8).GetCell(3).SetCellValue(" 年 月 日");
ws.GetRow(rowIndex + 8).GetCell(6).SetCellValue(" 年 月 日");
ws.GetRow(rowIndex + 8).GetCell(8).SetCellValue(" 年 月 日");
ws.GetRow(rowIndex + 8).GetCell(12).SetCellValue(" 年 月 日");
#endregion
ws = WsExcelCreateRow(ws, hssfworkbook, rowIndex + 10, rowIndex + 10, style, 0, 13, 3, true);
rowIndex += 11;
}
}
ws.SetMargin(MarginType.LeftMargin, 0.3);
ws.SetMargin(MarginType.RightMargin, 0.2);
ws.SetMargin(MarginType.BottomMargin, 0.4);
ws.PrintSetup.Landscape = false;
ws.PrintSetup.PaperSize = 9;
ws.ForceFormulaRecalculation = true;
using (FileStream filess = System.IO.File.OpenWrite(ReportFileName))
{
hssfworkbook.Write(filess);
}
FileInfo filet = new FileInfo(ReportFileName);
Response.Clear();
Response.Charset = "GB2312";
Response.ContentEncoding = System.Text.Encoding.UTF8;
// 添加头信息,为"文件下载/另存为"对话框指定默认文件名
Response.AddHeader("Content-Disposition", "attachment; filename=" + Server.UrlEncode("无损检测委托单(PMI).xlsx"));
// 添加头信息,指定文件大小,让浏览器能够显示下载进度
Response.AddHeader("Content-Length", filet.Length.ToString());
// 指定返回的是一个不能被客户端读取的流,必须被下载
Response.ContentType = "application/ms-excel";
// 把文件流发送到客户端
Response.WriteFile(filet.FullName);
// 停止页面的执行
Response.End();
// if (string.IsNullOrWhiteSpace(this.tvControlItem.SelectedNodeID))
// {
// Alert.ShowInTop("请选择委托单!", MessageBoxIcon.Warning);
// return;
// }
// string rootPath = Server.MapPath("~/") + Const.ExcelUrl;
// //导出文件
// string filePath = rootPath + DateTime.Now.ToString("yyyyMMddhhmmss") + "\\";
// if (!Directory.Exists(filePath))
// {
// Directory.CreateDirectory(filePath);
// }
// string ReportFileName = filePath + "out1.xlsx";
// int rowIndex = 0;
// XSSFWorkbook hssfworkbook = new XSSFWorkbook();
// XSSFSheet ws = new XSSFSheet();
// string trustBatchId = this.tvControlItem.SelectedNodeID;
//}
//else
//{
// ShowNotify(Resources.Lan.NoPrivilegePrompt, MessageBoxIcon.Warning);
//}
}
#region
/// <summary>
/// 获取某一列的所有值
/// </summary>
/// <typeparam name="T">列数据类型</typeparam>
/// <param name="dtSource">数据表</param>
/// <param name="filedName">列名</param>
/// <returns></returns>
public static List<T> GetColumnValues<T>(DataTable dtSource, string filedName)
{
return (from r in dtSource.AsEnumerable() select r.Field<T>(filedName)).ToList<T>();
}
/// <summary>
/// 无损检测委托单行和列
/// </summary>
@ -869,7 +481,7 @@ namespace FineUIPro.Web.WeldingProcess.PMI
}
/// <summary>
/// 行和列
/// 材料及配件检测委托单行和列
/// </summary>
/// <returns></returns>
private XSSFSheet ClExcelCreateRow(XSSFSheet ws, XSSFWorkbook hssfworkbook, int sRows, int eRows, ICellStyle style, int cStart, int cEnd, bool istitle = false, bool isnobk = false)
@ -896,7 +508,7 @@ namespace FineUIPro.Web.WeldingProcess.PMI
ws.GetRow(i).CreateCell(j);
if (isnobk)
{
ws.GetRow(i).GetCell(j).CellStyle = CommonPrint.SetExcelStyle(hssfworkbook, BorderStyle.None, BorderStyle.None, BorderStyle.None, BorderStyle.None, VerticalAlignment.Center, HorizontalAlignment.Center, 10, true, false);
ws.GetRow(i).GetCell(j).CellStyle = CommonPrint.SetExcelStyle(hssfworkbook, BorderStyle.None, BorderStyle.None, NPOI.SS.UserModel.BorderStyle.None, NPOI.SS.UserModel.BorderStyle.None, VerticalAlignment.Center, HorizontalAlignment.Center, 10, true, false);
}
else
{
@ -941,5 +553,18 @@ namespace FineUIPro.Web.WeldingProcess.PMI
#endregion
#region
/// <summary>
/// 获取按钮权限
/// </summary>
/// <param name="button"></param>
/// <returns></returns>
private bool GetButtonPower(string button)
{
return BLL.CommonService.GetAllButtonPowerList(this.CurrUser.LoginProjectId, this.CurrUser.UserId, BLL.Const.DailyReportCompleteMenuId, button);
}
#endregion
}
}

View File

@ -266,6 +266,15 @@ namespace FineUIPro.Web.WeldingProcess.PMI
/// </remarks>
protected global::FineUIPro.ToolbarFill ToolbarFill2;
/// <summary>
/// btnExport 控件。
/// </summary>
/// <remarks>
/// 自动生成的字段。
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
/// </remarks>
protected global::FineUIPro.Button btnExport;
/// <summary>
/// ToolbarSeparator1 控件。
/// </summary>

View File

@ -117,14 +117,14 @@
TextAlign="Left" Width="220px">
</f:RenderField>
<f:RenderField HeaderText="<%$ Resources:Lan,QualityNo %>" ColumnID="QualityNo" DataField="QualityNo"
FieldType="String" TextAlign="Left" Width="150px">
FieldType="String" TextAlign="Left" Width="150px" Hidden="true">
<Editor>
<f:TextBox ID="tbxEditorQualityNo" Required="true" runat="server">
</f:TextBox>
</Editor>
</f:RenderField>
<f:RenderField HeaderText="<%$ Resources:Lan,Acceptance %>" ColumnID="Acceptance"
DataField="Acceptance" FieldType="String" TextAlign="Left" Width="150px">
DataField="Acceptance" FieldType="String" TextAlign="Left" Width="150px" Hidden="true">
<Editor>
<f:TextBox ID="txtEditorAcceptance" Required="true" runat="server">
</f:TextBox>

View File

@ -85,7 +85,15 @@ namespace FineUIPro.Web.WeldingProcess.PMI
this.drpUnitId.SelectedValue = trust.UnitId;
}
this.txtDetectionMethod.Text = "PMI光谱分析";
this.txtDetectionStandard.Text = trust.DetectionStandard;
if (!string.IsNullOrEmpty(trust.DetectionStandard))
{
this.txtDetectionStandard.Text = trust.DetectionStandard;
}
else
{
txtDetectionStandard.Text = "GB 50184-2011";
}
if (!string.IsNullOrEmpty(trust.Tabler))
{
this.txtTabler.Text = BLL.Sys_UserService.GetUserNameByUserId(trust.Tabler);
@ -94,6 +102,7 @@ namespace FineUIPro.Web.WeldingProcess.PMI
}
else
{
txtDetectionStandard.Text = "GB 50184-2011";
this.txtTabler.Text = this.CurrUser.UserName;
this.SimpleForm1.Reset(); //重置所有字段
}

View File

@ -151,10 +151,10 @@
TextAlign="Center" Width="160px">
</f:RenderField>
<f:RenderField HeaderText="<%$ Resources:Lan,QualityNo %>" ColumnID="QualityNo" DataField="QualityNo"
FieldType="String" TextAlign="Left" Width="150px">
FieldType="String" TextAlign="Left" Width="150px" Hidden="true">
</f:RenderField>
<f:RenderField HeaderText="<%$ Resources:Lan,Acceptance %>" ColumnID="Acceptance"
DataField="Acceptance" FieldType="String" TextAlign="Left" Width="150px">
DataField="Acceptance" FieldType="String" TextAlign="Left" Width="150px" Hidden="true">
</f:RenderField>
<%-- 检测日期 --%>
<f:RenderField HeaderText="<%$ Resources:Lan,FilmDate %>" ColumnID="checkTime"

View File

@ -4106,12 +4106,12 @@ namespace FineUIPro.Web.WeldingProcess.TestPackageManage
ws.SetColumnWidth(12, 6 * 256);//M
ws.SetColumnWidth(13, 5 * 256);//N
ws.SetColumnWidth(14, 4 * 256);//O
ws.SetColumnWidth(15, 6 * 256);//P
ws.SetColumnWidth(15, 4 * 256);//P
ws.SetColumnWidth(16, 4 * 256);//Q
ws.SetColumnWidth(17, 5 * 256);//R
ws.SetColumnWidth(18, 6 * 256);//S
ws.SetColumnWidth(19, 7 * 256);//T
ws.SetColumnWidth(20, 13 * 256);//U
ws.SetColumnWidth(18, 5 * 256);//S
ws.SetColumnWidth(19, 5 * 256);//T
ws.SetColumnWidth(20, 18 * 256);//U
ws.AddMergedRegion(new CellRangeAddress(rowIndex, rowIndex + 3, 0, 2));
ws.GetRow(rowIndex).GetCell(0).SetCellValue("SH/T 3503-J412-1-2007");
@ -7514,7 +7514,7 @@ namespace FineUIPro.Web.WeldingProcess.TestPackageManage
{
Directory.CreateDirectory(filePath);
}
string fileName = "模版报表-" + DateTime.Now.ToString("yyyyMMddHHmmss") + ".xlsx";
string fileName = "试压包报表-" + DateTime.Now.ToString("yyyyMMddHHmmss") + ".xlsx";
string ReportFileName = filePath + fileName;
//XSSFWorkbook hssfworkbook = new XSSFWorkbook();

View File

@ -114,6 +114,14 @@
<f:Button ID="btnHandGenerate" Text="手动生成委托单" ToolTip="勾选需要生成委托单的焊口手动生成委托单" Icon="TableEdit" runat="server"
OnClick="btnHandGenerate_Click" >
</f:Button>
</Items>
</f:Toolbar>
<f:Toolbar ID="Toolbar4" Position="Top" runat="server" ToolbarAlign="Right">
<Items>
<f:Button ID="btnDailyCompPoint" Text="日报完成点口" ToolTip="日报忋完成审核点口" Icon="ArrowUndo"
runat="server" OnClick="btnDailyCompPoint_Click">
</f:Button>
<f:Button ID="btnbtnOpenResetPoint" Text="打开重新点口" ToolTip="打开重新点口" Icon="ArrowUndo"
runat="server" OnClick="btnbtnOpenResetPoint_Click">
</f:Button>

View File

@ -854,6 +854,332 @@ namespace FineUIPro.Web.WeldingProcess.TrustManage
}
}
/// <summary>
/// 日报完成点口
/// </summary>
/// <param name="sender"></param>
/// <param name="e"></param>
protected void btnDailyCompPoint_Click(object sender, EventArgs e)
{
if (CommonService.GetAllButtonPowerList(this.CurrUser.LoginProjectId, this.CurrUser.UserId, Const.HJGL_PointManageMenuId, Const.BtnOpenResetPoint))
{
string strSql = @"SELECT jot.ProjectId, pItem.PointBatchId,jot.CoverWelderId,rate.DetectionRateValue
FROM dbo.Batch_PointBatchItem pItem
LEFT JOIN dbo.Batch_PointBatch point ON point.PointBatchId = pItem.PointBatchId
LEFT JOIN dbo.Pipeline_WeldJoint jot ON jot.WeldJointId = pItem.WeldJointId
LEFT JOIN dbo.Base_DetectionRate rate ON rate.DetectionRateId=point.DetectionRateId
WHERE pItem.IsCompletedPoint=0
GROUP BY jot.ProjectId, pItem.PointBatchId,jot.CoverWelderId,rate.DetectionRateValue";
DataTable dt = SQLHelper.GetDataTableRunText(strSql, null);
if (dt.Rows.Count > 0)
{
foreach (DataRow r in dt.Rows)
{
// 已处理但批段未关闭的焊口
List<PointBatchList> batchNoClose = (from x in Funs.DB.Batch_PointBatchItem
join y in Funs.DB.Pipeline_WeldJoint on x.WeldJointId equals y.WeldJointId
where x.PointBatchId == r["PointBatchId"].ToString()
&& y.CoverWelderId == r["CoverWelderId"].ToString()
&& (x.BatchOrder == false || x.BatchOrder == null)
&& x.IsCompletedPoint == true
&& (y.IsCancel == false || y.IsCancel == null)
select new PointBatchList { PointBatchItemId = x.PointBatchItemId, JointAttribute = y.JointAttribute }).ToList();
// 未处理焊口
List<PointBatchList> jotList = (from x in Funs.DB.Batch_PointBatchItem
join y in Funs.DB.Pipeline_WeldJoint on x.WeldJointId equals y.WeldJointId
where x.PointBatchId == r["PointBatchId"].ToString()
&& y.CoverWelderId == r["CoverWelderId"].ToString()
&& (x.IsCompletedPoint == false || x.IsCompletedPoint == null)
&& (y.IsCancel == false || y.IsCancel == null)
orderby x.EnterDate
select new PointBatchList { PointBatchItemId = x.PointBatchItemId, JointAttribute = y.JointAttribute }).ToList();
// 未处理固定焊口
List<PointBatchList> GJot = jotList.Where(x=>x.JointAttribute == "固定F").ToList();
if (Convert.ToInt32(r["DetectionRateValue"]) != 0)
{
// 批中一段的数量
int dnum = Convert.ToInt32((double)100 / (int)r["DetectionRateValue"]);
// 已处理但批段未关闭的焊口数量
int batchNoCloseNum = batchNoClose.Count();
// 未处理焊口数量
int jotListNum = jotList.Count();
// 未处理固定焊口数量
int GJotNum = GJot.Count();
#region batchNoCloseNum大于0表示批段已处理但批段未关闭的焊口集合里
if (batchNoCloseNum > 0)
{
if ((batchNoCloseNum + jotListNum) > dnum)
{
// 关闭上一个批段还需要的数量
int closeNum = dnum - batchNoCloseNum;
var bachtclose = jotList.GetRange(0, closeNum);
// 补足上一个批段,关闭同时状态为已处理
foreach (var g in bachtclose)
{
BLL.Batch_PointBatchItemService.UpdatePointBatchOrder(g.PointBatchItemId, true);
BLL.Batch_PointBatchItemService.UpdateIsCompletedPoint(g.PointBatchItemId, true);
}
foreach (var g in batchNoClose)
{
BLL.Batch_PointBatchItemService.UpdatePointBatchOrder(g.PointBatchItemId, true);
}
if ((jotListNum - closeNum) > dnum)
{
// 取模(余数)
int modelNum = (jotListNum - closeNum) % dnum;
// 取整
double doubleNum = Math.Ceiling((double)((jotListNum - closeNum) / (double)dnum));
int intNum = Convert.ToInt32(doubleNum);
// 补足上一个批段后剩余的待处理的列表
var remailList = jotList.GetRange(closeNum, (jotListNum - closeNum));
for (int i = 0; i < intNum; i++)
{
if (modelNum == 0)
{
var bachtOrder = remailList.GetRange(i * dnum, dnum);
var bachtOrderG = bachtOrder.Where(p => p.JointAttribute == "固定F").ToList();
// 点口
GetRandomPoint(bachtOrderG, bachtOrder);
// 状态为已处理状态,并关闭此批段
foreach (var g in bachtOrder)
{
BLL.Batch_PointBatchItemService.UpdateIsCompletedPoint(g.PointBatchItemId, true);
BLL.Batch_PointBatchItemService.UpdatePointBatchOrder(g.PointBatchItemId, true);
}
}
else
{
if (i != intNum - 1)
{
var bachtOrder = remailList.GetRange(i * dnum, dnum);
var bachtOrderG = bachtOrder.Where(p => p.JointAttribute == "固定F").ToList();
// 点口
GetRandomPoint(bachtOrderG, bachtOrder);
// 状态为已处理状态,并关闭此批段
foreach (var g in bachtOrder)
{
BLL.Batch_PointBatchItemService.UpdateIsCompletedPoint(g.PointBatchItemId, true);
BLL.Batch_PointBatchItemService.UpdatePointBatchOrder(g.PointBatchItemId, true);
}
}
// 最后一个段
else
{
var bachtOrder = remailList.GetRange(i * dnum, modelNum);
var bachtOrderG = bachtOrder.Where(p => p.JointAttribute == "固定F").ToList();
// 点口
GetRandomPoint(bachtOrderG, bachtOrder);
// 状态为已处理状态,此批段不关闭
foreach (var g in bachtOrder)
{
BLL.Batch_PointBatchItemService.UpdateIsCompletedPoint(g.PointBatchItemId, true);
}
}
}
}
}
else if ((jotListNum - closeNum) == dnum)
{
var bachtOrder = jotList.GetRange(closeNum, (jotListNum - closeNum));
var bachtOrderG = bachtOrder.Where(p => p.JointAttribute == "固定F").ToList();
// 点口
GetRandomPoint(bachtOrderG, bachtOrder);
// 状态为已处理状态,并关闭此批段
foreach (var g in bachtOrder)
{
BLL.Batch_PointBatchItemService.UpdateIsCompletedPoint(g.PointBatchItemId, true);
BLL.Batch_PointBatchItemService.UpdatePointBatchOrder(g.PointBatchItemId, true);
}
}
else
{
var bachtOrder = jotList.GetRange(closeNum, (jotListNum - closeNum));
var bachtOrderG = bachtOrder.Where(p => p.JointAttribute == "固定F").ToList();
// 点口
GetRandomPoint(bachtOrderG, bachtOrder);
// 状态为已处理状态,此批段没关闭
foreach (var g in bachtOrder)
{
BLL.Batch_PointBatchItemService.UpdateIsCompletedPoint(g.PointBatchItemId, true);
}
}
}
// 当未关闭的批段+未处理焊口的数量等于探伤比例数量时批段关闭
else if (batchNoCloseNum + jotListNum == dnum)
{
// 批段关闭
foreach (var g in batchNoClose)
{
BLL.Batch_PointBatchItemService.UpdatePointBatchOrder(g.PointBatchItemId, true);
}
// 批段关闭,状态为已处理
foreach (var g in jotList)
{
BLL.Batch_PointBatchItemService.UpdatePointBatchOrder(g.PointBatchItemId, true);
BLL.Batch_PointBatchItemService.UpdateIsCompletedPoint(g.PointBatchItemId, true);
}
}
else
{
// 待处理完成,但批段未关闭
foreach (var g in jotList)
{
BLL.Batch_PointBatchItemService.UpdateIsCompletedPoint(g.PointBatchItemId, true);
}
}
}
#endregion
#region batchNoCloseNum等于0表示这个批段开始
else
{
if (jotListNum > dnum)
{
// 取模(余数)
int modelNum = jotList.Count() % dnum;
// 取整
double doubleNum = Math.Ceiling((double)jotList.Count() / (double)dnum);
int intNum=Convert.ToInt32(doubleNum);
for (int i = 0; i < intNum; i++)
{
if (modelNum == 0)
{
var bachtOrder = jotList.GetRange(i * dnum, dnum);
var bachtOrderG = bachtOrder.Where(p => p.JointAttribute == "固定F").ToList();
// 点口
GetRandomPoint(bachtOrderG, bachtOrder);
// 状态为已处理状态,并关闭此批段
foreach (var g in bachtOrder)
{
BLL.Batch_PointBatchItemService.UpdateIsCompletedPoint(g.PointBatchItemId, true);
BLL.Batch_PointBatchItemService.UpdatePointBatchOrder(g.PointBatchItemId, true);
}
}
else
{
if (i != intNum - 1)
{
var bachtOrder = jotList.GetRange(i * dnum, dnum);
var bachtOrderG = bachtOrder.Where(p => p.JointAttribute == "固定F").ToList();
// 点口
GetRandomPoint(bachtOrderG, bachtOrder);
// 状态为已处理状态,并关闭此批段
foreach (var g in bachtOrder)
{
BLL.Batch_PointBatchItemService.UpdateIsCompletedPoint(g.PointBatchItemId, true);
BLL.Batch_PointBatchItemService.UpdatePointBatchOrder(g.PointBatchItemId, true);
}
}
// 最后一个段
else
{
var bachtOrder = jotList.GetRange(i * dnum, modelNum);
var bachtOrderG = bachtOrder.Where(p => p.JointAttribute == "固定F").ToList();
// 点口
GetRandomPoint(bachtOrderG, bachtOrder);
// 状态为已处理状态,此批段不关闭
foreach (var g in bachtOrder)
{
BLL.Batch_PointBatchItemService.UpdateIsCompletedPoint(g.PointBatchItemId, true);
}
}
}
}
}
else if (jotListNum == dnum)
{
// 点口
GetRandomPoint(GJot, jotList);
// 状态为已处理状态,并关闭此批段
foreach (var g in jotList)
{
BLL.Batch_PointBatchItemService.UpdateIsCompletedPoint(g.PointBatchItemId, true);
BLL.Batch_PointBatchItemService.UpdatePointBatchOrder(g.PointBatchItemId, true);
}
}
else
{
// 点口
GetRandomPoint(GJot, jotList);
// 状态为已处理状态,但批段不关闭
foreach (var g in jotList)
{
BLL.Batch_PointBatchItemService.UpdateIsCompletedPoint(g.PointBatchItemId, true);
}
}
}
#endregion
}
else
{
// 不点口,状态为变已处理,批段完成
foreach (var q in jotList)
{
BLL.Batch_PointBatchItemService.UpdateIsCompletedPoint(q.PointBatchItemId, true);
BLL.Batch_PointBatchItemService.UpdatePointBatchOrder(q.PointBatchItemId, true);
}
}
}
}
}
else
{
ShowNotify(Resources.Lan.NoPrivilegePrompt, MessageBoxIcon.Warning);
return;
}
}
private void GetRandomPoint(List<PointBatchList> GJot, List<PointBatchList> jotList)
{
// 先查找固定口数量,如有固定口,则优先点
if (GJot.Count() > 0)
{
int Gnum = GJot.Count();
int rnum = Funs.GetRandomNum(1, Gnum);
int j = 1;
foreach (var g in GJot)
{
if (rnum == j)
{
BLL.Batch_PointBatchItemService.UpdatePointBatchItem(g.PointBatchItemId, "1", System.DateTime.Now, null);
}
j++;
}
}
else
{
if (jotList.Count() > 0)
{
int rnum = Funs.GetRandomNum(1, jotList.Count());
int j = 1;
foreach (var g in jotList)
{
if (rnum == j)
{
BLL.Batch_PointBatchItemService.UpdatePointBatchItem(g.PointBatchItemId, "1", System.DateTime.Now, null);
}
j++;
}
}
}
}
/// <summary>
/// 手动结束批
/// </summary>
@ -1632,6 +1958,20 @@ namespace FineUIPro.Web.WeldingProcess.TrustManage
return newTrustCode;
}
private class PointBatchList
{
public string PointBatchItemId
{
get;
set;
}
public string JointAttribute
{
get;
set;
}
}
}
}

View File

@ -203,6 +203,24 @@ namespace FineUIPro.Web.WeldingProcess.TrustManage
/// </remarks>
protected global::FineUIPro.Button btnHandGenerate;
/// <summary>
/// Toolbar4 控件。
/// </summary>
/// <remarks>
/// 自动生成的字段。
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
/// </remarks>
protected global::FineUIPro.Toolbar Toolbar4;
/// <summary>
/// btnDailyCompPoint 控件。
/// </summary>
/// <remarks>
/// 自动生成的字段。
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
/// </remarks>
protected global::FineUIPro.Button btnDailyCompPoint;
/// <summary>
/// btnbtnOpenResetPoint 控件。
/// </summary>

View File

@ -102,13 +102,15 @@ namespace FineUIPro.Web.WeldingProcess.WeldingManage
protected void BtnExtract_Click(object sender, EventArgs e)
{
bool canWPS = true;
var jotList = (from x in Funs.DB.Pipeline_WeldJoint where x.ProjectId == this.CurrUser.LoginProjectId && x.WeldingDailyId != null && x.WeldingMethodId != null select x).ToList();
var jotList = (from x in Funs.DB.Pipeline_WeldJoint where x.ProjectId == this.CurrUser.LoginProjectId && x.WeldingDailyId != null && x.WeldingMethodId != null
select x).ToList(); // && x.PipelineId== "246c6b8c-8fbd-480c-9810-43062bf09646"
foreach (var jot in jotList)
{
var wps = BLL.WPQListServiceService.GetWPQById(jot.WPQId);
string floorWelder = jot.BackingWelderId;
string cellWelder = jot.CoverWelderId;
bool canWPS = true;
if (wps != null)
{
// 验证焊工WPS资质
@ -143,7 +145,12 @@ namespace FineUIPro.Web.WeldingProcess.WeldingManage
decimal? sch = jot.Thickness;
string[] wmeCodes = mat.WeldingMethodCode.Split('+');
string location = loc.WeldingLocationCode;
string location=string.Empty;
if (loc != null)
{
location = loc.WeldingLocationCode;
}
string ste = jot.Material1Id;
List<Model.Welder_WelderQualify> floorWelderQualifys = (from x in Funs.DB.Welder_WelderQualify
@ -201,13 +208,17 @@ namespace FineUIPro.Web.WeldingProcess.WeldingManage
}
}
if (canWPS==false || canSave == false)
if (canWPS == false || canSave == false)
{
jot.IsSuperQueWelding = true;
Funs.DB.SubmitChanges();
}
}
else
{
jot.IsSuperQueWelding = null;
}
}
Funs.DB.SubmitChanges();
ShowNotify("提取完成");
return;

View File

@ -9,6 +9,7 @@ using NPOI.SS.Util;
using NPOI.XSSF.UserModel;
using System.Linq;
using BLL;
using System.Web.Configuration;
namespace FineUIPro.Web.WeldingProcess.WeldingManage
{
@ -353,6 +354,11 @@ namespace FineUIPro.Web.WeldingProcess.WeldingManage
var weldJoints = BLL.Pipeline_WeldJointService.GetWeldlinesByWeldingDailyId(weldingDailyId);
if (weldJoints.Count() > 0)
{
string[] jointList = weldJoints.Select(p => p.WeldJointId).ToArray();
var pointBatchList = from x in Funs.DB.Batch_PointBatchItem
where jointList.Contains(x.WeldJointId)
select x;
string[] pointBatchIdList = pointBatchList.Select(p => p.PointBatchId).Distinct().ToArray();
foreach (var item in weldJoints)
{
var updateWeldJoint = BLL.Pipeline_WeldJointService.GetWeldJointByWeldJointId(item.WeldJointId);
@ -369,8 +375,42 @@ namespace FineUIPro.Web.WeldingProcess.WeldingManage
BLL.Batch_NDEItemService.DeleteAllNDEInfoToWeldJoint(item.WeldJointId);
}
}
// 打开批
if (pointBatchIdList.Count() > 0)
{
foreach (string p in pointBatchIdList)
{
var pItem = (from x in Funs.DB.Batch_PointBatchItem
orderby x.EnterDate descending
where x.PointBatchId == p
select x).ToList();
int pItemNum = pItem.Count();
if (pItemNum > 0)
{
var batch = BLL.Batch_PointBatchService.GetPointBatchById(p);
var rate = BLL.Base_DetectionRateService.GetDetectionRateByDetectionRateId(batch.DetectionRateId);
int dnum = Convert.ToInt32((double)100 / (int)rate.DetectionRateValue);
// 取模(余数)
int modelNum = pItemNum % dnum;
// 等于0不处理
if (modelNum != 0)
{
var bachtOrder = pItem.GetRange(0, modelNum);
foreach (var g in bachtOrder)
{
BLL.Batch_PointBatchItemService.UpdatePointBatchOrder(g.PointBatchItemId, false);
}
}
}
}
}
}
BLL.Pipeline_WeldingDailyService.DeleteWeldingDailyByWeldingDailyId(weldingDailyId);
BLL.Sys_LogService.AddLog(BLL.Const.System_3, this.CurrUser.LoginProjectId, this.CurrUser.UserId, Const.HJGL_WeldReportMenuId, Const.BtnDelete, weldingDailyId);
ShowNotify(Resources.Lan.DeletedSuccessfully, MessageBoxIcon.Success);
this.BindGrid();
@ -1019,6 +1059,7 @@ namespace FineUIPro.Web.WeldingProcess.WeldingManage
// }
//}
string oldmat1 = d.Material1Id;
if (ds.Tables[0].Rows[i]["材质1"] != null && !string.IsNullOrEmpty(ds.Tables[0].Rows[i]["材质1"].ToString()))
{
var steel = materials.FirstOrDefault(x => x.MaterialCode == ds.Tables[0].Rows[i]["材质1"].ToString());
@ -1050,7 +1091,7 @@ namespace FineUIPro.Web.WeldingProcess.WeldingManage
else
{
if ((!string.IsNullOrEmpty(d.Material2Id) && steel.MaterialId != d.Material2Id)
&& (!string.IsNullOrEmpty(d.Material1Id) && steel.MaterialId != d.Material1Id))
&& (!string.IsNullOrEmpty(oldmat1) && steel.MaterialId != oldmat1))
{
errorInfos += (i + 2) + "行,材质2[" + ds.Tables[0].Rows[i]["材质2"].ToString() + "]验证不一至;";
}
@ -1061,7 +1102,7 @@ namespace FineUIPro.Web.WeldingProcess.WeldingManage
}
}
string oldCom1 = d.PipeAssembly1Id;
if (ds.Tables[0].Rows[i]["组件1"] != null && !string.IsNullOrEmpty(ds.Tables[0].Rows[i]["组件1"].ToString()))
{
var com = componentss.FirstOrDefault(x => x.ComponentsCode == ds.Tables[0].Rows[i]["组件1"].ToString());
@ -1093,8 +1134,8 @@ namespace FineUIPro.Web.WeldingProcess.WeldingManage
}
else
{
if ((!string.IsNullOrEmpty(d.PipeAssembly1Id) && com.ComponentsId != d.PipeAssembly1Id)
&& (!string.IsNullOrEmpty(d.PipeAssembly2Id) && com.ComponentsId != d.PipeAssembly2Id))
if ((!string.IsNullOrEmpty(d.PipeAssembly2Id) && com.ComponentsId != d.PipeAssembly2Id)
&& (!string.IsNullOrEmpty(oldCom1) && com.ComponentsId != oldCom1))
{
errorInfos += (i + 2) + "行,组件2[" + ds.Tables[0].Rows[i]["组件2"].ToString() + "]验证不一至;";
}
@ -1105,6 +1146,7 @@ namespace FineUIPro.Web.WeldingProcess.WeldingManage
}
}
string oldHeartNo1 = d.HeartNo1;
if (ds.Tables[0].Rows[i]["炉批号1"] != null && !string.IsNullOrEmpty(ds.Tables[0].Rows[i]["炉批号1"].ToString()))
{
if ((!string.IsNullOrEmpty(d.HeartNo1) && ds.Tables[0].Rows[i]["炉批号1"].ToString() != d.HeartNo1)
@ -1120,7 +1162,7 @@ namespace FineUIPro.Web.WeldingProcess.WeldingManage
if (ds.Tables[0].Rows[i]["炉批号2"] != null && !string.IsNullOrEmpty(ds.Tables[0].Rows[i]["炉批号2"].ToString()))
{
if ((!string.IsNullOrEmpty(d.HeartNo1) && ds.Tables[0].Rows[i]["炉批号2"].ToString() != d.HeartNo1)
if ((!string.IsNullOrEmpty(oldHeartNo1) && ds.Tables[0].Rows[i]["炉批号2"].ToString() != oldHeartNo1)
&& (!string.IsNullOrEmpty(d.HeartNo2) && ds.Tables[0].Rows[i]["炉批号2"].ToString() != d.HeartNo2))
{
errorInfos += (i + 2) + "行,炉批号2[" + ds.Tables[0].Rows[i]["炉批号2"].ToString() + "]验证不一至;";

View File

@ -340,23 +340,30 @@ namespace FineUIPro.Web.WeldingProcess.WeldingManage
var wps = BLL.WPQListServiceService.GetWPQById(item.WPQId);
// 验证焊工资质
if (item.BackingWelderId == item.CoverWelderId)
if (wps != null)
{
if (!wps.WelderIds.Contains(item.BackingWelderId))
if (item.BackingWelderId == item.CoverWelderId)
{
errorCheck += rowIndex + "行,焊工:" + item.BackingWelderCode + "无WPS焊接资质";
if (!wps.WelderIds.Contains(item.BackingWelderId))
{
errorCheck += rowIndex + "行,焊工:" + item.BackingWelderCode + "无WPS焊接资质";
}
}
else
{
if (!wps.WelderIds.Contains(item.BackingWelderId))
{
errorCheck += rowIndex + "行,焊工:" + item.BackingWelderCode + "无WPS焊接资质";
}
if (!wps.WelderIds.Contains(item.CoverWelderId))
{
errorCheck += rowIndex + "行,焊工:" + item.CoverWelderId + "无WPS焊接资质";
}
}
}
else
{
if (!wps.WelderIds.Contains(item.BackingWelderId))
{
errorCheck += rowIndex + "行,焊工:" + item.BackingWelderCode + "无WPS焊接资质";
}
if (!wps.WelderIds.Contains(item.CoverWelderId))
{
errorCheck += rowIndex + "行,焊工:" + item.CoverWelderId + "无WPS焊接资质";
}
errorCheck += rowIndex + "行WPS不能为空";
}
// 验证数据是否一至

View File

@ -37,6 +37,9 @@
<f:DropDownList ID="drpUnit" runat="server" Label="施工单位" LabelAlign="Right" Width="240px" EmptyText="请选择施工单位"
LabelWidth="90px">
</f:DropDownList>
<f:DropDownList ID="drpJointAttribute" Label="<%$ Resources:Lan,WeldingJointQuality %>" runat="server" LabelAlign="Right" Width="180px"
LabelWidth="90px">
</f:DropDownList>
<f:DropDownList ID="drpTeamGroup" runat="server" Label="班组" EnableCheckBoxSelect="true" EnableMultiSelect="true"
LabelAlign="Right" Width="160px" LabelWidth="80px">
</f:DropDownList>
@ -45,6 +48,15 @@
<f:ListItem Value="未审核" Text="未审核" />
<f:ListItem Value="已审核" Text="已审核" />
</f:DropDownList>
<f:ToolbarFill ID="ToolbarFill1" runat="server">
</f:ToolbarFill>
</Items>
</f:Toolbar>
</Toolbars>
<Toolbars>
<f:Toolbar ID="Toolbar2" Position="Top" runat="server" ToolbarAlign="Left">
<Items>
<f:DatePicker runat="server" Label="焊接日期" ID="txtStarTime" LabelAlign="Right"
LabelWidth="90px" Width="210px">
</f:DatePicker>
@ -53,15 +65,8 @@
<f:DatePicker runat="server" ID="txtEndTime" LabelAlign="Right" LabelWidth="80px"
Width="110px">
</f:DatePicker>
<f:ToolbarFill ID="ToolbarFill1" runat="server">
<f:ToolbarFill ID="ToolbarFill2" runat="server">
</f:ToolbarFill>
</Items>
</f:Toolbar>
</Toolbars>
<Toolbars>
<f:Toolbar ID="Toolbar2" Position="Top" runat="server" ToolbarAlign="Left">
<Items>
<f:Button ID="BtnAnalyse" Text="<%$ Resources:Lan,Statistics %>" Icon="ChartPie"
runat="server" OnClick="BtnAnalyse_Click">
</f:Button>

View File

@ -40,6 +40,13 @@ namespace FineUIPro.Web.WeldingProcess.WeldingReport
drpTeamGroup.DataSource = teamGroup;
drpTeamGroup.DataBind();
Funs.FineUIPleaseSelect(drpTeamGroup, "");
// 焊口属性
this.drpJointAttribute.DataTextField = "Text";
this.drpJointAttribute.DataValueField = "Value";
this.drpJointAttribute.DataSource = BLL.DropListService.HJGL_JointAttributeItem();
this.drpJointAttribute.DataBind();
Funs.FineUIPleaseSelect(this.drpJointAttribute, Resources.Lan.PleaseSelect);
}
}
@ -103,6 +110,11 @@ namespace FineUIPro.Web.WeldingProcess.WeldingReport
strSql += " AND pipeline.UnitId = @UnitId";
listStr.Add(new SqlParameter("@UnitId", drpUnit.SelectedValue));
}
if (this.drpJointAttribute.SelectedValue != Const._Null)
{
strSql += " AND weldJoint.JointAttribute = @JointAttribute";
listStr.Add(new SqlParameter("@JointAttribute", drpJointAttribute.SelectedValue));
}
if (this.drpTeamGroup.SelectedValueArray.Length>0)
{
string[] teamGroupList = drpTeamGroup.SelectedValueArray;
@ -251,261 +263,294 @@ namespace FineUIPro.Web.WeldingProcess.WeldingReport
}
//批量审核
protected void btnAuditAll_Click(object sender,EventArgs e)
protected void btnAuditAll_Click(object sender, EventArgs e)
{
var data = this.GetDataTable();
if (string.IsNullOrEmpty(txtStarTime.Text) && string.IsNullOrEmpty(txtEndTime.Text))
if (CommonService.GetAllButtonPowerList(this.CurrUser.LoginProjectId, this.CurrUser.UserId, Const.WeldDailyExportMenuId, Const.BtnAuditing))
{
ShowNotify("请按照日期选择要审核的日报!",MessageBoxIcon.Warning);
var data = this.GetDataTable();
if (string.IsNullOrEmpty(txtStarTime.Text) && string.IsNullOrEmpty(txtEndTime.Text))
{
ShowNotify("请按照日期选择要审核的日报!", MessageBoxIcon.Warning);
return;
}
List<string> ids = new List<string>();
foreach (DataRow dr in data.Rows)
{
ids.Add(dr["WeldJointId"].ToString());
}
ModifyAuditStatus(ids, 1);
this.BindGrid();
ShowNotify("批量审核成功!", MessageBoxIcon.Success);
}
else
{
ShowNotify(Resources.Lan.NoPrivilegePrompt, MessageBoxIcon.Warning);
return;
}
List<string> ids = new List<string>();
foreach (DataRow dr in data.Rows)
{
ids.Add(dr["WeldJointId"].ToString());
}
ModifyAuditStatus(ids, 1);
this.BindGrid();
ShowNotify("批量审核成功!", MessageBoxIcon.Success);
}
//审核
protected void btnAudit_Click(object sender,EventArgs e)
protected void btnAudit_Click(object sender, EventArgs e)
{
var listIds = GetWeldJointIdList();
if (listIds.Count == 0)
if (CommonService.GetAllButtonPowerList(this.CurrUser.LoginProjectId, this.CurrUser.UserId, Const.WeldDailyExportMenuId, Const.BtnAuditing))
{
ShowNotify("请选择要审核的焊接日报数据", MessageBoxIcon.Warning);
var listIds = GetWeldJointIdList();
if (listIds.Count == 0)
{
ShowNotify("请选择要审核的焊接日报数据", MessageBoxIcon.Warning);
return;
}
ModifyAuditStatus(listIds, 1);
this.BindGrid();
ShowNotify("批量审核成功!", MessageBoxIcon.Success);
}
else
{
ShowNotify(Resources.Lan.NoPrivilegePrompt, MessageBoxIcon.Warning);
return;
}
ModifyAuditStatus(listIds,1);
this.BindGrid();
ShowNotify("批量审核成功!", MessageBoxIcon.Success);
}
//取消审核
protected void btnCancel_Click(object sender, EventArgs e)
{
var listIds = GetWeldJointIdList();
if (listIds.Count == 0)
if (CommonService.GetAllButtonPowerList(this.CurrUser.LoginProjectId, this.CurrUser.UserId, Const.WeldDailyExportMenuId, Const.BtnCancelAuditing))
{
ShowNotify("请选择要取消审核的焊接日报数据", MessageBoxIcon.Warning);
var listIds = GetWeldJointIdList();
if (listIds.Count == 0)
{
ShowNotify("请选择要取消审核的焊接日报数据", MessageBoxIcon.Warning);
return;
}
ModifyAuditStatus(listIds, 0);
this.BindGrid();
ShowNotify("批量取消审核成功!", MessageBoxIcon.Success);
}
else
{
ShowNotify(Resources.Lan.NoPrivilegePrompt, MessageBoxIcon.Warning);
return;
}
ModifyAuditStatus(listIds,0);
this.BindGrid();
ShowNotify("批量取消审核成功!", MessageBoxIcon.Success);
}
//发送邮件
protected void btnSendEmail_Click(object sender,EventArgs e)
protected void btnSendEmail_Click(object sender, EventArgs e)
{
DataTable dt = GetDataTableAuditStatus();
if (dt.Rows.Count == 0)
if (CommonService.GetAllButtonPowerList(this.CurrUser.LoginProjectId, this.CurrUser.UserId, Const.WeldDailyExportMenuId, Const.BtnSendEmail))
{
ShowNotify("暂无已审核的数据!",MessageBoxIcon.Warning);
DataTable dt = GetDataTableAuditStatus();
if (dt.Rows.Count == 0)
{
ShowNotify("暂无已审核的数据!", MessageBoxIcon.Warning);
return;
}
string rootPath = Server.MapPath("~/") + Const.ExcelUrl;
//模板文件
string TempletFileName = rootPath + "WeldDailyExport.xlsx";
//导出文件
string filePath = rootPath + DateTime.Now.ToString("yyyyMMddhhmmss") + "\\";
if (!Directory.Exists(filePath))
{
Directory.CreateDirectory(filePath);
}
string ReportFileName = filePath + $"焊接日报_{DateTime.Now.ToString("yyyyMMddhhmmss")}.xlsx";
try
{
FileStream file = new FileStream(TempletFileName, FileMode.Open, FileAccess.Read);
XSSFWorkbook hssfworkbook = new XSSFWorkbook(file);
hssfworkbook.RemoveAt(0);
XSSFSheet ws = (XSSFSheet)hssfworkbook.CreateSheet("Sheet1");
int rowIndex = 0;
var style = CommonPrint.SetExcelStyle(hssfworkbook, BorderStyle.None, BorderStyle.None, BorderStyle.None, BorderStyle.None, VerticalAlignment.Center, NPOI.SS.UserModel.HorizontalAlignment.Center, 20, true, true, "Arial");
#region
ws = ExcelCreateRow(ws, hssfworkbook, rowIndex, rowIndex, style, 0, 19, true);
ws.AddMergedRegion(new NPOI.SS.Util.CellRangeAddress(rowIndex, rowIndex, 0, 19));
//设置表头文字
ws.GetRow(rowIndex).GetCell(0).SetCellValue("焊接日报表\nWelding Daily Report");
var style2 = CommonPrint.SetExcelStyle(hssfworkbook, BorderStyle.Thin, BorderStyle.Thin, BorderStyle.Thin, BorderStyle.Thin, VerticalAlignment.Center, NPOI.SS.UserModel.HorizontalAlignment.Center, 9, true, true, "Arial");
ws = ExcelCreateRow(ws, hssfworkbook, rowIndex + 1, rowIndex + 2, style2, 0, 19, true);
//设置表格表头
ws.GetRow(rowIndex + 1).GetCell(0).SetCellValue("序号");
ws.GetRow(rowIndex + 1).GetCell(1).SetCellValue("管线号-页码");
ws.GetRow(rowIndex + 1).GetCell(2).SetCellValue("图纸版本");
ws.GetRow(rowIndex + 1).GetCell(3).SetCellValue("焊口号");
ws.GetRow(rowIndex + 1).GetCell(4).SetCellValue("焊接形式");
ws.GetRow(rowIndex + 1).GetCell(5).SetCellValue("焊接位置");
ws.GetRow(rowIndex + 1).GetCell(6).SetCellValue("寸径");
ws.GetRow(rowIndex + 1).GetCell(7).SetCellValue("规格");
ws.GetRow(rowIndex + 1).GetCell(8).SetCellValue("焊工号");
ws.GetRow(rowIndex + 1).GetCell(9).SetCellValue("组对部件1");
ws.GetRow(rowIndex + 1).GetCell(10).SetCellValue("组件1材质");
ws.GetRow(rowIndex + 1).GetCell(11).SetCellValue("组件1炉批号");
ws.GetRow(rowIndex + 1).GetCell(12).SetCellValue("组对部件2");
ws.GetRow(rowIndex + 1).GetCell(13).SetCellValue("组件2材质");
ws.GetRow(rowIndex + 1).GetCell(14).SetCellValue("组件2炉批号");
ws.GetRow(rowIndex + 1).GetCell(15).SetCellValue("焊接方法");
ws.GetRow(rowIndex + 1).GetCell(16).SetCellValue("组对");
ws.GetRow(rowIndex + 1).GetCell(17).SetCellValue("外观");
ws.GetRow(rowIndex + 1).GetCell(18).SetCellValue("焊接日期");
ws.GetRow(rowIndex + 1).GetCell(19).SetCellValue("备注");
ws.GetRow(rowIndex + 2).GetCell(0).SetCellValue("S/N");
ws.GetRow(rowIndex + 2).GetCell(1).SetCellValue("LineNo.-PageNo.");
ws.GetRow(rowIndex + 2).GetCell(2).SetCellValue("Drawing\nRev");
ws.GetRow(rowIndex + 2).GetCell(3).SetCellValue("Joint\nNo.");
ws.GetRow(rowIndex + 2).GetCell(4).SetCellValue("JointType");
ws.GetRow(rowIndex + 2).GetCell(5).SetCellValue("Welding\nLocation");
ws.GetRow(rowIndex + 2).GetCell(6).SetCellValue("Inch");
ws.GetRow(rowIndex + 2).GetCell(7).SetCellValue("Size");
ws.GetRow(rowIndex + 2).GetCell(8).SetCellValue("Welder\nNo.");
ws.GetRow(rowIndex + 2).GetCell(9).SetCellValue("Part(1)");
ws.GetRow(rowIndex + 2).GetCell(10).SetCellValue("Material(1)");
ws.GetRow(rowIndex + 2).GetCell(11).SetCellValue("Heat\nNo.(1)");
ws.GetRow(rowIndex + 2).GetCell(12).SetCellValue("Part(2)");
ws.GetRow(rowIndex + 2).GetCell(13).SetCellValue("Material(2)");
ws.GetRow(rowIndex + 2).GetCell(14).SetCellValue("Heat\nNo.(2)");
ws.GetRow(rowIndex + 2).GetCell(15).SetCellValue("Weld\nProcess");
ws.GetRow(rowIndex + 2).GetCell(16).SetCellValue("Fit\nUp");
ws.GetRow(rowIndex + 2).GetCell(17).SetCellValue("VT");
ws.GetRow(rowIndex + 2).GetCell(18).SetCellValue("Welding\nDate");
ws.GetRow(rowIndex + 2).GetCell(19).SetCellValue("Remark");
ws.GetRow(rowIndex).Height = 69 * 20;
ws.GetRow(rowIndex + 1).Height = 15 * 20;
ws.GetRow(rowIndex + 2).Height = 30 * 20;
ws.SetColumnWidth(0, 5 * 256);
ws.SetColumnWidth(1, (int)(21.67 * 256));
ws.SetColumnWidth(2, (int)(9.78 * 256));
ws.SetColumnWidth(3, (int)(5.33 * 256));
ws.SetColumnWidth(4, (int)(7.67 * 256));
ws.SetColumnWidth(5, (int)(8.33 * 256));
ws.SetColumnWidth(6, (int)(7 * 256));
ws.SetColumnWidth(7, (int)(10.82 * 256));
ws.SetColumnWidth(8, (int)(8.33 * 256));
ws.SetColumnWidth(9, (int)(8.40 * 256));
ws.SetColumnWidth(10, (int)(15.67 * 256));
ws.SetColumnWidth(11, (int)(12 * 256));
ws.SetColumnWidth(12, (int)(8.22 * 256));
ws.SetColumnWidth(13, (int)(16.33 * 256));
ws.SetColumnWidth(14, (int)(11.45 * 256));
ws.SetColumnWidth(15, (int)(11.00 * 256));
ws.SetColumnWidth(16, (int)(4.00 * 256));
ws.SetColumnWidth(17, (int)(4.00 * 256));
ws.SetColumnWidth(18, (int)(9.00 * 256));
ws.SetColumnWidth(19, (int)(7 * 256));
#endregion
const int pageSize = 65;
var style3 = CommonPrint.SetExcelStyle(hssfworkbook, BorderStyle.Thin, BorderStyle.Thin, BorderStyle.Thin, BorderStyle.Thin, VerticalAlignment.Center, NPOI.SS.UserModel.HorizontalAlignment.Center, 9, false, false, "sans-serif");
ws = ExcelCreateRow(ws, hssfworkbook, rowIndex + 3, dt.Rows.Count + 2, style3, 0, 19);
for (int i = 0; i < dt.Rows.Count; i++)
{
int startIndex = (i + 3);
ws.GetRow(startIndex).GetCell(0).SetCellValue(i + 1);
ws.GetRow(startIndex).GetCell(1).SetCellValue(dt.Rows[i]["SingleNumber"].ToString());
ws.GetRow(startIndex).GetCell(2).SetCellValue(dt.Rows[i]["DrawingsNum"].ToString());
ws.GetRow(startIndex).GetCell(3).SetCellValue(dt.Rows[i]["WeldJointCode"].ToString());
ws.GetRow(startIndex).GetCell(4).SetCellValue(dt.Rows[i]["WeldTypeCode"].ToString());
ws.GetRow(startIndex).GetCell(5).SetCellValue(dt.Rows[i]["WeldingLocationCode"].ToString());
ws.GetRow(startIndex).GetCell(6).SetCellValue(dt.Rows[i]["Size"].ToString());
ws.GetRow(startIndex).GetCell(7).SetCellValue(dt.Rows[i]["Specification"].ToString());
ws.GetRow(startIndex).GetCell(8).SetCellValue(dt.Rows[i]["WelderCode"].ToString());
ws.GetRow(startIndex).GetCell(9).SetCellValue(dt.Rows[i]["ComponentsName1"].ToString());
ws.GetRow(startIndex).GetCell(10).SetCellValue(dt.Rows[i]["MaterialCode1"].ToString());
ws.GetRow(startIndex).GetCell(11).SetCellValue(dt.Rows[i]["HeartNo1"].ToString());
ws.GetRow(startIndex).GetCell(12).SetCellValue(dt.Rows[i]["ComponentsName2"].ToString());
ws.GetRow(startIndex).GetCell(13).SetCellValue(dt.Rows[i]["MaterialCode2"].ToString());
ws.GetRow(startIndex).GetCell(14).SetCellValue(dt.Rows[i]["HeartNo2"].ToString());
ws.GetRow(startIndex).GetCell(15).SetCellValue(dt.Rows[i]["WeldingMethodName"].ToString());
ws.GetRow(startIndex).GetCell(16).SetCellValue("ACC");
ws.GetRow(startIndex).GetCell(17).SetCellValue("ACC");
ws.GetRow(startIndex).GetCell(18).SetCellValue(dt.Rows[i]["WeldingDate"].ToString());
ws.GetRow(startIndex).GetCell(19).SetCellValue(dt.Rows[i]["Remark"].ToString());
ws.GetRow(startIndex).Height = 10 * 20;
if (startIndex == pageSize)
{
ws.SetRowBreak(startIndex);
startIndex += pageSize;
}
}
if (dt.Rows.Count > 0)
{
string weldingDate = string.Empty;
if (txtStarTime.Text == txtEndTime.Text)
{
weldingDate = txtStarTime.Text;
}
else
{
weldingDate = txtStarTime.Text + "-" + txtEndTime.Text;
}
var style4 = CommonPrint.SetExcelStyle(hssfworkbook, BorderStyle.Thin, BorderStyle.Thin, BorderStyle.Thin, BorderStyle.Thin, VerticalAlignment.Center, NPOI.SS.UserModel.HorizontalAlignment.Center, 9, true, true, "Arial");
ws = ExcelCreateRow(ws, hssfworkbook, dt.Rows.Count + 3, dt.Rows.Count + 3, style4, 0, 19);
var distinctPipelineCode = dt.AsEnumerable().GroupBy(row => row.Field<string>("PipelineCode")).Select(group => group.First());
var distinctWelder = dt.AsEnumerable().GroupBy(row => row.Field<string>("WelderCode")).Select(group => group.First());
decimal sumSize = decimal.Parse(dt.Compute("sum(Size)", "").ToString());
ws.GetRow(dt.Rows.Count + 3).GetCell(0).SetCellValue("Total");
ws.GetRow(dt.Rows.Count + 3).GetCell(1).SetCellValue($"{distinctPipelineCode.Count().ToString()}");
ws.GetRow(dt.Rows.Count + 3).GetCell(3).SetCellValue($"{dt.Rows.Count}");
ws.GetRow(dt.Rows.Count + 3).GetCell(6).SetCellValue($"{sumSize}");
ws.GetRow(dt.Rows.Count + 3).GetCell(8).SetCellValue($"{distinctWelder.Count().ToString()}");
ws.GetRow(dt.Rows.Count + 3).Height = 20 * 20;
}
#region
IFooter footer = ws.Footer;
string str = " CC7: 监理: Worley:";
str += "\n\n第 &P 页,共 &N 页";
footer.Center = str;
#endregion
ws.FitToPage = true;
ws.PrintSetup.FitWidth = 1;
ws.PrintSetup.FitHeight = short.MaxValue;
ws.SetMargin(MarginType.LeftMargin, (double)1.2 / 3);
ws.SetMargin(MarginType.RightMargin, (double)0.5 / 3);
ws.SetMargin(MarginType.TopMargin, (double)1.8 / 3);
ws.SetMargin(MarginType.BottomMargin, (double)2.9 / 3);
ws.PrintSetup.Landscape = true;
ws.ForceFormulaRecalculation = true;
ws.PrintSetup.PaperSize = (int)PaperSize.A4_Small;
ws.RepeatingRows = new NPOI.SS.Util.CellRangeAddress(0, 2, 0, 19);
using (FileStream filess = System.IO.File.OpenWrite(ReportFileName))
{
hssfworkbook.Write(filess);
}
hssfworkbook.Close();
this.GetEmailTemplateAndSendEmail(ReportFileName);
File.Delete(ReportFileName);
ShowNotify("焊接日报发送成功!", MessageBoxIcon.Success);
}
catch (Exception ex)
{
ShowNotify($"发送失败,原因:{ex.Message}", MessageBoxIcon.Error);
}
}
else
{
ShowNotify(Resources.Lan.NoPrivilegePrompt, MessageBoxIcon.Warning);
return;
}
string rootPath = Server.MapPath("~/") + Const.ExcelUrl;
//模板文件
string TempletFileName = rootPath + "WeldDailyExport.xlsx";
//导出文件
string filePath = rootPath + DateTime.Now.ToString("yyyyMMddhhmmss") + "\\";
if (!Directory.Exists(filePath))
{
Directory.CreateDirectory(filePath);
}
string ReportFileName = filePath + $"焊接日报_{DateTime.Now.ToString("yyyyMMddhhmmss")}.xlsx";
try
{
FileStream file = new FileStream(TempletFileName, FileMode.Open, FileAccess.Read);
XSSFWorkbook hssfworkbook = new XSSFWorkbook(file);
hssfworkbook.RemoveAt(0);
XSSFSheet ws = (XSSFSheet)hssfworkbook.CreateSheet("Sheet1");
int rowIndex = 0;
var style = CommonPrint.SetExcelStyle(hssfworkbook, BorderStyle.None, BorderStyle.None, BorderStyle.None, BorderStyle.None, VerticalAlignment.Center, NPOI.SS.UserModel.HorizontalAlignment.Center, 20, true, true, "微软雅黑");
#region
ws = ExcelCreateRow(ws, hssfworkbook, rowIndex, rowIndex, style, 0, 19, true);
ws.AddMergedRegion(new NPOI.SS.Util.CellRangeAddress(rowIndex, rowIndex, 0, 19));
//设置表头文字
ws.GetRow(rowIndex).GetCell(0).SetCellValue("焊接日报表\nWelding Daily Report");
var style2 = CommonPrint.SetExcelStyle(hssfworkbook, BorderStyle.Thin, BorderStyle.Thin, BorderStyle.Thin, BorderStyle.Thin, VerticalAlignment.Center, NPOI.SS.UserModel.HorizontalAlignment.Center, 9, true, true, "Arial");
ws = ExcelCreateRow(ws, hssfworkbook, rowIndex + 1, rowIndex + 2, style2, 0, 19, true);
//设置表格表头
ws.GetRow(rowIndex + 1).GetCell(0).SetCellValue("序号");
ws.GetRow(rowIndex + 1).GetCell(1).SetCellValue("管线号-页码");
ws.GetRow(rowIndex + 1).GetCell(2).SetCellValue("图纸版本");
ws.GetRow(rowIndex + 1).GetCell(3).SetCellValue("焊口号");
ws.GetRow(rowIndex + 1).GetCell(4).SetCellValue("焊接形式");
ws.GetRow(rowIndex + 1).GetCell(5).SetCellValue("焊接位置");
ws.GetRow(rowIndex + 1).GetCell(6).SetCellValue("寸径");
ws.GetRow(rowIndex + 1).GetCell(7).SetCellValue("规格");
ws.GetRow(rowIndex + 1).GetCell(8).SetCellValue("焊工号");
ws.GetRow(rowIndex + 1).GetCell(9).SetCellValue("组对部件1");
ws.GetRow(rowIndex + 1).GetCell(10).SetCellValue("组件1材质");
ws.GetRow(rowIndex + 1).GetCell(11).SetCellValue("组件1炉批号");
ws.GetRow(rowIndex + 1).GetCell(12).SetCellValue("组对部件2");
ws.GetRow(rowIndex + 1).GetCell(13).SetCellValue("组件2材质");
ws.GetRow(rowIndex + 1).GetCell(14).SetCellValue("组件2炉批号");
ws.GetRow(rowIndex + 1).GetCell(15).SetCellValue("焊接方法");
ws.GetRow(rowIndex + 1).GetCell(16).SetCellValue("组对");
ws.GetRow(rowIndex + 1).GetCell(17).SetCellValue("外观");
ws.GetRow(rowIndex + 1).GetCell(18).SetCellValue("焊接日期");
ws.GetRow(rowIndex + 1).GetCell(19).SetCellValue("备注");
ws.GetRow(rowIndex + 2).GetCell(0).SetCellValue("S/N");
ws.GetRow(rowIndex + 2).GetCell(1).SetCellValue("LineNo.-PageNo.");
ws.GetRow(rowIndex + 2).GetCell(2).SetCellValue("Drawing\nRev");
ws.GetRow(rowIndex + 2).GetCell(3).SetCellValue("Joint\nNo.");
ws.GetRow(rowIndex + 2).GetCell(4).SetCellValue("JointType");
ws.GetRow(rowIndex + 2).GetCell(5).SetCellValue("Welding\nLocation");
ws.GetRow(rowIndex + 2).GetCell(6).SetCellValue("Inch");
ws.GetRow(rowIndex + 2).GetCell(7).SetCellValue("Size");
ws.GetRow(rowIndex + 2).GetCell(8).SetCellValue("Welder\nNo.");
ws.GetRow(rowIndex + 2).GetCell(9).SetCellValue("Part(1)");
ws.GetRow(rowIndex + 2).GetCell(10).SetCellValue("Material(1)");
ws.GetRow(rowIndex + 2).GetCell(11).SetCellValue("Heat\nNo.(1)");
ws.GetRow(rowIndex + 2).GetCell(12).SetCellValue("Part(2)");
ws.GetRow(rowIndex + 2).GetCell(13).SetCellValue("Material(2)");
ws.GetRow(rowIndex + 2).GetCell(14).SetCellValue("Heat\nNo.(2)");
ws.GetRow(rowIndex + 2).GetCell(15).SetCellValue("Weld\nProcess");
ws.GetRow(rowIndex + 2).GetCell(16).SetCellValue("Fit\nUp");
ws.GetRow(rowIndex + 2).GetCell(17).SetCellValue("VT");
ws.GetRow(rowIndex + 2).GetCell(18).SetCellValue("Welding\nDate");
ws.GetRow(rowIndex + 2).GetCell(19).SetCellValue("Remark");
ws.GetRow(rowIndex).Height = 69 * 20;
ws.GetRow(rowIndex + 1).Height = 15 * 20;
ws.GetRow(rowIndex + 2).Height = 30 * 20;
ws.SetColumnWidth(0, 5 * 256);
ws.SetColumnWidth(1, (int)(21.67 * 256));
ws.SetColumnWidth(2, (int)(9.78 * 256));
ws.SetColumnWidth(3, (int)(5.33 * 256));
ws.SetColumnWidth(4, (int)(7.67 * 256));
ws.SetColumnWidth(5, (int)(8.33 * 256));
ws.SetColumnWidth(6, (int)(7 * 256));
ws.SetColumnWidth(7, (int)(10.82 * 256));
ws.SetColumnWidth(8, (int)(8.33 * 256));
ws.SetColumnWidth(9, (int)(8.40 * 256));
ws.SetColumnWidth(10, (int)(15.67 * 256));
ws.SetColumnWidth(11, (int)(12 * 256));
ws.SetColumnWidth(12, (int)(8.22 * 256));
ws.SetColumnWidth(13, (int)(16.33 * 256));
ws.SetColumnWidth(14, (int)(11.45 * 256));
ws.SetColumnWidth(15, (int)(11.00 * 256));
ws.SetColumnWidth(16, (int)(4.00 * 256));
ws.SetColumnWidth(17, (int)(4.00 * 256));
ws.SetColumnWidth(18, (int)(9.00 * 256));
ws.SetColumnWidth(19, (int)(7 * 256));
#endregion
const int pageSize = 65;
var style3 = CommonPrint.SetExcelStyle(hssfworkbook, BorderStyle.Thin, BorderStyle.Thin, BorderStyle.Thin, BorderStyle.Thin, VerticalAlignment.Center, NPOI.SS.UserModel.HorizontalAlignment.Center, 9, false, false, "sans-serif");
ws = ExcelCreateRow(ws, hssfworkbook, rowIndex + 3, dt.Rows.Count + 2, style3, 0, 19);
for (int i = 0; i < dt.Rows.Count; i++)
{
int startIndex = (i + 3);
ws.GetRow(startIndex).GetCell(0).SetCellValue(i + 1);
ws.GetRow(startIndex).GetCell(1).SetCellValue(dt.Rows[i]["SingleNumber"].ToString());
ws.GetRow(startIndex).GetCell(2).SetCellValue(dt.Rows[i]["DrawingsNum"].ToString());
ws.GetRow(startIndex).GetCell(3).SetCellValue(dt.Rows[i]["WeldJointCode"].ToString());
ws.GetRow(startIndex).GetCell(4).SetCellValue(dt.Rows[i]["WeldTypeCode"].ToString());
ws.GetRow(startIndex).GetCell(5).SetCellValue(dt.Rows[i]["WeldingLocationCode"].ToString());
ws.GetRow(startIndex).GetCell(6).SetCellValue(dt.Rows[i]["Size"].ToString());
ws.GetRow(startIndex).GetCell(7).SetCellValue(dt.Rows[i]["Specification"].ToString());
ws.GetRow(startIndex).GetCell(8).SetCellValue(dt.Rows[i]["WelderCode"].ToString());
ws.GetRow(startIndex).GetCell(9).SetCellValue(dt.Rows[i]["ComponentsName1"].ToString());
ws.GetRow(startIndex).GetCell(10).SetCellValue(dt.Rows[i]["MaterialCode1"].ToString());
ws.GetRow(startIndex).GetCell(11).SetCellValue(dt.Rows[i]["HeartNo1"].ToString());
ws.GetRow(startIndex).GetCell(12).SetCellValue(dt.Rows[i]["ComponentsName2"].ToString());
ws.GetRow(startIndex).GetCell(13).SetCellValue(dt.Rows[i]["MaterialCode2"].ToString());
ws.GetRow(startIndex).GetCell(14).SetCellValue(dt.Rows[i]["HeartNo2"].ToString());
ws.GetRow(startIndex).GetCell(15).SetCellValue(dt.Rows[i]["WeldingMethodName"].ToString());
ws.GetRow(startIndex).GetCell(16).SetCellValue("ACC");
ws.GetRow(startIndex).GetCell(17).SetCellValue("ACC");
ws.GetRow(startIndex).GetCell(18).SetCellValue(dt.Rows[i]["WeldingDate"].ToString());
ws.GetRow(startIndex).GetCell(19).SetCellValue(dt.Rows[i]["Remark"].ToString());
ws.GetRow(startIndex).Height = 10 * 20;
if (startIndex == pageSize)
{
ws.SetRowBreak(startIndex);
startIndex += pageSize;
}
}
if (dt.Rows.Count > 0)
{
string weldingDate = string.Empty;
if (txtStarTime.Text == txtEndTime.Text)
{
weldingDate = txtStarTime.Text;
}
else
{
weldingDate = txtStarTime.Text + "-" + txtEndTime.Text;
}
var style4 = CommonPrint.SetExcelStyle(hssfworkbook, BorderStyle.Thin, BorderStyle.Thin, BorderStyle.Thin, BorderStyle.Thin, VerticalAlignment.Center, NPOI.SS.UserModel.HorizontalAlignment.Center, 9, true, true, "Arial");
ws = ExcelCreateRow(ws, hssfworkbook, dt.Rows.Count + 3, dt.Rows.Count + 3, style4, 0, 19);
var distinctPipelineCode = dt.AsEnumerable().GroupBy(row => row.Field<string>("PipelineCode")).Select(group => group.First());
var distinctWelder = dt.AsEnumerable().GroupBy(row => row.Field<string>("WelderCode")).Select(group => group.First());
decimal sumSize = decimal.Parse(dt.Compute("sum(Size)", "").ToString());
ws.GetRow(dt.Rows.Count + 3).GetCell(0).SetCellValue("Total");
ws.GetRow(dt.Rows.Count + 3).GetCell(1).SetCellValue($"{distinctPipelineCode.Count().ToString()}");
ws.GetRow(dt.Rows.Count + 3).GetCell(3).SetCellValue($"{dt.Rows.Count}");
ws.GetRow(dt.Rows.Count + 3).GetCell(6).SetCellValue($"{sumSize}");
ws.GetRow(dt.Rows.Count + 3).GetCell(8).SetCellValue($"{distinctWelder.Count().ToString()}");
ws.GetRow(dt.Rows.Count + 3).Height = 20 * 20;
}
#region
IFooter footer = ws.Footer;
string str = " CC7: 监理: Worley:";
str += "\n\n第 &P 页,共 &N 页";
footer.Center = str;
#endregion
ws.FitToPage = true;
ws.PrintSetup.FitWidth = 1;
ws.PrintSetup.FitHeight = short.MaxValue;
ws.SetMargin(MarginType.LeftMargin, (double)1.2 / 3);
ws.SetMargin(MarginType.RightMargin, (double)0.5 / 3);
ws.SetMargin(MarginType.TopMargin, (double)1.8 / 3);
ws.SetMargin(MarginType.BottomMargin, (double)2.9 / 3);
ws.PrintSetup.Landscape = true;
ws.ForceFormulaRecalculation = true;
ws.PrintSetup.PaperSize = (int)PaperSize.A4_Small;
ws.RepeatingRows = new NPOI.SS.Util.CellRangeAddress(0, 2, 0, 19);
using (FileStream filess = System.IO.File.OpenWrite(ReportFileName))
{
hssfworkbook.Write(filess);
}
hssfworkbook.Close();
this.GetEmailTemplateAndSendEmail(ReportFileName);
File.Delete(ReportFileName);
ShowNotify("焊接日报发送成功!", MessageBoxIcon.Success);
}
catch (Exception ex)
{
ShowNotify($"发送失败,原因:{ex.Message}", MessageBoxIcon.Error);
}
}
protected void Window1_Close(object sender, EventArgs e)
{
@ -580,7 +625,7 @@ namespace FineUIPro.Web.WeldingProcess.WeldingReport
XSSFSheet ws = (XSSFSheet)hssfworkbook.CreateSheet("Sheet1");
int rowIndex = 0;
var style = CommonPrint.SetExcelStyle(hssfworkbook, BorderStyle.None, BorderStyle.None, BorderStyle.None, BorderStyle.None, VerticalAlignment.Center, NPOI.SS.UserModel.HorizontalAlignment.Center, 20, true, true, "微软雅黑");
var style = CommonPrint.SetExcelStyle(hssfworkbook, BorderStyle.None, BorderStyle.None, BorderStyle.None, BorderStyle.None, VerticalAlignment.Center, NPOI.SS.UserModel.HorizontalAlignment.Center, 20, true, true, "Arial");
#region
ws = ExcelCreateRow(ws, hssfworkbook, rowIndex, rowIndex, style, 0, 19, true);

View File

@ -86,6 +86,15 @@ namespace FineUIPro.Web.WeldingProcess.WeldingReport
/// </remarks>
protected global::FineUIPro.DropDownList drpUnit;
/// <summary>
/// drpJointAttribute 控件。
/// </summary>
/// <remarks>
/// 自动生成的字段。
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
/// </remarks>
protected global::FineUIPro.DropDownList drpJointAttribute;
/// <summary>
/// drpTeamGroup 控件。
/// </summary>
@ -104,6 +113,24 @@ namespace FineUIPro.Web.WeldingProcess.WeldingReport
/// </remarks>
protected global::FineUIPro.DropDownList drpAudit;
/// <summary>
/// ToolbarFill1 控件。
/// </summary>
/// <remarks>
/// 自动生成的字段。
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
/// </remarks>
protected global::FineUIPro.ToolbarFill ToolbarFill1;
/// <summary>
/// Toolbar2 控件。
/// </summary>
/// <remarks>
/// 自动生成的字段。
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
/// </remarks>
protected global::FineUIPro.Toolbar Toolbar2;
/// <summary>
/// txtStarTime 控件。
/// </summary>
@ -132,22 +159,13 @@ namespace FineUIPro.Web.WeldingProcess.WeldingReport
protected global::FineUIPro.DatePicker txtEndTime;
/// <summary>
/// ToolbarFill1 控件。
/// ToolbarFill2 控件。
/// </summary>
/// <remarks>
/// 自动生成的字段。
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
/// </remarks>
protected global::FineUIPro.ToolbarFill ToolbarFill1;
/// <summary>
/// Toolbar2 控件。
/// </summary>
/// <remarks>
/// 自动生成的字段。
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
/// </remarks>
protected global::FineUIPro.Toolbar Toolbar2;
protected global::FineUIPro.ToolbarFill ToolbarFill2;
/// <summary>
/// BtnAnalyse 控件。

View File

@ -29,6 +29,10 @@ namespace Model
#region
partial void OnCreated();
partial void OnCreated()
{
this.CommandTimeout = 600;
}
partial void InsertAttachFile(AttachFile instance);
partial void UpdateAttachFile(AttachFile instance);
partial void DeleteAttachFile(AttachFile instance);
@ -11772,7 +11776,7 @@ namespace Model
private string _RepairRecordId;
private System.Nullable<int> _BatchOrder;
private System.Nullable<bool> _BatchOrder;
private System.Nullable<bool> _IsCompletedPoint;
@ -11782,6 +11786,8 @@ namespace Model
private string _QTAudit;
private System.Nullable<System.DateTime> _EnterDate;
private EntitySet<Batch_BatchTrustItem> _Batch_BatchTrustItem;
private EntityRef<Pipeline_WeldJoint> _Pipeline_WeldJoint;
@ -11832,7 +11838,7 @@ namespace Model
partial void OnIsAuditChanged();
partial void OnRepairRecordIdChanging(string value);
partial void OnRepairRecordIdChanged();
partial void OnBatchOrderChanging(System.Nullable<int> value);
partial void OnBatchOrderChanging(System.Nullable<bool> value);
partial void OnBatchOrderChanged();
partial void OnIsCompletedPointChanging(System.Nullable<bool> value);
partial void OnIsCompletedPointChanged();
@ -11842,6 +11848,8 @@ namespace Model
partial void OnGLGSAuditChanged();
partial void OnQTAuditChanging(string value);
partial void OnQTAuditChanged();
partial void OnEnterDateChanging(System.Nullable<System.DateTime> value);
partial void OnEnterDateChanged();
#endregion
public Batch_PointBatchItem()
@ -12260,8 +12268,8 @@ namespace Model
}
}
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_BatchOrder", DbType="Int")]
public System.Nullable<int> BatchOrder
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_BatchOrder", DbType="Bit")]
public System.Nullable<bool> BatchOrder
{
get
{
@ -12360,6 +12368,26 @@ namespace Model
}
}
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_EnterDate", DbType="DateTime")]
public System.Nullable<System.DateTime> EnterDate
{
get
{
return this._EnterDate;
}
set
{
if ((this._EnterDate != value))
{
this.OnEnterDateChanging(value);
this.SendPropertyChanging();
this._EnterDate = value;
this.SendPropertyChanged("EnterDate");
this.OnEnterDateChanged();
}
}
}
[global::System.Data.Linq.Mapping.AssociationAttribute(Name="FK_Batch_BatchTrustItem_Batch_PointBatchItem", Storage="_Batch_BatchTrustItem", ThisKey="PointBatchItemId", OtherKey="PointBatchItemId", DeleteRule="NO ACTION")]
public EntitySet<Batch_BatchTrustItem> Batch_BatchTrustItem
{

View File

@ -8,7 +8,7 @@
<IISExpressWindowsAuthentication />
<IISExpressUseClassicPipelineMode />
<UseGlobalApplicationHostFile />
<LastActiveSolutionConfig>Debug|Any CPU</LastActiveSolutionConfig>
<LastActiveSolutionConfig>Release|Any CPU</LastActiveSolutionConfig>
<NameOfLastUsedPublishProfile>FolderProfile</NameOfLastUsedPublishProfile>
</PropertyGroup>
<ProjectExtensions>