提交代码

This commit is contained in:
2023-11-24 18:29:30 +08:00
parent 00db9731bf
commit 3aeb7e47de
12 changed files with 541 additions and 27 deletions
@@ -34,7 +34,7 @@ namespace FineUIPro.Web.HJGL.WeldingManage
ViewState["WeldJointId"] = value;
}
}
protected void Page_Load(object sender, EventArgs e)
{
@@ -235,10 +235,10 @@ namespace FineUIPro.Web.HJGL.WeldingManage
//string perfix = txtPipelineCode.Text + "/Z-";
string perfix = txtPipelineCode.Text + "/";
this.txtWeldJointCode.Text = perfix;
// txtWeldJointCode.Text = BLL.SQLHelper.RunProcNewIdByProjectId("SpGetNewCode4ByProjectId", "dbo.HJGL_WeldJoint", "WeldJointCode", this.CurrUser.LoginProjectId, perfix);
// txtWeldJointCode.Text = txtWeldJointCode.Text.Replace(perfix, "");
// txtWeldJointCode.Text = BLL.SQLHelper.RunProcNewIdByProjectId("SpGetNewCode4ByProjectId", "dbo.HJGL_WeldJoint", "WeldJointCode", this.CurrUser.LoginProjectId, perfix);
// txtWeldJointCode.Text = txtWeldJointCode.Text.Replace(perfix, "");
}
}
@@ -322,7 +322,7 @@ namespace FineUIPro.Web.HJGL.WeldingManage
/// </summary>
private void SaveData()
{
// if (string.IsNullOrEmpty(this.txtWeldJointCode.Text.Trim()) || this.drpPipingClass.SelectedValue == BLL.Const._Null || this.drpMaterial1.SelectedValue == BLL.Const._Null || this.drpMaterial2.SelectedValue == BLL.Const._Null || this.drpWeldTypeCode.SelectedValue == BLL.Const._Null || string.IsNullOrEmpty(this.hdWeldingMethodId.Text) || string.IsNullOrEmpty(this.txtWpqId.Text.Trim()))
// if (string.IsNullOrEmpty(this.txtWeldJointCode.Text.Trim()) || this.drpPipingClass.SelectedValue == BLL.Const._Null || this.drpMaterial1.SelectedValue == BLL.Const._Null || this.drpMaterial2.SelectedValue == BLL.Const._Null || this.drpWeldTypeCode.SelectedValue == BLL.Const._Null || string.IsNullOrEmpty(this.hdWeldingMethodId.Text) || string.IsNullOrEmpty(this.txtWpqId.Text.Trim()))
if (string.IsNullOrEmpty(this.txtWeldJointCode.Text.Trim()) || this.drpPipingClass.SelectedValue == BLL.Const._Null || this.drpMaterial1.SelectedValue == BLL.Const._Null || this.drpMaterial2.SelectedValue == BLL.Const._Null || this.drpWeldTypeCode.SelectedValue == BLL.Const._Null)
{
Alert.ShowInTop("页面必填项不能为空", MessageBoxIcon.Warning);
@@ -337,22 +337,22 @@ namespace FineUIPro.Web.HJGL.WeldingManage
//if (!this.txtWeldJointCode.Text.Contains("G"))
//{
int jointCode = Funs.GetNewIntOrZero(this.txtWeldJointCode.Text.Trim());
if (jointCode != 0)
int jointCode = Funs.GetNewIntOrZero(this.txtWeldJointCode.Text.Trim());
if (jointCode != 0)
{
if (jointCode < 10)
{
if (jointCode < 10)
{
joint.WeldJointCode = "0" + Convert.ToString(jointCode);
}
else
{
joint.WeldJointCode = Convert.ToString(jointCode);
}
joint.WeldJointCode = "0" + Convert.ToString(jointCode);
}
else
{
joint.WeldJointCode = this.txtWeldJointCode.Text;
joint.WeldJointCode = Convert.ToString(jointCode);
}
}
else
{
joint.WeldJointCode = this.txtWeldJointCode.Text;
}
//}
//else
//{
@@ -370,7 +370,7 @@ namespace FineUIPro.Web.HJGL.WeldingManage
}
joint.Size = Funs.GetNewDecimal(this.txtSize.Text.Trim());
joint.Dia = Funs.GetNewDecimal(this.txtDia.Text.Trim());
joint.DNDia=txtDNDia.Text.Trim();
joint.DNDia = txtDNDia.Text.Trim();
joint.Thickness = Funs.GetNewDecimal(this.txtThickness.Text.Trim());
//if (this.drpComponent1.SelectedValue != BLL.Const._Null)
//{
@@ -644,7 +644,7 @@ namespace FineUIPro.Web.HJGL.WeldingManage
{
var wpsRod = BLL.Base_ConsumablesService.GetConsumablesByConsumablesId(wps.WeldingRod);
var matRod = BLL.Base_ConsumablesService.GetConsumablesByConsumablesId(drpWeldingRod.SelectedValue);
if (IsCoverClass(wpsRod.SteelType, matRod.SteelType))
if (wpsRod != null && matRod != null && IsCoverClass(wpsRod.SteelType, matRod.SteelType))
{
}
@@ -683,7 +683,7 @@ namespace FineUIPro.Web.HJGL.WeldingManage
{
var wpsWire = BLL.Base_ConsumablesService.GetConsumablesByConsumablesId(wps.WeldingWire);
var matWire = BLL.Base_ConsumablesService.GetConsumablesByConsumablesId(drpWeldingWire.SelectedValue);
if (IsCoverClass(wpsWire.SteelType, matWire.SteelType))
if (wpsWire != null && matWire != null && IsCoverClass(wpsWire.SteelType, matWire.SteelType))
{
}