2023-06-29

This commit is contained in:
李鹏飞 2023-06-29 21:45:06 +08:00
parent 11313e97aa
commit 06572131a7
9 changed files with 1201 additions and 73 deletions

View File

@ -102,6 +102,7 @@
xhr.open(method, url, true); xhr.open(method, url, true);
if (method === "POST") if (method === "POST")
xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded");
xhr.setRequestHeader("token", "<%=UserId%>");
xhr.send(queryString); xhr.send(queryString);
xhr.onreadystatechange = function () { xhr.onreadystatechange = function () {
if (xhr.readyState === 4) { if (xhr.readyState === 4) {
@ -128,13 +129,12 @@
ajax({ ajax({
url: 'https://sggl.sedin.com.cn/sgglapi/api/FileUpload/DownloadDocument', url: 'https://sggl.sedin.com.cn/sgglapi/api/FileUpload/DownloadDocument',
type: 'post', type: 'post',
data: { data: {
'UrlStr': url, 'UrlStr': url,
'PCUrl': '<%=PCUrl%>', 'PCUrl': '<%=PCUrl%>',
}, },
headers: {
'token': '<%=UserId%>'
},
dataType: 'json', dataType: 'json',
async: false, async: false,
success: function (json) { success: function (json) {
@ -142,11 +142,11 @@
if (json.code == 1 || json.code == '1') { if (json.code == 1 || json.code == '1') {
alert('保存成功'); alert('保存成功');
} else { } else {
this.error(json, '保存失败'); this.error(json);
} }
}, },
error: function (json, msg) { error: function (json) {
alert(+msg); alert(json.message);
} }
}); });
} }

View File

@ -0,0 +1,344 @@
<?xml version="1.0" encoding="utf-8"?>
<Report ScriptLanguage="CSharp" ReportInfo.Created="12/29/2021 10:56:08" ReportInfo.Modified="06/29/2023 17:42:46" ReportInfo.CreatorVersion="2017.1.16.0">
<ScriptText>using System;
using System.Collections;
using System.Collections.Generic;
using System.ComponentModel;
using System.Windows.Forms;
using System.Drawing;
using System.Data;
using FastReport;
using FastReport.Data;
using FastReport.Dialog;
using FastReport.Barcode;
using FastReport.Table;
using FastReport.Utils;
namespace FastReport
{
public class ReportScript
{
private void Table4_ManualBuild(object sender, EventArgs e)
{
DataSourceBase rowData = Report.GetDataSource(&quot;Table1&quot;);
// init the data source
rowData.Init();
// print the first table row - it is a header
Table4.PrintRow(0);
// each PrintRow call must be followed by either PrintColumn or PrintColumns call
// to print cells on the row
Table4.PrintColumns();
// now enumerate the data source and print the table body
// print the table body
Table4.PrintRow(1);
Table4.PrintColumns();
Table4.PrintRow(2);
Table4.PrintColumns();
Table4.PrintRow(3);
Table4.PrintColumns();
Table4.PrintRow(4);
Table4.PrintColumns();
Table4.PrintRow(5);
Table4.PrintColumns();
// go next data source row
rowData.Next();
}
private void Table5_ManualBuild(object sender, EventArgs e)
{
Table5.PrintRow(0);
Table5.PrintColumns();
Table5.PrintRow(1);
Table5.PrintColumns();
}
private int x;
private void Tabel_Data_ManualBuild(object sender, EventArgs e)
{
DataSourceBase rowData = Report.GetDataSource(&quot;Data&quot;);
// init the data source
rowData.Init();
// print the first table row - it is a header
Tabel_Data.PrintRow(0);
// each PrintRow call must be followed by either PrintColumn or PrintColumns call
// to print cells on the row
Tabel_Data.PrintColumns();
x=0;
// now enumerate the data source and print the table body
while (rowData.HasMoreRows)
{
x++;
// print the table body
Tabel_Data.PrintRow(1);
Tabel_Data.PrintColumns();
// go next data source row
rowData.Next();
}
}
}
}
</ScriptText>
<Dictionary>
<MsSqlDataConnection Name="Connection" ConnectionString="rijcmlqvJIqZbrmqGn7L0P56UFhaUHihKXxbhpqie4wmZgM2ymDKry7UxzO5md9ybQlkfKpN2rHYbp9GtH1LDQPa7z2vVu/kEnNnTKeHt9obmaC7TQDh0IvsUBSuzhGZdfAIK7YyBqykCgeZm5rvA6K5b7zHGdA+7pUpJ/9ZLpp1NuxWRFlrkaEt00MIgAr8gX5JbSr">
<TableDataSource Name="Table1" Alias="Head" DataType="System.Int32" Enabled="true" SelectCommand="select * from CH_Trust where CH_TrustID=@CH_TrustID">
<Column Name="CH_TrustID" DataType="System.String"/>
<Column Name="CH_TrustCode" DataType="System.String"/>
<Column Name="CH_TrustUnit" DataType="System.String"/>
<Column Name="CH_TrustDate" DataType="System.DateTime"/>
<Column Name="CH_TrustType" DataType="System.String"/>
<Column Name="CH_TrustMan" DataType="System.String"/>
<Column Name="CH_Tabler" DataType="System.String"/>
<Column Name="CH_TableDate" DataType="System.DateTime"/>
<Column Name="CH_AuditMan" DataType="System.String"/>
<Column Name="CH_AuditDate" DataType="System.DateTime"/>
<Column Name="CH_Printer" DataType="System.String"/>
<Column Name="CH_PrintDate" DataType="System.DateTime"/>
<Column Name="CH_UnitName" DataType="System.String"/>
<Column Name="CH_WorkNo" DataType="System.String"/>
<Column Name="CH_ItemName" DataType="System.String"/>
<Column Name="CH_SlopeType" DataType="System.String"/>
<Column Name="CH_ServiceTemp" DataType="System.String"/>
<Column Name="CH_Press" DataType="System.String"/>
<Column Name="CH_WeldMethod" DataType="System.String"/>
<Column Name="CH_NDTRate" DataType="System.String"/>
<Column Name="CH_NDTMethod" DataType="System.String"/>
<Column Name="CH_NDTCriteria" DataType="System.String"/>
<Column Name="CH_AcceptGrade" DataType="System.String"/>
<Column Name="CH_Remark" DataType="System.String"/>
<Column Name="CH_CheckUnit" DataType="System.String"/>
<Column Name="ProjectId" DataType="System.String"/>
<Column Name="InstallationId" DataType="System.String"/>
<Column Name="CH_RequestDate" DataType="System.DateTime"/>
<Column Name="ToIso_Id" DataType="System.String"/>
<CommandParameter Name="CH_TrustID" DataType="22" Expression="[CH_TrustID]"/>
</TableDataSource>
<TableDataSource Name="Table3" Alias="Data" DataType="System.Int32" Enabled="true" SelectCommand=" SELECT batch.PipelineCode ,batch.WeldJointCode,batch.WelderCode,joint.Specification , joint.MaterialCode,joint.Remark &#13;&#10; FROM dbo.View_Batch_BatchTrustItem as batch&#13;&#10; left join View_HJGL_WeldJoint joint on batch .WeldJointId=joint.WeldJointId&#13;&#10; where batch.TrustBatchId=@TrustBatchId">
<Column Name="Remark" DataType="System.Int32" PropName="Column" Calculated="true" Expression=""/>
<Column Name="PipelineCode" DataType="System.String"/>
<Column Name="WeldJointCode" DataType="System.String"/>
<Column Name="WelderCode" DataType="System.String"/>
<Column Name="Specification" DataType="System.String"/>
<Column Name="MaterialCode" DataType="System.String"/>
<CommandParameter Name="TrustBatchId" DataType="12" Expression="[TrustBatchId]"/>
</TableDataSource>
</MsSqlDataConnection>
<TableDataSource Name="Table1" ReferenceName="Table1" DataType="System.Int32" Enabled="true">
<Column Name="CH_TrustCode" DataType="System.String"/>
<Column Name="CH_TrustUnit" DataType="System.String"/>
<Column Name="CH_TrustMan" DataType="System.String"/>
<Column Name="CH_SlopeType" DataType="System.String"/>
<Column Name="CH_WeldMethod" DataType="System.String"/>
<Column Name="CH_NDTRate" DataType="System.String"/>
<Column Name="CH_NDTMethod" DataType="System.String"/>
<Column Name="CH_NDTCriteria" DataType="System.String"/>
<Column Name="CH_AcceptGrade" DataType="System.String"/>
<Column Name="CH_CheckUnit" DataType="System.String"/>
<Column Name="ProjectName" DataType="System.String" PropName="ProjectId"/>
<Column Name="WorkAreaName" DataType="System.String" PropName="Column"/>
<Column Name="WorkAreaCode" DataType="System.String" PropName="Column"/>
<Column Name="Column" DataType="System.Int32" Calculated="true" Expression=""/>
<Column Name="Column1" DataType="System.Int32" Calculated="true" Expression=""/>
<Column Name="Column2" DataType="System.Int32" Calculated="true" Expression=""/>
<Column Name="Column3" DataType="System.Int32" Calculated="true" Expression=""/>
</TableDataSource>
<TableDataSource Name="Data" Alias="Dataaaa" ReferenceName="Data.Data" DataType="System.Int32" Enabled="true">
<Column Name="CH_TrustID" DataType="System.String"/>
<Column Name="ISO_IsoNo" DataType="System.Int32" PropName="Column" Calculated="true" Expression=""/>
<Column Name="ISO_IsoNumber" DataType="System.Int32" PropName="Column" Calculated="true" Expression=""/>
<Column Name="JOT_JointNo" DataType="System.Int32" PropName="Column1" Calculated="true" Expression=""/>
<Column Name="WED_Code2" DataType="System.Int32" PropName="Column2" Calculated="true" Expression=""/>
<Column Name="JOT_JointDesc" DataType="System.Int32" PropName="Column3" Calculated="true" Expression=""/>
<Column Name="STE_Name1" DataType="System.Int32" PropName="Column" Calculated="true" Expression=""/>
<Column Name="Remark" DataType="System.Int32" PropName="Column1" Calculated="true" Expression=""/>
</TableDataSource>
<Parameter Name="CH_TrustID" DataType="System.String"/>
<Parameter Name="supUnit" DataType="System.String"/>
<Parameter Name="totalUnit" DataType="System.String"/>
<Parameter Name="ConUnit" DataType="System.String"/>
<Parameter Name="CheckUnit" DataType="System.String"/>
<Parameter Name="TrustBatchId" DataType="System.String"/>
</Dictionary>
<ReportPage Name="Page1" RawPaperSize="9" Guides="75.6">
<PageHeaderBand Name="PageHeader1" Width="718.2" Height="283.5">
<TableObject Name="Table4" Left="18.9" Top="37.8" Width="699.25" Height="246.02" ManualBuildEvent="Table4_ManualBuild">
<TableColumn Name="Column13" Width="94.73"/>
<TableColumn Name="Column14" Width="94.73"/>
<TableColumn Name="Column15" Width="75.83"/>
<TableColumn Name="Column16" Width="94.73"/>
<TableColumn Name="Column17" Width="94.73"/>
<TableColumn Name="Column18" Width="72.05"/>
<TableColumn Name="Column19" Width="72.05"/>
<TableColumn Name="Column20" Width="100.4"/>
<TableRow Name="Row14" Height="64.64">
<TableCell Name="Cell81" Border.Lines="All" Text="SH/T 3543-G414" HorzAlign="Center" VertAlign="Center" Font="宋体, 11pt" ColSpan="2" RowSpan="2"/>
<TableCell Name="Cell82" Border.Lines="All" HorzAlign="Center" VertAlign="Center"/>
<TableCell Name="Cell83" Border.Lines="All" Text="管道焊口检测委托单" HorzAlign="Center" VertAlign="Center" Font="宋体, 16pt, style=Bold" ColSpan="4" RowSpan="2"/>
<TableCell Name="Cell84" Border.Lines="All" HorzAlign="Center" VertAlign="Center"/>
<TableCell Name="Cell85" Border.Lines="All" HorzAlign="Center" VertAlign="Center"/>
<TableCell Name="Cell86" Border.Lines="All" HorzAlign="Center" VertAlign="Center"/>
<TableCell Name="Cell87" Border.Lines="All" Text="工程名称" HorzAlign="Center" VertAlign="Center" Font="宋体, 10pt"/>
<TableCell Name="Cell88" Border.Lines="All" Text="[Table1.ProjectName]" HorzAlign="Center" VertAlign="Center" Font="宋体, 8pt"/>
</TableRow>
<TableRow Name="Row13" Height="43.78">
<TableCell Name="Cell73" Border.Lines="All" HorzAlign="Center" VertAlign="Center"/>
<TableCell Name="Cell74" Border.Lines="All" HorzAlign="Center" VertAlign="Center"/>
<TableCell Name="Cell75" Border.Lines="All" HorzAlign="Center" VertAlign="Center"/>
<TableCell Name="Cell76" Border.Lines="All" HorzAlign="Center" VertAlign="Center"/>
<TableCell Name="Cell77" Border.Lines="All" HorzAlign="Center" VertAlign="Center"/>
<TableCell Name="Cell78" Border.Lines="All" HorzAlign="Center" VertAlign="Center"/>
<TableCell Name="Cell79" Border.Lines="All" Text="单位工程名称" HorzAlign="Center" VertAlign="Center" Font="宋体, 10pt"/>
<TableCell Name="Cell80" Border.Lines="All" Text="[Table1.WorkAreaName]" HorzAlign="Center" VertAlign="Center"/>
</TableRow>
<TableRow Name="Row8" Height="34.4">
<TableCell Name="Cell33" Border.Lines="All" Text="检测单位" HorzAlign="Center" VertAlign="Center" Font="宋体, 10pt"/>
<TableCell Name="Cell34" Border.Lines="All" Text="[Table1.CH_CheckUnit]" HorzAlign="Center" VertAlign="Center" ColSpan="2"/>
<TableCell Name="Cell35" Border.Lines="All" HorzAlign="Center" VertAlign="Center"/>
<TableCell Name="Cell36" Border.Lines="All" Text="接收人" HorzAlign="Center" VertAlign="Center" Font="宋体, 10pt"/>
<TableCell Name="Cell37" Border.Lines="All" Text="[Table1.CH_TrustMan]" HorzAlign="Center" VertAlign="Center"/>
<TableCell Name="Cell58" Border.Lines="All" Text="委托单号" HorzAlign="Center" VertAlign="Center" Font="宋体, 10pt"/>
<TableCell Name="Cell63" Border.Lines="All" Text="[Table1.CH_TrustCode]" HorzAlign="Center" VertAlign="Center" Font="宋体, 8pt" ColSpan="2"/>
<TableCell Name="Cell68" Border.Lines="All" HorzAlign="Center" VertAlign="Center"/>
</TableRow>
<TableRow Name="Row9" Height="34.4">
<TableCell Name="Cell38" Border.Lines="All" Text="区号" HorzAlign="Center" VertAlign="Center" Font="宋体, 10pt"/>
<TableCell Name="Cell39" Border.Lines="All" Text="[Table1.WorkAreaCode]" HorzAlign="Center" VertAlign="Center" ColSpan="2"/>
<TableCell Name="Cell40" Border.Lines="All" HorzAlign="Center" VertAlign="Center"/>
<TableCell Name="Cell41" Border.Lines="All" Text="检测时机" HorzAlign="Center" VertAlign="Center" Font="宋体, 10pt"/>
<TableCell Name="Cell42" Border.Lines="All" Text="焊后" HorzAlign="Center" VertAlign="Center"/>
<TableCell Name="Cell59" Border.Lines="All" Text="检测标准" HorzAlign="Center" VertAlign="Center" Font="宋体, 10pt"/>
<TableCell Name="Cell64" Border.Lines="All" Text="[Table1.CH_NDTCriteria]" HorzAlign="Center" VertAlign="Center" ColSpan="2"/>
<TableCell Name="Cell69" Border.Lines="All" HorzAlign="Center" VertAlign="Center"/>
</TableRow>
<TableRow Name="Row10" Height="34.4">
<TableCell Name="Cell43" Border.Lines="All" Text="检测类别" HorzAlign="Center" VertAlign="Center" Font="宋体, 10pt"/>
<TableCell Name="Cell44" Border.Lines="All" HorzAlign="Center" VertAlign="Center" ColSpan="2"/>
<TableCell Name="Cell45" Border.Lines="All" HorzAlign="Center" VertAlign="Center"/>
<TableCell Name="Cell46" Border.Lines="All" Text="焊接方法" HorzAlign="Center" VertAlign="Center" Font="宋体, 10pt"/>
<TableCell Name="Cell47" Border.Lines="All" Text="[Table1.CH_WeldMethod]" HorzAlign="Center" VertAlign="Center"/>
<TableCell Name="Cell60" Border.Lines="All" Text="合格级别" HorzAlign="Center" VertAlign="Center" Font="宋体, 10pt"/>
<TableCell Name="Cell65" Border.Lines="All" Text="[Table1.CH_AcceptGrade]" HorzAlign="Center" VertAlign="Center" ColSpan="2"/>
<TableCell Name="Cell70" Border.Lines="All" HorzAlign="Center" VertAlign="Center"/>
</TableRow>
<TableRow Name="Row11" Height="34.4">
<TableCell Name="Cell48" Border.Lines="All" Text="检测方法" HorzAlign="Center" VertAlign="Center" Font="宋体, 10pt"/>
<TableCell Name="Cell49" Border.Lines="All" Text="[Table1.CH_NDTMethod]" HorzAlign="Center" VertAlign="Center" Font="宋体, 10pt" ColSpan="2"/>
<TableCell Name="Cell50" Border.Lines="All" HorzAlign="Center" VertAlign="Center" Font="宋体, 10pt"/>
<TableCell Name="Cell51" Border.Lines="All" Text="坡口形式" HorzAlign="Center" VertAlign="Center" Font="宋体, 10pt"/>
<TableCell Name="Cell52" Border.Lines="All" Text="[Table1.CH_SlopeType]" HorzAlign="Center" VertAlign="Center" Font="宋体, 10pt"/>
<TableCell Name="Cell61" Border.Lines="All" Text="检测比例" HorzAlign="Center" VertAlign="Center" Font="宋体, 10pt"/>
<TableCell Name="Cell66" Border.Lines="All" Text="[Table1.CH_NDTRate]" HorzAlign="Center" VertAlign="Center" Font="宋体, 10pt" ColSpan="2"/>
<TableCell Name="Cell71" Border.Lines="All" HorzAlign="Center" VertAlign="Center" Font="宋体, 10pt"/>
</TableRow>
</TableObject>
</PageHeaderBand>
<DataBand Name="Data1" Top="287.35" Width="718.2" Height="71.82">
<TableObject Name="Tabel_Data" Left="18.9" Width="699.18" Height="71.82" Border.Lines="Top" ManualBuildEvent="Tabel_Data_ManualBuild">
<TableColumn Name="Column21" Width="69.91"/>
<TableColumn Name="Column22" Width="117.16"/>
<TableColumn Name="Column23" Width="0"/>
<TableColumn Name="Column24" Width="158.76"/>
<TableColumn Name="Column25" Width="107.71"/>
<TableColumn Name="Column26" Width="85.03"/>
<TableColumn Name="Column27" Width="85.03"/>
<TableColumn Name="Column28" Width="75.58"/>
<TableRow Name="Row30" Height="22.68">
<TableCell Name="Cell229" Border.Lines="All" Text="序号" HorzAlign="Center" VertAlign="Center" Font="宋体, 10pt"/>
<TableCell Name="Cell230" Border.Lines="All" Text="管道编号" HorzAlign="Center" VertAlign="Center" Font="宋体, 10pt" ColSpan="2"/>
<TableCell Name="Cell231" Border.Lines="All" HorzAlign="Center" VertAlign="Center" Font="宋体, 10pt"/>
<TableCell Name="Cell232" Border.Lines="All" Text="焊口号" HorzAlign="Center" VertAlign="Center" Font="宋体, 10pt"/>
<TableCell Name="Cell233" Border.Lines="All" Text="焊工号" HorzAlign="Center" VertAlign="Center" Font="宋体, 10pt"/>
<TableCell Name="Cell234" Border.Lines="All" Text="焊口规格" HorzAlign="Center" VertAlign="Center" Font="宋体, 10pt"/>
<TableCell Name="Cell235" Border.Lines="All" Text="焊口材质" HorzAlign="Center" VertAlign="Center" Font="宋体, 10pt"/>
<TableCell Name="Cell236" Border.Lines="All" Text="备注" HorzAlign="Center" VertAlign="Center" Font="宋体, 10pt"/>
</TableRow>
<TableRow Name="Row21" Height="49.14">
<TableCell Name="Cell137" Border.Lines="All" Text="[x]" HorzAlign="Center" VertAlign="Center"/>
<TableCell Name="Cell138" Border.Lines="All" Text="[Data.PipelineCode]" VertAlign="Center" ColSpan="2"/>
<TableCell Name="Cell139" Border.Lines="All" HorzAlign="Center" VertAlign="Center"/>
<TableCell Name="Cell140" Border.Lines="All" Text="[Data.WeldJointCode]" HorzAlign="Center" VertAlign="Center"/>
<TableCell Name="Cell141" Border.Lines="All" Text="[Data.WelderCode]" HorzAlign="Center" VertAlign="Center"/>
<TableCell Name="Cell142" Border.Lines="All" Text="[Data.Specification]" HorzAlign="Center" VertAlign="Center"/>
<TableCell Name="Cell143" Border.Lines="All" Text="[Data.MaterialCode]" HorzAlign="Center" VertAlign="Center"/>
<TableCell Name="Cell144" Border.Lines="All" Text="[Data.Remark]" HorzAlign="Center" VertAlign="Center"/>
</TableRow>
</TableObject>
<DataFooterBand Name="DataFooter1" Top="416" Width="718.2">
<ChildBand Name="Child2" Top="363.01" Width="718.2" Height="49.14" FillUnusedSpace="true">
<TableObject Name="Table6" Left="18.9" Width="699.18" Height="49.14" Border.Lines="Top">
<TableColumn Name="Column53" Width="69.91"/>
<TableColumn Name="Column54" Width="117.16"/>
<TableColumn Name="Column55" Width="0"/>
<TableColumn Name="Column56" Width="158.76"/>
<TableColumn Name="Column57" Width="107.71"/>
<TableColumn Name="Column58" Width="85.03"/>
<TableColumn Name="Column59" Width="85.03"/>
<TableColumn Name="Column60" Width="75.58"/>
<TableRow Name="Row29" Height="49.14">
<TableCell Name="Cell221" Border.Lines="All"/>
<TableCell Name="Cell222" Border.Lines="All" ColSpan="2"/>
<TableCell Name="Cell223" Border.Lines="All"/>
<TableCell Name="Cell224" Border.Lines="All"/>
<TableCell Name="Cell225" Border.Lines="All"/>
<TableCell Name="Cell226" Border.Lines="All"/>
<TableCell Name="Cell227" Border.Lines="All"/>
<TableCell Name="Cell228" Border.Lines="All"/>
</TableRow>
</TableObject>
</ChildBand>
</DataFooterBand>
</DataBand>
<PageFooterBand Name="PageFooter1" Top="419.84" Width="718.2" Height="181.43">
<TableObject Name="Table5" Left="18.9" Width="699.21" Height="135.6" Border.Lines="All" RepeatHeaders="false">
<TableColumn Name="Column37" Width="99.45"/>
<TableColumn Name="Column38" Width="90"/>
<TableColumn Name="Column39" Width="99.45"/>
<TableColumn Name="Column40" Width="71.1"/>
<TableColumn Name="Column41" Width="99.45"/>
<TableColumn Name="Column42" Width="67.32"/>
<TableColumn Name="Column43" Width="76.77"/>
<TableColumn Name="Column44" Width="95.67"/>
<TableRow Name="Row24" Height="43.94">
<TableCell Name="Cell161" Border.Lines="Left, Right" Text="&#13;&#10;建设单位:&#13;&#10;" Font="宋体, 10pt" ColSpan="2" RowSpan="2"/>
<TableCell Name="Cell162" Border.Lines="Left, Right, Top" Font="宋体, 10pt"/>
<TableCell Name="Cell163" Border.Lines="Left, Right" Text="&#13;&#10;监理单位:&#13;&#10;" Font="宋体, 10pt" ColSpan="2" RowSpan="2"/>
<TableCell Name="Cell164" Border.Lines="Left, Right, Top" Font="宋体, 10pt"/>
<TableCell Name="Cell165" Border.Lines="Left, Right" Text="&#13;&#10;总包单位:&#13;&#10;" Font="宋体, 10pt" ColSpan="2" RowSpan="2"/>
<TableCell Name="Cell166" Border.Lines="Left, Right, Top" Font="宋体, 10pt"/>
<TableCell Name="Cell167" Border.Lines="Left, Right" Text="&#13;&#10;施工单位:&#13;&#10;" Font="宋体, 10pt" ColSpan="2" RowSpan="2"/>
<TableCell Name="Cell168" Border.Lines="Left, Right, Top" Font="宋体, 10pt"/>
</TableRow>
<TableRow Name="Row25" Height="45.83">
<TableCell Name="Cell169" Border.Lines="All"/>
<TableCell Name="Cell170" Border.Lines="All"/>
<TableCell Name="Cell171" Border.Lines="All"/>
<TableCell Name="Cell172" Border.Lines="All"/>
<TableCell Name="Cell173" Border.Lines="All"/>
<TableCell Name="Cell174" Border.Lines="All"/>
<TableCell Name="Cell175" Border.Lines="All"/>
<TableCell Name="Cell176" Border.Lines="All"/>
</TableRow>
<TableRow Name="Row27" Height="45.83">
<TableCell Name="Cell185" Border.Lines="Left, Right, Bottom" Text="日期: 年 月 日" ColSpan="2"/>
<TableCell Name="Cell186" Border.Lines="All"/>
<TableCell Name="Cell187" Border.Lines="Left, Right, Bottom" Text="日期: 年 月 日" ColSpan="2"/>
<TableCell Name="Cell188" Border.Lines="All"/>
<TableCell Name="Cell189" Border.Lines="Left, Right, Bottom" Text="日期: 年 月 日" ColSpan="2"/>
<TableCell Name="Cell190" Border.Lines="All"/>
<TableCell Name="Cell191" Border.Lines="Left, Right, Bottom" Text="日期: 年 月 日" ColSpan="2"/>
<TableCell Name="Cell192" Border.Lines="All"/>
</TableRow>
</TableObject>
<ChildBand Name="Child1" Top="605.12" Width="718.2" Height="17.77" PrintOnBottom="true"/>
</PageFooterBand>
</ReportPage>
</Report>

View File

@ -0,0 +1,239 @@
<?xml version="1.0" encoding="utf-8"?>
<Report ScriptLanguage="CSharp" ReportInfo.Created="12/29/2021 10:56:08" ReportInfo.Modified="06/29/2023 16:17:25" ReportInfo.CreatorVersion="2017.1.16.0">
<ScriptText>using System;
using System.Collections;
using System.Collections.Generic;
using System.ComponentModel;
using System.Windows.Forms;
using System.Drawing;
using System.Data;
using FastReport;
using FastReport.Data;
using FastReport.Dialog;
using FastReport.Barcode;
using FastReport.Table;
using FastReport.Utils;
namespace FastReport
{
public class ReportScript
{
private int x;
private void Tabel_Data_ManualBuild(object sender, EventArgs e)
{
DataSourceBase rowData = Report.GetDataSource(&quot;Data&quot;);
// init the data source
rowData.Init();
// print the first table row - it is a header
Tabel_Data.PrintRow(0);
// each PrintRow call must be followed by either PrintColumn or PrintColumns call
// to print cells on the row
Tabel_Data.PrintColumns();
x=0;
// now enumerate the data source and print the table body
while (rowData.HasMoreRows)
{
x++;
// print the table body
Tabel_Data.PrintRow(1);
Tabel_Data.PrintColumns();
// go next data source row
rowData.Next();
}
}
}
}
</ScriptText>
<Dictionary>
<MsSqlDataConnection Name="Connection" ConnectionString="rijcmlqvJIqZbrmqGn7L0P56UFhaUHihKXxbhpqie4wmZgM2ymDKry7UxzO5md9ybQlkfKpN2rHYbp9GtH1LDQPa7z2vVu/kEnNnTKeHt9obmaC7TQDh0IvsUBSuzhGZdfAIK7YyBqykCgeZm5rvA6K5b7zHGdA+7pUpJ/9ZLpp1NuxWREqJVR0Mamf/zPeVAMs94NN">
<TableDataSource Name="Data" DataType="System.Int32" Enabled="true" SelectCommand=" select PipelineCode as ISO_IsoNo ,WeldJointCode as JOT_JointNo,Specification as JOT_JointDesc,MaterialCode &#13;&#10; from dbo.View_HJGL_HotProess_TrustItem AS Trust &#13;&#10; WHERE Trust.HotProessTrustId=@HotProessTrustId">
<Column Name="ISO_IsoNo" DataType="System.String"/>
<Column Name="JOT_JointNo" DataType="System.String"/>
<Column Name="JOT_JointDesc" DataType="System.String"/>
<Column Name="MaterialCode" DataType="System.String"/>
<CommandParameter Name="HotProessTrustId" DataType="22" Expression="[HotProessTrustId]"/>
</TableDataSource>
</MsSqlDataConnection>
<TableDataSource Name="Table1" ReferenceName="Table1" DataType="System.Int32" Enabled="true">
<Column Name="ProjectName" DataType="System.String"/>
<Column Name="WorkAreaName" DataType="System.String"/>
<Column Name="HotProessTrustNo" DataType="System.String"/>
<Column Name="CH_TrustMan" DataType="System.String"/>
<Column Name="WorkAreaCode" DataType="System.String"/>
<Column Name="JoinNum" DataType="System.String"/>
</TableDataSource>
<Parameter Name="HotProessTrustId" DataType="System.String"/>
<Parameter Name="totalUnit" DataType="System.String"/>
<Parameter Name="supUnit" DataType="System.String"/>
<Parameter Name="ConUnit" DataType="System.String"/>
</Dictionary>
<ReportPage Name="Page1" RawPaperSize="9">
<PageHeaderBand Name="PageHeader1" Width="718.2" Height="211.33">
<TableObject Name="Table4" Left="18.9" Top="37.8" Width="699.25" Height="173.53">
<TableColumn Name="Column13" Width="94.73"/>
<TableColumn Name="Column14" Width="94.73"/>
<TableColumn Name="Column15" Width="75.83"/>
<TableColumn Name="Column16" Width="94.73"/>
<TableColumn Name="Column17" Width="94.73"/>
<TableColumn Name="Column18" Width="72.05"/>
<TableColumn Name="Column19" Width="43.7"/>
<TableColumn Name="Column20" Width="128.75"/>
<TableRow Name="Row14" Height="60.78">
<TableCell Name="Cell81" Border.Lines="All" Text="SH/T 3543" HorzAlign="Center" VertAlign="Center" Font="宋体, 11pt" ColSpan="2" RowSpan="2"/>
<TableCell Name="Cell82" Border.Lines="All" HorzAlign="Center" VertAlign="Center"/>
<TableCell Name="Cell83" Border.Lines="All" Text="管道焊口热处理委托单" HorzAlign="Center" VertAlign="Center" Font="宋体, 16pt, style=Bold" ColSpan="4" RowSpan="2"/>
<TableCell Name="Cell84" Border.Lines="All" HorzAlign="Center" VertAlign="Center"/>
<TableCell Name="Cell85" Border.Lines="All" HorzAlign="Center" VertAlign="Center"/>
<TableCell Name="Cell86" Border.Lines="All" HorzAlign="Center" VertAlign="Center"/>
<TableCell Name="Cell87" Border.Lines="Left, Top" Text="工程&#13;&#10;名称" HorzAlign="Center" VertAlign="Center" Font="宋体, 10pt"/>
<TableCell Name="Cell88" Border.Lines="Right, Top" Text="[Table1.ProjectName]" HorzAlign="Center" VertAlign="Center" Font="宋体, 8pt"/>
</TableRow>
<TableRow Name="Row13" Height="43.78">
<TableCell Name="Cell73" Border.Lines="All" HorzAlign="Center" VertAlign="Center"/>
<TableCell Name="Cell74" Border.Lines="All" HorzAlign="Center" VertAlign="Center"/>
<TableCell Name="Cell75" Border.Lines="All" HorzAlign="Center" VertAlign="Center"/>
<TableCell Name="Cell76" Border.Lines="All" HorzAlign="Center" VertAlign="Center"/>
<TableCell Name="Cell77" Border.Lines="All" HorzAlign="Center" VertAlign="Center"/>
<TableCell Name="Cell78" Border.Lines="All" HorzAlign="Center" VertAlign="Center"/>
<TableCell Name="Cell79" Border.Lines="Left, Bottom" Text="工区&#13;&#10;名称" HorzAlign="Center" VertAlign="Center" Font="宋体, 10pt"/>
<TableCell Name="Cell80" Border.Lines="Right, Bottom" Text="[Table1.WorkAreaName]" HorzAlign="Center" VertAlign="Center"/>
</TableRow>
<TableRow Name="Row8" Height="22.99">
<TableCell Name="Cell33" Border.Lines="All" Text="委托单编号" HorzAlign="Center" VertAlign="Center" Font="宋体, 10pt"/>
<TableCell Name="Cell34" Border.Lines="All" Text="[Table1.HotProessTrustNo]" HorzAlign="Center" VertAlign="Center" ColSpan="3"/>
<TableCell Name="Cell35" Border.Lines="All" HorzAlign="Center" VertAlign="Center"/>
<TableCell Name="Cell36" Border.Lines="All" HorzAlign="Center" VertAlign="Center" Font="宋体, 10pt"/>
<TableCell Name="Cell37" Border.Lines="All" Text="热处理接收人" HorzAlign="Center" VertAlign="Center"/>
<TableCell Name="Cell58" Border.Lines="All" HorzAlign="Center" VertAlign="Center" Font="宋体, 10pt" ColSpan="3"/>
<TableCell Name="Cell63" Border.Lines="All" HorzAlign="Center" VertAlign="Center" Font="宋体, 8pt"/>
<TableCell Name="Cell68" Border.Lines="All" HorzAlign="Center" VertAlign="Center"/>
</TableRow>
<TableRow Name="Row9" Height="22.99">
<TableCell Name="Cell38" Border.Lines="All" Text="区号" HorzAlign="Center" VertAlign="Center" Font="宋体, 10pt"/>
<TableCell Name="Cell39" Border.Lines="All" Text="[Table1.WorkAreaCode]" HorzAlign="Center" VertAlign="Center" ColSpan="2"/>
<TableCell Name="Cell40" Border.Lines="All" HorzAlign="Center" VertAlign="Center"/>
<TableCell Name="Cell41" Border.Lines="All" Text="热处理温度" HorzAlign="Center" VertAlign="Center" Font="宋体, 10pt"/>
<TableCell Name="Cell42" Border.Lines="All" HorzAlign="Center" VertAlign="Center"/>
<TableCell Name="Cell59" Border.Lines="All" Text="执行标准" HorzAlign="Center" VertAlign="Center" Font="宋体, 10pt"/>
<TableCell Name="Cell64" Border.Lines="All" HorzAlign="Center" VertAlign="Center" ColSpan="2"/>
<TableCell Name="Cell69" Border.Lines="All" HorzAlign="Center" VertAlign="Center"/>
</TableRow>
<TableRow Name="Row11" Height="22.99">
<TableCell Name="Cell48" Border.Lines="All" Text="检测方法" HorzAlign="Center" VertAlign="Center" Font="宋体, 10pt"/>
<TableCell Name="Cell49" Border.Lines="All" Text="硬度" HorzAlign="Center" VertAlign="Center" Font="宋体, 10pt" ColSpan="2"/>
<TableCell Name="Cell50" Border.Lines="All" HorzAlign="Center" VertAlign="Center" Font="宋体, 10pt"/>
<TableCell Name="Cell51" Border.Lines="All" Text="热处理方法" HorzAlign="Center" VertAlign="Center" Font="宋体, 10pt"/>
<TableCell Name="Cell52" Border.Lines="All" Text="电加热" HorzAlign="Center" VertAlign="Center" Font="宋体, 10pt"/>
<TableCell Name="Cell61" Border.Lines="All" Text="焊口数/道" HorzAlign="Center" VertAlign="Center" Font="宋体, 10pt"/>
<TableCell Name="Cell66" Border.Lines="All" Text="[Table1.JoinNum]" HorzAlign="Center" VertAlign="Center" Font="宋体, 10pt" ColSpan="2"/>
<TableCell Name="Cell71" Border.Lines="All" HorzAlign="Center" VertAlign="Center" Font="宋体, 10pt"/>
</TableRow>
</TableObject>
</PageHeaderBand>
<DataBand Name="Data1" Top="215.18" Width="718.2" Height="81.27">
<TableObject Name="Tabel_Data" Left="18.9" Width="697.67" Height="81.27" Border.Lines="Top" FixedRows="1" ManualBuildEvent="Tabel_Data_ManualBuild">
<TableColumn Name="Column21" Width="60.46"/>
<TableColumn Name="Column22" Width="107.71"/>
<TableColumn Name="Column23" Width="88.81"/>
<TableColumn Name="Column24" Width="69.91"/>
<TableColumn Name="Column26" Width="66.13"/>
<TableColumn Name="Column27" Width="151.18"/>
<TableColumn Name="Column61"/>
<TableColumn Name="Column28" Width="87.32"/>
<TableRow Name="Row30" Height="32.13">
<TableCell Name="Cell229" Border.Lines="All" Text="序号" HorzAlign="Center" VertAlign="Center" Font="宋体, 10pt"/>
<TableCell Name="Cell230" Border.Lines="All" Text="管道编号" HorzAlign="Center" VertAlign="Center" Font="宋体, 10pt"/>
<TableCell Name="Cell231" Border.Lines="All" Text="焊口号" HorzAlign="Center" VertAlign="Center" Font="宋体, 10pt"/>
<TableCell Name="Cell232" Border.Lines="All" Text="焊口规格" HorzAlign="Center" VertAlign="Center" Font="宋体, 10pt" ColSpan="2"/>
<TableCell Name="Cell234" Border.Lines="All" HorzAlign="Center" VertAlign="Center" Font="宋体, 10pt"/>
<TableCell Name="Cell235" Border.Lines="All" Text="焊口材质" HorzAlign="Center" VertAlign="Center" Font="宋体, 10pt"/>
<TableCell Name="Cell237" Border.Lines="All" Text="热处理日期" HorzAlign="Center" VertAlign="Center"/>
<TableCell Name="Cell236" Border.Lines="All" Text="备注" HorzAlign="Center" VertAlign="Center" Font="宋体, 10pt"/>
</TableRow>
<TableRow Name="Row21" Height="49.14">
<TableCell Name="Cell137" Border.Lines="All" Text="[x]" HorzAlign="Center" VertAlign="Center"/>
<TableCell Name="Cell138" Border.Lines="All" Text="[Data.ISO_IsoNo]" VertAlign="Center"/>
<TableCell Name="Cell139" Border.Lines="All" Text="[Data.JOT_JointNo]" HorzAlign="Center" VertAlign="Center"/>
<TableCell Name="Cell140" Border.Lines="All" Text="[Data.JOT_JointDesc]" HorzAlign="Center" VertAlign="Center" ColSpan="2"/>
<TableCell Name="Cell142" Border.Lines="All" HorzAlign="Center" VertAlign="Center"/>
<TableCell Name="Cell143" Border.Lines="All" Text="[Data.MaterialCode]" HorzAlign="Center" VertAlign="Center"/>
<TableCell Name="Cell238" Border.Lines="All" Format="Date" Format.Format="d" HorzAlign="Center" VertAlign="Center"/>
<TableCell Name="Cell144" Border.Lines="All" HorzAlign="Center" VertAlign="Center"/>
</TableRow>
</TableObject>
<DataFooterBand Name="DataFooter1" Top="353.28" Width="718.2">
<ChildBand Name="Child2" Top="300.29" Width="718.2" Height="49.14" FillUnusedSpace="true">
<TableObject Name="Table6" Left="18.9" Width="697.67" Height="49.14" Border.Lines="Top">
<TableColumn Name="Column53" Width="60.46"/>
<TableColumn Name="Column54" Width="107.71"/>
<TableColumn Name="Column55" Width="88.81"/>
<TableColumn Name="Column56" Width="69.91"/>
<TableColumn Name="Column58" Width="66.13"/>
<TableColumn Name="Column59" Width="151.18"/>
<TableColumn Name="Column62"/>
<TableColumn Name="Column60" Width="87.32"/>
<TableRow Name="Row29" Height="49.14">
<TableCell Name="Cell221" Border.Lines="All"/>
<TableCell Name="Cell222" Border.Lines="All"/>
<TableCell Name="Cell223" Border.Lines="All"/>
<TableCell Name="Cell224" Border.Lines="All" ColSpan="2"/>
<TableCell Name="Cell226" Border.Lines="All"/>
<TableCell Name="Cell227" Border.Lines="All"/>
<TableCell Name="Cell239" Border.Lines="All"/>
<TableCell Name="Cell228" Border.Lines="All"/>
</TableRow>
</TableObject>
</ChildBand>
</DataFooterBand>
</DataBand>
<PageFooterBand Name="PageFooter1" Top="357.12" Width="718.2" Height="219.24">
<TableObject Name="Table5" Left="18.9" Width="697.36" Height="163.77" Border.Lines="All" RepeatHeaders="false">
<TableColumn Name="Column37" Width="127.89"/>
<TableColumn Name="Column38" Width="110.88"/>
<TableColumn Name="Column39" Width="127.89"/>
<TableColumn Name="Column40" Width="99.54"/>
<TableColumn Name="Column41" Width="135.4"/>
<TableColumn Name="Column42" Width="95.76"/>
<TableRow Name="Row24" Height="43.94">
<TableCell Name="Cell161" Border.Lines="Left, Right" Text="&#13;&#10;施工单位:&#13;&#10;[ConUnit]&#13;&#10;" Font="宋体, 10pt" ColSpan="2" RowSpan="2"/>
<TableCell Name="Cell162" Border.Lines="Left, Right, Top" Font="宋体, 10pt"/>
<TableCell Name="Cell163" Border.Lines="Left, Right" Text="&#13;&#10;监理单位:&#13;&#10;[supUnit]&#13;&#10;" Font="宋体, 10pt" ColSpan="2" RowSpan="2"/>
<TableCell Name="Cell164" Border.Lines="Left, Right, Top" Font="宋体, 10pt"/>
<TableCell Name="Cell165" Border.Lines="Left, Right" Text="&#13;&#10;建设单位项目部门:&#13;&#10;[totalUnit]&#13;&#10;" Font="宋体, 10pt" ColSpan="2" RowSpan="2"/>
<TableCell Name="Cell166" Border.Lines="Left, Right, Top" Font="宋体, 10pt"/>
</TableRow>
<TableRow Name="Row25" Height="26.84">
<TableCell Name="Cell169" Border.Lines="All"/>
<TableCell Name="Cell170" Border.Lines="All"/>
<TableCell Name="Cell171" Border.Lines="All"/>
<TableCell Name="Cell172" Border.Lines="All"/>
<TableCell Name="Cell173" Border.Lines="All"/>
<TableCell Name="Cell174" Border.Lines="All"/>
</TableRow>
<TableRow Name="Row31" Height="47.25">
<TableCell Name="Cell240" Border.Lines="Left, Right" Text="技术员签字:&#13;&#10;&#13;&#10;焊接负责人:&#13;&#10;" ColSpan="2"/>
<TableCell Name="Cell241"/>
<TableCell Name="Cell242" Border.Lines="Left, Right" Text="签字人:" VertAlign="Center" ColSpan="2"/>
<TableCell Name="Cell243" VertAlign="Center"/>
<TableCell Name="Cell244" Border.Lines="Left, Right" Text="签字人:" VertAlign="Center" ColSpan="2"/>
<TableCell Name="Cell245" VertAlign="Center"/>
</TableRow>
<TableRow Name="Row27" Height="45.74">
<TableCell Name="Cell185" Border.Lines="Left, Right, Bottom" Text="&#13;&#10;&#13;&#10;日期: 年 月 日" ColSpan="2"/>
<TableCell Name="Cell186" Border.Lines="All"/>
<TableCell Name="Cell187" Border.Lines="Left, Right, Bottom" Text="&#13;&#10;&#13;&#10;日期: 年 月 日" ColSpan="2"/>
<TableCell Name="Cell188" Border.Lines="All"/>
<TableCell Name="Cell189" Border.Lines="Left, Right, Bottom" Text="&#13;&#10;&#13;&#10;日期: 年 月 日" ColSpan="2"/>
<TableCell Name="Cell190" Border.Lines="All"/>
</TableRow>
</TableObject>
<TextObject Name="Text1" Left="585.9" Top="179.55" Width="103.95" Height="28.35" Text="第[Page#]页 共[TotalPages#]页"/>
<ChildBand Name="Child1" Top="580.21" Width="718.2" Height="41.96" PrintOnBottom="true"/>
</PageFooterBand>
</ReportPage>
</Report>

View File

@ -46,6 +46,8 @@
</f:HiddenField> </f:HiddenField>
<f:ToolbarFill ID="ToolbarFill1" runat="server"> <f:ToolbarFill ID="ToolbarFill1" runat="server">
</f:ToolbarFill> </f:ToolbarFill>
<%--<f:Button ID="btnNew" Text="新增" ToolTip="新增" <%--<f:Button ID="btnNew" Text="新增" ToolTip="新增"
Icon="Add" runat="server" OnClick="btnNew_Click"> Icon="Add" runat="server" OnClick="btnNew_Click">
</f:Button> </f:Button>
@ -100,6 +102,9 @@
<f:TextBox ID="txtIsoNo" Label="管线号" runat="server" <f:TextBox ID="txtIsoNo" Label="管线号" runat="server"
LabelWidth="100px" LabelAlign="Right" AutoPostBack="true" OnTextChanged="TextBox_TextChanged"> LabelWidth="100px" LabelAlign="Right" AutoPostBack="true" OnTextChanged="TextBox_TextChanged">
</f:TextBox> </f:TextBox>
<f:Button ID="btnPrint" Text="打印" ToolTip="打印"
Icon="Printer" runat="server" OnClick="btnPrint_Click">
</f:Button>
<f:ToolbarFill ID="ToolbarFill2" runat="server"> <f:ToolbarFill ID="ToolbarFill2" runat="server">
</f:ToolbarFill> </f:ToolbarFill>
</Items> </Items>
@ -154,6 +159,10 @@
EnableMaximize="true" Target="Top" EnableResize="false" runat="server" OnClose="Window1_Close" EnableMaximize="true" Target="Top" EnableResize="false" runat="server" OnClose="Window1_Close"
IsModal="true" Width="1090px" Height="660px"> IsModal="true" Width="1090px" Height="660px">
</f:Window> </f:Window>
<f:Window ID="Window2" Title="打印" Hidden="true" EnableIFrame="true"
EnableMaximize="true" Target="Top" EnableResize="false" runat="server"
IsModal="true" Width="1010px" Height="660px">
</f:Window>
<f:Menu ID="Menu1" runat="server"> <f:Menu ID="Menu1" runat="server">
<f:MenuButton ID="btnNew" OnClick="btnNew_Click" EnablePostBack="true" runat="server" Hidden="true" Icon="Add" <f:MenuButton ID="btnNew" OnClick="btnNew_Click" EnablePostBack="true" runat="server" Hidden="true" Icon="Add"
Text="新增"> Text="新增">

View File

@ -3,6 +3,7 @@ using System;
using System.Collections.Generic; using System.Collections.Generic;
using System.Data; using System.Data;
using System.Data.SqlClient; using System.Data.SqlClient;
using System.IO;
using System.Linq; using System.Linq;
namespace FineUIPro.Web.HJGL.HotProcessHard namespace FineUIPro.Web.HJGL.HotProcessHard
@ -578,5 +579,117 @@ namespace FineUIPro.Web.HJGL.HotProcessHard
} }
} }
#endregion #endregion
/// <summary>
/// 打印
/// </summary>
/// <param name="sender"></param>
/// <param name="e"></param>
protected void btnPrint_Click(object sender, EventArgs e)
{
DataTable dt = new DataTable("Table1");
dt.Columns.Add("ProjectName", typeof(String));
dt.Columns.Add("WorkAreaName", typeof(String));
dt.Columns.Add("HotProessTrustNo", typeof(String));
dt.Columns.Add("CH_TrustMan", typeof(String));
dt.Columns.Add("WorkAreaCode", typeof(String));
dt.Columns.Add("JoinNum", typeof(String));
DataRow dr = dt.NewRow();
if (string.IsNullOrEmpty(this.HotProessTrustId))
{
Alert.ShowInTop("请选择要打印的委托单!", MessageBoxIcon.Warning);
return;
}
var hotProessTrust = BLL.HotProess_TrustService.GetHotProessTrustById(HotProessTrustId);
if (hotProessTrust != null)
{
string varValue = string.Empty;
var projectName = BLL.ProjectService.GetProjectNameByProjectId(this.CurrUser.LoginProjectId);
// var installation = BLL.Project_InstallationService.GetInstallationByInstallationId(hotProessTrust.InstallationId);
var PworkArea = Funs.DB.WBS_UnitWork .FirstOrDefault(x => x.UnitWorkId == hotProessTrust.UnitWorkId);
if (PworkArea != null)
{
//var cel = recordSheet.GetRow(3).CreateCell(1);
//cel.SetCellValue(PworkArea.WorkAreaCode);
//cel.CellStyle = styleCenter;
dr["WorkAreaName"] = PworkArea.UnitWorkName;
dr["WorkAreaCode"] = PworkArea.UnitWorkCode;
}
dr["ProjectName"] = projectName;
dr["HotProessTrustNo"] = hotProessTrust.HotProessTrustNo;
string strSql = @" select PipelineCode as ISO_IsoNo ,WeldJointCode as JOT_JointNo,Specification as JOT_JointDesc,MaterialCode from dbo.View_HJGL_HotProess_TrustItem AS Trust
WHERE Trust.HotProessTrustId=@HotProessTrustId ";
List<SqlParameter> listStr = new List<SqlParameter>();
listStr.Add(new SqlParameter("@ProjectId", hotProessTrust != null ? hotProessTrust.ProjectId : this.CurrUser.LoginProjectId));
listStr.Add(new SqlParameter("@HotProessTrustId", this.HotProessTrustId));
SqlParameter[] parameter = listStr.ToArray();
DataTable tb = SQLHelper.GetDataTableRunText(strSql, parameter);
if (tb != null)
{
tb.TableName = "data";
dr["JoinNum"] = tb.Rows.Count.ToString();
}
dt.Rows.Add(dr);
Dictionary<string, string> keyValuePairs = new Dictionary<string, string>();
keyValuePairs.Add("HotProessTrustId", HotProessTrustId);
keyValuePairs.Add("totalUnit", "赛鼎工程有限公司");
keyValuePairs.Add("ConUnit", "");
keyValuePairs.Add("supUnit", "");
var ConUnit = Funs.DB.Base_Unit.FirstOrDefault(x => x.UnitId == hotProessTrust.UnitId);
if (ConUnit != null)
{
keyValuePairs["ConUnit"] = ConUnit.UnitName;
}
var punit = ProjectUnitService.GetProjectUnitListByProjectIdUnitType(this.CurrUser.LoginProjectId, Const.ProjectUnitType_3);
if (punit.Count > 0)
{
var supUnit = Funs.DB.Base_Unit.FirstOrDefault(x => x.UnitId == punit[0].UnitId);
if (supUnit != null)
{
keyValuePairs["supUnit"] = supUnit.UnitName;
}
}
BLL.FastReportService.ResetData();
BLL.FastReportService.AddFastreportTable(dt);
BLL.FastReportService.AddFastreportParameter(keyValuePairs);
string initTemplatePath = "";
string rootPath = Server.MapPath("~/");
initTemplatePath = "File\\Fastreport\\管道焊口热处理委托单NoPic.frx";
if (File.Exists(rootPath + initTemplatePath))
{
PageContext.RegisterStartupScript(Window2.GetShowReference(String.Format("../../Controls/Fastreport.aspx?ReportPath={0}", rootPath + initTemplatePath)));
}
}
else
{
Alert.ShowInTop("请选择要打印的委托单!", MessageBoxIcon.Warning);
return;
}
}
} }
} }

View File

@ -7,10 +7,12 @@
// </自动生成> // </自动生成>
//------------------------------------------------------------------------------ //------------------------------------------------------------------------------
namespace FineUIPro.Web.HJGL.HotProcessHard { namespace FineUIPro.Web.HJGL.HotProcessHard
{
public partial class HotProessTrust { public partial class HotProessTrust
{
/// <summary> /// <summary>
/// form1 控件。 /// form1 控件。
@ -183,6 +185,15 @@ namespace FineUIPro.Web.HJGL.HotProcessHard {
/// </remarks> /// </remarks>
protected global::FineUIPro.TextBox txtIsoNo; protected global::FineUIPro.TextBox txtIsoNo;
/// <summary>
/// btnPrint 控件。
/// </summary>
/// <remarks>
/// 自动生成的字段。
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
/// </remarks>
protected global::FineUIPro.Button btnPrint;
/// <summary> /// <summary>
/// ToolbarFill2 控件。 /// ToolbarFill2 控件。
/// </summary> /// </summary>
@ -228,6 +239,15 @@ namespace FineUIPro.Web.HJGL.HotProcessHard {
/// </remarks> /// </remarks>
protected global::FineUIPro.Window Window1; protected global::FineUIPro.Window Window1;
/// <summary>
/// Window2 控件。
/// </summary>
/// <remarks>
/// 自动生成的字段。
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
/// </remarks>
protected global::FineUIPro.Window Window2;
/// <summary> /// <summary>
/// Menu1 控件。 /// Menu1 控件。
/// </summary> /// </summary>

View File

@ -105,6 +105,9 @@
<f:Label ID="lbIsAudit" Label="是否审核" runat="server" Hidden="true" <f:Label ID="lbIsAudit" Label="是否审核" runat="server" Hidden="true"
LabelWidth="105px" LabelAlign="Right"> LabelWidth="105px" LabelAlign="Right">
</f:Label> </f:Label>
<f:Button ID="Button1" Text="打印" Icon="Printer" runat="server"
OnClick="btnPrint_Click" >
</f:Button>
</Items> </Items>
</f:FormRow> </f:FormRow>
</Rows> </Rows>
@ -179,6 +182,10 @@
<f:Window ID="Window1" Title="弹出窗体" Hidden="true" EnableIFrame="true" <f:Window ID="Window1" Title="弹出窗体" Hidden="true" EnableIFrame="true"
EnableMaximize="true" Target="Top" EnableResize="false" runat="server" OnClose="Window1_Close" EnableMaximize="true" Target="Top" EnableResize="false" runat="server" OnClose="Window1_Close"
IsModal="true" Width="1050px" Height="650px"> IsModal="true" Width="1050px" Height="650px">
</f:Window>
<f:Window ID="Window2" Title="打印" Hidden="true" EnableIFrame="true"
EnableMaximize="true" Target="Top" EnableResize="false" runat="server"
IsModal="true" Width="1010px" Height="660px">
</f:Window> </f:Window>
<f:Menu ID="Menu1" runat="server"> <f:Menu ID="Menu1" runat="server">
<f:MenuButton ID="btnPointAudit" EnablePostBack="true" runat="server" Text="委托" Icon="ArrowNsew" OnClick="btnPointAudit_Click"> <f:MenuButton ID="btnPointAudit" EnablePostBack="true" runat="server" Text="委托" Icon="ArrowNsew" OnClick="btnPointAudit_Click">

View File

@ -1,8 +1,10 @@
using BLL; using BLL;
using FineUIPro.Web.HJGL.HotProcessHard;
using System; using System;
using System.Collections.Generic; using System.Collections.Generic;
using System.Data; using System.Data;
using System.Data.SqlClient; using System.Data.SqlClient;
using System.IO;
using System.Linq; using System.Linq;
using System.Web; using System.Web;
@ -550,7 +552,7 @@ namespace FineUIPro.Web.HJGL.PointTrust
} }
} }
protected void btnPrint_Click(object sender, EventArgs e) protected void btnPrint1_Click(object sender, EventArgs e)
{ {
if (CommonService.GetAllButtonPowerList(this.CurrUser.LoginProjectId, this.CurrUser.PersonId, Const.HJGL_TrustBatchMenuId, Const.BtnPrint)) if (CommonService.GetAllButtonPowerList(this.CurrUser.LoginProjectId, this.CurrUser.PersonId, Const.HJGL_TrustBatchMenuId, Const.BtnPrint))
{ {
@ -589,6 +591,380 @@ namespace FineUIPro.Web.HJGL.PointTrust
return; return;
} }
} }
protected void btnPrint_Click(object sender, EventArgs e)
{
// string reportId = this.tvControlItem.SelectedNode.NodeID;
// var trust = BLL.TrustManageEditService.GetCH_TrustByID(reportId);
DataTable dt = new DataTable("Table1");
dt.Columns.Add("ProjectName", typeof(String));
dt.Columns.Add("CH_CheckUnit", typeof(String));
dt.Columns.Add("WorkAreaName", typeof(String));
dt.Columns.Add("CH_TrustUnit", typeof(String));
dt.Columns.Add("CH_TrustMan", typeof(String));
dt.Columns.Add("CH_TrustCode", typeof(String));
dt.Columns.Add("WorkAreaCode", typeof(String));
dt.Columns.Add("CH_NDTCriteria", typeof(String));
dt.Columns.Add("CH_WeldMethod", typeof(String));
dt.Columns.Add("CH_AcceptGrade", typeof(String));
dt.Columns.Add("CH_NDTMethod", typeof(String));
dt.Columns.Add("CH_SlopeType", typeof(String));
dt.Columns.Add("CH_NDTRate", typeof(String));
DataRow dr = dt.NewRow();
if (this.tvControlItem.SelectedNode == null)
{
Alert.ShowInTop("请选择要打印的委托单!", MessageBoxIcon.Warning);
return;
}
string reportId = this.tvControlItem.SelectedNode.NodeID;
// Model.View_Batch_BatchTrust trust = BLL.Batch_BatchTrustService.GetBatchTrustViewByPointBatchId(this.tvControlItem.SelectedNodeID);
// Model.HJGL_Batch_PointBatch batch = BLL.PointBatchService.GetPointBatchById(this.tvControlItem.SelectedNodeID);
var trust = BLL.Batch_BatchTrustService.GetBatchTrustViewByPointBatchId(reportId);
if (trust != null)
{
string varValue = string.Empty;
var projectName = BLL.ProjectService.GetProjectNameByProjectId(this.CurrUser.LoginProjectId);
dr["ProjectName"] = projectName;
if (!string.IsNullOrEmpty(trust.NDEUnit))
{
dr["CH_CheckUnit"] = BLL.UnitService.GetUnitNameByUnitId(trust.NDEUnit).ToString();
}
if (!string.IsNullOrEmpty(trust.TrustBatchCode))
{
dr["CH_TrustCode"] = trust.TrustBatchCode;
}
/* if (!string.IsNullOrEmpty(trust.CH_NDTCriteria))
{
dr["CH_NDTCriteria"] = trust.CH_NDTCriteria;
}*/
if (!string.IsNullOrEmpty(trust.DetectionTypeCode))
{
dr["CH_NDTMethod"] = trust.DetectionTypeCode;
}
if (!string.IsNullOrEmpty(trust.DetectionRateId))
{
var list = BLL.Base_DetectionRateService.GetDetectionRateByDetectionRateId(trust.DetectionRateId);
if (list != null)
{
dr["CH_NDTRate"] = list.DetectionRateCode;
}
}
var PworkArea = Funs.DB.WBS_UnitWork.FirstOrDefault(x => x.UnitWorkId == trust.UnitWorkId);
if (PworkArea != null)
{
//var cel = recordSheet.GetRow(3).CreateCell(1);
//cel.SetCellValue(PworkArea.WorkAreaCode);
//cel.CellStyle = styleCenter;
dr["WorkAreaName"] = PworkArea.UnitWorkName;
dr["WorkAreaCode"] = PworkArea.UnitWorkCode;
}
dt.Rows.Add(dr);
Dictionary<string, string> keyValuePairs = new Dictionary<string, string>();
keyValuePairs.Add("TrustBatchId", trust.TrustBatchId);
keyValuePairs.Add("totalUnit", "赛鼎工程有限公司");
var unitcheck = Funs.DB.Project_ProjectUnit.FirstOrDefault(x => x.ProjectId == trust.ProjectId && x.UnitType == Const.ProjectUnitType_3);
if (unitcheck != null && !string.IsNullOrEmpty(unitcheck.UnitId))
{
keyValuePairs.Add("supUnit", BLL.UnitService.GetUnitNameByUnitId(unitcheck.UnitId).ToString());
}
/* if (!string.IsNullOrEmpty(trust.CH_CheckUnit))
{
keyValuePairs.Add("CheckUnit", BLL.UnitService.GetUnitNameByUnitId(trust.CH_CheckUnit).ToString());
}
if (!string.IsNullOrEmpty(trust.CH_TrustUnit))
{
keyValuePairs.Add("ConUnit", BLL.UnitService.GetUnitNameByUnitId(trust.CH_TrustUnit).ToString());
}
*/
BLL.FastReportService.ResetData();
BLL.FastReportService.AddFastreportTable(dt);
BLL.FastReportService.AddFastreportParameter(keyValuePairs);
// Session["Table"] = dt;
// Session["CH_TrustID"] = reportId;
string initTemplatePath = "";
string rootPath = Server.MapPath("~/");
initTemplatePath = "File\\Fastreport\\管道焊口检测委托单NoPic.frx";
if (File.Exists(rootPath + initTemplatePath))
{
PageContext.RegisterStartupScript(Window2.GetShowReference(String.Format("../../Controls/Fastreport.aspx?ReportPath={0}", rootPath + initTemplatePath)));
}
//if (trust != null)
//{
// string varValue = string.Empty;
// var projectName = BLL.ProjectService.GetProjectNameByProjectId(this.CurrUser.LoginProjectId);
// var installation = BLL.Project_InstallationService.GetInstallationByInstallationId(trust.InstallationId);
// string rootPath = Server.MapPath("~/") + Const.ExcelUrl;
// //模板文件
// string TempletFileName = Server.MapPath("~/") + "File/Excel/HJGL_DataOut/管道焊口检测委托单.xlsx";
// //导出文件
// string filePath = rootPath + DateTime.Now.ToString("yyyyMMddhhmmss") + "\\";
// if (!Directory.Exists(filePath))
// {
// Directory.CreateDirectory(filePath);
// }
// string ReportFileName = filePath + "out.xlsx";
// FileStream file = new FileStream(TempletFileName, FileMode.Open, FileAccess.Read);
// XSSFWorkbook hssfworkbook = new XSSFWorkbook(file);
// ICellStyle styleCenter = hssfworkbook.CreateCellStyle();
// styleCenter.VerticalAlignment = VerticalAlignment.Center;
// styleCenter.Alignment = HorizontalAlignment.Center;
// styleCenter.BorderLeft = BorderStyle.Thin;
// styleCenter.BorderTop = BorderStyle.Thin;
// styleCenter.BorderRight = BorderStyle.Thin;
// styleCenter.BorderBottom = BorderStyle.Thin;
// styleCenter.WrapText = true;
// IFont font = styleCenter.GetFont(hssfworkbook);
// font.Color = 10;//颜色
// font.FontHeightInPoints = 10;//字体高度与excel中的字号一致
// styleCenter.SetFont(font);
// XSSFSheet recordSheet = (XSSFSheet)hssfworkbook.GetSheet("管道焊口检测委托单");
// // recordSheet.AddMergedRegion(new CellRangeAddress(0, 0, 8, 9));
// recordSheet.GetRow(1).CreateCell(8).SetCellValue(projectName.ToString());
// recordSheet.GetRow(1).GetCell(8).CellStyle = styleCenter;
// //recordSheet.GetRow(1).CreateCell(8).SetCellValue(installation.InstallationName);
// //recordSheet.GetRow(1).GetCell(8).CellStyle = styleCenter;
// if (!string.IsNullOrEmpty(trust.CH_CheckUnit))
// {
// // recordSheet.AddMergedRegion(new CellRangeAddress(2, 2, 1, 2));
// var cel = recordSheet.GetRow(3).CreateCell(1);
// cel.SetCellValue(BLL.UnitService.GetUnitNameByUnitId(trust.CH_CheckUnit).ToString());
// cel.CellStyle = styleCenter;
// }
// if (!string.IsNullOrEmpty(trust.CH_TrustMan))
// {
// var cel = recordSheet.GetRow(3).CreateCell(5);
// cel.SetCellValue(BLL.UserService.GetUserNameByUserId(trust.CH_TrustMan));
// cel.CellStyle = styleCenter;
// }
// if (!string.IsNullOrEmpty(trust.CH_TrustCode))
// {
// var cel = recordSheet.GetRow(3).CreateCell(7);
// cel.SetCellValue(trust.CH_TrustCode);
// cel.CellStyle = styleCenter;
// }
// if (!string.IsNullOrEmpty(trust.CH_NDTCriteria))
// {
// var cel = recordSheet.GetRow(4).CreateCell(7);
// cel.SetCellValue(trust.CH_NDTCriteria);
// cel.CellStyle = styleCenter;
// }
// if (!string.IsNullOrEmpty(trust.CH_WeldMethod))
// {
// var type = BLL.Base_WeldingMethodService.GetWeldingMethodByWeldingMethodId(trust.CH_WeldMethod);
// var cel = recordSheet.GetRow(5).CreateCell(5);
// if (type != null)
// {
// cel.SetCellValue(type.WeldingMethodName);
// }
// cel.CellStyle = styleCenter;
// }
// if (!string.IsNullOrEmpty(trust.CH_AcceptGrade))
// {
// var list = BLL.TrustManageEditService.GetAcceptGradeList();
// var grade = list.FirstOrDefault(x => x.Value == trust.CH_AcceptGrade);
// var cel = recordSheet.GetRow(5).CreateCell(7);
// if (grade != null)
// {
// cel.SetCellValue(grade.Text);
// }
// cel.CellStyle = styleCenter;
// }
// if (!string.IsNullOrEmpty(trust.CH_NDTMethod))
// {
// var type = BLL.Base_DetectionTypeService.GetDetectionTypeByDetectionTypeId(trust.CH_NDTMethod);
// var cel = recordSheet.GetRow(6).CreateCell(1);
// if (type != null)
// {
// cel.SetCellValue(type.DetectionTypeName);
// }
// cel.CellStyle = styleCenter;
// }
// if (!string.IsNullOrEmpty(trust.CH_NDTRate))
// {
// var list = BLL.Base_DetectionRateService.GetNDTRateNameList();
// var rate = list.FirstOrDefault(x => x.Value == trust.CH_NDTRate);
// var cel = recordSheet.GetRow(6).CreateCell(7);
// if (rate != null)
// {
// cel.SetCellValue(rate.Text);
// }
// cel.CellStyle = styleCenter;
// }
// if (!string.IsNullOrEmpty(trust.CH_SlopeType))
// {
// var type = BLL.Base_GrooveTypeService.GetGrooveTypeByGrooveTypeId(trust.CH_SlopeType);
// var cel = recordSheet.GetRow(6).CreateCell(5);
// if (type != null)
// {
// cel.SetCellValue(type.GrooveTypeName);
// }
// cel.CellStyle = styleCenter;
// }
// string strSql = @"SELECT *
// FROM dbo.View_CH_TrustItem jot
// WHERE CH_TrustID=@CH_TrustID";
// List<SqlParameter> listStr = new List<SqlParameter>();
// listStr.Add(new SqlParameter("@CH_TrustID", tvControlItem.SelectedNodeID));
// SqlParameter[] parameter = listStr.ToArray();
// DataTable tb = SQLHelper.GetDataTableRunText(strSql, parameter);
// if (tb.Rows.Count > 0 && tb.Rows[0]["WorkAreaId"] != null)
// {
// var PworkArea = Funs.DB.ProjectData_WorkArea.FirstOrDefault(x => x.WorkAreaId == tb.Rows[0]["WorkAreaId"].ToString());
// if (PworkArea != null)
// {
// //var cel = recordSheet.GetRow(3).CreateCell(1);
// //cel.SetCellValue(PworkArea.WorkAreaCode);
// //cel.CellStyle = styleCenter;
// recordSheet.GetRow(2).CreateCell(8).SetCellValue(PworkArea.WorkAreaName);
// recordSheet.GetRow(2).GetCell(8).CellStyle = styleCenter;
// recordSheet.GetRow(4).CreateCell(1).SetCellValue(PworkArea.WorkAreaCode);
// recordSheet.GetRow(4).GetCell(1).CellStyle = styleCenter;
// }
// }
// if (tb.Rows.Count > 16)
// {
// recordSheet.ShiftRows(9, 28, tb.Rows.Count - 16);
// for (int j = 0; j < tb.Rows.Count - 16; j++)
// {
// recordSheet.CopyRow(8 + j, 9 + j);
// }
// var unit = Funs.DB.Project_ProjectUnit.FirstOrDefault(x => x.ProjectId == trust.ProjectId && x.UnitType == Const.ProjectUnitType_3);
// if (unit != null && !string.IsNullOrEmpty(unit.UnitId))
// {
// recordSheet.GetRow(20 + tb.Rows.Count - 16).GetCell(0).SetCellValue(BLL.UnitService.GetUnitNameByUnitId(unit.UnitId).ToString());
// }
// recordSheet.GetRow(20 + tb.Rows.Count - 16).GetCell(2).SetCellValue("中国天辰工程有限公司");
// if (!string.IsNullOrEmpty(trust.CH_TrustUnit))
// {
// recordSheet.GetRow(20 + tb.Rows.Count - 16).GetCell(5).SetCellValue(BLL.UnitService.GetUnitNameByUnitId(trust.CH_TrustUnit).ToString());
// }
// if (!string.IsNullOrEmpty(trust.CH_CheckUnit))
// {
// recordSheet.GetRow(20 + tb.Rows.Count - 16).CreateCell(7).SetCellValue(BLL.UnitService.GetUnitNameByUnitId(trust.CH_CheckUnit).ToString());
// }
// }
// else
// {
// var unit = Funs.DB.Project_ProjectUnit.FirstOrDefault(x => x.ProjectId == trust.ProjectId && x.UnitType == Const.ProjectUnitType_3);
// if (unit != null && !string.IsNullOrEmpty(unit.UnitId))
// {
// recordSheet.GetRow(20).GetCell(0).SetCellValue(BLL.UnitService.GetUnitNameByUnitId(unit.UnitId).ToString());
// }
// recordSheet.GetRow(20).GetCell(2).SetCellValue("中国天辰工程有限公司");
// if (!string.IsNullOrEmpty(trust.CH_TrustUnit))
// {
// recordSheet.GetRow(20).GetCell(5).SetCellValue(BLL.UnitService.GetUnitNameByUnitId(trust.CH_TrustUnit).ToString());
// }
// if (!string.IsNullOrEmpty(trust.CH_CheckUnit))
// {
// recordSheet.GetRow(20).GetCell(7).SetCellValue(BLL.UnitService.GetUnitNameByUnitId(trust.CH_CheckUnit).ToString());
// }
// }
// for (int i = 0; i < tb.Rows.Count; i++)
// {
// try
// {
// recordSheet.GetRow(8 + i).GetCell(0).SetCellValue("" + (i + 1));
// recordSheet.GetRow(8 + i).GetCell(1).SetCellValue(tb.Rows[i]["ISO_IsoNo"] != null ? tb.Rows[i]["ISO_IsoNo"].ToString() : "");
// recordSheet.GetRow(8 + i).GetCell(2).SetCellValue(tb.Rows[i]["ISO_IsoNumber"] != null ? tb.Rows[i]["ISO_IsoNumber"].ToString() : "");
// recordSheet.GetRow(8 + i).GetCell(3).SetCellValue(tb.Rows[i]["JOT_JointNo"] != null ? tb.Rows[i]["JOT_JointNo"].ToString() : "");
// //recordSheet.GetRow(7 + i).GetCell(4).SetCellValue(tb.Rows[i]["ISO_IsoNumber"] != null ? tb.Rows[i]["ISO_IsoNumber"].ToString() : "");
// recordSheet.GetRow(8 + i).GetCell(7).SetCellValue(tb.Rows[i]["STE_Name1"] != null ? tb.Rows[i]["STE_Name1"].ToString() : "");
// recordSheet.GetRow(8 + i).GetCell(6).SetCellValue(tb.Rows[i]["JOT_JointDesc"] != null ? tb.Rows[i]["JOT_JointDesc"].ToString() : "");
// string WED_Name = "";
// if (!string.IsNullOrEmpty(tb.Rows[i]["WED_Code1"].ToString()))
// WED_Name += tb.Rows[i]["WED_Code1"].ToString();
// if (!string.IsNullOrEmpty(tb.Rows[i]["WED_Code2"].ToString()) && WED_Name != tb.Rows[i]["WED_Code2"].ToString())
// WED_Name += " " + tb.Rows[i]["WED_Code2"].ToString();
// recordSheet.GetRow(8 + i).GetCell(5).SetCellValue(WED_Name);
// }
// catch (Exception)
// {
// }
// }
// using (FileStream filess = File.OpenWrite(ReportFileName))
// {
// hssfworkbook.Write(filess);
// }
// //PageContext.RegisterStartupScript(Window5.GetShowReference(String.Format("../../ReportPrint/ExReportPrint.aspx?ispop=1&reportId={0}&replaceParameter={1}&varValue={2}&projectId={3}", BLL.Const.HJGL_JointInfoReportId, isoId, varValue, this.CurrUser.LoginProjectId)));
// FileInfo filet = new FileInfo(ReportFileName);
// Response.Clear();
// Response.Charset = "GB2312";
// Response.ContentEncoding = System.Text.Encoding.UTF8;
// // 添加头信息,为"文件下载/另存为"对话框指定默认文件名
// Response.AddHeader("Content-Disposition", "attachment; filename=管道焊口检测委托单_" + Server.UrlEncode(DateTime.Now.ToString("yyyyMMddhhmmss") + ".xlsx"));
// // 添加头信息,指定文件大小,让浏览器能够显示下载进度
// Response.AddHeader("Content-Length", filet.Length.ToString());
// // 指定返回的是一个不能被客户端读取的流,必须被下载
// Response.ContentType = "application/ms-excel";
// // 把文件流发送到客户端
// Response.WriteFile(filet.FullName);
// // 停止页面的执行
// Response.End();
//}
}
else
{
Alert.ShowInTop("请选择要打印的委托单!", MessageBoxIcon.Warning);
return;
}
}
#region #region
/// <summary> /// <summary>

View File

@ -7,10 +7,12 @@
// </自动生成> // </自动生成>
//------------------------------------------------------------------------------ //------------------------------------------------------------------------------
namespace FineUIPro.Web.HJGL.PointTrust { namespace FineUIPro.Web.HJGL.PointTrust
{
public partial class TrustBatch { public partial class TrustBatch
{
/// <summary> /// <summary>
/// form1 控件。 /// form1 控件。
@ -210,6 +212,15 @@ namespace FineUIPro.Web.HJGL.PointTrust {
/// </remarks> /// </remarks>
protected global::FineUIPro.Label lbIsAudit; protected global::FineUIPro.Label lbIsAudit;
/// <summary>
/// Button1 控件。
/// </summary>
/// <remarks>
/// 自动生成的字段。
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
/// </remarks>
protected global::FineUIPro.Button Button1;
/// <summary> /// <summary>
/// Grid1 控件。 /// Grid1 控件。
/// </summary> /// </summary>
@ -255,6 +266,15 @@ namespace FineUIPro.Web.HJGL.PointTrust {
/// </remarks> /// </remarks>
protected global::FineUIPro.Window Window1; protected global::FineUIPro.Window Window1;
/// <summary>
/// Window2 控件。
/// </summary>
/// <remarks>
/// 自动生成的字段。
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
/// </remarks>
protected global::FineUIPro.Window Window2;
/// <summary> /// <summary>
/// Menu1 控件。 /// Menu1 控件。
/// </summary> /// </summary>