Compare commits
12 Commits
211a63d70e
...
master
| Author | SHA1 | Date | |
|---|---|---|---|
| f5e02c4219 | |||
| b88106a38f | |||
|
|
f70794b7b0 | ||
|
|
1157ea032b | ||
|
|
fd698e7a5d | ||
|
|
a54ec39df7 | ||
|
|
8fc23b0055 | ||
|
|
e372a5a5b2 | ||
|
|
bb9a64a85b | ||
|
|
ab40ce9205 | ||
|
|
863bf43873 | ||
|
|
b953e3afaa |
|
Before Width: | Height: | Size: 35 KiB After Width: | Height: | Size: 35 KiB |
@@ -0,0 +1,57 @@
|
||||
<Project Sdk="Microsoft.NET.Sdk">
|
||||
|
||||
<PropertyGroup>
|
||||
<TargetFrameworks>net462;net7.0;net8.0;net9.0</TargetFrameworks>
|
||||
<PackageId>DigitalData.EmailProfilerDispatcher.Abstraction.Attributes</PackageId>
|
||||
<Company>Digital Data GmbH</Company>
|
||||
<Copyright>Copyright 2025</Copyright>
|
||||
<PackageIcon>icon.png</PackageIcon>
|
||||
<PackageTags>digital data email dispatcher</PackageTags>
|
||||
<Description>This package provides the necessary ‘Attributes’ for the DigitalData.EmailProfilerDispatcher.Abstractions library to support the .NET Framrwork.</Description>
|
||||
<Authors>Digital Data GmbH</Authors>
|
||||
<RepositoryUrl>http://git.dd:3000/AppStd/EmailProfilerDispatcher.git</RepositoryUrl>
|
||||
<Version>1.0.0</Version>
|
||||
<AssemblyVersion>1.0.0</AssemblyVersion>
|
||||
<FileVersion>1.0.0</FileVersion>
|
||||
</PropertyGroup>
|
||||
|
||||
<PropertyGroup Condition="'$(TargetFramework)' == 'net462'">
|
||||
<ImplicitUsings>disable</ImplicitUsings>
|
||||
<LangVersion>7.3</LangVersion>
|
||||
</PropertyGroup>
|
||||
|
||||
<PropertyGroup Condition="'$(TargetFramework)' != 'net462'">
|
||||
<ImplicitUsings>enable</ImplicitUsings>
|
||||
<LangVersion>latest</LangVersion>
|
||||
</PropertyGroup>
|
||||
|
||||
<ItemGroup Condition="'$(TargetFramework)' == 'net462'">
|
||||
<PackageReference Include="System.ComponentModel.Annotations" Version="4.7.0" />
|
||||
</ItemGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<None Include="..\Assets\icon.png">
|
||||
<Pack>True</Pack>
|
||||
<PackagePath>\</PackagePath>
|
||||
</None>
|
||||
</ItemGroup>
|
||||
|
||||
<ItemGroup Condition="'$(TargetFramework)' == 'net7.0'">
|
||||
<PackageReference Include="DigitalData.Core.Abstractions.Security">
|
||||
<Version>1.0.0</Version>
|
||||
</PackageReference>
|
||||
</ItemGroup>
|
||||
|
||||
<ItemGroup Condition="'$(TargetFramework)' == 'net8.0'">
|
||||
<PackageReference Include="DigitalData.Core.Abstractions.Security">
|
||||
<Version>1.0.0</Version>
|
||||
</PackageReference>
|
||||
</ItemGroup>
|
||||
|
||||
<ItemGroup Condition="'$(TargetFramework)' == 'net9.0'">
|
||||
<PackageReference Include="DigitalData.Core.Abstractions.Security">
|
||||
<Version>1.0.0</Version>
|
||||
</PackageReference>
|
||||
</ItemGroup>
|
||||
|
||||
</Project>
|
||||
@@ -1,4 +1,8 @@
|
||||
namespace DigitalData.EmailProfilerDispatcher.Abstraction.Attributes
|
||||
#if NETFRAMEWORK
|
||||
using System;
|
||||
#endif
|
||||
|
||||
namespace DigitalData.EmailProfilerDispatcher.Abstraction.Attributes
|
||||
{
|
||||
[AttributeUsage(AttributeTargets.Property)]
|
||||
public class TemplatePlaceholderAttribute : Attribute
|
||||
Binary file not shown.
|
Before Width: | Height: | Size: 22 KiB |
@@ -1,9 +1,9 @@
|
||||
using DigitalData.Core.Abstractions.Infrastructure;
|
||||
using DigitalData.Core.Abstraction.Application.Repository;
|
||||
using DigitalData.EmailProfilerDispatcher.Abstraction.Entities;
|
||||
|
||||
namespace DigitalData.EmailProfilerDispatcher.Abstraction.Contracts
|
||||
namespace DigitalData.EmailProfilerDispatcher.Abstraction.Contracts;
|
||||
|
||||
[Obsolete("Use IRepository")]
|
||||
public interface IEmailOutRepository : ICRUDRepository<EmailOut, int>
|
||||
{
|
||||
public interface IEmailOutRepository : ICRUDRepository<EmailOut, int>
|
||||
{
|
||||
}
|
||||
}
|
||||
@@ -1,12 +1,12 @@
|
||||
using DigitalData.Core.Abstractions.Application;
|
||||
using DigitalData.Core.DTO;
|
||||
using DigitalData.Core.Abstraction.Application;
|
||||
using DigitalData.Core.Abstraction.Application.DTO;
|
||||
using DigitalData.EmailProfilerDispatcher.Abstraction.DTOs.EmailOut;
|
||||
using DigitalData.EmailProfilerDispatcher.Abstraction.Entities;
|
||||
|
||||
namespace DigitalData.EmailProfilerDispatcher.Abstraction.Contracts
|
||||
namespace DigitalData.EmailProfilerDispatcher.Abstraction.Contracts;
|
||||
|
||||
[Obsolete("Use MediatR")]
|
||||
public interface IEmailOutService : ICRUDService<EmailOutCreateDto, EmailOutDto, EmailOut, int>
|
||||
{
|
||||
public interface IEmailOutService : ICRUDService<EmailOutCreateDto, EmailOutDto, EmailOutDto, EmailOut, int>
|
||||
{
|
||||
Task<DataResult<int>> CreateWithTemplateAsync(EmailOutCreateDto createDto, params object[] models);
|
||||
}
|
||||
Task<DataResult<int>> CreateWithTemplateAsync(EmailOutCreateDto createDto, params object[] models);
|
||||
}
|
||||
@@ -1,27 +1,24 @@
|
||||
using DigitalData.Core.Abstractions;
|
||||
namespace DigitalData.EmailProfilerDispatcher.Abstraction.DTOs.EmailOut;
|
||||
|
||||
namespace DigitalData.EmailProfilerDispatcher.Abstraction.DTOs.EmailOut
|
||||
{
|
||||
public record EmailOutDto(
|
||||
int Id,
|
||||
int ReminderTypeId,
|
||||
int SendingProfile,
|
||||
int ReferenceId,
|
||||
string? ReferenceString,
|
||||
int? EntityId,
|
||||
int WfId,
|
||||
string? WfReference,
|
||||
string EmailAddress,
|
||||
string EmailSubj,
|
||||
string EmailBody,
|
||||
string? EmailAttmt1,
|
||||
DateTime? EmailSent,
|
||||
string? Comment,
|
||||
string AddedWho,
|
||||
DateTime? AddedWhen,
|
||||
string? ChangedWho,
|
||||
DateTime? ChangedWhen,
|
||||
DateTime? ErrorTimestamp,
|
||||
string? ErrorMsg
|
||||
) : IUnique<int>;
|
||||
}
|
||||
public record EmailOutDto(
|
||||
int Id,
|
||||
int ReminderTypeId,
|
||||
int SendingProfile,
|
||||
int ReferenceId,
|
||||
string? ReferenceString,
|
||||
int? EntityId,
|
||||
int WfId,
|
||||
string? WfReference,
|
||||
string EmailAddress,
|
||||
string EmailSubj,
|
||||
string EmailBody,
|
||||
string? EmailAttmt1,
|
||||
DateTime? EmailSent,
|
||||
string? Comment,
|
||||
string AddedWho,
|
||||
DateTime? AddedWhen,
|
||||
string? ChangedWho,
|
||||
DateTime? ChangedWhen,
|
||||
DateTime? ErrorTimestamp,
|
||||
string? ErrorMsg
|
||||
);
|
||||
@@ -1,7 +1,7 @@
|
||||
<Project Sdk="Microsoft.NET.Sdk">
|
||||
<Project Sdk="Microsoft.NET.Sdk">
|
||||
|
||||
<PropertyGroup>
|
||||
<TargetFramework>net7.0</TargetFramework>
|
||||
<TargetFrameworks>net7.0;net8.0;net9.0</TargetFrameworks>
|
||||
<ImplicitUsings>enable</ImplicitUsings>
|
||||
<Nullable>enable</Nullable>
|
||||
<PackageId>DigitalData.EmailProfilerDispatcher.Abstraction</PackageId>
|
||||
@@ -9,21 +9,28 @@
|
||||
<Company>Digital Data GmbH</Company>
|
||||
<Description>This package provides the necessary abstractions and interfaces for the DigitalData.EmailProfilerDispatcher library, facilitating a clean and decoupled architecture.</Description>
|
||||
<Copyright>Copyright 2024</Copyright>
|
||||
<PackageIcon>Assets\icon.png</PackageIcon>
|
||||
<PackageIcon>icon.png</PackageIcon>
|
||||
<RepositoryUrl>http://git.dd:3000/AppStd/EmailProfilerDispatcher.git</RepositoryUrl>
|
||||
<PackageTags>digital data email dispatcher abstraction</PackageTags>
|
||||
<Version>2.0.0</Version>
|
||||
<Version>3.2.0</Version>
|
||||
<FileVersion>3.2.0</FileVersion>
|
||||
<AssemblyVersion>3.2.0</AssemblyVersion>
|
||||
</PropertyGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<PackageReference Include="DigitalData.Core.Abstractions" Version="2.0.0" />
|
||||
</ItemGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<None Update="Assets\icon.png">
|
||||
<None Include="..\Assets\icon.png">
|
||||
<Pack>True</Pack>
|
||||
<PackagePath>\</PackagePath>
|
||||
</None>
|
||||
</ItemGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<PackageReference Include="DigitalData.Core.Abstractions.Security" Version="1.0.0" />
|
||||
<PackageReference Include="DigitalData.Core.Abstraction.Application" Version="1.0.0" />
|
||||
</ItemGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<ProjectReference Include="..\DigitalData.EmailProfilerDispatcher.Abstraction.Attributes\DigitalData.EmailProfilerDispatcher.Abstraction.Attributes.csproj" />
|
||||
</ItemGroup>
|
||||
|
||||
</Project>
|
||||
|
||||
@@ -1,12 +1,11 @@
|
||||
using DigitalData.Core.Abstractions;
|
||||
using System.ComponentModel;
|
||||
using System.ComponentModel;
|
||||
using System.ComponentModel.DataAnnotations;
|
||||
using System.ComponentModel.DataAnnotations.Schema;
|
||||
|
||||
namespace DigitalData.EmailProfilerDispatcher.Abstraction.Entities
|
||||
{
|
||||
[Table("TBEMLP_EMAIL_OUT")]
|
||||
public class EmailOut : IUnique<int>
|
||||
public class EmailOut
|
||||
{
|
||||
[Key]
|
||||
[DatabaseGenerated(DatabaseGeneratedOption.Identity)]
|
||||
@@ -74,7 +73,6 @@ namespace DigitalData.EmailProfilerDispatcher.Abstraction.Entities
|
||||
|
||||
[Column("ADDED_WHEN")]
|
||||
[DefaultValue("getdate()")]
|
||||
[NotMapped]
|
||||
public DateTime? AddedWhen { get; set; }
|
||||
|
||||
[Column("CHANGED_WHO", TypeName = "varchar(50)")]
|
||||
@@ -90,5 +88,16 @@ namespace DigitalData.EmailProfilerDispatcher.Abstraction.Entities
|
||||
[Column("ERROR_MSG", TypeName = "varchar(900)")]
|
||||
[StringLength(900)]
|
||||
public string? ErrorMsg { get; set; }
|
||||
|
||||
[Column("ATTACHMENT1_BYTES", TypeName = "varbinary(max)")]
|
||||
public byte[]? Attachment1Bytes { get; set; }
|
||||
|
||||
[Column("ATT1_RELATED_ID")]
|
||||
public long? Att1RelatedId { get; set; }
|
||||
|
||||
[Column("ATT1_REL_TYPE", TypeName = "varchar(20)")]
|
||||
[StringLength(20)]
|
||||
public string? Att1RelType { get; set; }
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
@@ -11,6 +11,15 @@ Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "DigitalData.EmailProfilerDi
|
||||
EndProject
|
||||
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "DigitalData.EmailProfilerDispatcher", "DigitalData.EmailProfilerDispatcher\DigitalData.EmailProfilerDispatcher.csproj", "{DF202B1D-6C6F-4354-9B73-20F03486D020}"
|
||||
EndProject
|
||||
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution Items", "{8EC462FD-D22E-90A8-E5CE-7E832BA40C5D}"
|
||||
EndProject
|
||||
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Assest", "Assest", "{02EA681E-C7D8-13C7-8484-4AC65E1B71E8}"
|
||||
ProjectSection(SolutionItems) = preProject
|
||||
Assets\icon.png = Assets\icon.png
|
||||
EndProjectSection
|
||||
EndProject
|
||||
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "DigitalData.EmailProfilerDispatcher.Abstraction.Attributes", "DigitalData.EmailProfilerDispatcher.Abstraction.Attributes\DigitalData.EmailProfilerDispatcher.Abstraction.Attributes.csproj", "{16785881-75BA-4721-9A0C-B469FAA95D95}"
|
||||
EndProject
|
||||
Global
|
||||
GlobalSection(SolutionConfigurationPlatforms) = preSolution
|
||||
Debug|Any CPU = Debug|Any CPU
|
||||
@@ -33,10 +42,17 @@ Global
|
||||
{DF202B1D-6C6F-4354-9B73-20F03486D020}.Debug|Any CPU.Build.0 = Release|Any CPU
|
||||
{DF202B1D-6C6F-4354-9B73-20F03486D020}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
||||
{DF202B1D-6C6F-4354-9B73-20F03486D020}.Release|Any CPU.Build.0 = Release|Any CPU
|
||||
{16785881-75BA-4721-9A0C-B469FAA95D95}.Debug|Any CPU.ActiveCfg = Release|Any CPU
|
||||
{16785881-75BA-4721-9A0C-B469FAA95D95}.Debug|Any CPU.Build.0 = Release|Any CPU
|
||||
{16785881-75BA-4721-9A0C-B469FAA95D95}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
||||
{16785881-75BA-4721-9A0C-B469FAA95D95}.Release|Any CPU.Build.0 = Release|Any CPU
|
||||
EndGlobalSection
|
||||
GlobalSection(SolutionProperties) = preSolution
|
||||
HideSolutionNode = FALSE
|
||||
EndGlobalSection
|
||||
GlobalSection(NestedProjects) = preSolution
|
||||
{02EA681E-C7D8-13C7-8484-4AC65E1B71E8} = {8EC462FD-D22E-90A8-E5CE-7E832BA40C5D}
|
||||
EndGlobalSection
|
||||
GlobalSection(ExtensibilityGlobals) = postSolution
|
||||
SolutionGuid = {CB0B8122-D532-4A7F-87CC-760B959A433C}
|
||||
EndGlobalSection
|
||||
|
||||
@@ -1,41 +1,56 @@
|
||||
<Project Sdk="Microsoft.NET.Sdk">
|
||||
<Project Sdk="Microsoft.NET.Sdk">
|
||||
|
||||
<PropertyGroup>
|
||||
<TargetFramework>net7.0</TargetFramework>
|
||||
<TargetFrameworks>net7.0;net8.0;net9.0</TargetFrameworks>
|
||||
<ImplicitUsings>enable</ImplicitUsings>
|
||||
<Nullable>enable</Nullable>
|
||||
<PackageId>DigitalData.EmailProfilerDispatcher</PackageId>
|
||||
<Version>2.0.0</Version>
|
||||
<Company>Digital Data GmbH</Company>
|
||||
<Copyright>Copyright 2024</Copyright>
|
||||
<PackageIcon>Assets\icon.png</PackageIcon>
|
||||
<PackageIcon>icon.png</PackageIcon>
|
||||
<PackageTags>digital data email dispatcher</PackageTags>
|
||||
<Description>DigitalData.EmailProfilerDispatcher enables adding data to the Email Profiler's SQL tables for systematic and batch email dispatching. It also supports dynamic and automatic template filling using attributes, allowing object property values to populate email templates.</Description>
|
||||
<Authors>Digital Data GmbH</Authors>
|
||||
<RepositoryUrl>http://git.dd:3000/AppStd/EmailProfilerDispatcher.git</RepositoryUrl>
|
||||
<Version>3.1.1</Version>
|
||||
<AssemblyVersion>3.1.1</AssemblyVersion>
|
||||
<FileVersion>3.1.1</FileVersion>
|
||||
</PropertyGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<PackageReference Include="AutoMapper" Version="13.0.1" />
|
||||
<PackageReference Include="DigitalData.Core.Abstractions" Version="2.0.0" />
|
||||
<PackageReference Include="DigitalData.Core.Application" Version="2.0.0" />
|
||||
<PackageReference Include="DigitalData.Core.Infrastructure" Version="2.0.0" />
|
||||
<PackageReference Include="Microsoft.EntityFrameworkCore" Version="7.0.16" />
|
||||
<PackageReference Include="Microsoft.EntityFrameworkCore.Relational" Version="7.0.16" />
|
||||
<PackageReference Include="Microsoft.Extensions.Localization" Version="7.0.19" />
|
||||
<PackageReference Include="Microsoft.Extensions.Localization.Abstractions" Version="7.0.19" />
|
||||
</ItemGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<ProjectReference Include="..\DigitalData.EmailProfilerDispatcher.Abstraction\DigitalData.EmailProfilerDispatcher.Abstraction.csproj" />
|
||||
</ItemGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<None Update="Assets\icon.png">
|
||||
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
|
||||
<None Include="..\Assets\icon.png">
|
||||
<Pack>True</Pack>
|
||||
<PackagePath>\</PackagePath>
|
||||
</None>
|
||||
</ItemGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<PackageReference Include="DigitalData.Core.Application" Version="3.3.4" />
|
||||
<PackageReference Include="DigitalData.Core.Infrastructure" Version="2.1.1" />
|
||||
<PackageReference Include="Microsoft.Extensions.Localization" Version="7.0.19" />
|
||||
<PackageReference Include="Microsoft.Extensions.Localization.Abstractions" Version="7.0.19" />
|
||||
</ItemGroup>
|
||||
|
||||
<ItemGroup Condition="'$(TargetFramework)' == 'net7.0'">
|
||||
<PackageReference Include="AutoMapper" Version="13.0.1" />
|
||||
<PackageReference Include="Microsoft.EntityFrameworkCore" Version="7.0.20" />
|
||||
<PackageReference Include="Microsoft.EntityFrameworkCore.Relational" Version="7.0.20" />
|
||||
</ItemGroup>
|
||||
|
||||
<ItemGroup Condition="'$(TargetFramework)' == 'net8.0'">
|
||||
<PackageReference Include="AutoMapper" Version="14.0.0" />
|
||||
<PackageReference Include="Microsoft.EntityFrameworkCore" Version="8.0.15" />
|
||||
<PackageReference Include="Microsoft.EntityFrameworkCore.Relational" Version="8.0.15" />
|
||||
</ItemGroup>
|
||||
|
||||
<ItemGroup Condition="'$(TargetFramework)' == 'net9.0'">
|
||||
<PackageReference Include="AutoMapper" Version="14.0.0" />
|
||||
<PackageReference Include="Microsoft.EntityFrameworkCore" Version="9.0.5" />
|
||||
<PackageReference Include="Microsoft.EntityFrameworkCore.Relational" Version="9.0.5" />
|
||||
</ItemGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<ProjectReference Include="..\DigitalData.EmailProfilerDispatcher.Abstraction\DigitalData.EmailProfilerDispatcher.Abstraction.csproj" />
|
||||
</ItemGroup>
|
||||
|
||||
</Project>
|
||||
|
||||
@@ -1,15 +1,16 @@
|
||||
using DigitalData.Core.Infrastructure;
|
||||
using DigitalData.Core.Abstraction.Application.Repository;
|
||||
using DigitalData.Core.Infrastructure;
|
||||
using DigitalData.EmailProfilerDispatcher.Abstraction.Contracts;
|
||||
using DigitalData.EmailProfilerDispatcher.Abstraction.Entities;
|
||||
using Microsoft.EntityFrameworkCore;
|
||||
|
||||
namespace DigitalData.EmailProfilerDispatcher.Repositories
|
||||
namespace DigitalData.EmailProfilerDispatcher.Repositories;
|
||||
|
||||
[Obsolete("Use IRepository")]
|
||||
public class EmailOutRepository<TDbContext> : CRUDRepository<EmailOut, int, TDbContext>, IEmailOutRepository
|
||||
where TDbContext : DbContext, IMailDbContext
|
||||
{
|
||||
public class EmailOutRepository<TDbContext> : CRUDRepository<EmailOut, int, TDbContext>, IEmailOutRepository
|
||||
where TDbContext : DbContext, IMailDbContext
|
||||
public EmailOutRepository(TDbContext dbContext) : base(dbContext, dbContext.EMailOuts)
|
||||
{
|
||||
public EmailOutRepository(TDbContext dbContext) : base(dbContext, dbContext.EMailOuts)
|
||||
{
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,32 +1,31 @@
|
||||
using AutoMapper;
|
||||
using DigitalData.Core.Application;
|
||||
using DigitalData.Core.DTO;
|
||||
using DigitalData.Core.Abstraction.Application.DTO;
|
||||
using DigitalData.EmailProfilerDispatcher.Abstraction.Contracts;
|
||||
using DigitalData.EmailProfilerDispatcher.Abstraction.DTOs.EmailOut;
|
||||
using DigitalData.EmailProfilerDispatcher.Abstraction.Entities;
|
||||
|
||||
namespace DigitalData.EmailProfilerDispatcher.Abstraction.Services
|
||||
{
|
||||
public class EmailOutService : CRUDService<IEmailOutRepository, EmailOutCreateDto, EmailOutDto, EmailOutDto, EmailOut, int>, IEmailOutService
|
||||
namespace DigitalData.EmailProfilerDispatcher.Abstraction.Services;
|
||||
|
||||
public class EmailOutService : CRUDService<IEmailOutRepository, EmailOutCreateDto, EmailOutDto, EmailOut, int>, IEmailOutService
|
||||
{
|
||||
public EmailOutService(IEmailOutRepository repository, IMapper mapper) : base(repository, mapper)
|
||||
{
|
||||
}
|
||||
|
||||
public async Task<DataResult<int>> CreateWithTemplateAsync(EmailOutCreateDto createDto, params object[] models)
|
||||
{
|
||||
createDto.EmailSubj = createDto.EmailSubj.FillTemplate(models);
|
||||
createDto.EmailBody = createDto.EmailBody.FillTemplate(models);
|
||||
public async Task<DataResult<int>> CreateWithTemplateAsync(EmailOutCreateDto createDto, params object[] models)
|
||||
{
|
||||
createDto.EmailSubj = createDto.EmailSubj.FillTemplate(models);
|
||||
createDto.EmailBody = createDto.EmailBody.FillTemplate(models);
|
||||
|
||||
return await base.CreateAsync(createDto);
|
||||
}
|
||||
return await base.CreateAsync(createDto).ThenAsync(email => Result.Success(email.Id), (msg, ntc) => Result.Fail<int>().Message(msg).Notice(ntc));
|
||||
}
|
||||
|
||||
public async Task<DataResult<int>> CreateWithTemplateAsync(EmailOutCreateDto createDto, Dictionary<string, string> placeholders, params object[] models)
|
||||
{
|
||||
createDto.EmailSubj = createDto.EmailSubj.FillTemplate(placeholders);
|
||||
createDto.EmailBody = createDto.EmailBody.FillTemplate(placeholders);
|
||||
public async Task<DataResult<int>> CreateWithTemplateAsync(EmailOutCreateDto createDto, Dictionary<string, string> placeholders, params object[] models)
|
||||
{
|
||||
createDto.EmailSubj = createDto.EmailSubj.FillTemplate(placeholders);
|
||||
createDto.EmailBody = createDto.EmailBody.FillTemplate(placeholders);
|
||||
|
||||
return await CreateWithTemplateAsync(createDto, models: models);
|
||||
}
|
||||
return await CreateWithTemplateAsync(createDto, models: models);
|
||||
}
|
||||
}
|
||||
@@ -1,4 +1,4 @@
|
||||
<Project Sdk="Microsoft.NET.Sdk">
|
||||
<Project Sdk="Microsoft.NET.Sdk">
|
||||
|
||||
<PropertyGroup>
|
||||
<TargetFramework>net7.0</TargetFramework>
|
||||
@@ -11,7 +11,8 @@
|
||||
|
||||
<ItemGroup>
|
||||
<PackageReference Include="coverlet.collector" Version="3.2.0" />
|
||||
<PackageReference Include="DigitalData.Core.Application" Version="2.0.0" />
|
||||
<PackageReference Include="DigitalData.Core.Application" Version="3.3.4" />
|
||||
<PackageReference Include="DigitalData.Core.Abstraction.Application" Version="1.0.0" />
|
||||
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="17.7.1" />
|
||||
<PackageReference Include="NUnit" Version="3.13.3" />
|
||||
<PackageReference Include="NUnit.Analyzers" Version="3.6.1" />
|
||||
|
||||
Reference in New Issue
Block a user