Köp för 600 SEK och få fri leverans!

Köp för 600 SEK och få fri leverans!

Exception in template (Designs/Robens/Paragraph/RBMediaRibbonItem.cshtml): System.NullReferenceException: Object reference not set to an instance of an object.
   at OaseOutdoors.Services.UrlParserService.UrlParserService.GetEmbedUrl(String url) in C:\projects\oase\src\Services\UrlParserService\UrlParserService.cs:line 97
   at OaseOutdoors.Components.Robens.Paragraphs.RBMediaRibbon.ModelBuilders.RBMediaRibbonViewModelBuilder.GetViewModel(ParagraphViewModel entity) in C:\projects\oase\src\Components\Robens\Paragraphs\RBMediaRibbon\ModelBuilders\RBMediaRibbonModelBuilder.cs:line 22
   at CompiledRazorTemplates.Dynamic.cbefeadfbdabfaf.Execute()
   at RazorEngine.Templating.TemplateBase.RazorEngine.Templating.ITemplate.Run(ExecuteContext context) in c:\Users\abbottm\Documents\GitHub\RazorEngine\src\Core\RazorEngine.Core\Templating\TemplateBase.cs:line 126
   at RazorEngine.Templating.TemplateService.Run(ITemplate template, DynamicViewBag viewBag) in c:\Users\abbottm\Documents\GitHub\RazorEngine\src\Core\RazorEngine.Core\Templating\TemplateService.cs:line 608
   at RazorEngine.Templating.TemplateService.Parse(String razorTemplate, Object model, DynamicViewBag viewBag, String cacheName) in c:\Users\abbottm\Documents\GitHub\RazorEngine\src\Core\RazorEngine.Core\Templating\TemplateService.cs:line 439
   at RazorEngine.Razor.Parse[T](String razorTemplate, T model, DynamicViewBag viewBag, String cacheName) in c:\Users\abbottm\Documents\GitHub\RazorEngine\src\Core\RazorEngine.Core\Razor.cs:line 290
   at Dynamicweb.Rendering.Template.RenderRazorTemplate()
@using Dynamicweb.Extensibility; @using Dynamicweb.Frontend; @using Dynamicweb.Rendering; @using OaseOutdoors.Components.Robens.Paragraphs.RBMediaRibbon.ModelBuilders @using OaseOutdoors.Services.ImageService.Enums @using OaseOutdoors.Services.ImageService.Initialization @using OaseOutdoors.Services.StaticResourceService.Initialization @inherits ViewModelTemplate<ParagraphViewModel> @{ var viewModelService = new RBMediaRibbonViewModelBuilder(); var staticResourceService = ServiceLocator.Current.GetStaticResourceService(); var imageService = ServiceLocator.Current.GetImageService(); var viewModel = viewModelService.GetViewModel(Model); string linkType = "_self"; if (viewModel.OpeninSeprateWindow) { linkType = "_blank"; } } <section class="ribbon media media--@viewModel.MediaType media--@viewModel.ContentDirection media--@viewModel.BackgroundColor container-ribbon"> <div class="container"> <figure> <div class="media__showcase"> @if (viewModel.MediaType == "video" && !string.IsNullOrEmpty(viewModel.YoutubeEmbedUrl)) { <div> <div class="video-container"> <iframe src="@(viewModel.YoutubeEmbedUrl)?rel=0&amp;showinfo=0" frameborder="0" allowfullscreen></iframe> </div> </div> } else if (viewModel.MediaType == "image" && viewModel.Image != null) { var image = imageService.Begin(viewModel.Image); <div class="lazy-bg" data-src-xxs="@image.SetWidth(600).SetCompression(80).SetCrop(CropType.KeepAspectRatio).GetCrop()" data-src-xs="@image.SetWidth(904).SetCompression(80).SetCrop(CropType.KeepAspectRatio).GetCrop()" data-src-sm="@image.SetWidth(1480).SetCompression(80).SetCrop(CropType.KeepAspectRatio).GetCrop()" data-src-md="@image.SetWidth(1920).SetCompression(80).SetCrop(CropType.Center).GetCrop()"> @if (!string.IsNullOrEmpty(viewModel.MediaLink)) { <a href="@viewModel.MediaLink" ></a> } </div> } </div> <figcaption class="media__text"> @if (viewModel.BackgroundImage != null) { var backgroundImage = imageService.Begin(viewModel.BackgroundImage); <div class="lazy-bg" data-src-xxs="@backgroundImage.SetWidth(904).SetCompression(80).SetCrop(CropType.KeepAspectRatio).GetCrop()" data-src-xs="@backgroundImage.SetWidth(1480).SetCompression(80).SetCrop(CropType.KeepAspectRatio).GetCrop()" data-src-sm="@backgroundImage.SetWidth(1928).SetCompression(80).SetCrop(CropType.Center).GetCrop()" data-src-md="@backgroundImage.SetWidth(835).SetCompression(80).SetCrop(CropType.Center).GetCrop()"> </div> } <div> @if (!string.IsNullOrEmpty(viewModel.Headline)) { <h2>@viewModel.Headline <span class="line"></span></h2> } @if (!string.IsNullOrEmpty(viewModel.Manchet)) { <h3>@viewModel.Manchet</h3> } @if (!string.IsNullOrEmpty(viewModel.BodyText)) { @viewModel.BodyText } @if (!string.IsNullOrEmpty(viewModel.Link) && !string.IsNullOrEmpty(viewModel.LinkTitle)) { <a href="@viewModel.Link" target="@linkType" class="btn"><span class="btn__text">@viewModel.LinkTitle</span></a> } </div> </figcaption> </figure> </div> </section>

Klondike

Kiowa

Fairbanks