Code Duplication    Length = 9-9 lines in 2 locations

src/views/tariff/server/view.php 1 location

@@ 31-39 (lines=9) @@
28
                <?php $price = $model->calculation()->price; ?>
29
                <?php $basePrice = $model->parentCalculation()->price; ?>
30
                <td><?= Yii::$app->formatter->asCurrency($price, $model->calculation()->currency) ?></td>
31
                <?php if (Yii::$app->user->can('manage')) : ?>
32
                    <td><?= Yii::$app->formatter->asCurrency($basePrice, $model->parentCalculation()->currency) ?></td>
33
                    <td>
34
                        <?= PriceDifferenceWidget::widget([
35
                            'new' => $price,
36
                            'old' => $basePrice,
37
                        ]) ?>
38
                    </td>
39
                <?php endif; ?>
40
            </tr>
41
            </tbody>
42
        </table>

src/views/tariff/vds/view.php 1 location

@@ 31-39 (lines=9) @@
28
                <?php $price = $model->calculation()->price; ?>
29
                <?php $basePrice = $model->parentCalculation()->price; ?>
30
                <td><?= Yii::$app->formatter->asCurrency($price, $model->calculation()->currency) ?></td>
31
                <?php if (Yii::$app->user->can('manage')) : ?>
32
                    <td><?= Yii::$app->formatter->asCurrency($basePrice, $model->parentCalculation()->currency) ?></td>
33
                    <td>
34
                        <?= PriceDifferenceWidget::widget([
35
                            'new' => $price,
36
                            'old' => $basePrice,
37
                        ]) ?>
38
                    </td>
39
                <?php endif; ?>
40
            </tr>
41
            </tbody>
42
        </table>