diff --git a/DataBase/版本日志/SGGLDB_V2022-08-04-001修改明细.txt b/DataBase/版本日志/SGGLDB_V2022-08-04-001修改明细.txt
new file mode 100644
index 00000000..8c882c0f
--- /dev/null
+++ b/DataBase/版本日志/SGGLDB_V2022-08-04-001修改明细.txt
@@ -0,0 +1,4 @@
+--ADD BY YangHongwei 2022-08-04
+1、宏宜项目(许洪涛):考勤月记录校正数据方法优化。
+2、现场人员同步门禁状态重置按钮功能实现。
+--END
\ No newline at end of file
diff --git a/SGGL/BLL/OpenService/GetDataService.cs b/SGGL/BLL/OpenService/GetDataService.cs
index 72bd272c..709758fb 100644
--- a/SGGL/BLL/OpenService/GetDataService.cs
+++ b/SGGL/BLL/OpenService/GetDataService.cs
@@ -277,7 +277,7 @@ namespace BLL
var getNums = from x in db.SitePerson_PersonInOutNumber
where x.ProjectId == projectId && x.InOutDate >= dateS
orderby x.InOutDate
- select x;
+ select x;
var getInouts = from x in db.SitePerson_PersonInOut
where x.ProjectId == projectId && x.ChangeTime.Value >= dateS
select x;
@@ -289,7 +289,7 @@ namespace BLL
var getAllPersonInOutList = from x in getInouts
where x.ChangeTime > date.AddDays(-1) && x.ChangeTime < date.AddDays(1)
select x;
-
+
if (getAllPersonInOutList.Count() > 0)
{
/// 出场记录
@@ -303,13 +303,16 @@ namespace BLL
{
SafeHours = getMaxInOutDate.WorkHours ?? 0;
}
+ else
+ {
+ SafeHours = db.SitePerson_PersonInOutNumber.Where(x => x.ProjectId == projectId && x.InOutDate < dateS).Max(x => x.WorkHours) ?? 0;
+ }
}
int getOutPersonCount = getPersonOutTimes.Select(x => x.PersonId).Distinct().Count();
SafeHours += getOutPersonCount * 8;
}
-
//SafeHours = Convert.ToInt32(SafeHours * 1.0 / 60);
if (itemNum != null)
{
diff --git a/SGGL/FineUIPro.Web/HSSE/SitePerson/PersonIn.aspx.cs b/SGGL/FineUIPro.Web/HSSE/SitePerson/PersonIn.aspx.cs
index eddc9f18..79baa63b 100644
--- a/SGGL/FineUIPro.Web/HSSE/SitePerson/PersonIn.aspx.cs
+++ b/SGGL/FineUIPro.Web/HSSE/SitePerson/PersonIn.aspx.cs
@@ -1097,7 +1097,7 @@ namespace FineUIPro.Web.HSSE.SitePerson
{
Model.QualityAudit_PersonQuality newPersonQuality = new Model.QualityAudit_PersonQuality
{
- PersonQualityId = SQLHelper.GetNewID(typeof(Model.QualityAudit_PersonQuality)),
+ PersonQualityId = SQLHelper.GetNewID(),
PersonId = newPerson.PersonId,
CompileMan = this.CurrUser.UserId,
CompileDate = DateTime.Now
diff --git a/SGGL/FineUIPro.Web/HSSE/SitePerson/PersonList.aspx b/SGGL/FineUIPro.Web/HSSE/SitePerson/PersonList.aspx
index 40819d71..4a15f61c 100644
--- a/SGGL/FineUIPro.Web/HSSE/SitePerson/PersonList.aspx
+++ b/SGGL/FineUIPro.Web/HSSE/SitePerson/PersonList.aspx
@@ -67,8 +67,8 @@
-
-
+
+
@@ -77,7 +77,7 @@
+ OnSelectedIndexChanged="TextBox_TextChanged" AutoColumnWidth="true">
@@ -92,17 +92,20 @@
AutoPostBack="true" OnCheckedChanged="TextBox_TextChanged">
-
+
-
-
-
+
-
+
+
+
diff --git a/SGGL/FineUIPro.Web/HSSE/SitePerson/PersonList.aspx.cs b/SGGL/FineUIPro.Web/HSSE/SitePerson/PersonList.aspx.cs
index 3d1bc261..fa5341d9 100644
--- a/SGGL/FineUIPro.Web/HSSE/SitePerson/PersonList.aspx.cs
+++ b/SGGL/FineUIPro.Web/HSSE/SitePerson/PersonList.aspx.cs
@@ -684,5 +684,23 @@ namespace FineUIPro.Web.HSSE.SitePerson
{
this.drpPost.SelectedValueArray = Funs.RemoveDropDownListNull(this.drpPost.SelectedValueArray);
}
+
+ protected void btnPersonStates_Click(object sender, EventArgs e)
+ {
+ var getPersons = from x in Funs.DB.SitePerson_Person
+ where x.ProjectId == this.CurrUser.LoginProjectId && x.ExchangeTime.HasValue
+ select x;
+ int pcount = getPersons.Count();
+ if (pcount > 0)
+ {
+ foreach (var item in getPersons)
+ {
+ item.ExchangeTime = null;
+ item.ExchangeTime2 = null;
+ Funs.DB.SubmitChanges();
+ }
+ }
+ Alert.ShowInTop("操作完成,重置人员" + pcount.ToString() + "条", MessageBoxIcon.Success);
+ }
}
}
\ No newline at end of file
diff --git a/SGGL/FineUIPro.Web/HSSE/SitePerson/PersonList.aspx.designer.cs b/SGGL/FineUIPro.Web/HSSE/SitePerson/PersonList.aspx.designer.cs
index cff9dfb5..1b726d1d 100644
--- a/SGGL/FineUIPro.Web/HSSE/SitePerson/PersonList.aspx.designer.cs
+++ b/SGGL/FineUIPro.Web/HSSE/SitePerson/PersonList.aspx.designer.cs
@@ -7,11 +7,13 @@
// 自动生成>
//------------------------------------------------------------------------------
-namespace FineUIPro.Web.HSSE.SitePerson {
-
-
- public partial class PersonList {
-
+namespace FineUIPro.Web.HSSE.SitePerson
+{
+
+
+ public partial class PersonList
+ {
+
///
/// form1 控件。
///
@@ -20,7 +22,7 @@ namespace FineUIPro.Web.HSSE.SitePerson {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
///
protected global::System.Web.UI.HtmlControls.HtmlForm form1;
-
+
///
/// PageManager1 控件。
///
@@ -29,7 +31,7 @@ namespace FineUIPro.Web.HSSE.SitePerson {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
///
protected global::FineUIPro.PageManager PageManager1;
-
+
///
/// Panel1 控件。
///
@@ -38,7 +40,7 @@ namespace FineUIPro.Web.HSSE.SitePerson {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
///
protected global::FineUIPro.Panel Panel1;
-
+
///
/// panelLeftRegion 控件。
///
@@ -47,7 +49,7 @@ namespace FineUIPro.Web.HSSE.SitePerson {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
///
protected global::FineUIPro.Panel panelLeftRegion;
-
+
///
/// tvProjectAndUnit 控件。
///
@@ -56,7 +58,7 @@ namespace FineUIPro.Web.HSSE.SitePerson {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
///
protected global::FineUIPro.Tree tvProjectAndUnit;
-
+
///
/// Toolbar2 控件。
///
@@ -65,7 +67,7 @@ namespace FineUIPro.Web.HSSE.SitePerson {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
///
protected global::FineUIPro.Toolbar Toolbar2;
-
+
///
/// btnPersonUnit 控件。
///
@@ -74,7 +76,7 @@ namespace FineUIPro.Web.HSSE.SitePerson {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
///
protected global::FineUIPro.Button btnPersonUnit;
-
+
///
/// panelCenterRegion 控件。
///
@@ -83,7 +85,7 @@ namespace FineUIPro.Web.HSSE.SitePerson {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
///
protected global::FineUIPro.Panel panelCenterRegion;
-
+
///
/// Grid1 控件。
///
@@ -92,7 +94,7 @@ namespace FineUIPro.Web.HSSE.SitePerson {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
///
protected global::FineUIPro.Grid Grid1;
-
+
///
/// Toolbar3 控件。
///
@@ -101,7 +103,7 @@ namespace FineUIPro.Web.HSSE.SitePerson {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
///
protected global::FineUIPro.Toolbar Toolbar3;
-
+
///
/// txtPersonName 控件。
///
@@ -110,7 +112,7 @@ namespace FineUIPro.Web.HSSE.SitePerson {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
///
protected global::FineUIPro.TextBox txtPersonName;
-
+
///
/// drpPost 控件。
///
@@ -119,7 +121,7 @@ namespace FineUIPro.Web.HSSE.SitePerson {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
///
protected global::FineUIPro.DropDownList drpPost;
-
+
///
/// drpTreamGroup 控件。
///
@@ -128,7 +130,7 @@ namespace FineUIPro.Web.HSSE.SitePerson {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
///
protected global::FineUIPro.DropDownList drpTreamGroup;
-
+
///
/// txtIdentityCard 控件。
///
@@ -137,7 +139,7 @@ namespace FineUIPro.Web.HSSE.SitePerson {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
///
protected global::FineUIPro.TextBox txtIdentityCard;
-
+
///
/// btSearch 控件。
///
@@ -146,7 +148,7 @@ namespace FineUIPro.Web.HSSE.SitePerson {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
///
protected global::FineUIPro.Button btSearch;
-
+
///
/// btnNew 控件。
///
@@ -155,7 +157,7 @@ namespace FineUIPro.Web.HSSE.SitePerson {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
///
protected global::FineUIPro.Button btnNew;
-
+
///
/// Toolbar1 控件。
///
@@ -164,7 +166,7 @@ namespace FineUIPro.Web.HSSE.SitePerson {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
///
protected global::FineUIPro.Toolbar Toolbar1;
-
+
///
/// rblPost 控件。
///
@@ -173,7 +175,7 @@ namespace FineUIPro.Web.HSSE.SitePerson {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
///
protected global::FineUIPro.RadioButtonList rblPost;
-
+
///
/// ckJT 控件。
///
@@ -182,7 +184,7 @@ namespace FineUIPro.Web.HSSE.SitePerson {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
///
protected global::FineUIPro.CheckBox ckJT;
-
+
///
/// ckTrain 控件。
///
@@ -191,7 +193,7 @@ namespace FineUIPro.Web.HSSE.SitePerson {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
///
protected global::FineUIPro.CheckBox ckTrain;
-
+
///
/// ckIdCardInfoNotOK 控件。
///
@@ -200,7 +202,7 @@ namespace FineUIPro.Web.HSSE.SitePerson {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
///
protected global::FineUIPro.CheckBox ckIdCardInfoNotOK;
-
+
///
/// ToolbarFill1 控件。
///
@@ -209,7 +211,7 @@ namespace FineUIPro.Web.HSSE.SitePerson {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
///
protected global::FineUIPro.ToolbarFill ToolbarFill1;
-
+
///
/// btnPersonOut 控件。
///
@@ -218,7 +220,7 @@ namespace FineUIPro.Web.HSSE.SitePerson {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
///
protected global::FineUIPro.Button btnPersonOut;
-
+
///
/// btnImport 控件。
///
@@ -227,7 +229,7 @@ namespace FineUIPro.Web.HSSE.SitePerson {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
///
protected global::FineUIPro.Button btnImport;
-
+
///
/// btnOut 控件。
///
@@ -236,7 +238,7 @@ namespace FineUIPro.Web.HSSE.SitePerson {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
///
protected global::FineUIPro.Button btnOut;
-
+
///
/// btnQR 控件。
///
@@ -245,7 +247,16 @@ namespace FineUIPro.Web.HSSE.SitePerson {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
///
protected global::FineUIPro.Button btnQR;
-
+
+ ///
+ /// btnPersonStates 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::FineUIPro.Button btnPersonStates;
+
///
/// btnPhoto 控件。
///
@@ -254,7 +265,7 @@ namespace FineUIPro.Web.HSSE.SitePerson {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
///
protected global::FineUIPro.Button btnPhoto;
-
+
///
/// ToolbarSeparator1 控件。
///
@@ -263,7 +274,7 @@ namespace FineUIPro.Web.HSSE.SitePerson {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
///
protected global::FineUIPro.ToolbarSeparator ToolbarSeparator1;
-
+
///
/// ToolbarText1 控件。
///
@@ -272,7 +283,7 @@ namespace FineUIPro.Web.HSSE.SitePerson {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
///
protected global::FineUIPro.ToolbarText ToolbarText1;
-
+
///
/// ddlPageSize 控件。
///
@@ -281,7 +292,7 @@ namespace FineUIPro.Web.HSSE.SitePerson {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
///
protected global::FineUIPro.DropDownList ddlPageSize;
-
+
///
/// Window1 控件。
///
@@ -290,7 +301,7 @@ namespace FineUIPro.Web.HSSE.SitePerson {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
///
protected global::FineUIPro.Window Window1;
-
+
///
/// Window2 控件。
///
@@ -299,7 +310,7 @@ namespace FineUIPro.Web.HSSE.SitePerson {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
///
protected global::FineUIPro.Window Window2;
-
+
///
/// Window3 控件。
///
@@ -308,7 +319,7 @@ namespace FineUIPro.Web.HSSE.SitePerson {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
///
protected global::FineUIPro.Window Window3;
-
+
///
/// WindowPunishRecord 控件。
///
@@ -317,7 +328,7 @@ namespace FineUIPro.Web.HSSE.SitePerson {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
///
protected global::FineUIPro.Window WindowPunishRecord;
-
+
///
/// Menu1 控件。
///
@@ -326,7 +337,7 @@ namespace FineUIPro.Web.HSSE.SitePerson {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
///
protected global::FineUIPro.Menu Menu1;
-
+
///
/// btnMenuEdit 控件。
///
@@ -335,7 +346,7 @@ namespace FineUIPro.Web.HSSE.SitePerson {
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
///
protected global::FineUIPro.MenuButton btnMenuEdit;
-
+
///
/// btnMenuDelete 控件。
///
diff --git a/SGGL/FineUIPro.Web/HSSE/SitePerson/PersonListEdit.aspx b/SGGL/FineUIPro.Web/HSSE/SitePerson/PersonListEdit.aspx
index c8df8461..eced8832 100644
--- a/SGGL/FineUIPro.Web/HSSE/SitePerson/PersonListEdit.aspx
+++ b/SGGL/FineUIPro.Web/HSSE/SitePerson/PersonListEdit.aspx
@@ -99,7 +99,8 @@
-
+
diff --git a/SGGL/FineUIPro.Web/HSSE/SitePerson/PersonListEdit.aspx.cs b/SGGL/FineUIPro.Web/HSSE/SitePerson/PersonListEdit.aspx.cs
index 4be79f10..ed9dea5e 100644
--- a/SGGL/FineUIPro.Web/HSSE/SitePerson/PersonListEdit.aspx.cs
+++ b/SGGL/FineUIPro.Web/HSSE/SitePerson/PersonListEdit.aspx.cs
@@ -251,6 +251,11 @@ namespace FineUIPro.Web.HSSE.SitePerson
this.rblIsUsed.SelectedValue = "True";
this.rblIsCardUsed.SelectedValue = "True";
}
+
+ if (this.drpAuditor.SelectedValue != this.CurrUser.UserId)
+ {
+ this.txtAuditorDate.Readonly = true;
+ }
}
}
#endregion
@@ -898,5 +903,20 @@ namespace FineUIPro.Web.HSSE.SitePerson
}
}
}
+
+ ///
+ /// 审核人下拉框
+ ///
+ ///
+ ///
+ protected void drpAuditor_SelectedIndexChanged(object sender, EventArgs e)
+ {
+ this.txtAuditorDate.Readonly = false;
+ /// 当审核人为当前人是 审核时间可读
+ if (this.drpAuditor.SelectedValue != this.CurrUser.UserId)
+ {
+ this.txtAuditorDate.Readonly = true;
+ }
+ }
}
}
\ No newline at end of file