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

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

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