Skip to content

Commit

Permalink
🎨 Add created and updated type column to database #9371
Browse files Browse the repository at this point in the history
  • Loading branch information
88250 committed Oct 9, 2023
1 parent 5c2f06d commit 1845799
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions kernel/model/attribute_view.go
Original file line number Diff line number Diff line change
Expand Up @@ -351,10 +351,10 @@ func renderAttributeViewTable(attrView *av.AttributeView, view *av.View) (ret *a
updatedStr := ial["updated"]
updated, parseErr := time.Parse("20060102150405", updatedStr)
if nil == parseErr {
cell.Value.Created = av.NewFormattedValueCreated(updated.UnixMilli(), 0, av.CreatedFormatNone)
cell.Value.Updated = av.NewFormattedValueUpdated(updated.UnixMilli(), 0, av.CreatedFormatNone)
} else {
logging.LogWarnf("parse updated [%s] failed: %s", updatedStr, parseErr)
cell.Value.Created = av.NewFormattedValueCreated(time.Now().UnixMilli(), 0, av.CreatedFormatNone)
cell.Value.Updated = av.NewFormattedValueUpdated(time.Now().UnixMilli(), 0, av.CreatedFormatNone)
}
}
}
Expand Down

0 comments on commit 1845799

Please sign in to comment.