// POST: PDF/PDFModel/Edit/5
        // To protect from overposting attacks, please enable the specific properties you want to bind to, for
        // more details see http://go.microsoft.com/fwlink/?LinkId=317598.

        public ActionResult Generate(int id)
        {
            MemoryStream stream     = new MemoryStream();
            PDFModel     pdfModel   = db.PDFs.Find(id);
            PDFService   pdfService = new PDFService();
            PDFFileModel pdfFile    = pdfService.HtmlToPdf("filename", pdfModel.HtmlContent, UserId, options: new string[] { "--disable-external-links", "--disable-internal-links" });

            return(File(pdfFile.FilePathAndName, "application/pdf", pdfFile.FileName));
        }