//NOP 3.830 public ActionResult ExportXml() { if (!_permissionService.Authorize(StandardPermissionProvider.ManageDiscounts)) { return(AccessDeniedView()); } try { var giftCards = _giftCardService.GetAllGiftCards(); var xml = _exportManager.ExportGiftCardsToXml(giftCards); return(new XmlDownloadResult(xml, "giftcards.xml")); } catch (Exception exc) { ErrorNotification(exc); return(RedirectToAction("List")); } }