20221214项目劳务人员优化出入记录,新增操作日志页面呈现

This commit is contained in:
2022-12-14 14:55:56 +08:00
parent dbd41568b5
commit 944ee63433
11 changed files with 72 additions and 44 deletions
+4 -4
View File
@@ -27,14 +27,14 @@ namespace FineUIPro.Web.Personal
/// </summary>
private void BindGrid()
{
string strSql = @"SELECT sysLog.LogId,sysLog.UserId,sysLog.OperationTime,sysLog.Ip,sysLog.HostName,sysLog.OperationLog,users.UserName,units.UnitName,Project.ProjectId,Project.ProjectName"
string strSql = @"SELECT sysLog.LogId,sysLog.UserId,sysLog.OperationTime,sysLog.Ip,sysLog.HostName,sysLog.OperationLog,users.PersonName,units.UnitName,Project.ProjectId,Project.ProjectName"
+ @" FROM dbo.Sys_Log as sysLog"
+ @" LEFT JOIN Person_Persons as users ON users.UserId=sysLog.UserId "
+ @" LEFT JOIN Person_Persons as users ON users.PersonId=sysLog.UserId "
+ @" LEFT JOIN Base_Unit as units on users.UnitId=units.UnitId"
+ @" LEFT JOIN Base_Project as Project on sysLog.ProjectId=Project.ProjectId"
+ @" WHERE sysLog.UserId != '" + Const.hfnbdId + "' AND sysLog.UserId !='" + Const.sedinId + "'";
List<SqlParameter> listStr = new List<SqlParameter>();
if (this.CurrUser.PersonId != BLL.Const.sysglyId)
if (this.CurrUser.PersonId != BLL.Const.sysglyId && this.CurrUser.PersonId != BLL.Const.hfnbdId)
{
strSql += " AND sysLog.UserId = @UserId";
listStr.Add(new SqlParameter("@UserId", this.CurrUser.PersonId));
@@ -46,7 +46,7 @@ namespace FineUIPro.Web.Personal
}
if (!string.IsNullOrEmpty(this.txtUser.Text.Trim()))
{
strSql += " AND users.UserName LIKE @UserName";
strSql += " AND users.PersonName LIKE @UserName";
listStr.Add(new SqlParameter("@UserName", "%" + this.txtUser.Text.Trim() + "%"));
}
if (!string.IsNullOrEmpty(this.txtOperationLog.Text.Trim()))