using DS.Module.Core;
using DS.Module.Core.Helpers;
using Microsoft.Extensions.DependencyInjection;
using SqlSugar;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using Newtonsoft;
using Newtonsoft.Json;
using DS.Module.Core.Extensions;
namespace DS.Module.EmailModule
{
public class EmailService : IEmailService
{
private readonly IServiceProvider _serviceProvider;
private readonly ISqlSugarClient db;
private readonly string emailServiceUrl;
///
/// 构造函数
///
///
public EmailService(IServiceProvider serviceProvider)
{
_serviceProvider = serviceProvider;
db = _serviceProvider.GetRequiredService();
}
public async Task> SendEmailByDjy(DjyEmailSendReq req)
{
var url = db.Queryable