内容模板建立文件夹

usertest
嵇文龙 3 months ago
parent 1299889e6d
commit f77bcee54e

@ -25,10 +25,15 @@
<ItemGroup> <ItemGroup>
<None Remove="Op\MailTemplate.cshtml" /> <None Remove="Op\MailTemplate.cshtml" />
<None Remove="Op\Templates\入货通知.cshtml" />
</ItemGroup> </ItemGroup>
<ItemGroup> <ItemGroup>
<Content Include="Op\MailTemplate.cshtml"> <Content Include="Op\Templates\入货通知.cshtml">
<ExcludeFromSingleFile>true</ExcludeFromSingleFile>
<CopyToPublishDirectory>PreserveNewest</CopyToPublishDirectory>
</Content>
<Content Include="Op\Templates\MailTemplate.cshtml">
<ExcludeFromSingleFile>true</ExcludeFromSingleFile> <ExcludeFromSingleFile>true</ExcludeFromSingleFile>
<CopyToPublishDirectory>PreserveNewest</CopyToPublishDirectory> <CopyToPublishDirectory>PreserveNewest</CopyToPublishDirectory>
</Content> </Content>

@ -69,7 +69,11 @@ namespace DS.WMS.Core.Op.Method.TaskInteraction.ActionExecutor.Booking
return; return;
} }
var model = new MailTemplateModel<SeaExportRes>(result2.Data) { BusinessId = context.TaskInfo.BusinessId }; var model = new MailTemplateModel<SeaExportRes>(result2.Data)
{
BusinessId = context.TaskInfo.BusinessId,
BusinessType = context.TaskInfo.BusinessType,
};
MailService mailService = new(context.ServiceProvider); MailService mailService = new(context.ServiceProvider);
result = await mailService.SendAsync(mailConfig, model); result = await mailService.SendAsync(mailConfig, model);
if (!result.Succeeded) if (!result.Succeeded)

@ -54,7 +54,11 @@ namespace DS.WMS.Core.Op.Method.TaskInteraction.ActionExecutor.SpaceRelease
} }
result.Data.Order = result2.Data; result.Data.Order = result2.Data;
var model = new MailTemplateModel<OpBusinessYardRes>(result.Data) { BusinessId = context.TaskInfo.BusinessId }; var model = new MailTemplateModel<OpBusinessYardRes>(result.Data)
{
BusinessId = context.TaskInfo.BusinessId,
BusinessType = context.TaskInfo.BusinessType,
};
MailService mailService = new(context.ServiceProvider); MailService mailService = new(context.ServiceProvider);
var result3 = await mailService.SendAsync(mailConfig, model); var result3 = await mailService.SendAsync(mailConfig, model);
if (!result3.Succeeded) if (!result3.Succeeded)

@ -1,4 +1,4 @@
@* @model DS.Module.Core.Data.MailTemplateModel<DS.WMS.Core.Op.Dtos.SeaExportRes> *@ @* @model DS.WMS.Core.Op.Entity.MailTemplateModel<DS.WMS.Core.Op.Dtos.SeaExportRes> *@
@{ @{
var item = Model.Primary; var item = Model.Primary;
} }

@ -0,0 +1,32 @@
@model DS.WMS.Core.Op.Entity.MailTemplateModel<DS.WMS.Core.Op.Dtos.OpBusinessYardRes>
@{
var item = Model.Primary;
}
<style>
.parent {
position: relative;
height: 300px;
width: 300px;
}
.child {
position: absolute;
bottom: 0;
right: 0;
width: 50px;
height: 50px;
}
</style>
<h1>测试邮件-@item.Order.MBLNO<span style="padding: 2px"></span>@item.Order.CustomerNo</h1>
<div>
<span>预计开船日期:@item.Order.ETD</span>
<span>预计抵达日期:@item.Order.ETA</span>
</div>
<hr />
<div class="parent">
<div id="sign" class="child"></div>
</div>
Loading…
Cancel
Save