]> gitweb.erp-flowers.ru Git - erp24_rep/yii-erp24/.git/commitdiff
[ERP-241] вывод во вьюшке остатков по смене origin/feature_smirnov_erp-241_shift_transfer
authorAlexander Smirnov <fredeom@mail.ru>
Wed, 20 Nov 2024 12:44:57 +0000 (15:44 +0300)
committerAlexander Smirnov <fredeom@mail.ru>
Wed, 20 Nov 2024 12:44:57 +0000 (15:44 +0300)
erp24/views/shift-transfer/view.php

index 58c7ab0e145354e65a111d7ba5e66dc0d2643686..bda4cbf24c32f9b6fb955ccc7d016483a96d4eeb 100644 (file)
@@ -56,4 +56,72 @@ use yii_app\records\ShiftTransfer;
         ]
     ]) ?>
 
+    <div class="row">
+        <div class="col-12">
+            <?= \yii\grid\GridView::widget([
+                'dataProvider' => new \yii\data\ArrayDataProvider([
+                    'allModels' => $shiftTransfer->shiftRemains
+                ]),
+                'columns' => [
+                    [
+                        'attribute'  => 'group_label',
+                        'label' => 'Название группы',
+                        'value' => function($data) {
+                            return $data['group_label'] ?? '';
+                        },
+                    ],
+                    [
+                        'attribute'  => 'product_guid',
+                        'label' => 'GUID продукта',
+                        'value' => function($data) {
+                            return $data['product_guid'] ?? '';
+                        },
+                    ],
+                    [
+                        'attribute'  => 'retail_price',
+                        'label' => 'Розничная цена, руб',
+                        'value' => function($data) {
+                            return $data['retail_price'] ?? '';
+                        },
+                    ],
+                    [
+                        'attribute'  => 'self_cost',
+                        'label' => 'Себестоимость, руб',
+                        'value' => function($data) {
+                            return $data['self_cost'] ?? '';
+                        },
+                    ],
+                    [
+                        'attribute'  => 'remains_summ',
+                        'label' => 'Сумма остатков (недостача или излишек), руб',
+                        'value' => function($data) {
+                            return $data['remains_summ'] ?? '';
+                        },
+                    ],
+                    [
+                        'attribute'  => 'remains_count',
+                        'label' => 'Фактические остатки кол-во',
+                        'value' => function($data) {
+                            return $data['remains_count'] ?? '';
+                        },
+                    ],
+                    [
+                        'attribute'  => 'fact_and_1c_diff',
+                        'label' => 'Разница факт и по программе 1с, руб',
+                        'value' => function($data) {
+                            return $data['fact_and_1c_diff'] ?? '';
+                        },
+                    ],
+                    [
+                        'attribute'  => 'remains_1c',
+                        'label' => 'Остатки по 1с, руб',
+                        'value' => function($data) {
+                            return $data['remains_1c'] ?? '';
+                        },
+                    ],
+                ],
+            ]); ?>
+        </div>
+    </div>
+
 </div>