diff --git a/lambda/MAS/Views/DailyEmail.cshtml b/lambda/MAS/Views/DailyEmail.cshtml index 197d0e4b..94260d91 100644 --- a/lambda/MAS/Views/DailyEmail.cshtml +++ b/lambda/MAS/Views/DailyEmail.cshtml @@ -5,32 +5,106 @@ //Layout = "~/Views/Shared/_EmailLayout.cshtml"; var groupedItems = Model.GroupBy(x => x.EvidenceType.Title).ToList(); + var specialitiesList = Model.SelectMany(x => x.Specialities).Select(x => x.Title).ToList(); + var specialitiesAsString = String.Join(',', specs); } -

DailyEmail

+ + + + + + +
+ + + + + + + +
+

+ *|INTERESTED:Daily specialities of interest:@specialitiesAsString|* + Articles that match your chosen specialities today + *|ELSE|* + No articles match your chosen specialities today + *|END:INTERESTED|* + - Edit your subscription +

+
+
- @foreach (var group in groupedItems) + +@foreach (var group in groupedItems) +{ + var evidenceType = group.Key; + + @:*| INTERESTED:Daily specialities of interest:specialitiesAsString | * + + + + + + +
+

evidenceType

+
+ + @foreach (var item in group) { - var evidenceType = group.Key; - -
- @evidenceType - - @foreach (var item in group) - { -
- @item.Title -
- @item.Source.Title -
- @String.Join(" | ", item.Specialities.Select(x => x.Title)) -
- @item.ShortSummary -
- SPS Comment -
- } -
+ @:*| INTERESTED:Daily specialities of interest:specialitiesAsString | * + + + + + + +
+ + + + + + + +
+

@item.Title

+

@item.ShortSummary

+

Read SPS commentary

+ +
+
+ @:*| END:INTERESTED | * } +@:*| END:INTERESTED | * +} + + + + + + + +
+ + + + + + + +
+

+ All articles from Medicines awareness services: Daily edition +

+
+