去除引用common.props
This commit is contained in:
@@ -1,6 +1,4 @@
|
||||
using JNPF.Common.Filter;
|
||||
|
||||
namespace JNPF.Message.Entitys.Dto.MessageAccount;
|
||||
namespace JNPF.Message.Entitys.Dto.MessageAccount;
|
||||
|
||||
public class EmailSendTestQuery : MessageAccountListOutput
|
||||
{
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
using JNPF.Common.Models.User;
|
||||
using JNPF.Message.Entitys.Dto.IM;
|
||||
using JNPF.Message.Entitys.Dto.MessageAccount;
|
||||
using JNPF.Message.Entitys.Model.IM;
|
||||
using Mapster;
|
||||
|
||||
|
||||
@@ -1,5 +1,4 @@
|
||||
<Project Sdk="Microsoft.NET.Sdk">
|
||||
<Import Project="$(SolutionDir)\common.props" />
|
||||
|
||||
<PropertyGroup>
|
||||
<TargetFramework>net6.0</TargetFramework>
|
||||
|
||||
@@ -1,5 +1,4 @@
|
||||
<Project Sdk="Microsoft.NET.Sdk">
|
||||
<Import Project="$(SolutionDir)\common.props" />
|
||||
|
||||
<PropertyGroup>
|
||||
<TargetFramework>net6.0</TargetFramework>
|
||||
|
||||
@@ -59,7 +59,7 @@ public class ImReplyService : IImReplyService, IDynamicApiController, ITransient
|
||||
|
||||
// 获取全部聊天对象列表
|
||||
var objectList = _repository.AsSugarClient().UnionAll(
|
||||
_repository.AsQueryable().Where(i => i.ReceiveUserId == _userManager.UserId && (SqlFunc.IsNullOrEmpty(i.ImreplySendDeleteMark)||i.ImreplySendDeleteMark != _userManager.UserId)).Select(it => new ImReplyObjectIdOutput { userId = it.UserId, latestDate = it.ReceiveTime }),
|
||||
_repository.AsQueryable().Where(i => i.ReceiveUserId == _userManager.UserId && (SqlFunc.IsNullOrEmpty(i.ImreplySendDeleteMark) || i.ImreplySendDeleteMark != _userManager.UserId)).Select(it => new ImReplyObjectIdOutput { userId = it.UserId, latestDate = it.ReceiveTime }),
|
||||
_repository.AsQueryable().Where(i => i.UserId == _userManager.UserId && (SqlFunc.IsNullOrEmpty(i.ImreplySendDeleteMark) || i.ImreplySendDeleteMark != _userManager.UserId)).Select(it => new ImReplyObjectIdOutput { userId = it.ReceiveUserId, latestDate = it.ReceiveTime })).MergeTable().GroupBy(it => new { it.userId }).Select(it => new { it.userId, latestDate = SqlFunc.AggregateMax(it.latestDate) }).ToList();
|
||||
var objectUserList = objectList.Adapt<List<ImReplyListOutput>>();
|
||||
if (objectUserList.Count > 0)
|
||||
@@ -78,7 +78,7 @@ public class ImReplyService : IImReplyService, IDynamicApiController, ITransient
|
||||
it.realName = item.RealName;
|
||||
it.headIcon = "/api/File/Image/userAvatar/" + item.HeadIcon;
|
||||
|
||||
var imContent = _repository.AsSugarClient().Queryable<IMContentEntity>().Where(i => (i.SendUserId == _userManager.UserId && i.ReceiveUserId == it.userId) || (i.SendUserId == it.userId && i.ReceiveUserId == _userManager.UserId)).Where(i => i.SendTime.Equals(it.latestDate) && (SqlFunc.IsNullOrEmpty(i.SendDeleteMark)|| i.SendDeleteMark != _userManager.UserId)).ToList().FirstOrDefault();
|
||||
var imContent = _repository.AsSugarClient().Queryable<IMContentEntity>().Where(i => (i.SendUserId == _userManager.UserId && i.ReceiveUserId == it.userId) || (i.SendUserId == it.userId && i.ReceiveUserId == _userManager.UserId)).Where(i => i.SendTime.Equals(it.latestDate) && (SqlFunc.IsNullOrEmpty(i.SendDeleteMark) || i.SendDeleteMark != _userManager.UserId)).ToList().FirstOrDefault();
|
||||
|
||||
// 获取最信息
|
||||
if (imContent != null)
|
||||
|
||||
@@ -1,13 +1,6 @@
|
||||
using JNPF.Common.Enums;
|
||||
using JNPF.Common.Extension;
|
||||
using JNPF.Common.Filter;
|
||||
using JNPF.DependencyInjection;
|
||||
using JNPF.DependencyInjection;
|
||||
using JNPF.DynamicApiController;
|
||||
using JNPF.FriendlyException;
|
||||
using JNPF.Message.Entitys.Dto.MessageAccount;
|
||||
using JNPF.Message.Entitys.Entity;
|
||||
using JNPF.Systems.Entitys.Permission;
|
||||
using Mapster;
|
||||
using Microsoft.AspNetCore.Mvc;
|
||||
using SqlSugar;
|
||||
|
||||
@@ -40,7 +33,7 @@ public class MessageDataTypeService : IDynamicApiController, ITransient
|
||||
[HttpGet("getTypeList/{type}")]
|
||||
public async Task<dynamic> GetTypeList(string type)
|
||||
{
|
||||
return (await _repository.GetListAsync(x => x.Type == type && x.DeleteMark == null)).Select(x => new { id = x.Id, fullName = x.FullName ,enCode=x.EnCode}).ToList();
|
||||
return (await _repository.GetListAsync(x => x.Type == type && x.DeleteMark == null)).Select(x => new { id = x.Id, fullName = x.FullName, enCode = x.EnCode }).ToList();
|
||||
}
|
||||
#endregion
|
||||
}
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
using JNPF.Common.Extension;
|
||||
using JNPF.Common.Filter;
|
||||
using JNPF.Common.Security;
|
||||
using JNPF.DependencyInjection;
|
||||
using JNPF.DynamicApiController;
|
||||
using JNPF.LinqBuilder;
|
||||
@@ -8,7 +7,6 @@ using JNPF.Message.Entitys.Dto.MessageMonitor;
|
||||
using JNPF.Message.Entitys.Entity;
|
||||
using JNPF.Systems.Entitys.Permission;
|
||||
using JNPF.Systems.Interfaces.Permission;
|
||||
using Mapster;
|
||||
using Microsoft.AspNetCore.Mvc;
|
||||
using SqlSugar;
|
||||
|
||||
|
||||
@@ -120,7 +120,7 @@ public class MessageService : IMessageService, IDynamicApiController, ITransient
|
||||
title = a.Title,
|
||||
type = a.Type,
|
||||
isRead = b.IsRead,
|
||||
flowType=a.FlowType
|
||||
flowType = a.FlowType
|
||||
}).ToPagedListAsync(input.currentPage, input.pageSize);
|
||||
return PageResult<MessageListOutput>.SqlSugarPageResult(list);
|
||||
}
|
||||
@@ -414,7 +414,7 @@ public class MessageService : IMessageService, IDynamicApiController, ITransient
|
||||
//modifyby zhoukeda 20230704 定时任务发起的推送消息没有user
|
||||
string userManagerUserId = _userManager.UserId ?? "";
|
||||
string userManagerTenantId = _userManager.TenantId ?? "";
|
||||
|
||||
|
||||
MessageEntity entity = new MessageEntity();
|
||||
entity.Id = SnowflakeIdHelper.NextId();
|
||||
entity.Title = title;
|
||||
|
||||
@@ -203,7 +203,7 @@ public class MessageTemplateService : IDynamicApiController, ITransient
|
||||
{
|
||||
var paramEntity = item.Adapt<MessageTemplateParamEntity>();
|
||||
paramEntity.TemplateId = entity.Id;
|
||||
paramEntity.Id= SnowflakeIdHelper.NextId();
|
||||
paramEntity.Id = SnowflakeIdHelper.NextId();
|
||||
await _repository.AsSugarClient().Insertable(paramEntity).IgnoreColumns(ignoreNullColumn: true).CallEntityMethod(m => m.Create()).ExecuteCommandAsync();
|
||||
}
|
||||
var smsFieldList = await _repository.AsSugarClient().Queryable<MessageSmsFieldEntity>().Where(x => x.TemplateId == id && x.DeleteMark == null).ToListAsync();
|
||||
|
||||
@@ -360,7 +360,7 @@ public class SendMessageService : ISendMessageService, IDynamicApiController, IT
|
||||
var paramsDic = messageSendModel.paramJson.ToDictionary(x => x.field, y => y.value);//参数
|
||||
var title = messageTemplateEntity.Title;
|
||||
var content = messageTemplateEntity.Content;
|
||||
if (messageTemplateEntity.MessageType=="6")
|
||||
if (messageTemplateEntity.MessageType == "6")
|
||||
{
|
||||
try
|
||||
{
|
||||
@@ -462,9 +462,9 @@ public class SendMessageService : ISendMessageService, IDynamicApiController, IT
|
||||
return errorList.Any() ? string.Join(",", errorList) : string.Empty;
|
||||
}
|
||||
|
||||
public async Task SendMessageDefult(string enCode, List<string> toUser,string creatorUser, string flowName, Dictionary<string, object> bodyDic)
|
||||
public async Task SendMessageDefult(string enCode, List<string> toUser, string creatorUser, string flowName, Dictionary<string, object> bodyDic)
|
||||
{
|
||||
var msgTemplateEntity= await _repository.AsSugarClient().Queryable<MessageTemplateEntity>().FirstAsync(x => x.EnCode == enCode && x.TemplateType=="1" && x.DeleteMark == null);
|
||||
var msgTemplateEntity = await _repository.AsSugarClient().Queryable<MessageTemplateEntity>().FirstAsync(x => x.EnCode == enCode && x.TemplateType == "1" && x.DeleteMark == null);
|
||||
msgTemplateEntity.Title = msgTemplateEntity.Title.Replace("@流程发起人", creatorUser).Replace("@流程名称", flowName);
|
||||
msgTemplateEntity.Content = msgTemplateEntity.Content.Replace("@流程发起人", creatorUser).Replace("@流程名称", flowName);
|
||||
await _messageService.SentMessage(toUser, msgTemplateEntity.Title, msgTemplateEntity.Content, bodyDic);
|
||||
@@ -534,7 +534,7 @@ public class SendMessageService : ISendMessageService, IDynamicApiController, IT
|
||||
Password = messageAccountEntity.SmtpPassword,
|
||||
SMTPHost = messageAccountEntity.SmtpServer,
|
||||
SMTPPort = messageAccountEntity.SmtpPort.ParseToInt(),
|
||||
Ssl=messageAccountEntity.SslLink.Equals("1")
|
||||
Ssl = messageAccountEntity.SslLink.Equals("1")
|
||||
}, mailModel);
|
||||
}
|
||||
|
||||
|
||||
@@ -99,8 +99,8 @@ public class ShortLinkService : IShortLinkService, IDynamicApiController, ITrans
|
||||
}
|
||||
else
|
||||
{
|
||||
_sqlSugarClient.AddConnection(JNPFTenantExtensions.GetConfig(options));
|
||||
_sqlSugarClient.ChangeDatabase(tenantId);
|
||||
_sqlSugarClient.AddConnection(JNPFTenantExtensions.GetConfig(options));
|
||||
_sqlSugarClient.ChangeDatabase(tenantId);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -1,18 +1,14 @@
|
||||
using System.Text;
|
||||
using System.Xml;
|
||||
using JNPF.Common.Enums;
|
||||
using JNPF.Common.Extension;
|
||||
using JNPF.Common.Security;
|
||||
using JNPF.DependencyInjection;
|
||||
using JNPF.DynamicApiController;
|
||||
using JNPF.Extras.Thirdparty.WeChat;
|
||||
using JNPF.Extras.Thirdparty.WeChat.Internal;
|
||||
using JNPF.FriendlyException;
|
||||
using JNPF.Logging.Attributes;
|
||||
using JNPF.Message.Entitys.Entity;
|
||||
using JNPF.Systems.Entitys.Permission;
|
||||
using Microsoft.AspNetCore.Authorization;
|
||||
using Microsoft.AspNetCore.Http;
|
||||
using Microsoft.AspNetCore.Mvc;
|
||||
using Senparc.Weixin.MP;
|
||||
using SqlSugar;
|
||||
@@ -122,7 +118,7 @@ public class WechatOpenService : IDynamicApiController, ITransient
|
||||
var input = new WechatMPEvent();
|
||||
input.ToUserName = doc.DocumentElement.SelectSingleNode("ToUserName").InnerText.Trim();
|
||||
input.FromUserName = doc.DocumentElement.SelectSingleNode("FromUserName").InnerText.Trim();
|
||||
input.Event= doc.DocumentElement.SelectSingleNode("Event").InnerText.Trim();
|
||||
input.Event = doc.DocumentElement.SelectSingleNode("Event").InnerText.Trim();
|
||||
return input;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,5 +1,4 @@
|
||||
<Project Sdk="Microsoft.NET.Sdk">
|
||||
<Import Project="$(SolutionDir)\common.props" />
|
||||
|
||||
<PropertyGroup>
|
||||
<TargetFramework>net6.0</TargetFramework>
|
||||
|
||||
Reference in New Issue
Block a user