1 2 3 4 5 6 7 8 9 10
import { Column, Entity, PrimaryColumn } from 'typeorm'; @Entity({ name: 'blocks' }) export class Block { @PrimaryColumn() public hash!: string; @PrimaryColumn() public number!: number; @Column({ name: 'unix_timestamp_seconds' }) public unixTimestampSeconds!: number; }