增加数据穿透界面
This commit is contained in:
@@ -27,6 +27,7 @@ namespace FineUIPro.Web.DataShow
|
||||
ddlPageSize.SelectedValue = Grid1.PageSize.ToString();
|
||||
// 绑定表格
|
||||
BindGrid();
|
||||
this.Panel1.Title = "工时数据(" + BLL.UnitService.GetUnitNameByUnitId(BLL.Const.UnitId_CWCEC) + ")";
|
||||
}
|
||||
}
|
||||
|
||||
@@ -35,19 +36,19 @@ namespace FineUIPro.Web.DataShow
|
||||
/// </summary>
|
||||
private void BindGrid()
|
||||
{
|
||||
string strSql = @"select DayReportId,CompileDate,ProjectId from SitePerson_DayReport WHERE 1=1 ";
|
||||
string strSql = @"select PersonInOutNumberId as DayReportId,InOutDate as CompileDate,ProjectId,WorkHours from SitePerson_PersonInOutNumber WHERE 1=1 ";
|
||||
List<SqlParameter> listStr = new List<SqlParameter>();
|
||||
strSql += " AND ProjectId = @ProjectId";
|
||||
listStr.Add(new SqlParameter("@ProjectId", Request.Params["projectId"]));
|
||||
|
||||
if (!string.IsNullOrEmpty(txtStartTime.Text.Trim()))
|
||||
{
|
||||
strSql += " AND CompileDate >= @StartTime";
|
||||
strSql += " AND InOutDate >= @StartTime";
|
||||
listStr.Add(new SqlParameter("@StartTime", this.txtStartTime.Text.Trim()));
|
||||
}
|
||||
if (!string.IsNullOrEmpty(this.txtEndTime.Text.Trim()))
|
||||
{
|
||||
strSql += " AND CompileDate <= @EndTime";
|
||||
strSql += " AND InOutDate <= @EndTime";
|
||||
listStr.Add(new SqlParameter("@EndTime", this.txtEndTime.Text.Trim()));
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user