添加周例会删除功能

This commit is contained in:
2026-07-09 17:12:04 +08:00
parent abeb97630a
commit c02aabec43
2 changed files with 30 additions and 2 deletions
@@ -106,5 +106,24 @@ namespace BLL
db.SubmitChanges(); db.SubmitChanges();
} }
} }
/// <summary>
/// 根据主键删除周例会
/// </summary>
/// <param name="weekMeetingId"></param>
public static void DeleteWeekMeetingById(string weekMeetingId)
{
Model.SGGLDB db = Funs.DB;
Model.Meeting_WeekMeeting weekMeeting = db.Meeting_WeekMeeting.FirstOrDefault(e => e.WeekMeetingId == weekMeetingId);
if (weekMeeting != null)
{
BLL.CodeRecordsService.DeleteCodeRecordsByDataId(weekMeetingId);
BLL.CommonService.DeleteAttachFileById(weekMeetingId);
////删除审核流程表
BLL.CommonService.DeleteFlowOperateByID(weekMeetingId);
db.Meeting_WeekMeeting.DeleteOnSubmit(weekMeeting);
db.SubmitChanges();
}
}
} }
} }
@@ -97,14 +97,23 @@ namespace WebAPI.Controllers
#endregion #endregion
#region ID删除会议 #region ID删除会议
// type C
[HttpDelete] [HttpDelete]
public Model.ResponeData DeleteMeeting(string meetingId) public Model.ResponeData DeleteMeeting(string meetingId, string type)
{ {
var responeData = new Model.ResponeData(); var responeData = new Model.ResponeData();
try try
{ {
if(type == "C")
{
BLL.ClassMeetingService.DeleteClassMeetingById(meetingId); BLL.ClassMeetingService.DeleteClassMeetingById(meetingId);
} }
if(type == "W")
{
BLL.ClassMeetingService.DeleteWeekMeetingById(meetingId);
}
}
catch (Exception ex) catch (Exception ex)
{ {
responeData.code = 0; responeData.code = 0;