Skip to content

Commit fb2c11d

Browse files
committed
HP-1349: interface issues, fix lang
1 parent 0ab8fc9 commit fb2c11d

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

src/grid/BackupingGridView.php

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -111,23 +111,23 @@ public function columns()
111111
]),
112112
],
113113
'state_label' => [
114+
'attribute' => 'state_label',
114115
'filter' => false,
115116
'enableSorting' => false,
117+
'value' => static fn($model): string => Yii::t('hipanel:hosting', $model->state_label),
116118
],
117119
'backup_last' => [
118120
'filter' => false,
119121
'format' => 'raw',
120-
'value' => static fn($model) => implode(' ', [
121-
Html::tag('nobr', Yii::$app->formatter->asDate($model->backup_last)),
122-
Html::tag('nobr', Yii::$app->formatter->asTime($model->backup_last)),
122+
'value' => fn($model) => implode(' ', [
123+
Html::tag('nobr', $this->formatter->asDate($model->backup_last)),
124+
Html::tag('nobr', $this->formatter->asTime($model->backup_last)),
123125
]),
124126
],
125127
'total_du' => [
126128
'filter' => false,
127129
'format' => 'raw',
128-
'value' => function ($model) {
129-
return Yii::$app->formatter->asShortSize($model->total_du, 2);
130-
},
130+
'value' => fn($model): string => $this->formatter->asShortSize($model->total_du, 2),
131131
],
132132
]);
133133
}

0 commit comments

Comments
 (0)