This commit is contained in:
2021-05-20 17:16:01 +08:00
parent f901e87a6e
commit e7cb804684
219 changed files with 17315 additions and 1571 deletions
@@ -2,6 +2,7 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
@@ -229,23 +230,21 @@ namespace FineUIPro.Web.CQMS.ProcessControl
protected void btnOut_Click(object sender, EventArgs e)
{
DateTime dt = DateTime.Now;
string filename = dt.Year.ToString() + dt.Month.ToString() + dt.Day.ToString() + dt.Hour.ToString() + dt.Minute.ToString() + dt.Second.ToString();
Response.Clear();
Response.Buffer = true;
Response.Charset = "GB2312";
Response.ContentEncoding = System.Text.Encoding.UTF8;
Response.Write("<meta http-equiv=Content-Type content=text/html;charset=UTF-8>");
Response.AppendHeader("Content-Disposition", "attachment;filename=" + System.Web.HttpUtility.UrlEncode("控制点检查检测合格率统计" + filename, System.Text.Encoding.UTF8) + ".xls");
Response.ContentType = "application/ms-excel";
this.EnableViewState = false;
System.IO.StringWriter oStringWriter = new System.IO.StringWriter();
System.Web.UI.HtmlTextWriter oHtmlTextWriter = new System.Web.UI.HtmlTextWriter(oStringWriter);
this.Grid1.RenderControl(oHtmlTextWriter);
Response.Write(oStringWriter.ToString());
Response.Flush();
Response.ClearContent();
string filename = Funs.GetNewFileName();
Response.AddHeader("content-disposition", "attachment; filename=" + System.Web.HttpUtility.UrlEncode("控制点检查检测合格率统计" + filename, System.Text.Encoding.UTF8) + ".xls");
Response.ContentType = "application/excel";
Response.ContentEncoding = Encoding.UTF8;
this.Grid1.PageSize = Grid1.RecordCount;
if (this.drpCNProfessional.SelectedValue != BLL.Const._Null)
{
BindGvInspectionManagement(this.drpCNProfessional.SelectedValue);
}
else
{
BindGvInspectionManagement(null);
}
Response.Write(GetGridTableHtml2(Grid1));
Response.End();
}
}