mirror of https://github.com/portainer/portainer
20 lines
451 B
TypeScript
20 lines
451 B
TypeScript
import { formatDate } from '@/portainer/filters/filters';
|
|
|
|
import { columnHelper } from './helper';
|
|
|
|
export const created = columnHelper.accessor('CreationDate', {
|
|
header: 'Created',
|
|
cell: ({ row, getValue }) => {
|
|
const date = formatDate(getValue());
|
|
const owner =
|
|
row.original.Labels?.['io.portainer.kubernetes.ingress.owner'];
|
|
|
|
if (owner) {
|
|
return `${date} by ${owner}`;
|
|
}
|
|
|
|
return date;
|
|
},
|
|
id: 'created',
|
|
});
|