diff --git a/SGGL/BLL/Transfer/PunchlistFromService.cs b/SGGL/BLL/Transfer/PunchlistFromService.cs
index c4b4c34c..63724288 100644
--- a/SGGL/BLL/Transfer/PunchlistFromService.cs
+++ b/SGGL/BLL/Transfer/PunchlistFromService.cs
@@ -1,14 +1,41 @@
-using System;
-using System.Collections.Generic;
+using System.Collections.Generic;
using System.Linq;
-using System.Text;
-using System.Threading.Tasks;
namespace BLL
{
public class PunchlistFromService
{
+ ///
+ /// Turnover System Code下拉框
+ ///
+ /// 项目id
+ /// 下拉框名字
+ /// 是否显示请选择
+ public static void InitTurnoverSystemCodeUnitDropDownList(FineUIPro.DropDownList dropName, string projectId, bool isShowPlease)
+ {
+ dropName.DataValueField = "string";
+ dropName.DataTextField = "string";
+ dropName.DataSource = GetTurnoverSystemCodeUnitDropDownList(projectId);
+ dropName.DataBind();
+ if (isShowPlease)
+ {
+ Funs.FineUIPleaseSelect(dropName);
+ }
+ }
+
+ ///
+ /// 获取Turnover System Code下拉框
+ ///
+ /// 项目id
+ ///
+ public static List GetTurnoverSystemCodeUnitDropDownList(string projectId)
+ {
+ var list = (from x in Funs.DB.Transfer_PunchlistFrom
+ where x.ProjectId == projectId
+ select x.Sub_Sys_No).Distinct().OrderBy(x => x).ToList();
+ return list;
+ }
///
/// 责任单位下拉框
@@ -18,7 +45,6 @@ namespace BLL
/// 是否显示请选择
public static void InitActionByUnitDropDownList(FineUIPro.DropDownList dropName, string projectId, bool isShowPlease)
{
- var sss = GetActionByUnitDropDownList(projectId);
dropName.DataValueField = "string";
dropName.DataTextField = "string";
dropName.DataSource = GetActionByUnitDropDownList(projectId);
diff --git a/SGGL/FineUIPro.Web/Transfer/Chart/PunchlistFromChartNew.aspx b/SGGL/FineUIPro.Web/Transfer/Chart/PunchlistFromChartNew.aspx
index 13b16f7e..c6c47af3 100644
--- a/SGGL/FineUIPro.Web/Transfer/Chart/PunchlistFromChartNew.aspx
+++ b/SGGL/FineUIPro.Web/Transfer/Chart/PunchlistFromChartNew.aspx
@@ -49,7 +49,7 @@
-
-
+ <%----%>
+
+
@@ -87,7 +89,7 @@
-
+
<%----%>
diff --git a/SGGL/FineUIPro.Web/Transfer/PunchlistFrom.aspx.cs b/SGGL/FineUIPro.Web/Transfer/PunchlistFrom.aspx.cs
index 644afa97..fe7b2ccd 100644
--- a/SGGL/FineUIPro.Web/Transfer/PunchlistFrom.aspx.cs
+++ b/SGGL/FineUIPro.Web/Transfer/PunchlistFrom.aspx.cs
@@ -31,7 +31,8 @@ namespace FineUIPro.Web.Transfer
if (!IsPostBack)
{
GetButtonPower();
- BLL.PunchlistFromService.InitActionByUnitDropDownList(this.ddlAction_By, this.CurrUser.LoginProjectId, true);
+ BLL.PunchlistFromService.InitTurnoverSystemCodeUnitDropDownList(this.drpTurnoverSystemCode, this.CurrUser.LoginProjectId, false);
+ BLL.PunchlistFromService.InitActionByUnitDropDownList(this.ddlAction_By, this.CurrUser.LoginProjectId, false);
BindGrid();
this.btnNew.OnClientClick = Window1.GetShowReference("PunchlistFromEdit.aspx") + "return false;";
@@ -58,10 +59,25 @@ namespace FineUIPro.Web.Transfer
strSql += " AND System_No like @System_No";
listStr.Add(new SqlParameter("@System_No", "%" + this.txtSystem_No.Text.Trim() + "%"));
}
- if (!string.IsNullOrEmpty(this.txtSub_Sys_No.Text.Trim()))
+ //if (!string.IsNullOrEmpty(this.txtSub_Sys_No.Text.Trim()))
+ //{
+ // strSql += " AND Sub_Sys_No like @Sub_Sys_No";
+ // listStr.Add(new SqlParameter("@Sub_Sys_No", "%" + this.txtSub_Sys_No.Text.Trim() + "%"));
+ //}
+ if (this.drpTurnoverSystemCode.SelectedItemArray.Count() > 1 || (this.drpTurnoverSystemCode.SelectedValue != BLL.Const._Null && this.drpTurnoverSystemCode.SelectedItemArray.Count() == 1))
{
- strSql += " AND Sub_Sys_No like @Sub_Sys_No";
- listStr.Add(new SqlParameter("@Sub_Sys_No", "%" + this.txtSub_Sys_No.Text.Trim() + "%"));
+ strSql += " AND (1=2 ";
+ int i = 0;
+ foreach (var item in this.drpTurnoverSystemCode.SelectedValueArray)
+ {
+ if (!string.IsNullOrEmpty(item) && item != BLL.Const._Null)
+ {
+ strSql += " OR Sub_Sys_No = @Sub_Sys_No" + i.ToString();
+ listStr.Add(new SqlParameter("@Sub_Sys_No" + i.ToString(), item));
+ }
+ i++;
+ }
+ strSql += ")";
}
//if (!string.IsNullOrEmpty(txtStartDate_Raised.Text.Trim()))
//{
@@ -123,11 +139,33 @@ namespace FineUIPro.Web.Transfer
// strSql += " AND Action_By = @Action_By";
// listStr.Add(new SqlParameter("@Action_By", txtAction_By.Text.Trim()));
//}
- if (ddlAction_By.SelectedValue != BLL.Const._Null)
+
+ //if (ddlAction_By.SelectedValue != null && ddlAction_By.SelectedValue != BLL.Const._Null)
+ //{
+ // strSql += " AND Action_By = @Action_By";
+ // listStr.Add(new SqlParameter("@Action_By", ddlAction_By.SelectedValue.Trim()));
+ //}
+ if (this.ddlAction_By.SelectedItemArray.Count() > 1 || (this.ddlAction_By.SelectedValue != BLL.Const._Null && this.ddlAction_By.SelectedItemArray.Count() == 1))
{
- strSql += " AND Action_By = @Action_By";
- listStr.Add(new SqlParameter("@Action_By", ddlAction_By.SelectedValue.Trim()));
+ strSql += " AND (1=2 ";
+ int i = 0;
+ foreach (var item in this.ddlAction_By.SelectedValueArray)
+ {
+ if (!string.IsNullOrEmpty(item) && item != BLL.Const._Null)
+ {
+ strSql += " OR Action_By = @Action_By" + i.ToString();
+ listStr.Add(new SqlParameter("@Action_By" + i.ToString(), item));
+ }
+ i++;
+ }
+ strSql += ")";
}
+
+ //if (ddlAction_By.SelectedValue != null && ddlAction_By.SelectedValue != BLL.Const._Null)
+ //{
+ // strSql += " AND Action_By = @Action_By";
+ // listStr.Add(new SqlParameter("@Action_By", ddlAction_By.SelectedValue.Trim()));
+ //}
if (!string.IsNullOrEmpty(txtPIC.Text.Trim()))
{
strSql += " AND PIC = @PIC";
diff --git a/SGGL/FineUIPro.Web/Transfer/PunchlistFrom.aspx.designer.cs b/SGGL/FineUIPro.Web/Transfer/PunchlistFrom.aspx.designer.cs
index 1ab82cbc..2962b7df 100644
--- a/SGGL/FineUIPro.Web/Transfer/PunchlistFrom.aspx.designer.cs
+++ b/SGGL/FineUIPro.Web/Transfer/PunchlistFrom.aspx.designer.cs
@@ -69,13 +69,13 @@ namespace FineUIPro.Web.Transfer
protected global::FineUIPro.TextBox txtSystem_No;
///
- /// txtSub_Sys_No 控件。
+ /// drpTurnoverSystemCode 控件。
///
///
/// 自动生成的字段。
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
///
- protected global::FineUIPro.TextBox txtSub_Sys_No;
+ protected global::FineUIPro.DropDownList drpTurnoverSystemCode;
///
/// txtRaised_By 控件。
diff --git a/SGGL/FineUIPro.Web/Web.config b/SGGL/FineUIPro.Web/Web.config
index 95acff1c..51fdae87 100644
--- a/SGGL/FineUIPro.Web/Web.config
+++ b/SGGL/FineUIPro.Web/Web.config
@@ -11,7 +11,7 @@
-
+
@@ -77,7 +77,7 @@
-
+