// Create email with predefine body and subject. SendMessageRequest GenerateEmail(UserInfo to) { return(CreateEmailObject( attachment: to.ItemId == null?new byte[] { 0x20 }: UnifiedApiHelper.GetItem(to.ItemId, (string)Session[SessionKeys.Login.AccessToken]), to: to, subject: Settings.MessageSubject, body: string.Format(Settings.MessageBody, to.Name) )); }
public FileContentResult Download(string id, string fileName) => File(UnifiedApiHelper.GetItem(id, (string)Session[SessionKeys.Login.AccessToken]), System.Net.Mime.MediaTypeNames.Application.Octet, fileName);