20250509 新增质量事故报告报表
This commit is contained in:
@@ -93,7 +93,7 @@
|
||||
<f:TextBox ID="txtContactPerson" runat="server" Label="合同联系人" LabelWidth="160px"></f:TextBox>
|
||||
<f:TextBox ID="txtContract_Tel" runat="server" Label="联系方式" LabelWidth="160px">
|
||||
</f:TextBox>
|
||||
<f:DropDownList ID="drpAllocation" runat="server" Label="Allocation(Y/N)" LabelAlign="Right" LabelWidth="160px">
|
||||
<f:DropDownList ID="drpAllocation" runat="server" Label="Allocation(Y/N)" LabelAlign="Right" LabelWidth="160px" Required="true" ShowRedStar="true" AutoPostBack="true" OnSelectedIndexChanged="drpAllocation_SelectedIndexChanged">
|
||||
<f:ListItem Text="-请选择" Value="0" Selected="true" />
|
||||
<f:ListItem Text="Y" Value="Y" />
|
||||
<f:ListItem Text="N" Value="N" />
|
||||
@@ -102,7 +102,7 @@
|
||||
</f:FormRow>
|
||||
<f:FormRow>
|
||||
<Items>
|
||||
<f:NumberBox ID="numProportion_of_FC_Definition" runat="server" Label="Current Allocation%" LabelWidth="160px" DecimalPrecision="2"></f:NumberBox>
|
||||
<f:NumberBox ID="numProportion_of_FC_Definition" runat="server" Label="Current Allocation%" LabelWidth="160px" DecimalPrecision="2" Required="true" ShowRedStar="true"></f:NumberBox>
|
||||
|
||||
<f:NumberBox ID="txtInitial_Budget" runat="server" Label="Initial Budget" LabelWidth="160px" NoNegative="true" EnableCommas="true" AutoPostBack="true" OnTextChanged="txtInitial_Budget_TextChanged">
|
||||
</f:NumberBox>
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
using BLL;
|
||||
using FineUIPro.Web.BaseInfo;
|
||||
using NPOI.OpenXmlFormats.Spreadsheet;
|
||||
using System;
|
||||
using System.Linq;
|
||||
@@ -57,7 +58,7 @@ namespace FineUIPro.Web.SES
|
||||
BLL.ItemService.InitDropDownList(this.drpItem, true);
|
||||
BLL.CurrencyService.InitDropDownList(this.drpCurrency, true); //币种
|
||||
BLL.FOTypeService.InitDropDownList(this.drpFOTypeId, true);
|
||||
BLL.TypeService.InitDropDownList(this.drpType, true);
|
||||
BLL.TypeService.InitDropDownList(this.drpType, true);
|
||||
|
||||
//合同员
|
||||
this.drpContract_Admin.DataTextField = "UserName";
|
||||
@@ -231,7 +232,7 @@ namespace FineUIPro.Web.SES
|
||||
}
|
||||
if (data.IfExtend.HasValue)
|
||||
{
|
||||
if (data.IfExtend==true)
|
||||
if (data.IfExtend == true)
|
||||
{
|
||||
this.drpIfExtend.SelectedValue = "True";
|
||||
this.txtPreviousFO.Enabled = true;
|
||||
@@ -450,19 +451,40 @@ namespace FineUIPro.Web.SES
|
||||
Alert.ShowInTop("Please select Const.Records!", MessageBoxIcon.Warning);
|
||||
return;
|
||||
}
|
||||
|
||||
if (this.drpAllocation.SelectedValue == "N")
|
||||
if (drpAllocation.SelectedValue == "0")
|
||||
{
|
||||
if (Funs.GetNewDecimal(numProportion_of_FC_Definition.Text) != null)
|
||||
Alert.ShowInTop("Please select Allocation(Y/N)!", MessageBoxIcon.Warning);
|
||||
return;
|
||||
}
|
||||
if (this.drpAllocation.SelectedValue == "Y")
|
||||
{
|
||||
if (!string.IsNullOrEmpty(this.numProportion_of_FC_Definition.Text.Trim()))
|
||||
{
|
||||
if (Funs.GetNewDecimal(numProportion_of_FC_Definition.Text) != 100)
|
||||
decimal d = Funs.GetNewDecimalOrZero(this.numProportion_of_FC_Definition.Text.Trim());
|
||||
if (d <= 0 || d >= 100)
|
||||
{
|
||||
Alert.ShowInTop("当Allocation选择N时,Volume Allocation应该是100%,请检查数据后再保存!", MessageBoxIcon.Warning);
|
||||
Alert.ShowInTop("当Allocation选择Y时,Volume Allocation必须是大于0或者小于100!", MessageBoxIcon.Warning);
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
else
|
||||
{
|
||||
Alert.ShowInTop("Volume Allocation不能为空!", MessageBoxIcon.Warning);
|
||||
return;
|
||||
}
|
||||
}
|
||||
//if (this.drpAllocation.SelectedValue == "N")
|
||||
//{
|
||||
// if (Funs.GetNewDecimal(numProportion_of_FC_Definition.Text) != null)
|
||||
// {
|
||||
// if (Funs.GetNewDecimal(numProportion_of_FC_Definition.Text) != 100)
|
||||
// {
|
||||
// Alert.ShowInTop("当Allocation选择N时,Volume Allocation应该是100%,请检查数据后再保存!", MessageBoxIcon.Warning);
|
||||
// return;
|
||||
// }
|
||||
// }
|
||||
|
||||
//}
|
||||
|
||||
Model.FC_SESRelatedData newData = new Model.FC_SESRelatedData();
|
||||
|
||||
@@ -749,5 +771,15 @@ namespace FineUIPro.Web.SES
|
||||
this.txtActual_Budget.Text = this.txtInitial_Budget.Text.Trim();
|
||||
}
|
||||
}
|
||||
|
||||
protected void drpAllocation_SelectedIndexChanged(object sender, EventArgs e)
|
||||
{
|
||||
//选择N时,current allocation 默认为100
|
||||
this.numProportion_of_FC_Definition.Text = string.Empty;
|
||||
if (this.drpAllocation.SelectedValue == "N")
|
||||
{
|
||||
this.numProportion_of_FC_Definition.Text = "100";
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user