{"id":312895,"date":"2020-11-10T15:00:33","date_gmt":"2020-11-10T15:00:33","guid":{"rendered":"http:\/\/savepearlharbor.com\/?p=312895"},"modified":"-0001-11-30T00:00:00","modified_gmt":"-0001-11-29T21:00:00","slug":"","status":"publish","type":"post","link":"https:\/\/savepearlharbor.com\/?p=312895","title":{"rendered":"\u041f\u0435\u0447\u0430\u0442\u043d\u044b\u0435 \u0444\u043e\u0440\u043c\u044b \u0434\u043e\u043a\u0443\u043c\u0435\u043d\u0442\u043e\u0432 \u0434\u043b\u044f Eloquent \u0432 0 \u0441\u0442\u0440\u043e\u0447\u0435\u043a \u043a\u043e\u0434\u0430"},"content":{"rendered":"\n<div class=\"post__text post__text-html post__text_v1\" id=\"post-content-body\">\n<p>\u041d\u0435\u0434\u0430\u0432\u043d\u043e \u0432 \u043f\u0440\u043e\u0435\u043a\u0442\u0435 \u043d\u0430 Laravel+Eloquent \u043f\u043e\u043d\u0430\u0434\u043e\u0431\u0438\u043b\u043e\u0441\u044c \u0441\u0434\u0435\u043b\u0430\u0442\u044c \u043f\u0435\u0447\u0430\u0442\u043d\u044b\u0435 \u0444\u043e\u0440\u043c\u044b \u0434\u043e\u043a\u0443\u043c\u0435\u043d\u0442\u043e\u0432 \u2014 \u0441\u0447\u0435\u0442\u043e\u0432, \u0434\u043e\u0433\u043e\u0432\u043e\u0440\u043e\u0432 \u0432 \u0444\u043e\u0440\u043c\u0430\u0442\u0435 Word. \u0422\u0430\u043a \u043a\u0430\u043a \u0432 \u0441\u0438\u0441\u0442\u0435\u043c\u0435 \u043c\u043d\u043e\u0433\u043e \u0440\u0430\u0437\u043d\u044b\u0445 \u0434\u043e\u043a\u0443\u043c\u0435\u043d\u0442\u043e\u0432, \u0442\u043e \u0440\u0435\u0448\u0438\u043b \u0441\u0434\u0435\u043b\u0430\u0442\u044c \u0443\u043d\u0438\u0432\u0435\u0440\u0441\u0430\u043b\u044c\u043d\u043e, \u0447\u0442\u043e\u0431\u044b \u043c\u043e\u0436\u043d\u043e \u0431\u044b\u043b\u043e \u043f\u043e\u0442\u043e\u043c \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u0438 \u0432 \u0434\u0440\u0443\u0433\u0438\u0445 \u043f\u0440\u043e\u0435\u043a\u0442\u0430\u0445.<\/p>\n<p>  <\/p>\n<p>\u0412 \u0438\u0442\u043e\u0433\u0435 \u043f\u043e\u043b\u0443\u0447\u0438\u043b\u0430\u0441\u044c \u0440\u0435\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u044f, \u043a\u043e\u0442\u043e\u0440\u0430\u044f \u0442\u0440\u0435\u0431\u0443\u0435\u0442 \u043c\u0438\u043d\u0438\u043c\u0443\u043c \u0437\u0430\u0442\u0440\u0430\u0442 \u043d\u0430 \u0438\u043d\u0442\u0435\u0433\u0440\u0430\u0446\u0438\u044e \u0432 \u043f\u0440\u043e\u0435\u043a\u0442.<\/p>\n<p>  <\/p>\n<p><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/z2\/il\/3m\/z2il3mcvwahjkdl5c5nqfm_xr1u.png\"><\/p>\n<p><a name=\"habracut\"><\/a>  <\/p>\n<p>\u041a\u0430\u043a \u044f \u0440\u0430\u043d\u044c\u0448\u0435 \u0434\u0435\u043b\u0430\u043b \u043f\u0435\u0447\u0430\u0442\u043d\u044b\u0435 \u0444\u043e\u0440\u043c\u044b. \u0418\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043b \u0440\u0430\u0437\u043d\u044b\u0435 \u043f\u043e\u0434\u0445\u043e\u0434\u044b<\/p>\n<p>  <\/p>\n<ul>\n<li>\u0412 \u0448\u0430\u0431\u043b\u043e\u043d \u0434\u043e\u043a\u0443\u043c\u0435\u043d\u0442\u0430 \u0440\u0430\u0437\u043c\u0435\u0449\u0430\u043b \u0442\u0435\u0433\u0438 \u0438 \u0437\u0430\u043c\u0435\u043d\u044f\u043b \u0438\u0445 \u043f\u0440\u0438 \u0433\u0435\u043d\u0435\u0440\u0430\u0446\u0438\u0438.<\/li>\n<li>\u0413\u0435\u043d\u0435\u0440\u0438\u0440\u043e\u0432\u0430\u043b \u0442\u0435\u043a\u0441\u0442 \u0434\u043e\u043a\u0443\u043c\u0435\u043d\u0442\u0430 \u0441 \u043d\u0443\u043b\u044f.<\/li>\n<li>\u0413\u0435\u043d\u0435\u0440\u0438\u0440\u043e\u0432\u0430\u043b html \u0438 \u043a\u043e\u043d\u0432\u0435\u0440\u0442\u0438\u0440\u043e\u0432\u0430\u043b \u0435\u0433\u043e \u0432 word.<\/li>\n<li>\u0414\u0435\u043b\u0430\u043b \u0441\u0432\u043e\u044e \u0441\u0438\u0441\u0442\u0435\u043c\u0443 \u0434\u043b\u044f \u0433\u0435\u043d\u0435\u0440\u0430\u0446\u0438\u0438 \u0434\u043e\u043a\u0443\u043c\u0435\u043d\u0442\u043e\u0432 \u043f\u043e \u0430\u043d\u0430\u043b\u043e\u0433\u0438\u0438 \u0441 \u0442\u043e\u0439, \u0447\u0442\u043e \u043e\u043f\u0438\u0441\u0430\u043d\u0430 \u0432 \u044d\u0442\u043e\u0439 \u0441\u0442\u0430\u0442\u044c\u0435, \u043d\u043e \u043d\u0430 \u0434\u0440\u0443\u0433\u0438\u0445 \u0442\u0435\u0445\u043d\u043e\u043b\u043e\u0433\u0438\u044f\u0445.<\/li>\n<\/ul>\n<p>  <\/p>\n<p>\u041a\u0430\u0436\u0434\u044b\u0439 \u0432\u0430\u0440\u0438\u0430\u043d\u0442 \u0445\u043e\u0440\u043e\u0448 \u0434\u043b\u044f \u0441\u0432\u043e\u0435\u0439 \u0437\u0430\u0434\u0430\u0447\u0438. \u041d\u043e \u0435\u0441\u043b\u0438 \u0443 \u0432\u0430\u0441 Eloquent, \u0442\u043e \u0432\u0435\u0441\u044c\u043c\u0430 \u0440\u0435\u043a\u043e\u043c\u0435\u043d\u0434\u0443\u044e \u0432\u0430\u0440\u0438\u0430\u043d\u0442, \u043e\u043f\u0438\u0441\u0430\u043d\u043d\u044b\u0439 \u0432 \u044d\u0442\u043e\u0439 \u0441\u0442\u0430\u0442\u044c\u0435.<\/p>\n<p>  <\/p>\n<p>\u0418\u0442\u0430\u043a, \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0430\u0435\u043c \u043f\u0430\u043a\u0435\u0442 <\/p>\n<p>  <\/p>\n<pre><code class=\"bash\">composer require mnvx\/eloquent-print-form<\/code><\/pre>\n<p>  <\/p>\n<p>\u0418 \u043e\u043f\u0438\u0441\u044b\u0432\u0430\u0435\u043c \u043c\u043e\u0434\u0435\u043b\u0438 Eloquent, \u0435\u0441\u043b\u0438 \u043e\u043d\u0438 \u0435\u0449\u0435 \u043d\u0435 \u043e\u043f\u0438\u0441\u0430\u043d\u044b. \u0414\u043e\u043f\u0443\u0441\u0442\u0438\u043c, \u0435\u0441\u0442\u044c \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u0435 \u043c\u043e\u0434\u0435\u043b\u0438.<\/p>\n<p>  <\/p>\n<pre><code class=\"php\">use Illuminate\\Database\\Eloquent\\Model;  \/**  * @property string $number  * @property string $start_at  * @property Customer $customer  * @property ContractAppendix[] $appendixes  *\/ class Contract extends Model {      public function customer()     {         return $this-&gt;belongsTo(Customer::class);     }      public function appendixes()     {         return $this-&gt;hasMany(ContractAppendix::class);     } }  \/**  * @property string $name  * @property CustomerCategory $category  *\/ class Customer extends Model {     public function category()     {         return $this-&gt;belongsTo(CustomerCategory::class);     }  }  \/**  * @property string $number  * @property string $date  * @property float $tax  *\/ class ContractAppendix extends Model {      public function getTaxAttribute()     {         $tax = 0;         foreach ($this-&gt;items as $item) {             $tax += $item-&gt;total_amount * (1 - 100 \/ (100+($item-&gt;taxStatus-&gt;vat_rate ?? 0)));         }         return $tax;     } }<\/code><\/pre>\n<p>  <\/p>\n<p>\u0414\u043b\u044f \u043d\u0430\u0433\u043b\u044f\u0434\u043d\u043e\u0441\u0442\u0438, \u0434\u0438\u0430\u0433\u0440\u0430\u043c\u043c\u0430 \u0441\u0432\u044f\u0437\u0435\u0439<\/p>\n<p>  <\/p>\n<p><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/15\/ax\/1q\/15ax1qz_x6psncnfx-x-c06_lw8.png\"><\/p>\n<p>  <\/p>\n<p>\u0422\u043e \u0435\u0441\u0442\u044c \u043e\u043f\u0438\u0441\u0430\u043d\u0430 \u0442\u0430\u0431\u043b\u0438\u0446\u0430 \u0441 \u0434\u043e\u0433\u043e\u0432\u043e\u0440\u0430\u043c\u0438 (<code>Contract<\/code>), \u0443 \u0434\u043e\u0433\u043e\u0432\u043e\u0440\u0430 \u043c\u043e\u0436\u0435\u0442 \u0431\u044b\u0442\u044c \u0437\u0430\u043f\u043e\u043b\u043d\u0435\u043d \u043a\u043e\u043d\u0442\u0440\u0430\u0433\u0435\u043d\u0442 (<code>Customer<\/code>), \u0443 \u043a\u043e\u043d\u0442\u0440\u0430\u0433\u0435\u043d\u0442\u0430 \u043c\u043e\u0436\u0435\u0442 \u0431\u044b\u0442\u044c \u0437\u0430\u043f\u043e\u043b\u043d\u0435\u043d\u0430 \u043a\u0430\u0442\u0435\u0433\u043e\u0440\u0438\u044f. \u0423 \u0434\u043e\u0433\u043e\u0432\u043e\u0440\u0430 \u043c\u043e\u0436\u0435\u0442 \u0431\u044b\u0442\u044c \u043d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u043e \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0439 (<code>ContractAppendix<\/code>).<\/p>\n<p>  <\/p>\n<p>\u0412\u0441\u0435 \u0447\u0442\u043e \u043d\u0443\u0436\u043d\u043e \u0434\u043b\u044f \u0433\u0435\u043d\u0435\u0440\u0430\u0446\u0438\u0438 \u043f\u0435\u0447\u0430\u0442\u043d\u043e\u0439 \u0444\u043e\u0440\u043c\u044b \u2014 \u043e\u043f\u0438\u0441\u0430\u0442\u044c \u043f\u043e\u043b\u044f \u0432 \u0448\u0430\u0431\u043b\u043e\u043d\u0435 \u043f\u0435\u0447\u0430\u0442\u043d\u043e\u0439 \u0444\u043e\u0440\u043c\u044b. \u0421\u043e\u0437\u0434\u0430\u0435\u043c docx \u0444\u0430\u0439\u043b \u0441 \u0442\u0430\u043a\u0438\u043c \u0441\u043e\u0434\u0435\u0440\u0436\u0438\u043c\u044b\u043c<\/p>\n<p>  <\/p>\n<p><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/lp\/eq\/pe\/lpeqpef7yuhs-wocepc9q_4_sgc.png\"><\/p>\n<p>  <\/p>\n<p>\u0412 \u043f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u044b\u0445 \u0443\u043a\u0430\u0437\u044b\u0432\u0430\u0435\u043c \u043d\u0430\u0437\u0432\u0430\u043d\u0438\u044f \u043f\u043e\u043b\u0435\u0439 \u0441\u0443\u0449\u043d\u043e\u0441\u0442\u0435\u0439 Eloquent. \u0415\u0441\u043b\u0438 \u043d\u0443\u0436\u043d\u043e \u0434\u043e\u0431\u0440\u0430\u0442\u044c\u0441\u044f \u043f\u043e \u0441\u0432\u044f\u0437\u044f\u043c \u0434\u043e \u0441\u043e\u0441\u0435\u0434\u043d\u0438\u0445 \u0442\u0430\u0431\u043b\u0438\u0446, \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u043c \u0442\u043e\u0447\u043a\u0443, \u043a\u0430\u043a \u0432 \u043f\u0440\u0438\u043c\u0435\u0440\u0435 \u0432\u044b\u0448\u0435, \u0432 <code>${customer.category.name}<\/code>. <\/p>\n<p>  <\/p>\n<p>\u0415\u0441\u043b\u0438 \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u043e\u0431\u0440\u0430\u0431\u043e\u0442\u0430\u0442\u044c \u0434\u0430\u043d\u043d\u044b\u0435 \u0438\u0437 \u0431\u0430\u0437\u044b, \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u043c \u043e\u043f\u0435\u0440\u0430\u0442\u043e\u0440 \u043a\u043e\u043d\u0432\u0435\u0439\u0435\u0440 <code>|<\/code>, \u043a\u0430\u043a \u0432 \u043f\u0440\u0438\u043c\u0435\u0440\u0435 <code>${number|placeholder}<\/code>. \u0415\u0441\u043b\u0438 \u043d\u0443\u0436\u043d\u043e \u0432\u044b\u043f\u043e\u043b\u043d\u0438\u0442\u044c \u043d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u043e \u043e\u0431\u0440\u0430\u0431\u043e\u0442\u043e\u043a, \u0441\u0442\u0440\u043e\u0438\u043c \u0446\u0435\u043f\u043e\u0447\u043a\u0443 \u043a\u043e\u043d\u0432\u0435\u0439\u0435\u0440\u043e\u0432, \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440 <code>${start_at|date|placeholder}<\/code>.<\/p>\n<p>  <\/p>\n<p>\u041f\u0440\u0438\u043c\u0435\u0440\u044b \u0433\u043e\u0442\u043e\u0432\u044b\u0445 \u043e\u043f\u0435\u0440\u0430\u0446\u0438\u0439<\/p>\n<p>  <\/p>\n<ul>\n<li><code>placeholder<\/code> \u2014 \u0437\u0430\u043c\u0435\u043d\u044f\u0435\u0442 \u043f\u0443\u0441\u0442\u043e\u0435 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 \u043d\u0430 &quot;<strong><strong><strong><strong>____<\/strong><\/strong><\/strong><\/strong>&quot;,<\/li>\n<li><code>date<\/code> \u2014 \u043f\u0440\u0438\u0432\u043e\u0434\u0438\u0442 \u0434\u0430\u0442\u0443 \u043a \u0444\u043e\u0440\u043c\u0430\u0442\u0443 24.12.2020,<\/li>\n<li><code>dateTime<\/code> \u2014 \u043f\u0440\u0438\u0432\u043e\u0434\u0438\u0442 \u0434\u0430\u0442\u0443-\u0432\u0440\u0435\u043c\u044f \u043a \u0444\u043e\u0440\u043c\u0430\u0442\u0443 24.12.2020 23:11,<\/li>\n<li><code>int<\/code> \u2014 \u043f\u0440\u0438\u0432\u043e\u0434\u0438\u0442 \u0446\u0435\u043b\u043e\u0435 \u0447\u0438\u0441\u043b\u043e \u043a \u0444\u043e\u0440\u043c\u0430\u0442\u0443 2`145,<\/li>\n<li><code>decimal<\/code> \u2014 \u043f\u0440\u0438\u0432\u043e\u0434\u0438\u0442 \u0434\u0440\u043e\u0431\u043d\u043e\u0435 \u0447\u0438\u0441\u043b\u043e \u043a \u0444\u043e\u0440\u043c\u0430\u0442\u0443 2`145.07.<\/li>\n<\/ul>\n<p>  <\/p>\n<p>\u0414\u043b\u044f \u0437\u0430\u043f\u043e\u043b\u043d\u0435\u043d\u0438\u044f \u0442\u0430\u0431\u043b\u0438\u0447\u043d\u044b\u0445 \u0434\u0430\u043d\u043d\u044b\u0445 \u0432\u0441\u0442\u0430\u0432\u043b\u044f\u0435\u043c \u043f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u044b\u0435 \u0432 \u0442\u0430\u0431\u043b\u0438\u0446\u0443 \u043a\u0430\u043a \u0432 \u043f\u0440\u0438\u043c\u0435\u0440\u0435 \u0434\u043e\u043a\u0443\u043c\u0435\u043d\u0442\u0430 \u0432\u044b\u0448\u0435. \u0414\u043b\u044f \u043d\u0443\u043c\u0435\u0440\u0430\u0446\u0438\u0438 \u0441\u0442\u0440\u043e\u043a \u0442\u0430\u0431\u043b\u0438\u0446\u044b \u043c\u043e\u0436\u043d\u043e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u043e\u0442\u0434\u0435\u043b\u044c\u043d\u0443\u044e \u043a\u043e\u043d\u0441\u0442\u0440\u0443\u043a\u0446\u0438\u044e <code>${entities.#row_number}<\/code>.<\/p>\n<p>  <\/p>\n<p>\u0422\u0435\u043f\u0435\u0440\u044c, \u043a\u043e\u0433\u0434\u0430 \u0434\u043e\u043a\u0443\u043c\u0435\u043d\u0442 \u043e\u043f\u0438\u0441\u0430\u043d, \u043e\u0441\u0442\u0430\u0435\u0442\u0441\u044f \u043f\u0440\u043e\u0441\u0442\u043e \u0437\u0430\u043f\u0443\u0441\u0442\u0438\u0442\u044c \u0433\u0435\u043d\u0435\u0440\u0430\u0446\u0438\u044e \u043f\u0435\u0447\u0430\u0442\u043d\u043e\u0439 \u0444\u043e\u0440\u043c\u044b<\/p>\n<p>  <\/p>\n<pre><code class=\"php\">use Mnvx\\EloquentPrintForm\\PrintFormProcessor;  $entity = Contract::find($id); $printFormProcessor = new PrintFormProcessor(); $templateFile = resource_path('path_to_print_forms\/your_print_form.docx'); $tempFileName = $printFormProcessor-&gt;process($templateFile, $entity);<\/code><\/pre>\n<p>  <\/p>\n<p>\u0412 \u0441\u0433\u0435\u043d\u0435\u0440\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u043e\u043c \u0444\u0430\u0439\u043b\u0435 <code>$tempFileName<\/code> \u0431\u0443\u0434\u0435\u0442 \u043b\u0435\u0436\u0430\u0442\u044c \u043f\u043e\u0434\u0433\u043e\u0442\u043e\u0432\u043b\u0435\u043d\u043d\u0430\u044f \u043f\u0435\u0447\u0430\u0442\u043d\u0430\u044f \u0444\u043e\u0440\u043c\u0430.<\/p>\n<p>  <\/p>\n<p>\u0412 \u043f\u0440\u043e\u0435\u043a\u0442\u0435 \u043d\u0430 Laravel \u043c\u0435\u0442\u043e\u0434 \u043a\u043e\u043d\u0442\u0440\u043e\u043b\u043b\u0435\u0440\u0430, \u043e\u0442\u0432\u0435\u0447\u0430\u044e\u0449\u0438\u0439 \u0437\u0430 \u0433\u0435\u043d\u0435\u0440\u0430\u0446\u0438\u044e \u043f\u0435\u0447\u0430\u0442\u043d\u043e\u0439 \u0444\u043e\u0440\u043c\u044b, \u043c\u043e\u0436\u0435\u0442 \u0432\u044b\u0433\u043b\u044f\u0434\u0435\u0442\u044c \u0442\u0430\u043a<\/p>\n<p>  <\/p>\n<pre><code class=\"php\">public function downloadPrintForm(FormRequest $request) {     $id = $request-&gt;get('id');     $entity = Contract::find($id);     $printFormProcessor = new PrintFormProcessor();     $templateFile = resource_path('path_to_print_forms\/your_print_form.docx');     $tempFileName = $printFormProcessor-&gt;process($templateFile, $entity);     $filename = 'contract_' . $id;     return response()         -&gt;download($tempFileName, $filename . '.docx')         -&gt;deleteFileAfterSend(); }<\/code><\/pre>\n<p>  <\/p>\n<p>\u0420\u0435\u0437\u044e\u043c\u0438\u0440\u0443\u044f, \u0441\u043a\u0430\u0436\u0443, \u0447\u0442\u043e \u044f \u043f\u0440\u0438\u043b\u0438\u0447\u043d\u043e \u0440\u0430\u0437\u0433\u0440\u0443\u0437\u0438\u043b \u0441\u0435\u0431\u044f, \u0441\u0434\u0435\u043b\u0430\u0432 \u044d\u0442\u0443 \u043d\u0435\u0431\u043e\u043b\u044c\u0448\u0443\u044e \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0443 \u0432 \u043f\u0440\u043e\u0435\u043a\u0442\u0435, \u0433\u0434\u0435 \u0434\u043e\u0432\u043e\u043b\u044c\u043d\u043e \u043c\u043d\u043e\u0433\u043e \u043f\u0435\u0447\u0430\u0442\u043d\u044b\u0445 \u0444\u043e\u0440\u043c. \u041c\u043d\u0435 \u043d\u0435 \u043d\u0430\u0434\u043e \u0434\u043b\u044f \u043a\u0430\u0436\u0434\u043e\u0439 \u0438\u0437 \u043d\u0438\u0445 \u043f\u0438\u0441\u0430\u0442\u044c \u0441\u0432\u043e\u0439 \u0443\u043d\u0438\u043a\u0430\u043b\u044c\u043d\u044b\u0439 \u043a\u043e\u0434. \u042f \u043f\u0440\u043e\u0441\u0442\u043e \u043e\u043f\u0438\u0441\u044b\u0432\u0430\u044e \u043f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u044b\u0435 \u043a\u0430\u043a \u0441\u043a\u0430\u0437\u0430\u043d\u043e \u0432\u044b\u0448\u0435 \u0438 \u0432\u0435\u0441\u044c\u043c\u0430 \u0431\u044b\u0441\u0442\u0440\u043e \u043f\u043e\u043b\u0443\u0447\u0430\u044e \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442. \u0411\u0443\u0434\u0443 \u0440\u0430\u0434, \u0435\u0441\u043b\u0438 \u0438 \u0432\u0430\u043c \u043f\u0430\u043a\u0435\u0442 \u043f\u043e\u043c\u043e\u0436\u0435\u0442 \u0441\u044d\u043a\u043e\u043d\u043e\u043c\u0438\u0442\u044c \u0432\u0440\u0435\u043c\u044f.<\/p>\n<p>  <\/p>\n<p>\u0421\u0441\u044b\u043b\u043a\u0430 \u043d\u0430 \u043f\u0440\u043e\u0435\u043a\u0442 \u043d\u0430 \u0433\u0438\u0442\u0445\u0430\u0431\u0435: <a href=\"https:\/\/github.com\/mnvx\/eloquent-print-form\" rel=\"nofollow\">https:\/\/github.com\/mnvx\/eloquent-print-form<\/a><\/p>\n<\/div>\n<p> \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\/ru\/post\/527356\/\"> https:\/\/habr.com\/ru\/post\/527356\/<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"\n<div class=\"post__text post__text-html post__text_v1\" id=\"post-content-body\">\n<p>\u041d\u0435\u0434\u0430\u0432\u043d\u043e \u0432 \u043f\u0440\u043e\u0435\u043a\u0442\u0435 \u043d\u0430 Laravel+Eloquent \u043f\u043e\u043d\u0430\u0434\u043e\u0431\u0438\u043b\u043e\u0441\u044c \u0441\u0434\u0435\u043b\u0430\u0442\u044c \u043f\u0435\u0447\u0430\u0442\u043d\u044b\u0435 \u0444\u043e\u0440\u043c\u044b \u0434\u043e\u043a\u0443\u043c\u0435\u043d\u0442\u043e\u0432 \u2014 \u0441\u0447\u0435\u0442\u043e\u0432, \u0434\u043e\u0433\u043e\u0432\u043e\u0440\u043e\u0432 \u0432 \u0444\u043e\u0440\u043c\u0430\u0442\u0435 Word. \u0422\u0430\u043a \u043a\u0430\u043a \u0432 \u0441\u0438\u0441\u0442\u0435\u043c\u0435 \u043c\u043d\u043e\u0433\u043e \u0440\u0430\u0437\u043d\u044b\u0445 \u0434\u043e\u043a\u0443\u043c\u0435\u043d\u0442\u043e\u0432, \u0442\u043e \u0440\u0435\u0448\u0438\u043b \u0441\u0434\u0435\u043b\u0430\u0442\u044c \u0443\u043d\u0438\u0432\u0435\u0440\u0441\u0430\u043b\u044c\u043d\u043e, \u0447\u0442\u043e\u0431\u044b \u043c\u043e\u0436\u043d\u043e \u0431\u044b\u043b\u043e \u043f\u043e\u0442\u043e\u043c \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u0438 \u0432 \u0434\u0440\u0443\u0433\u0438\u0445 \u043f\u0440\u043e\u0435\u043a\u0442\u0430\u0445.<\/p>\n<p>  <\/p>\n<p>\u0412 \u0438\u0442\u043e\u0433\u0435 \u043f\u043e\u043b\u0443\u0447\u0438\u043b\u0430\u0441\u044c \u0440\u0435\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u044f, \u043a\u043e\u0442\u043e\u0440\u0430\u044f \u0442\u0440\u0435\u0431\u0443\u0435\u0442 \u043c\u0438\u043d\u0438\u043c\u0443\u043c \u0437\u0430\u0442\u0440\u0430\u0442 \u043d\u0430 \u0438\u043d\u0442\u0435\u0433\u0440\u0430\u0446\u0438\u044e \u0432 \u043f\u0440\u043e\u0435\u043a\u0442.<\/p>\n<p>  <\/p>\n<p><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/z2\/il\/3m\/z2il3mcvwahjkdl5c5nqfm_xr1u.png\"><\/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-312895","post","type-post","status-publish","format-standard","hentry"],"_links":{"self":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/312895","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=312895"}],"version-history":[{"count":0,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/312895\/revisions"}],"wp:attachment":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=312895"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=312895"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=312895"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}