This commit is contained in:
2024-03-28 09:47:22 +08:00
8 changed files with 500 additions and 104 deletions
+13 -28
View File
@@ -107,6 +107,14 @@
<HintPath>..\FineUIPro\Reference BLL\Interop.WIA.dll</HintPath>
</Reference>
<Reference Include="Microsoft.CSharp" />
<Reference Include="Microsoft.Office.Interop.Excel, Version=15.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c, processorArchitecture=MSIL">
<HintPath>..\packages\Microsoft.Office.Interop.Excel.15.0.4795.1001\lib\net20\Microsoft.Office.Interop.Excel.dll</HintPath>
<EmbedInteropTypes>True</EmbedInteropTypes>
</Reference>
<Reference Include="Microsoft.Office.Interop.Word, Version=15.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c, processorArchitecture=MSIL">
<HintPath>..\packages\Microsoft.Office.Interop.Word.15.0.4797.1004\lib\net20\Microsoft.Office.Interop.Word.dll</HintPath>
<EmbedInteropTypes>True</EmbedInteropTypes>
</Reference>
<Reference Include="Microsoft.QualityTools.Testing.Fakes, Version=12.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>
</Reference>
@@ -128,6 +136,10 @@
<Reference Include="NPOI.OpenXmlFormats, Version=2.5.6.0, Culture=neutral, PublicKeyToken=0df73ec7942b34e1, processorArchitecture=MSIL">
<HintPath>..\packages\NPOI.2.5.6\lib\net45\NPOI.OpenXmlFormats.dll</HintPath>
</Reference>
<Reference Include="Office, Version=15.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c, processorArchitecture=MSIL">
<HintPath>..\packages\MicrosoftOfficeCore.15.0.0\lib\net35\Office.dll</HintPath>
<EmbedInteropTypes>True</EmbedInteropTypes>
</Reference>
<Reference Include="RestSharp, Version=106.15.0.0, Culture=neutral, PublicKeyToken=598062e77f915f75, processorArchitecture=MSIL">
<HintPath>..\packages\RestSharp.106.15.0\lib\net452\RestSharp.dll</HintPath>
</Reference>
@@ -14441,33 +14453,6 @@
<WCFMetadata Include="Service References\" />
</ItemGroup>
<ItemGroup>
<COMReference Include="Microsoft.Office.Core">
<Guid>{2DF8D04C-5BFA-101B-BDE5-00AA0044DE52}</Guid>
<VersionMajor>2</VersionMajor>
<VersionMinor>4</VersionMinor>
<Lcid>0</Lcid>
<WrapperTool>primary</WrapperTool>
<Isolated>False</Isolated>
<EmbedInteropTypes>True</EmbedInteropTypes>
</COMReference>
<COMReference Include="Microsoft.Office.Interop.Excel">
<Guid>{00020813-0000-0000-C000-000000000046}</Guid>
<VersionMajor>1</VersionMajor>
<VersionMinor>6</VersionMinor>
<Lcid>0</Lcid>
<WrapperTool>primary</WrapperTool>
<Isolated>False</Isolated>
<EmbedInteropTypes>True</EmbedInteropTypes>
</COMReference>
<COMReference Include="Microsoft.Office.Interop.Word">
<Guid>{00020905-0000-0000-C000-000000000046}</Guid>
<VersionMajor>8</VersionMajor>
<VersionMinor>4</VersionMinor>
<Lcid>0</Lcid>
<WrapperTool>primary</WrapperTool>
<Isolated>False</Isolated>
<EmbedInteropTypes>True</EmbedInteropTypes>
</COMReference>
<COMReference Include="VBIDE">
<Guid>{0002E157-0000-0000-C000-000000000046}</Guid>
<VersionMajor>5</VersionMajor>
@@ -14488,7 +14473,7 @@
<AutoAssignPort>True</AutoAssignPort>
<DevelopmentServerPort>0</DevelopmentServerPort>
<DevelopmentServerVPath>/</DevelopmentServerVPath>
<IISUrl>http://localhost:7155/</IISUrl>
<IISUrl>http://localhost:6233/</IISUrl>
<NTLMAuthentication>False</NTLMAuthentication>
<UseCustomServer>False</UseCustomServer>
<CustomServerUrl>
@@ -6,7 +6,7 @@
<head runat="server">
<link href="~/res/css/common.css" rel="stylesheet" type="text/css" />
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<script src="~/Controls/My97DatePicker/WdatePicker.js" type="text/javascript"></script>
<script src="~/Controls/My97DatePicker/WdatePicker.js" type="text/javascript"></script>
<title>隐患整改通知单</title>
</head>
<body>
@@ -16,7 +16,7 @@
ShowHeader="false" Layout="VBox" BoxConfigAlign="Stretch">
<Items>
<f:Grid ID="Grid1" ShowBorder="true" ShowHeader="false" Title="隐患整改通知单" EnableCollapse="true"
runat="server" BoxFlex="1" DataKeyNames="RectifyNoticesId" DataIDField="RectifyNoticesId" AllowSorting="true"
runat="server" BoxFlex="1" DataKeyNames="RectifyNoticesId" DataIDField="RectifyNoticesId" AllowSorting="true"
SortField="RectifyNoticesCode" SortDirection="DESC" OnSort="Grid1_Sort" EnableColumnLines="true" AllowPaging="true"
IsDatabasePaging="true" PageSize="10" OnPageIndexChange="Grid1_PageIndexChange" ForceFit="true"
EnableRowDoubleClickEvent="true" OnRowDoubleClick="Grid1_RowDoubleClick" EnableTextSelection="True">
@@ -62,7 +62,7 @@
<f:Button ID="btnNew" Text="新增" Icon="Add" EnablePostBack="false" runat="server"
Hidden="true">
</f:Button>
<%-- <f:Button ID="btnPrint" ToolTip="打印" Icon="Printer" Hidden="true" runat="server"
<%-- <f:Button ID="btnPrint" ToolTip="打印" Icon="Printer" Hidden="true" runat="server"
OnClick="btnPrint_Click">
</f:Button>--%>
<f:Button ID="btnOut" OnClick="btnOut_Click" runat="server" ToolTip="导出" Icon="FolderUp"
@@ -115,30 +115,36 @@
<f:ToolbarText ID="ToolbarText1" runat="server" Text="每页记录数:">
</f:ToolbarText>
<f:DropDownList runat="server" ID="ddlPageSize" Width="80px" AutoPostBack="true"
OnSelectedIndexChanged="ddlPageSize_SelectedIndexChanged">
OnSelectedIndexChanged="ddlPageSize_SelectedIndexChanged">
</f:DropDownList>
</PageItems>
</f:Grid>
</Items>
</f:Panel>
<f:Window ID="Window1" Title="编辑" Hidden="true" EnableIFrame="true" EnableMaximize="true"
Target="Parent" EnableResize="false" runat="server" IsModal="true" OnClose="Window1_Close"
Target="Parent" EnableResize="false" runat="server" IsModal="true" OnClose="Window1_Close"
Width="1100px" Height="620px">
</f:Window>
<f:Menu ID="Menu1" runat="server">
<Items>
<f:MenuButton ID="btnMenuModify" EnablePostBack="true" runat="server" Hidden="true"
<f:MenuButton ID="btnMenuModify" EnablePostBack="true" runat="server" Hidden="true"
Text="编辑" Icon="Pencil" OnClick="btnMenuModify_Click">
</f:MenuButton>
<f:MenuButton ID="btnView" EnablePostBack="true" runat="server"
<f:MenuButton ID="btnView" EnablePostBack="true" runat="server"
Text="查看" Icon="Find" OnClick="btnView_Click">
</f:MenuButton>
<f:MenuButton ID="btnPrinter" EnablePostBack="true" runat="server"
<f:MenuButton ID="btnPrinter" EnablePostBack="true" runat="server"
Text="导出[通知单]" Icon="Printer" OnClick="btnPrinter_Click" EnableAjax="false" DisableControlBeforePostBack="false">
</f:MenuButton>
<f:MenuButton ID="btnPrinterReturn" EnablePostBack="true" runat="server"
<f:MenuButton ID="btnAll" EnablePostBack="true" runat="server"
Text="导出全部[通知单]" Icon="Printer" OnClick="btnAll_Click" EnableAjax="false" DisableControlBeforePostBack="false">
</f:MenuButton>
<f:MenuButton ID="btnPrinterReturn" EnablePostBack="true" runat="server"
Text="导出[反馈单]" Icon="Printer" OnClick="btnPrinterReturn_Click" EnableAjax="false" DisableControlBeforePostBack="false">
</f:MenuButton>
<f:MenuButton ID="btnAll2" EnablePostBack="true" runat="server"
Text="导出全部[反馈单]" Icon="Printer" OnClick="btnAll2_Click" EnableAjax="false" DisableControlBeforePostBack="false">
</f:MenuButton>
<f:MenuButton ID="btnMenuDel" EnablePostBack="true" runat="server" Hidden="true"
Icon="Delete" Text="删除" ConfirmText="确定删除当前数据?" OnClick="btnMenuDel_Click">
</f:MenuButton>
@@ -397,7 +397,12 @@ namespace FineUIPro.Web.HSSE.Check
Alert.ShowInTop("请至少选择一条记录!", MessageBoxIcon.Warning);
return;
}
printRectify(getRectify);
}
private void printRectify(Model.Check_RectifyNotices getRectify)
{
string rootPath = Server.MapPath("~/");
string initTemplatePath = string.Empty;
string uploadfilepath = string.Empty;
@@ -714,7 +719,7 @@ namespace FineUIPro.Web.HSSE.Check
Response.Close();
File.Delete(newUrl);
File.Delete(pdfUrl);
//PrinterDocService.PrinterDocMethod(Const.ProjectRectifyNoticesMenuId + "#1", Grid1.SelectedRowID, "隐患整改通知单");
//PrinterDocService.PrinterDocMethod(Const.ProjectRectifyNoticesMenuId + "#1", Grid1.SelectedRowID, "隐患整改通知单");
}
#endregion
@@ -1109,5 +1114,14 @@ namespace FineUIPro.Web.HSSE.Check
PageContext.RegisterStartupScript(Window1.GetShowReference(String.Format("RectifyNoticesView.aspx?RectifyNoticesId={0}", Grid1.SelectedRowID, "查看 - ")));
}
protected void btnAll_Click(object sender, EventArgs e)
{
PrinterDocService.PrinterRectifyNoticesHtmlAll(this.ProjectId,"1");
}
protected void btnAll2_Click(object sender, EventArgs e)
{
PrinterDocService.PrinterRectifyNoticesHtmlAll(this.ProjectId, "2");
}
}
}
+50 -30
View File
@@ -7,11 +7,13 @@
// </自动生成>
//------------------------------------------------------------------------------
namespace FineUIPro.Web.HSSE.Check {
public partial class RectifyNotices {
namespace FineUIPro.Web.HSSE.Check
{
public partial class RectifyNotices
{
/// <summary>
/// form1 控件。
/// </summary>
@@ -20,7 +22,7 @@ namespace FineUIPro.Web.HSSE.Check {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
/// </remarks>
protected global::System.Web.UI.HtmlControls.HtmlForm form1;
/// <summary>
/// PageManager1 控件。
/// </summary>
@@ -29,7 +31,7 @@ namespace FineUIPro.Web.HSSE.Check {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
/// </remarks>
protected global::FineUIPro.PageManager PageManager1;
/// <summary>
/// Panel1 控件。
/// </summary>
@@ -38,7 +40,7 @@ namespace FineUIPro.Web.HSSE.Check {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
/// </remarks>
protected global::FineUIPro.Panel Panel1;
/// <summary>
/// Grid1 控件。
/// </summary>
@@ -47,7 +49,7 @@ namespace FineUIPro.Web.HSSE.Check {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
/// </remarks>
protected global::FineUIPro.Grid Grid1;
/// <summary>
/// Toolbar2 控件。
/// </summary>
@@ -56,7 +58,7 @@ namespace FineUIPro.Web.HSSE.Check {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
/// </remarks>
protected global::FineUIPro.Toolbar Toolbar2;
/// <summary>
/// txtUnitName 控件。
/// </summary>
@@ -65,7 +67,7 @@ namespace FineUIPro.Web.HSSE.Check {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
/// </remarks>
protected global::FineUIPro.TextBox txtUnitName;
/// <summary>
/// txtWorkAreaName 控件。
/// </summary>
@@ -74,7 +76,7 @@ namespace FineUIPro.Web.HSSE.Check {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
/// </remarks>
protected global::FineUIPro.TextBox txtWorkAreaName;
/// <summary>
/// txtRectifyNoticesCode 控件。
/// </summary>
@@ -83,7 +85,7 @@ namespace FineUIPro.Web.HSSE.Check {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
/// </remarks>
protected global::FineUIPro.TextBox txtRectifyNoticesCode;
/// <summary>
/// Toolbar1 控件。
/// </summary>
@@ -92,7 +94,7 @@ namespace FineUIPro.Web.HSSE.Check {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
/// </remarks>
protected global::FineUIPro.Toolbar Toolbar1;
/// <summary>
/// rbStates 控件。
/// </summary>
@@ -101,7 +103,7 @@ namespace FineUIPro.Web.HSSE.Check {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
/// </remarks>
protected global::FineUIPro.RadioButtonList rbStates;
/// <summary>
/// ToolbarFill2 控件。
/// </summary>
@@ -110,7 +112,7 @@ namespace FineUIPro.Web.HSSE.Check {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
/// </remarks>
protected global::FineUIPro.ToolbarSeparator ToolbarFill2;
/// <summary>
/// rbrbHiddenHazardType 控件。
/// </summary>
@@ -119,7 +121,7 @@ namespace FineUIPro.Web.HSSE.Check {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
/// </remarks>
protected global::FineUIPro.RadioButtonList rbrbHiddenHazardType;
/// <summary>
/// ToolbarFill1 控件。
/// </summary>
@@ -128,7 +130,7 @@ namespace FineUIPro.Web.HSSE.Check {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
/// </remarks>
protected global::FineUIPro.ToolbarFill ToolbarFill1;
/// <summary>
/// btnNew 控件。
/// </summary>
@@ -137,7 +139,7 @@ namespace FineUIPro.Web.HSSE.Check {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
/// </remarks>
protected global::FineUIPro.Button btnNew;
/// <summary>
/// btnOut 控件。
/// </summary>
@@ -146,7 +148,7 @@ namespace FineUIPro.Web.HSSE.Check {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
/// </remarks>
protected global::FineUIPro.Button btnOut;
/// <summary>
/// Label2 控件。
/// </summary>
@@ -155,7 +157,7 @@ namespace FineUIPro.Web.HSSE.Check {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
/// </remarks>
protected global::System.Web.UI.WebControls.Label Label2;
/// <summary>
/// ToolbarSeparator1 控件。
/// </summary>
@@ -164,7 +166,7 @@ namespace FineUIPro.Web.HSSE.Check {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
/// </remarks>
protected global::FineUIPro.ToolbarSeparator ToolbarSeparator1;
/// <summary>
/// ToolbarText1 控件。
/// </summary>
@@ -173,7 +175,7 @@ namespace FineUIPro.Web.HSSE.Check {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
/// </remarks>
protected global::FineUIPro.ToolbarText ToolbarText1;
/// <summary>
/// ddlPageSize 控件。
/// </summary>
@@ -182,7 +184,7 @@ namespace FineUIPro.Web.HSSE.Check {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
/// </remarks>
protected global::FineUIPro.DropDownList ddlPageSize;
/// <summary>
/// Window1 控件。
/// </summary>
@@ -191,7 +193,7 @@ namespace FineUIPro.Web.HSSE.Check {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
/// </remarks>
protected global::FineUIPro.Window Window1;
/// <summary>
/// Menu1 控件。
/// </summary>
@@ -200,7 +202,7 @@ namespace FineUIPro.Web.HSSE.Check {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
/// </remarks>
protected global::FineUIPro.Menu Menu1;
/// <summary>
/// btnMenuModify 控件。
/// </summary>
@@ -209,7 +211,7 @@ namespace FineUIPro.Web.HSSE.Check {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
/// </remarks>
protected global::FineUIPro.MenuButton btnMenuModify;
/// <summary>
/// btnView 控件。
/// </summary>
@@ -218,7 +220,7 @@ namespace FineUIPro.Web.HSSE.Check {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
/// </remarks>
protected global::FineUIPro.MenuButton btnView;
/// <summary>
/// btnPrinter 控件。
/// </summary>
@@ -227,7 +229,16 @@ namespace FineUIPro.Web.HSSE.Check {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
/// </remarks>
protected global::FineUIPro.MenuButton btnPrinter;
/// <summary>
/// btnAll 控件。
/// </summary>
/// <remarks>
/// 自动生成的字段。
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
/// </remarks>
protected global::FineUIPro.MenuButton btnAll;
/// <summary>
/// btnPrinterReturn 控件。
/// </summary>
@@ -236,7 +247,16 @@ namespace FineUIPro.Web.HSSE.Check {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
/// </remarks>
protected global::FineUIPro.MenuButton btnPrinterReturn;
/// <summary>
/// btnAll2 控件。
/// </summary>
/// <remarks>
/// 自动生成的字段。
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
/// </remarks>
protected global::FineUIPro.MenuButton btnAll2;
/// <summary>
/// btnMenuDel 控件。
/// </summary>