diff --git a/.gitignore b/.gitignore
index 273be0d..583bdb5 100644
--- a/.gitignore
+++ b/.gitignore
@@ -30,3 +30,4 @@ bin-release/
/HJGL_DSPackFile/版本日志
/HJGL_DS/FineUIPro.Web/FileUpload/FaceRecognition
/HJGL_DS/WebAPI/.vs
+/HJGL_DS/FineUIPro.Web/FileUpload/WeldMat/StockIn
diff --git a/DataBase/版本日志/HJGLDB_DS_2025-08-04_gf.sql b/DataBase/版本日志/HJGLDB_DS_2025-08-04_gf.sql
new file mode 100644
index 0000000..10d1adf
--- /dev/null
+++ b/DataBase/版本日志/HJGLDB_DS_2025-08-04_gf.sql
@@ -0,0 +1,3 @@
+alter table Weld_StockIn add WarrantyNo nvarchar(50) null
+alter table Weld_StockIn add IsCheckWarrantyNo bit null
+GO
\ No newline at end of file
diff --git a/HJGL_DS/BLL/Common/SysManage/Sys_UserSettingsService.cs b/HJGL_DS/BLL/Common/SysManage/Sys_UserSettingsService.cs
index 31a9522..4c224f9 100644
--- a/HJGL_DS/BLL/Common/SysManage/Sys_UserSettingsService.cs
+++ b/HJGL_DS/BLL/Common/SysManage/Sys_UserSettingsService.cs
@@ -247,7 +247,11 @@ namespace BLL
pUser.UserId = item.UserId;
pUser.ProjectId = projectid;
pUser.RoleId = bUser.FirstOrDefault(x => x.UserId == item.UserId).RoleId;
- AddProject_UserList.Add(pUser);
+ var us = Funs.DB.Project_User.FirstOrDefault(x => x.UserId == item.UserId && x.ProjectId == projectid);
+ if (us == null)
+ {
+ AddProject_UserList.Add(pUser);
+ }
//增加单位
uItem m = new uItem();
@@ -273,7 +277,11 @@ namespace BLL
{
pUnit.UnitType = bresult.UnitType;
}
- AddProject_Unit.Add(pUnit);
+ var un= bUnit.FirstOrDefault(x => x.ProjectId == projectid && x.UnitId == item.UnitId);
+ if (un == null)
+ {
+ AddProject_Unit.Add(pUnit);
+ }
}
}
}
diff --git a/HJGL_DS/BLL/WeldMat/Stock/StockInService.cs b/HJGL_DS/BLL/WeldMat/Stock/StockInService.cs
index 53b86c6..d367dd3 100644
--- a/HJGL_DS/BLL/WeldMat/Stock/StockInService.cs
+++ b/HJGL_DS/BLL/WeldMat/Stock/StockInService.cs
@@ -48,6 +48,7 @@ namespace BLL
newStockIn.Flag = stockIn.Flag;
newStockIn.UsingAmount = stockIn.UsingAmount;
newStockIn.Number = stockIn.Number;
+ newStockIn.WarrantyNo = stockIn.WarrantyNo;
db.Weld_StockIn.InsertOnSubmit(newStockIn);
db.SubmitChanges();
@@ -80,6 +81,8 @@ namespace BLL
newStockIn.HeartNo = stockIn.HeartNo;
newStockIn.SupplierId = stockIn.SupplierId;
newStockIn.UnitStoreId = stockIn.UnitStoreId;
+ newStockIn.WarrantyNo = stockIn.WarrantyNo;
+
db.SubmitChanges();
}
}
@@ -98,6 +101,8 @@ namespace BLL
newStockIn.HeartNo = stockIn.HeartNo;
newStockIn.SupplierId = stockIn.SupplierId;
newStockIn.UnitStoreId = stockIn.UnitStoreId;
+ newStockIn.WarrantyNo = stockIn.WarrantyNo;
+
db.SubmitChanges();
}
}
@@ -133,6 +138,17 @@ namespace BLL
}
}
+ public static void UpdateStockInIsCheckWarrantyNo(Model.Weld_StockIn stockIn)
+ {
+ Model.SGGLDB db = Funs.DB;
+ Model.Weld_StockIn newStockIn = db.Weld_StockIn.FirstOrDefault(e => e.StockInId == stockIn.StockInId);
+ if (newStockIn != null)
+ {
+ newStockIn.IsCheckWarrantyNo = stockIn.IsCheckWarrantyNo;
+ db.SubmitChanges();
+ }
+ }
+
///
/// 更新附件
///
diff --git a/HJGL_DS/FineUIPro.Web/ErrLog.txt b/HJGL_DS/FineUIPro.Web/ErrLog.txt
index ef4fcd8..708af39 100644
--- a/HJGL_DS/FineUIPro.Web/ErrLog.txt
+++ b/HJGL_DS/FineUIPro.Web/ErrLog.txt
@@ -94,3 +94,24 @@ IP地址:::1
出错时间:07/28/2025 11:13:06
+
+错误信息开始=====>
+错误类型:HttpCompileException
+错误信息:d:\工作\鼎盛\HJGL_DS\HJGL_DS\FineUIPro.Web\WeldMat\Stock\StockIn.aspx(132): error CS1061: “ASP.weldmat_stock_stockin_aspx”不包含“btnMenuConfirm_Click”的定义,并且找不到可接受类型为“ASP.weldmat_stock_stockin_aspx”的第一个参数的扩展方法“btnMenuConfirm_Click”(是否缺少 using 指令或程序集引用?)
+错误堆栈:
+ 在 System.Web.Compilation.BuildManager.CompileWebFile(VirtualPath virtualPath)
+ 在 System.Web.Compilation.BuildManager.GetVPathBuildResultInternal(VirtualPath virtualPath, Boolean noBuild, Boolean allowCrossApp, Boolean allowBuildInPrecompile, Boolean throwIfNotFound, Boolean ensureIsUpToDate)
+ 在 System.Web.Compilation.BuildManager.GetVPathBuildResultWithNoAssert(HttpContext context, VirtualPath virtualPath, Boolean noBuild, Boolean allowCrossApp, Boolean allowBuildInPrecompile, Boolean throwIfNotFound, Boolean ensureIsUpToDate)
+ 在 System.Web.Compilation.BuildManager.GetVirtualPathObjectFactory(VirtualPath virtualPath, HttpContext context, Boolean allowCrossApp, Boolean throwIfNotFound)
+ 在 System.Web.Compilation.BuildManager.CreateInstanceFromVirtualPath(VirtualPath virtualPath, Type requiredBaseType, HttpContext context, Boolean allowCrossApp)
+ 在 System.Web.UI.PageHandlerFactory.GetHandlerHelper(HttpContext context, String requestType, VirtualPath virtualPath, String physicalPath)
+ 在 System.Web.UI.PageHandlerFactory.GetHandler(HttpContext context, String requestType, String virtualPath, String path)
+ 在 System.Web.HttpApplication.MaterializeHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute()
+ 在 System.Web.HttpApplication.ExecuteStepImpl(IExecutionStep step)
+ 在 System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously)
+出错时间:08/04/2025 15:24:06
+出错文件:http://localhost:64304/WeldMat/Stock/StockIn.aspx
+IP地址:::1
+
+出错时间:08/04/2025 15:24:06
+
diff --git a/HJGL_DS/FineUIPro.Web/File/Excel/焊材入库导入模板.xlsx b/HJGL_DS/FineUIPro.Web/File/Excel/焊材入库导入模板.xlsx
index ef31c60..1384ea2 100644
Binary files a/HJGL_DS/FineUIPro.Web/File/Excel/焊材入库导入模板.xlsx and b/HJGL_DS/FineUIPro.Web/File/Excel/焊材入库导入模板.xlsx differ
diff --git a/HJGL_DS/FineUIPro.Web/WeldMat/Stock/StockIn.aspx b/HJGL_DS/FineUIPro.Web/WeldMat/Stock/StockIn.aspx
index d47d6b9..1f68beb 100644
--- a/HJGL_DS/FineUIPro.Web/WeldMat/Stock/StockIn.aspx
+++ b/HJGL_DS/FineUIPro.Web/WeldMat/Stock/StockIn.aspx
@@ -62,7 +62,7 @@
HeaderText="规格" HeaderTextAlign="Center" TextAlign="Center">
+ HeaderText="入库自编号" HeaderTextAlign="Center" TextAlign="Center" SortField="Warrantybook">
@@ -76,6 +76,10 @@
+
+
+
@@ -129,6 +133,9 @@
+
diff --git a/HJGL_DS/FineUIPro.Web/WeldMat/Stock/StockIn.aspx.cs b/HJGL_DS/FineUIPro.Web/WeldMat/Stock/StockIn.aspx.cs
index cd5f98f..5930e84 100644
--- a/HJGL_DS/FineUIPro.Web/WeldMat/Stock/StockIn.aspx.cs
+++ b/HJGL_DS/FineUIPro.Web/WeldMat/Stock/StockIn.aspx.cs
@@ -38,7 +38,7 @@ namespace FineUIPro.Web.WeldMat.Stock
///
private void BindGrid()
{
- string strSql = @"SELECT StockIn.StockInId,StockIn.WeldId,StockIn.Amount,StockIn.Weight,Users.UserName AS Materialman,StockIn.InStockDate,
+ string strSql = @"SELECT StockIn.StockInId,StockIn.WeldId,StockIn.Amount,StockIn.Weight,Users.UserName AS Materialman,StockIn.InStockDate,StockIn.WarrantyNo,StockIn.IsCheckWarrantyNo,
ReviewDate,Weld.WeldCode,Weld.WeldName,Weld.WeldSpec,StockIn.Warrantybook, StockIn.HeartNo,
WeldType.WeldTypeName, WeldType.WeldUnit,StockIn.UnitStoreId,(unit.UnitName+'('+store.UnitStoreName+')') AS UnitStoreName,
(CASE WHEN (StockIn.AttachUrl!='' AND StockIn.AttachUrl IS NOT NULL) THEN '是' ELSE '否' END) IsUploadAttach
@@ -50,7 +50,7 @@ namespace FineUIPro.Web.WeldMat.Stock
LEFT JOIN dbo.Base_Unit unit ON unit.UnitId=store.UnitId
WHERE StockIn.Flag='1' ";
List listStr = new List();
-
+
if (!string.IsNullOrEmpty(this.txtWeldName.Text.Trim()))
{
strSql += " AND Weld.WeldName LIKE @WeldName";
@@ -61,7 +61,7 @@ namespace FineUIPro.Web.WeldMat.Stock
strSql += " AND Weld.WeldTypeId = @WeldTypeId";
listStr.Add(new SqlParameter("@WeldTypeId", drpWeldType.SelectedValue));
}
- if (this.drpUnitStoreId.SelectedValue!=BLL.Const._Null)
+ if (this.drpUnitStoreId.SelectedValue != BLL.Const._Null)
{
strSql += " AND StockIn.UnitStoreId = @unitStoreId";
listStr.Add(new SqlParameter("@unitStoreId", drpUnitStoreId.SelectedValue));
@@ -237,7 +237,7 @@ namespace FineUIPro.Web.WeldMat.Stock
var s = BLL.UnitStoreService.GetUnitStoreById(q.UnitStoreId);
//if (s != null && s.UnitId == CurrUser.UnitId)
//{
- PageContext.RegisterStartupScript(Window1.GetShowReference(String.Format("StockInEdit.aspx?StockInId={0}", id, "编辑 - ")));
+ PageContext.RegisterStartupScript(Window1.GetShowReference(String.Format("StockInEdit.aspx?StockInId={0}", id, "编辑 - ")));
//}
//else
//{
@@ -245,7 +245,41 @@ namespace FineUIPro.Web.WeldMat.Stock
// return;
//}
}
-
+
+ }
+ }
+ else
+ {
+ Alert.ShowInTop("您没有这个权限,请与管理员联系!", MessageBoxIcon.Warning);
+ return;
+ }
+ }
+ #endregion
+
+ #region 质保书自编号确认按钮
+ ///
+ /// 质保书自编号确认按钮
+ ///
+ ///
+ ///
+ protected void btnMenuConfirm_Click(object sender, EventArgs e)
+ {
+ if (BLL.CommonService.GetAllButtonPowerList(this.CurrUser.LoginProjectId, this.CurrUser.UserId, BLL.Const.CLGL_StockInMenuId, BLL.Const.BtnModify))
+ {
+ if (Grid1.SelectedRowIndexArray.Length == 0)
+ {
+ Alert.ShowInTop("请至少选择一条记录!", MessageBoxIcon.Warning);
+ return;
+ }
+
+ string id = Grid1.SelectedRowID;
+ if (!string.IsNullOrEmpty(id))
+ {
+ var q = BLL.StockInService.GetStockInById(id);
+ q.IsCheckWarrantyNo = true;
+ BLL.StockInService.UpdateStockInIsCheckWarrantyNo(q);
+ this.BindGrid();
+ ShowNotify("质保书自编号确认成功!", MessageBoxIcon.Success);
}
}
else
@@ -309,7 +343,7 @@ namespace FineUIPro.Web.WeldMat.Stock
private bool judgementDelete(string rowID)
{
string content = string.Empty;
- var q = from x in Funs.DB.Weld_UsingMat where x.StockInId==rowID select x;
+ var q = from x in Funs.DB.Weld_UsingMat where x.StockInId == rowID select x;
if (q.Count() > 0)
{
content = "该入库材料已有领用,不能删除!";
diff --git a/HJGL_DS/FineUIPro.Web/WeldMat/Stock/StockIn.aspx.designer.cs b/HJGL_DS/FineUIPro.Web/WeldMat/Stock/StockIn.aspx.designer.cs
index c186e0f..7f3da53 100644
--- a/HJGL_DS/FineUIPro.Web/WeldMat/Stock/StockIn.aspx.designer.cs
+++ b/HJGL_DS/FineUIPro.Web/WeldMat/Stock/StockIn.aspx.designer.cs
@@ -192,6 +192,15 @@ namespace FineUIPro.Web.WeldMat.Stock {
///
protected global::FineUIPro.MenuButton btnMenuEdit;
+ ///
+ /// btnMenuConfirm 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::FineUIPro.MenuButton btnMenuConfirm;
+
///
/// btnMenuDelete 控件。
///
diff --git a/HJGL_DS/FineUIPro.Web/WeldMat/Stock/StockInEdit.aspx b/HJGL_DS/FineUIPro.Web/WeldMat/Stock/StockInEdit.aspx
index 9af5bc1..56c5361 100644
--- a/HJGL_DS/FineUIPro.Web/WeldMat/Stock/StockInEdit.aspx
+++ b/HJGL_DS/FineUIPro.Web/WeldMat/Stock/StockInEdit.aspx
@@ -88,11 +88,22 @@
+
+
+
+
+
+
+
+
+
diff --git a/HJGL_DS/FineUIPro.Web/WeldMat/Stock/StockInEdit.aspx.cs b/HJGL_DS/FineUIPro.Web/WeldMat/Stock/StockInEdit.aspx.cs
index eecdfdf..e927895 100644
--- a/HJGL_DS/FineUIPro.Web/WeldMat/Stock/StockInEdit.aspx.cs
+++ b/HJGL_DS/FineUIPro.Web/WeldMat/Stock/StockInEdit.aspx.cs
@@ -134,6 +134,7 @@ namespace FineUIPro.Web.WeldMat.Stock
this.txtRecycleAmount.Text = stockIn.RecycleAmount.Value.ToString("0.####");
}
}
+ this.txtWarrantyNo.Text = stockIn.WarrantyNo;
}
}
}
@@ -192,7 +193,7 @@ namespace FineUIPro.Web.WeldMat.Stock
stockIn.Warrantybook = this.txtWarrantybook.Text.Trim();
//stockIn.Number = txtNumber.Text.Trim();
stockIn.HeartNo = txtHeartNo.Text.Trim();
-
+ stockIn.WarrantyNo = txtWarrantyNo.Text.Trim();
if (this.drpUnitStore.SelectedValue != BLL.Const._Null)
{
stockIn.UnitStoreId = this.drpUnitStore.SelectedValue;
@@ -267,6 +268,30 @@ namespace FineUIPro.Web.WeldMat.Stock
PageContext.RegisterStartupScript(Window2.GetShowReference(String.Format("../../AttachFile/webuploader.aspx?toKeyId={0}&path=FileUpload/WeldMat/StockIn&menuId={1}&edit={2}", this.StockInId, Const.CLGL_StockInMenuId, edit)));
}
}
+
+ ///
+ /// 上传附件资源
+ ///
+ ///
+ ///
+ protected void btnAttachUrl2_Click(object sender, EventArgs e)
+ {
+ string edit = "0"; // 表示能打开附件上传窗口,但不能上传附件
+ if (BLL.CommonService.GetAllButtonPowerList(this.CurrUser.LoginProjectId, this.CurrUser.UserId, BLL.Const.CLGL_StockInMenuId, BLL.Const.BtnSave))
+ {
+ if (string.IsNullOrEmpty(this.StockInId))
+ {
+ if (this.hdWeldId.Text == string.Empty)
+ {
+ Alert.ShowInTop("请选择焊材牌号!", MessageBoxIcon.Warning);
+ return;
+ }
+ SaveData();
+ }
+ edit = "1";
+ PageContext.RegisterStartupScript(Window2.GetShowReference(String.Format("../../AttachFile/webuploader.aspx?toKeyId={0}&path=FileUpload/WeldMat/StockIn&menuId={1}&edit={2}", this.StockInId + "W", Const.CLGL_StockInMenuId, edit)));
+ }
+ }
#endregion
#region 查找焊材信息
diff --git a/HJGL_DS/FineUIPro.Web/WeldMat/Stock/StockInEdit.aspx.designer.cs b/HJGL_DS/FineUIPro.Web/WeldMat/Stock/StockInEdit.aspx.designer.cs
index cb05c14..7694809 100644
--- a/HJGL_DS/FineUIPro.Web/WeldMat/Stock/StockInEdit.aspx.designer.cs
+++ b/HJGL_DS/FineUIPro.Web/WeldMat/Stock/StockInEdit.aspx.designer.cs
@@ -201,6 +201,15 @@ namespace FineUIPro.Web.WeldMat.Stock {
///
protected global::FineUIPro.DatePicker txtReviewDate;
+ ///
+ /// txtWarrantyNo 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::FineUIPro.TextBox txtWarrantyNo;
+
///
/// UploadAttach 控件。
///
@@ -210,6 +219,15 @@ namespace FineUIPro.Web.WeldMat.Stock {
///
protected global::FineUIPro.LinkButton UploadAttach;
+ ///
+ /// UploadAttach2 控件。
+ ///
+ ///
+ /// 自动生成的字段。
+ /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
+ ///
+ protected global::FineUIPro.LinkButton UploadAttach2;
+
///
/// Toolbar2 控件。
///
diff --git a/HJGL_DS/FineUIPro.Web/WeldMat/Stock/StockInImport.aspx.cs b/HJGL_DS/FineUIPro.Web/WeldMat/Stock/StockInImport.aspx.cs
index 7da4766..f6f24cd 100644
--- a/HJGL_DS/FineUIPro.Web/WeldMat/Stock/StockInImport.aspx.cs
+++ b/HJGL_DS/FineUIPro.Web/WeldMat/Stock/StockInImport.aspx.cs
@@ -281,6 +281,14 @@ namespace FineUIPro.Web.WeldMat.Stock
{
errorInfos += (i + 2) + "行, [生产时间] 不能为空";
}
+ if (ds.Tables[0].Rows[i]["质保书自编号"] != null && !string.IsNullOrEmpty(ds.Tables[0].Rows[i]["质保书自编号"].ToString()))
+ {
+ stockIn.WarrantyNo = ds.Tables[0].Rows[i]["质保书自编号"].ToString();
+ }
+ else
+ {
+ errorInfos += (i + 2) + "行, [质保书自编号] 不能为空";
+ }
stockIn.StockInId = SQLHelper.GetNewID(typeof(Model.Weld_StockIn));
stockIn.Flag = "1";//入库
diff --git a/HJGL_DS/Model/Model.cs b/HJGL_DS/Model/Model.cs
index 6390973..c688674 100644
--- a/HJGL_DS/Model/Model.cs
+++ b/HJGL_DS/Model/Model.cs
@@ -110342,6 +110342,10 @@ namespace Model
private System.Nullable _MoveInDate;
+ private string _WarrantyNo;
+
+ private System.Nullable _IsCheckWarrantyNo;
+
#region 可扩展性方法定义
partial void OnLoaded();
partial void OnValidate(System.Data.Linq.ChangeAction action);
@@ -110392,6 +110396,10 @@ namespace Model
partial void OnMoveInManIdChanged();
partial void OnMoveInDateChanging(System.Nullable value);
partial void OnMoveInDateChanged();
+ partial void OnWarrantyNoChanging(string value);
+ partial void OnWarrantyNoChanged();
+ partial void OnIsCheckWarrantyNoChanging(System.Nullable value);
+ partial void OnIsCheckWarrantyNoChanged();
#endregion
public Weld_StockIn()
@@ -110859,6 +110867,46 @@ namespace Model
}
}
+ [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_WarrantyNo", DbType="NVarChar(50)")]
+ public string WarrantyNo
+ {
+ get
+ {
+ return this._WarrantyNo;
+ }
+ set
+ {
+ if ((this._WarrantyNo != value))
+ {
+ this.OnWarrantyNoChanging(value);
+ this.SendPropertyChanging();
+ this._WarrantyNo = value;
+ this.SendPropertyChanged("WarrantyNo");
+ this.OnWarrantyNoChanged();
+ }
+ }
+ }
+
+ [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_IsCheckWarrantyNo", DbType="Bit")]
+ public System.Nullable IsCheckWarrantyNo
+ {
+ get
+ {
+ return this._IsCheckWarrantyNo;
+ }
+ set
+ {
+ if ((this._IsCheckWarrantyNo != value))
+ {
+ this.OnIsCheckWarrantyNoChanging(value);
+ this.SendPropertyChanging();
+ this._IsCheckWarrantyNo = value;
+ this.SendPropertyChanged("IsCheckWarrantyNo");
+ this.OnIsCheckWarrantyNoChanged();
+ }
+ }
+ }
+
public event PropertyChangingEventHandler PropertyChanging;
public event PropertyChangedEventHandler PropertyChanged;