Esempio n. 1
0
        public async Task <IViewComponentResult> InvokeAsync()
        {
            var model = await _commonViewModelService.PrepareAdminHeaderLinks(_workContext.CurrentCustomer);

            if (!model.DisplayAdminLink && !model.IsCustomerImpersonated)
            {
                return(Content(""));
            }
            return(View(model));
        }
Esempio n. 2
0
        public IViewComponentResult Invoke()
        {
            var model = _commonViewModelService.PrepareAdminHeaderLinks(_workContext.CurrentCustomer);

            if (!model.DisplayAdminLink)
            {
                return(Content(""));
            }
            return(View(model));
        }