diff --git a/Childrens-Social-Care-CPD/Contentful/Models/VideoResource.cs b/Childrens-Social-Care-CPD/Contentful/Models/VideoResource.cs index a07fc6cb..706384c0 100644 --- a/Childrens-Social-Care-CPD/Contentful/Models/VideoResource.cs +++ b/Childrens-Social-Care-CPD/Contentful/Models/VideoResource.cs @@ -7,4 +7,5 @@ public class VideoResource : IContent public string Id { get; set; } public Asset Video { get; set; } public Document Transcript { get; set; } + public string EmbeddedSourceUrl { get; set; } } diff --git a/Childrens-Social-Care-CPD/Views/Shared/_VideoResource.cshtml b/Childrens-Social-Care-CPD/Views/Shared/_VideoResource.cshtml index 30da1af6..84f35001 100644 --- a/Childrens-Social-Care-CPD/Views/Shared/_VideoResource.cshtml +++ b/Childrens-Social-Care-CPD/Views/Shared/_VideoResource.cshtml @@ -8,9 +8,29 @@
- + @if(!string.IsNullOrEmpty(Model.EmbeddedSourceUrl)) + { + if (@Model.EmbeddedSourceUrl.IndexOf("vimeo") > -1) + { + + } + else + { + + } + } + else + { + + } +
View transcript
@@ -19,5 +39,7 @@ }
+ +
\ No newline at end of file