Error compiling template "Designs/Fusion/_parsed/LoginwithImpersonation.parsed.cshtml"
Line 1475: 'Dynamicweb.Security.UserManagement.User' does not contain a definition for 'UserID' and no extension method 'UserID' accepting a first argument of type 'Dynamicweb.Security.UserManagement.User' could be found (are you missing a using directive or an assembly reference?)

1 @inherits RazorTemplateBase<RazorTemplateModel<Template>> 2 @using Dynamicweb.Rendering; 3 @using System.Text.RegularExpressions; 4 @using System.Web; 5 @using Dynamicweb.Environment; 6 7 @helper RenderScripts(string location) 8 { 9 //possible location values: header, body, footer; 10 //posible scope: tracking, marketing, preferences, functional; 11 //possible cookie option values; 12 //no cookies = 0; 13 //functional only=1; 14 //all=2; 15 //marketing = 3; 16 //tracking = 4; 17 //preferences = 5; 18 //Item.Area.Tracking.Code; 19 //Item.Area.Tracking.Location; 20 //Item.Area.Tracking.Scope; 21 //cookie=Dynamicweb.CookieOptInLevel; 22 //Functional; 23 //None; 24 //All; 25 CookieOptInLevel level = CookieManager.GetCookieOptInLevel(); 26 int x = (int)level; 27 string[] allowedFunctional = {"functional"}; 28 string[] allowedTracking = {"functional","tracking"}; 29 string[] allowedMarketing = {"functional","marketing","tracking"}; 30 string[] allowedScope = {"functional"}; 31 switch(x) 32 { 33 case 0: 34 allowedScope = allowedFunctional; 35 break; 36 case 1: 37 allowedScope = allowedTracking; 38 break; 39 case 2: 40 allowedScope = allowedMarketing; 41 break; 42 default: 43 allowedScope = allowedFunctional; 44 break; 45 } 46 47 if(!string.IsNullOrEmpty(location) && x > 0){ 48 var trackingScripts = GetLoop("Item.Area.Tracking").Where(a=>a.GetString("Item.Area.Tracking.Location") == location); 49 trackingScripts = trackingScripts.Where(z=>allowedScope.Any(y=>y == z.GetString("Item.Area.Tracking.Scope"))); 50 foreach(var trackingScript in trackingScripts){ 51 <text>@trackingScript.GetString("Item.Area.Tracking.Code")</text> 52 } 53 } 54 55 56 } 57 58 59 @functions { 60 private string CommaSplittedString(string CommaSplittedString, string NewString) 61 { 62 63 if (!string.IsNullOrEmpty(CommaSplittedString)) 64 { 65 CommaSplittedString += ", "; 66 } 67 CommaSplittedString = NewString; 68 69 return CommaSplittedString; 70 } 71 public static string StripHtml(string source) 72 { 73 return Regex.Replace(source, "<.*?>", string.Empty); 74 } 75 76 77 78 79 80 81 82 83 } 84 <!DOCTYPE html> 85 <!--[if lt IE 7]> <html class="no-js lt-ie9 lt-ie8 lt-ie7"> <![endif]--> 86 <!--[if IE 7]> <html class="no-js lt-ie9 lt-ie8"> <![endif]--> 87 <!--[if IE 8]> <html class="no-js lt-ie9"> <![endif]--> 88 <!--[if gt IE 8]> <html class="no-js"> <![endif]--> 89 90 <head> 91 @using Dynamicweb; 92 @using Dynamicweb.Ecommerce.Products; 93 @using Dynamicweb.Security.UserManagement; 94 @using Dynamicweb.Modules.UserManagement; 95 @using Dynamicweb.Frontend; 96 @using System.Web; 97 @using System; 98 @{ 99 var serviceLocator = Dynamicweb.Extensibility.ServiceLocator.Current; 100 var pageService = serviceLocator.GetInstance<Dynamicweb.Content.IPageService>(); 101 102 var DisplayOptions = ""; 103 104 if (!string.IsNullOrEmpty(GetGlobalValue("Global:Item.Page.DisplayOptions").ToString())){ 105 DisplayOptions = (GetGlobalValue("Global:Item.Page.DisplayOptions").ToString() == "wide") ? "container-wide" : ""; 106 } 107 var pageURL = "/Default.aspx?" + System.Web.HttpContext.Current.Request.QueryString; 108 109 110 var currentUserAccess = Dynamicweb.Security.UserManagement.User.GetCurrentExtranetUser(); 111 var user = currentUserAccess; 112 var currentUser = currentUserAccess; 113 bool userIsLoggedIn = currentUser != null; 114 115 string customerNo = userIsLoggedIn ? currentUser.CustomerNumber : ""; 116 117 @*var galleryType = Pageview.Area.Item["Gallery"]; 118 var cartBehaviour = Pageview.Area.Item["CartBehaviour"]; 119 var cart_page_id = Pageview.Area.Item["CartPage_ID"];*@ 120 121 var area = PageView.Current().Area; 122 123 @*var galleryType = PageView.Current().Area.Item["Gallery"]; 124 var cartBehaviour = PageView.Current().Area.Item["CartBehaviour"]; 125 var cart_page_id = PageView.Current().Area.Item["CartPage_ID"];*@ 126 127 @*var currentUser = Dynamicweb.Frontend.PageView.Current().User; 128 var currentUserAccess = Dynamicweb.Modules.UserManagement.User.GetCurrentUser(); 129 var firstPageID = Pageview.Area.get_Value("AreaFirstPage");*@ 130 131 //var firstPageID = Dynamicweb.Frontend.PageView.Current().Area.AreaFirstPage; //PageView.Current().Area.FirstPage; 132 var firstPageID = pageService.GetFirstPageForArea(area.ID); 133 134 var currentPageID = GetGlobalValue("Global:Page.ID"); 135 136 string cartPage = "13"; 137 138 //Rolul userului autentificat 139 int customerRole = -1; 140 141 142 //customer numberul userului autentificat 143 //string customerNo = currentUser.LoggedIn ? currentUser.CustomerNumber.ToString() : null; 144 //string customerNo = currentUserAccess != null ? currentUserAccess.CustomerNumber : null; 145 146 //Id-ul nodului parinte pentru navigatie 147 var navigationParentId = !string.IsNullOrEmpty(customerNo) ? 17 : 17; 148 149 //determina daca navigatia este colapsata sau este vizibila implicit 150 var navigationCollapsed = "category-collapsed"; 151 if (!string.IsNullOrEmpty(GetString("Item.Page.DisplayOptions.Value"))){ 152 navigationCollapsed = GetString("Item.Page.DisplayOptions.Value"); 153 } 154 155 //determina fisierul XSLT folosit pentru randarea navigatiei 156 @*var navigationXSLT = !string.IsNullOrEmpty(customerNo) ? "CategoriesNavigationB2B.xslt" : "CategoriesNavigationB2B.xslt"; 157 var navigationMobileXSLT = !string.IsNullOrEmpty(customerNo) ? "CategoriesNavigationMobileB2B-v2.xslt" : "CategoriesNavigationMobileB2B-v2.xslt";*@ 158 159 //determina daca afisam navigatie pe coloana din stanga sau nu 160 var navigationColumn = 3; 161 162 //determina numarul de coloane al zonei de content 163 var navigationContent = 9; 164 165 //defineste obiect general de tip customer settings 166 //var customerSettings = !string.IsNullOrEmpty(customerNo) ? BrandFusion.Dw.Austral.eCommerce.CustomerFacade.Get(customerNo) : null; 167 var customerSettings = !string.IsNullOrEmpty(customerNo) ? BrandFusion.Dw.Austral.eCommerce.CustomerFacade.Get(customerNo,"aus") : null; 168 169 //Limita lunara totala pentru comenzi 170 var customerMonthlyLimit = customerSettings != null ? customerSettings.MonthlyBudget.GetValueOrDefault() : 0; 171 172 //Ziua de inceput pentru plasarea comenzilor 173 var customerOrderStart = customerSettings != null ? customerSettings.OrderStart.GetValueOrDefault() : 0; 174 175 //Ziua de sfarsit pentru plasarea comenzilor 176 var customerOrderEnd = customerSettings != null ? customerSettings.OrderEnd.GetValueOrDefault() : 0; 177 178 //Ziua de inceput pentru aprobarea comenzilor 179 var customerApprovalStart = customerSettings != null ? customerSettings.ApprovalStart.GetValueOrDefault() : 0; 180 181 //Ziua de sfarsit pentru aprobarea comenzilor 182 var customerApprovalEnd = customerSettings != null ? customerSettings.ApprovalEnd.GetValueOrDefault() : 0; 183 184 //Valoare minima comanda 185 decimal customerMinimumOrderValue = customerSettings != null ? customerSettings.MinimumOrderValue.GetValueOrDefault() : 0; 186 187 //Mesaj pentru comanda minima 188 string customerMinimumOrderMessage = customerSettings != null ? customerSettings.MinimumOrderValueMessage : ""; 189 190 //Ascunde preturile pentru user 191 bool customerHidePrices = false;//customerSettings != null ? customerSettings.HidePrices.GetValueOrDefault() : false; 192 193 194 int todayDay = (int)DateTime.Now.Day; 195 196 197 bool orderAllow = true ; 198 bool approveAllow = true ; 199 200 if (todayDay < customerOrderStart || todayDay > customerOrderEnd){ 201 orderAllow = false; 202 } 203 if (todayDay < customerApprovalStart || todayDay > customerApprovalEnd){ 204 approveAllow = false; 205 } 206 207 208 209 string customerListGroupID = null; 210 211 if(!string.IsNullOrEmpty(customerNo)){ 212 213 customerListGroupID= BrandFusion.Dw.Austral.eCommerce.GroupFacade.GetGroupId(customerNo); 214 customerRole = BrandFusion.Dw.Austral.eCommerce.UserFacade.GetRole(currentUserAccess).GetValueOrDefault(); 215 } 216 217 218 HttpContext.Current.Session["userListView"] = "box"; 219 220 if(System.Web.HttpContext.Current.Request["view"] != null){ 221 HttpContext.Current.Session["userListView"] = System.Web.HttpContext.Current.Request["view"]; 222 } 223 224 string userListView = HttpContext.Current.Session["userListView"].ToString(); 225 226 227 } 228 229 230 <title>@GetValue("Title")</title> 231 @GetValue("MetaTags") 232 @GetValue("CopyRightNotice") 233 234 235 <meta charset="utf-8"> 236 <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1"> 237 238 <meta name="viewport" content="width=device-width, initial-scale=1"> 239 240 @foreach (LoopItem i in GetLoop("Item.Area.Groups")) { 241 if (i.GetString("Item.Area.Group.Name") == "Header") { 242 foreach (LoopItem j in i.GetLoop("Item.Area.Group.Fields")) { 243 <meta name='@j.GetString("Item.Area.Field.Name")' content='@j.GetString("Item.Area.Field.Value")'> 244 } 245 } 246 } 247 @RenderSnippet("Meta") 248 249 <link rel="shortcut icon" href="/Files/Templates/Designs/Fusion/assets/img/favicon.ico"> 250 <link href='//fonts.googleapis.com/css?family=Roboto+Slab:400,300,100,700&subset=latin,latin-ext' rel='stylesheet' type='text/css'> 251 <link href='//fonts.googleapis.com/css?family=Roboto+Condensed:400,700,300' rel='stylesheet' type='text/css'> 252 <link href='//fonts.googleapis.com/css?family=Open+Sans:300italic,400italic,600italic,700italic,800italic,400,300,600,700,800&subset=latin,latin-ext' rel='stylesheet' type='text/css'> 253 <link href='//fonts.googleapis.com/css?family=Source+Sans+Pro:400,200,600,700,900,300&subset=latin,latin-ext' rel='stylesheet' type='text/css'> 254 <link href='//fonts.googleapis.com/css?family=Open+Sans+Condensed:300,700&subset=latin,latin-ext' rel='stylesheet' type='text/css'> 255 <link rel="stylesheet" type="text/css" href="//cdnjs.cloudflare.com/ajax/libs/animate.css/3.5.2/animate.css"> 256 <link rel="stylesheet" type="text/css" href="//cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css"> 257 <link rel="stylesheet" type="text/css" href="//cdnjs.cloudflare.com/ajax/libs/ionicons/2.0.1/css/ionicons.min.css"> 258 <link rel="stylesheet" type="text/css" href="//cdnjs.cloudflare.com/ajax/libs/flexslider/2.6.0/flexslider.min.css"> 259 <link rel="stylesheet" type="text/css" href="//cdnjs.cloudflare.com/ajax/libs/photoswipe/4.1.1/photoswipe.min.css"> 260 <link rel="stylesheet" type="text/css" href="//cdnjs.cloudflare.com/ajax/libs/photoswipe/4.1.1/default-skin/default-skin.min.css"> 261 <link rel="stylesheet" type="text/css" href="//cdnjs.cloudflare.com/ajax/libs/slick-carousel/1.6.0/slick.min.css"> 262 263 264 @* 265 <link rel="stylesheet" type="text/css" href="/Files/Templates/Designs/Fusion/assets/css/main.css"> 266 <link rel="stylesheet" type="text/css" href="/Files/Templates/Designs/Fusion/assets/css/fix.css"> 267 <link rel="stylesheet" type="text/css" href="/Files/Templates/Designs/Fusion/assets/css/main-v2.css"> 268 *@ 269 270 271 <link rel="stylesheet" type="text/css" href="/Files/Templates/Designs/Fusion/assets/css/main-v3.css"> 272 273 274 @* To be deleted *@ 275 <link rel="stylesheet" href="/Files/Templates/Designs/Fusion/assets/css/fix-mobile.css"> 276 <link rel="stylesheet" href="/Files/Templates/Designs/Fusion/assets/css/fixCss.css"> 277 <link rel="stylesheet" type="text/css" href="/Files/Templates/Designs/Fusion/assets/css/fix-transition.css"> 278 279 280 281 282 <!--[if lt IE 9]> 283 <link rel="stylesheet" href="/Files/Templates/Designs/Fusion/assets/css/ie.css" /> 284 <script type="text/javascript" src="/Files/Templates/Designs/Fusion/assets/js/html5shiv.min.js"></script> 285 <script type="text/javascript" src="/Files/Templates/Designs/Fusion/assets/js/respond.min.js"></script> 286 <![endif]--> 287 288 <script type="text/javascript" src="/Files/Templates/Designs/Fusion/assets/js/jquery-1.12.3.min.js"></script> 289 <script type="text/javascript" src="/Files/Templates/Designs/Fusion/assets/js/modernizr-2.7.1.min.js"></script> 290 <script type="text/javascript" src="/Files/Templates/Designs/Fusion/assets/js/modernizr-custom.js"></script> 291 292 @RenderSnippet("Head") 293 294 <!-- Facebook Pixel Code --> 295 <script> 296 !function(f,b,e,v,n,t,s){if(f.fbq)return;n=f.fbq=function(){n.callMethod? 297 n.callMethod.apply(n,arguments):n.queue.push(arguments)};if(!f._fbq)f._fbq=n; 298 n.push=n;n.loaded=!0;n.version='2.0';n.queue=[];t=b.createElement(e);t.async=!0; 299 t.src=v;s=b.getElementsByTagName(e)[0];s.parentNode.insertBefore(t,s)}(window, 300 document,'script','https://connect.facebook.net/en_US/fbevents.js'); 301 302 fbq('init', '1448596761825791'); 303 fbq('track', "PageView");</script> 304 <noscript><img height="1" width="1" style="display:none" src="https://www.facebook.com/tr?id=1448596761825791&ev=PageView&noscript=1"></noscript> 305 <!-- End Facebook Pixel Code --> 306 <script> 307 308 @RenderScripts("header") 309 310 @if(string.IsNullOrEmpty(customerNo)) { 311 <!--Start of Zopim Live Chat Script--> 312 <script type="text/javascript"> 313 window.$zopim||(function(d,s){var z=$zopim=function(c){z._.push(c)},$=z.s= 314 d.createElement(s),e=d.getElementsByTagName(s)[0];z.set=function(o){z.set. 315 _.push(o)};z._=[];z.set._=[];$.async=!0;$.setAttribute('charset','utf-8'); 316 $.src='//v2.zopim.com/?1DEBG92c1wNjRsFQMlxrAGvS8zlr3Ujv';z.t=+new Date;$. 317 type='text/javascript';e.parentNode.insertBefore($,e)})(document,'script'); 318 </script> 319 <!--End of Zopim Live Chat Script--> 320 } 321 <meta name="google-site-verification" content="RC3gdwFLyrYziMTNmlGB9YvN-n-7IDIGCY2rOHAfKQk"> 322 <meta name="google-site-verification" content="HwvHBJZdAxmQVtH4XGXNG_Bl1YmafpX8k7RVNF_v2mo"> 323 @GetValue("Stylesheets") 324 @GetValue("Javascripts") 325 </head> 326 <body data-pageid='@GetGlobalValue("Global:Page.ID")' data-productpage='@GetValue("Item.Area.Catalog_Page")' data-paragraph='@GetValue("Item.Area.InstantSearch_Paragraph")' data-areaid='@GetGlobalValue("Global:Area.ID")'> 327 @RenderScripts("body") 328 <!--[if lt IE 7]> 329 <p class="chromeframe">You are using an <strong>outdated</strong> browser. Please <a href="http://browsehappy.com/">upgrade your browser</a> or <a href="http://www.google.com/chromeframe/?redirect=true">activate Google Chrome Frame</a> to improve your experience.</p> 330 <![endif]--> 331 332 @* @if (Pageview.Device == Dynamicweb.Frontend.PageView.DeviceType.Mobile || Pageview.Device == Dynamicweb.Frontend.PageView.DeviceType.Tablet) { *@ 333 <div class="header-mobile"> 334 <div class="col-xs-12"> 335 <div class="row"> 336 <div class="logo col-xs-6"> 337 <a href="/"> 338 <img src='@GetValue("Item.Area.Logo")' alt='@GetValue("Item.Area.Site_Name")'> 339 </a> 340 </div> 341 <div class="mobile-nav-trigger col-xs-6"> 342 @{ 343 344 System.Globalization.TextInfo myTIMobile = new System.Globalization.CultureInfo("en-US", false).TextInfo; 345 @*string userMobile = Dynamicweb.Frontend.PageView.Current().User.UserName; 346 string userProfileNameMobile = Dynamicweb.Frontend.PageView.Current().User.Name; 347 string userCustomerNumberMobile = Dynamicweb.Frontend.PageView.Current().User.CustomerNumber;*@ 348 var userMobile = Dynamicweb.Security.UserManagement.User.GetCurrentExtranetUser(); 349 var userProfileNameMobile = userMobile; 350 bool userMobileIsLoggedIn = userProfileNameMobile != null; 351 352 string userCustomerNumberMobile = userIsLoggedIn && currentUser.CustomerNumber != null ? currentUser.CustomerNumber.ToString() : null; 353 354 355 356 //string userCustomerNumberMobile = Dynamicweb.Security.UserManagement.User.GetCurrentExtranetUser().CustomerNumber; 357 358 359 string userAccountLinkMobile = "/Default.aspx?ID=9"; 360 string userCartLinkMobile = "/Default.aspx?ID=13"; 361 362 if (!string.IsNullOrEmpty(userCustomerNumberMobile)) { 363 userAccountLinkMobile = "/Default.aspx?ID=170"; 364 userCartLinkMobile = "/Default.aspx?ID=42"; 365 } 366 367 } 368 369 370 371 <button type="button" id="mobile-nav-button"><i class="fa fa-bars"></i></button> 372 <div class="minicart"> 373 <a href="@userCartLinkMobile"> 374 <i class="ion-android-cart"></i> 375 @if (!@GetBoolean("Ecom:Order.IsEmpty")) { 376 <span data-minicart-update="">(0)</span> 377 } else { 378 <span data-minicart-update="">Cosul tau este gol</span> 379 } 380 381 </a> 382 </div> 383 384 @*@if(string.IsNullOrEmpty(userMobile)) {*@ 385 @if(userMobile == null) { 386 <button type="button" class="mobile-header-overlay-trigger"><i class="fa fa-user"></i></button> 387 <div class="mobile-header-overlay animated"> 388 <a href="/Default.aspx?ID=11" class="btn-main animated">@Translate("Intra in cont","Intra in cont")</a> 389 @*<a href="/Default.aspx?ID=10" class="btn-main animated">@Translate("Creeaza cont","Creeaza cont")</a>*@ 390 <button type="button" class="overlay-close"><i class="fa fa-close"></i> @Translate("Inchide","Inchide")</button> 391 </div> 392 393 } else { 394 <button type="button" class="mobile-header-overlay-trigger"><i class="fa fa-user"></i></button> 395 <div class="mobile-header-overlay animated"> 396 <a href="/Admin/Public/ExtranetLogoff.aspx" class="btn-main animated"><i class="fa fa-unlock-alt"></i> @Translate("Logout","Logout")</a> 397 <a href="@userAccountLinkMobile" class="btn-main animated"><i class="fa fa-user"></i> @Translate("Contul meu","Contul meu")</a> 398 <button type="button" class="overlay-close"><i class="fa fa-close"></i> @Translate("Inchide","Inchide")</button> 399 </div> 400 401 } 402 403 404 </div> 405 @if(!string.IsNullOrEmpty(customerNo)) { 406 <div class="search-mobile col-xs-12"><form action="/Default.aspx?ID=127" method="GET"> 407 <div class="form-group"> 408 <input type="text" name="q" id="q-mobile" autocomplete="off" spellcheck="false" placeholder='@Translate("search", "Cauta dupa cod sau nume...")' class="form-control"> 409 @if(!string.IsNullOrEmpty(customerNo) && !string.IsNullOrEmpty(customerListGroupID)){ 410 <input type="hidden" name="CustomerNumber" id="CustomerNumber" value="@customerNo"> 411 } 412 <button type="submit"><i class="ion-ios-search-strong"></i></button> 413 <div class="instant_search"></div> 414 </div> 415 </form></div> 416 } 417 </div> 418 </div> 419 </div> 420 <div id="mobile-navigation-overlay"> 421 <button type="button" class="overlay-close"><i class="fa fa-close"></i> @Translate("Inchide","Inchide")</button> 422 <div class="content-scrollable"> 423 @if(!string.IsNullOrEmpty(customerNo)) { 424 <ul class="root"> 425 <li> 426 <a href="#">Categorii de produse</a> 427 @RenderNavigation(new { 428 template = "CategoriesNavigationMobileB2B-v2.xslt", 429 expandmode = "all", 430 sitemapmode="true", 431 id = "categories", 432 startlevel = 1, 433 endlevel = 5, 434 areaid = 1 435 }) 436 </li> 437 </ul> 438 } 439 440 @if(!string.IsNullOrEmpty(customerNo)) { 441 @RenderNavigation(new { 442 template = "MainNavigationMobile-v2.xslt", 443 expandmode = "all", 444 id = "NavMainMobileAll", 445 startlevel = 2, 446 endlevel = 4, 447 parentid = 169, 448 customerGroup = @customerListGroupID, 449 customerRole = @customerRole 450 }); 451 } else { 452 453 @RenderNavigation(new { 454 template = "MainNavigationMobile-v2.xslt", 455 expandmode = "all", 456 id = "NavMainMobileAll", 457 startlevel = 1, 458 endlevel = 4 459 }); 460 461 } 462 463 </div> 464 465 466 </div> 467 @* } *@ 468 469 <div class="mobile-wrapper"> 470 471 @{ 472 473 System.Globalization.TextInfo myTI = new System.Globalization.CultureInfo("en-US", false).TextInfo; 474 @*string user = Dynamicweb.Frontend.PageView.Current().User.UserName; 475 string userProfileName = Dynamicweb.Frontend.PageView.Current().User.Name; 476 string userCustomerNumber = Dynamicweb.Frontend.PageView.Current().User.CustomerNumber;*@ 477 //string userProfileName = Dynamicweb.Security.UserManagement.User.GetCurrentExtranetUser().Name;throw new Exception("Exceptie 01"); 478 479 480 481 var userProfileName = currentUser; 482 483 bool userLoggedIn = userProfileName != null; 484 485 486 487 488 string userAccountLink = "/Default.aspx?ID=9"; 489 string userCartLink = "/Default.aspx?ID=13"; 490 491 double cartQuantity = GetDouble("Ecom:Order.OrderLines.TotalProductQuantity"); 492 double cartPrice = GetDouble("Ecom:Order.PriceWithoutFees.PriceWithVAT"); 493 string currencyCart = GetString("Ecom:Order.Price.Currency.Symbol"); 494 BrandFusion.Dw.Austral.eCommerce.CustomerAddress customerDetails = null; 495 string customerLogo = ""; 496 497 @*string customerName = Dynamicweb.Frontend.PageView.Current().User != null && !string.IsNullOrEmpty(userProfileName)? userProfileName : "";*@ 498 @*string customerName = currentUserAccess != null && !string.IsNullOrEmpty(userProfileName)? userProfileName : "";*@ 499 string customerName = currentUserAccess != null ? userProfileName.Name.ToString() : ""; 500 501 string userCustomerNumber = userIsLoggedIn && currentUser.CustomerNumber != null ? currentUser.CustomerNumber.ToString() : null; 502 503 504 if(!string.IsNullOrEmpty(userCustomerNumber)) { 505 506 507 cartPrice = GetDouble("Ecom:Order.PriceWithoutFees.PriceWithoutVAT"); 508 } 509 510 if (!string.IsNullOrEmpty(userCustomerNumber)) { 511 512 513 userAccountLink = "/Default.aspx?ID=170"; 514 userCartLink = "/Default.aspx?ID=42"; 515 516 } 517 518 if(!string.IsNullOrEmpty(userCustomerNumber)){ 519 520 521 customerDetails = BrandFusion.Dw.Austral.eCommerce.CustomerFacade.GetB2bBillingAddress(userCustomerNumber); 522 523 if (customerDetails != null) 524 { 525 customerName = customerDetails.Company; 526 customerLogo = !string.IsNullOrEmpty(customerDetails.GeoLocationImage) ? "/Files/Images/Austral/CustomerLogos/"+customerDetails.GeoLocationImage : ""; 527 } 528 } 529 530 } 531 @SnippetStart("Head") 532 533 @SnippetEnd("Head") 534 535 536 <div class="header-top hidden-xs hidden-sm"> 537 <div class="container"> 538 <div class="row"> 539 <div class="col-md-12"> 540 @*@if(!string.IsNullOrEmpty(user)) {*@ 541 @if(userIsLoggedIn) { 542 <ul class="right-align"> 543 @*@if(!string.IsNullOrEmpty(userProfileName)) {*@ 544 @if(userLoggedIn) { 545 <li> 546 @if (string.IsNullOrWhiteSpace(GetGlobalValue("Global:Extranet.SecondaryUser.UserID"))) { 547 <a href="@userAccountLink"> <i class="ion-ios-locked-outline"></i> 548 549 @userProfileName.Name 550 551 @if(!string.IsNullOrEmpty(userCustomerNumber)) { 552 <span>- @userCustomerNumber</span> 553 } 554 555 </a> 556 } else{ 557 <span> 558 <a href="/Default.aspx?ID=3500">@GetGlobalValue("Global:Extranet.SecondaryUser.Name") - (@GetGlobalValue("Global:Extranet.SecondaryUser.UserName")) @Translate("ImpersonatedBy", "este impersonat de") @Pageview.User.Name (@Pageview.User.UserName)</a> 559 </span> 560 } 561 </li> 562 <li><a href="/Admin/Public/ExtranetLogoff.aspx">@Translate("logout", "Logout")</a></li> 563 } 564 565 </ul> 566 } 567 <ul class="left-align"> 568 <li><p>@GetValue("Item.Area.Program")</p></li> 569 570 @if(!string.IsNullOrEmpty(GetString("Item.Area.Telefon"))) { 571 <li><p>@GetValue("Item.Area.Telefon")</p></li> 572 } 573 </ul> 574 575 </div> 576 577 578 579 </div> 580 </div> 581 </div> 582 <div class="header-middle hidden-xs hidden-sm"> 583 <div class="container"> 584 <div class="row"> 585 586 <div id="logo" class="col-sm-3 hidden-xs"> 587 <a href="/"> 588 <img src='@GetValue("Item.Area.Logo")' alt='@GetValue("Item.Area.Site_Name")'> 589 </a> 590 </div> 591 592 <div class="header-search-v2 col-sm-9"> 593 <div class="row"> 594 595 596 <div class="col-sm-6 col-md-5 col-lg-6"> 597 @if(user!=null) { 598 <form action="/Default.aspx?ID=127" method="GET" data-file="search-v2"> 599 <div class="form-group"> 600 <input type="text" name="q" id="q" autocomplete="off" spellcheck="false" placeholder='@Translate("search", "Cauta dupa cod sau nume...")' class="form-control"> 601 <input type="hidden" id="ID" name="ID" value="127"> 602 @if(!string.IsNullOrEmpty(customerNo) && !string.IsNullOrEmpty(customerListGroupID)){ 603 <input type="hidden" name="CustomerNumber" id="CustomerNumber" value="@customerNo"> 604 } 605 <button type="submit"><i class="ion-ios-search-strong"></i></button> 606 <div class="instant_search"></div> 607 </div> 608 </form> 609 } 610 </div> 611 @*@if(string.IsNullOrEmpty(user)) {*@ 612 @if(!userIsLoggedIn) { 613 <div class="header-account col-sm-3 col-md-4 col-lg-3"> 614 @*<a href="/Default.aspx?ID=10">@Translate("CreateAccount", "Creeaza cont")</a> <text>|</text>*@ <a href="/Default.aspx?ID=11">@Translate("Login", "Login")</a> 615 </div> 616 } else { 617 <div class="header-account customer col-sm-3 col-md-4 col-lg-3"> 618 <a href="@userAccountLink"> 619 @if (!string.IsNullOrEmpty(customerLogo)){ 620 <img src="/Admin/Public/GetImage.ashx?Image=@customerLogo&Format=jpg&Width=190&Height=85&Compression=100&Crop=5" class="img-responsive"> 621 }else{ 622 <span>@customerName</span> 623 } 624 </a> 625 </div> 626 } 627 628 <div class="col-sm-3 col-md-3 col-lg-3 minicart"> 629 <a href="@userCartLink"> 630 <i class="ion-android-cart"></i> 631 @*@if (!@GetBoolean("Ecom:Order.IsEmpty")) {*@ 632 @if (@GetBoolean("Ecom:Order.IsEmpty")) { 633 <span data-minicart-update="">(@cartQuantity) - @cartPrice<sup> @currencyCart</sup></span> 634 } else { 635 <span data-minicart-update="">Cosul este gol</span> 636 } 637 638 </a> 639 </div> 640 </div> 641 </div> 642 </div> 643 </div> 644 </div> 645 646 647 648 @SnippetStart("BottomJS") 649 <script type="text/javascript" src="/Files/Templates/Designs/Fusion/assets/js/main-v2.js"></script> 650 @SnippetEnd("BottomJS") 651 <div class="main-nav-2 hidden-xs hidden-sm"> 652 <span style="display: none;"> 653 @GetGlobalValue("Global:Item.Page.DisplayOptions").ToString() 654 </span> 655 656 <div class="container"> 657 <div class="row"> 658 659 @if(!string.IsNullOrEmpty(customerNo)) 660 { 661 <div class="col-md-3 hidden-sm hidden-xs"> 662 <div class="left-nav-box clearfix @navigationCollapsed"> 663 <div class="category-heading"><p>Categorii de produse</p></div> 664 <div class="menu3dmega" id="menuMega"> 665 @RenderNavigation(new { 666 template = "CategoriesNavigationB2B.xslt", 667 expandmode = "all", 668 sitemapmode="true", 669 id = "categories", 670 startlevel = 1, 671 endlevel = 5, 672 areaid = 1 673 }) 674 </div> 675 </div> 676 </div> 677 678 <div class="col-md-9" style="padding-left: 0;"> 679 @RenderNavigation(new { 680 template = "MainNavigation-v2.xslt", 681 expandmode = "all", 682 id = "NavMainAll", 683 startlevel = 2, 684 endlevel = 4, 685 parentid = 169, 686 customerGroup = @customerListGroupID, 687 customerRole = @customerRole 688 }) 689 690 </div> 691 } else { 692 693 @RenderSnippet("Homepagenavigation") 694 695 <div class="col-md-12"> 696 @RenderNavigation(new { 697 template = "MainNavigation-v2.xslt", 698 expandmode = "all", 699 id = "NavMainAll", 700 startlevel = 1, 701 endlevel = 4 702 }) 703 </div> 704 705 } 706 </div> 707 </div> 708 </div> 709 710 <div class="container"> 711 <div class="row"> 712 713 714 @if (Pageview.User.UserID == 0) { 715 716 <h3>Autentificare</h3> 717 <div class="login-box-mode" data-login-box-mode="login"> 718 @if (!string.IsNullOrWhiteSpace(System.Web.HttpContext.Current.Request["username"]) || !string.IsNullOrWhiteSpace(System.Web.HttpContext.Current.Request["password"])) { 719 <div class="loginbox-login-failed alert alert-error">Datele de utilizator introduse nu sunt corecte</div> 720 } 721 722 <form class="form-horizontal" method="post"> 723 <div class="control-group"> 724 <input type="text" id="login-username" name="username" spellcheck="false" placeholder="Username" value='@System.Web.HttpContext.Current.Request["username"]'> 725 </div> 726 <div class="control-group"> 727 <input type="password" id="login-password" name="password" placeholder="Password" value='@System.Web.HttpContext.Current.Request["password"]'> 728 </div> 729 <input type="submit" value="Login"> 730 </form> 731 </div> 732 } else { 733 734 @: Esti autentificat cu userul @Pageview.User.UserName 735 <br> 736 <br> 737 738 <form method="post"> 739 @if (string.IsNullOrWhiteSpace(GetGlobalValue("Global:Extranet.SecondaryUser.UserID"))) { 740 <table border="0"> 741 <tr> 742 <td>Alege userul pe care vrei sa il impersonezi</td> 743 </tr> 744 <tr> 745 <td> 746 <select id="DWExtranetSecondaryUserSelector" name="DWExtranetSecondaryUserSelector"> 747 @foreach (var secondaryUser in GetLoop("DWExtranetSecondaryUsers")) { 748 <option value='@secondaryUser.GetValue("UserID")'>@secondaryUser.GetValue("UserName")</option> 749 } 750 </select> 751 </td> 752 </tr> 753 <tr> 754 <td colspan="2"><input type="submit" tabindex="3" value="OK"></td> 755 </tr> 756 </table> 757 } else { 758 <h3>@GetGlobalValue("Global:Extranet.SecondaryUser.UserName") este impersonat de @Pageview.User.UserName.</h3> 759 <br> 760 <input type="submit" name="DwExtranetRemoveSecondaryUser" id="DwExtranetRemoveSecondaryUser" value="Stop impersonation"> 761 } 762 <br> 763 <br> 764 765 <a class="btn" href="/Admin/Public/ExtranetLogoff.aspx?ID=@Pageview.Page.ID">Logout</a> 766 767 768 769 770 </form> 771 } 772 </div> 773 </div> 774 <div class="container"> 775 <div class="row"> 776 777 778 <div class="brands-wrapper"> 779 <div class="container"> 780 <div class="col-md-12"> 781 <div class="row"> 782 783 @RenderParagraphContent(1514) 784 785 @* <div class="logo-slider"> 786 <div class="flexslider"> 787 <ul class="slides"> 788 @{ 789 var manufacturers = Dynamicweb.Ecommerce.Products.Manufacturer.GetManufacturers(); 790 int counter = 0; 791 int howManyOnRow = 1; 792 793 foreach (var manufacturer in manufacturers) 794 { 795 if (!string.IsNullOrEmpty(manufacturer.Logo)){ 796 if (counter % howManyOnRow == 0){ 797 if (counter == 0){ 798 @:<li class='item active'> 799 } 800 else { 801 @:</li><li class="item"> 802 } 803 } 804 805 <a href="#"> 806 <img src="/Files/@manufacturer.Logo.Trim('/')"> 807 </a> 808 if (counter % howManyOnRow == howManyOnRow - 1) 809 { 810 @:</li> 811 } 812 counter++; 813 } 814 } 815 if (counter % howManyOnRow != 0) 816 { 817 @: 818 } 819 } 820 </ul> 821 </div> 822 </div>*@ 823 824 @*<div class="brands-list-navigation product-list-navigation"> 825 <a href="#" class="flex-prev"><i class="ion-ios-arrow-back"></i></a> 826 <a href="#" class="flex-next"><i class="ion-ios-arrow-forward"></i></a> 827 </div> *@ 828 829 830 </div> 831 </div> 832 </div> 833 </div> 834 </div> 835 </div> 836 @* 837 <div class="services-list"> 838 <div class="container"> 839 <div class="row"> 840 <div class="col-lg-3 col-md-3 col-sm-6 col-xs-12"> 841 <div class="rec-banner hand"> 842 <div class="banner clearfix"> 843 <div class="services-icon"> 844 <img src="http://cdn.aperta.ro/Files/Templates/Designs/Fusion/assets/img/austral-hand.png" class="img-responsive"> 845 </div> 846 847 <div class="pull-left text-box"> 848 <h3>Garantie</h3> 849 <p>@GetValue("Item.Area.Garantie")</p> 850 </div> 851 </div> 852 </div> 853 </div> 854 <div class="col-lg-3 col-md-3 col-sm-6 col-xs-12"> 855 <div class="rec-banner return"> 856 <div class="banner clearfix"> 857 <div class="services-icon"> 858 <img src="http://cdn.aperta.ro/Files/Templates/Designs/Fusion/assets/img/austral-return.png" class="img-responsive"> 859 </div> 860 <div class="pull-left text-box"> 861 <h3>Retur in 14 zile</h3> 862 <p>@GetValue("Item.Area.Retur")</p> 863 </div> 864 </div> 865 </div> 866 </div> 867 <div class="col-lg-3 col-md-3 col-sm-6 col-xs-12"> 868 <div class="rec-banner support"> 869 <div class="banner clearfix"> 870 <div class="services-icon"> 871 <img src="http://cdn.aperta.ro/Files/Templates/Designs/Fusion/assets/img/austral-support.png" class="img-responsive"> 872 </div> 873 <div class="pull-left text-box"> 874 <h3>Serviciu clienti</h3> 875 <p>@GetValue("Item.Area.Serviciu_Clienti")</p> 876 </div> 877 </div> 878 </div> 879 </div> 880 <div class="col-lg-3 col-md-3 col-sm-6 col-xs-12"> 881 <div class="rec-banner car"> 882 <div class="banner clearfix"> 883 <div class="services-icon"> 884 <img src="http://cdn.aperta.ro/Files/Templates/Designs/Fusion/assets/img/austral-car.png" class="img-responsive"> 885 </div> 886 <div class="pull-left text-box"> 887 <h3>Transport gratuit</h3> 888 @if(!string.IsNullOrEmpty(customerNo)){ 889 <p>@GetValue("Item.Area.TransportB2B")</p> 890 }else{ 891 <p>@GetValue("Item.Area.Transport")</p> 892 } 893 </div> 894 </div> 895 </div> 896 </div> 897 </div> 898 </div> 899 </div>*@ 900 901 902 903 904 <div class="footer"> 905 <div class="container"> 906 <div class="row"> 907 908 <div class="col-md-3 col-sm-6 col-xs-12 shopinfo"> 909 <h4 class="title">AUSTRAL</h4> 910 <p> 911 @GetValue("Item.Area.Contact") 912 </p> 913 <div class="social-icons"> 914 <ul> 915 <li class="icon facebook"><a href='@GetValue("Item.Area.Facebook_Link")' target="_blank"><i class="fa fa-facebook fa-fw"></i></a></li> 916 <li class="icon twitter"><a href='@GetValue("Item.Area.Twitter_Link")' target="_blank"><i class="fa fa-twitter fa-fw"></i></a></li> 917 <li class="icon linkedin"><a href='@GetValue("Item.Area.Linkedin_link")' target="_blank"><i class="fa fa-linkedin fa-fw"></i></a></li> 918 <li class="icon google-plus"><a href='@GetValue("Item.Area.GooglePlus_Link")' target="_blank"><i class="fa fa-google-plus fa-fw"></i></a></li> 919 </ul> 920 </div> 921 </div> 922 <div class="col-md-3 col-sm-6 col-xs-12 footermenu"> 923 <h4 class="title">UTILE </h4> 924 @GetValue("DwNavigation(BottomNavigation)") 925 <a href="http://australservicii.ro/" target="_blank"><img src="/Files/Templates/Designs/Fusion/assets/img/Banner_Australservicii.png" alt="" style="margin: 9px 0 0 0;"></a> 926 </div> 927 <div class="col-md-3 col-sm-6 col-xs-12 footermenu"> 928 <h4 class="title">COMENZI</h4> 929 @GetValue("DwNavigation(BottomNavigation1)") 930 <img src="/Files/Templates/Designs/Fusion/assets/img/MobilPay-banner.png" alt=""> 931 </div> 932 <div class="col-md-3 col-sm-6 col-xs-12 getintouch"> 933 <h4 class="title">Certificari</h4> 934 <img src="/Files/Templates/Designs/Fusion/assets/img/ukas.jpg" alt=""> 935 </div> 936 937 </div> 938 </div> 939 </div> 940 <div class="cart--footer"> 941 <div class="container"> 942 <div class="row"> 943 <div class="col-xs-12"> 944 <a href="#" class="emptyCart">Goleste cos</a> 945 @GetValue("CartV2.NextStepButtonName") 946 947 @{ 948 var cartLink = "/Default.aspx?ID=13"; 949 if(!string.IsNullOrEmpty(customerNo)) { 950 cartLink = "/Default.aspx?ID=42"; 951 } 952 } 953 <a class="cart" href="@cartLink"> 954 <span class="spacing">Aveti <span class="em" cartproducts="">produse</span> in cos</span> 955 <span class="spacing">Cost total: <span class="em" carttotals="">Cosul este gol</span></span> 956 <span class="spacing cart--footer__button">Finalizeaza Comanda</span> 957 </a> 958 </div> 959 </div> 960 </div> 961 </div> 962 </div> 963 964 965 966 967 968 @* JS Libraries *@ 969 <script type="text/javascript" src="/Files/Templates/Designs/Fusion/assets/js/bootstrap.min.js"></script> 970 <script type="text/javascript" src="/Files/Templates/Designs/Fusion/assets/js/libraries/slick.min.js"></script> 971 <script src="https://cdnjs.cloudflare.com/ajax/libs/select2/4.0.3/js/select2.min.js" type="text/javascript"></script> 972 <script type="text/javascript" src="/Files/Templates/Designs/Fusion/assets/js/jquery.noty.packaged.js"></script> 973 <script type="text/javascript" src="/Files/Templates/Designs/Fusion/assets/js/bpopup.js"></script> 974 <script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/flexslider/2.6.0/jquery.flexslider.min.js"></script> 975 976 977 978 979 <script type="text/javascript" src="/Files/Templates/Designs/Fusion/assets/js/libraries/jscookie.js"></script> 980 <script type="text/javascript" src="/Files/Templates/Designs/Fusion/assets/js/alertify.js"></script> 981 @* <script type="text/javascript" src="/Files/Templates/Designs/Fusion/assets/js/mobile-menu.js"></script> *@ 982 <script type="text/javascript" src="/Files/Templates/Designs/Fusion/assets/js/mobile-menu-v2.js"></script> 983 <script type="text/javascript" src="/Files/Templates/Designs/Fusion/assets/js/login.js"></script> 984 <script type="text/javascript" src="/Files/Templates/Designs/Fusion/assets/js/main.js"></script> 985 <script type="text/javascript" src="/Files/Templates/Designs/Fusion/assets/js/carousels.js"></script> 986 <script type="text/javascript" src="/Files/Templates/Designs/Fusion/assets/js/main-v2.js"></script> 987 <script type="text/javascript" src="/Files/Templates/Designs/Fusion/assets/js/product-modal.js"></script> 988 989 990 <script src="https://cdnjs.cloudflare.com/ajax/libs/photoswipe/4.1.1/photoswipe.min.js" type="text/javascript"></script> 991 <script src="https://cdnjs.cloudflare.com/ajax/libs/photoswipe/4.1.1/photoswipe-ui-default.min.js" type="text/javascript"></script> 992 <script src="https://cdnjs.cloudflare.com/ajax/libs/lodash.js/4.16.6/lodash.min.js" type="text/javascript" charset="utf-8"></script> 993 994 <script type="text/javascript" src="/Files/Templates/Designs/Fusion/assets/js/product-list.js"></script> 995 <script type="text/javascript" src="/Files/Templates/Designs/Fusion/assets/js/loader.js"></script> 996 <script type="text/javascript" src="/Files/Templates/Designs/Fusion/assets/js/minicart.js"></script> 997 <script type="text/javascript" src="/Files/Templates/Designs/Fusion/assets/js/voucher.js"></script> 998 <script type="text/javascript" src="/Files/Templates/Designs/Fusion/assets/js/cart.js"></script> 999 <script type="text/javascript" src="/Files/Templates/Designs/Fusion/assets/js/jquery.validate.js"></script> 1000 1001 @RenderSnippet("modalBottom") 1002 @RenderSnippet("bottomJS") 1003 1004 @* Quickview modal *@ 1005 <div class="b-modal" id="quickview"> 1006 <div id="results" class="clearfix"></div> 1007 </div> 1008 1009 1010 1011 @RenderScripts("footer") 1012 </body> 1013