Skip to content

Commit a243f64

Browse files
tabunaactions-user
authored andcommitted
Fix styling
1 parent dbd2e61 commit a243f64

File tree

2 files changed

+9
-6
lines changed

2 files changed

+9
-6
lines changed

src/Filters/HttpFilter.php

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -131,7 +131,7 @@ protected function filtersExact(Builder $query, $value, string $property): Build
131131
$model = $query->getModel();
132132

133133
if ($this->isDate($model, $property)) {
134-
$query->when($value['start'] ?? null, function(Builder $query) use ($property, $value) {
134+
$query->when($value['start'] ?? null, function (Builder $query) use ($property, $value) {
135135
return $query->whereDate($property, '>=', $value['start']);
136136
});
137137
$query->when($value['end'] ?? null, function (Builder $query) use ($property, $value) {
@@ -148,7 +148,7 @@ protected function filtersExact(Builder $query, $value, string $property): Build
148148
$query->whereIn($property, $value);
149149
} elseif ($model->hasCast($property, ['bool', 'boolean'])) {
150150
$query->where($property, (bool)$value);
151-
} elseif (is_numeric($value) && !$model->hasCast($property, ['string'])) {
151+
} elseif (is_numeric($value) && ! $model->hasCast($property, ['string'])) {
152152
$query->where($property, $value);
153153
} else {
154154
$query->where($property, 'like', "%$value%");
@@ -235,14 +235,14 @@ public function getFilter(string $property)
235235
}
236236

237237
/**
238-
* @param Model $model
238+
* @param Model $model
239239
* @param string $property
240240
*
241241
* @return bool
242242
*/
243243
private function isDate(Model $model, string $property): bool
244244
{
245245
return $model->hasCast($property, ['date', 'datetime', 'immutable_date', 'immutable_datetime'])
246-
|| in_array($property,[$model->getCreatedAtColumn(),$model->getUpdatedAtColumn()],true);
246+
|| in_array($property, [$model->getCreatedAtColumn(),$model->getUpdatedAtColumn()], true);
247247
}
248248
}

src/Screen/TD.php

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -254,6 +254,7 @@ protected function detectConstantFilter(string $filter): Field
254254
$input = Input::make()->type($filter);
255255
break;
256256
}
257+
257258
return $input;
258259
}
259260

@@ -293,7 +294,7 @@ public function isAllowUserHidden(): bool
293294
*/
294295
public function buildItemMenu()
295296
{
296-
if (!$this->isAllowUserHidden()) {
297+
if (! $this->isAllowUserHidden()) {
297298
return;
298299
}
299300

@@ -379,7 +380,9 @@ protected function buildFilterString(): ?string
379380
}
380381

381382
if ($this->filterOptions) {
382-
$filter = array_map(function ($val) { return $this->filterOptions[$val] ?? $val; }, $filter);
383+
$filter = array_map(function ($val) {
384+
return $this->filterOptions[$val] ?? $val;
385+
}, $filter);
383386
}
384387

385388
return implode(', ', $filter);

0 commit comments

Comments
 (0)