Skip to content

Commit

Permalink
Merge branch '5.x' into feature/laravel-11
Browse files Browse the repository at this point in the history
  • Loading branch information
luanfreitasdev committed Dec 28, 2023
2 parents 1b7fda4 + f9f6f9d commit f7268d4
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/Commands/Actions/FillableTable.php
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ public static function eloquentBuilder(string $modelQualifiedName, string $model

$title = Str::of($field)->replace('_', ' ')->ucfirst();

if (in_array($columnType, ['datetime', 'date'])) {
if (in_array($columnType, ['datetime', 'date', 'timestamp'])) {
$columns .= ' Column::make(\'' . $title . '\', \'' . $field . '_formatted\', \'' . $field . '\')' . "\n" . ' ->sortable(),' . "\n\n";
}

Expand Down Expand Up @@ -157,7 +157,7 @@ public static function queryBuilder(string $databaseTableName, string $stubFile

$title = Str::of($field)->replace('_', ' ')->ucfirst();

if (in_array($columnType, ['datetime', 'date'])) {
if (in_array($columnType, ['datetime', 'date', 'timestamp'])) {
$columns .= ' Column::make(\'' . $title . '\', \'' . $field . '_formatted\', \'' . $field . '\')' . "\n" . ' ->sortable(),' . "\n\n";
}

Expand Down

0 comments on commit f7268d4

Please sign in to comment.