Compare commits
2 Commits
d2579aee15
...
1236187d73
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
1236187d73 | ||
|
|
56b59b0bb1 |
@ -11335,7 +11335,7 @@ namespace APT.BaseData.Services.DomainServices
|
||||
}
|
||||
else
|
||||
{
|
||||
var entity = this.GetEntity<T_SK_HIDDEN_DANGER_REPORT>(modelApp != null ? modelApp.DATA_ID : entityInt.DATA_ID);
|
||||
var entity = this.GetEntity<T_SK_HIDDEN_DANGER_REPORT>(modelApp != null ? modelApp.DATA_ID : entityInt.DATA_ID, "Nav_ReportFiles");
|
||||
entity.STATUS = PFStandardStatus.Archived;
|
||||
var reportDetails = this.GetEntities<T_SK_HIDDEN_DANGER_REPORT_DETAIL>(t => t.HIDDEN_DANGER_REPORT_ID == entity.ID, new BaseFilter(entity.ORG_ID), "Nav_ReportDetailFiles", "Nav_ReportDetailBasics", "Nav_ReportDetailReasons");
|
||||
//List<T_SK_HIDDEN_DANGER_REPORT_DETAIL> reportDetails = new List<T_SK_HIDDEN_DANGER_REPORT_DETAIL>();
|
||||
@ -11391,8 +11391,8 @@ namespace APT.BaseData.Services.DomainServices
|
||||
record.CHECK_PERSON = entity.CHECK_PERSON;
|
||||
record.CHECK_TYPE_ID = entity.CHECK_TYPE_ID;
|
||||
record.CHECK_QUESTION_ID = detail.CHECK_QUESTION_ID;
|
||||
record.CHECK_CONTENTS_ID = detail.CHECK_CONTENTS_ID;
|
||||
record.CHECK_TIME = entity.CHECK_TIME;
|
||||
record.CHECK_CONTENTS_ID = detail.CHECK_CONTENTS_ID;
|
||||
record.CHECK_TIME = entity.CHECK_TIME != null ? entity.CHECK_TIME : DateTime.Now;
|
||||
records.Add(record);
|
||||
if (detail.Nav_ReportDetailFiles != null && detail.Nav_ReportDetailFiles.Any())
|
||||
{
|
||||
@ -11471,7 +11471,7 @@ namespace APT.BaseData.Services.DomainServices
|
||||
record.CHECK_TYPE_ID = entity.CHECK_TYPE_ID;
|
||||
record.CHECK_QUESTION_ID = detail.CHECK_QUESTION_ID;
|
||||
record.CHECK_CONTENTS_ID = detail.CHECK_CONTENTS_ID;
|
||||
record.CHECK_TIME = entity.CHECK_TIME;
|
||||
record.CHECK_TIME = entity.CHECK_TIME != null ? entity.CHECK_TIME : DateTime.Now;
|
||||
records.Add(record);
|
||||
if (detail.Nav_ReportDetailFiles != null && detail.Nav_ReportDetailFiles.Any())
|
||||
{
|
||||
@ -11531,20 +11531,20 @@ namespace APT.BaseData.Services.DomainServices
|
||||
notice.CHECK_TYPE_ID = entity.CHECK_TYPE_ID;
|
||||
notice.PLANCHECKFREQUENCY = entity.PLANCHECKFREQUENCY;
|
||||
notice.DEPARTMENT_TYPE = entity.DEPARTMENT_TYPE;
|
||||
notice.CHECK_TIME = entity.CHECK_TIME;
|
||||
notice.CHECK_TIME = entity.CHECK_TIME!=null ? entity.CHECK_TIME :DateTime.Now;
|
||||
notice.CHECK_PERSON = entity.CHECK_PERSON;
|
||||
notices.Add(notice);
|
||||
//if (entity.Nav_ReportFiles != null && entity.Nav_ReportFiles.Any())
|
||||
//{
|
||||
// foreach (var item in entity.Nav_ReportFiles)
|
||||
// {
|
||||
// T_SK_HIDDEN_DANGER_RECTIFY_NOTICE_FILE file = new T_SK_HIDDEN_DANGER_RECTIFY_NOTICE_FILE();
|
||||
// file.ORG_ID = item.ORG_ID;
|
||||
// file.IMG_FILE_ID = item.IMG_FILE_ID;
|
||||
// file.HIDDEN_DANGER_RECTIFY_NOTICE_ID = notice.ID;
|
||||
// nfileList.Add(file);
|
||||
// }
|
||||
//}
|
||||
if (entity.Nav_ReportFiles != null && entity.Nav_ReportFiles.Any())
|
||||
{
|
||||
foreach (var item in entity.Nav_ReportFiles)
|
||||
{
|
||||
T_SK_HIDDEN_DANGER_RECTIFY_NOTICE_FILE file = new T_SK_HIDDEN_DANGER_RECTIFY_NOTICE_FILE();
|
||||
file.ORG_ID = item.ORG_ID;
|
||||
file.IMG_FILE_ID = item.IMG_FILE_ID;
|
||||
file.HIDDEN_DANGER_RECTIFY_NOTICE_ID = notice.ID;
|
||||
nfileList.Add(file);
|
||||
}
|
||||
}
|
||||
T_SK_HIDDEN_DANGER_RECTIFY_NOTICE_DETAIL noticeDetail = new T_SK_HIDDEN_DANGER_RECTIFY_NOTICE_DETAIL();
|
||||
noticeDetail.ORG_ID = entity.ORG_ID;
|
||||
noticeDetail.HIDDEN_DANGER_RECTIFY_NOTICE_ID = notice.ID;
|
||||
@ -11604,15 +11604,16 @@ namespace APT.BaseData.Services.DomainServices
|
||||
DateTime.Now.AddDays(1), (int)FMNoticeTypeEnum.消息, "SK020");
|
||||
sendNotices.Add(sendNotice);
|
||||
}
|
||||
var checkUser = users.FirstOrDefault(t => t.ID == detail.RECITIFY_USER_ID);
|
||||
if (checkUser != null)
|
||||
{
|
||||
var sendNotice = NotificationTaskService.InsertUserNoticeTaskModel("隐患上报表" + DateTime.Now.Month.PadLeft(2,'0')+ DateTime.Now.Day.PadLeft(2, '0') + "-确认", entity.ID, entity.ORG_ID, checkUser.ID, checkUser.NAME, DateTime.Now,
|
||||
DateTime.Now.AddHours(24), (int)FMNoticeTypeEnum.消息, "SK014_SHOWPRINT");
|
||||
sendNotices.Add(sendNotice);
|
||||
}
|
||||
detail.Nav_ReportDetailBasics = null;
|
||||
detail.Nav_ReportDetailFiles = null;
|
||||
}
|
||||
var checkUser = users.FirstOrDefault(t => t.ID == detail.RECITIFY_USER_ID);
|
||||
if (checkUser != null)
|
||||
{
|
||||
var sendNotice = NotificationTaskService.InsertUserNoticeTaskModel("隐患上报表" + DateTime.Now.Month.PadLeft(2, '0') + DateTime.Now.Day.PadLeft(2, '0') + "-确认", entity.ID, entity.ORG_ID, checkUser.ID, checkUser.NAME, DateTime.Now,
|
||||
DateTime.Now.AddHours(24), (int)FMNoticeTypeEnum.消息, "SK014_SHOWPRINT");
|
||||
sendNotices.Add(sendNotice);
|
||||
entity.STATUS = PFStandardStatus.Sign;
|
||||
}
|
||||
//if (detail.IS_STORE == SKIsStoreEnum.Yes)
|
||||
//{
|
||||
@ -11728,7 +11729,7 @@ namespace APT.BaseData.Services.DomainServices
|
||||
}
|
||||
else
|
||||
{
|
||||
var entity = this.GetEntity<T_SK_HIDDEN_DANGER_CONFIRM>(modelApp != null ? modelApp.DATA_ID : entityInt.DATA_ID, "Nav_Report", "Nav_Reasons");
|
||||
var entity = this.GetEntity<T_SK_HIDDEN_DANGER_CONFIRM>(modelApp != null ? modelApp.DATA_ID : entityInt.DATA_ID, "Nav_Report", "Nav_Reasons", "Nav_Files");
|
||||
entity.STATUS = PFStandardStatus.Archived;
|
||||
var photos = this.GetEntities<T_SK_HIDDEN_DANGER_CONFIRM_PHOTO>(t => t.HIDDEN_DANGER_CONFIRM_ID == entity.ID, new BaseFilter(entity.ORG_ID));
|
||||
var users = this.GetEntities<T_FM_USER>(t => t.ENABLE_STATUS == 0, new BaseFilter(entity.ORG_ID), "Nav_ApproveRole");
|
||||
@ -11737,7 +11738,8 @@ namespace APT.BaseData.Services.DomainServices
|
||||
List<T_FM_NOTIFICATION_TASK> sendNotices = new List<T_FM_NOTIFICATION_TASK>();
|
||||
T_SK_HIDDEN_DANGER_RECTIFY_RECORD record = null;
|
||||
List<T_SK_HIDDEN_DANGER_RECTIFY_RECORD_PHOTOA> photoList = new List<T_SK_HIDDEN_DANGER_RECTIFY_RECORD_PHOTOA>();
|
||||
T_SK_HIDDEN_DANGER_RECTIFY_NOTICE notice = null;
|
||||
T_SK_HIDDEN_DANGER_RECTIFY_NOTICE notice = null;
|
||||
List<T_SK_HIDDEN_DANGER_RECTIFY_NOTICE_FILE> noticeFiles = new List<T_SK_HIDDEN_DANGER_RECTIFY_NOTICE_FILE>();
|
||||
List<T_SK_HIDDEN_DANGER_RECTIFY_NOTICE_DETAIL> noticeDetails = new List<T_SK_HIDDEN_DANGER_RECTIFY_NOTICE_DETAIL>();
|
||||
List<T_SK_HIDDEN_DANGER_RECTIFY_NOTICE_DETAIL_FILE> noticeFileList = new List<T_SK_HIDDEN_DANGER_RECTIFY_NOTICE_DETAIL_FILE>();
|
||||
List<T_SK_HIDDEN_DANGER_RECTIFY_NOTICE_DETAIL_REASON> noticeReasonList = new List<T_SK_HIDDEN_DANGER_RECTIFY_NOTICE_DETAIL_REASON>();
|
||||
@ -11928,7 +11930,18 @@ namespace APT.BaseData.Services.DomainServices
|
||||
notice.PLANCHECKFREQUENCY = entity.PLANCHECKFREQUENCY;
|
||||
notice.DEPARTMENT_TYPE = entity.DEPARTMENT_TYPE;
|
||||
notice.CREATE_TIME = entity.Nav_Report?.CREATE_TIME;
|
||||
notice.CHECK_PERSON = entity.Nav_ApplyUser?.NAME;
|
||||
notice.CHECK_PERSON = entity.Nav_ApplyUser?.NAME;
|
||||
if (entity.Nav_Files != null && entity.Nav_Files.Any())
|
||||
{
|
||||
foreach (var item in entity.Nav_Files)
|
||||
{
|
||||
T_SK_HIDDEN_DANGER_RECTIFY_NOTICE_FILE file = new T_SK_HIDDEN_DANGER_RECTIFY_NOTICE_FILE();
|
||||
file.ORG_ID = item.ORG_ID;
|
||||
file.IMG_FILE_ID = item.IMG_FILE_ID;
|
||||
file.HIDDEN_DANGER_RECTIFY_NOTICE_ID = notice.ID;
|
||||
noticeFiles.Add(file);
|
||||
}
|
||||
}
|
||||
T_SK_HIDDEN_DANGER_RECTIFY_NOTICE_DETAIL noticeDetail = new T_SK_HIDDEN_DANGER_RECTIFY_NOTICE_DETAIL();
|
||||
noticeDetail.ORG_ID = entity.ORG_ID;
|
||||
noticeDetail.HIDDEN_DANGER_RECTIFY_NOTICE_ID = notice.ID;
|
||||
@ -11978,6 +11991,14 @@ namespace APT.BaseData.Services.DomainServices
|
||||
DateTime.Now.AddDays(1), (int)FMNoticeTypeEnum.消息, "SK020");
|
||||
sendNotices.Add(sendNotice);
|
||||
}
|
||||
}
|
||||
var checkUser = users.FirstOrDefault(t => t.ID == entity.RECITIFY_USER_ID);
|
||||
if (checkUser != null)
|
||||
{
|
||||
var sendNotice = NotificationTaskService.InsertUserNoticeTaskModel("隐患确认单" + DateTime.Now.Month.PadLeft(2, '0') + DateTime.Now.Day.PadLeft(2, '0') + "-确认", entity.ID, entity.ORG_ID, checkUser.ID, checkUser.NAME, DateTime.Now,
|
||||
DateTime.Now.AddHours(24), (int)FMNoticeTypeEnum.消息, "SK018_SHOWPRINT");
|
||||
sendNotices.Add(sendNotice);
|
||||
entity.STATUS = PFStandardStatus.Sign;
|
||||
}
|
||||
}
|
||||
UnifiedCommit(() =>
|
||||
@ -12006,6 +12027,8 @@ namespace APT.BaseData.Services.DomainServices
|
||||
this.BantchSaveEntityNoCommit(reasonList);
|
||||
if (notice != null)
|
||||
this.UpdateEntityNoCommit(notice);
|
||||
if (noticeFiles != null && noticeFiles.Any())
|
||||
this.BantchSaveEntityNoCommit(noticeFiles);
|
||||
if (noticeDetails != null && noticeDetails.Any())
|
||||
this.BantchSaveEntityNoCommit(noticeDetails);
|
||||
if (noticeFileList != null && noticeFileList.Any())
|
||||
@ -12099,9 +12122,11 @@ namespace APT.BaseData.Services.DomainServices
|
||||
else
|
||||
{
|
||||
var entity = this.GetEntity<T_SK_HIDDEN_DANGER_RECTIFY_DELAY_APPLY>(modelApp != null ? modelApp.DATA_ID : entityInt.DATA_ID);
|
||||
entity.STATUS = PFStandardStatus.Sign;
|
||||
entity.STATUS = PFStandardStatus.Reading;
|
||||
var record = this.GetEntity<T_SK_HIDDEN_DANGER_RECTIFY_RECORD>(t => t.ID == entity.HIDDEN_DANGER_RECTIFY_RECORD_ID, "Nav_AcceptUser");
|
||||
record.RECITIFY_TIME = DateTime.Now;
|
||||
record.RECITIFY_TIME = entity.DELAY_RECITIFY_TIME;
|
||||
var noticeTasks = this.GetEntities<T_FM_NOTIFICATION_TASK>(t => t.SOURCE_DATA_ID == entity.HIDDEN_DANGER_RECTIFY_RECORD_ID && t.NOTICE_STATUS == 0,new BaseFilter(entity.ORG_ID));
|
||||
noticeTasks.ForEach(t => { t.TASK_ENDDT = entity.DELAY_RECITIFY_TIME.Value; });
|
||||
T_FM_NOTIFICATION_TASK notice = null;
|
||||
if (record != null && record.ACCEPT_USER_ID != null)
|
||||
{
|
||||
@ -12123,7 +12148,9 @@ namespace APT.BaseData.Services.DomainServices
|
||||
if (record != null)
|
||||
this.UpdateEntityNoCommit(record);
|
||||
if (notice != null)
|
||||
this.UpdateEntityNoCommit(notice);
|
||||
this.UpdateEntityNoCommit(notice);
|
||||
if (noticeTasks != null && noticeTasks.Any())
|
||||
BantchSaveEntityNoCommit(noticeTasks);
|
||||
});
|
||||
}
|
||||
return true;
|
||||
|
||||
@ -1315,6 +1315,7 @@ builder.Property(t => t.REQUIRES).HasMaxLength(500);
|
||||
builder.Ignore(t => t.PUBLISH);
|
||||
builder.Ignore(t => t.IS_OVERTIME);
|
||||
builder.Property(t => t.PARENT_NAME).HasMaxLength(500);
|
||||
builder.Ignore(t => t.Nav_AcceptUsers);
|
||||
}
|
||||
}
|
||||
#endregion
|
||||
|
||||
@ -163,6 +163,10 @@ namespace APT.MS.Domain.Entities.FO
|
||||
/// 相关方
|
||||
/// </summary>
|
||||
[Description("相关方")]
|
||||
public Guid? RELATED_ID { get; set; }
|
||||
public Guid? RELATED_ID { get; set; }
|
||||
|
||||
[Description("导航属性:完工验收人员表")]
|
||||
[DataFieldIngore]
|
||||
public ICollection<T_FO_JOB_ACTIVITY_PERSON> Nav_AcceptUsers { get; set; }
|
||||
}
|
||||
}
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
@ -122,13 +122,30 @@ namespace APT.FO.WebApi.Controllers
|
||||
entity.Nav_Flow = safeMeasures.OrderBy(t => t.NUM).ThenBy(m => m.SafeMeasuresStr).ToList();
|
||||
newFilter.SelectField = new List<string> { "ID", "NUM", "JOB_ACTIVITY_RECORD_ID", "DealMeasuresStr", "IS_CONFIRM", "Nav_Files.Nav_ImgFile.FILE_NAME", "Nav_Files.Nav_ImgFile.FILE_PATH", "Nav_Files.Nav_ImgFile.FILE_TYPE", "Nav_Files.Nav_ImgFile" };
|
||||
var dealMeasures = this.GetEntities<T_FO_JOB_ACTIVITY_MEASURE>(t => t.JOB_ACTIVITY_RECORD_ID == entity.ID, newFilter).ToList();
|
||||
entity.Nav_Measure = dealMeasures.OrderBy(t => t.NUM).ThenBy(m => m.DealMeasuresStr).ToList();
|
||||
//if (result.Nav_Details != null && result.Nav_Details.Any())
|
||||
// result.Nav_Details = result.Nav_Details.OrderBy(t => t.NUM).ThenBy(m => m.SafeConfirmsStr).ToList();
|
||||
//if (result.Nav_Flow != null && result.Nav_Flow.Any())
|
||||
// result.Nav_Flow = result.Nav_Flow.OrderBy(t => t.NUM).ThenBy(m => m.SafeMeasuresStr).ToList();
|
||||
//if (result.Nav_Measure != null && result.Nav_Measure.Any())
|
||||
// result.Nav_Measure = result.Nav_Measure.OrderBy(t => t.NUM).ThenBy(m => m.DealMeasuresStr).ToList();
|
||||
entity.Nav_Measure = dealMeasures.OrderBy(t => t.NUM).ThenBy(m => m.DealMeasuresStr).ToList();
|
||||
//if (result.Nav_Details != null && result.Nav_Details.Any())
|
||||
// result.Nav_Details = result.Nav_Details.OrderBy(t => t.NUM).ThenBy(m => m.SafeConfirmsStr).ToList();
|
||||
//if (result.Nav_Flow != null && result.Nav_Flow.Any())
|
||||
// result.Nav_Flow = result.Nav_Flow.OrderBy(t => t.NUM).ThenBy(m => m.SafeMeasuresStr).ToList();
|
||||
//if (result.Nav_Measure != null && result.Nav_Measure.Any())
|
||||
// result.Nav_Measure = result.Nav_Measure.OrderBy(t => t.NUM).ThenBy(m => m.DealMeasuresStr).ToList();
|
||||
var tasks = this.GetEntities<T_FM_NOTIFICATION_TASK>(t => t.SOURCE_DATA_ID == entity.ID && t.SOURCE_FORMCODE == "FO022_SHOWPRINT" && t.NOTICE_TITLE == "关键许可作业活动记录-完工验收" && !t.IS_DELETED, null);
|
||||
if (tasks != null && tasks.Any())
|
||||
{
|
||||
var taskUserIds = tasks.Select(m => m.USER_ID).Distinct().ToList();
|
||||
entity.Nav_AcceptUsers = new List<T_FO_JOB_ACTIVITY_PERSON>();
|
||||
var users = this.GetEntities<T_FM_USER>(t => taskUserIds.Contains(t.ID), null, "Nav_UserSignFiles.Nav_ImgFile");
|
||||
foreach (var task in tasks)
|
||||
{
|
||||
var user = users.FirstOrDefault(t => t.ID == task.USER_ID);
|
||||
T_FO_JOB_ACTIVITY_PERSON pe = new T_FO_JOB_ACTIVITY_PERSON();
|
||||
pe.USER_ID = task.USER_ID;
|
||||
pe.Nav_User = user;
|
||||
pe.DEAL_STATUS = task.NOTICE_STATUS == 0 ? 0 : 1;
|
||||
pe.JOB_ACTIVITY_RECORD_ID = entity.ID;
|
||||
entity.Nav_AcceptUsers.Add(pe);
|
||||
}
|
||||
}
|
||||
}
|
||||
return entity;
|
||||
});
|
||||
@ -346,7 +363,9 @@ namespace APT.FO.WebApi.Controllers
|
||||
if (entity.IS_OUTSOURCE == true && entity.RELATED_ID != null)
|
||||
{
|
||||
entity.FORM_STATUS = (int)FOTeamActivityState.已归档;
|
||||
users.ForEach(t => t.DEAL_STATUS = 1);
|
||||
users.ForEach(t => t.DEAL_STATUS = 1);
|
||||
//触发完工验收
|
||||
GetAutoNext(entity, ref notices);
|
||||
}
|
||||
else
|
||||
{
|
||||
@ -486,6 +505,7 @@ namespace APT.FO.WebApi.Controllers
|
||||
userIds.Distinct();
|
||||
var userInfos = this.GetEntities<T_FM_USER>(t => t.ENABLE_STATUS == 0, new BaseFilter(job.ORG_ID));
|
||||
var departIds = userInfos.Where(t => userIds.Contains(t.ID)).Select(m => m.DEPARTMENT_ID).Distinct().ToList();
|
||||
departIds.Add(job.TERRITORY_DEPARTMENT_ID);
|
||||
var chargeUserIds = this.GetEntities<T_FM_DEPARTMENT>(t => departIds.Contains(t.ID) && t.USER_ID != null, new BaseFilter(job.ORG_ID)).Select(m => (Guid)m.USER_ID).Distinct().ToList();
|
||||
if (chargeUserIds != null && chargeUserIds.Any())
|
||||
{
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
@ -1,128 +1,137 @@
|
||||
|
||||
|
||||
|
||||
|
||||
//------------------------------------------------------------------------------
|
||||
// T4模板文件:基础接口类
|
||||
// 此代码由T4模板自动生成
|
||||
// 对此文件的更改可能会导致不正确的行为,并且如果重新生成代码,这些更改将会丢失。
|
||||
//------------------------------------------------------------------------------
|
||||
using APT.Infrastructure.Core;
|
||||
using Microsoft.AspNetCore.Mvc;
|
||||
using System.Collections.Generic;
|
||||
using APT.Utility;
|
||||
using APT.Infrastructure.Api;
|
||||
using APT.BaseData.Domain.ApiModel.PF;
|
||||
namespace APT.LG.WebApi.Controllers.Api
|
||||
{
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
//------------------------------------------------------------------------------
|
||||
// T4模板文件:基础接口类
|
||||
// 此代码由T4模板自动生成
|
||||
// 对此文件的更改可能会导致不正确的行为,并且如果重新生成代码,这些更改将会丢失。
|
||||
//------------------------------------------------------------------------------
|
||||
using APT.Infrastructure.Core;
|
||||
using Microsoft.AspNetCore.Mvc;
|
||||
using System.Collections.Generic;
|
||||
using APT.Utility;
|
||||
using APT.Infrastructure.Api;
|
||||
using APT.BaseData.Domain.ApiModel.PF;
|
||||
namespace APT.LG.WebApi.Controllers.Api
|
||||
{
|
||||
using APT.BaseData.Domain.Entities.LG;
|
||||
#region Oprate-表单操作日志表
|
||||
/// <summary>
|
||||
/// 表单操作日志表
|
||||
/// </summary>
|
||||
[Route("api/LG/Oprate")]
|
||||
public partial class OprateController : AuthorizeApiController<T_LG_OPRATE>
|
||||
{
|
||||
/// <summary>
|
||||
/// 查询所有数据
|
||||
/// </summary>
|
||||
/// <param name="filter">过滤实体</param>
|
||||
/// <returns></returns>
|
||||
[HttpPost, Route("Entities")]
|
||||
public JsonActionResult<IEnumerable<T_LG_OPRATE>> Entities([FromBody]KeywordFilter filter)
|
||||
{
|
||||
return WitEntities(null, filter);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 排序查询所有数据
|
||||
/// </summary>
|
||||
/// <param name="filter">过滤实体</param>
|
||||
/// <returns></returns>
|
||||
|
||||
[HttpPost, Route("OrderEntities")]
|
||||
public JsonActionResult<IEnumerable<T_LG_OPRATE>> OrderEntities([FromBody]KeywordFilter filter)
|
||||
{
|
||||
return WitOrderEntities(null, filter);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 分页查询数据
|
||||
/// </summary>
|
||||
/// <param name="pageFilter">分页过滤实体</param>
|
||||
/// <returns></returns>
|
||||
[HttpPost, Route("Paged")]
|
||||
public PagedActionResult<T_LG_OPRATE> Paged([FromBody]KeywordPageFilter pageFilter)
|
||||
{
|
||||
return WitPaged(null, pageFilter);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 排序分页查询数据
|
||||
/// </summary>
|
||||
/// <param name="pageFilter">分页过滤实体</param>
|
||||
/// <returns></returns>
|
||||
[HttpPost, Route("OrderPaged")]
|
||||
public PagedActionResult<T_LG_OPRATE> OrderPaged([FromBody]KeywordPageFilter pageFilter)
|
||||
{
|
||||
return WitOrderPaged(null, pageFilter);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 根据主键删除数据
|
||||
/// </summary>
|
||||
/// <param name="id">主键ID</param>
|
||||
/// <returns></returns>
|
||||
[HttpGet, Route("Delete")]
|
||||
public JsonActionResult<bool> Delete(string id)
|
||||
{
|
||||
return WitRealDelete(id);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 更新或新增数据
|
||||
/// </summary>
|
||||
/// <param name="entity">对象实体</param>
|
||||
/// <returns></returns>
|
||||
[HttpPost, Route("Update")]
|
||||
public JsonActionResult<bool> Update([FromBody]T_LG_OPRATE entity)
|
||||
{
|
||||
return WitUpdate(entity);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 批量更新
|
||||
/// </summary>
|
||||
/// <param name="entity">对象实体</param>
|
||||
/// <returns></returns>
|
||||
[HttpPost, Route("BatchUpdate")]
|
||||
public JsonActionResult<bool> BatchUpdate([FromBody] BatchUpdateModel<T_LG_OPRATE> entity)
|
||||
{
|
||||
return WitBantchUpdate(entity?.Data);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 批量删除数据
|
||||
/// </summary>
|
||||
/// <param name="ids">id字符串(id用逗号分隔)</param>
|
||||
/// <returns></returns>
|
||||
[HttpGet, Route("BatchDelete")]
|
||||
public JsonActionResult<bool> BatchDelete(string ids)
|
||||
{
|
||||
return WitRealBatchDelete(ids);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 获得单条实体数据
|
||||
/// </summary>
|
||||
/// <param name="filter">过滤实体</param>
|
||||
/// <returns></returns>
|
||||
[HttpPost, Route("Get")]
|
||||
public JsonActionResult<T_LG_OPRATE> Get([FromBody] KeywordFilter filter)
|
||||
{
|
||||
return WitEntity(null, filter);
|
||||
}
|
||||
|
||||
}
|
||||
#endregion
|
||||
}
|
||||
|
||||
#region Oprate-表单操作日志表
|
||||
/// <summary>
|
||||
/// 表单操作日志表
|
||||
/// </summary>
|
||||
[Route("api/LG/Oprate")]
|
||||
public partial class OprateController : AuthorizeApiController<T_LG_OPRATE>
|
||||
{
|
||||
/// <summary>
|
||||
/// 查询所有数据
|
||||
/// </summary>
|
||||
/// <param name="filter">过滤实体</param>
|
||||
/// <returns></returns>
|
||||
[HttpPost, Route("Entities")]
|
||||
public JsonActionResult<IEnumerable<T_LG_OPRATE>> Entities([FromBody]KeywordFilter filter)
|
||||
{
|
||||
return WitEntities(null, filter);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 排序查询所有数据
|
||||
/// </summary>
|
||||
/// <param name="filter">过滤实体</param>
|
||||
/// <returns></returns>
|
||||
|
||||
[HttpPost, Route("OrderEntities")]
|
||||
public JsonActionResult<IEnumerable<T_LG_OPRATE>> OrderEntities([FromBody]KeywordFilter filter)
|
||||
{
|
||||
return WitOrderEntities(null, filter);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 分页查询数据
|
||||
/// </summary>
|
||||
/// <param name="pageFilter">分页过滤实体</param>
|
||||
/// <returns></returns>
|
||||
[HttpPost, Route("Paged")]
|
||||
public PagedActionResult<T_LG_OPRATE> Paged([FromBody]KeywordPageFilter pageFilter)
|
||||
{
|
||||
return WitPaged(null, pageFilter);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 排序分页查询数据
|
||||
/// </summary>
|
||||
/// <param name="pageFilter">分页过滤实体</param>
|
||||
/// <returns></returns>
|
||||
[HttpPost, Route("OrderPaged")]
|
||||
public PagedActionResult<T_LG_OPRATE> OrderPaged([FromBody]KeywordPageFilter pageFilter)
|
||||
{
|
||||
return WitOrderPaged(null, pageFilter);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 根据主键删除数据
|
||||
/// </summary>
|
||||
/// <param name="id">主键ID</param>
|
||||
/// <returns></returns>
|
||||
[HttpGet, Route("Delete")]
|
||||
public JsonActionResult<bool> Delete(string id)
|
||||
{
|
||||
return WitRealDelete(id);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 更新或新增数据
|
||||
/// </summary>
|
||||
/// <param name="entity">对象实体</param>
|
||||
/// <returns></returns>
|
||||
[HttpPost, Route("Update")]
|
||||
public JsonActionResult<bool> Update([FromBody]T_LG_OPRATE entity)
|
||||
{
|
||||
return WitUpdate(entity);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 批量更新
|
||||
/// </summary>
|
||||
/// <param name="entity">对象实体</param>
|
||||
/// <returns></returns>
|
||||
[HttpPost, Route("BatchUpdate")]
|
||||
public JsonActionResult<bool> BatchUpdate([FromBody] BatchUpdateModel<T_LG_OPRATE> entity)
|
||||
{
|
||||
return WitBantchUpdate(entity?.Data);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 批量删除数据
|
||||
/// </summary>
|
||||
/// <param name="ids">id字符串(id用逗号分隔)</param>
|
||||
/// <returns></returns>
|
||||
[HttpGet, Route("BatchDelete")]
|
||||
public JsonActionResult<bool> BatchDelete(string ids)
|
||||
{
|
||||
return WitRealBatchDelete(ids);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 获得单条实体数据
|
||||
/// </summary>
|
||||
/// <param name="filter">过滤实体</param>
|
||||
/// <returns></returns>
|
||||
[HttpPost, Route("Get")]
|
||||
public JsonActionResult<T_LG_OPRATE> Get([FromBody] KeywordFilter filter)
|
||||
{
|
||||
return WitEntity(null, filter);
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
#endregion
|
||||
|
||||
}
|
||||
|
||||
@ -1,356 +1,370 @@
|
||||
|
||||
|
||||
|
||||
|
||||
//------------------------------------------------------------------------------
|
||||
// T4模板文件:基础接口类
|
||||
// 此代码由T4模板自动生成
|
||||
// 对此文件的更改可能会导致不正确的行为,并且如果重新生成代码,这些更改将会丢失。
|
||||
//------------------------------------------------------------------------------
|
||||
using APT.Infrastructure.Core;
|
||||
using Microsoft.AspNetCore.Mvc;
|
||||
using System.Collections.Generic;
|
||||
using APT.Utility;
|
||||
using APT.Infrastructure.Api;
|
||||
using APT.BaseData.Domain.ApiModel.PF;
|
||||
namespace APT.NW.WebApi.Controllers.Api
|
||||
{
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
//------------------------------------------------------------------------------
|
||||
// T4模板文件:基础接口类
|
||||
// 此代码由T4模板自动生成
|
||||
// 对此文件的更改可能会导致不正确的行为,并且如果重新生成代码,这些更改将会丢失。
|
||||
//------------------------------------------------------------------------------
|
||||
using APT.Infrastructure.Core;
|
||||
using Microsoft.AspNetCore.Mvc;
|
||||
using System.Collections.Generic;
|
||||
using APT.Utility;
|
||||
using APT.Infrastructure.Api;
|
||||
using APT.BaseData.Domain.ApiModel.PF;
|
||||
namespace APT.NW.WebApi.Controllers.Api
|
||||
{
|
||||
using APT.BaseData.Domain.Entities.NW;
|
||||
#region Enterprise-子企业表
|
||||
/// <summary>
|
||||
/// 子企业表
|
||||
/// </summary>
|
||||
[Route("api/NW/Enterprise")]
|
||||
public partial class EnterpriseController : AuthorizeTreeApiController<T_NW_ENTERPRISE>
|
||||
{
|
||||
/// <summary>
|
||||
/// 查询所有数据
|
||||
/// </summary>
|
||||
/// <param name="filter">过滤实体</param>
|
||||
/// <returns></returns>
|
||||
[HttpPost, Route("Entities")]
|
||||
public JsonActionResult<IEnumerable<T_NW_ENTERPRISE>> Entities([FromBody]KeywordFilter filter)
|
||||
{
|
||||
return WitEntities(null, filter);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 排序查询所有数据
|
||||
/// </summary>
|
||||
/// <param name="filter">过滤实体</param>
|
||||
/// <returns></returns>
|
||||
|
||||
[HttpPost, Route("OrderEntities")]
|
||||
public JsonActionResult<IEnumerable<T_NW_ENTERPRISE>> OrderEntities([FromBody]KeywordFilter filter)
|
||||
{
|
||||
return WitOrderEntities(null, filter);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 分页查询数据
|
||||
/// </summary>
|
||||
/// <param name="pageFilter">分页过滤实体</param>
|
||||
/// <returns></returns>
|
||||
[HttpPost, Route("Paged")]
|
||||
public PagedActionResult<T_NW_ENTERPRISE> Paged([FromBody]KeywordPageFilter pageFilter)
|
||||
{
|
||||
return WitPaged(null, pageFilter);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 排序分页查询数据
|
||||
/// </summary>
|
||||
/// <param name="pageFilter">分页过滤实体</param>
|
||||
/// <returns></returns>
|
||||
[HttpPost, Route("OrderPaged")]
|
||||
public PagedActionResult<T_NW_ENTERPRISE> OrderPaged([FromBody]KeywordPageFilter pageFilter)
|
||||
{
|
||||
return WitOrderPaged(null, pageFilter);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 根据主键删除数据
|
||||
/// </summary>
|
||||
/// <param name="id">主键ID</param>
|
||||
/// <returns></returns>
|
||||
[HttpGet, Route("Delete")]
|
||||
public JsonActionResult<bool> Delete(string id)
|
||||
{
|
||||
return WitRealDelete(id);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 更新或新增数据
|
||||
/// </summary>
|
||||
/// <param name="entity">对象实体</param>
|
||||
/// <returns></returns>
|
||||
[HttpPost, Route("Update")]
|
||||
public JsonActionResult<bool> Update([FromBody]T_NW_ENTERPRISE entity)
|
||||
{
|
||||
return WitUpdate(entity);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 批量更新
|
||||
/// </summary>
|
||||
/// <param name="entity">对象实体</param>
|
||||
/// <returns></returns>
|
||||
[HttpPost, Route("BatchUpdate")]
|
||||
public JsonActionResult<bool> BatchUpdate([FromBody] BatchUpdateModel<T_NW_ENTERPRISE> entity)
|
||||
{
|
||||
return WitBantchUpdate(entity?.Data);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 批量删除数据
|
||||
/// </summary>
|
||||
/// <param name="ids">id字符串(id用逗号分隔)</param>
|
||||
/// <returns></returns>
|
||||
[HttpGet, Route("BatchDelete")]
|
||||
public JsonActionResult<bool> BatchDelete(string ids)
|
||||
{
|
||||
return WitRealBatchDelete(ids);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 获得单条实体数据
|
||||
/// </summary>
|
||||
/// <param name="filter">过滤实体</param>
|
||||
/// <returns></returns>
|
||||
[HttpPost, Route("Get")]
|
||||
public JsonActionResult<T_NW_ENTERPRISE> Get([FromBody] KeywordFilter filter)
|
||||
{
|
||||
return WitEntity(null, filter);
|
||||
}
|
||||
/// <summary>
|
||||
/// 获得树形实体数据
|
||||
/// </summary>
|
||||
/// <param name="filter"></param>
|
||||
/// <returns></returns>
|
||||
[HttpPost, Route("TreeData")]
|
||||
public JsonActionResult<IEnumerable<TreeNode<T_NW_ENTERPRISE>>> TreeData([FromBody] KeywordFilter filter)
|
||||
{
|
||||
return WitTreeOrderEntities(null, filter);
|
||||
}
|
||||
|
||||
}
|
||||
#endregion
|
||||
#region RoleDataPerm-子企业数据权限表
|
||||
/// <summary>
|
||||
/// 子企业数据权限表
|
||||
/// </summary>
|
||||
[Route("api/NW/RoleDataPerm")]
|
||||
public partial class RoleDataPermController : AuthorizeApiController<T_NW_ROLE_DATA_PERM>
|
||||
{
|
||||
/// <summary>
|
||||
/// 查询所有数据
|
||||
/// </summary>
|
||||
/// <param name="filter">过滤实体</param>
|
||||
/// <returns></returns>
|
||||
[HttpPost, Route("Entities")]
|
||||
public JsonActionResult<IEnumerable<T_NW_ROLE_DATA_PERM>> Entities([FromBody]KeywordFilter filter)
|
||||
{
|
||||
return WitEntities(null, filter);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 排序查询所有数据
|
||||
/// </summary>
|
||||
/// <param name="filter">过滤实体</param>
|
||||
/// <returns></returns>
|
||||
|
||||
[HttpPost, Route("OrderEntities")]
|
||||
public JsonActionResult<IEnumerable<T_NW_ROLE_DATA_PERM>> OrderEntities([FromBody]KeywordFilter filter)
|
||||
{
|
||||
return WitOrderEntities(null, filter);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 分页查询数据
|
||||
/// </summary>
|
||||
/// <param name="pageFilter">分页过滤实体</param>
|
||||
/// <returns></returns>
|
||||
[HttpPost, Route("Paged")]
|
||||
public PagedActionResult<T_NW_ROLE_DATA_PERM> Paged([FromBody]KeywordPageFilter pageFilter)
|
||||
{
|
||||
return WitPaged(null, pageFilter);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 排序分页查询数据
|
||||
/// </summary>
|
||||
/// <param name="pageFilter">分页过滤实体</param>
|
||||
/// <returns></returns>
|
||||
[HttpPost, Route("OrderPaged")]
|
||||
public PagedActionResult<T_NW_ROLE_DATA_PERM> OrderPaged([FromBody]KeywordPageFilter pageFilter)
|
||||
{
|
||||
return WitOrderPaged(null, pageFilter);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 根据主键删除数据
|
||||
/// </summary>
|
||||
/// <param name="id">主键ID</param>
|
||||
/// <returns></returns>
|
||||
[HttpGet, Route("Delete")]
|
||||
public JsonActionResult<bool> Delete(string id)
|
||||
{
|
||||
return WitRealDelete(id);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 更新或新增数据
|
||||
/// </summary>
|
||||
/// <param name="entity">对象实体</param>
|
||||
/// <returns></returns>
|
||||
[HttpPost, Route("Update")]
|
||||
public JsonActionResult<bool> Update([FromBody]T_NW_ROLE_DATA_PERM entity)
|
||||
{
|
||||
return WitUpdate(entity);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 批量更新
|
||||
/// </summary>
|
||||
/// <param name="entity">对象实体</param>
|
||||
/// <returns></returns>
|
||||
[HttpPost, Route("BatchUpdate")]
|
||||
public JsonActionResult<bool> BatchUpdate([FromBody] BatchUpdateModel<T_NW_ROLE_DATA_PERM> entity)
|
||||
{
|
||||
return WitBantchUpdate(entity?.Data);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 批量删除数据
|
||||
/// </summary>
|
||||
/// <param name="ids">id字符串(id用逗号分隔)</param>
|
||||
/// <returns></returns>
|
||||
[HttpGet, Route("BatchDelete")]
|
||||
public JsonActionResult<bool> BatchDelete(string ids)
|
||||
{
|
||||
return WitRealBatchDelete(ids);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 获得单条实体数据
|
||||
/// </summary>
|
||||
/// <param name="filter">过滤实体</param>
|
||||
/// <returns></returns>
|
||||
[HttpPost, Route("Get")]
|
||||
public JsonActionResult<T_NW_ROLE_DATA_PERM> Get([FromBody] KeywordFilter filter)
|
||||
{
|
||||
return WitEntity(null, filter);
|
||||
}
|
||||
|
||||
}
|
||||
#endregion
|
||||
#region RoleMenu-子企业权限表
|
||||
/// <summary>
|
||||
/// 子企业权限表
|
||||
/// </summary>
|
||||
[Route("api/NW/RoleMenu")]
|
||||
public partial class RoleMenuController : AuthorizeApiController<T_NW_ROLE_MENU>
|
||||
{
|
||||
/// <summary>
|
||||
/// 查询所有数据
|
||||
/// </summary>
|
||||
/// <param name="filter">过滤实体</param>
|
||||
/// <returns></returns>
|
||||
[HttpPost, Route("Entities")]
|
||||
public JsonActionResult<IEnumerable<T_NW_ROLE_MENU>> Entities([FromBody]KeywordFilter filter)
|
||||
{
|
||||
return WitEntities(null, filter);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 排序查询所有数据
|
||||
/// </summary>
|
||||
/// <param name="filter">过滤实体</param>
|
||||
/// <returns></returns>
|
||||
|
||||
[HttpPost, Route("OrderEntities")]
|
||||
public JsonActionResult<IEnumerable<T_NW_ROLE_MENU>> OrderEntities([FromBody]KeywordFilter filter)
|
||||
{
|
||||
return WitOrderEntities(null, filter);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 分页查询数据
|
||||
/// </summary>
|
||||
/// <param name="pageFilter">分页过滤实体</param>
|
||||
/// <returns></returns>
|
||||
[HttpPost, Route("Paged")]
|
||||
public PagedActionResult<T_NW_ROLE_MENU> Paged([FromBody]KeywordPageFilter pageFilter)
|
||||
{
|
||||
return WitPaged(null, pageFilter);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 排序分页查询数据
|
||||
/// </summary>
|
||||
/// <param name="pageFilter">分页过滤实体</param>
|
||||
/// <returns></returns>
|
||||
[HttpPost, Route("OrderPaged")]
|
||||
public PagedActionResult<T_NW_ROLE_MENU> OrderPaged([FromBody]KeywordPageFilter pageFilter)
|
||||
{
|
||||
return WitOrderPaged(null, pageFilter);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 根据主键删除数据
|
||||
/// </summary>
|
||||
/// <param name="id">主键ID</param>
|
||||
/// <returns></returns>
|
||||
[HttpGet, Route("Delete")]
|
||||
public JsonActionResult<bool> Delete(string id)
|
||||
{
|
||||
return WitRealDelete(id);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 更新或新增数据
|
||||
/// </summary>
|
||||
/// <param name="entity">对象实体</param>
|
||||
/// <returns></returns>
|
||||
[HttpPost, Route("Update")]
|
||||
public JsonActionResult<bool> Update([FromBody]T_NW_ROLE_MENU entity)
|
||||
{
|
||||
return WitUpdate(entity);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 批量更新
|
||||
/// </summary>
|
||||
/// <param name="entity">对象实体</param>
|
||||
/// <returns></returns>
|
||||
[HttpPost, Route("BatchUpdate")]
|
||||
public JsonActionResult<bool> BatchUpdate([FromBody] BatchUpdateModel<T_NW_ROLE_MENU> entity)
|
||||
{
|
||||
return WitBantchUpdate(entity?.Data);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 批量删除数据
|
||||
/// </summary>
|
||||
/// <param name="ids">id字符串(id用逗号分隔)</param>
|
||||
/// <returns></returns>
|
||||
[HttpGet, Route("BatchDelete")]
|
||||
public JsonActionResult<bool> BatchDelete(string ids)
|
||||
{
|
||||
return WitRealBatchDelete(ids);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 获得单条实体数据
|
||||
/// </summary>
|
||||
/// <param name="filter">过滤实体</param>
|
||||
/// <returns></returns>
|
||||
[HttpPost, Route("Get")]
|
||||
public JsonActionResult<T_NW_ROLE_MENU> Get([FromBody] KeywordFilter filter)
|
||||
{
|
||||
return WitEntity(null, filter);
|
||||
}
|
||||
|
||||
}
|
||||
#endregion
|
||||
}
|
||||
|
||||
#region Enterprise-子企业表
|
||||
/// <summary>
|
||||
/// 子企业表
|
||||
/// </summary>
|
||||
[Route("api/NW/Enterprise")]
|
||||
public partial class EnterpriseController : AuthorizeTreeApiController<T_NW_ENTERPRISE>
|
||||
{
|
||||
/// <summary>
|
||||
/// 查询所有数据
|
||||
/// </summary>
|
||||
/// <param name="filter">过滤实体</param>
|
||||
/// <returns></returns>
|
||||
[HttpPost, Route("Entities")]
|
||||
public JsonActionResult<IEnumerable<T_NW_ENTERPRISE>> Entities([FromBody]KeywordFilter filter)
|
||||
{
|
||||
return WitEntities(null, filter);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 排序查询所有数据
|
||||
/// </summary>
|
||||
/// <param name="filter">过滤实体</param>
|
||||
/// <returns></returns>
|
||||
|
||||
[HttpPost, Route("OrderEntities")]
|
||||
public JsonActionResult<IEnumerable<T_NW_ENTERPRISE>> OrderEntities([FromBody]KeywordFilter filter)
|
||||
{
|
||||
return WitOrderEntities(null, filter);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 分页查询数据
|
||||
/// </summary>
|
||||
/// <param name="pageFilter">分页过滤实体</param>
|
||||
/// <returns></returns>
|
||||
[HttpPost, Route("Paged")]
|
||||
public PagedActionResult<T_NW_ENTERPRISE> Paged([FromBody]KeywordPageFilter pageFilter)
|
||||
{
|
||||
return WitPaged(null, pageFilter);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 排序分页查询数据
|
||||
/// </summary>
|
||||
/// <param name="pageFilter">分页过滤实体</param>
|
||||
/// <returns></returns>
|
||||
[HttpPost, Route("OrderPaged")]
|
||||
public PagedActionResult<T_NW_ENTERPRISE> OrderPaged([FromBody]KeywordPageFilter pageFilter)
|
||||
{
|
||||
return WitOrderPaged(null, pageFilter);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 根据主键删除数据
|
||||
/// </summary>
|
||||
/// <param name="id">主键ID</param>
|
||||
/// <returns></returns>
|
||||
[HttpGet, Route("Delete")]
|
||||
public JsonActionResult<bool> Delete(string id)
|
||||
{
|
||||
return WitRealDelete(id);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 更新或新增数据
|
||||
/// </summary>
|
||||
/// <param name="entity">对象实体</param>
|
||||
/// <returns></returns>
|
||||
[HttpPost, Route("Update")]
|
||||
public JsonActionResult<bool> Update([FromBody]T_NW_ENTERPRISE entity)
|
||||
{
|
||||
return WitUpdate(entity);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 批量更新
|
||||
/// </summary>
|
||||
/// <param name="entity">对象实体</param>
|
||||
/// <returns></returns>
|
||||
[HttpPost, Route("BatchUpdate")]
|
||||
public JsonActionResult<bool> BatchUpdate([FromBody] BatchUpdateModel<T_NW_ENTERPRISE> entity)
|
||||
{
|
||||
return WitBantchUpdate(entity?.Data);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 批量删除数据
|
||||
/// </summary>
|
||||
/// <param name="ids">id字符串(id用逗号分隔)</param>
|
||||
/// <returns></returns>
|
||||
[HttpGet, Route("BatchDelete")]
|
||||
public JsonActionResult<bool> BatchDelete(string ids)
|
||||
{
|
||||
return WitRealBatchDelete(ids);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 获得单条实体数据
|
||||
/// </summary>
|
||||
/// <param name="filter">过滤实体</param>
|
||||
/// <returns></returns>
|
||||
[HttpPost, Route("Get")]
|
||||
public JsonActionResult<T_NW_ENTERPRISE> Get([FromBody] KeywordFilter filter)
|
||||
{
|
||||
return WitEntity(null, filter);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 获得树形实体数据
|
||||
/// </summary>
|
||||
/// <param name="filter"></param>
|
||||
/// <returns></returns>
|
||||
[HttpPost, Route("TreeData")]
|
||||
public JsonActionResult<IEnumerable<TreeNode<T_NW_ENTERPRISE>>> TreeData([FromBody] KeywordFilter filter)
|
||||
{
|
||||
return WitTreeOrderEntities(null, filter);
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
#endregion
|
||||
|
||||
#region RoleDataPerm-子企业数据权限表
|
||||
/// <summary>
|
||||
/// 子企业数据权限表
|
||||
/// </summary>
|
||||
[Route("api/NW/RoleDataPerm")]
|
||||
public partial class RoleDataPermController : AuthorizeApiController<T_NW_ROLE_DATA_PERM>
|
||||
{
|
||||
/// <summary>
|
||||
/// 查询所有数据
|
||||
/// </summary>
|
||||
/// <param name="filter">过滤实体</param>
|
||||
/// <returns></returns>
|
||||
[HttpPost, Route("Entities")]
|
||||
public JsonActionResult<IEnumerable<T_NW_ROLE_DATA_PERM>> Entities([FromBody]KeywordFilter filter)
|
||||
{
|
||||
return WitEntities(null, filter);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 排序查询所有数据
|
||||
/// </summary>
|
||||
/// <param name="filter">过滤实体</param>
|
||||
/// <returns></returns>
|
||||
|
||||
[HttpPost, Route("OrderEntities")]
|
||||
public JsonActionResult<IEnumerable<T_NW_ROLE_DATA_PERM>> OrderEntities([FromBody]KeywordFilter filter)
|
||||
{
|
||||
return WitOrderEntities(null, filter);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 分页查询数据
|
||||
/// </summary>
|
||||
/// <param name="pageFilter">分页过滤实体</param>
|
||||
/// <returns></returns>
|
||||
[HttpPost, Route("Paged")]
|
||||
public PagedActionResult<T_NW_ROLE_DATA_PERM> Paged([FromBody]KeywordPageFilter pageFilter)
|
||||
{
|
||||
return WitPaged(null, pageFilter);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 排序分页查询数据
|
||||
/// </summary>
|
||||
/// <param name="pageFilter">分页过滤实体</param>
|
||||
/// <returns></returns>
|
||||
[HttpPost, Route("OrderPaged")]
|
||||
public PagedActionResult<T_NW_ROLE_DATA_PERM> OrderPaged([FromBody]KeywordPageFilter pageFilter)
|
||||
{
|
||||
return WitOrderPaged(null, pageFilter);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 根据主键删除数据
|
||||
/// </summary>
|
||||
/// <param name="id">主键ID</param>
|
||||
/// <returns></returns>
|
||||
[HttpGet, Route("Delete")]
|
||||
public JsonActionResult<bool> Delete(string id)
|
||||
{
|
||||
return WitRealDelete(id);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 更新或新增数据
|
||||
/// </summary>
|
||||
/// <param name="entity">对象实体</param>
|
||||
/// <returns></returns>
|
||||
[HttpPost, Route("Update")]
|
||||
public JsonActionResult<bool> Update([FromBody]T_NW_ROLE_DATA_PERM entity)
|
||||
{
|
||||
return WitUpdate(entity);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 批量更新
|
||||
/// </summary>
|
||||
/// <param name="entity">对象实体</param>
|
||||
/// <returns></returns>
|
||||
[HttpPost, Route("BatchUpdate")]
|
||||
public JsonActionResult<bool> BatchUpdate([FromBody] BatchUpdateModel<T_NW_ROLE_DATA_PERM> entity)
|
||||
{
|
||||
return WitBantchUpdate(entity?.Data);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 批量删除数据
|
||||
/// </summary>
|
||||
/// <param name="ids">id字符串(id用逗号分隔)</param>
|
||||
/// <returns></returns>
|
||||
[HttpGet, Route("BatchDelete")]
|
||||
public JsonActionResult<bool> BatchDelete(string ids)
|
||||
{
|
||||
return WitRealBatchDelete(ids);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 获得单条实体数据
|
||||
/// </summary>
|
||||
/// <param name="filter">过滤实体</param>
|
||||
/// <returns></returns>
|
||||
[HttpPost, Route("Get")]
|
||||
public JsonActionResult<T_NW_ROLE_DATA_PERM> Get([FromBody] KeywordFilter filter)
|
||||
{
|
||||
return WitEntity(null, filter);
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
#endregion
|
||||
|
||||
#region RoleMenu-子企业权限表
|
||||
/// <summary>
|
||||
/// 子企业权限表
|
||||
/// </summary>
|
||||
[Route("api/NW/RoleMenu")]
|
||||
public partial class RoleMenuController : AuthorizeApiController<T_NW_ROLE_MENU>
|
||||
{
|
||||
/// <summary>
|
||||
/// 查询所有数据
|
||||
/// </summary>
|
||||
/// <param name="filter">过滤实体</param>
|
||||
/// <returns></returns>
|
||||
[HttpPost, Route("Entities")]
|
||||
public JsonActionResult<IEnumerable<T_NW_ROLE_MENU>> Entities([FromBody]KeywordFilter filter)
|
||||
{
|
||||
return WitEntities(null, filter);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 排序查询所有数据
|
||||
/// </summary>
|
||||
/// <param name="filter">过滤实体</param>
|
||||
/// <returns></returns>
|
||||
|
||||
[HttpPost, Route("OrderEntities")]
|
||||
public JsonActionResult<IEnumerable<T_NW_ROLE_MENU>> OrderEntities([FromBody]KeywordFilter filter)
|
||||
{
|
||||
return WitOrderEntities(null, filter);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 分页查询数据
|
||||
/// </summary>
|
||||
/// <param name="pageFilter">分页过滤实体</param>
|
||||
/// <returns></returns>
|
||||
[HttpPost, Route("Paged")]
|
||||
public PagedActionResult<T_NW_ROLE_MENU> Paged([FromBody]KeywordPageFilter pageFilter)
|
||||
{
|
||||
return WitPaged(null, pageFilter);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 排序分页查询数据
|
||||
/// </summary>
|
||||
/// <param name="pageFilter">分页过滤实体</param>
|
||||
/// <returns></returns>
|
||||
[HttpPost, Route("OrderPaged")]
|
||||
public PagedActionResult<T_NW_ROLE_MENU> OrderPaged([FromBody]KeywordPageFilter pageFilter)
|
||||
{
|
||||
return WitOrderPaged(null, pageFilter);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 根据主键删除数据
|
||||
/// </summary>
|
||||
/// <param name="id">主键ID</param>
|
||||
/// <returns></returns>
|
||||
[HttpGet, Route("Delete")]
|
||||
public JsonActionResult<bool> Delete(string id)
|
||||
{
|
||||
return WitRealDelete(id);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 更新或新增数据
|
||||
/// </summary>
|
||||
/// <param name="entity">对象实体</param>
|
||||
/// <returns></returns>
|
||||
[HttpPost, Route("Update")]
|
||||
public JsonActionResult<bool> Update([FromBody]T_NW_ROLE_MENU entity)
|
||||
{
|
||||
return WitUpdate(entity);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 批量更新
|
||||
/// </summary>
|
||||
/// <param name="entity">对象实体</param>
|
||||
/// <returns></returns>
|
||||
[HttpPost, Route("BatchUpdate")]
|
||||
public JsonActionResult<bool> BatchUpdate([FromBody] BatchUpdateModel<T_NW_ROLE_MENU> entity)
|
||||
{
|
||||
return WitBantchUpdate(entity?.Data);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 批量删除数据
|
||||
/// </summary>
|
||||
/// <param name="ids">id字符串(id用逗号分隔)</param>
|
||||
/// <returns></returns>
|
||||
[HttpGet, Route("BatchDelete")]
|
||||
public JsonActionResult<bool> BatchDelete(string ids)
|
||||
{
|
||||
return WitRealBatchDelete(ids);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 获得单条实体数据
|
||||
/// </summary>
|
||||
/// <param name="filter">过滤实体</param>
|
||||
/// <returns></returns>
|
||||
[HttpPost, Route("Get")]
|
||||
public JsonActionResult<T_NW_ROLE_MENU> Get([FromBody] KeywordFilter filter)
|
||||
{
|
||||
return WitEntity(null, filter);
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
#endregion
|
||||
|
||||
}
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
@ -1,7 +1,13 @@
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
//------------------------------------------------------------------------------
|
||||
// T4模板文件:基础接口类
|
||||
// 此代码由T4模板自动生成
|
||||
@ -15,4 +21,5 @@ using APT.Infrastructure.Api;
|
||||
using APT.BaseData.Domain.ApiModel.PF;
|
||||
namespace APT.PP.WebApi.Controllers.Api
|
||||
{
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@ -270,14 +270,13 @@ namespace APT.SK.WebApi.Controllers
|
||||
var detailStr = new List<string>();
|
||||
if (item.Nav_Details != null && item.Nav_Details.Any())
|
||||
{
|
||||
var i = 1;
|
||||
foreach (var item2 in item.Nav_Details.OrderBy(t => t.NUM))
|
||||
{
|
||||
if (item2 != null && !string.IsNullOrEmpty(item2.MEASURES_NAME))
|
||||
{
|
||||
var temp = item2.NUM + "、" + item2.MEASURES_NAME + Environment.NewLine;
|
||||
item.MINE_NAME = item.MINE_NAME + temp;
|
||||
i++;
|
||||
{
|
||||
var temp = item2.NUM + "、" + item2.MEASURES_NAME + Environment.NewLine;
|
||||
item.MINE_NAME = item.MINE_NAME + temp;
|
||||
item.MEASURE = item.MEASURE + temp;
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -316,9 +315,10 @@ namespace APT.SK.WebApi.Controllers
|
||||
//var i = 1;
|
||||
if (item2 != null && !string.IsNullOrEmpty(item2.MEASURES_NAME))
|
||||
{
|
||||
detailStr.Add(item2.MEASURES_NAME);
|
||||
detailStr.Add(item2.MEASURES_NAME);
|
||||
var temp = item2.NUM + "、" + item2.MEASURES_NAME + Environment.NewLine;
|
||||
item.MINE_NAME = item.MINE_NAME + temp;
|
||||
item.MINE_NAME = item.MINE_NAME + temp;
|
||||
item.MEASURE = item.MEASURE + temp;
|
||||
//i++;
|
||||
}
|
||||
if (item2 != null && item2.Nav_DetailContents != null && item2.Nav_DetailContents.Any())
|
||||
@ -368,20 +368,20 @@ namespace APT.SK.WebApi.Controllers
|
||||
}
|
||||
}
|
||||
}
|
||||
if (detailStr.Any())
|
||||
{
|
||||
detailStr = detailStr.Distinct().ToList();
|
||||
var i = 1;
|
||||
foreach (var item2 in detailStr)
|
||||
{
|
||||
if (!string.IsNullOrEmpty(item2))
|
||||
{
|
||||
var temp = i + "、" + item2 + "\r\n";
|
||||
item.MEASURE = item.MEASURE + temp;
|
||||
i++;
|
||||
}
|
||||
}
|
||||
}
|
||||
//if (detailStr.Any())
|
||||
//{
|
||||
// detailStr = detailStr.Distinct().ToList();
|
||||
// var i = 1;
|
||||
// foreach (var item2 in detailStr)
|
||||
// {
|
||||
// if (!string.IsNullOrEmpty(item2))
|
||||
// {
|
||||
// var temp = i + "、" + item2 + "\r\n";
|
||||
// item.MEASURE = item.MEASURE + temp;
|
||||
// i++;
|
||||
// }
|
||||
// }
|
||||
//}
|
||||
if (contentStr.Any())
|
||||
{
|
||||
contentStr = contentStr.Distinct().ToList();
|
||||
|
||||
@ -60,15 +60,12 @@ namespace APT.SK.WebApi.Controllers.Api
|
||||
public PagedActionResult<T_SK_CHECK_TYPE> OrderPagedNew([FromBody] KeywordPageFilter pageFilter)
|
||||
{
|
||||
var result = new PagedActionResult<T_SK_CHECK_TYPE>();
|
||||
if (!string.IsNullOrEmpty(pageFilter.Keyword))
|
||||
{
|
||||
if (pageFilter.Keyword != "0")
|
||||
{
|
||||
FilterRule order2 = new FilterRule();
|
||||
order2.Field = "MineType";
|
||||
order2.Value = (SKProductionUnit)(int.Parse(pageFilter.Keyword));
|
||||
pageFilter.FilterGroup.Rules.Add(order2);
|
||||
}
|
||||
if (!string.IsNullOrEmpty(pageFilter.Keyword.ToString()))
|
||||
{
|
||||
FilterRule order2 = new FilterRule();
|
||||
order2.Field = "PRODUCTION_UNIT_ID";
|
||||
order2.Value = Guid.Parse(pageFilter.Keyword.ToString());
|
||||
pageFilter.FilterGroup.Rules.Add(order2);
|
||||
}
|
||||
result = GetOrderPageEntities<T_SK_CHECK_TYPE>(null, pageFilter);
|
||||
return result;
|
||||
|
||||
@ -647,7 +647,7 @@ namespace APT.SK.WebApi.Controllers.Api
|
||||
var detailStr = new List<string>(); var detailNum = new List<int?>();
|
||||
if (item.Nav_Details != null && item.Nav_Details.Any())
|
||||
{
|
||||
var i = 1;
|
||||
//var i = 1;
|
||||
foreach (var item2 in item.Nav_Details.OrderBy(t => t.NUM))
|
||||
{
|
||||
if (item2 != null && !string.IsNullOrEmpty(item2.MEASURES_NAME))
|
||||
@ -655,8 +655,9 @@ namespace APT.SK.WebApi.Controllers.Api
|
||||
detailStr.Add(item2.MEASURES_NAME);
|
||||
detailNum.Add(item2.NUM);
|
||||
var temp = item2.NUM + "、" + item2.MEASURES_NAME + Environment.NewLine;
|
||||
item.MINE_NAME = item.MINE_NAME + temp;
|
||||
i++;
|
||||
item.MINE_NAME = item.MINE_NAME + temp;
|
||||
item.MEASURE = item.MEASURE + temp;
|
||||
//i++;
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -794,7 +795,10 @@ namespace APT.SK.WebApi.Controllers.Api
|
||||
{
|
||||
if (item2 != null && !string.IsNullOrEmpty(item2.MEASURES_NAME))
|
||||
{
|
||||
detailStr.Add(item2.MEASURES_NAME);
|
||||
detailStr.Add(item2.MEASURES_NAME);
|
||||
var temp = item2.NUM + "、" + item2.MEASURES_NAME + Environment.NewLine;
|
||||
item.MINE_NAME = item.MINE_NAME + temp;
|
||||
item.MEASURE = item.MEASURE + temp;
|
||||
}
|
||||
if (item2 != null && item2.Nav_DetailContents != null && item2.Nav_DetailContents.Any())
|
||||
{
|
||||
@ -868,20 +872,20 @@ namespace APT.SK.WebApi.Controllers.Api
|
||||
}
|
||||
}
|
||||
}
|
||||
if (detailStr.Any())
|
||||
{
|
||||
detailStr = detailStr.Distinct().ToList();
|
||||
var i = 1;
|
||||
foreach (var item2 in detailStr)
|
||||
{
|
||||
if (!string.IsNullOrEmpty(item2))
|
||||
{
|
||||
var temp = i + "、" + item2 + "\r\n";
|
||||
item.MEASURE = item.MEASURE + temp;
|
||||
i++;
|
||||
}
|
||||
}
|
||||
}
|
||||
//if (detailStr.Any())
|
||||
//{
|
||||
// detailStr = detailStr.Distinct().ToList();
|
||||
// var i = 1;
|
||||
// foreach (var item2 in detailStr)
|
||||
// {
|
||||
// if (!string.IsNullOrEmpty(item2))
|
||||
// {
|
||||
// var temp = i + "、" + item2 + "\r\n";
|
||||
// item.MEASURE = item.MEASURE + temp;
|
||||
// i++;
|
||||
// }
|
||||
// }
|
||||
//}
|
||||
if (contentStr.Any())
|
||||
{
|
||||
contentStr = contentStr.Distinct().ToList();
|
||||
|
||||
@ -365,6 +365,44 @@ namespace APT.SK.WebApi.Controllers.Api
|
||||
return true;
|
||||
//return ApproveCallBackService.CallReject("HM/HMLicenseAnalysis/RejectUpdate", id);
|
||||
});
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 整改责任人确认
|
||||
/// </summary>
|
||||
/// <param name="entity"></param>
|
||||
/// <returns></returns>
|
||||
[HttpPost, Route("IdentityUpdate")]
|
||||
public JsonActionResult<bool> IdentityUpdate([FromBody] T_SK_HIDDEN_DANGER_CONFIRM entity)
|
||||
{
|
||||
return SafeExecute(() =>
|
||||
{
|
||||
T_FM_NOTIFICATION_TASK task = null;
|
||||
var notice = this.GetEntity<T_SK_HIDDEN_DANGER_CONFIRM>(entity.ID);
|
||||
notice.STATUS = PFStandardStatus.Archived;
|
||||
var userId = APT.Infrastructure.Api.AppContext.CurrentSession.UserID;
|
||||
if (entity.TaskID != Guid.Empty)
|
||||
{
|
||||
var currTask = GetEntity<T_FM_NOTIFICATION_TASK>(t => t.ID == entity.TaskID);
|
||||
if (currTask != null)
|
||||
{
|
||||
userId = currTask.USER_ID;
|
||||
}
|
||||
}
|
||||
if (entity.TaskID != Guid.Empty)
|
||||
{
|
||||
task = NotificationTaskService.GetTaskFinishModel(entity.TaskID);
|
||||
task.SOURCE_FORMCODE = "SK018_SHOWPRINT";
|
||||
}
|
||||
UnifiedCommit(() =>
|
||||
{
|
||||
if (notice != null)
|
||||
this.UpdateEntityNoCommit(notice);
|
||||
if (task != null)
|
||||
this.UpdateEntityNoCommit(task);
|
||||
});
|
||||
return true;
|
||||
});
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@ -107,7 +107,7 @@ namespace APT.SK.WebApi.Controllers.Api
|
||||
}
|
||||
}
|
||||
//发消息
|
||||
var titleName = "隐患确认单(" + depart?.NAME + DateTime.Now.ToShortDateString().Replace("/", "") + ")";
|
||||
var titleName = "隐患确认单(" + depart?.NAME + DateTime.Now.Month.PadLeft(2,'0') + DateTime.Now.Day.PadLeft(2, '0');
|
||||
if (orgId.ToString() == "d9871ba8-0eec-9e4a-bb87-7d5a540d8913")
|
||||
{
|
||||
titleName = "手动隐患上报完善";
|
||||
|
||||
@ -53,9 +53,16 @@ namespace APT.SK.WebApi.Controllers.Api
|
||||
var level = param == "Major" ? "重大" : "一般";
|
||||
if (hiddenLevel == SKHiddenLevel.General)
|
||||
{
|
||||
var departmentType = this.GetEntity<T_FM_DEPARTMENT>(t => t.ID == entity.APPLY_DEPARTMENT_ID && t.ENABLE_STATUS == 0)?.DEPARTMENT_TYPE;
|
||||
//param = Enum.GetName(typeof(SKDepartmentTypeEnum), departmentType);
|
||||
param = ((SKDepartmentTypeEnum)departmentType).GetDescription();
|
||||
var departmentType = this.GetEntity<T_FM_DEPARTMENT>(t => t.ID == entity.APPLY_DEPARTMENT_ID && t.ENABLE_STATUS == 0);
|
||||
//param = Enum.GetName(typeof(FMDepartmentType), departmentType);
|
||||
if (departmentType != null)
|
||||
{
|
||||
level = ((SKDepartmentTypeEnum)departmentType.DEPARTMENT_TYPE).GetDescription();
|
||||
if (departmentType.DEPARTMENT_STATUS != 1)
|
||||
{
|
||||
level = "公司级";
|
||||
}
|
||||
}
|
||||
}
|
||||
entity.STATUS = PFStandardStatus.Approving;
|
||||
//取审批流水码
|
||||
@ -65,7 +72,7 @@ namespace APT.SK.WebApi.Controllers.Api
|
||||
sysFilter.OrgId = entity.ORG_ID;
|
||||
var codes = CodeRuleService.NewGenSerial(sysFilter);
|
||||
var serialCode = codes.Split(new char[] { ',' });
|
||||
MFlowPermitService.InsertApprove(serialCode[0], "SK024", param, entity.ID, "SK024_SHOWPRINT", entity.TaskID, true, () =>
|
||||
MFlowPermitService.InsertApprove(serialCode[0], "SK024", level, entity.ID, "SK024_SHOWPRINT", entity.TaskID, true, () =>
|
||||
{
|
||||
if (entity != null)
|
||||
UpdateEntityNoCommit(entity);
|
||||
|
||||
@ -134,20 +134,50 @@ namespace APT.SK.WebApi.Controllers
|
||||
if (entity.PUBLISH != null && entity.PUBLISH.Equals("SaveAndNotify"))
|
||||
{
|
||||
if (entity.STATUS == PFStandardStatus.Draft || entity.STATUS == PFStandardStatus.Rejected)
|
||||
{
|
||||
if (entity.ACCEPT_USER_ID != null)
|
||||
{
|
||||
entity.STATUS = PFStandardStatus.Sign;
|
||||
entity.ACCEPT_OPINION = null;
|
||||
entity.ACCEPT_RESULTE = SKAcceptResultEnum.Yes;
|
||||
entity.ACCEPT_DATE = DateTime.Now;
|
||||
var departName = this.GetEntity<T_FM_DEPARTMENT>(t => t.ID == entity.APPLY_DEPARTMENT_ID && t.ENABLE_STATUS == 0)?.NAME;
|
||||
var UserNames = new List<string>();
|
||||
var user = this.GetEntity<T_FM_USER>(t => t.ENABLE_STATUS == (int)FMEnableStatusEnum.启用 && t.ID == entity.ACCEPT_USER_ID);
|
||||
//发消息
|
||||
notice = NotificationTaskService.InsertUserNoticeTaskModel("隐患整改记录(" + departName + DateTime.Now.ToShortDateString().Replace("/", "") + ")-验收", entity.ID, entity.ORG_ID, (Guid)entity.ACCEPT_USER_ID, user?.NAME, DateTime.Now,
|
||||
DateTime.Now.AddHours(24), (int)FMNoticeTypeEnum.消息, "SK022");
|
||||
{
|
||||
//整改责任人确认
|
||||
if (entity.RECITIFY_USER_ID != null)
|
||||
{
|
||||
entity.STATUS = PFStandardStatus.Reading;
|
||||
entity.COMPLETE_DATE = DateTime.Now;
|
||||
//var departName = this.GetEntity<T_FM_DEPARTMENT>(t => t.ID == entity.APPLY_DEPARTMENT_ID && t.ENABLE_STATUS == 0)?.NAME;
|
||||
var UserNames = new List<string>();
|
||||
var user = this.GetEntity<T_FM_USER>(t => t.ENABLE_STATUS == (int)FMEnableStatusEnum.启用 && t.ID == entity.RECITIFY_USER_ID);
|
||||
//发消息
|
||||
notice = NotificationTaskService.InsertUserNoticeTaskModel("隐患整改记录" + DateTime.Now.Month.PadLeft(2, '0') + DateTime.Now.Day.PadLeft(2, '0') + "-整改责任人确认", entity.ID, entity.ORG_ID, (Guid)entity.RECITIFY_USER_ID, user?.NAME, DateTime.Now,
|
||||
DateTime.Now.AddHours(24), (int)FMNoticeTypeEnum.消息, "SK022");
|
||||
}
|
||||
}
|
||||
else if (entity.STATUS == PFStandardStatus.Reading)
|
||||
{
|
||||
if (entity.ACCEPT_RESULTE == MS.Domain.Enums.SK.SKAcceptResultEnum.No)
|
||||
{
|
||||
if (entity.IMPLEMENT_USER_ID != null)
|
||||
{
|
||||
//驳回给整改落实人
|
||||
entity.STATUS = PFStandardStatus.Rejected;
|
||||
//var departName = this.GetEntity<T_FM_DEPARTMENT>(t => t.ID == entity.APPLY_DEPARTMENT_ID && t.ENABLE_STATUS == 0)?.NAME;
|
||||
var UserNames = new List<string>();
|
||||
var user = this.GetEntity<T_FM_USER>(t => t.ENABLE_STATUS == (int)FMEnableStatusEnum.启用 && t.ID == entity.IMPLEMENT_USER_ID);
|
||||
//发消息
|
||||
notice = NotificationTaskService.InsertUserNoticeTaskModel("隐患整改记录(" + DateTime.Now.ToShortDateString().Replace("/", "") + ")-驳回", entity.ID, entity.ORG_ID, (Guid)entity.IMPLEMENT_USER_ID, user?.NAME, DateTime.Now,
|
||||
DateTime.Now.AddHours(24), (int)FMNoticeTypeEnum.消息, "SK022");
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
//验收人确认
|
||||
if (entity.ACCEPT_USER_ID != null)
|
||||
{
|
||||
entity.STATUS = PFStandardStatus.Sign;
|
||||
var departName = this.GetEntity<T_FM_DEPARTMENT>(t => t.ID == entity.APPLY_DEPARTMENT_ID && t.ENABLE_STATUS == 0)?.NAME;
|
||||
var UserNames = new List<string>();
|
||||
var user = this.GetEntity<T_FM_USER>(t => t.ENABLE_STATUS == (int)FMEnableStatusEnum.启用 && t.ID == entity.ACCEPT_USER_ID);
|
||||
//发消息
|
||||
notice = NotificationTaskService.InsertUserNoticeTaskModel("隐患整改记录(" + departName + DateTime.Now.ToShortDateString().Replace("/", "") + ")-验收", entity.ID, entity.ORG_ID, (Guid)entity.ACCEPT_USER_ID, user?.NAME, DateTime.Now,
|
||||
DateTime.Now.AddHours(24), (int)FMNoticeTypeEnum.消息, "SK022");
|
||||
}
|
||||
}
|
||||
}
|
||||
else if (entity.STATUS == PFStandardStatus.Sign)
|
||||
{
|
||||
@ -195,14 +225,14 @@ namespace APT.SK.WebApi.Controllers
|
||||
//param = Enum.GetName(typeof(SKDepartmentTypeEnum), departmentType);
|
||||
if (departmentType != null)
|
||||
{
|
||||
param = ((SKDepartmentTypeEnum)departmentType.DEPARTMENT_TYPE).GetDescription();
|
||||
level = ((SKDepartmentTypeEnum)departmentType.DEPARTMENT_TYPE).GetDescription();
|
||||
if (departmentType.DEPARTMENT_STATUS != 1)
|
||||
{
|
||||
param = "公司级";
|
||||
level = "公司级";
|
||||
}
|
||||
}
|
||||
}
|
||||
MFlowPermitService.InsertApprove(serialCode[0], "SK022", param, entity.ID, "SK022_SHOWPRINT", entity.TaskID, true, () =>
|
||||
MFlowPermitService.InsertApprove(serialCode[0], "SK022", level, entity.ID, "SK022_SHOWPRINT", entity.TaskID, true, () =>
|
||||
{
|
||||
if (entity != null)
|
||||
UpdateEntityNoCommit(entity);
|
||||
|
||||
@ -67,9 +67,11 @@ namespace APT.SK.WebApi.Controllers.Api
|
||||
List<Guid> userIds = new List<Guid>();
|
||||
List<Guid> deleteFileIds = new List<Guid>();
|
||||
List<Guid> deleteBasicIds = new List<Guid>();
|
||||
List<Guid> deleteDetailIds = new List<Guid>();
|
||||
List<Guid> deleteDetailIds = new List<Guid>();
|
||||
List<Guid> deleteReasonIds = new List<Guid>();
|
||||
List<T_SK_HIDDEN_DANGER_REPORT_DETAIL_FILE> fileList = new List<T_SK_HIDDEN_DANGER_REPORT_DETAIL_FILE>();
|
||||
List<T_SK_HIDDEN_DANGER_REPORT_DETAIL_BASIC> basicList = new List<T_SK_HIDDEN_DANGER_REPORT_DETAIL_BASIC>();
|
||||
List<T_SK_HIDDEN_DANGER_REPORT_DETAIL_BASIC> basicList = new List<T_SK_HIDDEN_DANGER_REPORT_DETAIL_BASIC>();
|
||||
List<T_SK_HIDDEN_DANGER_REPORT_DETAIL_REASON> reasonList = new List<T_SK_HIDDEN_DANGER_REPORT_DETAIL_REASON>();
|
||||
SKHiddenLevel? hiddenLevel = SKHiddenLevel.General;
|
||||
if (details != null && details.Any())
|
||||
{
|
||||
@ -87,6 +89,11 @@ namespace APT.SK.WebApi.Controllers.Api
|
||||
{
|
||||
var tempIds = t.Nav_ReportDetailBasics.Select(m => m.ID).ToList();
|
||||
deleteBasicIds.AddRange(tempIds);
|
||||
}
|
||||
if (t.Nav_ReportDetailReasons != null && t.Nav_ReportDetailReasons.Any())
|
||||
{
|
||||
var tempIds = t.Nav_ReportDetailReasons.Select(m => m.ID).ToList();
|
||||
deleteReasonIds.AddRange(tempIds);
|
||||
}
|
||||
deleteDetailIds.Add(t.ID);
|
||||
});
|
||||
@ -123,6 +130,17 @@ namespace APT.SK.WebApi.Controllers.Api
|
||||
basic.LAW_ID = item2.LAW_ID;
|
||||
basicList.Add(basic);
|
||||
}
|
||||
}
|
||||
if (item.Nav_ReportDetailReasons != null && item.Nav_ReportDetailReasons.Any())
|
||||
{
|
||||
foreach (var item2 in item.Nav_ReportDetailReasons)
|
||||
{
|
||||
T_SK_HIDDEN_DANGER_REPORT_DETAIL_REASON basic = new T_SK_HIDDEN_DANGER_REPORT_DETAIL_REASON();
|
||||
basic.ORG_ID = entity.ORG_ID;
|
||||
basic.HIDDEN_DANGER_REPORT_DETAIL_ID = item.ID;
|
||||
basic.REASON_ID = item2.REASON_ID;
|
||||
reasonList.Add(basic);
|
||||
}
|
||||
}
|
||||
if (item.RECITIFY_USER_ID != null)
|
||||
{
|
||||
@ -192,17 +210,19 @@ namespace APT.SK.WebApi.Controllers.Api
|
||||
//param = Enum.GetName(typeof(FMDepartmentType), departmentType);
|
||||
if (departmentType != null)
|
||||
{
|
||||
param = ((SKDepartmentTypeEnum)departmentType.DEPARTMENT_TYPE).GetDescription();
|
||||
level = ((SKDepartmentTypeEnum)departmentType.DEPARTMENT_TYPE).GetDescription();
|
||||
if (departmentType.DEPARTMENT_STATUS != 1)
|
||||
{
|
||||
param = "公司级";
|
||||
level = "公司级";
|
||||
}
|
||||
}
|
||||
}
|
||||
MFlowPermitService.InsertApprove(serialCode[0], "SK014", param, entity.ID, "SK014_SHOWPRINT", entity.TaskID, true, () =>
|
||||
MFlowPermitService.InsertApprove(serialCode[0], "SK014", level, entity.ID, "SK014_SHOWPRINT", entity.TaskID, true, () =>
|
||||
{
|
||||
if (deleteBasicIds != null && deleteBasicIds.Any())
|
||||
this.BantchDeleteEntityNoCommit<T_SK_HIDDEN_DANGER_REPORT_DETAIL_BASIC>(deleteBasicIds);
|
||||
this.BantchDeleteEntityNoCommit<T_SK_HIDDEN_DANGER_REPORT_DETAIL_BASIC>(deleteBasicIds);
|
||||
if (deleteReasonIds != null && deleteReasonIds.Any())
|
||||
this.BantchDeleteEntityNoCommit<T_SK_HIDDEN_DANGER_REPORT_DETAIL_REASON>(deleteReasonIds);
|
||||
if (deleteFileIds != null && deleteFileIds.Any())
|
||||
this.BantchDeleteEntityNoCommit<T_SK_HIDDEN_DANGER_REPORT_DETAIL_FILE>(deleteFileIds);
|
||||
if (deleteDetailIds != null && deleteDetailIds.Any())
|
||||
@ -218,7 +238,9 @@ namespace APT.SK.WebApi.Controllers.Api
|
||||
if (fileList != null && fileList.Any())
|
||||
BantchSaveEntityNoCommit(fileList);
|
||||
if (basicList != null && basicList.Any())
|
||||
BantchSaveEntityNoCommit(basicList);
|
||||
BantchSaveEntityNoCommit(basicList);
|
||||
if (reasonList != null && reasonList.Any())
|
||||
BantchSaveEntityNoCommit(reasonList);
|
||||
if (notices != null && notices.Any())
|
||||
BantchSaveEntityNoCommit(notices);
|
||||
}, null, null, null, null, null, "SK014_SHOWPRINT", null, level + "隐患上报审批");
|
||||
@ -233,6 +255,8 @@ namespace APT.SK.WebApi.Controllers.Api
|
||||
|
||||
this.UnifiedCommit(() =>
|
||||
{
|
||||
if (deleteReasonIds != null && deleteReasonIds.Any())
|
||||
this.BantchDeleteEntityNoCommit<T_SK_HIDDEN_DANGER_REPORT_DETAIL_REASON>(deleteReasonIds);
|
||||
if (deleteBasicIds != null && deleteBasicIds.Any())
|
||||
this.BantchDeleteEntityNoCommit<T_SK_HIDDEN_DANGER_REPORT_DETAIL_BASIC>(deleteBasicIds);
|
||||
if (deleteFileIds != null && deleteFileIds.Any())
|
||||
@ -250,7 +274,9 @@ namespace APT.SK.WebApi.Controllers.Api
|
||||
if (fileList != null && fileList.Any())
|
||||
BantchSaveEntityNoCommit(fileList);
|
||||
if (basicList != null && basicList.Any())
|
||||
BantchSaveEntityNoCommit(basicList);
|
||||
BantchSaveEntityNoCommit(basicList);
|
||||
if (reasonList != null && reasonList.Any())
|
||||
BantchSaveEntityNoCommit(reasonList);
|
||||
if (notices != null && notices.Any())
|
||||
BantchSaveEntityNoCommit(notices);
|
||||
});
|
||||
@ -363,7 +389,7 @@ namespace APT.SK.WebApi.Controllers.Api
|
||||
});
|
||||
}
|
||||
/// <summary>
|
||||
/// 识别人确认
|
||||
/// 整改责任人确认
|
||||
/// </summary>
|
||||
/// <param name="entity"></param>
|
||||
/// <returns></returns>
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
Loading…
Reference in New Issue
Block a user