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
+3 -3
View File
@@ -15,7 +15,7 @@
<f:Panel runat="server" ID="panelCenterRegion" RegionPosition="Center" ShowBorder="true" Layout="VBox"
ShowHeader="false" BodyPadding="5px" IconFont="PlusCircle" Title="操作日志" TitleToolTip="操作日志">
<Items>
<f:Grid ID="Grid1" ShowBorder="true" ShowHeader="false" EnableCollapse="true" runat="server"
<f:Grid ID="Grid1" ShowBorder="true" ShowHeader="false" EnableCollapse="true" runat="server" ForceFit="true"
BoxFlex="1" DataKeyNames="LogId" EnableColumnLines="true" DataIDField="LogId" AllowSorting="true" SortField="OperationTime" SortDirection="DESC"
OnSort="Grid1_Sort" AllowPaging="true" IsDatabasePaging="true" PageSize="15" OnPageIndexChange="Grid1_PageIndexChange"
EnableRowDoubleClickEvent="true" AllowFilters="true" EnableTextSelection="True">
@@ -42,7 +42,7 @@
<f:RenderField Width="240px" ColumnID="UnitName" DataField="UnitName" SortField="UnitName"
FieldType="String" HeaderText="单位" HeaderTextAlign="Center" TextAlign="Left">
</f:RenderField>
<f:RenderField Width="95px" ColumnID="UserName" DataField="UserName" SortField="UserName"
<f:RenderField Width="95px" ColumnID="PersonName" DataField="PersonName" SortField="PersonName"
FieldType="String" HeaderText="操作人员" HeaderTextAlign="Center" TextAlign="Left">
</f:RenderField>
<f:RenderField Width="250px" ColumnID="ProjectName" DataField="ProjectName" SortField="ProjectName"
@@ -52,7 +52,7 @@
TextAlign="Left" >
</f:RenderField>
<f:RenderField ColumnID="OperationLog" DataField="OperationLog" SortField="OperationLog" HeaderTextAlign="Center" TextAlign="Left"
FieldType="String" HeaderText="操作日志" Width="320px" ExpandUnusedSpace="true">
FieldType="String" HeaderText="操作日志" Width="320px" >
</f:RenderField>
</Columns>
<PageItems >
+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()))