{"id":290399,"date":"2018-10-05T21:10:02","date_gmt":"2018-10-05T17:10:02","guid":{"rendered":"http:\/\/savepearlharbor.com\/?p=290399"},"modified":"-0001-11-30T00:00:00","modified_gmt":"-0001-11-29T21:00:00","slug":"","status":"publish","type":"post","link":"https:\/\/savepearlharbor.com\/?p=290399","title":{"rendered":"\u041d\u0435\u043e\u0447\u0435\u0432\u0438\u0434\u043d\u044b\u0435 \u043e\u0441\u043e\u0431\u0435\u043d\u043d\u043e\u0441\u0442\u0438 \u043f\u0440\u0438\u043c\u0435\u043d\u0435\u043d\u0438\u044f Rotativa \u0434\u043b\u044f \u0433\u0435\u043d\u0435\u0440\u0430\u0446\u0438\u0438 PDF \u0432 ASP.NET MVC \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0438"},"content":{"rendered":"\n<div class=\"post__text post__text-html js-mediator-article\">\n<p>\u041c\u043d\u043e\u0433\u0438\u0435 \u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u0447\u0438\u043a\u0438 \u0441\u0442\u0430\u043b\u043a\u0438\u0432\u0430\u044e\u0442\u0441\u044f \u0441 \u0437\u0430\u0434\u0430\u0447\u0435\u0439 \u0441\u043e\u0437\u0434\u0430\u043d\u0438\u044f PDF \u043e\u0442\u0447\u0435\u0442\u043e\u0432 \u0434\u043b\u044f \u0432\u0435\u0431 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0439, \u0432\u043f\u043e\u043b\u043d\u0435 \u0435\u0441\u0442\u0435\u0441\u0442\u0432\u0435\u043d\u043d\u044b\u0439 \u0437\u0430\u043f\u0440\u043e\u0441. \u042f \u0431\u044b \u0445\u043e\u0442\u0435\u043b \u043f\u0440\u0435\u0434\u0441\u0442\u0430\u0432\u0438\u0442\u044c \u0432\u0430\u0448\u0435\u043c\u0443 \u0432\u043d\u0438\u043c\u0430\u043d\u0438\u044e \u0441\u0432\u043e\u0439 \u043e\u043f\u044b\u0442 \u0440\u0430\u0431\u043e\u0442\u044b \u0441 \u0442\u0430\u043a\u043e\u0439 \u0437\u0430\u0434\u0430\u0447\u0435\u0439 \u043f\u0440\u0438 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0438 \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0438 Rotativa \u0434\u043b\u044f \u0433\u0435\u043d\u0435\u0440\u0430\u0446\u0438\u0438 \u043e\u0442\u0447\u0435\u0442\u043e\u0432. \u042d\u0442\u043e \u043e\u0434\u043d\u0430 \u0438\u0437 \u0441\u0430\u043c\u044b\u0445, \u043d\u0430 \u043c\u043e\u0439 \u0432\u0437\u0433\u043b\u044f\u0434, \u0443\u0434\u043e\u0431\u043d\u044b\u0445 \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a \u0434\u043b\u044f \u0442\u0430\u043a\u043e\u0439 \u0446\u0435\u043b\u0438 \u0432 \u0441\u0432\u043e\u0435\u043c \u0441\u0435\u0433\u043c\u0435\u043d\u0442\u0435, \u043d\u043e \u043f\u0440\u0438 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0438 \u0435\u0435 \u044f \u0441\u0442\u043e\u043b\u043a\u043d\u0443\u043b\u0441\u044f \u0441 \u043d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u0438\u043c\u0438 \u043d\u0435 \u043e\u0447\u0435\u0432\u0438\u0434\u043d\u044b\u043c\u0438 \u043c\u043e\u043c\u0435\u043d\u0442\u0430\u043c\u0438, \u043e \u043a\u043e\u0442\u043e\u0440\u044b\u0445 \u0438 \u0445\u043e\u0447\u0443 \u043f\u043e\u0433\u043e\u0432\u043e\u0440\u0438\u0442\u044c.<\/p>\n<p><a name=\"habracut\"><\/a>  <\/p>\n<p>\u0415\u0441\u043b\u0438 \u0431\u044b\u0442\u044c \u0434\u043e \u043a\u043e\u043d\u0446\u0430 \u0447\u0435\u0441\u0442\u043d\u044b\u043c, \u044f \u0431\u044b \u0445\u043e\u0442\u0435\u043b \u043f\u043e\u0434\u0435\u043b\u0438\u0442\u044c\u0441\u044f \u0442\u0435\u043c \u043d\u0430\u0431\u043e\u0440\u043e\u043c \u0433\u0440\u0430\u0431\u043b\u0435\u0439, \u043d\u0430 \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u043d\u0430\u0441\u0442\u0443\u043f\u0438\u043b \u0432 \u043f\u0440\u043e\u0446\u0435\u0441\u0441\u0435 \u0438\u043d\u0442\u0435\u0433\u0440\u0430\u0446\u0438\u0438 \u0434\u0430\u043d\u043d\u043e\u0439 \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0438, \u0431\u0435\u0437 \u0441\u043e\u043c\u043d\u0435\u043d\u0438\u044f \u0431\u044b\u0441\u0442\u0440\u043e\u0439 \u0438 \u043e\u0447\u0435\u043d\u044c \u0443\u0434\u043e\u0431\u043d\u043e\u0439.<\/p>\n<p>  <\/p>\n<p>\u0412 \u0434\u0430\u043d\u043d\u043e\u043c \u043c\u0430\u0442\u0435\u0440\u0438\u0430\u043b\u0435 \u044f \u043d\u0435 \u0431\u0443\u0434\u0443 \u043a\u0430\u0441\u0430\u0442\u044c\u0441\u044f \u0432\u043e\u043f\u0440\u043e\u0441\u0430 \u0432\u044b\u0431\u043e\u0440\u0430 \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0438. \u0423 \u043a\u0430\u0436\u0434\u043e\u0433\u043e \u043c\u043e\u0433\u0443\u0442 \u0431\u044b\u0442\u044c \u0441\u0432\u043e\u0438 \u043f\u0440\u0438\u0447\u0438\u043d\u044b \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u0442\u0443 \u0438\u043b\u0438 \u0438\u043d\u0443\u044e. \u042f \u0432\u044b\u0431\u0440\u0430\u043b Rotativa, \u043f\u043e\u0442\u043e\u043c\u0443 \u0447\u0442\u043e \u0432 \u043d\u0435\u0439 \u043f\u0440\u0438 \u043c\u0438\u043d\u0438\u043c\u0430\u043b\u044c\u043d\u044b\u0445 \u0437\u0430\u0442\u0440\u0430\u0442\u0430\u0445 \u043d\u0430 \u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0443 \u0437\u0430\u0432\u0435\u043b\u043e\u0441\u044c \u0432\u0441\u0435 \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e\u0435 \u0434\u043b\u044f \u043f\u043e\u043a\u0440\u044b\u0442\u0438\u044f \u0442\u0440\u0435\u0431\u043e\u0432\u0430\u043d\u0438\u0439 \u0437\u0430\u043a\u0430\u0437\u0447\u0438\u043a\u0430. \u041a\u0440\u043e\u043c\u0435 \u043d\u0435\u0435 \u044f \u043f\u043e\u043f\u0440\u043e\u0431\u043e\u0432\u0430\u043b \u0435\u0449\u0435 \u0442\u0440\u0438 \u0438\u043b\u0438 \u0447\u0435\u0442\u044b\u0440\u0435 \u0432\u0430\u0440\u0438\u0430\u043d\u0442\u0430.<\/p>\n<p>  <\/p>\n<h3 id=\"postanovka-zadachi\">\u041f\u043e\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0430 \u0437\u0430\u0434\u0430\u0447\u0438<\/h3>\n<p>  <\/p>\n<p>\u0412\u0435\u0431 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0435 \u043d\u0430 ASP.NET MVC, .NET \u0432\u0435\u0440\u0441\u0438\u0438 4.6. \u041f\u0440\u043e\u0447\u0438\u0435 \u043e\u0441\u043e\u0431\u0435\u043d\u043d\u043e\u0441\u0442\u0438 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u044f \u043d\u0435 \u0438\u043c\u0435\u044e\u0442 \u0432 \u0434\u0430\u043d\u043d\u043e\u043c \u043a\u043e\u043d\u0442\u0435\u043a\u0441\u0442\u0435, \u0437\u0430 \u0438\u0441\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u0435\u043c \u0434\u0435\u043f\u043b\u043e\u0439\u043c\u0435\u043d\u0442\u0430. \u041f\u0440\u0435\u0434\u043f\u043e\u043b\u0430\u0433\u0430\u0435\u0442\u0441\u044f, \u0447\u0442\u043e \u0440\u0430\u0437\u0432\u0435\u0440\u0442\u044b\u0432\u0430\u043d\u0438\u0435 \u0431\u0443\u0434\u0435\u0442 \u043f\u0440\u043e\u0438\u0441\u0445\u043e\u0434\u0438\u0442\u044c \u043d\u0430 Azure. \u042d\u0442\u043e \u0432\u0430\u0436\u043d\u043e, \u0442\u0430\u043a \u043a\u0430\u043a \u043d\u0435\u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u0434\u0440\u0443\u0433\u0438\u0435 \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0438 (\u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440 HiQPdf) \u043d\u0435 \u043f\u0435\u0440\u0435\u043d\u043e\u0441\u044f\u0442 \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0438 \u0432 \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u043d\u044b\u0445 \u043a\u043e\u043d\u0444\u0438\u0433\u0443\u0440\u0430\u0446\u0438\u044f\u0445 Azure, \u044d\u0442\u043e \u0434\u043e\u043a\u0443\u043c\u0435\u043d\u0442\u0438\u0440\u043e\u0432\u0430\u043d\u043e. <\/p>\n<p>  <\/p>\n<p>\u041c\u043d\u0435 \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u043f\u043e \u043e\u0434\u043d\u043e\u0439 \u0441\u0441\u044b\u043b\u043a\u0435 \u043e\u0442\u043a\u0440\u044b\u0432\u0430\u0442\u044c \u043d\u0435\u043a\u0438\u0439 \u0441\u0442\u0430\u0442\u0438\u0447\u043d\u044b\u0439 HTML \u043e\u0442\u0447\u0435\u0442, \u0430 \u043f\u043e \u0432\u0442\u043e\u0440\u043e\u0439 \u0441\u0441\u044b\u043b\u043a\u0435 \u2014 PDF \u0432\u0435\u0440\u0441\u0438\u044e \u0442\u043e\u0433\u043e \u0436\u0435 \u043e\u0442\u0447\u0435\u0442\u0430. \u0421\u0430\u043c \u043e\u0442\u0447\u0435\u0442 \u0441\u0443\u0442\u044c \u043f\u0440\u043e\u0441\u0442\u043e \u043d\u0430\u0431\u043e\u0440 \u043d\u0435\u043a\u043e\u0442\u043e\u0440\u044b\u0445 \u0442\u0430\u0431\u043b\u0438\u0446, \u043f\u043e\u043b\u0435\u0439 \u0438 \u0433\u0440\u0430\u0444\u0438\u043a\u043e\u0432 \u0434\u043b\u044f \u0434\u0435\u043c\u043e\u043d\u0441\u0442\u0440\u0430\u0446\u0438\u0438 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044e. \u041e\u0431\u0435 \u0432\u0435\u0440\u0441\u0438\u0438 \u043f\u0440\u0435\u0434\u043f\u043e\u043b\u0430\u0433\u0430\u044e\u0442 \u043d\u0430\u043b\u0438\u0447\u0438\u0435 \u043c\u0435\u043d\u044e \u0441 \u043d\u0430\u0432\u0438\u0433\u0430\u0446\u0438\u0435\u0439 \u043f\u043e \u0440\u0430\u0437\u0434\u0435\u043b\u0430\u043c \u043e\u0442\u0447\u0435\u0442\u0430, \u043d\u0430\u043b\u0438\u0447\u0438\u0435 \u0442\u0430\u0431\u043b\u0438\u0446, \u043d\u0435\u043a\u043e\u0442\u043e\u0440\u043e\u0439 \u0433\u0440\u0430\u0444\u0438\u043a\u0438 (\u0446\u0432\u0435\u0442\u0430, \u0440\u0430\u0437\u043c\u0435\u0440 \u0442\u0435\u043a\u0441\u0442\u0430, \u0431\u043e\u0440\u0434\u0435\u0440\u044b).<\/p>\n<p>  <\/p>\n<h3 id=\"primenenie-biblioteki-rotativa\">\u041f\u0440\u0438\u043c\u0435\u043d\u0435\u043d\u0438\u0435 \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0438 Rotativa<\/h3>\n<p>  <\/p>\n<p>Rotativa \u043f\u0440\u0438\u043c\u0435\u043d\u044f\u0435\u0442\u0441\u044f \u043c\u0430\u043a\u0441\u0438\u043c\u0430\u043b\u044c\u043d\u043e \u043b\u0435\u0433\u043a\u043e, \u043d\u0430\u0441\u043a\u043e\u043b\u044c\u043a\u043e \u044d\u0442\u043e \u0432\u043e\u043e\u0431\u0449\u0435 \u0432\u043e\u0437\u043c\u043e\u0436\u043d\u043e \u043d\u0430 \u043c\u043e\u0439 \u0432\u0437\u0433\u043b\u044f\u0434.<\/p>\n<p>  <\/p>\n<ol>\n<li>\u0423 \u0432\u0430\u0441 \u0443\u0436\u0435 \u0435\u0441\u0442\u044c \u0433\u043e\u0442\u043e\u0432\u044b\u0439 HTML \u043e\u0442\u0447\u0435\u0442 \u0432 \u0432\u0438\u0434\u0435 \u0448\u0430\u0431\u043b\u043e\u043d\u0430 \u0438 \u043a\u043e\u043d\u0442\u0440\u043e\u043b\u043b\u0435\u0440\u0430 ASP.NET MVC, \u0442\u0438\u043f\u0430 \u0442\u0430\u043a\u043e\u0433\u043e:<\/li>\n<\/ol>\n<p>  <\/p>\n<pre><code class=\"cs\">[HttpGet] public async Task&lt;ActionResult&gt; Index(int param1, string param2) {     var model = await service.GetReportDataAsync(param1, param2);     return View(model); }<\/code><\/pre>\n<p>  <\/p>\n<ol>\n<li>\n<p>\u0423\u0441\u0442\u0430\u043d\u0430\u0432\u043b\u0438\u0432\u0430\u0435\u0442\u0435 nuget \u043f\u0430\u043a\u0435\u0442 <a href=\"https:\/\/www.nuget.org\/packages\/Rotativa\/1.7.3\">Rotativa<\/a><\/p>\n<p>  <\/li>\n<li>\n<p>\u0414\u043e\u0431\u0430\u0432\u043b\u044f\u0435\u0442\u0435 \u043d\u043e\u0432\u044b\u0439 \u043a\u043e\u043d\u0442\u0440\u043e\u043b\u043b\u0435\u0440 \u0434\u043b\u044f PDF \u043e\u0442\u0447\u0435\u0442\u0430<\/p>\n<p>  <\/li>\n<\/ol>\n<p>  <\/p>\n<pre><code class=\"cs\">[HttpGet] public async Task&lt;ActionResult&gt; Pdf(int param1, string param2) {     var model = await service.GetReportDataAsync(param1, param2);                 return new ViewAsPdf(&quot;Index&quot;, model); }<\/code><\/pre>\n<p>  <\/p>\n<p>\u041f\u043e \u0441\u0443\u0442\u0438 \u0441 \u044d\u0442\u043e\u0433\u043e \u043c\u043e\u043c\u0435\u043d\u0442\u0430 \u0443 \u0432\u0430\u0441 \u0435\u0441\u0442\u044c PDF, \u0432\u043e\u0437\u0432\u0440\u0430\u0449\u0430\u0435\u043c\u044b\u0439 \u043a\u0430\u043a \u0444\u0430\u0439\u043b, \u0441\u043e\u0434\u0435\u0440\u0436\u0430\u0449\u0438\u0439 \u0432\u0441\u0435 \u0434\u0430\u043d\u043d\u044b\u0439 \u0438\u0437 \u0438\u0441\u0445\u043e\u0434\u043d\u043e\u0433\u043e HTML \u043e\u0442\u0447\u0435\u0442\u0430.<\/p>\n<p>  <\/p>\n<p><em>\u042f \u043d\u0435 \u043e\u043f\u0438\u0441\u044b\u0432\u0430\u043b \u0442\u0443\u0442 \u0440\u043e\u0443\u0442\u0438\u043d\u0433, \u043d\u043e \u043f\u043e\u0434\u0440\u0430\u0437\u0443\u043c\u0435\u0432\u0430\u0435\u0442\u0441\u044f, \u0447\u0442\u043e \u0432\u044b \u043d\u0430\u0441\u0442\u0440\u043e\u0438\u043b\u0438 \u0440\u043e\u0443\u0442\u044b \u0434\u043b\u044f \u043f\u0440\u0430\u0432\u0438\u043b\u044c\u043d\u043e\u0433\u043e \u0432\u044b\u0437\u043e\u0432\u0430 \u043e\u0431\u043e\u0438\u0445 \u043a\u043e\u043d\u0442\u0440\u043e\u043b\u043b\u0435\u0440\u043e\u0432<\/em><\/p>\n<p>  <\/p>\n<p>\u0418\u043d\u0442\u0435\u0440\u0435\u0441\u043d\u043e, \u0447\u0442\u043e \u0441\u0430\u043c\u0430 \u0434\u0430\u043d\u043d\u0430\u044f \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0430 \u043f\u043e \u0441\u0443\u0442\u0438 \u044f\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u043e\u0431\u0435\u0440\u0442\u043a\u043e\u0439 \u043d\u0430\u0434 \u0438\u0437\u0432\u0435\u0441\u0442\u043d\u043e\u0439 \u043a\u043e\u043d\u0441\u043e\u043b\u044c\u043d\u043e\u0439 \u0443\u0442\u0438\u043b\u0438\u0442\u043e\u0439 <a href=\"https:\/\/wkhtmltopdf.org\">wkhtmltopdf<\/a>. \u0421\u043a\u043e\u0440\u043e\u0441\u0442\u044c \u0440\u0430\u0431\u043e\u0442\u044b \u043d\u0430 \u0432\u044b\u0441\u043e\u0442\u0435, \u043c\u043e\u0436\u043d\u043e \u0441\u0442\u0430\u0432\u0438\u0442\u044c \u043d\u0430 Azure \u2014 \u0431\u0443\u0434\u0435\u0442 \u0440\u0430\u0431\u043e\u0442\u0430\u0442\u044c. \u041d\u043e \u0435\u0441\u0442\u044c \u043e\u0441\u043e\u0431\u0435\u043d\u043d\u043e\u0441\u0442\u0438, \u043e \u043a\u043e\u0442\u043e\u0440\u044b\u0445 \u0438 \u043f\u043e\u0433\u043e\u0432\u043e\u0440\u0438\u043c.<\/p>\n<p>  <\/p>\n<h3 id=\"page-number\">Page Number<\/h3>\n<p>  <\/p>\n<p>\u041b\u043e\u0433\u0438\u0447\u043d\u043e \u043f\u0440\u0435\u0434\u043f\u043e\u043b\u043e\u0436\u0438\u0442\u044c, \u0447\u0442\u043e \u0437\u0430\u043a\u0430\u0437\u0447\u0438\u043a \u0431\u0443\u0434\u0435\u0442 \u0440\u0430\u0441\u043f\u0435\u0447\u0430\u0442\u044b\u0432\u0430\u0442\u044c PDF \u0438 \u0437\u0430\u0445\u043e\u0447\u0435\u0442 \u0432\u0438\u0434\u0435\u0442\u044c \u043d\u043e\u043c\u0435\u0440 \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u044b. \u0422\u0443\u0442 \u0432\u0441\u0435 \u043f\u0440\u0435\u0434\u0435\u043b\u044c\u043d\u043e \u043f\u0440\u043e\u0441\u0442\u043e, \u0441\u043f\u0430\u0441\u0438\u0431\u043e \u0441\u043e\u0437\u0434\u0430\u0442\u0435\u043b\u044f\u043c Rotativa.<\/p>\n<p>  <\/p>\n<p>\u0421\u043e\u0433\u043b\u0430\u0441\u043d\u043e \u0434\u043e\u043a\u0443\u043c\u0435\u043d\u0442\u0430\u0446\u0438\u0438 Rotativa, \u0447\u0435\u0440\u0435\u0437 \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440 <code>CustomSwitches<\/code> \u043c\u043e\u0436\u043d\u043e \u0443\u043a\u0430\u0437\u0430\u0442\u044c \u0430\u0440\u0433\u0443\u043c\u0435\u043d\u0442\u044b, \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u0431\u0443\u0434\u0443\u0442 \u043f\u0435\u0440\u0435\u0434\u0430\u043d\u044b \u0432 \u0441\u0430\u043c\u0443 \u0443\u0442\u0438\u043b\u0438\u0442\u0443 <code>wkhtmltopdf<\/code>. \u041d\u0443 \u0438 \u0441\u043e\u0432\u0435\u0442\u044b \u0432 \u0441\u0435\u0442\u0438 \u0449\u0435\u0434\u0440\u044b \u043d\u0430 \u043f\u0440\u0438\u043c\u0435\u0440\u044b. \u0421\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u0439 \u0432\u044b\u0437\u043e\u0432 \u0434\u043e\u0431\u0430\u0432\u043b\u044f\u0435\u0442 \u043d\u043e\u043c\u0435\u0440 \u0432 \u043d\u0438\u0436\u043d\u044e\u044e \u0447\u0430\u0441\u0442\u044c \u043a\u0430\u0436\u0434\u043e\u0439 \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u044b:<\/p>\n<p>  <\/p>\n<pre><code class=\"cs\">return new ViewAsPdf(&quot;Index&quot;, model) {     PageMargins = new Rotativa.Options.Margins(10, 10, 10, 10),     PageSize = Rotativa.Options.Size.A4,     PageOrientation = Rotativa.Options.Orientation.Portrait,     CustomSwitches = &quot;--page-offset 0 --footer-center [page] --footer-font-size 8 };<\/code><\/pre>\n<p>  <\/p>\n<p>\u042d\u0442\u043e \u043f\u0440\u0435\u043a\u0440\u0430\u0441\u043d\u043e \u0440\u0430\u0431\u043e\u0442\u0430\u0435\u0442. \u0421\u0430\u043c \u043d\u043e\u043c\u0435\u0440 \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u044b \u043f\u0435\u0440\u0435\u0434\u0430\u0435\u0442\u0441\u044f \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u0430 <code>[page]<\/code>, \u0442\u0430\u043a\u043e\u0433\u043e \u0440\u043e\u0434\u0430 \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u044b \u0431\u0443\u0434\u0443\u0442 \u043f\u043e\u0434\u043c\u0435\u043d\u0435\u043d\u044b \u043d\u0430 \u043a\u043e\u043d\u043a\u0440\u0435\u0442\u043d\u044b\u0435 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u044f. <\/p>\n<p>  <\/p>\n<blockquote><p>\u041a\u0440\u043e\u043c\u0435 <code>[page]<\/code> \u0435\u0441\u0442\u044c \u0438 \u0434\u0440\u0443\u0433\u0438\u0435:  <\/p>\n<ul>\n<li>[page] Replaced by the number of the pages currently being printed<\/li>\n<li>[frompage] Replaced by the number of the first page to be printed<\/li>\n<li>[topage] Replaced by the number of the last page to be printed<\/li>\n<li>[webpage] Replaced by the URL of the page being printed<\/li>\n<li>[section] Replaced by the name of the current section<\/li>\n<li>[subsection] Replaced by the name of the current subsection<\/li>\n<li>[date] Replaced by the current date in system local format<\/li>\n<li>[isodate] Replaced by the current date in ISO 8601 extended format<\/li>\n<li>[time] Replaced by the current time in system local format<\/li>\n<li>[title] Replaced by the title of the of the current page object<\/li>\n<li>[doctitle] Replaced by the title of the output document<\/li>\n<li>[sitepage] Replaced by the number of the page in the current site being converted<\/li>\n<li>[sitepages] Replaced by the number of pages in the current site being converted<\/li>\n<\/ul>\n<p>  <\/p><\/blockquote>\n<p>  <\/p>\n<h3 id=\"table-of-content\">Table of content<\/h3>\n<p>  <\/p>\n<p>\u0411\u043e\u043b\u044c\u0448\u0438\u0435 \u043c\u043d\u043e\u0433\u043e\u0441\u0442\u0440\u0430\u043d\u0438\u0447\u043d\u044b\u0435 \u043e\u0442\u0447\u0435\u0442\u044b \u0442\u0440\u0435\u0431\u0443\u044e\u0442 \u043d\u0430\u043b\u0438\u0447\u0438\u044f \u0441\u043e\u0434\u0435\u0440\u0436\u0430\u043d\u0438\u044f \u0438 \u043d\u0430\u0432\u0438\u0433\u0430\u0446\u0438\u0438 \u043f\u043e \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u0430\u043c \u0432 PDF. \u042d\u0442\u043e \u043e\u0447\u0435\u043d\u044c \u0443\u0434\u043e\u0431\u043d\u043e \u0438 \u043f\u0440\u043e\u0441\u0442\u043e \u0436\u0438\u0437\u043d\u0435\u043d\u043d\u043e \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e, \u043a\u043e\u0433\u0434\u0430 \u043a\u043e\u043b\u0438\u0447\u0435\u0441\u0442\u0432\u043e \u0441\u0442\u0440\u0430\u043d\u0438\u0446 \u0432 \u043e\u0442\u0447\u0435\u0442\u0435 \u043f\u0435\u0440\u0435\u0432\u0430\u043b\u0438\u0432\u0430\u0435\u0442 \u0437\u0430 \u0441\u043e\u0442\u043d\u044e.<\/p>\n<p>  <\/p>\n<p><a href=\"https:\/\/wkhtmltopdf.org\/usage\/wkhtmltopdf.txt\">wkhtmltopdf manual<\/a> \u0441\u043e\u0434\u0435\u0440\u0436\u0438\u0442 \u043f\u043e\u043b\u043d\u044b\u0439 \u0441\u043f\u0438\u0441\u043e\u043a \u0432\u0441\u0435\u0445 \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u043e\u0432, \u0441\u0440\u0435\u0434\u0438 \u043a\u043e\u0442\u043e\u0440\u044b\u0445 \u0435\u0441\u0442\u044c <code>--toc<\/code>. \u0412\u0438\u0434\u044f \u0434\u0430\u043d\u043d\u044b\u0439 \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440, \u0443\u0442\u0438\u043b\u0438\u0442\u0430 \u043f\u043e \u0441\u0443\u0442\u0438 \u0441\u043e\u0431\u0438\u0440\u0430\u0435\u0442 \u0432\u0441\u0435 \u0442\u044d\u0433\u0438 <code>&lt;h1&gt;, &lt;h2&gt;, ... &lt;h6&gt;<\/code> \u043f\u043e \u0434\u043e\u043a\u0443\u043c\u0435\u043d\u0442\u0443 \u0438 \u0433\u0435\u043d\u0435\u0440\u0438\u0440\u0443\u0435\u0442 \u0442\u0430\u0431\u043b\u0438\u0446\u0443 \u0441\u043e\u0434\u0435\u0440\u0436\u0430\u043d\u0438\u044f \u043d\u0430 \u0438\u0445 \u043e\u0441\u043d\u043e\u0432\u0435. \u0421\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0435\u043d\u043d\u043e \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u043f\u0440\u0435\u0434\u0443\u0441\u043c\u043e\u0442\u0440\u0435\u0442\u044c \u043f\u0440\u0430\u0432\u0438\u043b\u044c\u043d\u043e\u0435 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435 \u044d\u0442\u0438\u0445 \u0437\u0430\u0433\u043e\u043b\u043e\u0432\u043e\u0447\u043d\u044b\u0445 \u0442\u044d\u0433\u043e\u0432 \u0443 \u0441\u0435\u0431\u044f \u0432 HTML \u0448\u0430\u0431\u043b\u043e\u043d\u0435.<\/p>\n<p>  <\/p>\n<p>\u041d\u043e \u0432 \u0440\u0435\u0430\u043b\u044c\u043d\u043e\u0441\u0442\u0438 \u0434\u043e\u0431\u0430\u0432\u043b\u0435\u043d\u0438\u0435 <code>--toc<\/code> \u043d\u0435 \u043f\u0440\u0438\u0432\u043e\u0434\u0438\u0442 \u043d\u0438 \u043a \u043a\u0430\u043a\u0438\u043c \u043f\u043e\u0441\u043b\u0435\u0434\u0441\u0442\u0432\u0438\u044f\u043c. \u0411\u0443\u0434\u0442\u043e \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u0430 \u0438 \u043d\u0435 \u0431\u044b\u043b\u043e. \u041f\u0440\u0438 \u044d\u0442\u043e\u043c \u0434\u0440\u0443\u0433\u0438\u0435 \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u044b \u0440\u0430\u0431\u043e\u0442\u0430\u044e\u0442. \u0411\u043b\u0430\u0433\u043e\u0434\u0430\u0440\u044f \u043f\u043e\u0441\u0442\u0443 \u043d\u0430 \u043a\u0430\u043a\u043e\u043c-\u0442\u043e \u0444\u043e\u0440\u0443\u043c\u0435 \u044f \u043e\u0431\u043d\u0430\u0440\u0443\u0436\u0438\u043b, \u0447\u0442\u043e \u0434\u0430\u043d\u043d\u044b\u0439 \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440 \u043d\u0443\u0436\u043d\u043e \u043f\u0435\u0440\u0435\u0434\u0430\u0432\u0430\u0442\u044c \u0431\u0435\u0437 \u0434\u0435\u0444\u0438\u0441\u043e\u0432: <code>toc<\/code>. \u0418 \u0434\u0435\u0439\u0441\u0442\u0432\u0438\u0442\u0435\u043b\u044c\u043d\u043e, \u0432 \u044d\u0442\u043e\u043c \u0441\u043b\u0443\u0447\u0430\u0435 \u0441\u043e\u0434\u0435\u0440\u0436\u0430\u043d\u0438\u0435 \u0434\u043e\u0431\u0430\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u043a\u0430\u043a \u0441\u0430\u043c\u0430\u044f \u043f\u0435\u0440\u0432\u0430\u044f \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u0430. \u041f\u0440\u0438 \u043d\u0430\u0436\u0430\u0442\u0438\u0438 \u043d\u0430 \u0441\u0442\u0440\u043e\u043a\u0443 \u0432 \u0441\u043e\u0434\u0435\u0440\u0436\u0430\u043d\u0438\u0438 \u043f\u0440\u043e\u0438\u0441\u0445\u043e\u0434\u0438\u0442 \u043f\u0435\u0440\u0435\u0445\u043e\u0434 \u043d\u0430 \u043d\u0443\u0436\u043d\u0443\u044e \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u0443 \u0434\u043e\u043a\u0443\u043c\u0435\u043d\u0442\u0430, \u043d\u043e\u043c\u0435\u0440\u0430 \u0441\u0442\u0440\u0430\u043d\u0438\u0446 \u0432\u0435\u0440\u043d\u044b\u0435. <\/p>\n<p>  <\/p>\n<p>\u041d\u0435 \u0434\u043e \u043a\u043e\u043d\u0446\u0430 \u043f\u043e\u043d\u044f\u0442\u043d\u043e \u043f\u043e\u043a\u0430 \u043a\u0430\u043a \u043d\u0430\u0441\u0442\u0440\u0430\u0438\u0432\u0430\u0442\u044c \u0441\u0442\u0438\u043b\u0438, \u043d\u043e \u044f \u043f\u043e\u043a\u0430 \u044d\u0442\u0438\u043c \u043d\u0435 \u0437\u0430\u043d\u0438\u043c\u0430\u043b\u0441\u044f.<\/p>\n<p>  <\/p>\n<h3 id=\"javascript-execution\">JavaScript Execution<\/h3>\n<p>  <\/p>\n<p>\u0421\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u0439 \u043c\u043e\u043c\u0435\u043d\u0442, \u0441 \u043a\u043e\u0442\u043e\u0440\u044b\u043c \u044f \u0441\u0442\u043e\u043b\u043a\u043d\u0443\u043b\u0441\u044f, \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e\u0441\u0442\u044c \u0434\u043e\u0431\u0430\u0432\u0438\u0442\u044c \u0432 \u043e\u0442\u0447\u0435\u0442 \u0433\u0440\u0430\u0444\u0438\u043a\u0438. \u041c\u043e\u044f HTML \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u0430 \u0441\u043e\u0434\u0435\u0440\u0436\u0438\u0442 JS \u043a\u043e\u0434, \u0434\u043e\u0431\u0430\u0432\u043b\u044f\u044e\u0449\u0438\u0439 \u0433\u0440\u0430\u0444\u0438\u043a\u0438 \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0438 <code>dc.js<\/code>. \u0412\u043e\u0442 \u043f\u0440\u0438\u043c\u0435\u0440:<\/p>\n<p>  <\/p>\n<pre><code>function initChart() {     renderChart(@Html.Raw(Json.Encode(Model.Chart_1_Data)), 'chartDiv_1'); }  function renderChart(data, chartElementId) {     var colors = ['#03a9f4', '#67daff', '#8bc34a'];     var barHeight = 45;     var clientHeight = data.length * barHeight + 50;     var clientWidth = document.getElementById(chartId).offsetWidth;      var chart = dc.rowChart('#' + chartElementId);     var ndx = crossfilter(dataToRender);     var dimension = ndx.dimension(d =&gt; d.name);     var group = dimension.group().reduceSum(d =&gt; d.value);      chart         .width(clientWidth)         .height(clientHeight)         .margins({ top: 16, right: 16, bottom: 16, left: 16 })         .ordinalColors(colors)         .dimension(dimension)         .group(group)         .xAxis()         .scale(d3.scaleLinear().domain([0, 2]).range([1, 3]).nice());     chart.render(); }<\/code><\/pre>\n<p>  <\/p>\n<p>\u041f\u0440\u0438 \u044d\u0442\u043e\u043c \u0432 HTML \u0443 \u043c\u0435\u043d\u044f \u0435\u0441\u0442\u044c \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0432\u0443\u044e\u0449\u0438\u0439 \u044d\u043b\u0435\u043c\u0435\u043d\u0442:<\/p>\n<p>  <\/p>\n<pre><code class=\"html\">&lt;div id=&quot;chart_C2&quot; class=&quot;dc-chart&quot;&gt;&lt;\/div&gt;<\/code><\/pre>\n<p>  <\/p>\n<p>\u0414\u043b\u044f \u0440\u0430\u0431\u043e\u0442\u043e\u0441\u043f\u043e\u0441\u043e\u0431\u043d\u043e\u0441\u0442\u0438 \u044d\u0442\u043e\u0433\u043e \u043a\u043e\u0434\u0430 \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u0438\u043c\u043f\u043e\u0440\u0442\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0443\u044e\u0449\u0438\u0435 \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0438: <code>dc.js<\/code>, <code>d3.js<\/code>, <code>crossfilter.js<\/code>. \u0412\u044b\u0437\u043e\u0432 \u0444\u0443\u043d\u043a\u0446\u0438\u0438 <code>initChart<\/code> \u0441\u043e\u0437\u0434\u0430\u0441\u0442 \u0433\u0440\u0430\u0444\u0438\u043a \u0438 \u0432\u0441\u0442\u0430\u0432\u0438\u0442 \u043f\u043e\u043b\u0443\u0447\u0435\u043d\u043d\u044b\u0439<br \/>  svg \u0432 \u0443\u043a\u0430\u0437\u0430\u043d\u043d\u044b\u0439 \u044d\u043b\u0435\u043c\u0435\u043d\u0442 \u0432 \u0434\u0435\u0440\u0435\u0432\u0435.<\/p>\n<p>  <\/p>\n<p>\u041d\u043e PDF \u043d\u0435 \u0441\u043e\u0434\u0435\u0440\u0436\u0438\u0442 \u0438 \u0441\u043b\u0435\u0434\u0430 \u0433\u0440\u0430\u0444\u0438\u043a\u043e\u0432. \u041a\u0430\u043a \u0432\u043f\u0440\u043e\u0447\u0435\u043c \u0438 \u043b\u044e\u0431\u043e\u0433\u043e \u0434\u0440\u0443\u0433\u043e \u0441\u043b\u0435\u0434\u0430 \u0432\u044b\u043f\u043e\u043b\u043d\u0435\u043d\u0438\u044f JavaScript \u043a\u043e\u0434\u0430 \u043f\u0435\u0440\u0435\u0434 \u0440\u0435\u043d\u0434\u0435\u0440\u0438\u043d\u0433\u043e\u043c PDF. \u041f\u0440\u043e\u0432\u0435\u0440\u0438\u0442\u044c \u044d\u0442\u043e \u0434\u043e\u0432\u043e\u043b\u044c\u043d\u043e \u043b\u0435\u0433\u043a\u043e \u2014 \u0441\u0442\u043e\u0438\u0442 \u043b\u0438\u0448\u044c \u0434\u043e\u0431\u0430\u0432\u0438\u0442\u044c \u044d\u043b\u0435\u043c\u0435\u043d\u0442\u0430\u0440\u043d\u044b\u0439 \u043a\u043e\u0434 \u0441\u043e\u0437\u0434\u0430\u043d\u0438\u044f \u043f\u0440\u043e\u0441\u0442\u043e\u0433\u043e <code>&lt;div&gt;<\/code> \u044d\u043b\u0435\u043c\u0435\u043d\u0442\u0430 \u0441 \u0442\u0435\u043a\u0441\u0442\u043e\u043c, \u043f\u0440\u043e\u0441\u0442\u043e \u0434\u043b\u044f \u0442\u0435\u0441\u0442\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f \u0444\u0430\u043a\u0442\u0430 \u0432\u044b\u0437\u043e\u0432\u0430 JavaScript.<\/p>\n<p>  <\/p>\n<p>\u041e\u043f\u044b\u0442\u043d\u044b\u043c \u043f\u0443\u0442\u0435\u043c \u0432\u044b\u044f\u0441\u043d\u0438\u043b\u043e\u0441\u044c, \u0447\u0442\u043e \u043c\u0435\u0441\u0442\u043e\u043f\u043e\u043b\u043e\u0436\u0435\u043d\u0438\u044f JS \u043a\u043e\u0434\u0430 \u0434\u043b\u044f <code>wkhtmltopdf<\/code> \u0438\u0433\u0440\u0430\u0435\u0442 \u0441\u0443\u0449\u0435\u0441\u0442\u0432\u0435\u043d\u043d\u0443\u044e \u0440\u043e\u043b\u044c. \u0420\u0430\u0441\u043f\u043e\u043b\u043e\u0436\u0435\u043d\u043d\u044b\u0439 \u0432 \u043a\u043e\u043d\u0446\u0435 <code>&lt;html&gt;<\/code> \u0438\u043b\u0438 \u0441\u043a\u0430\u0436\u0435\u043c \u0432 \u043a\u043e\u043d\u0446\u0435 <code>&lt;body&gt;<\/code> JS \u043a\u043e\u0434 \u0432\u044b\u043f\u043e\u043b\u043d\u0435\u043d \u043d\u0435 \u0431\u0443\u0434\u0435\u0442. \u0422\u0430\u043a\u043e\u0435 \u043e\u0449\u0443\u0449\u0435\u043d\u0438\u0435, \u0447\u0442\u043e \u0443\u0442\u0438\u043b\u0438\u0442\u0430 \u0435\u0433\u043e \u043f\u0440\u043e\u0441\u0442\u043e \u043d\u0435 \u0437\u0430\u043c\u0435\u0447\u0430\u0435\u0442, \u0438\u043b\u0438 \u043d\u0435 \u043e\u0436\u0438\u0434\u0430\u0435\u0442 \u0435\u0433\u043e \u0442\u0430\u043c \u0432\u0441\u0442\u0440\u0435\u0442\u0438\u0442\u044c. <\/p>\n<p>  <\/p>\n<p>\u0410 \u0432\u043e\u0442 \u043a\u043e\u0434, \u0440\u0430\u0441\u043f\u043e\u043b\u043e\u0436\u0435\u043d\u043d\u044b\u0439 \u0432\u043d\u0443\u0442\u0440\u0438 <code>&lt;head&gt;<\/code> \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u0435\u0442\u0441\u044f. \u0422\u0430\u043a\u0438\u043c \u043e\u0431\u0440\u0430\u0437\u043e\u043c \u044f \u043f\u0440\u0438\u0448\u0435\u043b \u043a \u0441\u0445\u0435\u043c\u0435, \u043a\u043e\u0433\u0434\u0430 JavaScript \u043a\u043e\u0434 \u0440\u0430\u0441\u043f\u043e\u043b\u0430\u0433\u0430\u0435\u0442\u0441\u044f \u043f\u043e\u0441\u043b\u0435 \u043e\u0431\u044a\u044f\u0432\u043b\u0435\u043d\u0438\u044f \u0441\u0442\u0438\u043b\u0435\u0439 \u0432\u043d\u0443\u0442\u0440\u0438 \u0442\u044d\u0433\u0430 <code>&lt;head&gt;<\/code>, \u0438 \u0432\u044b\u0437\u044b\u0432\u0430\u0435\u0442\u0441\u044f \u043e\u0431\u044b\u0447\u043d\u043e\u0439 \u043a\u043e\u043d\u0441\u0442\u0440\u0443\u043a\u0446\u0438\u0435\u0439:<\/p>\n<p>  <\/p>\n<pre><code>&lt;body onload=&quot;initCharts()&quot;&gt;<\/code><\/pre>\n<p>  <\/p>\n<p>\u0412 \u0442\u0430\u043a\u043e\u043c \u0441\u043b\u0443\u0447\u0430\u0435 \u043a\u043e\u0434 \u0431\u0443\u0434\u0435\u0442 \u0432\u044b\u043f\u043e\u043b\u043d\u0435\u043d \u043e\u0436\u0438\u0434\u0430\u0435\u043c\u044b\u043c \u043e\u0431\u0440\u0430\u0437\u043e\u043c.<\/p>\n<p>  <\/p>\n<h3 id=\"javascript-limitations\">JavaScript Limitations<\/h3>\n<p>  <\/p>\n<p>\u041d\u043e \u0433\u0440\u0430\u0444\u0438\u043a\u043e\u0432 \u0432 \u0432\u044b\u0445\u043e\u0434\u043d\u043e\u043c PDF \u0432\u0441\u0435 \u0440\u0430\u0432\u043d\u043e \u043d\u0435 \u0431\u044b\u043b\u043e. \u0422\u0443\u0442 \u044f \u043d\u0430\u0447\u0430\u043b \u0434\u043e\u0433\u0430\u0434\u044b\u0432\u0430\u0442\u044c\u0441\u044f, \u0447\u0442\u043e \u0431\u0443\u0434\u0443\u0447\u0438 \u043d\u0435 \u043f\u043e\u043b\u043d\u043e\u0446\u0435\u043d\u043d\u044b\u043c \u0431\u0440\u0430\u0443\u0437\u0435\u0440\u043e\u043c, \u0434\u0432\u0438\u0436\u043e\u043a \u0440\u0435\u043d\u0434\u0435\u0440\u0438\u043d\u0433\u0430 \u0438 \u0438\u0441\u043f\u043e\u043b\u043d\u0435\u043d\u0438\u044f pdf \u0441\u043a\u043e\u0440\u0435\u0435 \u0432\u0441\u0435\u0433\u043e \u043d\u0435 \u0441\u043e\u0432\u0435\u0440\u0448\u0435\u043d\u0435\u043d \u0438 \u043d\u0435 \u043f\u043e\u043d\u0438\u043c\u0430\u0435\u0442 \u043f\u043e\u0441\u043b\u0435\u0434\u043d\u0438\u0445 \u043f\u0440\u0430\u0432\u0438\u043b. \u041e\u043f\u044f\u0442\u044c \u0436\u0435 \u043e\u043f\u044b\u0442\u043d\u044b\u043c \u043f\u0443\u0442\u0435\u043c \u044f \u0432\u044b\u044f\u0441\u043d\u0438\u043b, \u0447\u0442\u043e \u0441\u0442\u0440\u0435\u043b\u043e\u0447\u043d\u044b\u0435 \u0444\u0443\u043d\u043a\u0446\u0438\u0438 \u043d\u0435 \u0432\u043e\u0441\u043f\u0440\u0438\u043d\u0438\u043c\u0430\u044e\u0442\u0441\u044f. \u041f\u0440\u0438\u0447\u0435\u043c \u0435\u0441\u043b\u0438 \u0438\u043d\u0442\u0435\u0440\u043f\u0440\u0435\u0442\u0430\u0442\u043e\u0440 \u043d\u0430\u0445\u043e\u0434\u0438\u0442 \u0447\u0442\u043e-\u0442\u043e \u0434\u043b\u044f \u043d\u0435\u0433\u043e \u043d\u0435\u0438\u0437\u0432\u0435\u0441\u0442\u043d\u043e\u0435, \u0442\u043e \u043e\u043d \u043f\u0440\u043e\u0441\u0442\u043e \u043f\u0435\u0440\u0435\u0441\u0442\u0430\u0435\u0442 \u0440\u0430\u0431\u043e\u0442\u0430\u0442\u044c. <\/p>\n<p>  <\/p>\n<p>\u0417\u0430\u043c\u0435\u043d\u0430 \u0441\u0442\u0440\u0435\u043b\u043e\u0447\u043d\u044b\u0445 \u0444\u0443\u043d\u043a\u0446\u0438\u0439 \u0432\u0438\u0434\u0430 <code>x =&gt; x.value<\/code> \u043d\u0430 \u0431\u043e\u043b\u0435\u0435 \u043a\u043b\u0430\u0441\u0441\u0438\u0447\u0435\u0441\u043a\u0438\u0435 <code>function(x) { return x.value; }<\/code> \u043f\u043e\u043c\u043e\u0433\u043b\u0430 \u0438 \u0432\u0435\u0441\u044c \u043a\u043e\u0434 \u0431\u044b\u043b \u0432\u044b\u043f\u043e\u043b\u043d\u0435\u043d, \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0438\u0440\u0443\u044e\u0449\u0438\u0439 \u0433\u0440\u0430\u0444\u0438\u043a \u043f\u043e\u043f\u0430\u043b \u0432 PDF \u0444\u0430\u0439\u043b.<\/p>\n<p>  <\/p>\n<h3 id=\"chart-width\">Chart Width<\/h3>\n<p>  <\/p>\n<p>\u041e\u043f\u044b\u0442\u043d\u044b\u043c \u043f\u0443\u0442\u0435\u043c \u0432\u044b\u044f\u0441\u043d\u0438\u043b\u043e\u0441\u044c, \u0447\u0442\u043e \u043e\u0431\u044f\u0437\u0430\u0442\u0435\u043b\u044c\u043d\u043e \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u0447\u0435\u0442\u043a\u043e \u0443\u043a\u0430\u0437\u0430\u0442\u044c \u0448\u0438\u0440\u0438\u043d\u0443 \u0440\u043e\u0434\u0438\u0442\u0435\u043b\u044c\u0441\u043a\u043e\u0433\u043e \u044d\u043b\u0435\u043c\u0435\u043d\u0442\u0430 \u0433\u0440\u0430\u0444\u0438\u043a\u0430. \u0414\u043b\u044f \u044d\u0442\u043e\u0433\u043e \u044f \u0443\u043a\u0430\u0437\u0430\u043b \u0441\u0442\u0438\u043b\u044c <code>dc-chart<\/code>. \u041e\u043d \u0441\u043e\u0434\u0435\u0440\u0436\u0438\u0442 \u0448\u0438\u0440\u0438\u043d\u0443 \u0433\u0440\u0430\u0444\u0438\u043a\u0430 \u0432 \u043f\u0438\u043a\u0441\u0435\u043b\u044f\u0445. \u0412 \u043f\u0440\u043e\u0442\u0438\u0432\u043d\u043e\u043c \u0441\u043b\u0443\u0447\u0430\u0435 \u0433\u0440\u0430\u0444\u0438\u043a \u043d\u0430 PDF \u043e\u043a\u0430\u0436\u0435\u0442\u0441\u044f \u043e\u0447\u0435\u043d\u044c \u043c\u0430\u043b\u0435\u043d\u044c\u043a\u0438\u043c, \u043d\u0435\u0441\u043c\u043e\u0442\u0440\u044f \u043d\u0430 \u0442\u043e, \u0447\u0442\u043e \u0432 HTML \u0432\u0435\u0440\u0441\u0438\u0438 \u043e\u043d \u0437\u0430\u0439\u043c\u0435\u0442 \u0432\u0441\u044e \u0448\u0438\u0440\u0438\u043d\u0443. \u0423\u043a\u0430\u0437\u0430\u043d\u0438\u0435 \u0448\u0438\u0440\u0438\u043d\u044b \u0432 \u043f\u0440\u043e\u0446\u0435\u043d\u0442\u0430\u0445 \u0441\u0440\u0430\u0431\u043e\u0442\u0430\u0435\u0442 \u0442\u043e\u043b\u044c\u043a\u043e \u0434\u043b\u044f HTML.<\/p>\n<p>  <\/p>\n<h3 id=\"inline-javascript--css\">Inline JavaScript \/ CSS<\/h3>\n<p>  <\/p>\n<p>\u041d\u0430\u043f\u043e\u0441\u043b\u0435\u0434\u043e\u043a \u044f \u0431\u044b \u0445\u043e\u0442\u0435\u043b \u043e\u0442\u043c\u0435\u0442\u0438\u0442\u044c, \u0447\u0442\u043e \u043c\u043d\u043e\u0433\u0438\u0435 \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0438 \u043a\u043e\u043d\u0432\u0435\u0440\u0442\u0430\u0446\u0438\u0438 HTML \u0432 PDF \u043f\u0440\u0438\u043d\u0438\u043c\u0430\u044e\u0442 \u043d\u0435\u043a\u0438\u0439 baseUrl \u043a\u0430\u043a \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440. \u042d\u0442\u043e URL, \u043d\u0430 \u043e\u0441\u043d\u043e\u0432\u0435 \u043a\u043e\u0442\u043e\u0440\u043e\u0433\u043e \u043a\u043e\u043d\u0432\u0435\u0440\u0442\u0435\u0440 \u0431\u0443\u0434\u0435\u0442 \u0434\u043e\u0441\u0442\u0440\u0430\u0438\u0432\u0430\u0442\u044c \u043e\u0442\u043d\u043e\u0441\u0438\u0442\u0435\u043b\u044c\u043d\u044b\u0435 \u043f\u0443\u0442\u0438 \u0434\u043b\u044f \u043f\u043e\u043b\u0443\u0447\u0435\u043d\u0438\u044f \u0438\u043c\u043f\u043e\u0440\u0442\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u044b\u0445 CSS \u0441\u0442\u0438\u043b\u0435\u0439, JavaScirpt \u0444\u0430\u0439\u043b\u043e\u0432 \u0438\u043b\u0438 \u0448\u0440\u0438\u0444\u0442\u043e\u0432. \u042f \u043d\u0435 \u043c\u043e\u0433\u0443 \u0442\u043e\u0447\u043d\u043e \u0443\u0442\u0432\u0435\u0440\u0436\u0434\u0430\u0442\u044c \u043a\u0430\u043a \u044d\u0442\u043e \u0440\u0430\u0431\u043e\u0442\u0430\u0435\u0442 \u0432 Rotativa, \u043d\u043e \u044f \u043f\u0440\u0438\u0448\u0435\u043b \u043a \u0434\u0440\u0443\u0433\u043e\u043c\u0443 \u043f\u043e\u0434\u0445\u043e\u0434\u0443.<\/p>\n<p>  <\/p>\n<p>\u0414\u043b\u044f \u0443\u0441\u043a\u043e\u0440\u0435\u043d\u0438\u044f \u043f\u0435\u0440\u0432\u0438\u0447\u043d\u043e\u0439 \u0437\u0430\u0433\u0440\u0443\u0437\u043a\u0438 \u043e\u0442\u0447\u0435\u0442\u0430 \u0438 \u0443\u0441\u0442\u0440\u0430\u043d\u0435\u043d\u0438\u044f \u0441\u0430\u043c\u043e\u0433\u043e \u0438\u0441\u0442\u043e\u0447\u043d\u0438\u043a \u043f\u0440\u043e\u0431\u043b\u0435\u043c \u0432\u0441\u0442\u0440\u0430\u0438\u0432\u0430\u043d\u0438\u044f \u0444\u0430\u0439\u043b\u043e\u0432 \u0441\u043a\u0440\u0438\u043f\u0442\u043e\u0432 \u0438\u043b\u0438 \u0441\u0442\u0438\u043b\u0435\u0439 \u043f\u0440\u0438 \u043a\u043e\u043d\u0432\u0435\u0440\u0442\u0430\u0446\u0438\u0438, \u044f \u0432\u0441\u0442\u0440\u0430\u0438\u0432\u0430\u044e \u043d\u0443\u0436\u043d\u044b\u0439 JS \u0438 CSS \u043d\u0435\u043f\u043e\u0441\u0440\u0435\u0434\u0441\u0442\u0432\u0435\u043d\u043d\u043e \u0432 \u0442\u0435\u043b\u043e HTML \u0448\u0430\u0431\u043b\u043e\u043d\u0430.<\/p>\n<p>  <\/p>\n<p>\u0414\u043b\u044f \u044d\u0442\u043e\u0433\u043e \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u0441\u043e\u0437\u0434\u0430\u0442\u044c \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0443\u044e\u0449\u0438\u0435 \u0431\u0430\u043d\u0434\u043b\u044b:<\/p>\n<p>  <\/p>\n<pre><code class=\"cs\">public class BundleConfig {     public static void RegisterBundles(BundleCollection bundles)     {         bundles.Add(new StyleBundle(&quot;~\/Styles\/report-html&quot;)                 .Include(&quot;~\/Styles\/report-common.css&quot;)                 .Include(&quot;~\/Styles\/report-html.css&quot;)         );          bundles.Add(new StyleBundle(&quot;~\/Styles\/report-pdf&quot;)                 .Include(&quot;~\/Styles\/report-common.css&quot;)                 .Include(&quot;~\/Styles\/report-pdf.css&quot;)         );          bundles.Add(new ScriptBundle(&quot;~\/Scripts\/charts&quot;)                 .Include(&quot;~\/Scripts\/d3\/d3.js&quot;)                 .Include(&quot;~\/Scripts\/crossfilter\/crossfilter.js&quot;)                 .Include(&quot;~\/Scripts\/dc\/dc.js&quot;)         );     } }<\/code><\/pre>\n<p>  <\/p>\n<p>\u0414\u043e\u0431\u0430\u0432\u0438\u0442\u044c \u0432\u044b\u0437\u043e\u0432 \u043a\u043e\u043d\u0444\u0438\u0433\u0443\u0440\u0430\u0446\u0438\u0438 \u044d\u0442\u0438\u0445 \u0431\u0430\u043d\u0434\u043b\u043e\u0432 \u0432 <code>Global.asax.cs<\/code><\/p>\n<p>  <\/p>\n<pre><code class=\"cs\">protected void Application_Start() {     ...     BundleConfig.RegisterBundles(BundleTable.Bundles); }<\/code><\/pre>\n<p>  <\/p>\n<p>\u0418 \u0434\u043e\u0431\u0430\u0432\u0438\u0442\u044c \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0443\u044e\u0449\u0438\u0439 \u043c\u0435\u0442\u043e\u0434 \u0434\u043b\u044f \u0432\u0441\u0442\u0440\u0430\u0438\u0432\u0430\u043d\u0438\u044f \u043a\u043e\u0434\u0430 \u0432 \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u0443. \u0415\u0433\u043e \u043d\u0443\u0436\u043d\u043e \u0440\u0430\u0437\u043c\u0435\u0441\u0442\u0438\u0442\u044c \u0432 \u0442\u043e\u043c \u0436\u0435 namespace, \u0447\u0442\u043e \u0438 <code>Global.asax.cs<\/code>, \u0447\u0442\u043e\u0431\u044b \u043c\u0435\u0442\u043e\u0434 \u043c\u043e\u0436\u043d\u043e \u0431\u044b\u043b\u043e \u0432\u044b\u0437\u0432\u0430\u0442\u044c \u0438\u0437 HTML \u0448\u0430\u0431\u043b\u043e\u043d\u0430:<\/p>\n<p>  <\/p>\n<pre><code class=\"cs\">public static class HtmlHelperExtensions {     public static IHtmlString InlineStyles(this HtmlHelper htmlHelper, string bundleVirtualPath)     {         string bundleContent = LoadBundleContent(htmlHelper.ViewContext.HttpContext, bundleVirtualPath);         string htmlTag = $&quot;&lt;style rel=\\&quot;stylesheet\\&quot; type=\\&quot;text\/css\\&quot;&gt;{bundleContent}&lt;\/style&gt;&quot;;         return new HtmlString(htmlTag);     }      public static IHtmlString InlineScripts(this HtmlHelper htmlHelper, string bundleVirtualPath)     {         string bundleContent = LoadBundleContent(htmlHelper.ViewContext.HttpContext, bundleVirtualPath);         string htmlTag = $&quot;&lt;script type=\\&quot;text\/javascript\\&quot;&gt;{bundleContent}&lt;\/script&gt;&quot;;         return new HtmlString(htmlTag);     }      private static string LoadBundleContent(HttpContextBase httpContext, string bundleVirtualPath)     {         var bundleContext = new BundleContext(httpContext, BundleTable.Bundles, bundleVirtualPath);         var bundle = BundleTable.Bundles.Single(b =&gt; b.Path == bundleVirtualPath);         var bundleResponse = bundle.GenerateBundleResponse(bundleContext);         return bundleResponse.Content;     } }<\/code><\/pre>\n<p>  <\/p>\n<p>\u041d\u0443 \u0438 \u0444\u0438\u043d\u0430\u043b\u044c\u043d\u044b\u0439 \u0448\u0442\u0440\u0438\u0445 \u2014 \u0432\u044b\u0437\u043e\u0432 \u0438\u0437 \u0448\u0430\u0431\u043b\u043e\u043d\u0430:<\/p>\n<p>  <\/p>\n<pre><code class=\"html\">@Html.InlineStyles(&quot;~\/Styles\/report-pdf&quot;); @Html.InlineScripts(&quot;~\/Scripts\/charts&quot;);<\/code><\/pre>\n<p>  <\/p>\n<p>\u0412 \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442\u0435 \u0432\u0435\u0441\u044c \u043d\u0443\u0436\u043d\u044b\u0439 CSS \u0438 JavaScript \u043e\u043a\u0430\u0436\u0435\u0442\u0441\u044f \u043d\u0435\u043f\u043e\u0441\u0440\u0435\u0434\u0441\u0442\u0432\u0435\u043d\u043d\u043e \u0432 HTML, \u0445\u043e\u0442\u044f \u043f\u0440\u0438 \u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u043a\u0435 \u043c\u043e\u0436\u043d\u043e \u0440\u0430\u0431\u043e\u0442\u0430\u0442\u044c \u0441 \u043e\u0442\u0434\u0435\u043b\u044c\u043d\u044b\u043c\u0438 \u0444\u0430\u0439\u043b\u0430\u043c\u0438.<\/p>\n<p>  <\/p>\n<p>\u0421\u043a\u043e\u0440\u0435\u0435 \u0432\u0441\u0435\u0433\u043e, \u043c\u043d\u043e\u0433\u0438\u0435 \u0441\u0440\u0430\u0437\u0443 \u0436\u0435 \u043f\u043e\u0434\u0443\u043c\u0430\u044e\u0442 \u043e \u043d\u0435\u044d\u0444\u0444\u0435\u043a\u0442\u0438\u0432\u043d\u043e\u0441\u0442\u0438 \u0442\u0430\u043a\u043e\u0433\u043e \u043f\u043e\u0434\u0445\u043e\u0434\u0430 \u0441 \u0442\u043e\u0447\u043a\u0438 \u0437\u0440\u0435\u043d\u0438\u044f \u043a\u044d\u0448\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f \u0437\u0430\u043f\u0440\u043e\u0441\u043e\u0432 \u0431\u0440\u0430\u0443\u0437\u0435\u0440\u043e\u043c. \u041d\u043e \u044f \u043f\u0440\u0435\u0441\u043b\u0435\u0434\u043e\u0432\u0430\u043b \u0434\u0432\u0435 \u043a\u043e\u043d\u043a\u0440\u0435\u0442\u043d\u044b\u0435 \u0446\u0435\u043b\u0438:<\/p>\n<p>  <\/p>\n<ul>\n<li>\u0447\u0442\u043e\u0431\u044b PDF \u043a\u043e\u043d\u0432\u0435\u0440\u0442\u0435\u0440\u0443 \u043d\u0435 \u043f\u0440\u0438\u0445\u043e\u0434\u0438\u043b\u043e\u0441\u044c \u0434\u0435\u043b\u0430\u0442\u044c \u0437\u0430\u043f\u0440\u043e\u0441\u044b \u043a\u0443\u0434\u0430-\u0442\u043e \u0437\u0430 \u0441\u0442\u0438\u043b\u044f\u043c\u0438 \u0438\u043b\u0438 \u043a\u043e\u0434\u043e\u043c, \u0430 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044e \u0436\u0434\u0430\u0442\u044c \u044d\u0442\u043e\u0433\u043e, \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0435\u043d\u043d\u043e;<\/li>\n<li>\u0447\u0442\u043e\u0431\u044b \u043f\u0435\u0440\u0432\u0430\u044f \u0437\u0430\u0433\u0440\u0443\u0437\u043a\u0430 PDF \u0438 HTML \u043e\u0442\u0447\u0435\u0442\u0430 \u0437\u0430\u043d\u0438\u043c\u0430\u043b\u0430 \u043c\u0438\u043d\u0438\u043c\u0430\u043b\u044c\u043d\u043e\u0435 \u0432\u0440\u0435\u043c\u044f, \u0431\u0435\u0437 \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e\u0441\u0442\u0438 \u043e\u0436\u0438\u0434\u0430\u043d\u0438\u044f \u043d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u0438\u0445 \u0434\u043e\u043f\u043e\u043b\u043d\u0438\u0442\u0435\u043b\u044c\u043d\u044b\u0445 \u0437\u0430\u043f\u0440\u043e\u0441. \u0412 \u0443\u0441\u043b\u043e\u0432\u0438\u044f\u0445 \u043c\u043e\u0435\u0433\u043e \u043f\u0440\u043e\u0435\u043a\u0442\u0430 \u044d\u0442\u043e \u0432\u0430\u0436\u043d\u043e;<\/li>\n<\/ul>\n<p>  <\/p>\n<h3 id=\"page-breaks\">Page Breaks<\/h3>\n<p>  <\/p>\n<p>\u0421\u0442\u0440\u0443\u043a\u0442\u0443\u0440\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435 \u043e\u0442\u0447\u0435\u0442\u0430 \u043d\u0430 \u0440\u0430\u0437\u0434\u0435\u043b\u044b \u043c\u043e\u0436\u0435\u0442 \u0441\u043e\u043f\u0440\u043e\u0432\u043e\u0436\u0434\u0430\u0442\u044c\u0441\u044f \u0442\u0440\u0435\u0431\u043e\u0432\u0430\u043d\u0438\u044f\u043c\u0438 \u043d\u0430\u0447\u0430\u0442\u044c \u043d\u043e\u0432\u044b\u0439 \u0440\u0430\u0437\u0434\u0435\u043b \u0441 \u043d\u043e\u0432\u043e\u0439 \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u044b. \u0412 \u0442\u0430\u043a\u043e\u043c \u0441\u043b\u0443\u0447\u0430\u0435 \u043c\u043e\u0436\u043d\u043e \u0443\u0441\u043f\u0435\u0448\u043d\u043e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u043f\u0440\u043e\u0441\u0442\u043e\u0439 CSS \u043f\u043e\u0434\u0445\u043e\u0434:<\/p>\n<p>  <\/p>\n<pre><code class=\"css\">.page-break-before {     page-break-before: always; }  .no-page-break-inside {     page-break-before: auto;     page-break-inside: avoid; }<\/code><\/pre>\n<p>  <\/p>\n<p>wkhtmltopdf \u0443\u0442\u0438\u043b\u0438\u0442\u044b \u0443\u0441\u043f\u0435\u0448\u043d\u043e \u0441\u0447\u0438\u0442\u044b\u0432\u0430\u0435\u0442 \u0434\u0430\u043d\u043d\u044b\u0435 \u043a\u043b\u0430\u0441\u0441\u044b \u0438 \u043f\u043e\u043d\u0438\u043c\u0430\u0435\u0442, \u0447\u0442\u043e \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u043d\u0430\u0447\u0430\u0442\u044c \u043d\u043e\u0432\u0443\u044e \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u0443. \u041f\u0435\u0440\u0432\u044b\u0439 \u043a\u043b\u0430\u0441\u0441 \u2014 <code>page-break-before<\/code> \u2014 \u043f\u043e\u0434\u0441\u043a\u0430\u0437\u044b\u0432\u0430\u0435\u0442 \u0443\u0442\u0438\u043b\u0438\u0442\u0435 \u0432\u0441\u0435\u0433\u0434\u0430 \u043d\u0430\u0447\u0438\u043d\u0430\u0442\u044c \u044d\u0442\u0438\u043c \u044d\u043b\u0435\u043c\u0435\u043d\u0442\u043e\u043c \u043d\u043e\u0432\u0443\u044e \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u0443. \u0412\u0442\u043e\u0440\u043e\u0439 \u043a\u043b\u0430\u0441\u0441 \u2014 <code>no-page-break-inside<\/code> \u2014 \u0441\u0442\u043e\u0438\u0442 \u043f\u0440\u0438\u043c\u0435\u043d\u044f\u0442\u044c \u043a \u0442\u0435\u043c \u044d\u043b\u0435\u043c\u0435\u043d\u0442\u0430\u043c, \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u0436\u0435\u043b\u0430\u0442\u0435\u043b\u044c\u043d\u043e \u0441\u043e\u0445\u0440\u0430\u043d\u0438\u0442\u044c \u043c\u0430\u043a\u0441\u0438\u043c\u0430\u043b\u044c\u043d\u043e \u0446\u0435\u043b\u044b\u043c\u0438 \u043d\u0430 \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u0435. \u041d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, \u0443 \u0432\u0430\u0441 \u0435\u0441\u0442\u044c \u043f\u043e\u0434\u0440\u044f\u0434 \u0438\u0434\u0443\u0449\u0438\u0435 \u0431\u043b\u043e\u043a\u0438 \u0441\u0442\u0440\u0443\u043a\u0442\u0443\u0440\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u043e\u0439 \u0438\u043d\u0444\u043e\u0440\u043c\u0430\u0446\u0438\u0438, \u0438\u043b\u0438 \u0441\u043a\u0430\u0436\u0435\u043c \u0442\u0430\u0431\u043b\u0438\u0446\u044b. \u0415\u0441\u043b\u0438 \u0434\u0432\u0430 \u0431\u043b\u043e\u043a\u0430 \u0443\u043c\u0435\u0449\u0430\u044e\u0442\u0441\u044f \u043d\u0430 \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u0443 \u2014 \u043e\u043d\u0438 \u0442\u0430\u043a \u0438 \u0440\u0430\u0441\u043f\u043e\u043b\u043e\u0436\u0430\u0442\u0441\u044f. \u0415\u0441\u043b\u0438 \u0442\u0440\u0435\u0442\u0438\u0439 \u0443\u0436\u0435 \u043d\u0435 \u0432\u043b\u0435\u0437\u0430\u0435\u0442 \u0432 \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u0443 \u2014 \u043e\u043d \u0431\u0443\u0434\u0435\u0442 \u043d\u0435 \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0435\u0439. \u0415\u0441\u043b\u0438 \u043e\u043d \u0431\u043e\u043b\u044c\u0448\u0435 \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u044b \u2014 \u0442\u0443\u0442 \u0443\u0436\u0435 \u043d\u0435\u0438\u0437\u0431\u0435\u0436\u0435\u043d \u0435\u0433\u043e \u043f\u0435\u0440\u0435\u043d\u043e\u0441. \u0420\u0430\u0431\u043e\u0442\u0430\u0435\u0442 \u0432\u0441\u0435 \u044d\u0442\u043e \u0430\u0434\u0435\u043a\u0432\u0430\u0442\u043d\u043e \u0438 \u0443\u0434\u043e\u0431\u043d\u043e.<\/p>\n<p>  <\/p>\n<h3 id=\"flex-behavior-in-wkhtmltopdf\">Flex Behavior in wkhtmltopdf<\/h3>\n<p>  <\/p>\n<p>\u041d\u0443 \u0438 \u043f\u043e\u0441\u043b\u0435\u0434\u043d\u044f\u044f \u0437\u0430\u043c\u0435\u0447\u0435\u043d\u043d\u0430\u044f \u043c\u043d\u043e\u0439 \u043e\u0441\u043e\u0431\u0435\u043d\u043d\u043e\u0441\u0442\u044c \u0441\u0432\u044f\u0437\u0430\u043d\u0430 \u0441 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435\u043c flexbox \u0441\u0442\u0438\u043b\u0435\u0439 \u0440\u0430\u0437\u043c\u0435\u0442\u043a\u0438. \u041c\u044b \u0432\u0441\u0435 \u0443\u0436\u0435 \u043f\u0440\u0438\u0432\u044b\u043a\u043b\u0438 \u043a \u043d\u0438\u043c \u0438 \u043f\u043e\u0447\u0442\u0438 \u0432\u0441\u044f \u0440\u0430\u0437\u043c\u0435\u0442\u043a\u0438 \u0441\u0434\u0435\u043b\u0430\u043d\u0430 \u0444\u043b\u0435\u043a\u0441\u0430\u043c\u0438. \u041e\u0434\u043d\u0430\u043a\u043e wkhtmltopdf \u0432 \u044d\u0442\u043e\u043c \u043f\u043b\u0430\u043d\u0435 \u0447\u0443\u0442\u044c \u043e\u0442\u0441\u0442\u0430\u043b. \u0413\u043e\u0440\u0438\u0437\u043e\u043d\u0442\u0430\u043b\u044c\u043d\u044b\u0435 \u043e\u043f\u0446\u0438\u0438 \u0444\u043b\u0435\u043a\u0441\u0430 \u043d\u0435 \u0440\u0430\u0431\u043e\u0442\u0430\u044e\u0442 (\u043f\u043e \u043a\u0440\u0430\u0439\u043d\u0435\u0439 \u043c\u0435\u0440\u0435 \u0432 \u043c\u043e\u0435\u043c \u0441\u043b\u0443\u0447\u0430\u0435 \u044d\u0442\u043e\u0433\u043e \u0434\u043e\u0431\u0438\u0442\u044c\u0441\u044f \u043d\u0435 \u043f\u043e\u043b\u0443\u0447\u0438\u043b\u043e\u0441\u044c. \u042f \u0432\u0438\u0434\u0435\u043b \u0432 \u0441\u0435\u0442\u0438 \u0443\u043f\u043e\u043c\u0438\u043d\u0430\u043d\u0438\u044f, \u0447\u0442\u043e \u0441\u0442\u043e\u0438\u0442 \u0434\u0443\u0431\u043b\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u0444\u043b\u0435\u043a\u0441 \u0441\u0442\u0438\u043b\u0438 \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u043c\u0438:<\/p>\n<p>  <\/p>\n<pre><code class=\"css\">display: -webkit-flex; display: flex;  flex-direction: row; -webkit-flex-direction: row; -webkit-box-pack: justify; \/* wkhtmltopdf uses this one *\/ -webkit-justify-content: space-between; justify-content: space-between;<\/code><\/pre>\n<p>  <\/p>\n<p>\u041d\u043e \u043a \u0441\u043e\u0436\u0430\u043b\u0435\u043d\u0438\u044e \u043a \u043e\u0436\u0438\u0434\u0430\u0435\u043c\u043e\u0439 \u0440\u0430\u0437\u043c\u0435\u0442\u043a\u0435 \u0432 PDF \u044d\u0442\u043e \u043d\u0435 \u043f\u0440\u0438\u0432\u0435\u043b\u043e. \u041c\u043d\u0435 \u043f\u0440\u0438\u0448\u043b\u043e\u0441\u044c \u043f\u0435\u0440\u0435\u0434\u0435\u043b\u044b\u0432\u0430\u0442\u044c \u0440\u0430\u0437\u043c\u0435\u0442\u043a\u0443 \u043d\u0435\u043a\u043e\u0442\u043e\u0440\u044b\u0445 \u044d\u043b\u0435\u043c\u0435\u043d\u0442\u043e\u0432, \u0447\u0442\u043e\u0431\u044b \u0433\u043e\u0440\u0438\u0437\u043e\u043d\u0442\u0430\u043b\u044c\u043d\u043e\u0435 \u0440\u0430\u0437\u043c\u0435\u0449\u0435\u043d\u0438\u0435 \u0431\u043b\u043e\u043a\u043e\u0432 \u0431\u044b\u043b\u043e \u0441\u043e\u0433\u043b\u0430\u0441\u043d\u043e \u0442\u0440\u0435\u0431\u043e\u0432\u0430\u043d\u0438\u044f\u043c. \u0415\u0441\u043b\u0438 \u0443 \u043a\u043e\u0433\u043e-\u0442\u043e \u0435\u0441\u0442\u044c \u0443\u0441\u043f\u0435\u0448\u043d\u044b\u0439 \u043e\u043f\u044b\u0442 \u0438\u043d\u0442\u0435\u0433\u0440\u0430\u0446\u0438\u0438 \u0444\u043b\u0435\u043a\u0441\u043e\u0432 \u0434\u043b\u044f wkhtmltopdf, \u043f\u043e\u0434\u0435\u043b\u0438\u0442\u0435\u0441\u044c, \u043f\u043e\u0436\u0430\u043b\u0443\u0439\u0441\u0442\u0430. \u042d\u0442\u043e \u0431\u044b\u043b\u043e \u0431\u044b \u0432\u0435\u0441\u044c\u043c\u0430 \u043f\u043e\u043b\u0435\u0437\u043d\u043e.<\/p>\n<p>  <\/p>\n<p>\u041d\u0435\u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u0441\u0441\u044b\u043b\u043a\u0438:<\/p>\n<p>  <\/p>\n<ul>\n<li><a href=\"https:\/\/wkhtmltopdf.org\">wkhtmltopdf<\/a><\/li>\n<li><a href=\"https:\/\/wkhtmltopdf.org\/usage\/wkhtmltopdf.txt\">wkhtmltopdf manual<\/a><\/li>\n<li><a href=\"https:\/\/github.com\/webgio\/Rotativa\">Rotativa GitHub<\/a><\/li>\n<li><a href=\"https:\/\/www.nuget.org\/packages\/Rotativa\">Rotativa Package<\/a><\/li>\n<li><a href=\"https:\/\/blog.mariusschulz.com\/2015\/10\/25\/inlining-css-and-javascript-bundles-with-asp-net-mvc\">Inline Styles HowTo<\/a><\/li>\n<\/ul>\n<\/div>\n<p>        <script class=\"js-mediator-script\">!function(e){function t(t,n){if(!(n in e)){for(var r,a=e.document,i=a.scripts,o=i.length;o--;)if(-1!==i[o].src.indexOf(t)){r=i[o];break}if(!r){r=a.createElement(\"script\"),r.type=\"text\/javascript\",r.async=!0,r.defer=!0,r.src=t,r.charset=\"UTF-8\";var d=function(){var e=a.getElementsByTagName(\"script\")[0];e.parentNode.insertBefore(r,e)};\"[object Opera]\"==e.opera?a.addEventListener?a.addEventListener(\"DOMContentLoaded\",d,!1):e.attachEvent(\"onload\",d):d()}}}t(\"\/\/mediator.mail.ru\/script\/2820404\/\",\"_mediator\")}(window);<\/script>     <br \/> \u0441\u0441\u044b\u043b\u043a\u0430 \u043d\u0430 \u043e\u0440\u0438\u0433\u0438\u043d\u0430\u043b \u0441\u0442\u0430\u0442\u044c\u0438 <a href=\"https:\/\/habr.com\/post\/425511\/\"> https:\/\/habr.com\/post\/425511\/<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"\n<div class=\"post__text post__text-html js-mediator-article\">\n<p>\u041c\u043d\u043e\u0433\u0438\u0435 \u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u0447\u0438\u043a\u0438 \u0441\u0442\u0430\u043b\u043a\u0438\u0432\u0430\u044e\u0442\u0441\u044f \u0441 \u0437\u0430\u0434\u0430\u0447\u0435\u0439 \u0441\u043e\u0437\u0434\u0430\u043d\u0438\u044f PDF \u043e\u0442\u0447\u0435\u0442\u043e\u0432 \u0434\u043b\u044f \u0432\u0435\u0431 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0439, \u0432\u043f\u043e\u043b\u043d\u0435 \u0435\u0441\u0442\u0435\u0441\u0442\u0432\u0435\u043d\u043d\u044b\u0439 \u0437\u0430\u043f\u0440\u043e\u0441. \u042f \u0431\u044b \u0445\u043e\u0442\u0435\u043b \u043f\u0440\u0435\u0434\u0441\u0442\u0430\u0432\u0438\u0442\u044c \u0432\u0430\u0448\u0435\u043c\u0443 \u0432\u043d\u0438\u043c\u0430\u043d\u0438\u044e \u0441\u0432\u043e\u0439 \u043e\u043f\u044b\u0442 \u0440\u0430\u0431\u043e\u0442\u044b \u0441 \u0442\u0430\u043a\u043e\u0439 \u0437\u0430\u0434\u0430\u0447\u0435\u0439 \u043f\u0440\u0438 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0438 \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0438 Rotativa \u0434\u043b\u044f \u0433\u0435\u043d\u0435\u0440\u0430\u0446\u0438\u0438 \u043e\u0442\u0447\u0435\u0442\u043e\u0432. \u042d\u0442\u043e \u043e\u0434\u043d\u0430 \u0438\u0437 \u0441\u0430\u043c\u044b\u0445, \u043d\u0430 \u043c\u043e\u0439 \u0432\u0437\u0433\u043b\u044f\u0434, \u0443\u0434\u043e\u0431\u043d\u044b\u0445 \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a \u0434\u043b\u044f \u0442\u0430\u043a\u043e\u0439 \u0446\u0435\u043b\u0438 \u0432 \u0441\u0432\u043e\u0435\u043c \u0441\u0435\u0433\u043c\u0435\u043d\u0442\u0435, \u043d\u043e \u043f\u0440\u0438 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0438 \u0435\u0435 \u044f \u0441\u0442\u043e\u043b\u043a\u043d\u0443\u043b\u0441\u044f \u0441 \u043d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u0438\u043c\u0438 \u043d\u0435 \u043e\u0447\u0435\u0432\u0438\u0434\u043d\u044b\u043c\u0438 \u043c\u043e\u043c\u0435\u043d\u0442\u0430\u043c\u0438, \u043e \u043a\u043e\u0442\u043e\u0440\u044b\u0445 \u0438 \u0445\u043e\u0447\u0443 \u043f\u043e\u0433\u043e\u0432\u043e\u0440\u0438\u0442\u044c.<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[],"tags":[],"class_list":["post-290399","post","type-post","status-publish","format-standard","hentry"],"_links":{"self":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/290399","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=290399"}],"version-history":[{"count":0,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/290399\/revisions"}],"wp:attachment":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=290399"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=290399"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=290399"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}