diff --git a/PaintingScreen/Handler/Function.cs b/PaintingScreen/Handler/Function.cs
index c2be4af..211cbeb 100644
--- a/PaintingScreen/Handler/Function.cs
+++ b/PaintingScreen/Handler/Function.cs
@@ -384,6 +384,8 @@ namespace PaintingScreen.Handler
public static string GetMiddleTableData(string page)
{
+
+ System.Threading.Thread.Sleep(700);
string res = "";
try
{
@@ -391,20 +393,22 @@ namespace PaintingScreen.Handler
select * from tb_ReportPaintingScreen
";
DataTable dt = SqlHelper.GetDataDateTable(SqlHelper.SqlConnString, CommandType.Text, sql, null);
+ int p = dt.Rows.Count;
+ string q = page.ToString();
if (Convert.ToInt32(page) * 9 >= dt.Rows.Count)
{
//查询第一页
page = "0";
}
else
- {
+ {
//查询下一页(page+1页)
page = (Convert.ToInt32(page) + 1).ToString();
}
string queryStr = @"
declare @pageIndex int;
declare @pageSize int;
- set @pageIndex = "+ page +@";
+ set @pageIndex = " + page + @";
set @pageSize = 9;
select * from
(
@@ -421,6 +425,11 @@ namespace PaintingScreen.Handler
WHERE t.xh between @pageSize*(@pageIndex - 1)+1 and @pageSize*@pageIndex
";
DataTable dt_page = SqlHelper.GetDataDateTable(SqlHelper.SqlConnString, CommandType.Text, queryStr, null);
+ if (dt_page.Rows.Count == 0)
+ {
+ LogHelper.WriteErrLogBase(q + " " + p.ToString() + "喷涂下线合格率看板 查询条数为0,语句:" + queryStr, MethodBase.GetCurrentMethod().Name);
+
+ }
if (dt_page != null && dt_page.Rows.Count > 0)
{
res += "
";
@@ -434,7 +443,7 @@ namespace PaintingScreen.Handler
res += "";
}
res += "
";
- res += ","+ page;
+ res += "," + page;
}
return res;
}
@@ -443,6 +452,9 @@ namespace PaintingScreen.Handler
LogHelper.WriteErrLogBase("喷涂下线合格率看板-查询中间分页数据失败:" + ex.ToString(), MethodBase.GetCurrentMethod().Name);
return res;
}
+
+
+
}
#endregion
@@ -699,6 +711,7 @@ namespace PaintingScreen.Handler
string res = "";
try
{
+ System.Threading.Thread.Sleep(700);
string sql = @"
select * from tb_ReportPaintingScreen_pg
";
@@ -713,6 +726,7 @@ namespace PaintingScreen.Handler
//查询下一页(page+1页)
page = (Convert.ToInt32(page) + 1).ToString();
}
+ int ppp = 0;
string queryStr = @"
declare @pageIndex int;
declare @pageSize int;
@@ -740,6 +754,11 @@ namespace PaintingScreen.Handler
WHERE t.xh between @pageSize*(@pageIndex - 1)+1 and @pageSize*@pageIndex
";
DataTable dt_page = SqlHelper.GetDataDateTable(SqlHelper.SqlConnString, CommandType.Text, queryStr, null);
+ if(dt_page.Rows.Count == 0)
+ {
+ LogHelper.WriteErrLogBase("抛光TOP5看板-查询中间table数据为空,语句为:" + queryStr, MethodBase.GetCurrentMethod().Name);
+
+ }
if (dt_page != null && dt_page.Rows.Count > 0)
{
res += "";
diff --git a/PaintingScreen/Handler/Handler.ashx b/PaintingScreen/Handler/Handler.ashx
index 92997da..b214907 100644
--- a/PaintingScreen/Handler/Handler.ashx
+++ b/PaintingScreen/Handler/Handler.ashx
@@ -33,6 +33,7 @@ public class Handler : IHttpHandler {
break;
case "GetMiddleTableData": //PaintingResultScreen2
string page = Request.Params["page"];
+
GetMiddleTableData(page);
break;
case "CreateTablePaoGuang":
diff --git a/PaintingScreen/Manage/PaintingResultScreen2.html b/PaintingScreen/Manage/PaintingResultScreen2.html
index d3b216f..f6e9a8a 100644
--- a/PaintingScreen/Manage/PaintingResultScreen2.html
+++ b/PaintingScreen/Manage/PaintingResultScreen2.html
@@ -13,11 +13,11 @@