20240122 生产人员培训
This commit is contained in:
@@ -752,8 +752,10 @@
|
||||
<Compile Include="TestRun\FeedingTestRunService.cs" />
|
||||
<Compile Include="TestRun\Meeting\MeetingService.cs" />
|
||||
<Compile Include="TestRun\PersonTrain\DriverPrepareTrainPlanService.cs" />
|
||||
<Compile Include="TestRun\PersonTrain\PersonTrainPlanService.cs" />
|
||||
<Compile Include="TestRun\PersonTrain\TrainContactService.cs" />
|
||||
<Compile Include="TestRun\PersonTrain\TrainContentService.cs" />
|
||||
<Compile Include="TestRun\PersonTrain\TrainRecordsService.cs" />
|
||||
<Compile Include="TestRun\ProduceProperty\AnalySampService.cs" />
|
||||
<Compile Include="TestRun\ProduceProperty\PropertyRunOthersCheckService.cs" />
|
||||
<Compile Include="TestRun\ProduceProperty\PropertyRunPumpCheckService.cs" />
|
||||
|
||||
@@ -1,7 +1,5 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
|
||||
namespace BLL
|
||||
{
|
||||
@@ -3186,6 +3184,16 @@ namespace BLL
|
||||
/// 开车方案编制计划模板文件原始虚拟路径
|
||||
/// </summary>
|
||||
public const string SchemePlanTemplateUrl = "File\\Excel\\TestRun\\开车方案编制计划.xlsx";
|
||||
|
||||
/// <summary>
|
||||
/// 培训报告
|
||||
/// </summary>
|
||||
public const string TestRun_TrainRecordsUrl = "File\\Word\\TestRun\\生产人员培训执行情况报告.doc";
|
||||
|
||||
/// <summary>
|
||||
/// 签到表
|
||||
/// </summary>
|
||||
public const string TestRun_SignUrl = "File\\Word\\TestRun\\项目培训签到表.doc";
|
||||
#endregion
|
||||
|
||||
#region 绩效考核模板文件路径
|
||||
@@ -5107,6 +5115,21 @@ namespace BLL
|
||||
/// </summary>
|
||||
public const string TrainContentMenuId = "600AB952-4DC0-4E6D-8C6F-B7B7B9FE589E";
|
||||
|
||||
/// <summary>
|
||||
/// 人员培训记录
|
||||
/// </summary>
|
||||
public const string PersonTrainPlanMenuId = "C8AD8E40-0E96-4007-A02F-62DDB0B275D5";
|
||||
|
||||
/// <summary>
|
||||
/// 培训合同
|
||||
/// </summary>
|
||||
public const string TrainContractMenuId = "586035BF-A2D4-4199-A503-0ACACBFA5A13";
|
||||
|
||||
/// <summary>
|
||||
/// 培训记录及执行报告
|
||||
/// </summary>
|
||||
public const string TrainRecordsMenuId = "80FDE614-1A37-4C1F-B818-C179CA97D66C";
|
||||
|
||||
/// <summary>
|
||||
/// 开车分包计划
|
||||
/// </summary>
|
||||
|
||||
@@ -233,6 +233,21 @@
|
||||
return list;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 试车管理:培训类型
|
||||
/// </summary>
|
||||
/// <returns></returns>
|
||||
public static ListItem[] drpTrainTypeList()
|
||||
{
|
||||
ListItem[] list = new ListItem[4];
|
||||
list[0] = new ListItem("办公室理论培训", "1");
|
||||
list[1] = new ListItem("制造厂车间培训", "2");
|
||||
list[2] = new ListItem("同类型装置操作培训", "3");
|
||||
list[3] = new ListItem("合同装置现场培训", "4");
|
||||
return list;
|
||||
}
|
||||
|
||||
|
||||
// 定义允许上传的文件类型列表
|
||||
public static List<string> allowExtensions = new List<string>
|
||||
{
|
||||
|
||||
@@ -0,0 +1,87 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace BLL
|
||||
{
|
||||
/// <summary>
|
||||
/// 人员培训计划
|
||||
/// </summary>
|
||||
public class PersonTrainPlanService
|
||||
{
|
||||
/// <summary>
|
||||
/// 根据主键获取人员培训计划
|
||||
/// </summary>
|
||||
/// <param name="personTrainPlanId"></param>
|
||||
/// <returns></returns>
|
||||
public static Model.TestRun_PersonTrainPlan GetPersonTrainPlanById(string personTrainPlanId)
|
||||
{
|
||||
return Funs.DB.TestRun_PersonTrainPlan.FirstOrDefault(e => e.PersonTrainPlanId == personTrainPlanId);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 添加人员培训计划
|
||||
/// </summary>
|
||||
/// <param name="plan"></param>
|
||||
public static void AddPersonTrainPlan(Model.TestRun_PersonTrainPlan plan)
|
||||
{
|
||||
Model.TestRun_PersonTrainPlan newPlan = new Model.TestRun_PersonTrainPlan
|
||||
{
|
||||
PersonTrainPlanId = plan.PersonTrainPlanId,
|
||||
ProjectId = plan.ProjectId,
|
||||
TrainType = plan.TrainType,
|
||||
Purpose = plan.Purpose,
|
||||
TrainingContent = plan.TrainingContent,
|
||||
TrainingAddress = plan.TrainingAddress,
|
||||
TrainingDate = plan.TrainingDate,
|
||||
TrainingPersonNum = plan.TrainingPersonNum,
|
||||
TrainingHours = plan.TrainingHours,
|
||||
TrainingManager = plan.TrainingManager,
|
||||
TrainingTeacher = plan.TrainingTeacher,
|
||||
AssessmentMethod = plan.AssessmentMethod
|
||||
};
|
||||
Funs.DB.TestRun_PersonTrainPlan.InsertOnSubmit(newPlan);
|
||||
Funs.DB.SubmitChanges();
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 修改人员培训计划
|
||||
/// </summary>
|
||||
/// <param name="plan"></param>
|
||||
public static void UpdatePersonTrainPlan(Model.TestRun_PersonTrainPlan plan)
|
||||
{
|
||||
Model.TestRun_PersonTrainPlan newPlan = Funs.DB.TestRun_PersonTrainPlan.FirstOrDefault(e => e.PersonTrainPlanId == plan.PersonTrainPlanId);
|
||||
if (newPlan != null)
|
||||
{
|
||||
newPlan.TrainType = plan.TrainType;
|
||||
newPlan.Purpose = plan.Purpose;
|
||||
newPlan.TrainingContent = plan.TrainingContent;
|
||||
newPlan.TrainingAddress = plan.TrainingAddress;
|
||||
newPlan.TrainingDate = plan.TrainingDate;
|
||||
newPlan.TrainingPersonNum = plan.TrainingPersonNum;
|
||||
newPlan.TrainingHours = plan.TrainingHours;
|
||||
newPlan.TrainingManager = plan.TrainingManager;
|
||||
newPlan.TrainingTeacher = plan.TrainingTeacher;
|
||||
newPlan.AssessmentMethod = plan.AssessmentMethod;
|
||||
Funs.DB.SubmitChanges();
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 根据主键删除人员培训计划
|
||||
/// </summary>
|
||||
/// <param name="personTrainPlanId"></param>
|
||||
public static void DeletePersonTrainPlanById(string personTrainPlanId)
|
||||
{
|
||||
Model.TestRun_PersonTrainPlan newPlan = Funs.DB.TestRun_PersonTrainPlan.FirstOrDefault(e => e.PersonTrainPlanId == personTrainPlanId);
|
||||
if (newPlan != null)
|
||||
{
|
||||
CommonService.DeleteAttachFileById(newPlan.PersonTrainPlanId);//删除附件
|
||||
Funs.DB.TestRun_PersonTrainPlan.DeleteOnSubmit(newPlan);
|
||||
Funs.DB.SubmitChanges();
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,79 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace BLL
|
||||
{
|
||||
/// <summary>
|
||||
/// 培训记录及执行报告
|
||||
/// </summary>
|
||||
public class TrainRecordsService
|
||||
{
|
||||
/// <summary>
|
||||
/// 根据主键获取培训记录及执行报告
|
||||
/// </summary>
|
||||
/// <param name="trainRecordsId"></param>
|
||||
/// <returns></returns>
|
||||
public static Model.TestRun_TrainRecords GetTrainRecordsById(string trainRecordsId)
|
||||
{
|
||||
return Funs.DB.TestRun_TrainRecords.FirstOrDefault(e => e.TrainRecordsId == trainRecordsId);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 添加培训记录及执行报告
|
||||
/// </summary>
|
||||
/// <param name="trainRecords"></param>
|
||||
public static void AddTrainRecords(Model.TestRun_TrainRecords trainRecords)
|
||||
{
|
||||
Model.TestRun_TrainRecords newTrainRecords = new Model.TestRun_TrainRecords
|
||||
{
|
||||
TrainRecordsId = trainRecords.TrainRecordsId,
|
||||
ProjectId = trainRecords.ProjectId,
|
||||
TrainRecordsCode = trainRecords.TrainRecordsCode,
|
||||
TrainRecordsName = trainRecords.TrainRecordsName,
|
||||
UploadDate = trainRecords.UploadDate,
|
||||
CompileMan = trainRecords.CompileMan,
|
||||
CompileDate = trainRecords.CompileDate,
|
||||
Remark = trainRecords.Remark
|
||||
};
|
||||
Funs.DB.TestRun_TrainRecords.InsertOnSubmit(newTrainRecords);
|
||||
Funs.DB.SubmitChanges();
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 修改培训记录及执行报告
|
||||
/// </summary>
|
||||
/// <param name="trainRecords"></param>
|
||||
public static void UpdateTrainRecords(Model.TestRun_TrainRecords trainRecords)
|
||||
{
|
||||
Model.TestRun_TrainRecords newTrainRecords = Funs.DB.TestRun_TrainRecords.FirstOrDefault(e => e.TrainRecordsId == trainRecords.TrainRecordsId);
|
||||
if (newTrainRecords != null)
|
||||
{
|
||||
newTrainRecords.TrainRecordsCode = trainRecords.TrainRecordsCode;
|
||||
newTrainRecords.TrainRecordsName = trainRecords.TrainRecordsName;
|
||||
newTrainRecords.UploadDate = trainRecords.UploadDate;
|
||||
newTrainRecords.CompileMan = trainRecords.CompileMan;
|
||||
newTrainRecords.CompileDate = trainRecords.CompileDate;
|
||||
newTrainRecords.Remark = trainRecords.Remark;
|
||||
Funs.DB.SubmitChanges();
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 根据主键删除培训记录及执行报告
|
||||
/// </summary>
|
||||
/// <param name="trainRecordId"></param>
|
||||
public static void DeleteTrainRecordsById(string trainRecordId)
|
||||
{
|
||||
Model.TestRun_TrainRecords newTrainRecords = Funs.DB.TestRun_TrainRecords.FirstOrDefault(e => e.TrainRecordsId == trainRecordId);
|
||||
if (newTrainRecords != null)
|
||||
{
|
||||
CommonService.DeleteAttachFileById(trainRecordId);//删除附件
|
||||
Funs.DB.TestRun_TrainRecords.DeleteOnSubmit(newTrainRecords);
|
||||
Funs.DB.SubmitChanges();
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user