|
@@ -29,6 +29,10 @@ public class RedPackApplication : IRedPackApplication, IScopeDependency
|
|
|
private readonly IOrderRepository _orderRepository;
|
|
|
private readonly ISnapshotSMSTemplateRepository _snapshotSMSTemplateRepository;
|
|
|
private readonly IIndustryRepository _industryRepository;
|
|
|
+
|
|
|
+ /// <summary>
|
|
|
+ /// 市民红包审核仓储
|
|
|
+ /// </summary>
|
|
|
private readonly IRedPackAuditRepository _redPackAuditRepository;
|
|
|
private readonly IRedPackRecordRepository _redPackRecordRepository;
|
|
|
private readonly IRepository<OrderSpecial> _orderSpecialRepository;
|
|
@@ -232,6 +236,66 @@ public class RedPackApplication : IRedPackApplication, IScopeDependency
|
|
|
return outDto;
|
|
|
}
|
|
|
|
|
|
+ /// <summary>
|
|
|
+ /// 特殊红包审批列表
|
|
|
+ /// </summary>
|
|
|
+ /// <param name="dto"></param>
|
|
|
+ /// <returns></returns>
|
|
|
+ /// <exception cref="NotImplementedException"></exception>
|
|
|
+ [ExportExcel("特殊红包审批")]
|
|
|
+ public ISugarQueryable<SnapshotOrderAuditItemsOutDto> GetRedPackSpecialAuditItems(SnapshotOrderAuditItemsInDto dto)
|
|
|
+ {
|
|
|
+ ERedPackAuditStatus? status = null;
|
|
|
+ if (dto.Status != -1 && Enum.TryParse<ERedPackAuditStatus>(dto.Status.ToString(), out var statusParse))
|
|
|
+ {
|
|
|
+ status = statusParse;
|
|
|
+ }
|
|
|
+ var query = _redPackAuditRepository.Queryable()
|
|
|
+ .LeftJoin<OrderSnapshot>((redPackAudit, snapshot) => redPackAudit.OrderId == snapshot.Id)
|
|
|
+ .LeftJoin<Order>((redPackAudit, snapshot, order) => redPackAudit.OrderId == order.Id)
|
|
|
+ .Where((redPackAudit, snapshot, order) => snapshot.IndustryName == "安全隐患" && order.OrderTagCode.Contains("DHZY"))
|
|
|
+ .Select((redPackAudit, snapshot,order) => new SnapshotOrderAuditItemsOutDto
|
|
|
+ {
|
|
|
+ Id = redPackAudit.Id,
|
|
|
+ RedPackAuditId = redPackAudit.Id,
|
|
|
+ OrderId = order.Id,
|
|
|
+ No = order.No,
|
|
|
+ Title = order.Title,
|
|
|
+ IndustryName = snapshot.IndustryName,
|
|
|
+ IndustryId = snapshot.IndustryId,
|
|
|
+ SourceChannel = order.SourceChannel,
|
|
|
+ SourceChannelCode = order.SourceChannelCode,
|
|
|
+ Status = order.Status,
|
|
|
+ IsDanger = snapshot.IsDanger,
|
|
|
+ FromPhone = order.FromPhone,
|
|
|
+ FromName = order.FromName,
|
|
|
+ AuditTime = redPackAudit.AuditTime,
|
|
|
+ ApprovedAmount = redPackAudit.ApprovedAmount,
|
|
|
+ AcutalAmount = redPackAudit.AcutalAmount,
|
|
|
+ IsIssued = redPackAudit.IsIssued,
|
|
|
+ //RecordRemark = record.Remark,
|
|
|
+ County = order.County,
|
|
|
+ // IsRectify = s.IsRepetition
|
|
|
+ IsDeal = snapshot.IsDeal,
|
|
|
+ NetworkENumber = snapshot.NetworkENumber,
|
|
|
+ IsTruth = snapshot.IsTruth,
|
|
|
+ IsTruthDepartment = snapshot.IsTruthDepartment,
|
|
|
+ IsRepetition = snapshot.IsRepetition,
|
|
|
+ CreationTime = order.CreationTime,
|
|
|
+ OrgLevelOneCode = order.OrgLevelOneCode,
|
|
|
+ OrgLevelOneName = order.OrgLevelOneName,
|
|
|
+ AuditId = redPackAudit.AuditId,
|
|
|
+ AuditName = redPackAudit.AuditName,
|
|
|
+ AuditOrgId = redPackAudit.AuditOrgId,
|
|
|
+ AuditOrgName = redPackAudit.AuditOrgName,
|
|
|
+ AuditRemark = redPackAudit.AuditRemark,
|
|
|
+ //BankCardNo = record.BankCardNo,
|
|
|
+ //OpenBank = record.OpenBank,
|
|
|
+ AuditStatus = redPackAudit.Status,
|
|
|
+ });
|
|
|
+ return query;
|
|
|
+ }
|
|
|
+
|
|
|
/// <summary>
|
|
|
/// 红包审核集合
|
|
|
/// </summary>
|