1
This commit is contained in:
@@ -1,8 +1,14 @@
|
||||
using BLL;
|
||||
using System;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Web;
|
||||
using System.Web.UI;
|
||||
using System.Web.UI.WebControls;
|
||||
using BLL;
|
||||
using AspNet = System.Web.UI.WebControls;
|
||||
|
||||
using System.Data;
|
||||
using System.Data.SqlClient;
|
||||
namespace FineUIPro.Web.ZHGL.DataSync.ProjectDataSync
|
||||
{
|
||||
public partial class Project_HJGLData_HJGL : PageBase
|
||||
@@ -25,16 +31,25 @@ namespace FineUIPro.Web.ZHGL.DataSync.ProjectDataSync
|
||||
/// </summary>
|
||||
private void BindGrid()
|
||||
{
|
||||
Model.Project_HJGLData_HJGL table = new Model.Project_HJGLData_HJGL();
|
||||
table.ProjectId = this.CurrUser.LoginProjectId;
|
||||
var tb = BLL.Project_HJGLData_HJGLService.getListData(table, Grid1);
|
||||
Grid1.RecordCount = Project_HJGLData_HJGLService.count;
|
||||
//tb = GetFilteredTable(Grid1.FilteredData, tb);
|
||||
Grid1.DataSource = tb;
|
||||
var list = from x in Funs.DB.View_Project_HJGLData_HJGL select x;
|
||||
if (!string.IsNullOrEmpty(txtProjectName.Text.Trim()))
|
||||
{
|
||||
list = list.Where(x => x.ProjectName.Contains(txtProjectName.Text.Trim()));
|
||||
}
|
||||
int count = list.Count();
|
||||
list = SortConditionHelper.SortingAndPaging(list, Grid1.SortField, Grid1.SortDirection, Grid1.PageIndex, Grid1.PageSize);
|
||||
|
||||
Grid1.RecordCount = count;
|
||||
Grid1.DataSource = list.ToList();
|
||||
Grid1.DataBind();
|
||||
}
|
||||
#endregion
|
||||
|
||||
protected void btSearch_Click(object sender, EventArgs e)
|
||||
{
|
||||
BindGrid();
|
||||
}
|
||||
|
||||
#region GV 数据操作
|
||||
/// <summary>
|
||||
/// 过滤表头
|
||||
@@ -176,7 +191,7 @@ namespace FineUIPro.Web.ZHGL.DataSync.ProjectDataSync
|
||||
{
|
||||
if (buttonList.Contains(BLL.Const.BtnAdd))
|
||||
{
|
||||
this.btnNew.Hidden = false;
|
||||
// this.btnNew.Hidden = false;
|
||||
}
|
||||
if (buttonList.Contains(BLL.Const.BtnModify))
|
||||
{
|
||||
@@ -202,7 +217,7 @@ namespace FineUIPro.Web.ZHGL.DataSync.ProjectDataSync
|
||||
Response.AddHeader("content-disposition", "attachment; filename=" + System.Web.HttpUtility.UrlEncode("焊接首页数据表" + filename, System.Text.Encoding.UTF8) + ".xls");
|
||||
Response.ContentType = "application/excel";
|
||||
Response.ContentEncoding = System.Text.Encoding.UTF8;
|
||||
this.Grid1.PageSize = 500;
|
||||
this.Grid1.PageSize = 10000;
|
||||
this.BindGrid();
|
||||
Response.Write(GetGridTableHtml(Grid1));
|
||||
Response.End();
|
||||
|
||||
Reference in New Issue
Block a user