代码无效引用清理,试压包资料界面看板修改

This commit is contained in:
2025-10-10 14:33:21 +08:00
parent 87fb529521
commit 55b798135c
933 changed files with 5897 additions and 7541 deletions
+62 -63
View File
@@ -1,15 +1,13 @@
using FineUIPro;
using System;
using System.Collections;
using System.Collections.Generic;
using System.Linq;
using System.Text;
namespace BLL
{
public static class Base_CompanytemplateService
public static class Base_CompanytemplateService
{
#region
/// <summary>
@@ -20,19 +18,19 @@ namespace BLL
get;
set;
}
public static List<Model.Base_CompanyTemplate> GetBase_CompanyTemplateByModle(Model.Base_CompanyTemplate table)
{
var q= from x in Funs.DB.Base_CompanyTemplate
where
( string.IsNullOrEmpty(table.TemplateId)||x.TemplateId.Contains(table.TemplateId)) &&
( string.IsNullOrEmpty(table.Code)||x.Code.Contains(table.Code)) &&
( string.IsNullOrEmpty(table.Name)||x.Name.Contains(table.Name)) &&
( string.IsNullOrEmpty(table.FilePath)||x.FilePath.Contains(table.FilePath)) &&
( string.IsNullOrEmpty(table.Remarks)||x.Remarks.Contains(table.Remarks))
select x
;
return q.ToList();
public static List<Model.Base_CompanyTemplate> GetBase_CompanyTemplateByModle(Model.Base_CompanyTemplate table)
{
var q = from x in Funs.DB.Base_CompanyTemplate
where
(string.IsNullOrEmpty(table.TemplateId) || x.TemplateId.Contains(table.TemplateId)) &&
(string.IsNullOrEmpty(table.Code) || x.Code.Contains(table.Code)) &&
(string.IsNullOrEmpty(table.Name) || x.Name.Contains(table.Name)) &&
(string.IsNullOrEmpty(table.FilePath) || x.FilePath.Contains(table.FilePath)) &&
(string.IsNullOrEmpty(table.Remarks) || x.Remarks.Contains(table.Remarks))
select x
;
return q.ToList();
}
/// 获取分页列表
@@ -42,55 +40,56 @@ namespace BLL
/// <returns></returns>
public static IEnumerable getListData(Model.Base_CompanyTemplate table, Grid Grid1)
{
var q= GetBase_CompanyTemplateByModle(table);
var q = GetBase_CompanyTemplateByModle(table);
count = q.Count();
if (count == 0)
{
return null;
}
// q= q.Take(Grid1.PageSize * Grid1.PageIndex).Skip(Grid1.PageSize * (Grid1.PageIndex)).ToList();
// q = SortConditionHelper.SortingAndPaging(q, Grid1.SortField, Grid1.SortDirection, Grid1.PageIndex, Grid1.PageSize);
// q = SortConditionHelper.SortingAndPaging(q, Grid1.SortField, Grid1.SortDirection, Grid1.PageIndex, Grid1.PageSize);
return from x in q
select new
{
x.TemplateId,
x.Code,
x.Name,
x.FilePath,
x.Remarks,
x.TemplateId,
x.Code,
x.Name,
x.FilePath,
x.Remarks,
};
}
#endregion
public static Model.Base_CompanyTemplate GetBase_CompanyTemplateById(string TemplateId)
{
return Funs.DB.Base_CompanyTemplate.FirstOrDefault(x=>x.TemplateId==TemplateId);
public static Model.Base_CompanyTemplate GetBase_CompanyTemplateById(string TemplateId)
{
return Funs.DB.Base_CompanyTemplate.FirstOrDefault(x => x.TemplateId == TemplateId);
}
public static Model.Base_CompanyTemplate GetBase_CompanyTemplateByCode(string Code)
{
return Funs.DB.Base_CompanyTemplate.FirstOrDefault(x => x.Code== Code);
return Funs.DB.Base_CompanyTemplate.FirstOrDefault(x => x.Code == Code);
}
public static bool IsExitCode(string Code)
{
bool result = false;
var q= (from x in Funs.DB.Base_CompanyTemplate where x.Code ==Code select x ).FirstOrDefault();
if (q!=null)
var q = (from x in Funs.DB.Base_CompanyTemplate where x.Code == Code select x).FirstOrDefault();
if (q != null)
{
result = true;
}
return result;
}
public static void AddBase_CompanyTemplate(Model.Base_CompanyTemplate newtable)
{
Model.Base_CompanyTemplate table = new Model.Base_CompanyTemplate{
TemplateId=newtable.TemplateId,
Code=newtable.Code,
Name=newtable.Name,
FilePath=newtable.FilePath,
Remarks=newtable.Remarks,
Model.Base_CompanyTemplate table = new Model.Base_CompanyTemplate
{
TemplateId = newtable.TemplateId,
Code = newtable.Code,
Name = newtable.Name,
FilePath = newtable.FilePath,
Remarks = newtable.Remarks,
};
Funs.DB.Base_CompanyTemplate.InsertOnSubmit(table);
Funs.DB.SubmitChanges();
@@ -103,41 +102,41 @@ namespace BLL
Funs.DB.SubmitChanges();
}
public static void UpdateBase_CompanyTemplate(Model.Base_CompanyTemplate newtable)
{
Model.Base_CompanyTemplate table = Funs.DB.Base_CompanyTemplate.FirstOrDefault(x=>x.TemplateId==newtable.TemplateId);
if (table != null)
Model.Base_CompanyTemplate table = Funs.DB.Base_CompanyTemplate.FirstOrDefault(x => x.TemplateId == newtable.TemplateId);
if (table != null)
{
table.TemplateId=newtable.TemplateId;
table.Code=newtable.Code;
table.Name=newtable.Name;
table.FilePath=newtable.FilePath;
table.Remarks=newtable.Remarks;
table.TemplateId = newtable.TemplateId;
table.Code = newtable.Code;
table.Name = newtable.Name;
table.FilePath = newtable.FilePath;
table.Remarks = newtable.Remarks;
Funs.DB.SubmitChanges();
}
}
public static void DeleteBase_CompanyTemplateById (string TemplateId)
{
Model.Base_CompanyTemplate table =Funs.DB.Base_CompanyTemplate.FirstOrDefault(x=>x.TemplateId==TemplateId);
if (table != null)
{
public static void DeleteBase_CompanyTemplateById(string TemplateId)
{
Model.Base_CompanyTemplate table = Funs.DB.Base_CompanyTemplate.FirstOrDefault(x => x.TemplateId == TemplateId);
if (table != null)
{
Funs.DB.Base_CompanyTemplate.DeleteOnSubmit(table);
Funs.DB.SubmitChanges();
}
}
}
public static void DeleteALLBase_CompanyTemplate ()
{
if( Funs.DB.Base_CompanyTemplate !=null)
{
Funs.DB.Base_CompanyTemplate.DeleteAllOnSubmit( Funs.DB.Base_CompanyTemplate);
public static void DeleteALLBase_CompanyTemplate()
{
if (Funs.DB.Base_CompanyTemplate != null)
{
Funs.DB.Base_CompanyTemplate.DeleteAllOnSubmit(Funs.DB.Base_CompanyTemplate);
Funs.DB.SubmitChanges();
}
}
}
public static void InitBase_CompanyTemplateDownList(FineUIPro.DropDownList dropName, bool isShowPlease)
{
+8 -10
View File
@@ -1,9 +1,7 @@
using FineUIPro;
using System;
using System.Collections;
using System.Collections.Generic;
using System.Linq;
using System.Text;
namespace BLL
@@ -28,7 +26,7 @@ namespace BLL
(string.IsNullOrEmpty(table.UnitId) || x.UnitId.Contains(table.UnitId)) &&
(string.IsNullOrEmpty(table.FactoryCode) || x.FactoryCode.Contains(table.FactoryCode)) &&
(string.IsNullOrEmpty(table.FactoryName) || x.FactoryName.Contains(table.FactoryName)) &&
(string.IsNullOrEmpty(table.Address) || x.Address.Contains(table.Address))
(string.IsNullOrEmpty(table.Address) || x.Address.Contains(table.Address))
select x
;
@@ -36,8 +34,8 @@ namespace BLL
}
public static List<Model.Base_Factory> GetBase_FactoryList()
{
var q = (from x in Funs.DB.Base_Factory orderby x.FactoryCode select x).ToList();
var q = (from x in Funs.DB.Base_Factory orderby x.FactoryCode select x).ToList();
return q;
}
@@ -73,10 +71,10 @@ namespace BLL
{
return Funs.DB.Base_Factory.FirstOrDefault(x => x.FactoryId == FactoryId);
}
public static string GetBase_FactoryNameById(object FactoryId)
public static string GetBase_FactoryNameById(object FactoryId)
{
string name = string.Empty;
if (FactoryId!=null)
if (FactoryId != null)
{
var model = Funs.DB.Base_Factory.FirstOrDefault(x => x.FactoryId == FactoryId.ToString());
if (model != null)
@@ -85,9 +83,9 @@ namespace BLL
}
}
return name;
return name;
}
public static Model.Base_Factory GetBase_FactoryByCode(string FactoryCode)
public static Model.Base_Factory GetBase_FactoryByCode(string FactoryCode)
{
return Funs.DB.Base_Factory.FirstOrDefault(x => x.FactoryCode == FactoryCode);
}
@@ -101,7 +99,7 @@ namespace BLL
FactoryCode = newtable.FactoryCode,
FactoryName = newtable.FactoryName,
Address = newtable.Address,
MapCoordinates= newtable.MapCoordinates,
MapCoordinates = newtable.MapCoordinates,
};
Funs.DB.Base_Factory.InsertOnSubmit(table);
Funs.DB.SubmitChanges();
+2 -5
View File
@@ -1,8 +1,5 @@
using System;
using System.Collections.Generic;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace BLL
{
@@ -27,7 +24,7 @@ namespace BLL
public static string GetTrainObjectNameById(string trainObjectId)
{
string name = string.Empty;
var o= Funs.DB.Base_CQMSTrainObject.FirstOrDefault(e => e.TrainObjectId == trainObjectId);
var o = Funs.DB.Base_CQMSTrainObject.FirstOrDefault(e => e.TrainObjectId == trainObjectId);
if (o != null)
{
name = o.TrainObjectName;
+1 -1
View File
@@ -32,7 +32,7 @@ namespace BLL
CertificateName = certificate.CertificateName,
CertificateType = certificate.CertificateType,
IsRegisterHSSE = certificate.IsRegisterHSSE,
Type= certificate.Type,
Type = certificate.Type,
Remark = certificate.Remark
};
db.Base_Certificate.InsertOnSubmit(newCertificate);
@@ -2,7 +2,6 @@
using System.Collections;
using System.Collections.Generic;
using System.Linq;
using Model;
namespace BLL
{
+1 -5
View File
@@ -1,8 +1,4 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Linq;
namespace BLL
{
+1 -5
View File
@@ -1,8 +1,4 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Linq;
namespace BLL
{
+2 -2
View File
@@ -62,7 +62,7 @@ namespace BLL
Model.SGGLDB db = Funs.DB;
Model.Base_CostTypeItem newCostType = new Model.Base_CostTypeItem
{
CostTypeItemId= costTypeItem.CostTypeItemId,
CostTypeItemId = costTypeItem.CostTypeItemId,
CostTypeId = costTypeItem.CostTypeId,
SortIndex = costTypeItem.SortIndex,
CostTypeItemName = costTypeItem.CostTypeItemName,
@@ -174,7 +174,7 @@ namespace BLL
/// </summary>
/// <param name="dropName">下拉框名字</param>
/// <param name="isShowPlease">是否显示请选择</param>
public static void InitCostTypeItemDropDownList(FineUIPro.DropDownList dropName,string costTypeId, bool isShowPlease)
public static void InitCostTypeItemDropDownList(FineUIPro.DropDownList dropName, string costTypeId, bool isShowPlease)
{
dropName.Items.Clear();
dropName.DataValueField = "CostTypeItemId";
+1 -1
View File
@@ -8,7 +8,7 @@ namespace BLL
/// </summary>
public static class MaterialTypeService
{
/// <summary>
/// 根据主键获取材料类型
@@ -8,7 +8,7 @@ namespace BLL
/// </summary>
public static class NoticeAndSupervisionTypeService
{
/// <summary>
/// 根据主键获取告知和监检类型
+1 -1
View File
@@ -8,7 +8,7 @@ namespace BLL
/// </summary>
public static class PictureTypeService
{
/// <summary>
/// 根据主键获取项目图片分类
+4 -4
View File
@@ -8,7 +8,7 @@ namespace BLL
/// </summary>
public static class PositionService
{
/// <summary>
/// 根据主键获取主键
@@ -20,10 +20,10 @@ namespace BLL
return Funs.DB.Base_Position.FirstOrDefault(e => e.PositionId == positionId);
}
public static string GetPositionNameById(string positionId)
public static string GetPositionNameById(string positionId)
{
string name =string.Empty;
var getData= Funs.DB.Base_Position.FirstOrDefault(e => e.PositionId == positionId);
string name = string.Empty;
var getData = Funs.DB.Base_Position.FirstOrDefault(e => e.PositionId == positionId);
if (getData != null)
{
name = getData.PositionName;
+1 -1
View File
@@ -5,7 +5,7 @@ namespace BLL
{
public static class PostTitleService
{
/// <summary>
/// 根据主键获取信息
@@ -5,7 +5,7 @@ namespace BLL
{
public static class PracticeCertificateService
{
/// <summary>
/// 根据主键获取执业资格证书
+1 -1
View File
@@ -8,7 +8,7 @@ namespace BLL
public static class ProjectTypeService
{
/// <summary>
/// 根据主键获取信息
+1 -1
View File
@@ -8,7 +8,7 @@ namespace BLL
/// </summary>
public static class PunishTypeService
{
/// <summary>
/// 根据主键获取处罚定义
@@ -6,7 +6,7 @@ namespace BLL
{
public class QualityQuestionTypeService
{
/// <summary>
/// 获取实体集合
+1 -1
View File
@@ -8,7 +8,7 @@ namespace BLL
/// </summary>
public static class RewardTypeService
{
/// <summary>
/// 根据主键获取奖励定义
@@ -8,7 +8,7 @@ namespace BLL
/// </summary>
public static class RulesRegulationsTypeService
{
/// <summary>
/// 根据主键获取规章制度类别
+1 -1
View File
@@ -8,7 +8,7 @@ namespace BLL
/// </summary>
public static class SafetyMeasuresService
{
/// <summary>
/// 根据主键获取安全措施
@@ -1,6 +1,5 @@
using System.Collections.Generic;
using System.Linq;
using Model;
namespace BLL
{
+2 -2
View File
@@ -9,7 +9,7 @@ namespace BLL
/// </summary>
public static class SpecialEquipmentService
{
/// <summary>
/// 根据主键获取机具设备
@@ -29,7 +29,7 @@ namespace BLL
public static string GetSpecialEquipmentNameById(string specialEquipmentId)
{
string name = string.Empty;
var q= Funs.DB.Base_SpecialEquipment.FirstOrDefault(e => e.SpecialEquipmentId == specialEquipmentId);
var q = Funs.DB.Base_SpecialEquipment.FirstOrDefault(e => e.SpecialEquipmentId == specialEquipmentId);
if (q != null)
{
name = q.SpecialEquipmentName;
@@ -5,7 +5,7 @@ namespace BLL
{
public static class SpecialSchemeTypeService
{
/// <summary>
/// 根据主键获取信息
@@ -1,8 +1,5 @@
using System;
using System.Collections.Generic;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace BLL
{
+1 -1
View File
@@ -8,7 +8,7 @@ namespace BLL
/// </summary>
public static class TrainLevelService
{
/// <summary>
/// 根据主键获取主键
+2 -2
View File
@@ -8,7 +8,7 @@ namespace BLL
/// </summary>
public static class TrainTypeService
{
/// <summary>
/// 根据主键获取培训类型
@@ -35,7 +35,7 @@ namespace BLL
Remark = trainType.Remark,
IsAboutSendCard = trainType.IsAboutSendCard,
IsRepeat = trainType.IsRepeat,
TrainType=trainType.TrainType,
TrainType = trainType.TrainType,
};
db.Base_TrainType.InsertOnSubmit(newTrainType);
db.SubmitChanges();
+1 -1
View File
@@ -6,7 +6,7 @@ namespace BLL
public static class UnitTypeService
{
/// <summary>
/// 根据主键获取信息
+2 -2
View File
@@ -6,7 +6,7 @@ namespace BLL
{
public static class WorkPostService
{
/// <summary>
/// 根据主键获取信息
@@ -31,7 +31,7 @@ namespace BLL
WorkPostCode = workPost.WorkPostCode,
WorkPostName = workPost.WorkPostName,
PostType = workPost.PostType,
IsCQMS=workPost.IsCQMS,
IsCQMS = workPost.IsCQMS,
IsHsse = workPost.IsHsse,
CNCodes = workPost.CNCodes,
Remark = workPost.Remark
-1
View File
@@ -1,6 +1,5 @@
using System.Collections.Generic;
using System.Linq;
using Model;
namespace BLL
{