Organisaties

in Twente
Maps

Zoeken naar een

Filters
Organisatie vacatures
Organisaties met vacatures
Gemeente
{{ municipality }}
Er zijn geen organisaties gevonden
Error executing template "Designs/TwenteBranding/QueryPublisher/JobOfferArticleList.cshtml"
System.InvalidOperationException: Unable to render view model template because no view model has been set.
at Dynamicweb.Rendering.RazorTemplateRenderingProvider.Render(Template template)
at Dynamicweb.Rendering.TemplateRenderingService.Render(Template template)
at Dynamicweb.Rendering.Template.RenderRazorTemplate()

1 @using Dynamicweb.Core 2 @using TwenteBranding.Data.Entities 3 @using TwenteBranding.Repository.Helpers 4 @inherits Dynamicweb.Rendering.RazorTemplateBase<Dynamicweb.Rendering.RazorTemplateModel<Dynamicweb.Rendering.Template>> 5 @{ 6 var culture = GetGlobalValue("Global:Area.LongLang"); 7 8 var totalPages = GetValue("QueryPublisher:Items.Paging.TotalPages"); 9 10 #region QueryStringHandling 11 var textFilterQueryStringParameter = Translate("QueryStringParameter_JobOfferText", "t").UrlEncode(); 12 var textFilter = System.Web.HttpContext.Current.Request.QueryString.Get(textFilterQueryStringParameter); 13 14 var jobProductFilterQueryStringParameter = Translate("QueryStringParameter_JobOfferJobProduct", "j").UrlEncode(); 15 var jobProductFilter = System.Web.HttpContext.Current.Request.QueryString.Get(jobProductFilterQueryStringParameter); 16 17 var disciplineFilterQueryStringParameter = Translate("QueryStringParameter_JobOfferDiscipline", "d").UrlEncode(); 18 var disciplineFilter = System.Web.HttpContext.Current.Request.QueryString.Get(disciplineFilterQueryStringParameter); 19 20 var educationalAttainmentFilterQueryStringParameter = Translate("QueryStringParameter_EducationalAttainment", "e").UrlEncode(); 21 var educationalAttainmentFilter = System.Web.HttpContext.Current.Request.QueryString.Get(educationalAttainmentFilterQueryStringParameter); 22 23 var isCollapsedString = System.Web.HttpContext.Current.Request.QueryString.Get("collapsed"); 24 var isCollapsed = false; 25 bool.TryParse(isCollapsedString, out isCollapsed); 26 27 var searched = !string.IsNullOrWhiteSpace(textFilter) || 28 !string.IsNullOrWhiteSpace(jobProductFilter) || 29 !string.IsNullOrWhiteSpace(disciplineFilter) || 30 !string.IsNullOrWhiteSpace(educationalAttainmentFilter); 31 #endregion 32 33 #region FilterValues 34 var jobProducts = ItemHelper.GetJobProducts(culture); 35 var disciplines = ItemHelper.GetJobDisciplines(culture); 36 var educationalAttainments = ItemHelper.GetEducationalAttainments(culture); 37 var searchedByExtended = ((!string.IsNullOrWhiteSpace(jobProductFilter) || !string.IsNullOrWhiteSpace(disciplineFilter) | !string.IsNullOrWhiteSpace(educationalAttainmentFilter)) && !isCollapsed); 38 var showExtendedSearch = (searchedByExtended || jobProducts != null || disciplines != null | educationalAttainments != null); 39 #endregion 40 41 //var items = GetLoop("ItemPublisher:Items.List"); 42 var items = GetLoop("QueryResultItem"); 43 44 if (items != null && items.Any()) 45 { 46 var currentAreaId = GetGlobalValue("Global:Area.ID"); 47 var currentPageId = GetGlobalValue("Global:Page.ID"); 48 49 var twenteBrandingItems = ItemHelper.GetTwenteBrandingItemsFromQueryPublisherLoopItems(items, currentPageId, culture, currentAreaId, true, true, TwenteBranding.Models.Constants.QueryPublisherSortEnum.QueryPublisherSort); 50 51 // todo : liquid Filter 52 53 if (twenteBrandingItems != null && twenteBrandingItems.Any()) 54 { 55 var index = 1; 56 foreach (var item in twenteBrandingItems) 57 { 58 var title = item.Title; 59 var text = item.Text; 60 var hashtag = item.MainHashtag.IsNotNullOrEmpty() ? item.MainHashtag : item.MainHashtagEnglish; 61 var earthIsCalling = item.EarthIsCalling; 62 var detailsUrl = item.DetailsUrl; 63 var backgroundStyle = item.BackgroundStyle; 64 var backgroundImage = item.Image; 65 66 var goalName = item.GoalName; 67 var goalGradientCss = item.GoalGradientCss; 68 var goalIcon = item.GoalIcon; 69 var goalType = item.GoalType; 70 var goalClass = !string.IsNullOrWhiteSpace(detailsUrl) ? item.ClassName : string.Format("{0} no-link", item.ClassName); 71 var goalUrl = item.GoalUrl; 72 73 var jobProduct = item.JobProduct; 74 var jobDiscipline = item.JobDiscipline; 75 var jobEducationalAttainment = item.JobEducationalAttainment; 76 var jobIntro = item.JobIntro; 77 var jobIntroInformationShort = item.JobIntroInformationShort; 78 var jobCompanyLogo = item.JobCompanyLogo; 79 jobCompanyLogo = $"/Admin/Public/GetImage.ashx?Image={jobCompanyLogo}&Format=webp&Width=200&Height=-1&Quality=100&Crop=0&t=2"; 80 var jobIsFeatured = item.JobIsFeatured; 81 var jobCompanyIsPartner = item.JobCompanyIsPartner; 82 83 var fontColor = string.IsNullOrWhiteSpace(item.HeaderFontColor) ? "font-color--white" : item.HeaderFontColor; 84 85 switch (goalType) 86 { 87 case TwenteBranding.Models.Constants.StringConstants.ItemInstanceType.CallToActionArticle: 88 @inherits Dynamicweb.Rendering.ViewModelTemplate<TwenteBranding.Models.ViewModels.TwenteBrandingItemModel> 89 @TwenteBranding.Repository.Helpers.ItemHelper.GetCtaHtml( 90 Model.ClassName, 91 Model.BackgroundStyle, 92 Model.Image, 93 Model.DetailsUrl, 94 Model.Text, 95 $"global-goal-indicator {Model.GoalGradientClass}", 96 TwenteBranding.Repository.Helpers.ItemHelper.GetTileIconLink(Model.GoalIconHeader, Model.GoalUrl)) 97 break; 98 default: 99 100 if (item.IsPartnerItem) 101 { 102 goalClass += " partner-item"; 103 } 104 105 if (!jobIsFeatured) 106 { 107 @using TwenteBranding.Repository.Helpers 108 @inherits Dynamicweb.Rendering.ViewModelTemplate<TwenteBranding.Models.ViewModels.TwenteBrandingItemModel> 109 @{ 110 <div class="item-container item-clickable item-jobofferarticle @Model.GoalGradientClass default"> 111 <div class="item"> 112 <div class="item-content"> 113 <div class="item-content-text"> 114 <h2 class="joboffer-title font-color--black"> 115 <a class="item-link" href="@Model.DetailsUrl">@Model.Title</a> 116 </h2> 117 118 @{ 119 if (Model.JobProduct != null || Model.JobDiscipline != null || Model.JobEducationalAttainment != null) 120 { 121 var jobOfferInfo = ItemHelper.CreateJobOfferInfoLine( 122 AreaHelper.GetCurrentArea().Culture, 123 Model.JobProduct, 124 Model.JobDiscipline, 125 Model.JobEducationalAttainment, 126 Model.JobIsFeatured 127 ); 128 129 <div class="joboffer-intro font-color--black"> 130 @jobOfferInfo 131 @Model.JobIntroInformationShort 132 </div> 133 134 if (!string.IsNullOrWhiteSpace(Model.JobCompanyLogo) && Model.JobCompanyIsPartner) 135 { 136 <div class="joboffer-companylogo"> 137 <img alt="logo @Model.Title.UrlEncode()" class="lazy" data-src="@Model.JobCompanyLogo" /> 138 </div> 139 } 140 } 141 } 142 </div> 143 </div> 144 </div> 145 </div> 146 } 147 } 148 else 149 { 150 @using TwenteBranding.Repository.Helpers 151 @inherits Dynamicweb.Rendering.ViewModelTemplate<TwenteBranding.Models.ViewModels.TwenteBrandingItemModel> 152 @{ 153 <div class="item-container item-clickable item-jobofferfeaturedarticle featured @Model.ClassName"> 154 <div class="item lazy" style="@Model.BackgroundStyle" data-src="@Model.Image"> 155 156 @if (!string.IsNullOrWhiteSpace(Model.JobCompanyLogo)) 157 { 158 <div class="joboffer-companylogo"> 159 <img alt="logo @Model.Title" class="lazy" data-src="@Model.JobCompanyLogo" /> 160 </div> 161 } 162 else 163 { 164 <div class="joboffer-companylogo"></div> 165 } 166 167 <div class="item-content"> 168 <div class="item-content-text"> 169 170 <h2 class="joboffer-title font-color-joboffer"> 171 <a class="item-link" href="@Model.DetailsUrl"> 172 @Model.Title 173 </a> 174 </h2> 175 176 @{ 177 var jobOfferInfo = ItemHelper.CreateJobOfferInfoLine( 178 AreaHelper.GetCurrentArea().Culture, 179 Model.JobProduct, 180 Model.JobDiscipline, 181 Model.JobEducationalAttainment, 182 Model.JobIsFeatured 183 ); 184 185 <div class="joboffer-info font-color-joboffer"> 186 @jobOfferInfo 187 @Model.JobIntroInformationShort 188 </div> 189 } 190 </div> 191 <div class="no-gradient"></div> 192 </div> 193 </div> 194 </div> 195 } 196 } 197 break; 198 } 199 index++; 200 } 201 } 202 } 203 204 if (items != null && items.Any() || searched) 205 { 206 @SnippetStart("Paging") 207 var prev = GetString("DwPaging.PreviousPageLink"); 208 var curr = GetInteger("DwPaging.CurrentPage"); 209 var total = GetInteger("DwPaging.PageCount"); 210 var next = GetString("DwPaging.NextPageLink"); 211 212 var allowPrev = curr == 1 ? "disabled" : ""; 213 var allowNext = curr == total ? "disabled" : ""; 214 215 <div class="paging"> 216 <a class="paging-prev button red button-small @allowPrev" href=@prev>@Translate("Paging_Prev", "Vorige")</a> 217 <span class="counter">@curr - @total</span> 218 <a class="paging-next button red button-small @allowNext" href=@next>@Translate("Paging_Next", "Volgende")</a> 219 </div> 220 @SnippetEnd("Paging") 221 222 @SnippetStart("ListFilter") 223 <div class="container filter-container no-horizontal-padding"> 224 <div class="input-group search-bar"> 225 <input type="text" class="form-control" name="textfilter-joboffer" id="textfilter-joboffer" placeholder="@Translate("JobOffers_TextFilterPlaceholder", "Bedrijf, functie, plaats, trefwoord")" value="@textFilter" /> 226 <span class="input-group-btn"> 227 <button class="btn btn-default icon--search icon-color--gray-4 icon-size--x1" type="button"></button> 228 </span> 229 </div> 230 @if (showExtendedSearch) 231 { 232 <div> 233 <button class="btn-filter-extended icon--menu-arrow-down icon-size--x1" type="button" data-toggle="collapse" data-target="#filter-extended-search" aria-expanded="@searched.ToString().ToLower()" aria-controls="filter-extended-search">@Translate("JobOffers_ExtendedSearchButtonText", "Uitgebreid zoeken")</button> 234 </div> 235 } 236 @if (searched) 237 { 238 <div class="d-none d-md-block col-md-4"> 239 <button class="btn btn-default icon--reset icon-color--gray-4 icon-size--x3 reset" type="button"></button> 240 </div> 241 } 242 </div> 243 @SnippetEnd("ListFilter") 244 245 @SnippetStart("ListFilterExtended") 246 <div class="@(!searchedByExtended ? "collapse": "collapse show")" id="filter-extended-search"> 247 <div class="container extended-filter-container"> 248 @if (jobProducts != null) 249 { 250 <h3>@Translate("JobOffers_JobProducts", "Soort vacatures")</h3> 251 <div class="grid extended-filter-grid cols-3"> 252 @foreach (var jobProduct in jobProducts) 253 { 254 var id = string.Format("JobProducts_{0}", jobProduct.ValueSystemName); 255 var isChecked = !string.IsNullOrWhiteSpace(jobProductFilter) && jobProductFilter.UrlDecode().Contains(jobProduct.ValueSystemName); 256 <div class="form-check"> 257 <input class="form-check-input" type="checkbox" value="@jobProduct.ValueSystemName" id="@jobProduct.ValueSystemName" name="JobProduct" @(isChecked ? "checked" : "")> 258 <label class="form-check-label" for="@jobProduct.ValueSystemName">@jobProduct.DefaultValue</label> 259 </div> 260 } 261 </div> 262 } 263 264 @if (disciplines != null) 265 { 266 <h3>@Translate("JobOffers_Disciplines", "Vakgebied")</h3> 267 <div class="grid extended-filter-grid cols-3"> 268 @foreach (var discipline in disciplines) 269 { 270 var id = string.Format("Discipline_{0}", discipline.ValueSystemName); 271 var isChecked = !string.IsNullOrWhiteSpace(disciplineFilter) && disciplineFilter.UrlDecode().Contains(discipline.ValueSystemName); 272 <div class="form-check"> 273 <input class="form-check-input" type="checkbox" value="@discipline.ValueSystemName" id="@discipline.ValueSystemName" name="Discipline" @(isChecked ? "checked" : "")> 274 <label class="form-check-label" for="@discipline.ValueSystemName">@discipline.DefaultValue</label> 275 </div> 276 } 277 </div> 278 } 279 280 @if (educationalAttainments != null) 281 { 282 <h3>@Translate("JobOffers_EducationalAttainments", "Opleidingsniveau")</h3> 283 <div class="grid extended-filter-grid cols-3"> 284 @foreach (var educationalAttainment in educationalAttainments) 285 { 286 var id = string.Format("EducationalAttainment_{0}", educationalAttainment.ValueSystemName); 287 var isChecked = !string.IsNullOrWhiteSpace(educationalAttainmentFilter) && educationalAttainmentFilter.UrlDecode().Contains(educationalAttainment.ValueSystemName); 288 <div class="form-check"> 289 <input class="form-check-input" type="checkbox" value="@educationalAttainment.ValueSystemName" id="@educationalAttainment.ValueSystemName" name="EducationalAttainment" @(isChecked ? "checked" : "")> 290 <label class="form-check-label" for="@educationalAttainment.ValueSystemName">@educationalAttainment.DefaultValue</label> 291 </div> 292 } 293 </div> 294 } 295 <div class="filter-buttons"> 296 <button class="btn-filter-show">@Translate("JobOffers_ShowResultsButtonText", "Toon resultaten")</button> 297 <button class="btn-filter-clear">@Translate("JobOffers_ClearFiltersButtonText", "Wis filters")</button> 298 </div> 299 </div> 300 </div> 301 @SnippetEnd("ListFilterExtended") 302 303 @SnippetStart("JavascriptBottom") 304 <script> 305 306 var jobProductFilter = []; 307 var disciplineFilter = []; 308 var educationalAttainmentFilter = []; 309 310 //For the call to action tiles 311 $(".detail-grid-container").addClass("joboffer-grid"); 312 313 function ResetJobOffersFilters() { 314 315 // todo: set loading icon? 316 317 var resetUrl = "/Default.aspx?ID=@GetGlobalValue("Global:Page.ID")"; 318 document.location = resetUrl; 319 } 320 321 function FilterJobOffers() { 322 323 // todo: set loading icon? 324 325 var filterText = $("#textfilter-joboffer").val(); 326 327 var filterUrl = "/Default.aspx?ID=@GetGlobalValue("Global:Page.ID")"; 328 329 if (filterText !== "") { 330 filterUrl += "&@textFilterQueryStringParameter="; 331 filterUrl += filterText; 332 } 333 if (jobProductFilter.length !== 0) { 334 filterUrl += "&@jobProductFilterQueryStringParameter="; 335 filterUrl += jobProductFilter; 336 } 337 if (disciplineFilter.length !== 0) { 338 filterUrl += "&@disciplineFilterQueryStringParameter="; 339 filterUrl += disciplineFilter; 340 } 341 if (educationalAttainmentFilter.length !== 0) { 342 filterUrl += "&@educationalAttainmentFilterQueryStringParameter="; 343 filterUrl += educationalAttainmentFilter; 344 } 345 346 document.location = filterUrl; 347 } 348 349 $('#textfilter-joboffer').bind("enterKey", function (e) { 350 FilterJobOffers(); 351 }); 352 353 $('#textfilter-joboffer').keyup(function (e) { 354 if (e.keyCode === 13) { 355 $(this).trigger("enterKey"); 356 } 357 }); 358 359 $(".search-bar button").off("click").on("click", function () { 360 FilterJobOffers(); 361 }); 362 363 $(".btn-filter-show").off("click").on("click", function () { 364 365 jobProductFilter = []; 366 $('input[name=JobProduct]:checked', ".extended-filter-container").each(function () { 367 jobProductFilter.push(this.value); 368 }); 369 370 disciplineFilter = []; 371 $('input[name=Discipline]:checked', ".extended-filter-container").each(function () { 372 disciplineFilter.push(this.value); 373 }); 374 375 educationalAttainmentFilter = []; 376 $('input[name=EducationalAttainment]:checked', ".extended-filter-container").each(function () { 377 educationalAttainmentFilter.push(this.value); 378 }); 379 380 FilterJobOffers(); 381 }); 382 383 $("button.reset").off("click").on("click", function () { 384 ResetJobOffersFilters() 385 }); 386 </script> 387 @SnippetEnd("JavascriptBottom") 388 } 389 }

Meld je aan voor de jobalert en ontvang vacatures die bij jou passen