This commit is contained in:
2025-02-24 10:10:04 +08:00
parent 4c28c0514b
commit 7484fb2ee3
15 changed files with 263 additions and 165 deletions
@@ -19,7 +19,7 @@
<Toolbars>
<f:Toolbar ID="Toolbar2" Position="Top" runat="server">
<Items>
<f:DropDownList ID="drpDepartmentIdS" runat="server" Label="Department" LabelAlign="Right" AutoPostBack="true" OnSelectedIndexChanged="Text_TextChanged"></f:DropDownList>
<f:DropDownList ID="drpTypes" runat="server" Label="Type" LabelAlign="Right" AutoPostBack="true" OnSelectedIndexChanged="Text_TextChanged"></f:DropDownList>
<f:DropDownList ID="drpDescipline" runat="server" Label="Descipline" LabelAlign="Right" AutoPostBack="true" OnSelectedIndexChanged="Text_TextChanged"></f:DropDownList>
</Items>
</f:Toolbar>
@@ -27,7 +27,7 @@
<Columns>
<f:RowNumberField EnablePagingNumber="true" Width="40px" HeaderTextAlign="Center"
TextAlign="Center" />
<f:RenderField Width="110px" ColumnID="DepartName" DataField="DepartName"
<f:RenderField Width="110px" ColumnID="DepartId" DataField="DepartId"
FieldType="String" HeaderText="Type" HeaderTextAlign="Center" TextAlign="Left">
</f:RenderField>
<f:RenderField Width="80px" ColumnID="DisciplinesWBSCode" DataField="DisciplinesWBSCode"
@@ -66,7 +66,7 @@
<Items>
<f:HiddenField ID="hfFormID" runat="server">
</f:HiddenField>
<f:DropDownList ID="drpDepartId" runat="server" Label="Type" LabelAlign="Right" LabelWidth="120px" EnableEdit="true" Required="true" ShowRedStar="true"></f:DropDownList>
<f:DropDownList ID="drpType" runat="server" Label="Type" LabelAlign="Right" LabelWidth="120px" EnableEdit="true" Required="true" ShowRedStar="true"></f:DropDownList>
<f:DropDownList ID="drpDisciplinesWBSId" runat="server" Label="Descipline" LabelAlign="Right" LabelWidth="120px" EnableEdit="true" Required="true" ShowRedStar="true" AutoPostBack="true" OnSelectedIndexChanged="drpDisciplinesWBSId_SelectedIndexChanged"></f:DropDownList>
<f:TextBox ID="txtDisciplinesWBSCode" Label="Identifier" ShowRedStar="true" Required="true"
runat="server" LabelAlign="right" LabelWidth="120px">
@@ -28,24 +28,26 @@ namespace FineUIPro.Web.BaseInfo
ddlPageSize.SelectedValue = Grid1.PageSize.ToString();
//部门(查询)
this.drpDepartmentIdS.DataTextField = "DepartName";
this.drpDepartmentIdS.DataValueField = "DepartId";
this.drpDepartmentIdS.DataSource = BLL.DepartService.GetDepartList();
this.drpDepartmentIdS.DataBind();
Funs.FineUIPleaseSelect(this.drpDepartmentIdS);
//this.drpDepartmentIdS.DataTextField = "DepartName";
//this.drpDepartmentIdS.DataValueField = "DepartId";
//this.drpDepartmentIdS.DataSource = BLL.DepartService.GetDepartList();
//this.drpDepartmentIdS.DataBind();
//Funs.FineUIPleaseSelect(this.drpDepartmentIdS);
BLL.ConstValue.InitSysConstDropDownList(this.drpTypes, "KeyQuantityType", true);
//部门
this.drpDepartId.DataTextField = "DepartName";
this.drpDepartId.DataValueField = "DepartId";
this.drpDepartId.DataSource = BLL.DepartService.GetDepartList();
this.drpDepartId.DataBind();
Funs.FineUIPleaseSelect(this.drpDepartId);
//this.drpDepartId.DataTextField = "DepartName";
//this.drpDepartId.DataValueField = "DepartId";
//this.drpDepartId.DataSource = BLL.DepartService.GetDepartList();
//this.drpDepartId.DataBind();
//Funs.FineUIPleaseSelect(this.drpDepartId);
BLL.ConstValue.InitSysConstDropDownList(this.drpType, "KeyQuantityType", false);
//专业(查询)
this.drpDescipline.DataTextField = "DisciplinesWBSName";
this.drpDescipline.DataValueField = "DisciplinesWBSId";
this.drpDescipline.DataSource = from x in Funs.DB.Base_DisciplinesWBS select x;
this.drpDepartId.DataBind();
this.drpDescipline.DataBind();
Funs.FineUIPleaseSelect(this.drpDescipline);
//专业
@@ -70,17 +72,15 @@ namespace FineUIPro.Web.BaseInfo
qua.DisciplinesWBSId,
qua.QuantityDesctiption,
qua.PlanMHRsUnit,
d.DepartName,
wbs.DisciplinesWBSCode,
wbs.DisciplinesWBSName
FROM Base_QuantityDesctiption as qua
left join Base_Depart as d on d.DepartId = qua.DepartId
left join Base_DisciplinesWBS as wbs on wbs.DisciplinesWBSId = qua.DisciplinesWBSId where 1=1";
List<SqlParameter> listStr = new List<SqlParameter>();
if (this.drpDepartmentIdS.SelectedValue != BLL.Const._Null && !string.IsNullOrEmpty(this.drpDepartmentIdS.SelectedValue))
if (this.drpTypes.SelectedValue != BLL.Const._Null && !string.IsNullOrEmpty(this.drpTypes.SelectedValue))
{
strSql += " AND qua.DepartId=@DepartId ";
listStr.Add(new SqlParameter("@DepartId", this.drpDepartmentIdS.SelectedValue));
listStr.Add(new SqlParameter("@DepartId", this.drpTypes.SelectedValue));
}
if (this.drpDescipline.SelectedValue != BLL.Const._Null && !string.IsNullOrEmpty(this.drpDescipline.SelectedValue))
{
@@ -140,7 +140,7 @@ namespace FineUIPro.Web.BaseInfo
private void EmptyText()
{
this.hfFormID.Text = string.Empty;
this.drpDepartId.SelectedValue = Const._Null;
this.drpType.SelectedValue = Const._Null;
this.drpDisciplinesWBSId.SelectedValue = Const._Null;
this.txtDisciplinesWBSCode.Text = string.Empty;
this.txtQuantityDesctiption.Text = string.Empty;
@@ -235,7 +235,7 @@ namespace FineUIPro.Web.BaseInfo
{
if (!string.IsNullOrEmpty(cons.DepartId))
{
this.drpDepartId.SelectedValue = cons.DepartId;
this.drpType.SelectedValue = cons.DepartId;
}
if (!string.IsNullOrEmpty(cons.DisciplinesWBSId))
{
@@ -273,7 +273,7 @@ namespace FineUIPro.Web.BaseInfo
ShowNotify("Please select Descipline", MessageBoxIcon.Warning);
return;
}
if (!BLL.QuantityDesctiptionService.IsExitQuantityDesctiption(this.drpDepartId.SelectedValue, this.drpDisciplinesWBSId.SelectedValue, this.txtQuantityDesctiption.Text.Trim(), strRowID))
if (!BLL.QuantityDesctiptionService.IsExitQuantityDesctiption(this.drpType.SelectedValue, this.drpDisciplinesWBSId.SelectedValue, this.txtQuantityDesctiption.Text.Trim(), strRowID))
{
Model.Base_QuantityDesctiption cons = new Model.Base_QuantityDesctiption
{
@@ -281,9 +281,9 @@ namespace FineUIPro.Web.BaseInfo
PlanMHRsUnit = Funs.GetNewDecimal(this.txtPlanMHRsUnit.Text)
};
if (this.drpDepartId.SelectedValue != BLL.Const._Null && !string.IsNullOrEmpty(this.drpDepartId.SelectedValue))
if (this.drpType.SelectedValue != BLL.Const._Null && !string.IsNullOrEmpty(this.drpType.SelectedValue))
{
cons.DepartId = this.drpDepartId.SelectedValue;
cons.DepartId = this.drpType.SelectedValue;
}
if (this.drpDisciplinesWBSId.SelectedValue != BLL.Const._Null && !string.IsNullOrEmpty(this.drpDisciplinesWBSId.SelectedValue))
{
@@ -60,13 +60,13 @@ namespace FineUIPro.Web.BaseInfo
protected global::FineUIPro.Toolbar Toolbar2;
/// <summary>
/// drpDepartmentIdS 控件。
/// drpTypes 控件。
/// </summary>
/// <remarks>
/// 自动生成的字段。
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
/// </remarks>
protected global::FineUIPro.DropDownList drpDepartmentIdS;
protected global::FineUIPro.DropDownList drpTypes;
/// <summary>
/// drpDescipline 控件。
@@ -123,13 +123,13 @@ namespace FineUIPro.Web.BaseInfo
protected global::FineUIPro.HiddenField hfFormID;
/// <summary>
/// drpDepartId 控件。
/// drpType 控件。
/// </summary>
/// <remarks>
/// 自动生成的字段。
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
/// </remarks>
protected global::FineUIPro.DropDownList drpDepartId;
protected global::FineUIPro.DropDownList drpType;
/// <summary>
/// drpDisciplinesWBSId 控件。