提交代码

This commit is contained in:
2025-05-12 10:20:13 +08:00
parent 3b18178e30
commit a75ba9f44a
12 changed files with 185 additions and 41 deletions
@@ -19,6 +19,9 @@ namespace FineUIPro.Web.CQMS.QuantityManagement
{
if (!IsPostBack)
{
BLL.DrawingService.InitDrawingChangeDropDownList(drpDrawingNo, this.CurrUser.LoginProjectId, true);
BLL.BaseService.InitAllPartDropDownList(this.drpPart, this.CurrUser.LoginProjectId, true);
BLL.BaseService.InitAllProjectContentDropDownList(this.drpProjectContent, this.CurrUser.LoginProjectId, true);
GetButtonPower();
BindGrid();
}
@@ -33,20 +36,20 @@ namespace FineUIPro.Web.CQMS.QuantityManagement
where C.ProjectId = @ProjectId";
List<SqlParameter> listStr = new List<SqlParameter>();
listStr.Add(new SqlParameter("@ProjectId", this.CurrUser.LoginProjectId));
if (!string.IsNullOrEmpty(this.txtDrawingNo.Text.Trim()))
if (this.drpDrawingNo.SelectedValue != BLL.Const._Null)
{
strSql += " AND DrawingNo like @DrawingNo";
listStr.Add(new SqlParameter("@DrawingNo", "%" + this.txtDrawingNo.Text.Trim() + "%"));
strSql += " AND DrawingId = @DrawingId";
listStr.Add(new SqlParameter("@DrawingId", this.drpDrawingNo.SelectedValue));
}
if (!string.IsNullOrEmpty(this.txtPart.Text.Trim()))
if (this.drpPart.SelectedValue != BLL.Const._Null)
{
strSql += " AND Part like @Part";
listStr.Add(new SqlParameter("@Part", "%" + this.txtPart.Text.Trim() + "%"));
strSql += " AND Part = @Part";
listStr.Add(new SqlParameter("@Part", this.drpPart.SelectedItem.Text));
}
if (!string.IsNullOrEmpty(this.txtProjectContent.Text.Trim()))
if (this.drpProjectContent.SelectedValue != BLL.Const._Null)
{
strSql += " AND ProjectContent like @ProjectContent";
listStr.Add(new SqlParameter("@ProjectContent", "%" + this.txtProjectContent.Text.Trim() + "%"));
strSql += " AND ProjectContent = @ProjectContent";
listStr.Add(new SqlParameter("@ProjectContent", this.drpProjectContent.SelectedItem.Text));
}
SqlParameter[] parameter = listStr.ToArray();
DataTable tb = SQLHelper.GetDataTableRunText(strSql, parameter);