This commit is contained in:
毕文静 2026-02-05 11:10:50 +08:00
commit 3aa557136d
4 changed files with 56 additions and 33 deletions

View File

@ -25,17 +25,6 @@
<f:HiddenField ID="hdQualityCertificateId" runat="server"></f:HiddenField> <f:HiddenField ID="hdQualityCertificateId" runat="server"></f:HiddenField>
</Items> </Items>
</f:FormRow> </f:FormRow>
<f:FormRow ColumnWidths="45% 5% 50%">
<Items>
<f:TextBox ID="txtWeldName" runat="server" Label="焊材牌号" LabelAlign="Right" Readonly="true"
ShowRedStar="true">
</f:TextBox>
<f:Button runat="server" ID="btnSelect" Icon="Find" OnClick="btnSelect_Click" ToolTip="查找焊材信息">
</f:Button>
<f:TextBox ID="txtWeldSpec" runat="server" Label="规格" LabelAlign="Right" Readonly="true">
</f:TextBox>
</Items>
</f:FormRow>
<f:FormRow> <f:FormRow>
<Items> <Items>
<f:DropDownList ID="drpWarrantybook" runat="server" Label="入库自编号" LabelAlign="Right" AutoPostBack="true" EnableEdit="true" <f:DropDownList ID="drpWarrantybook" runat="server" Label="入库自编号" LabelAlign="Right" AutoPostBack="true" EnableEdit="true"
@ -45,6 +34,17 @@
</f:TextBox> </f:TextBox>
</Items> </Items>
</f:FormRow> </f:FormRow>
<f:FormRow ColumnWidths="45% 5% 50%">
<Items>
<f:TextBox ID="txtWeldName" runat="server" Label="焊材牌号" LabelAlign="Right" Readonly="true"
ShowRedStar="true">
</f:TextBox>
<f:Button runat="server" ID="btnSelect" Icon="Find" OnClick="btnSelect_Click" ToolTip="查找焊材信息" Hidden="true">
</f:Button>
<f:TextBox ID="txtWeldSpec" runat="server" Label="规格" LabelAlign="Right" Readonly="true">
</f:TextBox>
</Items>
</f:FormRow>
<f:FormRow> <f:FormRow>
<Items> <Items>
<f:Label runat="server" ID="txtHeartNo" Label="批号" LabelAlign="Right"></f:Label> <f:Label runat="server" ID="txtHeartNo" Label="批号" LabelAlign="Right"></f:Label>

View File

@ -35,7 +35,7 @@ namespace FineUIPro.Web.HJGL.MaterialManage
{ {
this.btnClose.OnClientClick = ActiveWindow.GetHideReference(); this.btnClose.OnClientClick = ActiveWindow.GetHideReference();
this.QualityCertificateId = Request.Params["QualityCertificateId"]; this.QualityCertificateId = Request.Params["QualityCertificateId"];
StockInitService.InitHeartNo(this.drpWarrantybook, true); StockInitService.InitWarrantybook(this.drpWarrantybook, true);
if (!string.IsNullOrEmpty(this.QualityCertificateId)) if (!string.IsNullOrEmpty(this.QualityCertificateId))
{ {
this.hdQualityCertificateId.Text = this.QualityCertificateId; this.hdQualityCertificateId.Text = this.QualityCertificateId;
@ -81,7 +81,7 @@ namespace FineUIPro.Web.HJGL.MaterialManage
/// <param name="e"></param> /// <param name="e"></param>
protected void btnSave_Click(object sender, EventArgs e) protected void btnSave_Click(object sender, EventArgs e)
{ {
if (this.hdWeldId.Text == string.Empty) if (this.txtWeldName.Text.Trim() == string.Empty)
{ {
Alert.ShowInTop("请选择焊材牌号!", MessageBoxIcon.Warning); Alert.ShowInTop("请选择焊材牌号!", MessageBoxIcon.Warning);
return; return;
@ -148,7 +148,7 @@ namespace FineUIPro.Web.HJGL.MaterialManage
protected void btnAttachUrl2_Click(object sender, EventArgs e) protected void btnAttachUrl2_Click(object sender, EventArgs e)
{ {
string edit = "0"; // 表示能打开附件上传窗口,但不能上传附件 string edit = "0"; // 表示能打开附件上传窗口,但不能上传附件
if (BLL.CommonService.GetAllButtonPowerList(this.CurrUser.LoginProjectId, this.CurrUser.UserId, BLL.Const.CLGL_QualityCertificateMenuId, BLL.Const.BtnSave)) if (BLL.CommonService.GetAllButtonPowerList(this.CurrUser.LoginProjectId, this.CurrUser.UserId, BLL.Const.CLGL_QualityCertificateMenuId, BLL.Const.BtnAdd))
{ {
if (string.IsNullOrEmpty(this.hdQualityCertificateId.Text.Trim())) if (string.IsNullOrEmpty(this.hdQualityCertificateId.Text.Trim()))
{ {
@ -206,9 +206,32 @@ namespace FineUIPro.Web.HJGL.MaterialManage
protected void drpWarrantybook_SelectedIndexChanged(object sender, EventArgs e) protected void drpWarrantybook_SelectedIndexChanged(object sender, EventArgs e)
{ {
this.txtHeartNo.Text = string.Empty; this.txtHeartNo.Text = string.Empty;
this.txtWeldName.Text = string.Empty;
this.txtWeldSpec.Text = string.Empty;
this.txtWeldType.Text = string.Empty;
if (this.drpWarrantybook.SelectedValue != BLL.Const._Null) if (this.drpWarrantybook.SelectedValue != BLL.Const._Null)
{ {
this.txtHeartNo.Text = this.drpWarrantybook.SelectedValue; this.txtHeartNo.Text = this.drpWarrantybook.SelectedValue;
Model.Weld_StockIn s = (from x in Funs.DB.Weld_StockIn where x.Warrantybook == this.drpWarrantybook.SelectedItem.Text.Trim() select x).FirstOrDefault();
if (s != null)
{
this.hdWeldId.Text = s.WeldId;
var weld = BLL.WeldInfoService.GetWeldInfoById(s.WeldId);
if (weld != null)
{
//this.txtWeldCode.Text = weld.WeldCode;
this.txtWeldName.Text = weld.WeldName;
this.txtWeldSpec.Text = weld.WeldSpec;
if (!string.IsNullOrEmpty(weld.WeldTypeId))
{
var weldType = BLL.WeldTypeService.GetWeldTypeById(weld.WeldTypeId);
if (weldType != null)
{
this.txtWeldType.Text = weldType.WeldTypeName;
}
}
}
}
} }
} }
} }

View File

@ -57,6 +57,24 @@ namespace FineUIPro.Web.HJGL.MaterialManage {
/// </remarks> /// </remarks>
protected global::FineUIPro.HiddenField hdQualityCertificateId; protected global::FineUIPro.HiddenField hdQualityCertificateId;
/// <summary>
/// drpWarrantybook 控件。
/// </summary>
/// <remarks>
/// 自动生成的字段。
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
/// </remarks>
protected global::FineUIPro.DropDownList drpWarrantybook;
/// <summary>
/// txtWeldType 控件。
/// </summary>
/// <remarks>
/// 自动生成的字段。
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
/// </remarks>
protected global::FineUIPro.TextBox txtWeldType;
/// <summary> /// <summary>
/// txtWeldName 控件。 /// txtWeldName 控件。
/// </summary> /// </summary>
@ -84,24 +102,6 @@ namespace FineUIPro.Web.HJGL.MaterialManage {
/// </remarks> /// </remarks>
protected global::FineUIPro.TextBox txtWeldSpec; protected global::FineUIPro.TextBox txtWeldSpec;
/// <summary>
/// drpWarrantybook 控件。
/// </summary>
/// <remarks>
/// 自动生成的字段。
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
/// </remarks>
protected global::FineUIPro.DropDownList drpWarrantybook;
/// <summary>
/// txtWeldType 控件。
/// </summary>
/// <remarks>
/// 自动生成的字段。
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
/// </remarks>
protected global::FineUIPro.TextBox txtWeldType;
/// <summary> /// <summary>
/// txtHeartNo 控件。 /// txtHeartNo 控件。
/// </summary> /// </summary>

View File

@ -11,7 +11,7 @@
<FineUIPro DebugMode="false" Theme="Cupertino"/> <FineUIPro DebugMode="false" Theme="Cupertino"/>
<appSettings> <appSettings>
<!--连接字符串--> <!--连接字符串-->
<add key="ConnectionString" value="Server=.\SQL2022;Database=HJGLDB_DS;Integrated Security=False;User ID=sa;Password=1111;MultipleActiveResultSets=true;Max Pool Size = 1000;Connect Timeout=1200"/> <add key="ConnectionString" value="Server=.\MSSQLSERVER01;Database=HJGLDB_DS;Integrated Security=False;User ID=sa;Password=1111;MultipleActiveResultSets=true;Max Pool Size = 1000;Connect Timeout=1200"/>
<!--系统名称--> <!--系统名称-->
<add key="SystemName" value="诺必达焊接管理系统"/> <add key="SystemName" value="诺必达焊接管理系统"/>
<add key="ChartImageHandler" value="storage=file;timeout=20;url=~/Images/;"/> <add key="ChartImageHandler" value="storage=file;timeout=20;url=~/Images/;"/>