feat: 性能优化与功能增强

- 优化TestPackageData的InitTreeMenu方法,减少数据库查询次数
  - InstallList页面新增数据汇总统计功能
  - 修复SetSubReviewEdit2编辑时编号重复误报的bug
This commit is contained in:
2025-12-22 12:26:03 +08:00
parent 588fd6124c
commit 808beba1fd
7 changed files with 179 additions and 72 deletions
@@ -221,27 +221,36 @@ namespace FineUIPro.Web.PHTGL.BiddingManagement
return false;
}
var IsExitCodemodel = PHTGL_SetSubReviewService.GetPHTGL_SetSubReviewBySetSubReviewCode(this.txtSetSubReviewCode.Text.Trim().ToString());
// 获取当前输入的编号
string currentSetSubReviewCode = this.txtSetSubReviewCode.Text.Trim();
// 验证编号是否为空
if (string.IsNullOrEmpty(currentSetSubReviewCode))
{
ShowNotify("编号不能为空!", MessageBoxIcon.Warning);
return false;
}
// 检查编号重复性
var existingRecord = PHTGL_SetSubReviewService.GetPHTGL_SetSubReviewBySetSubReviewCode(currentSetSubReviewCode);
if (string.IsNullOrEmpty(SetSubReviewID))
{
if (IsExitCodemodel != null)
// 新增记录:检查编号是否已存在
if (existingRecord != null)
{
ShowNotify("编号已经重复,请修改!", MessageBoxIcon.Warning);
return false;
}
}
else
{
if (IsExitCodemodel != null && IsExitCodemodel.SetSubReviewID != SetSubReviewID)
// 编辑记录:检查编号是否被其他记录使用
if (existingRecord != null && existingRecord.SetSubReviewID != SetSubReviewID)
{
ShowNotify("编号已经重复,请修改!", MessageBoxIcon.Warning);
return false;
}
}
Model.PHTGL_SetSubReview _SetSubReview = new Model.PHTGL_SetSubReview();