Skip to content

Commit

Permalink
Change Index declaration method
Browse files Browse the repository at this point in the history
  • Loading branch information
blazejpass committed Apr 24, 2024
1 parent 8647f31 commit 6f69fd6
Showing 1 changed file with 1 addition and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ import { BoardDoBuilder, BoardNodeType } from './types';
const PATH_SEPARATOR = ',';

@Entity({ tableName: 'boardnodes', discriminatorColumn: 'type', abstract: true })
@Index({ properties: ['path', 'type'] })
export abstract class BoardNode extends BaseEntityWithTimestamps {
constructor(props: BoardNodeProps) {
super();
Expand All @@ -23,7 +24,6 @@ export abstract class BoardNode extends BaseEntityWithTimestamps {
this.title = props.title;
}

@Index()
@Property({ nullable: false })
path: string;

Expand All @@ -33,7 +33,6 @@ export abstract class BoardNode extends BaseEntityWithTimestamps {
@Property({ nullable: false })
position: number;

@Index()
@Enum(() => BoardNodeType)
type!: BoardNodeType;

Expand Down

0 comments on commit 6f69fd6

Please sign in to comment.