Exception in template (Designs\SkanskaMaskin\Paragraph\_form_retur.cshtml): System.NullReferenceException: Object reference not set to an instance of an object.
   at Softgear.SkanskaMaskin.Data.Entities.Rental.Return.renderReturnForm() in C:\Dev\Skanskamaskin\main\Softgear.SkanskaMaskin.Data\Entities\Rental\Return.cs:line 22
   at CompiledRazorTemplates.Dynamic.ebbdbafaaedfa.Execute()
   at RazorEngine.Templating.TemplateBase.RazorEngine.Templating.ITemplate.Run(ExecuteContext context)
   at RazorEngine.Razor.Parse[T](String razorTemplate, T model, String cacheName)
   at Dynamicweb.Rendering.Template.Output()
@inherits Dynamicweb.Rendering.RazorTemplateBase<Dynamicweb.Rendering.RazorTemplateModel<Dynamicweb.Rendering.Template>> @using Softgear.SkanskaMaskin.Data.Business @using Softgear.SkanskaMaskin.Data.Entities.Rental @using Softgear.SkanskaMaskin.Data.Helper @{ var hbh = new HandleBarsHelper(); var customerCenters = CacheManager.GetFromCache<Dynamicweb.Modules.UserManagement.UserCollection>(60, "customerCentersGroup4", () => Dynamicweb.Modules.UserManagement.User.GetUsersByGroupID(4)); var choose = new Dynamicweb.Modules.UserManagement.User(); var storeList = (from user in customerCenters.Where(y => y.Active) select new { value = Convert.ToString(user.ID), text = user.Name }).OrderBy(x => x.text).ToList(); storeList.Insert(0, new { value = "", text = Translate("Choose_KC", "Välj kundcenter") }); var storesData = new { baseUrl = "/service/storeinfo?storeid=", name = "store", required = "required", className = "Control--light", items = storeList.ToArray() }; var project = ProjectManager.getProject(AccountManager.getActiveProjectCode()); var returnForm = new Return(project); } <form action="/dashboard/returer/ny" method="get"> <div class="Grid Grid--equalPush"> <div class="Grid-cell"> <div class="Grid Grid--withGutter"> <div class="Grid-cell u-sizeFull"> <div class="Type"> <h2 class="Type-h1">Bekräfta och beställ retur</h2> </div> </div> <div class="Grid-cell u-sizeFull u-md-size1of2 u-lg-size1of2"> Välj kundcenter </div> <div class="Grid-cell u-sizeFull u-md-size1of2 u-lg-size1of2"> @hbh.render("control/index.hbs", storesData) </div> </div> </div> <div class="Grid-cell"> <div class="Grid Grid--withGutter"> <div class="Grid-cell u-sizeFull"> @returnForm.renderSummary() </div> </div> </div> <div class="Grid-cell"> <div class="Grid Grid--withGutter"> <div class="Grid-cell"> <div class="Byline"> @returnForm.renderReturnForm() </div> </div> </div> </div> <div class="Grid-cell"> <div class="Grid Grid--withGutter"> <div class="Grid-cell u-sizeFull"> <div class="Type"> <h3 class="Type-h3">Övrig information</h3> </div> </div> <div class="Grid-cell u-sizeFull"> <div class="Input Input--fill"> <label for="return-message" class="Input-label">Meddelande</label> <textarea id="return-message" class="Input-textarea js-formInputField" name="return-message" data-controller="form-input" rows="3" style="overflow: hidden; word-wrap: break-word; resize: horizontal; height: 97px;"> </textarea> </div> </div> </div> </div> <input type="hidden" name="project" value="58460"> <div class="Grid-cell"> <div class="Grid Grid--withGutter"> <div class="Grid-cell u-size1of2 u-textLeft"> <button class="Button Button--tertiary js-overlayClose" type="submit">Avbryt</button> </div> <div class="Grid-cell u-size1of2 u-textRight"> <button class="Button" type="submit">Beställ retur</button> </div> </div> </div> </div> </form>