检验批委托速度优化
This commit is contained in:
@@ -72,20 +72,22 @@ namespace FineUIPro.Web.common.ProjectSet
|
||||
{
|
||||
//string unitid = this.tvUnit.SelectedNodeID;
|
||||
|
||||
string strSql = @"SELECT WED_ID,WED_Code, WED_Name FROM dbo.HJGL_BS_Welder
|
||||
WHERE WED_ID NOT IN(SELECT WED_ID FROM Project_Welder WHERE ProjectId =@ProjectId)
|
||||
AND IsOAM=1";
|
||||
string strSql = @"SELECT W.WED_ID, W.WED_Code, W.WED_Name
|
||||
FROM dbo.HJGL_BS_Welder W
|
||||
LEFT JOIN Project_Welder PW ON W.WED_ID = PW.WED_ID AND PW.ProjectId = @ProjectId
|
||||
WHERE PW.WED_ID IS NULL
|
||||
AND W.IsOAM = 1 ";
|
||||
List<SqlParameter> listStr = new List<SqlParameter>();
|
||||
listStr.Add(new SqlParameter("@ProjectId", ProjectId));
|
||||
|
||||
if (!string.IsNullOrEmpty(txtWeldCode.Text))
|
||||
{
|
||||
strSql += " AND WED_Code LIKE @WED_Code";
|
||||
strSql += " AND W.WED_Code LIKE @WED_Code";
|
||||
listStr.Add(new SqlParameter("@WED_Code", "%" + this.txtWeldCode.Text.Trim() + "%"));
|
||||
}
|
||||
if (!string.IsNullOrEmpty(this.txtWeldName.Text))
|
||||
{
|
||||
strSql += " AND WED_Name LIKE @WED_Name";
|
||||
strSql += " AND W.WED_Name LIKE @WED_Name";
|
||||
listStr.Add(new SqlParameter("@WED_Name", "%" + this.txtWeldName.Text.Trim() + "%"));
|
||||
}
|
||||
SqlParameter[] parameter = listStr.ToArray();
|
||||
|
||||
Reference in New Issue
Block a user