c1
zl!XF@JkYiDw3bRx)x;@y^gysV8Wp^n}5_z2IfX
ze&9B&KLjYb0b6wd?C}@?vkcs!zm+@e3iJS@cAh}jrpx@31t{eG6w3;9M>FW>2
zTLnPNu>tU|bs&_t3k1Gu2)xIqWl(4|EOn0o_c1YWv)gEJ2uC|MP6U_1NwBcXc(~-7
z4BF!+fbHms@U%q=^ax3XOus4MVK)^v2xh=Tt(h=dX*Qg8nG4Sn=0PWi`LNu30nFeo
z1lO2FuvLCB?DSj=w>6f6yWvu(l3M}v)yY|lmC)936|fSrpdw%m=!{znZXc5FL#5);k407N=pG<5{?=UIY`pied5K%TS|M0-Jv>fh3EoK;N(Q>VF$f
zMwG!Y-aSY%y$4U+@57Pc`*3~SeXvq~2wn9bqu!pu`6181U#9{}y1ampj#WS(FuYZK
z3A$=8;Wzg;kmg(s0il1vAi-a-e^?E;$G(HB?Dz08_5+!qXz(VhCC5MryDO(MKH9aI
zD-M&NY`sE#3y&!oPSJXyKy1}G=#c>Y(hMKtC`1fC!U7SOj9%izsc49#p@x1x_0yx;
zr&R`uVlp`_yi&0EsL5>Dcfca)xB1)>IhaX_J=xo+YRBsyMX~65&DDPn=WWSwIY%j@+(~>A}-{iwM
zO7+Bc3h*leA5qzqzmtkNV>;BA{iXao9F`+7cLYud08U~(8Hiv~RsApc6yuue;Z
zQ3&xgiNhl)ShQfM=Zdl-cQVZ<=vX-P=;3*um?^u
zPct=nT09+|0q-XspVyw(f!CSGGO{&h@R@uTU!JeXSLUnoTktjcE%~kZwzZvWyViEE
z?O8jl)~|MWEkno@$_QnJ@NWiebK4r3Cj
z`!CQyEk2D3q8|OUvSd+Z(^gm2xJPg|FOY+FZFXGeBQF6XS|FwP3Mq7r&B#aWJZ7#pH
zjjbpiCkk+j433M5j|ofQxrc>C28Z&7#KeUlzdHhYWK~f+MEPQI`Uw2vCZc!dhDdn`BZM)6WSAf|
zMf`+lgD^w1Mf{AQcypu{2up+&g3cqX5p=VL;y)m4>iiTYNZpq;KsO6x@Wh4(z3_HW
z0^WujhZ_8Lrv)+$NeN^_9C@-PfI`vlr+=V>dqVt|QS2}-RUD5u|LE3TU|s0%6TG|f
zv3#n>w@9G#E0OUcvBvwBbcs9~Zy)8B0(CnLI)KMKpGYxd(r*X+YYbs|mz-m9d`_RTx9
z@6dm15=VmvI+@Q}PB%!uy*~C>K8;({c5))2U-@ZA@pa`h@E$1Lt&IhDw1Sae$@zJ-
z8lGH=OBVlro}y{amvq{6j^?@FQ@%tR*{*b)Y^cHiEk6T$pM?V=wYu@xP4jjAy*9eg
z#_MEff!}v^;QfAl*Dld}05>n<_lyY^Jy7Jg#6aRG{GQ9w9$t0YK3ZaFQu?2$f&T-3
C5Il$g
diff --git a/SGGL/FineUIPro.Web/HSSE/Check/CheckSpecial.aspx.cs b/SGGL/FineUIPro.Web/HSSE/Check/CheckSpecial.aspx.cs
index 29002a1c..c178df09 100644
--- a/SGGL/FineUIPro.Web/HSSE/Check/CheckSpecial.aspx.cs
+++ b/SGGL/FineUIPro.Web/HSSE/Check/CheckSpecial.aspx.cs
@@ -1,4 +1,5 @@
using Aspose.Words;
+using Aspose.Words.Tables;
using BLL;
using System;
using System.Collections.Generic;
@@ -45,7 +46,7 @@ namespace FineUIPro.Web.HSSE.Check
Technique_CheckItemSetService.InitCheckItemSetDropDownList(this.drpSupCheckItemSet, "2", "0", true);
////权限按钮方法
this.GetButtonPower();
- btnNew.OnClientClick = Window1.GetShowReference("CheckSpecialEdit.aspx") + "return false;";
+ //btnNew.OnClientClick = Window1.GetShowReference("CheckSpecialEdit.aspx") + "return false;";
ddlPageSize.SelectedValue = Grid1.PageSize.ToString();
// 绑定表格
BindGrid();
@@ -203,7 +204,9 @@ namespace FineUIPro.Web.HSSE.Check
}
else
{
- PageContext.RegisterStartupScript(Window1.GetShowReference(String.Format("CheckSpecialEdit.aspx?CheckSpecialId={0}", CheckSpecialId, "编辑 - ")));
+ //PageContext.RegisterStartupScript(Window1.GetShowReference(String.Format("CheckSpecialEdit.aspx?CheckSpecialId={0}", CheckSpecialId, "编辑 - ")));
+ //pc端只有台账
+ PageContext.RegisterStartupScript(Window1.GetShowReference(String.Format("CheckSpecialView.aspx?CheckSpecialId={0}", CheckSpecialId, "查看 - ")));
}
}
}
@@ -254,7 +257,7 @@ namespace FineUIPro.Web.HSSE.Check
{
if (buttonList.Contains(BLL.Const.BtnAdd))
{
- this.btnNew.Hidden = false;
+ //this.btnNew.Hidden = false;
}
if (buttonList.Contains(BLL.Const.BtnModify))
{
@@ -357,7 +360,7 @@ namespace FineUIPro.Web.HSSE.Check
initTemplatePath = "File\\Word\\HSSE\\专项检查.doc";
uploadfilepath = rootPath + initTemplatePath;
newUrl = uploadfilepath.Replace(".doc", string.Format("{0:yyyy-MM}", DateTime.Now) + ".doc");
- filePath = initTemplatePath.Replace(".doc", string.Format("{0:yyyy-MM}", DateTime.Now) + ".pdf");
+ //filePath = initTemplatePath.Replace(".doc", string.Format("{0:yyyy-MM}", DateTime.Now) + ".pdf");
if (File.Exists(newUrl)) {
File.Delete(newUrl);
}
@@ -427,6 +430,65 @@ namespace FineUIPro.Web.HSSE.Check
}
}
+ Bookmark bookmarkWorkAreaName = doc.Range.Bookmarks["WorkAreaName"];
+ if (bookmarkWorkAreaName != null)
+ {
+ if (checkSpecial != null)
+ {
+ if (!string.IsNullOrEmpty(checkSpecial.WorkAreaId))
+ {
+ bookmarkWorkAreaName.Text = UnitWorkService.GetUnitWorkName(checkSpecial.WorkAreaId);
+ }
+
+ }
+
+ }
+
+ Bookmark bookmarkResponsibleName = doc.Range.Bookmarks["ResponsibleName"];
+ if (bookmarkResponsibleName != null)
+ {
+ if (checkSpecial != null)
+ {
+ if (!string.IsNullOrEmpty(checkSpecial.ResponsibleUnit))
+ {
+ bookmarkResponsibleName.Text = UnitService.GetUnitNameByUnitId(checkSpecial.ResponsibleUnit);
+ }
+
+ }
+
+ }
+
+ Bookmark bookmarkQuestionName = doc.Range.Bookmarks["QuestionName"];
+ if (bookmarkQuestionName != null)
+ {
+ if (checkSpecial != null)
+ {
+ if (!string.IsNullOrEmpty(checkSpecial.QuestionType))
+ {
+ bookmarkQuestionName.Text = UnitService.GetQuestionTypeId(checkSpecial.QuestionType);
+ }
+
+ }
+
+ }
+
+ Bookmark bookmarkPartInPersonNames = doc.Range.Bookmarks["PartInPersonNames"];
+ if (bookmarkPartInPersonNames != null)
+ {
+ if (checkSpecial != null)
+ {
+ if (!string.IsNullOrEmpty(checkSpecial.PartInPersonNames))
+ {
+ bookmarkPartInPersonNames.Text = checkSpecial.PartInPersonNames;
+ }
+
+ }
+
+ }
+ //WorkAreaName
+ // ResponsibleName
+ // QuestionName
+ // PartInPersonNames
//专项检查列表
Aspose.Words.DocumentBuilder builder = new Aspose.Words.DocumentBuilder(doc);
builder.MoveToBookmark("tab");
@@ -443,6 +505,57 @@ namespace FineUIPro.Web.HSSE.Check
orderby x.SortIndex
select x).ToList();
int num = 1;
+ #region 插入表头
+ builder.InsertCell();
+ builder.CellFormat.VerticalMerge = Aspose.Words.Tables.CellMerge.None;
+ builder.CellFormat.HorizontalMerge = Aspose.Words.Tables.CellMerge.First;
+ builder.CellFormat.VerticalAlignment = Aspose.Words.Tables.CellVerticalAlignment.Center;//垂直居中对齐
+ builder.ParagraphFormat.Alignment = ParagraphAlignment.Center;//水平居中对齐
+ builder.CellFormat.Width = 40;
+ builder.Write("序号");
+
+ builder.InsertCell();
+ builder.CellFormat.VerticalMerge = Aspose.Words.Tables.CellMerge.None;
+ builder.CellFormat.HorizontalMerge = Aspose.Words.Tables.CellMerge.First;
+ builder.CellFormat.VerticalAlignment = Aspose.Words.Tables.CellVerticalAlignment.Center;//垂直居中对齐
+ builder.ParagraphFormat.Alignment = ParagraphAlignment.Center;//水平居中对齐
+ builder.CellFormat.Width = 100;
+ builder.Write("问题描述");
+
+ builder.InsertCell();
+ builder.CellFormat.VerticalMerge = Aspose.Words.Tables.CellMerge.None;
+ builder.CellFormat.HorizontalMerge = Aspose.Words.Tables.CellMerge.First;
+ builder.CellFormat.VerticalAlignment = Aspose.Words.Tables.CellVerticalAlignment.Center;//垂直居中对齐
+ builder.ParagraphFormat.Alignment = ParagraphAlignment.Center;//水平居中对齐
+ builder.CellFormat.Width = 250;
+ builder.CellFormat.WrapText = true;
+ builder.Write("检查内容");
+
+ //builder.InsertCell();
+ //builder.CellFormat.VerticalMerge = Aspose.Words.Tables.CellMerge.None;
+ //builder.CellFormat.HorizontalMerge = Aspose.Words.Tables.CellMerge.First;
+ //builder.CellFormat.VerticalAlignment = Aspose.Words.Tables.CellVerticalAlignment.Center;//垂直居中对齐
+ //builder.ParagraphFormat.Alignment = ParagraphAlignment.Center;//水平居中对齐
+ //builder.CellFormat.Width = 60;
+ //builder.Write("处理结果");
+
+ builder.InsertCell();
+ builder.CellFormat.VerticalMerge = Aspose.Words.Tables.CellMerge.None;
+ builder.CellFormat.HorizontalMerge = Aspose.Words.Tables.CellMerge.First;
+ builder.CellFormat.VerticalAlignment = Aspose.Words.Tables.CellVerticalAlignment.Center;//垂直居中对齐
+ builder.ParagraphFormat.Alignment = ParagraphAlignment.Center;//水平居中对齐
+ builder.CellFormat.Width = 60;
+ builder.Write("整改期限");
+
+ builder.InsertCell();
+ builder.CellFormat.VerticalMerge = Aspose.Words.Tables.CellMerge.None;
+ builder.CellFormat.HorizontalMerge = Aspose.Words.Tables.CellMerge.First;
+ builder.CellFormat.VerticalAlignment = Aspose.Words.Tables.CellVerticalAlignment.Center;//垂直居中对齐
+ builder.ParagraphFormat.Alignment = ParagraphAlignment.Center;//水平居中对齐
+ builder.CellFormat.Width = 60;
+ builder.Write("处理措施");
+ builder.EndRow();
+ #endregion
foreach (Model.View_CheckSpecialDetail detail in checkSpecialDetails)
{
//序号
@@ -451,80 +564,89 @@ namespace FineUIPro.Web.HSSE.Check
builder.CellFormat.HorizontalMerge = Aspose.Words.Tables.CellMerge.First;
builder.CellFormat.VerticalAlignment = Aspose.Words.Tables.CellVerticalAlignment.Center;//垂直居中对齐
builder.ParagraphFormat.Alignment = ParagraphAlignment.Center;//水平居中对齐
- builder.CellFormat.Width = 20;
+ builder.CellFormat.Width = 40;
builder.Write(num.ToString());
- //单位工程
- builder.InsertCell();
- builder.CellFormat.VerticalMerge = Aspose.Words.Tables.CellMerge.None;
- builder.CellFormat.HorizontalMerge = Aspose.Words.Tables.CellMerge.First;
- builder.CellFormat.VerticalAlignment = Aspose.Words.Tables.CellVerticalAlignment.Center;//垂直居中对齐
- builder.ParagraphFormat.Alignment = ParagraphAlignment.Center;//水平居中对齐
- builder.CellFormat.Width = 55;
- builder.Write(string.IsNullOrEmpty(detail.CheckAreaName) ? "" : detail.CheckAreaName);
- //单位
- builder.InsertCell();
- builder.CellFormat.VerticalMerge = Aspose.Words.Tables.CellMerge.None;
- builder.CellFormat.HorizontalMerge = Aspose.Words.Tables.CellMerge.First;
- builder.CellFormat.VerticalAlignment = Aspose.Words.Tables.CellVerticalAlignment.Center;//垂直居中对齐
- builder.ParagraphFormat.Alignment = ParagraphAlignment.Center;//水平居中对齐
- builder.CellFormat.Width = 120;
- builder.Write(string.IsNullOrEmpty(detail.UnitName) ? "" : detail.UnitName);
+ ////单位工程
+ //builder.InsertCell();
+ //builder.CellFormat.VerticalMerge = Aspose.Words.Tables.CellMerge.None;
+ //builder.CellFormat.HorizontalMerge = Aspose.Words.Tables.CellMerge.First;
+ //builder.CellFormat.VerticalAlignment = Aspose.Words.Tables.CellVerticalAlignment.Center;//垂直居中对齐
+ //builder.ParagraphFormat.Alignment = ParagraphAlignment.Center;//水平居中对齐
+ //builder.CellFormat.Width = 60;
+ //builder.Write(string.IsNullOrEmpty(detail.CheckAreaName) ? "" : detail.CheckAreaName);
+ ////单位
+ //builder.InsertCell();
+ //builder.CellFormat.VerticalMerge = Aspose.Words.Tables.CellMerge.None;
+ //builder.CellFormat.HorizontalMerge = Aspose.Words.Tables.CellMerge.First;
+ //builder.CellFormat.VerticalAlignment = Aspose.Words.Tables.CellVerticalAlignment.Center;//垂直居中对齐
+ //builder.ParagraphFormat.Alignment = ParagraphAlignment.Center;//水平居中对齐
+ //builder.CellFormat.Width = 120;
+ //builder.Write(string.IsNullOrEmpty(detail.UnitName) ? "" : detail.UnitName);
//问题描述
builder.InsertCell();
builder.CellFormat.VerticalMerge = Aspose.Words.Tables.CellMerge.None;
builder.CellFormat.HorizontalMerge = Aspose.Words.Tables.CellMerge.First;
builder.CellFormat.VerticalAlignment = Aspose.Words.Tables.CellVerticalAlignment.Center;//垂直居中对齐
builder.ParagraphFormat.Alignment = ParagraphAlignment.Center;//水平居中对齐
- builder.CellFormat.Width = 40;
- builder.Write(string.IsNullOrEmpty(detail.Unqualified) ? "" : detail.Unqualified);
- //问题类型
- builder.InsertCell();
- builder.CellFormat.VerticalMerge = Aspose.Words.Tables.CellMerge.None;
- builder.CellFormat.HorizontalMerge = Aspose.Words.Tables.CellMerge.First;
- builder.CellFormat.VerticalAlignment = Aspose.Words.Tables.CellVerticalAlignment.Center;//垂直居中对齐
- builder.ParagraphFormat.Alignment = ParagraphAlignment.Center;//水平居中对齐
builder.CellFormat.Width = 100;
- builder.Write(string.IsNullOrEmpty(detail.CheckItemName)?"": detail.CheckItemName);
+ builder.Write(string.IsNullOrEmpty(detail.Unqualified) ? "" : detail.Unqualified);
+ //问题内容
+ builder.InsertCell();
+ builder.CellFormat.VerticalMerge = Aspose.Words.Tables.CellMerge.None;
+ builder.CellFormat.HorizontalMerge = Aspose.Words.Tables.CellMerge.First;
+ builder.CellFormat.VerticalAlignment = Aspose.Words.Tables.CellVerticalAlignment.Center;//垂直居中对齐
+ builder.ParagraphFormat.Alignment = ParagraphAlignment.Left;//水平居中对齐
+ builder.CellFormat.Width = 250;
+ builder.CellFormat.WrapText = true;
+ builder.Write(string.IsNullOrEmpty(detail.CheckItemSetContent)?"": detail.CheckItemSetContent);
- //处理结果
+ ////处理结果
+ //builder.InsertCell();
+ //builder.CellFormat.VerticalMerge = Aspose.Words.Tables.CellMerge.None;
+ //builder.CellFormat.HorizontalMerge = Aspose.Words.Tables.CellMerge.First;
+ //builder.CellFormat.VerticalAlignment = Aspose.Words.Tables.CellVerticalAlignment.Center;//垂直居中对齐
+ //builder.ParagraphFormat.Alignment = ParagraphAlignment.Center;//水平居中对齐
+ //builder.CellFormat.Width = 60;
+ //builder.Write(string.IsNullOrEmpty(detail.CompleteStatusName) ? "" : detail.CompleteStatusName);
+ //整改期限
builder.InsertCell();
builder.CellFormat.VerticalMerge = Aspose.Words.Tables.CellMerge.None;
builder.CellFormat.HorizontalMerge = Aspose.Words.Tables.CellMerge.First;
builder.CellFormat.VerticalAlignment = Aspose.Words.Tables.CellVerticalAlignment.Center;//垂直居中对齐
builder.ParagraphFormat.Alignment = ParagraphAlignment.Center;//水平居中对齐
- builder.CellFormat.Width = 50;
- builder.Write(string.IsNullOrEmpty(detail.CompleteStatusName) ? "" : detail.CompleteStatusName);
+ builder.CellFormat.Width = 60;
+ builder.Write(string.Format("{0:yyyy-MM-dd}", detail.Rectification_Date));
//隐患类别
builder.InsertCell();
builder.CellFormat.VerticalMerge = Aspose.Words.Tables.CellMerge.None;
builder.CellFormat.HorizontalMerge = Aspose.Words.Tables.CellMerge.First;
builder.CellFormat.VerticalAlignment = Aspose.Words.Tables.CellVerticalAlignment.Center;//垂直居中对齐
builder.ParagraphFormat.Alignment = ParagraphAlignment.Center;//水平居中对齐
- builder.CellFormat.Width = 50;
- builder.Write(string.IsNullOrEmpty(detail.HiddenHazardTypeName) ? "" : detail.HiddenHazardTypeName);
+ builder.CellFormat.Width = 60;
+ builder.Write(string.IsNullOrEmpty(detail.HandleStepLink) ? "" : detail.HandleStepLink);
builder.EndRow();
num++;
}
builder.EndTable();
doc.Save(newUrl);
//生成PDF文件
- string pdfUrl = newUrl.Replace(".doc", ".pdf");
+ //string pdfUrl = newUrl.Replace(".doc", ".pdf");
Document doc1 = new Aspose.Words.Document(newUrl);
//验证参数
- if (doc1 == null) { throw new Exception("Word文件无效"); }
- doc1.Save(pdfUrl, Aspose.Words.SaveFormat.Pdf);//还可以改成其它格式
- string fileName = Path.GetFileName(filePath);
- FileInfo info = new FileInfo(pdfUrl);
+ //if (doc1 == null) { throw new Exception("Word文件无效"); }
+ //doc1.Save(pdfUrl, Aspose.Words.SaveFormat.Pdf);//还可以改成其它格式
+ string fileName = Path.GetFileName(newUrl);
+ FileInfo info = new FileInfo(newUrl);
long fileSize = info.Length;
Response.Clear();
Response.ContentType = "application/x-zip-compressed";
Response.AddHeader("Content-Disposition", "attachment;filename=" + System.Web.HttpUtility.UrlEncode(fileName, System.Text.Encoding.UTF8));
Response.AddHeader("Content-Length", fileSize.ToString());
- Response.TransmitFile(pdfUrl, 0, fileSize);
+ Response.TransmitFile(newUrl, 0, fileSize);
Response.Flush();
Response.Close();
File.Delete(newUrl);
- File.Delete(pdfUrl);
+ //File.Delete(pdfUrl);
}
#endregion
}
diff --git a/SGGL/FineUIPro.Web/HSSE/Check/CheckSpecialView.aspx b/SGGL/FineUIPro.Web/HSSE/Check/CheckSpecialView.aspx
index 3e87226e..4eb70936 100644
--- a/SGGL/FineUIPro.Web/HSSE/Check/CheckSpecialView.aspx
+++ b/SGGL/FineUIPro.Web/HSSE/Check/CheckSpecialView.aspx
@@ -33,6 +33,18 @@
+
+
+
+
+
+
+
+
+
+
+
+
@@ -50,28 +62,28 @@
-
-
- --%>
+ <%--
-
- --%>
+
-
-
- --%>
+
-
-
+ --%>
//------------------------------------------------------------------------------
-namespace FineUIPro.Web.HSSE.Check {
-
-
- public partial class CheckSpecialView {
-
+namespace FineUIPro.Web.HSSE.Check
+{
+
+
+ public partial class CheckSpecialView
+ {
+
///
/// form1 控件。
///
@@ -20,7 +22,7 @@ namespace FineUIPro.Web.HSSE.Check {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
///
protected global::System.Web.UI.HtmlControls.HtmlForm form1;
-
+
///
/// PageManager1 控件。
///
@@ -29,7 +31,7 @@ namespace FineUIPro.Web.HSSE.Check {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
///
protected global::FineUIPro.PageManager PageManager1;
-
+
///
/// SimpleForm1 控件。
///
@@ -38,7 +40,7 @@ namespace FineUIPro.Web.HSSE.Check {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
///
protected global::FineUIPro.Form SimpleForm1;
-
+
///
/// txtCheckSpecialCode 控件。
///
@@ -47,7 +49,7 @@ namespace FineUIPro.Web.HSSE.Check {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
///
protected global::FineUIPro.TextBox txtCheckSpecialCode;
-
+
///
/// rbType 控件。
///
@@ -56,7 +58,7 @@ namespace FineUIPro.Web.HSSE.Check {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
///
protected global::FineUIPro.RadioButtonList rbType;
-
+
///
/// txtSupCheckItemSet 控件。
///
@@ -65,7 +67,7 @@ namespace FineUIPro.Web.HSSE.Check {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
///
protected global::FineUIPro.TextBox txtSupCheckItemSet;
-
+
///
/// txtCheckDate 控件。
///
@@ -74,7 +76,34 @@ namespace FineUIPro.Web.HSSE.Check {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
///
protected global::FineUIPro.TextBox txtCheckDate;
-
+
+ ///
+ /// txtResponsibleUnit 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::FineUIPro.TextBox txtResponsibleUnit;
+
+ ///
+ /// txtWorkAreaId 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::FineUIPro.TextBox txtWorkAreaId;
+
+ ///
+ /// txtQuestionType 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::FineUIPro.TextBox txtQuestionType;
+
///
/// txtPartInPersons 控件。
///
@@ -83,7 +112,7 @@ namespace FineUIPro.Web.HSSE.Check {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
///
protected global::FineUIPro.TextBox txtPartInPersons;
-
+
///
/// txtPartInPersonNames 控件。
///
@@ -92,7 +121,7 @@ namespace FineUIPro.Web.HSSE.Check {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
///
protected global::FineUIPro.TextBox txtPartInPersonNames;
-
+
///
/// Grid1 控件。
///
@@ -101,7 +130,7 @@ namespace FineUIPro.Web.HSSE.Check {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
///
protected global::FineUIPro.Grid Grid1;
-
+
///
/// Toolbar1 控件。
///
@@ -110,7 +139,7 @@ namespace FineUIPro.Web.HSSE.Check {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
///
protected global::FineUIPro.Toolbar Toolbar1;
-
+
///
/// lbTemp 控件。
///
@@ -119,7 +148,7 @@ namespace FineUIPro.Web.HSSE.Check {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
///
protected global::FineUIPro.Label lbTemp;
-
+
///
/// btnAttachUrl 控件。
///
@@ -128,7 +157,7 @@ namespace FineUIPro.Web.HSSE.Check {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
///
protected global::FineUIPro.Button btnAttachUrl;
-
+
///
/// ToolbarFill1 控件。
///
@@ -137,7 +166,7 @@ namespace FineUIPro.Web.HSSE.Check {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
///
protected global::FineUIPro.ToolbarFill ToolbarFill1;
-
+
///
/// btnClose 控件。
///
@@ -146,7 +175,7 @@ namespace FineUIPro.Web.HSSE.Check {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
///
protected global::FineUIPro.Button btnClose;
-
+
///
/// hdId 控件。
///
@@ -155,7 +184,7 @@ namespace FineUIPro.Web.HSSE.Check {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
///
protected global::FineUIPro.HiddenField hdId;
-
+
///
/// hdAttachUrl 控件。
///
@@ -164,7 +193,7 @@ namespace FineUIPro.Web.HSSE.Check {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
///
protected global::FineUIPro.HiddenField hdAttachUrl;
-
+
///
/// WindowAtt 控件。
///
@@ -173,7 +202,7 @@ namespace FineUIPro.Web.HSSE.Check {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
///
protected global::FineUIPro.Window WindowAtt;
-
+
///
/// Window1 控件。
///
diff --git a/SGGL/FineUIPro.Web/HSSE/InformationAnalysis/CheckAnalysis.aspx.cs b/SGGL/FineUIPro.Web/HSSE/InformationAnalysis/CheckAnalysis.aspx.cs
index 7ca15220..e1888b58 100644
--- a/SGGL/FineUIPro.Web/HSSE/InformationAnalysis/CheckAnalysis.aspx.cs
+++ b/SGGL/FineUIPro.Web/HSSE/InformationAnalysis/CheckAnalysis.aspx.cs
@@ -59,37 +59,66 @@ namespace FineUIPro.Web.HSSE.InformationAnalysis
dtCheck.Columns.Add("检查类型", typeof(string));
dtCheck.Columns.Add("数量", typeof(string));
- List newCheckAnalyseView = new List();
- var checkAnalyseView = from x in Funs.DB.View_CheckAnalysis
- where x.ProjectId == this.ProjectId
- select x;
- if (!string.IsNullOrEmpty(this.txtStarTime.Text))
- {
- checkAnalyseView = checkAnalyseView.Where(x => x.CheckTime >= Funs.GetNewDateTime(this.txtStarTime.Text));
- }
- if (!string.IsNullOrEmpty(this.txtEndTime.Text))
- {
- checkAnalyseView = checkAnalyseView.Where(x => x.CheckTime <= Funs.GetNewDateTime(this.txtEndTime.Text));
- }
- if (checkAnalyseView.Count() > 0)
- {
- foreach (var item in checkAnalyseView)
- {
- Model.SpResourceCollection view = new Model.SpResourceCollection
- {
- UnitName = BLL.Check_ProjectCheckItemSetService.ConvertCheckItemType(item.CheckItem),
- TotalCount = 1
- };
- newCheckAnalyseView.Add(view);
- }
- }
+ //List newCheckAnalyseView = new List();
+ //var checkAnalyseView = from x in Funs.DB.View_CheckAnalysis
+ // where x.ProjectId == this.ProjectId
+ // select x;
+ //if (!string.IsNullOrEmpty(this.txtStarTime.Text))
+ //{
+ // checkAnalyseView = checkAnalyseView.Where(x => x.CheckTime >= Funs.GetNewDateTime(this.txtStarTime.Text));
+ //}
+ //if (!string.IsNullOrEmpty(this.txtEndTime.Text))
+ //{
+ // checkAnalyseView = checkAnalyseView.Where(x => x.CheckTime <= Funs.GetNewDateTime(this.txtEndTime.Text));
+ //}
+ //if (checkAnalyseView.Count() > 0)
+ //{
+ // foreach (var item in checkAnalyseView)
+ // {
+ // Model.SpResourceCollection view = new Model.SpResourceCollection
+ // {
+ // UnitName = BLL.Check_ProjectCheckItemSetService.ConvertCheckItemType(item.CheckItem),
+ // TotalCount = 1
+ // };
+ // newCheckAnalyseView.Add(view);
+ // }
+ //}
- var checkType = newCheckAnalyseView.Select(x => x.UnitName).Distinct();
- foreach (var itemType in checkType)
+ //var checkType = newCheckAnalyseView.Select(x => x.UnitName).Distinct();
+ string[] TypeArray = { "HSE巡检", "专项检查", "综合检查", "开工前检查", "季节性/节假日前检查" };
+ #region 加载各项数据的子数据
+ var count1 = Funs.DB.View_Hazard_HazardRegister.Where(x => x.ProjectId == this.ProjectId).ToList().Count();
+
+ var count2 = (from x in Funs.DB.Check_CheckSpecialDetail
+ join y in Funs.DB.Check_CheckSpecial on x.CheckSpecialId equals y.CheckSpecialId
+ select x).ToList().Count();
+
+ var count3 = (from x in Funs.DB.Check_CheckColligationDetail
+ join y in Funs.DB.Check_CheckColligation on x.CheckColligationId equals y.CheckColligationId
+ where y.ProjectId == this.ProjectId
+ select x).ToList().Count();
+
+ var count4 = (from x in Funs.DB.Check_CheckWorkDetail
+ join y in Funs.DB.Check_CheckWork on x.CheckWorkId equals y.CheckWorkId
+ where y.ProjectId == this.ProjectId
+ select x).ToList().Count;
+
+ var count5 = (from x in Funs.DB.Check_CheckHolidayDetail
+ join y in Funs.DB.Check_CheckHoliday on x.CheckHolidayId equals y.CheckHolidayId
+ select x).ToList().Count();
+
+ List list = new List();
+ list.Add(new CheckAnalysisModel() { itemType = TypeArray[0], count = count1 });
+ list.Add(new CheckAnalysisModel() { itemType = TypeArray[1], count = count2 });
+ list.Add(new CheckAnalysisModel() { itemType = TypeArray[2], count = count3 });
+ list.Add(new CheckAnalysisModel() { itemType = TypeArray[3], count = count4 });
+ list.Add(new CheckAnalysisModel() { itemType = TypeArray[4], count = count5 });
+ #endregion
+ foreach (var itemType in list)
{
DataRow rowUnit = dtCheck.NewRow();
- rowUnit["检查类型"] = itemType;
- rowUnit["数量"] = newCheckAnalyseView.Where(x => x.UnitName == itemType).Count();
+ rowUnit["检查类型"] = itemType.itemType;
+ rowUnit["数量"] = itemType.count;
dtCheck.Rows.Add(rowUnit);
}
@@ -97,6 +126,11 @@ namespace FineUIPro.Web.HSSE.InformationAnalysis
this.gvCheck.DataBind();
this.ChartCostTime.CreateChart(BLL.ChartControlService.GetDataSourceChart(dtCheck, "危险因素分析", this.drpChartType.SelectedValue, 1150, 450, this.ckbShow.Checked));
}
+
+ public class CheckAnalysisModel {
+ public string itemType { get; set; }
+ public int count { get; set; }
+ }
#endregion
#region 统计查询
diff --git a/SGGL/Model/APIItem/HSSE/CheckSpecialDetailItem.cs b/SGGL/Model/APIItem/HSSE/CheckSpecialDetailItem.cs
index b5539e84..8d6f8c13 100644
--- a/SGGL/Model/APIItem/HSSE/CheckSpecialDetailItem.cs
+++ b/SGGL/Model/APIItem/HSSE/CheckSpecialDetailItem.cs
@@ -203,5 +203,9 @@ namespace Model
///
public string Rectification_Date { get; set; }
+ ///
+ /// 处理意见
+ ///
+ public string CheckOpinions { get; set; }
}
}
diff --git a/SGGL/Model/APIItem/HSSE/CheckSpecialItem.cs b/SGGL/Model/APIItem/HSSE/CheckSpecialItem.cs
index 91f4f824..bda13b16 100644
--- a/SGGL/Model/APIItem/HSSE/CheckSpecialItem.cs
+++ b/SGGL/Model/APIItem/HSSE/CheckSpecialItem.cs
@@ -180,5 +180,65 @@ namespace Model
get;
set;
}
+
+ ///
+ /// 受检单位
+ ///
+ public string ResponsibleUnit
+ {
+ get;
+ set;
+ }
+ ///
+ /// 受检单位
+ ///
+ public string ResponsibleUnitName
+ {
+ get;
+ set;
+ }
+ ///
+ /// 单位工程ID
+ ///
+ public string WorkAreaId
+ {
+ get;
+ set;
+ }
+ ///
+ /// 单位工程ID
+ ///
+ public string WorkAreaName
+ {
+ get;
+ set;
+ }
+ ///
+ /// 问题类型
+ ///
+ public string QuestionType
+ {
+ get;
+ set;
+ }
+ ///
+ /// 问题类型
+ ///
+ public string QuestionTypeName
+ {
+ get;
+ set;
+ }
+
+ ///
+ /// 审核人
+ ///
+ public string ResponsibleMan { get; set; }
+
+ ///
+ /// 审核状态
+ ///
+ public string AuditState { get; set; }
+
}
}
diff --git a/SGGL/Model/Model.cs b/SGGL/Model/Model.cs
index f3139172..339bc509 100644
--- a/SGGL/Model/Model.cs
+++ b/SGGL/Model/Model.cs
@@ -59583,6 +59583,14 @@ namespace Model
private string _CheckItemSetId;
+ private string _ResponsibleUnit;
+
+ private string _WorkAreaId;
+
+ private string _QuestionType;
+
+ private string _ResponsibleMan;
+
private EntityRef _Base_Project;
private EntityRef _Technique_CheckItemSet;
@@ -59623,6 +59631,14 @@ namespace Model
partial void OnPartInPersonNamesChanged();
partial void OnCheckItemSetIdChanging(string value);
partial void OnCheckItemSetIdChanged();
+ partial void OnResponsibleUnitChanging(string value);
+ partial void OnResponsibleUnitChanged();
+ partial void OnWorkAreaIdChanging(string value);
+ partial void OnWorkAreaIdChanged();
+ partial void OnQuestionTypeChanging(string value);
+ partial void OnQuestionTypeChanged();
+ partial void OnResponsibleManChanging(string value);
+ partial void OnResponsibleManChanged();
#endregion
public Check_CheckSpecial()
@@ -59960,6 +59976,86 @@ namespace Model
}
}
+ [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ResponsibleUnit", DbType="NVarChar(50)")]
+ public string ResponsibleUnit
+ {
+ get
+ {
+ return this._ResponsibleUnit;
+ }
+ set
+ {
+ if ((this._ResponsibleUnit != value))
+ {
+ this.OnResponsibleUnitChanging(value);
+ this.SendPropertyChanging();
+ this._ResponsibleUnit = value;
+ this.SendPropertyChanged("ResponsibleUnit");
+ this.OnResponsibleUnitChanged();
+ }
+ }
+ }
+
+ [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_WorkAreaId", DbType="NVarChar(50)")]
+ public string WorkAreaId
+ {
+ get
+ {
+ return this._WorkAreaId;
+ }
+ set
+ {
+ if ((this._WorkAreaId != value))
+ {
+ this.OnWorkAreaIdChanging(value);
+ this.SendPropertyChanging();
+ this._WorkAreaId = value;
+ this.SendPropertyChanged("WorkAreaId");
+ this.OnWorkAreaIdChanged();
+ }
+ }
+ }
+
+ [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_QuestionType", DbType="NVarChar(50)")]
+ public string QuestionType
+ {
+ get
+ {
+ return this._QuestionType;
+ }
+ set
+ {
+ if ((this._QuestionType != value))
+ {
+ this.OnQuestionTypeChanging(value);
+ this.SendPropertyChanging();
+ this._QuestionType = value;
+ this.SendPropertyChanged("QuestionType");
+ this.OnQuestionTypeChanged();
+ }
+ }
+ }
+
+ [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ResponsibleMan", DbType="NVarChar(50)")]
+ public string ResponsibleMan
+ {
+ get
+ {
+ return this._ResponsibleMan;
+ }
+ set
+ {
+ if ((this._ResponsibleMan != value))
+ {
+ this.OnResponsibleManChanging(value);
+ this.SendPropertyChanging();
+ this._ResponsibleMan = value;
+ this.SendPropertyChanged("ResponsibleMan");
+ this.OnResponsibleManChanged();
+ }
+ }
+ }
+
[global::System.Data.Linq.Mapping.AssociationAttribute(Name="FK_Check_CheckSpecial_Base_Project", Storage="_Base_Project", ThisKey="ProjectId", OtherKey="ProjectId", IsForeignKey=true)]
public Base_Project Base_Project
{
@@ -60099,6 +60195,8 @@ namespace Model
private System.Nullable _Rectification_Date;
+ private string _CheckOpinions;
+
private EntityRef _Base_Unit;
private EntityRef _WBS_UnitWork;
@@ -60151,6 +60249,8 @@ namespace Model
partial void OnCheckItemSetContentChanged();
partial void OnRectification_DateChanging(System.Nullable value);
partial void OnRectification_DateChanged();
+ partial void OnCheckOpinionsChanging(string value);
+ partial void OnCheckOpinionsChanged();
#endregion
public Check_CheckSpecialDetail()
@@ -60608,6 +60708,26 @@ namespace Model
}
}
+ [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_CheckOpinions", DbType="NVarChar(2000)")]
+ public string CheckOpinions
+ {
+ get
+ {
+ return this._CheckOpinions;
+ }
+ set
+ {
+ if ((this._CheckOpinions != value))
+ {
+ this.OnCheckOpinionsChanging(value);
+ this.SendPropertyChanging();
+ this._CheckOpinions = value;
+ this.SendPropertyChanged("CheckOpinions");
+ this.OnCheckOpinionsChanged();
+ }
+ }
+ }
+
[global::System.Data.Linq.Mapping.AssociationAttribute(Name="FK_Check_CheckSpecialDetail_Base_Unit", Storage="_Base_Unit", ThisKey="UnitId", OtherKey="UnitId", IsForeignKey=true)]
public Base_Unit Base_Unit
{
diff --git a/SGGL/WebAPI/Controllers/PersonController.cs b/SGGL/WebAPI/Controllers/PersonController.cs
index 71118084..a146cd00 100644
--- a/SGGL/WebAPI/Controllers/PersonController.cs
+++ b/SGGL/WebAPI/Controllers/PersonController.cs
@@ -1083,5 +1083,28 @@ namespace WebAPI.Controllers
return responeData;
}
#endregion
+
+ #region 二维码扫码获取人员
+ ///
+ /// 二维码扫码获取人员
+ ///
+ ///
+ ///
+ public Model.ResponeData getPersonByPersonIdQrcode(string personId)
+ {
+ var responeData = new Model.ResponeData();
+ try
+ {
+ responeData.data = APIPersonService.getPersonByPersonIdQrcode(personId);
+ }
+ catch (Exception ex)
+ {
+ responeData.code = 0;
+ responeData.message = ex.Message;
+ }
+
+ return responeData;
+ }
+ #endregion
}
}
\ No newline at end of file